thinreports 0.10.2 → 0.10.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/.travis.yml +22 -6
- data/CHANGELOG.md +6 -0
- data/Gemfile +1 -1
- data/README.md +5 -6
- data/Rakefile +11 -25
- data/lib/thinreports/generator/pdf/document/draw_shape.rb +1 -1
- data/lib/thinreports/generator/pdf/document/draw_template_items.rb +1 -1
- data/lib/thinreports/layout/legacy_schema.rb +1 -0
- data/lib/thinreports/version.rb +1 -1
- data/test/features/dynamic_style/expect.pdf +3714 -0
- data/{examples → test/features}/dynamic_style/image.png +0 -0
- data/{examples/dynamic_style/dynamic_style.tlf → test/features/dynamic_style/templates/styles.tlf} +0 -0
- data/{examples/dynamic_style/dynamic_style_in_list.tlf → test/features/dynamic_style/templates/styles_in_list.tlf} +0 -0
- data/test/features/dynamic_style/test_dynamic_style.rb +152 -0
- data/{examples → test/features}/eudc/eudc.ttf +0 -0
- data/test/features/eudc/expect.pdf +0 -0
- data/{examples/eudc/eudc.tlf → test/features/eudc/template.tlf} +0 -0
- data/test/features/eudc/test_eudc.rb +27 -0
- data/test/features/feature_test.rb +58 -0
- data/test/features/graphics/expect.pdf +475 -0
- data/test/features/graphics/template.tlf +309 -0
- data/test/features/graphics/test_graphics.rb +12 -0
- data/test/features/hidden_item/expect.pdf +0 -0
- data/{examples/hidden_shapes/hidden_shapes.tlf → test/features/hidden_item/template.tlf} +0 -0
- data/test/features/hidden_item/test_hidden_item.rb +12 -0
- data/test/features/image_block/expect.pdf +0 -0
- data/{examples/dynamic_image → test/features/image_block}/img200x100.png +0 -0
- data/{examples/dynamic_image → test/features/image_block}/img50x50.png +0 -0
- data/{examples/dynamic_image/dynamic_image.tlf → test/features/image_block/template.tlf} +0 -0
- data/test/features/image_block/test_image_block.rb +35 -0
- data/test/features/list_events/expect.pdf +659 -0
- data/{examples/list_events/list_events.tlf → test/features/list_events/template.tlf} +0 -0
- data/{examples/list_events/list_events.rb → test/features/list_events/test_list_events.rb} +7 -3
- data/test/features/list_manually/expect.pdf +599 -0
- data/{examples/list_manual_generation/list_manual_generation.tlf → test/features/list_manually/template.tlf} +0 -0
- data/test/features/list_manually/test_list_manually.rb +25 -0
- data/test/features/page_number/expect.pdf +400 -0
- data/{examples/page_number/page_number.tlf → test/features/page_number/template.tlf} +0 -0
- data/test/features/page_number/test_page_number.rb +24 -0
- data/test/features/page_number_with_list/expect.pdf +721 -0
- data/{examples/list_page_number/list_page_number.tlf → test/features/page_number_with_list/template.tlf} +0 -0
- data/test/features/page_number_with_list/test_page_number_with_list.rb +21 -0
- data/test/features/palleted_png/expect.pdf +0 -0
- data/{examples → test/features}/palleted_png/palleted_png.png +0 -0
- data/{examples/palleted_png/palleted_png.tlf → test/features/palleted_png/template.tlf} +0 -0
- data/test/features/palleted_png/test_palleted_png.rb +14 -0
- data/test/features/report_callbacks/expect.pdf +169 -0
- data/{examples/report_callbacks/report_callbacks.tlf → test/features/report_callbacks/template.tlf} +0 -0
- data/test/features/report_callbacks/test_report_callbacks.rb +18 -0
- data/test/features/text_align/expect.pdf +0 -0
- data/{examples/text_align/text_align.tlf → test/features/text_align/template.tlf} +0 -0
- data/test/features/text_align/test_text_align.rb +12 -0
- data/test/features/text_block_overflow/expect.pdf +0 -0
- data/{examples/tblock_overflow/tblock_overflow.tlf → test/features/text_block_overflow/template.tlf} +0 -0
- data/test/features/text_block_overflow/test_text_block_overflow.rb +25 -0
- data/test/features/text_block_singleline/expect.pdf +0 -0
- data/{examples/single_line_tblock/single_line_tblock.tlf → test/features/text_block_singleline/template.tlf} +0 -0
- data/test/features/text_block_singleline/test_text_block_singleline.rb +15 -0
- data/test/features/text_block_style/expect.pdf +1390 -1
- data/{examples/tblock_styles/tblock_styles.tlf → test/features/text_block_style/templates/basic_styles.tlf} +0 -0
- data/{examples/tblock_styles → test/features/text_block_style/templates}/font_size.tlf +0 -0
- data/{examples/tblock_styles/tblock_styles.rb → test/features/text_block_style/test_text_block_style.rb} +9 -5
- data/test/features/text_character_spacing/expect.pdf +0 -0
- data/{examples/character_spacing/character_spacing.tlf → test/features/text_character_spacing/template.tlf} +0 -0
- data/test/features/text_character_spacing/test_text_character_spacing.rb +12 -0
- data/test/features/text_word_wrap/expect.pdf +0 -0
- data/{examples/word_wrap/word_wrap.tlf → test/features/text_word_wrap/template.tlf} +0 -0
- data/test/features/text_word_wrap/test_text_word_wrap.rb +30 -0
- data/test/test_helper.rb +1 -10
- data/test/{unit → units}/core/format/test_base.rb +0 -0
- data/test/{unit → units}/core/shape/base/test_internal.rb +0 -0
- data/test/{unit → units}/core/shape/basic/test_block_format.rb +0 -0
- data/test/{unit → units}/core/shape/basic/test_block_interface.rb +0 -0
- data/test/{unit → units}/core/shape/basic/test_block_internal.rb +0 -0
- data/test/{unit → units}/core/shape/basic/test_format.rb +0 -0
- data/test/{unit → units}/core/shape/basic/test_interface.rb +0 -0
- data/test/{unit → units}/core/shape/basic/test_internal.rb +0 -0
- data/test/{unit → units}/core/shape/image_block/test_interface.rb +0 -0
- data/test/{unit → units}/core/shape/image_block/test_internal.rb +0 -0
- data/test/{unit → units}/core/shape/list/test_format.rb +0 -0
- data/test/{unit → units}/core/shape/list/test_manager.rb +0 -0
- data/test/{unit → units}/core/shape/list/test_page.rb +0 -0
- data/test/{unit → units}/core/shape/list/test_page_state.rb +0 -0
- data/test/{unit → units}/core/shape/list/test_section_format.rb +0 -0
- data/test/{unit → units}/core/shape/list/test_section_interface.rb +0 -0
- data/test/{unit → units}/core/shape/list/test_section_internal.rb +0 -0
- data/test/{unit → units}/core/shape/manager/test_format.rb +0 -0
- data/test/{unit → units}/core/shape/manager/test_internal.rb +0 -0
- data/test/{unit → units}/core/shape/manager/test_target.rb +0 -0
- data/test/{unit → units}/core/shape/page_number/test_format.rb +0 -0
- data/test/{unit → units}/core/shape/page_number/test_interface.rb +0 -0
- data/test/{unit → units}/core/shape/page_number/test_internal.rb +0 -0
- data/test/{unit → units}/core/shape/styles/test_base.rb +0 -0
- data/test/{unit → units}/core/shape/styles/test_basic.rb +0 -0
- data/test/{unit → units}/core/shape/styles/test_graphic.rb +0 -0
- data/test/{unit → units}/core/shape/styles/test_text.rb +0 -0
- data/test/{unit → units}/core/shape/text/test_format.rb +0 -0
- data/test/{unit → units}/core/shape/text/test_internal.rb +0 -0
- data/test/{unit → units}/core/shape/text_block/formatter/test_basic.rb +0 -0
- data/test/{unit → units}/core/shape/text_block/formatter/test_datetime.rb +0 -0
- data/test/{unit → units}/core/shape/text_block/formatter/test_number.rb +0 -0
- data/test/{unit → units}/core/shape/text_block/formatter/test_padding.rb +0 -0
- data/test/{unit → units}/core/shape/text_block/test_format.rb +0 -0
- data/test/{unit → units}/core/shape/text_block/test_formatter.rb +0 -0
- data/test/{unit → units}/core/shape/text_block/test_interface.rb +0 -0
- data/test/{unit → units}/core/shape/text_block/test_internal.rb +0 -0
- data/test/{unit → units}/core/test_shape.rb +0 -0
- data/test/{unit → units}/core/test_utils.rb +0 -0
- data/test/{unit → units}/generator/pdf/document/graphics/test_attributes.rb +0 -0
- data/test/{unit → units}/generator/pdf/document/graphics/test_basic.rb +0 -0
- data/test/{unit → units}/generator/pdf/document/graphics/test_image.rb +0 -0
- data/test/{unit → units}/generator/pdf/document/graphics/test_text.rb +0 -0
- data/test/{unit → units}/generator/pdf/document/test_font.rb +0 -0
- data/test/{unit → units}/generator/pdf/document/test_graphics.rb +0 -0
- data/test/{unit → units}/generator/pdf/document/test_page.rb +0 -0
- data/test/{unit → units}/generator/pdf/document/test_parse_color.rb +0 -0
- data/test/{unit → units}/generator/pdf/prawn_ext/test_calc_image_dimensions.rb +0 -0
- data/test/{unit → units}/generator/pdf/prawn_ext/test_width_of.rb +0 -0
- data/test/{unit → units}/generator/pdf/test_document.rb +0 -0
- data/test/{unit → units}/generator/test_pdf.rb +0 -0
- data/test/{unit → units}/layout/test_base.rb +0 -0
- data/test/{unit → units}/layout/test_format.rb +0 -0
- data/test/{unit → units}/layout/test_legacy_schema.rb +3 -1
- data/test/{unit → units}/layout/test_version.rb +0 -0
- data/test/{unit → units}/report/test_base.rb +0 -0
- data/test/{unit → units}/report/test_internal.rb +0 -0
- data/test/{unit → units}/test_config.rb +0 -0
- data/test/{unit → units}/test_layout.rb +0 -0
- data/test/{unit → units}/test_report.rb +0 -0
- data/thinreports.gemspec +0 -1
- metadata +122 -123
- data/examples/character_spacing/character_spacing.rb +0 -8
- data/examples/dynamic_image/dynamic_image.rb +0 -31
- data/examples/dynamic_style/dynamic_style.rb +0 -150
- data/examples/eudc/eudc.rb +0 -20
- data/examples/helper.rb +0 -50
- data/examples/hidden_shapes/hidden_shapes.rb +0 -9
- data/examples/list_manual_generation/list_manual_generation.rb +0 -22
- data/examples/list_page_number/list_page_number.rb +0 -17
- data/examples/page_number/page_number.rb +0 -33
- data/examples/palleted_png/palleted_png.rb +0 -9
- data/examples/password_setting/password_setting.rb +0 -10
- data/examples/password_setting/password_setting.tlf +0 -45
- data/examples/report_callbacks/report_callbacks.rb +0 -14
- data/examples/single_line_tblock/single_line_tblock.rb +0 -13
- data/examples/tblock_overflow/tblock_overflow.rb +0 -20
- data/examples/text_align/text_align.rb +0 -8
- data/examples/typeB_page_size/B4_ISO.tlf +0 -45
- data/examples/typeB_page_size/B4_JIS.tlf +0 -45
- data/examples/typeB_page_size/typeB_page_size.rb +0 -17
- data/examples/word_wrap/word_wrap.rb +0 -26
- data/test/tmp/.gitkeep +0 -0
File without changes
|
@@ -0,0 +1,25 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'feature_test'
|
4
|
+
|
5
|
+
class TestListManually < FeatureTest
|
6
|
+
feature :list_manually do
|
7
|
+
report = Thinreports::Report.new layout: template_path
|
8
|
+
report.list.header do |h|
|
9
|
+
h.item(:header).value(report.page.no)
|
10
|
+
end
|
11
|
+
|
12
|
+
25.times do |row_index|
|
13
|
+
if report.list.overflow?
|
14
|
+
report.start_new_page
|
15
|
+
report.list.header header: report.page.no
|
16
|
+
end
|
17
|
+
|
18
|
+
report.list.page_break if row_index == 15
|
19
|
+
|
20
|
+
report.list.add_row detail: row_index
|
21
|
+
end
|
22
|
+
|
23
|
+
assert_pdf report.generate
|
24
|
+
end
|
25
|
+
end
|
@@ -0,0 +1,400 @@
|
|
1
|
+
%PDF-1.3
|
2
|
+
%����
|
3
|
+
1 0 obj
|
4
|
+
<< /CreationDate (D:20181106102142+09'00')
|
5
|
+
/Creator <feff005400680069006e007200650070006f007200740073002000470065006e0065007200610074006f007200200066006f00720020005200750062007900200030002e00310030002e0032>
|
6
|
+
/Title <feff>
|
7
|
+
/Producer <feff0050007200610077006e>
|
8
|
+
>>
|
9
|
+
endobj
|
10
|
+
2 0 obj
|
11
|
+
<< /Type /Catalog
|
12
|
+
/Pages 3 0 R
|
13
|
+
>>
|
14
|
+
endobj
|
15
|
+
3 0 obj
|
16
|
+
<< /Type /Pages
|
17
|
+
/Count 4
|
18
|
+
/Kids [7 0 R 11 0 R 14 0 R 16 0 R]
|
19
|
+
>>
|
20
|
+
endobj
|
21
|
+
4 0 obj
|
22
|
+
<< /Length 8
|
23
|
+
>>
|
24
|
+
stream
|
25
|
+
q
|
26
|
+
0.9 w
|
27
|
+
|
28
|
+
endstream
|
29
|
+
endobj
|
30
|
+
5 0 obj
|
31
|
+
<< /Type /Page
|
32
|
+
/Parent 3 0 R
|
33
|
+
/MediaBox [0 0 612.0 792.0]
|
34
|
+
/CropBox [0 0 612.0 792.0]
|
35
|
+
/BleedBox [0 0 612.0 792.0]
|
36
|
+
/TrimBox [0 0 612.0 792.0]
|
37
|
+
/ArtBox [0 0 612.0 792.0]
|
38
|
+
/Contents 4 0 R
|
39
|
+
/Resources << /ProcSet [/PDF /Text /ImageB /ImageC /ImageI]
|
40
|
+
>>
|
41
|
+
>>
|
42
|
+
endobj
|
43
|
+
6 0 obj
|
44
|
+
<< /Length 284
|
45
|
+
>>
|
46
|
+
stream
|
47
|
+
q
|
48
|
+
0.9 w
|
49
|
+
/Stamp1 Do
|
50
|
+
q
|
51
|
+
/DeviceRGB cs
|
52
|
+
0.0 0.0 0.0 scn
|
53
|
+
|
54
|
+
BT
|
55
|
+
110.046 715.966 Td
|
56
|
+
/F1.0 18 Tf
|
57
|
+
[<31>] TJ
|
58
|
+
ET
|
59
|
+
|
60
|
+
Q
|
61
|
+
q
|
62
|
+
/DeviceRGB cs
|
63
|
+
0.0 0.0 0.0 scn
|
64
|
+
|
65
|
+
10.0 Tc
|
66
|
+
|
67
|
+
BT
|
68
|
+
50.0 744.966 Td
|
69
|
+
/F1.0 18 Tf
|
70
|
+
[<31>] TJ
|
71
|
+
ET
|
72
|
+
|
73
|
+
|
74
|
+
0.0 Tc
|
75
|
+
Q
|
76
|
+
q
|
77
|
+
/DeviceRGB cs
|
78
|
+
0.0 0.0 0.0 scn
|
79
|
+
|
80
|
+
BT
|
81
|
+
170.092 688.966 Td
|
82
|
+
/F1.0 18 Tf
|
83
|
+
[<31>] TJ
|
84
|
+
ET
|
85
|
+
|
86
|
+
Q
|
87
|
+
Q
|
88
|
+
|
89
|
+
endstream
|
90
|
+
endobj
|
91
|
+
7 0 obj
|
92
|
+
<< /Type /Page
|
93
|
+
/Parent 3 0 R
|
94
|
+
/MediaBox [0 0 595.28 841.89]
|
95
|
+
/CropBox [0 0 595.28 841.89]
|
96
|
+
/BleedBox [0 0 595.28 841.89]
|
97
|
+
/TrimBox [0 0 595.28 841.89]
|
98
|
+
/ArtBox [0 0 595.28 841.89]
|
99
|
+
/Contents 6 0 R
|
100
|
+
/Resources << /ProcSet [/PDF /Text /ImageB /ImageC /ImageI]
|
101
|
+
/XObject << /Stamp1 8 0 R
|
102
|
+
>>
|
103
|
+
/Font << /F1.0 9 0 R
|
104
|
+
>>
|
105
|
+
>>
|
106
|
+
>>
|
107
|
+
endobj
|
108
|
+
8 0 obj
|
109
|
+
<< /Type /XObject
|
110
|
+
/Subtype /Form
|
111
|
+
/BBox [0 0 595.28 841.89]
|
112
|
+
/Resources << /Font << /F1.0 9 0 R
|
113
|
+
>>
|
114
|
+
>>
|
115
|
+
/Length 493
|
116
|
+
>>
|
117
|
+
stream
|
118
|
+
q
|
119
|
+
/DeviceRGB cs
|
120
|
+
0.0 0.0 0.0 scn
|
121
|
+
/DeviceRGB CS
|
122
|
+
0.0 0.0 0.0 SCN
|
123
|
+
0.9 w
|
124
|
+
0 J
|
125
|
+
0 j
|
126
|
+
[] 0 d
|
127
|
+
q
|
128
|
+
/DeviceRGB cs
|
129
|
+
0.0 0.0 0.0 scn
|
130
|
+
|
131
|
+
BT
|
132
|
+
20.0 782.966 Td
|
133
|
+
/F1.0 18 Tf
|
134
|
+
[<4261736973>] TJ
|
135
|
+
ET
|
136
|
+
|
137
|
+
Q
|
138
|
+
q
|
139
|
+
/DeviceRGB cs
|
140
|
+
0.0 0.0 0.0 scn
|
141
|
+
|
142
|
+
BT
|
143
|
+
195.0 717.838 Td
|
144
|
+
/F1.0 14 Tf
|
145
|
+
[<2843656e746572a0416c69676e6d656e7429>] TJ
|
146
|
+
ET
|
147
|
+
|
148
|
+
Q
|
149
|
+
q
|
150
|
+
/DeviceRGB cs
|
151
|
+
0.0 0.0 0.0 scn
|
152
|
+
|
153
|
+
BT
|
154
|
+
195.0 688.838 Td
|
155
|
+
/F1.0 14 Tf
|
156
|
+
[<285269676874a0416c69676e6d656e7429>] TJ
|
157
|
+
ET
|
158
|
+
|
159
|
+
Q
|
160
|
+
q
|
161
|
+
/DeviceRGB cs
|
162
|
+
0.0 0.0 0.0 scn
|
163
|
+
|
164
|
+
BT
|
165
|
+
20.0 648.966 Td
|
166
|
+
/F1.0 18 Tf
|
167
|
+
[<57697468a04944>] TJ
|
168
|
+
ET
|
169
|
+
|
170
|
+
Q
|
171
|
+
Q
|
172
|
+
|
173
|
+
endstream
|
174
|
+
endobj
|
175
|
+
9 0 obj
|
176
|
+
<< /Type /Font
|
177
|
+
/Subtype /Type1
|
178
|
+
/BaseFont /Helvetica
|
179
|
+
/Encoding /WinAnsiEncoding
|
180
|
+
>>
|
181
|
+
endobj
|
182
|
+
10 0 obj
|
183
|
+
<< /Length 453
|
184
|
+
>>
|
185
|
+
stream
|
186
|
+
q
|
187
|
+
0.9 w
|
188
|
+
/Stamp1 Do
|
189
|
+
q
|
190
|
+
/DeviceRGB cs
|
191
|
+
1.0 0.0 0.0 scn
|
192
|
+
|
193
|
+
BT
|
194
|
+
102.036 623.966 Td
|
195
|
+
/F2.0 18 Tf
|
196
|
+
[<32a02fa033>] TJ
|
197
|
+
ET
|
198
|
+
|
199
|
+
102.036 622.716 m
|
200
|
+
137.064 622.716 l
|
201
|
+
S
|
202
|
+
102.036 627.8432 m
|
203
|
+
137.064 627.8432 l
|
204
|
+
S
|
205
|
+
Q
|
206
|
+
q
|
207
|
+
/DeviceRGB cs
|
208
|
+
0.0 0.0 0.0 scn
|
209
|
+
|
210
|
+
BT
|
211
|
+
110.046 715.966 Td
|
212
|
+
/F1.0 18 Tf
|
213
|
+
[<32>] TJ
|
214
|
+
ET
|
215
|
+
|
216
|
+
Q
|
217
|
+
q
|
218
|
+
/DeviceRGB cs
|
219
|
+
0.0 0.0 0.0 scn
|
220
|
+
|
221
|
+
10.0 Tc
|
222
|
+
|
223
|
+
BT
|
224
|
+
50.0 744.966 Td
|
225
|
+
/F1.0 18 Tf
|
226
|
+
[<32>] TJ
|
227
|
+
ET
|
228
|
+
|
229
|
+
|
230
|
+
0.0 Tc
|
231
|
+
Q
|
232
|
+
q
|
233
|
+
/DeviceRGB cs
|
234
|
+
0.0 0.0 0.0 scn
|
235
|
+
|
236
|
+
BT
|
237
|
+
170.092 688.966 Td
|
238
|
+
/F1.0 18 Tf
|
239
|
+
[<32>] TJ
|
240
|
+
ET
|
241
|
+
|
242
|
+
Q
|
243
|
+
Q
|
244
|
+
|
245
|
+
endstream
|
246
|
+
endobj
|
247
|
+
11 0 obj
|
248
|
+
<< /Type /Page
|
249
|
+
/Parent 3 0 R
|
250
|
+
/MediaBox [0 0 595.28 841.89]
|
251
|
+
/CropBox [0 0 595.28 841.89]
|
252
|
+
/BleedBox [0 0 595.28 841.89]
|
253
|
+
/TrimBox [0 0 595.28 841.89]
|
254
|
+
/ArtBox [0 0 595.28 841.89]
|
255
|
+
/Contents 10 0 R
|
256
|
+
/Resources << /ProcSet [/PDF /Text /ImageB /ImageC /ImageI]
|
257
|
+
/XObject << /Stamp1 8 0 R
|
258
|
+
>>
|
259
|
+
/Font << /F2.0 12 0 R
|
260
|
+
/F1.0 9 0 R
|
261
|
+
>>
|
262
|
+
>>
|
263
|
+
>>
|
264
|
+
endobj
|
265
|
+
12 0 obj
|
266
|
+
<< /Type /Font
|
267
|
+
/Subtype /Type1
|
268
|
+
/BaseFont /Helvetica-Bold
|
269
|
+
/Encoding /WinAnsiEncoding
|
270
|
+
>>
|
271
|
+
endobj
|
272
|
+
13 0 obj
|
273
|
+
<< /Length 21
|
274
|
+
>>
|
275
|
+
stream
|
276
|
+
q
|
277
|
+
0.9 w
|
278
|
+
/Stamp1 Do
|
279
|
+
Q
|
280
|
+
|
281
|
+
endstream
|
282
|
+
endobj
|
283
|
+
14 0 obj
|
284
|
+
<< /Type /Page
|
285
|
+
/Parent 3 0 R
|
286
|
+
/MediaBox [0 0 595.28 841.89]
|
287
|
+
/CropBox [0 0 595.28 841.89]
|
288
|
+
/BleedBox [0 0 595.28 841.89]
|
289
|
+
/TrimBox [0 0 595.28 841.89]
|
290
|
+
/ArtBox [0 0 595.28 841.89]
|
291
|
+
/Contents 13 0 R
|
292
|
+
/Resources << /ProcSet [/PDF /Text /ImageB /ImageC /ImageI]
|
293
|
+
/XObject << /Stamp1 8 0 R
|
294
|
+
>>
|
295
|
+
>>
|
296
|
+
>>
|
297
|
+
endobj
|
298
|
+
15 0 obj
|
299
|
+
<< /Length 375
|
300
|
+
>>
|
301
|
+
stream
|
302
|
+
q
|
303
|
+
0.9 w
|
304
|
+
/Stamp1 Do
|
305
|
+
q
|
306
|
+
/DeviceRGB cs
|
307
|
+
0.0 0.0 0.0 scn
|
308
|
+
|
309
|
+
BT
|
310
|
+
102.036 623.966 Td
|
311
|
+
/F1.0 18 Tf
|
312
|
+
[<33a02fa033>] TJ
|
313
|
+
ET
|
314
|
+
|
315
|
+
Q
|
316
|
+
q
|
317
|
+
/DeviceRGB cs
|
318
|
+
0.0 0.0 0.0 scn
|
319
|
+
|
320
|
+
BT
|
321
|
+
110.046 715.966 Td
|
322
|
+
/F1.0 18 Tf
|
323
|
+
[<33>] TJ
|
324
|
+
ET
|
325
|
+
|
326
|
+
Q
|
327
|
+
q
|
328
|
+
/DeviceRGB cs
|
329
|
+
0.0 0.0 0.0 scn
|
330
|
+
|
331
|
+
10.0 Tc
|
332
|
+
|
333
|
+
BT
|
334
|
+
50.0 744.966 Td
|
335
|
+
/F1.0 18 Tf
|
336
|
+
[<33>] TJ
|
337
|
+
ET
|
338
|
+
|
339
|
+
|
340
|
+
0.0 Tc
|
341
|
+
Q
|
342
|
+
q
|
343
|
+
/DeviceRGB cs
|
344
|
+
0.0 0.0 0.0 scn
|
345
|
+
|
346
|
+
BT
|
347
|
+
170.092 688.966 Td
|
348
|
+
/F1.0 18 Tf
|
349
|
+
[<33>] TJ
|
350
|
+
ET
|
351
|
+
|
352
|
+
Q
|
353
|
+
Q
|
354
|
+
|
355
|
+
endstream
|
356
|
+
endobj
|
357
|
+
16 0 obj
|
358
|
+
<< /Type /Page
|
359
|
+
/Parent 3 0 R
|
360
|
+
/MediaBox [0 0 595.28 841.89]
|
361
|
+
/CropBox [0 0 595.28 841.89]
|
362
|
+
/BleedBox [0 0 595.28 841.89]
|
363
|
+
/TrimBox [0 0 595.28 841.89]
|
364
|
+
/ArtBox [0 0 595.28 841.89]
|
365
|
+
/Contents 15 0 R
|
366
|
+
/Resources << /ProcSet [/PDF /Text /ImageB /ImageC /ImageI]
|
367
|
+
/XObject << /Stamp1 8 0 R
|
368
|
+
>>
|
369
|
+
/Font << /F1.0 9 0 R
|
370
|
+
>>
|
371
|
+
>>
|
372
|
+
>>
|
373
|
+
endobj
|
374
|
+
xref
|
375
|
+
0 17
|
376
|
+
0000000000 65535 f
|
377
|
+
0000000015 00000 n
|
378
|
+
0000000291 00000 n
|
379
|
+
0000000340 00000 n
|
380
|
+
0000000418 00000 n
|
381
|
+
0000000475 00000 n
|
382
|
+
0000000737 00000 n
|
383
|
+
0000001072 00000 n
|
384
|
+
0000001397 00000 n
|
385
|
+
0000002038 00000 n
|
386
|
+
0000002135 00000 n
|
387
|
+
0000002640 00000 n
|
388
|
+
0000002980 00000 n
|
389
|
+
0000003083 00000 n
|
390
|
+
0000003155 00000 n
|
391
|
+
0000003458 00000 n
|
392
|
+
0000003885 00000 n
|
393
|
+
trailer
|
394
|
+
<< /Size 17
|
395
|
+
/Root 2 0 R
|
396
|
+
/Info 1 0 R
|
397
|
+
>>
|
398
|
+
startxref
|
399
|
+
4212
|
400
|
+
%%EOF
|
File without changes
|
@@ -0,0 +1,24 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'feature_test'
|
4
|
+
|
5
|
+
class TestPageNumber < FeatureTest
|
6
|
+
feature :page_number do
|
7
|
+
report = Thinreports::Report.new layout: template_path
|
8
|
+
|
9
|
+
report.start_new_page do |page|
|
10
|
+
page.item(:pageno).hide
|
11
|
+
end
|
12
|
+
report.start_new_page do |page|
|
13
|
+
page.item(:pageno).styles(color: 'red',
|
14
|
+
bold: true,
|
15
|
+
underline: true,
|
16
|
+
linethrough: true)
|
17
|
+
end
|
18
|
+
|
19
|
+
report.start_new_page count: false
|
20
|
+
report.start_new_page count: true
|
21
|
+
|
22
|
+
assert_pdf report.generate
|
23
|
+
end
|
24
|
+
end
|