05-25-2023, 05:24 AM
The result of running the small snippet of code below confuses me! I would expect Locate to use the first two arguments to set the column and row for text position,
but it uses the first for the vertical row position, and the second, not as the column but as a number to be determined from the font size.
I know, I'm easily confused, but can someone explain this to me?
but it uses the first for the vertical row position, and the second, not as the column but as a number to be determined from the font size.
I know, I'm easily confused, but can someone explain this to me?
PHP Code:
Screen _NewImage(1280, 960, 32)
f& = _LoadFont("c:\WINDOWS\Fonts\arial.ttf", 28)
_Font f&
'
Locate 31, 400
' I would expect this to be an invalid horizontal position
Print "This text location is row 31, column 400";
' but it uses the pixel position, and prints it there!
Sleep
Of all the places on Earth, and all the planets in the Universe, I'd rather live here (Perth, W.A.)