Issue 28610 - ITC substring in font names got ignored
Summary: ITC substring in font names got ignored
Status: CLOSED FIXED
Alias: None
Product: Writer
Classification: Application
Component: code (show other issues)
Version: OOo 1.1.1
Hardware: PC All
: P3 Trivial with 1 vote (vote)
Target Milestone: ---
Assignee: hdu@apache.org
QA Contact: issues@sw
URL:
Keywords: oooqa
: 78497 (view as issue list)
Depends on:
Blocks:
 
Reported: 2004-05-02 10:15 UTC by jvromans
Modified: 2013-08-07 14:43 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description jvromans 2004-05-02 10:15:54 UTC
vcl/unx/source/gdi/salgdi3.cxx contains explicit code to strip the ITC prefix on
font names. This is wrong, and causes problems when exchanging documents to and
from platforms that treat the font names correctly (probably all platforms
except *ix).

Note that this issue is not dependent on 26102.
Comment 1 flibby05 2004-05-02 11:13:01 UTC
set to "NEW"
Comment 2 michael.ruess 2004-05-03 11:26:07 UTC
MRU->US: please give your comment on this.
Comment 3 ulf.stroehler 2004-05-03 11:53:23 UTC
It's not that OOo doesn't like ITC but it tries to strip the XLFD font name so
that only the font family name gets displayed (the foundry field is as you
encountered also stripped). This has proven to work quite well now for a long time.
Unless you don't explicitly mention what "problems" this shall have on
"exchanging documents" I see no reason to change this. Thus the real issue seems
to be something else? Please describe.
Comment 4 jvromans 2004-05-03 14:20:23 UTC
The underlying intention is clear and honest.

Given, for example, font Garamond-Light, with name "ITC Garamond Light". On
Linux, the font name is stripped to "Garamond". When I save a document with that
font, the font name "Garamond" is saved with the document.

Exactly the same font (same .ttf) on Windows produces the font name "ITC
Garamond". When opening the (Linux) document on Windows, it cannot find the
correct font. Worse, it will try to use the font "Garamond" that happens to be
present on Windows, but with different typefaces and metrics.

IIRC, ITC added the prefix "ITC" to the font name to prevent it from being mixed
up with other Garamond fonts, just like many other foundries add pre- and postfixes.

Personally, I think stripping the ITC prefix is wrong. But the main problem is
the difference in treatment between platforms. If you insist on stripping the
prefix, then strip it on Windows as well.
Comment 5 ulf.stroehler 2004-05-03 17:46:42 UTC
Thanks for the update. So the problem is clear to me now.

On the other hand on Un*x you'll often find font aliases of the type
"Avantgarde" -> "ITC Avant Garde" (e.g. on Solaris 9). This example proves that
the current font name heuristic is  reasonable. Otherwise you'll get a long font
list with lots of dupes.

Regarding the mentioned different font naming on Windows compared to Un*x, I'll
guess this is due to different APIs. HDU, can you comment on this? 

Assuming the latter assumption is true, the only way out for OOo would be to
port the Un*x font name heuristic to Win32 to achieve consistency. Besides the
expenses of such a port (development, QA efford, bloating code) I bet that we'll
catch new issues, this time in the area of MS document import on Win32, choosing
wrong fonts :-(
Comment 6 lohmaier 2004-05-03 21:24:31 UTC
seems to be a dupe of issue 3730 if so, please close one or the other...
Comment 7 jvromans 2004-05-04 07:00:47 UTC
In a way it is related to 3730, but I'd consider this a separate bug since it
only affects the ITC prefix, while 3730 addresses a much more general issue.
Comment 8 jvromans 2004-06-21 11:33:38 UTC
I think the problem is clear, and each alternative solution has its pros and
cons. So I'd suggest to add a user option in OpenOffice.org > Fonts. This way it
is up to the user to decide whether to go for legacy compatibility, or correctness.

I someone can hint me how to add user options, I may provide a proof-of-concept
implementation.
Comment 9 hdu@apache.org 2004-08-05 12:20:59 UTC
HDU->CP: please decide based on the pros and cons outlined above...
Comment 10 christof.pintaske 2004-08-05 16:07:59 UTC
no additional UI changes for 2.0. I hope to address ease of use of fonts in the
next release after 2.0 
Comment 11 christof.pintaske 2005-02-22 17:54:05 UTC
cp->hdu: please push on your pile
Comment 12 pmjdebruijn 2008-06-01 18:23:02 UTC
I can confirm this for 2.4 and 3.0beta. This bug is still present.

All Bitstream ITC fonts, are incorrectly displayed without the ITC prefix.

In one case, it even clashes with another fonts:

* Bitstream ITC Garamond incorrectly displayed as "Garamond" should be "ITC
Garamond"
* Monotype Garamond correcty displayed as "Garamond"

This is very bad behaviour! OpenOffice.org should not be "intelligent" about
font naming, unless stuff is missing. Fonts should be displayed exactly as they are.

Please fix it for 3.0 final.
Comment 13 pmjdebruijn 2008-06-01 18:24:09 UTC
I've reported this as well to Ubuntu's Launchpad:

https://bugs.launchpad.net/openoffice/+bug/118370
Comment 14 hdu@apache.org 2008-06-02 08:01:47 UTC
Well, the change from OOo2 to OOo3 is a chance to fix this => retargeting
Comment 15 hdu@apache.org 2008-06-04 12:38:39 UTC
I have no clue what the original idea behind that ITC-substring-stripping magic was, but the OOo2-
>OOo3 change is a chance to get rid of it... => done in CWS vcl89
Comment 16 philipp.lohmann 2008-06-06 13:02:39 UTC
verified
Comment 17 hdu@apache.org 2008-07-02 09:17:39 UTC
the change got into DEV300_m22 => closing
Comment 18 eric.savary 2008-09-12 17:34:14 UTC
*** Issue 78497 has been marked as a duplicate of this issue. ***