Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Locate command on the ttf graphical screens
#6
As I mentioned, it all steps back to this:

Code: (Select All)
Screen 12
$Color:0
f = _LoadFont("courbd.ttf", 16)
g = _LoadFont("courbd.ttf", 16, "MONOSPACE")

_Font f
Print _FontWidth, _FontHeight, "notice the fontwidth with variable width?"
_Font g
Locate 2: Print _FontWidth, _FontHeight; " vs monospaced"

Variable width fonts have no set fontwidth, so you can't just move character width left/right, so it moves by pixels instead.
Reply


Messages In This Thread
RE: Locate command on the ttf graphical screens - by SMcNeill - 03-09-2025, 05:47 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Command$(count%) - I can't get a value when using the optional argument "(count%)" Unatic 3 530 08-22-2025, 11:58 AM
Last Post: Unatic
  keyword to get the EXE name and the EXE path instead of parsing Command$(0) ? madscijr 8 1,159 07-22-2025, 08:35 PM
Last Post: hsiangch_ong
  Using _MapTriangle in Small Virtual Screens NakedApe 7 870 07-05-2025, 11:54 AM
Last Post: SMcNeill
  Command$ issues eoredson 8 1,409 05-02-2025, 01:42 AM
Last Post: eoredson
  open multiple screens at once drewdavis 2 794 09-09-2024, 08:08 AM
Last Post: Pete

Forum Jump:


Users browsing this thread: 1 Guest(s)