questions about OpenType fonts with CFF data

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

questions about OpenType fonts with CFF data

by Manlio Perillo-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi.

I'm writing an OpenType font parser (in Python), and I want to implement
support for parsing the CFF data (I found the parser code in FreeType
very useful, thanks).

Unfortunately the OpenType spec is not very detailed about CFF, so I
have decided to ask the questions here; I hope its not a problem!

I have 3 questions:
1) Should I assume that only 1 font is allowed in the FontSet?
2) Should I assume that only CID-keyed fonts are allowed?
3) Should I assume that only charstring type 2 format is allowed?



Thanks   Manlio Perillo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkrHgnYACgkQscQJ24LbaUSv6ACeO5YIUxDE6+nUiuqND0+Ipyyh
YAwAn3b2PIfUKbkEDE576CVh1aCDepsa
=M47m
-----END PGP SIGNATURE-----


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Tom Kacvinsky-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

http://www.adobe.com/devnet/font/pdfs/5176.CFF.pdf  should give you  
more information on CFF.

AS for your assumptions:

(1) Most OpenTpe/CFF fonts I have seen have only one font in the FontSet

(2) There are other font encoding methods that can be used besides  
CID keyed fonts

(3) I've never seen a CFF font that uses Type 1 charstrings.  So you  
are left with Type 2
       charstrings.

Regards,

Tom


On 2009/10/03, at 12:57 , Manlio Perillo wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hi.
>
> I'm writing an OpenType font parser (in Python), and I want to  
> implement
> support for parsing the CFF data (I found the parser code in FreeType
> very useful, thanks).
>
> Unfortunately the OpenType spec is not very detailed about CFF, so I
> have decided to ask the questions here; I hope its not a problem!
>
> I have 3 questions:
> 1) Should I assume that only 1 font is allowed in the FontSet?
> 2) Should I assume that only CID-keyed fonts are allowed?
> 3) Should I assume that only charstring type 2 format is allowed?
>
>
>
> Thanks   Manlio Perillo
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.9 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
>
> iEYEARECAAYFAkrHgnYACgkQscQJ24LbaUSv6ACeO5YIUxDE6+nUiuqND0+Ipyyh
> YAwAn3b2PIfUKbkEDE576CVh1aCDepsa
> =M47m
> -----END PGP SIGNATURE-----
>
>
> _______________________________________________
> Freetype-devel mailing list
> Freetype-devel@...
> http://lists.nongnu.org/mailman/listinfo/freetype-devel



_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Manlio Perillo-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Tom Kacvinsky ha scritto:
> http://www.adobe.com/devnet/font/pdfs/5176.CFF.pdf  should give you more
> information on CFF.
>

Yes, I have already read it.
That problem is that I'm assuming there can be some restrictions when a
CFF font is embedded in an OpenType font.

In more detail, I'm writing a program that needs to embed OpenType fonts
in a PDF document.


> AS for your assumptions:
>
> (1) Most OpenTpe/CFF fonts I have seen have only one font in the FontSet
>

So, does this means that you have seen OpenType fonts with CFF data
having multiple font?

I can't figure out how these fonts should be handled.
There is only one cmap in the OpenType font.


> [...]


Thanks   Manlio Perillo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkrHyO4ACgkQscQJ24LbaUTUhgCeMfxH7kEm+o5AeAJQkTZHL2xL
cYoAniwQ6sb3cW/HXhi7nC2IN6WHpxTq
=qc/4
-----END PGP SIGNATURE-----


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Werner LEMBERG :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


> That problem is that I'm assuming there can be some restrictions
> when a CFF font is embedded in an OpenType font.

Actually, I think there are CFFs with Type 1 charstrings out there in
the wild, but it is definitely not the rule but rather the result of
poor conversion of Type 1 fonts to the CFF format.

>> (1) Most OpenTpe/CFF fonts I have seen have only one font in the
>> FontSet
>
> So, does this means that you have seen OpenType fonts with CFF data
> having multiple font?

This is not possible.  According to people from both Adobe and
Microsoft (as discussed on the OpenType mailing list, IIRC), a CFF
font in an SFNT wrapper can only have a single font.  This is
undocumented, however.


    Werner

_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Manlio Perillo-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Werner LEMBERG ha scritto:

> [...]
>>> (1) Most OpenTpe/CFF fonts I have seen have only one font in the
>>> FontSet
>> So, does this means that you have seen OpenType fonts with CFF data
>> having multiple font?
>
> This is not possible.  According to people from both Adobe and
> Microsoft (as discussed on the OpenType mailing list, IIRC), a CFF
> font in an SFNT wrapper can only have a single font.  This is
> undocumented, however.
>

Ok, thanks; this confirms my idea.
I hope this will get documented, at least in the ISO Open Font Format
specification.


Another restriction, IMHO, is with the FontMatrix: it can only take
values:  [1/unitsPerEm 0 0 1/unitsPerEm 0 0]


Is the OpenType mailing list you are speaking about this:
http://www.microsoft.com/typography/OTSPEC/otlist.htm
?



Regards  Manlio Perillo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkrIV8MACgkQscQJ24LbaURmeACfUb+n1sgXPfHOV4Mcq1KJErfr
jsQAnAgGt1sd71HOKyl/7xAk9ug8R7pN
=BBCb
-----END PGP SIGNATURE-----


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by George Williams :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


----- Werner LEMBERG <wl@...> wrote:
> > So, does this means that you have seen OpenType fonts with CFF data
> > having multiple font?
>
> This is not possible.  According to people from both Adobe and
> Microsoft (as discussed on the OpenType mailing list, IIRC), a CFF
> font in an SFNT wrapper can only have a single font.  This is
> undocumented, however.

Both the mac (10.6) and freetype support ttc files with CFF data in them...


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Manlio Perillo-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

George Williams ha scritto:

> ----- Werner LEMBERG <wl@...> wrote:
>>> So, does this means that you have seen OpenType fonts with CFF data
>>> having multiple font?
>> This is not possible.  According to people from both Adobe and
>> Microsoft (as discussed on the OpenType mailing list, IIRC), a CFF
>> font in an SFNT wrapper can only have a single font.  This is
>> undocumented, however.
>
> Both the mac (10.6) and freetype support ttc files with CFF data in them...
>

But that's a different question.

In a TrueType Collection, you have N fonts, and each font has its own
CFF data, its own cmap, and so on.



Regards   Manlio Perillo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkrI/nQACgkQscQJ24LbaURjkACfayjTdRdwh66FRNETgHElFvuJ
3zAAn3fYBFaA1JGP75Q1LYi3ofq/LlT2
=S2Eg
-----END PGP SIGNATURE-----


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Werner LEMBERG :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Sorry for the late reply.

>>> So, does this means that you have seen OpenType fonts with CFF
>>> data having multiple font?
>>
>> This is not possible.  According to people from both Adobe and
>> Microsoft (as discussed on the OpenType mailing list, IIRC), a CFF
>> font in an SFNT wrapper can only have a single font.  This is
>> undocumented, however.
>
> Ok, thanks; this confirms my idea.  I hope this will get documented,
> at least in the ISO Open Font Format specification.

I think it won't, since this is a limitation of the various OpenType
implementations and not of the specification itself.

> Another restriction, IMHO, is with the FontMatrix: it can only take
> values: [1/unitsPerEm 0 0 1/unitsPerEm 0 0]

From where did you get this information?

> Is the OpenType mailing list you are speaking about this:
> http://www.microsoft.com/typography/OTSPEC/otlist.htm
> ?

Yes; you might subscribe and try to get an answer to your above
question.  However, I think that this page is out of date; the correct
address is, AFAIK,

  opentype-migration-sub@...

for subscription.


    Werner


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Manlio Perillo-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Werner LEMBERG ha scritto:

> Sorry for the late reply.
>
>>>> So, does this means that you have seen OpenType fonts with CFF
>>>> data having multiple font?
>>> This is not possible.  According to people from both Adobe and
>>> Microsoft (as discussed on the OpenType mailing list, IIRC), a CFF
>>> font in an SFNT wrapper can only have a single font.  This is
>>> undocumented, however.
>> Ok, thanks; this confirms my idea.  I hope this will get documented,
>> at least in the ISO Open Font Format specification.
>
> I think it won't, since this is a limitation of the various OpenType
> implementations and not of the specification itself.
>

I have some doubts.
This is a limitation of the OpenType specification, since IMHO it can
not really handle CFF data with more than one font.

How do you associate, as an example, the metrics data with multiple fonts?

> [...]


Regards   Manlio
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkrna9oACgkQscQJ24LbaUToZgCfX+JdUqs3x4NZTAHliHDmsNRC
VQcAmgKFqMgdpxUBZte9t5X8MpOOEo2P
=Zej8
-----END PGP SIGNATURE-----


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Werner LEMBERG :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

>> I think it won't, since this is a limitation of the various
>> OpenType implementations and not of the specification itself.
>
> I have some doubts.  This is a limitation of the OpenType
> specification, since IMHO it can not really handle CFF data with
> more than one font.
>
> How do you associate, as an example, the metrics data with multiple
> fonts?

Probably you are right.  Can you discuss this on the OpenType mailing
list?


    Werner


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Manlio Perillo-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Werner LEMBERG ha scritto:

>>> I think it won't, since this is a limitation of the various
>>> OpenType implementations and not of the specification itself.
>> I have some doubts.  This is a limitation of the OpenType
>> specification, since IMHO it can not really handle CFF data with
>> more than one font.
>>
>> How do you associate, as an example, the metrics data with multiple
>> fonts?
>
> Probably you are right.  Can you discuss this on the OpenType mailing
> list?
>

I have sent my subscription request, but I have not yet received a
response; that list is moderated.

It's infortunate, I have other questions about OpenType, like, as an
example, why they added the VORG table instead of a more general table
with bounding box for each glyph.


Thanks   Manlio
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkrvQEQACgkQscQJ24LbaUQYLwCfTAOrcQ70zuSN6+56Krw/Gkqj
AtQAoJR/lr0DJ3pbLAkm5dgmLDX9nHhU
=jIj8
-----END PGP SIGNATURE-----


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Werner LEMBERG :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> I have sent my subscription request, but I have not yet received a
> response; that list is moderated.

Just to be sure, here are the actual addresses again.

  subscribe: opentype-migration-sub@...
  unsubscribe: opentype-migration-unsub@...
  messages: opentype-migration-list@...

Another forum might be

http://typophile.com/forum

For example, look at

  http://typophile.com/node/62675


     Werner


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Ralph Giles-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Mon, Nov 2, 2009 at 12:25 PM, Manlio Perillo
<manlio.perillo@...> wrote:

> I have sent my subscription request, but I have not yet received a
> response; that list is moderated.

FWIW, I signed up recently, and there was a week or two before my
subscription was approved. Patience seems to be in order...

 -r


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel

Re: questions about OpenType fonts with CFF data

by Manlio Perillo-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Ralph Giles ha scritto:
> On Mon, Nov 2, 2009 at 12:25 PM, Manlio Perillo
> <manlio.perillo@...> wrote:
>
>> I have sent my subscription request, but I have not yet received a
>> response; that list is moderated.
>
> FWIW, I signed up recently, and there was a week or two before my
> subscription was approved. Patience seems to be in order...
>

My subscription was accepted right after I sent this message; thanks.



Regards  Manlio
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkrwHIoACgkQscQJ24LbaUStRACfZJYJ2uuRfU+IRb+gfZ5pTMkb
4dAAoJuJwY9c5GZDIIF3Br/dO0uEBwvn
=5fmJ
-----END PGP SIGNATURE-----


_______________________________________________
Freetype-devel mailing list
Freetype-devel@...
http://lists.nongnu.org/mailman/listinfo/freetype-devel