Code simplification - help needed

Get help with FontCreator here. Please do not post feature requests or bug reports here.
Post Reply
Soleille
Posts: 16
Joined: Sat Jul 29, 2017 6:15 pm

Code simplification - help needed

Post by Soleille » Thu Aug 03, 2017 10:33 am

Hello ! :)

I'm a complete beginner, so it's difficult for me to do things in FontCreator.

In the following code I'm writing several times "sub 0 SingleSubstitution1;" :

Code: Select all

lookup ChainingContext2 {
  subtable "Subtable 1" {
    context @num1(@num2);
    sub 0 SingleSubstitution1;
  }
  subtable "Subtable 2" {
    context @num1(@numE);
    sub 0 SingleSubstitution1;
  }
  subtable "Subtable 3" {
    context @numI (@ttesE);
    sub 0 SingleSubstitution1;
  }
  subtable "Subtable 4" {
    context @num3 (@num4);
    sub 0 SingleSubstitution1;
  }
}
Is there another/better way of writing this ?

Thank you. :)

Erwin Denissen
Moderator
Moderator
Posts: 8288
Joined: Fri Oct 04, 2002 12:41 am
Location: Bilthoven, The Netherlands
Contact:

Re: Code simplification - help needed

Post by Erwin Denissen » Thu Aug 03, 2017 10:46 am

I don't think it can be reduced to shorter code, unless you can combine sub tables.
Erwin Denissen
High-Logic
Proven Font Technology

Soleille
Posts: 16
Joined: Sat Jul 29, 2017 6:15 pm

Re: Code simplification - help needed

Post by Soleille » Thu Aug 03, 2017 10:52 am

Ok. Thank you. :)

Post Reply