asciidoctor-pdf 1.5.0.beta.5 → 1.5.0.beta.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (89) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.adoc +33 -2
  3. data/README.adoc +22 -19
  4. data/asciidoctor-pdf.gemspec +5 -6
  5. data/data/fonts/mplus1mn-bold-ascii.ttf +0 -0
  6. data/data/fonts/mplus1mn-bold-subset.ttf +0 -0
  7. data/data/fonts/mplus1mn-bold_italic-ascii.ttf +0 -0
  8. data/data/fonts/mplus1mn-bold_italic-subset.ttf +0 -0
  9. data/data/fonts/mplus1mn-italic-ascii.ttf +0 -0
  10. data/data/fonts/mplus1mn-italic-subset.ttf +0 -0
  11. data/data/fonts/mplus1mn-regular-ascii-conums.ttf +0 -0
  12. data/data/fonts/mplus1mn-regular-subset.ttf +0 -0
  13. data/data/fonts/mplus1p-regular-fallback.ttf +0 -0
  14. data/data/fonts/notoserif-bold-subset.ttf +0 -0
  15. data/data/fonts/notoserif-bold_italic-subset.ttf +0 -0
  16. data/data/fonts/notoserif-italic-subset.ttf +0 -0
  17. data/data/fonts/notoserif-regular-subset.ttf +0 -0
  18. data/data/themes/base-theme.yml +3 -0
  19. data/data/themes/default-theme.yml +7 -1
  20. data/docs/theming-guide.adoc +254 -24
  21. data/lib/asciidoctor-pdf.rb +1 -4
  22. data/lib/asciidoctor-pdf/converter.rb +1 -4085
  23. data/lib/asciidoctor-pdf/version.rb +1 -6
  24. data/lib/asciidoctor/pdf.rb +4 -1
  25. data/lib/asciidoctor/pdf/converter.rb +4222 -0
  26. data/lib/asciidoctor/pdf/ext/asciidoctor.rb +9 -0
  27. data/lib/{asciidoctor-pdf/asciidoctor_ext → asciidoctor/pdf/ext/asciidoctor}/abstract_block.rb +0 -0
  28. data/lib/{asciidoctor-pdf/asciidoctor_ext → asciidoctor/pdf/ext/asciidoctor}/document.rb +0 -0
  29. data/lib/{asciidoctor-pdf/asciidoctor_ext → asciidoctor/pdf/ext/asciidoctor}/image.rb +0 -0
  30. data/lib/{asciidoctor-pdf/asciidoctor_ext → asciidoctor/pdf/ext/asciidoctor}/list.rb +0 -0
  31. data/lib/{asciidoctor-pdf/asciidoctor_ext → asciidoctor/pdf/ext/asciidoctor}/list_item.rb +0 -0
  32. data/lib/{asciidoctor-pdf/asciidoctor_ext → asciidoctor/pdf/ext/asciidoctor}/logging_shim.rb +0 -0
  33. data/lib/{asciidoctor-pdf/asciidoctor_ext → asciidoctor/pdf/ext/asciidoctor}/section.rb +0 -0
  34. data/lib/asciidoctor/pdf/ext/core.rb +7 -0
  35. data/lib/{asciidoctor-pdf/core_ext → asciidoctor/pdf/ext/core}/array.rb +0 -0
  36. data/lib/{asciidoctor-pdf/core_ext → asciidoctor/pdf/ext/core}/hash.rb +0 -0
  37. data/lib/{asciidoctor-pdf/core_ext → asciidoctor/pdf/ext/core}/numeric.rb +0 -0
  38. data/lib/{asciidoctor-pdf/core_ext → asciidoctor/pdf/ext/core}/object.rb +0 -0
  39. data/lib/{asciidoctor-pdf/core_ext → asciidoctor/pdf/ext/core}/quantifiable_stdout.rb +0 -0
  40. data/lib/{asciidoctor-pdf/core_ext → asciidoctor/pdf/ext/core}/regexp.rb +0 -0
  41. data/lib/{asciidoctor-pdf/core_ext → asciidoctor/pdf/ext/core}/string.rb +0 -0
  42. data/lib/asciidoctor/pdf/ext/pdf-core.rb +3 -0
  43. data/lib/{asciidoctor-pdf/pdf-core_ext → asciidoctor/pdf/ext/pdf-core}/page.rb +0 -0
  44. data/lib/{asciidoctor-pdf/pdf-core_ext → asciidoctor/pdf/ext/pdf-core}/pdf_object.rb +0 -0
  45. data/lib/{asciidoctor-pdf/prawn-svg_ext.rb → asciidoctor/pdf/ext/prawn-svg.rb} +1 -1
  46. data/lib/{asciidoctor-pdf/prawn-svg_ext → asciidoctor/pdf/ext/prawn-svg}/interface.rb +0 -0
  47. data/lib/asciidoctor/pdf/ext/prawn-table.rb +5 -0
  48. data/lib/{asciidoctor-pdf/prawn-table_ext → asciidoctor/pdf/ext/prawn-table}/cell.rb +0 -0
  49. data/lib/{asciidoctor-pdf/prawn-table_ext → asciidoctor/pdf/ext/prawn-table}/cell/asciidoc.rb +0 -0
  50. data/lib/{asciidoctor-pdf/prawn-table_ext → asciidoctor/pdf/ext/prawn-table}/cell/text.rb +0 -0
  51. data/lib/{asciidoctor-pdf/prawn-templates_ext.rb → asciidoctor/pdf/ext/prawn-templates.rb} +0 -0
  52. data/lib/asciidoctor/pdf/ext/prawn.rb +6 -0
  53. data/lib/{asciidoctor-pdf/prawn_ext → asciidoctor/pdf/ext/prawn}/coderay_encoder.rb +0 -0
  54. data/lib/{asciidoctor-pdf/prawn_ext → asciidoctor/pdf/ext/prawn}/extensions.rb +17 -5
  55. data/lib/{asciidoctor-pdf/prawn_ext → asciidoctor/pdf/ext/prawn}/font/afm.rb +0 -0
  56. data/lib/{asciidoctor-pdf/prawn_ext → asciidoctor/pdf/ext/prawn}/formatted_text/fragment.rb +2 -10
  57. data/lib/{asciidoctor-pdf/prawn_ext → asciidoctor/pdf/ext/prawn}/images.rb +0 -0
  58. data/lib/asciidoctor/pdf/ext/rouge.rb +5 -0
  59. data/lib/{asciidoctor-pdf/rouge_ext → asciidoctor/pdf/ext/rouge}/formatters/prawn.rb +0 -0
  60. data/lib/{asciidoctor-pdf/rouge_ext → asciidoctor/pdf/ext/rouge}/themes/asciidoctor_pdf_default.rb +0 -0
  61. data/lib/{asciidoctor-pdf/rouge_ext → asciidoctor/pdf/ext/rouge}/themes/bw.rb +0 -0
  62. data/lib/{asciidoctor-pdf/ttfunk_ext.rb → asciidoctor/pdf/ext/ttfunk.rb} +0 -0
  63. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text.rb +1 -0
  64. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text/formatter.rb +8 -6
  65. data/lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb +12 -0
  66. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text/inline_destination_marker.rb +0 -0
  67. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text/inline_image_arranger.rb +1 -4
  68. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text/inline_image_renderer.rb +0 -0
  69. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text/inline_text_aligner.rb +0 -0
  70. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text/parser.rb +0 -0
  71. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text/parser.treetop +0 -0
  72. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text/text_background_and_border_renderer.rb +0 -0
  73. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/formatted_text/transform.rb +3 -4
  74. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/index_catalog.rb +0 -0
  75. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/measurements.rb +0 -0
  76. data/lib/asciidoctor/pdf/optimizer.rb +23 -0
  77. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/pdfmark.rb +8 -2
  78. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/roman_numeral.rb +0 -0
  79. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/sanitizer.rb +3 -4
  80. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/temporary_path.rb +0 -0
  81. data/lib/{asciidoctor-pdf → asciidoctor/pdf}/theme_loader.rb +1 -1
  82. data/lib/asciidoctor/pdf/version.rb +6 -1
  83. metadata +68 -65
  84. data/lib/asciidoctor-pdf/asciidoctor_ext.rb +0 -9
  85. data/lib/asciidoctor-pdf/core_ext.rb +0 -7
  86. data/lib/asciidoctor-pdf/pdf-core_ext.rb +0 -3
  87. data/lib/asciidoctor-pdf/prawn-table_ext.rb +0 -5
  88. data/lib/asciidoctor-pdf/prawn_ext.rb +0 -6
  89. data/lib/asciidoctor-pdf/rouge_ext.rb +0 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f6a1fbcfb416a485f625f2b12c4b7c30806e0d05cdf3ecc327b2ae6b0b04003e
4
- data.tar.gz: bb1f4811237d7478cd132474175e11fbc1fa9e4755a0888ba1bb633215174b16
3
+ metadata.gz: fa4efe2963835f293701e1e831c7fc5cafce4c1922362b063e8265bd133e29a1
4
+ data.tar.gz: '08ff1cbea70552786797786465cfab1c626506287dbd8e56ae0204da000c5807'
5
5
  SHA512:
6
- metadata.gz: f8ed0674cbc59c95bd5408874381d24708d3d07f3c6762297e9352727ddab3a67afae2e32bd48585feac84f57f9cfc03d8cee1388003617772a457591354793a
7
- data.tar.gz: 1d38fa4fce88891b32d15b52829244222f5a1ada6269ad6108ed38cda7ed8a202d8793a4dab1ff9eadd597c53768994e0bf844e94587752d5ce51f7801677152
6
+ metadata.gz: 16733468d925e9e30158073fd0859498c2c70fd9c8f3ede9e49ab57eda7391dbde5eda608dead1fcf01db5414a4d46f5f0e486470f45f467b263cf11fdd95ded
7
+ data.tar.gz: ed4a9a710c1bf31940265451e4bafb312c1fb4ca4d75a2ab69e89948f6e2975c1410a9335edef5e1fd0ce4bb7bb286b4612149d5d01c52014d571143f4d807f4
@@ -5,6 +5,35 @@
5
5
  This document provides a high-level view of the changes to the {project-name} by release.
6
6
  For a detailed view of what has changed, refer to the {uri-repo}/commits/master[commit history] on GitHub.
7
7
 
8
+ == 1.5.0.beta.6 (2019-10-11) - @mojavelinux
9
+
10
+ * reorganize source files under asciidoctor/pdf folder (instead of asciidoctor-pdf)
11
+ * reorganize monkeypatch files under asciidoctor/pdf/ext
12
+ * allow toc to be positioned using toc macro (#1030)
13
+ * extend dots leading up to page number from wrapped line in toc (#1152)
14
+ * set fit=contain by default on cover and page background images (#1275)
15
+ * implement fit=fill for cover, page background, and running content raster (non-SVG) images (#1276)
16
+ * allow foreground image (e.g., watermark) to be added to each page using page-foreground-image attribute or theme key (#727)
17
+ * allow section body to be indented using section_indent key in theme (#737)
18
+ * add glyphs for built-in characters to bundled monospace font (M+ 1mn) (#1274)
19
+ * look for "noborder" role on image even if other roles are defined
20
+ * remove deprecated table_odd_row_background_color and table_even_row_background_color keys from theme
21
+ * implement unordered and ordered description lists (#1280)
22
+ * recognize transparent as valid value for cellbgcolor attribute
23
+ * allow custom role to revert font style to normal (#1286)
24
+ * allow theme to control font properties (font size, font color, etc) of description list term (#1289)
25
+ * allow theme to override caption styles for specific block categories: blockquote, code, example, footnotes, image, listing, and table (#307)
26
+ * allow theme to control style of verse block independently of a quote block (#40)
27
+ * position list marker correctly when media=prepress and list item is advanced to next page or split across pages (#1303)
28
+ * layout horizontal dlist in two columns (#310)
29
+ * apply normal substitutions to content of manname section (#1294)
30
+ * optimize PDF using quality specified in value of optimize attribute if optimize attribute is set (#535)
31
+ * allow xref macro to override xrefstyle set on document
32
+ * assume admonition icon in theme is a legacy FontAwesome icon if the icon set prefix is absent
33
+ * rewrite optimize-pdf as a bin script named asciidoctor-pdf-optimize
34
+ * allow image alt text formatting and arrangement to be controlled by theme (#730)
35
+ * upgrade prawn-icon to 2.5.0 (which upgrades Font Awesome to 5.11.2)
36
+
8
37
  == 1.5.0.beta.5 (2019-09-13) - @mojavelinux
9
38
 
10
39
  * pass styles for inline elements downwards when parsing, allowing role to override default styles for element (#1219)
@@ -110,10 +139,11 @@ For a detailed view of what has changed, refer to the {uri-repo}/commits/master[
110
139
  * scale SVG background image to fit page in the same way raster image is scaled (#765)
111
140
  * allow page background size to be controlled using image macro attributes (#1117)
112
141
  * allow page background image position to be controlled using position attribute on image macro (#1124)
113
- * add support for fit=cover for cover page, page background, and running content images (#1136)
142
+ * add support for fit=cover for cover, page background, and running content images (#1136)
114
143
  * change default background image position to center (#1124)
115
144
  * allow cover image position to be controlled using position attribute on image macro (#1134)
116
145
  * change default cover image position to center (#1134)
146
+ * allow cover image size to be controlled using fit, pdfwidth, and width attributes; don't scale image by default (#1134)
117
147
  * set enable_file_requests_with_root and enable_web_requests options for all SVGs (#683)
118
148
  * automatically set pdf-stylesdir if pdf-style ends with .yml and pdf-stylesdir is not specified (#1126)
119
149
  * replace hyphens with underscores in top-level theme keys
@@ -272,7 +302,8 @@ For a detailed view of what has changed, refer to the {uri-repo}/commits/master[
272
302
  * implement start line number for source listing (Rouge) (#752)
273
303
  * enable "start inline" option when highlighting PHP (#755)
274
304
  * persuade CodeRay to handle html+ source languages
275
- * introduce stripes attribute to table to control zebra-striping (#724)
305
+ * introduce stripes attribute to table to control zebra striping (#724)
306
+ * use theme key table_body_stripe_background_color to control color of table stripes (#724)
276
307
  * allow theme to set style of table border and grid (#766)
277
308
  * allow theme to set text transform on header cell in table body (#750)
278
309
  * set top border width of first body row to match bottom border width of header row
@@ -1,6 +1,6 @@
1
1
  = Asciidoctor PDF: A native PDF converter for AsciiDoc
2
2
  Dan Allen <https://github.com/mojavelinux[@mojavelinux]>; Sarah White <https://github.com/graphitefriction[@graphitefriction]>
3
- v1.5.0.beta.5, 2019-09-13
3
+ v1.5.0.beta.6, 2019-10-12
4
4
  // Settings:
5
5
  :experimental:
6
6
  :idprefix:
@@ -24,7 +24,7 @@ endif::[]
24
24
  :project-name: Asciidoctor PDF
25
25
  :project-handle: asciidoctor-pdf
26
26
  // Variables:
27
- :release-version: 1.5.0.beta.5
27
+ :release-version: 1.5.0.beta.6
28
28
  // URIs:
29
29
  :url-asciidoctor: http://asciidoctor.org
30
30
  :url-gem: http://rubygems.org/gems/asciidoctor-pdf
@@ -476,19 +476,20 @@ If the image height exceeds the height of the page, the image will be scaled dow
476
476
 
477
477
  === Background Image Sizing
478
478
 
479
- In addition to the width-related attributes previously covered, background images can be sized relative to the page using the `fit` attribute of the image macro.
479
+ In addition to the width-related attributes previously covered, cover and background images can be sized relative to the page using the `fit` attribute of the image macro.
480
480
  The `fit` attribute works similarly to the `object-fit` property in CSS.
481
481
  It's value must be specified as a single keyword, chosen from the table below.
482
482
  The starting size of the image is determined by the explicit width, if specified, or the implicit width.
483
- The height is always derived from with width, respecting the implicit aspect ratio of the image.
483
+ The height is always derived from the width while respecting the implicit aspect ratio of the image.
484
484
  The available space for a background image (i.e., the canvas) is the page.
485
+ If the `fit` attribute is not specified, it defaults to `contain`.
485
486
 
486
487
  [cols="1s,3"]
487
488
  |===
488
489
  | Value | Purpose
489
490
 
490
491
  | contain
491
- | The image is scaled up or down while retaining its aspect ratio to fit within the available space.
492
+ | The image is scaled up or down while retaining its aspect ratio to fit within the available space. (default)
492
493
 
493
494
  | cover
494
495
  | The image is scaled up or down while retaining its aspect ratio so the image completely covers the available space, even if it means the image must be clipped in one direction.
@@ -497,6 +498,10 @@ The available space for a background image (i.e., the canvas) is the page.
497
498
  | The image is scaled down while retaining its aspect ratio to fit within the available space.
498
499
  If the image already fits, it is not scaled.
499
500
 
501
+ | fill
502
+ | The image is scaled to fit the available space even if it means modifying the aspect ratio of the image.
503
+ Does not apply to SVG images.
504
+
500
505
  | none
501
506
  | The image is not scaled.
502
507
  |===
@@ -529,13 +534,13 @@ right
529
534
  Here's an example of how to place a background image at the top center of every page:
530
535
 
531
536
  ----
532
- :page-background-image: image:bg.png[pdfwidth=50%,position=top]
537
+ :page-background-image: image:bg.png[fit=none,pdfwidth=50%,position=top]
533
538
  ----
534
539
 
535
540
  Here's how to move it to the bottom right:
536
541
 
537
542
  ----
538
- :page-background-image: image:bg.png[pdfwidth=50%,position=bottom right]
543
+ :page-background-image: image:bg.png[fit=none,pdfwidth=50%,position=bottom right]
539
544
  ----
540
545
 
541
546
  If an image dimension matches the height or width of the page, the positioning keyword for that axis has no effect.
@@ -712,7 +717,7 @@ Let's start small.
712
717
 
713
718
  You'll find when you run this example that all the interdocument xrefs become internal references in the PDF.
714
719
 
715
- The reason both the path and anchor are required (even when liking to the top of a chapter) is so the interdocument xref works independent of the converter.
720
+ The reason both the path and anchor are required (even when linking to the top of a chapter) is so the interdocument xref works independent of the converter.
716
721
  In other words, it encodes the complete information about the reference so the converter can sort out where the target is in all circumstances.
717
722
 
718
723
  == STEM Support
@@ -894,27 +899,25 @@ However, you could use an extension, such as a TreeProcessor, to automatically m
894
899
 
895
900
  == Optimizing the Generated PDF
896
901
 
897
- === optimize-pdf
902
+ === asciidoctor-pdf-optimize
898
903
 
899
- {project-name} also provides a shell script that uses GhostScript (`gs`) to optimize and compress the generated PDF (with minimal impact on quality).
900
- You must have Ghostscript installed to use it.
904
+ {project-name} also provides a bin script that uses GhostScript to optimize and compress the generated PDF (with minimal impact on quality).
905
+ You must have Ghostscript (command: `gs`) and the `rghost` gem installed to use it.
901
906
 
902
907
  Here's an example usage:
903
908
 
904
- $ ./bin/optimize-pdf basic-example.pdf
905
-
906
- The command will generate the file [.path]_basic-example-optimized.pdf_ in the same directory.
909
+ $ asciidoctor-pdf-optimize basic-example.pdf
907
910
 
908
- WARNING: The `optimize-pdf` script currently requires a Bash shell (Linux, OSX, etc).
909
- We plan to rewrite the script in Ruby so it works across platforms (see https://github.com/asciidoctor/asciidoctor-pdf/issues/1[issue #1])
911
+ The command will overwrite the PDF file with an optimized version.
910
912
 
911
913
  If a file is found with the extension `.pdfmark` and the same rootname as the input file, it is used to add metadata to the generated PDF document.
912
914
  This file is necessary to preserve the document metadata since Ghostscript will otherwise drop it.
913
915
  That's why {project-name} always creates this file in addition to the PDF.
914
916
 
915
- IMPORTANT: The `optimize-pdf` script relies on Ghostscript >= 9.10.
916
- Otherwise, it may actually make the PDF larger.
917
- You should probably only consider using it if the file size of the original PDF is > 5MB.
917
+ IMPORTANT: The `asciidoctor-pdf-optimize` is not guaranteed to reduce the size of the PDF file.
918
+ It may actually make the PDF larger.
919
+ You should probably only consider using it if the file size of the original PDF is several megabytes.
920
+ You can also try reducing the quality of the output file using the `-q` flag (e.g., `-q screen`).
918
921
 
919
922
  === hexapdf
920
923
 
@@ -29,8 +29,7 @@ Gem::Specification.new do |s|
29
29
  files = Dir['**/*']
30
30
  end
31
31
  s.files = files.grep %r/^(?:(?:data|lib)\/.+|docs\/theming-guide\.adoc|(?:CHANGELOG|LICENSE|NOTICE|README)\.adoc|\.yardopts|#{s.name}\.gemspec)$/
32
- # FIXME optimize-pdf is currently a shell script, so listing it here won't work
33
- #s.executables = (files.grep %r/^bin\//).map {|f| File.basename f }
32
+ s.executables = (files.grep %r/^bin\//).map {|f| File.basename f }
34
33
  s.executables = ['asciidoctor-pdf']
35
34
  s.require_paths = ['lib']
36
35
  #s.test_files = files.grep %r/^(?:test|spec|feature)\/.*$/
@@ -40,20 +39,20 @@ Gem::Specification.new do |s|
40
39
  s.add_runtime_dependency 'prawn-table', '~> 0.2.0'
41
40
  s.add_runtime_dependency 'prawn-templates', '~> 0.1.0'
42
41
  s.add_runtime_dependency 'prawn-svg', '~> 0.29.0'
43
- s.add_runtime_dependency 'prawn-icon', '~> 2.4.0'
42
+ s.add_runtime_dependency 'prawn-icon', '~> 2.5.0'
44
43
  s.add_runtime_dependency 'safe_yaml', '~> 1.0.0'
45
44
  s.add_runtime_dependency 'thread_safe', '~> 0.3.0'
46
45
  s.add_runtime_dependency 'concurrent-ruby', '~> 1.1.0'
47
46
  # For our usage, treetop 1.6 is slower than treetop 1.5
48
47
  s.add_runtime_dependency 'treetop', '~> 1.5.0'
49
48
 
50
- s.add_development_dependency 'rake', '~> 12.3.0'
49
+ s.add_development_dependency 'rake', '~> 13.0.0'
51
50
  s.add_development_dependency 'deep-cover-core', '~> 0.7.0'
52
51
  s.add_development_dependency 'simplecov', '~> 0.17.0'
53
- s.add_development_dependency 'rspec', '~> 3.8.0'
52
+ s.add_development_dependency 'rspec', '~> 3.9.0'
54
53
  s.add_development_dependency 'pdf-inspector', '~> 1.3.0'
55
54
  # Asciidoctor PDF supports Rouge >= 2 (verified in CI build using 2.0.0)
56
- s.add_development_dependency 'rouge', '~> 3.6.0'
55
+ s.add_development_dependency 'rouge', '~> 3.11.0'
57
56
  s.add_development_dependency 'coderay', '~> 1.1.0'
58
57
  s.add_development_dependency 'chunky_png', '~> 1.3.0'
59
58
  end
@@ -74,6 +74,9 @@ admonition_label_text_transform: uppercase
74
74
  blockquote_border_color: 'EEEEEE'
75
75
  blockquote_border_width: 4
76
76
  blockquote_padding: [6, 12, -6, 14]
77
+ verse_border_color: 'EEEEEE'
78
+ verse_border_width: 4
79
+ verse_padding: [6, 12, -6, 14]
77
80
  code_font_family: Courier
78
81
  code_font_size: 10.8
79
82
  code_line_height: 1.2
@@ -164,7 +164,6 @@ admonition:
164
164
  text_transform: uppercase
165
165
  font_style: bold
166
166
  blockquote:
167
- font_color: $base_font_color
168
167
  font_size: $base_font_size_large
169
168
  border_color: $base_border_color
170
169
  border_width: 5
@@ -172,6 +171,13 @@ blockquote:
172
171
  padding: [0, $horizontal_rhythm, $block_margin_bottom * -0.75, $horizontal_rhythm + $blockquote_border_width / 2]
173
172
  cite_font_size: $base_font_size_small
174
173
  cite_font_color: 999999
174
+ verse:
175
+ font_size: $blockquote_font_size
176
+ border_color: $blockquote_border_color
177
+ border_width: $blockquote_border_width
178
+ padding: $blockquote_padding
179
+ cite_font_size: $blockquote_cite_font_size
180
+ cite_font_color: $blockquote_cite_font_color
175
181
  # code is used for source blocks (perhaps change to source or listing?)
176
182
  code:
177
183
  font_color: $base_font_color
@@ -37,7 +37,7 @@ This document describes how the theming system works, how to define a custom the
37
37
 
38
38
  TIP: The quickest way to create your own theme is to <<Extends,extend the default theme>>.
39
39
  This not only gives you a set of foundation styles to build on, it also provides a collection of <<Bundled Fonts,bundled fonts>>.
40
- If you want to replace the bundled fonts with your own, you must declare the name and location of each font in the <<Custom fonts,font catalog>>.
40
+ If you want to replace the bundled fonts with your own, you must declare the name and location of each font in the <<Custom Fonts,font catalog>>.
41
41
  To reuse the bundled fonts, you can either extend the default theme and/or redeclare the bundled fonts in the font catalog.
42
42
 
43
43
  WARNING: If you don't declare your own fonts (or extend the default theme), only the built-in (AFM) fonts provided by the PDF reader will be available.
@@ -314,7 +314,7 @@ base:
314
314
  === Math Expressions & Functions
315
315
 
316
316
  The theme language supports basic math operations to support calculated values.
317
- Like programming languages, multiple and divide take precedence over add and subtract.
317
+ Like programming languages, multiply and divide take precedence over add and subtract.
318
318
 
319
319
  The following table lists the supported operations and the corresponding operator for each.
320
320
 
@@ -448,7 +448,7 @@ Images can be aligned as follows:
448
448
 
449
449
  === Font Styles
450
450
 
451
- In most cases, whereever you can specify a custom font family, you can also specify a font style.
451
+ In most cases, wherever you can specify a custom font family, you can also specify a font style.
452
452
  These two settings are combined to locate the font to use.
453
453
 
454
454
  The following font styles are recognized:
@@ -578,6 +578,8 @@ table:
578
578
  background-color: transparent
579
579
  ----
580
580
 
581
+ The `transparent` keyword can be used for the background or border color, but not the font color.
582
+
581
583
  === Images
582
584
 
583
585
  An image is specified either as a bare image path or as an inline image macro as found in the AsciiDoc syntax.
@@ -815,7 +817,7 @@ Effectively, it subsets the font.
815
817
  While that saves space taken up by the generated PDF, you may still be storing the full font in your source repository.
816
818
  To minimize the size of the source font, you can use {url-fontforge}[FontForge] to subset the font ahead of time.
817
819
  Subsetting a font means remove glyphs you don't plan to use.
818
- Doing so it not a requirement, simply a personal preference.
820
+ Doing so is not a requirement, simply a personal preference.
819
821
 
820
822
  You can add any number of fonts to the catalog.
821
823
  Each font must be assigned a unique key, as shown here:
@@ -1112,6 +1114,12 @@ See <<Title Page>> for details.
1112
1114
  recto: image:page-bg-recto.png[]
1113
1115
  verso: image:page-bg-verso.png[]
1114
1116
 
1117
+ |foreground-image^[2]^
1118
+ |image macro^[3]^ +
1119
+ (default: _not set_)
1120
+ |page
1121
+ foreground-image: image:watermark.svg[]
1122
+
1115
1123
  |initial-zoom
1116
1124
  |Fit {vbar} FitH {vbar} FitV +
1117
1125
  (default: FitH)
@@ -1157,12 +1165,12 @@ See <<Title Page>> for details.
1157
1165
 
1158
1166
  . To disable the background color for the page, set the value to white (i.e., FFFFFF).
1159
1167
  The color keyword `transparent` is not recognized in this context.
1160
- . By default, page background images are automatically scaled to fit the bounds of the page (i.e., `fit=contain`) and centered (i.e., `position=center`).
1161
- The size of the background image can be controlled using any of the sizing attributes on the image macro (i.e., fit, pdfwidth, scaledwidth, or width).
1162
- The position of the background image can be controlled using the `position` attribute.
1163
- If the recto (right-hand, odd-numbered pages) or verso (left-hand, even-numbered pages) background is specified, it will be used only for that side.
1168
+ . By default, page background and foreground images are automatically scaled to fit the bounds of the page (i.e., `fit=contain`) and centered (i.e., `position=center`).
1169
+ The size of the image can be controlled using any of the sizing attributes on the image macro (i.e., fit, pdfwidth, scaledwidth, or width) when `fit=none`.
1170
+ The position of the image can be controlled using the `position` attribute.
1171
+ If the recto (right-hand, odd-numbered pages) or verso (left-hand, even-numbered pages) background image is specified, it will be used only for that side (not available for the foreground image).
1164
1172
  If you define the keys using the flatten structure (e.g., `page-background-image-recto`), you can also set the default page background image (`page-background-image`), which will then be used as a fallback if a background image isn't specified for a given side.
1165
- To disable the background image, use the value `none`.
1173
+ To disable the image, use the value `none`.
1166
1174
  . Target may be an absolute path or a path relative to the value of the `pdf-themesdir` attribute.
1167
1175
  . The margins for `recto` (right-hand, odd-numbered) and `verso` (left-hand, even-numbered) pages are calculated automatically from the margin-inner and margin-outer values.
1168
1176
  These margins and used when the value `prepress` is assigned to the `media` document attribute.
@@ -1277,9 +1285,10 @@ NOTE: While it's common to define additional keys in this category (e.g., `base-
1277
1285
  . The `text-transform` key cannot be set globally.
1278
1286
  Therefore, this key should not be used.
1279
1287
  The value of `none` is implicit and is documented here for completeness.
1280
- . The `line-height-length` is a pseudo property that's local the theme.
1281
- It's often used for computing the `base-line-height` from the base font size and the desired line height size.
1288
+ . `line-height-length` is a utility property that's internal to the theme.
1289
+ It's used as an intermediate property for computing the `base-line-height` from the base font size and the desired line height size.
1282
1290
  For instance, if you set `base-line-height-length`, you can use `$base-line-height-length / $base-font-size` to set the value of `base-line-height`.
1291
+ You don't have to go about it this way in your own theme.
1283
1292
 
1284
1293
  [#keys-vertical-spacing]
1285
1294
  === Vertical Spacing
@@ -1569,6 +1578,24 @@ The keys in this category control the style of most headings, including part tit
1569
1578
  . A font size is assigned to each heading level by the base theme.
1570
1579
  If you want the font size of a specific level to be inherited, you must assign the value `null` (or `~` for short).
1571
1580
 
1581
+ [#keys-section]
1582
+ === Section
1583
+
1584
+ The keys in this category control the style of a section body.
1585
+
1586
+ [cols="3,4,5l"]
1587
+ |===
1588
+ |Key |Value Type |Example
1589
+
1590
+ 3+|[#key-prefix-section]*Key Prefix:* <<key-prefix-section,section>>
1591
+
1592
+ |indent
1593
+ |<<measurement-units,Measurement>> +
1594
+ (default: 0)
1595
+ |section:
1596
+ indent: 36
1597
+ |===
1598
+
1572
1599
  [#keys-title-page]
1573
1600
  === Title Page
1574
1601
 
@@ -1906,7 +1933,7 @@ TIP: The title page can be disabled for the book doctype by setting the `notitle
1906
1933
  . To disable the background color for the title page, set the value to white (i.e., FFFFFF).
1907
1934
  The color keyword `transparent` is not recognized in this context.
1908
1935
  . By default, page background images are automatically scaled to fit the bounds of the page (i.e., `fit=contain`) and centered (i.e., `position=center`).
1909
- The size of the background image can be controlled using any of the sizing attributes on the image macro (i.e., fit, pdfwidth, scaledwidth, or width).
1936
+ The size of the background image can be controlled using any of the sizing attributes on the image macro (i.e., fit, pdfwidth, scaledwidth, or width) when `fit=none`.
1910
1937
  The position of the background image can be controlled using the `position` attribute.
1911
1938
  . Target may be an absolute path or a path relative to the value of the `pdf-themesdir` attribute.
1912
1939
  . Percentage unit can be % (relative to content height) or vh (relative to page height).
@@ -2002,6 +2029,7 @@ Block styles are applied to the following block types:
2002
2029
  === Caption
2003
2030
 
2004
2031
  The keys in this category control the arrangement and style of block captions.
2032
+ In addition to the generic caption category, each of these keys can be set on the caption key nested inside the following block categories: blockquote, code, example, footnotes, image, listing, table, and verse.
2005
2033
 
2006
2034
  [cols="3,4,5l"]
2007
2035
  |===
@@ -2392,7 +2420,7 @@ The keys in this category control the arrangement and style of quote blocks.
2392
2420
  |<<colors,Color>> +
2393
2421
  (default: #eeeeee)
2394
2422
  |blockquote:
2395
- border-color: #eeeeee
2423
+ border-color: #dddddd
2396
2424
 
2397
2425
  |font-color
2398
2426
  |<<colors,Color>> +
@@ -2470,6 +2498,105 @@ The keys in this category control the arrangement and style of quote blocks.
2470
2498
 
2471
2499
  . Only applies to the left side.
2472
2500
 
2501
+ [#keys-verse]
2502
+ === Verse
2503
+
2504
+ The keys in this category control the arrangement and style of verse blocks.
2505
+
2506
+ [cols="3,4,5l"]
2507
+ |===
2508
+ |Key |Value Type |Example
2509
+
2510
+ 3+|[#key-prefix-verse]*Key Prefix:* <<key-prefix-verse,verse>>
2511
+
2512
+ |border-width^[1]^
2513
+ |<<values,Number>> +
2514
+ (default: 4)
2515
+ |verse:
2516
+ border-width: 5
2517
+
2518
+ |border-color^[1]^
2519
+ |<<colors,Color>> +
2520
+ (default: #eeeeee)
2521
+ |verse:
2522
+ border-color: #dddddd
2523
+
2524
+ |font-color
2525
+ |<<colors,Color>> +
2526
+ (default: _inherit_)
2527
+ |verse:
2528
+ font-color: #333333
2529
+
2530
+ |font-family
2531
+ |<<fonts,Font family name>> +
2532
+ (default: _inherit_)
2533
+ |verse:
2534
+ font-family: M+ 1mn
2535
+
2536
+ |font-size
2537
+ |<<values,Number>> +
2538
+ (default: _inherit_)
2539
+ |verse:
2540
+ font-size: 10
2541
+
2542
+ |font-style
2543
+ |<<font-styles,Font style>> +
2544
+ (default: _inherit_)
2545
+ |verse:
2546
+ font-style: bold
2547
+
2548
+ |text-transform
2549
+ |<<text-transforms,Text transform>> +
2550
+ (default: _inherit_)
2551
+ |verse:
2552
+ text-transform: uppercase
2553
+
2554
+ |padding
2555
+ |<<measurement-units,Measurement>> {vbar} <<measurement-units,Measurement[top,right,bottom,left]>> +
2556
+ (default: [6, 12, -6, 14])
2557
+ |verse:
2558
+ padding: [5, 10, -5, 12]
2559
+
2560
+ 3+|[#key-prefix-verse-cite]*Key Prefix:* <<key-prefix-verse-cite,verse-cite>>
2561
+
2562
+ |font-size
2563
+ |<<values,Number>> +
2564
+ (default: _inherit_)
2565
+ |verse:
2566
+ cite:
2567
+ font-size: 9
2568
+
2569
+ |font-color
2570
+ |<<colors,Color>> +
2571
+ (default: _inherit_)
2572
+ |verse:
2573
+ cite:
2574
+ font-color: #999999
2575
+
2576
+ |font-family
2577
+ |<<fonts,Font family name>> +
2578
+ (default: _inherit_)
2579
+ |verse:
2580
+ cite:
2581
+ font-family: Noto Serif
2582
+
2583
+ |font-style
2584
+ |<<font-styles,Font style>> +
2585
+ (default: _inherit_)
2586
+ |verse:
2587
+ cite:
2588
+ font-style: italic
2589
+
2590
+ |text-transform
2591
+ |<<text-transforms,Text transform>> +
2592
+ (default: _inherit_)
2593
+ |verse:
2594
+ cite:
2595
+ text-transform: uppercase
2596
+ |===
2597
+
2598
+ . Only applies to the left side.
2599
+
2473
2600
  [#keys-sidebar]
2474
2601
  === Sidebar
2475
2602
 
@@ -2824,6 +2951,7 @@ The subkeys in the icon category cannot be flattened (e.g., `tip-name: far-light
2824
2951
  . Required.
2825
2952
  See the `.yml` files in the https://github.com/jessedoyle/prawn-icon/tree/master/data/fonts[prawn-icon repository] for a list of valid icon names.
2826
2953
  The prefix (e.g., `fas-`) determines which font set to use.
2954
+ If the prefix is not specified, `fa-` is assumed.
2827
2955
 
2828
2956
  [#keys-image]
2829
2957
  === Image
@@ -2871,6 +2999,43 @@ The keys in this category control the arrangement of block images.
2871
2999
  (default: content)
2872
3000
  |image:
2873
3001
  border-fit: auto
3002
+
3003
+ 3+|[#key-prefix-image-alt]*Key Prefix:* <<key-prefix-image-alt,image-alt>>
3004
+
3005
+ |content^[4]^
3006
+ |<<quoted-string,Quoted string>> +
3007
+ (default: "%\{link}[%\{alt}]%{/link} {vbar} %\{target}")
3008
+ |image:
3009
+ alt:
3010
+ content: "%{alt} (%{target})"
3011
+
3012
+ |font-color
3013
+ |<<colors,Color>> +
3014
+ (default: _inherit_)
3015
+ |image:
3016
+ alt:
3017
+ font-color: #ff000
3018
+
3019
+ |font-family
3020
+ |<<fonts,Font family name>> +
3021
+ (default: _inherit_)
3022
+ |image
3023
+ alt:
3024
+ font-family: Courier
3025
+
3026
+ |font-size
3027
+ |<<values,Number>> +
3028
+ (default: _inherit_)
3029
+ |image:
3030
+ alt:
3031
+ font-size: 9
3032
+
3033
+ |font-style
3034
+ |<<font-styles,Font style>> +
3035
+ (default: normal)
3036
+ |iamge:
3037
+ alt:
3038
+ font-style: italic
2874
3039
  |===
2875
3040
 
2876
3041
  . Only applies to block images.
@@ -2878,6 +3043,7 @@ If specified, this value takes precedence over the value of the `width` attribut
2878
3043
  . The border is only used if a border color is specified, the border width is specified, the border width is greater than 0, and the `noborder` role is not present.
2879
3044
  The border is drawn above the image on the inside of the box reserved for the image.
2880
3045
  . The value `auto` means the border should expand to fit the width of the container (i.e., full width) instead of the image.
3046
+ . Use the placeholders `%\{alt}`, `%\{target}`, `%\{link}`, and `%{/link}` to insert the alt text, image target, and link open/close tags into the content template.
2881
3047
 
2882
3048
  [#keys-svg]
2883
3049
  === SVG
@@ -3085,18 +3251,66 @@ The keys in this category control the style of thematic breaks (aka horizontal r
3085
3251
 
3086
3252
  The keys in this category control the arrangement and style of definition list items (terms and descriptions).
3087
3253
 
3254
+ [TIP]
3255
+ ====
3256
+ Asciidoctor PDF supports unordered and ordered description lists.
3257
+ These are defined as a description list, but get displayed as an unordered or ordered description list with the term as a subject.
3258
+ Only one term is supported.
3259
+ The subject is shown using the term font style (bold by default).
3260
+ The subject is stacked above the description if the "stack" role is present.
3261
+ Otherwise, the subject is arranged as a run-in followed by a subject stop (`:` by default).
3262
+ The subject stop can be customized using the `subject-stop` attribute.
3263
+
3264
+ [source,asciidoc]
3265
+ ----
3266
+ [unordered]
3267
+ * alpha:: partially complete and unstable
3268
+ * beta:: feature complete and undergoing testing
3269
+ ----
3270
+ ====
3271
+
3088
3272
  [cols="3,4,5l"]
3089
3273
  |===
3090
3274
  |Key |Value Type |Example
3091
3275
 
3092
3276
  3+|[#key-prefix-description-list]*Key Prefix:* <<key-prefix-description-list,description-list>>
3093
3277
 
3278
+ |term-font-color
3279
+ |<<colors,Color>> +
3280
+ (default: _inherit_)
3281
+ |description-list:
3282
+ term-font-color: #AA0000
3283
+
3284
+ |term-font-family
3285
+ |<<fonts,Font family name>> +
3286
+ (default: _inherit_)
3287
+ |description-list:
3288
+ term-font-family: Noto Serif
3289
+
3290
+ |term-font-size
3291
+ |<<values,Number>> +
3292
+ (default: _inherit_)
3293
+ |description-list:
3294
+ term-font-size: 12
3295
+
3094
3296
  |term-font-style
3095
3297
  |<<font-styles,Font style>> +
3096
3298
  (default: bold)
3097
3299
  |description-list:
3098
3300
  term-font-style: italic
3099
3301
 
3302
+ |term-text-transform
3303
+ |<<text-transforms,Text transform>> +
3304
+ (default: none)
3305
+ |description-list:
3306
+ term-text-transform: none
3307
+
3308
+ |term-line-height
3309
+ |<<values,Number>> +
3310
+ (default: $base-line-height)
3311
+ |description-list:
3312
+ term-line-height: 1.2
3313
+
3100
3314
  |term-spacing
3101
3315
  |<<measurement-units,Measurement>> +
3102
3316
  (default: 4)
@@ -3847,7 +4061,7 @@ To avoid this problem, reduce the height of the running content periphery or mak
3847
4061
  |header:
3848
4062
  image-vertical-align: 4
3849
4063
 
3850
- |sectlevels
4064
+ |sectlevels^[4]^
3851
4065
  |Integer +
3852
4066
  (default: 2)
3853
4067
  |header:
@@ -3871,14 +4085,14 @@ To avoid this problem, reduce the height of the running content periphery or mak
3871
4085
  |header:
3872
4086
  vertical-align: center
3873
4087
 
3874
- |<side>-columns^[4]^
4088
+ |<side>-columns^[5]^
3875
4089
  |Column specs triple +
3876
4090
  (default: _not set_)
3877
4091
  |header:
3878
4092
  recto:
3879
4093
  columns: <25% =50% >25%
3880
4094
 
3881
- |<side>-<position>-content^[4,5]^
4095
+ |<side>-<position>-content^[5,6]^
3882
4096
  |<<quoted-string,Quoted string>> +
3883
4097
  (default: '\{page-number}')
3884
4098
  |header:
@@ -3960,7 +4174,7 @@ To avoid this problem, reduce the height of the running content periphery or mak
3960
4174
  |footer:
3961
4175
  image-vertical-align: 4
3962
4176
 
3963
- |sectlevels
4177
+ |sectlevels^[4]^
3964
4178
  |Integer +
3965
4179
  (default: 2)
3966
4180
  |footer:
@@ -3984,14 +4198,14 @@ To avoid this problem, reduce the height of the running content periphery or mak
3984
4198
  |footer:
3985
4199
  vertical-align: top
3986
4200
 
3987
- |<side>-columns^[4]^
4201
+ |<side>-columns^[5]^
3988
4202
  |Column specs triple +
3989
4203
  (default: _not set_)
3990
4204
  |footer:
3991
4205
  verso:
3992
4206
  columns: <50% =0% <50%
3993
4207
 
3994
- |<side>-<position>-content^[4,5]^
4208
+ |<side>-<position>-content^[5,6]^
3995
4209
  |<<quoted-string,Quoted string>> +
3996
4210
  (default: '\{page-number}')
3997
4211
  |footer:
@@ -4002,7 +4216,9 @@ To avoid this problem, reduce the height of the running content periphery or mak
4002
4216
  . The background color spans the width of the page, as does the border when a background color is specified.
4003
4217
  . *If the height is not set, the running content at this periphery is disabled.*
4004
4218
  . If the side padding is negative, the content will bleed into the margin of the page.
4219
+ . The maximum section level considered when assigning the implicit `section-title` attribute (and related) available to the running content.
4005
4220
  . `<side>` can be `recto` (right-hand, odd-numbered pages) or `verso` (left-hand, even-numbered pages).
4221
+ The `columns` key can also be defined one level up (on `header` or `footer`), in which case the setting will be inherited.
4006
4222
  Where the page sides fall in relation to the physical or printed page number is controlled using the `pdf-folio-placement` attribute (except when `media=prepress`, which implies `physical`).
4007
4223
  . `<position>` can be `left`, `center` or `right`.
4008
4224
 
@@ -4022,7 +4238,7 @@ You can use _any_ attribute defined in your AsciiDoc document (such as `doctitle
4022
4238
  In addition, the following attributes are also available when defining the content keys in the footer:
4023
4239
 
4024
4240
  * page-count
4025
- * page-number
4241
+ * page-number (only set if the `pagenums` attribute is set on the document, which it is by default)
4026
4242
  * document-title
4027
4243
  * document-subtitle
4028
4244
  * part-title
@@ -4030,6 +4246,10 @@ In addition, the following attributes are also available when defining the conte
4030
4246
  * section-title
4031
4247
  * section-or-chapter-title
4032
4248
 
4249
+ If you reference an attribute which is not defined, all the text on that same line in the running content will be dropped.
4250
+ One case where this is useful is when referencing the `page-number` attribute.
4251
+ If you unset the `pagenums` attribute on the document, any line in the running content that makes reference to `\{page-number}` will be dropped.
4252
+
4033
4253
  You can also built-in AsciiDoc text replacements like `+(C)+`, numeric character references like `+&#169;+` and inline formatting (e.g., bold, italic, monospace).
4034
4254
 
4035
4255
  Here's an example that shows how attributes and replacements can be used in the running footer:
@@ -4056,6 +4276,8 @@ footer:
4056
4276
  content: '*{page-number}* | {chapter-title}'
4057
4277
  ----
4058
4278
 
4279
+ ==== Multiple Lines
4280
+
4059
4281
  You can split the content value across multiple lines using YAML's multiline string syntax.
4060
4282
  In this case, the single quotes around the string are not necessary.
4061
4283
  To force a hard line break in the output, add `{sp}+` to the end of the line in normal AsciiDoc fashion.
@@ -4199,6 +4421,10 @@ These settings override equivalent keys defined in the theme file, where applica
4199
4421
  |screen {vbar} print {vbar} prepress
4200
4422
  |:media: prepress
4201
4423
 
4424
+ |optimize
4425
+ |screen {vbar} ebook {vbar} printer {vbar} prepress {vbar} default (default: default)
4426
+ |:optimize: prepress
4427
+
4202
4428
  |outlinelevels^[10]^
4203
4429
  |Integer {vbar} Integer:Integer (default: same as _toclevels_)
4204
4430
  |:outlinelevels: 2
@@ -4211,6 +4437,10 @@ These settings override equivalent keys defined in the theme file, where applica
4211
4437
  |path^[2]^ {vbar} image macro^[3]^
4212
4438
  |:page-background-image-recto: image:bg-recto.jpg[]
4213
4439
 
4440
+ |page-foreground-image
4441
+ |path^[2]^ {vbar} image macro^[3]^
4442
+ |:page-foreground-image: image:watermark.svg[]
4443
+
4214
4444
  |pagenums^[5]^
4215
4445
  |flag (default: _set_)
4216
4446
  |:pagenums:
@@ -4265,13 +4495,13 @@ These settings override equivalent keys defined in the theme file, where applica
4265
4495
  . The target of the image macro is resolved relative to `imagesdir`.
4266
4496
  If the image macro syntax is not used, the value is resolved relative to the base directory, which defaults to the document directory.
4267
4497
  . By default, page background images are automatically scaled to fit the bounds of the page (i.e., `fit=contain`) and centered (i.e., `position=center`).
4268
- The size of the background image can be controlled using any of the sizing attributes on the image macro (i.e., fit, pdfwidth, scaledwidth, or width).
4498
+ The size of the background image can be controlled using any of the sizing attributes on the image macro (i.e., fit, pdfwidth, scaledwidth, or width) when `fit=none`.
4269
4499
  The position of the background image can be controlled using the `position` attribute.
4270
4500
  If the recto (right-hand, odd-numbered pages) or verso (left-hand, even-numbered pages) background is specified, it will be used only for that side.
4271
4501
  If a background image isn't specified for a side, the converter will use the default page background image (`page-background-image`), if specified.
4272
4502
  To disable the background image for a side, use the value `none`.
4273
- . Controls whether the `page-number` attribute is accessible to the running header and footer content specified in the theme file.
4274
- Use the `noheader` and `nofooter` attributes to disable the running header and footer, respectively, from the document.
4503
+ . Controls whether the implicit `page-number` attribute is to the running header and footer content specified in the theme file.
4504
+ Instead of disabling page numbers, you can use the `noheader` and `nofooter` attributes to disable the running header and footer, respectively.
4275
4505
  . Enables generation of the http://milan.kupcevic.net/ghostscript-ps-pdf/#marks[pdfmark] file, which contains metadata that is fed to Ghostscript when optimizing the PDF file.
4276
4506
  . _(Experimental)_ The `text-align` document attribute is intended as a simple way to toggle text justification.
4277
4507
  The value of this attribute overrides the `base-align` key set by the theme.
@@ -4447,7 +4677,7 @@ When you override a block element, you write PDF objects directly to the Prawn D
4447
4677
  When you override an inline element, you return pseudo-HTML, which is then parsed and converted into PDF objects.
4448
4678
 
4449
4679
  The pseudo-HTML in Asciidoctor PDF evolved from the inline formatting in Prawn, now supporting the following elements: a, br, button, code, color, del, em, font, img, key, mark, span, strong, sub, sup.
4450
- All decimal and hexadecimal character references are supported, as well as the named entities amp, apos, gt, lt, nbsp, and quot (e.g., `\&apos;`.
4680
+ All decimal and hexadecimal character references are supported, as well as the named entities amp, apos, gt, lt, nbsp, and quot (e.g., `\&apos;`).
4451
4681
  You can change the font color using `rgb` attribue on the `color` element (e.g., `<color rgb="#ff0000">`) and the font family and size using `name` and `size` attributes on the `font` element, respectively (e.g., `<font name="sans" size="12">`).
4452
4682
  You can also use the `style` attribute on `span` to control the font color, weight, and style using the relevant CSS property names.
4453
4683
  The pseudo-HTML in Asciidoctor PDF also supports the `class` attribute on any element for applying roles from the theme.