From 95a6e1900e913418c6872e2155dc8b9ac22de7e7 Mon Sep 17 00:00:00 2001 From: Shane Kilkelly Date: Thu, 17 Mar 2016 14:09:45 +0000 Subject: [PATCH] Add autocomplete entries for the `end{}` commands --- .../aceEditor/auto-complete/SnippetManager.coffee | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/services/web/public/coffee/ide/editor/directives/aceEditor/auto-complete/SnippetManager.coffee b/services/web/public/coffee/ide/editor/directives/aceEditor/auto-complete/SnippetManager.coffee index 438e83fd6b..d4d8e4ca86 100644 --- a/services/web/public/coffee/ide/editor/directives/aceEditor/auto-complete/SnippetManager.coffee +++ b/services/web/public/coffee/ide/editor/directives/aceEditor/auto-complete/SnippetManager.coffee @@ -140,6 +140,16 @@ define () -> """ meta: "env" } + ).concat( + # arguably these `end` commands shouldn't be here, as they're not snippets + # but this is where we have access to the `begin` environment names + # *shrug* + parsedNames.map (name) -> + { + caption: "\\end{#{name}}" + value: "\\end{#{name}}" + meta: "env" + } ) callback null, snippets