OPF
SpecDefinition referenceView source

Table Cell Style

Cell appearance. Sizes use reference pixels at a 720-pixel canvas short edge and scale with the slide.

Metadata

Definition
#/$defs/TableCellStyle
Form
object
Source
spec/schemas/opf.schema.json

Field index

FieldTypeReq.Description
fillref:ColorRef—Cell background: a hex color, a color-scheme slot or role name, or a 'var:<id>' variable reference. Eight-digit hex colors include alpha; #00000000 is transparent.
fill · Named choices (see schema for other values and constraints)
"accent1""accent2""accent3""accent4""accent5""accent6""dark1""dark2""light1""light2""hyperlink""followedHyperlink""primary""secondary""accent""background""surface""surfaceAlt""text""textSecondary"
colorref:ColorRef—Default text color, overridden by individual rich run colors. Accepts a hex color, a color-scheme slot or role name, or a 'var:<id>' variable reference.
color · Named choices (see schema for other values and constraints)
"accent1""accent2""accent3""accent4""accent5""accent6""dark1""dark2""light1""light2""hyperlink""followedHyperlink""primary""secondary""accent""background""surface""surfaceAlt""text""textSecondary"
boldboolean—Bold cell text. Runs that set their own bold keep it; a number cell stays bold and still uses the cell's or column's number format.
alignenum—Horizontal text alignment inside the cell.
align · Allowed values
"left""center""right"
verticalAlignenum—Vertical alignment inside the padded cell box.
verticalAlign · Allowed values
"top""middle""bottom"
paddingref:TableCellPadding—
bordersobject—Independent cell edges. Omitted edges retain the table theme border; width 0 removes an edge.

fill

typeref:ColorRefrequirednodefault—

Cell background: a hex color, a color-scheme slot or role name, or a 'var:<id>' variable reference. Eight-digit hex colors include alpha; #00000000 is transparent.

fill · Named choices (see schema for other values and constraints)
"accent1""accent2""accent3""accent4""accent5""accent6""dark1""dark2""light1""light2""hyperlink""followedHyperlink""primary""secondary""accent""background""surface""surfaceAlt""text""textSecondary"

color

typeref:ColorRefrequirednodefault—

Default text color, overridden by individual rich run colors. Accepts a hex color, a color-scheme slot or role name, or a 'var:<id>' variable reference.

color · Named choices (see schema for other values and constraints)
"accent1""accent2""accent3""accent4""accent5""accent6""dark1""dark2""light1""light2""hyperlink""followedHyperlink""primary""secondary""accent""background""surface""surfaceAlt""text""textSecondary"

bold

typebooleanrequirednodefault—

Bold cell text. Runs that set their own bold keep it; a number cell stays bold and still uses the cell's or column's number format.

align

typeenumrequirednodefault—

Horizontal text alignment inside the cell.

align · Allowed values
"left""center""right"
Field fragment · align.json
{
  "align": "left"
}

verticalAlign

typeenumrequirednodefault—

Vertical alignment inside the padded cell box.

verticalAlign · Allowed values
"top""middle""bottom"
Field fragment · verticalAlign.json
{
  "verticalAlign": "top"
}

padding

typeref:TableCellPaddingrequirednodefault—

borders

typeobjectrequirednodefault—

Independent cell edges. Omitted edges retain the table theme border; width 0 removes an edge.

borders.top.color · Named choices (see schema for other values and constraints)
"accent1""accent2""accent3""accent4""accent5""accent6""dark1""dark2""light1""light2""hyperlink""followedHyperlink""primary""secondary""accent""background""surface""surfaceAlt""text""textSecondary"
borders.top.dash · Allowed values
"solid""dash""dot"
Complete definition constraints
Exact schema constraints
{
  "type": "object",
  "additionalProperties": false,
  "properties": {
    "fill": {
      "$ref": "#/$defs/ColorRef",
      "description": "Cell background: a hex color, a color-scheme slot or role name, or a 'var:<id>' variable reference. Eight-digit hex colors include alpha; #00000000 is transparent."
    },
    "color": {
      "$ref": "#/$defs/ColorRef",
      "description": "Default text color, overridden by individual rich run colors. Accepts a hex color, a color-scheme slot or role name, or a 'var:<id>' variable reference."
    },
    "bold": {
      "type": "boolean",
      "description": "Bold cell text. Runs that set their own bold keep it; a number cell stays bold and still uses the cell's or column's number format."
    },
    "align": {
      "type": "string",
      "enum": [
        "left",
        "center",
        "right"
      ],
      "description": "Horizontal text alignment inside the cell."
    },
    "verticalAlign": {
      "type": "string",
      "enum": [
        "top",
        "middle",
        "bottom"
      ],
      "description": "Vertical alignment inside the padded cell box."
    },
    "padding": {
      "$ref": "#/$defs/TableCellPadding"
    },
    "borders": {
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "top": {
          "$ref": "#/$defs/TableCellBorder"
        },
        "right": {
          "$ref": "#/$defs/TableCellBorder"
        },
        "bottom": {
          "$ref": "#/$defs/TableCellBorder"
        },
        "left": {
          "$ref": "#/$defs/TableCellBorder"
        }
      },
      "description": "Independent cell edges. Omitted edges retain the table theme border; width 0 removes an edge."
    }
  },
  "description": "Cell appearance. Sizes use reference pixels at a 720-pixel canvas short edge and scale with the slide."
}