Custom hover documentation for Latex command in VS code with Latex Workshop extension

11 views Asked by At

Have a custom command with 7 arguments. It works perfectly for my application. I would like to however have a hover box appear that shows "\tab{colDef}{titleRow}{Rows}[Caption][Label][Width][align]" when my curser hovers over the command, so I can easily recall the arguments as I am implementing it. I have latex and latex workshop successfully installed on my pc. The hover command works for predefined functions. Thanks!

\NewDocumentCommand{\tab}{m >{\SplitList{,}}m >{\SplitList{,}}m o o O{\dimWidth} O{htbp}}{
    \vspace{-15pt}
    \begin{table}[#7] 
        \centering
        \color{accent2}
        \IfValueT{#4}{\textbf{\caption{#4}}}
        \vspace{\the\dimC}
        \normalcolor
        \begin{tabularx}{#6\textwidth}{#1}
            \ProcessList{#2}{\tabtitle} \\
            \hline
            \ProcessList{#3}{\tabrow}
        \end{tabularx}
        \IfValueT{#5}{\label{#5}}
    \end{table}
}

For now I have put the comment here

\NewDocumentCommand{\tab}{m >{\SplitList{,}}m >{\SplitList{,}}m o o O{\dimWidth} O{htbp}}{% \tab{colDef}{titleRow}{Rows}[Caption][Label][Width][align]
0

There are 0 answers