Attract-Mode Support Forum
Attract-Mode Support => Scripting => Topic started by: Oomek on March 12, 2017, 07:51:49 AM
-
Is there any way to make text alignment in AM more coder friendly?
Setting Align.Left does not make the text to be aligned to the left. The y offset is wrong too. What's even worse the gap changes depending on the font type used, so it's practicaly impossible in AM to make a neat theme which scales to various resolutions. I need to compensate the gap and vertical alignment manually in pixels which destroys scalability.
(https://s3.postimg.org/5paot5kjn/attract_2017_03_12_14_38_06_515.png)
-
https://github.com/mickelson/attract/wiki/Scripting-Tips-and-Tricks
hope something there can be help
-
I'm aware of that wiki page. Unfortunately it doesn't explain how to overcome the misalignment of text in relation to the text box
-
Well, after few failed attempts to overcome the issue I 've decided to fork AM and fix it myself.
(https://s12.postimg.org/iut16oofx/attract_2017_03_17_13_51_44_572.png)
https://www.youtube.com/watch?v=ULSgTj53ke4 (https://www.youtube.com/watch?v=ULSgTj53ke4)
https://github.com/mickelson/attract/pull/331/files (https://github.com/mickelson/attract/pull/331/files)
It's up to mickelson now if he wants to include it in his build.
-
just wanted to say thanks...looks like you really know what your doing.
good work . going to read up.....on it and use..
-
This is soooo awesome. It was always trial-and-error approach with text alignment. Like tweak-reload-tweak-reload-and so on. It's doable - but you have always make correction for text placement.
It will surely help with precise text positioning.
-
Now we just have to convince raygun to accept my pull request on github.
-
Is he against it? Or you didn't ask yet?
-
He probably didn't see it yet. He's not active recently on either AM forum or GitHub
-
Example of improvements in small thin font rendering.
As you can see only character size:20 is rendered properly.
On the left AM Baseline, on the right my build.
Make sure your browser has zoom set at 100% and your windows dpi settings are at 100% as well.
Otherwise all fonts will appear as interpolated.
(https://s13.postimg.org/5copgcf1z/fe_Text_fix.png)