[Table of Contents] [docx version]

WordprocessingML Reference Material - Table of Contents

ptab (Absolute Position Tab Character)

This element specifies that an absolute position tab character shall be placed at the current location in the run content. An absolute position tab is a character which is used to advance the position on the current line of text when displaying this WordprocessingML content, using the following logic:

Regardless of any number of custom tab stops defined using the tabs element (§2.3.1.38) , the absolute position tab character shall advance to the position specified by its alignment and relativeTo attributes. The resulting end position of the tab character shall not be affected by the addition of any custom tab stops or changes to the value of the defaultTabStop element (§2.15.1.24).

If the alignment location specified by the positional tab cannot be found on the current line, because the starting location is past that point, then the tab character shall advance to that location on the next available line in the document.

[Example: Consider a paragraph which contains two custom tab stops at 1.5" and 3.5", respectively. These two tab stops would be contained within a tabs element defining the set of tab stops of the paragraph as follows:

<w:pPr>

<w:tabs>

<w:tab w:val="left" w:pos="2160" />

<w:tab w:val="left" w:pos="5040" />

</w:tabs>

</w:pPr>

If a positional tab character was added to a run in this paragraph starting at 1” inside the margin and was defined as follows:

<w:ptab w:alignment="center" w:relativeTo="margin" />

This positional tab would then ignore the next custom tab stop and the indents on the current paragraph defined using the ind element (§2.3.1.12) and would advance to the center of the line with respect to the text margins, moving to a new line if needed. end example]

Parent Elements

r7.1.2.87); r2.3.2.23)

 

Attributes

Description

alignment (Positional Tab Stop Alignment)

Specifies the location of the positional tab stop on the line, as well as the alignment which shall be applied to text subsequent to the current positional tab stop.

 

[Example: Consider a positional tab stop in a WordprocessingML document who shall move to the left edge of the text margins and whose subsequent text should be left aligned. This positional tab stop would be defined as follows:

 

<w:ptab w:alignment="left" w:relativeTo=”margin” … />

 

The alignment attribute specifies that this absolute position tab stop shall align on the left edge of the line relative to the margin. end example]

 

The possible values for this attribute are defined by the ST_PTabAlignment simple type2.18.78).

leader (Tab Leader Character)

Specifies the character which shall be used to fill in the space created by a positional tab. This character shall be repeated as required to completely fill the tab spacing generated by the positional tab character.

 

[Example: Consider a positional tab stop which should be preceded by a sequence of underscore characters, as follows:

 

______________Text at the positional tab stop

 

This tab stop would have a leader attribute value of underscore, indicating that the tab stop shall be preceded by underscore characters as needed to fill the tab spacing. end example]

 

The possible values for this attribute are defined by the ST_PTabLeader simple type2.18.79).

relativeTo (Positional Tab Base)

Specifies the extents which shall be used to calculate the absolute positioning of this positional tab character.

 

[Example: Consider a positional tab stop in a WordprocessingML document that should have a resulting position that is centered on the text margins, ignoring both any custom tab stops and any text indents on the paragraph. This positional tab stop would be defined as follows:

 

<w:ptab w:relativeTo="margin" … />

 

The relativeTo attribute specifies that this absolute position tab stop shall be relative to the margin. end example]

 

The possible values for this attribute are defined by the ST_PTabRelativeTo simple type2.18.80).

The following XML Schema fragment defines the contents of this element:

<complexType name="CT_PTab">

   <attribute name="alignment" type="ST_PTabAlignment" use="required"/>

   <attribute name="relativeTo" type="ST_PTabRelativeTo" use="required"/>

   <attribute name="leader" type="ST_PTabLeader" use="required"/>

</complexType>