FontLab Forum
2012-05-16, 11:42:49 *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Welcome to the FontLab forum, read how to use it! Update: Archives from old MSN forums are now available on our forum.
 
   Home   Help Search Calendar Downloads Tags Login Register  
Del.icio.us Digg FURL FaceBook Stumble Upon Reddit SlashDot

Pages: [1]
  Print  
Author Topic: contextual multiple substitution error  (Read 2199 times)
siggy
Hero Member
*****

Karma: +0/-0
United States United States

Posts: 28


« on: 2010-09-09, 18:56:53 »

No one in the Fontographer or OpenType Layout Feature Development forums has any ideas so far, so I'm asking here.

I'm trying to set up a contextual multiple substitution, but FOG 5 keeps choking on the feature file and won't generate a font. The same substitution works in VOLT for TrueType OpenType fonts, but I'm trying to use it in a feature file (based on Adobe specs) for generating a CFF OpenType font in Fontographer 5.

Here's the basic syntax --

       sub [ @Glyphclass ] comma' by specialglyph comma;

Essentially, the comma should be replaced with both the specialglyph and the comma whenever the comma follows anything within the @Glyphclass.  Or, think of it this way: whenever the comma follows anything within the @Glyphclass, the specialglyph should be inserted before the comma -- without the user having to type the specialglyph.

Any ideas? Is the syntax wrong? Is it just not possible using Adobe specs? Thanks.

Logged
Georg Seifert (FontLab)
Team: FontLab
Sr. Member
****

Karma: +0/-1
Posts: 14


Email
« Reply #1 on: 2010-09-10, 07:02:50 »

One to many substitution are not allowed to be contextual. So you can only do things like:
Code:
sub comma by specialglyph comma;
So you need to do something like:
Code:
sub @Glyphclass comma' by specialcomma;
// new lookup
sub specialcomma by specialglyph comma;

unfortunately this does not work in FontLab or Fontographer.
Logged
siggy
Hero Member
*****

Karma: +0/-0
United States United States

Posts: 28


« Reply #2 on: 2010-09-10, 11:04:45 »

Unfortunately, I need a solution that works with FOG 5 to generate a CFF font. Thanks anyway.

What about an exception rule that contains context (ignore substitution)? What if the comma was always substituted with specialglyph comma, but certain contexts were ignored so the substitution would not happen?

Anyone? Anyone? Bueller? Anyone?

« Last Edit: 2010-09-10, 15:09:30 by siggy » Logged
Arno Enslin
Hero Member
*****

Karma: +8/-0
Germany Germany

Posts: 98



« Reply #3 on: 2010-09-11, 13:58:44 »

@ GeorgS and siggy
Quote
Code:
sub @Glyphclass comma' by specialcomma;
// new lookup
sub specialcomma by specialglyph comma;

With FOG 5 it also should work. FOG 5 uses the actual AFDKO.

Code:
lookup one {
sub @Glyphclass comma' by specialcomma;
} one;
lookup two {
sub specialcomma by specialglyph comma;
} two;

But siggy, since when can cff fonts include layout features?
« Last Edit: 2010-09-11, 14:02:12 by Arno Enslin » Logged
siggy
Hero Member
*****

Karma: +0/-0
United States United States

Posts: 28


« Reply #4 on: 2010-09-13, 15:45:12 »

Thanks, Arno -- I'll give that a try.

OpenType fonts can have TrueType or PostScript (CFF) outlines. The new FOG 5 can generate either format.

The difference? TrueType OpenType fonts for Latin scripts will have to be digitally signed to function correctly in the new Microsoft Word 2010. PostScript OpenType fonts do not need to be signed.

http://forum.fontlab.com/microsoft-visual-opentype-layout-tool-volt/opentype-ligatures-support-in-word-2010-t7176.0.html

Logged
Arno Enslin
Hero Member
*****

Karma: +8/-0
Germany Germany

Posts: 98



« Reply #5 on: 2010-09-13, 16:57:24 »

@ siggy. You can merge a DSIG table into a font with TTX. But I don’t know, if Office 2010 expects a valid digital signature. If it is just the DSIG table, that is required, it is absolutely no problem to add one. You even can add a sigg- or a Arno-table with TTX (http://sourceforge.net/projects/fonttools/).

http://forum.fontlab.com/microsoft-visual-opentype-layout-tool-volt/opentype-ligatures-support-in-word-2010-t7176.0.html

But it is Microsoft’s fault, if the fonts don’t work without a dsig table. I hope, that no font developer is going to fix non existing bugs in their fonts. Although as far as I know, it is according to the specs, that a TT flavored OpenType font must contain a DSIG table. In other words, a TT flavored font with layout features but without a digital signature is less OpenType than a TT flavored font without layout features but with a digital signature. That’s absurd!
Logged
Tags:
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!