Pat's Log
Mon, 27 Dec 2004

Beyond a Mock-up
xbox/20041226 The previously-designed mock-up is now a reality. Written in GTK, with code borrowed from gnome-swallow, the xeyes program was swallowed into this preliminary design. The program is actually attached to the tab pages, so when a tab is switched, the eyes are hidden. They return when the first tab is once again focused.

There are still many things to work out. The immediate concern is whether it is possible to have multiple applications swallowed. There is no reason why this should not be possible, but the current code does interesting synchronization magic by forking the swallowed program off and then attempting to control the main program loop. This, obviously, cannot work with more than one program at a time. At the same time, with a small number of programs swallowed, perhaps it is not a significant performanceissue to overcome.

The step after that is to be able to dynamically specify which programs belong to which tabs, rather than hard-coding. Related to this is the ability to set the swallowed applet's size. Currently, the eyes are scaled to fit the tab content area via command-line argument to xeyes. This solution is not practical when there is a configuration file, as the size of the tabs is not known in advance. Since the window identifier of the swallowed program is known, it would be cleaner to suggest to the program to resize to given dimensions via an Xlib call after the program is started, much like a window manager would.

Overall, this design is working out fairly well.


[/xbox] | posted @ 06:44 | link

copyright ©2004-2016 pat suwalski