Print textarea content in justify alignment in a dynamic document



LiveCycle Designer

I have a UI that has a text area for User Comments/Feedback, and the response is mapped to a dynamic form that is generated when the form is submitted. Now, the User comments should be displayed in 'Justify Alignment' on the document. But there is a glitch, that is - if the user enters his comments in points or paragraphs, then on the document the newline between the points/paragraphs is not identified. As a result, if a sentence ends in the middle of the page, the half line is stretched along the width of the page (due to justify alignment). Is there a way to counter this issue? Can I print the text area content in justify alignment on the document, irrespective of the way the user enters its comments?

Accepted Solutions (0)

Answers (4)

Answers (4)




if you add paragraph separator entities (
) to the xml source, the last line of a paragraph will be left aligned.


              <text>Sed consequat, leo eget bibendum sodales, augue velit cursus nunc, quis gravida magna mi a libero.&#x2029;            

Praesent adipiscing. Nullam nulla eros, ultricies sit amet, nonummy id, imperdiet feugiat, pede. Vestibulum facilisis, purus nec pulvinar iaculis, ligula mi congue nunc, vitae euismod ligula urna in dolor. Aenean massa.&#x2029;

Fusce risus nisl, viverra et, tempor et, pretium in, sapien. Curabitur nisi. Praesent metus tellus, elementum eu, semper a, adipiscing nec, purus. Fusce convallis metus id felis luctus adipiscing.&#x2029;

Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos hymenaeos. Etiam ultricies nisi vel augue. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo.&#x2029;

Aenean ut eros et nisl sagittis vestibulum. Sed libero. Proin magna. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</text>


The displayed result will be




I am having:

<para hAlign="justify"/>

in my xml, and I think that is why when I enter 2 paragraphs on UI, the last line of paragraph 1 fills the text area from left to right. While the last line of my entire text (i.e. the last line of paragraph 2) is left aligned.

Could you provide a work around for the last line of paragraph 1?




There a two different mehtods to justify texts.


For each line, instead of incorporating the

supplied white space characters, blank regions

are inserted between layout units, one per

breaking whitespace character in the original

text, sized, until the line fills the region from left

to right. The effect is the same regardless of the

flow direction.

<para hAlign="justifyAll"/>


All lines are justified except the last one in the

paragraph. The last line is left aligned if the

initial flow direction of the line is left to right

and right aligned if the initial flow direction is

right to left relative to the containing subform’s

layout attribute.

<para hAlign="justify"/>

Note: You cannot set all alignment methods from Designers UI but from the XML source.

<field name="Textfield1" y="3.175mm" x="3.175mm" w="196.85mm" h="79.375mm">


               <textEdit multiLine="1">


                     <edge stroke="lowered"/>





            <font typeface="Myriad Pro"/>

            <margin topInset="1mm" bottomInset="1mm" leftInset="1mm" rightInset="1mm"/>

            <para hAlign="justifyAll"/>

            <caption reserve="25mm">

               <para hAlign="justify"/>


                  <text>Text Field</text>




               <text>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium. Integer tincidunt. Cras dapibus. Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus.</text>