Skip to content

Commit

Permalink
Config: integratedTerminal -> terminal.integrated
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyriar committed May 27, 2016
1 parent 668a4ff commit 8c1dff7
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,26 +20,26 @@ let configurationRegistry = <IConfigurationRegistry>Registry.as(Extensions.Confi
configurationRegistry.registerConfiguration({
'id': 'terminal',
'order': 100,
'title': nls.localize('integratedTerminalConfigurationTitle', "Integrated terminal configuration"),
'title': nls.localize('terminalIntegratedConfigurationTitle', "Integrated terminal configuration"),
'type': 'object',
'properties': {
'integratedTerminal.shell.linux': {
'description': nls.localize('integratedTerminal.shell.linux', "The path of the shell that the terminal uses on Linux."),
'terminal.integrated.shell.linux': {
'description': nls.localize('terminal.integrated.shell.linux', "The path of the shell that the terminal uses on Linux."),
'type': 'string',
'default': TERMINAL_DEFAULT_SHELL_LINUX
},
'integratedTerminal.shell.osx': {
'description': nls.localize('integratedTerminal.shell.osx', "The path of the shell that the terminal uses on OS X."),
'terminal.integrated.shell.osx': {
'description': nls.localize('terminal.integrated.shell.osx', "The path of the shell that the terminal uses on OS X."),
'type': 'string',
'default': TERMINAL_DEFAULT_SHELL_OSX
},
'integratedTerminal.shell.windows': {
'description': nls.localize('integratedTerminal.shell.windows', "The path of the shell that the terminal uses on Windows."),
'terminal.integrated.shell.windows': {
'description': nls.localize('terminal.integrated.shell.windows', "The path of the shell that the terminal uses on Windows."),
'type': 'string',
'default': TERMINAL_DEFAULT_SHELL_WINDOWS
},
'integratedTerminal.fontFamily': {
'description': nls.localize('integratedTerminal.fontFamily', "The font family used by the terminal (CSS font-family format)."),
'terminal.integrated.fontFamily': {
'description': nls.localize('terminal.integrated.fontFamily', "The font family used by the terminal (CSS font-family format)."),
'type': 'string',
'default': 'Menlo, Monaco, Consolas, "Droid Sans Mono", "Courier New", monospace, "Droid Sans Fallback"'
}
Expand Down
16 changes: 9 additions & 7 deletions src/vs/workbench/parts/terminal/electron-browser/terminal.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,15 @@ export const TERMINAL_DEFAULT_SHELL_WINDOWS = processes.getWindowsShell();
export var ITerminalService = createDecorator<ITerminalService>(TERMINAL_SERVICE_ID);

export interface ITerminalConfiguration {
integratedTerminal: {
shell: {
linux: string,
osx: string,
windows: string
},
fontFamily: string
terminal: {
integrated: {
shell: {
linux: string,
osx: string,
windows: string
},
fontFamily: string
}
};
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ export class TerminalPanel extends Panel {
this.parentDomElement.appendChild(terminalScrollbar.getDomNode());

let config = this.configurationService.getConfiguration<ITerminalConfiguration>();
this.terminalDomElement.style.fontFamily = config.integratedTerminal.fontFamily;
this.terminalDomElement.style.fontFamily = config.terminal.integrated.fontFamily;
this.setTerminalTheme(this.themeService.getTheme());
resolve(void 0);
});
Expand Down Expand Up @@ -245,12 +245,12 @@ export class TerminalPanel extends Panel {
private getShell(): string {
let config = this.configurationService.getConfiguration<ITerminalConfiguration>();
if (platform.isWindows) {
return config.integratedTerminal.shell.windows;
return config.terminal.integrated.shell.windows;
}
if (platform.isMacintosh) {
return config.integratedTerminal.shell.osx;
return config.terminal.integrated.shell.osx;
}
return config.integratedTerminal.shell.linux;
return config.terminal.integrated.shell.linux;
}

public dispose(): void {
Expand Down

0 comments on commit 8c1dff7

Please sign in to comment.