提交 36ebaf50 编写于 作者: D Daniel Imms

Remove terminal selection theme key for now

Part of #28397
上级 4401032d
......@@ -144,6 +144,10 @@
.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div {
position: absolute;
}
/* TODO: Remove in favor of theme keys, see #28397*/
.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: #000; }
.vs-dark .monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: #FFF; }
.hc-black .monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: #FFF; }
.monaco-workbench .panel.integrated-terminal .xterm .xterm-bold {
font-weight: bold;
......
......@@ -19,11 +19,12 @@ export const TERMINAL_FOREGROUND_COLOR = registerColor('terminal.foreground', {
dark: '#CCCCCC',
hc: '#FFFFFF'
}, nls.localize('terminal.foreground', 'The foreground color of the terminal.'));
export const TERMINAL_SELECTION_BACKGROUND_COLOR = registerColor('terminal.selectionBackground', {
light: '#000',
dark: '#FFF',
hc: '#FFF'
}, nls.localize('terminal.selectionBackground', 'The selection background color of the terminal.'));
// TODO: Reinstate, see #28397
// export const TERMINAL_SELECTION_BACKGROUND_COLOR = registerColor('terminal.selectionBackground', {
// light: '#000',
// dark: '#FFF',
// hc: '#FFF'
// }, nls.localize('terminal.selectionBackground', 'The selection background color of the terminal.'));
const ansiColorMap = {
'terminal.ansiBlack': {
......
......@@ -16,7 +16,7 @@ import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry';
import { ITerminalService, ITerminalFont, TERMINAL_PANEL_ID } from 'vs/workbench/parts/terminal/common/terminal';
import { IThemeService, ITheme } from 'vs/platform/theme/common/themeService';
import { TerminalFindWidget } from './terminalFindWidget';
import { ansiColorIdentifiers, TERMINAL_BACKGROUND_COLOR, TERMINAL_FOREGROUND_COLOR, TERMINAL_SELECTION_BACKGROUND_COLOR } from './terminalColorRegistry';
import { ansiColorIdentifiers, TERMINAL_BACKGROUND_COLOR, TERMINAL_FOREGROUND_COLOR } from './terminalColorRegistry';
import { ColorIdentifier } from 'vs/platform/theme/common/colorRegistry';
import { KillTerminalAction, CreateNewTerminalAction, SwitchTerminalInstanceAction, SwitchTerminalInstanceActionItem, CopyTerminalSelectionAction, TerminalPasteAction, ClearTerminalAction } from 'vs/workbench/parts/terminal/electron-browser/terminalActions';
import { Panel } from 'vs/workbench/browser/panel';
......@@ -278,10 +278,11 @@ export class TerminalPanel extends Panel {
`.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-bar.focus.xterm-cursor-blink .terminal-cursor::before,` +
`.monaco-workbench .panel.integrated-terminal .xterm.xterm-cursor-style-underline.focus.xterm-cursor-blink .terminal-cursor::before { background-color: ${fgColor}; }`;
}
const selectionColor = theme.getColor(TERMINAL_SELECTION_BACKGROUND_COLOR);
if (selectionColor) {
css += `.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: ${selectionColor}; }`;
}
// TODO: Reinstate, see #28397
// const selectionColor = theme.getColor(TERMINAL_SELECTION_BACKGROUND_COLOR);
// if (selectionColor) {
// css += `.monaco-workbench .panel.integrated-terminal .xterm .xterm-selection div { background-color: ${selectionColor}; }`;
// }
this._themeStyleElement.innerHTML = css;
this._findWidget.updateTheme(theme);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册