RetroBASIC
Retrogamecoding(.org) => EGSL => Topic started by: Ed Davis on March 27, 2014, 01:10:03 PM
-
1) I want to write some text to a Window. I'd like to know how much I can fit, so I was thinking I would use fontheight to determine the height of the font. But fontheight requires a fontnumber. After opening a window, how do I determine the fontnumber?
2) Is there a way to create a user-resizable window in EGSL?
Thanks!
-
1. First you have to load a font (bitmap font) like this:
myfont = loadbmpfont (filename, lines, rows, fontface)
The variable myfont holds the fontnumber. So you can access it by using e.g.
fheight=fontheight (myfont)
If you are using a monofont, use monoheight instead.
2. Nope that's not possible. Of course you can make a menu or something where one can choose the size, then use
resizewindow (x,y)