I’m trying to adopt a script that Mekkablue wrote in order to automatically generate “Replace Glyphs” custom parameters for spin-off instances of my typeface (e.g., I’m trying to make a “SC Regular” instance identical to the “Regular” instance, except that the smcp feature is “always on”).
It does work, but I have the problem that ligatures and contextual alternates remain programmed as appropriate for the baseline font. I tried making .sc alternates for all lowercase ligatures and setting them to “do not export”, hoping that they would not be included in the liga feature when it was automatically recreated. Unfortunately, they apparently remain in use (according to the instance preview window).
Now, I suppose I could just recreate all of those ligatures as smallcaps and unnecessarily use them in the SC fonts. However, I would much prefer finding a way to remove them prior to export. Is there a Custom Parameter I should add to regenerate the liga feature? Or if the automatic liga feature is insensitive to non-exporting glyphs, could you help me add a line in my script to delete any .liga.sc beforehand?
just to make sure, if you rename glyphs, you do not need to remove the original glyphs first. so, if you are renaming a.ss01=a, you should not have remove a in your parameters.
but having set it up in the instances is much more convenient and also more flexible as the mentioned tool can only apply what is encoded with a feature. The build in solution is independent of the features.
OK, so I’ve belatedly figured out that I should offer an Italic to go with the Infant fonts, especially since the default Italic has Roman-style architecture for /g and /y and thus doesn’t work well as a replacement.
Now I’m running into the problem that if I replace the regular /g with /g.ss03 etc., the contextual alternate programming that keys off /g.ss03 etc no longer works. I suppose I need to replace either the .calt code or the class that I’m using for this particular replacement. Can I do this with custom parameters?
That’s what I’m already doing, but then this no longer works:
Class «alike»:
... g.ss03 ...
Feature «calt»:
lookup aFillerPrepPrep {
sub f' f t @alike by f.a;
} aFillerPrepPrep;
lookup aFillerPrep {
sub f' [f t] @alike by f.a;
} aFillerPrep;
lookup aFiller {
sub [t f]' @alike by [t.a f.a];
} aFiller;
(The first two lookups are there to ensure that things like /f/f/t/a are replaced by /f_f_t.liga.a/a. The automatic definition of the .liga feature won’t work with /f/f/t.a/a)
for “Replace Feature” or “Replace Class” I can only replace multiple Features by using the same Parameter multiple times.
that is okay an keeps me not messing up.
but when coping three “Replace Feature” parameters to another instance, it only –for sure– copies only one parameter called “Replace Feature”.
that will not save me time I spend setting up all remove-replace-etc parameters I set up for one instance and want to scale to eight more weights/instance in my master-flile.
only option to keep all multiple custom parameters > copy&paste the whole instance, not only the parameters.
adding all “Replace Feature” in one paramenter like:
ordn; sub A by A.ordn; locl; script latn; sub @Uppercase germandbls’ @Uppercase by uni1E9E;
will not work
I’ve had Jakob’s problem, too. I had to add in the second «Replace Feature» custom parameter into every instance by hand. It would be great if one could pack several features into the same «Replace Feature» string, as Jakob suggested.