If you do write GObject derivated classes often you may know it’s a boring and error prone task.
Lisp:gobject-class.el is a set of 3 functions to help you define the header, the code skeleton and to create files following GObject and Gtk naming schemas. All it ask you is 2 parameters: the class name and the parent class name, the last one may be omited and defaults to GObject.
G_TYPE_OBJECT), typedef and struct declarations and define the
_get_type()function. These contents are enclosed in
G_DEFINE_TYPEcall, and skeleton for
Class names are expected to have a namespace like gtk_button is really the class button in the namespace gtk, g_object is object in g.
;;; create the definitions for GtkButton, which derives from GtkBin (gobject-class-header "gtk_button" "gtk_bin")
;;; create the implementation for GtkButton (gobject-class-code "gtk_button" "gtk_bin")
;;; create files with header and code: gtk-button.h and gtk-button.c (gobject-class-generate "gtk_button" "gtk_bin")