Skip to content

Commit aaa3e80

Browse files
committed
Introducing TextRendererMixin
1 parent 61f3765 commit aaa3e80

16 files changed

+863
-795
lines changed

.github/workflows/continuous-integration-workflow.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ jobs:
149149
sed -i "s/author:.*/author: v$(python setup.py -V 2>/dev/null)/" mkdocs.yml
150150
cp tutorial/notebook.ipynb docs/
151151
mkdocs build
152-
pdoc --html -o public/ fpdf --config "git_link_template='https://github.com/py-pdf/fpdf2/blob/{commit}/{path}#L{start_line}-L{end_line}'"
152+
pdoc --html -o public/ fpdf --template-dir docs/pdoc
153153
scripts/add_pdoc_to_search_index.py
154154
- name: Build contributors map 🗺️
155155
# As build_contributors_html_page.py can hang due to GitHub rate-limiting, we only execute this on master for now

docs/Development.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ To preview the Markdown documentation, launch a local rendering server with:
240240

241241
To preview the API documentation, launch a local rendering server with:
242242

243-
pdoc --html -o public/ fpdf --http :
243+
pdoc --html -o public/ fpdf --template-dir docs/pdoc --http :
244244

245245
## PDF spec & new features
246246
The **PDF 1.7 spec** is available on Adobe website:

docs/Internals.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,4 +94,5 @@ drawing.py & svg.py packages
9494
9595
## Text shaping ?
9696
97+
+ add a diagram of the main links between modules/classes
9798
-->

docs/pdoc/config.mako

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<%!
2+
# pdoc configuration
3+
# * Doc: https://pdoc3.github.io/pdoc/doc/pdoc/#custom-templates
4+
# * Defaults: https://github.com/pdoc3/pdoc/blob/master/pdoc/templates/config.mako
5+
git_link_template = 'https://github.com/py-pdf/fpdf2/blob/{commit}/{path}#L{start_line}-L{end_line}'
6+
show_inherited_members = True
7+
%>

fpdf/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,12 @@
2424
from .fpdf import (
2525
FPDF,
2626
TitleStyle,
27-
FPDF_FONT_DIR as _FPDF_FONT_DIR,
2827
FPDF_VERSION as _FPDF_VERSION,
2928
)
3029
from .html import HTMLMixin, HTML2FPDF
3130
from .prefs import ViewerPreferences
3231
from .template import Template, FlexTemplate
32+
from .text_renderer import FPDF_FONT_DIR as _FPDF_FONT_DIR
3333
from .util import get_scale_factor
3434

3535
try:

fpdf/fonts.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def __deepcopy__(self, _memo):
3333

3434
from .deprecation import get_stack_level
3535
from .drawing import convert_to_device_color, DeviceGray, DeviceRGB
36-
from .enums import FontDescriptorFlags, TextEmphasis, Align
36+
from .enums import Align, FontDescriptorFlags, TextEmphasis
3737
from .syntax import Name, PDFObject
3838
from .util import escape_parens
3939

0 commit comments

Comments
 (0)