[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: The rise of minimalist Lua applications
- From: Pavel Holejsovsky <pavel.holejsovsky@...>
- Date: Mon, 20 Jan 2014 20:04:50 +0000 (UTC)
On Thu, 16 Jan 2014 16:20:52 -0500, Rena wrote:
> [1] The names are not always what you'd expect because of namespacing.
> For example in C you'd write GTK_WINDOW_TOPLEVEL, but the obvious
> translations to lgi.Gtk.WINDOW_TOPLEVEL or lgi.Gtk.Window.TOPLEVEL don't
> work. If you look at the manual you'll see GTK_WINDOW_TOPLEVEL is a
> member of an enum GtkWindowType and so the actual symbol you want is
> lgi.Gtk.WindowType.TOPLEVEL. This took me a little getting used to, but
> it's easy once you get the hang of it.
It is also possible to use strings as names of constants instead of
symbolic names. So whenever method accepts lgi.Gtk.WindowType value, it
is possible to use either lgi.Gtk.WindowType.TOPLEVEL or just 'TOPLEVEL'.
This might ease the pain a bit.
Pavel