On Wed, Mar 12, 2003 at 09:30:05PM +0000, Tom Payne wrote:
> to the authors). I would much rather see Ion written either in C++ or C with
> the glib/gtk object system. 

gobject... *puke*. That is the most awful object kludge I have ever come
across. It's too complicated, overdesigned and bloated monstrosity for a
non-OO language. The KISS principle works here. C is a  nice language as
long as you keep things simple. All the g* libraries have gone way beyond
that line a long time ago and Ion isn't too far either. Unfortunately
there aren't too many alternatives to C if you don't want to give up
lots of libraries and the speed of natively compiled programs.

The Ion OO stuff may be an ugly hack, but there really isn't much to it.
There are many macros yes, but I'd use macros with any OO system for
duplicated code that isn't really implementable as a function and to
increase legibility (e.g. FOR_ALL_*). Once you try to do things too
cleanly, things may become bloated and actually difficult to use. 
A small amount of quick and dirty hack attitude is always for good.

The class hierarchy? Really easy to find out be reading the first
line inside the structures defining classes.

WObj
 -> WThing (this might be unified with WObj or WRegion one day)
     -> WRegion
         -> WWindow (anything with a InputOutput X window except client
                     windows)
             -> WScreen
             -> WGenFrame
                 -> WIonFrame (ionws.so)
                 -> WFloatFrame (floatws.so)
             -> WInput (query.so)
                 -> WEdln (query.so)
                 -> WMessage (query.so)
         -> WClientWin
         -> WGenWS
             -> WFloatWS (floatws.so)
             -> WIonWS (ionws.so)
         -> WViewport
 -> WWsSplit (ionws.so)


> My ideal Ion would:
> * use gtk for as much as possible (modules, drawing, etc.)

If I had to use some toolkit, I'd probably choose Qt despite being C++.
At least it can be used by humans. Or could; I haven't given it a look
for years. Fortunately I don't have to choose. And what's the point in
using a WIMP-toolkit with an anti-WIMP-is-the-only-way-and-everyone-should-
conform-to-it WM anyway? In my opinion all programs should be written in
as presentation-agnostic way as possible.

> * use lua for configuration (mmm, scripting)

If someone makes the conversion, I'll be happy to do so. I don't have
plans of implementing this myself anytime soon. 

-- 
Tuomo

Reply via email to