MCPcopy
hub / github.com/witheve/Eve / findSpansAt

Method findSpansAt

src/ide.ts:1093–1103  ·  view source on GitHub ↗
(pos:Position, type?:string)

Source from the content-addressed store, hash-verified

1091 }
1092
1093 findSpansAt(pos:Position, type?:string):Span[] {
1094 let doc = this.cm.getDoc();
1095 let marks:SpanMarker[] = doc.findMarksAt(pos);
1096 let spans:Span[] = [];
1097 for(let mark of marks) {
1098 if(mark.span && (!type || mark.span.source.type === type)) {
1099 spans.push(mark.span);
1100 }
1101 }
1102 return spans;
1103 }
1104
1105 /** Create a new Span representing the given source in the document. */
1106 markSpan(from:Position, to:Position, source:any) {

Callers 12

updateDocumentMethod · 0.95
injectSpansMethod · 0.95
markBetweenMethod · 0.95
formatInlineMethod · 0.95
formatLineMethod · 0.95
formatBlockMethod · 0.95
EditorClass · 0.95
tokenInfoMethod · 0.80
IDEClass · 0.80
onChangeMethod · 0.80
applyMethod · 0.80
clearMethod · 0.80

Calls 2

getDocMethod · 0.80
findMarksAtMethod · 0.80

Tested by

no test coverage detected