First stage at creating ZPL compatability mode

Partly resolves #142 and relates to discussion in #197
This commit is contained in:
Robin Stuart 2020-08-22 11:09:57 +01:00
parent 321e1c1372
commit 9f5ae4cbb2
6 changed files with 131 additions and 41 deletions

View file

@ -125,6 +125,8 @@ static void usage(void) {
" -t, --types Display table of barcode types\n"
" --vers=NUMBER Set symbol version (size, check digits, other options)\n"
" -w, --whitesp=NUMBER Set width of whitespace in multiples of X-dimension\n"
" --werror Convert all warnings into errors\n"
" --wzpl ZPL compatibility mode (allows non-standard symbols)\n"
, ZINT_VERSION_MAJOR, ZINT_VERSION_MINOR, ZINT_VERSION_RELEASE);
}
@ -885,6 +887,12 @@ int main(int argc, char **argv) {
if (!strcmp(long_options[option_index].name, "nobackground")) {
strcpy(my_symbol->bgcolour, "ffffff00");
}
if (!strcmp(long_options[option_index].name, "werror")) {
my_symbol->warn_level = WARN_FAIL_ALL;
}
if (!strcmp(long_options[option_index].name, "wzpl")) {
my_symbol->warn_level = WARN_ZPL_COMPAT;
}
break;
case 'h':