Class OdfList
Represents a list in a text document. 表示文字文件中的清單。
public class OdfList
- Inheritance
-
OdfList
- Inherited Members
Properties
ContinueNumbering
Gets or sets a value indicating whether the list numbering continues from the previous list. 取得或設定一個值,指出清單編號是否延續上一清單。
public bool? ContinueNumbering { get; set; }
Property Value
- bool?
Items
Gets the list of list items. 取得清單專案清單。
public IReadOnlyList<OdfListItem> Items { get; }
Property Value
StyleName
Gets or sets the style name of this list. 取得或設定此清單的樣式名稱。
public string? StyleName { get; set; }
Property Value
Methods
AddItem(string)
Short overload of AddItem that accepts text; remaining optional parameters use defaults and forward to the full overload. 便利多載:提供 text;其餘可選參數使用預設值並轉呼叫最長 AddItem 多載。
public OdfListItem AddItem(string text)
Parameters
textstring
Returns
AddItem(string, int)
Adds item. 在指定層級新增清單專案(1-based)。層級 1 直接加入此清單;
public OdfListItem AddItem(string text, int level)
Parameters
textstringThe item text content. / 專案文字內容。
levelintThe target level, starting from 1, with a maximum of 10. / 目標層級,從 1 開始,最大值為 10。
Returns
- OdfListItem
The newly created list item. / 新建立的清單專案。
AddListItem()
Short overload of AddListItem that uses default values for all optional parameters and forwards to the full overload. 便利多載:AddListItem 的所有可選參數使用預設值並轉呼叫最長多載。
public OdfListItem AddListItem()
Returns
AddListItem(string)
Adds a list item to the list. 在清單中新增清單專案。
public OdfListItem AddListItem(string text)
Parameters
textstringThe default paragraph text content of the item. / 專案預設段落文字內容。
Returns
- OdfListItem
The newly created list item instance. / 新建立的清單專案執行個體。
RestartNumbering()
Short overload of RestartNumbering that uses default values for all optional parameters and forwards to the full overload. 便利多載:RestartNumbering 的所有可選參數使用預設值並轉呼叫最長多載。
public void RestartNumbering()
RestartNumbering(int)
Restarts the list's numbering. 重新開始清單的編號。
public void RestartNumbering(int startValue)
Parameters
startValueintThe start value. / 開始數值。
StartFrom(int)
Sets the starting number of the list. 設定清單的起始編號。
public OdfList StartFrom(int value)
Parameters
valueintThe start number; ODF 1.4 allows starting from 0. / 起始編號;ODF 1.4 允許從 0 開始。
Returns
- OdfList
The current list instance. / 目前清單執行個體。