Expand my Community achievements bar.

Enhance your AEM Assets & Boost Your Development: [AEM Gems | June 19, 2024] Improving the Developer Experience with New APIs and Events

Tab stops with justifyed text alignement in TextField


Level 1


I am dynamically filling a paragraph in a TextField divided with a tab stop to mimic a numbered list.

My problem is with text alignment.. I set it to justify and because of that the text renders with an offset larger then the rest of the lines of the text.


What I want to achieve:

1.  This text is offset by a tab

     this line starts at the preset tab-stop

This is what happens

1.     This text is offset by a tab + some offset to fill the line

     this line starts at the preset tab-stop

My paragraph:

<body xmlns="http://www.w3.org/1999/xhtml" xmlns:xfa="http://www.xfa.org/schema/xfa-data/1.0/">

    <p style="text-indent:-0.5cm;tab-stops:left 0cm left 0.5cm;line-height:13pt;text-align:justify;font-family:Arial;font-size:10pt;text-decoration:none">1.<span style="xfa-tab-count:1" />$SOME_DYNAMIC_MULTILINE_TEXT$</p>


My question is how to justify the text so that it always starts at the tab-stop offset?

Thank you!!

0 Replies