Hello Forum. I just started learning Glyphs not long ago specifically for my thesis, which I am currently designing Latin type and Thai script. However, I have a problem combining Thai marks. Thai alphabets consist of 44 letters which ALL of them can be combined with all of the marks (vowels and tones), and also able to stacked themselves on top of each other.
I have read Glyphs Handbook and also many articles about setting ‘anchors’ and ‘mark to mark/mark to base positioning’ but I still don’t quite get it because I don’t usually do encoding or writing any script and feel more comfortable with designing new letters instead.
Then, each mark will need anchors. Each anchor with an underscore will match up with the corresponding non-underscore anchor on a consonant. So here we have _topright which tells Glyphs to position the saraIi by looking at the topright anchor on a consonant:
I think I start to understand the logic behind mark positioning now, and these two options are quite helpful in their own way. I ended up using both of them consequently actually.
I still have more questions regarding of marks though. Is it possible to adjust marks position for each individual glyphs? As you can see in this picture below, the stem of vowel saraUu is not in the same position as consonant khoKhai;
You can either move the bottomcenter anchor on khoKhai, or use bottomright anchors instead of bottomcenter anchors. I use bottomright (eg in my screenshots above) so that all marks align to the right hand stems of consonants.
However, if I want to have mark saraU(ุ) align on the center between two stems of khoKhai, I basically have to create another anchor that says ‘bottomcenter’ on khoKhai and ‘_bottomcenter’ on mark saraU. Is that correct?
If you want to have different marks aligning in different ways, you can use whatever anchor names you like. You could have a _saraU anchor on saraU and a saraU anchor on each consonant to allow you to control precisely where just that specific mark sits in relation to the base. The anchor strategy is up to you, depending on what results you want.
I have spent two days trying to find a strategy of my own (that fits the style of my font in this case) and finally, successfully mark-to-mark every Thai characters with Thai marks, however, once I export it and test it on InDesign and other variable font preview website, the marks are still not marked to their places.
That’s great that you’ve figured out all the anchors to give the results you want!
First thing to check would be your settings in InDesign: the option you need is the ‘South Asian’ composer, I believe. (On older versions of InDesign, it’s the World-Ready Composer). If other Thai fonts are working correctly in InDesign, it’s a bug in your font…
Check you have the correct Unicode ranges set for Thai in Glyphs’ Font Info, and that you have a languagesystem declaration DFLT thai.
I can’t tell from your screenshot if you’re trying to substitute a small maiTho when it’s in the upstairs position, but maybe there’s a bug in your OpenType code. Do you have OT features being generated automatically?
Fist of all, I exported this font as Variable Fonts. Does it has something to do with that? I’m actually using Adobe InDesign 2020, however, there’s only button that says World-Ready. Do I also need to change the setting in Preference?
In my earlier screenshot I try to mark maiTho in upstair position of saraI on top of koKai. And to be honest, right now I am quite lost when you mention ‘language system declaration DFLT Thai’. And what do you mean by ‘OT features being generated automatically’?
I am so sorry I’m asking so many questions right now as I am so, totally lost…
Looks like yes, the World-ready composer is what you need here. I can’t see any relevant options in the preferences.
The maiTho-thai.small is the upstairs version, so if you haven’t drawn it yet, the font only has the default (downstairs) version, which may be what we’re seeing in InDesign where it’s overlapping. I don’t know what anchors you have on the saraIi-thai, but if it’s missing a “top” anchor then we’d expect to see the maiTho just sitting on top like this. Sara Ii (and the others) need both “_top” to attach to bases and “top” to position upstairs marks onto.
[The maiTho-thai.narrow is in case you want to add a compressed version for poPla, foFa and foFan, so the marks don’t stretch too far out to the left on those base consonants.]
In your features, you’ll need a languagesystem prefix so that the font can tell apps what scripts it contains:
The OpenType features for Thai include the glyph substitions (using the upstairs tonemarks when there’s an abovevowel, using the .less versions of yoYing and thoThan when there’s a vowel below) and mark positioning. Mark positioning is generated automatically, but the substitutions can be handled by Glyphs, if you add a feature [contextual alternates] and set it to ‘generate feature automatically’.
Thank you so much for your help until this point. Yes, my InDesign also support Variable Fonts, however, I think I need to show you my mark-to-mark process so that we can tackle on the real problem I have now and to prevent problems that could occur (again) in future:
In order for me to adjust marks on each Thai consonants later individually (without interfering one another), I decided to set anchors (for every mark ) on every Thai consonants individually as you can see in this picture;
But once I export and test it in InDesign, only some marks (maiEk, maiTho, maiTri, maiChattawa, and thanthakhat) don’t appear on top of consonants. However, some marks (maiHanaKat, maitakhu, saraI, saraIi, saraUe, saraUee, and nikhahit) do;
One quite important thing.
In the base glyph, put the anchor to the edge of the glyph. And in the mark, give it the space you need. That way you can define the distance for each mark in the mark itself.
I’m not sure if you’re showing actual screenshots from Glyphs, if you want more than one anchor in the same position, AFAIK you can’t use one anchor two names separated by a comma, you need two separate anchors.
Why is there an anchor above the maiTho? AFAIK there’s never anything that can sit above maiTho, even in minority languages.
That’s odd. Are there any error messages when you export? Check the glyph properties for your tonemarks (Cmd-alt-i in the main tab). The default (non-small, non-narrow) versions should have Unicode values, and should be defined as nonspacing marks. Make sure they’re set as exporting glyphs.
I forgot to mention that I screenshot it and wrote the text over. So in that example, there’s more anchors in the same position.
It is true that there’s nothing can sit on top of tonal marks in Thai because it totally doesn’t make any sense or mean anything, however, I would love to test it out and see how it could look like in reality. It’s a part of my thesis topic in a way.
There’s no error messages once I export at all… And yes, all default version marks have their Unicode values, BUT all boxes are empty, so I ticked them like this. However, the outcome is still the same…