Core types

Integral types

using orcus::spreadsheet::row_t = int32_t

Row ID type.

using orcus::spreadsheet::col_t = int32_t

Column ID type.

using orcus::spreadsheet::sheet_t = int32_t

Sheet ID type.

using orcus::spreadsheet::color_elem_t = uint8_t

Individual color element type.

using orcus::spreadsheet::col_width_t = uint16_t

Type for column width values. Column width values are stored in twips.

using orcus::spreadsheet::row_height_t = uint16_t

Type for row height values. Row height values are stored in twips.

using orcus::spreadsheet::pivot_cache_id_t = uint32_t

Pivot cache ID type.

Structs

struct address_t

Stores a 2-dimensional cell address.

Public Members

row_t row
col_t column
struct range_size_t

Stores the size of a range of a spreadsheet.

Public Members

row_t rows
col_t columns
struct range_t

Stores a 2-dimensional cell range by storing the positions of the top-left and bottom-right corners of the range.

Public Members

address_t first
address_t last
struct src_address_t

Stores 3-dimensional cell address. The ‘src’ abbreviation stands for sheet-row-column.

Public Members

sheet_t sheet
row_t row
col_t column
struct src_range_t

Stores 3-dimensional cell range address. The ‘src’ abbreviation stands for sheet-row-column.

Public Members

src_address_t first
src_address_t last
struct color_rgb_t

Stores a color value in RGB format.

Public Members

color_elem_t red
color_elem_t green
color_elem_t blue

Enums

enum class orcus::spreadsheet::error_value_t

Type of error value in cells.

Values:

enumerator unknown

Error type unknown, typically used as an initial error value or generic default value.

enumerator null

Null reference error, displayed as #NULL!.

enumerator div0

Division-by-zero error, displayed as #DIV/0.

enumerator value

Formula expression error, displayed as #VALUE!.

enumerator ref

Reference error, displayed as #REF!.

enumerator name

Invalid named-expression error, displayed as #NAME?

enumerator num

Invalid numeric value error, displayed as #NUM!.

enumerator na

No value is available error, displayed as #N/A!.

enum class orcus::spreadsheet::border_direction_t

Type of border direction, used to reference the position of a border in a cell.

Values:

enumerator unknown

Unknown or uninitialized border direction value.

enumerator top

Top border of a cell.

enumerator bottom

Bottom border of a cell.

enumerator left

Left border of a cell.

enumerator right

Right border of a cell.

enumerator diagonal

Cross-diagonal borders of a cell. This is equivalent of both diagonal_bl_tr and diagonal_tl_br combined.

enumerator diagonal_bl_tr

Diagonal border of a cell that runs from bottom-left to top-right.

enumerator diagonal_tl_br

Diagonal border of a cell that runs from top-left to bottom-right.

enum class orcus::spreadsheet::border_style_t

Type of border style.

Values:

enumerator unknown
enumerator none
enumerator solid
enumerator dash_dot
enumerator dash_dot_dot
enumerator dashed
enumerator dotted
enumerator double_border
enumerator hair
enumerator medium
enumerator medium_dash_dot
enumerator medium_dash_dot_dot
enumerator medium_dashed
enumerator slant_dash_dot
enumerator thick
enumerator thin
enumerator double_thin
enumerator fine_dashed
enum class orcus::spreadsheet::fill_pattern_t

Type of fill pattern for cell background.

Values:

enumerator none
enumerator solid
enumerator dark_down
enumerator dark_gray
enumerator dark_grid
enumerator dark_horizontal
enumerator dark_trellis
enumerator dark_up
enumerator dark_vertical
enumerator gray_0625
enumerator gray_125
enumerator light_down
enumerator light_gray
enumerator light_grid
enumerator light_horizontal
enumerator light_trellis
enumerator light_up
enumerator light_vertical
enumerator medium_gray
enum class orcus::spreadsheet::strikethrough_style_t

Strikethrough style as applied to a cell value.

Note

This is specific to ODS format.

Values:

enumerator none
enumerator solid
enumerator dash
enumerator dot_dash
enumerator dot_dot_dash
enumerator dotted
enumerator long_dash
enumerator wave
enum class orcus::spreadsheet::strikethrough_type_t

Strikethrough type as applied to a cell value.

Note

This is specific to ODS format.

Values:

enumerator unknown
enumerator none
enumerator single_type
enumerator double_type
enum class orcus::spreadsheet::strikethrough_width_t

Width of strikethrough applied to a cell value.

Note

This is specific to ODS format.

Values:

enumerator unknown
enumerator width_auto
enumerator thin
enumerator medium
enumerator thick
enumerator bold
enum class orcus::spreadsheet::strikethrough_text_t

Text used for strike-through.

Note

This is specific to ODS format.

Values:

enumerator unknown
enumerator slash

/ is used as the text.

enumerator cross

X is used as the text.

enum class orcus::spreadsheet::formula_grammar_t

Type that specifies the grammar of a formula expression. Each grammar may exhibit a different set of syntax rules.

Values:

enumerator unknown

Grammar type is either unknown or unspecified.

enumerator xls_xml

Grammar used by the Excel 2003 XML (aka XML Spreadsheet) format.

enumerator xlsx

Grammar used by the Office Open XML spreadsheet format.

enumerator ods

Grammar used by the OpenDocument Spreadsheet format.

enumerator gnumeric

Grammar used by the Gnumeric XML format.

enum class orcus::spreadsheet::formula_t

Type of formula expression.

Values:

enumerator unknown

Formula expression type unknown, or generic default value.

enumerator array

Formula expression in an array of cells.

enumerator data_table

Formula expression in a data table.

enumerator normal

Formula expression in a normal formula cell.

enumerator shared

Formula expression in a shared formula cell.

enum class orcus::spreadsheet::formula_ref_context_t

Formula reference context specifies the location where a formula expression is used. This is used mainly for those document formats that make use of multiple formula reference syntaxes, such as ODS.

Values:

enumerator global

Default context, that is, the context that is NOT any of the other contexts specified below.

enumerator named_expression_base

Base cell position of either a named range or expression.

enumerator named_range

Named range is a special case of named expression where the expression consists of only one range token.

enum class orcus::spreadsheet::formula_error_policy_t

Type of policy on how to handle a formula cell with an erroneous expression that has been parsed unsuccessfully.

Values:

enumerator unknown
enumerator fail

Loading of the document will be halted.

enumerator skip

The error cell will be skipped.

enum class orcus::spreadsheet::underline_t

Underline type for a cell value.

Values:

enumerator none

Underline is absent.

enumerator single_line

Underline consists of a single line.

enumerator single_accounting

Single line for accounting format.

Note

This is unique to xlsx format.

enumerator double_line

Underline consists of a double line.

enumerator double_accounting

Double line for accounting format.

Note

This is unique to xlsx format.

enumerator dotted

Underline is dotted.

enumerator dash

Underline is dashed.

enumerator long_dash

Underline consists of repeated long dash segments.

enumerator dot_dash

Underline consists of repeated dot and dash segments.

enumerator dot_dot_dash

Underline consists of repeated dot, dot and dash segments.

enumerator wave

Underline is waved.

enum class orcus::spreadsheet::underline_width_t

Underline width types, specific to ODF. When the enum value is either percent, positive_integer, or positive_length, the actual value should be given separately.

Note

The automatic enum value corresponds with the “auto” text value, which could not be used since it’s a keyword in C++.

Values:

enumerator none
enumerator automatic
enumerator bold
enumerator dash
enumerator medium
enumerator thick
enumerator thin
enumerator percent
enumerator positive_integer
enumerator positive_length
enum class orcus::spreadsheet::underline_mode_t

Underline mode that determines whether an underline is applied to both words and spaces, or words only.

Note

This is specific to ODS format.

Values:

enumerator continuous

Underline is applied to both words and spaces.

enumerator skip_white_space

Underline is applied only to words.

enum class orcus::spreadsheet::underline_type_t

Whether a single line or a double line is used as an underline.

Todo:

Perhaps we should merge this with underline_t.

Values:

enumerator none
enumerator single_type

A single line is used as an underline.

enumerator double_type

A double line is used as an underline.

enum class orcus::spreadsheet::hor_alignment_t

Type of horizontal alignment applied to a cell content.

Values:

enumerator unknown
enumerator left
enumerator center
enumerator right
enumerator justified
enumerator distributed
enumerator filled
enum class orcus::spreadsheet::ver_alignment_t

Type of vertical alignment applied to a cell content.

Values:

enumerator unknown
enumerator top
enumerator middle
enumerator bottom
enumerator justified
enumerator distributed
enum class orcus::spreadsheet::xf_category_t

Cell format categories. The abbreviation “xf” stands for “cell format” where the “x” is short for cell.

Values:

enumerator unknown
enumerator cell

Direct cell format, also often referenced as xf.

enumerator cell_style

Cell format for named styles.

enumerator differential

Incremental cell format, also referenced as dxf.

enum class orcus::spreadsheet::data_table_type_t

Type of data table. A data table can be either of a single-variable column, a single-variable row, or a double-variable type that uses both column and row input cells.

Values:

enumerator column
enumerator row
enumerator both
enum class orcus::spreadsheet::totals_row_function_t

Function type used in the totals row of a table.

Values:

enumerator none
enumerator sum
enumerator minimum
enumerator maximum
enumerator average
enumerator count
enumerator count_numbers
enumerator standard_deviation
enumerator variance
enumerator custom
enum class orcus::spreadsheet::conditional_format_t

Type of conditional format.

Values:

enumerator unknown
enumerator condition
enumerator date
enumerator formula
enumerator colorscale
enumerator databar
enumerator iconset
enum class orcus::spreadsheet::condition_operator_t

Operator type associated with a conditional format rule.

Values:

enumerator unknown
enumerator equal
enumerator less
enumerator greater
enumerator greater_equal
enumerator less_equal
enumerator not_equal
enumerator between
enumerator not_between
enumerator duplicate
enumerator unique
enumerator top_n
enumerator bottom_n
enumerator above_average
enumerator below_average
enumerator above_equal_average
enumerator below_equal_average
enumerator contains_error
enumerator contains_no_error
enumerator begins_with
enumerator ends_with
enumerator contains
enumerator contains_blanks
enumerator not_contains
enumerator expression
enum class orcus::spreadsheet::condition_type_t

Type of a condition in a conditional format rule. This is applicable only when the type of a conditional format entry is either:

  • colorscale,

  • databar or

  • iconset.

Values:

enumerator unknown
enumerator value
enumerator automatic
enumerator max
enumerator min
enumerator formula
enumerator percent
enumerator percentile
enum class orcus::spreadsheet::condition_date_t

Type of a date condition when the type of a conditional format entry is date.

Values:

enumerator unknown
enumerator today
enumerator yesterday
enumerator tomorrow
enumerator last_7_days
enumerator this_week
enumerator next_week
enumerator last_week
enumerator this_month
enumerator next_month
enumerator last_month
enumerator this_year
enumerator next_year
enumerator last_year
enum class orcus::spreadsheet::databar_axis_t

Databar axis type, applicable only when the type of a conditional format entry is databar.

Values:

enumerator none
enumerator middle
enumerator automatic
enum class orcus::spreadsheet::pivot_cache_group_by_t

Type of range grouping in a group field of a pivot table cache.

Values:

enumerator unknown

Type of range grouping is unknown.

This is an implicit default value of this type.

enumerator days

Grouping on “days” for date values.

enumerator hours

Grouping on “hours” for date values.

enumerator minutes

Grouping on “minutes” for date values.

enumerator months

Grouping on “months” for date values.

enumerator quarters

Grouping on “quarters” for date values.

enumerator range

Grouping by numeric ranges for numeric values.

enumerator seconds

Grouping on “seconds” for date values.

enumerator years

Grouping on “years” for date values.