mirror of
https://git.code.sf.net/p/zint/code
synced 2025-12-18 02:17:06 +00:00
CODE128: optimize for extended ASCII as well using techniques from
BWIPP minimal encoding by Bue Jensen (BWIPP PR #278); new extra escape `\^@` to turn off manual switching zint.h: increase `symbol->text` size 200 -> 256 (means that for the moment can no longer generate ZINT_WARN_HRT_TRUNCATED) GS1_128/GS1_128_CC: warn if READER_INIT option used CODE16K: move `c16k_set_a/b/c()` routines from "code128.c" and rename `c16k_` (also `C128_` defines to `C16K_`) common: make `itoc()` simple macro which adds '0' (>= 10 now ':', ';' etc) and adjust `expand()` accordingly for slight speed-up general: EXTRA_ESCAPE_MODE now implies ESCAPE_MODE tests: update BWIPP to latest and enable CODE128AB ("suppressc"); new test args '-n' (exclude func) and '-m' (match func)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
Zint Barcode Generator and Zint Barcode Studio User Manual
|
||||
Version 2.13.0.9
|
||||
October 2024
|
||||
November 2024
|
||||
|
||||
*******************************************************************************
|
||||
* For reference the following is a text-only version of the Zint manual, *
|
||||
@@ -2143,7 +2143,7 @@ the nature of the error. The errors generated by Zint are:
|
||||
Return Value Meaning
|
||||
------------------------------ -----------------------------------------------
|
||||
ZINT_WARN_HRT_TRUNCATED The Human Readable Text returned in text was
|
||||
truncated (maximum 199 bytes).
|
||||
truncated (maximum 255 bytes).
|
||||
|
||||
ZINT_WARN_INVALID_OPTION One of the values in zint_struct was set
|
||||
incorrectly but Zint has made a guess at what
|
||||
@@ -3011,20 +3011,27 @@ pharmaceuticals. The symbology is able to encode whole numbers between 3 and
|
||||
One of the most ubiquitous one-dimensional barcode symbologies, Code 128 was
|
||||
developed in 1981 by Computer Identics. This symbology supports full ASCII text
|
||||
and uses a three-Code Set system to compress the data into a smaller symbol.
|
||||
Zint automatically switches between Code Sets A, B and C (but see following) and
|
||||
Zint automatically switches between Code Sets A, B and C (but see below) and
|
||||
adds a hidden modulo-103 check digit.
|
||||
|
||||
Code 128 is the default barcode symbology used by Zint. In addition Zint
|
||||
supports the encoding of ISO/IEC 8859-1 (non-English) characters in Code 128
|
||||
symbols. The ISO/IEC 8859-1 character set is shown in Annex A.2 Latin Alphabet
|
||||
No. 1 (ISO/IEC 8859-1).
|
||||
|
||||
Manual switching of Code Sets is possible using the --extraesc option (API
|
||||
input_mode |= EXTRA_ESCAPE_MODE) and the Code 128-specific escapes \^A, \^B,
|
||||
\^C. For instance the following will force switching to Code Set B for the data
|
||||
"5678" (normally Code Set C would be used throughout):
|
||||
input_mode |= EXTRA_ESCAPE_MODE), which apart from processing normal escape
|
||||
sequences also processes the Code 128-specific escapes \^A, \^B, \^C and \^@
|
||||
(the latter turns off manual Code Set selection). For instance the following
|
||||
will force switching to Code Set B for the data "5678" (normally Code Set C
|
||||
would be used throughout):
|
||||
|
||||
zint -b CODE128 -d "1234\^B5678" --extraesc
|
||||
|
||||
The manually selected Code Set will apply until the next Code Set escape
|
||||
sequence, with the exception that data that cannot be represented in that Code
|
||||
Set will be switched as appropriate. If the data contains a special code
|
||||
sequence, it can be escaped by doubling the caret (^). For instance
|
||||
sequence or until a \^@, with the exception that data that cannot be represented
|
||||
in that Code Set will be switched as appropriate. If the data contains an extra
|
||||
escape sequence, it can be escaped by doubling the caret (^). For instance
|
||||
|
||||
zint -b CODE128 -d "\^AABC\^^BDEF" --extraesc
|
||||
|
||||
@@ -3035,13 +3042,9 @@ character (FNC1) anywhere you chose in the data, for instance
|
||||
|
||||
zint -b CODE128 -d "A\^1BC\^1DEF" --extraesc
|
||||
|
||||
Code 128 is the default barcode symbology used by Zint. In addition Zint
|
||||
supports the encoding of ISO/IEC 8859-1 (non-English) characters in Code 128
|
||||
symbols. The ISO/IEC 8859-1 character set is shown in Annex A.2 Latin Alphabet
|
||||
No. 1 (ISO/IEC 8859-1).
|
||||
|
||||
Zint can encode a maximum of 99 symbol characters, which allows for e.g. 198
|
||||
all-numeric characters.
|
||||
Zint can encode a maximum of 102 symbol characters, which allows for e.g. 202
|
||||
all-numeric or 101 all-uppercase characters. Sizes above 120 digits (60
|
||||
alphanumerics) are not recommended.
|
||||
|
||||
6.1.10.2 Code 128 Suppress Code Set C (Code Sets A and B only)
|
||||
|
||||
@@ -4826,7 +4829,7 @@ configured barcode is displayed once the "Generate" button is pressed.
|
||||
|
||||
Annex D. Man Page ZINT(1)
|
||||
|
||||
% ZINT(1) Version 2.13.0.9 % % October 2024
|
||||
% ZINT(1) Version 2.13.0.9 % % November 2024
|
||||
|
||||
NAME
|
||||
|
||||
@@ -5020,10 +5023,11 @@ OPTIONS
|
||||
|
||||
--extraesc
|
||||
|
||||
For Code 128 only, process the special escape sequences \^A, \^B and \^C
|
||||
that allow manual switching of Code Sets, and the special escape sequence
|
||||
\^1 that inserts an FNC1 character. The sequence \^^ can be used to encode
|
||||
data that contains special escape sequences.
|
||||
For Code 128 only, as well as processing the normal escape sequences above,
|
||||
process the special escape sequences \^A, \^B, \^C and \^@ that allow manual
|
||||
switching of Code Sets, and the special escape sequence \^1 that inserts an
|
||||
FNC1 character. The sequence \@ turns off manual switching. The sequence \^^
|
||||
can be used to encode data that contains special escape sequences.
|
||||
|
||||
--fast
|
||||
|
||||
|
||||
Reference in New Issue
Block a user