page_print 0.1.11-x86_64-linux → 0.2.1-x86_64-linux
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/README.md +2 -2
- data/docs/configuration.md +2 -0
- data/docs/production.md +1 -1
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-buffer.h +11 -3
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-features.h +1 -1
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-ot-color.h +14 -0
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-paint.h +19 -18
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-version.h +4 -4
- data/lib/page_print/vendor/x86_64-linux/include/plutobook/plutobook.h +14 -11
- data/lib/page_print/vendor/x86_64-linux/include/plutobook/plutobook.hpp +200 -64
- data/lib/page_print/vendor/x86_64-linux/lib/cmake/harfbuzz/harfbuzz-config.cmake +10 -10
- data/lib/page_print/vendor/x86_64-linux/lib/libharfbuzz-icu.a +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libharfbuzz.a +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libplutobook.so.0.20.0 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/pkgconfig/harfbuzz-icu.pc +2 -3
- data/lib/page_print/vendor/x86_64-linux/lib/pkgconfig/harfbuzz.pc +4 -5
- data/lib/page_print/vendor/x86_64-linux/lib/pkgconfig/plutobook.pc +1 -1
- data/lib/page_print/vendor/x86_64-linux/lib/so_aliases +2 -10
- data/lib/page_print/version.rb +1 -1
- metadata +5 -19
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-gobject-enums.h +0 -129
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-gobject-structs.h +0 -136
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-gobject.h +0 -40
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-subset-serialize.h +0 -83
- data/lib/page_print/vendor/x86_64-linux/include/harfbuzz/hb-subset.h +0 -297
- data/lib/page_print/vendor/x86_64-linux/lib/libffi.so.7 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libglib-2.0.so.0 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libgobject-2.0.so.0 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libgraphite2.so.3 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libharfbuzz-gobject.so.0.61230.0 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libharfbuzz-icu.so.0.61230.0 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libharfbuzz-subset.so.0.61230.0 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libharfbuzz.so.0.61230.0 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libpcre.so.3 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/libplutobook.so.0.19.0 +0 -0
- data/lib/page_print/vendor/x86_64-linux/lib/pkgconfig/harfbuzz-gobject.pc +0 -10
- data/lib/page_print/vendor/x86_64-linux/lib/pkgconfig/harfbuzz-subset.pc +0 -11
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 58cf73e529495d5ad81cd0346af3736d342a49fff0b92eb2062131f3ad8d1554
|
|
4
|
+
data.tar.gz: 193b58e7908363fa5f29a973b473d096c853bb6b27ecdeb00d87c51fd3237a01
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: bf65880bd6c6bf1702a6014551918f7f4691c921d806c2b188779867e3d68018d1392ddf95368146fc4a2b1179865da44a95a6c345181fd5644abfa71f368ea5
|
|
7
|
+
data.tar.gz: b55d4600b8248c15078e166ccfab2637ad93a834cb73a4e6dd48579896e2b3002c166a970a2e8f80ecbff9eeacf395894f9cb12e5766977f1e7d95889268e484
|
data/README.md
CHANGED
|
@@ -32,7 +32,7 @@ PDFKit and Wicked PDF are Ruby integrations for `wkhtmltopdf`; their rendering b
|
|
|
32
32
|
| Network access | Denied unless your fetcher supplies the resource | Built in |
|
|
33
33
|
| CSS compatibility | Print-focused and partial; no CSS Grid | Limited by the old WebKit engine |
|
|
34
34
|
| Operational footprint | Native gem and bundled libraries on supported platforms | `wkhtmltopdf` binary plus Qt/WebKit dependencies |
|
|
35
|
-
| Upstream status | PagePrint currently packages PlutoBook 0.
|
|
35
|
+
| Upstream status | PagePrint currently packages PlutoBook 0.20.0 | `wkhtmltopdf` was archived in 2023 |
|
|
36
36
|
|
|
37
37
|
PagePrint is a strong fit when you control the templates, value predictable print layout, and do not need JavaScript. Stay with a `wkhtmltopdf`-based gem if your existing templates depend on its JavaScript or WebKit-specific rendering behavior. When migrating, compare representative output carefully because changing engines can alter pagination, fonts, and layout.
|
|
38
38
|
|
|
@@ -55,7 +55,7 @@ bundle install
|
|
|
55
55
|
PagePrint requires Ruby 3.2 or newer. Native gems with vendored PlutoBook libraries are published for:
|
|
56
56
|
|
|
57
57
|
- `x86_64-linux`
|
|
58
|
-
- `arm64-darwin` (Apple Silicon)
|
|
58
|
+
- `arm64-darwin` (Apple Silicon, macOS 15 or newer)
|
|
59
59
|
|
|
60
60
|
Other platforms build from source and require PlutoBook development headers and libraries. See [Installing on other platforms](docs/production.md#installing-on-other-platforms).
|
|
61
61
|
|
data/docs/configuration.md
CHANGED
|
@@ -48,6 +48,8 @@ PagePrint.render(html, base_url: "https://example.test", resource_fetcher: fetch
|
|
|
48
48
|
|
|
49
49
|
The fetcher receives `https://example.test/assets/report.css`. A base URL resolves the URL; it does not enable network access.
|
|
50
50
|
|
|
51
|
+
With PlutoBook 0.20.0, relative resource URLs no longer resolve against the process working directory when no base URL is supplied. Use an explicit absolute base URL, such as `https://example.test/assets/` or `file:///absolute/assets/`, with a trailing slash for a directory.
|
|
52
|
+
|
|
51
53
|
Set an application-wide default when rendering outside Rails:
|
|
52
54
|
|
|
53
55
|
```ruby
|
data/docs/production.md
CHANGED
|
@@ -23,7 +23,7 @@ PagePrint requires Ruby 3.2 or newer.
|
|
|
23
23
|
| Platform | Installation |
|
|
24
24
|
| --- | --- |
|
|
25
25
|
| `x86_64-linux` | Native gem with vendored PlutoBook libraries; the Ruby extension is compiled against the local Ruby |
|
|
26
|
-
| `arm64-darwin` | Native gem with vendored PlutoBook libraries; the Ruby extension is compiled against the local Ruby |
|
|
26
|
+
| `arm64-darwin` (macOS 15 or newer) | Native gem with vendored PlutoBook libraries; the Ruby extension is compiled against the local Ruby |
|
|
27
27
|
| Other platforms | Source build using an installed PlutoBook |
|
|
28
28
|
|
|
29
29
|
The published native gems disable PlutoBook's optional curl, TurboJPEG, and WebP features to keep the bundled dependency set smaller. PagePrint uses its own Ruby resource fetcher boundary and does not expose PlutoBook's optional network fetcher.
|
|
@@ -495,7 +495,7 @@ typedef enum {
|
|
|
495
495
|
(1u << HB_BUFFER_CLUSTER_LEVEL_GRAPHEMES))))
|
|
496
496
|
|
|
497
497
|
/**
|
|
498
|
-
* HB_BUFFER_CLUSTER_LEVEL_IS_CHARACTERS
|
|
498
|
+
* HB_BUFFER_CLUSTER_LEVEL_IS_CHARACTERS:
|
|
499
499
|
* @level: #hb_buffer_cluster_level_t to test
|
|
500
500
|
*
|
|
501
501
|
* Tests whether a cluster level does not group cluster values by graphemes.
|
|
@@ -505,7 +505,7 @@ typedef enum {
|
|
|
505
505
|
*/
|
|
506
506
|
#define HB_BUFFER_CLUSTER_LEVEL_IS_CHARACTERS(level) \
|
|
507
507
|
((bool) ((1u << (unsigned) (level)) & \
|
|
508
|
-
((1u <<
|
|
508
|
+
((1u << HB_BUFFER_CLUSTER_LEVEL_MONOTONE_CHARACTERS) | \
|
|
509
509
|
(1u << HB_BUFFER_CLUSTER_LEVEL_CHARACTERS))))
|
|
510
510
|
|
|
511
511
|
HB_EXTERN void
|
|
@@ -672,7 +672,12 @@ hb_buffer_normalize_glyphs (hb_buffer_t *buffer);
|
|
|
672
672
|
* @HB_BUFFER_SERIALIZE_FLAG_GLYPH_EXTENTS: serialize glyph extents.
|
|
673
673
|
* @HB_BUFFER_SERIALIZE_FLAG_GLYPH_FLAGS: serialize glyph flags. Since: 1.5.0
|
|
674
674
|
* @HB_BUFFER_SERIALIZE_FLAG_NO_ADVANCES: do not serialize glyph advances,
|
|
675
|
-
* glyph offsets will reflect absolute glyph positions. Since: 1.8.0
|
|
675
|
+
* glyph offsets will reflect absolute glyph positions. Since: 1.8.0.
|
|
676
|
+
* Note: when this flag is used with a partial range of the buffer (i.e.
|
|
677
|
+
* @start is not 0), calculating the absolute positions has a cost
|
|
678
|
+
* proportional to @start. If the buffer is serialized in many small
|
|
679
|
+
* chunks, this can lead to quadratic behavior. It is recommended to
|
|
680
|
+
* use a larger @buf_size to minimize this cost.
|
|
676
681
|
* @HB_BUFFER_SERIALIZE_FLAG_DEFINED: All currently defined flags. Since: 4.4.0
|
|
677
682
|
*
|
|
678
683
|
* Flags that control what glyph information are serialized in hb_buffer_serialize_glyphs().
|
|
@@ -865,6 +870,9 @@ hb_buffer_set_message_func (hb_buffer_t *buffer,
|
|
|
865
870
|
hb_buffer_message_func_t func,
|
|
866
871
|
void *user_data, hb_destroy_func_t destroy);
|
|
867
872
|
|
|
873
|
+
HB_EXTERN void
|
|
874
|
+
hb_buffer_changed (hb_buffer_t *buffer);
|
|
875
|
+
|
|
868
876
|
|
|
869
877
|
HB_END_DECLS
|
|
870
878
|
|
|
@@ -136,6 +136,20 @@ hb_ot_color_glyph_has_paint (hb_face_t *face,
|
|
|
136
136
|
HB_EXTERN hb_bool_t
|
|
137
137
|
hb_ot_color_has_svg (hb_face_t *face);
|
|
138
138
|
|
|
139
|
+
HB_EXTERN unsigned int
|
|
140
|
+
hb_ot_color_get_svg_document_count (hb_face_t *face);
|
|
141
|
+
|
|
142
|
+
HB_EXTERN hb_bool_t
|
|
143
|
+
hb_ot_color_glyph_get_svg_document_index (hb_face_t *face,
|
|
144
|
+
hb_codepoint_t glyph,
|
|
145
|
+
unsigned int *svg_document_index /* OUT */);
|
|
146
|
+
|
|
147
|
+
HB_EXTERN hb_bool_t
|
|
148
|
+
hb_ot_color_get_svg_document_glyph_range (hb_face_t *face,
|
|
149
|
+
unsigned int svg_document_index,
|
|
150
|
+
hb_codepoint_t *start_glyph_id, /* OUT */
|
|
151
|
+
hb_codepoint_t *end_glyph_id /* OUT */);
|
|
152
|
+
|
|
139
153
|
HB_EXTERN hb_blob_t *
|
|
140
154
|
hb_ot_color_glyph_reference_svg (hb_face_t *face, hb_codepoint_t glyph);
|
|
141
155
|
|
|
@@ -684,23 +684,24 @@ typedef void (*hb_paint_pop_group_func_t) (hb_paint_funcs_t *funcs,
|
|
|
684
684
|
|
|
685
685
|
/**
|
|
686
686
|
* hb_paint_custom_palette_color_func_t:
|
|
687
|
-
* @funcs: paint functions object
|
|
688
|
-
* @paint_data:
|
|
689
|
-
* @color_index:
|
|
690
|
-
* @color: (out): fetched color
|
|
691
|
-
* @user_data:
|
|
687
|
+
* @funcs: paint functions object.
|
|
688
|
+
* @paint_data: data accompanying the paint functions in hb_font_paint_glyph().
|
|
689
|
+
* @color_index: color index to fetch.
|
|
690
|
+
* @color: (out): fetched color.
|
|
691
|
+
* @user_data: user data pointer passed to hb_paint_funcs_set_custom_palette_color_func().
|
|
692
692
|
*
|
|
693
|
-
* A virtual method for
|
|
694
|
-
* color
|
|
693
|
+
* A virtual method for #hb_paint_funcs_t to fetch a custom palette override
|
|
694
|
+
* color for @color_index.
|
|
695
695
|
*
|
|
696
|
-
* Custom palette colors override
|
|
697
|
-
*
|
|
698
|
-
* that should be taken from the font palette
|
|
696
|
+
* Custom palette colors override colors from the font's selected color palette.
|
|
697
|
+
* It is not necessary to override all palette entries; return `false` for
|
|
698
|
+
* entries that should be taken from the font palette.
|
|
699
699
|
*
|
|
700
|
-
* This function might
|
|
701
|
-
* expected to remain unchanged for duration of
|
|
700
|
+
* This function might be called multiple times, but the custom palette is
|
|
701
|
+
* expected to remain unchanged for the duration of one
|
|
702
|
+
* hb_font_paint_glyph() call.
|
|
702
703
|
*
|
|
703
|
-
* Return value: `true` if
|
|
704
|
+
* Return value: `true` if a custom color is provided, `false` otherwise.
|
|
704
705
|
*
|
|
705
706
|
* Since: 7.0.0
|
|
706
707
|
*/
|
|
@@ -934,12 +935,12 @@ hb_paint_funcs_set_pop_group_func (hb_paint_funcs_t *funcs,
|
|
|
934
935
|
|
|
935
936
|
/**
|
|
936
937
|
* hb_paint_funcs_set_custom_palette_color_func:
|
|
937
|
-
* @funcs:
|
|
938
|
-
* @func: (closure user_data) (destroy destroy) (scope notified):
|
|
939
|
-
* @user_data:
|
|
940
|
-
* @destroy: (nullable):
|
|
938
|
+
* @funcs: a paint functions struct.
|
|
939
|
+
* @func: (closure user_data) (destroy destroy) (scope notified): custom-palette-color callback.
|
|
940
|
+
* @user_data: data to pass to @func.
|
|
941
|
+
* @destroy: (nullable): function to call when @user_data is no longer needed.
|
|
941
942
|
*
|
|
942
|
-
* Sets the custom-palette-color callback on
|
|
943
|
+
* Sets the custom-palette-color callback on @funcs.
|
|
943
944
|
*
|
|
944
945
|
* Since: 7.0.0
|
|
945
946
|
*/
|
|
@@ -41,26 +41,26 @@ HB_BEGIN_DECLS
|
|
|
41
41
|
*
|
|
42
42
|
* The major component of the library version available at compile-time.
|
|
43
43
|
*/
|
|
44
|
-
#define HB_VERSION_MAJOR
|
|
44
|
+
#define HB_VERSION_MAJOR 13
|
|
45
45
|
/**
|
|
46
46
|
* HB_VERSION_MINOR:
|
|
47
47
|
*
|
|
48
48
|
* The minor component of the library version available at compile-time.
|
|
49
49
|
*/
|
|
50
|
-
#define HB_VERSION_MINOR
|
|
50
|
+
#define HB_VERSION_MINOR 0
|
|
51
51
|
/**
|
|
52
52
|
* HB_VERSION_MICRO:
|
|
53
53
|
*
|
|
54
54
|
* The micro component of the library version available at compile-time.
|
|
55
55
|
*/
|
|
56
|
-
#define HB_VERSION_MICRO
|
|
56
|
+
#define HB_VERSION_MICRO 1
|
|
57
57
|
|
|
58
58
|
/**
|
|
59
59
|
* HB_VERSION_STRING:
|
|
60
60
|
*
|
|
61
61
|
* A string literal containing the library version available at compile-time.
|
|
62
62
|
*/
|
|
63
|
-
#define HB_VERSION_STRING "
|
|
63
|
+
#define HB_VERSION_STRING "13.0.1"
|
|
64
64
|
|
|
65
65
|
/**
|
|
66
66
|
* HB_VERSION_ATLEAST:
|
|
@@ -38,8 +38,11 @@ extern "C" {
|
|
|
38
38
|
#define PLUTOBOOK_PRINTF_FORMAT(fmt_index, va_index)
|
|
39
39
|
#endif
|
|
40
40
|
|
|
41
|
+
#define PLUTOBOOK_XSTRINGIZE(x) #x
|
|
42
|
+
#define PLUTOBOOK_STRINGIZE(x) PLUTOBOOK_XSTRINGIZE(x)
|
|
43
|
+
|
|
41
44
|
#define PLUTOBOOK_VERSION_MAJOR 0
|
|
42
|
-
#define PLUTOBOOK_VERSION_MINOR
|
|
45
|
+
#define PLUTOBOOK_VERSION_MINOR 20
|
|
43
46
|
#define PLUTOBOOK_VERSION_MICRO 0
|
|
44
47
|
|
|
45
48
|
#define PLUTOBOOK_VERSION_ENCODE(major, minor, micro) (((major) * 10000) + ((minor) * 100) + ((micro) * 1))
|
|
@@ -476,8 +479,8 @@ PLUTOBOOK_API plutobook_canvas_t* plutobook_pdf_canvas_create_for_stream(
|
|
|
476
479
|
* An optional timezone of the form "[+/-]hh:mm" or "Z" for UTC time can be appended. All other metadata values can be any string.
|
|
477
480
|
*
|
|
478
481
|
* @param canvas A pointer to a `plutobook_canvas_t` object.
|
|
479
|
-
* @param metadata The metadata
|
|
480
|
-
* @param value The value of the metadata field.
|
|
482
|
+
* @param metadata The metadata field to set.
|
|
483
|
+
* @param value The value of the metadata field, or `NULL` to unset it.
|
|
481
484
|
*/
|
|
482
485
|
PLUTOBOOK_API void plutobook_pdf_canvas_set_metadata(plutobook_canvas_t* canvas, plutobook_pdf_metadata_t metadata, const char* value);
|
|
483
486
|
|
|
@@ -730,17 +733,17 @@ PLUTOBOOK_API void plutobook_clear_content(plutobook_t* book);
|
|
|
730
733
|
* An optional timezone of the form "[+/-]hh:mm" or "Z" for UTC time can be appended. All other metadata values can be any string.
|
|
731
734
|
*
|
|
732
735
|
* @param book A pointer to a `plutobook_t` object.
|
|
733
|
-
* @param metadata The metadata
|
|
734
|
-
* @param value The value of the metadata field.
|
|
736
|
+
* @param metadata The metadata field to set.
|
|
737
|
+
* @param value The value of the metadata field, or `NULL` to unset it.
|
|
735
738
|
*/
|
|
736
739
|
PLUTOBOOK_API void plutobook_set_metadata(plutobook_t* book, plutobook_pdf_metadata_t metadata, const char* value);
|
|
737
740
|
|
|
738
741
|
/**
|
|
739
|
-
* @brief Gets the value of the
|
|
742
|
+
* @brief Gets the value of the metadata field.
|
|
740
743
|
*
|
|
741
744
|
* @param book A pointer to a `plutobook_t` object.
|
|
742
|
-
* @param metadata The
|
|
743
|
-
* @return The value of the
|
|
745
|
+
* @param metadata The metadata field to get.
|
|
746
|
+
* @return The value of the metadata field, or `NULL` if it is not set.
|
|
744
747
|
*/
|
|
745
748
|
PLUTOBOOK_API const char* plutobook_get_metadata(const plutobook_t* book, plutobook_pdf_metadata_t metadata);
|
|
746
749
|
|
|
@@ -918,7 +921,7 @@ PLUTOBOOK_API void plutobook_render_document(const plutobook_t* book, plutobook_
|
|
|
918
921
|
* @brief Renders the entire document to the given cairo context.
|
|
919
922
|
*
|
|
920
923
|
* @param book A pointer to a `plutobook_t` object.
|
|
921
|
-
* @param
|
|
924
|
+
* @param context The cairo context to render the entire document on.
|
|
922
925
|
*/
|
|
923
926
|
PLUTOBOOK_API void plutobook_render_document_cairo(const plutobook_t* book, cairo_t* context);
|
|
924
927
|
|
|
@@ -939,7 +942,7 @@ PLUTOBOOK_API void plutobook_render_document_rect(const plutobook_t* book, pluto
|
|
|
939
942
|
* @brief Renders a specific rectangular portion of the document to the given cairo context.
|
|
940
943
|
*
|
|
941
944
|
* @param book A pointer to a `plutobook_t` object.
|
|
942
|
-
* @param
|
|
945
|
+
* @param context The cairo context to render the document portion on.
|
|
943
946
|
* @param x The x-coordinate of the top-left corner of the rectangle.
|
|
944
947
|
* @param y The y-coordinate of the top-left corner of the rectangle.
|
|
945
948
|
* @param width The width of the rectangle to render.
|
|
@@ -1076,7 +1079,7 @@ PLUTOBOOK_API void plutobook_set_error_message(const char* format, ...) PLUTOBOO
|
|
|
1076
1079
|
PLUTOBOOK_API const char* plutobook_get_error_message(void);
|
|
1077
1080
|
|
|
1078
1081
|
/**
|
|
1079
|
-
* @brief
|
|
1082
|
+
* @brief Clears any previously set error message for the current thread.
|
|
1080
1083
|
*/
|
|
1081
1084
|
PLUTOBOOK_API void plutobook_clear_error_message(void);
|
|
1082
1085
|
|