Skip to content

Commit 7389cee

Browse files
committed
fix: color hints may display twice(microsoft#175476)
1 parent def8a20 commit 7389cee

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/vs/editor/common/viewModel/modelLineProjection.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ class ModelLineProjection implements IModelLineProjection {
193193
if (options.inlineClassName) {
194194
const offset = (outputLineIndex > 0 ? lineBreakData.wrappedTextIndentLength : 0);
195195
const start = offset + Math.max(injectedTextStartOffsetInInputWithInjections - lineStartOffsetInInputWithInjections, 0);
196-
const end = offset + Math.min(injectedTextEndOffsetInInputWithInjections - lineStartOffsetInInputWithInjections, lineEndOffsetInInputWithInjections);
196+
const end = offset + Math.min(injectedTextEndOffsetInInputWithInjections - lineStartOffsetInInputWithInjections, lineEndOffsetInInputWithInjections - lineStartOffsetInInputWithInjections);
197197
if (start !== end) {
198198
inlineDecorations.push(new SingleLineInlineDecoration(start, end, options.inlineClassName, options.inlineClassNameAffectsLetterSpacing!));
199199
}

0 commit comments

Comments
 (0)