
2001-12-29 Michael Natterer <mitch@gimp.org> * app/gimpprogress.c * app/nav_window.c * app/ops_buttons.c * app/undo_history.c * app/display/gimpdisplayshell.c * app/gui/about-dialog.c * app/gui/brush-editor.c * app/gui/channels-commands.c * app/gui/color-area.c * app/gui/color-notebook.c * app/gui/color-select.c * app/gui/colormap-dialog.c * app/gui/convert-dialog.c * app/gui/device-status-dialog.c * app/gui/file-new-dialog.c * app/gui/file-open-dialog.c * app/gui/file-save-dialog.c * app/gui/gradient-editor.c * app/gui/info-dialog.c * app/gui/layers-commands.c * app/gui/module-browser.c * app/gui/offset-dialog.c * app/gui/palette-editor.c * app/gui/palettes-commands.c * app/gui/paths-dialog.c * app/gui/qmask-commands.c * app/gui/resize-dialog.c * app/gui/resolution-calibrate-dialog.c * app/gui/splash.c * app/gui/tips-dialog.c * app/gui/toolbox.c * app/gui/user-install-dialog.c * app/tools/gimpbrightnesscontrasttool.c * app/tools/gimpbycolorselecttool.c * app/tools/gimpcolorbalancetool.c * app/tools/gimpcolorpickertool.c * app/tools/gimpcroptool.c * app/tools/gimpcurvestool.c * app/tools/gimphuesaturationtool.c * app/tools/gimpinktool.c * app/tools/gimplevelstool.c * app/tools/gimpposterizetool.c * app/tools/gimprotatetool.c * app/tools/gimpthresholdtool.c * app/tools/paint_options.c * app/tools/selection_options.c * app/widgets/gimpchannellistview.c * app/widgets/gimpcolorpanel.c * app/widgets/gimpcomponentlistitem.c * app/widgets/gimpconstrainedhwrapbox.c * app/widgets/gimpcontainergridview.c * app/widgets/gimpcontainerlistview.c * app/widgets/gimpcontainermenuimpl.c * app/widgets/gimpdialogfactory.c * app/widgets/gimpdnd.c * app/widgets/gimpdock.c * app/widgets/gimpdockbook.c * app/widgets/gimpdrawablelistitem.c * app/widgets/gimpdrawablelistview.c * app/widgets/gimpfontselection-dialog.c * app/widgets/gimphistogramview.c * app/widgets/gimpitemfactory.c * app/widgets/gimplayerlistitem.c * app/widgets/gimplistitem.[ch] * app/widgets/gimpmenuitem.c * app/widgets/gimppreview.[ch] * app/widgets/gtkhwrapbox.c * app/widgets/gtkvwrapbox.c * app/widgets/gtkwrapbox.c * libgimp/gimpbrushmenu.c * libgimp/gimpexport.c * libgimp/gimpgradientmenu.c * libgimp/gimpmenu.c * libgimp/gimppatternmenu.c * libgimpwidgets/gimpbutton.c * libgimpwidgets/gimpchainbutton.[ch] * libgimpwidgets/gimpcolorarea.h * libgimpwidgets/gimpcolorbutton.c * libgimpwidgets/gimpfileselection.c * libgimpwidgets/gimphelpui.c * libgimpwidgets/gimpoffsetarea.c * libgimpwidgets/gimppatheditor.c * libgimpwidgets/gimppixmap.h * libgimpwidgets/gimpquerybox.c * libgimpwidgets/gimpstock.[ch] * libgimpwidgets/gimpwidgets.h * plug-ins/FractalExplorer/Dialogs.c * plug-ins/FractalExplorer/Events.c * plug-ins/FractalExplorer/FractalExplorer.c * plug-ins/Lighting/lighting_ui.c * plug-ins/MapObject/mapobject_ui.c * plug-ins/bmp/bmpwrite.c * plug-ins/dbbrowser/dbbrowser_utils.c * plug-ins/fits/fits.c * plug-ins/flame/flame.c * plug-ins/fp/fp_gtk.c * plug-ins/fp/fp_misc.c * plug-ins/gfig/gfig.c * plug-ins/gflare/gflare.c * plug-ins/gfli/gfli.c * plug-ins/gimpressionist/*.c * plug-ins/imagemap/*.[ch] * plug-ins/maze/maze_face.c * plug-ins/mosaic/mosaic.c * plug-ins/pagecurl/pagecurl.c * plug-ins/print/print_gimp.h * plug-ins/rcm/rcm_callback.c * plug-ins/rcm/rcm_dialog.c * plug-ins/rcm/rcm_misc.c * plug-ins/script-fu/script-fu-console.c * plug-ins/script-fu/script-fu-scripts.c * plug-ins/script-fu/script-fu-server.c * plug-ins/sel2path/sel2path.c * plug-ins/sel2path/sel2path_adv_dialog.c * plug-ins/sgi/sgi.c * plug-ins/webbrowser/webbrowser.c * plug-ins/xjt/xjt.c * plug-ins/common/[A-n]*.c: compile with GTK_DISABLE_DEPRECATED defined. Not everything is fully ported yet, had to #undef GTK_DISABLE_DEPRECATED in many places and added #warnings when doing so. * pixmaps/Makefile.am * pixmaps/chain.xpm: removed. * themes/Default/Makefile.am * themes/Default/images/Makefile.am * themes/Default/images/stock-button-hchain-broken.png * themes/Default/images/stock-button-hchain.png * themes/Default/images/stock-button-vchain-broken.png * themes/Default/images/stock-button-vchain.png: new stock icons.
269 lines
8.9 KiB
C
269 lines
8.9 KiB
C
/* LIBGIMP - The GIMP Library
|
|
* Copyright (C) 1995-1997 Peter Mattis and Spencer Kimball
|
|
*
|
|
* gimpwidgets.h
|
|
* Copyright (C) 2000 Michael Natterer <mitch@gimp.org>
|
|
*
|
|
* This library is free software; you can redistribute it and/or
|
|
* modify it under the terms of the GNU Lesser General Public
|
|
* License as published by the Free Software Foundation; either
|
|
* version 2 of the License, or (at your option) any later version.
|
|
*
|
|
* This library is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
* Lesser General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU Lesser General Public
|
|
* License along with this library; if not, write to the
|
|
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
|
* Boston, MA 02111-1307, USA.
|
|
*/
|
|
|
|
#ifndef __GIMP_WIDGETS_H__
|
|
#define __GIMP_WIDGETS_H__
|
|
|
|
|
|
#include <libgimpwidgets/gimpwidgetstypes.h>
|
|
|
|
#include <libgimpwidgets/gimpbutton.h>
|
|
#include <libgimpwidgets/gimpchainbutton.h>
|
|
#include <libgimpwidgets/gimpcolorarea.h>
|
|
#include <libgimpwidgets/gimpcolorbutton.h>
|
|
#include <libgimpwidgets/gimpdialog.h>
|
|
#include <libgimpwidgets/gimpfileselection.h>
|
|
#include <libgimpwidgets/gimphelpui.h>
|
|
#include <libgimpwidgets/gimpoffsetarea.h>
|
|
#include <libgimpwidgets/gimppatheditor.h>
|
|
#include <libgimpwidgets/gimppixmap.h>
|
|
#include <libgimpwidgets/gimpquerybox.h>
|
|
#include <libgimpwidgets/gimpsizeentry.h>
|
|
#include <libgimpwidgets/gimpstock.h>
|
|
#include <libgimpwidgets/gimpunitmenu.h>
|
|
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
/* For information look into the C source or the html documentation */
|
|
|
|
|
|
void gimp_widgets_init (void);
|
|
|
|
|
|
/*
|
|
* Widget Constructors
|
|
*/
|
|
|
|
GtkWidget * gimp_option_menu_new (gboolean menu_only,
|
|
|
|
/* specify menu items as va_list:
|
|
* gchar *label,
|
|
* GCallback callback,
|
|
* gpointer callback_data,
|
|
* gpointer item_data,
|
|
* GtkWidget **widget_ptr,
|
|
* gboolean active
|
|
*/
|
|
|
|
...);
|
|
|
|
GtkWidget * gimp_option_menu_new2 (gboolean menu_only,
|
|
GCallback menu_item_callback,
|
|
gpointer menu_item_callback_data,
|
|
gpointer initial, /* item_data */
|
|
|
|
/* specify menu items as va_list:
|
|
* gchar *label,
|
|
* gpointer item_data,
|
|
* GtkWidget **widget_ptr,
|
|
*/
|
|
|
|
...);
|
|
|
|
void gimp_option_menu_set_history (GtkOptionMenu *option_menu,
|
|
gpointer item_data);
|
|
|
|
GtkWidget * gimp_radio_group_new (gboolean in_frame,
|
|
const gchar *frame_title,
|
|
|
|
/* specify radio buttons as va_list:
|
|
* const gchar *label,
|
|
* GCallback callback,
|
|
* gpointer callback_data,
|
|
* gpointer item_data,
|
|
* GtkWidget **widget_ptr,
|
|
* gboolean active,
|
|
*/
|
|
|
|
...);
|
|
|
|
GtkWidget * gimp_radio_group_new2 (gboolean in_frame,
|
|
const gchar *frame_title,
|
|
GCallback radio_button_callback,
|
|
gpointer radio_button_callback_data,
|
|
gpointer initial, /* item_data */
|
|
|
|
/* specify radio buttons as va_list:
|
|
* const gchar *label,
|
|
* gpointer item_data,
|
|
* GtkWidget **widget_ptr,
|
|
*/
|
|
|
|
...);
|
|
|
|
void gimp_radio_group_set_active (GtkRadioButton *radio_button,
|
|
gpointer item_data);
|
|
|
|
GtkWidget * gimp_spin_button_new (/* return value: */
|
|
GtkObject **adjustment,
|
|
|
|
gfloat value,
|
|
gfloat lower,
|
|
gfloat upper,
|
|
gfloat step_increment,
|
|
gfloat page_increment,
|
|
gfloat page_size,
|
|
gfloat climb_rate,
|
|
guint digits);
|
|
|
|
#define GIMP_SCALE_ENTRY_LABEL(adj) \
|
|
GTK_LABEL (g_object_get_data (G_OBJECT (adj), "label"))
|
|
|
|
#define GIMP_SCALE_ENTRY_SCALE(adj) \
|
|
GTK_HSCALE (g_object_get_data (G_OBJECT (adj), "scale"))
|
|
#define GIMP_SCALE_ENTRY_SCALE_ADJ(adj) \
|
|
gtk_range_get_adjustment \
|
|
(GTK_RANGE (g_object_get_data (G_OBJECT (adj), "scale")))
|
|
|
|
#define GIMP_SCALE_ENTRY_SPINBUTTON(adj) \
|
|
GTK_SPIN_BUTTON (g_object_get_data (G_OBJECT (adj), "spinbutton"))
|
|
#define GIMP_SCALE_ENTRY_SPINBUTTON_ADJ(adj) \
|
|
gtk_spin_button_get_adjustment \
|
|
(GTK_SPIN_BUTTON (g_object_get_data (G_OBJECT (adj), "spinbutton")))
|
|
|
|
GtkObject * gimp_scale_entry_new (GtkTable *table,
|
|
gint column,
|
|
gint row,
|
|
const gchar *text,
|
|
gint scale_width,
|
|
gint spinbutton_width,
|
|
gfloat value,
|
|
gfloat lower,
|
|
gfloat upper,
|
|
gfloat step_increment,
|
|
gfloat page_increment,
|
|
guint digits,
|
|
gboolean constrain,
|
|
gfloat unconstrained_lower,
|
|
gfloat unconstrained_upper,
|
|
const gchar *tooltip,
|
|
const gchar *help_data);
|
|
|
|
#define GIMP_RANDOM_SEED_SPINBUTTON(hbox) \
|
|
GTK_SPIN_BUTTON (g_object_get_data (G_OBJECT (hbox), "spinbutton"))
|
|
#define GIMP_RANDOM_SEED_SPINBUTTON_ADJ(hbox) \
|
|
gtk_spin_button_get_adjustment \
|
|
(GTK_SPIN_BUTTON (g_object_get_data (G_OBJECT (hbox), "spinbutton")))
|
|
|
|
#define GIMP_RANDOM_SEED_TOGGLEBUTTON(hbox) \
|
|
GTK_TOGGLE_BUTTON (g_object_get_data (G_OBJECT (hbox), "togglebutton"))
|
|
|
|
GtkWidget * gimp_random_seed_new (gint *seed,
|
|
gint *use_time,
|
|
gint time_true,
|
|
gint time_false);
|
|
|
|
#define GIMP_COORDINATES_CHAINBUTTON(sizeentry) \
|
|
GIMP_CHAIN_BUTTON (g_object_get_data (G_OBJECT (sizeentry), \
|
|
"chainbutton"))
|
|
|
|
GtkWidget * gimp_coordinates_new (GimpUnit unit,
|
|
const gchar *unit_format,
|
|
gboolean menu_show_pixels,
|
|
gboolean menu_show_percent,
|
|
gint spinbutton_width,
|
|
GimpSizeEntryUpdatePolicy update_policy,
|
|
|
|
gboolean chainbutton_active,
|
|
gboolean chain_constrains_ratio,
|
|
|
|
const gchar *xlabel,
|
|
gdouble x,
|
|
gdouble xres,
|
|
gdouble lower_boundary_x,
|
|
gdouble upper_boundary_x,
|
|
gdouble xsize_0, /* % */
|
|
gdouble xsize_100, /* % */
|
|
|
|
const gchar *ylabel,
|
|
gdouble y,
|
|
gdouble yres,
|
|
gdouble lower_boundary_y,
|
|
gdouble upper_boundary_y,
|
|
gdouble ysize_0, /* % */
|
|
gdouble ysize_100 /* % */);
|
|
|
|
#define GIMP_MEM_SIZE_ENTRY_SPINBUTTON(memsize) \
|
|
GTK_SPIN_BUTTON (g_object_get_data (G_OBJECT (memsize), "spinbutton"))
|
|
#define GIMP_MEM_SIZE_ENTRY_SPINBUTTON_ADJ(memsize) \
|
|
gtk_spin_button_get_adjustment \
|
|
(GTK_SPIN_BUTTON (g_object_get_data (G_OBJECT (memsize), "spinbutton")))
|
|
#define GIMP_MEM_SIZE_ENTRY_OPTIONMENU(memsize) \
|
|
GTK_OPTION_MENU (g_object_get_data (G_OBJECT (memsize), "optionmenu"))
|
|
|
|
GtkWidget * gimp_mem_size_entry_new (GtkAdjustment *adjustment);
|
|
|
|
|
|
GtkWidget * gimp_pixmap_button_new (gchar **xpm_data,
|
|
const gchar *text);
|
|
|
|
/*
|
|
* Standard Callbacks
|
|
*/
|
|
|
|
void gimp_toggle_button_sensitive_update (GtkToggleButton *toggle_button);
|
|
|
|
void gimp_toggle_button_update (GtkWidget *widget,
|
|
gpointer data);
|
|
|
|
void gimp_radio_button_update (GtkWidget *widget,
|
|
gpointer data);
|
|
|
|
void gimp_menu_item_update (GtkWidget *widget,
|
|
gpointer data);
|
|
|
|
void gimp_int_adjustment_update (GtkAdjustment *adjustment,
|
|
gpointer data);
|
|
|
|
void gimp_uint_adjustment_update (GtkAdjustment *adjustment,
|
|
gpointer data);
|
|
|
|
void gimp_float_adjustment_update (GtkAdjustment *adjustment,
|
|
gpointer data);
|
|
|
|
void gimp_double_adjustment_update (GtkAdjustment *adjustment,
|
|
gpointer data);
|
|
|
|
void gimp_unit_menu_update (GtkWidget *widget,
|
|
gpointer data);
|
|
|
|
|
|
/*
|
|
* Helper Functions
|
|
*/
|
|
|
|
void gimp_table_attach_aligned (GtkTable *table,
|
|
gint column,
|
|
gint row,
|
|
const gchar *label_text,
|
|
gfloat xalign,
|
|
gfloat yalign,
|
|
GtkWidget *widget,
|
|
gint colspan,
|
|
gboolean left_align);
|
|
|
|
|
|
G_END_DECLS
|
|
|
|
#endif /* __GIMP_WIDGETS_H__ */
|