Bug 117207 - Incorrect font rendering of Open Sans Italic font with typographic subfamily Condensed Light Italic inside SVG in LibreOffice
Summary: Incorrect font rendering of Open Sans Italic font with typographic subfamily ...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
6.0.3.2 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: filter:svg, needsDevAdvice
Depends on:
Blocks: Font-Rendering SVG-Open
  Show dependency treegraph
 
Reported: 2018-04-24 11:59 UTC by Nithin
Modified: 2023-10-19 11:23 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Example file from Inkscape (3.35 KB, image/svg+xml)
2018-04-24 14:05 UTC, Nithin
Details
Example file from Draw (21.61 KB, image/svg+xml)
2018-04-24 14:06 UTC, Nithin
Details
How it should look like (18.52 KB, image/png)
2018-04-24 14:06 UTC, Nithin
Details
Screenshot from Win 10 (9.30 KB, image/png)
2018-05-14 16:52 UTC, Buovjaga
Details
How it looks in LibreOffice 6.2 master (153.08 KB, image/png)
2018-06-14 10:31 UTC, Xisco Faulí
Details
open sans condensed test (13.55 KB, application/vnd.oasis.opendocument.text)
2023-10-19 07:35 UTC, Sophie Sipasseuth
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nithin 2018-04-24 11:59:59 UTC
Description:
The text is rendered in a different font than what is mentioned in the SVG file. The file Example.svg was created and saved in Inkscape.


Steps to Reproduce:
1.Install Open Sans Condensed font family(Open Sans Condensed Light, Open Sans Condensed Light Italic, Open Sans Condensed Bold)
1.Drag and Drop Example.SVG into a LO application(Writer or Draw)


Actual Results:  
The second line is rendered in a different font than "Open Sans Condensed Light Italic"


Expected Results:
Font should rendered in the correct font


Reproducible: Always


User Profile Reset: Yes



Additional Info:
I am not sure where exactly the problem lies, here are the checks i have carried out.
Firefox check
1. Open Example_from_draw.svg in Firefox The rendering is wrong.
2. Close the file.
3. Open Example.svg in Firefox. Rendering is correct.
4. With the above Example.svg open drag and drop Example_from_draw in Firefox. Rendering is correct this time.

IE check
1. IE renders both files correcty.

Because of this I am not sure where the problem might lie. But in any case.



User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:59.0) Gecko/20100101 Firefox/59.0
Comment 1 Nithin 2018-04-24 14:05:40 UTC
Created attachment 141592 [details]
Example file from Inkscape
Comment 2 Nithin 2018-04-24 14:06:10 UTC
Created attachment 141593 [details]
Example file from Draw
Comment 3 Nithin 2018-04-24 14:06:52 UTC
Created attachment 141594 [details]
How it should look like
Comment 4 Buovjaga 2018-05-14 16:52:26 UTC
Created attachment 142097 [details]
Screenshot from Win 10

It looks correct on Windows, but for some reason not on Linux.

Version: 6.1.0.0.alpha1+
Build ID: 23c5125148a8110d88385b29570bf0b7d4400458
CPU threads: 4; OS: Windows 10.0; UI render: default; 
TinderBox: Win-x86@42, Branch:master, Time: 2018-05-12_00:15:25
Locale: fi-FI (fi_FI); Calc: group

Arch Linux 64-bit
Version: 6.1.0.0.alpha1+
Build ID: 21b11273ae91f0cf7fd5f3f9fd2168e4349852c4
CPU threads: 8; OS: Linux 4.16; UI render: default; VCL: kde4; 
Locale: fi-FI (fi_FI.UTF-8); Calc: group
Built on May 11th 2018
Comment 5 Buovjaga 2018-05-14 16:55:09 UTC
(In reply to Buovjaga from comment #4)
> It looks correct on Windows, but for some reason not on Linux.

I have to note that the wrong rendering is also seen in Firefox on Linux, so I think it is not LibreOffice's fault!
Setting back to unconfirmed.
Comment 6 Xisco Faulí 2018-06-14 10:31:37 UTC
Created attachment 142728 [details]
How it looks in LibreOffice 6.2 master

This isssue is no longer reproducible in

Version: 6.2.0.0.alpha0+
Build ID: 1cf27cb44380f4a2bd6778c2dbbdef2a2a00cbc8
CPU threads: 4; OS: Linux 4.13; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: group threaded
Comment 7 Xisco Faulí 2018-06-14 10:32:16 UTC
Closing as RESOLVED WORKSFORME!!
Comment 8 Buovjaga 2018-06-14 11:00:23 UTC
(In reply to Xisco Faulí from comment #6)
> Created attachment 142728 [details]
> How it looks in LibreOffice 6.2 master
> 
> This isssue is no longer reproducible in
> 
> Version: 6.2.0.0.alpha0+
> Build ID: 1cf27cb44380f4a2bd6778c2dbbdef2a2a00cbc8
> CPU threads: 4; OS: Linux 4.13; UI render: default; VCL: gtk3; 
> Locale: ca-ES (ca_ES.UTF-8); Calc: group threaded

No, it does not match the correct rendering, see my screenshot from Win: attachment 142097 [details]
Comment 9 LibreTraining 2018-08-25 23:10:41 UTC
Think I figured-out what is happening.

The upper font is the correct Open Sans Condensed Bold.

The lower font being displayed is the regular width Open Sans Italic.

Inkscape is embedding the font using the Typographic Family and Typographic Subfamily.
Typographic Family: Open Sans
Typographic Subfamily: Condensed Light Italic

It appears that LibreOffice generally tries to use the Font Family rather than the Typographic Family.

All of the regular width Open Sans fonts have "Open Sans" as the Font Family.
When I tested the Open Sans family a few days ago LO had all kinds of issues with it trying display the correct fonts with the metadata supplied.

Many large font families display perfectly in LO.
Some are a complete mess.
Open Sans is a mess.
And which version of Open Sans you have makes a difference.
If you have the v1.10 from OpenSans.com some of the font have Ope Sans as the Font Family, and there is a separate Open Sans Light family.
Same version from Font Squirrel.
The improved/ enhanced version 1.71 from Free OpenType Fonts has Open Sans as the Font Family on all fonts which makes LO crazy.

Thinking of making a family that works properly in LO on all platforms.

So the bottom line is that the way Inkscape is identifying the font is confusing LO. Take a look in the SVG file and you can see. And compare how Inkscape is selecting fonts in a family in their interfaces vs. how LO is selecting the same fonts in their interface.

I tested the Open Sans Condensed fonts in LO 6.1.0.3 x64 on Windows 7 x64.

LibreOffice selected the font like this
- Font Family: Open Sans Condensed
- Font Subfamily: Italic

Inkscape selected the font like this
- Typographic Family: Open Sans
- Typographic Subfamily: Condensed Light Italic

This is what is in the SVG file that LO does not understand.
So it picked what it thought was the correct font.


.
Comment 10 LibreTraining 2018-08-25 23:32:24 UTC
Above

- Font Family: Open Sans Condensed
should read
- Font Family: Open Sans Condensed Light
Comment 11 Xisco Faulí 2018-10-18 11:01:14 UTC
Let's put this to NEW...
Comment 12 QA Administrators 2019-10-19 02:42:30 UTC Comment hidden (obsolete)
Comment 13 QA Administrators 2021-10-19 03:41:48 UTC Comment hidden (obsolete)
Comment 14 Sophie Sipasseuth 2023-10-19 07:35:37 UTC
Created attachment 190291 [details]
open sans condensed test

No repro, I don't see problem with the last version of LibreOffice.

Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: e9374f74385d7dfe77d1902d3d82af20143bc775
CPU threads: 8; OS: Windows 10.0 Build 22621; UI render: Skia/Raster; VCL: win
Locale: fr-FR (fr_FR); UI: fr-FR
Calc: threaded
Comment 15 Buovjaga 2023-10-19 11:23:53 UTC
The lower one is still not correct on Linux.

Arch Linux 64-bit, X11
Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 7d08767b890e723cd502b1c61d250924f695eb98
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 17 October 2023