LWN.net Logo

Sobotka: Why GIMP is inadequate

Sobotka: Why GIMP is inadequate

Posted Jan 12, 2011 15:36 UTC (Wed) by Trelane (subscriber, #56877)
In reply to: Sobotka: Why GIMP is inadequate by romanfi
Parent article: Sobotka: Why GIMP is inadequate

>That's not as good as Qt.

In what (concrete) way?

>It really doesn't make much sense to build a GUI toolkit on top of C

because....?

>a GUI toolkit is crying for object oriented designs

Yes, and that's why it's object-based (GObject is the root object).


(Log in to post comments)

Sobotka: Why GIMP is inadequate

Posted Jan 13, 2011 5:54 UTC (Thu) by romanfi (guest, #72329) [Link]

Trelane wrote:

> In what (concrete) way?

- compatibility between platforms

- documentation

- structure of GUI components

- stability

- the designer IDE (here I'm not 100% sure)

- L&F

> because....?

A GUI is composed of elements that in some natural way inherit from each other. E.g. there are push buttons, radio buttons, which are all buttons. And buttons and many other elements are widgets. The main windows, dialogs and so on are frames or windows.

Motif already had an object oriented design, implemented using standard C. They even had public and private data members, faked using two header files defining two structures for every element, one of them for Motif itself, including the private members, the other one with just the public part, layout compatible. They've got virtual functions, implemented with function pointer arrays, and so on. And I can see the same thing in GTK.

So why not using the right tool for the job?

Sobotka: Why GIMP is inadequate

Posted Jan 13, 2011 20:09 UTC (Thu) by daniel (subscriber, #3181) [Link]

You omitted the biggest issue: casts. C makes you do this, the result is a nasty abomination. Been there.

Sobotka: Why GIMP is inadequate

Posted Jan 13, 2011 20:55 UTC (Thu) by Trelane (subscriber, #56877) [Link]

Perhaps you mean C-style casts? You still have to cast in C++, but it looks different and often does it implicitly (which can be a bad thing, see also passing a Manager to a function accepting an Employee instead of reference to Employee, as discussed in Stroustrup).

Sobotka: Why GIMP is inadequate

Posted Jan 18, 2011 17:56 UTC (Tue) by daniel (subscriber, #3181) [Link]

"Perhaps you mean C-style casts?"

I meant pointer casts that attempt to simulate a C++ class hierarchy using C structs with casts.

Sobotka: Why GIMP is inadequate

Posted Jan 13, 2011 20:53 UTC (Thu) by Trelane (subscriber, #56877) [Link]

> compatibility between platforms

This is pretty nebulous. Please be specific in what ways Qt is better than gtkmm in this regard.

> documentation

Again, this is very nebulous. Be specific.

> structure of GUI components

Yet again, this is not at all specific. What precisely is better about Qt's "structure" than gtkmm's? List examples where you can.

> stability
> the designer IDE (here I'm not 100% sure)
> L&F

This is simply a laundry list of things that are "better" (and most of the items aren't concrete examples of anything; they're categories) and nothing more. Please be specific with your argument and back it up with examples.

I'm going to learn Qt for maemo, so I hope to be less ignorant of Qt in the near future, as time permits. I do have a degree of experience in gtk and gtkmm, so I want to know what you think is failing (and perhaps even fix it). I can't fix "documentation"; I can fix the fact that there aren't any tutorials on how to frob the critical blort property in gtk/gtkmm, though.

> A GUI is composed of elements that in some natural way inherit from each other. E.g. there are push buttons, radio buttons, which are all buttons. And buttons and many other elements are widgets. The main windows, dialogs and so on are frames or windows.

Honestly, right here you sound like you haven't even looked at gtk+/gtkmm documentation, let *know* anything at all about it.

How about looking at the "Object Hierarchy"
http://library.gnome.org/devel/gtk/stable/GtkRadioButton....
http://library.gnome.org/devel/gtkmm/unstable/classGtk_1_...

> So why not using the right tool for the job?

I think you've confused me for you. I'm wondering why you think gtk+ is inferior to Qt in all situations (implicit in the statement "[gtkmm is]That's not as good as Qt." which is without qualifications. I don't mind Qt at all, and would like to improve gnome/gtk.

Sobotka: Why GIMP is inadequate

Posted Jan 13, 2011 21:00 UTC (Thu) by Trelane (subscriber, #56877) [Link]

Heh. I missed the thread. never mind the latter part. :)

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds