MCPcopy Create free account
hub / github.com/OpenEndedGroup/Field2 / attachVimMap

Function attachVimMap

lib/web/CodeMirror/keymap/vim.js:281–292  ·  view source on GitHub ↗
(cm, prev)

Source from the content-addressed store, hash-verified

279 leaveVimMode(cm);
280 }
281 function attachVimMap(cm, prev) {
282 if (this == CodeMirror.keyMap.vim) {
283 CodeMirror.addClass(cm.getWrapperElement(), "cm-fat-cursor");
284 if (cm.getOption("inputStyle") == "contenteditable" && document.body.style.caretColor != null) {
285 enableFatCursorMark(cm);
286 cm.getInputField().style.caretColor = "transparent";
287 }
288 }
289
290 if (!prev || prev.attach != attachVimMap)
291 enterVimMode(cm);
292 }
293
294 function updateFatCursorMark(cm) {
295 if (!cm.state.fatCursorMarks) return;

Callers

nothing calls this directly

Calls 2

enableFatCursorMarkFunction · 0.85
enterVimModeFunction · 0.85

Tested by

no test coverage detected