Terminal: Introduce Add/Close icons for the pane

Required a new "close" overlay.

Change-Id: I5268ec280992124ebcee78a73ab58b18e7c9309b
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
This commit is contained in:
Alessandro Portale
2023-03-23 16:40:10 +01:00
parent 47fcb28c8f
commit 3526b6a735
8 changed files with 40 additions and 4 deletions

View File

@@ -47,14 +47,16 @@ TerminalPane::TerminalPane(QObject *parent)
QAction &newTerminal = TerminalCommands::instance().paneActions().newTerminal;
QAction &closeTerminal = TerminalCommands::instance().paneActions().closeTerminal;
newTerminal.setIcon(
Icon({{":/terminal/images/settingscategory_terminal.png", Theme::Theme::IconsBaseColor}})
.icon());
newTerminal.setIcon(Icon({
{":/terminal/images/terminal.png", Theme::IconsBaseColor},
{":/utils/images/iconoverlay_add_small.png", Theme::IconsRunToolBarColor}}).icon());
newTerminal.setToolTip(Tr::tr("Create a new Terminal."));
connect(&newTerminal, &QAction::triggered, this, [this] { openTerminal({}); });
closeTerminal.setIcon(Icons::CLOSE_TOOLBAR.icon());
closeTerminal.setIcon(Icon({
{":/terminal/images/terminal.png", Theme::IconsBaseColor},
{":/utils/images/iconoverlay_close_small.png", Theme::IconsStopToolBarColor}}).icon());
closeTerminal.setToolTip(Tr::tr("Close the current Terminal."));
closeTerminal.setEnabled(false);