mirror of
https://git.code.sf.net/p/zint/code
synced 2025-12-22 12:27:03 +00:00
general: raw_segs -> content_segs, BARCODE_RAW_TEXT ->
`BARCODE_CONTENT_SEGS`, `z_rt_XXX()` -> `z_ct_XXX()`; move `encoded_data`/`row_height` to end of `zint_symbol` (see ZXing-C++ issue #883) manual: update re `content_segs`; `my_symbol` -> `symbol`; improve MicroPDF417 description
This commit is contained in:
@@ -808,7 +808,7 @@ static int ult_generate_codewords_segs(struct zint_symbol *symbol, struct zint_s
|
||||
const int gs1 = (symbol->input_mode & 0x07) == GS1_MODE;
|
||||
/* Raw text dealt with by `ZBarcode_Encode_Segs()`, except for `eci` feedback.
|
||||
Note not updating `eci` for GS1 mode as not converted */
|
||||
const int raw_text = !gs1 && (symbol->output_options & BARCODE_RAW_TEXT);
|
||||
const int content_segs = !gs1 && (symbol->output_options & BARCODE_CONTENT_SEGS);
|
||||
|
||||
for (i = 0; i < seg_count; i++) {
|
||||
if (segs[i].eci) {
|
||||
@@ -910,15 +910,15 @@ static int ult_generate_codewords_segs(struct zint_symbol *symbol, struct zint_s
|
||||
current_mode = symbol_mode;
|
||||
codeword_count = ult_generate_codewords(symbol, source, length, 0 /*eci*/, gs1, symbol_mode, ¤t_mode,
|
||||
codewords, codeword_count);
|
||||
if (raw_text && segs[0].eci) {
|
||||
z_rt_set_seg_eci(symbol, 0, segs[0].eci);
|
||||
if (content_segs && segs[0].eci) {
|
||||
z_ct_set_seg_eci(symbol, 0, segs[0].eci);
|
||||
}
|
||||
|
||||
for (i = 1; i < seg_count; i++) {
|
||||
codeword_count = ult_generate_codewords(symbol, segs[i].source, segs[i].length, segs[i].eci, gs1, symbol_mode,
|
||||
¤t_mode, codewords, codeword_count);
|
||||
if (raw_text && segs[i].eci) {
|
||||
z_rt_set_seg_eci(symbol, i, segs[i].eci);
|
||||
if (content_segs && segs[i].eci) {
|
||||
z_ct_set_seg_eci(symbol, i, segs[i].eci);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user