Page 1 of 1

how to use bitmap fonts?

Posted: Wed May 21, 2008 05:54
by pyhmail
I want use bitmap fonts,my mothed is :
1) create a font file MyFont.font, the content in the file is:
<?xml version="1.0" ?>
<Font Name="MyFont" Filename="TaharezLook.imageset" Type="Static" NativeHorzRes="800" NativeVertRes="600" AutoScaled="true">
<Mapping Codepoint="65" Image="ClientBrush" />
</Font>

2) create the bitmap font:
CEGUI::FontManager::getSingleton().createFont("MyFont.font");

when I run it ,there is a message for error:
FontManager::createFont - The value for the Font:Type attribute 'Static' is unknown.
how to fix it ?

Posted: Wed May 21, 2008 07:15
by scriptkid
Mmmm "Static" should work according to the .xsd file. I don't have a running Cegui installation at hands right now, so i can't test anything..

Apparently, dynamic fonts (which use 'Dynamic') do work on your setup?

Posted: Wed May 21, 2008 07:39
by pyhmail
thank scriptkid!

Posted: Wed May 21, 2008 08:52
by CrazyEddie
Depending on the version you have those type names were changed.

"Static" became "Pixmap"
"Dynamic" became "FreeType"

Don't ask why this change came about :lol:

CE.