Skip to content

Commit

Permalink
Rename editorActiveLineNumber.foreground. Fixes #46848
Browse files Browse the repository at this point in the history
  • Loading branch information
aeschli committed Mar 28, 2018
1 parent e72d8d1 commit cc81646
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 14 deletions.
2 changes: 1 addition & 1 deletion extensions/theme-abyss/themes/abyss-color-theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@
"editorHoverWidget.background": "#000c38",
"editorHoverWidget.border": "#004c18",
"editorLineNumber.foreground": "#406385",
"editorActiveLineNumber.foreground": "#80a2c2",
"editorLineNumber.activeForeground": "#80a2c2",
"editorMarkerNavigation.background": "#060621",
"editorMarkerNavigationError.background": "#AB395B",
"editorMarkerNavigationWarning.background": "#5B7E7A",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"editorHoverWidget.background": "#221a14",
"editorGroupHeader.tabsBackground": "#131510",
"editorGroup.background": "#0f0c08",
"editorActiveLineNumber.foreground": "#adadad",
"editorLineNumber.activeForeground": "#adadad",
"tab.inactiveBackground": "#131510",
"titleBar.activeBackground": "#423523",
"statusBar.background": "#423523",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"editor.selectionBackground": "#676b7180",
"editor.selectionHighlightBackground": "#575b6180",
"editor.lineHighlightBackground": "#303030",
"editorActiveLineNumber.foreground": "#949494",
"editorLineNumber.activeForeground": "#949494",
"editor.wordHighlightBackground": "#4747a180",
"editor.wordHighlightStrongBackground": "#6767ce80",
"editorCursor.foreground": "#c07020",
Expand Down
2 changes: 1 addition & 1 deletion extensions/theme-monokai/themes/monokai-color-theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"editor.wordHighlightBackground": "#4a4a7680",
"editor.wordHighlightStrongBackground": "#6a6a9680",
"editor.lineHighlightBackground": "#3e3d32",
"editorActiveLineNumber.foreground": "#c2c2bf",
"editorLineNumber.activeForeground": "#c2c2bf",
"editorCursor.foreground": "#f8f8f0",
"editorWhitespace.foreground": "#464741",
"editorIndentGuide.background": "#464741",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@
"editor.background": "#F5F5F5",
"editorWhitespace.foreground": "#AAAAAA",
"editor.lineHighlightBackground": "#E4F6D4",
"editorActiveLineNumber.foreground": "#9769dc",
"editorLineNumber.activeForeground": "#9769dc",
"editor.selectionBackground": "#C9D0D9",
"panel.background": "#F5F5F5",
"sideBar.background": "#F2F2F2",
Expand Down
2 changes: 1 addition & 1 deletion extensions/theme-red/themes/Red-color-theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"editorWhitespace.foreground": "#c10000",
"editor.selectionBackground": "#750000",
"editorLineNumber.foreground": "#ff777788",
"editorActiveLineNumber.foreground": "#ffbbbb88",
"editorLineNumber.activeForeground": "#ffbbbb88",
"editorWidget.background": "#300000",
"editorHoverWidget.background": "#300000",
"editorSuggestWidget.background": "#300000",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@
"editorCursor.foreground": "#D30102",
"editorWhitespace.foreground": "#93A1A180",
"editor.lineHighlightBackground": "#073642",
"editorActiveLineNumber.foreground": "#949494",
"editorLineNumber.activeForeground": "#949494",
"editor.selectionBackground": "#073642",
// "editorIndentGuide.background": "",
"editorHoverWidget.background": "#004052",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@
"editor.selectionBackground": "#EEE8D5",
// "editorIndentGuide.background": "",
"editorHoverWidget.background": "#CCC4B0",
"editorActiveLineNumber.foreground": "#567983",
"editorLineNumber.activeForeground": "#567983",
// "editorHoverWidget.border": "",
// "editorLineNumber.foreground": "",
// "editorMarkerNavigation.background": "",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"editor.foreground": "#ffffff",
"editor.selectionBackground": "#003f8e",
"editor.lineHighlightBackground": "#00346e",
"editorActiveLineNumber.foreground": "#949494",
"editorLineNumber.activeForeground": "#949494",
"editorCursor.foreground": "#ffffff",
"editorWhitespace.foreground": "#404f7d",
"editorWidget.background": "#001c40",
Expand Down
5 changes: 4 additions & 1 deletion src/vs/editor/common/view/editorColorRegistry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,10 @@ export const editorCursorBackground = registerColor('editorCursor.background', n
export const editorWhitespaces = registerColor('editorWhitespace.foreground', { dark: '#e3e4e229', light: '#33333333', hc: '#e3e4e229' }, nls.localize('editorWhitespaces', 'Color of whitespace characters in the editor.'));
export const editorIndentGuides = registerColor('editorIndentGuide.background', { dark: editorWhitespaces, light: editorWhitespaces, hc: editorWhitespaces }, nls.localize('editorIndentGuides', 'Color of the editor indentation guides.'));
export const editorLineNumbers = registerColor('editorLineNumber.foreground', { dark: '#5A5A5A', light: '#2B91AF', hc: Color.white }, nls.localize('editorLineNumbers', 'Color of editor line numbers.'));
export const editorActiveLineNumber = registerColor('editorActiveLineNumber.foreground', { dark: null, light: null, hc: null }, nls.localize('editorActiveLineNumber', 'Color of editor active line number'));

const deprecatedEditorActiveLineNumber = registerColor('editorActiveLineNumber.foreground', { dark: null, light: null, hc: null }, nls.localize('editorActiveLineNumber', 'Color of editor active line number'), false, nls.localize('deprecatedEditorActiveLineNumber', 'Id is deprecated. Use \'editorLineNumber.activeForeground\' instead.'));
export const editorActiveLineNumber = registerColor('editorLineNumber.activeForeground', { dark: deprecatedEditorActiveLineNumber, light: deprecatedEditorActiveLineNumber, hc: deprecatedEditorActiveLineNumber }, nls.localize('editorActiveLineNumber', 'Color of editor active line number'));

export const editorRuler = registerColor('editorRuler.foreground', { dark: '#5A5A5A', light: Color.lightgrey, hc: Color.white }, nls.localize('editorRuler', 'Color of the editor rulers.'));

export const editorCodeLensForeground = registerColor('editorCodeLens.foreground', { dark: '#999999', light: '#999999', hc: '#999999' }, nls.localize('editorCodeLensForeground', 'Foreground color of editor code lenses'));
Expand Down
12 changes: 8 additions & 4 deletions src/vs/platform/theme/common/colorRegistry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,14 @@ class ColorRegistry implements IColorRegistry {
this.colorsById = {};
}

public registerColor(id: string, defaults: ColorDefaults, description: string, needsTransparency = false): ColorIdentifier {
public registerColor(id: string, defaults: ColorDefaults, description: string, needsTransparency = false, deprecationMessage?: string): ColorIdentifier {
let colorContribution = { id, description, defaults, needsTransparency };
this.colorsById[id] = colorContribution;
this.colorSchema.properties[id] = { type: 'string', description, format: 'color-hex', default: '#ff0000' };
let propertySchema: IJSONSchema = { type: 'string', description, format: 'color-hex', default: '#ff0000' };
if (deprecationMessage) {
propertySchema.deprecationMessage = deprecationMessage;
}
this.colorSchema.properties[id] = propertySchema;
this.colorReferenceSchema.enum.push(id);
this.colorReferenceSchema.enumDescriptions.push(description);
return id;
Expand Down Expand Up @@ -134,8 +138,8 @@ class ColorRegistry implements IColorRegistry {
const colorRegistry = new ColorRegistry();
platform.Registry.add(Extensions.ColorContribution, colorRegistry);

export function registerColor(id: string, defaults: ColorDefaults, description: string, needsTransparency?: boolean): ColorIdentifier {
return colorRegistry.registerColor(id, defaults, description, needsTransparency);
export function registerColor(id: string, defaults: ColorDefaults, description: string, needsTransparency?: boolean, deprecationMessage?: string): ColorIdentifier {
return colorRegistry.registerColor(id, defaults, description, needsTransparency, deprecationMessage);
}

export function getColorRegistry(): IColorRegistry {
Expand Down

0 comments on commit cc81646

Please sign in to comment.