[bug] Indent after begin snippet in LaTeX
Closed this issue · 1 comments
irigone commented
After the snippet exits, there's no indentation on the new line.
Steps to reproduce:
- Make a LaTeX file with following content:
\documentclass{article}
\begin{document}
\end{document}
- Type "begin" on the empty line (below begin{document})
- Run command-yas-expand
- Type something
- Press TAB
- See how the cursor moves to a new empty line without indentation
The line gets indented after you press RET, so most of the time it's not an issue, but there are situations where you don't press RET at all and the line doesn't get indented. It also looks incredibly inconsistent when you type something on said unindented line until you make a new line.
AndreaCrotti commented
Mm well I think this is not really a problem with the snippet, the snippet itself doesn't have any indentation @veronikazaglotova .
When I enable latex-mode I can see that RET is bound to TeX-newline
which is what is actually doing the extra indentation.
It looks like you can customize that if you want
Hide Tex Newline Function: Value Menu newline
State : STANDARD.
Function to be called upon pressing ‘RET’.```
but yeah I'll close this issue since it's not related to the snippet.