2

I want something like this:

desired

but all I can do is this:

actual

I'm using the following code:

\documentclass{article}
\usepackage{menukeys}
\begin{document}
\sffamily
When you see \menu{File>Save}, it means to click on the \menu{File} menu item then on the \menu{Save} submenu item.
\end{document}

What do I need to do to get the output I want?

1 Answer 1

2

As far as I can see, the package does not support these features out of the box. But it uses TikZ, so it is easy to "hack". For your convenience, I added a command \Menu, which takes an optional argument that allows you to add these features. Let me stress that it will be easy to add tons of further features (just let me know) but at the moment the keys are t> for the arrow on the right side, and >t for the arrow on the left.

\documentclass{article}
\usepackage{menukeys}
\makeatletter
\tikzset{menu hack/.cd,
t>/.code={\tikzset{tw@menus@base/.append style={signal to=east}}},
>t/.code={\tikzset{tw@menus@base/.append style={signal from=west}}}}
\newcommand{\Menu}[2][]{\begingroup%
\tikzset{menu hack/.cd,#1}%
\menu{#2}%
\endgroup}
\makeatother
\begin{document}
\sffamily
When you see \menu{File>Save}, it means to click on the 
\Menu[t>]{File} menu item then on the \Menu[>t]{Save} submenu item.
\end{document}

enter image description here

2
  • Wow! Thank you very much for this! I'll upvote and accept this answer when I am able to.
    – user338955
    Commented Nov 8, 2019 at 1:08
  • @user338955 You're welcome!
    – user194703
    Commented Nov 8, 2019 at 1:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .