Skip to content
Anjunar/ DOCS

Tables

Tables have typed cells, headers and alignment; the live editor now exposes row and column actions.

Concept

Edit the grid

Place the caret in a cell. Add a row or column, align its column, toggle the header, or remove a row, column or whole table. Tab advances through cells and creates a row at the end.

Try the table toolbar

The first row is a header; the inspector shows the updated GFM table after each edit.

Module

Purpose

Core

Document

UI

View

A paragraph after the table.

11 words · 25 nodes
| Module | Purpose | | --- | --- | | Core | Document | | UI | View | A paragraph after the table.
Source

Table commands

InsertTable takes dimensions. Structural commands use the active cell or rectangular TableSelection.

scala
session.dispatch(TableCommands.InsertTable, TableSize(3, 3)) session.dispatch(TableCommands.InsertRow, RowPosition.Below) session.dispatch(TableCommands.InsertColumn, ColumnPosition.After) session.dispatch(TableCommands.ToggleHeaderRow) session.dispatch(TableCommands.SetColumnAlignment, ColumnAlignment.Center) session.dispatch(TableCommands.DeleteRow) session.dispatch(TableCommands.DeleteColumn) session.dispatch(TableCommands.DeleteTable)