Bladeren bron

Sets decoration range behavior

main
Eric Amodio 7 jaren geleden
bovenliggende
commit
86c413081d
2 gewijzigde bestanden met toevoegingen van 5 en 3 verwijderingen
  1. +2
    -1
      src/annotations/annotationController.ts
  2. +3
    -2
      src/currentLineController.ts

+ 2
- 1
src/annotations/annotationController.ts Bestand weergeven

@ -1,6 +1,6 @@
'use strict';
import { Iterables, Objects } from '../system';
import { DecorationRenderOptions, Disposable, Event, EventEmitter, ExtensionContext, OverviewRulerLane, Progress, ProgressLocation, TextDocument, TextDocumentChangeEvent, TextEditor, TextEditorDecorationType, TextEditorViewColumnChangeEvent, window, workspace } from 'vscode';
import { DecorationRangeBehavior, DecorationRenderOptions, Disposable, Event, EventEmitter, ExtensionContext, OverviewRulerLane, Progress, ProgressLocation, TextDocument, TextDocumentChangeEvent, TextEditor, TextEditorDecorationType, TextEditorViewColumnChangeEvent, window, workspace } from 'vscode';
import { AnnotationProviderBase, TextEditorCorrelationKey } from './annotationProvider';
import { Keyboard, KeyboardScope, KeyCommand, Keys } from '../keyboard';
import { TextDocumentComparer } from '../comparers';
@ -36,6 +36,7 @@ enum AnnotationStatus {
export const Decorations = {
blameAnnotation: window.createTextEditorDecorationType({
isWholeLine: true,
rangeBehavior: DecorationRangeBehavior.ClosedClosed,
textDecoration: 'none'
} as DecorationRenderOptions),
blameHighlight: undefined as TextEditorDecorationType | undefined,

+ 3
- 2
src/currentLineController.ts Bestand weergeven

@ -1,6 +1,6 @@
'use strict';
import { Functions, Objects } from './system';
import { debug, DecorationOptions, DecorationRenderOptions, Disposable, ExtensionContext, Range, StatusBarAlignment, StatusBarItem, TextEditor, TextEditorDecorationType, TextEditorSelectionChangeEvent, window, workspace } from 'vscode';
import { debug, DecorationOptions, DecorationRangeBehavior, DecorationRenderOptions, Disposable, ExtensionContext, Range, StatusBarAlignment, StatusBarItem, TextEditor, TextEditorDecorationType, TextEditorSelectionChangeEvent, window, workspace } from 'vscode';
import { AnnotationController, FileAnnotationType } from './annotations/annotationController';
import { Annotations, endOfLineIndex } from './annotations/annotations';
import { Commands } from './commands';
@ -14,7 +14,8 @@ const annotationDecoration: TextEditorDecorationType = window.createTextEditorDe
after: {
margin: '0 0 0 3em',
textDecoration: 'none'
}
},
rangeBehavior: DecorationRangeBehavior.ClosedClosed
} as DecorationRenderOptions);
export enum LineAnnotationType {

Laden…
Annuleren
Opslaan