A user of menukeys reported (GutHub issue #48) that there is an extra space before hyphens in a directory sequence, when the input separator is a back slash:
\documentclass{article}
\usepackage{menukeys}
\begin{document}
this: \directory[bslash]{c:\temp\dir-dir} (extra space before \verb|-|)
should be the same as this: \directory[/]{c:/temp/dir-dir}
\end{document}
Unfortunately I have no idea how to solve it. Any ideas here in the community?
\dir -dir. But I can't tell you if it is a catoptions bug or if you are using it in a wrong way. Neither the menukeys code nor the catoptions code is really comprehensible, and catoptions has no docu. As a work-around you can give the hyphen (and the other chars affected by the same problem) locally letter catcode. – Ulrike Fischer Sep 14 '17 at 18:09