Question

I write a lot of Geany snippets. I would like to add a snippet for %cursor% when writing snippets. I added this in the [Default] snippets:

cur=%cursor%

Problem being that will evaluate to placing the cursor, so disappears.

I am looking for an escape sequence for the %. I have tried \% and %% but no luck.

cur=%curso%cursor%%

is an OK workaround as I only need to add an r, but is not ideal.

Was it helpful?

Solution

The % is escaped with {pc} in Geany, so:

cur={pc}cursor{pc}

expands to %cursor%

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top