Bladeren bron

Adds control over annotation toggling

Supports toggling annotations for each file individually or all files at once
Closes #289
main
Eric Amodio 6 jaren geleden
bovenliggende
commit
b10f7391ed
14 gewijzigde bestanden met toevoegingen van 235 en 42 verwijderingen
  1. +6
    -0
      CHANGELOG.md
  2. +8
    -0
      README.md
  3. +33
    -3
      package.json
  4. +85
    -7
      src/annotations/annotationController.ts
  5. +5
    -7
      src/annotations/annotations.ts
  6. +1
    -1
      src/annotations/blameAnnotationProvider.ts
  7. +1
    -1
      src/annotations/recentChangesAnnotationProvider.ts
  8. +13
    -11
      src/commands/toggleFileBlame.ts
  9. +4
    -4
      src/commands/toggleFileHeatmap.ts
  10. +4
    -4
      src/commands/toggleFileRecentChanges.ts
  11. +1
    -1
      src/currentLineController.ts
  12. +11
    -0
      src/ui/config.ts
  13. BIN
      src/ui/images/settings/heatmap.png
  14. +63
    -3
      src/ui/settings/index.html

+ 6
- 0
CHANGELOG.md Bestand weergeven

@ -7,6 +7,12 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p
## [Unreleased]
### Added
- Adds multi-cursor support to current line annotations — closes [#291](https://github.com/eamodio/vscode-gitlens/issues/291)
- Adds support to toggle annotations for each file individually or for all files at once — closes [#289](https://github.com/eamodio/vscode-gitlens/issues/289)
- Adds new controls the interactive settings editor (*Open Settings* from the Command Palette) to configure this new behavior
- Adds `gitlens.blame.toggleMode` setting to specify how the gutter blame annotations will be toggled, per file or window
- Adds `gitlens.heatmap.toggleMode` setting to specify how the gutter heatmap annotations will be toggled, per file or window
- Adds `gitlens.recentChanges.toggleMode` setting to specify how the recently changed lines annotations will be toggled, per file or window
### Changed
- Renames *Compare Selected Ancestor with Working Tree* command to *Compare Ancestry with Working Tree* and removes the need to select a branch first, since all compares are done to the working tree — closes [#279](https://github.com/eamodio/vscode-gitlens/issues/279)

+ 8
- 0
README.md Bestand weergeven

@ -583,6 +583,13 @@ See also [Explorer Settings](#explorer-settings "Jump to the Explorer settings")
|`gitlens.blame.highlight.locations`|Specifies where the associated line highlights will be shown<br />`gutter` - adds a gutter glyph<br />`line` - adds a full-line highlight background color<br />`overview` - adds a decoration to the overview ruler (scroll bar)
|`gitlens.blame.ignoreWhitespace`|Specifies whether to ignore whitespace when comparing revisions during blame operations
|`gitlens.blame.separateLines`|Specifies whether gutter blame annotations will have line separators
|`gitlens.blame.toggleMode`|Specifies how the gutter blame annotations will be toggled<br />`file` - toggle each file individually<br />`window` - toggle the window, i.e. all files at once
### Gutter Heatmap Settings
|Name | Description
|-----|------------
|`gitlens.heatmap.toggleMode`|Specifies how the gutter heatmap annotations will be toggled<br />`file` - toggle each file individually<br />`window` - toggle the window, i.e. all files at once
### Hover Settings
@ -603,6 +610,7 @@ See also [Explorer Settings](#explorer-settings "Jump to the Explorer settings")
|Name | Description
|-----|------------
|`gitlens.recentChanges.highlight.locations`|Specifies where the highlights of the recently changed lines will be shown<br />`gutter` - adds a gutter glyph<br />`line` - adds a full-line highlight background color<br />`overview` - adds a decoration to the overview ruler (scroll bar)
|`gitlens.recentChanges.toggleMode`|Specifies how the recently changed lines annotations will be toggled<br />`file` - toggle each file individually<br />`window` - toggle the window, i.e. all files at once
### Status Bar Settings

+ 33
- 3
package.json Bestand weergeven

@ -129,6 +129,16 @@
"description": "Specifies whether gutter blame annotations will be separated by a small gap",
"scope": "window"
},
"gitlens.blame.toggleMode": {
"type": "string",
"default": "file",
"enum": [
"file",
"window"
],
"description": "Specifies how the gutter blame annotations will be toggled\n `file` - toggle each file individually\n `window` - toggle the window, i.e. all files at once",
"scope": "window"
},
"gitlens.codeLens.authors.command": {
"type": "string",
"default": "gitlens.toggleFileBlame",
@ -459,6 +469,16 @@
"description": "Specifies the starting view (mode) of the `GitLens` explorer\n `auto` - shows the last selected view, defaults to `repository`\n `history` - shows the commit history of the active file\n `repository` - shows a repository explorer",
"scope": "window"
},
"gitlens.heatmap.toggleMode": {
"type": "string",
"default": "file",
"enum": [
"file",
"window"
],
"description": "Specifies how the gutter heatmap annotations will be toggled\n `file` - toggle each file individually\n `window` - toggle the window, i.e. all files at once",
"scope": "window"
},
"gitlens.hovers.annotations.changes": {
"type": "boolean",
"default": true,
@ -571,6 +591,16 @@
"description": "Specifies where the highlights of the recently changed lines will be shown\n `gutter` - adds a gutter glyph\n `line` - adds a full-line highlight background color\n `overview` - adds a decoration to the overview ruler (scroll bar)",
"scope": "window"
},
"gitlens.recentChanges.toggleMode": {
"type": "string",
"default": "file",
"enum": [
"file",
"window"
],
"description": "Specifies how the recently changed lines annotations will be toggled\n `file` - toggle each file individually\n `window` - toggle the window, i.e. all files at once",
"scope": "window"
},
"gitlens.remotes": {
"type": "array",
"default": null,
@ -1733,7 +1763,7 @@
},
{
"command": "gitlens.clearFileAnnotations",
"when": "gitlens:annotationStatus == computed"
"when": "gitlens:activeIsBlameable && gitlens:annotationStatus == computed"
},
{
"command": "gitlens.computingFileAnnotations",
@ -2134,12 +2164,12 @@
},
{
"command": "gitlens.computingFileAnnotations",
"when": "gitlens:annotationStatus == computing && config.gitlens.advanced.menus.editorTitle.blame",
"when": "gitlens:activeIsBlameable && gitlens:annotationStatus == computing && config.gitlens.advanced.menus.editorTitle.blame",
"group": "navigation@100"
},
{
"command": "gitlens.clearFileAnnotations",
"when": "gitlens:annotationStatus == computed && config.gitlens.advanced.menus.editorTitle.blame",
"when": "gitlens:activeIsBlameable && gitlens:annotationStatus == computed && config.gitlens.advanced.menus.editorTitle.blame",
"group": "navigation@100"
},
{

+ 85
- 7
src/annotations/annotationController.ts Bestand weergeven

@ -2,7 +2,7 @@
import { Functions, Iterables } from '../system';
import { ConfigurationChangeEvent, DecorationRangeBehavior, DecorationRenderOptions, Disposable, Event, EventEmitter, OverviewRulerLane, Progress, ProgressLocation, TextDocument, TextEditor, TextEditorDecorationType, TextEditorViewColumnChangeEvent, ThemeColor, window, workspace } from 'vscode';
import { AnnotationProviderBase, AnnotationStatus, TextEditorCorrelationKey } from './annotationProvider';
import { configuration, FileAnnotationType, HighlightLocations } from '../configuration';
import { AnnotationsToggleMode, configuration, FileAnnotationType, HighlightLocations } from '../configuration';
import { CommandContext, isTextEditor, setCommandContext } from '../constants';
import { Container } from '../container';
import { DocumentBlameStateChangeEvent, DocumentDirtyStateChangeEvent, GitDocumentState } from '../trackers/documentTracker';
@ -46,6 +46,8 @@ export class AnnotationController extends Disposable {
private _disposable: Disposable;
private _editor: TextEditor | undefined;
private _keyboardScope: KeyboardScope | undefined = undefined;
private readonly _toggleModes: Map<FileAnnotationType, AnnotationsToggleMode>;
private _annotationType: FileAnnotationType | undefined = undefined;
constructor() {
super(() => this.dispose());
@ -53,11 +55,13 @@ export class AnnotationController extends Disposable {
this._disposable = Disposable.from(
configuration.onDidChange(this.onConfigurationChanged, this)
);
this._toggleModes = new Map();
this.onConfigurationChanged(configuration.initializingChangeEvent);
}
dispose() {
this._annotationProviders.forEach(async (p, key) => await this.clearCore(key, AnnotationClearReason.Disposing));
this.clearAll();
Decorations.blameAnnotation && Decorations.blameAnnotation.dispose();
Decorations.blameHighlight && Decorations.blameHighlight.dispose();
@ -132,6 +136,27 @@ export class AnnotationController extends Disposable {
});
}
if (initializing || configuration.changed(e, configuration.name('blame')('toggleMode').value)) {
this._toggleModes.set(FileAnnotationType.Blame, cfg.blame.toggleMode);
if (!initializing && cfg.blame.toggleMode === AnnotationsToggleMode.File) {
this.clearAll();
}
}
if (initializing || configuration.changed(e, configuration.name('heatmap')('toggleMode').value)) {
this._toggleModes.set(FileAnnotationType.Heatmap, cfg.heatmap.toggleMode);
if (!initializing && cfg.heatmap.toggleMode === AnnotationsToggleMode.File) {
this.clearAll();
}
}
if (initializing || configuration.changed(e, configuration.name('recentChanges')('toggleMode').value)) {
this._toggleModes.set(FileAnnotationType.RecentChanges, cfg.recentChanges.toggleMode);
if (!initializing && cfg.recentChanges.toggleMode === AnnotationsToggleMode.File) {
this.clearAll();
}
}
if (initializing) return;
if (configuration.changed(e, configuration.name('blame').value) ||
@ -154,12 +179,18 @@ export class AnnotationController extends Disposable {
}
}
private onActiveTextEditorChanged(editor: TextEditor | undefined) {
private async onActiveTextEditorChanged(editor: TextEditor | undefined) {
if (editor !== undefined && !isTextEditor(editor)) return;
this._editor = editor;
// Logger.log('AnnotationController.onActiveTextEditorChanged', editor && editor.document.uri.fsPath);
if (this.isInWindowToggle()) {
await this.showAnnotations(editor, this._annotationType!);
return;
}
const provider = this.getProvider(editor);
if (provider === undefined) {
setCommandContext(CommandContext.AnnotationStatus, undefined);
@ -215,7 +246,7 @@ export class AnnotationController extends Disposable {
provider.restore(e.textEditor);
}
private async onVisibleTextEditorsChanged(editors: TextEditor[]) {
private onVisibleTextEditorsChanged(editors: TextEditor[]) {
let provider: AnnotationProviderBase | undefined;
for (const e of editors) {
provider = this.getProvider(e);
@ -225,8 +256,29 @@ export class AnnotationController extends Disposable {
}
}
async clear(editor: TextEditor, reason: AnnotationClearReason = AnnotationClearReason.User) {
this.clearCore(AnnotationProviderBase.getCorrelationKey(editor), reason);
isInWindowToggle(): boolean {
return this.getToggleMode(this._annotationType) === AnnotationsToggleMode.Window;
}
private getToggleMode(annotationType: FileAnnotationType | undefined): AnnotationsToggleMode {
if (annotationType === undefined) return AnnotationsToggleMode.File;
return this._toggleModes.get(annotationType) || AnnotationsToggleMode.File;
}
clear(editor: TextEditor, reason: AnnotationClearReason = AnnotationClearReason.User) {
if (this.isInWindowToggle()) {
return this.clearAll();
}
return this.clearCore(AnnotationProviderBase.getCorrelationKey(editor), reason);
}
async clearAll() {
this._annotationType = undefined;
for (const [key] of this._annotationProviders) {
await this.clearCore(key, AnnotationClearReason.Disposing);
}
}
async getAnnotationType(editor: TextEditor | undefined): Promise<FileAnnotationType | undefined> {
@ -245,6 +297,26 @@ export class AnnotationController extends Disposable {
}
async showAnnotations(editor: TextEditor | undefined, type: FileAnnotationType, shaOrLine?: string | number): Promise<boolean> {
if (this.getToggleMode(type) === AnnotationsToggleMode.Window) {
let first = this._annotationType === undefined;
const reset = !first && this._annotationType !== type;
this._annotationType = type;
if (reset) {
await this.clearAll();
first = true;
}
if (first) {
for (const e of window.visibleTextEditors) {
if (e === editor) continue;
this.showAnnotations(e, type);
}
}
}
if (editor === undefined) return false; // || editor.viewColumn === undefined) return false;
this._editor = editor;
@ -283,7 +355,13 @@ export class AnnotationController extends Disposable {
if (provider === undefined) return this.showAnnotations(editor!, type, shaOrLine);
const reopen = provider.annotationType !== type;
await this.clearCore(provider.correlationKey, AnnotationClearReason.User);
if (this.isInWindowToggle()) {
await this.clearAll();
}
else {
await this.clearCore(provider.correlationKey, AnnotationClearReason.User);
}
if (!reopen) return false;

+ 5
- 7
src/annotations/annotations.ts Bestand weergeven

@ -1,5 +1,5 @@
import { Dates, Objects, Strings } from '../system';
import { DecorationInstanceRenderOptions, DecorationOptions, MarkdownString, ThemableDecorationRenderOptions, ThemeColor, window } from 'vscode';
import { DecorationInstanceRenderOptions, DecorationOptions, MarkdownString, ThemableDecorationRenderOptions, ThemeColor } from 'vscode';
import { DiffWithCommand, OpenCommitInRemoteCommand, OpenFileRevisionCommand, ShowQuickCommitDetailsCommand, ShowQuickCommitFileDetailsCommand } from '../commands';
import { FileAnnotationType } from './../configuration';
import { GlyphChars } from '../constants';
@ -41,7 +41,7 @@ export class Annotations {
return '#793738';
}
private static getHoverCommandBar(commit: GitCommit, hasRemote: boolean, annotationType?: FileAnnotationType) {
private static getHoverCommandBar(commit: GitCommit, hasRemote: boolean, annotationType?: FileAnnotationType, line: number = 0) {
let commandBar = `[\`${GlyphChars.DoubleArrowLeft}\`](${DiffWithCommand.getMarkdownCommandArgs(commit)} "Open Changes") `;
if (commit.previousSha !== undefined) {
@ -50,8 +50,6 @@ export class Annotations {
}
const uri = GitUri.toRevisionUri(commit.previousSha, commit.previousUri.fsPath, commit.repoPath);
const line = window.activeTextEditor!.selection.active.line;
commandBar += `[\`${GlyphChars.SquareWithTopShadow}\`](${OpenFileRevisionCommand.getMarkdownCommandArgs(uri, annotationType || FileAnnotationType.Blame, line)} "Blame Previous Revision") `;
}
@ -64,7 +62,7 @@ export class Annotations {
return commandBar;
}
static getHoverMessage(commit: GitCommit, dateFormat: string | null, hasRemote: boolean, annotationType?: FileAnnotationType): MarkdownString {
static getHoverMessage(commit: GitCommit, dateFormat: string | null, hasRemote: boolean, annotationType?: FileAnnotationType, line: number = 0): MarkdownString {
if (dateFormat === null) {
dateFormat = 'MMMM Do, YYYY h:mma';
}
@ -73,7 +71,7 @@ export class Annotations {
let commandBar = '';
let showCommitDetailsCommand = '';
if (!commit.isUncommitted) {
commandBar = `\n\n${this.getHoverCommandBar(commit, hasRemote, annotationType)}`;
commandBar = `\n\n${this.getHoverCommandBar(commit, hasRemote, annotationType, line)}`;
showCommitDetailsCommand = `[\`${commit.shortSha}\`](${ShowQuickCommitDetailsCommand.getMarkdownCommandArgs(commit.sha)} "Show Commit Details")`;
message = commit.message
@ -137,7 +135,7 @@ export class Annotations {
} as DecorationOptions;
}
static detailsHover(commit: GitCommit, dateFormat: string | null, hasRemote: boolean, annotationType?: FileAnnotationType): DecorationOptions {
static detailsHover(commit: GitCommit, dateFormat: string | null, hasRemote: boolean, annotationType?: FileAnnotationType, line: number = 0): DecorationOptions {
const message = this.getHoverMessage(commit, dateFormat, hasRemote, annotationType);
return {
hoverMessage: message

+ 1
- 1
src/annotations/blameAnnotationProvider.ts Bestand weergeven

@ -121,7 +121,7 @@ export abstract class BlameAnnotationProviderBase extends AnnotationProviderBase
}
}
const message = Annotations.getHoverMessage(logCommit || commit, Container.config.defaultDateFormat, await Container.git.hasRemote(commit.repoPath), this.annotationType);
const message = Annotations.getHoverMessage(logCommit || commit, Container.config.defaultDateFormat, await Container.git.hasRemote(commit.repoPath), this.annotationType, this.editor.selection.active.line);
return new Hover(message, document.validateRange(new Range(position.line, 0, position.line, RangeEndOfLineIndex)));
}

+ 1
- 1
src/annotations/recentChangesAnnotationProvider.ts Bestand weergeven

@ -56,7 +56,7 @@ export class RecentChangesAnnotationProvider extends AnnotationProviderBase {
if (cfg.hovers.enabled && cfg.hovers.annotations.enabled) {
if (cfg.hovers.annotations.details) {
this.decorations.push({
hoverMessage: Annotations.getHoverMessage(commit, dateFormat, await Container.git.hasRemote(commit.repoPath), this.annotationType),
hoverMessage: Annotations.getHoverMessage(commit, dateFormat, await Container.git.hasRemote(commit.repoPath), this.annotationType, this.editor.selection.active.line),
range: range
} as DecorationOptions);
}

+ 13
- 11
src/commands/toggleFileBlame.ts Bestand weergeven

@ -1,6 +1,6 @@
'use strict';
import { TextEditor, TextEditorEdit, Uri, window } from 'vscode';
import { Commands, EditorCommand } from './common';
import { TextEditor, Uri, window } from 'vscode';
import { ActiveEditorCommand, Commands } from './common';
import { UriComparer } from '../comparers';
import { FileAnnotationType } from '../configuration';
import { Container } from '../container';
@ -11,20 +11,22 @@ export interface ToggleFileBlameCommandArgs {
type?: FileAnnotationType;
}
export class ToggleFileBlameCommand extends EditorCommand {
export class ToggleFileBlameCommand extends ActiveEditorCommand {
constructor() {
super(Commands.ToggleFileBlame);
}
async execute(editor: TextEditor, edit: TextEditorEdit, uri?: Uri, args: ToggleFileBlameCommandArgs = {}): Promise<any> {
if (editor === undefined) return undefined;
async execute(editor: TextEditor, uri?: Uri, args: ToggleFileBlameCommandArgs = {}): Promise<any> {
// if (editor === undefined) return undefined;
// Handle the case where we are focused on a non-editor editor (output, debug console)
if (uri !== undefined && !UriComparer.equals(uri, editor.document.uri)) {
const e = window.visibleTextEditors.find(e => UriComparer.equals(uri, e.document.uri));
if (e !== undefined) {
editor = e;
if (editor !== undefined) {
// Handle the case where we are focused on a non-editor editor (output, debug console)
if (uri !== undefined && !UriComparer.equals(uri, editor.document.uri)) {
const e = window.visibleTextEditors.find(e => UriComparer.equals(uri, e.document.uri));
if (e !== undefined) {
editor = e;
}
}
}
@ -33,7 +35,7 @@ export class ToggleFileBlameCommand extends EditorCommand {
args = { ...args, type: FileAnnotationType.Blame };
}
return Container.annotations.toggleAnnotations(editor, args.type!, args.sha !== undefined ? args.sha : editor.selection.active.line);
return Container.annotations.toggleAnnotations(editor, args.type!, args.sha !== undefined ? args.sha : editor && editor.selection.active.line);
}
catch (ex) {
Logger.error(ex, 'ToggleFileBlameCommand');

+ 4
- 4
src/commands/toggleFileHeatmap.ts Bestand weergeven

@ -1,16 +1,16 @@
'use strict';
import { commands, TextEditor, TextEditorEdit, Uri } from 'vscode';
import { commands, TextEditor, Uri } from 'vscode';
import { ToggleFileBlameCommandArgs } from '../commands';
import { Commands, EditorCommand } from './common';
import { ActiveEditorCommand, Commands } from './common';
import { FileAnnotationType } from '../configuration';
export class ToggleFileHeatmapCommand extends EditorCommand {
export class ToggleFileHeatmapCommand extends ActiveEditorCommand {
constructor() {
super(Commands.ToggleFileHeatmap);
}
async execute(editor: TextEditor, edit: TextEditorEdit, uri?: Uri): Promise<any> {
async execute(editor: TextEditor, uri?: Uri): Promise<any> {
commands.executeCommand(Commands.ToggleFileBlame, uri, { type: FileAnnotationType.Heatmap } as ToggleFileBlameCommandArgs);
}
}

+ 4
- 4
src/commands/toggleFileRecentChanges.ts Bestand weergeven

@ -1,16 +1,16 @@
'use strict';
import { commands, TextEditor, TextEditorEdit, Uri } from 'vscode';
import { commands, TextEditor, Uri } from 'vscode';
import { ToggleFileBlameCommandArgs } from '../commands';
import { Commands, EditorCommand } from './common';
import { ActiveEditorCommand, Commands } from './common';
import { FileAnnotationType } from '../configuration';
export class ToggleFileRecentChangesCommand extends EditorCommand {
export class ToggleFileRecentChangesCommand extends ActiveEditorCommand {
constructor() {
super(Commands.ToggleFileRecentChanges);
}
async execute(editor: TextEditor, edit: TextEditorEdit, uri?: Uri): Promise<any> {
async execute(editor: TextEditor, uri?: Uri): Promise<any> {
commands.executeCommand(Commands.ToggleFileBlame, uri, { type: FileAnnotationType.RecentChanges } as ToggleFileBlameCommandArgs);
}
}

+ 1
- 1
src/currentLineController.ts Bestand weergeven

@ -263,7 +263,7 @@ export class CurrentLineController extends Disposable {
const trackedDocument = await Container.tracker.get(document);
if (trackedDocument === undefined) return undefined;
const message = Annotations.getHoverMessage(logCommit || commit, Container.config.defaultDateFormat, trackedDocument.hasRemotes, fileAnnotations);
const message = Annotations.getHoverMessage(logCommit || commit, Container.config.defaultDateFormat, trackedDocument.hasRemotes, fileAnnotations, position.line);
return new Hover(message, range);
}

+ 11
- 0
src/ui/config.ts Bestand weergeven

@ -1,5 +1,10 @@
'use strict';
export enum AnnotationsToggleMode {
File = 'file',
Window = 'window'
}
export enum CodeLensCommand {
DiffWithPrevious = 'gitlens.diffWithPrevious',
ShowQuickCommitDetails = 'gitlens.showQuickCommitDetails',
@ -256,6 +261,7 @@ export interface IConfig {
};
ignoreWhitespace: boolean;
separateLines: boolean;
toggleMode: AnnotationsToggleMode;
};
currentLine: {
@ -275,6 +281,10 @@ export interface IConfig {
gitExplorer: IGitExplorerConfig;
heatmap: {
toggleMode: AnnotationsToggleMode;
};
hovers: {
annotations: {
changes: boolean;
@ -301,6 +311,7 @@ export interface IConfig {
highlight: {
locations: HighlightLocations[];
};
toggleMode: AnnotationsToggleMode;
};
remotes: IRemotesConfig[];

BIN
src/ui/images/settings/heatmap.png Bestand weergeven

Voor Na
Breedte: 600  |  Hoogte: 206  |  Grootte: 10 KiB

+ 63
- 3
src/ui/settings/index.html Bestand weergeven

@ -281,7 +281,7 @@
For more advanced customizations open <a class="command" title="Open User Settings" href="command:workbench.action.openGlobalSettings">User Settings</a> and search for <b><i>gitlens.currentLine</i></b>
<span class="settings-group__hint--more">
Use the
<a class="command" title="Run command" href="command:gitlens.toggleLineBlame" class="command">GitLens: Toggle Line Blame Annotations</a> command to override this setting for the current window
<a class="command" title="Run command" href="command:gitlens.toggleLineBlame">GitLens: Toggle Line Blame Annotations</a> command to override this setting for the current window
</span>
</p>
</div>
@ -298,6 +298,14 @@
</div>
<div class="section__settings">
<div class="settings-group">
<div class="settings-group__setting">
<label for="blame.toggleMode">Toggle annotations for </label>
<select class="setting" id="blame.toggleMode" name="blame.toggleMode">
<option value="file">each file, invididually</option>
<option value="window">all files at once</option>
</select>
</div>
<div class="settings-group__setting nowrap">
<input class="setting" id="blame.heatmap.enabled" name="blame.heatmap.enabled" type="checkbox" />
<label for="blame.heatmap.enabled">Add a heatmap (age) indicator</label>
@ -356,6 +364,47 @@
<i class="icon icon--lg icon__info"></i>
For more advanced customizations open <a class="command" title="Open User Settings" href="command:workbench.action.openGlobalSettings">User Settings</a> and search for <b><i>gitlens.blame</i></b>
<span class="settings-group__hint--more">
Use the
<span class="command hidden" data-visibility="blame.toggleMode =file">GitLens: Toggle File Blame Annotations</span>
<a class="command hidden" title="Run command" href="command:gitlens.toggleFileBlame" data-visibility="blame.toggleMode =window">GitLens: Toggle File Blame Annotations</a>
command to turn the annotations on or off
</span>
<span class="settings-group__hint--more">
Press <span class="shortcut-key">Esc</span> to turn off the annotations
</span>
</p>
</div>
</section>
<section id="heatmap">
<div class="section__header">
<h2 class="section__title">Gutter Heatmap
<a class="link__learn-more" title="Learn more" href="https://github.com/eamodio/vscode-gitlens/#gutter-heatmap">
<i class="icon icon__info"></i>
</a>
</h2>
<p class="section__title-hint">Adds on-demand heatmap to the edge of the gutter to show the relative age of a line</p>
</div>
<div class="section__settings">
<div class="settings-group">
<div class="settings-group__setting">
<label for="heatmap.toggleMode">Toggle annotations for </label>
<select class="setting" id="heatmap.toggleMode" name="heatmap.toggleMode">
<option value="file">each file, invididually</option>
<option value="window">all files at once</option>
</select>
</div>
</div>
<div class="section__preview">
<img class="image__preview" src="{{root}}/images/settings/heatmap.png" />
</div>
<p class="settings-group__hint">
<i class="icon icon--lg icon__info"></i>
Use the
<span class="command hidden" data-visibility="heatmap.toggleMode =file">GitLens: Toggle File Heatmap Annotations</span>
<a class="command hidden" title="Run command" href="command:gitlens.toggleFileHeatmap" data-visibility="heatmap.toggleMode =window">GitLens: Toggle File Heatmap Annotations</a>
command to turn the annotations on or off
<span class="settings-group__hint--more">
Press <span class="shortcut-key">Esc</span> to turn off the annotations
</span>
</p>
@ -476,6 +525,14 @@
</div>
<div class="section__settings">
<div class="settings-group">
<div class="settings-group__setting">
<label for="recentChanges.toggleMode">Toggle annotations for </label>
<select class="setting" id="recentChanges.toggleMode" name="recentChanges.toggleMode">
<option value="file">each file, invididually</option>
<option value="window">all files at once</option>
</select>
</div>
<div class="settings-group__setting nowrap">
<input class="setting" id="recentChanges.highlight.locations" name="recentChanges.highlight.locations" type="checkbox" value="gutter" data-type="array" />
<label for="recentChanges.highlight.locations">Add gutter highlight</label>
@ -498,7 +555,9 @@
<p class="settings-group__hint">
<i class="icon icon--lg icon__info"></i>
Use the
<a class="command" title="Run command" href="command:gitlens.toggleFileRecentChanges" class="command">GitLens: Toggle Recent File Changes Annotations</a> command to turn the annotations on or off
<span class="command hidden" data-visibility="recentChanges.toggleMode =file">GitLens: Toggle Recent File Changes Annotations</span>
<a class="command hidden" title="Run command" href="command:gitlens.toggleFileRecentChanges" data-visibility="recentChanges.toggleMode =window">GitLens: Toggle Recent File Changes Annotations</a>
command to turn the annotations on or off
<span class="settings-group__hint--more">
Press <span class="shortcut-key">Esc</span> to turn off the annotations
</span>
@ -552,7 +611,7 @@
For more advanced customizations open <a class="command" title="Open User Settings" href="command:workbench.action.openGlobalSettings">User Settings</a> and search for <b><i>gitlens.statusBar</i></b>
<span class="settings-group__hint--more">
Use the
<a class="command" title="Run command" href="command:gitlens.toggleLineBlame" class="command">GitLens: Toggle Line Blame Annotations</a> command to override this setting for the current window
<a class="command" title="Run command" href="command:gitlens.toggleLineBlame">GitLens: Toggle Line Blame Annotations</a> command to override this setting for the current window
</span>
</p>
</div>
@ -602,6 +661,7 @@
<li><a href="#code-lens">Code Lens</a></li>
<li><a href="#current-line">Current Line Blame</a></li>
<li><a href="#blame">Gutter Blame</a></li>
<li><a href="#heatmap">Gutter Heatmap</a></li>
<li><a href="#hovers">Hovers</a></li>
<li><a href="#recent-changes">Recent Changes</a></li>
<li><a href="#status-bar">Status Bar Blame</a></li>

Laden…
Annuleren
Opslaan