International Language Environments Guide

Horizontal Tabs

A compound string can contain tab characters that control the placement of text. To interpret those characters on display, a widget refers the a list of tab stops to the rendition in effect for that compound string. However, the dynamic widgets TextField and XmText do not use the tab resource of the rendition. Instead, the widgets compute the tab width using the formula of 8*(width of character 0).

The tab measurement is the distance from the left margin of the compound string display. This distance is measured from the right margin, if the layout direction is right-to-left. Regardless of the direction of the text (Arabic right-to-left or English left-to-right), the tab inserts space to the right or left as specified by the layout direction (XmNlayoutDirection).

The text following a tab is always aligned at the tab stop. The tab stop is calculated from the start of the widget, which in turn is influenced by XmNlayoutDirection. The behavior of the tabs and their interaction with directionality of the text and the XmNlayoutDirection of the widget is illustrated in the following figure.

The input for this illustration is abc\tdef\tgh.

Figure 6–3 Tabbing Behavior

The figure illustrates the appearance of tabs in left-to-right
and right-to-left text.