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 🫢🌈