Re: GTK not good for newbies?



Hello gtk-app-devel-list !

I just started using GTK for the first time about four days ago. I'm working 
on doing scientific visualization using OpenGL (another thing I just started 
learning) and I come from a C/Java background (notice C comes first).  I've 
never used C++ and since GLUT just doesn't have what I need in the way of 
user interfaces, I started looking for a GUI library to get the job done.  
I've was recommended Qt, but that's just too C++ for me right now (and since 
no one cares how I get the job done [ah, University], I wanna stick with the 
Dennis Ritchie camp and leave Bjarne Stroustrup and crew for another day). So 
Gtk was what I wanted to go with (using OpenGL via GtkGLExt).

So four days in, what can I say about using GTK?  Well there are docs out 
there:
        GTK+ / Gnome Application Development
        http://developer.gnome.org/doc/GGAD/ggad.html
And tutorials:
        GTK+ 2.0 Tutorial
        http://www.gtk.org/tutorial/index.html
The one problem for "newbies" who are new to GTK and glib (like myself), is 
figuring out how to do things the glib way. Right now I said, screw that I'm 
going with:
        fprintf(stderr, "ERROR...");
        exit(EXIT_FAILURE);
Rather then rewriting my old code to use 
        g_critical();
I wasted a bunch of time trying to covert old stuff to the glib way, so the 
libc way of doing things is staying in this project. 

Once I got through the initial learning curve, things aren't so bad.  There is 
a point that needs to be made about the available API.  I've used the Java 
API (so that's what I'm juxtaposing against), now the thing that sucks about 
the GTK API is having to go through a bunch of web nodes to find what it is 
your looking for. A centralized function list would be great.  Right now I 
use the GTK Object Hierarchy:   
        http://developer.gnome.org/doc/API/2.0/gtk/ch01.html
as my "centralized" location for searching.  I might just be ignorant here and 
such a thing does exist, but as of Tue Feb 17 00:20:59 MST 2004 I haven't 
found it.

One documentation section that I think is lacking is docs on signals. The 
general usage and implementation docs are there, but I haven't found a 
complete list of the available signals that can be connected to each widget.  
This would be nice.

Comparing Qt and GTK, while already done, isn't really fair.  Trolltech has $$ 
to back up documentation initiatives (there was a ./ post a bit back about a 
new Qt book written by two guys from Trolltech...) and GTK relies on 
volunteers.  That's not to shut down any critical comments on GTK's docs 
(isn't the peer constructive criticism, one of the main points of Open 
Source?), but I always keep that in mind when comparing the two.

Rikke makes a good point.  It's my background in C that steered me toward GTK 
and away from C++: when dealing with libraries, they assume your note just 
finishing off the hello world tutorial in the implemented language. 

Once I get moving with GTK, I want to do what I can to help out.  I'm new to 
these mail lists, but they sure are a powerful tool.  And since your using it 
Manish, your already a step in the right direction.

Stay Fresh!
Matthew

 =-=-==-=--=-=--=-=-===--=--=-
www.ucalgary.ca/~matobias


On Monday 16 February 2004 20:14, Manish Chakravarty wrote:
hi all,
i am just beginning to understand GTK programming,
but the documentation is not very helpful
Just look at Qt's docs... they have a lovely tutorial and GTK's docs are
nowhere near it.
I wanted to prgram in C++ as i am more comfortable with it.
But the gtkmm docs are very sparse and moreover it does not work directly
with glade
Also, whenever i ask a question about programming with glade on any of the
LUG's or mailng list, usually the response is "Dont use Glade-generated
code, just use the XML file and write your own"
So does there exist a decent tutorial for gtk or gtkmm?
And i do think the authors of gtk and gtkmm should pay more attention to
documentation now.. for the experienced hackers its ok, but for novices and
first timers, you are asking them to shift to Qt
Regards
Manish



_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]