gimp/plug-ins/rcm/rcm.h
Michael Natterer 66c5dd8772 removed our own action_area API and use GtkDialog's one. Create all
2003-11-06  Michael Natterer  <mitch@gimp.org>

	* libgimpwidgets/gimpdialog.[ch]: removed our own action_area API
	and use GtkDialog's one. Create all dialogs without separator.
	Changed almost everything else too. Fixes bug #125143.

	* libgimpwidgets/gimpquerybox.c
	* libgimpwidgets/gimpunitmenu.c: changed accordingly.

	* libgimp/gimpexport.[ch]: ditto. Renamed enum GimpExportReturnType
	to GimpExportReturn.

	* libgimp/gimpcompat.h: added a #define for the old name.

	* themes/Default/gtkrc: increased action_area border to 6 pixels.

	* app/display/gimpdisplayshell-filter-dialog.c
	* app/display/gimpdisplayshell-scale.c
	* app/display/gimpprogress.c
	* app/gui/brush-select.c
	* app/gui/channels-commands.c
	* app/gui/color-notebook.c
	* app/gui/convert-dialog.c
	* app/gui/file-new-dialog.c
	* app/gui/font-select.c
	* app/gui/gradient-editor-commands.c
	* app/gui/gradient-select.c
	* app/gui/grid-dialog.c
	* app/gui/image-commands.c
	* app/gui/info-window.c
	* app/gui/layers-commands.c
	* app/gui/module-browser.c
	* app/gui/offset-dialog.c
	* app/gui/palette-import-dialog.c
	* app/gui/palette-select.c
	* app/gui/pattern-select.c
	* app/gui/preferences-dialog.c
	* app/gui/qmask-commands.c
	* app/gui/resize-dialog.c
	* app/gui/resolution-calibrate-dialog.c
	* app/gui/stroke-dialog.c
	* app/gui/templates-commands.c
	* app/gui/user-install-dialog.c
	* app/gui/vectors-commands.c
	* app/tools/gimpcolorpickertool.c
	* app/tools/gimpcroptool.c
	* app/tools/gimpimagemaptool.c
	* app/tools/gimpmeasuretool.c
	* app/tools/gimptransformtool.c
	* app/widgets/gimptexteditor.c
	* app/widgets/gimptooldialog.[ch]
	* app/widgets/gimpviewabledialog.[ch]
	* app/widgets/gimpwidgets-utils.c: changed accordingly and increased
	the dialogs' outer borders to 6 pixels all over the place.

	* plug-ins/*/*.c: changed accordingly. The plug-ins may be
	arbitrarily broken, I tested none of them.
2003-11-06 15:27:05 +00:00

142 lines
3.8 KiB
C

/*
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
*
* This is a plug-in for the GIMP.
*
* Colormap-Rotation plug-in. Exchanges two color ranges.
*
* Copyright (C) 1999 Sven Anders (anderss@fmi.uni-passau.de)
* Based on code from Pavel Grinfeld (pavel@ml.com)
*
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program 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 General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
/*-----------------------------------------------------------------------------------
* Change log:
*
* Version 2.0, 04 April 1999.
* Nearly complete rewrite, made plug-in stable.
* (Works with GIMP 1.1 and GTK+ 1.2)
*
* Version 1.0, 27 March 1997.
* Initial (unstable) release by Pavel Grinfeld
*
*-----------------------------------------------------------------------------------*/
/*-----------------------------------------------------------------------------------*/
/* Global defines */
/*-----------------------------------------------------------------------------------*/
#define TP (2*G_PI)
/*-----------------------------------------------------------------------------------*/
/* Typedefs */
/*-----------------------------------------------------------------------------------*/
enum { ENTIRE_IMAGE, SELECTION, SELECTION_IN_CONTEXT, PREVIEW_OPTIONS };
enum { EACH, BOTH, DEGREES, RADIANS, RADIANS_OVER_PI,
GRAY_FROM, GRAY_TO, CURRENT, ORIGINAL };
typedef enum { VIRGIN, DRAG_START, DRAGING, DO_NOTHING } RcmOp;
typedef struct
{
float alpha;
float beta;
int cw_ccw;
} RcmAngle;
typedef struct
{
gint width;
gint height;
guchar *rgb;
gdouble *hsv;
guchar *mask;
} ReducedImage;
typedef struct
{
GtkWidget *preview;
GtkWidget *frame;
GtkWidget *table;
GtkWidget *cw_ccw_button;
GtkWidget *cw_ccw_box;
GtkWidget *cw_ccw_label;
GtkWidget *cw_ccw_pixmap;
GtkWidget *a_b_button;
GtkWidget *a_b_box;
GtkWidget *a_b_pixmap;
GtkWidget *f360_button;
GtkWidget *f360_box;
GtkWidget *f360_pixmap;
GtkWidget *alpha_entry;
GtkWidget *alpha_units_label;
GtkWidget *beta_entry;
GtkWidget *beta_units_label;
gfloat *target;
gint mode;
RcmAngle *angle;
RcmOp action_flag;
gfloat prev_clicked;
} RcmCircle;
typedef struct
{
GtkWidget *dlg;
GtkWidget *bna_frame;
GtkWidget *before;
GtkWidget *after;
} RcmBna;
typedef struct
{
GtkWidget *preview;
GtkWidget *frame;
float gray_sat;
float hue;
float satur;
GtkWidget *gray_sat_entry;
GtkWidget *hue_entry;
GtkWidget *hue_units_label;
GtkWidget *satur_entry;
RcmOp action_flag;
} RcmGray;
typedef struct
{
gint Slctn;
gint RealTime;
gint Units;
gint Gray_to_from;
GimpDrawable *drawable;
GimpDrawable *mask;
ReducedImage *reduced;
RcmCircle *To;
RcmCircle *From;
RcmGray *Gray;
RcmBna *Bna;
} RcmParams;
/*-----------------------------------------------------------------------------------*/
/* Global variables */
/*-----------------------------------------------------------------------------------*/
extern RcmParams Current;
/*-----------------------------------------------------------------------------------*/