Skip to content

feat(ods): a column's default cell style reaches its cells - #558

Merged
productdevbook merged 1 commit into
mainfrom
feat/ods-column-default-style
Aug 13, 2026
Merged

feat(ods): a column's default cell style reaches its cells#558
productdevbook merged 1 commit into
mainfrom
feat/ods-column-default-style

Conversation

@productdevbook

Copy link
Copy Markdown
Owner

LibreOffice puts a column's format on the column, not on its cells:

<table:table-column table:default-cell-style-name="ce1"/>

where ce1 names the data style. A date column's yyyy-mm-dd lives there and nowhere else — the cells themselves say table:style-name="Default", a named style in styles.xml that this reader does not open.

hucre read neither, so a LibreOffice document came back with its values and none of its formats.

What is reachable, and what is not

The column default is an automatic style in content.xml, which this reader does parse — so that half is reachable, and is what this reads.

A column naming a style from styles.xml still resolves to nothing. That is the right answer for the one LibreOffice actually writes there — "Default", on the columns it did not format — since that style is the absence of formatting. PARITY.md records both halves.

Precedence and counting

  • A cell's own style still wins; the column only fills in for cells that named none.
  • A covered cell advances the column count too, or every default after a merge would land one column to the left.

This was the last open item

It was in the ODF grammar, in libreoffice-basic.ods, and nowhere in src/. Both halves of SPEC-COVERAGE.md now read "Nothing" under not yet looked at, and no item is marked open.

Output still validates against the OASIS grammar (validate-odf.mjs: all parts valid).

pnpm test green — 10,583 tests, 234 files.

🤖 Generated with Claude Code

LibreOffice puts a column's format on the column, not on its cells:

  <table:table-column table:default-cell-style-name="ce1"/>

where `ce1` names the data style. A date column's `yyyy-mm-dd` lives
there and nowhere else — the cells themselves say
`table:style-name="Default"`, a named style in `styles.xml` that this
reader does not open. hucre read neither, so a LibreOffice document came
back with its values and none of its formats.

The column default is an *automatic* style in `content.xml`, which this
reader does parse, so that half is reachable and is what this reads. A
column naming a style from `styles.xml` still resolves to nothing —
which is the right answer for the one LibreOffice actually writes there,
`"Default"`, since that style is the absence of formatting. PARITY says
so.

A cell's own style still wins; the column only fills in for cells that
named none. A covered cell advances the column count too, or every
default after a merge would land one column to the left.

This was the last open item in SPEC-COVERAGE.md — in the ODF grammar, in
`libreoffice-basic.ods`, and nowhere in `src/`. Both halves of the report
now read "Nothing" under *not yet looked at*, and no item is marked open.

Output still validates against the OASIS grammar.

pnpm test green — 10,583 tests, 234 files.
@productdevbook
productdevbook merged commit ad0f4a5 into main Aug 13, 2026
6 checks passed
@productdevbook
productdevbook deleted the feat/ods-column-default-style branch August 13, 2026 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant