• Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

Question - IDE Text Kerning - "GMKerning" data found in font.yy files?

Gleeson

Member
sublime_text_onpWIUElYW.png
(image above is a snippet from the font Quicksand when imported into GMS2 - this is in the .yy file)

Hey there - this is probably a very technical question that's probably appropriate for someone at YoYo, but happy to have a discussion about it and spark some interest.

So, in going down a rabbit hole trying to improve how I can render text in GameMaker Studio 2 (using 2.2.5.481), I discovered something in the font.yy files - there actually seems to be kerning pair data stored here!
But as far as I can tell, GameMaker does not attempt to do any kerning when rendering text - this is actually the issue I'm trying to solve. Either way, this is very curious!

While this does open up the potential for users to parse this JSON data themselves and make custom scripts to include kerning - but, why are these values rounded numbers? That doesn't seem right to me, as kerning values are typically fairly precise values - I can only conclude that this is an optimisation for a 'good-enough' result, maybe?

Is this a planned or intended feature? Or is this data just available for those (like me) who are interested in kerning to implement it themselves?

I can't really find a lot of information about this, and it doesn't seem like many people have looked into it either. I'm curious to hear from anyone who's tackled or attempted this problem!
 
Yea, unfortunately adjustable kerning isn't built into GMs text drawing capabilities, but it is possible in a sense. The solution, non-solution, is to draw each letter one at a time with some additional padding between each character.


Regarding the kerning data in the yy file, no clue what that data would be used for.
 
Top