Hi Rick,
look at the GObject tutorial: http://www.le-hacker.org/papers/gobject/
If you design your application in a oo-fashion, all global variables you have is an application object handle. That in turn knows the rest. Its like a tree, where one tree-node knows stuff about what it is responsible for and who is its parent.
Generally OO design needsa some thinking, like what parts, modules my app consist of and so on. It definitely pays back, when the app get larger.
A keyword to look out for is: 'Design Patterns'.
I myself look in apps like e.g gedit.
Ciao Stefan
Hello,
I am a noob to GTK+ programming, and GUI programming in general. I have worked through the example, and done a few simple programs of my own.
I would like to improve my programs. Particularly I would like to do away with , or at least reduce, the mumber of global variables. I would also like to make my code more modular and object oriented. Can anyone recommend any good examples, or simple programs, that I could study to learn good GTK+ coding practices?
Rick
_______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list