fonts and text

BlitzMax Forums/BlitzMax Beginners Area/fonts and text

Gillissie(Posted 2008) [#1]
Ok, I must be crazy, but I'm having trouble with basic text stuff.

The docs on this site talk about commands LoadImageFont and SetImageFont (they use a type named TImageFont). However, when I try to use those commands, the compiler says it doesn't exist.

However, I have found that LoadFont and SetFont seem to work (as in BlitzBasic), but those commands are not documented in BlitzMax.

Also, if I try to use one of the style flag constants, the compiler says that the identifier is not found (I'm using superstrict mode), although I know it exists in BRL.Font.BOLDFONT etc.


Gillissie(Posted 2008) [#2]
hmmm. It seems that it has to do with using the leadwerks.engine framework. When I make a basic program, the ImageFont commands work (although I'm not sure what to put in for the URL argument of LoadImageFont).

I guess nevermind then.


dmaz(Posted 2008) [#3]
Framework - from the docs
"Framework builds the BlitzMax application with only the Module specified rather than all modules installed."

starts you with only the mod specified as a base. you then have to import anything else you need. so for LoadImageFont you would do
Import BRL.Max2D

you can figure out what you need to import by going to the help (press "F1" twice when text cursor is on the word) and looking at the very top of the page.