[gtkmm-documentation/gmenu] menus_and_toolbars: Show use of accelerators



commit dae76b585b10bc932efa57d328dac51fbdc02c9c
Author: Murray Cumming <murrayc murrayc com>
Date:   Thu Sep 19 12:54:33 2013 +0200

    menus_and_toolbars: Show use of accelerators

 examples/book/menus/main_menu/examplewindow.cc |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/examples/book/menus/main_menu/examplewindow.cc b/examples/book/menus/main_menu/examplewindow.cc
index 10aeff5..f90f56d 100644
--- a/examples/book/menus/main_menu/examplewindow.cc
+++ b/examples/book/menus/main_menu/examplewindow.cc
@@ -90,6 +90,7 @@ ExampleWindow::ExampleWindow()
     "        <item>"
     "          <attribute name='label' translatable='yes'>New _Standard</attribute>"
     "          <attribute name='action'>example.newstandard</attribute>"
+    "          <attribute name='accel'>&lt;Primary&gt;n</attribute>"
     "        </item>"
     "        <item>"
     "          <attribute name='label' translatable='yes'>New _Foo</attribute>"
@@ -104,6 +105,7 @@ ExampleWindow::ExampleWindow()
     "        <item>"
     "          <attribute name='label' translatable='yes'>_Quit</attribute>"
     "          <attribute name='action'>example.quit</attribute>"
+    "          <attribute name='accel'>&lt;Primary&gt;q</attribute>"
     "        </item>"
     "      </section>"
     "    </submenu>"
@@ -113,10 +115,12 @@ ExampleWindow::ExampleWindow()
     "        <item>"
     "          <attribute name='label' translatable='yes'>_Copy</attribute>"
     "          <attribute name='action'>example.copy</attribute>"
+    "          <attribute name='accel'>&lt;Primary&gt;c</attribute>"
     "        </item>"
     "        <item>"
     "          <attribute name='label' translatable='yes'>_Paste</attribute>"
     "          <attribute name='action'>example.paste</attribute>"
+    "          <attribute name='accel'>&lt;Primary&gt;v</attribute>"
     "        </item>"
     "        <item>"
     "          <attribute name='label' translatable='yes'>_Something</attribute>"



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]