Merge branch 'master' of ssh://git.code.sf.net/p/zint/code

This commit is contained in:
Robin Stuart 2016-08-28 16:39:13 +01:00
commit f0d8bb82dc
17 changed files with 487 additions and 396 deletions

View File

@ -7,7 +7,7 @@ find_package(PNG)
set(zint_COMMON_SRCS common.c library.c render.c large.c reedsol.c gs1.c eci.c)
set(zint_ONEDIM_SRCS code.c code128.c 2of5.c upcean.c telepen.c medical.c plessey.c rss.c)
set(zint_POSTAL_SRCS postal.c auspost.c imail.c)
set(zint_TWODIM_SRCS code16k.c dmatrix.c pdf417.c qr.c maxicode.c composite.c aztec.c code49.c code1.c gridmtx.c hanxin.c dotcode.c)
set(zint_TWODIM_SRCS code16k.c codablock.c dmatrix.c pdf417.c qr.c maxicode.c composite.c aztec.c code49.c code1.c gridmtx.c hanxin.c dotcode.c)
set(zint_OUTPUT_SRCS render.c ps.c svg.c bmp.c pcx.c gif.c png.c raster.c)
set(zint_SRCS ${zint_OUTPUT_SRCS} ${zint_COMMON_SRCS} ${zint_ONEDIM_SRCS} ${zint_POSTAL_SRCS} ${zint_TWODIM_SRCS})
@ -22,7 +22,9 @@ add_library(zint SHARED ${zint_SRCS})
set_target_properties(zint PROPERTIES SOVERSION "${ZINT_VERSION_MAJOR}.${ZINT_VERSION_MINOR}"
VERSION ${ZINT_VERSION})
target_link_libraries(zint ${PNG_LIBRARIES} )
if(PNG_FOUND)
target_link_libraries(zint ${PNG_LIBRARIES} )
endif(PNG_FOUND)
target_link_libraries(zint -lm)
install(TARGETS zint ${INSTALL_TARGETS_DEFAULT_ARGS} )

45
backend/codablock.c Normal file
View File

@ -0,0 +1,45 @@
/* codablock.c - Handles Codablock-F and Codablock-E */
/*
libzint - the open source barcode library
Copyright (C) 2016 Harald Oehlmann
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. Neither the name of the project nor the names of its contributors
may be used to endorse or promote products derived from this software
without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
SUCH DAMAGE.
*/
#include <stdio.h>
#include "common.h"
int codablock(struct zint_symbol *symbol, unsigned char source[], int length) {
if (symbol->input_mode == GS1_MODE) {
printf("Encode GS1 data (Codablock-E?)\n");
} else {
printf("Encode in Codablock-F\n");
}
return ZINT_ERROR_INVALID_OPTION;
}

View File

@ -329,7 +329,9 @@ int code_49(struct zint_symbol *symbol, unsigned char source[], const int length
}
symbol->whitespace_width = 10;
symbol->output_options = BARCODE_BIND;
if (!(symbol->output_options & BARCODE_BIND)) {
symbol->output_options += BARCODE_BIND;
}
symbol->border_width = 2;
return 0;

View File

@ -1249,7 +1249,9 @@ int dotcode(struct zint_symbol *symbol, unsigned char source[], int length) {
symbol->row_height[k] = 1;
}
symbol->output_options += BARCODE_DOTTY_MODE;
if (!(symbol->output_options & BARCODE_DOTTY_MODE)) {
symbol->output_options += BARCODE_DOTTY_MODE;
}
return 0;
}

View File

@ -187,6 +187,7 @@ extern int code_one(struct zint_symbol *symbol, unsigned char source[], int leng
extern int grid_matrix(struct zint_symbol *symbol, const unsigned char source[], int length); /* Grid Matrix */
extern int han_xin(struct zint_symbol * symbol, const unsigned char source[], int length); /* Han Xin */
extern int dotcode(struct zint_symbol * symbol, const unsigned char source[], int length); /* DotCode */
extern int codablock(struct zint_symbol * symbol, const unsigned char source[], int length); /* Codablock */
extern int plot_raster(struct zint_symbol *symbol, int rotate_angle, int file_type); /* Plot to PNG/BMP/PCX */
extern int render_plot(struct zint_symbol *symbol, float width, float height); /* Plot to gLabels */
@ -349,6 +350,9 @@ int hibc(struct zint_symbol *symbol, unsigned char source[], int length) {
case BARCODE_HIBC_AZTEC:
error_number = aztec(symbol, (unsigned char *) to_process, length);
break;
case BARCODE_HIBC_BLOCKF:
error_number = codablock(symbol, (unsigned char *) to_process, length);
break;
}
return error_number;
@ -380,6 +384,7 @@ static int gs1_compliant(const int symbology) {
case BARCODE_CODE49:
case BARCODE_QRCODE:
case BARCODE_DOTCODE:
case BARCODE_CODABLOCK:
result = 1;
break;
}
@ -508,6 +513,7 @@ int ZBarcode_ValidID(int symbol_id) {
case BARCODE_HIBC_PDF:
case BARCODE_HIBC_MICPDF:
case BARCODE_HIBC_AZTEC:
case BARCODE_HIBC_BLOCKF:
case BARCODE_AZRUNE:
case BARCODE_CODE32:
case BARCODE_EANX_CC:
@ -525,6 +531,7 @@ int ZBarcode_ValidID(int symbol_id) {
case BARCODE_GRIDMATRIX:
case BARCODE_HANXIN:
case BARCODE_DOTCODE:
case BARCODE_CODABLOCK:
result = 1;
break;
}
@ -563,13 +570,17 @@ static int reduced_charset(struct zint_symbol *symbol, const unsigned char *sour
if (symbol->symbology == BARCODE_CODE16K) {
symbol->whitespace_width = 16;
symbol->border_width = 2;
symbol->output_options = BARCODE_BIND;
if (!(symbol->output_options & BARCODE_BIND)) {
symbol->output_options += BARCODE_BIND;
}
}
if (symbol->symbology == BARCODE_ITF14) {
symbol->whitespace_width = 20;
symbol->border_width = 8;
symbol->output_options = BARCODE_BOX;
if (!(symbol->output_options & BARCODE_BOX)) {
symbol->output_options += BARCODE_BOX;
}
}
switch (symbol->input_mode) {
@ -726,6 +737,8 @@ static int reduced_charset(struct zint_symbol *symbol, const unsigned char *sour
break;
case BARCODE_HIBC_AZTEC: error_number = hibc(symbol, preprocessed, length);
break;
case BARCODE_HIBC_BLOCKF: error_number = hibc(symbol, preprocessed, length);
break;
case BARCODE_JAPANPOST: error_number = japan_post(symbol, preprocessed, length);
break;
case BARCODE_CODE49: error_number = code_49(symbol, preprocessed, length);
@ -748,6 +761,8 @@ static int reduced_charset(struct zint_symbol *symbol, const unsigned char *sour
break;
case BARCODE_DOTCODE: error_number = dotcode(symbol, preprocessed, length);
break;
case BARCODE_CODABLOCK: error_number = codablock(symbol, preprocessed, length);
break;
}
return error_number;
@ -770,7 +785,11 @@ int ZBarcode_Encode(struct zint_symbol *symbol, unsigned char *source, int lengt
}
if (strcmp(symbol->outfile, "") == 0) {
#ifdef NO_PNG
strcpy(symbol->outfile, "out.gif");
#else
strcpy(symbol->outfile, "out.png");
#endif
}
#ifndef _MSC_VER
unsigned char local_source[length + 1];
@ -843,8 +862,8 @@ int ZBarcode_Encode(struct zint_symbol *symbol, unsigned char *source, int lengt
symbol->symbology = BARCODE_AUSPOST;
}
if (symbol->symbology == 73) {
strcpy(symbol->errtxt, "Codablock E not supported");
error_number = ZINT_ERROR_INVALID_OPTION;
symbol->symbology = BARCODE_CODABLOCK;
symbol->input_mode = GS1_MODE;
}
if (symbol->symbology == 78) {
symbol->symbology = BARCODE_RSS14;
@ -905,10 +924,6 @@ int ZBarcode_Encode(struct zint_symbol *symbol, unsigned char *source, int lengt
symbol->symbology = BARCODE_CODE128;
error_number = ZINT_WARN_INVALID_OPTION;
}
if ((symbol->symbology == BARCODE_CODABLOCKF) || (symbol->symbology == BARCODE_HIBC_BLOCKF)) {
strcpy(symbol->errtxt, "Codablock F not supported");
error_number = ZINT_ERROR_INVALID_OPTION;
}
if (error_number > 4) {
error_tag(symbol->errtxt, error_number);
@ -1021,7 +1036,7 @@ int ZBarcode_Print(struct zint_symbol *symbol, int rotate_angle) {
return ZINT_ERROR_INVALID_OPTION;
}
if (symbol->output_options &= BARCODE_DOTTY_MODE) {
if (symbol->output_options & BARCODE_DOTTY_MODE) {
if (!(is_matrix(symbol->symbology))) {
strcpy(symbol->errtxt, "Selected symbology cannot be rendered as dots");
return ZINT_ERROR_INVALID_OPTION;
@ -1078,6 +1093,11 @@ int ZBarcode_Print(struct zint_symbol *symbol, int rotate_angle) {
return ZINT_ERROR_INVALID_OPTION;
}
if (error_number == ZINT_ERROR_INVALID_OPTION) {
/* If libpng is not installed */
strcpy(symbol->errtxt, "Unknown output format");
}
error_tag(symbol->errtxt, error_number);
return error_number;
}

View File

@ -180,7 +180,7 @@ int pcx_pixel_plot(struct zint_symbol *symbol, int image_height, int image_width
}
/* Open output file in binary mode */
if ((symbol->output_options & BARCODE_STDOUT) != 0) {
if (symbol->output_options & BARCODE_STDOUT) {
#ifdef _MSC_VER
if (-1 == _setmode(_fileno(stdout), _O_BINARY)) {
strcpy(symbol->errtxt, "Can't open output file");

View File

@ -131,7 +131,7 @@ int png_pixel_plot(struct zint_symbol *symbol, int image_height, int image_width
bgblu = (16 * ctoi(symbol->bgcolour[4])) + ctoi(symbol->bgcolour[5]);
/* Open output file in binary mode */
if ((symbol->output_options & BARCODE_STDOUT) != 0) {
if (symbol->output_options & BARCODE_STDOUT) {
#ifdef _MSC_VER
if (-1 == _setmode(_fileno(stdout), _O_BINARY)) {
strcpy(symbol->errtxt, "Can't open output file");

View File

@ -99,7 +99,7 @@ int ps_plot(struct zint_symbol *symbol) {
}
}
if ((symbol->output_options & BARCODE_STDOUT) != 0) {
if (symbol->output_options & BARCODE_STDOUT) {
feps = stdout;
} else {
feps = fopen(symbol->outfile, "w");
@ -868,7 +868,7 @@ int ps_plot(struct zint_symbol *symbol) {
/* Do nothing! (It's already been done) */
break;
default:
if ((symbol->output_options & BARCODE_BIND) != 0) {
if (symbol->output_options & BARCODE_BIND) {
if ((symbol->rows > 1) && (is_stackable(symbol->symbology) == 1)) {
/* row binding */
fprintf(feps, "TE\n");
@ -882,7 +882,7 @@ int ps_plot(struct zint_symbol *symbol) {
}
}
}
if (((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
if ((symbol->output_options & BARCODE_BOX) || (symbol->output_options & BARCODE_BIND)) {
fprintf(feps, "TE\n");
if ((symbol->output_options & CMYK_COLOUR) == 0) {
fprintf(feps, "%.2f %.2f %.2f setrgbcolor\n", red_ink, green_ink, blue_ink);
@ -892,7 +892,7 @@ int ps_plot(struct zint_symbol *symbol) {
fprintf(feps, "%.2f %.2f TB %.2f %.2f TR\n", symbol->border_width * scaler, textoffset * scaler, 0.0, (symbol->width + xoffset + xoffset) * scaler);
fprintf(feps, "%.2f %.2f TB %.2f %.2f TR\n", symbol->border_width * scaler, (textoffset + symbol->height + symbol->border_width) * scaler, 0.0, (symbol->width + xoffset + xoffset) * scaler);
}
if ((symbol->output_options & BARCODE_BOX) != 0) {
if (symbol->output_options & BARCODE_BOX) {
/* side bars */
fprintf(feps, "TE\n");
if ((symbol->output_options & CMYK_COLOUR) == 0) {

View File

@ -292,7 +292,7 @@ int plot_raster_maxicode(struct zint_symbol *symbol, int rotate_angle, int data_
image_height = 300 + (2 * yoffset * 2);
if (!(pixelbuf = (char *) malloc(image_width * image_height))) {
printf("Insifficient memory for pixel buffer");
printf("Insufficient memory for pixel buffer");
return ZINT_ERROR_ENCODING_PROBLEM;
} else {
for (i = 0; i < (image_width * image_height); i++) {
@ -319,13 +319,13 @@ int plot_raster_maxicode(struct zint_symbol *symbol, int rotate_angle, int data_
}
}
if (((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
if ((symbol->output_options & BARCODE_BOX) || (symbol->output_options & BARCODE_BIND)) {
/* boundary bars */
draw_bar(pixelbuf, 0, image_width, 0, symbol->border_width * 2, image_width, image_height);
draw_bar(pixelbuf, 0, image_width, 300 + (symbol->border_width * 2), symbol->border_width * 2, image_width, image_height);
}
if ((symbol->output_options & BARCODE_BOX) != 0) {
if (symbol->output_options & BARCODE_BOX) {
/* side bars */
draw_bar(pixelbuf, 0, symbol->border_width * 2, 0, image_height, image_width, image_height);
draw_bar(pixelbuf, 300 + ((symbol->border_width + symbol->whitespace_width + symbol->whitespace_width) * 2), symbol->border_width * 2, 0, image_height, image_width, image_height);
@ -619,7 +619,7 @@ int plot_raster_default(struct zint_symbol *symbol, int rotate_angle, int data_t
}
}
if (((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
if ((symbol->output_options & BARCODE_BOX) || (symbol->output_options & BARCODE_BIND)) {
default_text_posn = image_height - 17;
} else {
default_text_posn = image_height - 17 - symbol->border_width - symbol->border_width;
@ -867,7 +867,7 @@ int plot_raster_default(struct zint_symbol *symbol, int rotate_angle, int data_t
xoffset -= comp_offset;
/* Put boundary bars or box around symbol */
if (((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
if ((symbol->output_options & BARCODE_BOX) || (symbol->output_options & BARCODE_BIND)) {
/* boundary bars */
draw_bar(pixelbuf, 0, (symbol->width + xoffset + xoffset) * 2, textoffset * 2, symbol->border_width * 2, image_width, image_height);
draw_bar(pixelbuf, 0, (symbol->width + xoffset + xoffset) * 2, (textoffset + symbol->height + symbol->border_width) * 2, symbol->border_width * 2, image_width, image_height);
@ -881,7 +881,7 @@ int plot_raster_default(struct zint_symbol *symbol, int rotate_angle, int data_t
}
}
if ((symbol->output_options & BARCODE_BOX) != 0) {
if (symbol->output_options & BARCODE_BOX) {
/* side bars */
draw_bar(pixelbuf, 0, symbol->border_width * 2, textoffset * 2, (symbol->height + (2 * symbol->border_width)) * 2, image_width, image_height);
draw_bar(pixelbuf, (symbol->width + xoffset + xoffset - symbol->border_width) * 2, symbol->border_width * 2, textoffset * 2, (symbol->height + (2 * symbol->border_width)) * 2, image_width, image_height);
@ -927,12 +927,11 @@ int plot_raster(struct zint_symbol *symbol, int rotate_angle, int file_type) {
#ifdef NO_PNG
if (file_type == OUT_PNG_FILE) {
printf("libpng not found");
return ZINT_ERROR_INVALID_OPTION;
}
#endif /* NO_PNG */
if (symbol->output_options &= BARCODE_DOTTY_MODE) {
if (symbol->output_options & BARCODE_DOTTY_MODE) {
error = plot_raster_dotty(symbol, rotate_angle, file_type);
} else {
if (symbol->symbology == BARCODE_MAXICODE) {

View File

@ -248,7 +248,7 @@ int render_plot(struct zint_symbol *symbol, const float width, const float heigh
}
large_bar_height = (symbol->height - preset_height) / large_bar_count;
if (((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
if ((symbol->output_options & BARCODE_BOX) || (symbol->output_options & BARCODE_BIND)) {
default_text_posn = (symbol->height + text_offset + symbol->border_width + symbol->border_width) * scaler;
} else {
default_text_posn = (symbol->height + text_offset + symbol->border_width) * scaler;
@ -643,13 +643,13 @@ int render_plot(struct zint_symbol *symbol, const float width, const float heigh
}
}
}
if (((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
if ((symbol->output_options & BARCODE_BOX) || (symbol->output_options & BARCODE_BIND)) {
line = render_plot_create_line(0, 0, (symbol->width + xoffset + xoffset) * scaler, symbol->border_width * scaler);
render_plot_add_line(symbol, line, &last_line);
line = render_plot_create_line(0, (symbol->height + symbol->border_width) * scaler, (symbol->width + xoffset + xoffset) * scaler, symbol->border_width * scaler);
render_plot_add_line(symbol, line, &last_line);
}
if ((symbol->output_options & BARCODE_BOX) != 0) {
if (symbol->output_options & BARCODE_BOX) {
/* side bars */
line = render_plot_create_line(0, 0, symbol->border_width * scaler, (symbol->height + (2 * symbol->border_width)) * scaler);
render_plot_add_line(symbol, line, &last_line);

View File

@ -95,7 +95,7 @@ int svg_plot(struct zint_symbol *symbol) {
}
}
if ((symbol->output_options & BARCODE_STDOUT) != 0) {
if (symbol->output_options & BARCODE_STDOUT) {
fsvg = stdout;
} else {
fsvg = fopen(symbol->outfile, "w");
@ -230,7 +230,7 @@ int svg_plot(struct zint_symbol *symbol) {
fprintf(fsvg, " <rect x=\"0\" y=\"0\" width=\"%d\" height=\"%d\" fill=\"#%s\" />\n", (int)ceil((74.0F + xoffset + xoffset) * scaler), (int)ceil((72.0F + yoffset + yoffset) * scaler), symbol->bgcolour);
}
if (((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
if ((symbol->output_options & BARCODE_BOX) || (symbol->output_options & BARCODE_BIND)) {
default_text_posn = (symbol->height + textoffset + symbol->border_width + symbol->border_width) * scaler;
} else {
default_text_posn = (symbol->height + textoffset + symbol->border_width) * scaler;
@ -242,11 +242,11 @@ int svg_plot(struct zint_symbol *symbol) {
textoffset = 0.0;
if (((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
if ((symbol->output_options & BARCODE_BOX) || (symbol->output_options & BARCODE_BIND)) {
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", 0.0, 0.0, (74.0 + xoffset + xoffset) * scaler, symbol->border_width * scaler);
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", 0.0, (72.0 + symbol->border_width) * scaler, (74.0 + xoffset + xoffset) * scaler, symbol->border_width * scaler);
}
if ((symbol->output_options & BARCODE_BOX) != 0) {
if (symbol->output_options & BARCODE_BOX) {
/* side bars */
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", 0.0, 0.0, symbol->border_width * scaler, (72.0 + (2 * symbol->border_width)) * scaler);
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", (74.0 + xoffset + xoffset - symbol->border_width) * scaler, 0.0, symbol->border_width * scaler, (72.0 + (2 * symbol->border_width)) * scaler);
@ -307,7 +307,7 @@ int svg_plot(struct zint_symbol *symbol) {
}
row_posn += yoffset;
if ((symbol->output_options & BARCODE_DOTTY_MODE) != 0) {
if (symbol->output_options & BARCODE_DOTTY_MODE) {
/* Use (currently undocumented) dot mode - see SF ticket #29 */
for (i = 0; i < symbol->width; i++) {
if (module_is_set(symbol, this_row, i)) {
@ -609,7 +609,7 @@ int svg_plot(struct zint_symbol *symbol) {
/* Do nothing! (It's already been done) */
break;
default:
if ((symbol->output_options & BARCODE_BIND) != 0) {
if (symbol->output_options & BARCODE_BIND) {
if ((symbol->rows > 1) && (is_stackable(symbol->symbology) == 1)) {
/* row binding */
for (r = 1; r < symbol->rows; r++) {
@ -617,11 +617,11 @@ int svg_plot(struct zint_symbol *symbol) {
}
}
}
if (((symbol->output_options & BARCODE_BOX) != 0) || ((symbol->output_options & BARCODE_BIND) != 0)) {
if ((symbol->output_options & BARCODE_BOX) || (symbol->output_options & BARCODE_BIND)) {
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", 0.0, 0.0, (symbol->width + xoffset + xoffset) * scaler, symbol->border_width * scaler);
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", 0.0, (symbol->height + symbol->border_width) * scaler, (symbol->width + xoffset + xoffset) * scaler, symbol->border_width * scaler);
}
if ((symbol->output_options & BARCODE_BOX) != 0) {
if (symbol->output_options & BARCODE_BOX) {
/* side bars */
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", 0.0, 0.0, symbol->border_width * scaler, (symbol->height + (2 * symbol->border_width)) * scaler);
fprintf(fsvg, " <rect x=\"%.2f\" y=\"%.2f\" width=\"%.2f\" height=\"%.2f\" />\n", (symbol->width + xoffset + xoffset - symbol->border_width) * scaler, 0.0, symbol->border_width * scaler, (symbol->height + (2 * symbol->border_width)) * scaler);

View File

@ -143,7 +143,7 @@ extern "C" {
#define BARCODE_RM4SCC 70
#define BARCODE_DATAMATRIX 71
#define BARCODE_EAN14 72
#define BARCODE_CODABLOCKF 74
#define BARCODE_CODABLOCK 74
#define BARCODE_NVE18 75
#define BARCODE_JAPANPOST 76
#define BARCODE_KOREAPOST 77

View File

@ -331,7 +331,7 @@ namespace Zint {
gwidth *= (maxi_width + 1);
}
if (m_zintSymbol->output_options &= BARCODE_DOTTY_MODE) {
if (m_zintSymbol->output_options & BARCODE_DOTTY_MODE) {
gwidth += 2.0;
gheight += 2.0;
}
@ -476,7 +476,7 @@ namespace Zint {
painter.drawEllipse(QPointF(14.5 * w, 16.5 * w * 0.868), w + w * 1.5, w + w * 1.5);
painter.drawEllipse(QPointF(14.5 * w, 16.5 * w * 0.868), w + w * 3, w + w * 3);
painter.restore();
} else if (m_zintSymbol->output_options &= BARCODE_DOTTY_MODE) {
} else if (m_zintSymbol->output_options & BARCODE_DOTTY_MODE) {
/* Draw with dots (circles) */
p.setColor(m_fgColor);

View File

@ -37,22 +37,22 @@
/* Print list of supported symbologies */
void types(void) {
printf( " 1: Code 11 51: Pharma One-Track 90: KIX Code\n"
" 2: Standard 2of5 52: PZN 92: Aztec Code\n"
" 3: Interleaved 2of5 53: Pharma Two-Track 93: DAFT Code\n"
" 4: IATA 2of5 55: PDF417 97: Micro QR Code\n"
" 6: Data Logic 56: PDF417 Trunc 98: HIBC Code 128\n"
" 7: Industrial 2of5 57: Maxicode 99: HIBC Code 39\n"
" 8: Code 39 58: QR Code 102: HIBC Data Matrix\n"
" 9: Extended Code 39 60: Code 128-B 104: HIBC QR Code\n"
"13: EAN 63: AP Standard Customer 106: HIBC PDF417\n"
"16: GS1-128 66: AP Reply Paid 108: HIBC MicroPDF417\n"
"18: Codabar 67: AP Routing 112: HIBC Aztec Code\n"
"20: Code 128 68: AP Redirection 115: DotCode\n"
"21: Leitcode 69: ISBN 116: Han Xin Code\n"
"22: Identcode 70: RM4SCC 128: Aztec Runes\n"
"23: Code 16k 71: Data Matrix 129: Code 32\n"
"24: Code 49 72: EAN-14 130: Comp EAN\n"
printf( " 1: Code 11 52: PZN 92: Aztec Code\n"
" 2: Standard 2of5 53: Pharma Two-Track 93: DAFT Code\n"
" 3: Interleaved 2of5 55: PDF417 97: Micro QR Code\n"
" 4: IATA 2of5 56: PDF417 Trunc 98: HIBC Code 128\n"
" 6: Data Logic 57: Maxicode 99: HIBC Code 39\n"
" 7: Industrial 2of5 58: QR Code 102: HIBC Data Matrix\n"
" 8: Code 39 60: Code 128-B 104: HIBC QR Code\n"
" 9: Extended Code 39 63: AP Standard Customer 106: HIBC PDF417\n"
"13: EAN 66: AP Reply Paid 108: HIBC MicroPDF417\n"
"16: GS1-128 67: AP Routing 110: HIBC Codablock-F\n"
"18: Codabar 68: AP Redirection 112: HIBC Aztec Code\n"
"20: Code 128 69: ISBN 115: DotCode\n"
"21: Leitcode 70: RM4SCC 116: Han Xin Code\n"
"22: Identcode 71: Data Matrix 128: Aztec Runes\n"
"23: Code 16k 72: EAN-14 129: Code 32\n"
"24: Code 49 74: Codablock 130: Comp EAN\n"
"25: Code 93 75: NVE-18 131: Comp GS1-128\n"
"28: Flattermarken 76: Japanese Post 132: Comp DataBar Omni\n"
"29: GS1 DataBar Omni 77: Korea Post 133: Comp DataBar Ltd\n"
@ -65,6 +65,7 @@ void types(void) {
"47: MSI Plessey 86: UK Plessey 140: Channel Code\n"
"49: FIM 87: Telepen Numeric 141: Code One\n"
"50: Logmars 89: ITF-14 142: Grid Matrix\n"
"51: Pharma One-Track 90: KIX Code\n"
);
}
@ -95,7 +96,7 @@ void usage(void) {
" --dump Dump hexadecimal representation to stdout\n"
" --rotate=NUMBER Rotate symbol (PNG output only).\n"
" --cols=NUMBER (PDF417) Number of columns.\n"
" --vers=NUMBER (QR Code) Version\n"
" --vers=NUMBER (QR Code or Han Xin) Version\n"
" --secure=NUMBER (PDF417 and QR Code) Error correction level.\n"
" --primary=STRING (Maxicode and Composite) Structured primary message.\n"
" --mode=NUMBER (Maxicode and Composite) Set encoding mode.\n"
@ -624,10 +625,10 @@ int main(int argc, char **argv) {
}
}
if (!strcmp(long_options[option_index].name, "vers")) {
if ((atoi(optarg) >= 1) && (atoi(optarg) <= 47)) {
if ((atoi(optarg) >= 1) && (atoi(optarg) <= 84)) {
my_symbol->option_2 = atoi(optarg);
} else {
fprintf(stderr, "Invalid QR Code version\n");
fprintf(stderr, "Invalid Version\n");
fflush(stderr);
}
}

View File

@ -1,419 +1,437 @@
echo testing Code 11
zint -o bar01.png -b 1 --height=50 --border=10 -d 87654321
zint -o bar01.eps -b 1 --height=50 --border=10 -d 87654321
zint -o bar01.svg -b 1 --height=50 --border=10 -d 87654321
./zint -o bar01.txt -b 1 -d 87654321
./zint -o bar01.gif -b 1 --height=50 --border=10 -d 87654321
./zint -o bar01.svg -b 1 --height=50 --border=10 -d 87654321
echo testing Code 2 of 5 Standard
zint -o bar02.png -b 2 --height=50 --border=10 -d 87654321
zint -o bar02.eps -b 2 --height=50 --border=10 -d 87654321
zint -o bar02.svg -b 2 --height=50 --border=10 -d 87654321
./zint -o bar02.txt -b 2 -d 87654321
./zint -o bar02.gif -b 2 --height=50 --border=10 -d 87654321
./zint -o bar02.svg -b 2 --height=50 --border=10 -d 87654321
echo testing Interleaved 2 of 5
zint -o bar03.png -b 3 --height=50 --border=10 -d 87654321
zint -o bar03.eps -b 3 --height=50 --border=10 -d 87654321
zint -o bar03.svg -b 3 --height=50 --border=10 -d 87654321
./zint -o bar03.txt -b 3 -d 87654321
./zint -o bar03.gif -b 3 --height=50 --border=10 -d 87654321
./zint -o bar03.svg -b 3 --height=50 --border=10 -d 87654321
echo testing Code 2 of 5 IATA
zint -o bar04.png -b 4 --height=50 --border=10 -d 87654321
zint -o bar04.eps -b 4 --height=50 --border=10 -d 87654321
zint -o bar04.svg -b 4 --height=50 --border=10 -d 87654321
./zint -o bar04.txt -b 4 -d 87654321
./zint -o bar04.gif -b 4 --height=50 --border=10 -d 87654321
./zint -o bar04.svg -b 4 --height=50 --border=10 -d 87654321
echo testing Code 2 of 5 Data Logic
zint -o bar06.png -b 6 --height=50 --border=10 -d 87654321
zint -o bar06.eps -b 6 --height=50 --border=10 -d 87654321
zint -o bar06.svg -b 6 --height=50 --border=10 -d 87654321
./zint -o bar06.txt -b 6 -d 87654321
./zint -o bar06.gif -b 6 --height=50 --border=10 -d 87654321
./zint -o bar06.svg -b 6 --height=50 --border=10 -d 87654321
echo testing Code 2 of 5 Industrial
zint -o bar07.png -b 7 --height=50 --border=10 -d 87654321
zint -o bar07.eps -b 7 --height=50 --border=10 -d 87654321
zint -o bar07.svg -b 7 --height=50 --border=10 -d 87654321
./zint -o bar07.txt -b 7 -d 87654321
./zint -o bar07.gif -b 7 --height=50 --border=10 -d 87654321
./zint -o bar07.svg -b 7 --height=50 --border=10 -d 87654321
echo testing Code 39
zint -o bar08.png -b 8 --height=50 --border=10 -d CODE39
zint -o bar08.eps -b 8 --height=50 --border=10 -d CODE39
zint -o bar08.svg -b 8 --height=50 --border=10 -d CODE39
./zint -o bar08.txt -b 8 -d CODE39
./zint -o bar08.gif -b 8 --height=50 --border=10 -d CODE39
./zint -o bar08.svg -b 8 --height=50 --border=10 -d CODE39
echo testing Extended Code 39
zint -o bar09.png -b 9 --height=50 --border=10 -d 'Code 39e'
zint -o bar09.eps -b 9 --height=50 --border=10 -d 'Code 39e'
zint -o bar09.svg -b 9 --height=50 --border=10 -d 'Code 39e'
./zint -o bar09.txt -b 9 -d 'Code 39e'
./zint -o bar09.gif -b 9 --height=50 --border=10 -d 'Code 39e'
./zint -o bar09.svg -b 9 --height=50 --border=10 -d 'Code 39e'
echo testing EAN8
zint -o bar10.png -b 13 --height=50 --border=10 -d 7654321
zint -o bar10.eps -b 13 --height=50 --border=10 -d 7654321
zint -o bar10.svg -b 13 --height=50 --border=10 -d 7654321
./zint -o bar10.txt -b 13 -d 7654321
./zint -o bar10.gif -b 13 --height=50 --border=10 -d 7654321
./zint -o bar10.svg -b 13 --height=50 --border=10 -d 7654321
echo testing EAN8 - 2 digits add on
zint -o bar11.png -b 13 --height=50 --border=10 -d 7654321+21
zint -o bar11.eps -b 13 --height=50 --border=10 -d 7654321+21
zint -o bar11.svg -b 13 --height=50 --border=10 -d 7654321+21
./zint -o bar11.txt -b 13 -d 7654321+21
./zint -o bar11.gif -b 13 --height=50 --border=10 -d 7654321+21
./zint -o bar11.svg -b 13 --height=50 --border=10 -d 7654321+21
echo testing EAN8 - 5 digits add-on
zint -o bar12.png -b 13 --height=50 --border=10 -d 7654321+54321
zint -o bar12.eps -b 13 --height=50 --border=10 -d 7654321+54321
zint -o bar12.svg -b 13 --height=50 --border=10 -d 7654321+54321
./zint -o bar12.txt -b 13 -d 7654321+54321
./zint -o bar12.gif -b 13 --height=50 --border=10 -d 7654321+54321
./zint -o bar12.svg -b 13 --height=50 --border=10 -d 7654321+54321
echo testing EAN13
zint -o bar13.png -b 13 --height=50 --border=10 -d 210987654321
zint -o bar13.eps -b 13 --height=50 --border=10 -d 210987654321
zint -o bar13.svg -b 13 --height=50 --border=10 -d 210987654321
./zint -o bar13.txt -b 13 -d 210987654321
./zint -o bar13.gif -b 13 --height=50 --border=10 -d 210987654321
./zint -o bar13.svg -b 13 --height=50 --border=10 -d 210987654321
echo testing EAN13 - 2 digits add-on
zint -o bar14.png -b 13 --height=50 --border=10 -d 210987654321+21
zint -o bar14.eps -b 13 --height=50 --border=10 -d 210987654321+21
zint -o bar14.svg -b 13 --height=50 --border=10 -d 210987654321+21
./zint -o bar14.txt -b 13 -d 210987654321+21
./zint -o bar14.gif -b 13 --height=50 --border=10 -d 210987654321+21
./zint -o bar14.svg -b 13 --height=50 --border=10 -d 210987654321+21
echo testing EAN13 - 5 digits add-on
zint -o bar15.png -b 13 --height=50 --border=10 -d 210987654321+54321
zint -o bar15.eps -b 13 --height=50 --border=10 -d 210987654321+54321
zint -o bar15.svg -b 13 --height=50 --border=10 -d 210987654321+54321
./zint -o bar15.txt -b 13 -d 210987654321+54321
./zint -o bar15.gif -b 13 --height=50 --border=10 -d 210987654321+54321
./zint -o bar15.svg -b 13 --height=50 --border=10 -d 210987654321+54321
echo testing GS1-128
zint -o bar16.png -b 16 --height=50 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
zint -o bar16.eps -b 16 --height=50 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
zint -o bar16.svg -b 16 --height=50 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
./zint -o bar16.txt -b 16 -d "[01]98898765432106[3202]012345[15]991231"
./zint -o bar16.gif -b 16 --height=50 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
./zint -o bar16.svg -b 16 --height=50 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
echo testing CodaBar
zint -o bar18.png -b 18 --height=50 --border=10 -d D765432C
zint -o bar18.eps -b 18 --height=50 --border=10 -d D765432C
zint -o bar18.svg -b 18 --height=50 --border=10 -d D765432C
./zint -o bar18.txt -b 18 -d D765432C
./zint -o bar18.gif -b 18 --height=50 --border=10 -d D765432C
./zint -o bar18.svg -b 18 --height=50 --border=10 -d D765432C
echo testing Code 128
zint -o bar20.png -b 20 --height=50 --border=10 -d 'Code 128'
zint -o bar20.eps -b 20 --height=50 --border=10 -d 'Code 128'
zint -o bar20.svg -b 20 --height=50 --border=10 -d 'Code 128'
./zint -o bar20.txt -b 20 -d 'Code 128'
./zint -o bar20.gif -b 20 --height=50 --border=10 -d 'Code 128'
./zint -o bar20.svg -b 20 --height=50 --border=10 -d 'Code 128'
echo testing Deutsche Post Leitcode
zint -o bar21.png -b 21 --height=50 --border=10 -d 3210987654321
zint -o bar21.eps -b 21 --height=50 --border=10 -d 3210987654321
zint -o bar21.svg -b 21 --height=50 --border=10 -d 3210987654321
./zint -o bar21.txt -b 21 -d 3210987654321
./zint -o bar21.gif -b 21 --height=50 --border=10 -d 3210987654321
./zint -o bar21.svg -b 21 --height=50 --border=10 -d 3210987654321
echo testing Deutsche Post Identcode
zint -o bar22.png -b 22 --height=50 --border=10 -d 10987654321
zint -o bar22.eps -b 22 --height=50 --border=10 -d 10987654321
zint -o bar22.svg -b 22 --height=50 --border=10 -d 10987654321
./zint -o bar22.txt -b 22 -d 10987654321
./zint -o bar22.gif -b 22 --height=50 --border=10 -d 10987654321
./zint -o bar22.svg -b 22 --height=50 --border=10 -d 10987654321
echo testing Code 16k
zint -o bar23.png -b 23 --height=50 --border=10 -d "Demonstration Code 16k symbol generated by libzint"
zint -o bar23.eps -b 23 --height=50 --border=10 -d "Demonstration Code 16k symbol generated by libzint"
zint -o bar23.svg -b 23 --height=50 --border=10 -d "Demonstration Code 16k symbol generated by libzint"
zint -o bar23a.png -b 23 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
zint -o bar23a.eps -b 23 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
zint -o bar23a.svg -b 23 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
./zint -o bar23.txt -b 23 -d "Demonstration Code 16k symbol generated by lib./zint"
./zint -o bar23.gif -b 23 --height=50 --border=10 -d "Demonstration Code 16k symbol generated by lib./zint"
./zint -o bar23.svg -b 23 --height=50 --border=10 -d "Demonstration Code 16k symbol generated by lib./zint"
./zint -o bar23a.txt -b 23 --gs1 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
./zint -o bar23a.gif -b 23 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
./zint -o bar23a.svg -b 23 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
echo testing Code 49
zint -o bar24.png -b 24 -d "Demonstration Code 49"
zint -o bar24.eps -b 24 -d "Demonstration Code 49"
zint -o bar24.svg -b 24 -d "Demonstration Code 49"
./zint -o bar24.txt -b 24 -d "Demonstration Code 49"
./zint -o bar24.gif -b 24 -d "Demonstration Code 49"
./zint -o bar24.svg -b 24 -d "Demonstration Code 49"
echo testing Code 93
zint -o bar25.png -b 25 --height=50 --border=10 -d 'Code 93'
zint -o bar25.eps -b 25 --height=50 --border=10 -d 'Code 93'
zint -o bar25.svg -b 25 --height=50 --border=10 -d 'Code 93'
./zint -o bar25.txt -b 25 -d 'Code 93'
./zint -o bar25.gif -b 25 --height=50 --border=10 -d 'Code 93'
./zint -o bar25.svg -b 25 --height=50 --border=10 -d 'Code 93'
echo testing Flattermarken
zint -o bar28.png -b 28 --height=50 --border=10 -d 87654321
zint -o bar28.eps -b 28 --height=50 --border=10 -d 87654321
zint -o bar28.svg -b 28 --height=50 --border=10 -d 87654321
./zint -o bar28.txt -b 28 -d 87654321
./zint -o bar28.gif -b 28 --height=50 --border=10 -d 87654321
./zint -o bar28.svg -b 28 --height=50 --border=10 -d 87654321
echo testing DataBar-14
zint -o bar29.png -b 29 --height=33 --border=10 -d 2001234567890
zint -o bar29.eps -b 29 --height=33 --border=10 -d 2001234567890
zint -o bar29.svg -b 29 --height=33 --border=10 -d 2001234567890
./zint -o bar29.txt -b 29 -d 2001234567890
./zint -o bar29.gif -b 29 --height=33 --border=10 -d 2001234567890
./zint -o bar29.svg -b 29 --height=33 --border=10 -d 2001234567890
echo testing DataBar Limited
zint -o bar30.png -b 30 --height=50 --border=10 -w 2 -d 31234567890
zint -o bar30.eps -b 30 --height=50 --border=10 -w 2 -d 31234567890
zint -o bar30.svg -b 30 --height=50 --border=10 -w 2 -d 31234567890
./zint -o bar30.txt -b 30 -w 2 -d 31234567890
./zint -o bar30.gif -b 30 --height=50 --border=10 -w 2 -d 31234567890
./zint -o bar30.svg -b 30 --height=50 --border=10 -w 2 -d 31234567890
echo testing DataBar Expanded
zint -o bar31.png -b 31 --height=50 --border=10 -d "[01]90012345678908[3103]001750"
zint -o bar31.eps -b 31 --height=50 --border=10 -d "[01]90012345678908[3103]001750"
zint -o bar31.svg -b 31 --height=50 --border=10 -d "[01]90012345678908[3103]001750"
./zint -o bar31.txt -b 31 -d "[01]90012345678908[3103]001750"
./zint -o bar31.gif -b 31 --height=50 --border=10 -d "[01]90012345678908[3103]001750"
./zint -o bar31.svg -b 31 --height=50 --border=10 -d "[01]90012345678908[3103]001750"
echo testing Telepen Alpha
zint -o bar32.png -b 32 --height=50 --border=10 -d 'Telepen'
zint -o bar32.eps -b 32 --height=50 --border=10 -d 'Telepen'
zint -o bar32.svg -b 32 --height=50 --border=10 -d 'Telepen'
./zint -o bar32.txt -b 32 -d 'Telepen'
./zint -o bar32.gif -b 32 --height=50 --border=10 -d 'Telepen'
./zint -o bar32.svg -b 32 --height=50 --border=10 -d 'Telepen'
echo testing UPC A
zint -o bar34.png -b 34 --height=50 --border=10 -d 10987654321
zint -o bar34.eps -b 34 --height=50 --border=10 -d 10987654321
zint -o bar34.svg -b 34 --height=50 --border=10 -d 10987654321
./zint -o bar34.txt -b 34 -d 10987654321
./zint -o bar34.gif -b 34 --height=50 --border=10 -d 10987654321
./zint -o bar34.svg -b 34 --height=50 --border=10 -d 10987654321
echo testing UPC A - 2 digit add-on
zint -o bar35.png -b 34 --height=50 --border=10 -d 10987654321+21
zint -o bar35.eps -b 34 --height=50 --border=10 -d 10987654321+21
zint -o bar35.svg -b 34 --height=50 --border=10 -d 10987654321+21
./zint -o bar35.txt -b 34 -d 10987654321+21
./zint -o bar35.gif -b 34 --height=50 --border=10 -d 10987654321+21
./zint -o bar35.svg -b 34 --height=50 --border=10 -d 10987654321+21
echo testing UPC A - 5 digit add-on
zint -o bar36.png -b 36 --height=50 --border=10 -d 10987654321+54321
zint -o bar36.eps -b 36 --height=50 --border=10 -d 10987654321+54321
zint -o bar36.svg -b 36 --height=50 --border=10 -d 10987654321+54321
./zint -o bar36.txt -b 36 -d 10987654321+54321
./zint -o bar36.gif -b 36 --height=50 --border=10 -d 10987654321+54321
./zint -o bar36.svg -b 36 --height=50 --border=10 -d 10987654321+54321
echo testing UPC E
zint -o bar37.png -b 37 --height=50 --border=10 -d 654321
zint -o bar37.eps -b 37 --height=50 --border=10 -d 654321
zint -o bar37.svg -b 37 --height=50 --border=10 -d 654321
./zint -o bar37.txt -b 37 -d 654321
./zint -o bar37.gif -b 37 --height=50 --border=10 -d 654321
./zint -o bar37.svg -b 37 --height=50 --border=10 -d 654321
echo testing UPC E - 2 digit add-on
zint -o bar38.png -b 37 --height=50 --border=10 -d 654321+21
zint -o bar38.eps -b 37 --height=50 --border=10 -d 654321+21
zint -o bar38.svg -b 37 --height=50 --border=10 -d 654321+21
./zint -o bar38.txt -b 37 -d 654321+21
./zint -o bar38.gif -b 37 --height=50 --border=10 -d 654321+21
./zint -o bar38.svg -b 37 --height=50 --border=10 -d 654321+21
echo testing UPC E - 5 digit add-on
zint -o bar39.png -b 37 --height=50 --border=10 -d 654321+54321
zint -o bar39.eps -b 37 --height=50 --border=10 -d 654321+54321
zint -o bar39.svg -b 37 --height=50 --border=10 -d 654321+54321
./zint -o bar39.txt -b 37 -d 654321+54321
./zint -o bar39.gif -b 37 --height=50 --border=10 -d 654321+54321
./zint -o bar39.svg -b 37 --height=50 --border=10 -d 654321+54321
echo testing PostNet-6
zint -o bar41.png -b 40 --border=10 -d 54321
zint -o bar41.eps -b 40 --border=10 -d 54321
zint -o bar41.svg -b 40 --border=10 -d 54321
./zint -o bar41.txt -b 40 -d 54321
./zint -o bar41.gif -b 40 --border=10 -d 54321
./zint -o bar41.svg -b 40 --border=10 -d 54321
echo testing PostNet-10
zint -o bar43.png -b 40 --border=10 -d 987654321
zint -o bar43.eps -b 40 --border=10 -d 987654321
zint -o bar43.svg -b 40 --border=10 -d 987654321
./zint -o bar43.txt -b 40 -d 987654321
./zint -o bar43.gif -b 40 --border=10 -d 987654321
./zint -o bar43.svg -b 40 --border=10 -d 987654321
echo testing PostNet-12
zint -o bar45.png -b 40 --border=10 -d 10987654321
zint -o bar45.eps -b 40 --border=10 -d 10987654321
zint -o bar45.svg -b 40 --border=10 -d 10987654321
./zint -o bar45.txt -b 40 -d 10987654321
./zint -o bar45.gif -b 40 --border=10 -d 10987654321
./zint -o bar45.svg -b 40 --border=10 -d 10987654321
echo testing MSI Code
zint -o bar47.png -b 47 --height=50 --border=10 -d 87654321
zint -o bar47.eps -b 47 --height=50 --border=10 -d 87654321
zint -o bar47.svg -b 47 --height=50 --border=10 -d 87654321
./zint -o bar47.txt -b 47 -d 87654321
./zint -o bar47.gif -b 47 --height=50 --border=10 -d 87654321
./zint -o bar47.svg -b 47 --height=50 --border=10 -d 87654321
echo testing FIM
zint -o bar49.png -b 49 --height=50 --border=10 -d D
zint -o bar49.eps -b 49 --height=50 --border=10 -d D
zint -o bar49.svg -b 49 --height=50 --border=10 -d D
./zint -o bar49.txt -b 49 -d D
./zint -o bar49.gif -b 49 --height=50 --border=10 -d D
./zint -o bar49.svg -b 49 --height=50 --border=10 -d D
echo testing LOGMARS
zint -o bar50.png -b 50 --height=50 --border=10 -d LOGMARS
zint -o bar50.eps -b 50 --height=50 --border=10 -d LOGMARS
zint -o bar50.svg -b 50 --height=50 --border=10 -d LOGMARS
./zint -o bar50.txt -b 50 -d LOGMARS
./zint -o bar50.gif -b 50 --height=50 --border=10 -d LOGMARS
./zint -o bar50.svg -b 50 --height=50 --border=10 -d LOGMARS
echo testing Pharmacode One-Track
zint -o bar51.png -b 51 --height=50 --border=10 -d 123456
zint -o bar51.eps -b 51 --height=50 --border=10 -d 123456
zint -o bar51.svg -b 51 --height=50 --border=10 -d 123456
./zint -o bar51.txt -b 51 -d 123456
./zint -o bar51.gif -b 51 --height=50 --border=10 -d 123456
./zint -o bar51.svg -b 51 --height=50 --border=10 -d 123456
echo testing Pharmazentralnumber
zint -o bar52.png -b 52 --height=50 --border=10 -d 654321
zint -o bar52.eps -b 52 --height=50 --border=10 -d 654321
zint -o bar52.svg -b 52 --height=50 --border=10 -d 654321
./zint -o bar52.txt -b 52 -d 654321
./zint -o bar52.gif -b 52 --height=50 --border=10 -d 654321
./zint -o bar52.svg -b 52 --height=50 --border=10 -d 654321
echo testing Pharmacode Two-Track
zint -o bar53.png -b 53 --height=50 --border=10 -d 12345678
zint -o bar53.eps -b 53 --height=50 --border=10 -d 12345678
zint -o bar53.svg -b 53 --height=50 --border=10 -d 12345678
./zint -o bar53.txt -b 53 --border=10 -d 12345678
./zint -o bar53.gif -b 53 --height=50 --border=10 -d 12345678
./zint -o bar53.svg -b 53 --height=50 --border=10 -d 12345678
echo testing PDF417
zint -o bar55.png -b 55 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
zint -o bar55.eps -b 55 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
zint -o bar55.svg -b 55 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
./zint -o bar55.txt -b 55 -d "Demonstration PDF417 symbol generated by libzint"
./zint -o bar55.gif -b 55 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
./zint -o bar55.svg -b 55 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
echo testing PDF417 Truncated
zint -o bar56.png -b 56 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
zint -o bar56.eps -b 56 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
zint -o bar56.svg -b 56 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
./zint -o bar56.txt -b 56 -d "Demonstration PDF417 symbol generated by libzint"
./zint -o bar56.gif -b 56 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
./zint -o bar56.svg -b 56 --border=10 -d "Demonstration PDF417 symbol generated by libzint"
echo testing Maxicode
zint -o bar57.png -b 57 --border=10 --primary="999999999840012" -d "Demonstration Maxicode symbol generated by libzint"
zint -o bar57.eps -b 57 --border=10 --primary="999999999840012" -d "Demonstration Maxicode symbol generated by libzint"
zint -o bar57.svg -b 57 --border=10 --primary="999999999840012" -d "Demonstration Maxicode symbol generated by libzint"
./zint -o bar57.txt -b 57 --primary="999999999840012" -d "Demonstration Maxicode symbol generated by libzint"
./zint -o bar57.gif -b 57 --border=10 --primary="999999999840012" -d "Demonstration Maxicode symbol generated by libzint"
./zint -o bar57.svg -b 57 --border=10 --primary="999999999840012" -d "Demonstration Maxicode symbol generated by libzint"
echo testing QR Code
zint -o bar58.png -b 58 --border=10 -d "Demonstration QR Code symbol generated by libzint"
zint -o bar58.eps -b 58 --border=10 -d "Demonstration QR Code symbol generated by libzint"
zint -o bar58.svg -b 58 --border=10 -d "Demonstration QR Code symbol generated by libzint"
zint -o bar58k.png -b 58 --kanji --border=10 -d "画像内の単語を非表示にする"
zint -o bar58k.eps -b 58 --kanji --border=10 -d "画像内の単語を非表示にする"
zint -o bar58k.svg -b 58 --kanji --border=10 -d "画像内の単語を非表示にする"
./zint -o bar58.txt -b 58 -d "Demonstration QR Code symbol generated by libzint"
./zint -o bar58.gif -b 58 --border=10 -d "Demonstration QR Code symbol generated by libzint"
./zint -o bar58.svg -b 58 --border=10 -d "Demonstration QR Code symbol generated by libzint"
./zint -o bar58k.txt -b 58 --kanji -d "画像内の単語を非表示にする"
./zint -o bar58k.gif -b 58 --kanji --border=10 -d "画像内の単語を非表示にする"
./zint -o bar58k.svg -b 58 --kanji --border=10 -d "画像内の単語を非表示にする"
echo testing Code 128 Subset B
zint -o bar60.png -b 60 --height=50 --border=10 -d 87654321
zint -o bar60.eps -b 60 --height=50 --border=10 -d 87654321
zint -o bar60.svg -b 60 --height=50 --border=10 -d 87654321
./zint -o bar60.txt -b 60 -d 87654321
./zint -o bar60.gif -b 60 --height=50 --border=10 -d 87654321
./zint -o bar60.svg -b 60 --height=50 --border=10 -d 87654321
echo testing Australian Post Standard Customer
zint -o bar63.png -b 63 --border=10 -d 87654321
zint -o bar63.eps -b 63 --border=10 -d 87654321
zint -o bar63.svg -b 63 --border=10 -d 87654321
./zint -o bar63.txt -b 63 -d 87654321
./zint -o bar63.gif -b 63 --border=10 -d 87654321
./zint -o bar63.svg -b 63 --border=10 -d 87654321
echo testing Australian Post Customer 2
zint -o bar64.png -b 63 --border=10 -d 87654321AUSPS
zint -o bar64.eps -b 63 --border=10 -d 87654321AUSPS
zint -o bar64.svg -b 63 --border=10 -d 87654321AUSPS
./zint -o bar64.txt -b 63 -d 87654321AUSPS
./zint -o bar64.gif -b 63 --border=10 -d 87654321AUSPS
./zint -o bar64.svg -b 63 --border=10 -d 87654321AUSPS
echo testing Australian Post Customer 3
zint -o bar65.png -b 63 --border=10 -d '87654321 AUSTRALIA'
zint -o bar65.eps -b 63 --border=10 -d '87654321 AUSTRALIA'
zint -o bar65.svg -b 63 --border=10 -d '87654321 AUSTRALIA'
./zint -o bar65.txt -b 63 -d '87654321 AUSTRALIA'
./zint -o bar65.gif -b 63 --border=10 -d '87654321 AUSTRALIA'
./zint -o bar65.svg -b 63 --border=10 -d '87654321 AUSTRALIA'
echo testing Australian Post Reply Paid
zint -o bar66.png -b 66 --border=10 -d 87654321
zint -o bar66.eps -b 66 --border=10 -d 87654321
zint -o bar66.svg -b 66 --border=10 -d 87654321
./zint -o bar66.txt -b 66 -d 87654321
./zint -o bar66.gif -b 66 --border=10 -d 87654321
./zint -o bar66.svg -b 66 --border=10 -d 87654321
echo testing Australian Post Routing
zint -o bar67.png -b 67 --border=10 -d 87654321
zint -o bar67.eps -b 67 --border=10 -d 87654321
zint -o bar67.svg -b 67 --border=10 -d 87654321
./zint -o bar67.txt -b 67 -d 87654321
./zint -o bar67.gif -b 67 --border=10 -d 87654321
./zint -o bar67.svg -b 67 --border=10 -d 87654321
echo testing Australian Post Redirection
zint -o bar68.png -b 68 --border=10 -d 87654321
zint -o bar68.eps -b 68 --border=10 -d 87654321
zint -o bar68.svg -b 68 --border=10 -d 87654321
./zint -o bar68.txt -b 68 -d 87654321
./zint -o bar68.gif -b 68 --border=10 -d 87654321
./zint -o bar68.svg -b 68 --border=10 -d 87654321
echo testing ISBN Code
zint -o bar69.png -b 69 --height=50 --border=10 -d 0333638514
zint -o bar69.eps -b 69 --height=50 --border=10 -d 0333638514
zint -o bar69.svg -b 69 --height=50 --border=10 -d 0333638514
./zint -o bar69.txt -b 69 -d 0333638514
./zint -o bar69.gif -b 69 --height=50 --border=10 -d 0333638514
./zint -o bar69.svg -b 69 --height=50 --border=10 -d 0333638514
echo testing Royal Mail 4 State
zint -o bar70.png -b 70 --border=10 -d ROYALMAIL
zint -o bar70.eps -b 70 --border=10 -d ROYALMAIL
zint -o bar70.svg -b 70 --border=10 -d ROYALMAIL
./zint -o bar70.txt -b 70 -d ROYALMAIL
./zint -o bar70.gif -b 70 --border=10 -d ROYALMAIL
./zint -o bar70.svg -b 70 --border=10 -d ROYALMAIL
echo testing Data Matrix
zint -o bar71.png -b 71 --border=10 -d "Demonstration Data Matrix symbol generated by libzint"
zint -o bar71.eps -b 71 --border=10 -d "Demonstration Data Matrix symbol generated by libzint"
zint -o bar71.svg -b 71 --border=10 -d "Demonstration Data Matrix symbol generated by libzint"
zint -o bar71a.png -b 71 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
zint -o bar71a.eps -b 71 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
zint -o bar71a.svg -b 71 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
./zint -o bar71.txt -b 71 -d "Demonstration Data Matrix symbol generated by libzint"
./zint -o bar71.gif -b 71 --border=10 -d "Demonstration Data Matrix symbol generated by libzint"
./zint -o bar71.svg -b 71 --border=10 -d "Demonstration Data Matrix symbol generated by libzint"
./zint -o bar71a.txt -b 71 --gs1 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
./zint -o bar71a.gif -b 71 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
./zint -o bar71a.svg -b 71 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
echo testing EAN-14
zint -o bar72.png -b 72 --height=50 --border=10 -d 3210987654321
zint -o bar72.eps -b 72 --height=50 --border=10 -d 3210987654321
zint -o bar72.svg -b 72 --height=50 --border=10 -d 3210987654321
./zint -o bar72.txt -b 72 -d 3210987654321
./zint -o bar72.gif -b 72 --height=50 --border=10 -d 3210987654321
./zint -o bar72.svg -b 72 --height=50 --border=10 -d 3210987654321
echo testing NVE-18
zint -o bar75.png -b 75 --height=50 --border=10 -d 76543210987654321
zint -o bar75.eps -b 75 --height=50 --border=10 -d 76543210987654321
zint -o bar75.svg -b 75 --height=50 --border=10 -d 76543210987654321
./zint -o bar75.txt -b 75 -d 76543210987654321
./zint -o bar75.gif -b 75 --height=50 --border=10 -d 76543210987654321
./zint -o bar75.svg -b 75 --height=50 --border=10 -d 76543210987654321
echo testing Japanese Post
zint -o bar76.png -b 76 --border=10 -d "10000131-3-2-503"
zint -o bar76.eps -b 76 --border=10 -d "10000131-3-2-503"
zint -o bar76.svg -b 76 --border=10 -d "10000131-3-2-503"
./zint -o bar76.txt -b 76 -d "10000131-3-2-503"
./zint -o bar76.gif -b 76 --border=10 -d "10000131-3-2-503"
./zint -o bar76.svg -b 76 --border=10 -d "10000131-3-2-503"
echo testing Korea Post
zint -o bar77.png -b 77 --height=50 --border=10 -d 123456
zint -o bar77.eps -b 77 --height=50 --border=10 -d 123456
zint -o bar77.svg -b 77 --height=50 --border=10 -d 123456
./zint -o bar77.txt -b 77 -d 123456
./zint -o bar77.gif -b 77 --height=50 --border=10 -d 123456
./zint -o bar77.svg -b 77 --height=50 --border=10 -d 123456
echo testing DataBar Truncated
zint -o bar78.png -b 29 --height=13 --border=10 -d 1234567890
zint -o bar78.eps -b 29 --height=13 --border=10 -d 1234567890
zint -o bar78.svg -b 29 --height=13 --border=10 -d 1234567890
./zint -o bar78.txt -b 29 -d 1234567890
./zint -o bar78.gif -b 29 --height=13 --border=10 -d 1234567890
./zint -o bar78.svg -b 29 --height=13 --border=10 -d 1234567890
echo testing DataBar Stacked
zint -o bar79.png -b 79 --border=10 -d 1234567890
zint -o bar79.eps -b 79 --border=10 -d 1234567890
zint -o bar79.svg -b 79 --border=10 -d 1234567890
./zint -o bar79.txt -b 79 -d 1234567890
./zint -o bar79.gif -b 79 --border=10 -d 1234567890
./zint -o bar79.svg -b 79 --border=10 -d 1234567890
echo testing DataBar Stacked Omnidirectional
zint -o bar80.png -b 80 --height=69 --border=10 -d 3456789012
zint -o bar80.eps -b 80 --height=69 --border=10 -d 3456789012
zint -o bar80.svg -b 80 --height=69 --border=10 -d 3456789012
./zint -o bar80.txt -b 80 -d 3456789012
./zint -o bar80.gif -b 80 --height=69 --border=10 -d 3456789012
./zint -o bar80.svg -b 80 --height=69 --border=10 -d 3456789012
echo testing DataBar Expanded Stacked
zint -o bar81.png -b 81 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
zint -o bar81.eps -b 81 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
zint -o bar81.svg -b 81 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
./zint -o bar81.txt -b 81 -d "[01]98898765432106[3202]012345[15]991231"
./zint -o bar81.gif -b 81 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
./zint -o bar81.svg -b 81 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
echo testing Planet 12 Digit
zint -o bar82.png -b 82 --border=10 -d 10987654321
zint -o bar82.eps -b 82 --border=10 -d 10987654321
zint -o bar82.svg -b 82 --border=10 -d 10987654321
./zint -o bar82.txt -b 82 -d 10987654321
./zint -o bar82.gif -b 82 --border=10 -d 10987654321
./zint -o bar82.svg -b 82 --border=10 -d 10987654321
echo testing Planet 14 Digit
zint -o bar83.png -b 82 --border=10 -d 3210987654321
zint -o bar83.eps -b 82 --border=10 -d 3210987654321
zint -o bar83.svg -b 82 --border=10 -d 3210987654321
./zint -o bar83.txt -b 82 -d 3210987654321
./zint -o bar83.gif -b 82 --border=10 -d 3210987654321
./zint -o bar83.svg -b 82 --border=10 -d 3210987654321
echo testing Micro PDF417
zint -o bar84.png -b 84 --border=10 -d "Demonstration MicroPDF417 symbol generated by libzint"
zint -o bar84.eps -b 84 --border=10 -d "Demonstration MicroPDF417 symbol generated by libzint"
zint -o bar84.svg -b 84 --border=10 -d "Demonstration MicroPDF417 symbol generated by libzint"
./zint -o bar84.txt -b 84 -d "Demonstration MicroPDF417 symbol generated by libzint"
./zint -o bar84.gif -b 84 --border=10 -d "Demonstration MicroPDF417 symbol generated by libzint"
./zint -o bar84.svg -b 84 --border=10 -d "Demonstration MicroPDF417 symbol generated by libzint"
echo testing USPS OneCode 4-State Customer Barcode
zint -o bar85.png -b 85 --border=10 -d 01234567094987654321
zint -o bar85.eps -b 85 --border=10 -d 01234567094987654321
zint -o bar85.svg -b 85 --border=10 -d 01234567094987654321
./zint -o bar85.txt -b 85 -d 01234567094987654321
./zint -o bar85.gif -b 85 --border=10 -d 01234567094987654321
./zint -o bar85.svg -b 85 --border=10 -d 01234567094987654321
echo testing Plessey Code with bidirectional reading support
zint -o bar86.png -b 86 --height=50 --border=10 -d 87654321
zint -o bar86.eps -b 86 --height=50 --border=10 -d 87654321
zint -o bar86.svg -b 86 --height=50 --border=10 -d 87654321
./zint -o bar86.txt -b 86 -d 87654321
./zint -o bar86.gif -b 86 --height=50 --border=10 -d 87654321
./zint -o bar86.svg -b 86 --height=50 --border=10 -d 87654321
echo testing Telepen Numeric
zint -o bar87.png -b 87 --height=50 --border=10 -d 87654321
zint -o bar87.eps -b 87 --height=50 --border=10 -d 87654321
zint -o bar87.svg -b 87 --height=50 --border=10 -d 87654321
./zint -o bar87.txt -b 87 -d 87654321
./zint -o bar87.gif -b 87 --height=50 --border=10 -d 87654321
./zint -o bar87.svg -b 87 --height=50 --border=10 -d 87654321
echo testing ITF-14
zint -o bar89.png -b 89 --height=50 --border=10 -d 3210987654321
zint -o bar89.eps -b 89 --height=50 --border=10 -d 3210987654321
zint -o bar89.svg -b 89 --height=50 --border=10 -d 3210987654321
./zint -o bar89.txt -b 89 -d 3210987654321
./zint -o bar89.gif -b 89 --height=50 --border=10 -d 3210987654321
./zint -o bar89.svg -b 89 --height=50 --border=10 -d 3210987654321
echo testing KIX Code
zint -o bar90.png -b 90 --border=10 -d '1231FZ13Xhs'
zint -o bar90.eps -b 90 --border=10 -d '1231FZ13Xhs'
zint -o bar90.svg -b 90 --border=10 -d '1231FZ13Xhs'
./zint -o bar90.txt -b 90 -d '1231FZ13Xhs'
./zint -o bar90.gif -b 90 --border=10 -d '1231FZ13Xhs'
./zint -o bar90.svg -b 90 --border=10 -d '1231FZ13Xhs'
echo testing Aztec Code
zint -o bar92.png -b 92 --border=10 -d "Demonstration Aztec Code symbol generated by libzint"
zint -o bar92.eps -b 92 --border=10 -d "Demonstration Aztec Code symbol generated by libzint"
zint -o bar92.svg -b 92 --border=10 -d "Demonstration Aztec Code symbol generated by libzint"
zint -o bar92a.png -b 92 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
zint -o bar92a.eps -b 92 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
zint -o bar92a.svg -b 92 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
./zint -o bar92.txt -b 92 -d "Demonstration Aztec Code symbol generated by libzint"
./zint -o bar92.gif -b 92 --border=10 -d "Demonstration Aztec Code symbol generated by libzint"
./zint -o bar92.svg -b 92 --border=10 -d "Demonstration Aztec Code symbol generated by libzint"
./zint -o bar92a.txt -b 92 --gs1 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
./zint -o bar92a.gif -b 92 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
./zint -o bar92a.svg -b 92 --gs1 --border=10 -d "[01]98898765432106[02]13012345678909[10]1234567ABCDEFG[3202]012345[15]991231"
echo testing DAFT Code
zint -o bar93.png -b 93 --border=10 -d "daftdaftdaftdaftdaftdaftdaftdaftdaft"
zint -o bar93.eps -b 93 --border=10 -d "daftdaftdaftdaftdaftdaftdaftdaftdaft"
zint -o bar93.svg -b 93 --border=10 -d "daftdaftdaftdaftdaftdaftdaftdaftdaft"
./zint -o bar93.txt -b 93 -d "daftdaftdaftdaftdaftdaftdaftdaftdaft"
./zint -o bar93.gif -b 93 --border=10 -d "daftdaftdaftdaftdaftdaftdaftdaftdaft"
./zint -o bar93.svg -b 93 --border=10 -d "daftdaftdaftdaftdaftdaftdaftdaftdaft"
echo testing Micro QR Code
zint -o bar97.png -b 97 --border=10 -d "MicroQR Code"
zint -o bar97.eps -b 97 --border=10 -d "MicroQR Code"
zint -o bar97.svg -b 97 --border=10 -d "MicroQR Code"
zint -o bar97k.png -b 97 --kanji --border=10 -d "小さい"
zint -o bar97k.eps -b 97 --kanji --border=10 -d "小さい"
zint -o bar97k.svg -b 97 --kanji --border=10 -d "小さい"
./zint -o bar97.txt -b 97 -d "MicroQR Code"
./zint -o bar97.gif -b 97 --border=10 -d "MicroQR Code"
./zint -o bar97.svg -b 97 --border=10 -d "MicroQR Code"
./zint -o bar97k.txt -b 97 --kanji -d "小さい"
./zint -o bar97k.gif -b 97 --kanji --border=10 -d "小さい"
./zint -o bar97k.svg -b 97 --kanji --border=10 -d "小さい"
echo testing HIBC LIC 128
zint -o bar98.png -b 98 --border=10 -d "A99912345/9901510X3"
zint -o bar98.eps -b 98 --border=10 -d "A99912345/9901510X3"
zint -o bar98.svg -b 98 --border=10 -d "A99912345/9901510X3"
./zint -o bar98.txt -b 98 -d "A99912345/9901510X3"
./zint -o bar98.gif -b 98 --border=10 -d "A99912345/9901510X3"
./zint -o bar98.svg -b 98 --border=10 -d "A99912345/9901510X3"
echo testing HIBC LIC 39
zint -o bar99.png -b 99 --border=10 -d "A123BJC5D6E71"
zint -o bar99.eps -b 99 --border=10 -d "A123BJC5D6E71"
zint -o bar99.svg -b 99 --border=10 -d "A123BJC5D6E71"
./zint -o bar99.txt -b 99 -d "A123BJC5D6E71"
./zint -o bar99.gif -b 99 --border=10 -d "A123BJC5D6E71"
./zint -o bar99.svg -b 99 --border=10 -d "A123BJC5D6E71"
echo testing HIBC LIC Data Matrix
zint -o bar102.png -b 102 --border=10 -d "A99912345/9901510X3"
zint -o bar102.eps -b 102 --border=10 -d "A99912345/9901510X3"
zint -o bar102.svg -b 102 --border=10 -d "A99912345/9901510X3"
./zint -o bar102.txt -b 102 -d "A99912345/9901510X3"
./zint -o bar102.gif -b 102 --border=10 -d "A99912345/9901510X3"
./zint -o bar102.svg -b 102 --border=10 -d "A99912345/9901510X3"
echo testing HIBC LIC QR-Code
zint -o bar104.png -b 104 --border=10 -d "A99912345/9901510X3"
zint -o bar104.eps -b 104 --border=10 -d "A99912345/9901510X3"
zint -o bar104.svg -b 104 --border=10 -d "A99912345/9901510X3"
./zint -o bar104.txt -b 104 -d "A99912345/9901510X3"
./zint -o bar104.gif -b 104 --border=10 -d "A99912345/9901510X3"
./zint -o bar104.svg -b 104 --border=10 -d "A99912345/9901510X3"
echo testing HIBC LIC PDF417
zint -o bar106.png -b 106 --border=10 -d "A99912345/9901510X3"
zint -o bar106.eps -b 106 --border=10 -d "A99912345/9901510X3"
zint -o bar106.svg -b 106 --border=10 -d "A99912345/9901510X3"
./zint -o bar106.txt -b 106 -d "A99912345/9901510X3"
./zint -o bar106.gif -b 106 --border=10 -d "A99912345/9901510X3"
./zint -o bar106.svg -b 106 --border=10 -d "A99912345/9901510X3"
echo testing HIBC LIC MicroPDF417
zint -o bar108.png -b 108 --border=10 -d "A99912345/9901510X3"
zint -o bar108.eps -b 108 --border=10 -d "A99912345/9901510X3"
zint -o bar108.svg -b 108 --border=10 -d "A99912345/9901510X3"
./zint -o bar108.txt -b 108 -d "A99912345/9901510X3"
./zint -o bar108.gif -b 108 --border=10 -d "A99912345/9901510X3"
./zint -o bar108.svg -b 108 --border=10 -d "A99912345/9901510X3"
echo testing HIBC LIC Aztec Code
zint -o bar112.png -b 112 --border=10 -d "A99912345/9901510X3"
zint -o bar112.eps -b 112 --border=10 -d "A99912345/9901510X3"
zint -o bar112.svg -b 112 --border=10 -d "A99912345/9901510X3"
./zint -o bar112.txt -b 112 -d "A99912345/9901510X3"
./zint -o bar112.gif -b 112 --border=10 -d "A99912345/9901510X3"
./zint -o bar112.svg -b 112 --border=10 -d "A99912345/9901510X3"
echo testing DotCode
./zint -o bar115.txt -b 115 -d "Demonstration DotCode symbol generated by libzint"
./zint -o bar115.gif -b 115 --scale=5 --border=10 -d "Demonstration DotCode symbol generated by libzint"
./zint -o bar115.svg -b 115 --scale=5 --border=10 -d "Demonstration DotCode symbol generated by libzint"
./zint -o bar115a.txt -b 115 --gs1 -d "[01]98898765432106[3202]012345[15]991231"
./zint -o bar115a.gif -b 115 --gs1 --scale=5 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
./zint -o bar115a.svg -b 115 --gs1 --scale=5 --border=10 -d "[01]98898765432106[3202]012345[15]991231"
echo testing Han Xin Code
./zint -o bar116.txt -b 116 -d "Demonstration DotCode symbol generated by libzint"
./zint -o bar116.gif -b 116 --scale=5 --border=10 -d "Demonstration DotCode symbol generated by libzint"
./zint -o bar116.svg -b 116 --scale=5 --border=10 -d "Demonstration DotCode symbol generated by libzint"
echo testing Aztec Runes
zint -o bar128.png -b 128 --border=10 -d 125
zint -o bar128.eps -b 128 --border=10 -d 125
zint -o bar128.svg -b 128 --border=10 -d 125
./zint -o bar128.txt -b 128 -d 125
./zint -o bar128.gif -b 128 --border=10 -d 125
./zint -o bar128.svg -b 128 --border=10 -d 125
echo testing Code 23
zint -o bar129.png -b 129 --border=10 -d "12345678"
zint -o bar129.eps -b 129 --border=10 -d "12345678"
zint -o bar129.svg -b 129 --border=10 -d "12345678"
./zint -o bar129.txt -b 129 -d "12345678"
./zint -o bar129.gif -b 129 --border=10 -d "12345678"
./zint -o bar129.svg -b 129 --border=10 -d "12345678"
echo testing EAN-8 Composite with CC-A
zint -o bar130.png -b 130 --height=100 --border=10 --mode=1 --primary=1234567 -d "[21]A12345678"
zint -o bar130.eps -b 130 --height=100 --border=10 --mode=1 --primary=1234567 -d "[21]A12345678"
zint -o bar130.svg -b 130 --height=100 --border=10 --mode=1 --primary=1234567 -d "[21]A12345678"
./zint -o bar130.txt -b 130 --mode=1 --primary=1234567 -d "[21]A12345678"
./zint -o bar130.gif -b 130 --height=100 --border=10 --mode=1 --primary=1234567 -d "[21]A12345678"
./zint -o bar130.svg -b 130 --height=100 --border=10 --mode=1 --primary=1234567 -d "[21]A12345678"
echo testing EAN-13 Composite with CC-A
zint -o bar130a.png -b 130 --height=100 --border=10 --mode=1 --primary=331234567890 -d "[99]1234-abcd"
zint -o bar130a.eps -b 130 --height=100 --border=10 --mode=1 --primary=331234567890 -d "[99]1234-abcd"
zint -o bar130a.svg -b 130 --height=100 --border=10 --mode=1 --primary=331234567890 -d "[99]1234-abcd"
./zint -o bar130a.txt -b 130 --mode=1 --primary=331234567890 -d "[99]1234-abcd"
./zint -o bar130a.gif -b 130 --height=100 --border=10 --mode=1 --primary=331234567890 -d "[99]1234-abcd"
./zint -o bar130a.svg -b 130 --height=100 --border=10 --mode=1 --primary=331234567890 -d "[99]1234-abcd"
echo testing UCC/EAN-128 Composite with CC-A
zint -o bar131.png -b 131 --height=100 --border=10 --mode=1 --primary="[01]03212345678906" -d "[10]1234567ABCDEFG"
zint -o bar131.eps -b 131 --height=100 --border=10 --mode=1 --primary="[01]03212345678906" -d "[10]1234567ABCDEFG"
zint -o bar131.svg -b 131 --height=100 --border=10 --mode=1 --primary="[01]03212345678906" -d "[10]1234567ABCDEFG"
./zint -o bar131.txt -b 131 --mode=1 --primary="[01]03212345678906" -d "[10]1234567ABCDEFG"
./zint -o bar131.gif -b 131 --height=100 --border=10 --mode=1 --primary="[01]03212345678906" -d "[10]1234567ABCDEFG"
./zint -o bar131.svg -b 131 --height=100 --border=10 --mode=1 --primary="[01]03212345678906" -d "[10]1234567ABCDEFG"
echo testing UCC/EAN-128 Composite with CC-C
zint -o bar131a.png -b 131 --height=100 --border=10 --mode=3 --primary="[00]030123456789012340" -d "[02]13012345678909[10]1234567ABCDEFG"
zint -o bar131a.eps -b 131 --height=100 --border=10 --mode=3 --primary="[00]030123456789012340" -d "[02]13012345678909[10]1234567ABCDEFG"
zint -o bar131a.svg -b 131 --height=100 --border=10 --mode=3 --primary="[00]030123456789012340" -d "[02]13012345678909[10]1234567ABCDEFG"
./zint -o bar131a.txt -b 131 --mode=3 --primary="[00]030123456789012340" -d "[02]13012345678909[10]1234567ABCDEFG"
./zint -o bar131a.gif -b 131 --height=100 --border=10 --mode=3 --primary="[00]030123456789012340" -d "[02]13012345678909[10]1234567ABCDEFG"
./zint -o bar131a.svg -b 131 --height=100 --border=10 --mode=3 --primary="[00]030123456789012340" -d "[02]13012345678909[10]1234567ABCDEFG"
echo testing DataBar-14 Composite with CC-A
zint -o bar132.png -b 132 --height=100 --border=10 --mode=1 --primary=361234567890 -d "[11]990102"
zint -o bar132.eps -b 132 --height=100 --border=10 --mode=1 --primary=361234567890 -d "[11]990102"
zint -o bar132.svg -b 132 --height=100 --border=10 --mode=1 --primary=361234567890 -d "[11]990102"
./zint -o bar132.txt -b 132 --mode=1 --primary=361234567890 -d "[11]990102"
./zint -o bar132.gif -b 132 --height=100 --border=10 --mode=1 --primary=361234567890 -d "[11]990102"
./zint -o bar132.svg -b 132 --height=100 --border=10 --mode=1 --primary=361234567890 -d "[11]990102"
echo testing DataBar Limited Composite with CC-B
zint -o bar133.png -b 133 --height=100 --border=10 --mode=2 --primary=351234567890 -d "[21]abcdefghijklmnopqrstuv"
zint -o bar133.eps -b 133 --height=100 --border=10 --mode=2 --primary=351234567890 -d "[21]abcdefghijklmnopqrstuv"
zint -o bar133.svg -b 133 --height=100 --border=10 --mode=2 --primary=351234567890 -d "[21]abcdefghijklmnopqrstuv"
./zint -o bar133.txt -b 133 --mode=2 --primary=351234567890 -d "[21]abcdefghijklmnopqrstuv"
./zint -o bar133.gif -b 133 --height=100 --border=10 --mode=2 --primary=351234567890 -d "[21]abcdefghijklmnopqrstuv"
./zint -o bar133.svg -b 133 --height=100 --border=10 --mode=2 --primary=351234567890 -d "[21]abcdefghijklmnopqrstuv"
echo testing DataBar Expanded Composite with CC-A
zint -o bar134.png -b 134 --height=100 --border=10 --mode=1 --primary="[01]93712345678904[3103]001234" -d "[91]1A2B3C4D5E"
zint -o bar134.eps -b 134 --height=100 --border=10 --mode=1 --primary="[01]93712345678904[3103]001234" -d "[91]1A2B3C4D5E"
zint -o bar134.svg -b 134 --height=100 --border=10 --mode=1 --primary="[01]93712345678904[3103]001234" -d "[91]1A2B3C4D5E"
./zint -o bar134.txt -b 134 --mode=1 --primary="[01]93712345678904[3103]001234" -d "[91]1A2B3C4D5E"
./zint -o bar134.gif -b 134 --height=100 --border=10 --mode=1 --primary="[01]93712345678904[3103]001234" -d "[91]1A2B3C4D5E"
./zint -o bar134.svg -b 134 --height=100 --border=10 --mode=1 --primary="[01]93712345678904[3103]001234" -d "[91]1A2B3C4D5E"
echo testing UPC-A Composite with CC-A
zint -o bar135.png -b 135 --height=100 --border=10 --mode=1 --primary=10987654321 -d "[15]021231"
zint -o bar135.eps -b 135 --height=100 --border=10 --mode=1 --primary=10987654321 -d "[15]021231"
zint -o bar135.svg -b 135 --height=100 --border=10 --mode=1 --primary=10987654321 -d "[15]021231"
./zint -o bar135.txt -b 135 --mode=1 --primary=10987654321 -d "[15]021231"
./zint -o bar135.gif -b 135 --height=100 --border=10 --mode=1 --primary=10987654321 -d "[15]021231"
./zint -o bar135.svg -b 135 --height=100 --border=10 --mode=1 --primary=10987654321 -d "[15]021231"
echo testing UPC-E Composite with CC-A
zint -o bar136.png -b 136 --height=100 --border=10 --mode=1 --primary=121230 -d "[15]021231"
zint -o bar136.eps -b 136 --height=100 --border=10 --mode=1 --primary=121230 -d "[15]021231"
zint -o bar136.svg -b 136 --height=100 --border=10 --mode=1 --primary=121230 -d "[15]021231"
./zint -o bar136.txt -b 136 --mode=1 --primary=121230 -d "[15]021231"
./zint -o bar136.gif -b 136 --height=100 --border=10 --mode=1 --primary=121230 -d "[15]021231"
./zint -o bar136.svg -b 136 --height=100 --border=10 --mode=1 --primary=121230 -d "[15]021231"
echo testing DataBar-14 Stacked Composite with CC-A
zint -o bar137.png -b 137 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
zint -o bar137.eps -b 137 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
zint -o bar137.svg -b 137 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
./zint -o bar137.txt -b 137 --mode=1 --primary=341234567890 -d "[17]010200"
./zint -o bar137.gif -b 137 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
./zint -o bar137.svg -b 137 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
echo testing DataBar-14 Stacked Omnidirectional Composite with CC-A
zint -o bar138.png -b 138 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
zint -o bar138.eps -b 138 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
zint -o bar138.svg -b 138 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
./zint -o bar138.txt -b 138 --mode=1 --primary=341234567890 -d "[17]010200"
./zint -o bar138.gif -b 138 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
./zint -o bar138.svg -b 138 --border=10 --mode=1 --primary=341234567890 -d "[17]010200"
echo testing DataBar Expanded Stacked Composite with CC-A
zint -o bar139.png -b 139 --height=150 --border=10 --mode=1 --primary="[01]00012345678905[10]ABCDEF" -d "[21]12345678"
zint -o bar139.eps -b 139 --height=150 --border=10 --mode=1 --primary="[01]00012345678905[10]ABCDEF" -d "[21]12345678"
zint -o bar139.svg -b 139 --height=150 --border=10 --mode=1 --primary="[01]00012345678905[10]ABCDEF" -d "[21]12345678"
./zint -o bar139.txt -b 139 --mode=1 --primary="[01]00012345678905[10]ABCDEF" -d "[21]12345678"
./zint -o bar139.gif -b 139 --height=150 --border=10 --mode=1 --primary="[01]00012345678905[10]ABCDEF" -d "[21]12345678"
./zint -o bar139.svg -b 139 --height=150 --border=10 --mode=1 --primary="[01]00012345678905[10]ABCDEF" -d "[21]12345678"
echo testing Channel Code
zint -o bar140.png -b 140 --height=100 --border=10 -d "12345"
zint -o bar140.eps -b 140 --height=100 --border=10 -d "12345"
zint -o bar140.svg -b 140 --height=100 --border=10 -d "12345"
./zint -o bar140.txt -b 140 -d "12345"
./zint -o bar140.gif -b 140 --height=100 --border=10 -d "12345"
./zint -o bar140.svg -b 140 --height=100 --border=10 -d "12345"
echo testing Code One
zint -o bar141.png -b 141 --border=10 -d "Demonstration Code One symbol generated by libzint"
zint -o bar141.eps -b 141 --border=10 -d "Demonstration Code One symbol generated by libzint"
zint -o bar141.svg -b 141 --border=10 -d "Demonstration Code One symbol generated by libzint"
./zint -o bar141.txt -b 141 -d "Demonstration Code One symbol generated by libzint"
./zint -o bar141.gif -b 141 --border=10 -d "Demonstration Code One symbol generated by libzint"
./zint -o bar141.svg -b 141 --border=10 -d "Demonstration Code One symbol generated by libzint"
echo testing Grid Matrix
zint -o bar142.png -b 142 --border=10 -d "Demonstration Grid Matrix generated by libzint"
zint -o bar142.eps -b 142 --border=10 -d "Demonstration Grid Matrix generated by libzint"
zint -o bar142.svg -b 142 --border=10 -d "Demonstration Grid Matrix generated by libzint"
echo testing PNG rotation
zint -o barrot0.png -b 130 --height=50 --border=10 --mode=1 --rotate=0 --primary=331234567890+01234 -d "[99]1234-abcd"
zint -o barrot90.png -b 130 --height=50 --border=10 --mode=1 --rotate=90 --primary=331234567890+01234 -d "[99]1234-abcd"
zint -o barrot180.png -b 130 --height=50 --border=10 --mode=1 --rotate=180 --primary=331234567890+01234 -d "[99]1234-abcd"
zint -o barrot270.png -b 130 --height=50 --border=10 --mode=1 --rotate=270 --primary=331234567890+01234 -d "[99]1234-abcd"
./zint -o bar142.txt -b 142 -d "Demonstration Grid Matrix generated by libzint"
./zint -o bar142.gif -b 142 --border=10 -d "Demonstration Grid Matrix generated by libzint"
./zint -o bar142.svg -b 142 --border=10 -d "Demonstration Grid Matrix generated by libzint"
echo testing output formats
./zint -o barout.png -b 58 --border=10 -d "Sample output QR Code"
./zint -o barout.gif -b 58 --border=10 -d "Sample output QR Code"
./zint -o barout.bmp -b 58 --border=10 -d "Sample output QR Code"
./zint -o barout.pcx -b 58 --border=10 -d "Sample output QR Code"
./zint -o barout.eps -b 58 --border=10 -d "Sample output QR Code"
./zint -o barout.svg -b 58 --border=10 -d "Sample output QR Code"
echo testing image rotation
./zint -o barrot0.gif -b 130 --height=50 --border=10 --mode=1 --rotate=0 --primary=331234567890+01234 -d "[99]1234-abcd"
./zint -o barrot90.gif -b 130 --height=50 --border=10 --mode=1 --rotate=90 --primary=331234567890+01234 -d "[99]1234-abcd"
./zint -o barrot180.gif -b 130 --height=50 --border=10 --mode=1 --rotate=180 --primary=331234567890+01234 -d "[99]1234-abcd"
./zint -o barrot270.gif -b 130 --height=50 --border=10 --mode=1 --rotate=270 --primary=331234567890+01234 -d "[99]1234-abcd"
echo testing Extended ASCII support
zint -o barext.png --height=50 --border=10 -d "größer"
zint -o barext.svg --height=50 --border=10 -d "größer"
./zint -o barext.txt -d "größer"
./zint -o barext.svg --height=50 --border=10 -d "größer"

View File

@ -39,6 +39,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags fl)
"Aztec Runes",
"Channel Code",
"Codabar",
"Codablock",
"Code 11",
"Code 128 (ISO 15417)",
"Code 16k",
@ -70,7 +71,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags fl)
"GS1 DataBar Stacked",
"GS1 DataBar Stacked Omnidirectional",
"Han Xin (Chinese Sensible) Code",
"ITF-14",
"ITF-14",
"International Standard Book Number (ISBN)",
"Japanese Postal Barcode",
"Korean Postal Barcode",
@ -108,7 +109,7 @@ MainWindow::MainWindow(QWidget* parent, Qt::WFlags fl)
bstyle->addItem(metaObject()->enumerator(0).key(i));
bstyle->setItemText(i,bstyle_text[i]);
}
bstyle->setCurrentIndex(9);
bstyle->setCurrentIndex(10);
change_options();
update_preview();
view->scene()->addItem(&m_bc);

View File

@ -46,6 +46,7 @@ public:
AZRUNE =128,
CHANNEL =140,
CODABAR =18,
CODABLOCK =74,
CODE11 =1,
CODE128 =20,
CODE16K =23,