I am developing an event based set of ncurses widgets, as part of my Summer-of-Code project (sponsored by Google) -- which is to create a curses-based frontend for Gaim. I am calling this set of widgets 'Gaim Ncurses Toolkit', or GNT for short. And the frontend is called gntgaim. I have also created a proof-of-concept client for xmms2 -- which I plan on developing farther once I have a little more time. The toolkit has been designed to make it easy to port especially GTK+ applications for the console. There are some sample codes and screenshots at:
Anyone intesrested to test this toolkit can follow these instructions to build the system:
There are some shortcut keys that you are going to need:
Alt+n: go to next window Alt+p: go to previous window Alt+m: start moving a window
cursor keys to move the window
enter/escape to stop moving the window
Alt+r: start resizing a window
cursor keys to resize the window
enter/escape to stop resizing the window Alt+w: show the list of windows escape to make it disappear enter to bring forward the selected window in the list Alt+d: dump the contents of the screen in "
dump.html" in `pwd`
(not all windows can be resized) Now, not all terminals give out the same codes for these keystrokes. So the shortcut keys will probably not work for some/many terminals. But they do work in mrxvt, urxvt, linux. I do wish to make them work in all/most terminals, and will try doing that once I understand a little more on how things work.
If you don't like the default colors, not to worry. Most of the shadow/colors can be configured from ~/.gntrc
Now, the problem I have been facing is: the screen often gets scrambled in some occasions, usually when the terminal size is large, or when I am moving a large window. (
http://www.site.uottawa.ca/~schow031/gnt/scrambled.png). However, if I get a screendump (by pressing Alt+d, which winch()es from newscr), the html looks fine (
http://www.site.uottawa.ca/~schow031/gnt/scrambled.html). This very likely means there's some memory corruption somewhere. But disturbingly, this problem goes away if I run from within valgrind. So I can't exactly find out where the corruption is happening. Can anyone suggest where I can take a look to fix this?
Thanks for your time (it's a rather long post :) ). Cheers, Sadrul