custom screenfont used from 'print' instead of default one

General FreeBASIC programming questions.
Post Reply
nitrofurano
Posts: 57
Joined: Dec 08, 2010 14:55
Location: Portugal
Contact:

custom screenfont used from 'print' instead of default one

Post by nitrofurano »

how can we create and use our custom tyefaces, screenfonts from 'print' command, instead of that default one? is that some kind of binary bitmap area allocation, or we should copy parts from a secondary screen with a screenfont sheet, get/put, drawing pixel by pixel, etc.?
counting_pine
Site Admin
Posts: 6323
Joined: Jul 05, 2005 17:32
Location: Manchester, Lancs

Re: custom screenfont used from 'print' instead of default o

Post by counting_pine »

The Draw String statement accepts custom fonts, though they are a slightly complicated to use. Have a good read though the www.freebasic.net/wiki/KeyPgDrawString, especially the second example program which shows you an example.
Essentially all the characters of the font are kept in an image buffer, stored one after the other, with the bytes of the top line of the image used for storing the width of each character.
nitrofurano
Posts: 57
Joined: Dec 08, 2010 14:55
Location: Portugal
Contact:

Re: custom screenfont used from 'print' instead of default o

Post by nitrofurano »

thanks! :)
Post Reply