FontLab Forum
2012-02-09, 04:20:34 *
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: AFDKO syntax suggestion: script latn include_DFLT;  (Read 2187 times)
Adam Twardoch (FontLab)
Product and marketing manager, Fontlab Ltd.
Administrator
Hero Member
*****

Karma: +12/-4
Germany Germany

Posts: 304


FontLab Studio 5.0.4, Mac OS X 10.4.11


WWW
« on: 2010-06-12, 13:06:48 »

The following is a way to define an OpenType Layout feature swsh to be registered in all globally (i.e. for the entire font) declared languagesystems:

Code:
languagesystem DFLT dflt;
languagesystem latn dflt;
languagesystem latn ROM;
languagesystem cyrl dflt;
languagesystem cyrl SRB;

feature swsh {
  lookup swsh01 {
    sub a by a.swsh;
  } swsh01;
} swsh;

The following is a valid way to write the same but using locally declared languagesystems.

Code:
feature swsh {
  script DFLT;
  language dflt;
    lookup swsh01 {
      sub a by a.swsh;
    } swsh01;
  script latn;
  language dflt;
    lookup swsh01;
  language ROM include_dflt;
  script cyrl;
  language dflt;
    lookup swsh01;
  language SRB include_dflt;
} swsh;

The following is an invalid way to write the same but using locally declared languagesystems (in AFDKO 2.5 syntax). I.e. it will not work with the current AFDKO syntax, although I guess it would be useful if such syntax were implemented.

Code:
feature swsh {
  script DFLT;
  language dflt;
    lookup swsh01 {
      sub a by a.swsh;
    } swsh01;
  script latn include_DFLT;
  script cyrl include_DFLT;
} swsh;

Obviously, I'm proposing the addition of include_DFLT and exclude_DFLT as keywords that can follow a script declaration. If include_DFLT is specified after a script declaration other than DFLT, all lookups defined in the script DFLT would be also registered with the scripts latn and cyrl (in the example above). The default implicit value for should be exclude_DFLT in order not to break backwards-compatibility.

This would make for a rather handy shorthand and eliminate quite some mistakes made by less experienced font developers.
« Last Edit: 2010-06-12, 13:09:32 by Adam Twardoch (FontLab) » Logged
Dezcom
Beta: FontLab Studio Mac
Hero Member
***

Karma: +6/-0
United States United States

Posts: 109


FLS 5.1.1 beta; Mac OSX 10.7.2


« Reply #1 on: 2010-06-13, 17:16:36 »

Sounds reasonable, Adam. Is there some hoop jumping to be done to make it so? Smiley
Logged
Arno Enslin
Hero Member
*****

Karma: +8/-0
Germany Germany

Posts: 98



« Reply #2 on: 2010-06-14, 05:42:58 »

A bit more info in the discussion with Adam on Typophile: http://typophile.com/node/71273

Thanks again, Adam!
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!