So I have a simple app that is a console IRC client. It uses sockets to
connect to the specified server, interprets commands entered by the user
(via STDIN), and writes data received from the socket to STDOUT.
Now I want to use this class (after whatever mods are needed) with a
ruby-gtk GUI. I’ve used Glade3 to layout the basic UI and used
ruby-glade-create-template to generate some initial code. I am able to
the on_connect_clicked method to create a new IRC object which
connects and I can see the output to the console… but now what? I’m
loss for how one goes about having the output go to a Gtk TextBuffer
than “putsing” it to STDOUT. I think I could use globals and get it to
work, but I’m not sure… and I think that may be a bad idea.
Any advice or pointers would be appreciated.