The Accidental Rubyist

invalid byte sequence in UTF-8

Horizontal scrolling in single line edit

leave a comment »

Class Field


Finally got around to doing this. If maxlen > display_length, then the field scrolls horizontally during edit, cursor_back and cursor_forward, and cursor_home (C-a) and cursor_end (C-e).


# Sum some numbers
   (5..10).inject {|sum, n| sum + n }              #=> 45


http://apidock.com/ruby/Enumerable/inject

Advertisements

Written by totalrecall

December 19, 2008 at 9:36 pm

Posted in rbcurse

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: