void
mapobject_stock_init (void)
{
  static gboolean initialized = FALSE;

  if (initialized)
    return;

  mapobject_icon_factory = gtk_icon_factory_new ();

  add_stock_icon (STOCK_INTENSITY_AMBIENT_LOW,       GTK_ICON_SIZE_BUTTON,
                  stock_intensity_ambient_low);
  add_stock_icon (STOCK_INTENSITY_AMBIENT_HIGH,      GTK_ICON_SIZE_BUTTON,
                  stock_intensity_ambient_high);
  add_stock_icon (STOCK_INTENSITY_DIFFUSE_LOW,       GTK_ICON_SIZE_BUTTON,
                  stock_intensity_diffuse_low);
  add_stock_icon (STOCK_INTENSITY_DIFFUSE_HIGH,      GTK_ICON_SIZE_BUTTON,
                  stock_intensity_diffuse_high);
  add_stock_icon (STOCK_REFLECTIVITY_DIFFUSE_LOW,    GTK_ICON_SIZE_BUTTON,
                  stock_reflectivity_diffuse_low);
  add_stock_icon (STOCK_REFLECTIVITY_DIFFUSE_HIGH,   GTK_ICON_SIZE_BUTTON,
                  stock_reflectivity_diffuse_high);
  add_stock_icon (STOCK_REFLECTIVITY_SPECULAR_LOW,   GTK_ICON_SIZE_BUTTON,
                  stock_reflectivity_specular_low);
  add_stock_icon (STOCK_REFLECTIVITY_SPECULAR_HIGH,  GTK_ICON_SIZE_BUTTON,
                  stock_reflectivity_specular_high);
  add_stock_icon (STOCK_REFLECTIVITY_HIGHLIGHT_LOW,  GTK_ICON_SIZE_BUTTON,
                  stock_reflectivity_highlight_low);
  add_stock_icon (STOCK_REFLECTIVITY_HIGHLIGHT_HIGH, GTK_ICON_SIZE_BUTTON,
                  stock_reflectivity_highlight_high);

  gtk_icon_factory_add_default (mapobject_icon_factory);

  gtk_stock_add_static (mapobject_stock_items,
                        G_N_ELEMENTS (mapobject_stock_items));

  initialized = TRUE;
}
Example #2
0
void
gfig_stock_init (void)
{
  static gboolean initialized = FALSE;

  if (initialized)
    return;

  gfig_icon_factory = gtk_icon_factory_new ();

  add_stock_icon (GFIG_STOCK_BEZIER,        GTK_ICON_SIZE_BUTTON, stock_bezier);
  add_stock_icon (GFIG_STOCK_CIRCLE,        GTK_ICON_SIZE_BUTTON, stock_circle);
  add_stock_icon (GFIG_STOCK_COPY_OBJECT,   GTK_ICON_SIZE_BUTTON, stock_copy_object);
  add_stock_icon (GFIG_STOCK_CURVE,         GTK_ICON_SIZE_BUTTON, stock_curve);
  add_stock_icon (GFIG_STOCK_DELETE_OBJECT, GTK_ICON_SIZE_BUTTON, stock_delete_object);
  add_stock_icon (GFIG_STOCK_ELLIPSE,       GTK_ICON_SIZE_BUTTON, stock_ellipse);
  add_stock_icon (GFIG_STOCK_LINE,          GTK_ICON_SIZE_BUTTON, stock_line);
  add_stock_icon (GFIG_STOCK_MOVE_OBJECT,   GTK_ICON_SIZE_BUTTON, stock_move_object);
  add_stock_icon (GFIG_STOCK_MOVE_POINT,    GTK_ICON_SIZE_BUTTON, stock_move_point);
  add_stock_icon (GFIG_STOCK_POLYGON,       GTK_ICON_SIZE_BUTTON, stock_polygon);
  add_stock_icon (GFIG_STOCK_RECTANGLE,     GTK_ICON_SIZE_BUTTON, stock_rectangle);
  add_stock_icon (GFIG_STOCK_SELECT_OBJECT, GTK_ICON_SIZE_BUTTON, stock_select_object);
  add_stock_icon (GFIG_STOCK_SHOW_ALL,      GTK_ICON_SIZE_BUTTON, stock_show_all);
  add_stock_icon (GFIG_STOCK_SPIRAL,        GTK_ICON_SIZE_BUTTON, stock_spiral);
  add_stock_icon (GFIG_STOCK_STAR,          GTK_ICON_SIZE_BUTTON, stock_star);

  gtk_icon_factory_add_default (gfig_icon_factory);

  gtk_stock_add_static (gfig_stock_items, G_N_ELEMENTS (gfig_stock_items));

  initialized = TRUE;
}
Example #3
0
void
gap_stock_init (void)
{
  static gboolean initialized = FALSE;

  if(gap_debug)
  {
    printf("gap_stock_init START\n");
  }

  if (initialized)
    return;

  gap_icon_factory = gtk_icon_factory_new ();
  
  add_stock_icon (GAP_STOCK_ADD_POINT          , GTK_ICON_SIZE_BUTTON, gap_add_point);
  add_stock_icon (GAP_STOCK_ANIM_PREVIEW       , GTK_ICON_SIZE_BUTTON, gap_anim_preview);
  add_stock_icon (GAP_STOCK_DELETE_ALL_POINTS  , GTK_ICON_SIZE_BUTTON, gap_delete_all_points);
  add_stock_icon (GAP_STOCK_DELETE_POINT       , GTK_ICON_SIZE_BUTTON, gap_delete_point);
  add_stock_icon (GAP_STOCK_FIRST_POINT        , GTK_ICON_SIZE_BUTTON, gap_first_point);
  add_stock_icon (GAP_STOCK_GRAB_POINTS        , GTK_ICON_SIZE_BUTTON, gap_grab_points);
  add_stock_icon (GAP_STOCK_INSERT_POINT       , GTK_ICON_SIZE_BUTTON, gap_insert_point);
  add_stock_icon (GAP_STOCK_LAST_POINT         , GTK_ICON_SIZE_BUTTON, gap_last_point);
  add_stock_icon (GAP_STOCK_NEXT_POINT         , GTK_ICON_SIZE_BUTTON, gap_next_point);
  add_stock_icon (GAP_STOCK_PAUSE              , GTK_ICON_SIZE_BUTTON, gap_pause);
  add_stock_icon (GAP_STOCK_PLAY               , GTK_ICON_SIZE_BUTTON, gap_play);
  add_stock_icon (GAP_STOCK_PLAY_REVERSE       , GTK_ICON_SIZE_BUTTON, gap_play_reverse);
  add_stock_icon (GAP_STOCK_PREV_POINT         , GTK_ICON_SIZE_BUTTON, gap_prev_point);
  add_stock_icon (GAP_STOCK_RESET_ALL_POINTS   , GTK_ICON_SIZE_BUTTON, gap_reset_all_points);
  add_stock_icon (GAP_STOCK_RESET_POINT        , GTK_ICON_SIZE_BUTTON, gap_reset_point);
  add_stock_icon (GAP_STOCK_ROTATE_FOLLOW      , GTK_ICON_SIZE_BUTTON, gap_rotate_follow);
  add_stock_icon (GAP_STOCK_SOURCE_IMAGE       , GTK_ICON_SIZE_BUTTON, gap_source_image);
  add_stock_icon (GAP_STOCK_STEPMODE           , GTK_ICON_SIZE_BUTTON, gap_stepmode);
  add_stock_icon (GAP_STOCK_UPDATE             , GTK_ICON_SIZE_BUTTON, gap_update);

  add_stock_icon ( GAP_STOCK_RANGE_END         , GTK_ICON_SIZE_BUTTON, gap_range_end);
  add_stock_icon ( GAP_STOCK_RANGE_START       , GTK_ICON_SIZE_BUTTON, gap_range_start);
  add_stock_icon ( GAP_STOCK_SET_RANGE_END     , GTK_ICON_SIZE_BUTTON, gap_set_range_end);
  add_stock_icon ( GAP_STOCK_SET_RANGE_START   , GTK_ICON_SIZE_BUTTON, gap_set_range_start);
  add_stock_icon ( GAP_STOCK_SPEED             , GTK_ICON_SIZE_BUTTON, gap_speed);

  gtk_icon_factory_add_default (gap_icon_factory);

  gtk_stock_add_static (gap_stock_items, G_N_ELEMENTS (gap_stock_items));

  initialized = TRUE;

  if(gap_debug)
  {
    printf("gap_stock_init DONE\n");
  }
}