Not logged inGosu Forums
Forum back to libgosu.org Help Search Register Login
Up Topic Gosu / Gosu News / Gosu 0.7.37 released
- - By jlnr (dev) Date 2011-09-12 04:46
I have pushed this update sooner rather than later because some people had trouble running 0.7.36 on Linux. It also includes two new features though.

• Linux: Using X11 Expose event instead of crashy XDamage event (thanks Jamer)
• All: Added Gosu::language() that retrieves the user's current language
• All: Added Font::setImage/Font#[]=(char, image) to set up a custom image for a character

Gosu::language is useful for localization systems. Just do a case-insensitive comparison on the first two letters of it and be prepared to have a fallback. In Ruby, you can use this to set up e.g. the r18n gem.

my_font['a'] = some_image - this allows developers to load custom bitmap fonts, while automatically having a fallback to normal Font functionality. Let me know if this does the trick for you in practice. I wanted to load my old bitmap font, but I lost the file. :(
Reply
Parent - By Trebor777 Date 2011-09-12 09:40
yeeees ! Love you Jlnr for the font thingie!!
Let's have some pretty effects on screen!!

Nice one for the language :P would probably help me avoid the "select language" screen on my project!
I'll have to try it out!
Reply
Parent - By TheOm3ga Date 2011-09-12 23:59
About Gosu::language, if anyone is interested, some months ago I wrote a tutorial about internationalization of projects using Gettext, which is the most common way of translating projects. You can find it here: http://rodin.uca.es:8081/xmlui/bitstream/handle/10498/10772/gettext.pdf?sequence=1 (however, it's in spanish).
Reply
Up Topic Gosu / Gosu News / Gosu 0.7.37 released

Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill