I've written the following snippet to work with the description environment under LaTeX.
`description= \begin{description}\n%ws%\item %cursor%\n\end{description}`
However, when I try to use it, it results in :
``` \begin \item \end ```
Which is not expected. Other snippets, like
`enumerate=\begin{enumerate}\n%ws%\item %cursor%\n\end{enumerate}`
work very well. This is Geany 1.29, under Debian GNU/Linux 9 (stretch).
Any idea ?
the sequence `{description}` is a substitution, see https://www.geany.org/manual/current/index.html#template-wildcards
There doesn't seem to be any way of stopping that, but since you don't seem to have any useful description, maybe you can set it to `{description}` :grin:
since you don't seem to have any useful description, maybe you can set it to {description}
Thank you for your response. However, I did not understand this last part I quote. Could you explain more precisely what you mean ? I did not know about substitutions.
Closed #1671.
Reopened #1671.
See the link I gave above, note in the `Dynamic Wildcards` table, the row for `description` has snippets in the right hand availability column meaning it is substituted in snippets, and where the value comes from is given in the middle column.
The good solution would be using the `{ob}` wildcard mentioned in the docs above: ``` description= \begin{ob}description{cb}\n%ws%\item %cursor%\n\end{ob}description{cb} ```
Ahh, there _is_ a way to stop substitutions.
Funny thing: In my default geany-config it's working without any issue. But I'm copying this config maybe for 10 years now.
Thank you very much, I did not know about this Wildcard thing. I used {ob} and {cb} and it now works like a charm.
Closed #1671.
github-comments@lists.geany.org