asciidoctor-pdf 1.5.0.beta.8 → 1.5.0.rc.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.adoc +49 -0
- data/LICENSE.adoc +1 -1
- data/NOTICE.adoc +1 -1
- data/README.adoc +43 -47
- data/asciidoctor-pdf.gemspec +5 -1
- data/bin/asciidoctor-pdf-optimize +1 -1
- data/data/themes/base-theme.yml +4 -3
- data/data/themes/default-theme.yml +10 -5
- data/docs/theming-guide.adoc +286 -22
- data/lib/asciidoctor-pdf.rb +1 -0
- data/lib/asciidoctor-pdf/converter.rb +1 -0
- data/lib/asciidoctor-pdf/version.rb +1 -0
- data/lib/asciidoctor/pdf.rb +13 -2
- data/lib/asciidoctor/pdf/converter.rb +3962 -3955
- data/lib/asciidoctor/pdf/ext.rb +9 -0
- data/lib/asciidoctor/pdf/ext/asciidoctor.rb +1 -0
- data/lib/asciidoctor/pdf/ext/asciidoctor/abstract_block.rb +1 -0
- data/lib/asciidoctor/pdf/ext/asciidoctor/abstract_node.rb +1 -0
- data/lib/asciidoctor/pdf/ext/asciidoctor/document.rb +1 -0
- data/lib/asciidoctor/pdf/ext/asciidoctor/image.rb +18 -16
- data/lib/asciidoctor/pdf/ext/asciidoctor/list.rb +3 -2
- data/lib/asciidoctor/pdf/ext/asciidoctor/list_item.rb +2 -1
- data/lib/asciidoctor/pdf/ext/asciidoctor/logging_shim.rb +3 -4
- data/lib/asciidoctor/pdf/ext/asciidoctor/section.rb +8 -6
- data/lib/asciidoctor/pdf/ext/core.rb +2 -0
- data/lib/asciidoctor/pdf/ext/core/array.rb +1 -0
- data/lib/asciidoctor/pdf/ext/core/hash.rb +1 -0
- data/lib/asciidoctor/pdf/ext/core/numeric.rb +4 -3
- data/lib/asciidoctor/pdf/ext/core/object.rb +1 -0
- data/lib/asciidoctor/pdf/ext/core/quantifiable_stdout.rb +8 -1
- data/lib/asciidoctor/pdf/ext/core/regexp.rb +1 -0
- data/lib/asciidoctor/pdf/ext/core/string.rb +6 -7
- data/lib/asciidoctor/pdf/ext/pdf-core.rb +1 -0
- data/lib/asciidoctor/pdf/ext/pdf-core/page.rb +3 -4
- data/lib/asciidoctor/pdf/ext/pdf-core/pdf_object.rb +2 -1
- data/lib/asciidoctor/pdf/ext/prawn-svg.rb +1 -0
- data/lib/asciidoctor/pdf/ext/prawn-svg/interface.rb +11 -8
- data/lib/asciidoctor/pdf/ext/prawn-table.rb +2 -1
- data/lib/asciidoctor/pdf/ext/prawn-table/cell.rb +9 -10
- data/lib/asciidoctor/pdf/ext/prawn-table/cell/asciidoc.rb +62 -57
- data/lib/asciidoctor/pdf/ext/prawn-table/cell/text.rb +5 -3
- data/lib/asciidoctor/pdf/ext/prawn-templates.rb +1 -0
- data/lib/asciidoctor/pdf/ext/prawn.rb +1 -0
- data/lib/asciidoctor/pdf/ext/prawn/coderay_encoder.rb +73 -72
- data/lib/asciidoctor/pdf/ext/prawn/extensions.rb +814 -818
- data/lib/asciidoctor/pdf/ext/prawn/font/afm.rb +4 -3
- data/lib/asciidoctor/pdf/ext/prawn/formatted_text/box.rb +2 -1
- data/lib/asciidoctor/pdf/ext/prawn/formatted_text/fragment.rb +7 -2
- data/lib/asciidoctor/pdf/ext/prawn/images.rb +45 -44
- data/lib/asciidoctor/pdf/ext/pygments.rb +34 -0
- data/lib/asciidoctor/pdf/ext/rouge.rb +1 -1
- data/lib/asciidoctor/pdf/ext/rouge/formatters/prawn.rb +181 -149
- data/lib/asciidoctor/pdf/ext/rouge/themes/asciidoctor_pdf_default.rb +1 -0
- data/lib/asciidoctor/pdf/formatted_text.rb +2 -0
- data/lib/asciidoctor/pdf/formatted_text/formatter.rb +35 -34
- data/lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb +8 -7
- data/lib/asciidoctor/pdf/formatted_text/inline_destination_marker.rb +13 -14
- data/lib/asciidoctor/pdf/formatted_text/inline_image_arranger.rb +112 -133
- data/lib/asciidoctor/pdf/formatted_text/inline_image_renderer.rb +43 -41
- data/lib/asciidoctor/pdf/formatted_text/inline_text_aligner.rb +15 -14
- data/lib/asciidoctor/pdf/formatted_text/source_wrap.rb +43 -0
- data/lib/asciidoctor/pdf/formatted_text/text_background_and_border_renderer.rb +46 -37
- data/lib/asciidoctor/pdf/formatted_text/transform.rb +371 -352
- data/lib/asciidoctor/pdf/index_catalog.rb +99 -95
- data/lib/asciidoctor/pdf/measurements.rb +51 -48
- data/lib/asciidoctor/pdf/optimizer.rb +34 -31
- data/lib/asciidoctor/pdf/pdfmark.rb +34 -33
- data/lib/asciidoctor/pdf/roman_numeral.rb +80 -79
- data/lib/asciidoctor/pdf/sanitizer.rb +38 -37
- data/lib/asciidoctor/pdf/temporary_path.rb +10 -9
- data/lib/asciidoctor/pdf/text_transformer.rb +101 -100
- data/lib/asciidoctor/pdf/theme_loader.rb +258 -256
- data/lib/asciidoctor/pdf/version.rb +5 -4
- metadata +55 -6
- data/lib/asciidoctor/pdf/ext/rouge/themes/bw.rb +0 -39
- data/lib/asciidoctor/pdf/ext/ttfunk.rb +0 -9
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: asciidoctor-pdf
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.0.
|
4
|
+
version: 1.5.0.rc.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dan Allen
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2020-01-06 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: asciidoctor
|
@@ -45,6 +45,26 @@ dependencies:
|
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: 2.2.0
|
48
|
+
- !ruby/object:Gem::Dependency
|
49
|
+
name: ttfunk
|
50
|
+
requirement: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: 1.5.0
|
55
|
+
- - ">="
|
56
|
+
- !ruby/object:Gem::Version
|
57
|
+
version: 1.5.1
|
58
|
+
type: :runtime
|
59
|
+
prerelease: false
|
60
|
+
version_requirements: !ruby/object:Gem::Requirement
|
61
|
+
requirements:
|
62
|
+
- - "~>"
|
63
|
+
- !ruby/object:Gem::Version
|
64
|
+
version: 1.5.0
|
65
|
+
- - ">="
|
66
|
+
- !ruby/object:Gem::Version
|
67
|
+
version: 1.5.1
|
48
68
|
- !ruby/object:Gem::Dependency
|
49
69
|
name: prawn-table
|
50
70
|
requirement: !ruby/object:Gem::Requirement
|
@@ -233,14 +253,42 @@ dependencies:
|
|
233
253
|
requirements:
|
234
254
|
- - "~>"
|
235
255
|
- !ruby/object:Gem::Version
|
236
|
-
version: 3.
|
256
|
+
version: 3.14.0
|
257
|
+
type: :development
|
258
|
+
prerelease: false
|
259
|
+
version_requirements: !ruby/object:Gem::Requirement
|
260
|
+
requirements:
|
261
|
+
- - "~>"
|
262
|
+
- !ruby/object:Gem::Version
|
263
|
+
version: 3.14.0
|
264
|
+
- !ruby/object:Gem::Dependency
|
265
|
+
name: rubocop
|
266
|
+
requirement: !ruby/object:Gem::Requirement
|
267
|
+
requirements:
|
268
|
+
- - "~>"
|
269
|
+
- !ruby/object:Gem::Version
|
270
|
+
version: 0.78.0
|
271
|
+
type: :development
|
272
|
+
prerelease: false
|
273
|
+
version_requirements: !ruby/object:Gem::Requirement
|
274
|
+
requirements:
|
275
|
+
- - "~>"
|
276
|
+
- !ruby/object:Gem::Version
|
277
|
+
version: 0.78.0
|
278
|
+
- !ruby/object:Gem::Dependency
|
279
|
+
name: rubocop-rspec
|
280
|
+
requirement: !ruby/object:Gem::Requirement
|
281
|
+
requirements:
|
282
|
+
- - "~>"
|
283
|
+
- !ruby/object:Gem::Version
|
284
|
+
version: 1.37.0
|
237
285
|
type: :development
|
238
286
|
prerelease: false
|
239
287
|
version_requirements: !ruby/object:Gem::Requirement
|
240
288
|
requirements:
|
241
289
|
- - "~>"
|
242
290
|
- !ruby/object:Gem::Version
|
243
|
-
version:
|
291
|
+
version: 1.37.0
|
244
292
|
- !ruby/object:Gem::Dependency
|
245
293
|
name: coderay
|
246
294
|
requirement: !ruby/object:Gem::Requirement
|
@@ -313,6 +361,7 @@ files:
|
|
313
361
|
- lib/asciidoctor-pdf/version.rb
|
314
362
|
- lib/asciidoctor/pdf.rb
|
315
363
|
- lib/asciidoctor/pdf/converter.rb
|
364
|
+
- lib/asciidoctor/pdf/ext.rb
|
316
365
|
- lib/asciidoctor/pdf/ext/asciidoctor.rb
|
317
366
|
- lib/asciidoctor/pdf/ext/asciidoctor/abstract_block.rb
|
318
367
|
- lib/asciidoctor/pdf/ext/asciidoctor/abstract_node.rb
|
@@ -347,11 +396,10 @@ files:
|
|
347
396
|
- lib/asciidoctor/pdf/ext/prawn/formatted_text/box.rb
|
348
397
|
- lib/asciidoctor/pdf/ext/prawn/formatted_text/fragment.rb
|
349
398
|
- lib/asciidoctor/pdf/ext/prawn/images.rb
|
399
|
+
- lib/asciidoctor/pdf/ext/pygments.rb
|
350
400
|
- lib/asciidoctor/pdf/ext/rouge.rb
|
351
401
|
- lib/asciidoctor/pdf/ext/rouge/formatters/prawn.rb
|
352
402
|
- lib/asciidoctor/pdf/ext/rouge/themes/asciidoctor_pdf_default.rb
|
353
|
-
- lib/asciidoctor/pdf/ext/rouge/themes/bw.rb
|
354
|
-
- lib/asciidoctor/pdf/ext/ttfunk.rb
|
355
403
|
- lib/asciidoctor/pdf/formatted_text.rb
|
356
404
|
- lib/asciidoctor/pdf/formatted_text/formatter.rb
|
357
405
|
- lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb
|
@@ -361,6 +409,7 @@ files:
|
|
361
409
|
- lib/asciidoctor/pdf/formatted_text/inline_text_aligner.rb
|
362
410
|
- lib/asciidoctor/pdf/formatted_text/parser.rb
|
363
411
|
- lib/asciidoctor/pdf/formatted_text/parser.treetop
|
412
|
+
- lib/asciidoctor/pdf/formatted_text/source_wrap.rb
|
364
413
|
- lib/asciidoctor/pdf/formatted_text/text_background_and_border_renderer.rb
|
365
414
|
- lib/asciidoctor/pdf/formatted_text/transform.rb
|
366
415
|
- lib/asciidoctor/pdf/index_catalog.rb
|
@@ -1,39 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
module Rouge
|
3
|
-
module Themes
|
4
|
-
# A port of the bw style from Pygments.
|
5
|
-
# See https://bitbucket.org/birkenfeld/pygments-main/src/default/pygments/styles/bw.py
|
6
|
-
class BlackWhiteTheme < CSSTheme
|
7
|
-
name 'bw'
|
8
|
-
|
9
|
-
style Text, fg: '#000000', bg: '#ffffff'
|
10
|
-
|
11
|
-
style Comment, italic: true
|
12
|
-
style Comment::Preproc, italic: false
|
13
|
-
|
14
|
-
style Keyword, bold: true
|
15
|
-
style Keyword::Pseudo, bold: false
|
16
|
-
style Keyword::Type, bold: false
|
17
|
-
|
18
|
-
style Operator, bold: true
|
19
|
-
|
20
|
-
style Name::Class, bold: true
|
21
|
-
style Name::Namespace, bold: true
|
22
|
-
style Name::Exception, bold: true
|
23
|
-
style Name::Entity, bold: true
|
24
|
-
style Name::Tag, bold: true
|
25
|
-
|
26
|
-
style Literal::String, italic: true
|
27
|
-
style Literal::String::Interpol, bold: true
|
28
|
-
style Literal::String::Escape, bold: true
|
29
|
-
|
30
|
-
style Generic::Heading, bold: true
|
31
|
-
style Generic::Subheading, bold: true
|
32
|
-
style Generic::Emph, italic: true
|
33
|
-
style Generic::Strong, bold: true
|
34
|
-
style Generic::Prompt, bold: true
|
35
|
-
|
36
|
-
style Error, fg: '#FF0000'
|
37
|
-
end
|
38
|
-
end
|
39
|
-
end
|