From b132259e00150627c23cbcb9ffdf8bff19e041bc Mon Sep 17 00:00:00 2001 From: Jim Evins Date: Tue, 29 Mar 2016 19:51:50 -0400 Subject: [PATCH] Added Datamatrix with GS1 input mode barcode type to zint backend. --- src/bc-backends.c | 3 +++ src/bc-zint.c | 2 ++ 2 files changed, 5 insertions(+) diff --git a/src/bc-backends.c b/src/bc-backends.c index 5ff8f56c..0758f59d 100644 --- a/src/bc-backends.c +++ b/src/bc-backends.c @@ -269,6 +269,9 @@ static const Style styles[] = { { "zint", "DMTX", N_("Data Matrix"), gl_barcode_zint_new, FALSE, FALSE, TRUE, FALSE, "0000000000", TRUE, 10}, + { "zint", "DMTX-GS1", N_("Data Matrix (GS1)"), gl_barcode_zint_new, + FALSE, FALSE, TRUE, FALSE, "0000000000", TRUE, 10}, + { "zint", "DPL", N_("Deutsche Post Leitcode"), gl_barcode_zint_new, TRUE, TRUE, TRUE, FALSE, "1234567890123", TRUE, 13}, diff --git a/src/bc-zint.c b/src/bc-zint.c index 015196e3..4b533348 100644 --- a/src/bc-zint.c +++ b/src/bc-zint.c @@ -93,6 +93,8 @@ gl_barcode_zint_new (const gchar *id, if (g_ascii_strcasecmp (id, "Code128B") == 0) { symbol->symbology = BARCODE_CODE128B; } if (g_ascii_strcasecmp (id, "DAFT") == 0) { symbol->symbology = BARCODE_DAFT; } if (g_ascii_strcasecmp (id, "DMTX") == 0) { symbol->symbology = BARCODE_DATAMATRIX; } + if (g_ascii_strcasecmp (id, "DMTX-GS1") == 0) { symbol->symbology = BARCODE_DATAMATRIX; + symbol->input_mode = GS1_MODE; } if (g_ascii_strcasecmp (id, "DPL") == 0) { symbol->symbology = BARCODE_DPLEIT; } if (g_ascii_strcasecmp (id, "DPI") == 0) { symbol->symbology = BARCODE_DPIDENT; } if (g_ascii_strcasecmp (id, "KIX") == 0) { symbol->symbology = BARCODE_KIX; } -- 2.39.5