mirror of
https://git.code.sf.net/p/zint/code
synced 2026-06-09 15:13:35 +00:00
general: fix some typos using https://github.com/crate-ci/typos
(see gs1-syntax-engine PR #15, props Viktor Szépe)
This commit is contained in:
+1
-1
@@ -1514,7 +1514,7 @@ INTERNAL int zint_codeone(struct zint_symbol *symbol, struct zint_seg segs[], co
|
||||
c1_block_copy(symbol, datagrid, 0, 0, 10, 16, 0, 0);
|
||||
c1_block_copy(symbol, datagrid, 0, 16, 10, 16, 0, 1);
|
||||
break;
|
||||
case 3: /* Verion T-48 */
|
||||
case 3: /* Version T-48 */
|
||||
z_set_module(symbol, 0, 24);
|
||||
z_set_module(symbol, 10, 24);
|
||||
z_set_module(symbol, 12, 24);
|
||||
|
||||
@@ -264,7 +264,7 @@ INTERNAL int zint_upu_s10(struct zint_symbol *symbol, unsigned char source[], in
|
||||
|
||||
if (!z_isupper(local_source[0]) || !z_isupper(local_source[1])) {
|
||||
return z_errtxt(ZINT_ERROR_INVALID_DATA, symbol, 835,
|
||||
"Invalid character in Service Indictor (first 2 characters) (alphabetic only)");
|
||||
"Invalid character in Service Indicator (first 2 characters) (alphabetic only)");
|
||||
}
|
||||
if (z_not_sane(NEON_F, local_source + 2, 12 - 4) || (have_check_digit && !z_isdigit(have_check_digit))) {
|
||||
return z_errtxtf(ZINT_ERROR_INVALID_DATA, symbol, 836,
|
||||
|
||||
+1
-1
@@ -387,7 +387,7 @@ INTERNAL int z_errtxtf(const int error_number, struct zint_symbol *symbol, const
|
||||
if (arg == -1) {
|
||||
if (!(symbol->debug & ZINT_DEBUG_TEST)) assert(0);
|
||||
return z_errtxt(ZINT_ERROR_ENCODING_PROBLEM, symbol, 0,
|
||||
"Internal error: invalid numbered format specifer");
|
||||
"Internal error: invalid numbered format specifier");
|
||||
}
|
||||
if (i >= 9) {
|
||||
if (!(symbol->debug & ZINT_DEBUG_TEST)) assert(0);
|
||||
|
||||
+1
-1
@@ -141,7 +141,7 @@ static int dc_score_array(const char Dots[], const int Hgt, const int Wid) {
|
||||
int x, y, worstedge, first, last, sum;
|
||||
int penalty;
|
||||
|
||||
/* First, guard against "pathelogical" gaps in the array
|
||||
/* First, guard against "pathological" gaps in the array
|
||||
subtract a penalty score for empty rows/columns from total code score for each mask,
|
||||
where the penalty is Sum(N ^ n), where N is the number of positions in a column/row,
|
||||
and n is the number of consecutive empty rows/columns */
|
||||
|
||||
+2
-2
@@ -480,7 +480,7 @@ INTERNAL int zint_emf_plot(struct zint_symbol *symbol, int rotate_angle) {
|
||||
while (circ) {
|
||||
/* Note using circle width the proper way, with a non-null pen of specified width and a null brush for fill,
|
||||
causes various different rendering issues for LibreOffice Draw and Inkscape, so using following hack */
|
||||
if (previous_diameter != circ->diameter + circ->width) { /* Drawing MaxiCode bullseye using overlayed discs */
|
||||
if (previous_diameter != circ->diameter + circ->width) { /* Drawing MaxiCode bullseye using overlaid discs */
|
||||
previous_diameter = circ->diameter + circ->width;
|
||||
radius = emf_mul3dpf(0.5f, previous_diameter);
|
||||
}
|
||||
@@ -494,7 +494,7 @@ INTERNAL int zint_emf_plot(struct zint_symbol *symbol, int rotate_angle) {
|
||||
bytecount += 24;
|
||||
recordcount++;
|
||||
|
||||
if (symbol->symbology == BARCODE_MAXICODE) { /* Drawing MaxiCode bullseye using overlayed discs */
|
||||
if (symbol->symbology == BARCODE_MAXICODE) { /* Drawing MaxiCode bullseye using overlaid discs */
|
||||
float inner_radius = radius - circ->width;
|
||||
zint_out_le_u32(circle[this_circle].type, 0x0000002a); /* EMR_ELLIPSE */
|
||||
zint_out_le_u32(circle[this_circle].size, 24);
|
||||
|
||||
+4
-3
@@ -1198,7 +1198,8 @@ int ZBarcode_Encode_Segs(struct zint_symbol *symbol, const struct zint_seg segs[
|
||||
if (symbol->eci) {
|
||||
/* Check that ECI is at least CSET82 (an ASCII Invariant subset) compatible */
|
||||
if (symbol->eci == 25 || (symbol->eci >= 33 && symbol->eci <= 35)) { /* UTF-16/32 BE/LE */
|
||||
return error_tag(ZINT_ERROR_INVALID_OPTION, symbol, 856, "In GS1 mode ECI must be ASCII compatible");
|
||||
return error_tag(ZINT_ERROR_INVALID_OPTION, symbol, 856,
|
||||
"In GS1 mode ECI must be ASCII compatible");
|
||||
}
|
||||
/* Note not warning here that ECI is not supported in GS1 mode, leaving it up to individual
|
||||
symbologies, as standards are inconsistent in mentioning it */
|
||||
@@ -2019,8 +2020,8 @@ float ZBarcode_Default_Xdim(int symbol_id) {
|
||||
case BARCODE_HIBC_PDF:
|
||||
case BARCODE_MICROPDF417:
|
||||
case BARCODE_HIBC_MICPDF:
|
||||
/* Fairly arbitrarily using ISO/IEC 15416:2016 Section 5.3.1 Table 1, aperature diameters 0.125 & 0.250
|
||||
(also fits in 0.25 <= X < 0.5 range for aperature 0.2 from ISO/IEC 15415:2011 Annex D Table D.1) */
|
||||
/* Fairly arbitrarily using ISO/IEC 15416:2016 Section 5.3.1 Table 1, aperture diameters 0.125 & 0.250
|
||||
(also fits in 0.25 <= X < 0.5 range for aperture 0.2 from ISO/IEC 15415:2011 Annex D Table D.1) */
|
||||
x_dim_mm = 0.33f;
|
||||
break;
|
||||
|
||||
|
||||
+1
-1
@@ -31,7 +31,7 @@
|
||||
/* SPDX-License-Identifier: BSD-3-Clause */
|
||||
|
||||
/*
|
||||
* Developed in accordance with "Royal Mail Mailmark barcode C encoding and deconding instructions"
|
||||
* Developed in accordance with "Royal Mail Mailmark barcode C encoding and decoding instructions"
|
||||
* (https://www.royalmail.com/sites/default/files/
|
||||
* Mailmark-4-state-barcode-C-encoding-and-decoding-instructions-Sept-2015.pdf)
|
||||
* and "Royal Mail Mailmark barcode L encoding and decoding"
|
||||
|
||||
+1
-1
@@ -83,7 +83,7 @@ static void wpng_flush(png_structp png_ptr) {
|
||||
(void) zint_fm_flush(fmp);
|
||||
}
|
||||
|
||||
/* Guestimate best compression strategy */
|
||||
/* Guesstimate best compression strategy */
|
||||
static int wpng_guess_compression_strategy(struct zint_symbol *symbol, const unsigned char *pixelbuf) {
|
||||
(void)pixelbuf;
|
||||
|
||||
|
||||
+2
-2
@@ -1794,7 +1794,7 @@ INTERNAL int zint_qrcode(struct zint_symbol *symbol, struct zint_seg segs[], con
|
||||
}
|
||||
}
|
||||
|
||||
/* Ensure maxium error correction capacity unless user-specified */
|
||||
/* Ensure maximum error correction capacity unless user-specified */
|
||||
if (symbol->option_1 == -1 || symbol->option_1 - 1 != ecc_level) {
|
||||
if (est_binlen <= qr_data_codewords[QR_LEVEL_H][version - 1] * 8) {
|
||||
ecc_level = QR_LEVEL_H;
|
||||
@@ -2530,7 +2530,7 @@ static void rmqr_setup_grid(unsigned char *grid, const int h_size, const int v_s
|
||||
grid[(h_size * 2) - 2] = 0x10;
|
||||
grid[(h_size * 2) - 1] = 0x11;
|
||||
|
||||
/* Add seperator */
|
||||
/* Add separator */
|
||||
for (i = 0; i < 7; i++) {
|
||||
grid[(i * h_size) + 7] = 0x20;
|
||||
}
|
||||
|
||||
@@ -420,14 +420,14 @@ static void test_input(const testCtx *const p_ctx) {
|
||||
/* 18*/ { BARCODE_CODABLOCKF, UNICODE_MODE, -1, -1, "\037\037\037ß", -1, 0, 2, 101, 1, 1, "67 62 40 5F 5F 5F 63 03 6A 67 64 0B 64 3F 0E 34 1A 6A", "CodeA US (3) / CodeB FNC4 ß fully on next line" },
|
||||
/* 19*/ { BARCODE_CODABLOCKF, UNICODE_MODE, -1, -1, "aà", -1, 0, 2, 101, 1, 1, "67 64 40 41 64 40 63 59 6A 67 64 0B 63 64 5D 1E 16 6A", "CodeB a FNC4 à fits 1st line" },
|
||||
/* 20*/ { BARCODE_CODABLOCKF, UNICODE_MODE, -1, -1, "\037à", -1, 0, 2, 101, 0, 1, "67 62 40 5F 65 62 40 26 6A 67 64 0B 63 64 1B 1E 01 6A", "CodeA US FNC4 Shift à fits 1st line; BWIPP different encodation (CodeB instead of Shift)" },
|
||||
/* 21*/ { BARCODE_CODABLOCKF, UNICODE_MODE, -1, -1, "\037àa", -1, 0, 2, 101, 0, 1, "67 62 40 5F 64 64 40 2C 6A 67 64 0B 41 63 52 4A 16 6A", "CodeA US LatchB FNC4 à fits 1st line / Code B a; BWIPP diffent encodation (as above)" },
|
||||
/* 21*/ { BARCODE_CODABLOCKF, UNICODE_MODE, -1, -1, "\037àa", -1, 0, 2, 101, 0, 1, "67 62 40 5F 64 64 40 2C 6A 67 64 0B 41 63 52 4A 16 6A", "CodeA US LatchB FNC4 à fits 1st line / Code B a; BWIPP different encodation (as above)" },
|
||||
/* 22*/ { BARCODE_CODABLOCKF, UNICODE_MODE, -1, -1, "aaà", -1, 0, 2, 101, 1, 1, "67 64 40 41 41 64 40 16 6A 67 64 0B 63 64 51 5D 1F 6A", "CodeB a a FNC4 à fits 1st line" },
|
||||
/* 23*/ { BARCODE_CODABLOCKF, UNICODE_MODE, -1, -1, "\037\037à", -1, 0, 2, 101, 1, 1, "67 62 40 5F 5F 63 64 1D 6A 67 64 0B 64 40 37 1B 55 6A", "CodeA US US / Code B FNC4 à fully on next line" },
|
||||
/* 24*/ { BARCODE_CODABLOCKF, UNICODE_MODE, -1, -1, "aaaà", -1, 0, 2, 101, 1, 1, "67 64 40 41 41 41 63 39 6A 67 64 0B 64 40 50 51 13 6A", "CodeB a (3) / Code B FNC4 à fully on next line" },
|
||||
/* 25*/ { BARCODE_CODABLOCKF, UNICODE_MODE, -1, -1, "\037\037\037à", -1, 0, 2, 101, 1, 1, "67 62 40 5F 5F 5F 63 03 6A 67 64 0B 64 40 1C 37 0F 6A", "CodeA US (3) / CodeB FNC4 à fully on next line" },
|
||||
/* 26*/ { BARCODE_CODABLOCKF, DATA_MODE, -1, -1, "\037\200", -1, 0, 2, 101, 1, 899, "67 62 40 5F 65 40 63 4E 6A 67 64 0B 63 64 5D 0A 05 6A", "CodeA US FNC4 PAD fits 1st line" },
|
||||
/* 27*/ { BARCODE_CODABLOCKF, DATA_MODE, -1, -1, "\141\200", -1, 0, 2, 101, 0, 899, "67 64 40 41 64 62 40 31 6A 67 64 0B 63 64 49 0A 08 6A", "CodeB a FNC4 Shift PAD fits 1st line; BWIPP different encodation (CodeA instead of Shift)" },
|
||||
/* 28*/ { BARCODE_CODABLOCKF, DATA_MODE, -1, -1, "\141\200\037", -1, 0, 2, 101, 0, 899, "67 64 40 41 65 65 40 44 6A 67 62 0B 5F 63 10 12 3E 6A", "CodeB a LatchA FNC4 PAD fits 1st line / CodeA US; BWIPP diffent encodation (as above)" },
|
||||
/* 28*/ { BARCODE_CODABLOCKF, DATA_MODE, -1, -1, "\141\200\037", -1, 0, 2, 101, 0, 899, "67 64 40 41 65 65 40 44 6A 67 62 0B 5F 63 10 12 3E 6A", "CodeB a LatchA FNC4 PAD fits 1st line / CodeA US; BWIPP different encodation (as above)" },
|
||||
/* 29*/ { BARCODE_CODABLOCKF, DATA_MODE, -1, -1, "\037\037\200", -1, 0, 2, 101, 1, 899, "67 62 40 5F 5F 65 40 1D 6A 67 64 0B 63 64 0F 5D 0A 6A", "CodeA US US FNC4 PAD fits 1st line" },
|
||||
/* 30*/ { BARCODE_CODABLOCKF, DATA_MODE, -1, -1, "\141\141\200", -1, 0, 2, 101, 1, 899, "67 64 40 41 41 63 64 1B 6A 67 62 0B 65 40 33 49 21 6A", "CodeB a a / CodeA FNC4 PAD fully on next line" },
|
||||
/* 31*/ { BARCODE_CODABLOCKF, DATA_MODE, -1, -1, "\037\037\037\200", -1, 0, 2, 101, 1, 899, "67 62 40 5F 5F 5F 63 03 6A 67 62 0B 65 40 4A 0F 06 6A", "CodeA US (3) / CodeA FNC4 PAD fully on next line" },
|
||||
|
||||
@@ -3277,7 +3277,7 @@ static void test_encode_segs(const testCtx *const p_ctx) {
|
||||
"0000110101011010101000"
|
||||
"0110000110100100110110"
|
||||
},
|
||||
/* 10*/ { UNICODE_MODE, 9, { 0, 0, "" }, { { TU("A"), -1, 3 }, { TU("B"), -1, 4 }, { TU("C"), -1, 5 } }, ZINT_ERROR_INVALID_OPTION, 0, 0, 1, "Multiple segments not suppoted for Version S",
|
||||
/* 10*/ { UNICODE_MODE, 9, { 0, 0, "" }, { { TU("A"), -1, 3 }, { TU("B"), -1, 4 }, { TU("C"), -1, 5 } }, ZINT_ERROR_INVALID_OPTION, 0, 0, 1, "Multiple segments not supported for Version S",
|
||||
""
|
||||
},
|
||||
};
|
||||
|
||||
@@ -1301,10 +1301,10 @@ static void test_upu_s10_input(const testCtx *const p_ctx) {
|
||||
static const struct item data[] = {
|
||||
/* 0*/ { "AB123456789ABC", ZINT_ERROR_TOO_LONG, 0, "Error 834: Input length 14 wrong (12 or 13 characters required)", "" },
|
||||
/* 1*/ { "AB1234567AB", ZINT_ERROR_TOO_LONG, 0, "Error 834: Input length 11 wrong (12 or 13 characters required)", "" },
|
||||
/* 2*/ { "1B123456789AB", ZINT_ERROR_INVALID_DATA, 0, "Error 835: Invalid character in Service Indictor (first 2 characters) (alphabetic only)", "" },
|
||||
/* 3*/ { "1B12345678AB", ZINT_ERROR_INVALID_DATA, 0, "Error 835: Invalid character in Service Indictor (first 2 characters) (alphabetic only)", "" },
|
||||
/* 4*/ { "A2123456789AB", ZINT_ERROR_INVALID_DATA, 0, "Error 835: Invalid character in Service Indictor (first 2 characters) (alphabetic only)", "" },
|
||||
/* 5*/ { "A212345678AB", ZINT_ERROR_INVALID_DATA, 0, "Error 835: Invalid character in Service Indictor (first 2 characters) (alphabetic only)", "" },
|
||||
/* 2*/ { "1B123456789AB", ZINT_ERROR_INVALID_DATA, 0, "Error 835: Invalid character in Service Indicator (first 2 characters) (alphabetic only)", "" },
|
||||
/* 3*/ { "1B12345678AB", ZINT_ERROR_INVALID_DATA, 0, "Error 835: Invalid character in Service Indicator (first 2 characters) (alphabetic only)", "" },
|
||||
/* 4*/ { "A2123456789AB", ZINT_ERROR_INVALID_DATA, 0, "Error 835: Invalid character in Service Indicator (first 2 characters) (alphabetic only)", "" },
|
||||
/* 5*/ { "A212345678AB", ZINT_ERROR_INVALID_DATA, 0, "Error 835: Invalid character in Service Indicator (first 2 characters) (alphabetic only)", "" },
|
||||
/* 6*/ { "ABX23456789AB", ZINT_ERROR_INVALID_DATA, 0, "Error 836: Invalid character in Serial Number (middle 9 characters) (digits only)", "" },
|
||||
/* 7*/ { "AB12345678XAB", ZINT_ERROR_INVALID_DATA, 0, "Error 836: Invalid character in Serial Number (middle 9 characters) (digits only)", "" },
|
||||
/* 8*/ { "ABX2345678AB", ZINT_ERROR_INVALID_DATA, 0, "Error 836: Invalid character in Serial Number (middle 8 characters) (digits only)", "" },
|
||||
|
||||
@@ -433,14 +433,14 @@ static void test_errtxtf(const testCtx *const p_ctx) {
|
||||
};
|
||||
/* s/\/\*[ 0-9]*\*\//\=printf("\/\*%3d*\/", line(".") - line("'<")): */
|
||||
static const struct item data[] = {
|
||||
/* 0*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%0$d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifer" },
|
||||
/* 1*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%1d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifer" },
|
||||
/* 2*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%10$d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifer" },
|
||||
/* 3*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%10d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifer" },
|
||||
/* 4*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%00d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifer" },
|
||||
/* 5*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%000d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifer" },
|
||||
/* 6*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%001d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifer" },
|
||||
/* 7*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%0111d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifer" },
|
||||
/* 0*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%0$d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifier" },
|
||||
/* 1*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%1d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifier" },
|
||||
/* 2*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%10$d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifier" },
|
||||
/* 3*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%10d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifier" },
|
||||
/* 4*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%00d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifier" },
|
||||
/* 5*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%000d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifier" },
|
||||
/* 6*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%001d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifier" },
|
||||
/* 7*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%0111d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid numbered format specifier" },
|
||||
/* 8*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%x", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: unknown format specifier ('%c','%d','%f','%g','%s' only)" },
|
||||
/* 9*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%1$10d", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: unknown format specifier ('%c','%d','%f','%g','%s' only)" },
|
||||
/* 10*/ { 1, ZINT_ERROR_TOO_LONG, 123, "%.0s", 0, 0, NULL, 0, ZINT_ERROR_ENCODING_PROBLEM, "000: Internal error: invalid length precision" },
|
||||
|
||||
@@ -432,7 +432,7 @@ static void test_encode(const testCtx *const p_ctx) {
|
||||
"78878361115516163138317"
|
||||
"77777777777777777777777"
|
||||
},
|
||||
/* 4*/ { UNICODE_MODE, 10, -1, -1, ULTRA_COMPRESSION, { 0, 0, "" }, "אולטרה-קוד1234", 0, 13, 19, 1, "AIMD/TSC15032-43 Figure G.3 Same except DCC correct whereas DCC in Figure G.3 is incorrent",
|
||||
/* 4*/ { UNICODE_MODE, 10, -1, -1, ULTRA_COMPRESSION, { 0, 0, "" }, "אולטרה-קוד1234", 0, 13, 19, 1, "AIMD/TSC15032-43 Figure G.3 Same except DCC correct whereas DCC in Figure G.3 is incorrect",
|
||||
"7777777777777777777"
|
||||
"7857865565566616657"
|
||||
"7737853333613351517"
|
||||
|
||||
@@ -79,7 +79,7 @@ static struct zint_vector_circle *find_circle(struct zint_symbol *symbol, float
|
||||
y = rnd3dpf(y);
|
||||
diameter = rnd3dpf(diameter);
|
||||
for (circle = symbol->vector->circles; circle != NULL; circle = circle->next) {
|
||||
/* printf("x %.9g, y %.9g, diamter %.9g\n", circle->x, circle->y, circle->diameter); */
|
||||
/* printf("x %.9g, y %.9g, diameter %.9g\n", circle->x, circle->y, circle->diameter); */
|
||||
if (rnd3dpf(circle->x) == x && rnd3dpf(circle->y) == y) {
|
||||
if (diameter) {
|
||||
if (rnd3dpf(circle->diameter) == diameter) {
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
/* Generate ECI multibyte tables from unicode.org mapping files */
|
||||
/*
|
||||
libzint - the open source barcode library
|
||||
Copyright (C) 2022-2023 Robin Stuart <rstuart114@gmail.com>
|
||||
Copyright (C) 2022-2025 Robin Stuart <rstuart114@gmail.com>
|
||||
*/
|
||||
/* SPDX-License-Identifier: BSD-3-Clause */
|
||||
/*
|
||||
@@ -357,7 +357,7 @@ foreach ($lines as $line) {
|
||||
continue;
|
||||
}
|
||||
$u = hexdec($matches[2]);
|
||||
// PUA characters (user-defined range), dealt with programatically by `u_sjis()`
|
||||
// PUA characters (user-defined range), dealt with programmatically by `u_sjis()`
|
||||
// See CJKV Information Processing by Ken Lunde, 2nd ed., Table 4-86, p.286
|
||||
// https://file.allitebooks.com/20160708/CJKV%20Information%20Processing.pdf
|
||||
if ($u >= 0xE000 && $u <= 0xE757) {
|
||||
@@ -621,7 +621,7 @@ foreach ($lines as $line) {
|
||||
if (isset($in_gbk[$u])) {
|
||||
continue;
|
||||
}
|
||||
// User-defined, dealt with programatically by `u_gb18030()`
|
||||
// User-defined, dealt with programmatically by `u_gb18030()`
|
||||
if ($u >= 0xE000 && $u <= 0xE765) {
|
||||
continue;
|
||||
}
|
||||
|
||||
+1
-1
@@ -851,7 +851,7 @@ static int ult_generate_codewords_segs(struct zint_symbol *symbol, struct zint_s
|
||||
/* ECI indicates use of character set within ISO/IEC 8859 */
|
||||
codewords[0] = 257 + (eci - 3);
|
||||
if (codewords[0] > 267) {
|
||||
/* Avoids ECI 14 for non-existant ISO/IEC 8859-12 */
|
||||
/* Avoids ECI 14 for non-existent ISO/IEC 8859-12 */
|
||||
codewords[0]--;
|
||||
}
|
||||
} else if (eci > 18 && eci <= 898) {
|
||||
|
||||
Reference in New Issue
Block a user