]> git.sur5r.net Git - glabels/commitdiff
2005-01-22 Jim Evins <evins@snaught.com>
authorJim Evins <evins@snaught.com>
Sat, 22 Jan 2005 19:22:11 +0000 (19:22 +0000)
committerJim Evins <evins@snaught.com>
Sat, 22 Jan 2005 19:22:11 +0000 (19:22 +0000)
* MESSAGE-OF-DOOM:
Added.
* Makefile.am:
Added MESSAGE-OF-DOOM to EXTRA_DIST.
* NEWS:
Final prep for 2.1.0.
* configure.in:
Set version to 2.1.0.  Output MESSAGE-OF-DOOM.
* glabels.spec.in:
Added '--remove-original' flag to desktop-file-install, so that there is
only one menu entry.

git-svn-id: https://glabels.svn.sourceforge.net/svnroot/glabels/trunk@497 f5e0f49d-192f-0410-a22d-a8d8700d0965

66 files changed:
glabels2/AUTHORS
glabels2/ChangeLog
glabels2/MESSAGE-OF-DOOM [new file with mode: 0644]
glabels2/Makefile.am
glabels2/NEWS
glabels2/configure.in
glabels2/data/desktop/glabels.desktop.in
glabels2/data/dtd/glabels-2.0.dtd
glabels2/data/glade/object-editor.glade
glabels2/data/man/glabels.1
glabels2/data/mime/glabels.keys.in
glabels2/data/pixmaps/Makefile.am
glabels2/data/pixmaps/glabels-about-logo.png
glabels2/data/pixmaps/glabels-application-x-glabels.png [new file with mode: 0644]
glabels2/data/pixmaps/glabels-icon.png [deleted file]
glabels2/data/pixmaps/glabels-logo.png [deleted file]
glabels2/data/pixmaps/glabels-splash.png [new file with mode: 0644]
glabels2/data/pixmaps/glabels.png
glabels2/data/templates/avery-iso-templates.xml
glabels2/data/templates/misc-iso-templates.xml
glabels2/data/templates/misc-us-templates.xml
glabels2/data/ui/glabels-ui.xml
glabels2/glabels.spec.in
glabels2/mkinstalldirs [deleted file]
glabels2/po/fr.po
glabels2/src/Makefile.am
glabels2/src/color.c
glabels2/src/color.h
glabels2/src/debug.c
glabels2/src/debug.h
glabels2/src/glabels-batch.c
glabels2/src/glabels.c
glabels2/src/label-barcode.c
glabels2/src/label-box.c
glabels2/src/label-ellipse.c
glabels2/src/label-line.c
glabels2/src/label-object.c
glabels2/src/label-object.h
glabels2/src/label-text.c
glabels2/src/object-editor-bc-page.c
glabels2/src/object-editor-fill-page.c
glabels2/src/object-editor-line-page.c
glabels2/src/object-editor-private.h
glabels2/src/object-editor-text-page.c
glabels2/src/object-editor.c
glabels2/src/object-editor.h
glabels2/src/prefs-model.c
glabels2/src/prefs-model.h
glabels2/src/print.c
glabels2/src/print.h
glabels2/src/splash.c
glabels2/src/template-designer.c
glabels2/src/ui-property-bar.c
glabels2/src/ui.c
glabels2/src/view-barcode.c
glabels2/src/view-box.c
glabels2/src/view-ellipse.c
glabels2/src/view-image.c
glabels2/src/view-line.c
glabels2/src/view-text.c
glabels2/src/view.c
glabels2/src/view.h
glabels2/src/window.c
glabels2/src/xml-label-04.c
glabels2/src/xml-label-191.c
glabels2/src/xml-label.c

index a837a3af48d892557ea8651d8b1f411a045893f1..7271b17513ee5a290323d51752ff33b36ea41a24 100644 (file)
@@ -40,6 +40,7 @@ These are copyright:
         * Copyright (C) 1999-2000 Sven Neumann <sven@gimp.org>
 
 Glabels includes contributions from:
+       Frederic Ruaudel  <grumz@users.sf.net>
        Emmanuel Pacaud <emmanuel.pacaud@univ-poitiers.fr>
        Wayne Schuller <k_wayne@linuxpower.org>
        nestor di <nestordi@usuarios.retecal.es>  --  excellent splash screen
@@ -53,7 +54,8 @@ Glabels includes contributions from:
 
 Translations:
 
-       Olivier Berger <oberger@april.org> -- French
+       Olivier Berger <oberger@april.org> -- French (original)
+       Florent Morel <florent@taket.org> -- French (2.0.2)
        Marcus Bauer <m@7n7.de> -- German (original)
        Christian Neumair <christian-neumair@web.de> -- German (1.89.1)
        Takeshi AIHANA <aihana@gnome.gr.jp> -- Japanese
@@ -139,5 +141,8 @@ particular products (I apologize if I have missed anybody):
        JBadger
        Frank Altpeter
        Matthew J. Lockner
+       Larry Harriman
+       Juan Carlos Valero
+       Nick Hill
 
 And many others for their many helpful suggestions and bug reports -- thanks.
index f16997e1ffc8101b49a132ca9ad4dd13b1969b90..2ad96346df53d6d0a398e51568b69b806920d962 100644 (file)
@@ -1,3 +1,262 @@
+2005-01-22  Jim Evins  <evins@snaught.com>
+
+       * MESSAGE-OF-DOOM:
+               Added.
+       * Makefile.am:
+               Added MESSAGE-OF-DOOM to EXTRA_DIST.
+       * NEWS:
+               Final prep for 2.1.0.
+       * configure.in:
+               Set version to 2.1.0.  Output MESSAGE-OF-DOOM.
+       * glabels.spec.in:
+               Added '--remove-original' flag to desktop-file-install, so that there is
+               only one menu entry.
+       
+2005-01-20  Jim Evins  <evins@snaught.com>
+
+       * data/glade/object-editor.glade:
+               - Font family entry should not be editable.
+               - img_key_entry should have sensitivity=YES, so that it follows the
+                 sensitivity of img_key_combo.
+       
+2005-01-19  Jim Evins  <evins@snaught.com>
+
+       * AUTHORS:
+               Give credit to Frederic Ruaudel for the color merge patches.
+
+2005-01-18  Frederic Ruaudel  <grumz@users.sf.net>
+       Add support to merge color for all other color attribute (Feature 
+       Requests item #1008635. If the data is invalid, the color used is transparent 
+       (GL_COLOR_NONE). The format     for color in merge data file are those accepted 
+       by gdk_color_parse() these include name for a color from rgb.txt, such as 
+       DarkSlateGray, or a hex specification such as #305050. File format has been 
+       changed but backward compatibility is preserved for all format. For
+       box/ellipse/line, keep attribute "line_color" for static color or replace by
+       "line_color_field" for merge data. For text/barcode objects, keep attribute
+       "color" for static color or replace by "color_field" for merge data. In the
+       edit canvas window, merged color are represented by half-transparent black
+       line/area.
+       * data/dtd/glabels-2.0.dtd:
+               Added line_color_field to line_attrs. Added color_field to 
+               Object-barcode and Span.
+       * data/glade/object-editor.glade:
+               Modify the layout of the editor to add merge possibility to color options
+       * src/color.c:
+               Fix a copy/paste error in a comment
+       * src/color.h:
+               Add default color for merge color representation in the editor canvas.
+       * src/label-barcode.c:
+       * src/object-editor-bc-page.c:
+       * src/view-barcode.c:
+               Add merge color support for barcode color.
+       * src/label-box.c:
+       * src/view-box.c:
+               Add merge color support for box border color.
+       * src/label-ellipse.c:
+       * src/view-ellipse.c:
+               Add merge color support for ellipse border color.
+       * src/label-line.c:
+       * src/view-line.c:
+               Add merge color support for line color.
+       * src/label-object.c:
+       * src/label-object.h:
+       * src/object-editor.c:
+       * src/object-editor.h:
+       * src/ui-property-bar.c:
+       * src/view.c:
+       * src/view.h:
+       * src/xml-label-04.c:
+       * src/xml-label-191.c:
+               Add support for merging to other color attribute.
+       * src/label-text.c:
+       * src/object-editor-text-page.c:
+       * src/view-text.c:
+               Add merge color support for text color.
+       * src/object-editor-fill-page.c:
+               Change a blocked handler that didn't match the good widget. Fix the type
+               of some debug message.
+       * src/object-editor-line-page.c:
+               Add merging support to line color option.
+       * src/object-editor-private.h:
+               Add variables for new widget.
+       * src/print.c:
+               Modify the draw functions to get merge data if needed.
+       * src/window.c:
+               Change the default size of the window in order to see all widget in the
+               "text style tab" of the editor.
+       * src/xml-label.c:
+               Modify the parser to record/retreive the field value for objects that need
+               "color" attribute. For box/ellipse/line, keep attribute "line_color" for 
+               static color or replace by "line_color_field" for merge data. For 
+               text/barcode objects, keep attribute "color" for static color or replace 
+               by "color_field" for merge data.
+       
+2005-01-17  Jim Evins  <evins@snaught.com>
+
+       * src/view.c: (screen_changed_cb):
+               Don't do anything if we don't have a screen.
+
+2005-01-06  Jim Evins  <evins@snaught.com>
+
+       * src/view.c: (get_home_scale):
+               Fixed bad call to gtk_widget_has_screen() -- huh?.
+
+2005-01-06  Jim Evins  <evins@snaught.com>
+
+       * data/dtd/glabels-2.0.dtd:
+               Added fill_color_field to fill_attrs.  Also added xmlns attribute to all
+               top-level elements.
+
+2005-01-06  Jim Evins  <evins@snaught.com>
+
+       * data/glade/object-editor.glade:
+               Set entries for fill and data field key dropdowns to NOT editable.
+       * src/view-box.c: (construct_properties_editor):
+       * src/view-ellipse.c: (construct_properties_editor):
+               Update object editor when label's merge property has changed.
+       * src/xml-label.c: (xml_parse_object_ellipse):
+               Completed the merge color support for the ellipse item.
+
+2005-01-06  Frederic Ruaudel  <grumz@users.sf.net>
+
+       Add support to merge color for object that have a "Fill color" attribute (Feature 
+       Requests item #1008635. If the data is invalid, the color used is transparent 
+       (GL_COLOR_NONE). The format     for color in merge data file are those accepted 
+       by gdk_color_parse() these include name for a color from rgb.txt, such as 
+       DarkSlateGray, or a hex specification such as #305050. File format has been 
+       changed but backward compatibility is preserved for all format. For box/ellipse, 
+       keep attribute "fill_color" for static  color or replace by "fill_color_field" 
+       for merge data.
+
+       * data/glade/object-editor.glade:
+               Modify "Fill" tab to add the merge key combo and convert the labels into 
+               radio button.
+       * src/color.h:
+       * src/color.c:
+               Add "glColorNode" structure and associated functions to manage it. This 
+               structure is equivalent for color than the "glTextNode". It holds the color
+               and the key field.
+       * src/label-object.h:
+       * src/label-object.c:
+       * src/label-box.c:
+       * src/label-ellipse.c:
+       * src/ui-property-bar.c:
+       * src/view.h:
+       * src/view.c:
+       * src/view-box.c:
+       * src/view-ellipse.c:
+       * src/xml-label-04.c:
+       * src/xml-label-191.c:
+               Change functions of objects that have a "fill color" attribute to use the 
+               new "glColorNode" structure. Use barcode code as example.
+       * src/Makefile.am:
+               Add the color.[ch] file to glabels_batch binary that now need support for 
+               "glColorNode".
+       * src/object-editor.h:
+       * src/object-editor.c:
+       * src/object-editor-fill-page.c:
+               Manage the new widget of the editor's "Fill" tab : key combo and radio button
+               to choose between static color or merge key. Use barcode code as example.
+       * src/object-editor-private.h:
+               Add new widget in the "_glObjectEditorPrivate" structure.
+       * src/print.c:
+               Modify the draw functions to get merge data if needed.
+       * src/xml-label.c:
+               Modify the parser to record/retreive the field value for objects that need
+               "Fill color" attribute. For box/ellipse, put attribute "fill_color" for static
+               color or "fill_color_field" for merge data.             
+       
+2005-01-04  Jim Evins  <evins@snaught.com>
+
+       * AUTHORS:
+       * data/templates/avery-iso-templates.xml:
+       * data/templates/misc-iso-templates.xml:
+       * data/templates/misc-us-templates.xml:
+               Added templates, submitted by Larry Harriman, Juan Carlos Valero, and
+               Nick Hill.
+
+2004-11-26  Jim Evins  <evins@snaught.com>
+
+       * AUTHORS:
+       * po/fr.po:
+               Updated french translations provided by Florent Morel <florent@taket.org>.
+       * src/view-barcode.c:
+       * src/view-box.c:
+       * src/view-ellipse.c:
+       * src/view-image.c:
+       * src/view-line.c:
+       * src/view-text.c:
+               Added '#include <config.h>' -- HAVE_*GETTEXT macros were not defined and
+               thus _() strings were not being translated.
+
+2004-11-14  Jim Evins  <evins@snaught.com>
+
+       * src/debug.h:
+       * src/debug.c: (gl_debug_init), (gl_debug):
+               Borrowed from gedit:  use environmental variables to select debug
+               sections.
+       * src/splash.c:
+               Removed unused include of debug.h.
+       * src/glabels.c: (main):
+               Added call to gl_debug_init(), and removed debug clutter from command line
+               options.
+       * src/glabels-batch.c: (main):
+               Added call to gl_debug_init().
+
+2004-11-13  Jim Evins  <evins@snaught.com>
+
+       Drawing and property toolbars were being initialized with the "icons and text"
+       look in Fedora Core 3.  Even though none of the buttons had any text attached to
+       them, the buttons were being sized as if they were.  This led to less real estate
+       for the property editor, leading to Bug #1064630.  The
+       
+       * data/ui/glabels-ui.xml:
+               Added explicit "look" property to both drawing and property toolbars.
+       * src/prefs-model.c: (gl_prefs_model_save_settings),
+       (gl_prefs_model_load_settings):
+       * src/prefs-model.h:
+               Removed drawing_toolbar_button_style configuration parameter.
+       * src/ui.c: (view_menu_item_toggled_cb),
+       (set_app_drawing_toolbar_style):
+               Do not attempt to adjust look property of the drawing toolbar.
+
+2004-10-28  Jim Evins  <evins@snaught.com>
+
+       * data/pixmaps/glabels-about-logo.png:
+               Updated about logo.
+       
+2004-10-28  Jim Evins  <evins@snaught.com>
+
+       * data/man/glabels.1:
+       * src/glabels-batch.c: (main):
+       * src/print.h:
+       * src/print.c: (gl_print_batch):
+
+               Added option to glabels-batch to select the first label to begin
+               printing on.
+
+2004-09-26  Jim Evins  <evins@snaught.com>
+
+       * data/desktop/glabels.desktop.in:
+               Point to app icon, "glabels.png"
+       * data/mime/glabels.keys.in:
+               Point at mime icon, "glabels-application-x-glabels.png"
+       * data/pixmaps/Makefile.am:
+               Added glabels_app_icondir.  Renamed icons.
+       * data/pixmaps/glabels.png:
+               New cleaned up app icon.  Deleted glabels-icon.png.
+       * data/pixmaps/glabels-application-x-glabels.png:
+               New mime icon.
+       * data/pixmaps/glabels-splash.png:
+               Renamed glabels-logo to glabels-splash to be more correct about role.
+       * src/glabels.c:
+       * src/template-designer.c:
+               Point at app icon, "glabels.png"
+       * src/splash.c:
+               Point at renamed splash image, "glabels-splash.png"
+
 2004-08-22  Jim Evins  <evins@snaught.com>
 
        * AUTHORS:
        * src/xml-template.h:
                Added function gl_xml_template_write_template_to_file(), used
                in gl_template_register().
-
-       
diff --git a/glabels2/MESSAGE-OF-DOOM b/glabels2/MESSAGE-OF-DOOM
new file mode 100644 (file)
index 0000000..9ddbfaa
--- /dev/null
@@ -0,0 +1,15 @@
+ *** IMPORTANT *** 
+
+This is an unstable (development) version of glabels. 
+It is for testing purposes only.
+
+Please, DO NOT use it in a production environment.
+It will probably crash and you will lose your data.
+
+If you are looking for a stable release of glabels, it can be downloaded from:
+
+  http://glabels.sourceforge.net/download
+
+ *** END OF WARNING ***
+
+
index 3d5476a1a0e27cefa3e251afb8311999de442705..86ea9081f7948968e40f21b4afe4cdf6f5c88801 100644 (file)
@@ -18,5 +18,6 @@ EXTRA_DIST = \
        intltool-merge.in \
        intltool-update.in \
        glabels.spec.in \
-       glabels.spec
+       glabels.spec \
+       MESSAGE-OF-DOOM
 
index e58bc67789fbcae1533c30ac5c7c17283ed5030a..3f4bb99f81c2cd1367e0dd5a89a5bc4b045a6e58 100644 (file)
@@ -1,3 +1,25 @@
+* gLabels 2.1.0 (unstable) release.  Release date 2005-01-22.
+
+- Added ability to select color from merge source (Frederic Ruaudel)
+- See 2.0.2
+
+* gLabels 2.0.2 release.  Release date 2005-01-22.
+
+- Desktop file reconciled with desktop-entry-spec
+- New cleaned-up icon
+- Added option to glabels-batch to allow selection of first label.
+- Added options to glabels-batch to allow selection of merge source and crop marks.
+  (José Dapena Paz)
+- Updated french translation (Florent Morel)
+- Fixed translation problem with object editor labels
+- Minor bug fixes and cleanup
+- New templates
+
+* gLabels 2.0.1 release.  Release date 2004-08-15.
+
+- Fixed crash when reading some labels created with 1.93.x.
+- Updated japanese translations (Takeshi AIHANA)
+- Fixed crash from improperly freeing translation strings.
 
 * gLabels 2.0.0 release.  Release date 2004-08-09.
 
index ddee81c34d3cc648b52b9889577775b247821a96..937467f5daaae5e5ee61210eda4e6dace4ebd1c1 100644 (file)
@@ -2,7 +2,7 @@ dnl Process this file with autoconf to produce a configure script.
 
 AC_PREREQ(2.52)
 
-AC_INIT(glabels, 2.1cvs, http://sourceforge.net/tracker/?func=add&group_id=46122&atid=445116)
+AC_INIT(glabels, 2.1.0, http://sourceforge.net/tracker/?func=add&group_id=46122&atid=445116)
 AC_CONFIG_SRCDIR(src/glabels.c)
 AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION)
 
@@ -179,3 +179,6 @@ Configuration:
         Compiler:               ${CC} 
 
 "
+
+cat ${srcdir}/MESSAGE-OF-DOOM
+
index 58878c9129cf44e06abe947da8ecb4f2d7597643..be70f928d0ef03eda29442e1d458d2745709a6ec 100644 (file)
@@ -3,7 +3,7 @@ Encoding=UTF-8
 _Name=gLabels Label Designer
 _Comment=Create labels, business cards and media covers
 Exec=glabels %F
-Icon=glabels/glabels-icon.png
+Icon=glabels.png
 Terminal=false
 Type=Application
 Categories=GNOME;Application;Office;
index fb8fa47d583e18aa141cce6a6d206c228b9847be..5d8047a3ea2d541e7e0e90494faeb8d69f2852ce 100644 (file)
@@ -57,6 +57,9 @@
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
 <!ELEMENT Glabels-paper-sizes (Paper-size*)>
+<!ATTLIST Glabels-paper-sizes
+                 xmlns           %STRING_TYPE;           #IMPLIED
+>
 
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
@@ -64,6 +67,9 @@
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
 <!ELEMENT Glabels-templates (Template*)>
+<!ATTLIST Glabels-templates
+                 xmlns           %STRING_TYPE;           #IMPLIED
+>
 
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
@@ -71,6 +77,9 @@
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
 <!ELEMENT Glabels-document (Template, Objects+, Merge?, Data*)>
+<!ATTLIST Glabels-document
+                 xmlns           %STRING_TYPE;           #IMPLIED
+>
 
 <!-- :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
 <!-- Paper size                                                           -->
 >
 
 <!ENTITY % line_attrs
-                 "line_width      %LENGTH_TYPE;          #IMPLIED
-                  line_color      %UINT_TYPE;            #IMPLIED"
+                 "line_width       %LENGTH_TYPE;          #IMPLIED
+                  line_color       %UINT_TYPE;            #IMPLIED
+                  line_color_field %STRING_TYPE;          #IMPLIED"
 >
 
 <!ENTITY % fill_attrs
-                 "fill_color      %UINT_TYPE;            #IMPLIED"
+                 "fill_color       %UINT_TYPE;           #IMPLIED
+                  fill_color_field %STRING_TYPE;         #IMPLIED"
 >
 
 <!ENTITY % affine_attrs
 <!ATTLIST Object-barcode
                  %position_attrs;
                  %size_attrs;
-                 style           %BC_STYLE_TYPE;         #REQUIRED
-                 text            %BOOLEAN_TYPE;          #REQUIRED
-                 checksum        %BOOLEAN_TYPE;          #REQUIRED
-                 color           %UINT_TYPE;             #REQUIRED
-                 data            %STRING_TYPE;           #IMPLIED
-                 field           %STRING_TYPE;           #IMPLIED
-                 format          %UINT_TYPE;             #IMPLIED
+                 style            %BC_STYLE_TYPE;         #REQUIRED
+                 text             %BOOLEAN_TYPE;          #REQUIRED
+                 checksum         %BOOLEAN_TYPE;          #REQUIRED
+                 color            %UINT_TYPE;             #IMPLIED
+                 color_field      %STRING_TYPE;           #IMPLIED
+                 data             %STRING_TYPE;           #IMPLIED
+                 field            %STRING_TYPE;           #IMPLIED
+                 format           %UINT_TYPE;             #IMPLIED
                  %affine_attrs;
                  %shadow_attrs;
 >
                  font_weight     %FONT_WEIGHT_TYPE;      #IMPLIED
                  font_italic     %BOOLEAN_TYPE;          #IMPLIED
                  color           %UINT_TYPE;             #IMPLIED
+                                color_field     %STRING_TYPE;           #IMPLIED
                  line_spacing    %LENGTH_TYPE;           #IMPLIED
 >
 
 >
 
 <!ELEMENT NL EMPTY>
-
-
index 797d2636b42ba30a30d3a0df6334a051292c0948..cffea583d83fb0b3293bcb44552de1fda0c120e5 100644 (file)
   <property name="modal">False</property>
   <property name="resizable">True</property>
   <property name="destroy_with_parent">False</property>
+  <property name="decorated">True</property>
+  <property name="skip_taskbar_hint">False</property>
+  <property name="skip_pager_hint">False</property>
+  <property name="type_hint">GDK_WINDOW_TYPE_HINT_DIALOG</property>
+  <property name="gravity">GDK_GRAVITY_NORTH_WEST</property>
   <property name="has_separator">True</property>
 
   <child internal-child="vbox">
@@ -34,6 +39,7 @@
              <property name="label">gtk-close</property>
              <property name="use_stock">True</property>
              <property name="relief">GTK_RELIEF_NORMAL</property>
+             <property name="focus_on_click">True</property>
              <property name="response_id">-7</property>
            </widget>
          </child>
                              <property name="visible">True</property>
                              <property name="can_focus">True</property>
                              <property name="editable">True</property>
+                             <property name="overwrite">False</property>
+                             <property name="accepts_tab">True</property>
                              <property name="justification">GTK_JUSTIFY_LEFT</property>
                              <property name="wrap_mode">GTK_WRAP_NONE</property>
                              <property name="cursor_visible">True</property>
                          <property name="label" translatable="yes">Insert merge field</property>
                          <property name="use_underline">True</property>
                          <property name="relief">GTK_RELIEF_NORMAL</property>
+                         <property name="focus_on_click">True</property>
                        </widget>
                        <packing>
                          <property name="padding">0</property>
                        </packing>
                      </child>
 
-                     <child>
-                       <widget class="GtkLabel" id="text_color_label">
-                         <property name="visible">True</property>
-                         <property name="label" translatable="yes">Color:</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">3</property>
-                         <property name="bottom_attach">4</property>
-                         <property name="x_options">fill</property>
-                         <property name="y_options"></property>
-                       </packing>
-                     </child>
-
                      <child>
                        <widget class="GtkLabel" id="text_align_label">
                          <property name="visible">True</property>
                                <widget class="GtkEntry" id="text_family_entry">
                                  <property name="visible">True</property>
                                  <property name="can_focus">True</property>
-                                 <property name="editable">True</property>
+                                 <property name="editable">False</property>
                                  <property name="visibility">True</property>
                                  <property name="max_length">0</property>
                                  <property name="text" translatable="yes"></property>
                              <property name="visible">True</property>
                              <property name="can_focus">True</property>
                              <property name="relief">GTK_RELIEF_NORMAL</property>
+                             <property name="focus_on_click">True</property>
                              <property name="active">False</property>
                              <property name="inconsistent">False</property>
 
                              <property name="visible">True</property>
                              <property name="can_focus">True</property>
                              <property name="relief">GTK_RELIEF_NORMAL</property>
+                             <property name="focus_on_click">True</property>
                              <property name="active">False</property>
                              <property name="inconsistent">False</property>
 
                              <property name="visible">True</property>
                              <property name="can_focus">True</property>
                              <property name="relief">GTK_RELIEF_NORMAL</property>
+                             <property name="focus_on_click">True</property>
                              <property name="active">False</property>
                              <property name="inconsistent">False</property>
 
                              <property name="visible">True</property>
                              <property name="can_focus">True</property>
                              <property name="relief">GTK_RELIEF_NORMAL</property>
+                             <property name="focus_on_click">True</property>
                              <property name="active">False</property>
                              <property name="inconsistent">False</property>
 
                              <property name="visible">True</property>
                              <property name="can_focus">True</property>
                              <property name="relief">GTK_RELIEF_NORMAL</property>
+                             <property name="focus_on_click">True</property>
                              <property name="active">False</property>
                              <property name="inconsistent">False</property>
 
                        </packing>
                      </child>
 
-                     <child>
-                       <widget class="GtkHBox" id="hbox3">
-                         <property name="visible">True</property>
-                         <property name="homogeneous">False</property>
-                         <property name="spacing">12</property>
-
-                         <child>
-                           <widget class="Custom" id="text_color_combo">
-                             <property name="visible">True</property>
-                             <property name="creation_function">gl_object_editor_construct_color_combo</property>
-                             <property name="int1">2</property>
-                             <property name="int2">0</property>
-                             <property name="last_modification_time">Sun, 16 Nov 2003 06:52:23 GMT</property>
-                           </widget>
-                           <packing>
-                             <property name="padding">0</property>
-                             <property name="expand">False</property>
-                             <property name="fill">False</property>
-                           </packing>
-                         </child>
-                       </widget>
-                       <packing>
-                         <property name="left_attach">1</property>
-                         <property name="right_attach">2</property>
-                         <property name="top_attach">3</property>
-                         <property name="bottom_attach">4</property>
-                         <property name="x_options">fill</property>
-                         <property name="y_options">fill</property>
-                       </packing>
-                     </child>
-
                      <child>
                        <widget class="GtkHBox" id="hbox31">
                          <property name="visible">True</property>
                          <property name="label" translatable="yes">Allow merge to automatically shrink text</property>
                          <property name="use_underline">True</property>
                          <property name="relief">GTK_RELIEF_NORMAL</property>
+                         <property name="focus_on_click">True</property>
                          <property name="active">False</property>
                          <property name="inconsistent">False</property>
                          <property name="draw_indicator">True</property>
                          <property name="y_options"></property>
                        </packing>
                      </child>
+
+                     <child>
+                       <widget class="GtkVBox" id="vbox3">
+                         <property name="visible">True</property>
+                         <property name="homogeneous">False</property>
+                         <property name="spacing">6</property>
+
+                         <child>
+                           <widget class="GtkHBox" id="hbox42">
+                             <property name="visible">True</property>
+                             <property name="homogeneous">False</property>
+                             <property name="spacing">6</property>
+
+                             <child>
+                               <widget class="GtkRadioButton" id="text_color_radio">
+                                 <property name="visible">True</property>
+                                 <property name="can_focus">True</property>
+                                 <property name="label" translatable="yes"></property>
+                                 <property name="use_underline">True</property>
+                                 <property name="relief">GTK_RELIEF_NORMAL</property>
+                                 <property name="focus_on_click">True</property>
+                                 <property name="active">False</property>
+                                 <property name="inconsistent">False</property>
+                                 <property name="draw_indicator">True</property>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">False</property>
+                                 <property name="fill">False</property>
+                               </packing>
+                             </child>
+
+                             <child>
+                               <widget class="GtkHBox" id="hbox43">
+                                 <property name="visible">True</property>
+                                 <property name="homogeneous">False</property>
+                                 <property name="spacing">12</property>
+
+                                 <child>
+                                   <widget class="Custom" id="text_color_combo">
+                                     <property name="visible">True</property>
+                                     <property name="creation_function">gl_object_editor_construct_color_combo</property>
+                                     <property name="int1">2</property>
+                                     <property name="int2">0</property>
+                                     <property name="last_modification_time">Sun, 16 Nov 2003 06:52:23 GMT</property>
+                                   </widget>
+                                   <packing>
+                                     <property name="padding">0</property>
+                                     <property name="expand">False</property>
+                                     <property name="fill">False</property>
+                                   </packing>
+                                 </child>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">True</property>
+                                 <property name="fill">True</property>
+                               </packing>
+                             </child>
+                           </widget>
+                           <packing>
+                             <property name="padding">0</property>
+                             <property name="expand">True</property>
+                             <property name="fill">True</property>
+                           </packing>
+                         </child>
+
+                         <child>
+                           <widget class="GtkHBox" id="hbox44">
+                             <property name="visible">True</property>
+                             <property name="homogeneous">False</property>
+                             <property name="spacing">6</property>
+
+                             <child>
+                               <widget class="GtkRadioButton" id="text_color_key_radio">
+                                 <property name="visible">True</property>
+                                 <property name="can_focus">True</property>
+                                 <property name="label" translatable="yes">Key:</property>
+                                 <property name="use_underline">True</property>
+                                 <property name="relief">GTK_RELIEF_NORMAL</property>
+                                 <property name="focus_on_click">True</property>
+                                 <property name="active">False</property>
+                                 <property name="inconsistent">False</property>
+                                 <property name="draw_indicator">True</property>
+                                 <property name="group">text_color_radio</property>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">False</property>
+                                 <property name="fill">False</property>
+                               </packing>
+                             </child>
+
+                             <child>
+                               <widget class="GtkHBox" id="hbox45">
+                                 <property name="visible">True</property>
+                                 <property name="homogeneous">False</property>
+                                 <property name="spacing">12</property>
+
+                                 <child>
+                                   <widget class="GtkCombo" id="text_color_key_combo">
+                                     <property name="width_request">80</property>
+                                     <property name="visible">True</property>
+                                     <property name="value_in_list">False</property>
+                                     <property name="allow_empty">True</property>
+                                     <property name="case_sensitive">False</property>
+                                     <property name="enable_arrow_keys">True</property>
+                                     <property name="enable_arrows_always">False</property>
+
+                                     <child internal-child="entry">
+                                       <widget class="GtkEntry" id="text_color_key_entry">
+                                         <property name="visible">True</property>
+                                         <property name="can_focus">True</property>
+                                         <property name="editable">False</property>
+                                         <property name="visibility">True</property>
+                                         <property name="max_length">0</property>
+                                         <property name="text" translatable="yes"></property>
+                                         <property name="has_frame">True</property>
+                                         <property name="invisible_char" translatable="yes">*</property>
+                                         <property name="activates_default">False</property>
+                                       </widget>
+                                     </child>
+
+                                     <child internal-child="list">
+                                       <widget class="GtkList" id="list4">
+                                         <property name="visible">True</property>
+                                         <property name="selection_mode">GTK_SELECTION_BROWSE</property>
+                                       </widget>
+                                     </child>
+                                   </widget>
+                                   <packing>
+                                     <property name="padding">0</property>
+                                     <property name="expand">False</property>
+                                     <property name="fill">False</property>
+                                   </packing>
+                                 </child>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">True</property>
+                                 <property name="fill">True</property>
+                               </packing>
+                             </child>
+                           </widget>
+                           <packing>
+                             <property name="padding">0</property>
+                             <property name="expand">True</property>
+                             <property name="fill">True</property>
+                           </packing>
+                         </child>
+                       </widget>
+                       <packing>
+                         <property name="left_attach">1</property>
+                         <property name="right_attach">2</property>
+                         <property name="top_attach">3</property>
+                         <property name="bottom_attach">4</property>
+                         <property name="x_options">fill</property>
+                         <property name="y_options">fill</property>
+                       </packing>
+                     </child>
+
+                     <child>
+                       <widget class="GtkLabel" id="text_color_label">
+                         <property name="visible">True</property>
+                         <property name="label" translatable="yes">Color:</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.14</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">3</property>
+                         <property name="bottom_attach">4</property>
+                         <property name="x_options">fill</property>
+                         <property name="y_options">fill</property>
+                       </packing>
+                     </child>
                    </widget>
                    <packing>
                      <property name="padding">0</property>
                        </packing>
                      </child>
 
+                     <child>
+                       <widget class="GtkVBox" id="vbox2">
+                         <property name="visible">True</property>
+                         <property name="homogeneous">False</property>
+                         <property name="spacing">6</property>
+
+                         <child>
+                           <widget class="GtkHBox" id="hbox38">
+                             <property name="visible">True</property>
+                             <property name="homogeneous">False</property>
+                             <property name="spacing">6</property>
+
+                             <child>
+                               <widget class="GtkRadioButton" id="line_color_radio">
+                                 <property name="visible">True</property>
+                                 <property name="can_focus">True</property>
+                                 <property name="label" translatable="yes"></property>
+                                 <property name="use_underline">True</property>
+                                 <property name="relief">GTK_RELIEF_NORMAL</property>
+                                 <property name="focus_on_click">True</property>
+                                 <property name="active">False</property>
+                                 <property name="inconsistent">False</property>
+                                 <property name="draw_indicator">True</property>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">False</property>
+                                 <property name="fill">False</property>
+                               </packing>
+                             </child>
+
+                             <child>
+                               <widget class="GtkHBox" id="hbox39">
+                                 <property name="visible">True</property>
+                                 <property name="homogeneous">False</property>
+                                 <property name="spacing">12</property>
+
+                                 <child>
+                                   <widget class="Custom" id="line_color_combo">
+                                     <property name="visible">True</property>
+                                     <property name="creation_function">gl_object_editor_construct_color_combo</property>
+                                     <property name="int1">2</property>
+                                     <property name="int2">0</property>
+                                     <property name="last_modification_time">Sun, 16 Nov 2003 06:52:23 GMT</property>
+                                   </widget>
+                                   <packing>
+                                     <property name="padding">0</property>
+                                     <property name="expand">False</property>
+                                     <property name="fill">False</property>
+                                   </packing>
+                                 </child>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">True</property>
+                                 <property name="fill">True</property>
+                               </packing>
+                             </child>
+                           </widget>
+                           <packing>
+                             <property name="padding">0</property>
+                             <property name="expand">True</property>
+                             <property name="fill">True</property>
+                           </packing>
+                         </child>
+
+                         <child>
+                           <widget class="GtkHBox" id="hbox40">
+                             <property name="visible">True</property>
+                             <property name="homogeneous">False</property>
+                             <property name="spacing">6</property>
+
+                             <child>
+                               <widget class="GtkRadioButton" id="line_key_radio">
+                                 <property name="visible">True</property>
+                                 <property name="can_focus">True</property>
+                                 <property name="label" translatable="yes">Key:</property>
+                                 <property name="use_underline">True</property>
+                                 <property name="relief">GTK_RELIEF_NORMAL</property>
+                                 <property name="focus_on_click">True</property>
+                                 <property name="active">False</property>
+                                 <property name="inconsistent">False</property>
+                                 <property name="draw_indicator">True</property>
+                                 <property name="group">line_color_radio</property>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">False</property>
+                                 <property name="fill">False</property>
+                               </packing>
+                             </child>
+
+                             <child>
+                               <widget class="GtkHBox" id="hbox41">
+                                 <property name="visible">True</property>
+                                 <property name="homogeneous">False</property>
+                                 <property name="spacing">12</property>
+
+                                 <child>
+                                   <widget class="GtkCombo" id="line_key_combo">
+                                     <property name="width_request">80</property>
+                                     <property name="visible">True</property>
+                                     <property name="value_in_list">False</property>
+                                     <property name="allow_empty">True</property>
+                                     <property name="case_sensitive">False</property>
+                                     <property name="enable_arrow_keys">True</property>
+                                     <property name="enable_arrows_always">False</property>
+
+                                     <child internal-child="entry">
+                                       <widget class="GtkEntry" id="line_key_entry">
+                                         <property name="visible">True</property>
+                                         <property name="can_focus">True</property>
+                                         <property name="editable">False</property>
+                                         <property name="visibility">True</property>
+                                         <property name="max_length">0</property>
+                                         <property name="text" translatable="yes"></property>
+                                         <property name="has_frame">True</property>
+                                         <property name="invisible_char" translatable="yes">*</property>
+                                         <property name="activates_default">False</property>
+                                       </widget>
+                                     </child>
+
+                                     <child internal-child="list">
+                                       <widget class="GtkList" id="list3">
+                                         <property name="visible">True</property>
+                                         <property name="selection_mode">GTK_SELECTION_BROWSE</property>
+                                       </widget>
+                                     </child>
+                                   </widget>
+                                   <packing>
+                                     <property name="padding">0</property>
+                                     <property name="expand">False</property>
+                                     <property name="fill">False</property>
+                                   </packing>
+                                 </child>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">True</property>
+                                 <property name="fill">True</property>
+                               </packing>
+                             </child>
+                           </widget>
+                           <packing>
+                             <property name="padding">0</property>
+                             <property name="expand">True</property>
+                             <property name="fill">True</property>
+                           </packing>
+                         </child>
+                       </widget>
+                       <packing>
+                         <property name="left_attach">1</property>
+                         <property name="right_attach">2</property>
+                         <property name="top_attach">1</property>
+                         <property name="bottom_attach">2</property>
+                         <property name="x_options">fill</property>
+                         <property name="y_options">fill</property>
+                       </packing>
+                     </child>
+
                      <child>
                        <widget class="GtkLabel" id="line_color_label">
                          <property name="visible">True</property>
                          <property name="wrap">False</property>
                          <property name="selectable">False</property>
                          <property name="xalign">0</property>
-                         <property name="yalign">0.5</property>
+                         <property name="yalign">0.14</property>
                          <property name="xpad">0</property>
                          <property name="ypad">0</property>
                        </widget>
                          <property name="top_attach">1</property>
                          <property name="bottom_attach">2</property>
                          <property name="x_options">fill</property>
-                         <property name="y_options"></property>
-                       </packing>
-                     </child>
-
-                     <child>
-                       <widget class="GtkHBox" id="hbox8">
-                         <property name="visible">True</property>
-                         <property name="homogeneous">False</property>
-                         <property name="spacing">12</property>
-
-                         <child>
-                           <widget class="Custom" id="line_color_combo">
-                             <property name="visible">True</property>
-                             <property name="creation_function">gl_object_editor_construct_color_combo</property>
-                             <property name="int1">1</property>
-                             <property name="int2">0</property>
-                             <property name="last_modification_time">Sat, 15 Nov 2003 22:10:18 GMT</property>
-                           </widget>
-                           <packing>
-                             <property name="padding">0</property>
-                             <property name="expand">False</property>
-                             <property name="fill">False</property>
-                           </packing>
-                         </child>
-                       </widget>
-                       <packing>
-                         <property name="left_attach">1</property>
-                         <property name="right_attach">2</property>
-                         <property name="top_attach">1</property>
-                         <property name="bottom_attach">2</property>
-                         <property name="x_options">fill</property>
                          <property name="y_options">fill</property>
                        </packing>
                      </child>
                      <property name="column_spacing">12</property>
 
                      <child>
-                       <widget class="GtkLabel" id="label23">
-                         <property name="visible">True</property>
-                         <property name="label" translatable="yes">Color:</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.5</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">0</property>
-                         <property name="bottom_attach">1</property>
-                         <property name="x_options">fill</property>
-                         <property name="y_options"></property>
-                       </packing>
-                     </child>
-
-                     <child>
-                       <widget class="GtkHBox" id="hbox9">
+                       <widget class="GtkVBox" id="vbox5">
                          <property name="visible">True</property>
                          <property name="homogeneous">False</property>
-                         <property name="spacing">12</property>
+                         <property name="spacing">6</property>
 
                          <child>
-                           <widget class="Custom" id="fill_color_combo">
+                           <widget class="GtkHBox" id="hbox50">
                              <property name="visible">True</property>
-                             <property name="creation_function">gl_object_editor_construct_color_combo</property>
-                             <property name="string1"></property>
-                             <property name="int1">0</property>
-                             <property name="int2">0</property>
-                             <property name="last_modification_time">Sat, 15 Nov 2003 20:47:48 GMT</property>
+                             <property name="homogeneous">False</property>
+                             <property name="spacing">6</property>
+
+                             <child>
+                               <widget class="GtkRadioButton" id="fill_color_radio">
+                                 <property name="visible">True</property>
+                                 <property name="can_focus">True</property>
+                                 <property name="label" translatable="yes"></property>
+                                 <property name="use_underline">True</property>
+                                 <property name="relief">GTK_RELIEF_NORMAL</property>
+                                 <property name="focus_on_click">True</property>
+                                 <property name="active">False</property>
+                                 <property name="inconsistent">False</property>
+                                 <property name="draw_indicator">True</property>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">False</property>
+                                 <property name="fill">False</property>
+                               </packing>
+                             </child>
+
+                             <child>
+                               <widget class="GtkHBox" id="hbox51">
+                                 <property name="visible">True</property>
+                                 <property name="homogeneous">False</property>
+                                 <property name="spacing">12</property>
+
+                                 <child>
+                                   <widget class="Custom" id="fill_color_combo">
+                                     <property name="visible">True</property>
+                                     <property name="creation_function">gl_object_editor_construct_color_combo</property>
+                                     <property name="int1">2</property>
+                                     <property name="int2">0</property>
+                                     <property name="last_modification_time">Sun, 16 Nov 2003 06:52:23 GMT</property>
+                                   </widget>
+                                   <packing>
+                                     <property name="padding">0</property>
+                                     <property name="expand">False</property>
+                                     <property name="fill">False</property>
+                                   </packing>
+                                 </child>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">True</property>
+                                 <property name="fill">True</property>
+                               </packing>
+                             </child>
                            </widget>
                            <packing>
                              <property name="padding">0</property>
-                             <property name="expand">False</property>
-                             <property name="fill">False</property>
+                             <property name="expand">True</property>
+                             <property name="fill">True</property>
+                           </packing>
+                         </child>
+
+                         <child>
+                           <widget class="GtkHBox" id="hbox52">
+                             <property name="visible">True</property>
+                             <property name="homogeneous">False</property>
+                             <property name="spacing">6</property>
+
+                             <child>
+                               <widget class="GtkRadioButton" id="fill_key_radio">
+                                 <property name="visible">True</property>
+                                 <property name="can_focus">True</property>
+                                 <property name="label" translatable="yes">Key:</property>
+                                 <property name="use_underline">True</property>
+                                 <property name="relief">GTK_RELIEF_NORMAL</property>
+                                 <property name="focus_on_click">True</property>
+                                 <property name="active">False</property>
+                                 <property name="inconsistent">False</property>
+                                 <property name="draw_indicator">True</property>
+                                 <property name="group">fill_color_radio</property>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">False</property>
+                                 <property name="fill">False</property>
+                               </packing>
+                             </child>
+
+                             <child>
+                               <widget class="GtkHBox" id="hbox53">
+                                 <property name="visible">True</property>
+                                 <property name="homogeneous">False</property>
+                                 <property name="spacing">12</property>
+
+                                 <child>
+                                   <widget class="GtkCombo" id="fill_key_combo">
+                                     <property name="width_request">80</property>
+                                     <property name="visible">True</property>
+                                     <property name="value_in_list">False</property>
+                                     <property name="allow_empty">True</property>
+                                     <property name="case_sensitive">False</property>
+                                     <property name="enable_arrow_keys">True</property>
+                                     <property name="enable_arrows_always">False</property>
+
+                                     <child internal-child="entry">
+                                       <widget class="GtkEntry" id="fill_key_entry">
+                                         <property name="visible">True</property>
+                                         <property name="can_focus">True</property>
+                                         <property name="editable">False</property>
+                                         <property name="visibility">True</property>
+                                         <property name="max_length">0</property>
+                                         <property name="text" translatable="yes"></property>
+                                         <property name="has_frame">True</property>
+                                         <property name="invisible_char" translatable="yes">*</property>
+                                         <property name="activates_default">False</property>
+                                       </widget>
+                                     </child>
+
+                                     <child internal-child="list">
+                                       <widget class="GtkList" id="list6">
+                                         <property name="visible">True</property>
+                                         <property name="selection_mode">GTK_SELECTION_BROWSE</property>
+                                       </widget>
+                                     </child>
+                                   </widget>
+                                   <packing>
+                                     <property name="padding">0</property>
+                                     <property name="expand">False</property>
+                                     <property name="fill">False</property>
+                                   </packing>
+                                 </child>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">True</property>
+                                 <property name="fill">True</property>
+                               </packing>
+                             </child>
+                           </widget>
+                           <packing>
+                             <property name="padding">0</property>
+                             <property name="expand">True</property>
+                             <property name="fill">True</property>
                            </packing>
                          </child>
                        </widget>
                          <property name="y_options">fill</property>
                        </packing>
                      </child>
+
+                     <child>
+                       <widget class="GtkLabel" id="fill_color_label">
+                         <property name="visible">True</property>
+                         <property name="label" translatable="yes">Color:</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.14</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">0</property>
+                         <property name="bottom_attach">1</property>
+                         <property name="x_options">fill</property>
+                         <property name="y_options">fill</property>
+                       </packing>
+                     </child>
                    </widget>
                    <packing>
                      <property name="padding">0</property>
                          <property name="label" translatable="yes">File:</property>
                          <property name="use_underline">True</property>
                          <property name="relief">GTK_RELIEF_NORMAL</property>
+                         <property name="focus_on_click">True</property>
                          <property name="active">False</property>
                          <property name="inconsistent">False</property>
                          <property name="draw_indicator">True</property>
                      <property name="browse_dialog_title" translatable="yes">Load image</property>
                      <property name="modal">False</property>
                      <property name="do_preview">True</property>
+                     <property name="use_filechooser">False</property>
 
                      <child internal-child="entry">
                        <widget class="GtkEntry" id="combo-entry3">
                          <property name="label" translatable="yes">Key:</property>
                          <property name="use_underline">True</property>
                          <property name="relief">GTK_RELIEF_NORMAL</property>
+                         <property name="focus_on_click">True</property>
                          <property name="active">False</property>
                          <property name="inconsistent">False</property>
                          <property name="draw_indicator">True</property>
                          <child internal-child="entry">
                            <widget class="GtkEntry" id="img_key_entry">
                              <property name="visible">True</property>
-                             <property name="sensitive">False</property>
                              <property name="can_focus">True</property>
                              <property name="editable">False</property>
                              <property name="visibility">True</property>
                          <property name="label" translatable="yes">Literal:</property>
                          <property name="use_underline">True</property>
                          <property name="relief">GTK_RELIEF_NORMAL</property>
+                         <property name="focus_on_click">True</property>
                          <property name="active">False</property>
                          <property name="inconsistent">False</property>
                          <property name="draw_indicator">True</property>
                          <property name="label" translatable="yes">Key:</property>
                          <property name="use_underline">True</property>
                          <property name="relief">GTK_RELIEF_NORMAL</property>
+                         <property name="focus_on_click">True</property>
                          <property name="active">False</property>
                          <property name="inconsistent">False</property>
                          <property name="draw_indicator">True</property>
                                <widget class="GtkEntry" id="data_key_entry">
                                  <property name="visible">True</property>
                                  <property name="can_focus">True</property>
-                                 <property name="editable">True</property>
+                                 <property name="editable">False</property>
                                  <property name="visibility">True</property>
                                  <property name="max_length">0</property>
                                  <property name="text" translatable="yes"></property>
                        </packing>
                      </child>
 
-                     <child>
-                       <widget class="GtkLabel" id="bc_color_label">
-                         <property name="visible">True</property>
-                         <property name="label" translatable="yes">Color:</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">3</property>
-                         <property name="bottom_attach">4</property>
-                         <property name="x_options">fill</property>
-                         <property name="y_options"></property>
-                       </packing>
-                     </child>
-
                      <child>
                        <widget class="GtkHBox" id="hbox20">
                          <property name="visible">True</property>
                        </packing>
                      </child>
 
-                     <child>
-                       <widget class="GtkHBox" id="hbox23">
-                         <property name="visible">True</property>
-                         <property name="homogeneous">False</property>
-                         <property name="spacing">12</property>
-
-                         <child>
-                           <widget class="Custom" id="bc_color_combo">
-                             <property name="visible">True</property>
-                             <property name="creation_function">gl_object_editor_construct_color_combo</property>
-                             <property name="int1">1</property>
-                             <property name="int2">0</property>
-                             <property name="last_modification_time">Sun, 16 Nov 2003 07:00:32 GMT</property>
-                           </widget>
-                           <packing>
-                             <property name="padding">0</property>
-                             <property name="expand">False</property>
-                             <property name="fill">False</property>
-                           </packing>
-                         </child>
-                       </widget>
-                       <packing>
-                         <property name="left_attach">1</property>
-                         <property name="right_attach">2</property>
-                         <property name="top_attach">3</property>
-                         <property name="bottom_attach">4</property>
-                         <property name="x_options">fill</property>
-                         <property name="y_options">fill</property>
-                       </packing>
-                     </child>
-
                      <child>
                        <widget class="GtkCheckButton" id="bc_text_check">
                          <property name="visible">True</property>
                          <property name="label" translatable="yes">Text</property>
                          <property name="use_underline">True</property>
                          <property name="relief">GTK_RELIEF_NORMAL</property>
+                         <property name="focus_on_click">True</property>
                          <property name="active">False</property>
                          <property name="inconsistent">False</property>
                          <property name="draw_indicator">True</property>
                          <property name="label" translatable="yes">Checksum</property>
                          <property name="use_underline">True</property>
                          <property name="relief">GTK_RELIEF_NORMAL</property>
+                         <property name="focus_on_click">True</property>
                          <property name="active">False</property>
                          <property name="inconsistent">False</property>
                          <property name="draw_indicator">True</property>
                          <property name="y_options"></property>
                        </packing>
                      </child>
+
+                     <child>
+                       <widget class="GtkVBox" id="vbox4">
+                         <property name="visible">True</property>
+                         <property name="homogeneous">False</property>
+                         <property name="spacing">6</property>
+
+                         <child>
+                           <widget class="GtkHBox" id="hbox46">
+                             <property name="visible">True</property>
+                             <property name="homogeneous">False</property>
+                             <property name="spacing">6</property>
+
+                             <child>
+                               <widget class="GtkRadioButton" id="bc_color_radio">
+                                 <property name="visible">True</property>
+                                 <property name="can_focus">True</property>
+                                 <property name="label" translatable="yes"></property>
+                                 <property name="use_underline">True</property>
+                                 <property name="relief">GTK_RELIEF_NORMAL</property>
+                                 <property name="focus_on_click">True</property>
+                                 <property name="active">False</property>
+                                 <property name="inconsistent">False</property>
+                                 <property name="draw_indicator">True</property>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">False</property>
+                                 <property name="fill">False</property>
+                               </packing>
+                             </child>
+
+                             <child>
+                               <widget class="GtkHBox" id="hbox47">
+                                 <property name="visible">True</property>
+                                 <property name="homogeneous">False</property>
+                                 <property name="spacing">12</property>
+
+                                 <child>
+                                   <widget class="Custom" id="bc_color_combo">
+                                     <property name="visible">True</property>
+                                     <property name="creation_function">gl_object_editor_construct_color_combo</property>
+                                     <property name="int1">2</property>
+                                     <property name="int2">0</property>
+                                     <property name="last_modification_time">Sun, 16 Nov 2003 06:52:23 GMT</property>
+                                   </widget>
+                                   <packing>
+                                     <property name="padding">0</property>
+                                     <property name="expand">False</property>
+                                     <property name="fill">False</property>
+                                   </packing>
+                                 </child>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">True</property>
+                                 <property name="fill">True</property>
+                               </packing>
+                             </child>
+                           </widget>
+                           <packing>
+                             <property name="padding">0</property>
+                             <property name="expand">True</property>
+                             <property name="fill">True</property>
+                           </packing>
+                         </child>
+
+                         <child>
+                           <widget class="GtkHBox" id="hbox48">
+                             <property name="visible">True</property>
+                             <property name="homogeneous">False</property>
+                             <property name="spacing">6</property>
+
+                             <child>
+                               <widget class="GtkRadioButton" id="bc_key_radio">
+                                 <property name="visible">True</property>
+                                 <property name="can_focus">True</property>
+                                 <property name="label" translatable="yes">Key:</property>
+                                 <property name="use_underline">True</property>
+                                 <property name="relief">GTK_RELIEF_NORMAL</property>
+                                 <property name="focus_on_click">True</property>
+                                 <property name="active">False</property>
+                                 <property name="inconsistent">False</property>
+                                 <property name="draw_indicator">True</property>
+                                 <property name="group">bc_color_radio</property>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">False</property>
+                                 <property name="fill">False</property>
+                               </packing>
+                             </child>
+
+                             <child>
+                               <widget class="GtkHBox" id="hbox49">
+                                 <property name="visible">True</property>
+                                 <property name="homogeneous">False</property>
+                                 <property name="spacing">12</property>
+
+                                 <child>
+                                   <widget class="GtkCombo" id="bc_key_combo">
+                                     <property name="width_request">80</property>
+                                     <property name="visible">True</property>
+                                     <property name="value_in_list">False</property>
+                                     <property name="allow_empty">True</property>
+                                     <property name="case_sensitive">False</property>
+                                     <property name="enable_arrow_keys">True</property>
+                                     <property name="enable_arrows_always">False</property>
+
+                                     <child internal-child="entry">
+                                       <widget class="GtkEntry" id="bc_key_entry">
+                                         <property name="visible">True</property>
+                                         <property name="can_focus">True</property>
+                                         <property name="editable">False</property>
+                                         <property name="visibility">True</property>
+                                         <property name="max_length">0</property>
+                                         <property name="text" translatable="yes"></property>
+                                         <property name="has_frame">True</property>
+                                         <property name="invisible_char" translatable="yes">*</property>
+                                         <property name="activates_default">False</property>
+                                       </widget>
+                                     </child>
+
+                                     <child internal-child="list">
+                                       <widget class="GtkList" id="list5">
+                                         <property name="visible">True</property>
+                                         <property name="selection_mode">GTK_SELECTION_BROWSE</property>
+                                       </widget>
+                                     </child>
+                                   </widget>
+                                   <packing>
+                                     <property name="padding">0</property>
+                                     <property name="expand">False</property>
+                                     <property name="fill">False</property>
+                                   </packing>
+                                 </child>
+                               </widget>
+                               <packing>
+                                 <property name="padding">0</property>
+                                 <property name="expand">True</property>
+                                 <property name="fill">True</property>
+                               </packing>
+                             </child>
+                           </widget>
+                           <packing>
+                             <property name="padding">0</property>
+                             <property name="expand">True</property>
+                             <property name="fill">True</property>
+                           </packing>
+                         </child>
+                       </widget>
+                       <packing>
+                         <property name="left_attach">1</property>
+                         <property name="right_attach">2</property>
+                         <property name="top_attach">3</property>
+                         <property name="bottom_attach">4</property>
+                         <property name="x_options">fill</property>
+                         <property name="y_options">fill</property>
+                       </packing>
+                     </child>
+
+                     <child>
+                       <widget class="GtkLabel" id="bc_color_label">
+                         <property name="visible">True</property>
+                         <property name="label" translatable="yes">Color:</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.14</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">3</property>
+                         <property name="bottom_attach">4</property>
+                         <property name="x_options">fill</property>
+                         <property name="y_options">fill</property>
+                       </packing>
+                     </child>
                    </widget>
                    <packing>
                      <property name="padding">0</property>
                              <property name="label" translatable="yes">Reset image size</property>
                              <property name="use_underline">True</property>
                              <property name="relief">GTK_RELIEF_NORMAL</property>
+                             <property name="focus_on_click">True</property>
                            </widget>
                            <packing>
                              <property name="padding">0</property>
index 1597e1f47951998084a61256554f842f8d54f663..489b2a422350fc1e35368517decc149c5aaae47f 100644 (file)
@@ -48,6 +48,9 @@ Set number of sheets to \fIn\fR. (default=1)
 \fB\-c\fR \fIn\fR, \fB\-\-copies\fR=\fIn\fR
 Set number of copies to \fIn\fR. (default=1)
 .TP
+\fB\-f\fR \fIn\fR, \fB\-\-first\fR=\fIn\fR
+Set label on first sheet to start printing from to \fIn\fR. (default=1)
+.TP
 \fB\-l\fR, \fB\-\-outline\fR
 Print outlines around labels.  This is useful for testing printer alignment
 or printing proof sheets.
index 98da03e72a3efd2c00bffb2459d7ce537226a049..596c96c7e70ea20b7f8147a5f9d9cf3fdaf1f2cc 100644 (file)
@@ -1,7 +1,7 @@
 application/x-glabels:
        open=glabels %f
        _description=gLabels Project File
-        icon_filename=glabels.png
+        icon_filename=glabels-application-x-glabels.png
         default_action_type=application
        category=Documents
         short_list_application_ids_for_novice_user_level=glabels
index f501ed32a160acca351e5adad418cdb8eeb3bc49..4cebb802003d11f82e021be94c8db34638ea62d4 100644 (file)
@@ -3,8 +3,7 @@
 glabels_pixmapsdir = $(datadir)/pixmaps/glabels
 
 glabels_pixmaps_DATA = \
-       glabels-icon.png        \
-       glabels-logo.png        \
+       glabels-splash.png      \
        glabels-about-logo.png  \
        ex-rect-size.png        \
        ex-round-size.png       \
@@ -12,9 +11,16 @@ glabels_pixmaps_DATA = \
        ex-1layout.png          \
        ex-2layouts.png         
 
+glabels_app_icondir = $(datadir)/pixmaps
+
+glabels_app_icon_DATA = \
+       glabels.png
+
 glabels_mime_icondir = $(datadir)/pixmaps
 
-glabels_mime_icon_DATA = glabels.png
+glabels_mime_icon_DATA = \
+       glabels-application-x-glabels.png
 
-EXTRA_DIST = $(glabels_pixmaps_DATA) \
+EXTRA_DIST = $(glabels_pixmaps_DATA)   \
+            $(glabels_app_icon_DATA)  \
             $(glabels_mime_icon_DATA)
index b96e276b42bfae950087b8ff39cc8bd491473c17..9997c67ed0e712f554786e21cbf6b651ae6b17a7 100644 (file)
Binary files a/glabels2/data/pixmaps/glabels-about-logo.png and b/glabels2/data/pixmaps/glabels-about-logo.png differ
diff --git a/glabels2/data/pixmaps/glabels-application-x-glabels.png b/glabels2/data/pixmaps/glabels-application-x-glabels.png
new file mode 100644 (file)
index 0000000..59c749f
Binary files /dev/null and b/glabels2/data/pixmaps/glabels-application-x-glabels.png differ
diff --git a/glabels2/data/pixmaps/glabels-icon.png b/glabels2/data/pixmaps/glabels-icon.png
deleted file mode 100644 (file)
index f44f325..0000000
Binary files a/glabels2/data/pixmaps/glabels-icon.png and /dev/null differ
diff --git a/glabels2/data/pixmaps/glabels-logo.png b/glabels2/data/pixmaps/glabels-logo.png
deleted file mode 100644 (file)
index 713cb8a..0000000
Binary files a/glabels2/data/pixmaps/glabels-logo.png and /dev/null differ
diff --git a/glabels2/data/pixmaps/glabels-splash.png b/glabels2/data/pixmaps/glabels-splash.png
new file mode 100644 (file)
index 0000000..713cb8a
Binary files /dev/null and b/glabels2/data/pixmaps/glabels-splash.png differ
index 376a2de3239c44d14b5e7f2b7368d6e81e44c91d..afb7ecfbd20fa1dec36421cfcd2a7dcae6ee4a75 100644 (file)
Binary files a/glabels2/data/pixmaps/glabels.png and b/glabels2/data/pixmaps/glabels.png differ
index 80c90f1c5563c9c0c2848e7ddd0dd040ed578348..9973e398e36715b3b92cff65741ca70a03dabe14 100644 (file)
     </Label-rectangle>
   </Template>
 
+  <!-- ============================================================ -->
+  <!-- Avery 32015: Business Cards                                  -->
+  <!-- ============================================================ -->
+  <Template name="Zweckform 32015" size="A4" _description="Business Cards">
+    <Label-rectangle id="0" width="85mm" height="54mm" round="0mm">
+      <Markup-margin size="5mm"/>
+      <Layout nx="2" ny="4" x0="17mm" y0="31.5mm" dx="91mm" dy="60mm"/>
+    </Label-rectangle>
+    <Alias name="Zwekform 32015"/>
+  </Template>
+
 
 
 </Glabels-templates>
index d7a69cd7a8c969abbd87af476ac7a613a618d1e9..690d1689bd1a97908bbc5cc290df5b60f2224319 100644 (file)
     </Label-rectangle>
   </Template>
 
+  <!-- =================================================================== -->
+  <!-- Herma 5079: CD/DVD Labels, 2 per sheet                              -->
+  <!-- =================================================================== -->
+  <Template name="Herma 5079" size="A4" description="CD/DVD Labels">
+    <Label-cd id="0" radius="164.409pt" hole="58.1102pt" waste="9pt">
+      <Markup-margin size="9pt"/>
+      <Layout nx="1" ny="2" x0="133.228pt" y0="46.7717pt" dx="346.819pt" dy="419.528pt"/>
+    </Label-cd>
+  </Template>
+
   <!-- ===================================================================-->
   <!-- Neato brand CD/DVD Labels (face only), 2 per sheet                 -->
   <!-- ===================================================================-->
     </Label-cd>
   </Template>
 
+  <!-- =================================================================== -->
+  <!-- Pressit CD Labels/                                                  -->
+  <!-- =================================================================== -->
+  <Template name="Pressit  50blank" size="A4" _description="CD Labels">
+    <Label-cd id="0" radius="166.5pt" hole="58.5pt" waste="9pt">
+      <Markup-margin size="9pt"/>
+      <Layout nx="1" ny="1" x0="30.096pt" y0="70.416pt" dx="351pt" dy="351pt"/>
+      <Layout nx="1" ny="1" x0="233.208pt" y0="440.712pt" dx="351pt" dy="351pt"/>
+    </Label-cd>
+  </Template>
+
 
 
   <!-- ******************************************************************** -->
index 0552d884b961b1d9c496e9f6ec3834b39d4d0176..0ee5f53062af1b8e2ae652763bc24419910ee62d 100644 (file)
     </Label-rectangle>
   </Template> 
 
+  <!-- =================================================================== -->
+  <!-- Kingdom L Cassette Labels, 12 per sheet.                            -->
+  <!-- =================================================================== -->
+  <Template name="Kingdom L" size="US-Letter" _description="Cassette Labels">
+    <Label-rectangle id="0" width="252pt" height="117pt" round="9pt" x_waste="2.376pt" y_waste="2.376pt">
+      <Markup-margin size="9pt"/>
+      <Layout nx="2" ny="6" x0="33.12pt" y0="27pt" dx="261pt" dy="126.144pt"/>
+    </Label-rectangle>
+  </Template>
+
 </Glabels-templates>
 
 
index 0170536bc6d8d3d9e288a848fc8e082ea1630365..1c5561aff902414d69f9fb57fb1a795ebd37bce9 100644 (file)
                        type="toggle" state="0"
                />
 
-               <cmd name="DrawingToolbarSystem"
-                       id="DrawingToolbarSystem"
-                       _label="_Desktop Default"
-                       _tip="Set drawing toolbar button style according to desktop default"
-                       type="radio" group="drawing_buttons" state="1"
-               />
-
-               <cmd name="DrawingToolbarIcon"
-                       id="DrawingToolbarIcon"
-                       _label="_Icon"
-                       _tip="Only show icons in the drawing toolbar"
-                       type="radio" group="drawing_buttons"
-               />
-
-               <cmd name="DrawingToolbarIconText"
-                       id="DrawingToolbarIconText"
-                               _label="Icon and _Text"
-                               _tip="Show both icons and texts in the drawing toolbar"
-                               type="radio" group="drawing_buttons"
-               />
-
                <cmd name="DrawingToolbarTooltips"
                        id="DrawingToolbarTooltips"
                        _label="Show _Tooltips"
                behavior="exclusive"
                in_new_band="1"
                band_num="2"
+                look="icon"
        >
 
                <toolitem name="ToolsArrow"
                behavior="exclusive,never vertical"
                in_new_band="1"
                placement="bottom"
+                look="icon"
        >
 
                <control name="PropFontName"
index 952ec6dee8353b3c63d8b73019f934bce86b1377..a7949d582422c8ce62fc300e3ab4acbbda5d7186 100644 (file)
@@ -45,7 +45,7 @@ supply stores.
 %makeinstall
 %find_lang %{name}
 
-desktop-file-install --vendor gnome                \
+desktop-file-install --vendor gnome --delete-original \
        --add-category X-Red-Hat-Base              \
        --dir %{buildroot}%{_datadir}/applications \
        %{buildroot}%{_datadir}/applications/%{name}.desktop
diff --git a/glabels2/mkinstalldirs b/glabels2/mkinstalldirs
deleted file mode 100755 (executable)
index 6b3b5fc..0000000
+++ /dev/null
@@ -1,40 +0,0 @@
-#! /bin/sh
-# mkinstalldirs --- make directory hierarchy
-# Author: Noah Friedman <friedman@prep.ai.mit.edu>
-# Created: 1993-05-16
-# Public domain
-
-# $Id$
-
-errstatus=0
-
-for file
-do
-   set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
-   shift
-
-   pathcomp=
-   for d
-   do
-     pathcomp="$pathcomp$d"
-     case "$pathcomp" in
-       -* ) pathcomp=./$pathcomp ;;
-     esac
-
-     if test ! -d "$pathcomp"; then
-        echo "mkdir $pathcomp"
-
-        mkdir "$pathcomp" || lasterr=$?
-
-        if test ! -d "$pathcomp"; then
-         errstatus=$lasterr
-        fi
-     fi
-
-     pathcomp="$pathcomp/"
-   done
-done
-
-exit $errstatus
-
-# mkinstalldirs ends here
index c4241fb0429d8ffe8740ec325be9179732855944..8c576e5a2da7c9a3fb4f9e20a6a747ad0694a958 100644 (file)
@@ -1,16 +1,17 @@
 # French translation of glabels.
 # Copyright (C) 2001 Jim Evins <evins@snaught.com>
-# Olivier Berger <oberger@gnu.org>, 2001.
+# Olivier Berger <oberger@gnu.org>
+# Florent Morel <florent@taket.org>, 2001, 2004
 # 
 msgid ""
 msgstr ""
-"Project-Id-Version: glabels 0.4.4\n"
-"POT-Creation-Date: 2004-08-08 00:43-0400\n"
+"Project-Id-Version: glabels 2.0.1\n"
+"POT-Creation-Date: 2004-08-14 21:09-0400\n"
 "PO-Revision-Date: 2001-10-15 15:31+0200\n"
-"Last-Translator: Olivier Berger <oberger@gnu.org>\n"
+"Last-Translator: Florent Morel <florent@taket.org>\n"
 "Language-Team: French <gnomefr@traduc.org>\n"
 "MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=iso-8859-1\n"
+"Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
 
 #: src/glabels.c:55
@@ -107,15 +108,15 @@ msgstr ""
 
 #: src/glabels-batch.c:48
 msgid "print this message"
-msgstr "imprimer ce message"
+msgstr "afficher ce message"
 
 #: src/glabels-batch.c:50
 msgid "print the version of glabels-batch being used"
-msgstr "imprimer la version de glabels-batch utilisée"
+msgstr "afficher la version de glabels-batch utilisée"
 
 #: src/glabels-batch.c:52
 msgid "set output filename (default=\"output.ps\")"
-msgstr "définit le fichier de sortie (défaut=\"output.ps\")"
+msgstr "définit le fichier de sortie (défaut=\"output.ps\")"
 
 #: src/glabels-batch.c:52
 msgid "filename"
@@ -123,7 +124,7 @@ msgstr "nom de fichier"
 
 #: src/glabels-batch.c:54
 msgid "number of sheets (default=1)"
-msgstr "nombre de pages (défaut=1)"
+msgstr "nombre de pages (défaut=1)"
 
 # src/print_copies.c:193
 # src/print_copies.c:193
@@ -135,7 +136,7 @@ msgstr "feuilles"
 
 #: src/glabels-batch.c:56
 msgid "number of copies (default=1)"
-msgstr "nombre de copies (défaut=1)"
+msgstr "nombre de copies (défaut=1)"
 
 # src/print.c:153
 # src/print.c:153
@@ -156,7 +157,7 @@ msgstr "imprimer des bordures (pour tester l'alignement de l'imprimante)"
 # src/print_dialog.c:160
 #: src/glabels-batch.c:60 src/print-dialog.c:344
 msgid "print in reverse (i.e. a mirror image)"
-msgstr "imprimer Ã  l'envers (i.e. une image miroir)"
+msgstr "imprimer Ã  l'envers (i.e. une image miroir)"
 
 #: src/glabels-batch.c:96
 msgid "[OPTION...] GLABELS_FILE..."
@@ -177,171 +178,155 @@ msgstr "impossible d'ouvrir le fichier glabels %s\n"
 
 #: src/window.c:244
 msgid "(none) - gLabels"
-msgstr ""
+msgstr "(vide) - gLabels"
 
 #: src/window.c:414
 msgid "(modified)"
-msgstr ""
+msgstr "(modifié)"
 
 # src/display.c:1157 src/display.c:1205
 # src/display.c:1160 src/display.c:1208
 # src/menu.c:94
 # src/menu.c:94
 #: src/stock.c:65 data/ui/glabels-ui.xml.h:165
-#, fuzzy
 msgid "_Select Mode"
-msgstr "Sélectionner"
+msgstr "_Sélectionner"
 
 # src/item_text.c:442 src/item_text.c:627
 # src/item_text.c:442 src/item_text.c:627
 # src/item_text.c:460 src/item_text.c:464 src/item_text.c:637 src/menu.c:100
 # src/item_text.c:460 src/item_text.c:464 src/item_text.c:637 src/menu.c:100
 #: src/stock.c:66 data/ui/glabels-ui.xml.h:166
-#, fuzzy
 msgid "_Text"
-msgstr "Texte"
+msgstr "_Texte"
 
 # src/item_line.c:271
 # src/item_line.c:271
 # src/item_line.c:256 src/menu.c:106
 # src/item_line.c:256 src/menu.c:106
 #: src/stock.c:67 data/ui/glabels-ui.xml.h:151
-#, fuzzy
 msgid "_Line"
-msgstr "Ligne"
+msgstr "_Ligne"
 
 # src/menu.c:103
 # src/menu.c:103
 #: src/stock.c:68 data/ui/glabels-ui.xml.h:133
-#, fuzzy
 msgid "_Box"
-msgstr "Boîte"
+msgstr "_Boîte"
 
 # src/menu.c:109
 # src/menu.c:109
 #: src/stock.c:69 data/ui/glabels-ui.xml.h:144
-#, fuzzy
 msgid "_Ellipse"
-msgstr "Ellipse"
+msgstr "_Ellipse"
 
 # src/item_image.c:283
 # src/item_image.c:283
 # src/item_image.c:268 src/menu.c:113
 # src/item_image.c:268 src/menu.c:113
 #: src/stock.c:70 data/ui/glabels-ui.xml.h:149
-#, fuzzy
 msgid "_Image"
-msgstr "Image"
+msgstr "_Image"
 
 # src/item_barcode.c:316
 # src/item_barcode.c:317
 # src/menu.c:116
 # src/menu.c:116
 #: src/stock.c:71 data/ui/glabels-ui.xml.h:11
-#, fuzzy
 msgid "Bar_code"
-msgstr "Code-barre"
+msgstr "_Code-barre"
 
 # src/item_text.c:467
 # src/item_text.c:467
 # src/menu.c:132 src/menu.c:223
 # src/menu.c:132 src/menu.c:223
 #: src/stock.c:72
-#, fuzzy
 msgid "_Merge Properties"
-msgstr "Propriétés de fusion"
+msgstr "_Propriétés de fusion"
 
 # src/item_text.c:467
 # src/item_text.c:467
 # src/item_text.c:482
 # src/item_text.c:482
 #: src/stock.c:73
-#, fuzzy
 msgid "Object _Properties"
-msgstr "Propriétés du texte"
+msgstr "_Propriétés de l'objet"
 
 # src/display.c:1167 src/display.c:1215
 # src/display.c:1170 src/display.c:1218
 # src/display.c:1181 src/display.c:1229
 # src/display.c:1196 src/display.c:1244
 #: src/stock.c:74 data/ui/glabels-ui.xml.h:13
-#, fuzzy
 msgid "Bring to _Front"
-msgstr "Avancer au premier plan"
+msgstr "_Avancer au premier plan"
 
 # src/display.c:1173 src/display.c:1221
 # src/display.c:1176 src/display.c:1224
 # src/display.c:1187 src/display.c:1235
 # src/display.c:1202 src/display.c:1250
 #: src/stock.c:75 data/ui/glabels-ui.xml.h:110
-#, fuzzy
 msgid "Send to _Back"
-msgstr "Reculer Ã  l'arrière-plan"
+msgstr "_Reculer Ã  l'arrière-plan"
 
 # src/rotate_select.c:187
 # src/rotate_select.c:187
 # src/rotate_select.c:167
 # src/rotate_select.c:169
 #: src/stock.c:76 data/ui/glabels-ui.xml.h:97
-#, fuzzy
 msgid "Rotate _Left"
-msgstr "Rotation"
+msgstr "Rotation _Gauche"
 
 # src/rotate_select.c:187
 # src/rotate_select.c:187
 # src/rotate_select.c:167
 # src/rotate_select.c:169
 #: src/stock.c:77 data/ui/glabels-ui.xml.h:98
-#, fuzzy
 msgid "Rotate _Right"
-msgstr "Rotation"
+msgstr "Rotation _Droite"
 
 #: src/stock.c:78 data/ui/glabels-ui.xml.h:52
 msgid "Flip _Horizontally"
-msgstr ""
+msgstr "Retourner _Horizontalement"
 
 #: src/stock.c:79 data/ui/glabels-ui.xml.h:53
 msgid "Flip _Vertically"
-msgstr ""
+msgstr "Retourner _Verticalement"
 
 #: src/stock.c:80 data/ui/glabels-ui.xml.h:150
 msgid "_Lefts"
-msgstr ""
+msgstr "_Gauches"
 
 #: src/stock.c:81 data/ui/glabels-ui.xml.h:162
 msgid "_Rights"
-msgstr ""
+msgstr "_Droites"
 
 #: src/stock.c:82 data/ui/glabels-ui.xml.h:134
 msgid "_Centers"
-msgstr ""
+msgstr "_Centres"
 
 # src/menu.c:157
 # src/menu.c:157
 #: src/stock.c:83 data/ui/glabels-ui.xml.h:167
-#, fuzzy
 msgid "_Tops"
-msgstr "_Outils"
+msgstr "En _haut"
 
 #: src/stock.c:84
 msgid "Bottoms"
-msgstr ""
+msgstr "En _bas"
 
 #: src/stock.c:85
 msgid "Centers"
-msgstr ""
+msgstr "_Centré"
 
 #: src/stock.c:86 src/stock.c:87 data/ui/glabels-ui.xml.h:62
 msgid "Label Ce_nter"
-msgstr ""
+msgstr "Centre de l'étiquette"
 
 #: src/stock.c:88 data/ui/glabels-ui.xml.h:51
-#, fuzzy
 msgid "Fill color"
 msgstr "Couleur de remplissage"
 
 #: src/stock.c:89 data/ui/glabels-ui.xml.h:64
-#, fuzzy
 msgid "Line color"
 msgstr "Couleur de ligne"
 
@@ -366,29 +351,26 @@ msgstr "Aucun"
 # src/display.c:1171 src/display.c:1219
 # src/display.c:1186 src/display.c:1234
 #: src/ui-property-bar.c:345 src/object-editor.c:499
-#, fuzzy
 msgid "Default"
-msgstr "Supprimer"
+msgstr "Défaut"
 
 #: src/ui-property-bar.c:360 src/object-editor.c:512
 msgid "No fill"
-msgstr ""
+msgstr "Pas de remplissage"
 
 # src/merge.c:80
 # src/merge.c:78
 #: src/ui-property-bar.c:375 src/object-editor.c:505
-#, fuzzy
 msgid "No line"
-msgstr "Aucun"
+msgstr "Pas de ligne"
 
 # src/item_text.c:467
 # src/item_text.c:467
 # src/item_text.c:482
 # src/item_text.c:482
 #: src/ui-sidebar.c:180
-#, fuzzy
 msgid "Object properties"
-msgstr "Propriétés du texte"
+msgstr "Propriétés de l'objet"
 
 # src/menu.c:185
 # src/menu.c:185
@@ -408,17 +390,17 @@ msgid ""
 "FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for "
 "more details.\n"
 msgstr ""
-"Un programme de création d'étiquettes et de cartes de visite pour GNOME.\n"
+"Un programme de création d'étiquettes et de cartes de visite pour GNOME.\n"
 " \n"
 "Ce programme est un logiciel libre ; vous pouvez le redistribuer et/ou le "
-"modifier conformément aux dispositions de la Licence Publique Générale GNU, "
-"telle que publiée par la Free Software Foundation ; version 2 de la licence, "
-"ou encore (à votre choix) toute version ultérieure.\n"
+"modifier conformément aux dispositions de la Licence Publique Générale GNU, "
+"telle que publiée par la Free Software Foundation ; version 2 de la licence, "
+"ou encore (à votre choix) toute version ultérieure.\n"
 " \n"
-"Ce programme est distribué dans l'espoir qu'il sera utile, mais SANS AUCUNE "
-"GARANTIE ; sans même la garantie implicite de COMMERCIALISATION ou "
-"D'ADAPTATION A UN OBJET PARTICULIER. Pour plus de détail, voir la Licence "
-"Publique Générale GNU.\n"
+"Ce programme est distribué dans l'espoir qu'il sera utile, mais SANS AUCUNE "
+"GARANTIE ; sans même la garantie implicite de COMMERCIALISATION ou "
+"D'ADAPTATION A UN OBJET PARTICULIER. Pour plus de détail, voir la Licence "
+"Publique Générale GNU.\n"
 
 #: src/commands.c:399
 msgid "See the file AUTHORS for additional credits,"
@@ -430,16 +412,15 @@ msgstr ""
 
 #: src/commands.c:409
 msgid " "
-msgstr ""
+msgstr " "
 
 # src/print_copies.c:210
 # src/print_copies.c:210
 # src/print_copies.c:188
 # src/print_copies.c:187
 #: src/commands.c:424
-#, fuzzy
 msgid "glabels"
-msgstr "Etiquettes"
+msgstr "glabels"
 
 # src/file.c:59
 # src/file.c:59
@@ -447,7 +428,7 @@ msgstr "Etiquettes"
 # src/file.c:72
 #: src/file.c:100
 msgid "New Label or Card"
-msgstr "Nouvelle Ã©tiquette ou carte"
+msgstr "Nouvelle Ã©tiquette ou carte"
 
 # src/file.c:87
 # src/file.c:87
@@ -455,7 +436,7 @@ msgstr "Nouvelle 
 # src/file.c:98
 #: src/file.c:132 src/file.c:304
 msgid "Media Type"
-msgstr "Type de média"
+msgstr "Type de média"
 
 # src/file.c:98
 # src/file.c:98
@@ -463,46 +444,43 @@ msgstr "Type de m
 # src/file.c:109
 #: src/file.c:138 src/file.c:310
 msgid "Label orientation"
-msgstr "Orientation de l'étiquette"
+msgstr "Orientation de l'étiquette"
 
 # src/item_text.c:467
 # src/item_text.c:467
 # src/item_text.c:482
 # src/item_text.c:482
 #: src/file.c:269
-#, fuzzy
 msgid "Label properties"
-msgstr "Propriétés du texte"
+msgstr "Propriétés de l'étiquette"
 
 #: src/file.c:452 src/file.c:870
 msgid "All files"
-msgstr ""
+msgstr "Tous les fichiers"
 
 # src/preferences.c:92
 # src/prefs.c:101
 # src/prefs.c:92
 # src/prefs.c:86
 #: src/file.c:457 src/file.c:875
-#, fuzzy
 msgid "gLabels documents"
-msgstr "Glabels : Préférences"
+msgstr "Documents gLabels"
 
 # src/menu.c:86
 # src/menu.c:86
 # src/menu.c:86
 # src/menu.c:86
 #: src/file.c:505 src/file.c:617 src/file.c:934 src/file.c:1130
-#, fuzzy
 msgid "Empty file name selection"
-msgstr "Supprime toutes les sélections"
+msgstr "Nom de fichier sélectionné vide"
 
 #: src/file.c:506 src/file.c:520 src/file.c:618 src/file.c:632
 msgid "Please select a file or supply a valid file name"
-msgstr ""
+msgstr "Selectionnez un fichier ou donner un nom de fichier valide"
 
 #: src/file.c:519 src/file.c:631
 msgid "File does not exist"
-msgstr ""
+msgstr "Ce fichier n'existe pas"
 
 # src/file.c:178
 # src/file.c:178
@@ -518,73 +496,72 @@ msgstr "Ouvrir"
 # src/file.c:213
 #: src/file.c:565
 msgid "Open label"
-msgstr "Ouvrir une Ã©tiquette"
+msgstr "Ouvrir une Ã©tiquette"
 
 # src/file.c:214
 # src/file.c:214
 # src/file.c:249
 # src/file.c:249
 #: src/file.c:707
-#, fuzzy, c-format
+# c-format
 msgid "Could not open file \"%s\""
 msgstr "Impossible d'ouvrir le fichier"
 
 #: src/file.c:715
 msgid "Not a supported file format"
-msgstr ""
+msgstr "Format de fichier non supporté"
 
 # src/file.c:248 src/mdi.c:635
 # src/file.c:248 src/mdi.c:641
 # src/file.c:288 src/mdi.c:601
 # src/file.c:288 src/mdi.c:601
 #: src/file.c:797 src/file.c:979 src/file.c:1174
-#, fuzzy, c-format
+#, c-format
 msgid "Could not save file \"%s\""
-msgstr "Impossible d'enregistrer le fichier"
+msgstr "Impossible d'enregistrer \"%s\""
 
 #: src/file.c:805 src/file.c:987 src/file.c:1182
 msgid "Error encountered during save.  The file is still not saved."
-msgstr ""
+msgstr "Erreur rencontrée durant l'enregistrement. Le fichier n'est toujours pas enregistré. "
 
 # src/file.c:278
 # src/file.c:278
 # src/file.c:316
 # src/file.c:316
 #: src/file.c:848 src/file.c:1048
-#, fuzzy, c-format
+#, c-format
 msgid "Save \"%s\" as"
-msgstr "Enregistrer l'étiquette sous"
+msgstr "Enregistrer \"%s\" sous"
 
 # src/file.c:319 src/mdi.c:729
 # src/file.c:319 src/mdi.c:735
 # src/file.c:362 src/mdi.c:693
 # src/file.c:362 src/mdi.c:693
 #: src/file.c:935 src/file.c:1131
-#, fuzzy
 msgid "Please supply a valid file name"
-msgstr "Vous devez donner un nom de fichier"
+msgstr "Donnez un nom de fichier valide"
 
 #: src/file.c:952 src/file.c:1147
 #, c-format
 msgid "Overwrite file \"%s\"?"
-msgstr ""
+msgstr "Ecrasez le fichier \"%s\"?"
 
 #: src/file.c:960 src/file.c:1155
 msgid "File already exists."
-msgstr ""
+msgstr "Ce fichier existe déjà."
 
 #: src/file.c:1271
 #, c-format
 msgid "Save changes to document \"%s\" before closing?"
-msgstr ""
+msgstr "Enregistrez les changements au document \"%s\" avant de fermer?"
 
 #: src/file.c:1279
 msgid "Your changes will be lost if you don't save them."
-msgstr ""
+msgstr "Vos changements seront perdus si vous ne les enregistrez pas."
 
 #: src/file.c:1282
 msgid "Close without saving"
-msgstr ""
+msgstr "Fermer sans enregistrer"
 
 # src/print.c:171
 # src/prefs.c:463 src/prefs.c:470 src/prop_line.c:202
@@ -617,16 +594,15 @@ msgstr "mm"
 # src/prefs.c:92
 # src/prefs.c:86
 #: src/prefs-dialog.c:248 data/glade/prefs-dialog.glade.h:22
-#, fuzzy
 msgid "gLabels Preferences"
-msgstr "Glabels : Préférences"
+msgstr "gLabels : Préférences"
 
 #.
 #. * Submenu: Order
 #.
 #: src/view.c:3570 data/ui/glabels-ui.xml.h:157
 msgid "_Order"
-msgstr ""
+msgstr "_Ordre"
 
 # src/rotate_select.c:187
 # src/rotate_select.c:187
@@ -636,32 +612,30 @@ msgstr ""
 #. * Submenu: Rotate/Flip
 #.
 #: src/view.c:3591 data/ui/glabels-ui.xml.h:163
-#, fuzzy
 msgid "_Rotate/Flip"
-msgstr "Rotation"
+msgstr "_Rotation/Renversement"
 
 #.
 #. * Submenu: Align Horizontally
 #.
 #: src/view.c:3624
 msgid "Align _Horizontally"
-msgstr ""
+msgstr "Aligner _Horizontalement"
 
 #.
 #. * Submenu: Align Vertically
 #.
 #: src/view.c:3663
 msgid "Align _Vertically"
-msgstr ""
+msgstr "Aligner _Verticalement"
 
 # src/display.c:1157 src/display.c:1205
 # src/display.c:1160 src/display.c:1208
 # src/display.c:1171 src/display.c:1219
 # src/display.c:1186 src/display.c:1234
 #: src/view.c:3724 data/ui/glabels-ui.xml.h:140
-#, fuzzy
 msgid "_Delete"
-msgstr "Supprimer"
+msgstr "_Supprimer"
 
 # src/item_box.c:251
 # src/item_box.c:251
@@ -669,9 +643,8 @@ msgstr "Supprimer"
 # src/item_box.c:235
 #. Build editor.
 #: src/view-box.c:223
-#, fuzzy
 msgid "Box object properties"
-msgstr "Editer les propriétés de l'objet boîte..."
+msgstr "Propriétés de l'objet boîte"
 
 # src/item_ellipse.c:256
 # src/item_ellipse.c:256
@@ -679,9 +652,8 @@ msgstr "Editer les propri
 # src/item_ellipse.c:237
 #. Build editor.
 #: src/view-ellipse.c:223
-#, fuzzy
 msgid "Ellipse object properties"
-msgstr "Editer les propriétés de l'objet ellipse..."
+msgstr "Propriétés de l'objet ellipse"
 
 # src/item_box.c:251
 # src/item_box.c:251
@@ -689,9 +661,8 @@ msgstr "Editer les propri
 # src/item_box.c:235
 #. Build editor.
 #: src/view-line.c:223
-#, fuzzy
 msgid "Line object properties"
-msgstr "Editer les propriétés de l'objet boîte..."
+msgstr "Propriétés de l'objet boîte"
 
 # src/item_image.c:272
 # src/item_image.c:272
@@ -699,9 +670,8 @@ msgstr "Editer les propri
 # src/item_image.c:257
 #. Build editor.
 #: src/view-image.c:222
-#, fuzzy
 msgid "Image object properties"
-msgstr "Editer les propriétés de l'objet image..."
+msgstr "Propriétés de l'objet image"
 
 # src/item_box.c:251
 # src/item_box.c:251
@@ -709,9 +679,8 @@ msgstr "Editer les propri
 # src/item_box.c:235
 #. Build editor.
 #: src/view-text.c:250
-#, fuzzy
 msgid "Text object properties"
-msgstr "Editer les propriétés de l'objet boîte..."
+msgstr "Propriétés de l'objet texte"
 
 # src/item_text.c:442 src/item_text.c:627
 # src/item_text.c:442 src/item_text.c:627
@@ -727,16 +696,14 @@ msgstr "Texte"
 # src/item_barcode.c:287
 #. Build editor.
 #: src/view-barcode.c:209
-#, fuzzy
 msgid "Barcode object properties"
-msgstr "Editer les propriétés de l'objet code-barre..."
+msgstr "Propriétés de l'objet code-barre"
 
 # src/item_barcode.c:564 src/item_barcode.c:588 src/print.c:641
 # src/item_barcode.c:570 src/item_barcode.c:594 src/print.c:641
 # src/item_barcode.c:549 src/item_barcode.c:572 src/print.c:799
 # src/item_barcode.c:549 src/item_barcode.c:572 src/print.c:600
 #: src/view-barcode.c:579 src/print.c:1088
-#, fuzzy
 msgid "Invalid barcode data"
 msgstr "Code-barre invalide"
 
@@ -745,9 +712,8 @@ msgstr "Code-barre invalide"
 # src/menu.c:132 src/menu.c:223
 # src/menu.c:132 src/menu.c:223
 #: src/merge-properties-dialog.c:231
-#, fuzzy
 msgid "Merge Properties"
-msgstr "Propriétés de fusion"
+msgstr "Propriétés de fusion"
 
 # src/merge_properties.c:131
 # src/merge_properties.c:131
@@ -775,18 +741,18 @@ msgstr "Emplacement :"
 # src/merge_ui_text.c:170
 #: src/merge-properties-dialog.c:282 src/merge-properties-dialog.c:393
 msgid "Select merge-database source"
-msgstr "Sélection de la base de données source de la fusion"
+msgstr "Sélection du fichier de données pour la fusion"
 
 # src/merge_ui.c:207 src/merge_ui.c:242 src/merge_ui.c:387 src/merge_ui.c:428
 # src/merge_ui.c:207 src/merge_ui.c:242 src/merge_ui.c:387 src/merge_ui.c:428
 #: src/merge-properties-dialog.c:289 src/merge-properties-dialog.c:404
 msgid "N/A"
-msgstr "Non défini"
+msgstr "Non défini"
 
 #. ---- Sample Fields section ----
 #: src/merge-properties-dialog.c:300
 msgid "Record selection/preview:"
-msgstr ""
+msgstr "Sélection/Prévisualisation des enregistrements :"
 
 # src/display.c:1157 src/display.c:1205
 # src/display.c:1160 src/display.c:1208
@@ -794,11 +760,11 @@ msgstr ""
 # src/menu.c:94
 #: src/merge-properties-dialog.c:326
 msgid "Select"
-msgstr "Sélectionner"
+msgstr "Sélectionner"
 
 #: src/merge-properties-dialog.c:334
 msgid "Record/Field"
-msgstr ""
+msgstr "Enregistrements/Champs"
 
 # src/item_barcode.c:309
 # src/item_barcode.c:308
@@ -806,7 +772,7 @@ msgstr ""
 # src/item_barcode.c:297
 #: src/merge-properties-dialog.c:342 data/glade/object-editor.glade.h:9
 msgid "Data"
-msgstr "Données"
+msgstr "Données"
 
 # src/print.c:149
 # src/print.c:149
@@ -818,16 +784,15 @@ msgstr "Imprimer"
 
 #: src/print-dialog.c:281
 msgid "_Job"
-msgstr ""
+msgstr "_Travail"
 
 # src/print.c:149
 # src/print.c:149
 # src/print.c:141
 # src/print_dialog.c:99
 #: src/print-dialog.c:286
-#, fuzzy
 msgid "P_rinter"
-msgstr "Imprimer"
+msgstr "_Imprimante"
 
 # src/print.c:153
 # src/print.c:153
@@ -843,7 +808,7 @@ msgstr "Copies"
 #. ------- Add merge control widget ------------
 #: src/print-dialog.c:322
 msgid "Document merge control"
-msgstr "Contrôle de la fusion de document"
+msgstr "Contrôle de la fusion de document"
 
 # src/print.c:171
 # src/print.c:171
@@ -856,7 +821,7 @@ msgstr "Options"
 
 #: src/print-dialog.c:351
 msgid "print crop marks"
-msgstr ""
+msgstr "imprimer les guides de coupe"
 
 # src/print.c:235
 # src/print.c:235
@@ -864,11 +829,11 @@ msgstr ""
 # src/print_dialog.c:241 src/print_dialog.c:280
 #: src/print-dialog.c:553 src/print-dialog.c:592
 msgid "Print preview"
-msgstr "Aperçu avant impression"
+msgstr "Aperçu avant impression"
 
 #: src/template-designer.c:409 data/glade/template-designer.glade.h:73
 msgid "gLabels Template Designer"
-msgstr ""
+msgstr "Créateur de patrons gLabels"
 
 #: src/bc.c:60
 msgid "POSTNET (any)"
@@ -984,7 +949,7 @@ msgstr ""
 
 #: src/label.c:569
 msgid "Untitled"
-msgstr ""
+msgstr "Sans titre"
 
 # src/label.c:186 src/label.c:211
 # src/label.c:186 src/label.c:211
@@ -1004,24 +969,23 @@ msgstr "Pas de racine de document"
 
 #: src/xml-label.c:264
 msgid "Importing from glabels 0.1 format"
-msgstr ""
+msgstr "Import depuis le format glabels 0.1"
 
 #: src/xml-label.c:272
 msgid "Importing from glabels 0.4 format"
-msgstr ""
+msgstr "Import depuis le format glabels 0.4"
 
 #: src/xml-label.c:279
 msgid "Importing from glabels 1.91 format"
-msgstr ""
+msgstr "Import depuis le format glabels 1.91"
 
 # src/label.c:248
 # src/label.c:249
 # src/label.c:236
 # src/label.c:234
 #: src/xml-label.c:282
-#, fuzzy
 msgid "bad document, unknown glabels Namespace"
-msgstr "document de type erroné, aucun espace de noms glabels trouvé"
+msgstr "document de type erroné, espace de noms glabels inconnu"
 
 # src/label.c:253
 # src/label.c:254
@@ -1037,7 +1001,7 @@ msgstr "Mauvais noeud racine = \"%s\""
 # src/label.c:241
 # src/label.c:239
 #: src/xml-label.c:348 src/xml-label-191.c:165
-#, fuzzy, c-format
+#, c-format
 msgid "bad node in Document node =  \"%s\""
 msgstr "Mauvais noeud racine = \"%s\""
 
@@ -1055,30 +1019,30 @@ msgstr "mauvais noeud =  \"%s\""
 # src/label.c:294
 # src/label.c:290
 #: src/xml-label.c:796 src/xml-label-191.c:605
-#, fuzzy, c-format
+#, c-format
 msgid "bad node in Data node =  \"%s\""
-msgstr "mauvais noeud =  \"%s\""
+msgstr "mauvais noeud de données =  \"%s\""
 
-#: src/xml-label.c:962 libglabels/xml-template.c:528
+#: src/xml-label.c:962 libglabels/xml-template.c:535
 msgid "Utf8 conversion error."
-msgstr ""
+msgstr "Erreur de conversion Utf8"
 
 # src/label.c:487
 # src/label.c:493
 # src/label.c:589
 # src/label.c:587
-#: src/xml-label.c:969 libglabels/xml-template.c:535
+#: src/xml-label.c:969 libglabels/xml-template.c:542
 msgid "Problem saving xml file."
-msgstr "Problème de sauvegarde du fichier xml."
+msgstr "Problème de sauvegarde du fichier xml."
 
 #. This should always be an id, but just in case a name
 #. slips by!
-#: src/xml-label-191.c:680 libglabels/xml-template.c:192
+#: src/xml-label-191.c:680 libglabels/xml-template.c:199
 #, c-format
 msgid "Unknown page size id \"%s\", trying as name"
 msgstr ""
 
-#: src/xml-label-191.c:690 libglabels/xml-template.c:202
+#: src/xml-label-191.c:690 libglabels/xml-template.c:209
 #, c-format
 msgid "Unknown page size id or name \"%s\""
 msgstr ""
@@ -1092,38 +1056,34 @@ msgstr "Aucun"
 # src/merge.c:98
 # src/merge.c:94
 #: src/merge-init.c:53
-#, fuzzy
 msgid "Text file with comma delimeters (CSV)"
-msgstr "Texte séparé par des virgules (CSV)"
+msgstr "Texte séparé par des virgules (CSV)"
 
 # src/merge.c:107
 # src/merge.c:102
 #: src/merge-init.c:60
-#, fuzzy
 msgid "Text file with colon delimeters"
-msgstr "Texte séparé par des deux-points"
+msgstr "Texte séparé par des deux-points"
 
 # src/merge.c:89
 # src/merge.c:86
 #: src/merge-init.c:67
-#, fuzzy
 msgid "Text file with tab delimeters"
-msgstr "Texte avec séparateurs de tabulation"
+msgstr "Texte avec séparateurs de tabulation"
 
 # src/item_box.c:274 src/item_ellipse.c:279
 # src/item_box.c:274 src/item_ellipse.c:279
 # src/item_box.c:258 src/item_ellipse.c:260
 # src/item_box.c:258 src/item_ellipse.c:260
 #: src/wdgt-image-select.c:201 data/glade/object-editor.glade.h:11
-#, fuzzy
 msgid "File:"
-msgstr "Remplissage"
+msgstr "Fichier :"
 
 # src/prop_bc_data.c:196 src/prop_text_entry.c:180
 # src/prop_bc_data.c:196 src/prop_text_entry.c:180
 #: src/wdgt-image-select.c:245 data/glade/object-editor.glade.h:16
 msgid "Key:"
-msgstr "Clé :"
+msgstr "Clé :"
 
 # src/print_copies.c:193
 # src/print_copies.c:193
@@ -1155,19 +1115,19 @@ msgstr "de :"
 # src/print_copies.c:198
 #: src/wdgt-print-copies.c:207
 msgid "to:"
-msgstr "à :"
+msgstr "à :"
 
 # src/print_copies_merge.c:197
 # src/print_merge.c:170
 #: src/wdgt-print-merge.c:178
 msgid "Start on label"
-msgstr "Commencer par l'étiquette"
+msgstr "Commencer par l'étiquette"
 
 # src/print_copies_merge.c:206
 # src/print_merge.c:179
 #: src/wdgt-print-merge.c:186
 msgid "on 1st sheet"
-msgstr "en 1ère page"
+msgstr "en 1ère page"
 
 # src/print.c:153
 # src/print.c:153
@@ -1207,7 +1167,7 @@ msgstr "Taille de page :"
 # src/media_select.c:232
 #: src/wdgt-media-select.c:290
 msgid "Label size:"
-msgstr "Taille d'étiquette :"
+msgstr "Taille d'étiquette :"
 
 # src/media_select.c:231
 # src/media_select.c:257
@@ -1229,9 +1189,9 @@ msgstr "%d x %d  (%d par feuille)"
 # src/media_select.c:481
 # src/media_select.c:353
 #: src/wdgt-media-select.c:582
-#, fuzzy, c-format
+#, c-format
 msgid "%d per sheet"
-msgstr "%d x %d  (%d par feuille)"
+msgstr "%d par feuille"
 
 # src/media_select.c:522
 # src/media_select.c:488
@@ -1252,12 +1212,12 @@ msgstr "%.5g x %.5g %s"
 #: src/wdgt-media-select.c:630 src/wdgt-media-select.c:644
 #, c-format
 msgid "%s %s diameter"
-msgstr ""
+msgstr "%s %s diamètre"
 
 #: src/wdgt-media-select.c:634 src/wdgt-media-select.c:648
 #, c-format
 msgid "%.5g %s diameter"
-msgstr ""
+msgstr "%.5g %s diamètre"
 
 # src/rotate_select.c:187
 # src/rotate_select.c:187
@@ -1271,9 +1231,8 @@ msgstr "Rotation"
 # src/merge_ui_text.c:334
 #. This is the default custom color
 #: src/mygal/color-palette.c:396
-#, fuzzy
 msgid "custom"
-msgstr "Clé de champ spécifique"
+msgstr "Personnalisé"
 
 # src/prop_bc.c:204 src/prop_fill.c:186 src/prop_line.c:203
 # src/prop_text.c:263
@@ -1285,13 +1244,12 @@ msgstr "Cl
 # src/prop_text.c:234
 #. "Custom" color - we'll pop up a GnomeColorPicker
 #: src/mygal/color-palette.c:438
-#, fuzzy
 msgid "Custom Color:"
-msgstr "Couleur :"
+msgstr "Couleur personnalisée :"
 
 #: src/mygal/color-palette.c:446
 msgid "Choose Custom Color"
-msgstr ""
+msgstr "Choisir une couleur personnalisée"
 
 #: src/mygal/color-palette.c:579
 msgid "black"
@@ -1394,9 +1352,8 @@ msgstr ""
 # src/item_image.c:268 src/menu.c:113
 # src/item_image.c:268 src/menu.c:113
 #: src/mygal/color-palette.c:609 src/mygal/color-palette.c:641
-#, fuzzy
 msgid "magenta"
-msgstr "Image"
+msgstr ""
 
 #: src/mygal/color-palette.c:610
 msgid "bright orange"
@@ -1410,9 +1367,8 @@ msgstr ""
 # src/prop_vector.c:224
 # src/prop_vector.c:224
 #: src/mygal/color-palette.c:612
-#, fuzzy
 msgid "green"
-msgstr "degrés"
+msgstr ""
 
 #: src/mygal/color-palette.c:613 src/mygal/color-palette.c:643
 msgid "cyan"
@@ -1484,118 +1440,115 @@ msgstr ""
 # src/template.c:223
 #: libglabels/template.c:897
 msgid "No template files found!"
-msgstr "Aucun fichier de patron trouvé !"
+msgstr "Aucun fichier de patron trouvé !"
 
 #. Create and append an "Other" entry.
 #: libglabels/paper.c:67
 msgid "Other"
-msgstr ""
+msgstr "Autre"
 
 # src/template.c:179
 # src/template.c:178
 # src/template.c:223
 #: libglabels/paper.c:361
-#, fuzzy
 msgid "No paper files found!"
-msgstr "Aucun fichier de patron trouvé !"
+msgstr "Aucun fichier de papier trouvé !"
 
 #: data/ui/glabels-ui.xml.h:1
 msgid "About glabels"
-msgstr ""
+msgstr "A propos de glabels"
 
 #: data/ui/glabels-ui.xml.h:2
 msgid "About..."
-msgstr ""
+msgstr "A propos..."
 
 #: data/ui/glabels-ui.xml.h:3
 msgid "Align _Horizontal"
-msgstr ""
+msgstr "Aligner _Horizontalement"
 
 #: data/ui/glabels-ui.xml.h:4
 msgid "Align _Vertical"
-msgstr ""
+msgstr "Aligner _Verticalement"
 
 #: data/ui/glabels-ui.xml.h:5
 msgid "Align objects to bottoms"
-msgstr ""
+msgstr "Aligner le bas des objets"
 
 #: data/ui/glabels-ui.xml.h:6
 msgid "Align objects to horizontal centers"
-msgstr ""
+msgstr "Aligner horizontalement le centre des objets"
 
 #: data/ui/glabels-ui.xml.h:7
 msgid "Align objects to left edges"
-msgstr ""
+msgstr "Aligner la gauche des objets"
 
 #: data/ui/glabels-ui.xml.h:8
 msgid "Align objects to right edges"
-msgstr ""
+msgstr "Aligner la droite des objets"
 
 #: data/ui/glabels-ui.xml.h:9
 msgid "Align objects to tops"
-msgstr ""
+msgstr "Aligner le haut des objets"
 
 #: data/ui/glabels-ui.xml.h:10
 msgid "Align objects to vertical centers"
-msgstr ""
+msgstr "Aligner verticalement le centre des objets"
 
 #: data/ui/glabels-ui.xml.h:12
 msgid "Bold"
-msgstr ""
+msgstr "Gras"
 
 # src/item_barcode.c:337
 # src/item_barcode.c:343 src/prefs.c:243
 # src/item_barcode.c:320 src/prefs.c:221
 # src/item_barcode.c:320 src/prefs.c:215
 #: data/ui/glabels-ui.xml.h:14
-#, fuzzy
 msgid "Center align"
-msgstr "Général"
+msgstr "Centrer"
 
 #: data/ui/glabels-ui.xml.h:15
 msgid "Center objects to horizontal label center"
-msgstr ""
+msgstr "Déplacer les objets horizontalement au centre de l'étiquette"
 
 #: data/ui/glabels-ui.xml.h:16
 msgid "Center objects to vertical label center"
-msgstr ""
+msgstr "Déplacer les objets verticalement au centre de l'étiquette"
 
 #: data/ui/glabels-ui.xml.h:17
 msgid "Change the visibility of markup lines in the current window"
-msgstr ""
+msgstr "Afficher ou non les lignes de marges dans la fenêtre courante"
 
 #: data/ui/glabels-ui.xml.h:18
 msgid "Change the visibility of the drawing toolbar in the current window"
-msgstr ""
+msgstr "Afficher ou non la barre d'outils de dessin dans la fenêtre courante"
 
 #: data/ui/glabels-ui.xml.h:19
 msgid "Change the visibility of the grid in the current window"
-msgstr ""
+msgstr "Afficher ou non la grille dans la fenêtre courante"
 
 #: data/ui/glabels-ui.xml.h:20
 msgid "Change the visibility of the main toolbar in the current window"
-msgstr ""
+msgstr "Afficher ou non la barre d'outils principale dans la fenêtre courante"
 
 #: data/ui/glabels-ui.xml.h:21
 msgid "Change the visibility of the property toolbar in the current window"
-msgstr ""
+msgstr "Afficher ou non la barre d'outils de propriétés dans la fenêtre courante"
 
 #: data/ui/glabels-ui.xml.h:22
 msgid "Close"
-msgstr ""
+msgstr "Fermer"
 
 # src/menu.c:142
 # src/menu.c:142
 # src/menu.c:172
 # src/menu.c:172
 #: data/ui/glabels-ui.xml.h:23
-#, fuzzy
 msgid "Close the current file"
-msgstr "Sauvegarder le fichier en cours"
+msgstr "Clore le fichier en cours"
 
 #: data/ui/glabels-ui.xml.h:24
 msgid "Configure the application"
-msgstr ""
+msgstr "Configurer le logiciel"
 
 #: data/ui/glabels-ui.xml.h:25
 msgid "Contents"
@@ -1603,34 +1556,31 @@ msgstr ""
 
 #: data/ui/glabels-ui.xml.h:26
 msgid "Copy"
-msgstr ""
+msgstr "Copier"
 
 # src/menu.c:86
 # src/menu.c:86
 # src/menu.c:86
 # src/menu.c:86
 #: data/ui/glabels-ui.xml.h:27
-#, fuzzy
 msgid "Copy the selection"
-msgstr "Supprime toutes les sélections"
+msgstr "Copier la sélection"
 
 # src/tools.c:70
 # src/tools.c:70
 # src/menu.c:106 src/menu.c:197
 # src/menu.c:106 src/menu.c:197
 #: data/ui/glabels-ui.xml.h:28
-#, fuzzy
 msgid "Create a custom template"
-msgstr "Créer un objet ligne"
+msgstr "Créer un patron personnalisé"
 
 # src/tools.c:70
 # src/tools.c:70
 # src/menu.c:106 src/menu.c:197
 # src/menu.c:106 src/menu.c:197
 #: data/ui/glabels-ui.xml.h:29
-#, fuzzy
 msgid "Create a new document"
-msgstr "Créer un objet ligne"
+msgstr "Créer un nouveau document"
 
 # src/tools.c:79
 # src/tools.c:79
@@ -1638,7 +1588,7 @@ msgstr "Cr
 # src/menu.c:116 src/menu.c:206
 #: data/ui/glabels-ui.xml.h:30
 msgid "Create barcode object"
-msgstr "Créer un objet code-barre"
+msgstr "Créer un objet code-barre"
 
 # src/tools.c:67
 # src/tools.c:67
@@ -1646,7 +1596,7 @@ msgstr "Cr
 # src/menu.c:103 src/menu.c:194
 #: data/ui/glabels-ui.xml.h:31
 msgid "Create box/rectangle object"
-msgstr "Créer un objet boîte/rectangle"
+msgstr "Créer un objet boîte/rectangle"
 
 # src/tools.c:73
 # src/tools.c:73
@@ -1654,7 +1604,7 @@ msgstr "Cr
 # src/menu.c:110 src/menu.c:200
 #: data/ui/glabels-ui.xml.h:32
 msgid "Create ellipse/circle object"
-msgstr "Créer un objet ellipse/cercle"
+msgstr "Créer un objet ellipse/cercle"
 
 # src/tools.c:76
 # src/tools.c:76
@@ -1662,7 +1612,7 @@ msgstr "Cr
 # src/menu.c:113 src/menu.c:203
 #: data/ui/glabels-ui.xml.h:33
 msgid "Create image object"
-msgstr "Créer un objet image"
+msgstr "Créer un objet image"
 
 # src/tools.c:70
 # src/tools.c:70
@@ -1670,7 +1620,7 @@ msgstr "Cr
 # src/menu.c:106 src/menu.c:197
 #: data/ui/glabels-ui.xml.h:34
 msgid "Create line object"
-msgstr "Créer un objet ligne"
+msgstr "Créer un objet ligne"
 
 # src/tools.c:64
 # src/tools.c:64
@@ -1678,46 +1628,45 @@ msgstr "Cr
 # src/menu.c:100 src/menu.c:191
 #: data/ui/glabels-ui.xml.h:35
 msgid "Create text object"
-msgstr "Créer un objet texte"
+msgstr "Créer un objet texte"
 
 #: data/ui/glabels-ui.xml.h:36
 msgid "Cu_t"
-msgstr ""
+msgstr "Cou_per"
 
 # src/merge_ui_text.c:334
 # src/merge_ui_text.c:334
 #: data/ui/glabels-ui.xml.h:37
-#, fuzzy
 msgid "Customize"
-msgstr "Clé de champ spécifique"
+msgstr "Personnaliser"
 
 #: data/ui/glabels-ui.xml.h:38
 msgid "Customize Drawing Toolbar"
-msgstr ""
+msgstr "Personnaliser la Barre d'Outils Dessin"
 
 #: data/ui/glabels-ui.xml.h:39
 msgid "Customize Main Toolbar"
-msgstr ""
+msgstr "Personnaliser le Barre d'Outils Principale"
 
 #: data/ui/glabels-ui.xml.h:40
 msgid "Customize Property Toolbar"
-msgstr ""
+msgstr "Personnaliser la Barre d'Outils de Propriétés"
 
 #: data/ui/glabels-ui.xml.h:41
 msgid "Customize toolbars"
-msgstr ""
+msgstr "Personnaliser les Barres d'Outils"
 
 #: data/ui/glabels-ui.xml.h:42
 msgid "Cut"
-msgstr ""
+msgstr "Couper"
 
 #: data/ui/glabels-ui.xml.h:43
 msgid "Cut the selection"
-msgstr ""
+msgstr "Couper la selection"
 
 #: data/ui/glabels-ui.xml.h:44
 msgid "Decrease magnification"
-msgstr ""
+msgstr "Réduire le zoom"
 
 # src/display.c:1157 src/display.c:1205
 # src/display.c:1160 src/display.c:1208
@@ -1732,13 +1681,12 @@ msgstr "Supprimer"
 # src/menu.c:100 src/menu.c:191
 # src/menu.c:100 src/menu.c:191
 #: data/ui/glabels-ui.xml.h:46
-#, fuzzy
 msgid "Delete the selected objects"
-msgstr "Créer un objet texte"
+msgstr "Supprimer les objets sélectionnés"
 
 #: data/ui/glabels-ui.xml.h:47
 msgid "Drawing toolbar"
-msgstr ""
+msgstr "Barre d'Outils de dessin"
 
 #: data/ui/glabels-ui.xml.h:48
 msgid "Dump XML"
@@ -1754,115 +1702,108 @@ msgstr ""
 # src/menu.c:133
 #: data/ui/glabels-ui.xml.h:50
 msgid "Edit merge properties"
-msgstr "Editer les propriétés de fusion"
+msgstr "Editer les propriétés de fusion"
 
 #: data/ui/glabels-ui.xml.h:54
 msgid "Flip object horizontally"
-msgstr ""
+msgstr "Retourner l'objet horizontalement"
 
 #: data/ui/glabels-ui.xml.h:55
 msgid "Flip object vertically"
-msgstr ""
+msgstr "Retourner l'objet verticalement"
 
 # src/mdi.c:482
 # src/mdi.c:488
 # src/mdi.c:459
 # src/mdi.c:459
 #: data/ui/glabels-ui.xml.h:56
-#, fuzzy
 msgid "Font name"
-msgstr "Ne pas sauver"
+msgstr "Nom de police"
 
 # src/menu.c:86
 # src/menu.c:86
 # src/menu.c:86
 # src/menu.c:86
 #: data/ui/glabels-ui.xml.h:57
-#, fuzzy
 msgid "Font selector"
-msgstr "Supprime toutes les sélections"
+msgstr "Sélecteur de polices"
 
 # src/mdi.c:482
 # src/mdi.c:488
 # src/mdi.c:459
 # src/mdi.c:459
 #: data/ui/glabels-ui.xml.h:58
-#, fuzzy
 msgid "Font size"
-msgstr "Ne pas sauver"
+msgstr "Taille de polices"
 
 #: data/ui/glabels-ui.xml.h:59
 msgid "Icon and _Text"
-msgstr ""
+msgstr "Icones et _Textes"
 
 #: data/ui/glabels-ui.xml.h:60
 msgid "Increase magnification"
-msgstr ""
+msgstr "Augmenter le zoom"
 
 #: data/ui/glabels-ui.xml.h:61
 msgid "Italic"
-msgstr ""
+msgstr "Italique"
 
 #: data/ui/glabels-ui.xml.h:63
 msgid "Left align"
-msgstr ""
+msgstr "Aligner Ã  gauche"
 
 #: data/ui/glabels-ui.xml.h:65
 msgid "Line width"
-msgstr ""
+msgstr "Largeur de la ligne"
 
 #: data/ui/glabels-ui.xml.h:66
 msgid "Lower object to bottom"
-msgstr ""
+msgstr "Descendre l'objet Ã  l'arrière plan"
 
 #: data/ui/glabels-ui.xml.h:67
 msgid "M_arkup"
-msgstr ""
+msgstr "_Marges"
 
 #: data/ui/glabels-ui.xml.h:68
 msgid "Main toolbar"
-msgstr ""
+msgstr "Barre d'outil principale"
 
 # src/preferences.c:213
 #: data/ui/glabels-ui.xml.h:69
-#, fuzzy
 msgid "Markup"
-msgstr "Démarrage"
+msgstr "Marges"
 
 # src/item_box.c:251
 # src/item_box.c:251
 # src/merge_properties.c:82
 # src/merge_properties.c:82
 #: data/ui/glabels-ui.xml.h:70
-#, fuzzy
 msgid "Modify document properties"
-msgstr "Editer les propriétés de fusion de document"
+msgstr "Editer les propriétés du document"
 
 # src/menu.c:50
 # src/menu.c:50
 # src/menu.c:50
 # src/menu.c:50
 #: data/ui/glabels-ui.xml.h:71
-#, fuzzy
 msgid "New"
-msgstr "_Nouveau"
+msgstr "Nouveau"
 
 # src/item_text.c:467
 # src/item_text.c:467
 # src/item_text.c:482
 # src/item_text.c:482
 #: data/ui/glabels-ui.xml.h:72
-#, fuzzy
 msgid "Object property editor"
-msgstr "Propriétés du texte"
+msgstr "Editeur de propriétés des objets"
 
 #: data/ui/glabels-ui.xml.h:73
 msgid "Only show icons in the drawing toolbar"
-msgstr ""
+msgstr "Ne montrer que les icones dans la barre d'outils de dessin"
 
 #: data/ui/glabels-ui.xml.h:74
 msgid "Only show icons in the main toolbar"
-msgstr ""
+msgstr "Ne montrer que les icones dans la barre d'outils principale"
 
 # src/menu.c:140
 # src/menu.c:140
@@ -1877,42 +1818,38 @@ msgstr "Ouvrir un fichier"
 # src/file.c:213
 # src/file.c:213
 #: data/ui/glabels-ui.xml.h:77
-#, fuzzy
 msgid "Open the glabels manual"
-msgstr "Ouvrir une Ã©tiquette"
+msgstr "Ouvrir le manuel de glabels"
 
 #: data/ui/glabels-ui.xml.h:78
 msgid "Paste"
-msgstr ""
+msgstr "Coller"
 
 #: data/ui/glabels-ui.xml.h:79
 msgid "Paste the clipboard"
-msgstr ""
+msgstr "Coller le presse-papier"
 
 # src/preferences.c:92
 # src/prefs.c:101
 # src/prefs.c:92
 # src/prefs.c:86
 #: data/ui/glabels-ui.xml.h:80
-#, fuzzy
 msgid "Pr_eferences..."
-msgstr "Glabels : Préférences"
+msgstr "Pré_férences..."
 
 # src/preferences.c:92
 # src/prefs.c:101
 # src/prefs.c:92
 # src/prefs.c:86
 #: data/ui/glabels-ui.xml.h:81
-#, fuzzy
 msgid "Preferences"
-msgstr "Glabels : Préférences"
+msgstr "Préférences"
 
 # src/menu.c:145
 # src/menu.c:145
 # src/menu.c:175
 # src/menu.c:175
 #: data/ui/glabels-ui.xml.h:83
-#, fuzzy
 msgid "Print the current file"
 msgstr "Imprimer le fichier en cours"
 
@@ -1921,46 +1858,44 @@ msgstr "Imprimer le fichier en cours"
 # src/item_text.c:482
 # src/item_text.c:482
 #: data/ui/glabels-ui.xml.h:84
-#, fuzzy
 msgid "Proper_ties..."
-msgstr "Propriétés du texte"
+msgstr "P_ropriétés..."
 
 # src/item_text.c:467
 # src/item_text.c:467
 # src/item_text.c:482
 # src/item_text.c:482
 #: data/ui/glabels-ui.xml.h:85
-#, fuzzy
 msgid "Properties"
-msgstr "Propriétés du texte"
+msgstr "Propriétés"
 
 #: data/ui/glabels-ui.xml.h:86
 msgid "Property toolbar"
-msgstr ""
+msgstr "Barre d'outil de propriétés"
 
 #: data/ui/glabels-ui.xml.h:87
 msgid "Quit"
-msgstr ""
+msgstr "Quitter"
 
 #: data/ui/glabels-ui.xml.h:88
 msgid "Quit the program"
-msgstr ""
+msgstr "Quitter le programme"
 
 #: data/ui/glabels-ui.xml.h:89
 msgid "Raise object to top"
-msgstr ""
+msgstr "Remonter l'objet au sommet"
 
 #: data/ui/glabels-ui.xml.h:90
 msgid "Recent _Files"
-msgstr ""
+msgstr "_Fichiers récents"
 
 #: data/ui/glabels-ui.xml.h:91
 msgid "Redo"
-msgstr ""
+msgstr "Refaire"
 
 #: data/ui/glabels-ui.xml.h:92
 msgid "Redo the undone action"
-msgstr ""
+msgstr "Refaire l'action annulée"
 
 # src/menu.c:86
 # src/menu.c:86
@@ -1968,33 +1903,32 @@ msgstr ""
 # src/menu.c:86
 #: data/ui/glabels-ui.xml.h:93
 msgid "Remove all selections"
-msgstr "Supprime toutes les sélections"
+msgstr "Supprimer toutes les sélections"
 
 #: data/ui/glabels-ui.xml.h:95
 #, no-c-format
 msgid "Restore scale to 100%"
-msgstr ""
+msgstr "Remettre l'échelle Ã  100%"
 
 #: data/ui/glabels-ui.xml.h:96
 msgid "Right align"
-msgstr ""
+msgstr "Aligner Ã  droite"
 
 #: data/ui/glabels-ui.xml.h:99
 msgid "Rotate object 90 clockwise"
-msgstr ""
+msgstr "Tourner l'objet de 90 degrés dans le sens des aiguilles d'une montre"
 
 #: data/ui/glabels-ui.xml.h:100
 msgid "Rotate object 90 counter-clockwise"
-msgstr ""
+msgstr "Tourner l'objet de 90 degrés dans le sens inverse des aiguilles d'une montre"
 
 # src/file.c:271 src/mdi.c:660
 # src/file.c:271 src/mdi.c:666
 # src/file.c:311 src/mdi.c:623
 # src/file.c:311 src/mdi.c:623
 #: data/ui/glabels-ui.xml.h:101
-#, fuzzy
 msgid "Save"
-msgstr "Enregistrer sous"
+msgstr "Enregistrer"
 
 # src/file.c:271 src/mdi.c:660
 # src/file.c:271 src/mdi.c:666
@@ -2009,49 +1943,44 @@ msgstr "Enregistrer sous"
 # src/file.c:311 src/mdi.c:623
 # src/file.c:311 src/mdi.c:623
 #: data/ui/glabels-ui.xml.h:103
-#, fuzzy
 msgid "Save _As..."
-msgstr "Enregistrer sous"
+msgstr "Enregistrer _sous..."
 
 # src/menu.c:142
 # src/menu.c:142
 # src/menu.c:172
 # src/menu.c:172
 #: data/ui/glabels-ui.xml.h:104
-#, fuzzy
 msgid "Save the current file"
 msgstr "Sauvegarder le fichier en cours"
 
 #: data/ui/glabels-ui.xml.h:105
 msgid "Save the current file with a different name"
-msgstr ""
+msgstr "Enregistrer le fichier en cours avec un nom différent"
 
 # src/menu.c:86
 # src/menu.c:86
 # src/menu.c:85
 # src/menu.c:85
 #: data/ui/glabels-ui.xml.h:106
-#, fuzzy
 msgid "Select All"
-msgstr "_Désélectionne tout"
+msgstr "Tout Sélectionner"
 
 # src/menu.c:86
 # src/menu.c:86
 # src/menu.c:85
 # src/menu.c:85
 #: data/ui/glabels-ui.xml.h:107
-#, fuzzy
 msgid "Select _All"
-msgstr "_Désélectionne tout"
+msgstr "_Tout sélectionner"
 
 # src/tools.c:59
 # src/tools.c:59
 # src/menu.c:95 src/menu.c:186
 # src/menu.c:95 src/menu.c:186
 #: data/ui/glabels-ui.xml.h:108
-#, fuzzy
 msgid "Select all objects"
-msgstr "Sélectionner, déplacer et modifier les objets"
+msgstr "Sélectionner tous les objets"
 
 # src/tools.c:59
 # src/tools.c:59
@@ -2059,47 +1988,47 @@ msgstr "S
 # src/menu.c:95 src/menu.c:186
 #: data/ui/glabels-ui.xml.h:109
 msgid "Select, move and modify objects"
-msgstr "Sélectionner, déplacer et modifier les objets"
+msgstr "Sélectionner, déplacer et modifier les objets"
 
 #: data/ui/glabels-ui.xml.h:111
 msgid "Set drawing toolbar button style according to desktop default"
-msgstr ""
+msgstr "Utiliser les préférences du bureau pour le style des boutons de la barre d'outils de dessin"
 
 #: data/ui/glabels-ui.xml.h:112
 msgid "Set main toolbar button style according to desktop default"
-msgstr ""
+msgstr "Utiliser les préférences du bureau pour le style des boutons de la barre d'outils principale"
 
 #: data/ui/glabels-ui.xml.h:113
 msgid "Show _Tooltips"
-msgstr ""
+msgstr "Afficher les infos-bulles"
 
 #: data/ui/glabels-ui.xml.h:114
 msgid "Show both icons and texts in the drawing toolbar"
-msgstr ""
+msgstr "Afficher les icones et le texte dans la barre d'outils de dessin"
 
 #: data/ui/glabels-ui.xml.h:115
 msgid "Show both icons and texts in the main toolbar"
-msgstr ""
+msgstr "Afficher les icones et le texte dans la barre d'outils principale "
 
 #: data/ui/glabels-ui.xml.h:116
 msgid "Show tooltips in the drawing toolbar"
-msgstr ""
+msgstr "Afficher les info-bulles dans la barre d'outils de dessin"
 
 #: data/ui/glabels-ui.xml.h:117
 msgid "Show tooltips in the main toolbar"
-msgstr ""
+msgstr "Afficher les info-bulles dans la barre d'outils principale"
 
 #: data/ui/glabels-ui.xml.h:118
 msgid "Show tooltips in the property toolbar"
-msgstr ""
+msgstr "Afficher les info-bulles dans la barre d'outils de propriétés"
 
 #: data/ui/glabels-ui.xml.h:119
 msgid "Template Designer"
-msgstr ""
+msgstr "Créateur de patrons"
 
 #: data/ui/glabels-ui.xml.h:120
 msgid "Template _Designer..."
-msgstr ""
+msgstr "_Créateur de Patrons..."
 
 #: data/ui/glabels-ui.xml.h:121
 msgid "Text color"
@@ -2110,97 +2039,89 @@ msgstr "Couleur du texte"
 # src/menu.c:85
 # src/menu.c:85
 #: data/ui/glabels-ui.xml.h:122
-#, fuzzy
 msgid "U_n-select All"
-msgstr "_Désélectionne tout"
+msgstr "Tout _Désélectionner"
 
 # src/menu.c:86
 # src/menu.c:86
 # src/menu.c:85
 # src/menu.c:85
 #: data/ui/glabels-ui.xml.h:123
-#, fuzzy
 msgid "Un-select All"
-msgstr "_Désélectionne tout"
+msgstr "Désélectionner tout"
 
 #: data/ui/glabels-ui.xml.h:124
 msgid "Undo"
-msgstr ""
+msgstr "Annuler"
 
 # src/preferences.c:215
 #: data/ui/glabels-ui.xml.h:125
-#, fuzzy
 msgid "Undo the last action"
-msgstr "En construction"
+msgstr "Annuler la dernière action"
 
 # src/tools.c:90
 # src/tools.c:90
 # src/menu.c:127
 # src/menu.c:127
 #: data/ui/glabels-ui.xml.h:126
-#, fuzzy
 msgid "Zoom _1:1"
-msgstr "Zoom 1:1"
+msgstr "Zoom _1:1"
 
 # src/tools.c:84
 # src/tools.c:84
 # src/menu.c:121 src/menu.c:211
 # src/menu.c:121 src/menu.c:211
 #: data/ui/glabels-ui.xml.h:127
-#, fuzzy
 msgid "Zoom _In"
-msgstr "Zoom supérieur"
+msgstr "Zoom su_périeur"
 
 # src/tools.c:87
 # src/tools.c:87
 # src/menu.c:124 src/menu.c:214
 # src/menu.c:124 src/menu.c:214
 #: data/ui/glabels-ui.xml.h:128
-#, fuzzy
 msgid "Zoom _Out"
-msgstr "Zoom inférieur"
+msgstr "Zoom in_férieur"
 
 # src/tools.c:90
 # src/tools.c:90
 # src/menu.c:127 src/menu.c:217
 # src/menu.c:127 src/menu.c:217
 #: data/ui/glabels-ui.xml.h:129
-#, fuzzy
 msgid "Zoom to _fit"
-msgstr "Zoomer Ã  1:1"
+msgstr "_Adapter le zoom Ã  la taille de la fenètre"
 
 #: data/ui/glabels-ui.xml.h:130
 msgid "Zoom to fit window"
-msgstr ""
+msgstr "Adapter le zoom Ã  la taille de la fenètre"
 
 #: data/ui/glabels-ui.xml.h:131
 msgid "_About..."
-msgstr ""
+msgstr "_A propos..."
 
 #: data/ui/glabels-ui.xml.h:132
 msgid "_Bottoms"
-msgstr ""
+msgstr "En _Bas"
 
 #: data/ui/glabels-ui.xml.h:135
 msgid "_Close"
-msgstr ""
+msgstr "_Fermer"
 
 #: data/ui/glabels-ui.xml.h:136
 msgid "_Contents"
-msgstr ""
+msgstr "_Contenu de l'aide"
 
 #: data/ui/glabels-ui.xml.h:137
 msgid "_Copy"
-msgstr ""
+msgstr "_Copier"
 
 # src/tools.c:64
 # src/tools.c:64
 # src/menu.c:100 src/menu.c:191
 # src/menu.c:100 src/menu.c:191
 #: data/ui/glabels-ui.xml.h:138
-#, fuzzy
 msgid "_Create Object"
-msgstr "Créer un objet texte"
+msgstr "_Créer un objet"
 
 #: data/ui/glabels-ui.xml.h:139
 msgid "_Debug"
@@ -2208,49 +2129,47 @@ msgstr ""
 
 #: data/ui/glabels-ui.xml.h:141
 msgid "_Desktop Default"
-msgstr ""
+msgstr "Par _Défaut"
 
 #: data/ui/glabels-ui.xml.h:142
 msgid "_Drawing Toolbar"
-msgstr ""
+msgstr "Barre d'outils de _Dessin"
 
 #: data/ui/glabels-ui.xml.h:143
 msgid "_Edit"
-msgstr ""
+msgstr "_Edition"
 
 # src/item_box.c:274 src/item_ellipse.c:279
 # src/item_box.c:274 src/item_ellipse.c:279
 # src/item_box.c:258 src/item_ellipse.c:260
 # src/item_box.c:258 src/item_ellipse.c:260
 #: data/ui/glabels-ui.xml.h:145
-#, fuzzy
 msgid "_File"
-msgstr "Remplissage"
+msgstr "_Fichier"
 
 #: data/ui/glabels-ui.xml.h:146
 msgid "_Grid"
-msgstr ""
+msgstr "_Grille"
 
 #: data/ui/glabels-ui.xml.h:147
 msgid "_Help"
-msgstr ""
+msgstr "_Aide"
 
 #: data/ui/glabels-ui.xml.h:148
 msgid "_Icon"
-msgstr ""
+msgstr "_Icones"
 
 #: data/ui/glabels-ui.xml.h:152
 msgid "_Main Toolbar"
-msgstr ""
+msgstr "Barre d'outils pr_incipale"
 
 # src/item_text.c:467
 # src/item_text.c:467
 # src/menu.c:132 src/menu.c:223
 # src/menu.c:132 src/menu.c:223
 #: data/ui/glabels-ui.xml.h:153
-#, fuzzy
 msgid "_Merge Properties..."
-msgstr "Propriétés de fusion"
+msgstr "_Propriétés de fusion..."
 
 # src/menu.c:50
 # src/menu.c:50
@@ -2262,68 +2181,64 @@ msgstr "_Nouveau"
 
 #: data/ui/glabels-ui.xml.h:155
 msgid "_Objects"
-msgstr ""
+msgstr "_Objets"
 
 # src/file.c:178
 # src/file.c:178
 # src/file.c:211
 # src/file.c:211
 #: data/ui/glabels-ui.xml.h:156
-#, fuzzy
 msgid "_Open..."
-msgstr "Ouvrir"
+msgstr "_Ouvrir..."
 
 #: data/ui/glabels-ui.xml.h:158
 msgid "_Paste"
-msgstr ""
+msgstr "Co_ller"
 
 # src/print.c:149
 # src/print.c:149
 # src/print.c:141
 # src/print_dialog.c:99
 #: data/ui/glabels-ui.xml.h:159
-#, fuzzy
 msgid "_Print..."
-msgstr "Imprimer"
+msgstr "Im_primer..."
 
 #: data/ui/glabels-ui.xml.h:160
 msgid "_Property Toolbar"
-msgstr ""
+msgstr "Barre d'outils de pr_opriétés"
 
 #: data/ui/glabels-ui.xml.h:161
 msgid "_Quit"
-msgstr ""
+msgstr "_Quitter"
 
 # src/file.c:271 src/mdi.c:660
 # src/file.c:271 src/mdi.c:666
 # src/file.c:311 src/mdi.c:623
 # src/file.c:311 src/mdi.c:623
 #: data/ui/glabels-ui.xml.h:164
-#, fuzzy
 msgid "_Save"
-msgstr "Enregistrer sous"
+msgstr "_Enregistrer"
 
 # src/menu.c:50
 # src/menu.c:50
 # src/menu.c:50
 # src/menu.c:50
 #: data/ui/glabels-ui.xml.h:168
-#, fuzzy
 msgid "_View"
-msgstr "_Nouveau"
+msgstr "_Affichage"
 
 #: data/glade/prefs-dialog.glade.h:1
 msgid "   "
-msgstr ""
+msgstr "   "
 
 #: data/glade/prefs-dialog.glade.h:2 data/glade/object-editor.glade.h:1
 #: data/glade/template-designer.glade.h:5
 msgid "*"
-msgstr ""
+msgstr "*"
 
 #: data/glade/prefs-dialog.glade.h:3
 msgid "<span weight=\"bold\">Default page size</span>"
-msgstr ""
+msgstr "<span weight=\"bold\">Taille de page par défaut</span>"
 
 #: data/glade/prefs-dialog.glade.h:4
 msgid "<span weight=\"bold\">Fill</span>"
@@ -2331,15 +2246,15 @@ msgstr ""
 
 #: data/glade/prefs-dialog.glade.h:5
 msgid "<span weight=\"bold\">Line</span>"
-msgstr ""
+msgstr "<span weight=\"bold\">Ligne</span>"
 
 #: data/glade/prefs-dialog.glade.h:6
 msgid "<span weight=\"bold\">Text</span>"
-msgstr ""
+msgstr "<span weight=\"bold\">Texte</span>"
 
 #: data/glade/prefs-dialog.glade.h:7
 msgid "<span weight=\"bold\">Units</span>"
-msgstr ""
+msgstr "<span weight=\"bold\">Unités</span>"
 
 # src/prop_text.c:277
 # src/prop_text.c:264
@@ -2382,27 +2297,27 @@ msgstr "Pouces"
 
 #: data/glade/prefs-dialog.glade.h:13 data/glade/object-editor.glade.h:19
 msgid "Line Spacing:"
-msgstr ""
+msgstr "Espacement :"
 
 # src/prop_bc.c:189
 # src/prop_bc.c:187
 # src/prop_bc.c:168
 # src/prop_bc.c:168
 #: data/glade/prefs-dialog.glade.h:14
-#, fuzzy
 msgid "Locale"
-msgstr "Echelle :"
+msgstr "Localisation"
 
 # src/prefs.c:271
 # src/prefs.c:250
+
 # src/prefs.c:244
 #: data/glade/prefs-dialog.glade.h:15
 msgid "Millimeters"
-msgstr "Milimètres"
+msgstr "Milimètres"
 
 #: data/glade/prefs-dialog.glade.h:16
 msgid "Object defaults"
-msgstr ""
+msgstr "Paramètres par défaut pour les objets"
 
 # src/print.c:149
 # src/prefs.c:259
@@ -2414,11 +2329,11 @@ msgstr "Points"
 
 #: data/glade/prefs-dialog.glade.h:18
 msgid "Select default properties for new objects."
-msgstr ""
+msgstr "Sélectionner les propriétés pas défaut pour les nouveaux objets."
 
 #: data/glade/prefs-dialog.glade.h:19
 msgid "Select locale specific behavior."
-msgstr ""
+msgstr "Sélectionnez les paramètres de localisation"
 
 #: data/glade/prefs-dialog.glade.h:20 data/templates/paper-sizes.xml.h:25
 msgid "US Letter"
@@ -2439,11 +2354,12 @@ msgstr ""
 
 #: data/glade/object-editor.glade.h:3
 msgid "<span weight=\"bold\" size=\"larger\">Xxx object properties</span>"
-msgstr ""
+msgstr "<span weight=\"bold\" size=\"larger\">Xxx Propriétés de l'objet</span>"
 
 #: data/glade/object-editor.glade.h:5
 msgid "Allow merge to automatically shrink text"
-msgstr ""
+msgstr "Permettre Ã  la fusion de diminuer\n"
+"automatiquement la taille du texte"
 
 # src/prop_vector.c:207
 # src/prop_vector.c:228
@@ -2455,16 +2371,15 @@ msgstr "Angle :"
 
 #: data/glade/object-editor.glade.h:7
 msgid "Checksum"
-msgstr ""
+msgstr "Somme de contrôle"
 
 # src/item_box.c:274 src/item_ellipse.c:279
 # src/item_box.c:274 src/item_ellipse.c:279
 # src/item_box.c:258 src/item_ellipse.c:260
 # src/item_box.c:258 src/item_ellipse.c:260
 #: data/glade/object-editor.glade.h:10
-#, fuzzy
 msgid "Family:"
-msgstr "Remplissage"
+msgstr "Famille :"
 
 # src/item_box.c:274 src/item_ellipse.c:279
 # src/item_box.c:274 src/item_ellipse.c:279
@@ -2493,7 +2408,7 @@ msgstr "Image"
 # src/prop_text_entry.c:196
 #: data/glade/object-editor.glade.h:15
 msgid "Insert merge field"
-msgstr "Insérer champ de fusion"
+msgstr "Insérer un champ\nde fusion"
 
 # src/prop_vector.c:196
 # src/prop_vector.c:202
@@ -2515,11 +2430,11 @@ msgstr "Ligne"
 # src/prop_bc_data.c:176
 #: data/glade/object-editor.glade.h:20
 msgid "Literal:"
-msgstr "Littéral :"
+msgstr "Littéral :"
 
 #: data/glade/object-editor.glade.h:21
 msgid "Load image"
-msgstr ""
+msgstr "Charger l'image"
 
 # src/item_barcode.c:362 src/item_barcode.c:365 src/item_box.c:291
 # src/item_ellipse.c:296 src/item_image.c:315 src/item_line.c:289
@@ -2566,16 +2481,14 @@ msgstr "Taille"
 # src/item_box.c:286 src/item_ellipse.c:288 src/item_image.c:329
 # src/item_line.c:285
 #: data/glade/object-editor.glade.h:25
-#, fuzzy
 msgid "Size:"
-msgstr "Taille"
+msgstr "Taille :"
 
 # src/item_barcode.c:347
 # src/item_barcode.c:353
 # src/item_barcode.c:330
 # src/item_barcode.c:330
 #: data/glade/object-editor.glade.h:26
-#, fuzzy
 msgid "Style"
 msgstr "Style"
 
@@ -2584,9 +2497,8 @@ msgstr "Style"
 # src/item_barcode.c:330
 # src/item_barcode.c:330
 #: data/glade/object-editor.glade.h:27
-#, fuzzy
 msgid "Style:"
-msgstr "Style"
+msgstr "Style :"
 
 # src/prop_position.c:192
 # src/prop_position.c:173
@@ -2607,7 +2519,7 @@ msgstr "Y :"
 # src/prop_vector.c:224
 #: data/glade/object-editor.glade.h:32
 msgid "degrees"
-msgstr "degrés"
+msgstr "degrés"
 
 #: data/glade/object-editor.glade.h:33
 msgid "dialog1"
@@ -2622,98 +2534,95 @@ msgstr ""
 # src/merge_properties.c:143
 # src/merge_properties.c:143
 #: data/glade/object-editor.glade.h:35
-#, fuzzy
 msgid "format:"
-msgstr "Format :"
+msgstr "format :"
 
 #: data/glade/template-designer.glade.h:1
 msgid "  "
-msgstr ""
+msgstr "  "
 
 #: data/glade/template-designer.glade.h:2
 msgid "(e.g., \"Mailing Labels,\" \"Business Cards,\" ...)"
-msgstr ""
+msgstr "(ex : \"Etiquettes de Publipostage\", \"Cartes de Visites\", ...)"
 
 #: data/glade/template-designer.glade.h:3
 msgid "(e.g., 8163A)"
-msgstr ""
+msgstr "(ex : 8163A)"
 
 #: data/glade/template-designer.glade.h:4
 msgid "(e.g., Avery, Acme, ...)"
-msgstr ""
+msgstr "(ex : Avery, Acme, ...)"
 
 #: data/glade/template-designer.glade.h:6
 msgid "1. Outer radius:"
-msgstr ""
+msgstr "1. Rayon Extérieur :"
 
 #: data/glade/template-designer.glade.h:7
 msgid "1. Radius:"
-msgstr ""
+msgstr "1. Rayon :"
 
 # src/prop_line.c:188
 # src/prop_line.c:187 src/prop_size.c:202
 # src/prop_line.c:169 src/prop_size.c:182
 # src/prop_line.c:169 src/prop_size.c:182
 #: data/glade/template-designer.glade.h:8
-#, fuzzy
 msgid "1. Width:"
-msgstr "Largeur :"
+msgstr "1. Largeur :"
 
 # src/prop_size.c:220
 # src/prop_size.c:198
 # src/prop_size.c:198
 #: data/glade/template-designer.glade.h:9
-#, fuzzy
 msgid "2. Height:"
-msgstr "Hauteur :"
+msgstr "2. Hauteur :"
 
 #: data/glade/template-designer.glade.h:10
 msgid "2. Inner radius:"
-msgstr ""
+msgstr "2. Rayon Intérieur"
 
 #: data/glade/template-designer.glade.h:11
 msgid "2. Waste (overprint allowed):"
-msgstr ""
+msgstr "2. Déchet (impression en surcharge autorisée)"
 
 #: data/glade/template-designer.glade.h:12
 msgid "3. Clipping width:"
-msgstr ""
+msgstr "3. Largeur de Rognure :"
 
 #: data/glade/template-designer.glade.h:13
 msgid "3. Margin"
-msgstr ""
+msgstr "3. Marge"
 
 #: data/glade/template-designer.glade.h:14
 msgid "3. Round (radius of corner):"
-msgstr ""
+msgstr "3. Arrondi (rayon du coin) :"
 
 #: data/glade/template-designer.glade.h:15
 msgid "4. Clipping height:"
-msgstr ""
+msgstr "4. Hauteur de Rognure :"
 
 #: data/glade/template-designer.glade.h:16
 msgid "4. Horiz. waste (overprint allowed):"
-msgstr ""
+msgstr "4. Déchet horiz. (impression en surcharge autorisée)"
 
 #: data/glade/template-designer.glade.h:17
 msgid "5. Vert. waste (overprint allowed):"
-msgstr ""
+msgstr "5. Déchet Vert. (impression en surcharge autorisée)"
 
 #: data/glade/template-designer.glade.h:18
 msgid "5. Waste (overprint allowed):"
-msgstr ""
+msgstr "5. Déchet (impression en surcharge autorisée)"
 
 #: data/glade/template-designer.glade.h:19
 msgid "6. Margin"
-msgstr ""
+msgstr "6. Marge"
 
 #: data/glade/template-designer.glade.h:20
 msgid "Brand/Manufacturer:"
-msgstr ""
+msgstr "Marque/Fabricant"
 
 #: data/glade/template-designer.glade.h:21
 msgid "CD/DVD (including credit card CDs)"
-msgstr ""
+msgstr "CD/DVD (y compris CD au format carte de crédit)"
 
 #: data/glade/template-designer.glade.h:22
 msgid ""
@@ -2725,22 +2634,29 @@ msgid ""
 "Otherwise, you may click \"Cancel\" to abandon your design\n"
 "or \"Back\" to continue editing this design."
 msgstr ""
+"Félicitations !"
+"\n"
+"Vous avez terminé la création d'un patron gLabels.\n"
+"Si vous voulez accepter et sauver votre création, cliquez sur \"Appliquer\".\n"
+"\n"
+"Dans le cas contraire, vous pouvez cliquer sur \"Annuler\" pour abandonner votre création.\n"
+"ou \"Précédent\" pour continuer d'éditer cette création."
 
 #: data/glade/template-designer.glade.h:30
 msgid "Design Completed"
-msgstr ""
+msgstr "Création terminée"
 
 #: data/glade/template-designer.glade.h:31
 msgid "Distance from left edge (x0):"
-msgstr ""
+msgstr "Distance par rapport au bord gauche (x0) :"
 
 #: data/glade/template-designer.glade.h:32
 msgid "Distance from top edge (y0):"
-msgstr ""
+msgstr "Distance pas rapport au bord haut (y0) :"
 
 #: data/glade/template-designer.glade.h:34
 msgid "Horizontal pitch (dx):"
-msgstr ""
+msgstr "Espacement Horizontal (dx) :"
 
 #: data/glade/template-designer.glade.h:35
 msgid ""
@@ -2750,158 +2666,162 @@ msgid ""
 "Most templates only need one layout, as in the first example.\n"
 "The second example illustrates when two layouts are needed."
 msgstr ""
+"Combien de dispositions votre patron contiendra-t-il ? \n"
+"\n"
+"Une disposition est un ensemble d'étiquettes ou de cartes qui peuvent Ãªtre rangés sur une simple grille.\n"
+"La plupart des patrons n'ont besoin que d'une disposition, comme pour le premier exemple.\n"
+"Le deuxième exemple illustre le cas où deux dispositions sont nécessaires."
 
 #: data/glade/template-designer.glade.h:40
 msgid "Label Size (CD/DVD)"
-msgstr ""
+msgstr "Taille des Ã©tiquettes (CD/DVD)"
 
 # src/media_select.c:226
 # src/media_select.c:252
 # src/media_select.c:232
 # src/media_select.c:232
 #: data/glade/template-designer.glade.h:41
-#, fuzzy
 msgid "Label Size (Round)"
-msgstr "Taille d'étiquette :"
+msgstr "Taille des Ã©tiquettes (rondes) :"
 
 # src/file.c:59
 # src/file.c:59
 # src/file.c:72
 # src/file.c:72
 #: data/glade/template-designer.glade.h:42
-#, fuzzy
 msgid "Label or Card Shape"
-msgstr "Nouvelle Ã©tiquette ou carte"
+msgstr "Forme des cartes ou des Ã©tiquettes"
 
 #: data/glade/template-designer.glade.h:43
 msgid "Label or Card Size (Rectangular)"
-msgstr ""
+msgstr "Taille des Etiquettes ou Cartes (Rectangulaires)"
 
 # src/media_select.c:231
 # src/media_select.c:257
 # src/media_select.c:237
 # src/media_select.c:237
 #: data/glade/template-designer.glade.h:44
-#, fuzzy
 msgid "Layout #1"
-msgstr "Disposition :"
+msgstr "Disposition n°1 :"
 
 # src/media_select.c:231
 # src/media_select.c:257
 # src/media_select.c:237
 # src/media_select.c:237
 #: data/glade/template-designer.glade.h:45
-#, fuzzy
 msgid "Layout #2"
-msgstr "Disposition :"
+msgstr "Disposition n°2 :"
 
 # src/media_select.c:231
 # src/media_select.c:257
 # src/media_select.c:237
 # src/media_select.c:237
 #: data/glade/template-designer.glade.h:46
-#, fuzzy
 msgid "Layout(s)"
-msgstr "Disposition :"
+msgstr "Disposition(s) :"
 
 # src/media_select.c:216
 # src/media_select.c:242
 # src/media_select.c:222
 # src/media_select.c:222
 #: data/glade/template-designer.glade.h:47
-#, fuzzy
 msgid "Name and Description"
-msgstr "Description :"
+msgstr "Nom et Description"
 
 #: data/glade/template-designer.glade.h:48
 msgid "Number across (nx):"
-msgstr ""
+msgstr "Nombre horizontalement (nx)"
 
 #: data/glade/template-designer.glade.h:49
 msgid "Number down (ny):"
-msgstr ""
+msgstr "Nombre verticalement (ny)"
 
 #: data/glade/template-designer.glade.h:50
 msgid "Number of Layouts"
-msgstr ""
+msgstr "Nombre de Dispositions"
 
 #: data/glade/template-designer.glade.h:51
 msgid "Number of layouts:"
-msgstr ""
+msgstr "Nombre de dispositions :"
 
 # src/media_select.c:221
 # src/media_select.c:247
 # src/media_select.c:227
 # src/media_select.c:227
 #: data/glade/template-designer.glade.h:52
-#, fuzzy
 msgid "Page Size"
-msgstr "Taille de page :"
+msgstr "Taille de page"
 
 #: data/glade/template-designer.glade.h:54
 msgid "Part #:"
-msgstr ""
+msgstr "Ref :"
 
 #: data/glade/template-designer.glade.h:55
 msgid ""
 "Please enter the following identifying information about the template "
 "stationery."
-msgstr ""
+msgstr "Entrez les informations suivantes Ã  propos du fabricant de papier."
 
 #: data/glade/template-designer.glade.h:56
 msgid "Please enter the following layout information."
-msgstr ""
+msgstr "Entrez les informations suivantes sur la disposition"
 
 #: data/glade/template-designer.glade.h:57
 msgid ""
 "Please enter the following size parameters of a single label in your "
 "template."
 msgstr ""
+"Entrez les paramètres de taille suivants pour une Ã©tiquette."
 
 #: data/glade/template-designer.glade.h:58
 msgid ""
 "Please enter the following size parameters of a single label or card in your "
 "template."
 msgstr ""
+"Entrez les paramètres de taille suivant pour une carte ou une Ã©tiquette."
 
 #: data/glade/template-designer.glade.h:59
 msgid "Please select the basic shape of the labels or cards."
-msgstr ""
+msgstr "Sélectionnez la forme de base des cartes ou des Ã©tiquettes"
 
 #: data/glade/template-designer.glade.h:60
 msgid "Please select the page size of the template stationery."
-msgstr ""
+msgstr "Sélectionnez la taille du papier."
 
 # src/print_copies_merge.c:206
 # src/print_merge.c:179
 #: data/glade/template-designer.glade.h:61
-#, fuzzy
 msgid "Print test sheet"
-msgstr "en 1ère page"
+msgstr "Imprimer une page de tests"
 
 #: data/glade/template-designer.glade.h:62
 msgid "Rectangular or square (can have rounded corners)"
-msgstr ""
+msgstr "Rectangulaire ou carré (éventuellement Ã  bords arrondis)"
 
 #: data/glade/template-designer.glade.h:63
 msgid "Round"
-msgstr ""
+msgstr "Rond"
 
 #: data/glade/template-designer.glade.h:64
 msgid ""
 "Templates needing\n"
 "two layouts."
 msgstr ""
+"Patron nécessitant\n"
+"deux dispositions."
 
 #: data/glade/template-designer.glade.h:66
 msgid ""
 "Templates needing only\n"
 "one layout."
+
 msgstr ""
+"Patron nécessitant\n"
+"une disposition"
 
 #: data/glade/template-designer.glade.h:68
 msgid "Vertical pitch (dy):"
-msgstr ""
+msgstr "Espacement vertical (dy) :"
 
 #: data/glade/template-designer.glade.h:69
 msgid ""
@@ -2909,7 +2829,9 @@ msgid ""
 "\n"
 "This dialog will assist you in the creation of a custom gLabels template."
 msgstr ""
-
+"Bienvenue dans le Créateur de Patrons de gLabels."
+"\n"
+"Ce questionnaire va vous aider Ã  créer un patron personnalisé pour glabels."
 #: data/templates/paper-sizes.xml.h:1
 msgid "A0"
 msgstr ""
@@ -3032,9 +2954,8 @@ msgstr ""
 # src/print_copies.c:188
 # src/print_copies.c:187
 #: data/templates/avery-us-templates.xml.h:5
-#, fuzzy
 msgid "Filing Labels"
-msgstr "Etiquettes"
+msgstr ""
 
 #: data/templates/avery-us-templates.xml.h:6
 msgid "Full Sheet Labels"
@@ -3043,9 +2964,8 @@ msgstr ""
 # src/print_copies_merge.c:197
 # src/print_merge.c:170
 #: data/templates/avery-us-templates.xml.h:7
-#, fuzzy
 msgid "Large Round Labels"
-msgstr "Commencer par l'étiquette"
+msgstr ""
 
 #: data/templates/avery-us-templates.xml.h:8
 msgid "Name Badge Labels"
@@ -3062,18 +2982,16 @@ msgstr ""
 # src/print_copies_merge.c:197
 # src/print_merge.c:170
 #: data/templates/avery-us-templates.xml.h:11
-#, fuzzy
 msgid "Small Round Labels"
-msgstr "Commencer par l'étiquette"
+msgstr ""
 
 # src/print_copies.c:210
 # src/print_copies.c:210
 # src/print_copies.c:188
 # src/print_copies.c:187
 #: data/templates/avery-us-templates.xml.h:12
-#, fuzzy
 msgid "Square Labels"
-msgstr "Etiquettes"
+msgstr ""
 
 #: data/templates/avery-us-templates.xml.h:13
 msgid "Video Tape Face Labels"
@@ -3103,9 +3021,8 @@ msgstr ""
 #: data/templates/zweckform-iso-templates.xml.h:4
 #: data/templates/misc-us-templates.xml.h:4
 #: data/templates/misc-iso-templates.xml.h:10
-#, fuzzy
 msgid "CD/DVD Labels"
-msgstr "Etiquettes"
+msgstr ""
 
 #: data/templates/avery-iso-templates.xml.h:6
 msgid "Diskette labels"
@@ -3122,9 +3039,8 @@ msgstr ""
 # src/print_copies.c:188
 # src/print_copies.c:187
 #: data/templates/avery-iso-templates.xml.h:8
-#, fuzzy
 msgid "Mailing labels"
-msgstr "Etiquettes"
+msgstr ""
 
 #: data/templates/avery-iso-templates.xml.h:9
 msgid "Mini Address Labels"
@@ -3135,9 +3051,8 @@ msgstr ""
 # src/file.c:213
 # src/file.c:213
 #: data/templates/avery-iso-templates.xml.h:10
-#, fuzzy
 msgid "Shipping labels"
-msgstr "Ouvrir une Ã©tiquette"
+msgstr ""
 
 #: data/templates/zweckform-iso-templates.xml.h:2
 msgid "Allround Labels"
@@ -3190,9 +3105,8 @@ msgstr ""
 # src/print_copies.c:188
 # src/print_copies.c:187
 #: data/templates/misc-us-templates.xml.h:7
-#, fuzzy
 msgid "DLT Labels"
-msgstr "Etiquettes"
+msgstr ""
 
 #: data/templates/misc-us-templates.xml.h:8
 msgid "Microtube labels"
@@ -3304,9 +3218,8 @@ msgstr ""
 # src/item_text.c:482
 # src/item_text.c:482
 #: data/mime/glabels.keys.in.h:1 data/mime/glabels.xml.in.h:1
-#, fuzzy
 msgid "gLabels Project File"
-msgstr "Propriétés du texte"
+msgstr "Fichier de projet glabels"
 
 # src/item_text.c:467
 # src/item_text.c:467
@@ -3314,20 +3227,20 @@ msgstr "Propri
 # src/item_text.c:482
 #, fuzzy
 #~ msgid "Object _Properties..."
-#~ msgstr "Propriétés du texte"
+#~ msgstr "Propriétés du texte"
 
 # src/prefs.c:248
 # src/prefs.c:226
 # src/prefs.c:220
 #~ msgid "Display units"
-#~ msgstr "Unités d'affichage"
+#~ msgstr "Unités d'affichage"
 
 # src/item_image.c:341
 # src/prefs.c:278
 # src/prefs.c:255
 # src/prefs.c:249
 #~ msgid "Default page size"
-#~ msgstr "Taille de page par défaut"
+#~ msgstr "Taille de page par défaut"
 
 # src/item_box.c:264 src/item_ellipse.c:269
 # src/item_box.c:264 src/item_ellipse.c:269
@@ -3341,21 +3254,21 @@ msgstr "Propri
 # src/item_line.c:243
 # src/item_line.c:243
 #~ msgid "Edit line object properties"
-#~ msgstr "Editer les propriétés de l'objet ligne..."
+#~ msgstr "Editer les propriétés de l'objet ligne..."
 
 # src/item_text.c:432
 # src/item_text.c:432
 # src/item_text.c:450
 # src/item_text.c:450
 #~ msgid "Edit text object properties"
-#~ msgstr "Editer les propriétés de l'objet texte..."
+#~ msgstr "Editer les propriétés de l'objet texte..."
 
 # src/prop_size.c:215
 # src/prop_size.c:247
 # src/prop_size.c:222
 # src/prop_size.c:222
 #~ msgid "Maintain current aspect ratio"
-#~ msgstr "Conserver le rapport d'échelle actuel"
+#~ msgstr "Conserver le rapport d'échelle actuel"
 
 # src/print_copies.c:210
 # src/print_copies.c:210
@@ -3378,13 +3291,13 @@ msgstr "Propri
 # src/mdi.c:169
 # src/mdi.c:169
 #~ msgid "Revert to saved copy of %s?"
-#~ msgstr "Rétablir la version sauvegardée de %s ?"
+#~ msgstr "Rétablir la version sauvegardée de %s ?"
 
 # src/mdi.c:219
 # src/mdi.c:207
 # src/mdi.c:207
 #~ msgid "Unknown media type. Using default."
-#~ msgstr "Type de media inconnu. Utilisation de celui par défaut."
+#~ msgstr "Type de media inconnu. Utilisation de celui par défaut."
 
 # src/mdi.c:477
 # src/mdi.c:483
@@ -3395,7 +3308,7 @@ msgstr "Propri
 #~ "\n"
 #~ "Do you wish to save it?"
 #~ msgstr ""
-#~ "``%s'' a Ã©té modifié \n"
+#~ "``%s'' a Ã©té modifié \n"
 #~ "\n"
 #~ "Voulez-vous l'enregistrer ?"
 
@@ -3404,7 +3317,7 @@ msgstr "Propri
 # src/mdi.c:626
 # src/mdi.c:626
 #~ msgid "Close / Save label as"
-#~ msgstr "Fermer / Enregistrer l'étiquette sous"
+#~ msgstr "Fermer / Enregistrer l'étiquette sous"
 
 # src/file.c:309 src/mdi.c:716
 # src/file.c:309 src/mdi.c:722
@@ -3418,14 +3331,14 @@ msgstr "Propri
 # src/file.c:374 src/mdi.c:705
 # src/file.c:374 src/mdi.c:705
 #~ msgid "Error writing file"
-#~ msgstr "Erreur d'écriture du fichier"
+#~ msgstr "Erreur d'écriture du fichier"
 
 # src/display.c:1194
 # src/display.c:1197
 # src/display.c:1208
 # src/display.c:1223
 #~ msgid "Edit properties..."
-#~ msgstr "Editer les propriétés..."
+#~ msgstr "Editer les propriétés..."
 
 # src/item_barcode.c:334 src/item_box.c:261 src/item_ellipse.c:266
 # src/item_line.c:268 src/item_text.c:464
@@ -3454,14 +3367,14 @@ msgstr "Propri
 # src/item_image.c:389 src/item_image.c:454
 # src/item_image.c:389 src/item_image.c:454
 #~ msgid "Image format not currently supported"
-#~ msgstr "Format d'image non supporté actuellement"
+#~ msgstr "Format d'image non supporté actuellement"
 
 # src/item_barcode.c:316
 # src/item_barcode.c:317
 # src/item_barcode.c:299
 # src/item_barcode.c:299
 #~ msgid "Barcode data"
-#~ msgstr "Données de code-barre"
+#~ msgstr "Données de code-barre"
 
 # src/prop_bc.c:202
 # src/prop_bc.c:182
@@ -3491,14 +3404,14 @@ msgstr "Propri
 # src/merge_ui_text.c:338
 # src/merge_ui_text.c:338
 #~ msgid "Sample data"
-#~ msgstr "Exemple de données"
+#~ msgstr "Exemple de données"
 
 # src/menu.c:51
 # src/menu.c:51
 # src/menu.c:51
 # src/menu.c:51
 #~ msgid "Make a new, empty label"
-#~ msgstr "Créer une nouvelle Ã©tiquette vide"
+#~ msgstr "Créer une nouvelle Ã©tiquette vide"
 
 # src/menu.c:138
 # src/menu.c:138
@@ -3512,7 +3425,7 @@ msgstr "Propri
 # src/menu.c:168
 # src/menu.c:168
 #~ msgid "New Label/Card"
-#~ msgstr "Nouvelle Ã©tiquette/carte"
+#~ msgstr "Nouvelle Ã©tiquette/carte"
 
 # src/menu.c:140
 # src/menu.c:140
@@ -3540,12 +3453,12 @@ msgstr "Propri
 # src/menu.c:326
 # src/menu.c:326
 #~ msgid "Function is not implemented!"
-#~ msgstr "Cette fonction n'est pas implémentée !"
+#~ msgstr "Cette fonction n'est pas implémentée !"
 
 # src/tools.c:297
 # src/tools.c:297
 #~ msgid "Function is not yet implemented!"
-#~ msgstr "Cette fonction n'est pas encore implémentée !"
+#~ msgstr "Cette fonction n'est pas encore implémentée !"
 
 # src/prop_size.c:194
 #~ msgid "w"
@@ -3569,4 +3482,4 @@ msgstr "Propri
 
 #, fuzzy
 #~ msgid "Maintain original aspect ratio"
-#~ msgstr "Conserver le rapport d'échelle d'origine"
+#~ msgstr "Conserver le rapport d'échelle d'origine"
index 111774533c982c286de867d37d0ff438f194ac43..63c12e781e961094b6adf707b140f65dbb536cff 100644 (file)
@@ -227,6 +227,8 @@ glabels_batch_SOURCES =             \
        prefs-model.h                   \
        util.c                          \
        util.h                          \
+       color.c                         \
+       color.h                         \
        debug.c                         \
        debug.h                         \
        $(BUILT_SOURCES)
index c51cf8f762bcc93712727d4ea0b07513b88ba08e..7004fef289b96d76580ddbb522229872052b474d 100644 (file)
@@ -69,3 +69,136 @@ gl_color_from_gdk_color (GdkColor *gdk_color)
        return color;
 }
 
+/****************************************************************************/
+/* Create a single color node with default color.                           */
+/****************************************************************************/
+glColorNode *
+gl_color_node_new_default ()
+{
+       glColorNode* color_node;
+       
+       color_node = g_new0(glColorNode,1);
+       
+       color_node->field_flag = FALSE;
+       color_node->color = GL_COLOR_NONE;
+       color_node->key = NULL;
+
+       return color_node;
+}
+
+/****************************************************************************/
+/* Copy a single color node.                                                 */
+/****************************************************************************/
+glColorNode *
+gl_color_node_dup (glColorNode *src)
+{
+       glColorNode *dst;
+
+       if ( src == NULL ) return NULL;
+
+       dst = g_new0 (glColorNode, 1);
+
+       dst->field_flag = src->field_flag;
+       if (src->key != NULL)
+       {
+               dst->key = g_strdup (src->key);
+       }
+       else
+       {
+               dst->key = NULL;
+       }
+       dst->color = src->color;
+
+       return dst;
+}
+
+/****************************************************************************/
+/* Compare 2 color nodes for equality.                                       */
+/****************************************************************************/
+gboolean
+gl_color_node_equal (glColorNode     *color_node1,
+                   glColorNode     *color_node2)
+{
+       /* First take care of the case of either or both being NULL. */
+       if ( color_node1 == NULL ) {
+               return ( color_node2 == NULL );
+       } else {
+               if ( color_node2 == NULL ) {
+                       return FALSE;
+               }
+       }
+
+       /* Bail if field flags differ. */
+       if ( color_node1->field_flag != color_node2->field_flag ) {
+               return FALSE;
+       }
+
+       /* Now take care of the case of either or both color fields being different. */
+       if ( color_node1->color != color_node2->color ){
+               return FALSE;
+       }
+       
+       /* Then take care of the case of either or both key fields being NULL. */
+       if ( color_node1->key == NULL ) {
+               return ( color_node2->key == NULL );
+       } else {
+               if ( color_node2->key == NULL ) {
+                       return FALSE;
+               }
+       }
+
+       /* Field flags are identical, so now compare the keys. */
+       return (strcmp (color_node1->key, color_node2->key) == 0);
+}
+
+/****************************************************************************/
+/* Expand single node into representative color.                            */
+/****************************************************************************/
+guint
+gl_color_node_expand (glColorNode    *color_node,
+                    glMergeRecord *record)
+{
+       gchar* text;
+       GdkColor *gdk_color;
+       guint color;
+
+       if (color_node->field_flag) {
+               if (record == NULL) {
+                       return GL_COLOR_NONE;
+               } else {
+                       text = gl_merge_eval_key (record, color_node->key);
+                       if (text != NULL) {
+                               gdk_color = g_new0 (GdkColor, 1);
+                               if (gdk_color_parse (text, gdk_color))
+                               {
+                                       color = gl_color_from_gdk_color (gdk_color);
+                                       g_free (gdk_color);
+                                       return color;
+                               }
+                               else
+                               {
+                                       g_free (gdk_color);
+                                       return GL_COLOR_NONE;
+                               }
+                       } else {
+                               return GL_COLOR_NONE;
+                       }
+               }
+       } else {
+               return color_node->color;
+       }
+}
+
+/****************************************************************************/
+/* Free a single color node.                                                */
+/****************************************************************************/
+void
+gl_color_node_free (glColorNode **color_node)
+{
+       if ( *color_node == NULL ) return;
+
+       g_free ((*color_node)->key);
+       (*color_node)->key = NULL;
+       g_free (*color_node);
+       *color_node = NULL;
+}
index a9d54b4d83d443d47c1a7891d72eeb5548771cfb..65f8b0272d5a195a65ecc69553731c6eea714f6d 100644 (file)
 #define __COLOR_H__
 
 #include <libgnomecanvas/gnome-canvas.h>
+#include "merge.h"
 
 G_BEGIN_DECLS
 
+typedef struct {
+       gboolean field_flag;
+       guint color;
+       gchar *key;
+} glColorNode;
+
 #define GL_COLOR(r,g,b)     GNOME_CANVAS_COLOR(r,g,b)
 #define GL_COLOR_A(r,g,b,a) GNOME_CANVAS_COLOR_A(r,g,b,a)
 
 #define GL_COLOR_NONE GL_COLOR_A(0,0,0,0)
+#define GL_COLOR_FILL_MERGE_DEFAULT GL_COLOR_A(255,255,255,128)
+#define GL_COLOR_MERGE_DEFAULT      GL_COLOR_A(0,0,0,128)
 
 #define GL_COLOR_I_RED(x)   (((x)>>24) & 0xff)
 #define GL_COLOR_I_GREEN(x) (((x)>>16) & 0xff)
@@ -47,6 +56,16 @@ guint     gl_color_set_opacity (guint color, gdouble opacity);
 GdkColor *gl_color_to_gdk_color   (guint     color);
 guint     gl_color_from_gdk_color (GdkColor *gdk_color);
 
+glColorNode *gl_color_node_new_default    ();
+
+glColorNode *gl_color_node_dup            (glColorNode     *color_node);
+gboolean     gl_color_node_equal          (glColorNode     *color_node1,
+                                          glColorNode     *color_node2);
+guint        gl_color_node_expand         (glColorNode     *color_node,
+                                          glMergeRecord   *record);
+void         gl_color_node_free           (glColorNode    **color_node);
+
+
 G_END_DECLS
 
 #endif /* __COLOR_H__ */
index 581c069dde3c89b57266e227114337a214743e37..99f984217164cfa3a8b8b7a135bae723e00e330a 100644 (file)
  * Copyright (C) 2000, 2001 Chema Celorio, Paolo Maggi 
  *
  */
-#include <glib.h>
 
 #include "debug.h"
 
-/* External debug options, used here and in glabels.c */
-gint gl_debug_all = 0;
-gint gl_debug_view = 0;
-gint gl_debug_item = 0;
-gint gl_debug_prefs = 0;
-gint gl_debug_print = 0;
-gint gl_debug_file = 0;
-gint gl_debug_label = 0;
-gint gl_debug_template = 0;
-gint gl_debug_paper = 0;
-gint gl_debug_xml = 0;
-gint gl_debug_merge = 0;
-gint gl_debug_commands = 0;
-gint gl_debug_undo = 0;
-gint gl_debug_recent = 0;
-gint gl_debug_window = 0;
-gint gl_debug_ui = 0;
-gint gl_debug_property_bar = 0;
-gint gl_debug_media_select = 0;
-gint gl_debug_mini_preview = 0;
-gint gl_debug_pixbuf_cache = 0;
-gint gl_debug_editor = 0;
-gint gl_debug_wdgt = 0;
+glDebugSection debug_flags = GLABELS_DEBUG_NONE;
+
+/****************************************************************************/
+/* Initialize debug flags, based on environmental variables.                */
+/****************************************************************************/
+void
+gl_debug_init (void)
+{
+       if (g_getenv ("GLABELS_DEBUG") != NULL)
+       {
+               /* enable all debugging */
+               debug_flags = ~GLABELS_DEBUG_NONE;
+               return;
+       }
+
+       if (g_getenv ("GLABELS_DEBUG_VIEW") != NULL)
+               debug_flags |= GLABELS_DEBUG_VIEW;
+       if (g_getenv ("GLABELS_DEBUG_ITEM") != NULL)
+               debug_flags |= GLABELS_DEBUG_ITEM;
+       if (g_getenv ("GLABELS_DEBUG_PRINT") != NULL)
+               debug_flags |= GLABELS_DEBUG_PRINT;
+       if (g_getenv ("GLABELS_DEBUG_PREFS") != NULL)
+               debug_flags |= GLABELS_DEBUG_PREFS;
+       if (g_getenv ("GLABELS_DEBUG_FILE") != NULL)
+               debug_flags |= GLABELS_DEBUG_FILE;
+       if (g_getenv ("GLABELS_DEBUG_LABEL") != NULL)
+               debug_flags |= GLABELS_DEBUG_LABEL;
+       if (g_getenv ("GLABELS_DEBUG_TEMPLATE") != NULL)
+               debug_flags |= GLABELS_DEBUG_TEMPLATE;
+       if (g_getenv ("GLABELS_DEBUG_PAPER") != NULL)
+               debug_flags |= GLABELS_DEBUG_PAPER;
+       if (g_getenv ("GLABELS_DEBUG_XML") != NULL)
+               debug_flags |= GLABELS_DEBUG_XML;
+       if (g_getenv ("GLABELS_DEBUG_MERGE") != NULL)
+               debug_flags |= GLABELS_DEBUG_MERGE;
+       if (g_getenv ("GLABELS_DEBUG_UNDO") != NULL)
+               debug_flags |= GLABELS_DEBUG_UNDO;
+       if (g_getenv ("GLABELS_DEBUG_RECENT") != NULL)
+               debug_flags |= GLABELS_DEBUG_RECENT;
+       if (g_getenv ("GLABELS_DEBUG_COMMANDS") != NULL)
+               debug_flags |= GLABELS_DEBUG_COMMANDS;
+       if (g_getenv ("GLABELS_DEBUG_WINDOW") != NULL)
+               debug_flags |= GLABELS_DEBUG_WINDOW;
+       if (g_getenv ("GLABELS_DEBUG_UI") != NULL)
+               debug_flags |= GLABELS_DEBUG_UI;
+       if (g_getenv ("GLABELS_DEBUG_PROPERTY_BAR") != NULL)
+               debug_flags |= GLABELS_DEBUG_PROPERTY_BAR;
+       if (g_getenv ("GLABELS_DEBUG_MEDIA_SELECT") != NULL)
+               debug_flags |= GLABELS_DEBUG_MEDIA_SELECT;
+       if (g_getenv ("GLABELS_DEBUG_MINI_PREVIEW") != NULL)
+               debug_flags |= GLABELS_DEBUG_MINI_PREVIEW;
+       if (g_getenv ("GLABELS_DEBUG_PIXBUF_CACHE") != NULL)
+               debug_flags |= GLABELS_DEBUG_PIXBUF_CACHE;
+       if (g_getenv ("GLABELS_DEBUG_EDITOR") != NULL)
+               debug_flags |= GLABELS_DEBUG_EDITOR;
+       if (g_getenv ("GLABELS_DEBUG_WDGT") != NULL)
+               debug_flags |= GLABELS_DEBUG_WDGT;
+}
+
 
 /****************************************************************************/
 /* Print debugging information.                                             */
 /****************************************************************************/
 void
-gl_debug (gint   section,
-         gchar *file,
-         gint   line,
-         gchar *function,
-         gchar *format,
+gl_debug (glDebugSection  section,
+         const gchar    *file,
+         gint            line,
+         const gchar    *function,
+         const gchar    *format,
          ...)
 {
-       va_list  args;
-       gchar   *msg;
+       if  (debug_flags & section)
+       {
+               va_list  args;
+               gchar   *msg;
 
-       g_return_if_fail (format != NULL);
+               g_return_if_fail (format != NULL);
 
-       va_start (args, format);
-       msg = g_strdup_vprintf (format, args);
-       va_end (args);
+               va_start (args, format);
+               msg = g_strdup_vprintf (format, args);
+               va_end (args);
 
-       if (gl_debug_all ||
-           (gl_debug_view         && section == GL_DEBUG_VIEW)           ||
-           (gl_debug_item         && section == GL_DEBUG_ITEM)           ||
-           (gl_debug_print        && section == GL_DEBUG_PRINT)          ||
-           (gl_debug_prefs        && section == GL_DEBUG_PREFS)          ||
-           (gl_debug_file         && section == GL_DEBUG_FILE)           ||
-           (gl_debug_label        && section == GL_DEBUG_LABEL)          ||
-           (gl_debug_template     && section == GL_DEBUG_TEMPLATE)       ||
-           (gl_debug_paper        && section == GL_DEBUG_PAPER)          ||
-           (gl_debug_xml          && section == GL_DEBUG_XML)            ||
-           (gl_debug_merge        && section == GL_DEBUG_MERGE)          ||
-           (gl_debug_commands     && section == GL_DEBUG_COMMANDS)       ||
-           (gl_debug_undo         && section == GL_DEBUG_UNDO)           ||
-           (gl_debug_recent       && section == GL_DEBUG_RECENT)         ||
-           (gl_debug_window       && section == GL_DEBUG_WINDOW)         ||
-           (gl_debug_ui           && section == GL_DEBUG_UI)             ||
-           (gl_debug_property_bar && section == GL_DEBUG_PROPERTY_BAR)   ||
-           (gl_debug_media_select && section == GL_DEBUG_MEDIA_SELECT)   ||
-           (gl_debug_mini_preview && section == GL_DEBUG_MINI_PREVIEW)   ||
-           (gl_debug_pixbuf_cache && section == GL_DEBUG_PIXBUF_CACHE)   ||
-           (gl_debug_editor       && section == GL_DEBUG_EDITOR)         ||
-           (gl_debug_wdgt         && section == GL_DEBUG_WDGT) )
                g_print ("%s:%d (%s) %s\n", file, line, function, msg);
+
+               g_free (msg);
+       }
        
-       g_free (msg);
 }
index 809d6f98e07e44372cb1de0fe0e99e65a0a2cfa3..58cba587a5bca6968483595810ba77a0de7609c3 100644 (file)
 #ifndef __DEBUG_H__
 #define __DEBUG_H__
 
+#include <glib.h>
+
 G_BEGIN_DECLS
 
+/*
+ * Set an environmental var of the same name to turn on
+ * debugging output. Setting GLABELS_DEBUG will turn on all
+ * sections.
+ */
+
 typedef enum {
-       GL_DEBUG_VIEW,
-       GL_DEBUG_ITEM,
-       GL_DEBUG_PRINT,
-       GL_DEBUG_PREFS,
-       GL_DEBUG_FILE,
-       GL_DEBUG_LABEL,
-       GL_DEBUG_TEMPLATE,
-       GL_DEBUG_PAPER,
-       GL_DEBUG_XML,
-       GL_DEBUG_MERGE,
-       GL_DEBUG_UNDO,
-       GL_DEBUG_RECENT,
-       GL_DEBUG_COMMANDS,
-       GL_DEBUG_WINDOW,
-       GL_DEBUG_UI,
-       GL_DEBUG_PROPERTY_BAR,
-       GL_DEBUG_MEDIA_SELECT,
-       GL_DEBUG_MINI_PREVIEW,
-       GL_DEBUG_PIXBUF_CACHE,
-       GL_DEBUG_EDITOR,
-       GL_DEBUG_WDGT,
+       GLABELS_DEBUG_NONE         = 0,
+       GLABELS_DEBUG_VIEW         = 1 << 0,
+       GLABELS_DEBUG_ITEM         = 1 << 1,
+       GLABELS_DEBUG_PRINT        = 1 << 2,
+       GLABELS_DEBUG_PREFS        = 1 << 3,
+       GLABELS_DEBUG_FILE         = 1 << 4,
+       GLABELS_DEBUG_LABEL        = 1 << 5,
+       GLABELS_DEBUG_TEMPLATE     = 1 << 6,
+       GLABELS_DEBUG_PAPER        = 1 << 7,
+       GLABELS_DEBUG_XML          = 1 << 8,
+       GLABELS_DEBUG_MERGE        = 1 << 9,
+       GLABELS_DEBUG_UNDO         = 1 << 10,
+       GLABELS_DEBUG_RECENT       = 1 << 11,
+       GLABELS_DEBUG_COMMANDS     = 1 << 12,
+       GLABELS_DEBUG_WINDOW       = 1 << 13,
+       GLABELS_DEBUG_UI           = 1 << 14,
+       GLABELS_DEBUG_PROPERTY_BAR = 1 << 15,
+       GLABELS_DEBUG_MEDIA_SELECT = 1 << 16,
+       GLABELS_DEBUG_MINI_PREVIEW = 1 << 17,
+       GLABELS_DEBUG_PIXBUF_CACHE = 1 << 18,
+       GLABELS_DEBUG_EDITOR       = 1 << 19,
+       GLABELS_DEBUG_WDGT         = 1 << 20,
 } glDebugSection;
 
-extern gint gl_debug_all;
-extern gint gl_debug_view;
-extern gint gl_debug_item;
-extern gint gl_debug_print;
-extern gint gl_debug_prefs;
-extern gint gl_debug_file;
-extern gint gl_debug_label;
-extern gint gl_debug_template;
-extern gint gl_debug_paper;
-extern gint gl_debug_xml;
-extern gint gl_debug_merge;
-extern gint gl_debug_commands;
-extern gint gl_debug_undo;
-extern gint gl_debug_recent;
-extern gint gl_debug_window;
-extern gint gl_debug_ui;
-extern gint gl_debug_property_bar;
-extern gint gl_debug_media_select;
-extern gint gl_debug_mini_preview;
-extern gint gl_debug_pixbuf_cache;
-extern gint gl_debug_editor;
-extern gint gl_debug_wdgt;
 
 #ifndef __GNUC__
 #define __FUNCTION__   ""
 #endif
 
-#define        DEBUG_VIEW      GL_DEBUG_VIEW,    __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_ITEM      GL_DEBUG_ITEM,    __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_PRINT     GL_DEBUG_PRINT,   __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_PREFS     GL_DEBUG_PREFS,   __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_FILE      GL_DEBUG_FILE,    __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_LABEL     GL_DEBUG_LABEL,   __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_TEMPLATE  GL_DEBUG_TEMPLATE,__FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_PAPER     GL_DEBUG_PAPER,   __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_XML       GL_DEBUG_XML,     __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_MERGE     GL_DEBUG_MERGE,   __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_UNDO      GL_DEBUG_UNDO,    __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_RECENT    GL_DEBUG_RECENT,  __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_COMMANDS  GL_DEBUG_COMMANDS,__FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_WINDOW    GL_DEBUG_WINDOW,  __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_UI        GL_DEBUG_UI,      __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_PROPERTY_BAR      GL_DEBUG_PROPERTY_BAR,     __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_MEDIA_SELECT      GL_DEBUG_MEDIA_SELECT,     __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_MINI_PREVIEW      GL_DEBUG_MINI_PREVIEW,     __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_PIXBUF_CACHE      GL_DEBUG_PIXBUF_CACHE,     __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_EDITOR    GL_DEBUG_EDITOR,  __FILE__, __LINE__, __FUNCTION__
-#define        DEBUG_WDGT      GL_DEBUG_WDGT,    __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_VIEW      GLABELS_DEBUG_VIEW,    __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_ITEM      GLABELS_DEBUG_ITEM,    __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_PRINT     GLABELS_DEBUG_PRINT,   __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_PREFS     GLABELS_DEBUG_PREFS,   __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_FILE      GLABELS_DEBUG_FILE,    __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_LABEL     GLABELS_DEBUG_LABEL,   __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_TEMPLATE  GLABELS_DEBUG_TEMPLATE,__FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_PAPER     GLABELS_DEBUG_PAPER,   __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_XML       GLABELS_DEBUG_XML,     __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_MERGE     GLABELS_DEBUG_MERGE,   __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_UNDO      GLABELS_DEBUG_UNDO,    __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_RECENT    GLABELS_DEBUG_RECENT,  __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_COMMANDS  GLABELS_DEBUG_COMMANDS,__FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_WINDOW    GLABELS_DEBUG_WINDOW,  __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_UI        GLABELS_DEBUG_UI,      __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_PROPERTY_BAR      GLABELS_DEBUG_PROPERTY_BAR,     __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_MEDIA_SELECT      GLABELS_DEBUG_MEDIA_SELECT,     __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_MINI_PREVIEW      GLABELS_DEBUG_MINI_PREVIEW,     __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_PIXBUF_CACHE      GLABELS_DEBUG_PIXBUF_CACHE,     __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_EDITOR    GLABELS_DEBUG_EDITOR,  __FILE__, __LINE__, __FUNCTION__
+#define        DEBUG_WDGT      GLABELS_DEBUG_WDGT,    __FILE__, __LINE__, __FUNCTION__
+
+void gl_debug_init (void);
 
-void gl_debug (gint section, gchar *file,
-              gint line, gchar* function, gchar* format, ...);
+void gl_debug      (glDebugSection  section,
+                   const gchar    *file,
+                   gint            line,
+                   const gchar    *function,
+                   const gchar    *format,
+                   ...);
 
 G_END_DECLS
 
index dc32147e429cbf23cd65e8d22f5a928b25b88815..509836b92095f746096d9288eece3856e38c78e2 100644 (file)
@@ -31,6 +31,7 @@
 #include <libglabels/paper.h>
 #include <libglabels/template.h>
 #include "util.h"
+#include "debug.h"
 
 /*============================================*/
 /* Private globals                            */
@@ -40,6 +41,7 @@ static gboolean version_flag = FALSE;
 static gchar    *output      = "output.ps";
 static gint     n_copies     = 1;
 static gint     n_sheets     = 1;
+static gint     first        = 1;
 static gboolean outline_flag = FALSE;
 static gboolean reverse_flag = FALSE;
 static gboolean crop_marks_flag = FALSE;
@@ -56,6 +58,8 @@ static struct poptOption options[] = {
         N_("number of sheets (default=1)"), N_("sheets")},
        {"copies", 'c', POPT_ARG_INT, &n_copies, 0,
         N_("number of copies (default=1)"), N_("copies")},
+       {"first", 'f', POPT_ARG_INT, &first, 0,
+        N_("first label on first sheet (default=1)"), N_("first")},
        {"outline", 'l', POPT_ARG_NONE, &outline_flag, 0,
         N_("print outlines (to test printer alignment)"), NULL},
        {"reverse", 'r', POPT_ARG_NONE, &reverse_flag, 0,
@@ -131,6 +135,7 @@ main (int argc, char **argv)
        flags.crop_marks = crop_marks_flag;
 
        /* initialize components */
+       gl_debug_init ();
        gl_merge_init ();
        gl_paper_init ();
        gl_template_init ();
@@ -170,7 +175,7 @@ main (int argc, char **argv)
                                g_free( abs_fn );
                        }
 
-                       gl_print_batch (job, label, n_sheets, n_copies, &flags);
+                       gl_print_batch (job, label, n_sheets, n_copies, first, &flags);
                        g_object_unref (label);
                }
                else {
index d2f6f23e0a196e7ac57953e8f3f40ba854bf3fda..0414be1c4235617dfd574cc1baf3ac6388c5a01f 100644 (file)
 /*========================================================*/
 #define ICON_PIXMAP gnome_program_locate_file (NULL,\
                                               GNOME_FILE_DOMAIN_APP_PIXMAP,\
-                                              "glabels/glabels-icon.png",\
+                                              "glabels.png",\
                                               FALSE, NULL)
 
 /*========================================================*/
 /* Private globals                                        */
 /*========================================================*/
-static const struct poptOption options [] =
-{
-       { "debug-view", '\0', POPT_ARG_NONE, &gl_debug_view, 0,
-         N_("Show view debugging messages."), NULL },
-
-       { "debug-item", '\0', POPT_ARG_NONE, &gl_debug_item, 0,
-         N_("Show item debugging messages."), NULL },
-
-       { "debug-print", '\0', POPT_ARG_NONE, &gl_debug_print, 0,
-         N_("Show printing debugging messages."), NULL },
-
-       { "debug-prefs", '\0', POPT_ARG_NONE, &gl_debug_prefs, 0,
-         N_("Show prefs debugging messages."), NULL },
-
-       { "debug-file", '\0', POPT_ARG_NONE, &gl_debug_file, 0,
-         N_("Show file debugging messages."), NULL },
-
-       { "debug-label", '\0', POPT_ARG_NONE, &gl_debug_label, 0,
-         N_("Show document debugging messages."), NULL },
-
-       { "debug-template", '\0', POPT_ARG_NONE, &gl_debug_template, 0,
-         N_("Show template debugging messages."), NULL },
-
-       { "debug-paper", '\0', POPT_ARG_NONE, &gl_debug_paper, 0,
-         N_("Show paper debugging messages."), NULL },
-
-       { "debug-xml", '\0', POPT_ARG_NONE, &gl_debug_xml, 0,
-         N_("Show xml debugging messages."), NULL },
-
-       { "debug-merge", '\0', POPT_ARG_NONE, &gl_debug_merge, 0,
-         N_("Show document merge debugging messages."), NULL },
-
-       { "debug-commands", '\0', POPT_ARG_NONE, &gl_debug_commands, 0,
-         N_("Show commands debugging messages."), NULL },
-
-       { "debug-undo", '\0', POPT_ARG_NONE, &gl_debug_undo, 0,
-         N_("Show undo debugging messages."), NULL },
-
-       { "debug-recent", '\0', POPT_ARG_NONE, &gl_debug_recent, 0,
-         N_("Show recent debugging messages."), NULL },
-
-       { "debug-window", '\0', POPT_ARG_NONE, &gl_debug_window, 0,
-         N_("Show window debugging messages."), NULL },
-
-       { "debug-ui", '\0', POPT_ARG_NONE, &gl_debug_ui, 0,
-         N_("Show ui debugging messages."), NULL },
-
-       { "debug-property-bar", '\0', POPT_ARG_NONE, &gl_debug_property_bar, 0,
-         N_("Show property_bar debugging messages."), NULL },
-
-       { "debug-media-select", '\0', POPT_ARG_NONE, &gl_debug_media_select, 0,
-         N_("Show media select widget debugging messages."), NULL },
-
-       { "debug-mini-preview", '\0', POPT_ARG_NONE, &gl_debug_mini_preview, 0,
-         N_("Show mini preview widget debugging messages."), NULL },
-
-       { "debug-pixbuf-cache", '\0', POPT_ARG_NONE, &gl_debug_pixbuf_cache, 0,
-         N_("Show pixbuf cache debugging messages."), NULL },
-
-       { "debug-editor", '\0', POPT_ARG_NONE, &gl_debug_editor, 0,
-         N_("Show widget debugging messages."), NULL },
-
-       { "debug-wdgt", '\0', POPT_ARG_NONE, &gl_debug_wdgt, 0,
-         N_("Show object editor debugging messages."), NULL },
-
-       { "debug", '\0', POPT_ARG_NONE, &gl_debug_all, 0,
-         N_("Turn on all debugging messages."), NULL },
-
-       {NULL, '\0', 0, NULL, 0}
-};
 
 /*========================================================*/
 /* Local function prototypes                              */
@@ -158,14 +88,11 @@ main (int argc, char **argv)
        program = gnome_program_init ("glabels", VERSION,
                                      LIBGNOMEUI_MODULE, argc, argv,
                                      GNOME_PROGRAM_STANDARD_PROPERTIES,
-                                     GNOME_PARAM_POPT_TABLE, options,
                                      NULL);
 
        /* Splash screen */
        gl_splash ();
 
-       gl_stock_init();
-
        /* Set default icon */
        if (!g_file_test (ICON_PIXMAP, G_FILE_TEST_EXISTS))
        {
@@ -177,6 +104,8 @@ main (int argc, char **argv)
        }
        
        /* Initialize subsystems */
+       gl_debug_init ();
+       gl_stock_init ();
        gl_paper_init ();
        gl_prefs_init ();
        gl_template_init ();
index 47b77350666f87dab893827f4e83e1d975f57904..d00f690c266b7c79a08f2eb7b48f86d8cf4d15be 100644 (file)
@@ -39,7 +39,7 @@
 struct _glLabelBarcodePrivate {
        glTextNode     *text_node;
        gchar          *id;
-       guint           color;
+       glColorNode    *color_node;
        gboolean        text_flag;
        gboolean        checksum_flag;
        guint           format_digits;
@@ -69,9 +69,9 @@ static void  get_size                       (glLabelObject       *object,
                                             gdouble             *h);
 
 static void  set_line_color                 (glLabelObject       *object,
-                                            guint                line_color);
+                                            glColorNode         *line_color);
 
-static guint get_line_color                 (glLabelObject       *object);
+static glColorNode *get_line_color           (glLabelObject       *object);
 
 
 \f
@@ -124,6 +124,7 @@ static void
 gl_label_barcode_instance_init (glLabelBarcode *lbc)
 {
        lbc->private = g_new0 (glLabelBarcodePrivate, 1);
+       lbc->private->color_node = gl_color_node_new_default ();
 }
 
 static void
@@ -135,6 +136,7 @@ gl_label_barcode_finalize (GObject *object)
 
        lbc = GL_LABEL_BARCODE (object);
 
+       gl_color_node_free (&(lbc->private->color_node));
        gl_text_node_free (&lbc->private->text_node);
        g_free (lbc->private);
 
@@ -169,7 +171,7 @@ copy (glLabelObject *dst_object,
        gchar               *id;
        gboolean             text_flag;
        gboolean             checksum_flag;
-       guint                color;
+       glColorNode         *color_node;
        guint                format_digits;
 
        gl_debug (DEBUG_LABEL, "START");
@@ -179,12 +181,13 @@ copy (glLabelObject *dst_object,
 
        text_node = gl_label_barcode_get_data (lbc);
        gl_label_barcode_get_props (lbc, &id, &text_flag, &checksum_flag, &format_digits);
-       color = get_line_color (src_object);
+       color_node = get_line_color (src_object);
 
        gl_label_barcode_set_data (new_lbc, text_node);
        gl_label_barcode_set_props (new_lbc, id, text_flag, checksum_flag, format_digits);
-       set_line_color (dst_object, color);
+       set_line_color (dst_object, color_node);
 
+       gl_color_node_free (&color_node);
        gl_text_node_free (&text_node);
        g_free (id);
 
@@ -331,14 +334,16 @@ get_size (glLabelObject *object,
 /*---------------------------------------------------------------------------*/
 static void
 set_line_color (glLabelObject *object,
-               guint          line_color)
+               glColorNode   *line_color_node)
 {
        glLabelBarcode *lbarcode = (glLabelBarcode *)object;
 
        g_return_if_fail (lbarcode && GL_IS_LABEL_BARCODE (lbarcode));
 
-       if ( lbarcode->private->color != line_color ) {
-               lbarcode->private->color = line_color;
+       if ( !gl_color_node_equal(lbarcode->private->color_node, line_color_node) ) {
+               
+               gl_color_node_free (&(lbarcode->private->color_node));
+               lbarcode->private->color_node = gl_color_node_dup (line_color_node);
                gl_label_object_emit_changed (GL_LABEL_OBJECT(lbarcode));
        }
 }
@@ -346,13 +351,12 @@ set_line_color (glLabelObject *object,
 /*---------------------------------------------------------------------------*/
 /* PRIVATE.  Get line color method.                                          */
 /*---------------------------------------------------------------------------*/
-static guint
+static glColorNode*
 get_line_color (glLabelObject *object)
 {
        glLabelBarcode *lbarcode = (glLabelBarcode *)object;
 
        g_return_if_fail (lbarcode && GL_IS_LABEL_BARCODE (lbarcode));
 
-       return lbarcode->private->color;
+       return gl_color_node_dup (lbarcode->private->color_node);
 }
-
index cd948553453af4ba330a8c8f6a7d213cbae4c48f..654c39d0deef585d2ddb42fa7189454c9be042a9 100644 (file)
@@ -32,8 +32,8 @@
 
 struct _glLabelBoxPrivate {
        gdouble          line_width;
-       guint            line_color;
-       guint            fill_color;
+       glColorNode      *line_color_node;
+       glColorNode      *fill_color_node;
 };
 
 /*========================================================*/
@@ -55,20 +55,20 @@ static void    gl_label_box_finalize      (GObject         *object);
 static void    copy                       (glLabelObject   *dst_object,
                                           glLabelObject   *src_object);
 
-static void    set_fill_color              (glLabelObject    *object,
-                                           guint             fill_color);
+static void    set_fill_color             (glLabelObject   *object,
+                                          glColorNode     *fill_color_node);
 
-static void    set_line_color              (glLabelObject    *object,
-                                           guint             line_color);
+static void    set_line_color             (glLabelObject   *object,
+                                          glColorNode     *line_color_node);
 
-static void    set_line_width              (glLabelObject    *object,
-                                           gdouble           line_width);
+static void    set_line_width             (glLabelObject   *object,
+                                          gdouble          line_width);
 
-static guint   get_fill_color              (glLabelObject    *object);
+static glColorNode*   get_fill_color      (glLabelObject   *object);
 
-static guint   get_line_color              (glLabelObject    *object);
+static glColorNode*   get_line_color      (glLabelObject   *object);
 
-static gdouble get_line_width              (glLabelObject    *object);
+static gdouble get_line_width             (glLabelObject   *object);
 
 
 \f
@@ -124,6 +124,8 @@ static void
 gl_label_box_instance_init (glLabelBox *lbox)
 {
        lbox->private = g_new0 (glLabelBoxPrivate, 1);
+       lbox->private->line_color_node = gl_color_node_new_default ();
+       lbox->private->fill_color_node = gl_color_node_new_default ();
 }
 
 static void
@@ -135,6 +137,8 @@ gl_label_box_finalize (GObject *object)
 
        lbox = GL_LABEL_BOX (object);
 
+       gl_color_node_free (&(lbox->private->fill_color_node));
+       gl_color_node_free (&(lbox->private->line_color_node));
        g_free (lbox->private);
 
        G_OBJECT_CLASS (parent_class)->finalize (object);
@@ -162,10 +166,11 @@ static void
 copy (glLabelObject *dst_object,
       glLabelObject *src_object)
 {
-       glLabelBox *lbox     = (glLabelBox *)src_object;
-       glLabelBox *new_lbox = (glLabelBox *)dst_object;
-       gdouble     line_width;
-       guint       line_color, fill_color;
+       glLabelBox  *lbox     = (glLabelBox *)src_object;
+       glLabelBox  *new_lbox = (glLabelBox *)dst_object;
+       gdouble      line_width;
+       glColorNode *line_color_node;
+       glColorNode *fill_color_node;
 
        gl_debug (DEBUG_LABEL, "START");
 
@@ -173,12 +178,15 @@ copy (glLabelObject *dst_object,
        g_return_if_fail (new_lbox && GL_IS_LABEL_BOX (new_lbox));
 
        line_width = get_line_width (src_object);
-       line_color = get_line_color (src_object);
-       fill_color = get_fill_color (src_object);
+       line_color_node = get_line_color (src_object);
+       fill_color_node = get_fill_color (src_object);
 
        set_line_width (dst_object, line_width);
-       set_line_color (dst_object, line_color);
-       set_fill_color (dst_object, fill_color);
+       set_line_color (dst_object, line_color_node);
+       set_fill_color (dst_object, fill_color_node);
+       
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
 
        gl_debug (DEBUG_LABEL, "END");
 }
@@ -189,16 +197,22 @@ copy (glLabelObject *dst_object,
 /*---------------------------------------------------------------------------*/
 static void
 set_fill_color (glLabelObject *object,
-               guint          fill_color)
+               glColorNode   *fill_color_node)
 {
        glLabelBox *lbox = (glLabelBox *)object;
+       
+       gl_debug (DEBUG_LABEL, "START");
 
        g_return_if_fail (lbox && GL_IS_LABEL_BOX (lbox));
 
-       if ( lbox->private->fill_color != fill_color ) {
-               lbox->private->fill_color = fill_color;
+       if (!gl_color_node_equal (lbox->private->fill_color_node, fill_color_node)) {
+
+               gl_color_node_free (&(lbox->private->fill_color_node));
+               lbox->private->fill_color_node = gl_color_node_dup (fill_color_node);
+
                gl_label_object_emit_changed (GL_LABEL_OBJECT(lbox));
        }
+       gl_debug (DEBUG_LABEL, "END");
 }
 
 /*---------------------------------------------------------------------------*/
@@ -206,14 +220,15 @@ set_fill_color (glLabelObject *object,
 /*---------------------------------------------------------------------------*/
 static void
 set_line_color (glLabelObject *object,
-               guint          line_color)
+               glColorNode   *line_color_node)
 {
        glLabelBox *lbox = (glLabelBox *)object;
 
        g_return_if_fail (lbox && GL_IS_LABEL_BOX (lbox));
 
-       if ( lbox->private->line_color != line_color ) {
-               lbox->private->line_color = line_color;
+       if ( !gl_color_node_equal (lbox->private->line_color_node, line_color_node )) {
+               gl_color_node_free (&(lbox->private->line_color_node));
+               lbox->private->line_color_node = gl_color_node_dup (line_color_node);
                gl_label_object_emit_changed (GL_LABEL_OBJECT(lbox));
        }
 }
@@ -252,26 +267,25 @@ get_line_width (glLabelObject *object)
 /*---------------------------------------------------------------------------*/
 /* PRIVATE.  Get line color method.                                          */
 /*---------------------------------------------------------------------------*/
-static guint
+static glColorNode*
 get_line_color (glLabelObject *object)
 {
        glLabelBox *lbox = (glLabelBox *)object;
 
        g_return_val_if_fail (lbox && GL_IS_LABEL_BOX (lbox), 0);
 
-       return lbox->private->line_color;
+       return gl_color_node_dup (lbox->private->line_color_node);
 }
 
 /*---------------------------------------------------------------------------*/
 /* PRIVATE.  Get line width method.                                          */
 /*---------------------------------------------------------------------------*/
-static guint
+static glColorNode*
 get_fill_color (glLabelObject *object)
 {
        glLabelBox *lbox = (glLabelBox *)object;
 
        g_return_val_if_fail (lbox && GL_IS_LABEL_BOX (lbox), 0);
 
-       return lbox->private->fill_color;
+       return gl_color_node_dup (lbox->private->fill_color_node);
 }
-
index 01dc6f46b7b564c736510b8d61c1356ee8643aa7..95fa936483ab3e6cc43bb76423466682790ba450 100644 (file)
@@ -32,8 +32,8 @@
 
 struct _glLabelEllipsePrivate {
        gdouble          line_width;
-       guint            line_color;
-       guint            fill_color;
+       glColorNode     *line_color_node;
+       glColorNode     *fill_color_node;
 };
 
 /*========================================================*/
@@ -56,17 +56,17 @@ static void    copy                           (glLabelObject       *dst_object,
                                               glLabelObject       *src_object);
 
 static void    set_fill_color                 (glLabelObject       *object,
-                                              guint                fill_color);
+                                              glColorNode         *fill_color_node);
 
 static void    set_line_color                 (glLabelObject       *object,
-                                              guint                line_color);
+                                              glColorNode         *line_color_node);
 
 static void    set_line_width                 (glLabelObject       *object,
                                               gdouble              line_width);
 
-static guint   get_fill_color                 (glLabelObject       *object);
+static glColorNode*   get_fill_color          (glLabelObject       *object);
 
-static guint   get_line_color                 (glLabelObject       *object);
+static glColorNode*   get_line_color          (glLabelObject       *object);
 
 static gdouble get_line_width                 (glLabelObject       *object);
 
@@ -124,6 +124,8 @@ static void
 gl_label_ellipse_instance_init (glLabelEllipse *lellipse)
 {
        lellipse->private = g_new0 (glLabelEllipsePrivate, 1);
+       lellipse->private->fill_color_node = gl_color_node_new_default ();
+       lellipse->private->fill_color_node = gl_color_node_new_default ();
 }
 
 static void
@@ -135,6 +137,8 @@ gl_label_ellipse_finalize (GObject *object)
 
        lellipse = GL_LABEL_ELLIPSE (object);
 
+       gl_color_node_free (&(lellipse->private->line_color_node));
+       gl_color_node_free (&(lellipse->private->fill_color_node));
        g_free (lellipse->private);
 
        G_OBJECT_CLASS (parent_class)->finalize (object);
@@ -165,7 +169,8 @@ copy (glLabelObject *dst_object,
        glLabelEllipse *lellipse     = (glLabelEllipse *)src_object;
        glLabelEllipse *new_lellipse = (glLabelEllipse *)dst_object;
        gdouble         line_width;
-       guint           line_color, fill_color;
+       glColorNode    *line_color_node;
+       glColorNode    *fill_color_node;
 
        gl_debug (DEBUG_LABEL, "START");
 
@@ -173,13 +178,16 @@ copy (glLabelObject *dst_object,
        g_return_if_fail (new_lellipse && GL_IS_LABEL_ELLIPSE (new_lellipse));
 
        line_width = get_line_width (src_object);
-       line_color = get_line_color (src_object);
-       fill_color = get_fill_color (src_object);
+       line_color_node = get_line_color (src_object);
+       fill_color_node = get_fill_color (src_object);
 
        set_line_width (dst_object, line_width);
-       set_line_color (dst_object, line_color);
-       set_fill_color (dst_object, fill_color);
+       set_line_color (dst_object, line_color_node);
+       set_fill_color (dst_object, fill_color_node);
 
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
+       
        gl_debug (DEBUG_LABEL, "END");
 }
 
@@ -189,16 +197,19 @@ copy (glLabelObject *dst_object,
 /*---------------------------------------------------------------------------*/
 static void
 set_fill_color (glLabelObject *object,
-               guint          fill_color)
+               glColorNode   *fill_color_node)
 {
        glLabelEllipse *lellipse = (glLabelEllipse *)object;
 
        g_return_if_fail (lellipse && GL_IS_LABEL_ELLIPSE (lellipse));
 
-       if ( lellipse->private->fill_color != fill_color ) {
-               lellipse->private->fill_color = fill_color;
+       if (!gl_color_node_equal (lellipse->private->fill_color_node, fill_color_node)) {
+
+               gl_color_node_free (&(lellipse->private->fill_color_node));
+               lellipse->private->fill_color_node = gl_color_node_dup (fill_color_node);
+
                gl_label_object_emit_changed (GL_LABEL_OBJECT(lellipse));
-       }
+       }       
 }
 
 /*---------------------------------------------------------------------------*/
@@ -206,14 +217,17 @@ set_fill_color (glLabelObject *object,
 /*---------------------------------------------------------------------------*/
 static void
 set_line_color (glLabelObject *object,
-               guint          line_color)
+               glColorNode   *line_color_node)
 {
        glLabelEllipse *lellipse = (glLabelEllipse *)object;
 
        g_return_if_fail (lellipse && GL_IS_LABEL_ELLIPSE (lellipse));
 
-       if ( lellipse->private->line_color != line_color ) {
-               lellipse->private->line_color = line_color;
+       if ( !gl_color_node_equal (lellipse->private->line_color_node, line_color_node) ) {
+               
+               gl_color_node_free (&(lellipse->private->line_color_node));
+               lellipse->private->line_color_node = gl_color_node_dup (line_color_node);
+               
                gl_label_object_emit_changed (GL_LABEL_OBJECT(lellipse));
        }
 }
@@ -252,27 +266,25 @@ get_line_width (glLabelObject *object)
 /*---------------------------------------------------------------------------*/
 /* PRIVATE.  Get line color method.                                          */
 /*---------------------------------------------------------------------------*/
-static guint
+static glColorNode*
 get_line_color (glLabelObject *object)
 {
        glLabelEllipse *lellipse = (glLabelEllipse *)object;
 
        g_return_val_if_fail (lellipse && GL_IS_LABEL_ELLIPSE (lellipse), 0);
 
-       return lellipse->private->line_color;
+       return gl_color_node_dup (lellipse->private->line_color_node);
 }
 
 /*---------------------------------------------------------------------------*/
 /* PRIVATE.  Get line width method.                                          */
 /*---------------------------------------------------------------------------*/
-static guint
+static glColorNode*
 get_fill_color (glLabelObject *object)
 {
        glLabelEllipse *lellipse = (glLabelEllipse *)object;
 
        g_return_val_if_fail (lellipse && GL_IS_LABEL_ELLIPSE (lellipse), 0);
 
-       return lellipse->private->fill_color;
+       return gl_color_node_dup (lellipse->private->fill_color_node);
 }
-
-
index 23fd5d87ebb51a58ab6107502c2bcc8a6d6a99ad..9a2f6a7ceb27176507cdb8190c38c6e279444fba 100644 (file)
@@ -32,7 +32,7 @@
 
 struct _glLabelLinePrivate {
        gdouble          line_width;
-       guint            line_color;
+       glColorNode     *line_color_node;
 };
 
 /*========================================================*/
@@ -55,12 +55,12 @@ static void    copy                        (glLabelObject    *dst_object,
                                            glLabelObject    *src_object);
 
 static void    set_line_color              (glLabelObject    *object,
-                                           guint             line_color);
+                                           glColorNode      *line_color_node);
 
 static void    set_line_width              (glLabelObject    *object,
                                            gdouble           line_width);
 
-static guint   get_line_color              (glLabelObject    *object);
+static glColorNode   *get_line_color       (glLabelObject    *object);
 
 static gdouble get_line_width              (glLabelObject    *object);
 
@@ -116,6 +116,7 @@ static void
 gl_label_line_instance_init (glLabelLine *lline)
 {
        lline->private = g_new0 (glLabelLinePrivate, 1);
+       lline->private->line_color_node = gl_color_node_new_default ();
 }
 
 static void
@@ -127,6 +128,7 @@ gl_label_line_finalize (GObject *object)
 
        lline = GL_LABEL_LINE (object);
 
+       gl_color_node_free (&(lline->private->line_color_node));
        g_free (lline->private);
 
        G_OBJECT_CLASS (parent_class)->finalize (object);
@@ -157,7 +159,7 @@ copy (glLabelObject *dst_object,
        glLabelLine *lline     = (glLabelLine *)src_object;
        glLabelLine *new_lline = (glLabelLine *)dst_object;
        gdouble      line_width;
-       guint        line_color;
+       glColorNode *line_color_node;
 
        gl_debug (DEBUG_LABEL, "START");
 
@@ -165,11 +167,13 @@ copy (glLabelObject *dst_object,
        g_return_if_fail (new_lline && GL_IS_LABEL_LINE (new_lline));
 
        line_width = get_line_width (src_object);
-       line_color = get_line_color (src_object);
+       line_color_node = get_line_color (src_object);
 
        set_line_width (dst_object, line_width);
-       set_line_color (dst_object, line_color);
+       set_line_color (dst_object, line_color_node);
 
+       gl_color_node_free (&line_color_node);
+       
        gl_debug (DEBUG_LABEL, "END");
 }
 
@@ -179,14 +183,17 @@ copy (glLabelObject *dst_object,
 /*---------------------------------------------------------------------------*/
 static void
 set_line_color (glLabelObject *object,
-               guint          line_color)
+               glColorNode   *line_color_node)
 {
        glLabelLine *lline = (glLabelLine *)object;
 
        g_return_if_fail (lline && GL_IS_LABEL_LINE (lline));
 
-       if ( lline->private->line_color != line_color ) {
-               lline->private->line_color = line_color;
+       if ( !gl_color_node_equal (lline->private->line_color_node, line_color_node)) {
+               
+               gl_color_node_free (&(lline->private->line_color_node ));
+               lline->private->line_color_node = gl_color_node_dup (line_color_node);
+               
                gl_label_object_emit_changed (GL_LABEL_OBJECT(lline));
        }
 }
@@ -225,13 +232,12 @@ get_line_width (glLabelObject *object)
 /*---------------------------------------------------------------------------*/
 /* PRIVATE.  Get line width method.                                          */
 /*---------------------------------------------------------------------------*/
-static guint
+static glColorNode*
 get_line_color (glLabelObject *object)
 {
        glLabelLine *lline = (glLabelLine *)object;
 
        g_return_val_if_fail (lline && GL_IS_LABEL_LINE (lline), 0);
 
-       return lline->private->line_color;
+       return gl_color_node_dup (lline->private->line_color_node);
 }
-
index 70780ce0d4804054eed44b42813db047f92d98b4..bcda655bd303c081f251d970159520d5a7a08264 100644 (file)
@@ -755,7 +755,7 @@ gl_label_object_set_text_line_spacing (glLabelObject     *object,
 /****************************************************************************/
 void
 gl_label_object_set_text_color (glLabelObject     *object,
-                               guint              text_color)
+                               glColorNode       *text_color_node)
 {
        gl_debug (DEBUG_LABEL, "START");
 
@@ -764,7 +764,7 @@ gl_label_object_set_text_color (glLabelObject     *object,
        if ( GL_LABEL_OBJECT_GET_CLASS(object)->set_text_color != NULL ) {
 
                /* We have an object specific method, use it */
-               GL_LABEL_OBJECT_GET_CLASS(object)->set_text_color (object, text_color);
+               GL_LABEL_OBJECT_GET_CLASS(object)->set_text_color (object, text_color_node);
 
        }
 
@@ -918,10 +918,10 @@ gl_label_object_get_text_line_spacing (glLabelObject     *object)
 /****************************************************************************/
 /* Get text color for all text contained in object.                         */
 /****************************************************************************/
-guint
+glColorNode*
 gl_label_object_get_text_color (glLabelObject     *object)
 {
-       guint ret = 0;
+       glColorNode *ret = NULL;
 
        gl_debug (DEBUG_LABEL, "START");
 
@@ -966,7 +966,7 @@ gl_label_object_can_fill (glLabelObject     *object)
 /****************************************************************************/
 void
 gl_label_object_set_fill_color (glLabelObject     *object,
-                               guint              fill_color)
+                               glColorNode       *fill_color_node)
 {
        gl_debug (DEBUG_LABEL, "START");
 
@@ -975,7 +975,7 @@ gl_label_object_set_fill_color (glLabelObject     *object,
        if ( GL_LABEL_OBJECT_GET_CLASS(object)->set_fill_color != NULL ) {
 
                /* We have an object specific method, use it */
-               GL_LABEL_OBJECT_GET_CLASS(object)->set_fill_color (object, fill_color);
+               GL_LABEL_OBJECT_GET_CLASS(object)->set_fill_color (object, fill_color_node);
 
        }
 
@@ -985,10 +985,10 @@ gl_label_object_set_fill_color (glLabelObject     *object,
 /****************************************************************************/
 /* Get fill color for object.                                               */
 /****************************************************************************/
-guint
+glColorNode*
 gl_label_object_get_fill_color (glLabelObject     *object)
 {
-       guint ret = 0;
+       glColorNode *ret = NULL;
 
        gl_debug (DEBUG_LABEL, "START");
 
@@ -1033,7 +1033,7 @@ gl_label_object_can_line_color (glLabelObject     *object)
 /****************************************************************************/
 void
 gl_label_object_set_line_color (glLabelObject     *object,
-                               guint              line_color)
+                               glColorNode       *line_color_node)
 {
        gl_debug (DEBUG_LABEL, "START");
 
@@ -1042,7 +1042,7 @@ gl_label_object_set_line_color (glLabelObject     *object,
        if ( GL_LABEL_OBJECT_GET_CLASS(object)->set_line_color != NULL ) {
 
                /* We have an object specific method, use it */
-               GL_LABEL_OBJECT_GET_CLASS(object)->set_line_color (object, line_color);
+               GL_LABEL_OBJECT_GET_CLASS(object)->set_line_color (object, line_color_node);
 
        }
 
@@ -1052,10 +1052,10 @@ gl_label_object_set_line_color (glLabelObject     *object,
 /****************************************************************************/
 /* Get line color for object.                                               */
 /****************************************************************************/
-guint
+glColorNode*
 gl_label_object_get_line_color (glLabelObject     *object)
 {
-       guint ret = 0;
+       glColorNode *ret = NULL;
 
        gl_debug (DEBUG_LABEL, "START");
 
@@ -1323,4 +1323,3 @@ merge_changed_cb (glLabel       *label,
 {
        gl_label_object_emit_changed (object);
 }
-
index 08e594db19f57afe097ee7d9da445d507f9e31be..810f6bd7ce5507738b31b6a0c88360799eee2013 100644 (file)
@@ -54,6 +54,7 @@ typedef struct _glLabelObjectClass     glLabelObjectClass;
 typedef struct _glLabelObjectPrivate   glLabelObjectPrivate;
 
 #include "label.h"
+#include "color.h"
 
 struct _glLabelObject {
        GObject               object;
@@ -97,13 +98,13 @@ struct _glLabelObjectClass {
                                                    gdouble           text_line_spacing);
 
        void              (*set_text_color)       (glLabelObject     *object,
-                                                  guint              text_color);
+                                                  glColorNode       *text_color_node);
 
        void              (*set_fill_color)       (glLabelObject     *object,
-                                                  guint              fill_color);
+                                                  glColorNode       *fill_color_node);
 
        void              (*set_line_color)       (glLabelObject     *object,
-                                                  guint              line_color);
+                                                  glColorNode       *line_color_node);
 
        void              (*set_line_width)       (glLabelObject     *object,
                                                   gdouble            line_width);
@@ -120,11 +121,11 @@ struct _glLabelObjectClass {
 
        gdouble           (*get_text_line_spacing) (glLabelObject    *object);
 
-       guint             (*get_text_color)       (glLabelObject     *object);
+       glColorNode*      (*get_text_color)       (glLabelObject     *object);
 
-       guint             (*get_fill_color)       (glLabelObject     *object);
+       glColorNode*      (*get_fill_color)       (glLabelObject     *object);
 
-       guint             (*get_line_color)       (glLabelObject     *object);
+       glColorNode*      (*get_line_color)       (glLabelObject     *object);
 
        gdouble           (*get_line_width)       (glLabelObject     *object);
 
@@ -224,7 +225,7 @@ void           gl_label_object_set_text_alignment    (glLabelObject     *object,
                                                      GtkJustification   text_alignment);
 
 void           gl_label_object_set_text_color        (glLabelObject     *object,
-                                                     guint              text_color);
+                                                     glColorNode       *text_color_node);
 
 void           gl_label_object_set_text_line_spacing (glLabelObject     *object,
                                                      gdouble            text_line_spacing);
@@ -242,23 +243,23 @@ GtkJustification gl_label_object_get_text_alignment    (glLabelObject     *objec
 
 gdouble          gl_label_object_get_text_line_spacing (glLabelObject     *object);
 
-guint            gl_label_object_get_text_color        (glLabelObject     *object);
+glColorNode     *gl_label_object_get_text_color        (glLabelObject     *object);
 
 
 gboolean       gl_label_object_can_fill              (glLabelObject     *object);
 
 void           gl_label_object_set_fill_color        (glLabelObject     *object,
-                                                     guint              fill_color);
+                                                     glColorNode       *fill_color_node);
 
-guint          gl_label_object_get_fill_color        (glLabelObject     *object);
+glColorNode*   gl_label_object_get_fill_color        (glLabelObject     *object);
 
 
 gboolean       gl_label_object_can_line_color        (glLabelObject     *object);
 
 void           gl_label_object_set_line_color        (glLabelObject     *object,
-                                                     guint              line_color);
+                                                     glColorNode       *line_color_node);
 
-guint          gl_label_object_get_line_color        (glLabelObject     *object);
+glColorNode   *gl_label_object_get_line_color        (glLabelObject     *object);
 
 gboolean       gl_label_object_can_line_width        (glLabelObject     *object);
 
index 2a8a432459f77d38f6af94e81d2da9c1286d1d10..34ad7caa134fdbf1aa6529318ff25fcdf2fa3883 100644 (file)
@@ -55,7 +55,7 @@ struct _glLabelTextPrivate {
        GnomeFontWeight  font_weight;
        gboolean         font_italic_flag;
        GtkJustification just;
-       guint            color;
+       glColorNode     *color_node;
        gdouble          line_spacing;
        gboolean         auto_shrink;
 };
@@ -105,7 +105,7 @@ static void set_text_line_spacing       (glLabelObject    *object,
                                         gdouble           text_line_spacing);
 
 static void set_text_color              (glLabelObject    *object,
-                                        guint             text_color);
+                                        glColorNode      *text_color_node);
 
 static gchar          *get_font_family             (glLabelObject    *object);
 
@@ -113,13 +113,13 @@ static gdouble         get_font_size               (glLabelObject    *object);
 
 static GnomeFontWeight get_font_weight             (glLabelObject    *object);
 
-static gboolean         get_font_italic_flag       (glLabelObject    *object);
+static gboolean        get_font_italic_flag        (glLabelObject    *object);
 
-static GtkJustification get_text_alignment          (glLabelObject    *object);
+static GtkJustification get_text_alignment         (glLabelObject    *object);
 
-static gdouble         get_text_line_spacing        (glLabelObject    *object);
+static gdouble         get_text_line_spacing       (glLabelObject    *object);
 
-static guint            get_text_color              (glLabelObject    *object);
+static glColorNode*    get_text_color              (glLabelObject    *object);
 
 \f
 /*****************************************************************************/
@@ -186,17 +186,18 @@ gl_label_text_instance_init (glLabelText *ltext)
 {
        ltext->private = g_new0 (glLabelTextPrivate, 1);
 
-       ltext->private->tag_table        = gtk_text_tag_table_new ();
-       ltext->private->buffer           = gtk_text_buffer_new (ltext->private->tag_table);
+       ltext->private->tag_table         = gtk_text_tag_table_new ();
+       ltext->private->buffer            = gtk_text_buffer_new (ltext->private->tag_table);
 
-       ltext->private->font_family      = g_strdup(DEFAULT_FONT_FAMILY);
-       ltext->private->font_size        = DEFAULT_FONT_SIZE;
-       ltext->private->font_weight      = DEFAULT_FONT_WEIGHT;
-       ltext->private->font_italic_flag = DEFAULT_FONT_ITALIC_FLAG;
-       ltext->private->just             = DEFAULT_JUST;
-       ltext->private->color            = DEFAULT_COLOR;
-       ltext->private->line_spacing     = DEFAULT_TEXT_LINE_SPACING;
-       ltext->private->auto_shrink      = DEFAULT_AUTO_SHRINK;
+       ltext->private->font_family       = g_strdup(DEFAULT_FONT_FAMILY);
+       ltext->private->font_size         = DEFAULT_FONT_SIZE;
+       ltext->private->font_weight       = DEFAULT_FONT_WEIGHT;
+       ltext->private->font_italic_flag  = DEFAULT_FONT_ITALIC_FLAG;
+       ltext->private->just              = DEFAULT_JUST;
+       ltext->private->color_node        = gl_color_node_new_default ();
+       ltext->private->color_node->color = DEFAULT_COLOR;
+       ltext->private->line_spacing      = DEFAULT_TEXT_LINE_SPACING;
+       ltext->private->auto_shrink       = DEFAULT_AUTO_SHRINK;
 
        g_signal_connect (G_OBJECT(ltext->private->buffer), "changed",
                          G_CALLBACK(buffer_changed_cb), ltext);
@@ -211,6 +212,7 @@ gl_label_text_finalize (GObject *object)
 
        ltext = GL_LABEL_TEXT (object);
 
+       gl_color_node_free (&(ltext->private->color_node));
        g_object_unref (ltext->private->tag_table);
        g_object_unref (ltext->private->buffer);
        g_free (ltext->private);
@@ -243,6 +245,7 @@ copy (glLabelObject *dst_object,
        glLabelText      *ltext     = (glLabelText *)src_object;
        glLabelText      *new_ltext = (glLabelText *)dst_object;
        GList            *lines;
+       glColorNode      *text_color_node;
 
        gl_debug (DEBUG_LABEL, "START");
 
@@ -250,17 +253,19 @@ copy (glLabelObject *dst_object,
        g_return_if_fail (new_ltext && GL_IS_LABEL_TEXT (new_ltext));
 
        lines = gl_label_text_get_lines (ltext);
+       text_color_node = get_text_color (src_object);
        gl_label_text_set_lines (new_ltext, lines);
 
        new_ltext->private->font_family      = g_strdup (ltext->private->font_family);
        new_ltext->private->font_size        = ltext->private->font_size;
        new_ltext->private->font_weight      = ltext->private->font_weight;
        new_ltext->private->font_italic_flag = ltext->private->font_italic_flag;
-       new_ltext->private->color            = ltext->private->color;
+       set_text_color (dst_object, text_color_node);
        new_ltext->private->just             = ltext->private->just;
        new_ltext->private->line_spacing     = ltext->private->line_spacing;
        new_ltext->private->auto_shrink      = ltext->private->auto_shrink;
 
+       gl_color_node_free (&text_color_node);
        gl_text_node_lines_free (&lines);
 
        gl_debug (DEBUG_LABEL, "END");
@@ -579,7 +584,7 @@ set_text_line_spacing (glLabelObject *object,
 /*---------------------------------------------------------------------------*/
 static void
 set_text_color (glLabelObject *object,
-               guint        text_color)
+               glColorNode   *text_color_node)
 {
        glLabelText    *ltext = (glLabelText *)object;
 
@@ -587,9 +592,11 @@ set_text_color (glLabelObject *object,
 
        g_return_if_fail (ltext && GL_IS_LABEL_TEXT (ltext));
 
-       if (ltext->private->color != text_color) {
+       if (!gl_color_node_equal (ltext->private->color_node, text_color_node)) {
 
-               ltext->private->color = text_color;
+               gl_color_node_free (&(ltext->private->color_node));
+               ltext->private->color_node = gl_color_node_dup (text_color_node);
+               
                gl_label_object_emit_changed (GL_LABEL_OBJECT(ltext));
 
        }
@@ -690,7 +697,7 @@ get_text_line_spacing (glLabelObject *object)
 /*---------------------------------------------------------------------------*/
 /* PRIVATE.  get text color method.                                          */
 /*---------------------------------------------------------------------------*/
-static guint
+static glColorNode*
 get_text_color (glLabelObject *object)
 {
        glLabelText    *ltext = (glLabelText *)object;
@@ -699,7 +706,7 @@ get_text_color (glLabelObject *object)
 
        g_return_val_if_fail (ltext && GL_IS_LABEL_TEXT (ltext), 0);
 
-       return ltext->private->color;
+       return gl_color_node_dup (ltext->private->color_node);
 }
 
 /*****************************************************************************/
@@ -735,4 +742,3 @@ gl_label_text_get_auto_shrink (glLabelText      *ltext)
 
        return ltext->private->auto_shrink;
 }
-
index 84fc11fd7ea0a741caf2039da19c54eeb39bffd1..66728e9fb0a704f5a4a601e623024ee8782c3802 100644 (file)
@@ -49,7 +49,8 @@
 /* Local function prototypes                 */
 /*===========================================*/
 
-static void style_changed_cb (glObjectEditor       *editor);
+static void style_changed_cb     (glObjectEditor       *editor);
+static void bc_radio_toggled_cb  (glObjectEditor       *editor);
 
 
 /*--------------------------------------------------------------------------*/
@@ -75,6 +76,14 @@ gl_object_editor_prepare_bc_page (glObjectEditor       *editor)
                glade_xml_get_widget (editor->priv->gui, "bc_cs_check");
        editor->priv->bc_color_combo =
                glade_xml_get_widget (editor->priv->gui, "bc_color_combo");
+       editor->priv->bc_key_combo = 
+               glade_xml_get_widget (editor->priv->gui, "bc_key_combo");       
+       editor->priv->bc_key_entry = 
+               glade_xml_get_widget (editor->priv->gui, "bc_key_entry");       
+       editor->priv->bc_key_radio = 
+               glade_xml_get_widget (editor->priv->gui, "bc_key_radio");       
+       editor->priv->bc_color_radio = 
+               glade_xml_get_widget (editor->priv->gui, "bc_color_radio");     
        editor->priv->data_format_label =
                glade_xml_get_widget (editor->priv->gui, "data_format_label");
        editor->priv->data_ex_label =
@@ -91,6 +100,11 @@ gl_object_editor_prepare_bc_page (glObjectEditor       *editor)
        gtk_combo_set_popdown_strings (GTK_COMBO(editor->priv->bc_style_combo), styles);
        gl_barcode_free_styles_list (styles);
 
+       /* Modify widgets */
+       gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (editor->priv->bc_color_radio), TRUE);
+       gtk_widget_set_sensitive (editor->priv->bc_color_combo, TRUE);
+       gtk_widget_set_sensitive (editor->priv->bc_key_combo, FALSE);
+       
        /* Un-hide */
        gtk_widget_show_all (editor->priv->bc_page_vbox);
 
@@ -111,6 +125,18 @@ gl_object_editor_prepare_bc_page (glObjectEditor       *editor)
                                  "color_changed",
                                  G_CALLBACK (gl_object_editor_changed_cb),
                                  G_OBJECT (editor));
+       g_signal_connect_swapped (G_OBJECT (editor->priv->bc_key_entry),
+                                 "changed",
+                                 G_CALLBACK (gl_object_editor_changed_cb),
+                                 G_OBJECT (editor));
+       g_signal_connect_swapped (G_OBJECT (editor->priv->bc_color_radio),
+                                 "toggled",
+                                 G_CALLBACK (bc_radio_toggled_cb),
+                                 G_OBJECT (editor));                             
+       g_signal_connect_swapped (G_OBJECT (editor->priv->bc_key_radio),
+                                 "toggled",
+                                 G_CALLBACK (bc_radio_toggled_cb),
+                                 G_OBJECT (editor));
        g_signal_connect_swapped (G_OBJECT (editor->priv->data_digits_spin),
                                  "changed",
                                  G_CALLBACK (gl_object_editor_changed_cb),
@@ -313,52 +339,123 @@ gl_object_editor_get_bc_style (glObjectEditor      *editor,
 /*****************************************************************************/
 void
 gl_object_editor_set_bc_color (glObjectEditor      *editor,
-                              guint                bc_color)
+                              gboolean             merge_flag,
+                              glColorNode         *color_node)
 {
        GdkColor *gdk_color;
+       gint pos;
 
        gl_debug (DEBUG_EDITOR, "START");
 
        g_signal_handlers_block_by_func (G_OBJECT(editor->priv->bc_color_combo),
                                         gl_object_editor_changed_cb,
                                         editor);
+       g_signal_handlers_block_by_func (G_OBJECT(editor->priv->bc_key_entry),
+                                        gl_object_editor_changed_cb,
+                                        editor);
 
-        gdk_color = gl_color_to_gdk_color (bc_color);
-        color_combo_set_color (COLOR_COMBO(editor->priv->bc_color_combo), gdk_color);
-        g_free (gdk_color);
+       gtk_widget_set_sensitive (editor->priv->bc_key_radio, merge_flag);
 
+       if ( color_node->color == GL_COLOR_NONE ) {
+
+               color_combo_set_color_to_default (COLOR_COMBO(editor->priv->bc_color_combo));
+
+       } else {
+
+               gdk_color = gl_color_to_gdk_color (color_node->color);
+               color_combo_set_color (COLOR_COMBO(editor->priv->bc_color_combo),
+                                          gdk_color);
+               g_free (gdk_color);
+       }
+       
+       if (!color_node->field_flag) {
+               gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON
+                                                 (editor->priv->bc_color_radio), TRUE); 
+               gtk_widget_set_sensitive (editor->priv->bc_color_combo, TRUE);
+               gtk_widget_set_sensitive (editor->priv->bc_key_combo, FALSE);
+               
+       } else {
+               gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON
+                                                 (editor->priv->bc_key_radio), TRUE); 
+               gtk_widget_set_sensitive (editor->priv->bc_color_combo, FALSE);
+               gtk_widget_set_sensitive (editor->priv->bc_key_combo, TRUE);
+               
+               gtk_editable_delete_text (GTK_EDITABLE (editor->priv->bc_key_entry), 0, -1);
+               pos = 0;
+               if (color_node->key != NULL ) {
+                       gtk_editable_insert_text (GTK_EDITABLE (editor->priv->bc_key_entry),
+                                                                       color_node->key,
+                                                                       strlen (color_node->key),
+                                                                       &pos);
+               }
+       }       
+       
        g_signal_handlers_unblock_by_func (G_OBJECT(editor->priv->bc_color_combo),
                                           gl_object_editor_changed_cb,
                                           editor);
-
+       g_signal_handlers_unblock_by_func (G_OBJECT(editor->priv->bc_key_entry),
+                                          gl_object_editor_changed_cb,
+                                          editor);
+       
        gl_debug (DEBUG_EDITOR, "END");
 }
 
 /*****************************************************************************/
 /* Query bc color.                                                           */
 /*****************************************************************************/
-guint
+glColorNode*
 gl_object_editor_get_bc_color (glObjectEditor      *editor)
 {
-       GdkColor  *gdk_color;
-       guint     color;
-       gboolean  is_default;
+       GdkColor     *gdk_color;
+       glColorNode  *color_node;
+       gboolean      is_default;
 
        gl_debug (DEBUG_EDITOR, "START");
 
-        gdk_color = color_combo_get_color (COLOR_COMBO(editor->priv->bc_color_combo),
+       color_node = gl_color_node_new_default ();
+       
+       if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (editor->priv->bc_key_radio))) {
+               color_node->field_flag = TRUE;
+               color_node->color = gl_prefs->default_line_color;
+               color_node->key = 
+                       gtk_editable_get_chars (GTK_EDITABLE (editor->priv->bc_key_entry), 0, -1);
+       } else {
+               color_node->field_flag = FALSE;
+               color_node->key = NULL;
+               gdk_color = color_combo_get_color (COLOR_COMBO(editor->priv->bc_color_combo),
                                            &is_default);
-                                                                                
-        if (is_default) {
-                color = gl_prefs->default_line_color;
-        } else {
-                color = gl_color_from_gdk_color (gdk_color);
-        }
-                                                                                
 
+               if (is_default) {
+                       color_node->color = gl_prefs->default_line_color;
+               } else {
+                       color_node->color = gl_color_from_gdk_color (gdk_color);
+               }
+       }
+       
        gl_debug (DEBUG_EDITOR, "END");
 
-       return color;
+       return color_node;
 }
 
-
+/*--------------------------------------------------------------------------*/
+/* PRIVATE.  barcode color radio callback.                                  */
+/*--------------------------------------------------------------------------*/
+static void
+bc_radio_toggled_cb (glObjectEditor *editor)
+{
+    gl_debug (DEBUG_EDITOR, "START");
+       
+       if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (editor->priv->bc_color_radio))) {
+                gtk_widget_set_sensitive (editor->priv->bc_color_combo, TRUE);
+                gtk_widget_set_sensitive (editor->priv->bc_key_combo, FALSE);
+    } else {
+                gtk_widget_set_sensitive (editor->priv->bc_color_combo, FALSE);
+                gtk_widget_set_sensitive (editor->priv->bc_key_combo, TRUE);
+               
+       }
+    /* Emit our "changed" signal */
+    g_signal_emit (G_OBJECT (editor), gl_object_editor_signals[CHANGED], 0);
+    gl_debug (DEBUG_EDITOR, "END");
+}
index d6f943f1fddf3a2f546983e15d58ca3c697217f4..e2a9418a221b8c2df01a53487059ada89b945a58 100644 (file)
@@ -49,6 +49,8 @@
 /* Local function prototypes                 */
 /*===========================================*/
 
+static void fill_radio_toggled_cb                (glObjectEditor        *editor);
+
 \f
 /*--------------------------------------------------------------------------*/
 /* PRIVATE.  Prepare fill page.                                             */
@@ -65,8 +67,20 @@ gl_object_editor_prepare_fill_page (glObjectEditor *editor)
                                                               "fill_page_vbox");
        editor->priv->fill_color_combo = glade_xml_get_widget (editor->priv->gui,
                                                               "fill_color_combo");
-
+       editor->priv->fill_key_combo = glade_xml_get_widget (editor->priv->gui,
+                                                               "fill_key_combo");      
+       editor->priv->fill_key_entry = glade_xml_get_widget (editor->priv->gui,
+                                                               "fill_key_entry");      
+       editor->priv->fill_key_radio = glade_xml_get_widget (editor->priv->gui,
+                                                               "fill_key_radio");      
+       editor->priv->fill_color_radio = glade_xml_get_widget (editor->priv->gui,
+                                                               "fill_color_radio");    
+
+       
        /* Modify widgets based on configuration */
+       gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (editor->priv->fill_color_radio), TRUE);
+       gtk_widget_set_sensitive (editor->priv->fill_color_combo, TRUE);
+    gtk_widget_set_sensitive (editor->priv->fill_key_combo, FALSE);
        gdk_color = gl_color_to_gdk_color (gl_prefs->default_fill_color);
        color_combo_set_color (COLOR_COMBO(editor->priv->fill_color_combo), gdk_color);
        g_free (gdk_color);
@@ -79,7 +93,18 @@ gl_object_editor_prepare_fill_page (glObjectEditor *editor)
                                  "color_changed",
                                  G_CALLBACK (gl_object_editor_changed_cb),
                                  G_OBJECT (editor));
-
+       g_signal_connect_swapped (G_OBJECT (editor->priv->fill_key_entry),
+                                 "changed",
+                                 G_CALLBACK (gl_object_editor_changed_cb),
+                                 G_OBJECT (editor));
+       g_signal_connect_swapped (G_OBJECT (editor->priv->fill_color_radio),
+                                 "toggled",
+                                 G_CALLBACK (fill_radio_toggled_cb),
+                                 G_OBJECT (editor));                             
+       g_signal_connect_swapped (G_OBJECT (editor->priv->fill_key_radio),
+                                 "toggled",
+                                 G_CALLBACK (fill_radio_toggled_cb),
+                                 G_OBJECT (editor));                             
        gl_debug (DEBUG_EDITOR, "END");
 }
 
@@ -88,31 +113,63 @@ gl_object_editor_prepare_fill_page (glObjectEditor *editor)
 /*****************************************************************************/
 void
 gl_object_editor_set_fill_color (glObjectEditor      *editor,
-                                guint                color)
+                                gboolean             merge_flag,
+                                glColorNode         *color_node)
 {
        GdkColor *gdk_color;
+       gint pos;
 
        gl_debug (DEBUG_EDITOR, "START");
 
        g_signal_handlers_block_by_func (G_OBJECT(editor->priv->fill_color_combo),
-                                        gl_object_editor_changed_cb,
+                                        G_CALLBACK (gl_object_editor_changed_cb),
+                                        editor);
+       g_signal_handlers_block_by_func (G_OBJECT(editor->priv->fill_key_entry),
+                                        G_CALLBACK (gl_object_editor_changed_cb),
                                         editor);
 
-       if ( color == GL_COLOR_NONE ) {
+       gtk_widget_set_sensitive (editor->priv->fill_key_radio, merge_flag);
+
+       if ( color_node->color == GL_COLOR_NONE ) {
 
                color_combo_set_color_to_default (COLOR_COMBO(editor->priv->fill_color_combo));
 
        } else {
 
-               gdk_color = gl_color_to_gdk_color (color);
+               gdk_color = gl_color_to_gdk_color (color_node->color);
                color_combo_set_color (COLOR_COMBO(editor->priv->fill_color_combo),
-                                      gdk_color);
+                                          gdk_color);
                g_free (gdk_color);
 
        }
-
+       
+       if (!color_node->field_flag) {
+               gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON
+                                                 (editor->priv->fill_color_radio), TRUE); 
+               gtk_widget_set_sensitive (editor->priv->fill_color_combo, TRUE);
+               gtk_widget_set_sensitive (editor->priv->fill_key_combo, FALSE);
+               
+       } else {
+               gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON
+                                                 (editor->priv->fill_key_radio), TRUE); 
+               gtk_widget_set_sensitive (editor->priv->fill_color_combo, FALSE);
+               gtk_widget_set_sensitive (editor->priv->fill_key_combo, TRUE);
+               
+               gtk_editable_delete_text (GTK_EDITABLE (editor->priv->fill_key_entry), 0, -1);
+               pos = 0;
+               if (color_node->key != NULL ) {
+                       gtk_editable_insert_text (GTK_EDITABLE (editor->priv->fill_key_entry),
+                                                                       color_node->key,
+                                                                       strlen (color_node->key),
+                                                                       &pos);
+               }
+       }
+       
        g_signal_handlers_unblock_by_func (G_OBJECT(editor->priv->fill_color_combo),
-                                          gl_object_editor_changed_cb,
+                                          G_CALLBACK (gl_object_editor_changed_cb),
+                                          editor);
+       g_signal_handlers_unblock_by_func (G_OBJECT(editor->priv->fill_key_entry),
+                                          G_CALLBACK (gl_object_editor_changed_cb),
                                           editor);
 
        gl_debug (DEBUG_EDITOR, "END");
@@ -121,26 +178,56 @@ gl_object_editor_set_fill_color (glObjectEditor      *editor,
 /*****************************************************************************/
 /* Query fill color.                                                         */
 /*****************************************************************************/
-guint
+glColorNode*
 gl_object_editor_get_fill_color (glObjectEditor      *editor)
 {
-        GdkColor *gdk_color;
-        gboolean  is_default;
-       guint     color;
+        GdkColor    *gdk_color;
+        gboolean     is_default;
+       glColorNode *color_node;
  
        gl_debug (DEBUG_EDITOR, "START");
 
-        gdk_color = color_combo_get_color (COLOR_COMBO(editor->priv->fill_color_combo),
+       color_node = gl_color_node_new_default ();
+       
+       if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (editor->priv->fill_key_radio))) {
+               color_node->field_flag = TRUE;
+               color_node->key = 
+                       gtk_editable_get_chars (GTK_EDITABLE (editor->priv->fill_key_entry), 0, -1);
+    } else {
+               color_node->field_flag = FALSE;
+               color_node->key = NULL;
+               gdk_color = color_combo_get_color (COLOR_COMBO(editor->priv->fill_color_combo),
                                            &is_default);
-        if (is_default) {
-                color = GL_COLOR_NONE;
-        } else {
-                color = gl_color_from_gdk_color (gdk_color);
+
+               if (!is_default) {
+               color_node->color = gl_color_from_gdk_color (gdk_color);
         }
+       }
 
        gl_debug (DEBUG_EDITOR, "END");
 
-       return color;
+       return color_node;
 }
 
+/*--------------------------------------------------------------------------*/
+/* PRIVATE.  fill radio callback.                                           */
+/*--------------------------------------------------------------------------*/
+static void
+fill_radio_toggled_cb (glObjectEditor *editor)
+{
+    gl_debug (DEBUG_EDITOR, "START");
+       
+       if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (editor->priv->fill_color_radio))) {
+                gtk_widget_set_sensitive (editor->priv->fill_color_combo, TRUE);
+                gtk_widget_set_sensitive (editor->priv->fill_key_combo, FALSE);
+    } else {
+                gtk_widget_set_sensitive (editor->priv->fill_color_combo, FALSE);
+                gtk_widget_set_sensitive (editor->priv->fill_key_combo, TRUE);
+               
+       }
+        /* Emit our "changed" signal */
+        g_signal_emit (G_OBJECT (editor), gl_object_editor_signals[CHANGED], 0);
+        gl_debug (DEBUG_EDITOR, "END");
+}
index a23c626a44b2766f672b5d527cf58ddbe2908072..6512a7635e1f1312ee6e4772c5d7082ec306af3b 100644 (file)
@@ -48,6 +48,7 @@
 /*===========================================*/
 /* Local function prototypes                 */
 /*===========================================*/
+static void line_radio_toggled_cb               (glObjectEditor        *editor);
 
 \f
 /*--------------------------------------------------------------------------*/
@@ -67,8 +68,19 @@ gl_object_editor_prepare_line_page (glObjectEditor *editor)
                                                               "line_width_spin");
        editor->priv->line_color_combo = glade_xml_get_widget (editor->priv->gui,
                                                               "line_color_combo");
+       editor->priv->line_key_combo = glade_xml_get_widget (editor->priv->gui,
+                                                               "line_key_combo");      
+       editor->priv->line_key_entry = glade_xml_get_widget (editor->priv->gui,
+                                                               "line_key_entry");      
+       editor->priv->line_key_radio = glade_xml_get_widget (editor->priv->gui,
+                                                               "line_key_radio");      
+       editor->priv->line_color_radio = glade_xml_get_widget (editor->priv->gui,
+                                                               "line_color_radio");    
 
        /* Modify widgets based on configuration */
+       gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (editor->priv->line_color_radio), TRUE);
+       gtk_widget_set_sensitive (editor->priv->line_color_combo, TRUE);
+    gtk_widget_set_sensitive (editor->priv->line_key_combo, FALSE);    
        gtk_spin_button_set_value (GTK_SPIN_BUTTON (editor->priv->line_width_spin),
                                   gl_prefs->default_line_width);
        gdk_color = gl_color_to_gdk_color (gl_prefs->default_line_color);
@@ -87,6 +99,18 @@ gl_object_editor_prepare_line_page (glObjectEditor *editor)
                                  "color_changed",
                                  G_CALLBACK (gl_object_editor_changed_cb),
                                  G_OBJECT (editor));
+       g_signal_connect_swapped (G_OBJECT (editor->priv->line_key_entry),
+                                 "changed",
+                                 G_CALLBACK (gl_object_editor_changed_cb),
+                                 G_OBJECT (editor));
+       g_signal_connect_swapped (G_OBJECT (editor->priv->line_color_radio),
+                                 "toggled",
+                                 G_CALLBACK (line_radio_toggled_cb),
+                                 G_OBJECT (editor));                             
+       g_signal_connect_swapped (G_OBJECT (editor->priv->line_key_radio),
+                                 "toggled",
+                                 G_CALLBACK (line_radio_toggled_cb),
+                                 G_OBJECT (editor));
 
        gl_debug (DEBUG_EDITOR, "END");
 }
@@ -137,9 +161,11 @@ gl_object_editor_get_line_width (glObjectEditor      *editor)
 /*****************************************************************************/
 void
 gl_object_editor_set_line_color (glObjectEditor      *editor,
-                                guint                color)
+                                gboolean             merge_flag,
+                                glColorNode         *color_node)
 {
        GdkColor *gdk_color;
+       gint pos;
 
        gl_debug (DEBUG_EDITOR, "START");
 
@@ -147,22 +173,54 @@ gl_object_editor_set_line_color (glObjectEditor      *editor,
                                         gl_object_editor_changed_cb,
                                         editor);
 
-       if ( color == GL_COLOR_NONE ) {
+       g_signal_handlers_block_by_func (G_OBJECT(editor->priv->line_key_entry),
+                                        G_CALLBACK (gl_object_editor_changed_cb),
+                                        editor);
+
+       gl_debug (DEBUG_EDITOR, "color field %s(%d) / %X", color_node->key, color_node->field_flag, color_node->color);
+       gtk_widget_set_sensitive (editor->priv->line_key_radio, merge_flag);
+
+       if ( color_node->color == GL_COLOR_NONE ) {
 
                color_combo_set_color_to_default (COLOR_COMBO(editor->priv->line_color_combo));
 
        } else {
 
-               gdk_color = gl_color_to_gdk_color (color);
+               gdk_color = gl_color_to_gdk_color (color_node->color);
                color_combo_set_color (COLOR_COMBO(editor->priv->line_color_combo),
-                                      gdk_color);
+                                          gdk_color);
                g_free (gdk_color);
 
+       }       
+       
+       if (!color_node->field_flag) {
+               gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON
+                                                 (editor->priv->line_color_radio), TRUE); 
+               gtk_widget_set_sensitive (editor->priv->line_color_combo, TRUE);
+               gtk_widget_set_sensitive (editor->priv->line_key_combo, FALSE);
+               
+       } else {
+               gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON
+                                                 (editor->priv->line_key_radio), TRUE); 
+               gtk_widget_set_sensitive (editor->priv->line_color_combo, FALSE);
+               gtk_widget_set_sensitive (editor->priv->line_key_combo, TRUE);
+               
+               gtk_editable_delete_text (GTK_EDITABLE (editor->priv->line_key_entry), 0, -1);
+               pos = 0;
+               if (color_node->key != NULL ) {
+                       gtk_editable_insert_text (GTK_EDITABLE (editor->priv->line_key_entry),
+                                                                       color_node->key,
+                                                                       strlen (color_node->key),
+                                                                       &pos);
+               }
        }
 
        g_signal_handlers_unblock_by_func (G_OBJECT(editor->priv->line_color_combo),
                                           gl_object_editor_changed_cb,
                                           editor);
+       g_signal_handlers_unblock_by_func (G_OBJECT(editor->priv->line_key_entry),
+                                          gl_object_editor_changed_cb,
+                                          editor);     
 
        gl_debug (DEBUG_EDITOR, "END");
 }
@@ -170,26 +228,56 @@ gl_object_editor_set_line_color (glObjectEditor      *editor,
 /*****************************************************************************/
 /* Query line color.                                                         */
 /*****************************************************************************/
-guint
+glColorNode*
 gl_object_editor_get_line_color (glObjectEditor      *editor)
 {
-        GdkColor *gdk_color;
-        gboolean  is_default;
-       guint     color;
+        GdkColor    *gdk_color;
+        gboolean     is_default;
+       glColorNode *color_node;
  
        gl_debug (DEBUG_EDITOR, "START");
 
-        gdk_color = color_combo_get_color (COLOR_COMBO(editor->priv->line_color_combo),
+       color_node = gl_color_node_new_default ();
+       
+       if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (editor->priv->line_key_radio))) {
+               color_node->field_flag = TRUE;
+               color_node->key = 
+                       gtk_editable_get_chars (GTK_EDITABLE (editor->priv->line_key_entry), 0, -1);
+    } else {
+               color_node->field_flag = FALSE;
+               color_node->key = NULL;
+               gdk_color = color_combo_get_color (COLOR_COMBO(editor->priv->line_color_combo),
                                            &is_default);
-        if (is_default) {
-                color = GL_COLOR_NONE;
-        } else {
-                color = gl_color_from_gdk_color (gdk_color);
-        }
 
+               if (!is_default) {
+               color_node->color = gl_color_from_gdk_color (gdk_color);
+        }
+       }
+       
        gl_debug (DEBUG_EDITOR, "END");
 
-       return color;
+       return color_node;
 }
 
+/*--------------------------------------------------------------------------*/
+/* PRIVATE.  line color radio callback.                                     */
+/*--------------------------------------------------------------------------*/
+static void
+line_radio_toggled_cb (glObjectEditor *editor)
+{
+    gl_debug (DEBUG_EDITOR, "START");
+       
+       if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (editor->priv->line_color_radio))) {
+                gtk_widget_set_sensitive (editor->priv->line_color_combo, TRUE);
+                gtk_widget_set_sensitive (editor->priv->line_key_combo, FALSE);
+    } else {
+                gtk_widget_set_sensitive (editor->priv->line_color_combo, FALSE);
+                gtk_widget_set_sensitive (editor->priv->line_key_combo, TRUE);
+               
+       }
+    /* Emit our "changed" signal */
+    g_signal_emit (G_OBJECT (editor), gl_object_editor_signals[CHANGED], 0);
+    gl_debug (DEBUG_EDITOR, "END");
+}
index 1cfe372d4efd352a2fdaffa0629d701db4e9d61c..2338169522200a81f429bb6d3da4f91af6e1e144 100644 (file)
@@ -74,10 +74,18 @@ struct _glObjectEditorPrivate {
 
        GtkWidget  *fill_page_vbox;
        GtkWidget  *fill_color_combo;
+       GtkWidget  *fill_key_combo;
+       GtkWidget  *fill_key_entry;
+       GtkWidget  *fill_key_radio;
+       GtkWidget  *fill_color_radio;
 
        GtkWidget  *line_page_vbox;
        GtkWidget  *line_width_spin;
+       GtkWidget  *line_color_radio;
        GtkWidget  *line_color_combo;
+       GtkWidget  *line_key_radio;
+       GtkWidget  *line_key_combo;
+       GtkWidget  *line_key_entry;
 
        GtkWidget  *img_page_vbox;
        GtkWidget  *img_file_radio;
@@ -92,7 +100,11 @@ struct _glObjectEditorPrivate {
        GtkWidget  *text_size_spin;
        GtkWidget  *text_bold_toggle;
        GtkWidget  *text_italic_toggle;
+       GtkWidget  *text_color_radio;
        GtkWidget  *text_color_combo;
+       GtkWidget  *text_color_key_radio;
+       GtkWidget  *text_color_key_combo;
+       GtkWidget  *text_color_key_entry;
        GtkWidget  *text_left_toggle;
        GtkWidget  *text_center_toggle;
        GtkWidget  *text_right_toggle;
@@ -111,7 +123,11 @@ struct _glObjectEditorPrivate {
        GtkWidget  *bc_style_combo;
        GtkWidget  *bc_text_check;
        GtkWidget  *bc_cs_check;
+       GtkWidget  *bc_color_radio;
        GtkWidget  *bc_color_combo;
+       GtkWidget  *bc_key_radio;
+       GtkWidget  *bc_key_combo;
+       GtkWidget  *bc_key_entry;
 
        GtkWidget  *data_page_vbox;
        GtkWidget  *data_literal_radio;
index 0c202399564956b5cef99c70f082766517f5fe15..def7b1170571d6176538f78c26a9c9f94766e88f 100644 (file)
@@ -51,6 +51,7 @@
 
 static void align_toggle_cb (GtkToggleButton *toggle,
                             glObjectEditor  *editor);
+static void text_radio_toggled_cb              (glObjectEditor        *editor);
 
 
 /*--------------------------------------------------------------------------*/
@@ -78,6 +79,14 @@ gl_object_editor_prepare_text_page (glObjectEditor       *editor)
                glade_xml_get_widget (editor->priv->gui, "text_italic_toggle");
        editor->priv->text_color_combo =
                glade_xml_get_widget (editor->priv->gui, "text_color_combo");
+       editor->priv->text_color_radio =
+               glade_xml_get_widget (editor->priv->gui, "text_color_radio");
+       editor->priv->text_color_key_radio =
+               glade_xml_get_widget (editor->priv->gui, "text_color_key_radio");
+       editor->priv->text_color_key_combo =
+               glade_xml_get_widget (editor->priv->gui, "text_color_key_combo");
+       editor->priv->text_color_key_entry =
+               glade_xml_get_widget (editor->priv->gui, "text_color_key_entry");
        editor->priv->text_left_toggle =
                glade_xml_get_widget (editor->priv->gui, "text_left_toggle");
        editor->priv->text_center_toggle =
@@ -95,6 +104,11 @@ gl_object_editor_prepare_text_page (glObjectEditor       *editor)
                                       family_names);
        gnome_font_family_list_free (family_names);
 
+       /* Modify widgets */
+       gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (editor->priv->text_color_radio), TRUE);
+       gtk_widget_set_sensitive (editor->priv->text_color_combo, TRUE);
+    gtk_widget_set_sensitive (editor->priv->text_color_key_combo, FALSE);
+
        /* Un-hide */
        gtk_widget_show_all (editor->priv->text_page_vbox);
 
@@ -119,6 +133,18 @@ gl_object_editor_prepare_text_page (glObjectEditor       *editor)
                                  "color_changed",
                                  G_CALLBACK (gl_object_editor_changed_cb),
                                  G_OBJECT (editor));
+       g_signal_connect_swapped (G_OBJECT (editor->priv->text_color_key_entry),
+                                 "changed",
+                                 G_CALLBACK (gl_object_editor_changed_cb),
+                                 G_OBJECT (editor));
+       g_signal_connect_swapped (G_OBJECT (editor->priv->text_color_radio),
+                                 "toggled",
+                                 G_CALLBACK (text_radio_toggled_cb),
+                                 G_OBJECT (editor));                             
+       g_signal_connect_swapped (G_OBJECT (editor->priv->text_color_key_radio),
+                                 "toggled",
+                                 G_CALLBACK (text_radio_toggled_cb),
+                                 G_OBJECT (editor));
 
        g_signal_connect (G_OBJECT (editor->priv->text_left_toggle),
                          "toggled",
@@ -446,23 +472,67 @@ gl_object_editor_get_text_alignment (glObjectEditor      *editor)
 /*****************************************************************************/
 void
 gl_object_editor_set_text_color (glObjectEditor      *editor,
-                                guint                text_color)
+                                gboolean             merge_flag,
+                                glColorNode         *text_color_node)
 {
        GdkColor *gdk_color;
+       gint pos;
 
        gl_debug (DEBUG_EDITOR, "START");
 
        g_signal_handlers_block_by_func (G_OBJECT(editor->priv->text_color_combo),
                                         gl_object_editor_changed_cb,
                                         editor);
+       g_signal_handlers_block_by_func (G_OBJECT(editor->priv->text_color_key_entry),
+                                        gl_object_editor_changed_cb,
+                                        editor);
+
+       gl_debug (DEBUG_EDITOR, "color field %s(%d) / %X", text_color_node->key, text_color_node->field_flag, text_color_node->color);
+       
+       gtk_widget_set_sensitive (editor->priv->text_color_key_radio, merge_flag);
+
+       if ( text_color_node->color == GL_COLOR_NONE ) {
 
-        gdk_color = gl_color_to_gdk_color (text_color);
+               color_combo_set_color_to_default (COLOR_COMBO(editor->priv->text_color_combo));
+
+       } else {
+               
+        gdk_color = gl_color_to_gdk_color (text_color_node->color);
         color_combo_set_color (COLOR_COMBO(editor->priv->text_color_combo), gdk_color);
         g_free (gdk_color);
+       }
+       
+       if (!text_color_node->field_flag) {
+               gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON
+                                                 (editor->priv->text_color_radio), TRUE); 
+               gtk_widget_set_sensitive (editor->priv->text_color_combo, TRUE);
+               gl_debug (DEBUG_EDITOR, "color field false 0");
+               gtk_widget_set_sensitive (editor->priv->text_color_key_combo, FALSE);
+               
+       } else {
+               gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON
+                                                 (editor->priv->text_color_key_radio), TRUE); 
+               gtk_widget_set_sensitive (editor->priv->text_color_combo, FALSE);
+               gtk_widget_set_sensitive (editor->priv->text_color_key_combo, TRUE);
+               
+               gtk_editable_delete_text (GTK_EDITABLE (editor->priv->text_color_key_entry), 0, -1);
+               pos = 0;
+               gl_debug (DEBUG_EDITOR, "color field true 1");
+               if (text_color_node->key != NULL ) {
+                       gtk_editable_insert_text (GTK_EDITABLE (editor->priv->text_color_key_entry),
+                                                                       text_color_node->key,
+                                                                       strlen (text_color_node->key),
+                                                                       &pos);
+               }
+               gl_debug (DEBUG_EDITOR, "color field true 2");
+       }
 
        g_signal_handlers_unblock_by_func (G_OBJECT(editor->priv->text_color_combo),
                                           gl_object_editor_changed_cb,
                                           editor);
+       g_signal_handlers_unblock_by_func (G_OBJECT(editor->priv->text_color_key_entry),
+                                          gl_object_editor_changed_cb,
+                                          editor);
 
        gl_debug (DEBUG_EDITOR, "END");
 }
@@ -470,28 +540,38 @@ gl_object_editor_set_text_color (glObjectEditor      *editor,
 /*****************************************************************************/
 /* Query text color.                                                         */
 /*****************************************************************************/
-guint
+glColorNode*
 gl_object_editor_get_text_color (glObjectEditor      *editor)
 {
-       GdkColor  *gdk_color;
-       guint     color;
-       gboolean  is_default;
+       GdkColor    *gdk_color;
+       glColorNode *color_node;
+       gboolean     is_default;
 
        gl_debug (DEBUG_EDITOR, "START");
 
-        gdk_color = color_combo_get_color (COLOR_COMBO(editor->priv->text_color_combo),
+       color_node = gl_color_node_new_default ();
+       
+       if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (editor->priv->text_color_key_radio))) {
+               color_node->field_flag = TRUE;
+               color_node->color = gl_prefs->default_text_color;
+               color_node->key = 
+                       gtk_editable_get_chars (GTK_EDITABLE (editor->priv->text_color_key_entry), 0, -1);
+    } else {
+               color_node->field_flag = FALSE;
+               color_node->key = NULL;
+               gdk_color = color_combo_get_color (COLOR_COMBO(editor->priv->text_color_combo),
                                            &is_default);
-                                                                                
+
         if (is_default) {
-                color = gl_prefs->default_text_color;
+                color_node->color = gl_prefs->default_text_color;
         } else {
-                color = gl_color_from_gdk_color (gdk_color);
+                color_node->color = gl_color_from_gdk_color (gdk_color);
         }
-                                                                                
+       }      
 
        gl_debug (DEBUG_EDITOR, "END");
 
-       return color;
+       return color_node;
 }
 
 
@@ -576,3 +656,25 @@ gboolean    gl_object_editor_get_text_auto_shrink (glObjectEditor      *editor)
        return auto_shrink;
 }
 
+/*--------------------------------------------------------------------------*/
+/* PRIVATE.  color radio callback.                                           */
+/*--------------------------------------------------------------------------*/
+static void
+text_radio_toggled_cb (glObjectEditor *editor)
+{
+    gl_debug (DEBUG_EDITOR, "START");
+       
+       if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (editor->priv->text_color_radio))) {
+                gtk_widget_set_sensitive (editor->priv->text_color_combo, TRUE);
+                gtk_widget_set_sensitive (editor->priv->text_color_key_combo, FALSE);
+    } else {
+                gtk_widget_set_sensitive (editor->priv->text_color_combo, FALSE);
+                gtk_widget_set_sensitive (editor->priv->text_color_key_combo, TRUE);
+               
+       }
+        /* Emit our "changed" signal */
+        g_signal_emit (G_OBJECT (editor), gl_object_editor_signals[CHANGED], 0);
+        gl_debug (DEBUG_EDITOR, "END");
+}
index d35aae7684aa15f2464535abdfe5ecf79a44dd67..19b239cd6e7a4dfd1ea80c0c5bcf1d2484bfa153 100644 (file)
@@ -383,6 +383,18 @@ gl_object_editor_set_key_names (glObjectEditor      *editor,
                                          merge != NULL);
        }
  
+       if (editor->priv->text_color_key_combo) {
+               gtk_widget_set_sensitive (editor->priv->text_color_key_combo, merge != NULL);
+       }
+       if (editor->priv->text_color_key_radio) {
+               gtk_widget_set_sensitive (editor->priv->text_color_key_radio, merge != NULL);
+               if (merge == NULL) {
+                       gtk_toggle_button_set_active (
+                               GTK_TOGGLE_BUTTON(editor->priv->text_color_radio), TRUE);
+               }
+       }       
+       
        if (editor->priv->edit_insert_field_button) {
                gtk_widget_set_sensitive (editor->priv->edit_insert_field_button,
                                          merge != NULL);
@@ -411,7 +423,7 @@ gl_object_editor_set_key_names (glObjectEditor      *editor,
                                GTK_TOGGLE_BUTTON(editor->priv->data_literal_radio), TRUE);
                }
        }
+       
        fixed_flag = editor->priv->data_format_fixed_flag;
        if (editor->priv->data_format_label) {
                gtk_widget_set_sensitive (editor->priv->data_format_label,
@@ -429,7 +441,43 @@ gl_object_editor_set_key_names (glObjectEditor      *editor,
                gtk_widget_set_sensitive (editor->priv->data_digits_spin,
                                          (merge != NULL) && !fixed_flag);
        }
+
+       if (editor->priv->fill_key_combo) {
+               gtk_widget_set_sensitive (editor->priv->fill_key_combo, merge != NULL);
+       }
+       if (editor->priv->fill_key_radio) {
+               gtk_widget_set_sensitive (editor->priv->fill_key_radio, merge != NULL);
+               if (merge == NULL) {
+                       gtk_toggle_button_set_active (
+                               GTK_TOGGLE_BUTTON(editor->priv->fill_color_radio), TRUE);
+               }
+       }
+       
+       if (editor->priv->line_key_combo) {
+               gtk_widget_set_sensitive (editor->priv->line_key_combo, merge != NULL);
+       }
+       if (editor->priv->line_key_radio) {
+               gtk_widget_set_sensitive (editor->priv->line_key_radio, merge != NULL);
+               if (merge == NULL) {
+                       gtk_toggle_button_set_active (
+                               GTK_TOGGLE_BUTTON(editor->priv->line_color_radio), TRUE);
+               }
+       }
+       
+       if (editor->priv->bc_key_combo) {
+               gtk_widget_set_sensitive (editor->priv->bc_key_combo, merge != NULL);
+       }
  
+       if (editor->priv->bc_key_radio) {
+               gtk_widget_set_sensitive (editor->priv->bc_key_radio, merge != NULL);
+               if (merge == NULL) {
+                       gtk_toggle_button_set_active (
+                               GTK_TOGGLE_BUTTON(editor->priv->bc_color_radio), TRUE);
+               }
+       }       
+       
         keys = gl_merge_get_key_list (merge);
         if ( keys != NULL ) {
 
@@ -447,7 +495,27 @@ gl_object_editor_set_key_names (glObjectEditor      *editor,
                if (combo) {
                        gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
                }
+               
+               combo = editor->priv->fill_key_combo;
+               if (combo) {
+                       gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
+               }
 
+               combo = editor->priv->text_color_key_combo;
+               if (combo) {
+                       gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
+               }
+
+               combo = editor->priv->line_key_combo;
+               if (combo) {
+                       gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
+               }
+               
+               combo = editor->priv->bc_key_combo;
+               if (combo) {
+                       gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
+               }
+               
                 gl_merge_free_key_list (&keys);
         } else {
 
@@ -462,12 +530,32 @@ gl_object_editor_set_key_names (glObjectEditor      *editor,
                if (combo) {
                        gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
                }
-
+               
                combo = editor->priv->data_key_combo;
                if (combo) {
                        gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
                }
+               
+               combo = editor->priv->fill_key_combo;
+               if (combo) {
+                       gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
+               }
+               
+               combo = editor->priv->text_color_key_combo;
+               if (combo) {
+                       gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
+               }
 
+               combo = editor->priv->line_key_combo;
+               if (combo) {
+                       gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
+               }
+               
+               combo = editor->priv->bc_key_combo;
+               if (combo) {
+                       gtk_combo_set_popdown_strings (GTK_COMBO (combo), keys);
+               }
+               
                 g_list_free (keys);
         }
  
@@ -565,4 +653,3 @@ prefs_changed_cb (glObjectEditor *editor)
 
        gl_debug (DEBUG_EDITOR, "END");
 }
-
index 3cae2e908c2cd033474ddc919188d4b3bd56fab1..fa9aa119b4d742b3badc51bb90a43c6a1d478f93 100644 (file)
@@ -26,6 +26,7 @@
 #include "text-node.h"
 #include "merge.h"
 #include "bc.h"
+#include "color.h"
 #include <gtk/gtkenums.h>
 #include <libgnomeprint/gnome-font.h>
 
@@ -143,18 +144,20 @@ void        gl_object_editor_get_lsize            (glObjectEditor      *editor,
  * Fill Page
  */
 void        gl_object_editor_set_fill_color       (glObjectEditor      *editor,
-                                                  guint                color);
+                                                  gboolean             merge_flag,
+                                                  glColorNode         *color_node);
 
-guint       gl_object_editor_get_fill_color       (glObjectEditor      *editor);
+glColorNode* gl_object_editor_get_fill_color      (glObjectEditor      *editor);
 
 
 /*
  * Line/Outline Page
  */
 void        gl_object_editor_set_line_color       (glObjectEditor      *editor,
-                                                  guint                color);
+                                                  gboolean             merge_flag,
+                                                  glColorNode         *color_node);
 
-guint       gl_object_editor_get_line_color       (glObjectEditor      *editor);
+glColorNode* gl_object_editor_get_line_color      (glObjectEditor      *editor);
 
 void        gl_object_editor_set_line_width       (glObjectEditor      *editor,
                                                   gdouble              width);
@@ -201,14 +204,15 @@ void        gl_object_editor_set_text_alignment   (glObjectEditor      *editor,
 GtkJustification gl_object_editor_get_text_alignment (glObjectEditor      *editor);
 
 void        gl_object_editor_set_text_line_spacing (glObjectEditor      *editor,
-                                                  gdouble              text_line_spacing);
+                                                  gdouble               text_line_spacing);
 
 gdouble     gl_object_editor_get_text_line_spacing (glObjectEditor      *editor);
 
-void        gl_object_editor_set_text_color       (glObjectEditor      *editor,
-                                                  guint                text_color);
+void        gl_object_editor_set_text_color       (glObjectEditor       *editor,
+                                                  gboolean              merge_flag,
+                                                  glColorNode          *text_color_node);
 
-guint       gl_object_editor_get_text_color       (glObjectEditor      *editor);
+glColorNode* gl_object_editor_get_text_color      (glObjectEditor      *editor);
 
 void        gl_object_editor_set_text_auto_shrink (glObjectEditor      *editor,
                                                   gboolean             auto_shrink);
@@ -238,9 +242,10 @@ void        gl_object_editor_get_bc_style         (glObjectEditor      *editor,
                                                   guint               *format_digits);
 
 void        gl_object_editor_set_bc_color         (glObjectEditor      *editor,
-                                                  guint                text_color);
+                                                  gboolean             merge_flag,
+                                                  glColorNode         *color_node);
 
-guint       gl_object_editor_get_bc_color         (glObjectEditor      *editor);
+glColorNode* gl_object_editor_get_bc_color        (glObjectEditor      *editor);
 
 
 /*
index bb141503da3cf5a4b384c2ad0bb781817d8fd896..fe2dd6bdbcc48b00950cc134fb4b3051ce5e6176 100644 (file)
@@ -58,7 +58,6 @@
 #define PREF_MAIN_TOOLBAR_VIEW_TOOLTIPS     "/main-toolbar-view-tooltips"
 
 #define PREF_DRAWING_TOOLBAR_VISIBLE        "/drawing-toolbar-visible"
-#define PREF_DRAWING_TOOLBAR_BUTTONS_STYLE  "/drawing-toolbar-buttons-style"
 #define PREF_DRAWING_TOOLBAR_VIEW_TOOLTIPS  "/drawing-toolbar-view-tooltips"
 
 #define PREF_PROPERTY_TOOLBAR_VISIBLE        "/property-toolbar-visible"
@@ -349,11 +348,6 @@ gl_prefs_model_save_settings (glPrefsModel *prefs_model)
                               prefs_model->drawing_toolbar_visible,
                               NULL);
 
-       gconf_client_set_int (prefs_model->gconf_client,
-                             BASE_KEY PREF_DRAWING_TOOLBAR_BUTTONS_STYLE,
-                             prefs_model->drawing_toolbar_buttons_style,
-                             NULL);
-
        gconf_client_set_bool (prefs_model->gconf_client,
                               BASE_KEY PREF_DRAWING_TOOLBAR_VIEW_TOOLTIPS,
                               prefs_model->drawing_toolbar_view_tooltips,
@@ -498,11 +492,6 @@ gl_prefs_model_load_settings (glPrefsModel *prefs_model)
                          BASE_KEY PREF_DRAWING_TOOLBAR_VISIBLE,
                          TRUE);
 
-       prefs_model->drawing_toolbar_buttons_style =
-               get_int (prefs_model->gconf_client,
-                        BASE_KEY PREF_DRAWING_TOOLBAR_BUTTONS_STYLE,
-                        GL_TOOLBAR_SYSTEM);
-
        prefs_model->drawing_toolbar_view_tooltips =
                get_bool (prefs_model->gconf_client,
                          BASE_KEY PREF_DRAWING_TOOLBAR_VIEW_TOOLTIPS,
index fc2f93f6dd78b848547d68ba0fa4fb87f56b7a57..cd113122ddad41ae7debd6f98bd21abc6bd3ab24 100644 (file)
@@ -89,7 +89,6 @@ struct _glPrefsModel {
 
        /* User Interface/Drawing Toolbar */
        gboolean          drawing_toolbar_visible;
-       glToolbarSetting  drawing_toolbar_buttons_style; 
        gboolean          drawing_toolbar_view_tooltips;
 
        /* User Interface/Property Toolbar */
index a7d29ac857ab48f15619815e90ef73f63a584248..c691482216e382ab5180904c903ea67e2ccf15bd 100644 (file)
@@ -108,13 +108,16 @@ static void       draw_text_object            (PrintInfo        *pi,
                                               glMergeRecord    *record);
 
 static void       draw_box_object             (PrintInfo        *pi,
-                                              glLabelBox       *object);
+                                              glLabelBox       *object,
+                                                  glMergeRecord  *record);
 
 static void       draw_line_object            (PrintInfo        *pi,
-                                              glLabelLine      *object);
+                                              glLabelLine      *object,
+                                                  glMergeRecord  *record);                                                
 
 static void       draw_ellipse_object         (PrintInfo        *pi,
-                                              glLabelEllipse   *object);
+                                              glLabelEllipse   *object,
+                                                  glMergeRecord  *record);
 
 static void       draw_image_object           (PrintInfo        *pi,
                                               glLabelImage     *object,
@@ -368,6 +371,7 @@ gl_print_batch (GnomePrintJob    *job,
                glLabel          *label,
                gint              n_sheets,
                gint              n_copies,
+               gint              first,
                glPrintFlags     *flags)
 {
        glMerge                   *merge;
@@ -384,9 +388,9 @@ gl_print_batch (GnomePrintJob    *job,
        if ( merge == NULL ) {
                n_per_page = gl_template_get_n_labels(label_type);
 
-               gl_print_simple (job, label, n_sheets, 1, n_per_page, flags);
+               gl_print_simple (job, label, n_sheets, first, n_per_page, flags);
        } else {
-               gl_print_merge_collated (job, label, n_copies, 1, flags);
+               gl_print_merge_collated (job, label, n_copies, first, flags);
        }
        gl_template_free (template);
 
@@ -697,11 +701,11 @@ draw_object (PrintInfo     *pi,
        if (GL_IS_LABEL_TEXT(object)) {
                draw_text_object (pi, GL_LABEL_TEXT(object), record);
        } else if (GL_IS_LABEL_BOX(object)) {
-               draw_box_object (pi, GL_LABEL_BOX(object));
+               draw_box_object (pi, GL_LABEL_BOX(object), record);
        } else if (GL_IS_LABEL_LINE(object)) {
-               draw_line_object (pi, GL_LABEL_LINE(object));
+               draw_line_object (pi, GL_LABEL_LINE(object), record);
        } else if (GL_IS_LABEL_ELLIPSE(object)) {
-               draw_ellipse_object (pi, GL_LABEL_ELLIPSE(object));
+               draw_ellipse_object (pi, GL_LABEL_ELLIPSE(object), record);
        } else if (GL_IS_LABEL_IMAGE(object)) {
                draw_image_object (pi, GL_LABEL_IMAGE(object), record);
        } else if (GL_IS_LABEL_BARCODE(object)) {
@@ -732,6 +736,7 @@ draw_text_object (PrintInfo     *pi,
        GnomeFontWeight  font_weight;
        gboolean         font_italic_flag;
        guint            color;
+       glColorNode     *color_node;
        GtkJustification just;
        gboolean         auto_shrink;
        GnomeGlyphList  *glyphlist;
@@ -748,7 +753,11 @@ draw_text_object (PrintInfo     *pi,
        font_size = gl_label_object_get_font_size (GL_LABEL_OBJECT(object));
        font_weight = gl_label_object_get_font_weight (GL_LABEL_OBJECT(object));
        font_italic_flag = gl_label_object_get_font_italic_flag (GL_LABEL_OBJECT(object));
-       color = gl_label_object_get_text_color (GL_LABEL_OBJECT(object));
+
+       color_node = gl_label_object_get_text_color (GL_LABEL_OBJECT(object));
+       color = gl_color_node_expand (color_node, record);
+       gl_color_node_free (&color_node);
+       
        just = gl_label_object_get_text_alignment (GL_LABEL_OBJECT(object));
        text_line_spacing =
                gl_label_object_get_text_line_spacing (GL_LABEL_OBJECT(object));
@@ -868,19 +877,28 @@ draw_text_object (PrintInfo     *pi,
 /*---------------------------------------------------------------------------*/
 static void
 draw_box_object (PrintInfo  *pi,
-                glLabelBox *object)
+                glLabelBox *object,
+                glMergeRecord  *record)
 {
-       gdouble w, h;
-       gdouble line_width;
-       guint line_color, fill_color;
+       gdouble      w, h;
+       gdouble      line_width;
+       guint        line_color;
+       glColorNode *line_color_node;
+       glColorNode *fill_color_node;
+       guint        fill_color;
 
        gl_debug (DEBUG_PRINT, "START");
 
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
        line_width = gl_label_object_get_line_width (GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
-       fill_color = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
-
+       
+       line_color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       fill_color_node = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
+       line_color = gl_color_node_expand (line_color_node, record);
+       fill_color = gl_color_node_expand (fill_color_node, record);
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
+       
        /* Paint fill color */
        create_rectangle_path (pi->pc, 0.0, 0.0, w, h);
        gnome_print_setrgbcolor (pi->pc,
@@ -908,17 +926,22 @@ draw_box_object (PrintInfo  *pi,
 /*---------------------------------------------------------------------------*/
 static void
 draw_line_object (PrintInfo   *pi,
-                 glLabelLine *object)
+                 glLabelLine *object,
+                 glMergeRecord  *record)
 {
-       gdouble w, h;
-       gdouble line_width;
-       guint line_color;
+       gdouble      w, h;
+       gdouble      line_width;
+       guint        line_color;
+       glColorNode *line_color_node;
 
        gl_debug (DEBUG_PRINT, "START");
 
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
        line_width = gl_label_object_get_line_width (GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       
+       line_color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       line_color = gl_color_node_expand (line_color_node, record);
+       gl_color_node_free (&line_color_node);
 
        gnome_print_moveto (pi->pc, 0.0, 0.0);
        gnome_print_lineto (pi->pc, w, h);
@@ -938,18 +961,27 @@ draw_line_object (PrintInfo   *pi,
 /*---------------------------------------------------------------------------*/
 static void
 draw_ellipse_object (PrintInfo      *pi,
-                    glLabelEllipse *object)
+                    glLabelEllipse *object,
+                     glMergeRecord  *record)
 {
-       gdouble x0, y0, rx, ry, w, h;
-       gdouble line_width;
-       guint line_color, fill_color;
+       gdouble      x0, y0, rx, ry, w, h;
+       gdouble      line_width;
+       glColorNode *line_color_node;
+       glColorNode *fill_color_node;
+       guint        line_color;
+       guint        fill_color;
 
        gl_debug (DEBUG_PRINT, "START");
 
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
        line_width = gl_label_object_get_line_width (GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
-       fill_color = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
+       
+       line_color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       fill_color_node = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
+       line_color = gl_color_node_expand (line_color_node, record);
+       fill_color = gl_color_node_expand (fill_color_node, record);
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
 
        rx = w / 2.0;
        ry = h / 2.0;
@@ -1048,6 +1080,7 @@ draw_barcode_object (PrintInfo      *pi,
        gboolean            text_flag;
        gboolean            checksum_flag;
        guint               color;
+       glColorNode        *color_node;
        guint               format_digits;
        gdouble             w, h;
 
@@ -1056,7 +1089,11 @@ draw_barcode_object (PrintInfo      *pi,
        text_node = gl_label_barcode_get_data (object);
        gl_label_barcode_get_props (object,
                                    &id, &text_flag, &checksum_flag, &format_digits);
-       color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+                                       
+       color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       color = gl_color_node_expand (color_node, record);
+       gl_color_node_free (&color_node);
+       
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
 
        text = gl_text_node_expand (text_node, record);
index 07c77bf804e093fa15f23ed5307a9ccc1af504de..6e9b583ced27a2313dacbd4560d736fc2a439fa2 100644 (file)
@@ -57,7 +57,8 @@ void gl_print_merge_uncollated (GnomePrintJob    *job,
 void gl_print_batch            (GnomePrintJob    *job,
                                glLabel          *label,
                                gint              n_sheets,
-                               gint              n_bcopies,
+                               gint              n_copies,
+                               gint              first,
                                glPrintFlags     *flags);
 
 G_END_DECLS
index 62be7ee64b02aa2416c3e1e4361f90f127788bb2..83e18d3ccd8ba682010845ede679fe1d55677a0a 100644 (file)
 
 #include "splash.h"
 
-#include "debug.h"
-
 #define SPLASH_PIXMAP gnome_program_locate_file (NULL,\
                                                 GNOME_FILE_DOMAIN_APP_PIXMAP,\
-                                                "glabels/glabels-logo.png",\
+                                                "glabels/glabels-splash.png",\
                                                 FALSE, NULL)
 
 #define SPLASH_TIMEOUT 2000
index d24be891a2f5f50fa37823a2036cfcc675002520..18b6d78f6fd6f248e41b4607e57c7de37d829b41 100644 (file)
@@ -40,7 +40,7 @@
 /*========================================================*/
 #define ICON_PIXMAP gnome_program_locate_file (NULL,\
                                                GNOME_FILE_DOMAIN_APP_PIXMAP,\
-                                               "glabels/glabels-icon.png",\
+                                               "glabels.png",\
                                                FALSE, NULL)
 
 #define EX_RECT_IMAGE gnome_program_locate_file (NULL,\
index 603c033f0db8604f9155de72a04c02187d9681ca..17433bf15be1224ddf773ac7c7b802f2b66b9e5c 100644 (file)
@@ -511,6 +511,7 @@ update_text_properties (glView *view,
        gchar *selection_font_family, *font_family;
        gdouble selection_font_size, font_size;
        guint selection_text_color, text_color;
+       glColorNode *text_color_node;
        gboolean selection_is_italic, is_italic;
        gboolean selection_is_bold, is_bold;
        GtkJustification selection_justification, justification;
@@ -550,7 +551,17 @@ update_text_properties (glView *view,
                }       
 
                font_size = gl_label_object_get_font_size (object);
-               text_color = gl_label_object_get_text_color (object);
+               
+               text_color_node = gl_label_object_get_text_color (object);
+               if (text_color_node->field_flag) {
+                       /* If a merge field is set we use the default color for merged color*/
+                       text_color = GL_COLOR_MERGE_DEFAULT;
+                       
+               } else {
+                       text_color = text_color_node->color;
+               }
+               gl_color_node_free (&text_color_node);
+               
                is_italic = gl_label_object_get_font_italic_flag (object);
                is_bold = gl_label_object_get_font_weight (object) == GNOME_FONT_BOLD;
                justification = gl_label_object_get_text_alignment (object);
@@ -640,6 +651,7 @@ update_fill_color (glView *view,
        glLabelObject *object;
        guint selection_fill_color, fill_color;
        GdkColor *gdk_color;
+       glColorNode *fill_color_node;
 
        can = gl_view_can_selection_fill (view);
        gl_ui_util_set_verb_list_sensitive (property_bar->ui_component,
@@ -657,7 +669,15 @@ update_fill_color (glView *view,
                if (!gl_label_object_can_fill (object)) 
                        continue;
 
-               fill_color = gl_label_object_get_fill_color (object);
+               fill_color_node = gl_label_object_get_fill_color (object);
+               if (fill_color_node->field_flag) {
+                       /* If a merge field is set we use the default color for merged color*/
+                       fill_color = GL_COLOR_FILL_MERGE_DEFAULT;
+                       
+               } else {
+                       fill_color = fill_color_node->color;
+               }
+               gl_color_node_free (&fill_color_node);
 
                if (is_first_object) {
                        selection_fill_color = fill_color;
@@ -686,6 +706,7 @@ update_line_color (glView *view,
        GList *p;
        glLabelObject *object;
        guint selection_line_color, line_color;
+       glColorNode *line_color_node;
        GdkColor *gdk_color;
 
        can = gl_view_can_selection_line_color (view);
@@ -704,7 +725,15 @@ update_line_color (glView *view,
                if (!gl_label_object_can_line_color (object)) 
                        continue;
 
-               line_color = gl_label_object_get_line_color (object);
+               line_color_node = gl_label_object_get_line_color (object);
+               if (line_color_node->field_flag) {
+                       /* If a merge field is set we use the default color for merged color*/
+                       line_color = GL_COLOR_MERGE_DEFAULT;
+                       
+               } else {
+                       line_color = line_color_node->color;
+               }
+               gl_color_node_free (&line_color_node);
 
                if (is_first_object) {
                        selection_line_color = line_color;
@@ -880,7 +909,7 @@ text_color_changed_cb (ColorCombo           *cc,
                       gboolean              is_default,
                       glUIPropertyBar      *property_bar)
 {
-       guint text_color;
+       glColorNode *text_color_node;
 
        if (property_bar->stop_signals)
                return;
@@ -893,27 +922,30 @@ text_color_changed_cb (ColorCombo           *cc,
                                         selection_changed_cb,
                                         property_bar);
 
-       text_color = gl_color_from_gdk_color (gdk_color);
-
+       text_color_node = gl_color_node_new_default ();
+       text_color_node->color = gl_color_from_gdk_color (gdk_color);
+       
        gl_debug (DEBUG_PROPERTY_BAR, "Color=%08x, Custom=%d, By_User=%d, Is_default=%d",
-                 text_color, custom, by_user, is_default);
+                 text_color_node->color, custom, by_user, is_default);
 
        if (is_default) {
-
+               text_color_node->color = gl_prefs->default_text_color;
                gl_view_set_selection_text_color (property_bar->view,
-                                                 gl_prefs->default_text_color);
+                                                 text_color_node);
                gl_view_set_default_text_color   (property_bar->view,
                                                  gl_prefs->default_text_color);
 
        } else {
 
                gl_view_set_selection_text_color (property_bar->view,
-                                                 text_color);
+                                                 text_color_node);
                gl_view_set_default_text_color   (property_bar->view,
-                                                 text_color);
+                                                 text_color_node->color);
 
        }
 
+       gl_color_node_free (&text_color_node);
+       
        g_signal_handlers_unblock_by_func (G_OBJECT(property_bar->view->label),
                                           selection_changed_cb,
                                           property_bar);
@@ -932,7 +964,7 @@ fill_color_changed_cb (ColorCombo           *cc,
                       gboolean              is_default,
                       glUIPropertyBar      *property_bar)
 {
-       guint fill_color;
+       glColorNode *fill_color_node;
 
        if (property_bar->stop_signals)
                return;
@@ -945,27 +977,31 @@ fill_color_changed_cb (ColorCombo           *cc,
                                         selection_changed_cb,
                                         property_bar);
 
-       fill_color = gl_color_from_gdk_color (gdk_color);
+       fill_color_node = gl_color_node_new_default ();
+
+       fill_color_node->color = gl_color_from_gdk_color (gdk_color);
 
        gl_debug (DEBUG_PROPERTY_BAR, "Color=%08x, Custom=%d, By_User=%d, Is_default=%d",
-                 fill_color, custom, by_user, is_default);
+                 fill_color_node->color, custom, by_user, is_default);
 
        if (is_default) {
 
+               fill_color_node->color = GL_COLOR_NONE;
                gl_view_set_selection_fill_color (property_bar->view,
-                                                 GL_COLOR_NONE);
+                                                 fill_color_node);
                gl_view_set_default_fill_color   (property_bar->view,
-                                                 GL_COLOR_NONE);
+                                                 fill_color_node->color);
 
        } else {
 
                gl_view_set_selection_fill_color (property_bar->view,
-                                                 fill_color);
+                                                 fill_color_node);
                gl_view_set_default_fill_color   (property_bar->view,
-                                                 fill_color);
+                                                 fill_color_node->color);
 
        }
-
+       gl_color_node_free (&fill_color_node);
+       
        g_signal_handlers_unblock_by_func (G_OBJECT(property_bar->view->label),
                                           selection_changed_cb,
                                           property_bar);
@@ -984,7 +1020,7 @@ line_color_changed_cb (ColorCombo           *cc,
                       gboolean              is_default,
                       glUIPropertyBar      *property_bar)
 {
-       guint line_color;
+       glColorNode *line_color_node;
 
        if (property_bar->stop_signals)
                return;
@@ -997,26 +1033,28 @@ line_color_changed_cb (ColorCombo           *cc,
                                         selection_changed_cb,
                                         property_bar);
 
-       line_color = gl_color_from_gdk_color (gdk_color);
+       line_color_node = gl_color_node_new_default ();
+       line_color_node->color = gl_color_from_gdk_color (gdk_color);
 
        gl_debug (DEBUG_PROPERTY_BAR, "Color=%08x, Custom=%d, By_User=%d, Is_default=%d",
-                 line_color, custom, by_user, is_default);
+                 line_color_node->color, custom, by_user, is_default);
 
        if (is_default) {
-
+               line_color_node->color = GL_COLOR_NONE;
                gl_view_set_selection_line_color (property_bar->view,
-                                                 GL_COLOR_NONE);
+                                                 line_color_node);
                gl_view_set_default_line_color   (property_bar->view,
-                                                 GL_COLOR_NONE);
+                                                 line_color_node->color);
 
        } else {
 
                gl_view_set_selection_line_color (property_bar->view,
-                                                 line_color);
+                                                 line_color_node);
                gl_view_set_default_line_color   (property_bar->view,
-                                                 line_color);
+                                                 line_color_node->color);
 
        }
+       gl_color_node_free (&line_color_node);
 
        g_signal_handlers_unblock_by_func (G_OBJECT(property_bar->view->label),
                                           selection_changed_cb,
@@ -1164,4 +1202,3 @@ null_cmd (BonoboUIComponent           *ui_component,
          const gchar                 *verbname)
 {
 }
-
index 4f37d78f8192bd0a0b3ede5f23764526b51fd0fe..184840a671c4a1ff1b977242555e0d34c32c6903 100644 (file)
@@ -601,33 +601,6 @@ view_menu_item_toggled_cb (BonoboUIComponent           *ui_component,
                return;
        }
 
-       if (s && (strcmp (path, "DrawingToolbarSystem") == 0))
-       {               
-               gl_prefs->drawing_toolbar_buttons_style = GL_TOOLBAR_SYSTEM;
-               set_app_drawing_toolbar_style (ui_component);
-               gl_prefs_model_save_settings (gl_prefs);
-
-               return;
-       }
-
-       if (s && (strcmp (path, "DrawingToolbarIcon") == 0))
-       {               
-               gl_prefs->drawing_toolbar_buttons_style = GL_TOOLBAR_ICONS;
-               set_app_drawing_toolbar_style (ui_component);
-               gl_prefs_model_save_settings (gl_prefs);
-
-               return;
-       }
-
-       if (s && (strcmp (path, "DrawingToolbarIconText") == 0))
-       {               
-               gl_prefs->drawing_toolbar_buttons_style = GL_TOOLBAR_ICONS_AND_TEXT;
-               set_app_drawing_toolbar_style (ui_component);
-               gl_prefs_model_save_settings (gl_prefs);
-
-               return;
-       }
-
        if (strcmp (path, "DrawingToolbarTooltips") == 0)
        {
                gl_prefs->drawing_toolbar_view_tooltips = s;
@@ -826,21 +799,6 @@ set_app_drawing_toolbar_style (BonoboUIComponent *ui_component)
                                       "/commands/DrawingToolbarTooltips",
                                       gl_prefs->drawing_toolbar_visible);
 
-       gl_ui_util_set_verb_state (
-               ui_component, 
-               "/commands/DrawingToolbarSystem",
-               gl_prefs->drawing_toolbar_buttons_style == GL_TOOLBAR_SYSTEM);
-
-       gl_ui_util_set_verb_state (
-               ui_component, 
-               "/commands/DrawingToolbarIcon",
-               gl_prefs->drawing_toolbar_buttons_style == GL_TOOLBAR_ICONS);
-
-       gl_ui_util_set_verb_state (
-               ui_component, 
-               "/commands/DrawingToolbarIconText",
-               gl_prefs->drawing_toolbar_buttons_style == GL_TOOLBAR_ICONS_AND_TEXT);
-
        gl_ui_util_set_verb_state (ui_component, 
                        "/commands/DrawingToolbarTooltips",
                        gl_prefs->drawing_toolbar_view_tooltips);
@@ -852,49 +810,6 @@ set_app_drawing_toolbar_style (BonoboUIComponent *ui_component)
                "tips", gl_prefs->drawing_toolbar_view_tooltips ? "1" : "0",
                NULL);
        
-       switch (gl_prefs->drawing_toolbar_buttons_style)
-       {
-               case GL_TOOLBAR_SYSTEM:
-                                               
-                       client = gconf_client_get_default ();
-                       if (client == NULL) 
-                               goto error;
-
-                       labels = gconf_client_get_bool (client, 
-                                       "/desktop/gnome/interface/toolbar-labels", NULL);
-
-                       g_object_unref (G_OBJECT (client));
-                       
-                       if (labels)
-                       {                       
-                               bonobo_ui_component_set_prop (
-                                       ui_component, "/DrawingToolbar", "look", "both", NULL);
-                       
-                       }
-                       else
-                       {
-                               bonobo_ui_component_set_prop (
-                                       ui_component, "/DrawingToolbar", "look", "icons", NULL);
-                       }
-       
-                       break;
-                       
-               case GL_TOOLBAR_ICONS:
-                       bonobo_ui_component_set_prop (
-                               ui_component, "/DrawingToolbar", "look", "icon", NULL);
-                       
-                       break;
-                       
-               case GL_TOOLBAR_ICONS_AND_TEXT:
-                       bonobo_ui_component_set_prop (
-                               ui_component, "/DrawingToolbar", "look", "both", NULL);
-                       
-                       break;
-               default:
-                       goto error;
-                       break;
-       }
-       
        bonobo_ui_component_set_prop (
                        ui_component, "/DrawingToolbar",
                        "hidden", gl_prefs->drawing_toolbar_visible ? "0":"1", NULL);
index 761dc99aa93a42c323c918288636e1810de639c9..61cb043fe534b99357477b2610e627e7be6e3271 100644 (file)
@@ -19,6 +19,7 @@
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  */
+#include <config.h>
 
 #include <glib.h>
 
@@ -261,7 +262,7 @@ update_object_from_editor_cb (glObjectEditor *editor,
        glTextNode        *text_node;
        gchar             *id;
        gboolean           text_flag, cs_flag;
-       guint              color;
+       glColorNode       *color_node;
        guint              format_digits;
 
        gl_debug (DEBUG_VIEW, "START");
@@ -285,10 +286,11 @@ update_object_from_editor_cb (glObjectEditor *editor,
        gl_text_node_free (&text_node);
 
        gl_object_editor_get_bc_style (editor, &id, &text_flag, &cs_flag, &format_digits);
-       color = gl_object_editor_get_bc_color (editor);
+       color_node = gl_object_editor_get_bc_color (editor);
        gl_label_barcode_set_props (GL_LABEL_BARCODE(object),
                                    id, text_flag, cs_flag, format_digits);
-       gl_label_object_set_line_color (object, color);
+       gl_label_object_set_line_color (object, color_node);
+       gl_color_node_free (&color_node);
        g_free (id);
 
        g_signal_handlers_unblock_by_func (G_OBJECT(object),
@@ -312,7 +314,7 @@ update_editor_from_object_cb (glLabelObject  *object,
        glTextNode        *text_node;
        gchar             *id;
        gboolean           text_flag, cs_flag;
-       guint              color;
+       glColorNode       *color_node;
        glMerge           *merge;
        guint              format_digits;
 
@@ -320,16 +322,18 @@ update_editor_from_object_cb (glLabelObject  *object,
 
        gl_label_object_get_size (object, &w, &h);
        gl_object_editor_set_size (editor, w, h);
+       
+       merge = gl_label_get_merge (GL_LABEL(object->parent));
 
        gl_label_barcode_get_props (GL_LABEL_BARCODE(object),
                                    &id, &text_flag, &cs_flag, &format_digits);
-       color = gl_label_object_get_line_color (object);
+       color_node = gl_label_object_get_line_color (object);
        gl_object_editor_set_bc_style (editor, id, text_flag, cs_flag, format_digits);
-       gl_object_editor_set_bc_color (editor, color);
+       gl_object_editor_set_bc_color (editor, (merge != NULL), color_node);
+       gl_color_node_free (&color_node);
        g_free (id);
 
        text_node = gl_label_barcode_get_data (GL_LABEL_BARCODE(object));
-       merge = gl_label_get_merge (GL_LABEL(object->parent));
        gl_object_editor_set_data (editor, (merge != NULL), text_node);
        gl_text_node_free (&text_node);
 
@@ -427,6 +431,7 @@ gl_view_barcode_create_event_handler (GnomeCanvas *canvas,
        static GObject      *object;
        gdouble             x, y;
        glTextNode          *text_node;
+       glColorNode         *color_node;
 
        gl_debug (DEBUG_VIEW, "");
 
@@ -436,6 +441,7 @@ gl_view_barcode_create_event_handler (GnomeCanvas *canvas,
                gl_debug (DEBUG_VIEW, "BUTTON_PRESS");
                switch (event->button.button) {
                case 1:
+                       color_node = gl_color_node_new_default ();
                        dragging = TRUE;
                        gnome_canvas_item_grab (canvas->root,
                                                GDK_POINTER_MOTION_MASK |
@@ -456,14 +462,16 @@ gl_view_barcode_create_event_handler (GnomeCanvas *canvas,
                                                    FALSE,
                                                    TRUE,
                                                    0);
-                       gl_label_object_set_line_color (GL_LABEL_OBJECT(object),
-                                                   gl_color_set_opacity (
+                       color_node->color = gl_color_set_opacity (
                                                      gl_view_get_default_line_color(view),
-                                                      0.5));
+                                                      0.5);
+                       gl_label_object_set_line_color (GL_LABEL_OBJECT(object),
+                                                       color_node);
                        view_barcode = gl_view_barcode_new (GL_LABEL_BARCODE(object),
                                                            view);
                        x0 = x;
                        y0 = y;
+                       gl_color_node_free (&color_node);
                        return TRUE;
 
                default:
@@ -474,6 +482,7 @@ gl_view_barcode_create_event_handler (GnomeCanvas *canvas,
                gl_debug (DEBUG_VIEW, "BUTTON_RELEASE");
                switch (event->button.button) {
                case 1:
+                       color_node = gl_color_node_new_default ();
                        dragging = FALSE;
                        gnome_canvas_item_ungrab (canvas->root, event->button.time);
                        gnome_canvas_window_to_world (canvas,
@@ -486,11 +495,13 @@ gl_view_barcode_create_event_handler (GnomeCanvas *canvas,
                                                    FALSE,
                                                    TRUE,
                                                    0);
+                       color_node->color = gl_view_get_default_line_color(view);
                        gl_label_object_set_line_color (GL_LABEL_OBJECT(object),
-                                                       gl_view_get_default_line_color(view));
+                                                       color_node);
                        gl_view_unselect_all (view);
                        gl_view_object_select (GL_VIEW_OBJECT(view_barcode));
                        gl_view_arrow_mode (view);
+                       gl_color_node_free (&color_node);
                        return TRUE;
 
                default:
@@ -528,7 +539,7 @@ draw_barcode (glViewBarcode *view_barcode)
        gchar *id;
        gboolean text_flag;
        gboolean checksum_flag;
-       guint color;
+       glColorNode *color_node;
        gdouble w, h;
        glBarcodeLine *line;
        glBarcodeChar *bchar;
@@ -548,7 +559,11 @@ draw_barcode (glViewBarcode *view_barcode)
        object = gl_view_object_get_object (GL_VIEW_OBJECT(view_barcode));
        gl_label_barcode_get_props (GL_LABEL_BARCODE(object),
                                    &id, &text_flag, &checksum_flag, &format_digits);
-       color = gl_label_object_get_line_color (object);
+       color_node = gl_label_object_get_line_color (object);
+       if (color_node->field_flag)
+       {
+               color_node->color = GL_COLOR_MERGE_DEFAULT;
+       }
        gl_label_object_get_size (object, &w, &h);
        text_node = gl_label_barcode_get_data(GL_LABEL_BARCODE(object));
        if (text_node->field_flag) {
@@ -578,7 +593,7 @@ draw_barcode (glViewBarcode *view_barcode)
 
                cstring = _("Invalid barcode data");
                glyphlist = gnome_glyphlist_from_text_sized_dumb (font,
-                                                                 color,
+                                                                 color_node->color,
                                                                  0.0, 0.0,
                                                                  cstring,
                                                                  strlen
@@ -609,7 +624,7 @@ draw_barcode (glViewBarcode *view_barcode)
                                                        gnome_canvas_line_get_type (),
                                                        "points", points,
                                                        "width_units", line->width,
-                                                       "fill_color_rgba", color,
+                                                       "fill_color_rgba", color_node->color,
                                                        NULL);
                        view_barcode->private->item_list =
                                g_list_prepend (view_barcode->private->item_list, item);
@@ -624,7 +639,7 @@ draw_barcode (glViewBarcode *view_barcode)
                                                       GL_BARCODE_FONT_WEIGHT,
                                                       FALSE, bchar->fsize);
                        glyphlist = gnome_glyphlist_from_text_sized_dumb (font,
-                                                                         color,
+                                                                         color_node->color,
                                                                          0.0,
                                                                          0.0,
                                                                          &
@@ -651,10 +666,10 @@ draw_barcode (glViewBarcode *view_barcode)
        }
 
        /* clean up */
+       gl_color_node_free (&color_node);
        gl_barcode_free (&gbc);
        g_free (digits);
        g_free (id);
 
        gl_debug (DEBUG_VIEW, "END");
 }
-
index 5095a357fd290c58fe0a73a454bbc56f76763aef..d61ec0327e7be856611992f4bd4310eba2e810de 100644 (file)
@@ -19,6 +19,7 @@
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  */
+#include <config.h>
 
 #include <glib.h>
 
@@ -162,10 +163,11 @@ glViewObject *
 gl_view_box_new (glLabelBox *object,
                 glView     *view)
 {
-       glViewBox          *view_box;
+       glViewBox         *view_box;
        gdouble            line_width;
-       guint              line_color, fill_color;
+       glColorNode       *line_color_node;
        gdouble            w, h;
+       glColorNode       *fill_color_node;
 
        gl_debug (DEBUG_VIEW, "START");
        g_return_if_fail (object && GL_IS_LABEL_BOX (object));
@@ -181,8 +183,16 @@ gl_view_box_new (glLabelBox *object,
        /* Query properties of object. */
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
        line_width = gl_label_object_get_line_width(GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
-       fill_color = gl_label_object_get_fill_color(GL_LABEL_OBJECT(object));
+       line_color_node = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
+       if (line_color_node->field_flag)
+       {
+               line_color_node->color = GL_COLOR_MERGE_DEFAULT;
+       }
+       fill_color_node = gl_label_object_get_fill_color(GL_LABEL_OBJECT(object));
+       if (fill_color_node->field_flag)
+       {
+               fill_color_node->color = GL_COLOR_FILL_MERGE_DEFAULT;
+       }
 
        /* Create analogous canvas item. */
        view_box->private->item =
@@ -193,10 +203,13 @@ gl_view_box_new (glLabelBox *object,
                                         "x2", w + DELTA,
                                         "y2", h + DELTA,
                                         "width_units", line_width,
-                                        "outline_color_rgba", line_color,
-                                        "fill_color_rgba", fill_color,
+                                        "outline_color_rgba", line_color_node->color,
+                                        "fill_color_rgba", fill_color_node->color,
                                         NULL);
 
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
+       
        g_signal_connect (G_OBJECT (object), "changed",
                          G_CALLBACK (update_canvas_item_from_object_cb), view_box);
 
@@ -241,6 +254,8 @@ construct_properties_editor (glViewObject *view_object)
                          G_CALLBACK (update_editor_from_move_cb), editor);
        g_signal_connect (G_OBJECT (object->parent), "size_changed",
                          G_CALLBACK (update_editor_from_label_cb), editor);
+       g_signal_connect (G_OBJECT (object->parent), "merge_changed",
+                         G_CALLBACK (update_editor_from_label_cb), editor);
 
        gl_debug (DEBUG_VIEW, "END");
 
@@ -255,25 +270,37 @@ update_canvas_item_from_object_cb (glLabelObject *object,
                                   glViewBox     *view_box)
 {
        gdouble            line_width;
-       guint              line_color, fill_color;
+       glColorNode       *line_color_node;
        gdouble            w, h;
+       glColorNode       *fill_color_node;
 
        gl_debug (DEBUG_VIEW, "START");
 
        /* Query properties of object. */
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
        line_width = gl_label_object_get_line_width(GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
-       fill_color = gl_label_object_get_fill_color(GL_LABEL_OBJECT(object));
+       line_color_node = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
+       if (line_color_node->field_flag)
+       {
+               line_color_node->color = GL_COLOR_MERGE_DEFAULT;
+       }
+       fill_color_node = gl_label_object_get_fill_color(GL_LABEL_OBJECT(object));
+       if (fill_color_node->field_flag)
+       {
+               fill_color_node->color = GL_COLOR_FILL_MERGE_DEFAULT;
+       }
 
        /* Adjust appearance of analogous canvas item. */
        gnome_canvas_item_set (view_box->private->item,
                               "x2", w + DELTA,
                               "y2", h + DELTA,
                               "width_units", line_width,
-                              "outline_color_rgba", line_color,
-                              "fill_color_rgba", fill_color,
+                              "outline_color_rgba", line_color_node->color,
+                              "fill_color_rgba", fill_color_node->color,
                               NULL);
+       
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
 
        gl_debug (DEBUG_VIEW, "END");
 }
@@ -286,8 +313,9 @@ update_object_from_editor_cb (glObjectEditor *editor,
                              glLabelObject  *object)
 {
        gdouble            x, y, w, h;
-       guint              line_color, fill_color;
+       glColorNode       *line_color_node;
        gdouble            line_width;
+       glColorNode       *fill_color_node;
 
        gl_debug (DEBUG_VIEW, "START");
 
@@ -304,11 +332,13 @@ update_object_from_editor_cb (glObjectEditor *editor,
        gl_object_editor_get_size (editor, &w, &h);
        gl_label_object_set_size (object, w, h);
 
-       fill_color = gl_object_editor_get_fill_color (editor);
-       gl_label_object_set_fill_color (object, fill_color);
+       fill_color_node = gl_object_editor_get_fill_color (editor);
+       gl_label_object_set_fill_color (object, fill_color_node);
+       gl_color_node_free (&fill_color_node);
 
-       line_color = gl_object_editor_get_line_color (editor);
-       gl_label_object_set_line_color (object, line_color);
+       line_color_node = gl_object_editor_get_line_color (editor);
+       gl_label_object_set_line_color (object, line_color_node);
+       gl_color_node_free (&line_color_node);
 
        line_width = gl_object_editor_get_line_width (editor);
        gl_label_object_set_line_width (object, line_width);
@@ -332,19 +362,24 @@ update_editor_from_object_cb (glLabelObject  *object,
                              glObjectEditor *editor)
 {
        gdouble            w, h;
-       guint              line_color, fill_color;
+       glColorNode       *line_color_node;
        gdouble            line_width;
+       glColorNode       *fill_color_node;
+       glMerge           *merge;
 
        gl_debug (DEBUG_VIEW, "START");
 
        gl_label_object_get_size (object, &w, &h);
        gl_object_editor_set_size (editor, w, h);
+       merge = gl_label_get_merge (GL_LABEL(object->parent));
+       
+       fill_color_node = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
+       gl_object_editor_set_fill_color (editor, (merge != NULL), fill_color_node);
+       gl_color_node_free (&fill_color_node);
 
-       fill_color = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
-       gl_object_editor_set_fill_color (editor, fill_color);
-
-       line_color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
-       gl_object_editor_set_line_color (editor, line_color);
+       line_color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       gl_object_editor_set_line_color (editor, (merge != NULL), line_color_node);
+       gl_color_node_free (&line_color_node);
 
        line_width = gl_label_object_get_line_width (GL_LABEL_OBJECT(object));
        gl_object_editor_set_line_width (editor, line_width);
@@ -379,6 +414,7 @@ update_editor_from_label_cb (glLabel        *label,
                             glObjectEditor *editor)
 {
        gdouble            label_width, label_height;
+       glMerge                    *merge;
 
        gl_debug (DEBUG_VIEW, "START");
 
@@ -387,6 +423,9 @@ update_editor_from_label_cb (glLabel        *label,
                                           label_width, label_height);
        gl_object_editor_set_max_size (GL_OBJECT_EDITOR (editor),
                                       label_width, label_height);
+       
+       merge = gl_label_get_merge (label);
+       gl_object_editor_set_key_names (editor, merge);
 
        gl_debug (DEBUG_VIEW, "END");
 }
@@ -436,8 +475,9 @@ gl_view_box_create_event_handler (GnomeCanvas *canvas,
        static gboolean      dragging = FALSE;
        static glViewObject *view_box;
        static GObject      *object;
-       guint                line_color, fill_color;
+       glColorNode         *line_color_node;
        gdouble              x, y, w, h;
+       glColorNode         *fill_color_node;
 
        gl_debug (DEBUG_VIEW, "");
 
@@ -446,6 +486,9 @@ gl_view_box_create_event_handler (GnomeCanvas *canvas,
        case GDK_BUTTON_PRESS:
                switch (event->button.button) {
                case 1:
+                       fill_color_node = gl_color_node_new_default ();
+                       line_color_node = gl_color_node_new_default ();
+               
                        dragging = TRUE;
                        gnome_canvas_item_grab ( canvas->root,
                                                 GDK_POINTER_MOTION_MASK |
@@ -460,16 +503,19 @@ gl_view_box_create_event_handler (GnomeCanvas *canvas,
                                                     x, y);
                        gl_label_object_set_size (GL_LABEL_OBJECT(object),
                                                  0.0, 0.0);
-                       line_color = gl_color_set_opacity (gl_view_get_default_line_color(view), 0.5);
-                       fill_color = gl_color_set_opacity (gl_view_get_default_fill_color(view), 0.5);
+                       line_color_node->color = gl_color_set_opacity (gl_view_get_default_line_color(view), 0.5);
+                       fill_color_node->color = gl_color_set_opacity (gl_view_get_default_fill_color(view), 0.5);
                        gl_label_object_set_line_width (GL_LABEL_OBJECT(object),
                                                     gl_view_get_default_line_width(view));
                        gl_label_object_set_line_color (GL_LABEL_OBJECT(object),
-                                                    line_color);
+                                                    line_color_node);
                        gl_label_object_set_fill_color (GL_LABEL_OBJECT(object),
-                                                    fill_color);
+                                                    fill_color_node);
                        view_box = gl_view_box_new (GL_LABEL_BOX(object),
                                                    view);
+                                                       
+                       gl_color_node_free (&fill_color_node);
+                       gl_color_node_free (&line_color_node);
                        x0 = x;
                        y0 = y;
                        return TRUE;
@@ -481,6 +527,9 @@ gl_view_box_create_event_handler (GnomeCanvas *canvas,
        case GDK_BUTTON_RELEASE:
                switch (event->button.button) {
                case 1:
+                       fill_color_node = gl_color_node_new_default ();
+                       line_color_node = gl_color_node_new_default ();
+               
                        dragging = FALSE;
                        gnome_canvas_item_ungrab (canvas->root, event->button.time);
                        gnome_canvas_window_to_world (canvas,
@@ -496,13 +545,16 @@ gl_view_box_create_event_handler (GnomeCanvas *canvas,
                        h = MAX (y, y0) - MIN (y, y0);
                        gl_label_object_set_size (GL_LABEL_OBJECT(object),
                                                  w, h);
-                       gl_label_object_set_line_color (GL_LABEL_OBJECT(object),
-                                                    gl_view_get_default_line_color(view));
-                       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object),
-                                                    gl_view_get_default_fill_color(view));
+                       line_color_node->color = gl_view_get_default_line_color(view);
+                       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+                       fill_color_node->color = gl_view_get_default_fill_color(view);
+                       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color_node);
                        gl_view_unselect_all (view);
                        gl_view_object_select (GL_VIEW_OBJECT(view_box));
                        gl_view_arrow_mode (view);
+                       
+                       gl_color_node_free (&fill_color_node);
+                       gl_color_node_free (&line_color_node);
                        return TRUE;
 
                default:
index 986436185a39a2c0842c3b2db7f8c0426883e1a7..f4d141230643c661f2c39e509d67b0d1996a78a1 100644 (file)
@@ -19,6 +19,7 @@
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  */
+#include <config.h>
 
 #include <glib.h>
 
@@ -164,8 +165,9 @@ gl_view_ellipse_new (glLabelEllipse *object,
 {
        glViewEllipse     *view_ellipse;
        gdouble            line_width;
-       guint              line_color, fill_color;
+       glColorNode       *line_color_node;
        gdouble            w, h;
+       glColorNode       *fill_color_node;
 
        gl_debug (DEBUG_VIEW, "START");
        g_return_if_fail (object && GL_IS_LABEL_ELLIPSE (object));
@@ -181,8 +183,16 @@ gl_view_ellipse_new (glLabelEllipse *object,
        /* Query properties of object. */
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
        line_width = gl_label_object_get_line_width(GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
-       fill_color = gl_label_object_get_fill_color(GL_LABEL_OBJECT(object));
+       line_color_node = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
+       if (line_color_node->field_flag)
+       {
+               line_color_node->color = GL_COLOR_MERGE_DEFAULT;
+       }
+       fill_color_node = gl_label_object_get_fill_color(GL_LABEL_OBJECT(object));
+       if (fill_color_node->field_flag)
+       {
+               fill_color_node->color = GL_COLOR_FILL_MERGE_DEFAULT;
+       }       
 
        /* Create analogous canvas item. */
        view_ellipse->private->item =
@@ -193,10 +203,13 @@ gl_view_ellipse_new (glLabelEllipse *object,
                                         "x2", w + DELTA,
                                         "y2", h + DELTA,
                                         "width_units", line_width,
-                                        "outline_color_rgba", line_color,
-                                        "fill_color_rgba", fill_color,
+                                        "outline_color_rgba", line_color_node->color,
+                                        "fill_color_rgba", fill_color_node->color,
                                         NULL);
 
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
+       
        g_signal_connect (G_OBJECT (object), "changed",
                          G_CALLBACK (update_canvas_item_from_object_cb), view_ellipse);
 
@@ -241,6 +254,8 @@ construct_properties_editor (glViewObject *view_object)
                          G_CALLBACK (update_editor_from_move_cb), editor);
        g_signal_connect (G_OBJECT (object->parent), "size_changed",
                          G_CALLBACK (update_editor_from_label_cb), editor);
+       g_signal_connect (G_OBJECT (object->parent), "merge_changed",
+                         G_CALLBACK (update_editor_from_label_cb), editor);
 
        gl_debug (DEBUG_VIEW, "END");
 
@@ -255,25 +270,37 @@ update_canvas_item_from_object_cb (glLabelObject *object,
                                   glViewEllipse *view_ellipse)
 {
        gdouble            line_width;
-       guint              line_color, fill_color;
+       glColorNode       *line_color_node;
        gdouble            w, h;
+       glColorNode       *fill_color_node;
 
        gl_debug (DEBUG_VIEW, "START");
 
        /* Query properties of object. */
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
        line_width = gl_label_object_get_line_width(GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
-       fill_color = gl_label_object_get_fill_color(GL_LABEL_OBJECT(object));
+       line_color_node = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
+       if (line_color_node->field_flag)
+       {
+               line_color_node->color = GL_COLOR_MERGE_DEFAULT;
+       }
+       fill_color_node = gl_label_object_get_fill_color(GL_LABEL_OBJECT(object));
+       if (fill_color_node->field_flag)
+       {
+               fill_color_node->color = GL_COLOR_FILL_MERGE_DEFAULT;
+       }
 
        /* Adjust appearance of analogous canvas item. */
        gnome_canvas_item_set (view_ellipse->private->item,
                               "x2", w + DELTA,
                               "y2", h + DELTA,
                               "width_units", line_width,
-                              "outline_color_rgba", line_color,
-                              "fill_color_rgba", fill_color,
+                              "outline_color_rgba", line_color_node->color,
+                              "fill_color_rgba", fill_color_node->color,
                               NULL);
+       
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
 
        gl_debug (DEBUG_VIEW, "END");
 }
@@ -286,8 +313,10 @@ update_object_from_editor_cb (glObjectEditor *editor,
                              glLabelObject  *object)
 {
        gdouble            x, y, w, h;
-       guint              line_color, fill_color;
+       glColorNode       *line_color_node;
        gdouble            line_width;
+       glColorNode       *fill_color_node;
+       glMerge           *merge;       
 
        gl_debug (DEBUG_VIEW, "START");
 
@@ -305,11 +334,13 @@ update_object_from_editor_cb (glObjectEditor *editor,
        gl_object_editor_get_size (editor, &w, &h);
        gl_label_object_set_size (object, w, h);
 
-       fill_color = gl_object_editor_get_fill_color (editor);
-       gl_label_object_set_fill_color (object, fill_color);
+       fill_color_node = gl_object_editor_get_fill_color (editor);
+       gl_label_object_set_fill_color (object, fill_color_node);
+       gl_color_node_free (&fill_color_node);
 
-       line_color = gl_object_editor_get_line_color (editor);
-       gl_label_object_set_line_color (object, line_color);
+       line_color_node = gl_object_editor_get_line_color (editor);
+       gl_label_object_set_line_color (object, line_color_node);
+       gl_color_node_free (&line_color_node);
 
        line_width = gl_object_editor_get_line_width (editor);
        gl_label_object_set_line_width (object, line_width);
@@ -333,19 +364,24 @@ update_editor_from_object_cb (glLabelObject  *object,
                              glObjectEditor *editor)
 {
        gdouble            w, h;
-       guint              line_color, fill_color;
+       glColorNode       *line_color_node;
        gdouble            line_width;
+       glColorNode       *fill_color_node;
+       glMerge           *merge;
 
        gl_debug (DEBUG_VIEW, "START");
 
        gl_label_object_get_size (object, &w, &h);
        gl_object_editor_set_size (editor, w, h);
+       merge = gl_label_get_merge (GL_LABEL(object->parent));
 
-       fill_color = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
-       gl_object_editor_set_fill_color (editor, fill_color);
+       fill_color_node = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
+       gl_object_editor_set_fill_color (editor, (merge != NULL), fill_color_node);
+       gl_color_node_free (&fill_color_node);
 
-       line_color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
-       gl_object_editor_set_line_color (editor, line_color);
+       line_color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       gl_object_editor_set_line_color (editor, (merge != NULL), line_color_node);
+       gl_color_node_free (&line_color_node);
 
        line_width = gl_label_object_get_line_width (GL_LABEL_OBJECT(object));
        gl_object_editor_set_line_width (editor, line_width);
@@ -380,6 +416,7 @@ update_editor_from_label_cb (glLabel        *label,
                             glObjectEditor *editor)
 {
        gdouble            label_width, label_height;
+       glMerge                    *merge;
 
        gl_debug (DEBUG_VIEW, "START");
 
@@ -388,6 +425,9 @@ update_editor_from_label_cb (glLabel        *label,
                                           label_width, label_height);
        gl_object_editor_set_max_size (GL_OBJECT_EDITOR (editor),
                                       label_width, label_height);
+       
+       merge = gl_label_get_merge (label);
+       gl_object_editor_set_key_names (editor, merge);
 
        gl_debug (DEBUG_VIEW, "END");
 }
@@ -437,16 +477,22 @@ gl_view_ellipse_create_event_handler (GnomeCanvas *canvas,
        static gboolean      dragging = FALSE;
        static glViewObject *view_ellipse;
        static GObject      *object;
-       guint                line_color, fill_color;
+       glColorNode         *line_color_node;
        gdouble              x, y, w, h;
+       glColorNode         *fill_color_node;
 
        gl_debug (DEBUG_VIEW, "");
 
+       
+       
        switch (event->type) {
 
        case GDK_BUTTON_PRESS:
                switch (event->button.button) {
                case 1:
+                       fill_color_node = gl_color_node_new_default ();
+                       line_color_node = gl_color_node_new_default ();
+               
                        dragging = TRUE;
                        gnome_canvas_item_grab ( canvas->root,
                                                 GDK_POINTER_MOTION_MASK |
@@ -461,16 +507,19 @@ gl_view_ellipse_create_event_handler (GnomeCanvas *canvas,
                                                     x, y);
                        gl_label_object_set_size (GL_LABEL_OBJECT(object),
                                                  0.0, 0.0);
-                       line_color = gl_color_set_opacity (gl_view_get_default_line_color(view), 0.5);
-                       fill_color = gl_color_set_opacity (gl_view_get_default_fill_color(view), 0.5);
+                       line_color_node->color = gl_color_set_opacity (gl_view_get_default_line_color(view), 0.5);
+                       fill_color_node->color = gl_color_set_opacity (gl_view_get_default_fill_color(view), 0.5);
                        gl_label_object_set_line_width (GL_LABEL_OBJECT(object),
                                                     gl_view_get_default_line_width(view));
                        gl_label_object_set_line_color (GL_LABEL_OBJECT(object),
-                                                        line_color);
+                                                        line_color_node);
                        gl_label_object_set_fill_color (GL_LABEL_OBJECT(object),
-                                                        fill_color);
+                                                        fill_color_node);
                        view_ellipse = gl_view_ellipse_new (GL_LABEL_ELLIPSE(object),
                                                            view);
+                       
+                       gl_color_node_free (&fill_color_node);
+                       gl_color_node_free (&line_color_node);
                        x0 = x;
                        y0 = y;
                        return TRUE;
@@ -482,6 +531,9 @@ gl_view_ellipse_create_event_handler (GnomeCanvas *canvas,
        case GDK_BUTTON_RELEASE:
                switch (event->button.button) {
                case 1:
+                       fill_color_node = gl_color_node_new_default ();
+                       line_color_node = gl_color_node_new_default ();
+               
                        dragging = FALSE;
                        gnome_canvas_item_ungrab (canvas->root, event->button.time);
                        gnome_canvas_window_to_world (canvas,
@@ -497,13 +549,17 @@ gl_view_ellipse_create_event_handler (GnomeCanvas *canvas,
                        h = MAX (y, y0) - MIN (y, y0);
                        gl_label_object_set_size (GL_LABEL_OBJECT(object),
                                                  w, h);
-                       gl_label_object_set_line_color (GL_LABEL_OBJECT(object),
-                                                    gl_view_get_default_line_color(view));
-                       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object),
-                                                    gl_view_get_default_fill_color(view));
+                       line_color_node->color = gl_view_get_default_line_color(view);
+                       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+                       
+                       fill_color_node->color = gl_view_get_default_fill_color(view);
+                       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color_node);
                        gl_view_unselect_all (view);
                        gl_view_object_select (GL_VIEW_OBJECT(view_ellipse));
                        gl_view_arrow_mode (view);
+                       
+                       gl_color_node_free (&fill_color_node);
+                       gl_color_node_free (&line_color_node);
                        return TRUE;
 
                default:
index 176b169cdfce0fd725ad64f83f1154ad7e66f32f..eb122e9a5d5bdd7f17d9523e245a3c73d2a27d25 100644 (file)
@@ -19,6 +19,7 @@
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  */
+#include <config.h>
 
 #include <glib.h>
 
index 143ed481199acbe90e73b4a3d489fcd0ea315ec4..67e42245e99011eb15871cce0a2b51c86e0b8f3a 100644 (file)
@@ -19,6 +19,7 @@
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  */
+#include <config.h>
 
 #include <glib.h>
 
@@ -162,7 +163,7 @@ gl_view_line_new (glLabelLine *object,
 {
        glViewLine        *view_line;
        gdouble            line_width;
-       guint              line_color;
+       glColorNode       *line_color_node;
        gdouble            w, h;
        GnomeCanvasPoints *points;
 
@@ -180,7 +181,11 @@ gl_view_line_new (glLabelLine *object,
        /* Query properties of object. */
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
        line_width = gl_label_object_get_line_width(GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
+       line_color_node = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
+       if (line_color_node->field_flag)
+       {
+               line_color_node->color = GL_COLOR_MERGE_DEFAULT;
+       }
 
        /* Create analogous canvas item. */
        points = gnome_canvas_points_new (2);
@@ -193,8 +198,9 @@ gl_view_line_new (glLabelLine *object,
                                         gnome_canvas_line_get_type (),
                                         "points", points,
                                         "width_units", line_width,
-                                        "fill_color_rgba", line_color,
+                                        "fill_color_rgba", line_color_node->color,
                                         NULL);
+       gl_color_node_free (&line_color_node);
        gnome_canvas_points_free (points);
 
        g_signal_connect (G_OBJECT (object), "changed",
@@ -240,6 +246,8 @@ construct_properties_editor (glViewObject *view_object)
                          G_CALLBACK (update_editor_from_move_cb), editor);
        g_signal_connect (G_OBJECT (object->parent), "size_changed",
                          G_CALLBACK (update_editor_from_label_cb), editor);
+       g_signal_connect (G_OBJECT (object->parent), "merge_changed",
+                         G_CALLBACK (update_editor_from_label_cb), editor);
 
        gl_debug (DEBUG_VIEW, "END");
 
@@ -254,16 +262,20 @@ update_canvas_item_from_object_cb (glLabelObject *object,
                                   glViewLine     *view_line)
 {
        gdouble            line_width;
-       guint              line_color;
+       glColorNode       *line_color_node;
        gdouble            w, h;
-       GnomeCanvasPoints  *points;
+       GnomeCanvasPoints *points;
 
        gl_debug (DEBUG_VIEW, "START");
 
        /* Query properties of object. */
        gl_label_object_get_size (GL_LABEL_OBJECT(object), &w, &h);
        line_width = gl_label_object_get_line_width(GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
+       line_color_node = gl_label_object_get_line_color(GL_LABEL_OBJECT(object));
+       if (line_color_node->field_flag)
+       {
+               line_color_node->color = GL_COLOR_MERGE_DEFAULT;
+       }
 
        /* Adjust appearance of analogous canvas item. */
        points = gnome_canvas_points_new (2);
@@ -274,8 +286,9 @@ update_canvas_item_from_object_cb (glLabelObject *object,
        gnome_canvas_item_set (view_line->private->item,
                               "points", points,
                               "width_units", line_width,
-                              "fill_color_rgba", line_color,
+                              "fill_color_rgba", line_color_node->color,
                               NULL);
+       gl_color_node_free (&line_color_node);
        gnome_canvas_points_free (points);
 
        gl_debug (DEBUG_VIEW, "END");
@@ -289,7 +302,7 @@ update_object_from_editor_cb (glObjectEditor *editor,
                              glLabelObject  *object)
 {
        gdouble            x, y, w, h;
-       guint              line_color;
+       glColorNode       *line_color_node;
        gdouble            line_width;
 
        gl_debug (DEBUG_VIEW, "START");
@@ -307,9 +320,10 @@ update_object_from_editor_cb (glObjectEditor *editor,
 
        gl_object_editor_get_lsize (editor, &w, &h);
        gl_label_object_set_size (object, w, h);
-
-       line_color = gl_object_editor_get_line_color (editor);
-       gl_label_object_set_line_color (object, line_color);
+       
+       line_color_node = gl_object_editor_get_line_color (editor);
+       gl_label_object_set_line_color (object, line_color_node);
+       gl_color_node_free (&line_color_node);
 
        line_width = gl_object_editor_get_line_width (editor);
        gl_label_object_set_line_width (object, line_width);
@@ -333,16 +347,20 @@ update_editor_from_object_cb (glLabelObject  *object,
                              glObjectEditor *editor)
 {
        gdouble            w, h;
-       guint              line_color;
+       glColorNode       *line_color_node;
        gdouble            line_width;
+       glMerge           *merge;
 
        gl_debug (DEBUG_VIEW, "START");
 
        gl_label_object_get_size (object, &w, &h);
        gl_object_editor_set_lsize (editor, w, h);
+       
+       merge = gl_label_get_merge (GL_LABEL(object->parent));
 
-       line_color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
-       gl_object_editor_set_line_color (editor, line_color);
+       line_color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       gl_object_editor_set_line_color (editor, (merge != NULL), line_color_node);
+       gl_color_node_free (&line_color_node);
 
        line_width = gl_label_object_get_line_width (GL_LABEL_OBJECT(object));
        gl_object_editor_set_line_width (editor, line_width);
@@ -377,6 +395,7 @@ update_editor_from_label_cb (glLabel        *label,
                             glObjectEditor *editor)
 {
        gdouble            label_width, label_height;
+       glMerge           *merge;
 
        gl_debug (DEBUG_VIEW, "START");
 
@@ -385,6 +404,9 @@ update_editor_from_label_cb (glLabel        *label,
                                           label_width, label_height);
        gl_object_editor_set_max_lsize (GL_OBJECT_EDITOR (editor),
                                        label_width, label_height);
+       
+       merge = gl_label_get_merge (label);
+       gl_object_editor_set_key_names (editor, merge);
 
        gl_debug (DEBUG_VIEW, "END");
 }
@@ -430,11 +452,12 @@ gl_view_line_create_event_handler (GnomeCanvas *canvas,
                                   GdkEvent    *event,
                                   glView      *view)
 {
-       static gdouble      x0, y0;
-       static gboolean     dragging = FALSE;
+       static gdouble       x0, y0;
+       static gboolean      dragging = FALSE;
        static glViewObject *view_line;
        static GObject      *object;
-       gdouble             x, y, w, h;
+       gdouble              x, y, w, h;
+       glColorNode         *line_color_node;
 
        gl_debug (DEBUG_VIEW, "");
 
@@ -443,6 +466,7 @@ gl_view_line_create_event_handler (GnomeCanvas *canvas,
        case GDK_BUTTON_PRESS:
                switch (event->button.button) {
                case 1:
+                       line_color_node = gl_color_node_new_default ();
                        dragging = TRUE;
                        gnome_canvas_item_grab (canvas->root,
                                                GDK_POINTER_MOTION_MASK |
@@ -459,12 +483,14 @@ gl_view_line_create_event_handler (GnomeCanvas *canvas,
                                                  0.0, 0.0);
                        gl_label_object_set_line_width (GL_LABEL_OBJECT(object),
                                                      gl_view_get_default_line_width(view));
+                       line_color_node->color = gl_color_set_opacity (gl_view_get_default_line_color(view), 0.5);
                        gl_label_object_set_line_color (GL_LABEL_OBJECT(object),
-                                                    gl_color_set_opacity (gl_view_get_default_line_color(view), 0.5));
+                                                    line_color_node);
                        view_line = gl_view_line_new (GL_LABEL_LINE(object),
                                                      view);
                        x0 = x;
                        y0 = y;
+                       gl_color_node_free (&line_color_node);
                        return TRUE;
 
                default:
@@ -474,6 +500,7 @@ gl_view_line_create_event_handler (GnomeCanvas *canvas,
        case GDK_BUTTON_RELEASE:
                switch (event->button.button) {
                case 1:
+                       line_color_node = gl_color_node_new_default ();
                        dragging = FALSE;
                        gnome_canvas_item_ungrab (canvas->root, event->button.time);
                        gnome_canvas_window_to_world (canvas,
@@ -487,11 +514,13 @@ gl_view_line_create_event_handler (GnomeCanvas *canvas,
                        h = y - y0;
                        gl_label_object_set_size (GL_LABEL_OBJECT(object),
                                                  w, h);
+                       line_color_node->color = gl_view_get_default_line_color(view);
                        gl_label_object_set_line_color (GL_LABEL_OBJECT(object),
-                                                    gl_view_get_default_line_color(view));
+                                                    line_color_node);
                        gl_view_unselect_all (view);
                        gl_view_object_select (GL_VIEW_OBJECT(view_line));
                        gl_view_arrow_mode (view);
+                       gl_color_node_free (&line_color_node);
                        return TRUE;
 
                default:
@@ -517,4 +546,3 @@ gl_view_line_create_event_handler (GnomeCanvas *canvas,
        }
 
 }
-
index d2abc47b7eff148490503c9c604285eec8139846..9e5a054a3ae4e676a74091ac708885db9b8bc18c 100644 (file)
@@ -19,6 +19,7 @@
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  */
+#include <config.h>
 
 #include <glib.h>
 
@@ -258,9 +259,9 @@ construct_properties_editor (glViewObject *view_object)
        gl_object_editor_set_text_buffer (GL_OBJECT_EDITOR(editor), buffer);
        
        /* Update */
+       update_editor_from_label_cb (object->parent, GL_OBJECT_EDITOR(editor));
        update_editor_from_object_cb (object, GL_OBJECT_EDITOR(editor));
        update_editor_from_move_cb (object, 0, 0, GL_OBJECT_EDITOR(editor));
-       update_editor_from_label_cb (object->parent, GL_OBJECT_EDITOR(editor));
 
        /* Connect signals. */
        g_signal_connect (G_OBJECT (editor), "changed",
@@ -272,7 +273,7 @@ construct_properties_editor (glViewObject *view_object)
        g_signal_connect (G_OBJECT (object), "moved",
                          G_CALLBACK (update_editor_from_move_cb), editor);
        g_signal_connect (G_OBJECT (object->parent), "size_changed",
-                         G_CALLBACK (update_editor_from_label_cb), editor);
+                         G_CALLBACK (update_editor_from_label_cb), editor);                      
        g_signal_connect (G_OBJECT (object->parent), "merge_changed",
                          G_CALLBACK (update_editor_from_label_cb), editor);
 
@@ -309,7 +310,7 @@ update_object_from_editor_cb (glObjectEditor *editor,
        gdouble            font_size;
        GnomeFontWeight    font_weight;
        gboolean           font_italic_flag;
-       guint              color;
+       glColorNode       *color_node;
        GtkJustification   just;
        gdouble            text_line_spacing;
        gboolean           auto_shrink;
@@ -328,7 +329,7 @@ update_object_from_editor_cb (glObjectEditor *editor,
        font_size = gl_object_editor_get_font_size (editor);
        font_weight = gl_object_editor_get_font_weight (editor);
        font_italic_flag = gl_object_editor_get_font_italic_flag (editor);
-       color = gl_object_editor_get_text_color (editor);
+       color_node = gl_object_editor_get_text_color (editor);
        just = gl_object_editor_get_text_alignment (editor);
        text_line_spacing = gl_object_editor_get_text_line_spacing (editor);
        auto_shrink = gl_object_editor_get_text_auto_shrink (editor);
@@ -338,11 +339,12 @@ update_object_from_editor_cb (glObjectEditor *editor,
        gl_label_object_set_font_size (object, font_size);
        gl_label_object_set_font_weight (object, font_weight);
        gl_label_object_set_font_italic_flag (object, font_italic_flag);
-       gl_label_object_set_text_color (object, color);
+       gl_label_object_set_text_color (object, color_node);
        gl_label_object_set_text_alignment (object, just);
        gl_label_object_set_text_line_spacing (object, text_line_spacing);
        gl_label_text_set_auto_shrink (GL_LABEL_TEXT (object), auto_shrink);
 
+       gl_color_node_free (&color_node);
        g_free (font_family);
 
        g_signal_handlers_unblock_by_func (G_OBJECT(object),
@@ -399,21 +401,23 @@ update_editor_from_object_cb (glLabelObject  *object,
        gdouble            font_size;
        GnomeFontWeight    font_weight;
        gboolean           font_italic_flag;
-       guint              color;
+       glColorNode       *color_node;
        GtkJustification   just;
        gdouble            text_line_spacing;
        gboolean           auto_shrink;
+       glMerge                    *merge;
 
        gl_debug (DEBUG_VIEW, "START");
 
        gl_label_object_get_size (object, &w, &h);
        gl_object_editor_set_size (editor, w, h);
+       merge = gl_label_get_merge (GL_LABEL(object->parent));
 
        font_family      = gl_label_object_get_font_family (object);
        font_size        = gl_label_object_get_font_size (object);
        font_weight      = gl_label_object_get_font_weight (object);
        font_italic_flag = gl_label_object_get_font_italic_flag (object);
-       color            = gl_label_object_get_text_color (object);
+       color_node       = gl_label_object_get_text_color (object);
        just             = gl_label_object_get_text_alignment (object);
        text_line_spacing = gl_label_object_get_text_line_spacing (object);
        auto_shrink      = gl_label_text_get_auto_shrink (GL_LABEL_TEXT (object));
@@ -422,11 +426,12 @@ update_editor_from_object_cb (glLabelObject  *object,
        gl_object_editor_set_font_size (editor, font_size);
        gl_object_editor_set_font_weight (editor, font_weight);
        gl_object_editor_set_font_italic_flag (editor, font_italic_flag);
-       gl_object_editor_set_text_color (editor, color);
+       gl_object_editor_set_text_color (editor, (merge != NULL), color_node);
        gl_object_editor_set_text_alignment (editor, just);
        gl_object_editor_set_text_line_spacing (editor, text_line_spacing);
        gl_object_editor_set_text_auto_shrink (editor, auto_shrink);
 
+       gl_color_node_free (&color_node);
        g_free (font_family);
 
        gl_debug (DEBUG_VIEW, "END");
@@ -516,13 +521,14 @@ gl_view_text_create_event_handler (GnomeCanvas *canvas,
                                   GdkEvent    *event,
                                   glView      *view)
 {
-       static gdouble      x0, y0;
-       static gboolean     dragging = FALSE;
+       static gdouble       x0, y0;
+       static gboolean      dragging = FALSE;
        static glViewObject *view_text;
        static GObject      *object;
-       gdouble             x, y;
+       gdouble              x, y;
        GList               *lines;
        gchar               *family;
+       glColorNode         *color_node;
 
        gl_debug (DEBUG_VIEW, "");
 
@@ -532,6 +538,7 @@ gl_view_text_create_event_handler (GnomeCanvas *canvas,
                gl_debug (DEBUG_VIEW, "BUTTON_PRESS");
                switch (event->button.button) {
                case 1:
+                       color_node = gl_color_node_new_default ();
                        dragging = TRUE;
                        gnome_canvas_item_grab (canvas->root,
                                                GDK_POINTER_MOTION_MASK |
@@ -552,8 +559,10 @@ gl_view_text_create_event_handler (GnomeCanvas *canvas,
                                                         gl_view_get_default_font_weight (view));
                        gl_label_object_set_font_italic_flag (GL_LABEL_OBJECT(object),
                                                              gl_view_get_default_font_italic_flag (view));
+                                                                 
+                       color_node->color = gl_color_set_opacity (gl_view_get_default_text_color (view), 0.5);
                        gl_label_object_set_text_color (GL_LABEL_OBJECT(object),
-                                                       gl_color_set_opacity (gl_view_get_default_text_color (view), 0.5));
+                                                       color_node);
                        gl_label_object_set_text_alignment (GL_LABEL_OBJECT(object),
                                                            gl_view_get_default_text_alignment (view));
                        gl_label_object_set_text_line_spacing (GL_LABEL_OBJECT(object), gl_view_get_default_text_line_spacing (view));
@@ -565,6 +574,7 @@ gl_view_text_create_event_handler (GnomeCanvas *canvas,
                                                      view);
                        x0 = x;
                        y0 = y;
+                       gl_color_node_free (&color_node);
                        return TRUE;
 
                default:
@@ -575,6 +585,7 @@ gl_view_text_create_event_handler (GnomeCanvas *canvas,
                gl_debug (DEBUG_VIEW, "BUTTON_RELEASE");
                switch (event->button.button) {
                case 1:
+                       color_node = gl_color_node_new_default ();
                        dragging = FALSE;
                        gnome_canvas_item_ungrab (canvas->root, event->button.time);
                        gnome_canvas_window_to_world (canvas,
@@ -590,8 +601,10 @@ gl_view_text_create_event_handler (GnomeCanvas *canvas,
                                                         gl_view_get_default_font_weight (view));
                        gl_label_object_set_font_italic_flag (GL_LABEL_OBJECT(object),
                                                              gl_view_get_default_font_italic_flag (view));
+                       
+                       color_node->color = gl_view_get_default_text_color (view);
                        gl_label_object_set_text_color (GL_LABEL_OBJECT(object),
-                                                       gl_view_get_default_text_color (view));
+                                                       color_node);
                        gl_label_object_set_text_alignment (GL_LABEL_OBJECT(object),
                                                            gl_view_get_default_text_alignment (view));
                        gl_label_object_set_text_line_spacing (GL_LABEL_OBJECT(object), gl_view_get_default_text_line_spacing (view));
@@ -600,6 +613,7 @@ gl_view_text_create_event_handler (GnomeCanvas *canvas,
                        gl_view_unselect_all (view);
                        gl_view_object_select (GL_VIEW_OBJECT(view_text));
                        gl_view_arrow_mode (view);
+                       gl_color_node_free (&color_node);
                        return TRUE;
 
                default:
@@ -641,7 +655,7 @@ draw_hacktext (glViewText *view_text)
        gboolean           font_italic_flag;
        gdouble            font_size;
        gdouble            text_line_spacing;
-       guint              color;
+       glColorNode       *color_node;
        GtkJustification   just;
        GnomeFont         *font;
        GnomeGlyphList    *glyphlist;
@@ -662,7 +676,11 @@ draw_hacktext (glViewText *view_text)
        text_line_spacing = gl_label_object_get_text_line_spacing (object);
        font_weight = gl_label_object_get_font_weight (object);
        font_italic_flag = gl_label_object_get_font_italic_flag (object);
-       color = gl_label_object_get_text_color (object);
+       color_node = gl_label_object_get_text_color (object);
+       if (color_node->field_flag)
+       {
+               color_node->color = GL_COLOR_MERGE_DEFAULT;
+       }
        just = gl_label_object_get_text_alignment (object);
        buffer = gl_label_text_get_buffer(GL_LABEL_TEXT(object));
        gtk_text_buffer_get_bounds (buffer, &start, &end);
@@ -689,7 +707,7 @@ draw_hacktext (glViewText *view_text)
        /* render to group, one item per line. */
        for (i = 0; line[i] != NULL; i++) {
 
-               glyphlist = gnome_glyphlist_from_text_dumb (font, color,
+               glyphlist = gnome_glyphlist_from_text_dumb (font, color_node->color,
                                                            0.0, 0.0,
                                                            line[i]);
 
@@ -733,6 +751,7 @@ draw_hacktext (glViewText *view_text)
        }
 
        /* clean up */
+       gl_color_node_free (&color_node);
        g_strfreev (line);
        g_free (text);
 
@@ -754,7 +773,7 @@ draw_cursor (glViewText *view_text)
        GnomeFontWeight    font_weight;
        gboolean           font_italic_flag;
        gdouble            font_size;
-       guint              color;
+       glColorNode       *color_node;
        GtkJustification   just;
        GnomeFont         *font;
        GnomeGlyphList    *glyphlist;
@@ -778,7 +797,7 @@ draw_cursor (glViewText *view_text)
        font_size = gl_label_object_get_font_size (object);
        font_weight = gl_label_object_get_font_weight (object);
        font_italic_flag = gl_label_object_get_font_italic_flag (object);
-       color = gl_label_object_get_text_color (object);
+       color_node = gl_label_object_get_text_color (object);
        just = gl_label_object_get_text_alignment (object);
        buffer = gl_label_text_get_buffer(GL_LABEL_TEXT(object));
        gtk_text_buffer_get_bounds (buffer, &start, &end);
@@ -808,7 +827,7 @@ draw_cursor (glViewText *view_text)
                if ( i == cursor_line ) {
                        GnomeCanvasPoints *points;
                        
-                       glyphlist = gnome_glyphlist_from_text_dumb (font, color,
+                       glyphlist = gnome_glyphlist_from_text_dumb (font, color_node->color,
                                                                    0.0, 0.0,
                                                                    line[i]);
 
@@ -831,7 +850,7 @@ draw_cursor (glViewText *view_text)
                                break;  /* shouldn't happen */
                        }
 
-                       glyphlist = gnome_glyphlist_from_text_sized_dumb (font, color,
+                       glyphlist = gnome_glyphlist_from_text_sized_dumb (font, color_node->color,
                                                                          0.0, 0.0,
                                                                          line[i],
                                                                          cursor_char);
@@ -866,6 +885,7 @@ draw_cursor (glViewText *view_text)
        }
 
        /* clean up */
+       gl_color_node_free (&color_node);
        g_strfreev (line);
        g_free (text);
 
@@ -959,4 +979,3 @@ item_event_cb (GnomeCanvasItem *item,
 {
        gl_debug (DEBUG_VIEW, "");
 }
-
index fd35d74a3566138dee5f22f153160d86ca387768..bd456d3a6d437ea91af6bec1cfb937bd519209ce 100644 (file)
@@ -466,7 +466,7 @@ get_home_scale (glView *view)
        gdouble    x_pixels_per_mm, y_pixels_per_mm;
        gdouble    scale;
 
-       if (!gtk_widget_has_screen) return 1.0;
+       if (!gtk_widget_has_screen (GTK_WIDGET (view->canvas))) return 1.0;
 
        screen = gtk_widget_get_screen (GTK_WIDGET (view->canvas));
 
@@ -2795,7 +2795,7 @@ gl_view_set_selection_text_line_spacing (glView            *view,
 /*****************************************************************************/
 void
 gl_view_set_selection_text_color (glView            *view,
-                                 guint              text_color)
+                                 glColorNode       *text_color_node)
 {
        GList *p;
        glLabelObject *object;
@@ -2807,7 +2807,7 @@ gl_view_set_selection_text_color (glView            *view,
        for (p = view->selected_object_list; p != NULL; p = p->next) {
 
                object = gl_view_object_get_object(GL_VIEW_OBJECT (p->data));
-               gl_label_object_set_text_color (object, text_color);
+               gl_label_object_set_text_color (object, text_color_node);
 
        }
 
@@ -2844,7 +2844,7 @@ gl_view_can_selection_fill (glView            *view)
 /*****************************************************************************/
 void
 gl_view_set_selection_fill_color (glView            *view,
-                                 guint              fill_color)
+                                 glColorNode       *fill_color_node)
 {
        GList *p;
        glLabelObject *object;
@@ -2856,7 +2856,7 @@ gl_view_set_selection_fill_color (glView            *view,
        for (p = view->selected_object_list; p != NULL; p = p->next) {
 
                object = gl_view_object_get_object(GL_VIEW_OBJECT (p->data));
-               gl_label_object_set_fill_color (object, fill_color);
+               gl_label_object_set_fill_color (object, fill_color_node);
 
        }
 
@@ -2893,7 +2893,7 @@ gl_view_can_selection_line_color (glView            *view)
 /*****************************************************************************/
 void
 gl_view_set_selection_line_color (glView            *view,
-                                 guint              line_color)
+                                 glColorNode       *line_color_node)
 {
        GList *p;
        glLabelObject *object;
@@ -2905,7 +2905,7 @@ gl_view_set_selection_line_color (glView            *view,
        for (p = view->selected_object_list; p != NULL; p = p->next) {
 
                object = gl_view_object_get_object(GL_VIEW_OBJECT (p->data));
-               gl_label_object_set_line_color (object, line_color);
+               gl_label_object_set_line_color (object, line_color_node);
 
        }
 
@@ -3222,14 +3222,18 @@ screen_changed_cb (glView          *view)
 {
        gl_debug (DEBUG_VIEW, "START");
 
-       view->home_scale = get_home_scale (view);
+       if (gtk_widget_has_screen (GTK_WIDGET (view->canvas))) {
 
-       gnome_canvas_set_pixels_per_unit (GNOME_CANVAS (view->canvas),
-                                         view->zoom * view->home_scale);
+               view->home_scale = get_home_scale (view);
+
+               gnome_canvas_set_pixels_per_unit (GNOME_CANVAS (view->canvas),
+                                                 view->zoom * view->home_scale);
+
+               if (view->zoom_to_fit_flag) {
+                       /* Maintain best fit zoom */
+                       gl_view_zoom_to_fit (view);
+               }
 
-       if (view->zoom_to_fit_flag) {
-               /* Maintain best fit zoom */
-               gl_view_zoom_to_fit (view);
        }
 
        gl_debug (DEBUG_VIEW, "END");
@@ -4254,4 +4258,3 @@ guint gl_view_get_default_fill_color (glView            *view)
 
        return view->default_fill_color;
 }
-
index 1eebe09c65437cc4024a3efe1687670cb5576480..6bed15a50b67866c53c212fb9a46c635dae51784 100644 (file)
@@ -44,6 +44,7 @@ typedef struct _glView      glView;
 typedef struct _glViewClass glViewClass;
 
 #include "view-object.h"
+#include "color.h"
 
 struct _glView {
        GtkVBox           parent_widget;
@@ -232,17 +233,17 @@ void       gl_view_set_selection_text_alignment   (glView           *view,
                                                   GtkJustification  text_alignment);
 
 void       gl_view_set_selection_text_color       (glView           *view,
-                                                  guint             text_color);
+                                                  glColorNode      *text_color_node);
 
 gboolean   gl_view_can_selection_fill             (glView           *view);
 
 void       gl_view_set_selection_fill_color       (glView           *view,
-                                                  guint             fill_color);
+                                                  glColorNode      *fill_color);
 
 gboolean   gl_view_can_selection_line_color       (glView           *view);
 
 void       gl_view_set_selection_line_color       (glView           *view,
-                                                  guint             line_color);
+                                                  glColorNode      *line_color_node);
 
 gboolean   gl_view_can_selection_line_width       (glView           *view);
 
index d3206658eb5ad2a46e7195dbfca51a2584791beb..8ab466366b74671e139f7da49f50cba6dbc8d65a 100644 (file)
@@ -36,7 +36,7 @@
 /*============================================================================*/
 
 #define DEFAULT_WINDOW_WIDTH  788
-#define DEFAULT_WINDOW_HEIGHT 560
+#define DEFAULT_WINDOW_HEIGHT 600
 
 #define CURSOR_INFO_WIDTH     150
 #define ZOOM_INFO_WIDTH        50
@@ -566,4 +566,3 @@ modified_changed_cb (glLabel  *label,
 
        gl_debug (DEBUG_WINDOW, "END");
 }
-
index 0e041b913427c7ba6709e62fe4f2049e34562363..aebce11402e273eb1d0ff2671cb5ef7e3f81145f 100644 (file)
@@ -195,7 +195,7 @@ xml04_parse_text_props (xmlNodePtr    object_node,
        gdouble          font_size;
        GnomeFontWeight  font_weight;
        gboolean         font_italic_flag;
-       guint            color;
+       glColorNode      *color_node;
        GtkJustification just;
        xmlNodePtr       line_node, text_node;
        glTextNode       *node_text;
@@ -216,14 +216,17 @@ xml04_parse_text_props (xmlNodePtr    object_node,
        just = gl_util_string_to_just (string);
        g_free (string);
 
-       color = gl_xml_get_prop_uint (object_node, "color", 0);
+       color_node = gl_color_node_new_default ();
+       color_node->color = gl_xml_get_prop_uint (object_node, "color", 0);
 
        gl_label_object_set_font_family (GL_LABEL_OBJECT(object), font_family);
        gl_label_object_set_font_size (GL_LABEL_OBJECT(object), font_size);
        gl_label_object_set_font_weight (GL_LABEL_OBJECT(object), font_weight);
        gl_label_object_set_font_italic_flag (GL_LABEL_OBJECT(object), font_italic_flag);
-       gl_label_object_set_text_color (GL_LABEL_OBJECT(object), color);
+       gl_label_object_set_text_color (GL_LABEL_OBJECT(object), color_node);
        gl_label_object_set_text_alignment (GL_LABEL_OBJECT(object), just);
+       
+       gl_color_node_free (&color_node);
 
        lines = NULL;
        for (line_node = object_node->xmlChildrenNode; line_node != NULL;
@@ -306,7 +309,8 @@ xml04_parse_box_props (xmlNodePtr    node,
                       glLabelBox    *object)
 {
        gdouble w, h, line_width;
-       guint line_color, fill_color;
+       glColorNode *line_color_node;
+       glColorNode *fill_color_node;
 
        gl_debug (DEBUG_XML, "START");
 
@@ -315,14 +319,19 @@ xml04_parse_box_props (xmlNodePtr    node,
 
        line_width = gl_xml_get_prop_double (node, "line_width", 0);
 
-       line_color = gl_xml_get_prop_uint (node, "line_color", 0);
-       fill_color = gl_xml_get_prop_uint (node, "fill_color", 0);
+       line_color_node = gl_color_node_new_default ();
+       line_color_node->color = gl_xml_get_prop_uint (node, "line_color", 0);
+       
+       fill_color_node = gl_color_node_new_default ();
+       fill_color_node->color = gl_xml_get_prop_uint (node, "fill_color", 0);
 
        gl_label_object_set_size (GL_LABEL_OBJECT(object), w, h);
        gl_label_object_set_line_width (GL_LABEL_OBJECT(object), line_width);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color);
-       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color);
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color_node);
 
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
        gl_debug (DEBUG_XML, "END");
 }
 
@@ -334,7 +343,7 @@ xml04_parse_line_props (xmlNodePtr    node,
                        glLabelLine *object)
 {
        gdouble w, h, line_width;
-       guint line_color;
+       glColorNode *line_color_node;
 
        gl_debug (DEBUG_XML, "START");
 
@@ -343,12 +352,15 @@ xml04_parse_line_props (xmlNodePtr    node,
 
        line_width = gl_xml_get_prop_double (node, "line_width", 0);
 
-       line_color = gl_xml_get_prop_uint (node, "line_color", 0);
+       line_color_node = gl_color_node_new_default ();
+       line_color_node->color = gl_xml_get_prop_uint (node, "line_color", 0);
 
        gl_label_object_set_size (GL_LABEL_OBJECT(object), w, h);
        gl_label_object_set_line_width (GL_LABEL_OBJECT(object), line_width);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color);
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
 
+       gl_color_node_free (&line_color_node);
+       
        gl_debug (DEBUG_XML, "END");
 }
 
@@ -360,7 +372,8 @@ xml04_parse_ellipse_props (xmlNodePtr     node,
                           glLabelEllipse *object)
 {
        gdouble w, h, line_width;
-       guint line_color, fill_color;
+       glColorNode *line_color_node;
+       glColorNode *fill_color_node;
 
        gl_debug (DEBUG_XML, "START");
 
@@ -369,14 +382,19 @@ xml04_parse_ellipse_props (xmlNodePtr     node,
 
        line_width = gl_xml_get_prop_double (node, "line_width", 0);
 
-       line_color = gl_xml_get_prop_uint (node, "line_color", 0);
-       fill_color = gl_xml_get_prop_uint (node, "fill_color", 0);
+       line_color_node = gl_color_node_new_default ();
+       line_color_node->color = gl_xml_get_prop_uint (node, "line_color", 0);
+       
+       fill_color_node = gl_color_node_new_default ();
+       fill_color_node->color = gl_xml_get_prop_uint (node, "fill_color", 0);
 
        gl_label_object_set_size (GL_LABEL_OBJECT(object), w, h);
        gl_label_object_set_line_width (GL_LABEL_OBJECT(object), line_width);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color);
-       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color);
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color_node);
 
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
        gl_debug (DEBUG_XML, "END");
 }
 
@@ -414,7 +432,7 @@ xml04_parse_barcode_props (xmlNodePtr    node,
 {
        gchar         *id;
        gboolean       text_flag;
-       guint          color;
+       glColorNode   *color_node;
        gdouble        scale;
        xmlNodePtr     child;
        glTextNode     *text_node;
@@ -422,7 +440,8 @@ xml04_parse_barcode_props (xmlNodePtr    node,
 
        gl_debug (DEBUG_XML, "START");
 
-       color = gl_xml_get_prop_uint (node, "color", 0);
+       color_node = gl_color_node_new_default ();
+       color_node->color = gl_xml_get_prop_uint (node, "color", 0);
 
        id = xmlGetProp (node, "style");
 
@@ -432,7 +451,7 @@ xml04_parse_barcode_props (xmlNodePtr    node,
                scale = 0.5; /* Set to a valid value */
        }
        gl_label_barcode_set_props (object, id, text_flag, TRUE, 0);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), color);
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), color_node);
 
        child = node->xmlChildrenNode;
        text_node = g_new0 (glTextNode, 1);
@@ -447,6 +466,7 @@ xml04_parse_barcode_props (xmlNodePtr    node,
        }
        gl_label_barcode_set_data (object, text_node);
 
+       gl_color_node_free (&color_node);
        gl_text_node_free (&text_node);
        g_free (id);
 
@@ -480,4 +500,3 @@ xml04_parse_merge_properties (xmlNodePtr node,
 
        gl_debug (DEBUG_XML, "END");
 }
-
index 08b9acab1dd70ec76a7d1781986bc0f92306ec25..54d83f2b8462ca94a5db6eb2529684d138f385ad 100644 (file)
@@ -271,7 +271,7 @@ xml191_parse_text_props (xmlNodePtr  object_node,
        gdouble           font_size;
        GnomeFontWeight   font_weight;
        gboolean          font_italic_flag;
-       guint             color;
+       glColorNode      *color_node;
        GtkJustification  just;
        xmlNodePtr        line_node, text_node;
        glTextNode       *node_text;
@@ -299,7 +299,8 @@ xml191_parse_text_props (xmlNodePtr  object_node,
        just = gl_util_string_to_just (string);
        g_free (string);
 
-       color = gl_xml_get_prop_uint (object_node, "color", 0);
+       color_node = gl_color_node_new_default ();
+       color_node->color = gl_xml_get_prop_uint (object_node, "color", 0);
 
        lines = NULL;
        for (line_node = object_node->xmlChildrenNode;
@@ -345,9 +346,10 @@ xml191_parse_text_props (xmlNodePtr  object_node,
        gl_label_object_set_font_size (GL_LABEL_OBJECT(object), font_size);
        gl_label_object_set_font_weight (GL_LABEL_OBJECT(object), font_weight);
        gl_label_object_set_font_italic_flag (GL_LABEL_OBJECT(object), font_italic_flag);
-       gl_label_object_set_text_color (GL_LABEL_OBJECT(object), color);
+       gl_label_object_set_text_color (GL_LABEL_OBJECT(object), color_node);
        gl_label_object_set_text_alignment (GL_LABEL_OBJECT(object), just);
 
+       gl_color_node_free (&color_node);
        gl_text_node_lines_free (&lines);
        g_free (font_family);
 
@@ -365,7 +367,8 @@ xml191_parse_box_props (xmlNodePtr  node,
 {
        GObject *object;
        gdouble  line_width;
-       guint    line_color, fill_color;
+       glColorNode *line_color_node;
+       glColorNode *fill_color_node;
        gdouble  w, h;
 
        gl_debug (DEBUG_XML, "START");
@@ -377,14 +380,19 @@ xml191_parse_box_props (xmlNodePtr  node,
 
        line_width = gl_xml_get_prop_length (node, "line_width", 1.0);
 
-       line_color = gl_xml_get_prop_uint (node, "line_color", 0);
-       fill_color = gl_xml_get_prop_uint (node, "fill_color", 0);
+       line_color_node = gl_color_node_new_default ();
+       line_color_node->color = gl_xml_get_prop_uint (node, "line_color", 0);
+       
+       fill_color_node = gl_color_node_new_default ();
+       fill_color_node->color = gl_xml_get_prop_uint (node, "fill_color", 0);
 
        gl_label_object_set_size (GL_LABEL_OBJECT(object), w, h);
        gl_label_object_set_line_width (GL_LABEL_OBJECT(object), line_width);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color);
-       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color);
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color_node);
 
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
        gl_debug (DEBUG_XML, "END");
 
        return GL_LABEL_OBJECT(object);
@@ -399,7 +407,7 @@ xml191_parse_line_props (xmlNodePtr  node,
 {
        GObject *object;
        gdouble  line_width;
-       guint    line_color;
+       glColorNode  *line_color_node;
        gdouble  w, h;
 
        gl_debug (DEBUG_XML, "START");
@@ -411,11 +419,14 @@ xml191_parse_line_props (xmlNodePtr  node,
 
        line_width = gl_xml_get_prop_length (node, "line_width", 1.0);
 
-       line_color = gl_xml_get_prop_uint (node, "line_color", 0);
+       line_color_node = gl_color_node_new_default ();
+       line_color_node->color = gl_xml_get_prop_uint (node, "line_color", 0);
 
        gl_label_object_set_size (GL_LABEL_OBJECT(object), w, h);
        gl_label_object_set_line_width (GL_LABEL_OBJECT(object), line_width);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color);
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+
+       gl_color_node_free (&line_color_node);
 
        gl_debug (DEBUG_XML, "END");
 
@@ -431,7 +442,8 @@ xml191_parse_ellipse_props (xmlNodePtr  node,
 {
        GObject *object;
        gdouble  line_width;
-       guint    line_color, fill_color;
+       glColorNode *line_color_node;
+       glColorNode *fill_color_node;
        gdouble  w, h;
 
        gl_debug (DEBUG_XML, "START");
@@ -443,14 +455,19 @@ xml191_parse_ellipse_props (xmlNodePtr  node,
 
        line_width = gl_xml_get_prop_length (node, "line_width", 1.0);
 
-       line_color = gl_xml_get_prop_uint (node, "line_color", 0);
-       fill_color = gl_xml_get_prop_uint (node, "fill_color", 0);
+       line_color_node = gl_color_node_new_default ();
+       line_color_node->color = gl_xml_get_prop_uint (node, "line_color", 0);
+       
+       fill_color_node = gl_color_node_new_default ();
+       fill_color_node->color = gl_xml_get_prop_uint (node, "fill_color", 0);
 
        gl_label_object_set_size (GL_LABEL_OBJECT(object), w, h);
        gl_label_object_set_line_width (GL_LABEL_OBJECT(object), line_width);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color);
-       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color);
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color_node);
 
+       gl_color_node_free (&line_color_node);
+       gl_color_node_free (&fill_color_node);
        gl_debug (DEBUG_XML, "END");
 
        return GL_LABEL_OBJECT(object);
@@ -513,7 +530,7 @@ xml191_parse_barcode_props (xmlNodePtr  node,
        gchar              *id;
        gboolean            text_flag;
        gboolean            checksum_flag;
-       guint               color;
+       glColorNode        *color_node;
 
        gl_debug (DEBUG_XML, "START");
 
@@ -522,7 +539,8 @@ xml191_parse_barcode_props (xmlNodePtr  node,
        w = gl_xml_get_prop_length (node, "w", 0);
        h = gl_xml_get_prop_length (node, "h", 0);
 
-       color = gl_xml_get_prop_uint (node, "color", 0);
+       color_node = gl_color_node_new_default ();
+       color_node->color = gl_xml_get_prop_uint (node, "color", 0);
 
        id = xmlGetProp (node, "style");
 
@@ -547,8 +565,9 @@ xml191_parse_barcode_props (xmlNodePtr  node,
        gl_label_barcode_set_data (GL_LABEL_BARCODE(object), text_node);
        gl_label_barcode_set_props (GL_LABEL_BARCODE(object),
                                    id, text_flag, checksum_flag, 0);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), color);
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), color_node);
 
+       gl_color_node_free (&color_node);       
        gl_text_node_free (&text_node);
        g_free (id);
 
@@ -904,4 +923,3 @@ xml191_parse_alias (xmlNodePtr  alias_node,
 
        gl_debug (DEBUG_TEMPLATE, "END");
 }
-
index 5f51e91ee56c28c832376eab03751a62df49fd0a..f420a2d2c438efc9463f7192e43de63a3519794e 100644 (file)
@@ -471,12 +471,14 @@ static void
 xml_parse_object_box (xmlNodePtr  node,
                      glLabel    *label)
 {
-       GObject *object;
-       gdouble  x, y;
-       gdouble  w, h;
-       gdouble  line_width;
-       guint    line_color, fill_color;
-       gdouble  affine[6];
+       GObject      *object;
+       gdouble       x, y;
+       gdouble       w, h;
+       gdouble       line_width;
+       glColorNode  *line_color_node;
+       gdouble       affine[6];
+       gchar        *string;
+       glColorNode  *fill_color_node;
 
        gl_debug (DEBUG_XML, "START");
 
@@ -494,14 +496,32 @@ xml_parse_object_box (xmlNodePtr  node,
 
        /* line attrs */
        line_width = gl_xml_get_prop_length (node, "line_width", 1.0);
-       line_color = gl_xml_get_prop_uint (node, "line_color", 0);
        gl_label_object_set_line_width (GL_LABEL_OBJECT(object), line_width);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color);
+       
+       line_color_node = gl_color_node_new_default ();
+       string = xmlGetProp (node, "line_color_field");
+       if ( string ) {
+               line_color_node->field_flag = TRUE;
+               line_color_node->key = string;
+       } else {
+               line_color_node->color = gl_xml_get_prop_uint (node, "line_color", 0);
+       }
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+       gl_color_node_free (&line_color_node);
 
-       /* fill attrs */
-       fill_color = gl_xml_get_prop_uint (node, "fill_color", 0);
-       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color);
 
+       /* fill attrs */
+       fill_color_node = gl_color_node_new_default ();
+       string = xmlGetProp (node, "fill_color_field");
+       if ( string ) {
+               fill_color_node->field_flag = TRUE;
+               fill_color_node->key = string;
+       } else {
+               fill_color_node->color = gl_xml_get_prop_uint (node, "fill_color", 0);
+       }
+       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color_node);
+       gl_color_node_free (&fill_color_node);
+       
        /* affine attrs */
        affine[0] = gl_xml_get_prop_double (node, "a0", 0.0);
        affine[1] = gl_xml_get_prop_double (node, "a1", 0.0);
@@ -521,12 +541,14 @@ static void
 xml_parse_object_ellipse (xmlNodePtr  node,
                          glLabel    *label)
 {
-       GObject *object;
-       gdouble  x, y;
-       gdouble  w, h;
-       gdouble  line_width;
-       guint    line_color, fill_color;
-       gdouble  affine[6];
+       GObject     *object;
+       gdouble      x, y;
+       gdouble      w, h;
+       gdouble      line_width;
+       glColorNode *line_color_node;
+       gdouble      affine[6];
+       gchar       *string;
+       glColorNode *fill_color_node;
 
        gl_debug (DEBUG_XML, "START");
 
@@ -544,13 +566,31 @@ xml_parse_object_ellipse (xmlNodePtr  node,
 
        /* line attrs */
        line_width = gl_xml_get_prop_length (node, "line_width", 1.0);
-       line_color = gl_xml_get_prop_uint (node, "line_color", 0);
        gl_label_object_set_line_width (GL_LABEL_OBJECT(object), line_width);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color);
+
+       line_color_node = gl_color_node_new_default ();
+       string = xmlGetProp (node, "line_color_field");
+       if ( string ) {
+               line_color_node->field_flag = TRUE;
+               line_color_node->key = string;
+       } else {
+               line_color_node->color = gl_xml_get_prop_uint (node, "line_color", 0);          
+       }
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+       gl_color_node_free (&line_color_node);
+
 
        /* fill attrs */
-       fill_color = gl_xml_get_prop_uint (node, "fill_color", 0);
-       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color);
+       fill_color_node = gl_color_node_new_default ();
+       string = xmlGetProp (node, "fill_color_field");
+       if ( string ) {
+               fill_color_node->field_flag = TRUE;
+               fill_color_node->key = string;
+       } else {
+               fill_color_node->color = gl_xml_get_prop_uint (node, "fill_color", 0);
+       }
+       gl_label_object_set_fill_color (GL_LABEL_OBJECT(object), fill_color_node);
+       gl_color_node_free (&fill_color_node);
 
        /* affine attrs */
        affine[0] = gl_xml_get_prop_double (node, "a0", 0.0);
@@ -571,12 +611,13 @@ static void
 xml_parse_object_line (xmlNodePtr  node,
                       glLabel    *label)
 {
-       GObject *object;
-       gdouble  x, y;
-       gdouble  dx, dy;
-       gdouble  line_width;
-       guint    line_color;
-       gdouble  affine[6];
+       GObject     *object;
+       gdouble      x, y;
+       gdouble      dx, dy;
+       gdouble      line_width;
+       glColorNode *line_color_node;
+       gdouble      affine[6];
+       gchar       *string;
 
        gl_debug (DEBUG_XML, "START");
 
@@ -594,9 +635,18 @@ xml_parse_object_line (xmlNodePtr  node,
 
        /* line attrs */
        line_width = gl_xml_get_prop_length (node, "line_width", 1.0);
-       line_color = gl_xml_get_prop_uint (node, "line_color", 0);
        gl_label_object_set_line_width (GL_LABEL_OBJECT(object), line_width);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color);
+       
+       line_color_node = gl_color_node_new_default ();
+       string = xmlGetProp (node, "line_color_field");
+       if ( string ) {
+               line_color_node->field_flag = TRUE;
+               line_color_node->key = string;
+       } else {
+               line_color_node->color = gl_xml_get_prop_uint (node, "line_color", 0);          
+       }
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), line_color_node);
+       gl_color_node_free (&line_color_node);
 
        /* affine attrs */
        affine[0] = gl_xml_get_prop_double (node, "a0", 0.0);
@@ -686,7 +736,7 @@ xml_parse_object_barcode (xmlNodePtr  node,
        gchar              *id;
        gboolean            text_flag;
        gboolean            checksum_flag;
-       guint               color;
+       glColorNode        *color_node;
        guint               format_digits;
        gdouble             affine[6];
 
@@ -708,12 +758,21 @@ xml_parse_object_barcode (xmlNodePtr  node,
        id = xmlGetProp (node, "style");
        text_flag = gl_xml_get_prop_boolean (node, "text", FALSE);
        checksum_flag = gl_xml_get_prop_boolean (node, "checksum", TRUE);
-       color = gl_xml_get_prop_uint (node, "color", 0);
        format_digits = gl_xml_get_prop_uint (node, "format", 10);
        gl_label_barcode_set_props (GL_LABEL_BARCODE(object),
                                    id, text_flag, checksum_flag, format_digits);
-       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), color);
        g_free (id);
+       
+       color_node = gl_color_node_new_default ();
+       string = xmlGetProp (node, "color_field");
+       if ( string ) {
+               color_node->field_flag = TRUE;
+               color_node->key = string;
+       } else {
+               color_node->color = gl_xml_get_prop_uint (node, "color", 0);            
+       }
+       gl_label_object_set_line_color (GL_LABEL_OBJECT(object), color_node);
+       gl_color_node_free (&color_node);
 
        /* data or field attr */
        string = xmlGetProp (node, "data");
@@ -852,7 +911,7 @@ xml_parse_toplevel_span  (xmlNodePtr        node,
        gdouble           font_size;
        GnomeFontWeight   font_weight;
        gboolean          font_italic_flag;
-       guint             color;
+       glColorNode      *color_node;
        gdouble           text_line_spacing;
        gchar            *string;
        GList            *lines, *text_nodes;
@@ -881,8 +940,17 @@ xml_parse_toplevel_span  (xmlNodePtr        node,
        gl_label_object_set_font_italic_flag (object, font_italic_flag);
 
        /* Text color attr */
-       color = gl_xml_get_prop_uint (node, "color", 0);
-       gl_label_object_set_text_color (object, color);
+       color_node = gl_color_node_new_default ();
+       string = xmlGetProp (node, "color_field");
+       if ( string ) {
+               color_node->field_flag = TRUE;
+               color_node->key = string;
+       } else {
+               color_node->color = gl_xml_get_prop_uint (node, "color", 0);            
+       }
+       gl_label_object_set_text_color (object, color_node);
+       gl_color_node_free (&color_node);
+       
 
        /* Text line spacing attr  */
        text_line_spacing = gl_xml_get_prop_double (node, "line_spacing", 1.0);
@@ -1158,8 +1226,9 @@ xml_create_object_box (xmlNodePtr     root,
        gdouble           x, y;
        gdouble           w, h;
        gdouble           line_width;
-       guint             line_color, fill_color;
+       glColorNode      *line_color_node;
        gdouble           affine[6];
+       glColorNode *fill_color_node;
 
        gl_debug (DEBUG_XML, "START");
 
@@ -1177,13 +1246,30 @@ xml_create_object_box (xmlNodePtr     root,
 
        /* line attrs */
        line_width = gl_label_object_get_line_width (GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
        gl_xml_set_prop_length (node, "line_width", line_width);
-       gl_xml_set_prop_uint_hex (node, "line_color", line_color);
+       
+       line_color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       if (line_color_node->field_flag)
+       {
+               xmlSetProp (node, "line_color_field", line_color_node->key);
+       }
+       else
+       {
+               gl_xml_set_prop_uint_hex (node, "line_color", line_color_node->color);
+       }
+       gl_color_node_free (&line_color_node);
 
-       /* fill attrs */
-       fill_color = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
-       gl_xml_set_prop_uint_hex (node, "fill_color", fill_color);
+       /* fill attrs (color or field) */
+       fill_color_node = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
+       if (fill_color_node->field_flag)
+       {
+               xmlSetProp (node, "fill_color_field", fill_color_node->key);
+       }
+       else
+       {
+               gl_xml_set_prop_uint_hex (node, "fill_color", fill_color_node->color);
+       }
+       gl_color_node_free (&fill_color_node);
 
        /* affine attrs */
        gl_label_object_get_affine (object, affine);
@@ -1209,8 +1295,9 @@ xml_create_object_ellipse (xmlNodePtr     root,
        gdouble           x, y;
        gdouble           w, h;
        gdouble           line_width;
-       guint             line_color, fill_color;
+       glColorNode      *line_color_node;
        gdouble           affine[6];
+       glColorNode *fill_color_node;
 
        gl_debug (DEBUG_XML, "START");
 
@@ -1228,13 +1315,31 @@ xml_create_object_ellipse (xmlNodePtr     root,
 
        /* line attrs */
        line_width = gl_label_object_get_line_width (GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
        gl_xml_set_prop_length (node, "line_width", line_width);
-       gl_xml_set_prop_uint_hex (node, "line_color", line_color);
+       
+       line_color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       if (line_color_node->field_flag)
+       {
+               xmlSetProp (node, "line_color_field", line_color_node->key);
+       }
+       else
+       {
+               gl_xml_set_prop_uint_hex (node, "line_color", line_color_node->color);
+       }
+       gl_color_node_free (&line_color_node);
 
-       /* fill attrs */
-       fill_color = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
-       gl_xml_set_prop_uint_hex (node, "fill_color", fill_color);
+
+       /* fill attrs (color or field) */
+       fill_color_node = gl_label_object_get_fill_color (GL_LABEL_OBJECT(object));
+       if (fill_color_node->field_flag)
+       {
+               xmlSetProp (node, "fill_color_field", fill_color_node->key);
+       }
+       else
+       {
+               gl_xml_set_prop_uint_hex (node, "fill_color", fill_color_node->color);
+       }
+       gl_color_node_free (&fill_color_node);
 
        /* affine attrs */
        gl_label_object_get_affine (object, affine);
@@ -1260,7 +1365,7 @@ xml_create_object_line (xmlNodePtr     root,
        gdouble           x, y;
        gdouble           dx, dy;
        gdouble           line_width;
-       guint             line_color;
+       glColorNode      *line_color_node;
        gdouble           affine[6];
 
        gl_debug (DEBUG_XML, "START");
@@ -1279,9 +1384,19 @@ xml_create_object_line (xmlNodePtr     root,
 
        /* line attrs */
        line_width = gl_label_object_get_line_width (GL_LABEL_OBJECT(object));
-       line_color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
        gl_xml_set_prop_length (node, "line_width", line_width);
-       gl_xml_set_prop_uint_hex (node, "line_color", line_color);
+       
+       line_color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       if (line_color_node->field_flag)
+       {
+               xmlSetProp (node, "line_color_field", line_color_node->key);
+       }
+       else
+       {
+               gl_xml_set_prop_uint_hex (node, "line_color", line_color_node->color);
+       }
+       gl_color_node_free (&line_color_node);
+
 
        /* affine attrs */
        gl_label_object_get_affine (object, affine);
@@ -1359,7 +1474,7 @@ xml_create_object_barcode (xmlNodePtr     root,
        gchar            *id;
        gboolean          text_flag;
        gboolean          checksum_flag;
-       guint             color;
+       glColorNode      *color_node;
        guint             format_digits;
        gdouble           affine[6];
 
@@ -1380,12 +1495,23 @@ xml_create_object_barcode (xmlNodePtr     root,
        /* Barcode properties attrs */
        gl_label_barcode_get_props (GL_LABEL_BARCODE(object),
                                    &id, &text_flag, &checksum_flag, &format_digits);
-       color = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
        xmlSetProp (node, "style", id);
        gl_xml_set_prop_boolean (node, "text", text_flag);
        gl_xml_set_prop_boolean (node, "checksum", checksum_flag);
-       gl_xml_set_prop_uint_hex (node, "color", color);
+       
        g_free (id);
+       
+       color_node = gl_label_object_get_line_color (GL_LABEL_OBJECT(object));
+       if (color_node->field_flag)
+       {
+               xmlSetProp (node, "color_field", color_node->key);
+       }
+       else
+       {
+               gl_xml_set_prop_uint_hex (node, "color", color_node->color);
+       }
+       gl_color_node_free (&color_node);
+
 
        /* data OR field attr */
        text_node = gl_label_barcode_get_data (GL_LABEL_BARCODE(object));
@@ -1527,7 +1653,7 @@ xml_create_toplevel_span (xmlNodePtr        root,
        gdouble           font_size;
        GnomeFontWeight   font_weight;
        gboolean          font_italic_flag;
-       guint             color;
+       glColorNode      *color_node;
        GtkJustification  just;
        gdouble           text_line_spacing;
        GList            *lines, *p_line, *p_node;
@@ -1542,13 +1668,24 @@ xml_create_toplevel_span (xmlNodePtr        root,
        text_line_spacing = gl_label_object_get_text_line_spacing (GL_LABEL_OBJECT(object_text));
        font_weight = gl_label_object_get_font_weight (GL_LABEL_OBJECT(object_text));
        font_italic_flag = gl_label_object_get_font_italic_flag (GL_LABEL_OBJECT(object_text));
-       color = gl_label_object_get_text_color (GL_LABEL_OBJECT(object_text));
+       
+       color_node = gl_label_object_get_text_color (GL_LABEL_OBJECT(object_text));
+       if (color_node->field_flag)
+       {
+               xmlSetProp (node, "color_field", color_node->key);
+       }
+       else
+       {
+               gl_xml_set_prop_uint_hex (node, "color", color_node->color);
+       }
+       gl_color_node_free (&color_node);
+       
        just = gl_label_object_get_text_alignment (GL_LABEL_OBJECT(object_text));
        xmlSetProp (node, "font_family", font_family);
        gl_xml_set_prop_double (node, "font_size", font_size);
        xmlSetProp (node, "font_weight", gl_util_weight_to_string (font_weight));
        gl_xml_set_prop_boolean (node, "font_italic", font_italic_flag);
-       gl_xml_set_prop_uint_hex (node, "color", color);
+       
        gl_xml_set_prop_double (node, "line_spacing", text_line_spacing);
 
        /* Build children. */