Wintermute Engine Forum

Wintermute Engine => Technical forum => Topic started by: Prote1n on April 05, 2010, 08:56:51 AM

Title: Query about font TTF ?
Post by: Prote1n on April 05, 2010, 08:56:51 AM
Is there any way to create a "selected" font while using a TTF file format. I'd like the standard white letters over black screen

This works well with a Bitmap font but I do not succeed to create a black background in the TTF definition file

Could anybody help me ?
 
Title: Re: Query about font TTF ?
Post by: metamorphium on April 07, 2010, 09:51:26 AM
You can't use the font by itself, it's always part of STATIC, WINDOW or similar entities. So I'd suggest for example creating static with the background in question and the font assigned and by calling SizeToFit adjust the background only for the font width.

Title: Re: Query about font TTF ?
Post by: Prote1n on April 07, 2010, 11:30:11 AM
My Goal is to use a TTF in a editor control ... and it's not possible to get the SelStart and SelEnd in real time ....
Title: Re: Query about font TTF ?
Post by: Mnemonic on April 07, 2010, 12:13:58 PM
You can't achieve a solid background for TrueType fonts. You'll have to use a different letter color for selected text.