Table of contents
TOC
折叠目录
展开目录

ParagraphFormat.Tabs 属性 (发布服务器)ParagraphFormat.Tabs Property (Publisher)

office 365 dev account|上次更新日期: 2018/3/13
|
2 参与人员

返回TabStops表示自定义的对象和默认为一个段落或一组段落的选项卡。Returns a TabStops object representing the custom and default tabs for a paragraph or group of paragraphs.

语法Syntax

表达式选项卡expression. Tabs

_expression_A 表示ParagraphFormat对象的变量。_expression_A variable that represents a ParagraphFormat object.

返回值Return Value

TabStopsTabStops

示例Example

以下示例将两个制表位添加到选定段落。第一个制表位是带有划线制表符前导符的左对齐制表符,位于 1 英寸(72 磅)位置。第二个制表位居中对齐,位于 2 英寸位置。The following example adds two tab stops to the selected paragraphs. The first tab stop is a left-aligned tab with a dotted tab leader positioned at 1 inch (72 points). The second tab stop is centered and is positioned at 2 inches.

Dim tabsAll As TabStops 

Set tabsAll = Selection.TextRange.ParagraphFormat.Tabs 

With tabsAll 
 .Add Position:=InchesToPoints(1), _ 
 Leader:=pbTabLeaderDot, Alignment:=pbTabAlignmentLeading 
 .Add Position:=InchesToPoints(2), _ 
 Leader:=pbTabLeaderNone, Alignment:=pbTabAlignmentCenter 
End With
© 2018 Microsoft