[MonoDevelop] Gnome and Gtk project templates

Francisco T. Martinez martinf at mfconsulting.com
Tue Jan 24 08:16:54 EST 2006

Lluis Sanchez wrote:
> In fact, are the Gnome# and Glade# templates useful at all? I find them
> a bit confusing. 
> For example: somebody wants to develop an application for the Gnome
> desktop, using GTK as widget library, and Glade to design the windows.
> So he clicks on "New Project" and finds three project templates: Gnome#
> project, Gtk# project and Glade# project. It wouldn't be easy for him to
> make a choice!
> I think it would be easier to have a single project template for GTK#
> applications, and then provide file templates which can be added to the
> project (gnome program, glade file, etc). 
> We could also have a "Samples" category and put there some more complete
> templates.
> Comments?
> Lluis.
You may be on to something.  As you may know I have project templates
for Gtk# and Glade# applications that ship with the Gtk# Installer for
.NET Framework SDK.  These are installed and configured for the user if
the installation routine detects the presence of VS 2003 on the host
system.  My templates are very much inspired by some of the concept you
would see on Microsoft MFC applications.

There could be value in using a pattern like the model view controller
concept.  This mean a main frame window, a document class and a View
class for the document.  Each of these classes would be on their own
file, and could be given as a choice to a user when creating a new
file.  However when creating a new project one could have a very thin
main class that handles command line argument parsing as well as the
invocation of the Main Frame window class, and the life cycle of the
main message loop.

I realize that not all applications need such pattern but I wonder how
many desktop applications (statistically speaking), have some common
denominators like a menu and toolbar.  Speaking of menus, I would go out
on a limb here and say that if there will be a menu, there is a good
chance that it would sport choices for Quit and an About Dialog.  If
there is some agreement with that statement, one could see having that
Main Frame class file having at least the most basic facilities for a
menu that has File->Exit and Help->About.

When new programmers to Gtk# are not using Glade, there are always some
questions about where and how to use Accelerators, event handlers, stock
menu-items and the like.

Just some thoughts :)


More information about the Monodevelop-list mailing list