Declined
Last Updated: 04 Dec 2017 08:26 by ADMIN
Conor
Created on: 01 Jun 2016 21:27
Type: Feature Request
2
Text Boxes word-wrap / line-breaks
Would it be possible to prioritize which characters can "Break" when wrapping text inside a text box?  For example "foobar/foobar" will not break at the slash, it'll instead break at the character that hits the width limit. It would be my suggestion that punctuation be prioritized for "breaking" before all other characters, in the event that there is no space.

In the attached example, the column headers are dynamic (localized), and there's no way to predict what the text will look like (in whatever language)... Though I accept that no matter what, a string longer than the textbox width will need to break somewhere, I'd prefer that you break on "better" characters if they are present.

(Pretty nitpicky, I know, but this would save me trying to code the logic into an expression or function... which could prove complicated due to variable width of fonts)
Attached Files:
1 comment
ADMIN
Milen | Product Manager @DX
Posted on: 04 Dec 2017 08:26
Hi, Text rendering is done using the Graphics.DrawString method with wrapping by word setting. In other words, the decision of wrapping is delegated to an external library. Fitting the words on our side would be error-prone and very slow (we basically should measure each chunk that we consider a word so that we can fit it on the current line or move it to the next one), and we cannot afford that. The best approach will be to ensure the input text of the report has proper white spaces included with each punctuation symbol.