Next: define-g-flags, Previous: define-g-interface, Up: Generating type definitions by introspection
(define-g-enum g-name name (&key (export t) type-initializer) &body value*) value ::= :keyword value ::= (:keyword integer)
name
enum_get_type
.
Macro that defines CFFI enumeration, registers it with GValue, and calls the type initializer.
Example:
(define-g-enum "GtkTextDirection" text-direction (:export t :type-initializer "gtk_text_direction_get_type") (:none 0) (:ltr 1) (:rtl 2)) (define-g-enum "GtkSizeGroupMode" size-group-mode (:export t :type-initializer "gtk_size_group_mode_get_type") :none :horizontal :vertical :both)