Common Lisp Package: GLIB

Cl-gtk2-glib is wrapper for @a[http://library.gnome.org/devel/glib/]{GLib}.

README:

FUNCTION

Public

G-FREE (PTR)

@arg[ptr]{pointer previously obtained with @fun{g-malloc} or with g_malloc C function} Frees the pointer by calling g_free on it.

G-IDLE-ADD-FULL (PRIORITY FUNCTION DATA NOTIFY)

A low-level function for adding callbacks to be called from main loop. Wrapper around g_idle_add_full. Adds a function to be called whenever there are no higher priority events pending. If the function returns FALSE it is automatically removed from the list of event sources and will not be called again. @arg[priority]{an integer specifying the priority. See @variable{+g-priority-default+}, @variable{+g-priority-default-idle+}, @variable{+g-priority-high+}, @variable{+g-priority-high-idle+}, @variable{+g-priority-low+}.} @arg[function]{pointer to callback that will be called. Callback should accept a single pointer argument and return a boolean FALSE if it should be removed} @arg[data]{pointer that will be passed to callback function} @arg[notify]{function that will be called when callback is no more needed. It will receive the @code{data} argument}

G-MALLOC (N-BYTES)

@arg[n-bytes]{an integer} @return{pointer to beginning of allocated memory} Allocates the specified number of bytes in memory. Calls g_malloc. @see{g-free}

G-STRDUP (STR)

@arg[str]{a @class{string}} @return{foreign pointer to new string} Allocates a new string that is equal to @code{str}. Use @fun{g-free} to free it.

Undocumented

BUILD-FILENAME (&REST ARGS)

G-IDLE-ADD (FUNCTION DATA)

G-SOURCE-REMOVE (ID)

G-TIMEOUT-ADD-FULL (PRIORITY INTERVAL-MILLISECONDS FUNCTION DATA DESTROY-NOTIFY)

GET-USER-CACHE-DIR

GET-USER-CONFIG-DIR

GET-USER-DATA-DIR

RANDOM-BOOLEAN

RANDOM-DOUBLE

RANDOM-DOUBLE-RANGE (BEGIN END)

RANDOM-INT

RANDOM-INT-RANGE (BEGIN END)

RANDOM-SET-SEED (SEED)

REQUIRE-LIBRARY-VERSION (LIBRARY MIN-MAJOR-VERSION MIN-MINOR-VERSION MAJOR-VERSION MINOR-VERSION)

Private

Undocumented

%VAR-ACCESSOR-*GLIB-BINARY-AGE*

SETF%VAR-ACCESSOR-*GLIB-BINARY-AGE* (VALUE)

%VAR-ACCESSOR-*GLIB-INTERFACE-AGE*

SETF%VAR-ACCESSOR-*GLIB-INTERFACE-AGE* (VALUE)

%VAR-ACCESSOR-*GLIB-MAJOR-VERSION*

SETF%VAR-ACCESSOR-*GLIB-MAJOR-VERSION* (VALUE)

%VAR-ACCESSOR-*GLIB-MICRO-VERSION*

SETF%VAR-ACCESSOR-*GLIB-MICRO-VERSION* (VALUE)

%VAR-ACCESSOR-*GLIB-MINOR-VERSION*

SETF%VAR-ACCESSOR-*GLIB-MINOR-VERSION* (VALUE)

G-BUILD-FILENAMEV (ARGS)

G-CLEAR-ERROR (ERR-PTR)

G-ERROR-COPY (ERROR)

G-ERROR-FREE (ERROR)

G-ERROR-MATCHES (ERROR DOMAIN CODE)

G-ERROR-NEW-LITERAL (DOMAIN CODE MESSAGE)

G-GET-USER-CACHE-DIR

G-GET-USER-CONFIG-DIR

G-GET-USER-DATA-DIR

G-IDLE-REMOVE-BY-DATA (DATA)

G-IDLE-SOURCE-NEW

G-LIST-FIRST (LIST)

G-LIST-FREE (LIST)

G-LIST-NEXT (LIST)

G-MAIN-CONTEXT-ACQUIRE (CONTEXT)

G-MAIN-CONTEXT-ADD-POLL (CONTEXT FD PRIORITY)

G-MAIN-CONTEXT-CHECK (CONTEXT MAX-PRIORITY FDS N-FDS)

G-MAIN-CONTEXT-DEFAULT

G-MAIN-CONTEXT-DISPATCH (CONTEXT)

G-MAIN-CONTEXT-FIND-SOURCE-BY-FUNCS-USER-DATA (CONTEXT FUNCS USER-DATA)

G-MAIN-CONTEXT-FIND-SOURCE-BY-ID (CONTEXT SOURCE-ID)

G-MAIN-CONTEXT-FIND-SOURCE-BY-USER-DATA (CONTEXT USER-DATA)

G-MAIN-CONTEXT-GET-POLL-FUNC (CONTEXT)

G-MAIN-CONTEXT-IS-OWNER (CONTEXT)

G-MAIN-CONTEXT-ITERATION (CONTEXT MAY-BLOCK)

G-MAIN-CONTEXT-NEW

G-MAIN-CONTEXT-PENDING (CONTEXT)

G-MAIN-CONTEXT-REF (CONTEXT)

G-MAIN-CONTEXT-RELEASE (CONTEXT)

G-MAIN-CONTEXT-REMOVE-POLL (CONTEXT FD)

G-MAIN-CONTEXT-SET-POLL-FUNC (CONTEXT FUNC)

G-MAIN-CONTEXT-UNREF (CONTEXT)

G-MAIN-CONTEXT-WAIT (CONTEXT COND MUTEX)

G-MAIN-CONTEXT-WAKEUP (CONTEXT)

G-MAIN-CURRENT-SOURCE

G-MAIN-DEPTH

G-MAIN-LOOP-GET-CONTEXT (LOOP)

G-MAIN-LOOP-IS-RUNNING (LOOP)

G-MAIN-LOOP-NEW (CONTEXT IS-RUNNING)

G-MAIN-LOOP-QUIT (LOOP)

G-MAIN-LOOP-REF (LOOP)

G-MAIN-LOOP-RUN (LOOP)

G-MAIN-LOOP-UNREF (LOOP)

G-PROPAGATE-ERROR (DEST-PTR SRC-PTR)

G-QUARK-FROM-STRING (STRING)

G-QUARK-TO-STRING (QUARK)

G-SET-ERROR-LITERAL (ERR-PTR DOMAIN CODE MESSAGE)

G-SLIST-ALLOC

G-SLIST-FREE (LIST)

G-SLIST-NEXT (LIST)

G-SOURCE-ADD-POLL (SOURCE FD)

G-SOURCE-ATTACH (SOURCE CONTEXT)

G-SOURCE-DESTROY (SOURCE)

G-SOURCE-GET-CAN-RECURSE (SOURCE)

G-SOURCE-GET-CONTEXT (SOURCE)

G-SOURCE-GET-CURRENT-TIME (SOURCE TIMEVAL-RET)

G-SOURCE-GET-ID (SOURCE)

G-SOURCE-GET-PRIORITY (SOURCE)

G-SOURCE-IS-DESTROYED (SOURCE)

G-SOURCE-NEW (SOURCE-FUNCS STRUCT-SIZE)

G-SOURCE-REF (SOURCE)

G-SOURCE-REMOVE-BY-FUNCS-USER-DATA (FUNCS DATA)

G-SOURCE-REMOVE-BY-USER-DATA (DATA)

G-SOURCE-REMOVE-POLL (SOURCE FD)

G-SOURCE-SET-CALLBACK (SOURCE FUNC DATA NOTIFY)

G-SOURCE-SET-CAN-RECURSE (SOURCE CAN-RECURSE)

G-SOURCE-SET-FUNCS (SOURCE FUNCS)

G-SOURCE-SET-PRIORITY (SOURCE PRIORITY)

G-SOURCE-UNREF (SOURCE)

G-THREAD-GET-INITIALIZED

G-THREAD-INIT (VTABLE)

G-THREAD-JOIN (THREAD)

G-THREAD-PRIORITY (THREAD PRIORITY)

G-THREAD-SELF

G-TIMEOUT-ADD (INTERVAL-MILLISECONDS FUNCTION DATA)

G-TIMEOUT-ADD-SECONDS (INTERVAL-SECONDS FUNCTION DATA)

G-TIMEOUT-ADD-SECONDS-FULL (PRIORITY INTERVAL-SECONDS FUNCTION DATA DESTROY-NOTIFY)

G-TIMEOUT-SOURCE-NEW (INTERVAL-MILLISECONDS)

G-TIMEOUT-SOURCE-NEW-SECONDS (INTERVAL-SECONDS)

G_MAIN_CONTEXT_PREPARE (CONTEXT PRIORITY-RET)

G_MAIN_CONTEXT_QUERY (CONTEXT MAX-PRIORITY TIMEOUT-RET FDS-RET N-DFS)

MAYBER-RAISE-G-ERROR-CONDITION (ERR)

REGISTER-FINALIZER (KEY FN)

REGISTER-INITIALIZER (KEY FN)

RUN-FINALIZERS

RUN-INITIALIZERS

MACRO

Public

AT-INIT ((&REST KEYS) &BODY BODY)

@arg[keys]{list of expression} @arg[body]{the code} Runs the code normally but also schedules the code to be run at image load time. It is used to reinitialize the libraries when the dumped image is loaded. (Works only on SBCL for now). At-init form may be called multiple times. The same code from should not be run multiple times at initialization time (in best case, this will only slow down initialization, in worst case, the code may crash). To ensure this, every @code{at-init} expression is added to hash-table with the @code{body} and @code{keys} as a composite key. This ensures that the same code is only executed once (once on the same set of parameters). Example: @begin{pre} (defmethod initialize-instance :after ((class gobject-class) &key &allow-other-keys) (register-object-type (gobject-class-g-type-name class) (class-name class)) (at-init (class) (initialize-gobject-class-g-type class))) @end{pre} In this example, for every @code{class}, @code{(initialize-gobject-class-g-type class)} will be called only once.

Undocumented

AT-FINALIZE ((&REST KEYS) &BODY BODY)

PUSH-LIBRARY-VERSION-FEATURES (LIBRARY-NAME MAJOR-VERSION-VAR MINOR-VERSION-VAR &BODY VERSIONS)

WITH-CATCHING-TO-G-ERROR ((ERR) &BODY BODY)

WITH-G-ERROR ((ERR) &BODY BODY)

GENERIC-FUNCTION

Public

Undocumented

G-ERROR-CONDITION-CODE (CONDITION)

G-ERROR-CONDITION-DOMAIN (CONDITION)

G-ERROR-CONDITION-MESSAGE (CONDITION)

Private

Undocumented

.ACTUAL-VERSION (CONDITION)

.LIBRARY (CONDITION)

.MINIMUM-VERSION (CONDITION)

SLOT-ACCESSOR

Private

Undocumented

G-STRING-TYPE-FFF (OBJECT)

G-STRING-TYPE-FTF (OBJECT)

GLIST-TYPE-FREE-FROM-FOREIGN (OBJECT)

GLIST-TYPE-FREE-TO-FOREIGN (OBJECT)

GLIST-TYPE-TYPE (OBJECT)

GSLIST-TYPE-FREE-FROM-FOREIGN (OBJECT)

GSLIST-TYPE-FREE-TO-FOREIGN (OBJECT)

GSLIST-TYPE-TYPE (OBJECT)

GSTRV-TYPE-FFF (OBJECT)

GSTRV-TYPE-FTF (OBJECT)

VARIABLE

Private

Undocumented

*FINALIZERS*

*FINALIZERS-TABLE*

*INITIALIZERS*

*INITIALIZERS-TABLE*

CLASS

Private

Undocumented

G-COND-TCLASS

G-ERROR-TCLASS

G-LIST-TCLASS

G-MAIN-CONTEXT-TCLASS

G-MAIN-LOOP-TCLASS

G-MUTEX-TCLASS

G-POLL-FD-TCLASS

G-SLIST-TCLASS

G-SOURCE-CALLBACK-FUNCS-TCLASS

G-SOURCE-FUNCS-TCLASS

G-SOURCE-TCLASS

G-STRING-TYPE

G-THREAD-TCLASS

G-TIME-VAL-TCLASS

GLIST-TYPE

GSLIST-TYPE

GSTRV-TYPE

QUARK-TYPE

CONDITION

Public

Undocumented

FOREIGN-LIBRARY-MINIMUM-VERSION-MISMATCH

G-ERROR-CONDITION

CONSTANT

Public

+G-PRIORITY-DEFAULT+

Use this for default priority event sources. In GLib this priority is used when adding timeout functions with g_timeout_add(). In GDK this priority is used for events from the X server.

+G-PRIORITY-DEFAULT-IDLE+

Use this for default priority idle functions. In GLib this priority is used when adding idle functions with g_idle_add().

+G-PRIORITY-HIGH+

Use this for high priority event sources. It is not used within GLib or GTK+.

+G-PRIORITY-HIGH-IDLE+

Use this for high priority idle functions. GTK+ uses @variable{+g-priority-high-idle+} + 10 for resizing operations, and @variable{+g-priority-high-idle+} + 20 for redrawing operations. (This is done to ensure that any pending resizes are processed before any pending redraws, so that widgets are not redrawn twice unnecessarily.)

+G-PRIORITY-LOW+

Use this for very low priority background tasks. It is not used within GLib or GTK+.