Skip to main content

Module col

Module col 

Source
Expand description

Column operations for worksheet manipulation.

All functions operate directly on a WorksheetXml structure, keeping the business logic decoupled from the Workbook wrapper.

Functionsยง

get_col_outline_level
Get the outline (grouping) level of a column. Returns 0 if not set.
get_col_style
Get the style ID for a column. Returns 0 (default) if the column has no explicit style set.
get_col_visible
Get the visibility of a column. Returns true if visible (not hidden).
get_col_width
Get the width of a column. Returns None when there is no explicit width defined for the column.
get_cols
Get all columns with their data from a worksheet.
insert_cols
Insert count columns starting at col, shifting existing columns at and to the right of col further right.
remove_col
Remove a single column, shifting columns to its right leftward by one.
set_col_outline_level
Set the outline (grouping) level of a column.
set_col_style
Set the style for an entire column. The style_id is the ID returned by add_style().
set_col_visible
Set the visibility of a column.
set_col_width
Set the width of a column. Creates the Cols container and/or a Col entry if they do not yet exist.