diff --git a/src/dlangide/tools/d/dsyntax.d b/src/dlangide/tools/d/dsyntax.d index 3737c4f..9e753ee 100644 --- a/src/dlangide/tools/d/dsyntax.d +++ b/src/dlangide/tools/d/dsyntax.d @@ -637,5 +637,21 @@ class SimpleDSyntaxSupport : SyntaxSupport { if (elapsed > 20) Log.d("updateHighlight took ", elapsed, "ms"); } + + + /// returns true if smart indent is supported + override bool supportsSmartIndents() { + return true; + } + + /// apply smart indent, if supported + override void applySmartIndent(EditOperation op, Object source) { + if (op.isInsertNewLine) { + // Enter key pressed - new line inserted or splitted + } else if (op.singleChar == '}') { + // } entered - probably need + } + } + }