Bug 158931

Summary: Display of SVG images containing the text-anchor="end" attribute and subscript text
Product: LibreOffice Reporter: dattero2011
Component: LibreOfficeAssignee: Not Assigned <libreoffice-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal CC: raal, xiscofauli
Priority: medium    
Version: 7.4.7.2 release   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
Crash report or crash signature: Regression By:
Bug Depends on:    
Bug Blocks: 88278    
Attachments: Example of image that causes the behaviour
LO 24.8 on the left, Firefox right

Description dattero2011 2023-12-30 13:37:40 UTC
Description:
Any Libreoffice application fails to properly display inserted SVG images if they contain subscript text (attribute dy="-4.80px" of "tspan" tag) and are aligned to the right (text-anchor="end"). In particular, that text is displayed in a wrong position. Other applications (web browsers, Inkscape, Ristretto image viewer, etc.) display the image properly.
In my case, the image was generated using SVG terminal of gnuplot (using the command set label "text_with subscript" right).
Even in the exported PDF files, the problem is still there.

Steps to Reproduce:
1.Open any Libreoffice application (e.g. Writer)
2.Import an SVG image with the described characteristics
3. (optional) export as PDF

Actual Results:
Image not displayed properly

Expected Results:
The image should have been displayed as in a web browser or any other image viewer


Reproducible: Always


User Profile Reset: No

Additional Info:
Version: 7.4.7.2 / LibreOffice Community
Build ID: 40(Build:2)
CPU threads: 8; OS: Linux 6.1; UI render: default; VCL: gtk3
Locale: en-GB (en_GB.UTF-8); UI: en-GB
Debian package version: 4:7.4.7-1
Calc: threaded
Comment 1 dattero2011 2023-12-30 13:38:15 UTC
Created attachment 191648 [details]
Example of image that causes the behaviour
Comment 2 raal 2023-12-30 15:20:28 UTC
Hello, I doesn't see the problem with Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 71c28942fbc7f36e5bcd46c5a6cdfbb3fcbcd6a0
CPU threads: 4; OS: Linux 6.2; UI render: default; VCL: gtk3
Locale: cs-CZ (cs_CZ.UTF-8); UI: en-US
Calc: threaded

Comparing LO with Firefox. Please could you test it with dev version?  You can download it here: http://dev-builds.libreoffice.org/daily/master/
Thank you
Comment 3 raal 2023-12-30 15:22:36 UTC
Created attachment 191651 [details]
LO 24.8 on the left, Firefox right
Comment 4 Xisco FaulĂ­ 2024-01-02 11:26:58 UTC
This issue got fixed by 2795a230464aea3a792e67b5625fce2a0c01d547
Closing as duplicated of bug 151103

*** This bug has been marked as a duplicate of bug 151103 ***
Comment 5 dattero2011 2024-01-02 13:18:58 UTC
It was indeed a duplicate of the already reported bug. My bad for not finding it. My version also cannot display properly the attachment in the other report page. Glad it got fixed.