Bug 35538 - Handling of fonts with more that 4 styles (R/B/I/BI) is suboptimal
Summary: Handling of fonts with more that 4 styles (R/B/I/BI) is suboptimal
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: high major
Assignee: Not Assigned
URL:
Whiteboard: BSA
Keywords: topicUI
: 69881 87288 93157 112857 (view as bug list)
Depends on: 69254 72944 98596 105298
Blocks: Font-Rendering 103596 Font-List
  Show dependency treegraph
 
Reported: 2011-03-22 05:06 UTC by GwenDragon
Modified: 2018-08-16 14:57 UTC (History)
29 users (show)

See Also:
Crash report or crash signature:


Attachments
Screenshot of character formatting with Kallos ITC (56.18 KB, image/jpeg)
2011-03-22 05:06 UTC, GwenDragon
Details
PDF of galliard test document (244.69 KB, application/pdf)
2012-05-25 16:27 UTC, NoOp
Details
ODT of galliard test document. (227.75 KB, application/vnd.oasis.opendocument.text)
2012-05-25 16:27 UTC, NoOp
Details
PDF of with Kallos formatted ODT (expected result) (236.31 KB, application/pdf)
2014-06-24 07:15 UTC, GwenDragon
Details
PDF of with Kallos formatted ODT (real result) (156.89 KB, application/pdf)
2014-06-24 07:17 UTC, GwenDragon
Details
Screen recording (GIF) showing loss of font format with font family Kallos (1.57 MB, image/gif)
2016-11-10 09:37 UTC, GwenDragon
Details

Note You need to log in before you can comment on or make changes to this bug.
Description GwenDragon 2011-03-22 05:06:08 UTC
Created attachment 44709 [details]
Screenshot of character formatting with Kallos ITC

I'm using Kallos ITC family and in this family six fonts exists:
Kallos ITC Book
Kallos ITC Book Italic
Kallos ITC Medium
Kallos ITC Medium Italic
Kallos ITC Bold
Kallos ITC Bold Italic

Linux shows the fonts as:

user12@pc:~$ fc-list | grep Kallos
Kallos ITC:style=Bold
Kallos ITC:style=Book
Kallos ITC:style=Medium
Kallos ITC:style=Bold Italic
Kallos ITC:style=Medium Italic
Kallos ITC:style=Book Italic

1) LibreOffice shows Kallos ITC Medium as Regular in font selection (picture)!
Strange!

2) If i create a textdocument with a text formatted as Kallos ITC Medium and Kallos ITC Medium italic and reopens in LibreOffice the charcater settings are reset to Kallos ITC Book
LibreOffice does not remmber the font settings.

Seems to be the same as openoffice bug from 2007: http://openoffice.org/bugzilla/show_bug.cgi?id=82986
Comment 1 GwenDragon 2011-03-22 05:07:54 UTC
Font pack can be send to tester for testing only if desired.
Comment 2 GwenDragon 2011-04-02 01:02:33 UTC
Bugfix is important.

LibreOffice should support komplex font families and handle the character formatting with thes fonts.
It would be useless for professionell office work with missing font support.
Comment 3 GwenDragon 2011-07-19 05:23:05 UTC
Same problem in 3.3.2
Comment 4 Cor Nouws 2011-08-02 11:29:52 UTC
.
Comment 5 Björn Michaelsen 2011-12-23 11:43:26 UTC Comment hidden (obsolete, spam)
Comment 6 GwenDragon 2011-12-27 10:21:49 UTC
Bug still exists in:  
LOdev 3.5.0beta2 
Build-ID: c3bcb31-760cc4d-f39cf3d-1b2857e-60db978

Tested on Ubuntu 11.04 x64
Comment 7 GwenDragon 2012-04-27 05:01:38 UTC
Problem exists on 
LibreOffice 3.5.2.2 
Build-ID: 281b639-6baa1d3-ef66a77-d866f25-f36d45f

Linux KUbuntu 11.04 x64
Comment 8 NoOp 2012-05-25 16:25:22 UTC
I can verify with another ITC OpenType font:

I have _many_ ITC fonts on my Ubuntu/Debian system (way too many to list here), and for the most part I can select them in LO (3.5.3.2)[1]. For example, if I select an ITC .otf font galliard:

$ locate galliard
/home/<user>/.fonts/galliard-black.otf
/home/<user>/.fonts/galliard-blackitalic.otf
/home/<user>/.fonts/galliard-bold.otf
/home/<user>/.fonts/galliard-bolditalic.otf
/home/<user>/.fonts/galliard-italic.otf
/home/<user>/.fonts/galliard-roman.otf
/home/<user>/.fonts/galliard-ultra.otf
/home/<user>/.fonts/galliard-ultraitalic.otf

As you can see, the only galliard fonts on this system are .otf.

In LO 3.5 (via Format|Character) I can select ITC Galliard:
Ultra
UltraItalic
Roman
Italic
Bold
Bold Italic
Black
Ultra Italic
Black Italic

I made a file with each font selection, took a screenshot & added it to the file, saved the file, closed LO and reopened LO and the file.

Before saving I noticed that the bolding seemed to be backwards (with bold selected the font appears normal, with bold unselected from LO icon the font appears bold).

After saving I noticed (in addition to the bolding) when checking Format|Charater:
- Italic changed UltraItalic
- Roman changed to Ultra
It is repeatable & I'll add a pdf and odt of the document.

[1] LibreOffice 3.5.3.2 
Build ID: 235ab8a-3802056-4a8fed3-2d66ea8-e241b8
Comment 9 NoOp 2012-05-25 16:27:05 UTC
Created attachment 62116 [details]
PDF of galliard test document
Comment 10 NoOp 2012-05-25 16:27:48 UTC
Created attachment 62117 [details]
ODT of galliard test document.
Comment 11 GwenDragon 2012-10-17 13:42:42 UTC
Problem still exists in LibreOffice 3.6.1.2 with Linux Debian 6 x64
Comment 12 GwenDragon 2012-10-17 13:47:21 UTC
Forgot information about sys for previous comment:

LibreOffice 3.6.1.2  Build ID e29a214
KDE 4.8.4
Debian 6.06
Comment 13 GwenDragon 2013-04-10 14:38:00 UTC
My problem with font described in 1) and 2) still exists in:

Libreoffice Version 3.6.5.2 (Build ID: 5b93205)
Debian 6 x64, KDE 4.8.4

1) Kallos ITC Bold is displayed as Bold
Kallos ITC Medium is displayed as Standard

2) Formatting for Kallos ITC Medium is reset to Kallos ITC Book
Comment 14 GwenDragon 2014-04-28 10:30:06 UTC
Bug confirmed for 
Libreoffice 4.1.5.3 Build-ID: 1c1366bba2ba2b554cd2ca4d87c06da81c05d24
Debian 7.2 x64, KDE 4.8.4
Comment 15 GwenDragon 2014-06-24 07:03:27 UTC
Bug mentioned in https://bugs.freedesktop.org/show_bug.cgi?id=35538#c13 confirmed for LbreOffice 4.2.4.2 Build-ID: 63150712c6d317d27ce2db16eb94c2f3d7b699f8
on Debian 7.5 x64 KDE
Comment 16 GwenDragon 2014-06-24 07:15:06 UTC
Created attachment 101641 [details]
PDF of with Kallos formatted ODT (expected result)

Formatted with Kallos ITC as it should really be after opening ODT with LibreOffice
Comment 17 GwenDragon 2014-06-24 07:17:05 UTC
Created attachment 101642 [details]
PDF of with Kallos formatted ODT (real result)

This PDF shows that LibreOffice lost format of text KallosITCMedium after reopening ODT
Comment 18 GwenDragon 2014-10-27 15:20:17 UTC
Confirmed for Libreoffice Version: 4.2.6.3 Build-ID: 3fd416d4c6db7d3204c17ce57a1d70f6e531ee21
on Debian 7.7 x64 with KDE 4.8.4
Comment 19 GwenDragon 2014-11-28 10:39:15 UTC
Same problem of loosing formatting after saving and reopening document.
 
LibreOffice 4.3.3.2 Build-ID: 430m0(Build:2)
KDE 4.14.2 on Debian 7 Testing
Comment 20 dkcmtdfned 2015-11-06 13:08:44 UTC
I have been experiencing what I believe to be the same problem described in this bug with LibreOffice versions 4.4.6.3 and 5.0.3.2.
Comment 21 QA Administrators 2016-11-08 11:56:09 UTC Comment hidden (obsolete, spam)
Comment 22 GwenDragon 2016-11-08 13:35:32 UTC
Confirmed for
Libreoffice 5.2 x64 
Version: 5.2.3.1 Build-ID: 1:5.2.3~rc1-4~bpo8+1
Debian 8.6 x64 KDE 4.14.2
Comment 23 GwenDragon 2016-11-08 13:53:43 UTC
Confirmed for
Libreoffice  4.3 
Version: 4.3.3.2 
Build ID: 430m0(Build:2)
Debian 8.6 x64 KDE 4.14.2
Comment 24 Cor Nouws 2016-11-09 20:07:41 UTC
@Khaled

is this something that touches your work on fonts/rendering, maybe? Thanks!

Subject: Re: [tdf-discuss] Libnreoffice Writer (3.x, 4.x, 5.x) on Linux
looses font  formt after repening document
Date: Wed, 9 Nov 2016 19:49:19 +0100
From: GwenDragon <info@gwendragon.de>
To: Cor Nouws <oolst@nouenoff.nl>

Hello Cor,
On Wed, 9 Nov 2016, at 13:23:34 [GMT +0100] (which was 13:23 where I
live) Cor wrote:

> Now that I'm writing this: there is some changes ongoing in font
> handling at the moment. Can you try a fresh daily build maybe?
> http://dev-builds.libreoffice.org/daily/master/

Unfortunately the daily 5.3 dev build did not find the Type 1 fonts.
The fonts are not shown in fonts list/dropdown.
Comment 25 GwenDragon 2016-11-10 09:37:30 UTC
Created attachment 128639 [details]
Screen recording (GIF) showing loss of font format with font family Kallos

Shows that the previous set font style of Kallos ITC Medium is reset after saving and reopening document.
Comment 26 Khaled Hosny 2016-11-10 18:54:01 UTC
This might be related to the fact that we don’t handle fonts that has more than four styles R/B/I/BI quite well. But that is related to font selection not layout.
Comment 27 Thomas Linard 2016-12-30 15:57:33 UTC
Indeed, LibreOffice doesn't handle fonts that has more than four styles R/B/I/BI quite well. I don't know for Linux, but Windows and macOS (since LO 4.1) use platform dependent handling.
LibreOffice on Windows use traditional GDI handling, LibreOffice on macOS use CoreText (and, probably, incorrectly, as the styles names are localised). See my Bug 69881 for LibreOffice 4.1, still valid for 5.3. And the numerous duplicates of Bug 69254.
Comment 28 Xisco Faulí 2017-07-13 11:00:11 UTC
Setting Assignee back to default. Please assign it back to yourself if you're
still working on this issue
Comment 29 Thomas Linard 2018-01-05 09:55:07 UTC
*** Bug 72944 has been marked as a duplicate of this bug. ***
Comment 30 Thomas Linard 2018-01-05 09:55:37 UTC
*** Bug 69254 has been marked as a duplicate of this bug. ***
Comment 31 Thomas Linard 2018-01-05 09:57:09 UTC
*** Bug 101905 has been marked as a duplicate of this bug. ***
Comment 32 Thomas Linard 2018-01-05 09:57:28 UTC
*** Bug 89242 has been marked as a duplicate of this bug. ***
Comment 33 Thomas Linard 2018-01-05 09:57:41 UTC
*** Bug 79726 has been marked as a duplicate of this bug. ***
Comment 34 Thomas Linard 2018-01-05 09:57:51 UTC
*** Bug 69881 has been marked as a duplicate of this bug. ***
Comment 35 Thomas Linard 2018-01-05 09:58:10 UTC
*** Bug 68889 has been marked as a duplicate of this bug. ***
Comment 36 Thomas Linard 2018-01-05 09:59:08 UTC
*** Bug 72938 has been marked as a duplicate of this bug. ***
Comment 37 Thomas Linard 2018-01-05 10:01:41 UTC
*** Bug 100835 has been marked as a duplicate of this bug. ***
Comment 38 Thomas Linard 2018-01-05 10:02:23 UTC
*** Bug 87288 has been marked as a duplicate of this bug. ***
Comment 39 Thomas Linard 2018-01-05 10:03:20 UTC
*** Bug 98596 has been marked as a duplicate of this bug. ***
Comment 40 Thomas Linard 2018-01-05 10:06:20 UTC
*** Bug 105298 has been marked as a duplicate of this bug. ***
Comment 41 Thomas Linard 2018-01-05 10:16:23 UTC
*** Bug 83006 has been marked as a duplicate of this bug. ***
Comment 42 Thomas Linard 2018-01-05 10:16:47 UTC
*** Bug 93157 has been marked as a duplicate of this bug. ***
Comment 43 Thomas Linard 2018-01-05 10:17:15 UTC
*** Bug 95816 has been marked as a duplicate of this bug. ***
Comment 44 Tor Lillqvist 2018-01-22 17:47:39 UTC
Even if this problem apparently is present on all platforms, the actual font enumeration code is still platform-specific, so separate fixes might well be needed for macOS, Windows, and Linux.
Comment 45 Tor Lillqvist 2018-01-22 21:23:53 UTC
The font enumeration and UI aspect is just one part of the issue. What apparently hasn't been taken into consideration at all in the comments above is how to handle the "extra" styles in the document formats, in a backward-compatible way, so that the document wouldn't break horribly if opened in another application reading the same format, or in an older version of LibreOffice. Far from trivial.
Comment 46 Thomas Linard 2018-01-22 22:15:06 UTC
But the documents are already "breaking horribly" because of platform-specific handling…
Comment 47 Tor Lillqvist 2018-01-23 12:07:08 UTC
Actually, I take my previous comment back. It was pointed out to me that even if the toolbar just has a typeface selector and the B and I buttons, in the right-click:Character...:Font dialog there is a separate "Style" selector (sadly called "Typeface" on the Mac), and with that one can select any of the styles the typeface is available in. For instance, for the Overpass typeface, "Thin Italic".

See my further comments in https://bugs.documentfoundation.org/show_bug.cgi?id=69254#c32
Comment 48 Thomas Linard 2018-01-30 14:02:11 UTC
I organized the bugs this way:

Bug 35538 (this bug)
  blocked by:
  bug 69254 (CoreText bugs - Mac)
  bug 72944 (future DirectWrite implementation - Windows)
  bug 98596 (FontConfig bugs - Linux)
  bug 105298 (cross-platform bugs)

Bug 35538 (this bug)
   blocking:
   bug 103596 (future Variable Fonts implementation)
Comment 49 Khaled Hosny 2018-02-01 19:26:37 UTC
*** Bug 112857 has been marked as a duplicate of this bug. ***
Comment 50 V Stuart Foote 2018-08-06 01:30:58 UTC
*** Bug 119116 has been marked as a duplicate of this bug. ***