In Writer, 1. Create a new document. 2. Insert a shape - Symbol | Smiley Face . Make it a few paragraphs' worth in height, and about the same width. 3. Save the document as HTML. 4. Open the output HTML in a web browser Expected result: You only see the smilary-face image. Actual result: You see a /> after the smiley face (at the top and to the right of it).
Created attachment 172900 [details] Smiley face example: ODT + faulty HTML Note there's a GIF which the HTML references.
Seen with: Version: 7.2.0.0.alpha1+ / LibreOffice Community Build ID: 162f5a20095c6937030d23ee03fb8f72c51eefa1 CPU threads: 4; OS: Linux 5.10; UI render: default; VCL: gtk3 Locale: en-US (en_IL); UI: en-US TinderBox: Linux-rpm_deb-x86_64@86-TDF, Branch:master, Time: 2021-06-06_16:55:45
Repro Version: 7.2.0.0.alpha1+ (x64) / LibreOffice Community Build ID: 239b4bb27fd8db26e8416045b3015688a8b1b0ae CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win Locale: nl-NL (nl_NL); UI: en-US Calc: CL not in Version: 7.1.0.0.beta1+ (x64) Build ID: f9fab4203c1aa0b9a3f27ce2713b6d5addc7df19 CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: default; VCL: win Locale: nl-NL (nl_NL); UI: nl-NL Calc: CL Note: 7.1 has issues though! [Note: also observing kind of 'crop' Right and bottom on html export have 'flat' area; something happening on more exports (recalling something about File -> Export -> Image in Draw doing the same)
Relevant HTML looks like this: <img src="smiley_html_9ea10e4862fb59d1.gif" name="Shape 1" alt="Shape 1" align="left" width="142" height="122"<img src="smiley_html_9ea10e4862fb59d1.gif" name="Shape 1" alt="Shape 1" align="left" width="142" height="122"/> /> As you can see, the HTML source has a second, unnecessary copy of the img element nested inside the expected img element. This is not correct HTML syntax. I think this is clearly a bug and not an enhancement. Since you can work around it by manually editing the HTML code to remove the unnecessary second element, I have changed the priority to minor.
This seems to have begun at the below commit. Adding Cc: to Miklos Vajna ; Could you possibly take a look at this one? Thanks 9d0147aa2ba591e2692bb574d0ba107adbff1c86 is the first bad commit commit 9d0147aa2ba591e2692bb574d0ba107adbff1c86 Author: Jenkins Build User <tdf@pollux.tdf> Date: Fri Jun 4 13:22:17 2021 +0200 source e76471c5ce725dae9abb6f78b7674c6f77df34f4 https://git.libreoffice.org/core/+/e76471c5ce725dae9abb6f78b7674c6f77df34f4 sw XHTML / reqif export: export non-PNG graphic shapes directly
Yes, I'll take a look.
Miklos Vajna committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/2d9580e6a65a2699ff61fc1b0e07f62b4946de84 tdf#142871 sw HTML export: avoid unwanted inner PNG for images It will be available in 7.3.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.
Miklos Vajna committed a patch related to this issue. It has been pushed to "libreoffice-7-2": https://git.libreoffice.org/core/commit/e8903df87ecdef73471e379193bdccbb015f79f0 tdf#142871 sw HTML export: avoid unwanted inner PNG for images It will be available in 7.2.0.0.beta2. 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.
*** Bug 142872 has been marked as a duplicate of this bug. ***
it's solved. Verified in Version: 7.3.0.0.alpha0+ / LibreOffice Community Build ID: eac5977bfc11797eda356560a5e45c51108ef5a1 CPU threads: 4; OS: Linux 5.8; UI render: default; VCL: gtk3 Locale: ro-RO (ro_RO.UTF-8); UI: en-US Calc: threaded