[gnome-calculator] Update Keyboard shortcuts
- From: Robert Roth <robertroth src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-calculator] Update Keyboard shortcuts
- Date: Sun, 19 Jan 2020 21:10:50 +0000 (UTC)
commit 2715433adcf43baca1856c326495d43471a4cf12
Author: Sabri Ünal <libreajans gmail com>
Date: Sun Jan 19 21:10:32 2020 +0000
Update Keyboard shortcuts
Add a shortcut for Keyboard Shortcuts page
Add new shortcut of K.S. to the Keyboard Shortcuts page.
Move "Quit the application" under the "Close current window".
Add Common shortcuts (Copy, Paste, Undo, Redo) to the page.
Add alternative shortcut for "Switch to Keyboard mode".
Change odd primary to ctrl.
src/gnome-calculator.vala | 1 +
src/math-shortcuts.ui | 68 ++++++++++++++++++++++++++++++++++++++++++-----
2 files changed, 62 insertions(+), 7 deletions(-)
---
diff --git a/src/gnome-calculator.vala b/src/gnome-calculator.vala
index be9e84d1..d4816606 100644
--- a/src/gnome-calculator.vala
+++ b/src/gnome-calculator.vala
@@ -107,6 +107,7 @@ public class Calculator : Gtk.Application
set_accels_for_action ("app.quit", {"<control>Q"});
set_accels_for_action ("app.new-window", {"<control>N"});
set_accels_for_action ("app.help", {"F1"});
+ set_accels_for_action ("app.shortcuts", {"<control>F1", "<control>question"});
return current_window;
}
diff --git a/src/math-shortcuts.ui b/src/math-shortcuts.ui
index 52b76db4..04e03bc8 100644
--- a/src/math-shortcuts.ui
+++ b/src/math-shortcuts.ui
@@ -8,7 +8,7 @@
<object class="GtkShortcutsSection">
<property name="visible">1</property>
<property name="section-name">shortcuts</property>
- <property name="max-height">12</property>
+ <property name="max-height">13</property>
<child>
<object class="GtkShortcutsGroup">
<property name="visible">1</property>
@@ -27,6 +27,13 @@
<property name="title" translatable="yes" context="shortcut window">Close current
window</property>
</object>
</child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">1</property>
+ <property name="accelerator"><ctrl>q</property>
+ <property name="title" translatable="yes" context="shortcut window">Quit the
application</property>
+ </object>
+ </child>
<child>
<object class="GtkShortcutsShortcut">
<property name="visible">1</property>
@@ -37,15 +44,15 @@
<child>
<object class="GtkShortcutsShortcut">
<property name="visible">1</property>
- <property name="accelerator"><primary>Escape</property>
- <property name="title" translatable="yes" context="shortcut window">Clear history</property>
+ <property name="accelerator"><ctrl>F1</property>
+ <property name="title" translatable="yes" context="shortcut window">Keyboard
shortcuts</property>
</object>
</child>
<child>
<object class="GtkShortcutsShortcut">
<property name="visible">1</property>
- <property name="accelerator"><ctrl>q</property>
- <property name="title" translatable="yes" context="shortcut window">Quit the
application</property>
+ <property name="accelerator"><ctrl>Escape</property>
+ <property name="title" translatable="yes" context="shortcut window">Clear history</property>
</object>
</child>
</object>
@@ -85,7 +92,7 @@
<child>
<object class="GtkShortcutsShortcut">
<property name="visible">1</property>
- <property name="accelerator"><alt>t</property>
+ <property name="accelerator"><alt>k</property>
<property name="title" translatable="yes" context="shortcut window">Switch to Keyboard
mode</property>
</object>
</child>
@@ -173,8 +180,55 @@
</child>
</object>
</child>
+ <child>
+ <object class="GtkShortcutsGroup">
+ <property name="visible">1</property>
+ <property name="title" translatable="yes" context="shortcut window">Others</property>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">1</property>
+ <property name="accelerator"><ctrl>C</property>
+ <property name="title" translatable="yes" context="shortcut window">Copy</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">1</property>
+ <property name="accelerator"><ctrl>V</property>
+ <property name="title" translatable="yes" context="shortcut window">Paste</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">1</property>
+ <property name="accelerator"><ctrl>Z</property>
+ <property name="title" translatable="yes" context="shortcut window">Undo</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">1</property>
+ <property name="accelerator"><ctrl><shift>Z</property>
+ <property name="title" translatable="yes" context="shortcut window">Redo</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">1</property>
+ <property name="accelerator"><ctrl>question</property>
+ <property name="title" translatable="yes" context="shortcut window">Keyboard shortcuts
(alt.)</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkShortcutsShortcut">
+ <property name="visible">1</property>
+ <property name="accelerator"><alt>t</property>
+ <property name="title" translatable="yes" context="shortcut window">Switch to Keyboard mode
(alt.)</property>
+ </object>
+ </child>
+ </object>
+ </child>
</object>
</child>
</object>
-
</interface>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]