Font colour changed after paste from web page

Discuss the word processor
Post Reply
Peter5004
Posts: 27
Joined: Thu Oct 19, 2023 6:17 pm

Font colour changed after paste from web page

Post by Peter5004 »

This is not so much a bug report as a caution to other users.

I wanted to insert an obelus or 'dagger' symbol (†) into an OO Writer document. Instead of looking it up under the 'insert special character' tab (and not knowing the Unicode for it), I copied-and-pasted it from Wikipedia. I also surrounded it with 'smart' apostrophes.

It was not until some time later that I discovered that subsequent text, up until the next save point (I think), had its font colour changed from 'default' to 'black'. Since the default colour is black anyway, this was a change I was hardly likely to notice!

I only learnt about this after I'd posted the text to a website that can be configured to either 'light' mode (black-text-on-white) or 'dark' mode (white-text-on-black). Another user, who uses dark mode, told me that the black-on-black text doesn't show up very well! The 'default-colour' text shows up OK, though.

The moral behind this is, if you copy-paste anything from another document or site, do check the 'font colour' before you continue!

I'm attaching a sample file illustrating the problem.
Attachments
Font Colour test.odt
(8.93 KiB) Downloaded 9 times
Last edited by MrProgrammer on Thu May 21, 2026 10:11 pm, edited 1 time in total.
Reason: Edited topic's subject to add "paste" to subject
Peter
Open Office 4.1.16 on Windows 10
User avatar
Hagar Delest
Moderator
Posts: 33643
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Font Colour unexpectedly changing

Post by Hagar Delest »

Or paste as unformatted text.

Please add [Solved] at the beginning of the title in your first post (top of the topic) with the button if your issue has been fixed.
LibreOffice 25.2 on Linux Mint Debian Edition (LMDE 7 Gigi) and 25.2 portable on Windows 11.
Jan_J
Posts: 196
Joined: Wed Apr 29, 2009 1:42 pm
Location: Poland

Re: Font Colour unexpectedly changing

Post by Jan_J »

Here's literal quotation from the source code of your .odt document:

Code: Select all

<text:p text:style-name="Text_20_body">The quick brown fox ‘<text:span text:style-name="T1">†’ jumps over a lazy dog</text:span></text:p>
What does it mean?
There is a single paragraph containing entire sentence. Inside it, the text starting at the dagger (†) up to “dog” is marked with inline style named T1. However, in the user's interface this corresponds to unnamed (anoymous) style, typical for manual formatting — probably inherited from the clipboard content. That is why it can keep colour attached to this style, while Text_20_body (i.e. the Text Body standard paragraph style) changes its properties.

If you want to preserve formatting in as you designed it, paste only non-formatted text.
You can also erase all anonymous styles in a marked region using Format→Clear manual formatting menu operation over it.
JJ ∙ https://forum.openoffice.org/pl/
LO (26.2) ∙ Python (3.13|3.10) ∙ Unicode 17 ∙ LᴬTEX 2ε ∙ XML ∙ Unix tools ∙ Linux (Rocky|CentOS)
Post Reply