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

Function add

lib/web/CodeMirror/src/display/selection.js:60–67  ·  view source on GitHub ↗
(left, top, width, bottom)

Source from the content-addressed store, hash-verified

58 let docLTR = doc.direction == "ltr"
59
60 function add(left, top, width, bottom) {
61 if (top < 0) top = 0
62 top = Math.round(top)
63 bottom = Math.round(bottom)
64 fragment.appendChild(elt("div", null, "CodeMirror-selected", `position: absolute; left: ${left}px;
65 top: ${top}px; width: ${width == null ? rightSide - left : width}px;
66 height: ${bottom - top}px`))
67 }
68
69 function drawForLine(line, fromArg, toArg) {
70 let lineObj = getLine(doc, line)

Callers 2

drawForLineFunction · 0.70
drawSelectionRangeFunction · 0.70

Calls 1

eltFunction · 0.90

Tested by

no test coverage detected