Disable auto-pairing of double dollar signs

Use case or problem

As a personal preference, I don’t like autocompletion of delimiters. In the editor preferences, I have “Auto-pair brackets” and “Auto-pair Markdown syntax” turned off. However, neither of these settings affect the behaviour of double dollar signs ($$ and $$ as opening and closing delimiters), used for display math.

This means I sometimes find myself fighting with the editor. For example, if I already wrote some LaTeX code and want to turn it into a displayed equation then I might write a $$ in front of it, but then the editor puts another $$ in as well, perhaps in the wrong place. So I delete the artificially added $$ and type it in the correct place - but then the editor puts in another unwanted $$ in the wrong place, so there’s this little back-and-forth that has to happen before I can get just a single $$ in the place where I typed it originally.

This is just a preference of mine, so the default behaviour shouldn’t be changed, but I’d like the option to turn it off.

Proposed solution

Add an option “Auto-pair double dollar signs” alongside “Auto-pair brackets” and “Auto-pair Markdown syntax” in the editor preferences. When it’s turned off, pressing enter after typing $$ will do anything special, so that another $$ will not appear elsewhere in the document.

1 Like