-
-
Notifications
You must be signed in to change notification settings - Fork 493
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
ANCHOR_ constants treat the screen as vertically stretched #1376
Comments
At first glance looks like anchor points are relative to level, not to screen. |
That's not the case. ANCHOR_BOTTOM puts the text under the screen even when Tux is at the very bottom of the level. The position in the level has no effect, the text always shows in the same position relative to the screen. |
If the coordinate system starts in the top left, and ANCHOR_BOTTOM is selected, then naturally, it'll draw the text below the screen. Not sure if this is expected behaviour. |
I'm 100% sure this worked the way I expected it to in older versions. I came across this when some text didn't show up in one of my older levels, whereas in the older version (which, I think, was 0.4.x), the text was shown at the bottom as it should be. So something must have changed between versions, and I don't think it was on purpose. |
SuperTux version: recent git version (commit 99f72fb), but it does the same in 0.6.1.1
System information: Ubuntu 19.10 64bit
Actual behaviour:
When setting the anchor point of Text (and maybe also floating images, but I haven't tested that), the ANCHOR_ constants anchor the text in the wrong position as if the screen was stretched vertically. TOP_LEFT, TOP and TOP_RIGHT work fine, but MIDDLE_LEFT, MIDDLE and MIDDLE_RIGHT put the text in the bottom half of the screen and BOTTOM_LEFT, BOTTOM and BOTTOM_RIGHT put it under the screen completely, so it can't be seen.
Expected behaviour:
MIDDLE should anchor the text in the middle and BOTTOM should put it at the bottom of the screen, not underneath it.
Video:
https://youtu.be/zHvzNWYR2Nw
The text was updated successfully, but these errors were encountered: