Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LaTeX snippets \begin{description} won't work #1671

Closed
litobig opened this issue Nov 5, 2017 · 7 comments
Closed

LaTeX snippets \begin{description} won't work #1671

litobig opened this issue Nov 5, 2017 · 7 comments

Comments

@litobig
Copy link

litobig commented Nov 5, 2017

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 ?

@elextr
Copy link
Member

elextr commented Nov 5, 2017

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} 😁

@litobig
Copy link
Author

litobig commented Nov 6, 2017

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.

@litobig litobig closed this as completed Nov 6, 2017
@litobig litobig reopened this Nov 6, 2017
@elextr
Copy link
Member

elextr commented Nov 6, 2017

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.

@b4n
Copy link
Member

b4n commented Nov 7, 2017

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}

@elextr
Copy link
Member

elextr commented Nov 7, 2017

Ahh, there is a way to stop substitutions.

@frlan
Copy link
Member

frlan commented Nov 7, 2017

Funny thing: In my default geany-config it's working without any issue. But I'm copying this config maybe for 10 years now.

@litobig
Copy link
Author

litobig commented Nov 7, 2017

Thank you very much,
I did not know about this Wildcard thing. I used {ob} and {cb} and it now works like a charm.

@litobig litobig closed this as completed Nov 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants