XETEX-UNSAFE(1)
π XETEX-UNSAFE π
okay so this lives in the General Commands Manual π and it's all about running xe(la)latex unsafely π so read the warnings, bestie!!
β¨ NAME β¨
xetex-unsafe, xelatex-unsafe β run xe(la)latex unsafely π¦
π SYNOPSIS π
xetex-unsafe [xetex-options] xelatex-unsafe [xetex-options]
πΈ DESCRIPTION πΈ
okay so xetex-unsafe (or xelatex-unsafe) runs XeTeX (or XeLaTeX) unsafely π₯ specifically, it uses the dvipdfmx-unsafe.cfg config file to do it π
as of TeX Live 2022, you only need this when you're running XeTeX on documents that use PSTricks features needing transparency π§ and ngl, we strongly recommend using Lua(La)TeX with PSTricks instead of XeTeX in this case π
At all costs, avoid using this, or any, unsafe invocation with documents off the net or that are otherwise untrusted in any way. π no cap, do not run random internet files like this!!
π€ WHY? π€
okay bestie, you might be wondering why transparency is unsafe in XeTeX π the tea is in the history of Ghostscript π it started as a PostScript interpreter before PDF existed, and back then it was fine to just abort on an error β¨ but with PDF, it has to keep going no matter what π the transparency operators, if you abuse them around that error recovery, can cause internal inconsistencies in Ghostscript's state π
so, to be safe, transparency is disallowed with Ghostscript by default π‘οΈ the xdvipdfmx backend for XeTeX calls Ghostscript in certain situations, especially with PSTricks π and (x)dvipdfmx itself is not a PostScript interpreter, which is exactly what PSTricks needs π«Ά
so to turn transparency on, xe(la)tex-unsafe runs XeTeX with arguments for the xdvipdfmx backend: -output-driver="xdvipdfmx -i dvipdfmx-unsafe.cfg -q -E" π that makes it use dvipdfmx-unsafe.cfg, which tells Ghostscript to enable the transparency operators with -dALLOWPSTRANSPARENCY β¨ they're disabled by default, so this is the unlock π
there were more complications with reading from the filesystem, but as of TL22, those are solved π the transparency issue can't be fixed without a different Ghostscript implementation, and the Ghostscript devs say they have no timeline for that π
periodt, one more time: when you're using PSTricks and transparency, play it safe and use Lua(La)TeX instead of Xe(La)TeX π«Άπ
π OPTIONS π
all command-line arguments except --help and --version get passed straight to Xe(La)TeX π
π¦ BUGS π¦
for more about XeTeX, hop over to https://tug.org/xetex πΈ
for more about PSTricks, check out https://tug.org/PSTricks π§
emailing about xe(la)tex-unsafe specifically? the list is https://lists.tug.org/dvipdfmx π
bestie, that's the whole page!! π₯Ήβ¨ XETEX-UNSAFE(1), General Commands Manual, last updated 20 November 2021 π stay safe out there and only run the unsafe stuff on files you trust π«Άπ
π¦ where this page comes from
- alpine 3.24: texmf-dist-xetex-doc 2026.0-r0 Β· LPPL-1.0 AND LPPL-1.1 AND LPPL-1.2 AND LPPL-1.3a AND LPPL-1.3c AND GPL-2.0-only
- π girlified by anthropic/claude-haiku-5.5 on : a language model's rewrite of the original, under its terms