W Wrapl, The Programming Language

Libraries:Gtk:Gdk:Atom

Types

T

Constants

Nil : T

Functions

Intern(atom_name @ Std.String.T, only_if_exists @ Std.Symbol.T) : Gtk.Gdk.Atom.T

Finds or creates an atom corresponding to a given string.

atom_name a string.
only_if_exists if TRUE, GDK is allowed to not create a new atom, but just return GDK_NONE if the requested atom doesn't already exists. Currently, the flag is ignored, since checking the existance of an atom is as expensive as creating it.
Returns the atom corresponding to atom_name.


InternStaticString(atom_name @ Std.String.T) : Gtk.Gdk.Atom.T

Finds or creates an atom corresponding to a given string.

Note that this function is identical to Intern except that if a new T is created the string itself is used rather than a copy. This saves memory, but can only be used if the string will always exist. It can be used with statically allocated strings in the main program, but not with statically allocated memory in dynamically loaded modules, if you expect to ever unload the module again (e.g. do not use this function in GTK+ theme engines).

atom_name a static string
Returns the atom corresponding to atom_name


Methods

:"="(_ @ T, _ @ T)

:Name(self @ T) : Std.String.T

Determines the string corresponding to an atom.

atom a T.
Returns a newly-allocated string containing the string corresponding to atom. When you are done with the return value, you should free it using g_free().


:"~="(_ @ T, _ @ T)