+2004-07-11 Jim Evins <evins@snaught.com>
+
+ * data/glabels-2.0.dtd:
+ * libglabels/template.c: (gl_template_rect_label_type_new),
+ (gl_template_round_label_type_new),
+ (gl_template_cd_label_type_new), (gl_template_label_type_dup),
+ (template_full_page):
+ * libglabels/template.h:
+ * libglabels/xml-template.c: (xml_parse_label_rectangle_node),
+ (xml_create_label_node):
+ * pixmaps/ex-rect-size.png:
+ * src/print.c: (clip_to_outline), (clip_punchouts):
+ * src/template-designer.c: (construct_rect_size_page),
+ (rect_size_page_prepare_cb), (layout_page_prepare_cb),
+ (build_template):
+ * src/template-designer.glade:
+ * src/xml-label-191.c: (xml191_parse_label):
+ Modifications to allow separate horizontal (x_waste) and vertical (y_waste)
+ properties for rectangular labels. Templates remain backwards compatible,
+ but this breaks the libglabels API (I don't know of anyone outside of
+ glabels using libglabels at this time -- what can I say, the program is
+ is still "unstable"). This addresses the suggestion in Feature Request
+ #976313.
+
2004-07-05 Jim Evins <evins@snaught.com>
* src/print.c: (print_crop_marks), (draw_outline):
Changed crop marks and label outlines to black, instead of 25% gray.
height %LENGTH_TYPE; #REQUIRED
round %LENGTH_TYPE; "0 pt"
waste %LENGTH_TYPE; #IMPLIED
+ x_waste %LENGTH_TYPE; #IMPLIED
+ y_waste %LENGTH_TYPE; #IMPLIED
>
<!ELEMENT Label-round ((%markup_element;)*, Layout+)>
gdouble w,
gdouble h,
gdouble r,
- gdouble waste)
+ gdouble x_waste,
+ gdouble y_waste)
{
glTemplateLabelType *label_type;
label_type = g_new0 (glTemplateLabelType, 1);
label_type->id = g_strdup (id);
- label_type->waste = waste;
label_type->shape = GL_TEMPLATE_SHAPE_RECT;
label_type->size.rect.w = w;
label_type->size.rect.h = h;
label_type->size.rect.r = r;
+ label_type->size.rect.x_waste = x_waste;
+ label_type->size.rect.y_waste = y_waste;
return label_type;
}
label_type = g_new0 (glTemplateLabelType, 1);
label_type->id = g_strdup (id);
- label_type->waste = waste;
label_type->shape = GL_TEMPLATE_SHAPE_ROUND;
label_type->size.round.r = r;
+ label_type->size.round.waste = waste;
return label_type;
}
label_type = g_new0 (glTemplateLabelType, 1);
label_type->id = g_strdup (id);
- label_type->waste = waste;
label_type->shape = GL_TEMPLATE_SHAPE_CD;
label_type->size.cd.r1 = r1;
label_type->size.cd.r2 = r2;
label_type->size.cd.w = w;
label_type->size.cd.h = h;
+ label_type->size.cd.waste = waste;
return label_type;
}
orig_label_type->size.rect.w,
orig_label_type->size.rect.h,
orig_label_type->size.rect.r,
- orig_label_type->waste);
+ orig_label_type->size.rect.x_waste,
+ orig_label_type->size.rect.y_waste);
break;
case GL_TEMPLATE_SHAPE_ROUND:
label_type =
gl_template_round_label_type_new (orig_label_type->id,
orig_label_type->size.round.r,
- orig_label_type->waste);
+ orig_label_type->size.round.waste);
break;
case GL_TEMPLATE_SHAPE_CD:
orig_label_type->size.cd.r2,
orig_label_type->size.cd.w,
orig_label_type->size.cd.h,
- orig_label_type->waste);
+ orig_label_type->size.cd.waste);
break;
default:
paper->width,
paper->height,
0.0,
+ 0.0,
0.0);
gl_template_add_label_type (template, label_type);
GList *layouts; /* List of glTemplateLayouts */
GList *markups; /* List of glTemplateMarkups */
- gdouble waste; /* Amount of overprint allowed. */
-
glTemplateLabelShape shape;
union {
struct {
- gdouble w; /* Width */
- gdouble h; /* Height */
- gdouble r; /* Corner radius */
+ gdouble w; /* Width */
+ gdouble h; /* Height */
+ gdouble r; /* Corner radius */
+ gdouble x_waste; /* Amount of horiz overprint allowed. */
+ gdouble y_waste; /* Amount of vert overprint allowed. */
} rect;
struct {
- gdouble r; /* Radius */
+ gdouble r; /* Radius */
+ gdouble waste; /* Amount of overprint allowed. */
+
} round;
struct {
- gdouble r1; /* Outer radius */
- gdouble r2; /* Inner radius (hole) */
- gdouble w; /* Clip width, business card CDs */
- gdouble h; /* Clip height, business card CDs */
+ gdouble r1; /* Outer radius */
+ gdouble r2; /* Inner radius (hole) */
+ gdouble w; /* Clip width, business card CDs */
+ gdouble h; /* Clip height, business card CDs */
+ gdouble waste; /* Amount of overprint allowed. */
} cd;
} size;
gdouble w,
gdouble h,
gdouble r,
- gdouble waste);
+ gdouble x_waste,
+ gdouble y_waste);
glTemplateLabelType *gl_template_round_label_type_new (const gchar *id,
gdouble r,
glTemplate *template)
{
gchar *id;
- gdouble waste;
+ gchar *tmp;
+ gdouble x_waste, y_waste;
gdouble w, h, r;
glTemplateLabelType *label_type;
xmlNodePtr node;
- id = xmlGetProp (label_node, "id");
- waste = gl_xml_get_prop_length (label_node, "waste", 0);
- w = gl_xml_get_prop_length (label_node, "width", 0);
- h = gl_xml_get_prop_length (label_node, "height", 0);
- r = gl_xml_get_prop_length (label_node, "round", 0);
+ id = xmlGetProp (label_node, "id");
+
+ if (tmp = xmlGetProp (label_node, "waste")) {
+ /* Handle single "waste" property. */
+ x_waste = y_waste = gl_xml_get_prop_length (label_node, "waste", 0);
+ g_free (tmp);
+ } else {
+ x_waste = gl_xml_get_prop_length (label_node, "x_waste", 0);
+ y_waste = gl_xml_get_prop_length (label_node, "y_waste", 0);
+ }
+
+ w = gl_xml_get_prop_length (label_node, "width", 0);
+ h = gl_xml_get_prop_length (label_node, "height", 0);
+ r = gl_xml_get_prop_length (label_node, "round", 0);
- label_type = gl_template_rect_label_type_new (id, w, h, r, waste);
+ label_type = gl_template_rect_label_type_new (id, w, h, r, x_waste, y_waste);
gl_template_add_label_type (template, label_type);
for (node = label_node->xmlChildrenNode; node != NULL;
gl_xml_set_prop_length (node, "width", label_type->size.rect.w);
gl_xml_set_prop_length (node, "height", label_type->size.rect.h);
gl_xml_set_prop_length (node, "round", label_type->size.rect.r);
- gl_xml_set_prop_length (node, "waste", label_type->waste);
+ gl_xml_set_prop_length (node, "x_waste", label_type->size.rect.x_waste);
+ gl_xml_set_prop_length (node, "y_waste", label_type->size.rect.y_waste);
break;
case GL_TEMPLATE_SHAPE_ROUND:
node = xmlNewChild(root, ns, "Label-round", NULL);
xmlSetProp (node, "id", label_type->id);
gl_xml_set_prop_length (node, "radius", label_type->size.round.r);
- gl_xml_set_prop_length (node, "waste", label_type->waste);
+ gl_xml_set_prop_length (node, "waste", label_type->size.round.waste);
break;
case GL_TEMPLATE_SHAPE_CD:
if (label_type->size.cd.h != 0.0) {
gl_xml_set_prop_length (node, "height", label_type->size.cd.h);
}
- gl_xml_set_prop_length (node, "waste", label_type->waste);
+ gl_xml_set_prop_length (node, "waste", label_type->size.cd.waste);
break;
default:
const glTemplateLabelType *label_type;
gdouble w, h, r;
gdouble r1;
- gdouble waste;
+ gdouble waste, x_waste, y_waste;
gl_debug (DEBUG_PRINT, "START");
case GL_TEMPLATE_SHAPE_RECT:
gl_label_get_size (label, &w, &h);
r = label_type->size.rect.r;
- waste = label_type->waste;
+ x_waste = label_type->size.rect.x_waste;
+ y_waste = label_type->size.rect.y_waste;
if (r == 0.0) {
/* simple rectangle */
create_rectangle_path (pi->pc,
- -waste, -waste, w+2*waste, h+2*waste);
+ -x_waste, -y_waste,
+ w+2*x_waste, h+2*y_waste);
} else {
/* rectangle with rounded corners */
- create_rounded_rectangle_path (pi->pc, -waste, -waste,
- w+2*waste, h+2*waste, r);
+ create_rounded_rectangle_path (pi->pc,
+ -x_waste, -y_waste,
+ w+2*x_waste, h+2*y_waste, r);
}
gnome_print_clip (pi->pc);
break;
case GL_TEMPLATE_SHAPE_ROUND:
r1 = label_type->size.round.r;
- waste = label_type->waste;
+ waste = label_type->size.round.waste;
create_ellipse_path (pi->pc, r1, r1, r1+waste, r1+waste);
gnome_print_clip (pi->pc);
break;
case GL_TEMPLATE_SHAPE_CD:
- waste = label_type->waste;
+ waste = label_type->size.cd.waste;
if ((label_type->size.cd.h == 0) && (label_type->size.cd.w == 0)) {
/* CD style, round label w/ concentric round hole */
r1 = label_type->size.cd.r1;
case GL_TEMPLATE_SHAPE_CD:
gl_label_get_size (label, &w, &h);
- waste = label_type->waste;
+ waste = label_type->size.cd.waste;
r2 = label_type->size.cd.r2;
create_ellipse_path (pi->pc, w/2, h/2, r2-waste, r2-waste);
gnome_print_setrgbcolor (pi->pc, 1.0, 1.0, 1.0);
GtkWidget *rect_w_spin;
GtkWidget *rect_h_spin;
GtkWidget *rect_r_spin;
- GtkWidget *rect_waste_spin;
+ GtkWidget *rect_x_waste_spin;
+ GtkWidget *rect_y_waste_spin;
GtkWidget *rect_margin_spin;
GtkWidget *rect_w_units_label;
GtkWidget *rect_h_units_label;
GtkWidget *rect_r_units_label;
- GtkWidget *rect_waste_units_label;
+ GtkWidget *rect_x_waste_units_label;
+ GtkWidget *rect_y_waste_units_label;
GtkWidget *rect_margin_units_label;
/* Label size (round) page controls */
glade_xml_get_widget (dlg->priv->gui, "rect_h_spin");
dlg->priv->rect_r_spin =
glade_xml_get_widget (dlg->priv->gui, "rect_r_spin");
- dlg->priv->rect_waste_spin =
- glade_xml_get_widget (dlg->priv->gui, "rect_waste_spin");
+ dlg->priv->rect_x_waste_spin =
+ glade_xml_get_widget (dlg->priv->gui, "rect_x_waste_spin");
+ dlg->priv->rect_y_waste_spin =
+ glade_xml_get_widget (dlg->priv->gui, "rect_y_waste_spin");
dlg->priv->rect_margin_spin =
glade_xml_get_widget (dlg->priv->gui, "rect_margin_spin");
dlg->priv->rect_w_units_label =
glade_xml_get_widget (dlg->priv->gui, "rect_h_units_label");
dlg->priv->rect_r_units_label =
glade_xml_get_widget (dlg->priv->gui, "rect_r_units_label");
- dlg->priv->rect_waste_units_label =
- glade_xml_get_widget (dlg->priv->gui, "rect_waste_units_label");
+ dlg->priv->rect_x_waste_units_label =
+ glade_xml_get_widget (dlg->priv->gui, "rect_x_waste_units_label");
+ dlg->priv->rect_y_waste_units_label =
+ glade_xml_get_widget (dlg->priv->gui, "rect_y_waste_units_label");
dlg->priv->rect_margin_units_label =
glade_xml_get_widget (dlg->priv->gui, "rect_margin_units_label");
dlg->priv->climb_rate, 10.0*dlg->priv->climb_rate);
gtk_label_set_text (GTK_LABEL(dlg->priv->rect_r_units_label),
dlg->priv->units_string);
- gtk_spin_button_set_digits (GTK_SPIN_BUTTON(dlg->priv->rect_waste_spin),
+ gtk_spin_button_set_digits (GTK_SPIN_BUTTON(dlg->priv->rect_x_waste_spin),
dlg->priv->digits);
- gtk_spin_button_set_increments (GTK_SPIN_BUTTON(dlg->priv->rect_waste_spin),
+ gtk_spin_button_set_increments (GTK_SPIN_BUTTON(dlg->priv->rect_x_waste_spin),
dlg->priv->climb_rate, 10.0*dlg->priv->climb_rate);
- gtk_label_set_text (GTK_LABEL(dlg->priv->rect_waste_units_label),
+ gtk_label_set_text (GTK_LABEL(dlg->priv->rect_x_waste_units_label),
+ dlg->priv->units_string);
+ gtk_spin_button_set_digits (GTK_SPIN_BUTTON(dlg->priv->rect_y_waste_spin),
+ dlg->priv->digits);
+ gtk_spin_button_set_increments (GTK_SPIN_BUTTON(dlg->priv->rect_y_waste_spin),
+ dlg->priv->climb_rate, 10.0*dlg->priv->climb_rate);
+ gtk_label_set_text (GTK_LABEL(dlg->priv->rect_y_waste_units_label),
dlg->priv->units_string);
gtk_spin_button_set_digits (GTK_SPIN_BUTTON(dlg->priv->rect_margin_spin),
dlg->priv->digits);
DEFAULT_RECT_H * dlg->priv->units_per_point);
gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_r_spin),
DEFAULT_RECT_R * dlg->priv->units_per_point);
- gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_waste_spin),
+ gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_x_waste_spin),
+ DEFAULT_RECT_WASTE * dlg->priv->units_per_point);
+ gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_y_waste_spin),
DEFAULT_RECT_WASTE * dlg->priv->units_per_point);
gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_margin_spin),
DEFAULT_MARGIN * dlg->priv->units_per_point);
rect_size_page_prepare_cb (glTemplateDesigner *dlg)
{
gdouble max_w, max_h;
- gdouble w, h, r, waste, margin;
+ gdouble w, h, r, x_waste, y_waste, margin;
/* Limit label size based on already chosen page size. */
max_w = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->pg_w_spin));
w = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_w_spin));
h = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_h_spin));
r = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_r_spin));
- waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_waste_spin));
+ x_waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_x_waste_spin));
+ y_waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_y_waste_spin));
margin = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_margin_spin));
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->rect_w_spin),
dlg->priv->climb_rate, max_h);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->rect_r_spin),
0.0, MIN(max_w, max_h)/2.0);
- gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->rect_waste_spin),
+ gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->rect_x_waste_spin),
+ 0.0, MIN(max_w, max_h)/4.0);
+ gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->rect_y_waste_spin),
0.0, MIN(max_w, max_h)/4.0);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->rect_margin_spin),
0.0, MIN(max_w, max_h)/4.0);
gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_w_spin), w);
gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_h_spin), h);
gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_r_spin), r);
- gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_waste_spin), waste);
+ gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_x_waste_spin), x_waste);
+ gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_y_waste_spin), y_waste);
gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->rect_margin_spin), margin);
}
layout_page_prepare_cb (glTemplateDesigner *dlg)
{
gdouble page_w, page_h;
- gdouble w, h, waste;
+ gdouble w, h, x_waste, y_waste;
gint max_nx, max_ny;
gint nlayouts;
gdouble nx_1, ny_1, x0_1, y0_1, dx_1, dy_1;
if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON(dlg->priv->shape_rect_radio))) {
w = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_w_spin));
h = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_h_spin));
- waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_waste_spin));
+ x_waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_x_waste_spin));
+ y_waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_y_waste_spin));
}
if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON(dlg->priv->shape_round_radio))) {
w = 2*gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->round_r_spin));
h = w;
- waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->round_waste_spin));
+ x_waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->round_waste_spin));
+ y_waste = x_waste;
}
if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON(dlg->priv->shape_cd_radio))) {
w = 2*gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->cd_radius_spin));
h = w;
- waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->cd_waste_spin));
+ x_waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->cd_waste_spin));
+ y_waste = x_waste;
}
- max_nx = MAX (floor (page_w/(w + 2*waste) + DELTA), 1.0);
- max_ny = MAX (floor (page_h/(h + 2*waste) + DELTA), 1.0);
+ max_nx = MAX (floor (page_w/(w + 2*x_waste) + DELTA), 1.0);
+ max_ny = MAX (floor (page_h/(h + 2*y_waste) + DELTA), 1.0);
nx_1 = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->layout1_nx_spin));
ny_1 = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->layout1_ny_spin));
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout1_ny_spin),
1, max_ny);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout1_x0_spin),
- waste, page_w - w - waste);
+ x_waste, page_w - w - x_waste);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout1_y0_spin),
- waste, page_h - h - waste);
+ y_waste, page_h - h - y_waste);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout1_dx_spin),
- w + 2*waste, page_w - w - 2*waste);
+ w + 2*x_waste, page_w - w - 2*x_waste);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout1_dy_spin),
- h + 2*waste, page_h - h - 2*waste);
+ h + 2*y_waste, page_h - h - 2*y_waste);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout2_nx_spin),
1, max_nx);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout2_ny_spin),
1, max_ny);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout2_x0_spin),
- waste, page_w - w - waste);
+ x_waste, page_w - w - x_waste);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout2_y0_spin),
- waste, page_h - h - waste);
+ y_waste, page_h - h - y_waste);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout2_dx_spin),
- w + 2*waste, page_w - w - 2*waste);
+ w + 2*x_waste, page_w - w - 2*x_waste);
gtk_spin_button_set_range (GTK_SPIN_BUTTON (dlg->priv->layout2_dy_spin),
- h + 2*waste, page_h - h - 2*waste);
+ h + 2*y_waste, page_h - h - 2*y_waste);
gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->layout1_nx_spin), nx_1);
gtk_spin_button_set_value (GTK_SPIN_BUTTON(dlg->priv->layout1_ny_spin), ny_1);
glPaper *paper;
glTemplateLabelShape shape;
glTemplateLabelType *label_type;
- gdouble w, h, r, radius, hole, waste, margin;
+ gdouble w, h, r, radius, hole, waste, x_waste, y_waste, margin;
gint nlayouts;
gdouble nx_1, ny_1, x0_1, y0_1, dx_1, dy_1;
gdouble nx_2, ny_2, x0_2, y0_2, dx_2, dy_2;
w = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_w_spin));
h = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_h_spin));
r = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_r_spin));
- waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_waste_spin));
+ x_waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_x_waste_spin));
+ y_waste = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_y_waste_spin));
margin = gtk_spin_button_get_value (GTK_SPIN_BUTTON(dlg->priv->rect_margin_spin));
}
label_type =
gl_template_rect_label_type_new ("0",
w/upp, h/upp, r/upp,
- waste/upp);
+ x_waste/upp, y_waste/upp);
break;
case GL_TEMPLATE_SHAPE_ROUND:
label_type =
<child>
<widget class="GtkTable" id="table4">
<property name="visible">True</property>
- <property name="n_rows">5</property>
+ <property name="n_rows">6</property>
<property name="n_columns">3</property>
<property name="homogeneous">False</property>
<property name="row_spacing">12</property>
<child>
<widget class="GtkLabel" id="label86">
<property name="visible">True</property>
- <property name="label" translatable="yes">4. Waste (overprint allowed):</property>
+ <property name="label" translatable="yes">4. Horiz. waste (overprint allowed):</property>
<property name="use_underline">False</property>
<property name="use_markup">False</property>
<property name="justify">GTK_JUSTIFY_LEFT</property>
</child>
<child>
- <widget class="GtkLabel" id="rect_waste_units_label">
+ <widget class="GtkLabel" id="rect_x_waste_units_label">
<property name="visible">True</property>
<property name="label" translatable="yes">inches</property>
<property name="use_underline">False</property>
</child>
<child>
- <widget class="GtkSpinButton" id="rect_waste_spin">
+ <widget class="GtkSpinButton" id="rect_x_waste_spin">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="climb_rate">0.01</property>
<child>
<widget class="GtkLabel" id="label101">
<property name="visible">True</property>
- <property name="label" translatable="yes">5. Margin</property>
+ <property name="label" translatable="yes">6. Margin</property>
<property name="use_underline">False</property>
<property name="use_markup">False</property>
<property name="justify">GTK_JUSTIFY_LEFT</property>
<packing>
<property name="left_attach">0</property>
<property name="right_attach">1</property>
- <property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
+ <property name="top_attach">5</property>
+ <property name="bottom_attach">6</property>
<property name="x_options">fill</property>
<property name="y_options"></property>
</packing>
</child>
+ <child>
+ <widget class="GtkSpinButton" id="rect_margin_spin">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="climb_rate">0.01</property>
+ <property name="digits">0</property>
+ <property name="numeric">False</property>
+ <property name="update_policy">GTK_UPDATE_ALWAYS</property>
+ <property name="snap_to_ticks">False</property>
+ <property name="wrap">False</property>
+ <property name="adjustment">0 0 100 1 10 10</property>
+ </widget>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">5</property>
+ <property name="bottom_attach">6</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+
<child>
<widget class="GtkLabel" id="rect_margin_units_label">
<property name="visible">True</property>
<packing>
<property name="left_attach">2</property>
<property name="right_attach">3</property>
- <property name="top_attach">4</property>
- <property name="bottom_attach">5</property>
+ <property name="top_attach">5</property>
+ <property name="bottom_attach">6</property>
<property name="x_options">fill</property>
<property name="y_options"></property>
</packing>
</child>
<child>
- <widget class="GtkSpinButton" id="rect_margin_spin">
+ <widget class="GtkSpinButton" id="rect_y_waste_spin">
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="climb_rate">0.01</property>
<property name="y_options"></property>
</packing>
</child>
+
+ <child>
+ <widget class="GtkLabel" id="rect_y_waste_units_label">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">inches</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </widget>
+ <packing>
+ <property name="left_attach">2</property>
+ <property name="right_attach">3</property>
+ <property name="top_attach">4</property>
+ <property name="bottom_attach">5</property>
+ <property name="x_options">fill</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+
+ <child>
+ <widget class="GtkLabel" id="label107">
+ <property name="visible">True</property>
+ <property name="label" translatable="yes">5. Vert. waste (overprint allowed):</property>
+ <property name="use_underline">False</property>
+ <property name="use_markup">False</property>
+ <property name="justify">GTK_JUSTIFY_LEFT</property>
+ <property name="wrap">False</property>
+ <property name="selectable">False</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0.5</property>
+ <property name="xpad">0</property>
+ <property name="ypad">0</property>
+ </widget>
+ <packing>
+ <property name="left_attach">0</property>
+ <property name="right_attach">1</property>
+ <property name="top_attach">4</property>
+ <property name="bottom_attach">5</property>
+ <property name="x_options">fill</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
</widget>
<packing>
<property name="padding">0</property>
h = gl_xml_get_prop_length (label_node, "height", 0);
r = gl_xml_get_prop_length (label_node, "round", 0);
label_type =
- gl_template_rect_label_type_new ("0", w, h, r, 0.0);
+ gl_template_rect_label_type_new ("0", w, h, r, 0.0, 0.0);
break;
case GL_TEMPLATE_SHAPE_ROUND: