Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scribble not drawing text in same location as Game Maker's native text drawing in 8.7.1 #536

Closed
SpookySquidGames opened this issue Jun 5, 2024 · 9 comments
Labels
bug 😅 Juju did a bad thing
Milestone

Comments

@SpookySquidGames
Copy link

Noticed that Scribble is drawing text two pixels lower than the native Game Maker text render. That doesn't seem to be the intended behavior from what I read in the documentation? This example image is 8.7.1 running in GM LTS.

scribble-not-drawing-in-same-place-as-native-text-rendering

@JujuAdams
Copy link
Owner

Will need to take a look at a project to determine the cause here.

It is unlikely that this can be fixed for 8.7.x because this would be a breaking change for people who are reliant on a (potentially incorrect) vertical offset. However, I can suggest a workaround if this turns out to be a Scribble bug.

@SpookySquidGames
Copy link
Author

Decided to run some tests using other fonts on a hunch and this only seems to effect Silver. Still weird that Scribble and native GM are handling it differently, but at least it seems to not be a larger issue that affects all fonts. Let me know if you'd still like a test project to figure out what's going on here. Thanks!

Going to test the kerning function bug I reported on other fonts as well in case that's also Silver specific.

@JujuAdams
Copy link
Owner

I thhhink I know what this is (ascender offset) but I'd need to see it in situ to be sure.

@SpookySquidGames
Copy link
Author

Ok! I'll put together a little test project and post it here as soon as I have chance. Thanks!

@JujuAdams
Copy link
Owner

Thank you kindly.

@JujuAdams JujuAdams added bug 😅 Juju did a bad thing and removed help me! 😨 Argh labels Jun 7, 2024
@SpookySquidGames
Copy link
Author

Ok example file attached!
silver and scribble test.zip

While making this I found an "interesting" GameMaker quirk. Silver's vertical alignment in native GameMaker text rendering changes depending on what characters you've included in the range. After having a random assortment of Japanese and Korean characters added to the range it started rendering text one pixel lower than before (at least when vertical alignment is set to the top). Extra weird. Removing those characters after doesn't fix it, even making a completely new font from Silver without those characters didn't fix it. It somehow permanently changes the position for the font across all versions. Since I could not find a way to undo this change I wasn't able to test if adding those characters had the same effect in Scribble or on other vertical alignments for native text rendering. Fun!

@JujuAdams
Copy link
Owner

Thank you for the example project. I will take a look soon.

@JujuAdams
Copy link
Owner

Was indeed the ascender offset: 2c464fc

This will not go into v8.7.x but I will put out a v8.8 today with this fix.

@JujuAdams JujuAdams added this to the 8.8 milestone Jun 8, 2024
@JujuAdams
Copy link
Owner

Fix available in 8.8.0: https://github.com/JujuAdams/Scribble/releases/tag/8.8.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 😅 Juju did a bad thing
Projects
None yet
Development

No branches or pull requests

2 participants