Skip to content

Commit 195ecd4

Browse files
committed
Upgrade calls to fpdf2 to avoid mypy errors
1 parent 6921079 commit 195ecd4

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

020-xmp/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
pdf = FPDF()
1010
pdf.add_page()
1111
pdf.set_font("Helvetica", size=12)
12-
pdf.cell(200, 10, txt="Hello, World!", ln=1, align="C")
12+
pdf.cell(200, 10, text="Hello, World!", align="C", new_x="LMARGIN", new_y="NEXT")
1313
pdf.output(name=output)
1414
output.seek(0)
1515

024-annotations/create_annotated_pdf.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
pdf.add_page()
1212
pdf.set_font("Helvetica", size=24)
1313

14-
pdf.text(x=10, y=20, txt="Some text.")
14+
pdf.text(x=10, y=20, text="Some text.")
1515
pdf.text_annotation(
1616
x=60,
1717
y=20,
@@ -21,8 +21,8 @@
2121
with pdf.highlight("Highlight comment"):
2222
pdf.text(50, 50, "Line 1")
2323
pdf.set_y(50)
24-
pdf.multi_cell(w=30, txt="Line 2")
25-
pdf.cell(w=60, txt="Not highlighted", border=1)
24+
pdf.multi_cell(w=30, text="Line 2")
25+
pdf.cell(w=60, text="Not highlighted", border=1)
2626

2727

2828
pdf.ink_annotation(

0 commit comments

Comments
 (0)