command line: allow data/input args anywhere on line; frontend tests

This commit is contained in:
gitlost 2020-08-04 22:22:26 +01:00
parent 2fcf622754
commit 736bc76f66
9 changed files with 891 additions and 185 deletions

View file

@ -86,7 +86,7 @@ INTERNAL void to_upper(unsigned char source[]) {
for (i = 0; i < src_len; i++) {
if ((source[i] >= 'a') && (source[i] <= 'z')) {
source [i] = (source[i] - 'a') + 'A';
source[i] = (source[i] - 'a') + 'A';
}
}
}

View file

@ -235,7 +235,7 @@ static int dump_plot(struct zint_symbol *symbol) {
space++;
byt = 0;
}
if (space == 2) {
if (space == 2 && i + 1 < symbol->width) {
fputc(' ', f);
space = 0;
}

View file

@ -183,7 +183,7 @@ INTERNAL int svg_plot(struct zint_symbol *symbol) {
fsvg = fopen(symbol->outfile, "w");
}
if (fsvg == NULL) {
strcpy(symbol->errtxt, "660: Could not open output file");
strcpy(symbol->errtxt, "680: Could not open output file");
return ZINT_ERROR_FILE_ACCESS;
}

View file

@ -13,7 +13,7 @@ set(ZINT_DEBUG FALSE CACHE BOOL "Set debug compile flag")
set(ZINT_SANITIZE FALSE CACHE BOOL "Set sanitize compile/link flags")
set(ZINT_TEST FALSE CACHE BOOL "Set test compile flag")
find_package(LibZint 2.7.1 REQUIRED)
find_package(LibZint REQUIRED)
find_package(PNG)
if(PNG_FOUND)