From 4d42d2cdb0267a4a7a702ddea96ad03afe5774ce Mon Sep 17 00:00:00 2001 From: Jim Evins Date: Sat, 11 Aug 2007 03:08:52 +0000 Subject: [PATCH] 2007-08-10 Jim Evins MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit * src/bc-postnet.c: (gl_barcode_postnet_new): * src/bc.c: Added support for Brazilian CEPNet barcodes. This is simply an instance of the US POSTNET format with 8 digits. Patch supplied by Mário Meyer in bug # 1768792. * AUTHORS: Updated acknowledgments to reflect above patch and recent shuffling of underlying technology. git-svn-id: https://glabels.svn.sourceforge.net/svnroot/glabels/trunk@663 f5e0f49d-192f-0410-a22d-a8d8700d0965 --- glabels2/AUTHORS | 21 ++++++--------------- glabels2/ChangeLog | 11 +++++++++++ glabels2/src/bc-postnet.c | 5 +++++ glabels2/src/bc.c | 3 +++ 4 files changed, 25 insertions(+), 15 deletions(-) diff --git a/glabels2/AUTHORS b/glabels2/AUTHORS index 70e0c4da..24ac08e9 100644 --- a/glabels2/AUTHORS +++ b/glabels2/AUTHORS @@ -6,33 +6,23 @@ Jim Evins Acknowledgments =============== -The GNU Barcode Library provides a large chunk of the barcode functionality +- The GNU Barcode Library provides a large chunk of the barcode functionality and is distributed with glabels. See ./barcode-0.98/README for more information. The author: Alessandro Rubini +- The iec16022 library provides encoding for 2D barcodes. See +iec16022-0.2.1/README for more information. -I borrowed the hacktext canvas item from libgnomeprint to render text that -is faithful to the final printed product. Original authors of the hacktext -canvas item: - - Federico Mena , - Raph Levien , - Lauris Kaplinski - -Glabels includes modified versions of several widgets from the GAL library. +- Glabels includes modified versions of several widgets from the GAL library. These are copyright: * Copyright 2000, 2001, Ximian, Inc. * Copyright 2000, Michael Levy * Copyright 2001, Almer S. Tigelaar -Glabels includes gnome-recent objects. The author: - - James Willcox - -Glabels includes a modified version of the gimpchainbutton widget from the +- Glabels includes a modified version of the gimpchainbutton widget from the gimp, as well as several stock icons from the gimp's default theme. These are copyright: @@ -53,6 +43,7 @@ Glabels includes contributions from: José Dapena Paz Akkana Dag Wieers + Mário Meyer Translations: diff --git a/glabels2/ChangeLog b/glabels2/ChangeLog index 4c964c56..4ba02d4d 100644 --- a/glabels2/ChangeLog +++ b/glabels2/ChangeLog @@ -1,3 +1,14 @@ +2007-08-10 Jim Evins + + * src/bc-postnet.c: (gl_barcode_postnet_new): + * src/bc.c: + Added support for Brazilian CEPNet barcodes. This is simply an + instance of the US POSTNET format with 8 digits. Patch supplied + by Mário Meyer in bug # 1768792. + * AUTHORS: + Updated acknowledgments to reflect above patch and recent shuffling + of underlying technology. + 2007-05-13 Jim Evins * src/merge-text.c: (parse_line), (parse_field): diff --git a/glabels2/src/bc-postnet.c b/glabels2/src/bc-postnet.c index 1db1df18..5b710c09 100644 --- a/glabels2/src/bc-postnet.c +++ b/glabels2/src/bc-postnet.c @@ -114,6 +114,11 @@ gl_barcode_postnet_new (const gchar *id, return NULL; } } + if ( (g_strcasecmp (id, "CEPNET") == 0) ) { + if (!is_length_valid (digits, 8)) { + return NULL; + } + } /* First get code string */ code = postnet_code (digits); diff --git a/glabels2/src/bc.c b/glabels2/src/bc.c index 9b78b023..89de2fbb 100644 --- a/glabels2/src/bc.c +++ b/glabels2/src/bc.c @@ -76,6 +76,9 @@ static const Backend backends[] = { { "POSTNET-11", N_("POSTNET-11 (DPBC)"), gl_barcode_postnet_new, FALSE, FALSE, TRUE, FALSE, "12345-6789-12", FALSE, 11}, + { "CEPNET", N_("CEPNET"), gl_barcode_postnet_new, + FALSE, FALSE, TRUE, FALSE, "12345-678", FALSE, 8}, + { "EAN", N_("EAN (any)"), gl_barcode_gnubarcode_new, TRUE, TRUE, TRUE, FALSE, "000000000000 00000", FALSE, 17}, -- 2.39.5