asciidoctor-pdf 2.3.22 → 2.3.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.adoc +23 -0
- data/README.adoc +1 -1
- data/data/fonts/notosans-regular-subset.ttf +0 -0
- data/data/fonts/notoserif-regular-subset.ttf +0 -0
- data/lib/asciidoctor/pdf/converter.rb +20 -7
- data/lib/asciidoctor/pdf/ext/prawn/extensions.rb +4 -1
- data/lib/asciidoctor/pdf/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 274287402a150ddf26c07f844b1d07cad1e43a7d5174c06c24837564b1da1965
|
|
4
|
+
data.tar.gz: d6039b200512a3e2e3bafe40ec8cb0673694920ebf118fb29b8954e0d0f27d3e
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 030d61aacae9e4327b059bd99690ace9b4d136be54da1ce4715695186e9526589ab43b8d9bf689093c57bd572e4668d09b9b5ac41c5b42b9c48db97d9722335e
|
|
7
|
+
data.tar.gz: af263cfd0d458918f28e9b4ab4a5f79d404e5645fd95e060d055d24429fd7057422886e580c5def7e906a48a1f760f877284dcdfb48ff425e32af37aae5637ee
|
data/CHANGELOG.adoc
CHANGED
|
@@ -5,6 +5,29 @@
|
|
|
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 {url-repo}/commits/main[commit history] on GitHub.
|
|
7
7
|
|
|
8
|
+
== 2.3.24 (2025-11-15) - @mojavelinux
|
|
9
|
+
|
|
10
|
+
Improvements::
|
|
11
|
+
|
|
12
|
+
* bypass any dry run logic if remaining height on page is less than heading font size
|
|
13
|
+
* update import_page method on converter to return true if page was imported (nil otherwise), on par with the functionality of method it replaces
|
|
14
|
+
* limit min toclevels value so it does not cause TOC to be empty (#2619)
|
|
15
|
+
* add checkmark glyph (U+2713) to prose fonts (Noto Serif and Noto Sans) to avoid need for fallback font (#2617)
|
|
16
|
+
|
|
17
|
+
=== Details
|
|
18
|
+
|
|
19
|
+
{url-repo}/releases/tag/v2.3.24[git tag] | {url-repo}/compare/v2.3.23\...v2.3.24[full diff]
|
|
20
|
+
|
|
21
|
+
== 2.3.23 (2025-10-26) - @mojavelinux
|
|
22
|
+
|
|
23
|
+
Bug Fixes::
|
|
24
|
+
|
|
25
|
+
* fix incorrect spacing between entries in horizontal dlist when entry description crosses page boundary (#2614)
|
|
26
|
+
|
|
27
|
+
=== Details
|
|
28
|
+
|
|
29
|
+
{url-repo}/releases/tag/v2.3.23[git tag] | {url-repo}/compare/v2.3.22\...v2.3.23[full diff]
|
|
30
|
+
|
|
8
31
|
== 2.3.22 (2025-10-23) - @mojavelinux
|
|
9
32
|
|
|
10
33
|
Bug Fixes::
|
data/README.adoc
CHANGED
|
@@ -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
|
-
v2.3.
|
|
3
|
+
v2.3.24, 2025-11-15
|
|
4
4
|
// Settings:
|
|
5
5
|
:experimental:
|
|
6
6
|
:idprefix:
|
|
Binary file
|
|
Binary file
|
|
@@ -195,10 +195,10 @@ module Asciidoctor
|
|
|
195
195
|
end if doc.header? && !doc.notitle
|
|
196
196
|
end
|
|
197
197
|
|
|
198
|
-
num_front_matter_pages = toc_page_nums =
|
|
198
|
+
num_front_matter_pages = toc_page_nums = nil
|
|
199
199
|
|
|
200
|
+
toc_num_levels = resolve_toclevels doc
|
|
200
201
|
indent_section do
|
|
201
|
-
toc_num_levels = (doc.attr 'toclevels', 2).to_i
|
|
202
202
|
if (toc_at_top = (doc.attr? 'toc') && !((toc_placement = doc.attr 'toc-placement') == 'macro' || toc_placement == 'preamble') && !(get_entries_for_toc doc).empty?)
|
|
203
203
|
start_new_page if @ppbook && verso_page?
|
|
204
204
|
add_dest_for_block doc, id: 'toc', y: (at_page_top? ? page_height : nil)
|
|
@@ -1505,10 +1505,11 @@ module Asciidoctor
|
|
|
1505
1505
|
indent term_column_width + desc_padding[3], desc_padding[1] do
|
|
1506
1506
|
traverse_list_item desc, :dlist_desc, normalize_line_height: true, margin_bottom: ((next_enclosed_block desc, descend: true) ? nil : 0)
|
|
1507
1507
|
end
|
|
1508
|
+
# ensure cursor is below last term
|
|
1508
1509
|
if page_number < after_term_page_number
|
|
1509
1510
|
go_to_page after_term_page_number
|
|
1510
1511
|
@y = after_term_y
|
|
1511
|
-
elsif y > after_term_y
|
|
1512
|
+
elsif page_number == after_term_page_number && y > after_term_y
|
|
1512
1513
|
@y = after_term_y
|
|
1513
1514
|
end
|
|
1514
1515
|
end
|
|
@@ -2422,7 +2423,7 @@ module Asciidoctor
|
|
|
2422
2423
|
if ((doc = node.document).attr? 'toc-placement', placement) && (doc.attr? 'toc') && !(get_entries_for_toc doc).empty?
|
|
2423
2424
|
start_toc_page node, placement if (is_book = doc.doctype == 'book')
|
|
2424
2425
|
add_dest_for_block node, id: (node.id || 'toc') if is_macro
|
|
2425
|
-
toc_extent = @toc_extent = allocate_toc doc, (doc
|
|
2426
|
+
toc_extent = @toc_extent = allocate_toc doc, (resolve_toclevels doc), cursor, (title_as_page = is_book || (doc.attr? 'title-page'))
|
|
2426
2427
|
if title_as_page
|
|
2427
2428
|
if @theme.page_numbering_start_at == 'toc'
|
|
2428
2429
|
@index.start_page_number = toc_extent.from.page
|
|
@@ -2814,7 +2815,7 @@ module Asciidoctor
|
|
|
2814
2815
|
if ::String === num_levels
|
|
2815
2816
|
if num_levels.include? ':'
|
|
2816
2817
|
num_levels, expand_levels = num_levels.split ':', 2
|
|
2817
|
-
num_levels = num_levels.empty? ? (doc
|
|
2818
|
+
num_levels = num_levels.empty? ? (resolve_toclevels doc) : num_levels.to_i
|
|
2818
2819
|
expand_levels = expand_levels.to_i
|
|
2819
2820
|
else
|
|
2820
2821
|
num_levels = expand_levels = num_levels.to_i
|
|
@@ -2909,6 +2910,11 @@ module Asciidoctor
|
|
|
2909
2910
|
# the next page. This method is not called if the cursor is already at the top of the page or
|
|
2910
2911
|
# whether this node has no node that follows it in document order.
|
|
2911
2912
|
def arrange_heading node, title, opts
|
|
2913
|
+
# quick optimization if font size itself won't fit in remaining space
|
|
2914
|
+
unless theme_font(:heading, level: (hlevel = opts[:level])) { font_size <= cursor }
|
|
2915
|
+
advance_page
|
|
2916
|
+
return
|
|
2917
|
+
end
|
|
2912
2918
|
if (min_height_after = @theme.heading_min_height_after) == 'auto' || (node.option? 'breakable')
|
|
2913
2919
|
orphaned = nil
|
|
2914
2920
|
doc = node.document
|
|
@@ -2916,7 +2922,7 @@ module Asciidoctor
|
|
|
2916
2922
|
dry_run single_page: true do
|
|
2917
2923
|
push_scratch doc
|
|
2918
2924
|
start_page_number ||= page_number # block will be restarted if first attempt fails
|
|
2919
|
-
theme_font :heading, level:
|
|
2925
|
+
theme_font :heading, level: hlevel do
|
|
2920
2926
|
if opts[:part]
|
|
2921
2927
|
ink_part_title node, title, opts
|
|
2922
2928
|
elsif opts[:chapterlike]
|
|
@@ -2936,7 +2942,7 @@ module Asciidoctor
|
|
|
2936
2942
|
end
|
|
2937
2943
|
advance_page if orphaned
|
|
2938
2944
|
else
|
|
2939
|
-
theme_font :heading, level:
|
|
2945
|
+
theme_font :heading, level: hlevel do
|
|
2940
2946
|
if (space_below = ::Numeric === min_height_after ? min_height_after : 0) > 0 && (node.context == :section ? node.blocks? : !node.last_child?)
|
|
2941
2947
|
space_below += @theme[%(heading_h#{hlevel}_margin_bottom)] || @theme.heading_margin_bottom
|
|
2942
2948
|
else
|
|
@@ -3927,6 +3933,13 @@ module Asciidoctor
|
|
|
3927
3933
|
node.sections
|
|
3928
3934
|
end
|
|
3929
3935
|
|
|
3936
|
+
def resolve_toclevels doc
|
|
3937
|
+
if (toc_num_levels = (doc.attr 'toclevels', 2).to_i) < 1
|
|
3938
|
+
toc_num_levels = doc.doctype == 'book' && doc.sections.find {|s| s.sectname == 'part' } ? 0 : 1
|
|
3939
|
+
end
|
|
3940
|
+
toc_num_levels
|
|
3941
|
+
end
|
|
3942
|
+
|
|
3930
3943
|
# NOTE: num_front_matter_pages not used during a dry run
|
|
3931
3944
|
def ink_toc doc, num_levels, toc_page_number, start_cursor, num_front_matter_pages = 0
|
|
3932
3945
|
go_to_page toc_page_number unless (page_number == toc_page_number) || scratch?
|
|
@@ -891,6 +891,8 @@ module Asciidoctor
|
|
|
891
891
|
# However, due to how page creation works in Prawn, understand that advancing
|
|
892
892
|
# to the next page is necessary to prevent the size & layout of the imported
|
|
893
893
|
# page from affecting a newly created page.
|
|
894
|
+
#
|
|
895
|
+
# Returns a Boolean indicating whether the page to import exists and was imported.
|
|
894
896
|
def import_page file, options = {}
|
|
895
897
|
prev_page_layout = page.layout
|
|
896
898
|
prev_page_size = page.size
|
|
@@ -912,6 +914,7 @@ module Asciidoctor
|
|
|
912
914
|
advance_page layout: prev_page_layout, margin: prev_page_margin, size: prev_page_size
|
|
913
915
|
(@bounding_box = prev_bounds).reset_top if ColumnBox === prev_bounds
|
|
914
916
|
end
|
|
917
|
+
imported = true
|
|
915
918
|
elsif options.fetch :advance_if_missing, true
|
|
916
919
|
delete_current_page
|
|
917
920
|
# NOTE: see previous comment
|
|
@@ -920,7 +923,7 @@ module Asciidoctor
|
|
|
920
923
|
else
|
|
921
924
|
delete_current_page
|
|
922
925
|
end
|
|
923
|
-
|
|
926
|
+
imported
|
|
924
927
|
end
|
|
925
928
|
|
|
926
929
|
# Create a new page for the specified image.
|
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: 2.3.
|
|
4
|
+
version: 2.3.24
|
|
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: 2025-
|
|
12
|
+
date: 2025-11-15 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: asciidoctor
|