We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
<!DOCTYPE document SYSTEM "rml.dtd"> <document filename="example_01.pdf"> <template showBoundary="1"> <!--Debugging is now turned on, frame outlines --> <!--will appear on the page --> <docinit> <registerTTFont faceName="Arial" fileName="./msttcorefonts/arial.ttf" /> <registerTTFont faceName="Arial-Bold" fileName="./msttcorefonts/arialbd.ttf" /> <addMapping faceName="Arial" bold="0" italic="0" pasName="Arial"/> <addMapping faceName="Arial-Bold" bold="1" italic="0" psName="Arial-Bold"/> </docinit> <pageTemplate id="main"> <!-- two frames are defined here: --> <frame id="first" x1="100" y1="400" width="150" height="200"/> <frame id="second" x1="300" y1="400" width="150" height="200"/> </pageTemplate> </template> <stylesheet> <!-- still empty...--> <paraStyle name="Arial" fontName="Arial" fontSize="11" spaceBefore="0.5 cm"/> <paraStyle name="Arial-Bold" fontName="Arial-Bold" fontSize="11" spaceBefore="0.5 cm"/> </stylesheet> <story> <para style="Arial"> Welcome to RML </para> </story> </document>
from reportlab.lib.fonts import addMapping from reportlab.pdfbase.ttfonts import TTFont from reportlab.pdfbase import pdfmetrics from reportlab.pdfbase.ttfonts import TTFont pdfmetrics.registerFont(TTFont("Arial", "./msttcorefonts/Arial.ttf")) pdfmetrics.registerFont(TTFont("Arial-Bold", "./msttcorefonts/arialbd.ttf")) from z3c.rml import rml2pdf addMapping("Arial", 0, 0, "Arial") addMapping("Arial", 0, 1, "Arial") addMapping("Arial", 1, 0, "Arial-Bold") addMapping("Arial", 1, 1, "Arial-Bold") rml2pdf.go("example0.prep", "example_01.pdf")
I have tried move font file in the same dir but still error
Python 3.11.4
Linux ubuntu
The text was updated successfully, but these errors were encountered:
No branches or pull requests
BUG/PROBLEM REPORT / FEATURE REQUEST
What I did:
What actually happened:
What version of Python and Zope/Addons I am using:
Python 3.11.4
Linux ubuntu
The text was updated successfully, but these errors were encountered: