Package: glib

Function glib:gtype

Lambda List

glib:gtype (thing)

Arguments

thing -- a string, an integer, or an g:gtype instance

Return Value

The g:gtype instance for thing.

Details

Returns a g:gtype instance for thing. If the string or the integer does not represent a valid GType type the nil value is returned and a warning is printed.

Examples

(g:gtype 20) => #<GTYPE :name "gboolean" :id 20>
(g:gtype "gboolean") => #<GTYPE :name "gboolean" :id 20>
(g:gtype (g:gtype 20)) => #<GTYPE :name "gboolean" :id 20>
(g:gtype "unknown")
=> WARNING: unknown is not known to the GType system
=> NIL    
 

See also

2024-12-8