plug-ins/common/waves.c plug-ins/common/whirlpinch.c

2000-01-16  Shirasaki Yasuhiro  <yasuhiro@gnome.gr.jp>

	* plug-ins/common/waves.c
	* plug-ins/common/whirlpinch.c
	* plug-ins/common/wind.c
	* plug-ins/common/wmf.c
	* plug-ins/pagecurl/pagecurl.c
	* plug-ins/pagecurl/Makefile.am
	* po-plug-ins/POTFILES.in: added gettext support.

-- yasuhiro
This commit is contained in:
Shirasaki Yasuhiro
2000-01-15 17:22:19 +00:00
committed by SHIRASAKI Yasuhiro
parent 53b9cb5227
commit 72ae425bfc
8 changed files with 131 additions and 97 deletions

View File

@ -1,3 +1,13 @@
2000-01-16 Shirasaki Yasuhiro <yasuhiro@gnome.gr.jp>
* plug-ins/common/waves.c
* plug-ins/common/whirlpinch.c
* plug-ins/common/wind.c
* plug-ins/common/wmf.c
* plug-ins/pagecurl/pagecurl.c
* plug-ins/pagecurl/Makefile.am
* po-plug-ins/POTFILES.in: added gettext support.
2000-01-15 Garry R. Osgood <gosgood@idt.net>
* app/layers_dialog.c

View File

@ -34,6 +34,7 @@
#include <libgimp/gimp.h>
#include <libgimp/gimpui.h>
#include "libgimp/stdplugins-intl.h"
#include <plug-ins/megawidget/megawidget.h>
@ -128,13 +129,15 @@ query (void)
static GParamDef *rets = NULL;
static int nrets = 0;
INIT_I18N();
gimp_install_procedure ("plug_in_waves",
"Distort the image with waves",
_("Distort the image with waves"),
"none yet",
"Eric L. Hernes, Stephen Norris",
"Stephen Norris",
"1997",
"<Image>/Filters/Distorts/Waves...",
N_("<Image>/Filters/Distorts/Waves..."),
"RGB*, GRAY*",
PROC_PLUG_IN,
nargs, nrets,
@ -166,6 +169,7 @@ run (gchar *name,
GDrawable *drw;
case RUN_INTERACTIVE:
INIT_I18N_UI();
/* XXX: add code here for interactive running */
if (args.type == -1)
{
@ -191,6 +195,7 @@ run (gchar *name,
break;
case RUN_NONINTERACTIVE:
INIT_I18N();
/* XXX: add code here for non-interactive running */
if (nparam != 8)
{
@ -211,6 +216,7 @@ run (gchar *name,
break;
case RUN_WITH_LAST_VALS:
INIT_I18N();
/* XXX: add code here for last-values running */
if (pluginCore (&args, param[2].data.d_drawable) == -1)
{
@ -322,14 +328,14 @@ pluginCoreIA (struct piArgs *argp,
gtk_init (&argc, &argv);
gtk_rc_parse (gimp_gtkrc ());
dlg = gimp_dialog_new ("Waves", "waves",
dlg = gimp_dialog_new ( _("Waves"), "waves",
gimp_plugin_help_func, "filters/waves.html",
GTK_WIN_POS_MOUSE,
FALSE, TRUE, FALSE,
"OK", waves_ok_callback,
_("OK"), waves_ok_callback,
NULL, NULL, NULL, TRUE, FALSE,
"Cancel", gtk_widget_destroy,
_("Cancel"), gtk_widget_destroy,
NULL, 1, NULL, FALSE, TRUE,
NULL);
@ -351,7 +357,7 @@ pluginCoreIA (struct piArgs *argp,
gtk_object_set_data (GTK_OBJECT (preview), "piArgs", argp);
waves_do_preview (preview);
toggle = gtk_check_button_new_with_label ("Reflective");
toggle = gtk_check_button_new_with_label ( _("Reflective"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (toggle), argp->reflective);
gtk_box_pack_start (GTK_BOX (vbox), toggle, FALSE, FALSE, 0);
gtk_signal_connect (GTK_OBJECT (toggle), "toggled",
@ -363,7 +369,7 @@ pluginCoreIA (struct piArgs *argp,
gtk_box_pack_start (GTK_BOX (hbox), vbox, TRUE, TRUE, 0);
gtk_widget_show (vbox);
frame = gtk_frame_new ("Parameters");
frame = gtk_frame_new ( _("Parameters"));
gtk_frame_set_shadow_type (GTK_FRAME (frame), GTK_SHADOW_ETCHED_IN);
gtk_box_pack_start (GTK_BOX (vbox), frame, FALSE, FALSE, 0);
gtk_widget_show (frame);
@ -375,7 +381,7 @@ pluginCoreIA (struct piArgs *argp,
gtk_container_add (GTK_CONTAINER (frame), table);
adj = gimp_scale_entry_new (GTK_TABLE (table), 0, 0,
"Amplitude:", 140, 0,
_("Amplitude:"), 140, 0,
argp->amplitude, 0.0, 101.0, 1.0, 5.0, 2,
NULL, NULL);
gtk_signal_connect (GTK_OBJECT (adj), "value_changed",
@ -383,7 +389,7 @@ pluginCoreIA (struct piArgs *argp,
&argp->amplitude);
adj = gimp_scale_entry_new (GTK_TABLE (table), 0, 1,
"Phase:", 140, 0,
_("Phase:"), 140, 0,
argp->phase, 0.0, 360.0, 2.0, 5.0, 2,
NULL, NULL);
gtk_signal_connect (GTK_OBJECT (adj), "value_changed",
@ -391,7 +397,7 @@ pluginCoreIA (struct piArgs *argp,
&argp->phase);
adj = gimp_scale_entry_new (GTK_TABLE (table), 0, 2,
"Wavelength:", 140, 0,
_("Wavelength:"), 140, 0,
argp->wavelength, 0.1, 50.0, 1.0, 5.0, 2,
NULL, NULL);
gtk_signal_connect (GTK_OBJECT (adj), "value_changed",
@ -400,12 +406,12 @@ pluginCoreIA (struct piArgs *argp,
gtk_widget_show (table);
frame = gimp_radio_group_new2 (TRUE, "Mode",
frame = gimp_radio_group_new2 (TRUE, _("Mode"),
waves_radio_button_update,
&argp->type, (gpointer) argp->type,
"Smear", (gpointer) MODE_SMEAR, NULL,
"Blacken", (gpointer) MODE_BLACKEN, NULL,
_("Smear"), (gpointer) MODE_SMEAR, NULL,
_("Blacken"), (gpointer) MODE_BLACKEN, NULL,
NULL);
@ -511,7 +517,7 @@ wave (guchar *src,
if (verbose)
{
gimp_progress_init ("Waves");
gimp_progress_init ( _("Waving..."));
prog_interval=height/10;
}

View File

@ -59,6 +59,7 @@
#include <libgimp/gimp.h>
#include <libgimp/gimpui.h>
#include <libgimp/gimplimits.h>
#include "libgimp/stdplugins-intl.h"
#define PLUG_IN_NAME "plug_in_whirl_pinch"
#define PLUG_IN_VERSION "May 1997, 2.09"
@ -192,17 +193,15 @@ query (void)
static int nargs = sizeof(args) / sizeof(args[0]);
static int nreturn_vals = 0;
INIT_I18N();
gimp_install_procedure (PLUG_IN_NAME,
"Distort an image by whirling and pinching",
"Distorts the image by whirling and pinching, which are two common "
"center-based, circular distortions. Whirling is like projecting "
"the image onto the surface of water in a toilet and flushing. "
"Pinching is similar to projecting the image onto an elastic surface "
"and pressing or pulling on the center of the surface.",
_("Distort an image by whirling and pinching"),
_("Distorts the image by whirling and pinching, which are two common center-based, circular distortions. Whirling is like projecting the image onto the surface of water in a toilet and flushing. Pinching is similar to projecting the image onto an elastic surface and pressing or pulling on the center of the surface."),
"Federico Mena Quintero and Scott Goehring",
"Federico Mena Quintero and Scott Goehring",
PLUG_IN_VERSION,
"<Image>/Filters/Distorts/Whirl and Pinch...",
N_("<Image>/Filters/Distorts/Whirl and Pinch..."),
"RGB*, GRAY*",
PROC_PLUG_IN,
nargs,
@ -294,6 +293,7 @@ run (gchar *name,
switch (run_mode)
{
case RUN_INTERACTIVE:
INIT_I18N_UI();
/* Possibly retrieve data */
gimp_get_data (PLUG_IN_NAME, &wpvals);
@ -304,6 +304,7 @@ run (gchar *name,
break;
case RUN_NONINTERACTIVE:
INIT_I18N();
/* Make sure all the arguments are present */
if (nparams != 6)
status = STATUS_CALLING_ERROR;
@ -318,6 +319,7 @@ run (gchar *name,
break;
case RUN_WITH_LAST_VALS:
INIT_I18N();
/* Possibly retrieve data */
gimp_get_data (PLUG_IN_NAME, &wpvals);
break;
@ -402,7 +404,7 @@ whirl_pinch (void)
progress = 0;
max_progress = sel_width * sel_height;
gimp_progress_init ("Whirling and pinching...");
gimp_progress_init ( _("Whirling and pinching..."));
whirl = wpvals.whirl * G_PI / 180;
radius2 = radius * radius * wpvals.radius;
@ -823,14 +825,14 @@ whirl_pinch_dialog (void)
build_preview_source_image ();
dialog = gimp_dialog_new ("Whirl and Pinch", "whirlpinch",
dialog = gimp_dialog_new ( _("Whirl and Pinch"), "whirlpinch",
gimp_plugin_help_func, "filters/whirlpinch.html",
GTK_WIN_POS_MOUSE,
FALSE, TRUE, FALSE,
"OK", dialog_ok_callback,
_("OK"), dialog_ok_callback,
NULL, NULL, NULL, TRUE, FALSE,
"Cancel", gtk_widget_destroy,
_("Cancel"), gtk_widget_destroy,
NULL, 1, NULL, FALSE, TRUE,
NULL);
@ -868,7 +870,7 @@ whirl_pinch_dialog (void)
gtk_widget_show (table);
adj = gimp_scale_entry_new (GTK_TABLE (table), 0, 0,
"Whirl Angle:", SCALE_WIDTH, 0,
_("Whirl Angle:"), SCALE_WIDTH, 0,
wpvals.whirl, -360.0, 360.0, 1.0, 15.0, 2,
NULL, NULL);
gtk_signal_connect (GTK_OBJECT (adj), "value_changed",
@ -876,7 +878,7 @@ whirl_pinch_dialog (void)
&wpvals.whirl);
adj = gimp_scale_entry_new (GTK_TABLE (table), 0, 1,
"Pinch Amount:", SCALE_WIDTH, 0,
_("Pinch Amount:"), SCALE_WIDTH, 0,
wpvals.pinch, -1.0, 1.0, 0.01, 0.1, 3,
NULL, NULL);
gtk_signal_connect (GTK_OBJECT (adj), "value_changed",
@ -884,7 +886,7 @@ whirl_pinch_dialog (void)
&wpvals.pinch);
adj = gimp_scale_entry_new (GTK_TABLE (table), 0, 2,
"Radius:", SCALE_WIDTH, 0,
_("Radius:"), SCALE_WIDTH, 0,
wpvals.radius, 0.0, 2.0, 0.01, 0.1, 3,
NULL, NULL);
gtk_signal_connect (GTK_OBJECT (adj), "value_changed",

View File

@ -25,10 +25,12 @@
#include <stdio.h>
#include <stdlib.h>
#include "config.h"
#include <gtk/gtk.h>
#include <libgimp/gimp.h>
#include <libgimp/gimpui.h>
#include "libgimp/stdplugins-intl.h"
#define PLUG_IN_NAME "wind"
@ -41,17 +43,6 @@
#define MIN_STRENGTH 1
#define MAX_STRENGTH 50
#define NEGATIVE_STRENGTH_TEXT "\n Wind Strength must be greater than 0. \n"
#define THRESHOLD_TEXT "Higher values restrict the effect to fewer areas of the image"
#define STRENGTH_TEXT "Higher values increase the magnitude of the effect"
#define WIND_TEXT "A fine grained algorithm"
#define BLAST_TEXT "A coarse grained algorithm"
#define LEFT_TEXT "Makes the wind come from the left"
#define RIGHT_TEXT "Makes the wind come from the right"
#define LEADING_TEXT "The effect is applied at the leading edge of objects"
#define TRAILING_TEXT "The effect is applied at the trailing edge of objects"
#define BOTH_TEXT "The effect is applied at both edges of objects"
typedef enum
{
LEFT,
@ -161,13 +152,15 @@ query (void)
static int nargs = sizeof(args) / sizeof(args[0]);
static int nreturn_vals = 0;
INIT_I18N();
gimp_install_procedure ("plug_in_wind",
"Renders a wind effect.",
"Renders a wind effect.",
_("Renders a wind effect."),
_("Renders a wind effect."),
"Nigel Wetten",
"Nigel Wetten",
"1998",
"<Image>/Filters/Distorts/Wind...",
N_("<Image>/Filters/Distorts/Wind..."),
"RGB*",
PROC_PLUG_IN,
nargs, nreturn_vals,
@ -192,6 +185,7 @@ run (gchar *name,
switch (run_mode)
{
case RUN_NONINTERACTIVE:
INIT_I18N();
if (nparams == 8)
{
config.threshold = param[3].data.d_int32;
@ -211,6 +205,7 @@ run (gchar *name,
break;
case RUN_INTERACTIVE:
INIT_I18N_UI();
gimp_get_data("plug_in_wind", &config);
dialog_box();
if (dialog_result == -1)
@ -228,6 +223,7 @@ run (gchar *name,
break;
case RUN_WITH_LAST_VALS:
INIT_I18N();
gimp_get_data("plug_in_wind", &config);
if (render_effect(drawable) == -1)
{
@ -255,13 +251,13 @@ render_effect (GDrawable *drawable)
{
if (config.alg == RENDER_WIND)
{
gimp_progress_init("Rendering Wind...");
gimp_progress_init( _("Rendering Wind..."));
render_wind(drawable, config.threshold, config. strength,
config.direction, config.edge);
}
else if (config.alg == RENDER_BLAST)
{
gimp_progress_init("Rendering Blast...");
gimp_progress_init( _("Rendering Blast..."));
render_blast(drawable, config.threshold, config.strength,
config.direction, config.edge);
}
@ -674,12 +670,12 @@ modal_message_box (gchar *text)
GtkWidget *message_box;
GtkWidget *label;
message_box = gimp_dialog_new ("Wind", "wind",
message_box = gimp_dialog_new ( _("Wind"), "wind",
gimp_plugin_help_func, "filters/wind.html",
GTK_WIN_POS_MOUSE,
FALSE, TRUE, FALSE,
"OK", msg_ok_callback,
_("OK"), msg_ok_callback,
NULL, NULL, NULL, TRUE, TRUE,
NULL);
@ -702,7 +698,7 @@ ok_callback (GtkWidget *widget,
if (config.strength < 1)
{
modal_message_box (NEGATIVE_STRENGTH_TEXT);
modal_message_box ( _("\n Wind Strength must be greater than 0. \n"));
}
else
{
@ -729,14 +725,14 @@ dialog_box (void)
gtk_init (&argc, &argv);
gtk_rc_parse (gimp_gtkrc ());
dlg = gimp_dialog_new ("Wind", "wind",
dlg = gimp_dialog_new ( _("Wind"), "wind",
gimp_plugin_help_func, "filters/wind.html",
GTK_WIN_POS_MOUSE,
FALSE, TRUE, FALSE,
"OK", ok_callback,
_("OK"), ok_callback,
NULL, NULL, NULL, TRUE, FALSE,
"Cancel", gtk_widget_destroy,
_("Cancel"), gtk_widget_destroy,
NULL, 1, NULL, FALSE, TRUE,
NULL);
@ -771,10 +767,10 @@ dialog_box (void)
***************************************************/
adj = gimp_scale_entry_new (GTK_TABLE (table), 0, 0,
"Threshold:", SCALE_WIDTH, 0,
_("Threshold:"), SCALE_WIDTH, 0,
config.threshold,
MIN_THRESHOLD, MAX_THRESHOLD, 1.0, 10, 0,
THRESHOLD_TEXT, NULL);
_("Higher values restrict the effect to fewer areas of the image"), NULL);
gtk_signal_connect (GTK_OBJECT (adj), "value_changed",
GTK_SIGNAL_FUNC (gimp_int_adjustment_update),
&config.threshold);
@ -784,10 +780,10 @@ dialog_box (void)
****************************************************/
adj = gimp_scale_entry_new (GTK_TABLE (table), 0, 1,
"Strength:", SCALE_WIDTH, 0,
_("Strength:"), SCALE_WIDTH, 0,
config.strength,
MIN_STRENGTH, MAX_STRENGTH, 1.0, 10.0, 0,
STRENGTH_TEXT, NULL);
_("Higher values increase the magnitude of the effect"), NULL);
gtk_signal_connect (GTK_OBJECT (adj), "value_changed",
GTK_SIGNAL_FUNC (gimp_int_adjustment_update),
&config.strength);
@ -807,12 +803,12 @@ dialog_box (void)
radio buttons for choosing wind rendering algorithm
******************************************************/
frame = gimp_radio_group_new2 (TRUE, "Style",
frame = gimp_radio_group_new2 (TRUE, _("Style"),
gimp_radio_button_update,
&config.alg, (gpointer) config.alg,
"Wind", (gpointer) RENDER_WIND, NULL,
"Blast", (gpointer) RENDER_BLAST, NULL,
_("Wind"), (gpointer) RENDER_WIND, NULL,
_("Blast"), (gpointer) RENDER_BLAST, NULL,
NULL);
@ -824,12 +820,12 @@ dialog_box (void)
radio buttons for choosing LEFT or RIGHT
**************************************************/
frame = gimp_radio_group_new2 (TRUE, "Direction",
frame = gimp_radio_group_new2 (TRUE, _("Direction"),
gimp_radio_button_update,
&config.direction, (gpointer) config.direction,
"Left", (gpointer) LEFT, NULL,
"Right", (gpointer) RIGHT, NULL,
_("Left"), (gpointer) LEFT, NULL,
_("Right"), (gpointer) RIGHT, NULL,
NULL);
@ -841,13 +837,13 @@ dialog_box (void)
radio buttons for choosing BOTH, LEADING, TRAILING
***************************************************/
frame = gimp_radio_group_new2 (TRUE, "Edge Affected",
frame = gimp_radio_group_new2 (TRUE, _("Edge Affected"),
gimp_radio_button_update,
&config.edge, (gpointer) config.edge,
"Leading", (gpointer) LEADING, NULL,
"Trailing", (gpointer) TRAILING, NULL,
"Both", (gpointer) BOTH, NULL,
_("Leading"), (gpointer) LEADING, NULL,
_("Trailing"), (gpointer) TRAILING, NULL,
_("Both"), (gpointer) BOTH, NULL,
NULL);

View File

@ -26,10 +26,13 @@
#include <stdlib.h>
#include <string.h>
#include "config.h"
#include <gtk/gtk.h>
#include <libgimp/gimp.h>
#include <libgimp/gimpui.h>
#include "libgimp/stdplugins-intl.h"
typedef guchar BYTE;
typedef guint16 WORD;
@ -926,14 +929,14 @@ load_dialog (char *file_name)
vals = g_new (LoadDialogVals, 1);
vals->dialog = gimp_dialog_new ("Load Windows Metafile", "wmf",
vals->dialog = gimp_dialog_new ( _("Load Windows Metafile"), "wmf",
gimp_plugin_help_func, "filters/wmf.html",
GTK_WIN_POS_MOUSE,
FALSE, TRUE, FALSE,
"OK", load_ok_callback,
_("OK"), load_ok_callback,
vals, NULL, NULL, TRUE, FALSE,
"Cancel", gtk_widget_destroy,
_("Cancel"), gtk_widget_destroy,
NULL, 1, NULL, FALSE, TRUE,
NULL);
@ -943,7 +946,7 @@ load_dialog (char *file_name)
NULL);
/* Rendering */
frame = gtk_frame_new (g_strdup_printf ("Rendering %s", file_name));
frame = gtk_frame_new (g_strdup_printf ( _("Rendering %s"), file_name));
gtk_container_set_border_width (GTK_CONTAINER (frame), 6);
gtk_frame_set_shadow_type (GTK_FRAME (frame), GTK_SHADOW_ETCHED_IN);
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (vals->dialog)->vbox), frame,
@ -960,7 +963,7 @@ load_dialog (char *file_name)
gtk_box_pack_start (GTK_BOX (vbox), table, FALSE, FALSE, 0);
gtk_widget_show (table);
label = gtk_label_new ("Scale (log 2):");
label = gtk_label_new ( _("Scale (log 2):"));
gtk_misc_set_alignment (GTK_MISC (label), 1.0, 1.0);
gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1,
GTK_FILL, GTK_FILL, 0, 0);
@ -1020,8 +1023,10 @@ query ()
};
static int nload_setargs_args = sizeof (load_setargs_args) / sizeof (load_setargs_args[0]);
INIT_I18N();
gimp_install_procedure ("file_wmf_load",
"loads files of the Windows(tm) metafile file format",
_("loads files of the Windows(tm) metafile file format"),
"FIXME: write help for file_wmf_load",
"Tor Lillqvist <tml@iki.fi>",
"Tor Lillqvist",
@ -1033,8 +1038,8 @@ query ()
load_args, load_return_vals);
gimp_install_procedure ("file_wmf_load_setargs",
"set additional parameters for the procedure file_wmf_load",
"set additional parameters for the procedure file_wmf_load",
_("set additional parameters for the procedure file_wmf_load"),
_("set additional parameters for the procedure file_wmf_load"),
"Tor Lillqvist <tml@iki.fi>",
"Tor Lillqvist",
"1998",
@ -1069,6 +1074,7 @@ run (char *name,
switch (l_run_mode)
{
case RUN_INTERACTIVE:
INIT_I18N_UI();
gimp_get_data ("file_wmf_load", &load_vals);
if (!load_dialog (param[1].data.d_string))
@ -1076,10 +1082,12 @@ run (char *name,
break;
case RUN_NONINTERACTIVE:
INIT_I18N();
gimp_get_data ("file_wmf_load", &load_vals);
break;
case RUN_WITH_LAST_VALS:
INIT_I18N();
gimp_get_data ("file_wmf_load", &load_vals);
}
@ -2327,15 +2335,14 @@ load_image (char *filename)
if (canvas->height >= 100)
{
name_buf = g_malloc (strlen (filename) + 100);
sprintf (name_buf, "Transferring image");
g_strdup_printf (name_buf, _("Transferring image"));
gimp_progress_init (name_buf);
g_free (name_buf);
}
image_ID = gimp_image_new (canvas->width, canvas->height, RGB);
gimp_image_set_filename (image_ID, filename);
layer_ID = gimp_layer_new (image_ID, "Background",
layer_ID = gimp_layer_new (image_ID, _("Background"),
canvas->width, canvas->height, RGB_IMAGE,
100, NORMAL_MODE);
gimp_image_add_layer (image_ID, layer_ID, 0);

View File

@ -15,6 +15,9 @@ pagecurl_SOURCES = \
curl6.xpm \
curl7.xpm
AM_CPPFLAGS = \
-DLOCALEDIR=\""$(localedir)"\"
INCLUDES = \
-I$(top_srcdir) \
$(GTK_CFLAGS) \

View File

@ -57,6 +57,7 @@
#include <libgimp/gimp.h>
#include <libgimp/gimpui.h>
#include "libgimp/stdplugins-intl.h"
#include "curl0.xpm"
#include "curl1.xpm"
@ -220,13 +221,15 @@ query (void)
static int nargs = sizeof (args) / sizeof (args[0]);
static int nreturn_vals = sizeof (return_vals) / sizeof (return_vals[0]);
INIT_I18N();
gimp_install_procedure (PLUG_IN_NAME,
"Pagecurl effect",
"This plug-in creates a pagecurl-effect.",
_("Pagecurl effect"),
_("This plug-in creates a pagecurl-effect."),
"Federico Mena Quintero and Simon Budig",
"Federico Mena Quintero and Simon Budig",
PLUG_IN_VERSION,
"<Image>/Filters/Distorts/Pagecurl...",
N_("<Image>/Filters/Distorts/Pagecurl..."),
"RGBA, GRAYA",
PROC_PLUG_IN,
nargs,
@ -272,12 +275,14 @@ run (gchar *name,
switch (run_mode)
{
case RUN_INTERACTIVE:
INIT_I18N_UI();
/* First acquire information with a dialog */
if (!do_dialog ())
return;
break;
case RUN_NONINTERACTIVE:
INIT_I18N();
/* Make sure all the arguments are there! */
if (nparams != 7)
status = STATUS_CALLING_ERROR;
@ -321,6 +326,7 @@ run (gchar *name,
break;
case RUN_WITH_LAST_VALS:
INIT_I18N();
break;
default:
@ -573,14 +579,14 @@ do_dialog (void)
gtk_rc_parse (gimp_gtkrc ());
gdk_set_use_xshm (gimp_use_xshm ());
dialog = gimp_dialog_new ("Pagecurl Effect", "pagecurl",
dialog = gimp_dialog_new ( _("Pagecurl Effect"), "pagecurl",
gimp_plugin_help_func, "filters/pagecurl.html",
GTK_WIN_POS_MOUSE,
FALSE, TRUE, FALSE,
"OK", dialog_ok_callback,
_("OK"), dialog_ok_callback,
NULL, NULL, NULL, TRUE, FALSE,
"Cancel", gtk_widget_destroy,
_("Cancel"), gtk_widget_destroy,
NULL, 1, NULL, FALSE, TRUE,
NULL);
@ -651,7 +657,7 @@ do_dialog (void)
FALSE, FALSE, 0);
gtk_widget_show (curl_pixmap_widget);
corner_frame = gtk_frame_new ("Curl Location");
corner_frame = gtk_frame_new ( _("Curl Location"));
gtk_frame_set_shadow_type (GTK_FRAME (corner_frame), GTK_SHADOW_ETCHED_IN);
gtk_box_pack_start (GTK_BOX (orhbox1), corner_frame, TRUE, TRUE, 0);
@ -662,10 +668,10 @@ do_dialog (void)
{
gint i;
gchar *name[] =
{ "Upper Left",
"Upper Right",
"Lower Left",
"Lower Right"
{ N_("Upper Left"),
N_("Upper Right"),
N_("Lower Left"),
N_("Lower Right")
};
button = NULL;
@ -674,7 +680,7 @@ do_dialog (void)
button = gtk_radio_button_new_with_label
((button == NULL) ?
NULL : gtk_radio_button_group (GTK_RADIO_BUTTON (button)),
name[i]);
gettext(name[i]));
gtk_toggle_button_set_active
(GTK_TOGGLE_BUTTON (button),
(i == 0 ? curl.do_upper_left : i == 1 ? curl.do_upper_right :
@ -693,7 +699,7 @@ do_dialog (void)
gtk_widget_show (corner_frame);
gtk_widget_show (orhbox1);
orient_frame = gtk_frame_new ("Curl Orientation");
orient_frame = gtk_frame_new ( _("Curl Orientation"));
gtk_frame_set_shadow_type (GTK_FRAME (orient_frame), GTK_SHADOW_ETCHED_IN);
gtk_box_pack_start (GTK_BOX (vbox), orient_frame, FALSE, FALSE, 0);
@ -705,8 +711,8 @@ do_dialog (void)
gint i;
gchar *name[] =
{
"Horizontal",
"Vertical"
N_("Horizontal"),
N_("Vertical")
};
button = NULL;
@ -715,7 +721,7 @@ do_dialog (void)
button = gtk_radio_button_new_with_label
((button == NULL) ?
NULL : gtk_radio_button_group (GTK_RADIO_BUTTON (button)),
name[i]);
gettext(name[i]));
gtk_toggle_button_set_active
(GTK_TOGGLE_BUTTON (button),
(i == 0 ? curl.do_horizontal : curl.do_vertical));
@ -732,7 +738,7 @@ do_dialog (void)
gtk_widget_show (orhbox2);
gtk_widget_show (orient_frame);
shade_button = gtk_check_button_new_with_label ("Shade under Curl");
shade_button = gtk_check_button_new_with_label ( _("Shade under Curl"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (shade_button),
curl.do_shade_under ? TRUE : FALSE);
gtk_signal_connect (GTK_OBJECT (shade_button), "toggled",
@ -742,8 +748,7 @@ do_dialog (void)
gtk_widget_show (shade_button);
gradient_button =
gtk_check_button_new_with_label ("Use Current Gradient\n"
"instead of FG/BG-Color");
gtk_check_button_new_with_label (_("Use Current Gradient\ninstead of FG/BG-Color"));
gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (gradient_button),
curl.do_curl_gradient ? TRUE : FALSE);
gtk_signal_connect (GTK_OBJECT (gradient_button), "toggled",
@ -752,7 +757,7 @@ do_dialog (void)
gtk_box_pack_start (GTK_BOX (vbox), gradient_button, FALSE, FALSE, 0);
gtk_widget_show (gradient_button);
label = gtk_label_new ("Curl Opacity");
label = gtk_label_new (_("Curl Opacity"));
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
gtk_box_pack_start (GTK_BOX (vbox), label, FALSE, FALSE, 0);
gtk_widget_show (label);
@ -874,7 +879,7 @@ do_curl_effect (void)
color_image = gimp_drawable_is_rgb (drawable->id);
curl_layer =
gimp_drawable_get (gimp_layer_new (image_id,
"Curl layer",
_("Curl layer"),
true_sel_width,
true_sel_height,
color_image ? RGBA_IMAGE : GRAYA_IMAGE,
@ -1125,7 +1130,7 @@ page_curl (void)
PARAM_IMAGE, image_id,
PARAM_END);
gimp_progress_init ("Page Curl...");
gimp_progress_init ( _("Page Curl..."));
init_calculation ();
do_curl_effect ();
clear_curled_region ();

View File

@ -123,7 +123,11 @@ plug-ins/common/video.c
plug-ins/common/vinvert.c
plug-ins/common/vpropagate.c
plug-ins/common/warp.c
plug-ins/common/waves.c
plug-ins/common/whirlpinch.c
plug-ins/common/wind.c
plug-ins/common/winprint.c
plug-ins/common/wmf.c
plug-ins/common/xbm.c
plug-ins/common/xpm.c
plug-ins/common/xwd.c
@ -219,6 +223,7 @@ plug-ins/maze/maze.c
plug-ins/maze/maze_face.c
plug-ins/megawidget/megawidget.c
plug-ins/mosaic/mosaic.c
plug-ins/pagecurl/pagecurl.c
plug-ins/print/print-escp2.c
plug-ins/print/print-pcl.c
plug-ins/print/print-ps.c