Clear direct formatting ignores Character Styles

If I am using a paragraph style, then I format part of it with a character style to highlight it (same font and font size, but a different color with italics, for example), then I change the paragraph style, the character style portion of the text is unaffected.

Ideally, I think the paragraph attributes should be applied to the character style, when “Clear direct formatting” (Ctrl-M) is invoked. Or, all character formatting could be removed, and the raw paragraph style selected could be used.

The tool is not “Clear character formatting”, but “Clear direct formatting”, with “direct” opposed to “formatting with styles”. As character styles are styles, the tool’s behaviour is consistent.

You must first understand how styles work.

Three layers are available and the shallower override the deeper.

The lowest level is paragraph style. As the name implies, you act on the layer by giving a style to a whole paragraph. You reset it by giving a “neutral” paragraph style, in principle Default Style, which, because of this usage, should never be modified or actively used in the document (unless you know what you’re doing).

The second layer is character style. You act on this layer by giving a style to a selected range of characters. Contrary to more complex DTP programs like Quark XPress®, any character can receive only a single character style, the latest applied overriding the previous one. You reset the style to the paragraph style by applying character style Default Style.

This latter style is not a real style. You can’t modify it. Its sole purpose is to remove any character style.

The top layer is direct formatting. You set attributes with the buttons in the toolbar(s) or their shortcut equivalent. They are erased with FormatClear Direct Formatting or Ctrl+M.

I suspect this third layer was provided to avoid the burden of setting up a consistent set of styles for short one-shot documents and maybe also for “compatibility” (i.e. not upsetting users even if it is “wrong”) with other text processors.

Every layer is independent from each other. Resetting one does not reset the others.

To answer your question about resetting character style:

  1. Select the paragraph content (e.g. quadruple click)
  2. Apply character style Default Style

If this answer helped you, please accept it by clicking the check mark :heavy_check_mark: to the left and, karma permitting, upvote it. If this resolves your problem, close the question, that will help other people with the same question.

Voila! THANK YOU!

This is a great explanation of a positively terrible implementation of styles in LibreOffice. LO devs take note: if the paragraph style contains custom font formatting,

  • it makes zero sense to force users to find a separate character style setting that isn’t linked in the paragraph style dialog, and
  • know to switch the character style to a special default paragraph style setting
  • particularly when the special setting doesn’t even accurately describe what the user is doing if they are working with a custom style (rather than a default one).

This is completely different from the way styles work in Word, and it is a serious barrier to adoption of LO.

@doug: I think M$ Word implementation is wrong because it lacks the character style layer, forcing user to heavily use direct formatting. Implementation with the styles layers is cleaner and much more maintenance-friendly.

IMHO, to get more versatility (and “purity”), the character style layer should not be limited to a single style (but that opens the door to many problems).

I don’t understand "to find a separate character style setting that isn’t linked in the paragraph style dialog*: paragraph and character styles are independent for each other and this is the source of power. Linking character style to para style would defeat the freedom to apply a semantically meaningful style [name] anywhere.

Also, working with custom styles is the normal way for an author. Built-in styles are only there to suggest a structure when starting with LO Writer. They are not sacred and can be customised at will.

Dont’t forget also styles can be hierarchically organised in their families.

@ajlittoz Yes, I am seeing there are benefits to the LO styles implementation.

The confusing thing here is that the character style setting of default paragraph style is not the default setting for character style. This steepens the learning curve, especially for crossover M$ Word users, who then need to come to this website to see what is going on.

I would propose to improve the functionality by eliminating font controls in the paragraph styles dialogs and instead introducing an option to link a paragraph style to a character style. That would would retain all the current functionality but make it more obvious to a non-power user that the real character-level formatting action is in character styles not paragraph styles. That visibility would be in the options for paragraph styles, not a separate and independent set of option dialogs.

I see what you mean. I remember when switching to Writer being confused by the duality between paragraph/character styles. But this is the source of power. If your proposal were implemented, you would need to define all attributes in the character style because applying one in the middle of a paragraph would replace the default. Presently, you only set the overriding attributes; the others are in a “transparent” state, taking the default values in the para style. Keeping the current behaviour can be done only by allowing several char styles to be simultaneously active, which is not (yet?) possible and causes many problems.

Note also that para styles are organised in a tree-like structure, allowing to manage easily doc appearance from a handful of “critical” styles. In your proposal, you’d have two hierarchies: one for lay-out (para), one for type (char). I do use the char structuring but only for specific “local” hierarchies, not a global one paralleling the para one. …

Also, the Default Style para style is not a real style: you can’t change it. It is in fact a substitute for a “Reset” button, erasing all added character style(s). I agree this is confusing to beginners.

What I miss most is a “toggle” state for attributes where this is relevant (e.g. italics for fonts with a single slant angle, or bold when there are only 2 variants). According to ODF standard, char styles can inherit only from other char styles (the tree-structure previously mentioned); however, they are applied against para styles. A toggle attribute is significant only as a dynamic state (thus applied to the current para style). Think of italics in typographical rules: highlighted word is italics in Roman para, Roman in italics para. You can’t presently specify this formatting: it must be done manually by selecting an appropriate char style. Change the para style and you visually lose the highlighting.

Also, the Default Style para style

I assume that para was an affix meaning “near”, and it was about character style, not a paragraph style (which is a proper style, available for modifications).

Wanted to mention that there are more layers between paragraph style and character style: they are: paragraph-level direct formatting (right above paragraph style); numbering style; numbering direct formatting. The topmost direct formatting is character-related.

As Mike Kaganski says, it is intended behavior. If you deem it illogical, feel free to file a bug report/RFE. If you want to remove style-based character formatting, right click → Styles → Default Character.

Bug reports already have been discussed and closed.

Different would be a report (RFE) for an extra feature/shortcut. (Well, that may exist too)

I’ve linked Ctrl+Shift+0 to the character style Default to do fast changes.