diff --git a/src/widgets/settingsdialog.cpp b/src/widgets/settingsdialog.cpp index a81eb9d8d..4d4ad064e 100644 --- a/src/widgets/settingsdialog.cpp +++ b/src/widgets/settingsdialog.cpp @@ -92,7 +92,7 @@ void SettingsDialog::addTabs() this->ui.tabContainer->addSpacing(16); - // this->addTab(new settingspages::KeyboardSettingsPage); + this->addTab(new settingspages::KeyboardSettingsPage); // this->addTab(new settingspages::LogsPage); this->addTab(new settingspages::ModerationPage); // this->addTab(new settingspages::SpecialChannelsPage); diff --git a/src/widgets/settingspages/keyboardsettingspage.cpp b/src/widgets/settingspages/keyboardsettingspage.cpp index bc9b00813..39df2c2e3 100644 --- a/src/widgets/settingspages/keyboardsettingspage.cpp +++ b/src/widgets/settingspages/keyboardsettingspage.cpp @@ -1,5 +1,10 @@ #include "keyboardsettingspage.hpp" +#include "util/layoutcreator.hpp" + +#include +#include + namespace chatterino { namespace widgets { namespace settingspages { @@ -7,6 +12,31 @@ namespace settingspages { KeyboardSettingsPage::KeyboardSettingsPage() : SettingsPage("Keybindings", "") { + auto layout = util::LayoutCreator(this).setLayoutType(); + + auto form = layout.emplace(); + + form->addRow(new QLabel("Hold Ctrl"), new QLabel("Show resize handles")); + form->addRow(new QLabel("Hold Ctrl + Alt"), new QLabel("Show split overlay")); + + form->addItem(new QSpacerItem(16, 16)); + form->addRow(new QLabel("Ctrl + T"), new QLabel("Create new split")); + form->addRow(new QLabel("Ctrl + W"), new QLabel("Close current split")); + + form->addRow(new QLabel("Ctrl + Shift + T"), new QLabel("Create new tab")); + form->addRow(new QLabel("Ctrl + Shift + W"), new QLabel("Close current tab")); + + form->addItem(new QSpacerItem(16, 16)); + form->addRow(new QLabel("Ctrl + 1/2/3/..."), new QLabel("Select tab 1/2/3/...")); + form->addRow(new QLabel("Ctrl + Tab"), new QLabel("Select next tab")); + form->addRow(new QLabel("Ctrl + Shift + Tab"), new QLabel("Select previous tab")); + + form->addRow(new QLabel("Alt + Left/Up/Right/Down"), + new QLabel("Select split left/up/right/down")); + + form->addItem(new QSpacerItem(16, 16)); + form->addRow(new QLabel("Ctrl + R"), new QLabel("Change channel")); + form->addRow(new QLabel("Ctrl + F"), new QLabel("Search in current channel")); } } // namespace settingspages