Bug 104389 - Direct formatting instead of styles is used for text on table autoformat/styles
Summary: Direct formatting instead of styles is used for text on table autoformat/styles
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
5.2.3.3 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: needsDevAdvice, needsUXEval
Depends on:
Blocks: Writer-Tables-Style Table-AutoFormat
  Show dependency treegraph
 
Reported: 2016-12-04 12:27 UTC by RGB
Modified: 2019-07-18 21:36 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description RGB 2016-12-04 12:27:47 UTC
Tested with table autoformat on 5.2 and with table styles on 5.3 beta.

Steps to reproduce the problem:

1- Insert a table
2- With the cursor inside the table, apply a table autoformat (5.2) or table style (5.3 beta), for example, "lavender"

Results:

- Text on the table is set with Thorndale font even if the corresponding paragraph style is set as "liberation serif".

- Ctrl-M does NOT restore the paragraph style formatting, you need to apply it by hand.

Expected results: Table styles should not overwrite the paragraph styles used inside the table with direct formatting.
Comment 1 Regina Henschel 2016-12-04 22:34:06 UTC
Calc does not allow more than one paragraph in a cell and it uses cell styles. In Calc I see a similar problem. The "AutoFormat Style" applies a direct formatting of attributes, which were defined in a cell style in the source of that "AutoFormat Style". I guess, that the old binary autotbl.fmt is not able to contain styles. (But I don't know any documentation of that format). Writer uses the same old binary autotbl.fmt. In regard to the old binary format, I would consider this a "Wontfix", because the goal is to get rid of the binary format. 

The new table style in Writer uses the ODF element <table:table-template>. This has children, which are able to reference a cell-style. A cell-style can contain paragraph and text properties. But the Writer UI has no tools to define cell styles. So I think, that this is not really a bug, but a missing feature in the implementation.

LibreOffice would need an implementation of cell-styles in Writer (and in Impress/Draw too). And it would need a new UI for defining table styles including custom paragraph style and text style. Such UI is complex, because it is possible, that a cell can contain more than one paragraph and each paragraph can have a background in addition to the table-cells background.

Whether a table style should overwrite existing formating or not, when the table style is applied, is an additional problem.
Comment 2 Thomas Lendo 2018-02-06 13:42:47 UTC
Adding keyword needsUXEval and CC'ing Heiko and Jay as they worked on new table styles in Writer.

Please read Regina's comment 1, especially
(In reply to Regina Henschel from comment #1)
> The new table style in Writer uses the ODF element <table:table-template>.
> This has children, which are able to reference a cell-style. A cell-style
> can contain paragraph and text properties. But the Writer UI has no tools to
> define cell styles.
...
> LibreOffice would need an implementation of cell-styles in Writer (and in
> Impress/Draw too). And it would need a new UI for defining table styles
> including custom paragraph style and text style.

I also see a problem that table styles (old binary and new styles) ignore/don't use/don't set the table paragraphs "table content" and "table heading". Should table styles include paragraph styles or even overwrite paragraph/character attributes?
Comment 3 Heiko Tietze 2018-02-06 14:47:27 UTC
Table style is kind of a template rather than a real style. That means when you have defined the text as Thorndale it will be applied as such for the tables. 

The "legacy" Table > Autoformat Styles... dialog allows to select what property is used. This option is still missing together with the manipulation dialog for the new implementation. It was part of the design.