On Sat, 2007-09-29 at 02:00 +0400, Tirra is a Cat wrote: > Hello, > > > On Fri, 28 Sep 2007 10:32:47 -0400 > "Unix OS" <[EMAIL PROTECTED]> wrote: > > Hello, > > I'm an undergraduate student at James Madison University. I've > decided to convert one of my CS classes to an Honors class, which > involves doing some sort of extra project typically. Anyway, I've > been working with my professor, and he wants to try porting his text > editor to a windowed application that can run on Windows. I figured > GTK would be a great place to start. > > Enough back story. > > What's involved in converting a terminal application like a text > editor into a windowed application? Will I need to simply need to > write a custom widget to wrap the terminal application's output? Then > redirect keyboard and mouse events to the original code? Or is it > more involved than that?
Use a vte widget. That's the widget used in gnome-terminal. > I know Vim can be compiled to run as a GTK app. I figure the original > terminal-only code must have been reused. > > > Thanks, > Kris Kalish > > -= > So, it's depends on your code, but generally you will need to rewrite all the > functions that works with CLI (I mean the terminal I/O) to the GUI (event > driven) - it's a long process. If your editor logic separated from the term > I/O - it will be the good start point for remaking console editor to the GUI. > > Have a nice day. > > -- behdad http://behdad.org/ "Those who would give up Essential Liberty to purchase a little Temporary Safety, deserve neither Liberty nor Safety." -- Benjamin Franklin, 1759 _______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list