From 81b1cc00e70572d62cfd2a0d383e8d08e3042cb1 Mon Sep 17 00:00:00 2001 From: Lucas Cimon <925560+Lucas-C@users.noreply.github.com> Date: Fri, 11 Oct 2024 13:52:40 +0200 Subject: [PATCH] Minor fixups in docs --- docs/HTML.md | 4 ++-- docs/Shapes.md | 2 +- docs/Templates.md | 2 +- fpdf/fonts.py | 2 +- fpdf/fpdf.py | 2 +- fpdf/html.py | 4 ++-- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/docs/HTML.md b/docs/HTML.md index f6d7ee12a..cb0d7db0a 100644 --- a/docs/HTML.md +++ b/docs/HTML.md @@ -133,7 +133,7 @@ However, **Pull Request are welcome** to implement missing features! ### Default font -_New in [:octicons-tag-24: 2.7.10](https://github.com/py-pdf/fpdf2/blob/master/CHANGELOG.md)_ +_New in [:octicons-tag-24: 2.8.0](https://github.com/py-pdf/fpdf2/blob/master/CHANGELOG.md)_ The default font used by [`FPDF.write_html()`](https://py-pdf.github.io/fpdf2/fpdf/fpdf.html#fpdf.fpdf.FPDF.write_html) is **Times**. @@ -178,7 +178,7 @@ pdf.output("html_helvetica.pdf") ### Page breaks -_New in [:octicons-tag-24: 2.7.10](https://github.com/py-pdf/fpdf2/blob/master/CHANGELOG.md)_ +_New in [:octicons-tag-24: 2.8.0](https://github.com/py-pdf/fpdf2/blob/master/CHANGELOG.md)_ Page breaks can be triggered explicitly using the [break-before](https://developer.mozilla.org/en-US/docs/Web/CSS/break-before) or [break-after](https://developer.mozilla.org/en-US/docs/Web/CSS/break-after) CSS properties. For exemple you can use: diff --git a/docs/Shapes.md b/docs/Shapes.md index 89e14f2e4..e59ed6701 100644 --- a/docs/Shapes.md +++ b/docs/Shapes.md @@ -164,7 +164,7 @@ pdf.output("solid_arc.pdf") ![](solid_arc.png) ## Bezier Curve ## -_New in [:octicons-tag-24: 2.7.10](https://github.com/py-pdf/fpdf2/blob/master/CHANGELOG.md)_ +_New in [:octicons-tag-24: 2.8.0](https://github.com/py-pdf/fpdf2/blob/master/CHANGELOG.md)_ Using [`bezier()`](fpdf/fpdf.html#fpdf.fpdf.FPDF.bezier) to create a cubic Bézier curve: ```python diff --git a/docs/Templates.md b/docs/Templates.md index e9f53d907..e487fbbc0 100644 --- a/docs/Templates.md +++ b/docs/Templates.md @@ -265,7 +265,7 @@ f.render("./template.pdf") See template.py or [Web2Py] (Web2Py.md) for a complete example. # Example - Elements defined in JSON file # -_New in [:octicons-tag-24: 2.7.10](https://github.com/py-pdf/fpdf2/blob/master/CHANGELOG.md)_ +_New in [:octicons-tag-24: 2.8.0](https://github.com/py-pdf/fpdf2/blob/master/CHANGELOG.md)_ The JSON file must consist of an array of objects. Each object with its name/value pairs define a template element: diff --git a/fpdf/fonts.py b/fpdf/fonts.py index f62cc84a1..d7ff1194a 100644 --- a/fpdf/fonts.py +++ b/fpdf/fonts.py @@ -173,7 +173,7 @@ class TitleStyle(TextStyle): def __init__(self, *args, **kwargs): warnings.warn( ( - "fpdf.TitleStyle is deprecated since 2.7.10." + "fpdf.TitleStyle is deprecated since 2.8.0." " It has been replaced by fpdf.TextStyle." ), DeprecationWarning, diff --git a/fpdf/fpdf.py b/fpdf/fpdf.py index 7a7ff043e..326c1db95 100644 --- a/fpdf/fpdf.py +++ b/fpdf/fpdf.py @@ -400,7 +400,7 @@ def write_html(self, text, *args, **kwargs): pre_code_font (str): [**DEPRECATED since v2.7.9**] font to use for `
` & `` blocks - Set `tag_styles` instead
warn_on_tags_not_matching (bool): control warnings production for unmatched HTML tags. Defaults to `True`.
- tag_indents (dict): [**DEPRECATED since v2.7.10**]
+ tag_indents (dict): [**DEPRECATED since v2.8.0**]
mapping of HTML tag names to numeric values representing their horizontal left identation. - Set `tag_styles` instead
tag_styles (dict[str, fpdf.fonts.TextStyle]): mapping of HTML tag names to `fpdf.TextStyle` or `fpdf.FontFace` instances
"""
diff --git a/fpdf/html.py b/fpdf/html.py
index 3f0256caf..08706f768 100644
--- a/fpdf/html.py
+++ b/fpdf/html.py
@@ -335,7 +335,7 @@ def __init__(
pre_code_font (str): [**DEPRECATED since v2.7.9**]
font to use for `` & `` blocks - Set `tag_styles` instead
warn_on_tags_not_matching (bool): control warnings production for unmatched HTML tags. Defaults to `True`.
- tag_indents (dict): [**DEPRECATED since v2.7.10**]
+ tag_indents (dict): [**DEPRECATED since v2.8.0**]
mapping of HTML tag names to numeric values representing their horizontal left identation. - Set `tag_styles` instead
tag_styles (dict[str, fpdf.fonts.TextStyle]): mapping of HTML tag names to `fpdf.TextStyle` or `fpdf.FontFace` instances
font_family (str): optional font family. Default to Times.
@@ -476,7 +476,7 @@ def __init__(
if tag_indents:
warnings.warn(
(
- "The tag_indents parameter is deprecated since v2.7.10 "
+ "The tag_indents parameter is deprecated since v2.8.0 "
"and will be removed in a future release. "
"Set the `tag_styles` parameter instead."
),