Page 1 of 1

Approach to native Rubygame text handling - discuss

PostPosted: Mon Apr 05, 2010 1:39 pm
by cgmjr
I'd like to elicit ideas and opinions about handling basic text input/output natively with Rubygame. My needs don't rise to the level of using wxRuby or the like, and I like the idea of keeping everything simple.

What do y'all think? Does Rubygame::Rect together with some simple character buffers as Arrays give us most of what we need? Or perhaps Rubygame::Sprite with the @image as a Rubygame::TTF#render the ticket?

I betcha y'all have some clever ideas you've devised or run into.

Re: Approach to native Rubygame text handling - discuss

PostPosted: Tue Apr 06, 2010 5:34 pm
by shawn42
Feel free to steal, er borrow code from rubygoo. It has a text field widget.

http://github.com/shawn42/rubygoo
http://github.com/shawn42/rubygoo/blob/ ... t_field.rb

old site w/ screenshots:
http://code.google.com/p/rubygoo/

Re: Approach to native Rubygame text handling - discuss

PostPosted: Tue Apr 06, 2010 5:36 pm
by kiba
The way I handled text handling is buried deep in the bowel of RubyTet.

You want to take a look at text_manager.rb and text_render.rb