Home
Analytics
Wrapped text in a right-aligned column does not line up correctly
ChrisXL
<p>I have a Label control in the header row of a narrow column, containing a long string of text, with each word being long enough to fill the cell. The control and cell are set to align right, with auto whitespace.</p>
<p> </p>
<p>For PDF output only, all bar the first and last lines of the wrapped text are indented slightly from the right of the cell:</p>
<p> </p>
<p>
Find more posts tagged with
Comments
mwilliams
<p>You could always try something like this in the onCreate script:</p>
<pre class="_prettyXprint _linenums:0">
this.text = this.text.replaceAll(" ","\n");</pre>
<p>This should get rid of the space that is the character that's staying on the line with each word forcing it to be "indented" to the left.</p>
<p> </p>
<p>The problem with this solution would be if you have shorter words that can both fit on a single line.</p>