[862] in The GTK GIMP ToolKit mailing list archive

home help back first fref pref prev next nref lref last post

[gtk-list] Re: A type system for high-level interfaces

daemon@ATHENA.MIT.EDU (Maurizio Vitale)
Wed Aug 27 08:58:42 1997

To: gtk-list@redhat.com
From: Maurizio Vitale <Maurizio.Vitale@esat.kuleuven.ac.be>
Date: 27 Aug 1997 14:37:26 +0200
In-Reply-To: Marius Vollmer's message of "27 Aug 1997 11:54:52 +0200"
Resent-From: gtk-list@redhat.com
Reply-To: gtk-list@redhat.com

Marius Vollmer <mvo@zagadka.ping.de> writes:

> Maurizio Vitale <Maurizio.Vitale@esat.kuleuven.ac.be> writes:
> > 
> > > > Making those symbols part of a gtk module (or prefixed by gtk:) would
> > > > help alleviating the name pollution problem.
> > > 
> > > Gtk already has to keep the namespace clean, so that wouldn't be a
> > > problem in Scheme, I think.
> > 
> > What I meant was that if you've somewhere something to the effect of
> > (define toplevel GTK_TOPLEVEL) then the user cannot bind anything else 
> > to toplevel, while if you seize all identifiers starting with gtk: for 
> > your interface you've much less problems.
> 
> The enumeration values would have their usual Gtk names, I think.
> Like GTK_WINDOW_TOPLEVEL, GTK_WINDOW_DIALOG.  So we would have code
> to effect of
> 
>     (define GTK_WINDOW_TOPLEVEL 0)
>     (define GTK_WINDOW_DIALOG 1)
> 
> Or maybe with dashes in place of the underscores.

and maybe we could lowercase them, mangle a bit and get
(define gtk:window-toplevel 0) :-).

Seriously, what is the preferred way for declaring identifiers in
C/C++ is not necessarly the best way in scheme/LISP.
On the other hand, by using the same names you can reuse gtk
documentation 'as is' [even if STk shows that this kind of 1 to 1
mappings are not a big deal].

I've no strong objections to GTK_WINDOW_TOPLEVEL (although I'd prefer
the other style _in_ scheme), as long as there's an unique prefix [I
think your original proposal had a plain 'toplevel].

	Maurizio

--
To unsubscribe: mail -s unsubscribe gtk-list-request@redhat.com < /dev/null


home help back first fref pref prev next nref lref last post