Ask Your Question

Why definition of a character style "relative" to the "Default Style" is blocked? [closed]

asked 2014-09-05 09:35:05 +0100

Alias duel zone gravatar image

updated 2020-07-21 12:41:33 +0100

Alex Kemp gravatar image

I only work with styles within any editor (because I intend to work on large and professionnal documents).

I would like to define a character style which will only depend on the "Default Style". Let's take an example with a style I need: "Important". This character style named "Important" will be used within any paragraph to just change the Font Typeface from "Regular" to "Bold". I want to get the same result whichever is the actual paragraph font in use in my actual paragraph.

Here is how I proceeded. My cursor is on a paragraph of style "P1". P1 is using typeface Papyrus, 16pt. I defined a new character style named "Important" with the function "New Style from Selection". Within "Organizer" I choosed Linked with "Default Style". LibreOffice displayed an error message:

This Style cannot be used as a base Style,

because it would result in a recursive reference.

I can't understand how defining a relation as simple as

Default Style → Important

might cause any form of recursion: there is no loop of dependency there.

Why is this relative definition blocked?

I feel that such a relative definition is very practical and basic need. To ensure all my character styles won't stay stiff if I decide to change a full range of paragrahs styles I need relative character definitions and not absolute ones.

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by Alex Kemp
close date 2016-03-03 16:53:29.935305

3 Answers

Sort by » oldest newest most voted

answered 2014-09-05 18:03:52 +0100

Regina gravatar image

The error message is indeed misleading and the UI can be improved. The character style "default style" is actually no style, but it means "remove the character style markup".

Text consists in file format of <text:h> elements for headings and <text:p> elements for other paragraphs. Both always exists. Applying a character style or a direct character formatting introduces an additional element <text:span>...</text:span>. The text between the two tags gets the new appearance.

If it is a direct character formatting, you can remove this <text:span> element by Format > Clear Direct Formatting. But if it is a style-based character formatting, there is no such menu item. But it is the purpose of the "default style" in the category "Character Styles". It removes the <text:span> tags.

So "Default Style" might not be the best name for it. I first thought of name "Clear Styles". But that does not reflect, that you can generate a new style without inheritance from the context menu.

edit flag offensive delete link more


I appreciate this pretty clear explanation. I share your point of view: a correct name to a function is a key point in ergonomics. "Clear Styles" or "No Styles" would be better choices.

Alias duel zone gravatar imageAlias duel zone ( 2014-09-05 19:50:50 +0100 )edit

@Regina, thanks for clearing this up. Some sort of distinction between the Default Style paragraph style and Default Style character style, in terms of hierarchical definitions, would seem warranted. IMO this character style should be renamed (e.g., "Clear character styles") or exposed via a different mechanism, such as a separate menu entry. This also appears to indicate there is no base character style definition (and this probably needs to be created to make managing these styles easier).

oweng gravatar imageoweng ( 2014-09-06 04:16:15 +0100 )edit

@Regina - Great explanation. I played around bit and agree very much with the name proposal by @oweng. Would be nice if such a name could be introduced soon.

ROSt52 gravatar imageROSt52 ( 2014-10-25 12:38:11 +0100 )edit

answered 2014-09-05 15:58:24 +0100

petermau gravatar image

You are asking a number of interesting questions. I find the LibO manuals very useful in answering these types of questions, and some you have yet to ask. Even the downloadable help useful. I suggest you examine the Styles chapter for LibO Writer. You can download the complete manual or just chapters. I personally prefer the old fashioned paper versions which you can order from Lulu.

I am delighted you are using Styles and not the basic control overrides. Some users never get this far. There is also a draft Styles and Templates manual being written which can be found on the Authors website. However, I understand it still has some way to go... Good luck Peter

edit flag offensive delete link more


Before asking a question I usually search the documentation, and then I search throughout the questions which received a high vote.

Alias duel zone gravatar imageAlias duel zone ( 2014-09-05 17:52:13 +0100 )edit

answered 2014-09-05 17:01:22 +0100

oweng gravatar image

updated 2014-09-06 04:04:58 +0100

The particular error message indicated, is only evident when editing a style i.e., creating a new character style via the New Style From Selection button or using right-click on a character style (that is not the Default Style) > Modify.... It is possible to right-click on the Default Style character style > New... > Organizer tab > Inherit from displays "Default Style" > make changes as required > click OK. However, subsequent editing of this newly created style will reveal the character style has lost this inheritance setting (it reverts to "- None -").

It would appear that only character styles other than the Default Style can support hierarchical relationships. Refer the answer by @Regina.

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2014-09-05 09:35:05 +0100

Seen: 866 times

Last updated: Sep 06 '14