From 21c2822fdb3e29692b5d24bcd33523307b407c4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Unai=20Hern=C3=A1ndez=20Minaberry?= Date: Mon, 16 Aug 2021 13:28:48 -0300 Subject: [PATCH] Add '=' case to autoindent --- src/moepkg/editor.nim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/moepkg/editor.nim b/src/moepkg/editor.nim index e21f5a0b9..403a32ae2 100644 --- a/src/moepkg/editor.nim +++ b/src/moepkg/editor.nim @@ -324,7 +324,8 @@ proc insertIndentInNimForKeyEnter(bufStatus: var BufferStatus, line.splitWhitespace == @[ru "let"] or line.splitWhitespace == @[ru "const"] or (line.len > 6 and line[line.len - 6 .. ^1] == ru "object") or - line[^1] == ru ':'): + line[^1] == (ru ':') or + line[^1] == ru '='): let count = countRepeat(line, Whitespace, 0) + tabStop oldLine = bufStatus.buffer[windowNode.currentLine + 1]