62
63
public static filter(lineDecorations: InlineDecoration[], lineNumber: number, minLineColumn: number, maxLineColumn: number): LineDecoration[] {
65
return [];
66
}
68
>
const result: LineDecoration[] = [];
69
>
let resultLen = 0;
70
>
71
>
for (let i = 0, len = lineDecorations.length; i < len; i++) {
72
>
const d = lineDecorations[i];
73
>
const range = d.range;
74
>
75
>
if (range.endLineNumber < lineNumber || range.startLineNumber > lineNumber) {
76
// Ignore decorations that sit outside this line
77
continue;
78
}
80
>
if (range.isEmpty() && (d.type === InlineDecorationType.Regular || d.type === InlineDecorationType.RegularAffectingLetterSpacing)) {
81
// Ignore empty range decorations
82
continue;
83
}
85
>
const startColumn = (range.startLineNumber === lineNumber ? range.startColumn : minLineColumn);
86
>
const endColumn = (range.endLineNumber === lineNumber ? range.endColumn : maxLineColumn);
87
>
88
>
result[resultLen++] = new LineDecoration(startColumn, endColumn, d.inlineClassName, d.type);
89
>
}
90
>
91
>
return result;
92
>
}
93
94
private static _typeCompare(a: InlineDecorationType, b: InlineDecorationType): number {