Hello, I’m hoping someone can help with a difficulty I’m having with contextual substitution in Adobe Indesign, Photoshop and Illustrator.
I’ve read that text is treated differently between Adobe programs but the problem I’m having seems to be similar across them all.
This is my first typeface and the visuals below are far from crafted in terms of design, spacing, kerning etc. so please ignore that. My ambition is to create a specific-purpose typeface that substitutes a LOT of words and phases with alternate words and phrases. Also accounting for case (lowercase, all-caps and sentence case).
In Indesign, the issue is this:
— when ‘Adobe Paragraph Composer’ is selected, characters added to extend a word/phase don’t work and the last character of the original word/phrase persists
— when ‘Adobe Word-Ready Paragraph Composer’ is selected, the extended characters work perfectly but wherever a space occurs in the original word/phrase there is a corresponding spacing error in the substituted word/phrase.
In the image below every word/phrase in the left column should change to the word ‘forever’ in the right column.
In Illustrator the issue is observed when switching between ‘Adobe single-line Composer’ and ‘Middle Eastern & South Asian Every-line Composer’ (which needs to be activated through Illustrator preferences).
In Photoshop the issue is observed when switching between ‘Latin and East Asian Layout’ and ‘Middle Eastern and South Asian Layout’.
I’ve arrived at the code below which works almost exactly as desired in programs other than Indesign, Illustrator and Photoshop.
ignore substitute @alpha [N n]’ [O o]’ [W w]’, [N n]’ [O o]’ [W w]’ @alpha;
sub [N n]’ [O o] [W w] by [F.alt f.alt];
sub [F.alt f.alt] [O o]’ [W w] by [O.alt o.alt];
sub [F.alt f.alt] [O.alt o.alt] W’ by R.alt E.alt V.alt E.alt R.alt;
sub [F.alt f.alt] [O.alt o.alt] w’ by r.alt e.alt v.alt e.alt r.alt;
sub [Q q]’ [U u] [I i] [Z z] [Z z] [E e] [D d] by [F.alt f.alt];
sub [F.alt f.alt] [U u]’ [I i] [Z z] [Z z] [E e] [D d] by [O.alt o.alt];
sub [F.alt f.alt] [O.alt o.alt] [I i]’ [Z z] [Z z] [E e] [D d] by [R.alt r.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [Z z]’ [Z z] [E e] [D d] by [E.alt e.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [Z z]’ [E e] [D d] by [V.alt v.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [V.alt v.alt] [E e]’ [D d] by [E.alt e.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [V.alt v.alt] [E.alt e.alt] [D d]’ by [R.alt r.alt] ;
sub [A a]’ space [H h] [O o] [L l] [I i] [D d] [A a] [Y y] by [F.alt f.alt];
sub [F.alt f.alt] space’ @uppr [O o] [L l] [I i] [D d] [A a] [Y y] by O.alt;
sub [F.alt f.alt] space’ @lowr [O o] [L l] [I i] [D d] [A a] [Y y] by o.alt;
sub [F.alt f.alt] [O.alt o.alt] [H h]’ [O o] [L l] [I i] [D d] [A a] [Y y] by [R.alt r.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [O o]’ [L l] [I i] [D d] [A a] [Y y] by [E.alt e.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [L l]’ [I i] [D d] [A a] [Y y] by [V.alt v.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [V.alt v.alt] [I i]’ [D d] [A a] [Y y] by [E.alt e.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [V.alt v.alt] [E.alt e.alt] [D d]’ [A a] [Y y] by [R.alt r.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [V.alt v.alt] [E.alt e.alt] [R.alt r.alt] [A a]’ [Y y]’ by .notdef;
sub [O o]’ [N n] [E e] space [D d] [A a] [Y y] by [F.alt f.alt];
sub [F.alt f.alt] [N n]’ [E e] space [D d] [A a] [Y y] by [O.alt o.alt];
sub [F.alt f.alt] [O.alt o.alt] [E e]’ space [D d] [A a] [Y y] by [R.alt r.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] space’ @uppr [A a] [Y y] by E.alt;
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] space’ @lowr [A a] [Y y] by e.alt;
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [D d]’ [A a] [Y y] by [V.alt v.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [V.alt v.alt] [A a]’ [Y y] by [E.alt e.alt];
sub [F.alt f.alt] [O.alt o.alt] [R.alt r.alt] [E.alt e.alt] [V.alt v.alt] [E.alt e.alt] [Y y]’ by [R.alt r.alt] ;
ignore substitute @alpha [A a]’ [S s]’, [A a]’ [S s]’ @alpha;
sub [A a]’ [S s] by [F.alt f.alt];
sub [F.alt f.alt] S’ by O.alt R.alt E.alt V.alt E.alt R.alt;
sub [F.alt f.alt] a’ by o.alt r.alt e.alt v.alt e.alt r.alt;
Any help with this would be greatly appreciated.