The base glyph (e.g. thoThahan-thai) has a top anchor. first mark (e.g. saraIi-thai) has a _top (somewhere below the outline) anchor to attach to the top anchor of the base glyph. But, it also has a top anchor (above the outline) itself. The second mark (e.g. maiEk-thai) again has a _top anchor. So it attaches to the top anchor in the saraIi.
So the base glyph does not need to know about the second mark glyph.
because the two marks on top of each other are quite high. So one would use maiEk-thai.small instead of the maiEk-thai. The glyphs are exchanged in the ccmp feature.
nothing special, just the top anchor in the thoThahan-thai and the _top anchor in the maiEk-thai
The same as above, just move the top anchor a bit to the left:
![Thai Mark 2](upload://w0EYtWyeb52XCCsiosOqFiZUHpy.png "Thai Mark 2")
Same as thoThahan-thai
Same as poPla-thai. The maiEk-thai attaches to the saraIi-thai so you dot need to think about it.
And did you generate the features in Font Info > Features? Hit the arrow button in the lower left.
Add an glyph named loChula-thai.short. It will get a top anchor. Or, if you do not what to add it, just add a top anchor (context menu > Add anchor, change name to “top”)
and it helps if you put the top anchor in the “regular” base glyphs centered above the right stem. Then move the _top anchor in the mark glyphs to the right, too. (Select two nodes of the stem and an the anchor and hit cmd+shift+A.) That way the _top anchor in the maiEk-thai is centered, too.
And put them on the x-height line (for the regular glyphs).
I forgot to mention that you have to enable the “World Ready composer” in Indesign, too. Follow the instructions in the site I send earlier.
If that does not help, could you send me the .glyphs file and the generated .otf?
Hello @zood and @GeorgSeifert,
I followed the conversation carefully because i have almost the same problem with Thai -Glyphs and the correct placing of _top and _bottom accents on the first and second level.
All accents that Glyphs offers have been created, but somehow there seems to be no difference in choosing for instance maiEk-thai and maiEk-thai.small.
I’m not clear what the difficulty is here, but I’ll try to be clear and simple about what needs to be done.
All tone marks (both upstairs and downstairs versions) need “_top” anchors.
Above-base vowel marks need “_top” anchors, and consonants need “top” anchors, so that these vowels will sit in the right place.
Above-base vowel marks also need “top” anchors, so that any upstairs tone marks can sit in the right place.
If you’ve used the Glyphs naming convention, your upstairs tone marks will be called maiEk-thai.small, maiTho-thai.small etc. In your OpenType features panel (cmd+I>Features), you will then add a ‘calt’ feature for contextual alternates and click to auto-generate the code (or write it yourself if you like). This will tell the font to switch downstairs tone marks to upstairs versions when following an above-base vowel.
(For Thai, you will also need the ccmp feature to decompose sara Am into nikkahit and sara Aa.)
I missed to thank you for your reply @Bendy, sorry for the delay!
The “top” and "_top" anchors seem to work somehow. A year later i still have not figured out how the above-base vowel marks turn into upstairs tone marks, or second level to first level.
Another thing is that glyphs won’t let me create the ‘calt’ feature for contextual alternates. On click to auto-generate the code the feature disappears.
I created all glyphs for Thai – any accents .small (e.g. maiEk-thai.small) are existing, but not used somehow.
This problem is something most Thai-fonts don’t solve, although some System-fonts seem to manage. I am really stuck here, thanks again for your help.
I think you’re thinking of things in the same way many of the older Thai fonts did things. Nowadays we don’t ever need to switch second level to first level. Default is in the right place above the consonant (not flying away), and only when there’s a vowel like Sara I does the tone mark move upstairs.
@GeorgSeifert or @mekkablue perhaps we need to write a Thai tutorial? It seems like the process isn’t as intuitive as we’d like (I haven’t tried the auto-generate calt feature for Thai, shouldn’t it work comprehensively if the glyph names are following Glyphs’ convention? Why is the feature disappearing when clicking auto-generate?)
I’m not sure why you’re lowering it in that example. After Mai Hanakat, any tone mark should be the upstairs version, and if the anchors are in the correct places the marks will not crash.
Here’s an example. Default Mai Ek is shown on Ko Kai and Po Pla. Anchors can be repositioned if you’d prefer to have the Mai Ek above the stem of Po Pla. Adding in a topvowel makes Mai Ek switch to the upstairs (calt) version. Again, anchors can be repositioned to put the marks exactly where you want them, but there should be no need to switch an upstairs glyph for a default one.
In my example above maiEk-thai is somehow used on both glyphs. There seems no choice to either lower it on one and lift it up on the other glyph, like the anchors offer as an individual positioning.
In your screenshot that works exactly how i wanted it, but i cannot find the mistake in my setup. This might be connected to the missing calt feature, but the glyphs preview doesn’t look right in the first place.