From 9d21b20ed765ef3f924a9ee48158cde94f707022 Mon Sep 17 00:00:00 2001 From: Sam Lown Date: Tue, 6 Jul 2010 15:50:29 +0200 Subject: [PATCH] Adding Robin's changes for latest Zint --- src/bc-zint.c | 216 +++++++++++++++++++++++++++----------------------- src/bc.c | 201 ++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 311 insertions(+), 106 deletions(-) diff --git a/src/bc-zint.c b/src/bc-zint.c index 8db2c132..c50160fc 100644 --- a/src/bc-zint.c +++ b/src/bc-zint.c @@ -59,31 +59,86 @@ gl_barcode_zint_new (const gchar *id, { glBarcode *gbc; struct zint_symbol *symbol; - gint type; - gint result; - gchar errtxt[100]; + gint type; + gint result; symbol = ZBarcode_Create(); - /* Auto set to default size */ - if ( (w == 0) && (h == 0) ) - { - w = DEFAULT_W; - h = DEFAULT_H; - } + /* Auto set to default size */ + if ( (w == 0) && (h == 0) ) + { + w = DEFAULT_W; + h = DEFAULT_H; + } /* Assign type flag. Pre-filter by length for subtypes. */ - if (g_ascii_strcasecmp (id, "GS1-128") == 0) { - symbol->symbology = BARCODE_EAN128; - } else if (g_ascii_strcasecmp (id, "GTIN-13") == 0) { - symbol->symbology = BARCODE_EANX; - } else if (g_ascii_strcasecmp (id, "GTIN-14") == 0) { - symbol->symbology = BARCODE_EAN14; - } else { - g_message( "Illegal barcode id %s", id ); - ZBarcode_Delete (symbol); - return NULL; - } + if (g_ascii_strcasecmp (id, "AUSP") == 0) { symbol->symbology = BARCODE_AUSPOST; } + if (g_ascii_strcasecmp (id, "AUSRP") == 0) { symbol->symbology = BARCODE_AUSREPLY; } + if (g_ascii_strcasecmp (id, "AUSRT") == 0) { symbol->symbology = BARCODE_AUSROUTE; } + if (g_ascii_strcasecmp (id, "AUSRD") == 0) { symbol->symbology = BARCODE_AUSREDIRECT; } + if (g_ascii_strcasecmp (id, "AZTEC") == 0) { symbol->symbology = BARCODE_AZTEC; } + if (g_ascii_strcasecmp (id, "AZRUN") == 0) { symbol->symbology = BARCODE_AZRUNE; } + if (g_ascii_strcasecmp (id, "CBR") == 0) { symbol->symbology = BARCODE_CODABAR; } + if (g_ascii_strcasecmp (id, "Code1") == 0) { symbol->symbology = BARCODE_CODEONE; } + if (g_ascii_strcasecmp (id, "Code11") == 0) { symbol->symbology = BARCODE_CODE11; } + if (g_ascii_strcasecmp (id, "C16K") == 0) { symbol->symbology = BARCODE_CODE16K; } + if (g_ascii_strcasecmp (id, "C25M") == 0) { symbol->symbology = BARCODE_C25MATRIX; } + if (g_ascii_strcasecmp (id, "C25I") == 0) { symbol->symbology = BARCODE_C25IATA; } + if (g_ascii_strcasecmp (id, "C25DL") == 0) { symbol->symbology = BARCODE_C25LOGIC; } + if (g_ascii_strcasecmp (id, "Code32") == 0) { symbol->symbology = BARCODE_CODE32; } + if (g_ascii_strcasecmp (id, "Code39") == 0) { symbol->symbology = BARCODE_CODE39; } + if (g_ascii_strcasecmp (id, "Code39E") == 0) { symbol->symbology = BARCODE_EXCODE39; } + if (g_ascii_strcasecmp (id, "Code49") == 0) { symbol->symbology = BARCODE_CODE49; } + if (g_ascii_strcasecmp (id, "Code93") == 0) { symbol->symbology = BARCODE_CODE93; } + if (g_ascii_strcasecmp (id, "Code128") == 0) { symbol->symbology = BARCODE_CODE128; } + 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, "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; } + if (g_ascii_strcasecmp (id, "EAN") == 0) { symbol->symbology = BARCODE_EANX; } + if (g_ascii_strcasecmp (id, "HIBC128") == 0) { symbol->symbology = BARCODE_HIBC_128; } + if (g_ascii_strcasecmp (id, "HIBC39") == 0) { symbol->symbology = BARCODE_HIBC_39; } + if (g_ascii_strcasecmp (id, "HIBCDM") == 0) { symbol->symbology = BARCODE_HIBC_DM; } + if (g_ascii_strcasecmp (id, "HIBCQR") == 0) { symbol->symbology = BARCODE_HIBC_QR; } + if (g_ascii_strcasecmp (id, "HIBCPDF") == 0) { symbol->symbology = BARCODE_HIBC_MICPDF; } + if (g_ascii_strcasecmp (id, "HIBCMPDF") == 0) { symbol->symbology = BARCODE_HIBC_AZTEC; } + if (g_ascii_strcasecmp (id, "HIBCAZ") == 0) { symbol->symbology = BARCODE_C25INTER; } + if (g_ascii_strcasecmp (id, "I25") == 0) { symbol->symbology = BARCODE_C25INTER; } + if (g_ascii_strcasecmp (id, "ISBN") == 0) { symbol->symbology = BARCODE_ISBNX; } + if (g_ascii_strcasecmp (id, "ITF14") == 0) { symbol->symbology = BARCODE_ITF14; } + if (g_ascii_strcasecmp (id, "GMTX") == 0) { symbol->symbology = BARCODE_GRIDMATRIX; } + if (g_ascii_strcasecmp (id, "GS1-128") == 0) { symbol->symbology = BARCODE_EAN128; } + if (g_ascii_strcasecmp (id, "LOGM") == 0) { symbol->symbology = BARCODE_LOGMARS; } + if (g_ascii_strcasecmp (id, "RSS14") == 0) { symbol->symbology = BARCODE_RSS14; } + if (g_ascii_strcasecmp (id, "RSSLTD") == 0) { symbol->symbology = BARCODE_RSS_LTD; } + if (g_ascii_strcasecmp (id, "RSSEXP") == 0) { symbol->symbology = BARCODE_RSS_EXP; } + if (g_ascii_strcasecmp (id, "RSSS") == 0) { symbol->symbology = BARCODE_RSS14STACK; } + if (g_ascii_strcasecmp (id, "RSSSO") == 0) { symbol->symbology = BARCODE_RSS14STACK_OMNI; } + if (g_ascii_strcasecmp (id, "RSSSE") == 0) { symbol->symbology = BARCODE_RSS_EXPSTACK; } + if (g_ascii_strcasecmp (id, "PHARMA") == 0) { symbol->symbology = BARCODE_PHARMA; } + if (g_ascii_strcasecmp (id, "PHARMA2") == 0) { symbol->symbology = BARCODE_PHARMA_TWO; } + if (g_ascii_strcasecmp (id, "PZN") == 0) { symbol->symbology = BARCODE_PZN; } + if (g_ascii_strcasecmp (id, "TELE") == 0) { symbol->symbology = BARCODE_TELEPEN; } + if (g_ascii_strcasecmp (id, "TELEX") == 0) { symbol->symbology = BARCODE_TELEPEN_NUM; } + if (g_ascii_strcasecmp (id, "JAPAN") == 0) { symbol->symbology = BARCODE_JAPANPOST; } + if (g_ascii_strcasecmp (id, "KOREA") == 0) { symbol->symbology = BARCODE_KOREAPOST; } + if (g_ascii_strcasecmp (id, "MPDF") == 0) { symbol->symbology = BARCODE_MICROPDF417; } + if (g_ascii_strcasecmp (id, "MSI") == 0) { symbol->symbology = BARCODE_MSI_PLESSEY; } + if (g_ascii_strcasecmp (id, "MQR") == 0) { symbol->symbology = BARCODE_MICROQR; } + if (g_ascii_strcasecmp (id, "NVE") == 0) { symbol->symbology = BARCODE_NVE18; } + if (g_ascii_strcasecmp (id, "PLAN") == 0) { symbol->symbology = BARCODE_PLANET; } + if (g_ascii_strcasecmp (id, "POSTNET") == 0) { symbol->symbology = BARCODE_POSTNET; } + if (g_ascii_strcasecmp (id, "PDF") == 0) { symbol->symbology = BARCODE_PDF417; } + if (g_ascii_strcasecmp (id, "PDFT") == 0) { symbol->symbology = BARCODE_PDF417TRUNC; } + if (g_ascii_strcasecmp (id, "QR") == 0) { symbol->symbology = BARCODE_QRCODE; } + if (g_ascii_strcasecmp (id, "RM4") == 0) { symbol->symbology = BARCODE_RM4SCC; } + if (g_ascii_strcasecmp (id, "UPC-A") == 0) { symbol->symbology = BARCODE_UPCA; } + if (g_ascii_strcasecmp (id, "UPC-E") == 0) { symbol->symbology = BARCODE_UPCE; } + if (g_ascii_strcasecmp (id, "USPS") == 0) { symbol->symbology = BARCODE_ONECODE; } + if (g_ascii_strcasecmp (id, "PLS") == 0) { symbol->symbology = BARCODE_PLESSEY; } + /* Checksum not supported yet!! if (!checksum_flag) { @@ -94,29 +149,17 @@ gl_barcode_zint_new (const gchar *id, result = ZBarcode_Encode(symbol, (unsigned char *)digits, 0); if (result) { gl_debug (DEBUG_BARCODE, "Zint Error: %s", symbol->errtxt); - strcpy(errtxt, symbol->errtxt); ZBarcode_Delete (symbol); - // Invalid! Print out a Code128 barcode instead with message - symbol = ZBarcode_Create(); - symbol->symbology = BARCODE_CODE128; - result = ZBarcode_Encode(symbol, (unsigned char *)errtxt, 0); - if (result) { - gl_debug (DEBUG_BARCODE, "Zint Error: %s", symbol->errtxt); - ZBarcode_Delete (symbol); - return NULL; - } + return NULL; + } + + if(!text_flag) { + symbol->show_hrt = 0; } - /* Scale calculated after height, always maintain aspect ratio */ - symbol->scale = (w / symbol->width); - symbol->height = h / symbol->scale; // height always in standard size - - /* - * With the size and scale set, send a request to Zint renderer - */ - if (!ZBarcode_Render(symbol, (unsigned int) !text_flag, (float) w, (float) h)) { + if (!ZBarcode_Render(symbol, (float) w, (float) h)) { + g_message("Zint Rendering Error: %s", symbol->errtxt); ZBarcode_Delete(symbol); - gl_debug(DEBUG_BARCODE, "Zint Rendering Error: %s", symbol->errtxt); return NULL; } @@ -130,91 +173,64 @@ gl_barcode_zint_new (const gchar *id, /*-------------------------------------------------------------------------- - * PRIVATE. Render to glBarcode the provided Zint Rendered Plot + * PRIVATE. Render to glBarcode the provided Zint symbol. * - * Takes the special zint_render structure and converts to glBarcode. + * Based on the SVG output from Zint library, handles lots of otherwise + * internal Zint code to convert directly to glBarcode representation. * *--------------------------------------------------------------------------*/ static glBarcode *render_zint(struct zint_symbol *symbol, gboolean text_flag) { + + int i; + double string_offset; - glBarcode *gbc; - glBarcodeLine *line; - glBarcodeChar *bchar; - - struct zint_render *render; - struct zint_render_line *zline; + glBarcode *gbc; + glBarcodeShapeLine *line; + glBarcodeShapeAlpha *bchar; + + struct zint_render *render; + struct zint_render_line *zline; struct zint_render_string *zstring; - gchar *p; - gint length; - gdouble xoffset, width, char_width; - render = symbol->rendered; gbc = g_new0(glBarcode, 1); + + + for ( zline = render->lines; zline != NULL; zline = zline->next ) { + line = gl_barcode_shape_line_new (); - /* - * Go through each line, alter the x position for centering, and add. - * Zint already applies the scaling factor. - */ - zline = render->lines; - while (zline) { - line = g_new0 (glBarcodeLine, 1); - - line->width = (gdouble) zline->width; - line->length = (gdouble) zline->length; + line->width = (double) zline->width; + line->length = (double) zline->length; /* glBarcodeLine centers based on width, counter-act!!! */ - line->x = (gdouble) (zline->x + (zline->width / 2.0)); - line->y = (gdouble) zline->y; + line->x = (double) (zline->x + (zline->width / 2.0)); + line->y = (double) zline->y; - gbc->lines = g_list_append (gbc->lines, line); - - // g_message ("Zint Adding Line at: %f x %f dim: %f x %f", line->x, line->y, line->width, line->length); - zline = zline->next; + gl_barcode_add_shape (gbc, (glBarcodeShape *)line); } /* * Repeat loop for characters */ - zstring = render->strings; - if (text_flag) { - while (zstring) { - - // Guess the first position based on width or number of characters - length = strlen(zstring->text); - width = zstring->width; - if (width > 0) { - char_width = width / length; - } else { - // No width, set our own by removing 30% of height - char_width = zstring->fsize - (zstring->fsize * 0.3); - width = char_width * length; - } - xoffset = zstring->x - (width / 2.0); - - for (p = (gchar *) zstring->text; *p != 0; p++) { - - bchar = g_new0 (glBarcodeChar, 1); - bchar->x = xoffset; - bchar->y = (gdouble) zstring->y; - bchar->fsize = (gdouble) zstring->fsize; - bchar->c = (gchar) *p; - - gbc->chars = g_list_append (gbc->chars, bchar); - - xoffset += char_width; - } - - zstring = zstring->next; + if(text_flag) { + for ( zstring = render->strings; zstring != NULL; zstring = zstring->next ) { + string_offset = (double) zstring->x - (((6.0 / 9.0) * zstring->length * zstring->fsize) / 2); + for(i = 0; i < zstring->length; i++) { + bchar = gl_barcode_shape_alpha_new(); + bchar->x = (double) string_offset + ((6.0 / 9.0) * i * zstring->fsize); + bchar->y = (double) zstring->y; + bchar->fsize = (double) zstring->fsize; + bchar->c = (char) zstring->text[i]; + gl_barcode_add_shape (gbc, (glBarcodeShape *)bchar); + } } } /* * Finally add complete sizes */ - //gbc->width = (gdouble) render->width; - //gbc->height = (gdouble) render->height; + gbc->width = (gdouble) render->width; + gbc->height = (gdouble) render->height; - return gbc; } diff --git a/src/bc.c b/src/bc.c index c4455a45..3d9fe6e7 100644 --- a/src/bc.c +++ b/src/bc.c @@ -159,14 +159,203 @@ static const Backend backends[] = { #ifdef HAVE_LIBZINT - { "GS1-128", N_("GS1-128"), gl_barcode_zint_new, - TRUE, TRUE, FALSE, FALSE, "[00]001234560000000018", TRUE, 22}, + { "AUSP", N_("Australia Post Standard"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "AUSRP", N_("Australia Post Reply Paid"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "AUSRT", N_("Australia Post Route Code"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "AUSRD", N_("Australia Post Redirect"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "AZTEC", N_("Aztec Code"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "AZRUN", N_("Aztec Rune"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "CBR", N_("Codabar"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "Code1", N_("Code One"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "Code11", N_("Code 11"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "C16K", N_("Code 16K"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "C25M", N_("Code 2 of 5 Matrix"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "C25I", N_("Code 2 of 5 IATA"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "C25DL", N_("Code 2 of 5 Data Logic"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "Code32", N_("Code 32 (Italian Pharmacode)"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "Code39", N_("Code 39"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "Code39E", N_("Code 39 Extended"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "Code49", N_("Code 49"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "Code93", N_("Code 93"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "Code128", N_("Code 128"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "Code128B", N_("Code 128 (Mode C supression)"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "DAFT", N_("DAFT Code"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "DMTX", N_("Data Matrix"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "DPL", N_("Deutsche Post Leitcode"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "DPI", N_("Deutsche Post Identcode"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "KIX", N_("Dutch Post KIX Code"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "EAN", N_("European Article Number (EAN)"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "000000000000 00000", FALSE, 13}, + + { "GMTX", N_("Grid Matrix"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, - { "GTIN-13", N_("GTIN-13"), gl_barcode_zint_new, - TRUE, TRUE, FALSE, FALSE, "000000000000", FALSE, 13}, + { "GS1-128", N_("GS1-128"), gl_barcode_zint_new, + TRUE, TRUE, FALSE, FALSE, "[00]001234560000000018", TRUE, 16}, - { "GTIN-14", N_("GTIN-14"), gl_barcode_zint_new, - TRUE, TRUE, FALSE, FALSE, "000000000000", FALSE, 14}, + { "RSS14", N_("GS1 DataBar-14"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "RSSLTD", "GS1 DataBar-14 Limited", gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "RSSEXP", "GS1 DataBar Extended", gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "RSSS", N_("GS1 DataBar-14 Stacked"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "RSSSO", N_("GS1 DataBar-14 Stacked Omnidirectional"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "RSSSE", N_("GS1 DataBar Extended Stacked"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "HIBC128", N_("HIBC Code 128"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "HIBC39", N_("HIBC Code 39"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "HIBCDM", N_("HIBC Data Matrix"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "HIBCQR", N_("HIBC QR Code"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "HIBCPDF", N_("HIBC PDF417"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "HIBCMPDF", N_("HIBC Micro PDF417"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "HIBCAZ", N_("HIBC Aztec Code"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "I25", N_("Interleaved 2 of 5"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "ISBN", N_("ISBN"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "ITF14", N_("ITF-14"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "JAPAN", N_("Japanese Postal"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "KOREA", N_("Korean Postal"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "LOGM", N_("LOGMARS"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "MPDF", N_("Micro PDF417"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "MQR", N_("Micro QR Code"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "MSI", N_("MSI Plessey"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "NVE", N_("NVE-18"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "PDF", N_("PDF417"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "PDFT", N_("PDF417 Truncated"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "PLAN", N_("PLANET"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "POSTNET", N_("PostNet"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "PHARMA", N_("Pharmacode"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "00000", TRUE, 5}, + + { "PHARMA2", N_("Pharmacode 2-track"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "PZN", N_("Pharmazentral Nummer (PZN)"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "QR", N_("QR Code"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "RM4", N_("Royal Mail 4-State"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "TELE", N_("Telepen"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "TELEX", N_("Telepen Numeric"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "UPC-A", N_("UPC-A"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "00000000000", FALSE, 11}, + + { "UPC-E", N_("UPC-E"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "000000", FALSE, 6}, + + { "USPS", N_("USPS One Code"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, + + { "PLS", N_("UK Plessey"), gl_barcode_zint_new, + TRUE, TRUE, TRUE, FALSE, "0000000000", TRUE, 10}, #endif /* HAVE_LIBZINT */ -- 2.39.5