version 6.5
WR ADD TAB (area; position; justification; fillCharacter)
| Parameter | Type | Description | |
| area | Longint | 4D Write area | |
| position | Number | Tab location | |
| justification | Integer | Justification value | |
| fillCharacter | Alpha | Selected fill character |
Description
The WR ADD TAB command allows you to add a new tab at the location passed in position, measured from the left margin of the document. It also allows you to to define the fill character and the justification of the new tab stop.
This tab stop will be added to all the paragraphs of the selection. If a tab stop already exist at this location, it will be replaced by the one you just created.
position is the distance from the left margin (expressed in the document's default unit).
The justification optional parameter determines the tab stop type. You can either use the value or one of the following predefined constants.
| Value | Constant | Text alignment |
| 1 | wr left tab | Left aligned |
| 2 | wr centered tab | Centered |
| 3 | wr right tab | Right aligned |
| 4 | wr decimal tab | Decimal |
| 5 | wr vertical separator tab | Vertical separator |
If justification is omitted, a left aligned tab is created.
Note: The list of constants and their values is available in the "WR Tabs" constants theme. You can either pass a constant name or its value.
The fillCharacter optional parameter can be any character whose ASCII code is between 33 and 127. This character will be added using the same font as the tab stop.
If fillCharacter is omitted or if you pass an empty string, no fill character will be inserted.
Example
The following example create a left tab stop, 50 units away from the left margin with a dot as fill character.
WR ADD TAB (area;50;1;".") `or WR ADD TAB (area;50;wr left tab;".")
See also
WR ADD STYLESHEET TAB, WR DELETE TAB.