[Writer] Usage of "percent" character sizes, how does it work?

The “Font” tab in paragraph/character style dialog allows character sizes to be defined as a relative percentage, e.g. 80% or 150%.

It the case of paragraph styles, the typical use is to create a consistent size hierarchy among linked styles such as the Heading x family. Here, I understand that the actual size in points can be computed at style definition time from the parent style. When character size is changed in the master style, the change is cascaded in the dependent styles as expected.

The situation is not as clear for character styles.

This is my use case: I write definitions for technical keywords. The definition itself is written in the Default Style character style (i.e. not stylistic variation applied) in the Text Body paragraph. The keywords are styled Source Text so that they are displayed in a monospaced font. Since the x-height of the proportional font for ordinary text and the one of the monospaced font are not the same, visual appearance is not satisfactory. To correct this, font size in character style Source Text is adjusted to 80%. This works fine in Text Body paragraphs.

Sometimes, clarifications are given in footnotes which are obviously styled Footnote. Keywords are also styled Source Text. I expected the 80% correction factor to be applied to the current paragraph style, i.e. Footnote, so that the keyword would “integrate” smoothly in the line. Instead of that, the keyword is displayed with the same absolute size (in points) as in Text Body paragraphs. It looks like the actual size has been computed at style definition time against some (which one? Default Style?) reference.

WG40-WriterGuideLO (latest available) states on page 219 that a character-style %-size is relative to the current paragraph-style size. There is nothing about %-sizes in the on-line help.

This incorrect (in my expectation) behaviour is the same with LO 5.0, 4.4 and even 3.x.

The question is: how can I get the desired result?

If I missed something in LO configuration, please give me the clues to the appropriate parameters.

I closed my question, but I’m not satisfied by the answer. Though the ODF is consistent with the idea of hierarchically organised character styles (parallel to paragraph styles), I feel that “percent” sizes are intrinsically ambiguous for character styles. They can be used to build a hierarchy of character styles from root to leaves. Or, these %-cent sizes are contextual modification for the current paragraph style (no hierarchical relation). Unfortunately, these semantics are incompatible.

Unfortunately, it cannot work like you want. In the ODF specification section 20.183 fo:font-size in specification part 1 you find,

The value of this attribute is either an absolute length or a percentage as described in §7.8.4 of [XSL]. In contrast to XSL, percentage values can be used within common styles only and are based on the font height of the parent style rather than to the font height of the attributes neighborhood. Absolute font heights and relative font heights are not supported.

Important part is “are based on the font height of the parent style rather than to the font height of the attributes neighborhood”. And ‘parent style’ is a character style in the hierarchy of character styles.

You need to build your own character style for markup in a footnote and maintain it manually. In addition, there is no way to bind a character style to a paragraph style.

Thanks for your answer. My present workaround is to define some “reasonable” size which is smaller than the “Text Body” x-height but not too big compared to “FootNote” x-height. I think i’ll stick with it because I try to use character style for kind of semantic markup with as few styles as possible.

I suggest that the Writer Guide (p. 219 for version 4.0) be corrected for next 5.0. As presently written, it erroneously hints to my understanding.