Commit ba647d5e authored by Sven Neumann's avatar Sven Neumann Committed by Sven Neumann
Browse files

plug-ins/FractalExplorer/Dialogs.c plug-ins/common/film.c adapt to libgimp

2003-06-19  Sven Neumann  <sven@gimp.org>

	* plug-ins/FractalExplorer/Dialogs.c
	* plug-ins/common/film.c
	* plug-ins/script-fu/script-fu-scripts.c: adapt to libgimp API
	changes.
parent 9768e4be
2003-06-19 Sven Neumann <sven@gimp.org>
* plug-ins/FractalExplorer/Dialogs.c
* plug-ins/common/film.c
* plug-ins/script-fu/script-fu-scripts.c: adapt to libgimp API
changes.
2003-06-19 Hans Breuer <hans@breuer.org>
 
* makefile.msc : replace the win9x specific cd ....
......@@ -207,10 +207,12 @@ explorer_number_of_colors_callback (GtkAdjustment *adjustment,
g_free (gradient_samples);
if (gradient_name == NULL)
if (! gradient_name)
gradient_name = gimp_gradients_get_gradient ();
gimp_gradients_get_gradient_data (gradient_name, wvals.ncolors, &dummy,
gimp_gradients_get_gradient_data (gradient_name,
wvals.ncolors,
&dummy,
&gradient_samples);
set_cmap_preview ();
......@@ -218,10 +220,10 @@ explorer_number_of_colors_callback (GtkAdjustment *adjustment,
}
static void
explorer_gradient_select_callback (gchar *name,
explorer_gradient_select_callback (const gchar *name,
gint width,
gdouble *gradient_data,
gint dialog_closing,
const gdouble *gradient_data,
gboolean dialog_closing,
gpointer data)
{
gint dummy;
......@@ -231,7 +233,9 @@ explorer_gradient_select_callback (gchar *name,
gradient_name = g_strdup (name);
gimp_gradients_get_gradient_data (gradient_name, wvals.ncolors, &dummy,
gimp_gradients_get_gradient_data (gradient_name,
wvals.ncolors,
&dummy,
&gradient_samples);
if (wvals.colormode == 1)
......
......@@ -81,7 +81,7 @@ typedef struct
GtkObject *advanced_adj[7];
GtkTreeModel *image_list_all;
GtkTreeModel *image_list_film;
gint run;
gboolean run;
} FilmInterface;
......@@ -156,12 +156,12 @@ static GtkTreeModel * add_image_list (gboolean add_box_flag,
gint32 *image_id,
GtkWidget *hbox);
static gint film_dialog (gint32 image_ID);
static gboolean film_dialog (gint32 image_ID);
static void film_ok_callback (GtkWidget *widget,
gpointer data);
static void film_reset_callback (GtkWidget *widget,
gpointer data);
static void film_font_select_callback (gchar *name,
static void film_font_select_callback (const gchar *name,
gboolean closing,
gpointer data);
......@@ -1476,7 +1476,7 @@ create_advanced_tab (GtkWidget *notebook)
NULL);
}
static gint
static gboolean
film_dialog (gint32 image_ID)
{
GtkWidget *dlg;
......@@ -1518,7 +1518,6 @@ film_dialog (gint32 image_ID)
gtk_widget_show (dlg);
gtk_main ();
gdk_flush ();
return filmint.run;
}
......@@ -1565,7 +1564,7 @@ film_reset_callback (GtkWidget *widget,
}
static void
film_font_select_callback (gchar *name,
film_font_select_callback (const gchar *name,
gboolean closing,
gpointer data)
{
......
......@@ -54,11 +54,11 @@
typedef struct
{
GtkAdjustment *adj;
gfloat value;
gfloat lower;
gfloat upper;
gfloat step;
gfloat page;
gdouble value;
gdouble lower;
gdouble upper;
gdouble step;
gdouble page;
gint digits;
SFAdjustmentType type;
} SFAdjustment;
......@@ -74,7 +74,7 @@ typedef struct
gchar *name;
gdouble opacity;
gint spacing;
gint paint_mode;
GimpLayerModeEffects paint_mode;
} SFBrush;
typedef struct
......@@ -172,28 +172,28 @@ static void script_fu_menu_callback (gint32 id,
static void script_fu_file_selection_callback (GtkWidget *widget,
gpointer data);
static void script_fu_pattern_preview (gchar *name,
static void script_fu_pattern_preview (const gchar *name,
gint width,
gint height,
gint bytes,
gchar *mask_data,
const guchar *mask_data,
gboolean closing,
gpointer data);
static void script_fu_gradient_preview (gchar *name,
static void script_fu_gradient_preview (const gchar *name,
gint width,
gdouble *mask_data,
const gdouble *mask_data,
gboolean closing,
gpointer data);
static void script_fu_font_preview (gchar *name,
static void script_fu_font_preview (const gchar *name,
gboolean closing,
gpointer data);
static void script_fu_brush_preview (gchar *name,
static void script_fu_brush_preview (const gchar *name,
gdouble opacity,
gint spacing,
gint paint_mode,
GimpLayerModeEffects paint_mode,
gint width,
gint height,
gchar *mask_data,
const guchar *mask_data,
gboolean closing,
gpointer data);
......@@ -1184,13 +1184,15 @@ script_fu_interface (SFScript *script)
for (i = start_args; i < script->num_args; i++)
{
/* we add a colon after the label;
some languages want an extra space here */
gchar *label_text =
g_strdup_printf (_("%s:"), gettext (script->arg_labels[i]));
gchar *label_text;
gfloat label_yalign = 0.5;
gboolean widget_leftalign = TRUE;
/* we add a colon after the label;
some languages want an extra space here */
label_text = g_strdup_printf (_("%s:"),
gettext (script->arg_labels[i]));
switch (script->arg_types[i])
{
case SF_IMAGE:
......@@ -1476,11 +1478,11 @@ script_fu_interface_quit (SFScript *script)
}
static void
script_fu_pattern_preview (gchar *name,
script_fu_pattern_preview (const gchar *name,
gint width,
gint height,
gint bytes,
gchar *mask_data,
const guchar *mask_data,
gboolean closing,
gpointer data)
{
......@@ -1493,9 +1495,9 @@ script_fu_pattern_preview (gchar *name,
}
static void
script_fu_gradient_preview (gchar *name,
script_fu_gradient_preview (const gchar *name,
gint width,
gdouble *mask_data,
const gdouble *mask_data,
gboolean closing,
gpointer data)
{
......@@ -1508,7 +1510,7 @@ script_fu_gradient_preview (gchar *name,
}
static void
script_fu_font_preview (gchar *name,
script_fu_font_preview (const gchar *name,
gboolean closing,
gpointer data)
{
......@@ -1521,13 +1523,13 @@ script_fu_font_preview (gchar *name,
}
static void
script_fu_brush_preview (gchar *name,
script_fu_brush_preview (const gchar *name,
gdouble opacity,
gint spacing,
gint paint_mode,
GimpLayerModeEffects paint_mode,
gint width,
gint height,
gchar *mask_data,
const guchar *mask_data,
gboolean closing,
gpointer data)
{
......
......@@ -54,11 +54,11 @@
typedef struct
{
GtkAdjustment *adj;
gfloat value;
gfloat lower;
gfloat upper;
gfloat step;
gfloat page;
gdouble value;
gdouble lower;
gdouble upper;
gdouble step;
gdouble page;
gint digits;
SFAdjustmentType type;
} SFAdjustment;
......@@ -74,7 +74,7 @@ typedef struct
gchar *name;
gdouble opacity;
gint spacing;
gint paint_mode;
GimpLayerModeEffects paint_mode;
} SFBrush;
typedef struct
......@@ -172,28 +172,28 @@ static void script_fu_menu_callback (gint32 id,
static void script_fu_file_selection_callback (GtkWidget *widget,
gpointer data);
static void script_fu_pattern_preview (gchar *name,
static void script_fu_pattern_preview (const gchar *name,
gint width,
gint height,
gint bytes,
gchar *mask_data,
const guchar *mask_data,
gboolean closing,
gpointer data);
static void script_fu_gradient_preview (gchar *name,
static void script_fu_gradient_preview (const gchar *name,
gint width,
gdouble *mask_data,
const gdouble *mask_data,
gboolean closing,
gpointer data);
static void script_fu_font_preview (gchar *name,
static void script_fu_font_preview (const gchar *name,
gboolean closing,
gpointer data);
static void script_fu_brush_preview (gchar *name,
static void script_fu_brush_preview (const gchar *name,
gdouble opacity,
gint spacing,
gint paint_mode,
GimpLayerModeEffects paint_mode,
gint width,
gint height,
gchar *mask_data,
const guchar *mask_data,
gboolean closing,
gpointer data);
......@@ -1184,13 +1184,15 @@ script_fu_interface (SFScript *script)
for (i = start_args; i < script->num_args; i++)
{
/* we add a colon after the label;
some languages want an extra space here */
gchar *label_text =
g_strdup_printf (_("%s:"), gettext (script->arg_labels[i]));
gchar *label_text;
gfloat label_yalign = 0.5;
gboolean widget_leftalign = TRUE;
/* we add a colon after the label;
some languages want an extra space here */
label_text = g_strdup_printf (_("%s:"),
gettext (script->arg_labels[i]));
switch (script->arg_types[i])
{
case SF_IMAGE:
......@@ -1476,11 +1478,11 @@ script_fu_interface_quit (SFScript *script)
}
static void
script_fu_pattern_preview (gchar *name,
script_fu_pattern_preview (const gchar *name,
gint width,
gint height,
gint bytes,
gchar *mask_data,
const guchar *mask_data,
gboolean closing,
gpointer data)
{
......@@ -1493,9 +1495,9 @@ script_fu_pattern_preview (gchar *name,
}
static void
script_fu_gradient_preview (gchar *name,
script_fu_gradient_preview (const gchar *name,
gint width,
gdouble *mask_data,
const gdouble *mask_data,
gboolean closing,
gpointer data)
{
......@@ -1508,7 +1510,7 @@ script_fu_gradient_preview (gchar *name,
}
static void
script_fu_font_preview (gchar *name,
script_fu_font_preview (const gchar *name,
gboolean closing,
gpointer data)
{
......@@ -1521,13 +1523,13 @@ script_fu_font_preview (gchar *name,
}
static void
script_fu_brush_preview (gchar *name,
script_fu_brush_preview (const gchar *name,
gdouble opacity,
gint spacing,
gint paint_mode,
GimpLayerModeEffects paint_mode,
gint width,
gint height,
gchar *mask_data,
const guchar *mask_data,
gboolean closing,
gpointer data)
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment