How can i add a new font to CEGUI Editor.?

For help with anything that CEGUI doesn't offer straight out-of-the-box, e.g.:
- Implementation of new features, such as new Core classes, widgets, WindowRenderers, etc. ...
- Modification of any existing features for specific purposes
- Integration of CEGUI in new engines or frameworks and writing of new plugins (Renderer, Parser, ...) or modules

Moderators: CEGUI MVP, CEGUI Team

Ahmadi
Just popping in
Just popping in
Posts: 9
Joined: Sun Aug 06, 2006 22:11

How can i add a new font to CEGUI Editor.?

Postby Ahmadi » Sun Aug 06, 2006 22:21

Hi
i want add new font to CEGUI Editor. its not a english font. but if i know how can i add a new english font to CEGUI Editor, then i can add my font.

Pre Thanks for any help
Ahmadi

User avatar
tgraupmann
Quite a regular
Quite a regular
Posts: 78
Joined: Thu Aug 18, 2005 00:47
Contact:

Postby tgraupmann » Mon Aug 07, 2006 00:08

Localization sounds good. Is it easy to add a new font? How would you go about doing it?

User avatar
scriptkid
Home away from home
Home away from home
Posts: 1178
Joined: Wed Jan 12, 2005 12:06
Location: The Hague, The Netherlands
Contact:

Postby scriptkid » Mon Aug 07, 2006 07:38

Hi,

adding an new font is possible indeed. You can save your new font definition (xml) into the directory which contains your fonts. Then is becomes available to set as a window's font, or even as a default font through the "View->Set default font" menu item. (After restarting the editor).

Make sure that you specify the glyph information inside the definition file for non-English characters.

Good luck!

Ahmadi
Just popping in
Just popping in
Posts: 9
Joined: Sun Aug 06, 2006 22:11

Postby Ahmadi » Mon Aug 07, 2006 10:52

scriptkid wrote:Hi,

adding an new font is possible indeed. You can save your new font definition (xml) into the directory which contains your fonts. Then is becomes available to set as a window's font, or even as a default font through the "View->Set default font" menu item. (After restarting the editor).

Make sure that you specify the glyph information inside the definition file for non-English characters.

Good luck!

Ok, now i have my font in editor, but editor only use 0..127 character of my font, and i can not use 128..255 character in editor.
my font have 0..255 character that i only can use first half of it in editor.

Ahmadi
Just popping in
Just popping in
Posts: 9
Joined: Sun Aug 06, 2006 22:11

No setting founded for character limitation.

Postby Ahmadi » Mon Aug 07, 2006 12:29

Also i can not find any font setting that can i change character limitation with it . :cry: :cry:

Maybe limitation is in CELayoutEditor.exe?

User avatar
tgraupmann
Quite a regular
Quite a regular
Posts: 78
Joined: Thu Aug 18, 2005 00:47
Contact:

Postby tgraupmann » Mon Aug 07, 2006 14:34

scriptkid wrote:Hi,

adding an new font is possible indeed. You can save your new font definition (xml) into the directory which contains your fonts. Then is becomes available to set as a window's font, or even as a default font through the "View->Set default font" menu item. (After restarting the editor).

Make sure that you specify the glyph information inside the definition file for non-English characters.

Good luck!


Where do you get a font definition xml file from? And the glyphs. What if you just have a TTF file?

User avatar
scriptkid
Home away from home
Home away from home
Posts: 1178
Joined: Wed Jan 12, 2005 12:06
Location: The Hague, The Netherlands
Contact:

Postby scriptkid » Tue Aug 08, 2006 12:20

Hi,

font definition files are the ones you find in "datafiles/fonts". You need to define a font in such a file to be able to create them non-hardcoded.

About the font settings: please search the forum for "glyphset". This results in topics about "glypsets", "glyphranges", ASCII vs. Utf8* and so on. I'm not a font / unicode guru myself, so i hope this helps.

Good luck both of you!

User avatar
tgraupmann
Quite a regular
Quite a regular
Posts: 78
Joined: Thu Aug 18, 2005 00:47
Contact:

Postby tgraupmann » Fri Aug 11, 2006 03:57

Here's a nice utility that might be useful:
http://www.cegui.org.uk/phpBB2/viewtopic.php?t=1538

User avatar
tgraupmann
Quite a regular
Quite a regular
Posts: 78
Joined: Thu Aug 18, 2005 00:47
Contact:

Postby tgraupmann » Fri Aug 11, 2006 03:58


User avatar
arkos
Quite a regular
Quite a regular
Posts: 49
Joined: Thu Apr 27, 2006 21:45

Postby arkos » Tue Sep 12, 2006 15:39

hey, this is just a shot in the dark, but I was thinking that if the layout editor can't read more than 127 of your font, maybe you should try using the getWindow()->setText("you message here"); from within code. Maybe this will work.

Hope this helps.


Return to “Modifications / Integrations / Customisations”

Who is online

Users browsing this forum: No registered users and 5 guests