Win32: Why are symbol fonts not supported?

View: New views
3 Messages — Rating Filter:   Alert me  

Win32: Why are symbol fonts not supported?

by Peter Frentrup :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I noticed that I cannot load any symbol font with the win32 backend in
pango. While I was debugging the issue, I found the following:

[pangowin32-fontmap.c, line 1026,...]
/* Ignore Symbol fonts (which don't have any Unicode mapping
 * table). We could also be fancy and use the PostScript glyph name
 * table for such if present, and build a Unicode map by mapping
 * each PostScript glyph name to Unicode character. Oh well.
 */
if (lfp->lfCharSet == SYMBOL_CHARSET)
  return;

This restriction prevents anyone from using e.g. the Mathematica fonts
(I already wrote about this problem a while ago) with win32 fontmaps.
Of course, Symbol fonts do not have Unicode mappings, but I don't need
such a mapping, because I know the glyph indices and can insert them
directly in a PangoGlyphString.

It would be nice if the restriction could be removed.

Peter
_______________________________________________
gtk-i18n-list mailing list
gtk-i18n-list@...
http://mail.gnome.org/mailman/listinfo/gtk-i18n-list

Re: Win32: Why are symbol fonts not supported?

by Tor Lillqvist :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> Of course, Symbol fonts do not have Unicode mappings, but I don't need
> such a mapping, because I know the glyph indices and can insert them
> directly in a PangoGlyphString.

Hmm, but if Symbol fonts were allowed, there should then be some check
preventing users from trying to use them with normal strings,? Or will
it work out fine if users do that and they will get what they deserve,
i.e. the unknown glyph thingies?

> It would be nice if the restriction could be removed.

File a bug in bugzilla.gnome.org and attach a patch, and some test code.

--tml
_______________________________________________
gtk-i18n-list mailing list
gtk-i18n-list@...
http://mail.gnome.org/mailman/listinfo/gtk-i18n-list

Re: Win32: Why are symbol fonts not supported?

by Peter Frentrup :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Tor Lillqvist schrieb:
>> Of course, Symbol fonts do not have Unicode mappings, but I don't need
>> such a mapping, because I know the glyph indices and can insert them
>> directly in a PangoGlyphString.
>
> Hmm, but if Symbol fonts were allowed, there should then be some check
> preventing users from trying to use them with normal strings,? Or will
> it work out fine if users do that and they will get what they deserve,
> i.e. the unknown glyph thingies?
I think such an option is not necessary. A user who wants to load a
symbol font normaly knows how to handle it (o at least should know).
One can load symbol fonts with a freetype fontmap on Windows and there
is no such option, either.
> File a bug in bugzilla.gnome.org and attach a patch, and some test code.
Done: http://bugzilla.gnome.org/show_bug.cgi?id=533426
I hope nothing important is missing and the diff file has the
appropriate format. I have no experience with diff/patch commands.

Peter
_______________________________________________
gtk-i18n-list mailing list
gtk-i18n-list@...
http://mail.gnome.org/mailman/listinfo/gtk-i18n-list