ApiParagraph
Represents the ApiParagraph class.
Methods
Method | Returns | Description |
---|---|---|
AddElement | boolean | Adds an element to the current paragraph. |
AddLineBreak | ApiRun | Adds a line break to the current position and starts the next element from a new line. |
AddTabStop | ApiRun | Adds a tab stop to the current paragraph. |
AddText | ApiRun | Adds some text to the current paragraph. |
Copy | ApiParagraph | Creates a paragraph copy. Ingnore comments, footnote references, complex fields. |
Delete | boolean | Deletes the current paragraph. |
GetClassType | "paragraph" | Returns a type of the ApiParagraph class. |
GetClassType | "paraPr" | Returns a type of the ApiParaPr class. |
GetElement | ParagraphContent | Returns a paragraph element using the position specified. |
GetElementsCount | number | Returns a number of elements in the current paragraph. |
GetIndFirstLine | twips | undefined | Returns the paragraph first line indentation. |
GetIndLeft | twips | undefined | Returns the paragraph left side indentation. |
GetIndRight | twips | undefined | Returns the paragraph right side indentation. |
GetJc | "left" | "right" | "both" | "center" | undefined | Returns the paragraph contents justification. |
GetNext | ApiParagraph | null | Returns the next paragraph. |
GetOutlineLvl | Number | Returns the outline level of the specified properties. |
GetParaPr | ApiParaPr | Returns the paragraph properties. |
GetPrevious | ApiParagraph | Returns the previous paragraph. |
GetSpacingAfter | twips | Returns the spacing after value of the current paragraph. |
GetSpacingBefore | twips | Returns the spacing before value of the current paragraph. |
GetSpacingLineRule | "auto" | "atLeast" | "exact" | undefined | Returns the paragraph line spacing rule. |
GetSpacingLineValue | twips | line240 | undefined | Returns the paragraph line spacing value. |
RemoveAllElements | None | Removes all the elements from the current paragraph.\ 💡 When all the elements are removed from the paragraph, a new empty run is automatically created. If you want to add\ content to this run, use the ApiParagraph#GetElement method. |
RemoveElement | None | Removes an element using the position specified.\ 💡 If the element you remove is the last paragraph element (i.e. all the elements are removed from the paragraph),\ a new empty run is automatically created. If you want to add\ content to this run, use the ApiParagraph#GetElement method. |
SetBullet | None | Sets the bullet or numbering to the current paragraph. |
SetHighlight | ApiParagraph | Specifies a highlighting color which is applied as a background to the contents of the current paragraph. |
SetIndFirstLine | None | Sets the paragraph first line indentation. |
SetIndLeft | None | Sets the paragraph left side indentation. |
SetIndRight | None | Sets the paragraph right side indentation. |
SetJc | None | Sets the paragraph contents justification. |
SetOutlineLvl | boolean | Sets the outline level for the specified properties. |
SetSpacingAfter | None | Sets the spacing after the current paragraph. If the value of the isAfterAuto parameter is true, then \ any value of the nAfter is ignored. If isAfterAuto parameter is not specified, then it \ will be interpreted as false. |
SetSpacingBefore | None | Sets the spacing before the current paragraph. If the value of the isBeforeAuto parameter is true, then \ any value of the nBefore is ignored. If isBeforeAuto parameter is not specified, then \ it will be interpreted as false. |
SetSpacingLine | None | Sets the paragraph line spacing. If the value of the sLineRule parameter is either \ "atLeast" or "exact", then the value of nLine will be interpreted as twentieths of a point. If \ the value of the sLineRule parameter is "auto", then the value of the \ nLine parameter will be interpreted as 240ths of a line. |
SetTabs | None | Specifies a sequence of custom tab stops which will be used for any tab characters in the current paragraph.\ -Warning: The lengths of aPos array and aVal array -MUST BE equal to each other. |