1998-06-09 05:53:45 +08:00
|
|
|
#include <stdlib.h>
|
|
|
|
#include <stdio.h>
|
|
|
|
#include "appenv.h"
|
|
|
|
#include "actionarea.h"
|
|
|
|
#include "app_procs.h"
|
|
|
|
#include "commands.h"
|
|
|
|
#include "general.h"
|
1998-06-13 03:43:55 +08:00
|
|
|
#include "gimage.h"
|
1998-06-09 05:53:45 +08:00
|
|
|
#include "gimprc.h"
|
1998-06-13 03:43:55 +08:00
|
|
|
#include "global_edit.h"
|
1998-06-09 05:53:45 +08:00
|
|
|
#include "interface.h"
|
|
|
|
#include "plug_in.h"
|
1998-06-13 03:43:55 +08:00
|
|
|
#include "tile_manager_pvt.h"
|
1998-08-16 08:34:20 +08:00
|
|
|
#include "gdisplay.h"
|
1998-06-09 05:53:45 +08:00
|
|
|
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
#include "libgimp/gimpintl.h"
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
typedef struct {
|
|
|
|
GtkWidget *dlg;
|
1998-06-14 04:57:23 +08:00
|
|
|
GtkWidget *height_spinbutton;
|
|
|
|
GtkWidget *width_spinbutton;
|
|
|
|
GtkWidget *height_units_spinbutton;
|
|
|
|
GtkWidget *width_units_spinbutton;
|
|
|
|
GtkWidget *resolution_spinbutton;
|
1998-06-09 05:53:45 +08:00
|
|
|
float resolution; /* always in dpi */
|
|
|
|
float unit; /* this is a float that is equal to unit/inch, 2.54 for cm for example */
|
1998-06-10 05:21:23 +08:00
|
|
|
float res_unit; /* same as above but for the res unit */
|
1998-06-09 05:53:45 +08:00
|
|
|
int width;
|
|
|
|
int height;
|
|
|
|
int type;
|
|
|
|
int fill_type;
|
|
|
|
} NewImageValues;
|
|
|
|
|
|
|
|
/* new image local functions */
|
|
|
|
static void file_new_ok_callback (GtkWidget *, gpointer);
|
|
|
|
static void file_new_cancel_callback (GtkWidget *, gpointer);
|
|
|
|
static gint file_new_delete_callback (GtkWidget *, GdkEvent *, gpointer);
|
|
|
|
static void file_new_toggle_callback (GtkWidget *, gpointer);
|
|
|
|
static void file_new_width_update_callback (GtkWidget *, gpointer);
|
|
|
|
static void file_new_height_update_callback (GtkWidget *, gpointer);
|
|
|
|
static void file_new_width_units_update_callback (GtkWidget *, gpointer);
|
|
|
|
static void file_new_height_units_update_callback (GtkWidget *, gpointer);
|
|
|
|
static void file_new_resolution_callback (GtkWidget *, gpointer);
|
|
|
|
static void file_new_units_inch_menu_callback (GtkWidget *, gpointer);
|
|
|
|
static void file_new_units_cm_menu_callback (GtkWidget *, gpointer);
|
1998-06-10 05:21:23 +08:00
|
|
|
static void file_new_res_units_inch_callback (GtkWidget *, gpointer);
|
|
|
|
static void file_new_res_units_cm_callback (GtkWidget *, gpointer);
|
1998-06-18 13:04:01 +08:00
|
|
|
static float file_new_default_unit_parse (int);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
/* static variables */
|
|
|
|
static int last_width = 256;
|
|
|
|
static int last_height = 256;
|
|
|
|
static int last_type = RGB;
|
|
|
|
static int last_fill_type = BACKGROUND_FILL;
|
|
|
|
static float last_resolution = 72; /* always in DPI */
|
|
|
|
static float last_unit = 1;
|
1998-06-10 05:21:23 +08:00
|
|
|
static float last_res_unit =1;
|
1998-06-13 03:43:55 +08:00
|
|
|
static gboolean last_new_image = TRUE;
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
/* these are temps that should be set in gimprc eventually */
|
1998-06-10 05:21:23 +08:00
|
|
|
/* FIXME */
|
1998-06-18 13:04:01 +08:00
|
|
|
/* static float default_resolution = 72; this needs to be set in gimprc */
|
|
|
|
static float default_unit = 1;
|
|
|
|
|
|
|
|
static float default_res_unit = 1;
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
static int new_dialog_run;
|
1998-06-13 03:43:55 +08:00
|
|
|
extern TileManager *global_buf;
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
static void
|
|
|
|
file_new_ok_callback (GtkWidget *widget,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
NewImageValues *vals;
|
|
|
|
GImage *gimage;
|
|
|
|
GDisplay *gdisplay;
|
|
|
|
Layer *layer;
|
|
|
|
int type;
|
|
|
|
|
|
|
|
vals = data;
|
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
vals->width = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (vals->width_spinbutton));
|
|
|
|
vals->height = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (vals->height_spinbutton));
|
1998-10-19 04:38:36 +08:00
|
|
|
|
|
|
|
/* resolution is always in DPI, but the value in the spinner may not
|
|
|
|
* be */
|
1998-06-14 04:57:23 +08:00
|
|
|
vals->resolution = gtk_spin_button_get_value_as_float (GTK_SPIN_BUTTON (vals->resolution_spinbutton));
|
1998-10-19 04:38:36 +08:00
|
|
|
vals->resolution *= vals->res_unit;
|
1998-06-14 04:57:23 +08:00
|
|
|
|
|
|
|
|
1998-06-13 03:43:55 +08:00
|
|
|
last_new_image = TRUE;
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_widget_destroy (vals->dlg);
|
|
|
|
|
|
|
|
last_width = vals->width;
|
|
|
|
last_height = vals->height;
|
|
|
|
last_type = vals->type;
|
|
|
|
last_fill_type = vals->fill_type;
|
|
|
|
last_resolution = vals->resolution;
|
|
|
|
last_unit = vals->unit;
|
1998-06-10 05:21:23 +08:00
|
|
|
last_res_unit = vals->res_unit;
|
1998-06-13 03:43:55 +08:00
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
switch (vals->fill_type)
|
|
|
|
{
|
|
|
|
case BACKGROUND_FILL:
|
1998-07-14 13:35:42 +08:00
|
|
|
case FOREGROUND_FILL:
|
1998-06-09 05:53:45 +08:00
|
|
|
case WHITE_FILL:
|
|
|
|
type = (vals->type == RGB) ? RGB_GIMAGE : GRAY_GIMAGE;
|
|
|
|
break;
|
|
|
|
case TRANSPARENT_FILL:
|
|
|
|
type = (vals->type == RGB) ? RGBA_GIMAGE : GRAYA_GIMAGE;
|
|
|
|
break;
|
|
|
|
default:
|
|
|
|
type = RGB_IMAGE;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
|
|
|
|
gimage = gimage_new (vals->width, vals->height, vals->type);
|
|
|
|
|
1998-11-15 07:28:47 +08:00
|
|
|
/* XXX for the moment, we set both x and y resolution to the same,
|
|
|
|
* since we don't have the UI to get both values from the user, and
|
|
|
|
* besides, that's what PhotoShop seems to do. */
|
|
|
|
gimp_image_set_resolution(gimage, vals->resolution, vals->resolution);
|
1998-10-05 18:05:29 +08:00
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
/* Make the background (or first) layer */
|
1998-06-29 08:24:44 +08:00
|
|
|
layer = layer_new (gimage, gimage->width, gimage->height,
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
type, _("Background"), OPAQUE_OPACITY, NORMAL);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
if (layer) {
|
|
|
|
/* add the new layer to the gimage */
|
|
|
|
gimage_disable_undo (gimage);
|
|
|
|
gimage_add_layer (gimage, layer, 0);
|
|
|
|
gimage_enable_undo (gimage);
|
|
|
|
|
|
|
|
drawable_fill (GIMP_DRAWABLE(layer), vals->fill_type);
|
|
|
|
|
|
|
|
gimage_clean_all (gimage);
|
|
|
|
|
|
|
|
gdisplay = gdisplay_new (gimage, 0x0101);
|
|
|
|
}
|
|
|
|
|
|
|
|
g_free (vals);
|
|
|
|
}
|
|
|
|
|
|
|
|
static gint
|
|
|
|
file_new_delete_callback (GtkWidget *widget,
|
|
|
|
GdkEvent *event,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
file_new_cancel_callback (widget, data);
|
|
|
|
|
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
static void
|
|
|
|
file_new_cancel_callback (GtkWidget *widget,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
NewImageValues *vals;
|
|
|
|
|
|
|
|
vals = data;
|
|
|
|
|
|
|
|
gtk_widget_destroy (vals->dlg);
|
|
|
|
g_free (vals);
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
file_new_toggle_callback (GtkWidget *widget,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
int *val;
|
|
|
|
|
|
|
|
if (GTK_TOGGLE_BUTTON (widget)->active)
|
|
|
|
{
|
|
|
|
val = data;
|
|
|
|
*val = (long) gtk_object_get_user_data (GTK_OBJECT (widget));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
file_new_width_update_callback (GtkWidget *widget,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
NewImageValues *vals;
|
|
|
|
int new_width;
|
|
|
|
float temp;
|
|
|
|
|
|
|
|
vals = data;
|
1998-06-14 04:57:23 +08:00
|
|
|
new_width = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (vals->width_spinbutton));
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
temp = ((float) new_width / (float) vals->resolution) * vals->unit;
|
1998-06-14 04:57:23 +08:00
|
|
|
|
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->width_units_spinbutton), vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->width_units_spinbutton), temp);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->width_units_spinbutton), vals);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
}
|
|
|
|
static void
|
|
|
|
file_new_height_update_callback (GtkWidget *widget,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
|
|
|
|
NewImageValues *vals;
|
|
|
|
int new_height;
|
|
|
|
float temp;
|
1998-06-14 06:05:22 +08:00
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
vals = data;
|
1998-06-14 04:57:23 +08:00
|
|
|
new_height = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (vals->height_spinbutton));
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
temp = ((float) new_height / (float) vals->resolution) * vals->unit;
|
1998-06-14 04:57:23 +08:00
|
|
|
|
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->height_units_spinbutton), vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->height_units_spinbutton), temp);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->height_units_spinbutton), vals);
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
file_new_width_units_update_callback (GtkWidget *widget,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
NewImageValues *vals;
|
|
|
|
float new_width_units;
|
|
|
|
float temp;
|
|
|
|
|
|
|
|
vals = data;
|
1998-06-14 04:57:23 +08:00
|
|
|
new_width_units = gtk_spin_button_get_value_as_float (GTK_SPIN_BUTTON (vals->width_units_spinbutton));
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 06:05:22 +08:00
|
|
|
temp = ((((float) new_width_units) / vals->unit) * ((float) vals->resolution));
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->width_spinbutton), vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->width_spinbutton), temp);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->width_spinbutton), vals);
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
file_new_height_units_update_callback (GtkWidget *widget,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
NewImageValues *vals;
|
|
|
|
float new_height_units;
|
|
|
|
float temp;
|
|
|
|
|
|
|
|
vals = data;
|
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
new_height_units = gtk_spin_button_get_value_as_float (GTK_SPIN_BUTTON (vals->height_units_spinbutton));
|
|
|
|
|
|
|
|
|
1998-06-14 06:05:22 +08:00
|
|
|
temp = ((((float) new_height_units) / vals->unit ) * ((float) vals->resolution));
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->height_spinbutton), vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->height_spinbutton), temp);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->height_spinbutton), vals);
|
1998-06-09 05:53:45 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
file_new_resolution_callback (GtkWidget *widget,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
NewImageValues *vals;
|
|
|
|
float temp_units;
|
|
|
|
float temp_pixels;
|
1998-06-10 05:21:23 +08:00
|
|
|
float temp_resolution;
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
vals = data;
|
1998-06-14 04:57:23 +08:00
|
|
|
temp_resolution = gtk_spin_button_get_value_as_float (GTK_SPIN_BUTTON (vals->resolution_spinbutton));
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
/* a bit of a kludge to keep height/width from going to zero */
|
1998-06-10 05:21:23 +08:00
|
|
|
if(temp_resolution <= 1)
|
|
|
|
temp_resolution = 1;
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-10 05:21:23 +08:00
|
|
|
/* vals->resoluion is always in DPI */
|
|
|
|
vals->resolution = (temp_resolution * vals->res_unit);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
/* figure the new height */
|
1998-06-14 04:57:23 +08:00
|
|
|
temp_units = gtk_spin_button_get_value_as_float (GTK_SPIN_BUTTON (vals->height_units_spinbutton));
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
temp_pixels = (float) vals->resolution * ((float)temp_units / vals->unit) ;
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->height_spinbutton), vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->height_spinbutton), temp_pixels);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->height_spinbutton), vals);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
/* figure the new width */
|
1998-06-14 04:57:23 +08:00
|
|
|
|
|
|
|
|
|
|
|
temp_units = gtk_spin_button_get_value_as_float (GTK_SPIN_BUTTON (vals->width_units_spinbutton));
|
1998-06-09 05:53:45 +08:00
|
|
|
temp_pixels = (float) vals->resolution * ((float) temp_units / vals->unit);
|
1998-06-14 04:57:23 +08:00
|
|
|
|
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->width_spinbutton), vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->width_spinbutton), temp_pixels);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->width_spinbutton), vals);
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
file_new_units_inch_menu_callback (GtkWidget *widget ,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
NewImageValues *vals;
|
|
|
|
|
|
|
|
float temp_pixels_height;
|
|
|
|
float temp_pixels_width;
|
|
|
|
float temp_units_height;
|
|
|
|
float temp_units_width;
|
|
|
|
|
|
|
|
vals = data;
|
|
|
|
vals->unit = 1; /* set fo/inch ratio for conversions */
|
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
temp_pixels_height = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (vals->height_spinbutton));
|
|
|
|
temp_pixels_width = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON (vals->width_spinbutton));
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
|
1998-06-10 05:21:23 +08:00
|
|
|
/* remember vals->resoltuion is always in dpi */
|
|
|
|
temp_units_height = (float) temp_pixels_height / (((float) vals->resolution) * vals->unit);
|
|
|
|
temp_units_width = (float)temp_pixels_width / (((float) vals->resolution) * vals->unit);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->height_units_spinbutton),vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->height_units_spinbutton), temp_units_height);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->height_units_spinbutton),vals);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->width_units_spinbutton),vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->width_units_spinbutton), temp_units_width);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->width_units_spinbutton),vals);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
static void
|
|
|
|
file_new_units_cm_menu_callback (GtkWidget *widget ,
|
|
|
|
gpointer data)
|
|
|
|
{
|
|
|
|
NewImageValues *vals;
|
|
|
|
|
|
|
|
float temp_pixels_height;
|
|
|
|
float temp_pixels_width;
|
|
|
|
float temp_units_height;
|
|
|
|
float temp_units_width;
|
|
|
|
|
|
|
|
vals = data;
|
|
|
|
vals->unit = 2.54;
|
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
temp_pixels_height = gtk_spin_button_get_value_as_float (GTK_SPIN_BUTTON (vals->height_spinbutton));
|
|
|
|
|
|
|
|
temp_pixels_width = gtk_spin_button_get_value_as_float (GTK_SPIN_BUTTON (vals->width_spinbutton));
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
/* remember resoltuion is always in dpi */
|
|
|
|
/* convert from inches to centimeters here */
|
|
|
|
|
1998-06-10 05:21:23 +08:00
|
|
|
temp_units_height = ((float) temp_pixels_height / (((float) vals->resolution)) * vals->unit);
|
|
|
|
temp_units_width = ((float)temp_pixels_width / (((float) vals->resolution)) * vals->unit);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->height_units_spinbutton),vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->height_units_spinbutton), temp_units_height);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->height_units_spinbutton),vals);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->width_units_spinbutton),vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->width_units_spinbutton), temp_units_width);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->width_units_spinbutton),vals);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-10 05:21:23 +08:00
|
|
|
}
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-10 05:21:23 +08:00
|
|
|
static void file_new_res_units_inch_callback (GtkWidget *widget, gpointer data)
|
|
|
|
{
|
|
|
|
|
|
|
|
NewImageValues *vals;
|
|
|
|
float temp_resolution;
|
|
|
|
|
|
|
|
vals = data;
|
|
|
|
vals->res_unit = 1.0;
|
|
|
|
|
|
|
|
/* vals->resoltuion is alwayd DPI */
|
|
|
|
temp_resolution = (vals->resolution / vals->res_unit);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->resolution_spinbutton),vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->resolution_spinbutton), temp_resolution);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->resolution_spinbutton),vals);
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
}
|
|
|
|
|
1998-06-10 05:21:23 +08:00
|
|
|
static void file_new_res_units_cm_callback (GtkWidget *widget, gpointer data)
|
|
|
|
{
|
|
|
|
|
|
|
|
NewImageValues *vals;
|
|
|
|
float temp_resolution;
|
|
|
|
|
|
|
|
vals = data;
|
|
|
|
vals->res_unit = 2.54;
|
|
|
|
|
|
|
|
/* vals->resolution is always DPI */
|
|
|
|
temp_resolution = (vals->resolution / vals->res_unit);
|
1998-06-14 04:57:23 +08:00
|
|
|
|
|
|
|
gtk_signal_handler_block_by_data (GTK_OBJECT (vals->resolution_spinbutton),vals);
|
|
|
|
gtk_spin_button_set_value (GTK_SPIN_BUTTON (vals->resolution_spinbutton), temp_resolution);
|
|
|
|
gtk_signal_handler_unblock_by_data (GTK_OBJECT (vals->resolution_spinbutton),vals);
|
1998-06-10 05:21:23 +08:00
|
|
|
|
|
|
|
}
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
void
|
|
|
|
file_new_cmd_callback (GtkWidget *widget,
|
|
|
|
gpointer callback_data,
|
|
|
|
guint callback_action)
|
|
|
|
{
|
|
|
|
GDisplay *gdisp;
|
|
|
|
NewImageValues *vals;
|
|
|
|
GtkWidget *button;
|
|
|
|
GtkWidget *label;
|
|
|
|
GtkWidget *vbox;
|
|
|
|
GtkWidget *hbox;
|
|
|
|
GtkWidget *table;
|
|
|
|
GtkWidget *frame;
|
|
|
|
GtkWidget *radio_box;
|
|
|
|
GtkWidget *menu;
|
|
|
|
GtkWidget *menuitem;
|
|
|
|
GtkWidget *optionmenu;
|
1998-06-14 04:57:23 +08:00
|
|
|
GtkAdjustment *adj;
|
1998-06-09 05:53:45 +08:00
|
|
|
GSList *group;
|
|
|
|
float temp;
|
|
|
|
|
1998-06-18 13:04:01 +08:00
|
|
|
default_res_unit = file_new_default_unit_parse(default_resolution_units);
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
if(!new_dialog_run)
|
|
|
|
{
|
|
|
|
last_width = default_width;
|
|
|
|
last_height = default_height;
|
|
|
|
last_type = default_type;
|
|
|
|
last_resolution = default_resolution; /* this isnt set in gimprc yet */
|
|
|
|
last_unit = default_unit; /* not in gimprc either, inches for now */
|
1998-06-10 05:21:23 +08:00
|
|
|
last_res_unit = default_res_unit;
|
1998-06-18 13:04:01 +08:00
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
new_dialog_run = 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* Before we try to determine the responsible gdisplay,
|
|
|
|
* make sure this wasn't called from the toolbox
|
|
|
|
*/
|
|
|
|
if (callback_action)
|
|
|
|
gdisp = gdisplay_active ();
|
|
|
|
else
|
|
|
|
gdisp = NULL;
|
|
|
|
|
|
|
|
vals = g_malloc (sizeof (NewImageValues));
|
|
|
|
vals->fill_type = last_fill_type;
|
|
|
|
|
|
|
|
if (gdisp)
|
|
|
|
{
|
|
|
|
vals->width = gdisp->gimage->width;
|
|
|
|
vals->height = gdisp->gimage->height;
|
|
|
|
vals->type = gimage_base_type (gdisp->gimage);
|
1998-11-15 07:28:47 +08:00
|
|
|
vals->resolution = gdisp->gimage->xresolution;
|
1998-06-09 05:53:45 +08:00
|
|
|
vals->unit = last_unit;
|
1998-10-19 04:38:36 +08:00
|
|
|
vals->res_unit = 1.0;
|
1998-06-09 05:53:45 +08:00
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
vals->width = last_width;
|
|
|
|
vals->height = last_height;
|
|
|
|
vals->type = last_type;
|
|
|
|
vals->resolution = last_resolution;
|
|
|
|
vals->unit = last_unit;
|
1998-06-10 05:21:23 +08:00
|
|
|
vals->res_unit = last_res_unit;
|
1998-06-09 05:53:45 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
if (vals->type == INDEXED)
|
|
|
|
vals->type = RGB; /* no indexed images */
|
|
|
|
|
1998-06-13 03:43:55 +08:00
|
|
|
/* if a cut buffer exist, default to using its size for the new image */
|
|
|
|
/* also check to see if a new_image has been opened */
|
|
|
|
|
|
|
|
if(global_buf && !last_new_image)
|
|
|
|
{
|
1998-08-16 03:17:36 +08:00
|
|
|
vals->width = global_buf->width;
|
|
|
|
vals->height = global_buf->height;
|
1998-10-19 04:38:36 +08:00
|
|
|
/* It would be good to set the resolution here, but that would
|
|
|
|
* require TileManagers to know about the resolution of tiles
|
|
|
|
* they're dealing with. It's not clear we want to go down that
|
|
|
|
* road. -- austin */
|
1998-06-13 03:43:55 +08:00
|
|
|
}
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
vals->dlg = gtk_dialog_new ();
|
|
|
|
gtk_window_set_wmclass (GTK_WINDOW (vals->dlg), "new_image", "Gimp");
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
gtk_window_set_title (GTK_WINDOW (vals->dlg), _("New Image"));
|
1998-12-04 07:01:44 +08:00
|
|
|
gtk_window_set_position (GTK_WINDOW (vals->dlg), GTK_WIN_POS_MOUSE);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
/* handle the wm close signal */
|
|
|
|
gtk_signal_connect (GTK_OBJECT (vals->dlg), "delete_event",
|
|
|
|
GTK_SIGNAL_FUNC (file_new_delete_callback),
|
|
|
|
vals);
|
|
|
|
|
1998-12-04 07:01:44 +08:00
|
|
|
gtk_container_set_border_width (GTK_CONTAINER (GTK_DIALOG (vals->dlg)->action_area), 2);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
button = gtk_button_new_with_label (_("OK"));
|
1998-06-09 05:53:45 +08:00
|
|
|
GTK_WIDGET_SET_FLAGS (button, GTK_CAN_DEFAULT);
|
|
|
|
gtk_signal_connect (GTK_OBJECT (button), "clicked",
|
|
|
|
(GtkSignalFunc) file_new_ok_callback,
|
|
|
|
vals);
|
|
|
|
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (vals->dlg)->action_area),
|
|
|
|
button, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_grab_default (button);
|
|
|
|
gtk_widget_show (button);
|
|
|
|
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
button = gtk_button_new_with_label (_("Cancel"));
|
1998-06-09 05:53:45 +08:00
|
|
|
GTK_WIDGET_SET_FLAGS (button, GTK_CAN_DEFAULT);
|
|
|
|
gtk_signal_connect (GTK_OBJECT (button), "clicked",
|
|
|
|
(GtkSignalFunc) file_new_cancel_callback,
|
|
|
|
vals);
|
|
|
|
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (vals->dlg)->action_area),
|
|
|
|
button, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_show (button);
|
|
|
|
|
|
|
|
|
|
|
|
vbox = gtk_vbox_new (FALSE, 1);
|
1998-12-04 07:01:44 +08:00
|
|
|
gtk_container_set_border_width (GTK_CONTAINER (vbox), 2);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_box_pack_start (GTK_BOX (GTK_DIALOG (vals->dlg)->vbox),
|
|
|
|
vbox, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_show (vbox);
|
|
|
|
|
|
|
|
table = gtk_table_new (3, 3, FALSE);
|
|
|
|
gtk_table_set_row_spacings (GTK_TABLE (table), 2);
|
|
|
|
gtk_table_set_col_spacings (GTK_TABLE (table), 2);
|
|
|
|
gtk_box_pack_start (GTK_BOX (vbox), table, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_show (table);
|
|
|
|
|
|
|
|
/* label for top of table, Width */
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
label = gtk_label_new (_("Width"));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_table_attach (GTK_TABLE (table), label, 0, 1, 0, 1,
|
|
|
|
GTK_FILL, GTK_FILL, 0, 0);
|
|
|
|
gtk_widget_show (label);
|
|
|
|
|
|
|
|
/* Label for top of table, Height */
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
label = gtk_label_new (_("Height"));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_table_attach (GTK_TABLE (table), label, 1, 2, 0, 1,
|
|
|
|
GTK_FILL, GTK_FILL, 0, 0);
|
|
|
|
gtk_widget_show (label);
|
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
/* width in pixels spinbutton */
|
|
|
|
adj = (GtkAdjustment *) gtk_adjustment_new (vals->width, 1.0, 32767.0,
|
|
|
|
1.0, 50.0, 0.0);
|
|
|
|
vals->width_spinbutton = gtk_spin_button_new (adj, 1.0, 0.0);
|
|
|
|
gtk_spin_button_set_shadow_type (GTK_SPIN_BUTTON(vals->width_spinbutton), GTK_SHADOW_NONE);
|
|
|
|
gtk_widget_set_usize (vals->width_spinbutton, 75, 0);
|
|
|
|
|
|
|
|
gtk_table_attach (GTK_TABLE (table), vals->width_spinbutton, 0, 1, 1, 2,
|
1998-06-09 05:53:45 +08:00
|
|
|
GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
|
1998-06-19 00:54:56 +08:00
|
|
|
gtk_signal_connect (GTK_OBJECT (vals->width_spinbutton), "changed",
|
1998-06-14 04:57:23 +08:00
|
|
|
(GtkSignalFunc) file_new_width_update_callback, vals);
|
|
|
|
gtk_widget_show (vals->width_spinbutton);
|
|
|
|
|
|
|
|
/* height in pixels spinbutton */
|
|
|
|
adj = (GtkAdjustment *) gtk_adjustment_new (vals->height, 1.0, 32767.0,
|
|
|
|
1.0, 50.0, 0.0);
|
|
|
|
vals->height_spinbutton = gtk_spin_button_new (adj, 1.0, 0.0);
|
|
|
|
gtk_spin_button_set_shadow_type (GTK_SPIN_BUTTON(vals->height_spinbutton), GTK_SHADOW_NONE);
|
|
|
|
gtk_widget_set_usize (vals->height_spinbutton, 75, 0);
|
|
|
|
gtk_table_attach (GTK_TABLE (table), vals->height_spinbutton, 1, 2, 1, 2,
|
1998-06-09 05:53:45 +08:00
|
|
|
GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
|
1998-06-19 00:54:56 +08:00
|
|
|
gtk_signal_connect (GTK_OBJECT (vals->height_spinbutton), "changed",
|
1998-06-09 05:53:45 +08:00
|
|
|
(GtkSignalFunc) file_new_height_update_callback, vals);
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_widget_show (vals->height_spinbutton);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
/* width in units spinbutton */
|
1998-10-19 04:38:36 +08:00
|
|
|
temp = (float) vals->width / vals->resolution * vals->unit;
|
1998-09-12 00:34:23 +08:00
|
|
|
adj = (GtkAdjustment *) gtk_adjustment_new (temp, 0.0, 32767.0,
|
1998-06-18 13:04:01 +08:00
|
|
|
1.0, 0.01, 0.0);
|
1998-06-14 04:57:23 +08:00
|
|
|
vals->width_units_spinbutton = gtk_spin_button_new (adj, 1.0, 2.0);
|
1998-06-18 13:04:01 +08:00
|
|
|
gtk_spin_button_set_update_policy (GTK_SPIN_BUTTON(vals->width_units_spinbutton), GTK_UPDATE_ALWAYS
|
|
|
|
| GTK_UPDATE_IF_VALID );
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_spin_button_set_shadow_type (GTK_SPIN_BUTTON(vals->width_units_spinbutton), GTK_SHADOW_NONE);
|
1998-06-18 13:04:01 +08:00
|
|
|
gtk_spin_button_set_snap_to_ticks(GTK_SPIN_BUTTON(vals->width_units_spinbutton), 0);
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_widget_set_usize (vals->width_units_spinbutton, 75, 0);
|
|
|
|
gtk_signal_connect (GTK_OBJECT (vals->width_units_spinbutton), "changed",
|
1998-06-09 05:53:45 +08:00
|
|
|
(GtkSignalFunc) file_new_width_units_update_callback, vals);
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_table_attach (GTK_TABLE (table), vals->width_units_spinbutton , 0, 1, 2, 3,
|
1998-06-09 05:53:45 +08:00
|
|
|
GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_widget_show (vals->width_units_spinbutton);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
/* height in units spinbutton */
|
1998-10-19 04:38:36 +08:00
|
|
|
temp = (float) vals->height / vals->resolution * vals->unit;
|
1998-09-12 00:34:23 +08:00
|
|
|
adj = (GtkAdjustment *) gtk_adjustment_new (temp, 0.0, 32767.0,
|
1998-06-18 13:04:01 +08:00
|
|
|
1.0, 0.01, 0.0);
|
1998-06-14 04:57:23 +08:00
|
|
|
vals->height_units_spinbutton = gtk_spin_button_new (adj, 1.0, 2.0);
|
1998-06-18 13:04:01 +08:00
|
|
|
gtk_spin_button_set_update_policy (GTK_SPIN_BUTTON(vals->height_units_spinbutton), GTK_UPDATE_ALWAYS |
|
|
|
|
GTK_UPDATE_IF_VALID);
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_spin_button_set_shadow_type (GTK_SPIN_BUTTON(vals->height_units_spinbutton), GTK_SHADOW_NONE);
|
1998-06-18 13:04:01 +08:00
|
|
|
gtk_spin_button_set_snap_to_ticks(GTK_SPIN_BUTTON(vals->height_units_spinbutton), 0);
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_widget_set_usize (vals->height_units_spinbutton, 75, 0);
|
|
|
|
gtk_signal_connect (GTK_OBJECT (vals->height_units_spinbutton), "changed",
|
1998-06-09 05:53:45 +08:00
|
|
|
(GtkSignalFunc) file_new_height_units_update_callback, vals);
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_table_attach (GTK_TABLE (table), vals->height_units_spinbutton , 1, 2, 2, 3,
|
1998-06-09 05:53:45 +08:00
|
|
|
GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_widget_show (vals->height_units_spinbutton);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
|
|
|
/* Label for right hand side of pixel size boxes */
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
label = gtk_label_new (_("Pixels"));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5);
|
|
|
|
gtk_table_attach (GTK_TABLE (table), label , 2, 3, 1, 2,
|
|
|
|
GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
|
|
|
|
gtk_widget_show (label);
|
|
|
|
|
|
|
|
/* menu and menu items for the units pop-up menu for the units entries */
|
|
|
|
menu = gtk_menu_new();
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
menuitem = gtk_menu_item_new_with_label (_("inches"));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_menu_append (GTK_MENU (menu), menuitem);
|
|
|
|
gtk_signal_connect (GTK_OBJECT (menuitem), "activate",
|
|
|
|
(GtkSignalFunc) file_new_units_inch_menu_callback, vals);
|
|
|
|
gtk_widget_show(menuitem);
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
menuitem = gtk_menu_item_new_with_label (_("cm"));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_menu_append (GTK_MENU (menu), menuitem);
|
|
|
|
gtk_signal_connect (GTK_OBJECT (menuitem), "activate",
|
|
|
|
(GtkSignalFunc) file_new_units_cm_menu_callback, vals);
|
|
|
|
gtk_widget_show(menuitem);
|
|
|
|
|
|
|
|
optionmenu = gtk_option_menu_new();
|
|
|
|
gtk_option_menu_set_menu (GTK_OPTION_MENU (optionmenu), menu);
|
1998-10-19 04:38:36 +08:00
|
|
|
if (vals->unit != 1.0)
|
|
|
|
gtk_option_menu_set_history (GTK_OPTION_MENU (optionmenu), 1);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_table_attach (GTK_TABLE (table), optionmenu , 2, 3, 2, 3,
|
|
|
|
GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
|
|
|
|
gtk_widget_show(optionmenu);
|
|
|
|
|
|
|
|
/* resolution frame */
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
frame = gtk_frame_new (_("Resolution"));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_box_pack_start (GTK_BOX (vbox), frame, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_show (frame);
|
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
/* hbox containing the label, the spinbutton, and the optionmenu */
|
1998-06-09 05:53:45 +08:00
|
|
|
hbox = gtk_hbox_new (FALSE, 1);
|
1998-12-04 07:01:44 +08:00
|
|
|
gtk_container_set_border_width (GTK_CONTAINER (hbox), 2);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_container_add(GTK_CONTAINER (frame), hbox);
|
|
|
|
gtk_widget_show(hbox);
|
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
/* resoltuion spinbutton */
|
1998-10-19 04:38:36 +08:00
|
|
|
adj = (GtkAdjustment *) gtk_adjustment_new (vals->resolution/vals->res_unit,
|
|
|
|
1.0, 32767.0,
|
1998-06-14 04:57:23 +08:00
|
|
|
1.0, 5.0, 0.0);
|
|
|
|
vals->resolution_spinbutton = gtk_spin_button_new (adj, 1.0, 2.0);
|
|
|
|
gtk_spin_button_set_shadow_type (GTK_SPIN_BUTTON(vals->resolution_spinbutton), GTK_SHADOW_NONE);
|
|
|
|
gtk_widget_set_usize (vals->resolution_spinbutton, 76, 0);
|
|
|
|
gtk_box_pack_start (GTK_BOX (hbox), vals->resolution_spinbutton, TRUE, TRUE, 0);
|
|
|
|
gtk_signal_connect (GTK_OBJECT (vals->resolution_spinbutton), "changed",
|
1998-06-09 05:53:45 +08:00
|
|
|
(GtkSignalFunc) file_new_resolution_callback,
|
|
|
|
vals);
|
1998-06-14 04:57:23 +08:00
|
|
|
gtk_widget_show (vals->resolution_spinbutton);
|
1998-06-09 05:53:45 +08:00
|
|
|
|
1998-06-14 04:57:23 +08:00
|
|
|
/* resolution label */
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
label =gtk_label_new (_(" pixels per "));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_box_pack_start (GTK_BOX (hbox), label, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_show (label);
|
|
|
|
|
|
|
|
menu = gtk_menu_new();
|
|
|
|
/* This units stuff doesnt do anything yet. I'm not real sure if it
|
|
|
|
it should do anything yet, excpet for maybe set some default resolutions
|
|
|
|
and change the image default rulers. But the rulers stuff probabaly
|
|
|
|
needs some gtk acking first to really be useful.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/* probabaly should be more general here */
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
menuitem = gtk_menu_item_new_with_label (_("inch"));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_menu_append (GTK_MENU (menu), menuitem);
|
1998-06-10 05:21:23 +08:00
|
|
|
gtk_signal_connect (GTK_OBJECT (menuitem), "activate",
|
|
|
|
(GtkSignalFunc) file_new_res_units_inch_callback, vals);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_widget_show(menuitem);
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
menuitem = gtk_menu_item_new_with_label (_("cm"));
|
1998-06-10 05:21:23 +08:00
|
|
|
gtk_signal_connect (GTK_OBJECT (menuitem), "activate",
|
|
|
|
(GtkSignalFunc) file_new_res_units_cm_callback, vals);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_menu_append (GTK_MENU (menu), menuitem);
|
|
|
|
gtk_widget_show(menuitem);
|
|
|
|
|
|
|
|
optionmenu = gtk_option_menu_new();
|
|
|
|
gtk_option_menu_set_menu (GTK_OPTION_MENU (optionmenu), menu);
|
1998-10-19 04:38:36 +08:00
|
|
|
if (vals->res_unit != 1.0)
|
|
|
|
gtk_option_menu_set_history (GTK_OPTION_MENU (optionmenu), 1);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_box_pack_start (GTK_BOX (hbox), optionmenu, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_show(optionmenu);
|
|
|
|
|
|
|
|
|
|
|
|
/* hbox containing thje Image ype and fill type frames */
|
|
|
|
hbox = gtk_hbox_new(FALSE, 1);
|
1998-12-04 07:01:44 +08:00
|
|
|
gtk_container_set_border_width (GTK_CONTAINER (hbox), 2);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_box_pack_start (GTK_BOX (vbox), hbox, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_show(hbox);
|
|
|
|
|
|
|
|
/* frame for Image Type */
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
frame = gtk_frame_new (_("Image Type"));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_box_pack_start (GTK_BOX (hbox), frame, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_show (frame);
|
|
|
|
|
|
|
|
/* radio buttons and box */
|
|
|
|
radio_box = gtk_vbox_new (FALSE, 1);
|
1998-12-04 07:01:44 +08:00
|
|
|
gtk_container_set_border_width (GTK_CONTAINER (radio_box), 2);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_container_add (GTK_CONTAINER (frame), radio_box);
|
|
|
|
gtk_widget_show (radio_box);
|
|
|
|
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
button = gtk_radio_button_new_with_label (NULL, _("RGB"));
|
1998-06-09 05:53:45 +08:00
|
|
|
group = gtk_radio_button_group (GTK_RADIO_BUTTON (button));
|
|
|
|
gtk_box_pack_start (GTK_BOX (radio_box), button, TRUE, TRUE, 0);
|
|
|
|
gtk_object_set_user_data (GTK_OBJECT (button), (gpointer) RGB);
|
|
|
|
gtk_signal_connect (GTK_OBJECT (button), "toggled",
|
|
|
|
(GtkSignalFunc) file_new_toggle_callback,
|
|
|
|
&vals->type);
|
|
|
|
if (vals->type == RGB)
|
|
|
|
gtk_toggle_button_set_state (GTK_TOGGLE_BUTTON (button), TRUE);
|
|
|
|
gtk_widget_show (button);
|
|
|
|
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
button = gtk_radio_button_new_with_label (group, _("Grayscale"));
|
1998-06-09 05:53:45 +08:00
|
|
|
group = gtk_radio_button_group (GTK_RADIO_BUTTON (button));
|
|
|
|
gtk_box_pack_start (GTK_BOX (radio_box), button, TRUE, TRUE, 0);
|
|
|
|
gtk_object_set_user_data (GTK_OBJECT (button), (gpointer) GRAY);
|
|
|
|
gtk_signal_connect (GTK_OBJECT (button), "toggled",
|
|
|
|
(GtkSignalFunc) file_new_toggle_callback,
|
|
|
|
&vals->type);
|
|
|
|
if (vals->type == GRAY)
|
|
|
|
gtk_toggle_button_set_state (GTK_TOGGLE_BUTTON (button), TRUE);
|
|
|
|
gtk_widget_show (button);
|
|
|
|
|
|
|
|
|
|
|
|
/* frame for fill type */
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
frame = gtk_frame_new (_("Fill Type"));
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_box_pack_start (GTK_BOX (hbox), frame, TRUE, TRUE, 0);
|
|
|
|
gtk_widget_show (frame);
|
|
|
|
|
|
|
|
radio_box = gtk_vbox_new (FALSE, 1);
|
1998-12-04 07:01:44 +08:00
|
|
|
gtk_container_set_border_width (GTK_CONTAINER (radio_box), 2);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_container_add (GTK_CONTAINER (frame), radio_box);
|
|
|
|
gtk_widget_show (radio_box);
|
|
|
|
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
button = gtk_radio_button_new_with_label (NULL, _("Foreground"));
|
1998-06-09 05:53:45 +08:00
|
|
|
group = gtk_radio_button_group (GTK_RADIO_BUTTON (button));
|
|
|
|
gtk_box_pack_start (GTK_BOX (radio_box), button, TRUE, TRUE, 0);
|
1998-07-29 03:24:23 +08:00
|
|
|
gtk_object_set_user_data (GTK_OBJECT (button), (gpointer) FOREGROUND_FILL);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_signal_connect (GTK_OBJECT (button), "toggled",
|
|
|
|
(GtkSignalFunc) file_new_toggle_callback,
|
|
|
|
&vals->fill_type);
|
1998-07-29 03:24:23 +08:00
|
|
|
if (vals->fill_type == FOREGROUND_FILL)
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_toggle_button_set_state (GTK_TOGGLE_BUTTON (button), TRUE);
|
|
|
|
gtk_widget_show (button);
|
|
|
|
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
button = gtk_radio_button_new_with_label (group, _("Background"));
|
1998-06-09 05:53:45 +08:00
|
|
|
group = gtk_radio_button_group (GTK_RADIO_BUTTON (button));
|
|
|
|
gtk_box_pack_start (GTK_BOX (radio_box), button, TRUE, TRUE, 0);
|
1998-07-29 03:24:23 +08:00
|
|
|
gtk_object_set_user_data (GTK_OBJECT (button), (gpointer) BACKGROUND_FILL);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_signal_connect (GTK_OBJECT (button), "toggled",
|
|
|
|
(GtkSignalFunc) file_new_toggle_callback,
|
|
|
|
&vals->fill_type);
|
1998-07-29 03:24:23 +08:00
|
|
|
if (vals->fill_type == BACKGROUND_FILL)
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_toggle_button_set_state (GTK_TOGGLE_BUTTON (button), TRUE);
|
|
|
|
gtk_widget_show (button);
|
|
|
|
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
button = gtk_radio_button_new_with_label (group, _("White"));
|
1998-06-09 05:53:45 +08:00
|
|
|
group = gtk_radio_button_group (GTK_RADIO_BUTTON (button));
|
|
|
|
gtk_box_pack_start (GTK_BOX (radio_box), button, TRUE, TRUE, 0);
|
1998-07-29 03:24:23 +08:00
|
|
|
gtk_object_set_user_data (GTK_OBJECT (button), (gpointer) WHITE_FILL);
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_signal_connect (GTK_OBJECT (button), "toggled",
|
|
|
|
(GtkSignalFunc) file_new_toggle_callback,
|
|
|
|
&vals->fill_type);
|
1998-07-29 03:24:23 +08:00
|
|
|
if (vals->fill_type == WHITE_FILL)
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_toggle_button_set_state (GTK_TOGGLE_BUTTON (button), TRUE);
|
|
|
|
gtk_widget_show (button);
|
|
|
|
|
Lots of ii8n stuff here and some additions to the de.po. Applied
Wed Oct 14 17:46:15 EDT 1998 Adrian Likins <adrian@gimp.org>
* app/*, po/de.po, de/POTFILES.in, libgimp/gimpintl.h:
Lots of ii8n stuff here and some additions to the de.po.
Applied gimp-egger-981005-1 ,gimp-egger-981006-1,
gimp-egger-981007-1, gimp-egger-981008-1,
gimp-egger-981009-1.patch, gimp-egger-981010-1.patch
* plug-in/guillotine/guillotine.c: added the coordinates
of the split images from the original image to the title.
ie foo.jpg (0,0) for the image in the topleft.
* plug-in/script-fu/scripts/neon-logo.scm,
perspective-shadow.scm, predator.scm,rendermap.scm,
ripply-anim.scm, select_to_image.scm,swirltile.scm,
xach-effect.scm: updated scripts to use new script-fu stuff
wooo boy! a big un!
in testing this, it looks like some of the po files are busted.
but the code stuff seems okay.
-adrian
1998-10-15 07:23:52 +08:00
|
|
|
button = gtk_radio_button_new_with_label (group, _("Transparent"));
|
1998-07-14 13:35:42 +08:00
|
|
|
group = gtk_radio_button_group (GTK_RADIO_BUTTON (button));
|
|
|
|
gtk_box_pack_start (GTK_BOX (radio_box), button, TRUE, TRUE, 0);
|
1998-07-29 03:24:23 +08:00
|
|
|
gtk_object_set_user_data (GTK_OBJECT (button), (gpointer) TRANSPARENT_FILL);
|
1998-07-14 13:35:42 +08:00
|
|
|
gtk_signal_connect (GTK_OBJECT (button), "toggled",
|
|
|
|
(GtkSignalFunc) file_new_toggle_callback,
|
|
|
|
&vals->fill_type);
|
1998-07-29 03:24:23 +08:00
|
|
|
if (vals->fill_type == TRANSPARENT_FILL)
|
1998-07-14 13:35:42 +08:00
|
|
|
gtk_toggle_button_set_state (GTK_TOGGLE_BUTTON (button), TRUE);
|
|
|
|
gtk_widget_show (button);
|
|
|
|
|
1998-06-09 05:53:45 +08:00
|
|
|
gtk_widget_show (vals->dlg);
|
|
|
|
}
|
|
|
|
|
1998-06-13 03:43:55 +08:00
|
|
|
void file_new_reset_current_cut_buffer()
|
|
|
|
{
|
|
|
|
/* this unction just changes the status of last_image_new
|
|
|
|
so i can if theres been a cut/copy since the last file new */
|
|
|
|
last_new_image = FALSE;
|
|
|
|
|
|
|
|
}
|
1998-06-18 13:04:01 +08:00
|
|
|
|
|
|
|
static float file_new_default_unit_parse (int ruler_unit)
|
|
|
|
{
|
|
|
|
|
|
|
|
/* checks the enum passed from gimprc to see what the values are */
|
|
|
|
|
|
|
|
if(ruler_unit == 1)
|
|
|
|
return 1.0;
|
|
|
|
if(ruler_unit == 2)
|
|
|
|
return 2.54;
|
|
|
|
|
|
|
|
return 1.0;
|
|
|
|
|
|
|
|
}
|