跳到主要内容

ApiRichParagraph

表示富文本段落的类。

ApiRichParagraph 是 ApiRichParaPr 的子类。

方法​

下表列出了可用的方法。

方法返回值描述
AddElementboolean向当前段落添加元素。
AddTextApiRichRun向当前段落添加文本。
CopyApiRichParagraph创建段落副本。
Deleteboolean删除当前段落。
GetClassType"richParagraph"返回 ApiRichParagraph 类的类型。
GetElementApiRichRun | null | undefined使用指定的位置返回段落元素。
GetElementsCountnumber返回当前段落中的元素数量。
GetJcHorTextAlign返回富文本段落内容的对齐方式。
GetLastRunWithTextApiRun返回当前段落中最后一个包含文本的 Run。
GetNextApiRichParagraph | null | undefined返回下一个段落。
GetParaPrApiRichParaPr返回段落属性。
GetPosInParentNumber返回段落在其父元素中的位置。
GetPreviousApiRichParagraph | null | undefined返回上一个段落。
GetTextstring返回段落文本。
LastApiRichRun返回段落的最后一个元素。
Pushboolean向当前段落添加元素。
RemoveAllElementsboolean从当前段落中移除所有元素。
RemoveElementboolean使用指定的位置移除元素。
SetJcboolean设置富文本段落内容的对齐方式。
SetParaPrboolean设置段落属性。
SetReadingOrderApiRichParagraph指定当前段落的阅读顺序。