Alternate space glyph for a different script

Hello! Is it possible to have an alternate “space glyph” with a different width for a different script in the same font? In my case, baybayin is generally wider than Latin, so using the same space glyph can make it feel cramped.

What is the best implementation of this in the code? (space => space.baybayin OR space => baybayinspace)

that can be done. The proper way would be to use a script depended lookup:

script tglg;
language TGL;
lookup locl_tagalog_0 {
	sub space by space.loclTGL;
} locl_tagalog_0;

I just found that the internal language data for Baybayin/Tagalog was incomplete. I fixed it, so with the next update you only need to add the glyph “space.loclTGL” and update the features.

But the localized lookups are not always working. So you can try a context based approach. make a class that contains all Baybayin glyphs. Then the code looks like this:

sub @allBaybayin space' by space.loclTGL;
sub space' @allBaybayin by space.loclTGL;
1 Like

There aren’t standards yet for fonts of this script so I am also just figuring stuff out along the way. Thank you always for the tech support, Georg!

And if the contextual substitutions don’t work, you can try kerning:

pos @allBaybayin space' @allBaybayin 30;