- Print
- PDF
Rearrange Properties (Text Alignment)
Let us now consider how to align text inside a fixed-size box by using the Text vertical and horizontal alignment settings.
Text horizontal alignment
The setting implies a horizontal alignment of a text within the text box.
Text vertical alignment
The setting implies a vertical alignment of a text within the text box.
Exercise
Download and import the attached configuration called 06. Rearrange Properties (Text Alignment) in Lasernet Developer 9. Afterward, navigate to the Forms section, and then open the Sample form.
Add a new Rearrange that is similar to the one you can see in the following image:
Specify the following settings for the Rearrange you have just added.
Set Size type to Auto Y.
Set the X position to 30, Y to 40, and Width to 55.
For Box horizontal alignment, ensure the Left check box is selected. It is selected by default.
For Box vertical alignment, ensure the Top check box is selected. It is selected by default.
For Overflow, select the Force line break radio button.
Ensure that now you have a text available in a left-top aligned box.
Copy and paste the Rearrange. For a Rearrange copy, specify the following position settings: X to 150 and Y to 40.
Edit the Rearrange properties and set Box horizontal alignment to Right.
Edit the Rearrange properties and set Text horizontal alignment to Right.
Note
The box text alignment can also be set via the Property bar.
Select Rearranges. To this end, use the Select tool. Ensure it is selected on the Developer toolbar. Afterward, hold down CTRL and click each Rearrange. Right-click a selection, and then click Copy. Move a cursor to the following position: X = 30 mm and Y = 130 mm. Right-click at the cursor position, and then click Paste.
Select the Rearrange located in the bottom left-hand corner and set Text horizontal alignment to Center.
Select the Rearrange located in the bottom right-hand corner and set Text horizontal alignment to Justified.
Four Rearrange text blocks are now aligned in the text boxes as illustrated in the following image:
Select the Rearrange located in the bottom left-hand corner.
Edit the Rearrange settings and set Size type to Manual.
Set the X position to 30, Y to 103, Width to 55, and Height to 30.
When Size type is set to Manual, the Text vertical alignment setting is enabled. Set the Text vertical alignment setting to Bottom.
Select the Rearrange located in the bottom right-hand corner.
Edit the Rearrange settings and set Size type to Manual.
Set the X position to 150, Y to 103, Width to 55, and Height to 60.
Set the Text vertical alignment setting to Middle.
Four Rearrange text blocks are now aligned in the text boxes as illustrated in the following image: