w:adjustRightInd (Auto-Adjust Right Indent for Document Grid)
Automatically adjusts the right indent of a paragraph to align with the document grid column width.
Parent elements
Description
w:adjustRightInd is a toggle property that instructs the processor to automatically expand the right indent of a paragraph to align with the nearest grid column boundary defined by the document grid (w:docGrid in w:sectPr). This ensures that East Asian paragraphs set on a character grid end flush with the grid rather than leaving a fractional gap.
It is defined in ECMA-376 Part 1 §17.3.1.1.
Attributes
| Attribute | Type | Possible Values | Description |
|---|---|---|---|
w:val |
ST_OnOff |
true, false, 1, 0, on, off |
Enables automatic right-indent adjustment. Omit to inherit. |
Examples
<w:p>
<w:pPr>
<w:adjustRightInd/>
</w:pPr>
<w:r><w:t>右インデントをドキュメントグリッドに自動調整する段落。</w:t></w:r>
</w:p>
using DocumentFormat.OpenXml.Wordprocessing;
var para = new Paragraph(
new ParagraphProperties(
new AdjustRightIndent()
),
new Run(new Text("右インデントをドキュメントグリッドに自動調整する段落。"))
);
Notes
- This property is primarily relevant for East Asian documents that use a character-pitch document grid.
- Has no visible effect when no document grid is defined in
w:sectPr.