Exemplo n.º 1
0
CAMLprim value ml_gtkmisc_init(value unit)
{
    /* Since these are declared const, must force gcc to call them! */
    GType t =
        gtk_gamma_curve_get_type() +
        gtk_statusbar_get_type() +
#ifdef HASGTK210
        gtk_status_icon_get_type() +
#endif
        gtk_calendar_get_type() +
        gtk_drawing_area_get_type() +
        gtk_curve_get_type() +
        gtk_misc_get_type() +
        gtk_arrow_get_type() +
        gtk_image_get_type() +
        gtk_label_get_type() +
        gtk_tips_query_get_type() +
        gtk_pixmap_get_type() +
        gtk_hseparator_get_type() +
        gtk_vseparator_get_type() +
        gtk_preview_get_type () +
        gtk_font_selection_get_type() +
        gtk_color_selection_get_type();
    return Val_GType(t);
}
Exemplo n.º 2
0
/*
 * Initializes the GbWidget structure.
 * I've placed this at the end of the file so we don't have to include
 * declarations of all the functions.
 */
GbWidget*
gb_font_selection_init ()
{
  /* Initialise the GTK type */
  volatile GtkType type;
  type = gtk_font_selection_get_type();

  /* Initialize the GbWidget structure */
  gb_widget_init_struct(&gbwidget);

  /* Fill in the pixmap struct & tooltip */
  gbwidget.pixmap_struct = fontsel_xpm;
  gbwidget.tooltip = _("Font Selection");

  /* Fill in any functions that this GbWidget has */
  gbwidget.gb_widget_new		= gb_font_selection_new;
  gbwidget.gb_widget_create_properties	= gb_font_selection_create_properties;
  gbwidget.gb_widget_get_properties	= gb_font_selection_get_properties;
  gbwidget.gb_widget_set_properties	= gb_font_selection_set_properties;
/*
  gbwidget.gb_widget_create_popup_menu	= gb_font_selection_create_popup_menu;
*/
  gbwidget.gb_widget_write_source	= gb_font_selection_write_source;

  return &gbwidget;
}