TransWikia.com

path{} command and blank spaces

TeX - LaTeX Asked by blank space on February 25, 2021

The document that I am writing includes lots of paths to files. Many of them have blank spaces that I am powerless to remove since they originate outside of my domain of control. But the path{} command that this document uses actually butchers those paths by removing blank spaces. path{C:My Documents} outputs MyDocuments`. I am not sure who thought that it was a good idea or even acceptable to alter the command’s argument.

I cannot simply switch to texttt{} because this would require escaping lots of backslashes, underscores, dollar signs, etc, all over the document.

How can I fix the result of the path{} command?

One Answer

documentclass{article}
usepackage[obeyspaces]{url} %before hyperref if hyperref is used
usepackage{hyperref}
begin{document}

path{C:My Documents}

end{document}

enter image description here

Answered by Ulrike Fischer on February 25, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP