Page 1 of 1

Code simplification - help needed

Posted: Thu Aug 03, 2017 10:33 am
by Soleille
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. :)

Re: Code simplification - help needed

Posted: Thu Aug 03, 2017 10:46 am
by Erwin Denissen
I don't think it can be reduced to shorter code, unless you can combine sub tables.

Re: Code simplification - help needed

Posted: Thu Aug 03, 2017 10:52 am
by Soleille
Ok. Thank you. :)