ruby-zint 1.1.0 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/ext/ruby-zint/extconf.rb +2 -2
- data/lib/zint/aus_post.rb +1 -0
- data/lib/zint/aus_redirect.rb +1 -0
- data/lib/zint/aus_reply.rb +1 -0
- data/lib/zint/aus_route.rb +1 -0
- data/lib/zint/azrune.rb +1 -0
- data/lib/zint/aztec.rb +1 -0
- data/lib/zint/barcode.rb +85 -39
- data/lib/zint/{bind.rb → bc_412.rb} +3 -2
- data/lib/zint/c25iata.rb +1 -0
- data/lib/zint/c25ind.rb +1 -0
- data/lib/zint/c25inter.rb +1 -0
- data/lib/zint/c25logic.rb +1 -0
- data/lib/zint/c25matrix.rb +1 -0
- data/lib/zint/c25standard.rb +1 -0
- data/lib/zint/{dotty_mode.rb → cep_net.rb} +3 -2
- data/lib/zint/channel.rb +1 -0
- data/lib/zint/codabar.rb +1 -0
- data/lib/zint/codablock_f.rb +1 -0
- data/lib/zint/code11.rb +1 -0
- data/lib/zint/code128.rb +1 -0
- data/lib/zint/{noascii.rb → code128ab.rb} +3 -2
- data/lib/zint/code128b.rb +2 -4
- data/lib/zint/code16k.rb +1 -0
- data/lib/zint/code32.rb +1 -0
- data/lib/zint/code39.rb +1 -0
- data/lib/zint/code49.rb +1 -0
- data/lib/zint/code93.rb +1 -0
- data/lib/zint/code_one.rb +1 -0
- data/lib/zint/constants/capability_flags.rb +14 -11
- data/lib/zint/constants/input_data_types.rb +8 -7
- data/lib/zint/constants/output_options.rb +14 -11
- data/lib/zint/constants/symbologies.rb +13 -6
- data/lib/zint/constants/warn_levels.rb +1 -1
- data/lib/zint/daft.rb +1 -0
- data/lib/zint/data_matrix.rb +1 -0
- data/lib/zint/dbarexp.rb +1 -0
- data/lib/zint/dbarexpstk.rb +1 -0
- data/lib/zint/dbarltd.rb +1 -0
- data/lib/zint/dbaromn.rb +1 -0
- data/lib/zint/dbaromnstk.rb +1 -0
- data/lib/zint/dbarstk.rb +1 -0
- data/lib/zint/dependencies.rb +2 -2
- data/lib/zint/dot_code.rb +1 -0
- data/lib/zint/dpd.rb +1 -0
- data/lib/zint/dpident.rb +1 -0
- data/lib/zint/dpleit.rb +1 -0
- data/lib/zint/ean128.rb +1 -0
- data/lib/zint/ean14.rb +1 -0
- data/lib/zint/eanx.rb +1 -0
- data/lib/zint/eanxchk.rb +1 -0
- data/lib/zint/excode39.rb +1 -0
- data/lib/zint/fim.rb +1 -0
- data/lib/zint/flat.rb +1 -0
- data/lib/zint/grid_matrix.rb +1 -0
- data/lib/zint/gs1_128.rb +1 -0
- data/lib/zint/hanxin.rb +1 -0
- data/lib/zint/hibc128.rb +1 -0
- data/lib/zint/hibc39.rb +1 -0
- data/lib/zint/hibcaztec.rb +1 -0
- data/lib/zint/hibcblockf.rb +1 -0
- data/lib/zint/hibcdm.rb +1 -0
- data/lib/zint/hibcmicpdf.rb +1 -0
- data/lib/zint/hibcpdf.rb +1 -0
- data/lib/zint/hibcqr.rb +1 -0
- data/lib/zint/isbnx.rb +1 -0
- data/lib/zint/itf14.rb +1 -0
- data/lib/zint/japan_post.rb +1 -0
- data/lib/zint/kix.rb +1 -0
- data/lib/zint/korea_post.rb +1 -0
- data/lib/zint/logmars.rb +1 -0
- data/lib/zint/mailmark.rb +1 -0
- data/lib/zint/mailmark_2d.rb +8 -0
- data/lib/zint/mailmark_4s.rb +8 -0
- data/lib/zint/maxi_code.rb +1 -0
- data/lib/zint/micro_pdf417.rb +1 -0
- data/lib/zint/micro_qr.rb +1 -0
- data/lib/zint/msiplessey.rb +1 -0
- data/lib/zint/native.rb +1 -1
- data/lib/zint/nve18.rb +1 -0
- data/lib/zint/one_code.rb +1 -0
- data/lib/zint/pdf417.rb +1 -0
- data/lib/zint/pdf417comp.rb +1 -0
- data/lib/zint/pdf417trunc.rb +1 -0
- data/lib/zint/pharma.rb +1 -0
- data/lib/zint/pharmatwo.rb +1 -0
- data/lib/zint/planet.rb +1 -0
- data/lib/zint/plessey.rb +1 -0
- data/lib/zint/postnet.rb +1 -0
- data/lib/zint/pzn.rb +1 -0
- data/lib/zint/qr.rb +1 -0
- data/lib/zint/rmqr.rb +1 -0
- data/lib/zint/rss14.rb +1 -0
- data/lib/zint/rss14stack.rb +1 -0
- data/lib/zint/rss14stackomni.rb +1 -0
- data/lib/zint/rssexp.rb +1 -0
- data/lib/zint/rssexpstack.rb +1 -0
- data/lib/zint/rssltd.rb +1 -0
- data/lib/zint/structs/structapp.rb +25 -0
- data/lib/zint/structs/symbol.rb +38 -35
- data/lib/zint/structs/vector_circle.rb +3 -2
- data/lib/zint/telepen.rb +1 -0
- data/lib/zint/telepennum.rb +1 -0
- data/lib/zint/ultra.rb +1 -0
- data/lib/zint/upc_a.rb +1 -0
- data/lib/zint/upc_a_chk.rb +1 -0
- data/lib/zint/upc_e.rb +1 -0
- data/lib/zint/upc_e_chk.rb +1 -0
- data/lib/zint/upnqr.rb +1 -0
- data/lib/zint/{box.rb → upu_s10.rb} +3 -2
- data/lib/zint/uspsimail.rb +1 -0
- data/lib/zint/version.rb +1 -1
- data/lib/zint/vin.rb +1 -0
- data/lib/zint.rb +8 -1
- data/ports/archives/zint-2.12.0-src.tar.gz +0 -0
- metadata +9 -7
- data/lib/zint/stdout.rb +0 -7
- data/ports/archives/zint-2.10.0-src.tar.gz +0 -0
data/lib/zint/structs/symbol.rb
CHANGED
@@ -1,41 +1,44 @@
|
|
1
1
|
module Zint
|
2
2
|
module Structs
|
3
3
|
class Symbol < FFI::ManagedStruct
|
4
|
-
layout :symbology, :int,
|
5
|
-
:height, :float,
|
6
|
-
:
|
7
|
-
:
|
8
|
-
:
|
9
|
-
:
|
10
|
-
:
|
11
|
-
:
|
12
|
-
:
|
13
|
-
:
|
14
|
-
:
|
15
|
-
:
|
16
|
-
:
|
17
|
-
:
|
18
|
-
:
|
19
|
-
:
|
20
|
-
:
|
21
|
-
:
|
22
|
-
:
|
23
|
-
:
|
24
|
-
:
|
25
|
-
:
|
26
|
-
:
|
27
|
-
:
|
28
|
-
:
|
29
|
-
:
|
30
|
-
:
|
31
|
-
:
|
32
|
-
:
|
33
|
-
:
|
34
|
-
:
|
35
|
-
:
|
36
|
-
:
|
37
|
-
:
|
38
|
-
:
|
4
|
+
layout :symbology, :int, # Symbol to use (see BARCODE_XXX below)
|
5
|
+
:height, :float, # Barcode height in X-dimensions (ignored for fixed-width barcodes)
|
6
|
+
:scale, :float, # Scale factor when printing barcode, i.e. adjusts X-dimension. Default 1
|
7
|
+
:whitespace_width, :int, # Width in X-dimensions of whitespace to left & right of barcode
|
8
|
+
:whitespace_height, :int, # Height in X-dimensions of whitespace above & below the barcode
|
9
|
+
:border_width, :int, # Size of border in X-dimensions
|
10
|
+
:output_options, :int, # Various output parameters (bind, box etc, see below)
|
11
|
+
:fgcolour, [:char, 10], # Foreground as RGB/RGBA hexadecimal string, 6 or 8 characters, NUL-terminated
|
12
|
+
:bgcolour, [:char, 10], # Background as RGB/RGBA hexadecimal string, 6 or 8 characters, NUL-terminated
|
13
|
+
:fgcolor, :pointer, # Pointer to fgcolour (alternate spelling)
|
14
|
+
:bgcolor, :pointer, # Pointer to bgcolour (alternate spelling)
|
15
|
+
:outfile, [:char, 256], # Name of file to output to, NUL-terminated. Default "out.png" ("out.gif" if NO_PNG)
|
16
|
+
:primary, [:char, 128], # Primary message data (MaxiCode, Composite), NUL-terminated
|
17
|
+
:option_1, :int, # Symbol-specific options (see "../docs/manual.txt")
|
18
|
+
:option_2, :int, # Symbol-specific options
|
19
|
+
:option_3, :int, # Symbol-specific options
|
20
|
+
:show_hrt, :int, # Show (1) or hide (0) Human Readable Text (HRT). Default 1
|
21
|
+
:fontsize, :int, # Unused
|
22
|
+
:input_mode, :int, # Encoding of input data (see DATA_MODE etc below). Default DATA_MODE
|
23
|
+
:eci, :int, # Extended Channel Interpretation. Default 0 (none)
|
24
|
+
:dpmm, :float, # Resolution of output in dots per mm (BMP/EMF/PCX/PNG/TIF only). Default 0 (none)
|
25
|
+
:dot_size, :float, # Size of dots used in BARCODE_DOTTY_MODE. Default 0.8
|
26
|
+
:guard_descent, :float, # Height in X-dimensions that EAN/UPC guard bars descend. Default 5
|
27
|
+
:structapp, Structapp, # Structured Append info. Default structapp.count 0 (none)
|
28
|
+
:warn_level, :int, # Affects error/warning value returned by Zint API (see WARN_XXX below)
|
29
|
+
:debug, :int, # Debugging flags
|
30
|
+
:text, [:uchar, 128], # Human Readable Text (if any), UTF-8, NUL-terminated (output only)
|
31
|
+
:rows, :int, # Number of rows used by the symbol (output only)
|
32
|
+
:width, :int, # Width of the generated symbol (output only)
|
33
|
+
:encoded_data, [:uchar, 200 * 144], # Encoded data (output only). Allows for rows of 1152 modules
|
34
|
+
:row_height, [:float, 200], # Heights of rows (output only). Allows for 200 row DotCode
|
35
|
+
:errtxt, [:char, 100], # Error message if an error or warning occurs, NUL-terminated (output only)
|
36
|
+
:bitmap, :pointer, # Stored bitmap image (raster output only)
|
37
|
+
:bitmap_width, :int, # Width of bitmap image (raster output only)
|
38
|
+
:bitmap_height, :int, # Height of bitmap image (raster output only)
|
39
|
+
:alphamap, :pointer, # Array of alpha values used (raster output only)
|
40
|
+
:bitmap_byte_length, :uchar, # Size of BMP bitmap data (raster output only)
|
41
|
+
:vector, Vector.by_ref # Pointer to vector header (vector output only)
|
39
42
|
|
40
43
|
# @private
|
41
44
|
def self.release(ptr)
|
@@ -3,8 +3,9 @@ module Zint
|
|
3
3
|
class VectorCircle < FFI::Struct
|
4
4
|
layout :x, :float,
|
5
5
|
:y, :float,
|
6
|
-
:diameter, :float,
|
7
|
-
:
|
6
|
+
:diameter, :float, # Circle diameter. Does not include width (if any)
|
7
|
+
:width, :float, # Width of circle perimeter (circumference). 0 for fill (disc)
|
8
|
+
:colour, :int, # Non-zero for draw with background colour (else draw with foreground colour)
|
8
9
|
:next, VectorCircle.by_ref # Pointer to next circle
|
9
10
|
|
10
11
|
# x position
|
data/lib/zint/telepen.rb
CHANGED
data/lib/zint/telepennum.rb
CHANGED
data/lib/zint/ultra.rb
CHANGED
data/lib/zint/upc_a.rb
CHANGED
data/lib/zint/upc_a_chk.rb
CHANGED
data/lib/zint/upc_e.rb
CHANGED
data/lib/zint/upc_e_chk.rb
CHANGED
data/lib/zint/upnqr.rb
CHANGED
@@ -1,7 +1,8 @@
|
|
1
1
|
module Zint
|
2
|
-
|
2
|
+
# Universal Postal Union S10
|
3
|
+
class UpuS10 < Barcode
|
3
4
|
def initialize(value: nil, input_file: nil, options: {})
|
4
|
-
super(value: value, input_file: input_file, type: Zint::
|
5
|
+
super(value: value, input_file: input_file, type: Zint::BARCODE_UPU_S10, options: options)
|
5
6
|
end
|
6
7
|
end
|
7
8
|
end
|
data/lib/zint/uspsimail.rb
CHANGED
data/lib/zint/version.rb
CHANGED
data/lib/zint/vin.rb
CHANGED
data/lib/zint.rb
CHANGED
@@ -20,6 +20,7 @@ require "zint/structs/vector_hexagon"
|
|
20
20
|
require "zint/structs/vector_rect"
|
21
21
|
require "zint/structs/vector_string"
|
22
22
|
require "zint/structs/vector"
|
23
|
+
require "zint/structs/structapp"
|
23
24
|
require "zint/structs/symbol"
|
24
25
|
require "zint/native"
|
25
26
|
|
@@ -36,6 +37,7 @@ module Zint
|
|
36
37
|
include Constants::Warnings
|
37
38
|
|
38
39
|
# Barcode
|
40
|
+
autoload :Bc412, "zint/bc_412"
|
39
41
|
autoload :Bitmap, "zint/bitmap"
|
40
42
|
autoload :BitmapPixel, "zint/bitmap_pixel"
|
41
43
|
autoload :Barcode, "zint/barcode"
|
@@ -53,12 +55,14 @@ module Zint
|
|
53
55
|
autoload :C25logic, "zint/c25logic"
|
54
56
|
autoload :C25matrix, "zint/c25matrix"
|
55
57
|
autoload :C25standard, "zint/c25standard"
|
58
|
+
autoload :CepNet, "zint/cep_net"
|
56
59
|
autoload :Channel, "zint/channel"
|
57
60
|
autoload :Codabar, "zint/codabar"
|
58
61
|
autoload :CodablockF, "zint/codablock_f"
|
59
62
|
autoload :Code11, "zint/code11"
|
60
63
|
autoload :Code128, "zint/code128"
|
61
|
-
autoload :
|
64
|
+
autoload :Code128AB, "zint/code128ab"
|
65
|
+
autoload :Code128B, "zint/code128b"
|
62
66
|
autoload :Code16k, "zint/code16k"
|
63
67
|
autoload :Code32, "zint/code32"
|
64
68
|
autoload :Code39, "zint/code39"
|
@@ -103,6 +107,8 @@ module Zint
|
|
103
107
|
autoload :KoreaPost, "zint/korea_post"
|
104
108
|
autoload :Logmars, "zint/logmars"
|
105
109
|
autoload :Mailmark, "zint/mailmark"
|
110
|
+
autoload :Mailmark2D, "zint/mailmark_2d"
|
111
|
+
autoload :Mailmark4S, "zint/mailmark_4s"
|
106
112
|
autoload :MaxiCode, "zint/maxi_code"
|
107
113
|
autoload :MicroPdf417, "zint/micro_pdf417"
|
108
114
|
autoload :MicroQr, "zint/micro_qr"
|
@@ -136,6 +142,7 @@ module Zint
|
|
136
142
|
autoload :UpcE, "zint/upc_e"
|
137
143
|
autoload :UpcEChk, "zint/upc_e_chk"
|
138
144
|
autoload :Upnqr, "zint/upnqr"
|
145
|
+
autoload :UpuS10, "zint/upu_s10"
|
139
146
|
autoload :UspsImail, "zint/uspsimail"
|
140
147
|
autoload :Vin, "zint/vin"
|
141
148
|
|
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ruby-zint
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Elias Fröhner
|
@@ -62,21 +62,22 @@ files:
|
|
62
62
|
- lib/zint/azrune.rb
|
63
63
|
- lib/zint/aztec.rb
|
64
64
|
- lib/zint/barcode.rb
|
65
|
-
- lib/zint/
|
65
|
+
- lib/zint/bc_412.rb
|
66
66
|
- lib/zint/bitmap.rb
|
67
67
|
- lib/zint/bitmap_pixel.rb
|
68
|
-
- lib/zint/box.rb
|
69
68
|
- lib/zint/c25iata.rb
|
70
69
|
- lib/zint/c25ind.rb
|
71
70
|
- lib/zint/c25inter.rb
|
72
71
|
- lib/zint/c25logic.rb
|
73
72
|
- lib/zint/c25matrix.rb
|
74
73
|
- lib/zint/c25standard.rb
|
74
|
+
- lib/zint/cep_net.rb
|
75
75
|
- lib/zint/channel.rb
|
76
76
|
- lib/zint/codabar.rb
|
77
77
|
- lib/zint/codablock_f.rb
|
78
78
|
- lib/zint/code11.rb
|
79
79
|
- lib/zint/code128.rb
|
80
|
+
- lib/zint/code128ab.rb
|
80
81
|
- lib/zint/code128b.rb
|
81
82
|
- lib/zint/code16k.rb
|
82
83
|
- lib/zint/code32.rb
|
@@ -103,7 +104,6 @@ files:
|
|
103
104
|
- lib/zint/dbarstk.rb
|
104
105
|
- lib/zint/dependencies.rb
|
105
106
|
- lib/zint/dot_code.rb
|
106
|
-
- lib/zint/dotty_mode.rb
|
107
107
|
- lib/zint/dpd.rb
|
108
108
|
- lib/zint/dpident.rb
|
109
109
|
- lib/zint/dpleit.rb
|
@@ -132,12 +132,13 @@ files:
|
|
132
132
|
- lib/zint/korea_post.rb
|
133
133
|
- lib/zint/logmars.rb
|
134
134
|
- lib/zint/mailmark.rb
|
135
|
+
- lib/zint/mailmark_2d.rb
|
136
|
+
- lib/zint/mailmark_4s.rb
|
135
137
|
- lib/zint/maxi_code.rb
|
136
138
|
- lib/zint/micro_pdf417.rb
|
137
139
|
- lib/zint/micro_qr.rb
|
138
140
|
- lib/zint/msiplessey.rb
|
139
141
|
- lib/zint/native.rb
|
140
|
-
- lib/zint/noascii.rb
|
141
142
|
- lib/zint/nve18.rb
|
142
143
|
- lib/zint/one_code.rb
|
143
144
|
- lib/zint/pdf417.rb
|
@@ -157,7 +158,7 @@ files:
|
|
157
158
|
- lib/zint/rssexp.rb
|
158
159
|
- lib/zint/rssexpstack.rb
|
159
160
|
- lib/zint/rssltd.rb
|
160
|
-
- lib/zint/
|
161
|
+
- lib/zint/structs/structapp.rb
|
161
162
|
- lib/zint/structs/symbol.rb
|
162
163
|
- lib/zint/structs/vector.rb
|
163
164
|
- lib/zint/structs/vector_circle.rb
|
@@ -172,11 +173,12 @@ files:
|
|
172
173
|
- lib/zint/upc_e.rb
|
173
174
|
- lib/zint/upc_e_chk.rb
|
174
175
|
- lib/zint/upnqr.rb
|
176
|
+
- lib/zint/upu_s10.rb
|
175
177
|
- lib/zint/uspsimail.rb
|
176
178
|
- lib/zint/version.rb
|
177
179
|
- lib/zint/vin.rb
|
178
180
|
- lib/zint/zint_recipe.rb
|
179
|
-
- ports/archives/zint-2.
|
181
|
+
- ports/archives/zint-2.12.0-src.tar.gz
|
180
182
|
homepage: https://github.com/api-walker/ruby-zint
|
181
183
|
licenses:
|
182
184
|
- MIT
|
data/lib/zint/stdout.rb
DELETED
Binary file
|