ApiTableCell
class ApiTableCell extends ApiTableCellPr
Description
Class representing a table cell.
Instance Methods
- GetClassType
(): tableCell
Returns a type of the ApiTableCell class.
- GetContent
(): ApiDocumentContent
Returns the current cell content.
- GetIndex
(): Number
Returns the current cell index.
- GetRowIndex
(): number
Returns an index of the parent row.
- GetParentRow
(): ApiTableRow | "null"
Returns a parent row of the current cell.
- GetParentTable
(): ApiTable | "null"
Returns a parent table of the current cell.
- AddRows
(nCount, isBefore): ApiTable | "null"
Adds the new rows to the current table.
- AddColumns
(nCount, isBefore): ApiTable | "null"
Adds the new columns to the current table.
- RemoveColumn
(): bool | "null"
Removes a column containing the current cell.
- RemoveRow
(): boolean
Removes a row containing the current cell.
- Search
(sText, isMatchCase): ApiRange[]
S.
- GetNext
(): ApiTableCell | "null"
Returns the next cell if exists.
- GetPrevious
(): ApiTableCell | "null"
Returns the previous cell if exists.
- Split
(nRow, nCol): ApiTable | "null"
Splits the cell into a given number of rows and columns.
- SetCellPr
(oApiTableCellPr): boolean
Sets the cell properties to the current cell.
- SetTextPr
(oTextPr): boolean
Applies the text settings to the entire contents of the current cell.
- Clear
(): boolean
Clears the content from the current cell.
- AddElement
(nPos, oElement): boolean
Adds a paragraph or a table or a blockLvl content control using its position in the cell.
- SetBackgroundColor
(r, g, b, bNone): boolean
Sets the background color to the current table cell.
- SetColumnBackgroundColor
(r, g, b, bNone): boolean
Sets the background color to all cells in the column containing the current cell.
- SetShd
(sType, r, g, b, isAuto)
Specifies the shading applied to the contents of the table cell.
- SetCellMarginBottom
(nValue)
Specifies an amount of space which will be left between the bottom extent of the cell contents and the border of a specific table cell within a table.
- SetCellMarginLeft
(nValue)
Specifies an amount of space which will be left between the left extent of the cell contents and the border of a specific table cell within a table.
- SetCellMarginRight
(nValue)
Specifies an amount of space which will be left between the right extent of the cell contents and the border of a specific table cell within a table.
- SetCellMarginTop
(nValue)
Specifies an amount of space which will be left between the upper extent of the cell contents and the border of a specific table cell within a table.
- SetCellBorderBottom
(sType, nSize, nSpace, r, g, b)
Sets the border which will be displayed at the bottom of the current table cell.
- SetCellBorderLeft
(sType, nSize, nSpace, r, g, b)
Sets the border which will be displayed to the left of the current table cell.
- SetCellBorderRight
(sType, nSize, nSpace, r, g, b)
Sets the border which will be displayed to the right of the current table cell.
- SetCellBorderTop
(sType, nSize, nSpace, r, g, b)
Sets the border which will be displayed at the top of the current table cell.
- SetWidth
(sType, nValue)
Sets the preferred width to the current table cell.
- SetVerticalAlign
(sType)
Specifies the vertical alignment for the text contents within the current table cell.
- SetTextDirection
(sType)
Specifies the direction of the text flow for this table cell.
- SetNoWrap
(isNoWrap)
S.
- ToJSON
()
Converts the ApiTableCellPr object into the JSON object.
Extends
- ApiTableCellPr
Class representing the table cell properties.