I'm trying to write some hebrew words to a PDF file using the PDF Library in Python
and I'm getting an error
UnicodeEncodeError: 'latin-1' codec can't encode characters in position 51-55: ordinal not in range(256) How can I fix that and write hebrew to the PDF file?
from fpdf import FPDF
pdf = FPDF()
pdf.add_page()
uni=True
pdf.set_font("Arial", size=15)
welcome=u"היייי"
pdf.cell(200, 10, txt=welcome, ln=1, align="C")
pdf.output("simple_demo.pdf")