Description: No matter what font or point size I use, when I save to html and then reopen the doc, I get "font name;serif" or "font name;sans serif" at 10 point. This makes it difficult for me to read and difficult to further process the document. Steps to Reproduce: 1.Set font and point size to any document in any format INCLUDING html. 2."Save" document as an html document 3.Re-open document. Actual Results: "font name;serif" or "font name;sans serif" at 10 point size Expected Results: open document with the Saved Font, at Saved point size Reproducible: Always User Profile Reset: Yes Additional Info: Document should open to the Saved Font, at Saved point size
Sorry, but is this really unexpected? LibreOffice is not a text editor--and is a pretty poor HTML editor (Writer Web) When you "round-trip" an ODF document from writer--exporting to HTML (using XHTML filter rules) and then re-import that HMTL back to LO (opening into Writer-Web module) there will be reformatting. Better way to asses might be to export/save-as to .html and then review the markup that LO filters assign. Any texteditor would do--on Windows notepad++ does a nice job of presenting the markup as exported. Are the font stanzas being munged there--I just did a test and note that the export filter defaults output css for font for "size=" (HTML4 numeric) and "font-size=" (as points). But there is no font family written. Meaning on round-trip import opening to Writer-Web module LO template defaults for font and size will be applied. Kind of seem this is expected.
"It's not a bug, it's a feature!" Now where have I heard THAT before?
[Automated Action] NeedInfo-To-Unconfirmed
(In reply to JIM7 from comment #0) > Description: > No matter what font or point size I use, when I save to html and then reopen > the doc, I get "font name;serif" or "font name;sans serif" at 10 point. > This makes it difficult for me to read and difficult to further process the > document. > > Steps to Reproduce: > 1.Set font and point size to any document in any format INCLUDING html. > 2."Save" document as an html document > 3.Re-open document. > > Actual Results: > "font name;serif" or "font name;sans serif" at 10 point size > > Expected Results: > open document with the Saved Font, at Saved point size Tested with Save As HTML and I can make it lose the font size definition, if I had used direct character formatting. However, even with char formatting, it doesn't lose the font family. By modifying the paragraph style, both font size and family are retained. Can you explain in detail what you did? Arch Linux 64-bit, X11 Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community Build ID: 1f9cd62b67d679da078c50b4b48295918657a70a CPU threads: 8; OS: Linux 6.5; UI render: default; VCL: kf5 (cairo+xcb) Locale: fi-FI (fi_FI.UTF-8); UI: en-US Calc: threaded Built on 11 October 2023
concerning the font sizes lost, regression bisected to https://git.libreoffice.org/core/+/db115bec9254417ef7a3faf687478fe5424ab378 tdf#78510 see also https://ask.libreoffice.org/t/writer-html-import-messing-up-font-size-regression-7-6/104076
Reportedly [1] the DF font size bibisection result as: https://git.libreoffice.org/core/+/db115bec9254417ef7a3faf687478fe5424ab378 =-ref-= [1] https://ask.libreoffice.org/t/writer-html-import-messing-up-font-size-regression-7-6/104076/2
Concerning the change of title for this buzilla, would be interesting to share a reference for "Writer-web HTML". AFAI'm concerned, I have - "File" > "Save" > *"HTML Document (Writer) (.html)"* > test.html - "File" > "Close" - "File" > "Recent Documents" > test.html P.S. and indeed, font name changes from "Times New Roman" to "Times New Roman;serif", but I can't see a difference in rendering.
For general reference: Writer-web is the LO module that by default opens .html/.htm with tailored filter import, and shows a Web "layout" of the document and an HTML source view. Users can explicitly use Writer module to filter open the .html/.htm by selecting the 'HTML Document (Writer) (*.html,*.xhtml,*.htm)' filter from the os/DE file dialog. It opens back to the View -> Normal, provides a Web "layout" but doesn't offer the HTML source view. But think the loss of direct formatted Font and Font size on HTML filter export, as well as munging the Font of exported paragraph style is more the issue here.
Michael Stahl committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/ac05822b8957d80018d3ce1cbf97cd9faa0dfe99 tdf#154581 tdf#157411 tdf#158549 sw: HTML import: fix SfxItemIter reuse It will be available in 24.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
reportedly fixed on master
Michael Stahl committed a patch related to this issue. It has been pushed to "libreoffice-24-2": https://git.libreoffice.org/core/commit/d33d3bbd9fb021c9ef15689f4e8e5b9898541e70 tdf#154581 tdf#157411 tdf#158549 sw: HTML import: fix SfxItemIter reuse It will be available in 24.2.4. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Michael Stahl committed a patch related to this issue. It has been pushed to "libreoffice-7-6": https://git.libreoffice.org/core/commit/f6fb5dedc3926ce214560a4053815f692b29b934 tdf#154581 tdf#157411 tdf#158549 sw: HTML import: fix SfxItemIter reuse It will be available in 7.6.8. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Michael Stahl committed a patch related to this issue. It has been pushed to "libreoffice-24-2-3": https://git.libreoffice.org/core/commit/9b5b007df580eaeff2bab2fda9a6cb45e3a3bd24 tdf#154581 tdf#157411 tdf#158549 sw: HTML import: fix SfxItemIter reuse It will be available in 24.2.3. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Michael Stahl committed a patch related to this issue. It has been pushed to "libreoffice-7-6-7": https://git.libreoffice.org/core/commit/598cc6c5f03bf0aae525e80ae6960de2c78efeae tdf#154581 tdf#157411 tdf#158549 sw: HTML import: fix SfxItemIter reuse It will be available in 7.6.7. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Xisco Fauli committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/0479f870e05d5d231d2d57aaeedff11544bd370c tdf#154581 tdf#157411 tdf#158549: sw_htmlimport: Add unittest It will be available in 24.8.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.