Bug 99940 - HTML export: Formatting for text underlines decorations
Summary: HTML export: Formatting for text underlines decorations
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium minor
Assignee: Not Assigned
URL:
Whiteboard: confirmed:5.2.0.0.Alpha1+:windows10
Keywords: filter:html
Depends on:
Blocks: (X)HTML-Export
  Show dependency treegraph
 
Reported: 2016-05-19 00:22 UTC by librelibre
Modified: 2023-06-30 08:20 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
ODT file to test bug (10.37 KB, application/vnd.oasis.opendocument.text)
2021-06-30 00:16 UTC, Stéphane Guillou (stragu)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description librelibre 2016-05-19 00:22:30 UTC
when exporting text with colored underlines
the text has black underline when colored variants mroe expected
but it's css3-draft
https://developer.mozilla.org/en-US/docs/Web/CSS/text-decoration-color
Comment 1 Theodore Matula Jr. 2016-05-19 01:11:19 UTC
I was able to reproduce this bug on Version 5.2.0.0.alpha1+ in Windows 10. When exporting text with a colored underline as HTML, the colored underline is displayed as black. However, if both the font color and the underline color are changed to the same color, both colors are displayed correctly. If the font color and underline colors are different, the HTML will display both as whatever the font color is, overwriting the underline color. It seems that for a HTML file, the font color overwrites the underline color.

Test with Red underline:
1. Open a new Writer Document
2. Type a word, highlight it, and press CTRL+U
3. Click Format>Character and select the Font Effects Tab
4. Change the Underline Color to Red and click ok
5. Click file>save as and save the document as .html
6. open the new html file

Expected:
The underline will be red.
Actual:
The underline is black.

Test with red underline and red text:
Repeat steps 1-3 in first test
4. Change the Underline Color and Font Color to Red and click ok
5. Click file>save as and save the document as .html
6. open the new html file

Expected:
The underline and font will be red.
Actual:
The underline and font is red.

Test with red underline and Green text:
Repeat steps 1-3 in first test
4. Change the Underline Color to red, the Font Color to green, and click ok
5. Click file>save as and save the document as .html
6. open the new html file

Expected:
The underline will be red and the font will be green.
Actual:
The underline and font are both green.
Comment 2 QA Administrators 2017-05-22 13:39:55 UTC Comment hidden (obsolete)
Comment 3 QA Administrators 2019-12-03 15:02:39 UTC Comment hidden (obsolete)
Comment 4 Stéphane Guillou (stragu) 2021-06-30 00:16:43 UTC
Created attachment 173276 [details]
ODT file to test bug

Adding a test file to test easily.

Reproduced with current-ish master:

Version: 7.3.0.0.alpha0+ / LibreOffice Community
Build ID: f446a203fa2897bab8ae7686c948a8bf060675c6
CPU threads: 8; OS: Linux 4.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
TinderBox: Linux-rpm_deb-x86_64@86-TDF, Branch:master, Time: 2021-06-24_15:16:38
Calc: threaded

"Save as > HTML" and "Export > XHTML" have same effect: underline can't have a colour different to font.
Comment 5 Sophie Sipasseuth 2023-06-30 08:20:43 UTC
The bug is still present in this version of LO:

Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 9fc0b2b9b96d87eb642a3b29e9dcb5d6273265eb
CPU threads: 4; OS: Windows 10.0 Build 19045; UI render: default; VCL: win
Locale: fr-FR (fr_FR); UI: fr-FR
Calc: CL threaded