XHTML2PDF3(1)
π XHTML2PDF3(1) π
okay bestie, pull up a chair, we're learning xhtml2pdf3 β the User Commands girly that turns your HTML and CSS into a whole PDF. yes, really. it's giving β¨magicβ¨ but it's actually just Python.
π NAME π
xhtml2pdf3 β a PDF generator that eats HTML and CSS for breakfast π
β¨ SYNOPSIS β¨
xhtml2pdf3 [-b base path] [--base=base path] [-c CSS file]
[--css=CSS file] [--css-dump] [-d] [--debug]
[--encoding=character encoding] [-h] [--help] [-q] [--quiet]
[--version] [-w] [--warn] [-x] [--xml] [--xhtml] [--html]
[SRC] [DEST]
πΈ DESCRIPTION πΈ
so this manual page? it documents the xhtml2pdf3 command briefly. that's the whole job. π
xhtml2pdf3 is an HTML-to-PDF converter, and it's built on the ReportLab Toolkit, HTML5lib and pyPdf. iconic lineup, no cap.
it supports HTML 5 and CSS 2.1 (plus some of CSS 3 β we get a lil taste π). and the best part? it's completely written in pure Python, so it's platform independent, she goes everywhere. π
the main benefit lowkey, and this is the whole point: if you already have Web skills like HTML and CSS, you can generate PDF templates very quickly without learning a single new technology. yes bestie, your existing brain is enough. and it integrates easily into Python frameworks like CherryPy, KID Templating, TurboGears, Django, Zope, Plone, Google AppEngine (GAE) etc. she's social, she gets along with everyone. π«Ά
π OPTIONS π
a summary of the options is included below, and yes we're doing all of them. no skipping, that's the rule. π
SRCβ the name of a HTML file, or a file pattern using a*placeholder. wanna read from stdin? use-as the file name, queen. you can also load an URL over HTTP like a main character. β οΈ and take care of putting thesrcin quotes if it contains characters like?β those little guys will absolutely cause chaos otherwise. πDESTβ the name of the generated PDF file, or-if you'd like to send the result to stdout, cute. mind that the destination file is not already opened by any other application, like the Adobe Reader β she will not be sharing. π and if the destination isn't writeable, a similar name will be calculated automatically, so don't panic, she'll find a way. β¨-b,--baseβ specify a base path if the input comes in via STDIN. that's it, that's the girl. π-c,--cssβ path to the default CSS file. dress her up. π--css-dumpβ dumps the default CSS definitions to STDOUT. show me the receipts. π-d,--debugβ show debugging information. we love a β¨transparentβ¨ moment.--encodingβ the character encoding ofSRC. if you leave it empty (default), this information will be extracted from the HTML header data. she'll figure it out herself, she's smart like that. π§-h,--helpβ show the help text. when in doubt, ask her. π-q,--quietβ show no messages. silent. mysterious. ethereal. π€«--versionβ show version information. it's giving receipts. π·οΈ-w,--warnβ show warnings. she's not mad, she's just letting you know bestie. π-x,--xml,--xhtmlβ force parsing in XML mode. this is automatically used ifSRCends with.xml. stricter, more structured, very type-A of her. π--htmlβ force parsin in HTML mode (default). the chill, go-with-the-flow option. π
π AUTHOR π
xhtml2pdf3 was written by Dirk Holtwick <<dirk.holtwick@gmail.com>>. thank you king π«‘
this manual page was written by Toby Smithe <<tsmithe@ubuntu.com>>, for the Debian project (but may be used by others). generous! iconic! we stan. π
and that's the whole vibe check bestie πΈ the version tag on this one is pisa, dated 01/29/2026, filed under XHTML2PDF3(1) β go forth and generate those PDFs, you're doing amazing, periodt. π
β¨π
π¦ where this page comes from
- ubuntu resolute: python3-xhtml2pdf 0.2.17+dfsg-1ubuntu2 Β· Apache-2.0
- ubuntu stonking: python3-xhtml2pdf 0.2.17+dfsg-1ubuntu2 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms