Show shortcut keys in pop-up menus
authorColin Clark <colin.clark@cclark.uk>
Wed, 29 Dec 2021 13:22:12 +0000 (13:22 +0000)
committerColin Clark <colin.clark@cclark.uk>
Wed, 29 Dec 2021 13:22:12 +0000 (13:22 +0000)
Also fixes:
https://github.com/BestImageViewer/geeqie/issues/935

- Show shortcut keys in right-click pop-up menus
- Script file to generate the shortcut key documentation in the Help
files

23 files changed:
CHECKLIST.md
README.md
doc/create-shortcuts-xml.sh [new file with mode: 0755]
doc/docbook/GuideMainWindowImagePane.xml
doc/docbook/GuideOptionsKeyboard.xml
doc/docbook/GuideReferenceCollectionsShortcuts.xml [new file with mode: 0644]
doc/docbook/GuideReferenceDuplicatesShortcuts.xml [new file with mode: 0644]
doc/docbook/GuideReferenceImageViewShortcuts.xml [new file with mode: 0644]
doc/docbook/GuideReferenceKeyboardShortcuts.xml
doc/docbook/GuideReferenceMainWindowShortcuts.xml [new file with mode: 0644]
doc/docbook/GuideReferencePanViewShortcuts.xml [new file with mode: 0644]
doc/docbook/GuideReferenceSearchShortcuts.xml [new file with mode: 0644]
src/collect-table.c
src/dupe.c
src/img-view.c
src/layout_image.c
src/layout_util.c
src/menu.c
src/pan-view/pan-view.c
src/search.c
src/typedefs.h
src/ui_menu.c
src/view_file/view_file.c

index b6b28d7..9d93ed4 100644 (file)
@@ -1,35 +1,53 @@
-## A checklist to be used after Geeqie has been updated
+# A checklist to be used after Geeqie has been updated
 
-Before compiling the sources, carry out the following actions when necessary:
+## Before compiling the sources, carry out the following actions when necessary
 
 * Update `org.geeqie.Geeqie.appdata.xml.in` with the latest released version and date
+
 * If source files have been added or removed from `./src/` directory, resync `./po/POTFILES.in`
+
 ```sh
 cd ./po
 ./regen_potfiles.sh | patch -p0
 ```
+
 * Keep translations in sync with the code
+
 ```sh
 cd ./po
 make update-po
 ```
+
 * Update the the timezone database
+
 ```sh
 ./scripts/zonedetect/create_timezone_database
 ```
 
-After compiling the sources, carry out the following actions when necessary:
+* Upload the timezone database to TBD
+
+## After compiling the sources, carry out the following actions when necessary
+
 * Update the man page and Command Line Options section in Help
+
 ```sh
 ./scripts/generate-man-page.sh
 ```
 
-*  Commit the changes
+* Update the keyboard shortcuts page in Help
+
+```sh
+./doc/create-shortcuts-xml.sh
+```
+
+* Commit the changes
 
 * Generate a new AppImage (note that this should be run on a **20.04 system**)
+
 ```sh
 ./scripts/generate-appimage.sh <location of local appimages folder>
 ```
+
 * Upload AppImage to web AppImages location
 * Edit `<location of local geeqie.github.io>/AppImage/appimages.txt` to include latest AppImage at the *top* of the list
 * Copy Help html files to `<location of local geeqie.github.io>/help`
index 7897ab1..a907487 100644 (file)
--- a/README.md
+++ b/README.md
@@ -133,7 +133,7 @@ If you wish to compile the sources yourself you may download the latest version
 
 Either: `git clone git://www.geeqie.org/geeqie.git`
 
-Or: `git clone http://www.geeqie.org/git/geeqie.git`
+Or: `git clone http://git.geeqie.org/git/geeqie.git`
 
 ## Manual Installation
 
diff --git a/doc/create-shortcuts-xml.sh b/doc/create-shortcuts-xml.sh
new file mode 100755 (executable)
index 0000000..a8ac2ce
--- /dev/null
@@ -0,0 +1,146 @@
+#!/bin/bash
+
+#**********************************************************************
+# Copyright (C) 2021 - The Geeqie Team
+#
+# Author: Colin Clark
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program; if not, write to the Free Software Foundation, Inc.,
+# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+#**********************************************************************
+
+## @file
+## @brief Generate Help .xml files describing window shortcut keys.
+##
+## The .xml files are included within ./doc/docbook/GuideReferenceKeyboardShortcuts.xml
+##
+## For separate windows, source code files are searched for the string "hard_coded_window_keys"  
+## which is an array containing the shortcut key and the menu label.
+##
+## For the main window the source file ./src/layout_util.c is searched for
+## lines which contain shortcut definitions.
+##
+## This needs to be run only when the sortcut keys have been changed
+##
+
+duplicates_xml="<link linkend=\"GuideImageSearchFindingDuplicates\">Duplicates window</link>"
+search_xml="<link linkend=\"GuideImageSearchSearch\">Search window</link>"
+pan_view_xml="<link linkend=\"GuideOtherWindowsPanView\">Pan view window</link>"
+collections_xml="<link linkend=\"GuideCollections\">Collections window</link>"
+image_xml="<link linkend=\"GuideOtherWindowsImageWindow\">Image view window</link>"
+main_window_xml="<link linkend=\"GuideMainWindow\">Main window</link>"
+
+pre_1_xml="<table frame=\"all\">\n
+<title>\n
+"
+
+pre_2_xml="
+keyboard shortcuts\n
+</title>\n
+<tgroup cols=\"2\" rowsep=\"1\" colsep=\"1\">\n
+<thead>\n
+<row>\n
+<entry>Shortcut</entry>\n
+<entry>Action</entry>\n
+</row>\n
+</thead>\n
+<tbody>\n
+"
+
+post_xml="</tbody></tgroup></table>"
+
+post_main_window_xml="
+<row>
+<entry>
+<keycap>1</keycap>...<keycap>6</keycap>
+</entry>
+<entry>Toggle mark 1 ... 6</entry>
+</row>
+<row>
+<entry>
+<code>Ctrl +<keycap>1</keycap></code>...<code>Ctrl +<keycap>6</keycap></code>
+</entry>
+<entry>Select mark 1 ... 6</entry>
+</row>
+
+</tbody></tgroup></table>"
+
+# shellcheck disable=SC2016
+awk_window='BEGIN {
+       {FS=","}
+       while ($0 !~ /^hard_coded_window_keys/) {getline}
+}
+$0~/\{0, 0/ {exit}
+{
+gsub(/{0/, "", $1);
+gsub(/{GDK_CONTROL_MASK \+ GDK_SHIFT_MASK/, "Ctrl + Shift +", $1);
+gsub(/{GDK_CONTROL_MASK/, "Ctrl +", $1);
+gsub(/{GDK_SHIFT_MASK/, "Shift +", $1);
+gsub(/{GDK_MOD1_MASK/, "Alt +", $1);
+gsub(/ GDK_KEY_/, "", $2);
+gsub(/\047/, "", $2);
+gsub(/N_\(/, "", $3);
+gsub(/\)\}/, "", $3);
+gsub(/"/, "", $3);
+}
+{print "<row> <entry> <code>", $1, "<keycap>", $2, "</keycap> </code> </entry> <entry>", $3, "</entry> </row>"}
+'
+
+# This assumes that lines beginning with /^  { "/ are the only ones in layout_util.c containing key shortcuts
+# shellcheck disable=SC2016
+awk_main_window='BEGIN {
+       {FS=","}
+}
+$0 ~ /^  { "/ {
+       if ($4 !~ /NULL/) {
+               {
+               gsub(/^[[:space:]]+|[[:space:]]+$/,"",$4);
+               gsub(/^[[:space:]]+|[[:space:]]+$/,"",$5);
+               gsub(/{0/, "", $4);
+               gsub(/<control>/, "Ctrl + ", $4);
+               gsub(/<alt>/, "Alt + ", $4);
+               gsub(/<shift>/, "Shift + ", $4);
+               gsub(/"/,"", $4);
+               gsub(/slash/,"/", $4);
+               gsub(/bracketleft/,"[", $4);
+               gsub(/bracketright/,"]", $4);
+               gsub(/"/,"", $5);
+               gsub(/N_\(/, "", $5);
+               gsub(/\)\}/, "", $5);
+               gsub(/"/, "", $5);
+               gsub(/\.\.\./, "", $5);
+               gsub(/)/, "", $5);
+               }
+               {print "<row> <entry> <code>", "<keycap>", $4, "</keycap> </code> </entry> <entry>", $5, "</entry> </row>"}
+       }
+}
+'
+
+keys_xml=$(awk "$awk_window" ./src/dupe.c )
+echo -e "$pre_1_xml" "$duplicates_xml" "$pre_2_xml" "$keys_xml" "$post_xml" > ./doc/docbook/GuideReferenceDuplicatesShortcuts.xml
+
+keys_xml=$(awk "$awk_window" ./src/search.c )
+echo -e "$pre_1_xml" "$search_xml" "$pre_2_xml" "$keys_xml" "$post_xml" > ./doc/docbook/GuideReferenceSearchShortcuts.xml
+
+keys_xml=$(awk "$awk_window" ./src/pan-view/pan-view.c )
+echo -e "$pre_1_xml" "$pan_view_xml" "$pre_2_xml" "$keys_xml" "$post_xml" > ./doc/docbook/GuideReferencePanViewShortcuts.xml
+
+keys_xml=$(awk "$awk_window" ./src/collect-table.c)
+echo -e "$pre_1_xml" "$collections_xml" "$pre_2_xml" "$keys_xml" "$post_xml" > ./doc/docbook/GuideReferenceCollectionsShortcuts.xml
+
+keys_xml=$(awk "$awk_window" ./src/img-view.c)
+echo -e "$pre_1_xml" "$image_xml" "$pre_2_xml" "$keys_xml" "$post_xml" > ./doc/docbook/GuideReferenceImageViewShortcuts.xml
+
+keys_xml=$(awk "$awk_main_window" ./src/layout_util.c)
+echo -e "$pre_1_xml" "$main_window_xml" "$pre_2_xml" "$keys_xml" "$post_main_window_xml" > ./doc/docbook/GuideReferenceMainWindowShortcuts.xml
index 37d6c00..6ad4077 100644 (file)
@@ -77,7 +77,7 @@
     <section id="Mouse">
       <title>Mouse</title>
       <para>
-        Press the primary mouse button on the image and hold it, then move the mouse to pan the image in the desired direction. Releasing the mouse button will stop the panning operation. The mouse wheel can also be used to scroll the image when holding down the Shift key
+        Press the left mouse button on the image and hold it, then move the mouse to pan the image in the desired direction. Releasing the mouse button will stop the panning operation. The mouse wheel can also be used to scroll the image when holding down the Shift key
         <footnote id='ref2'>
           The mouse wheel behavior for scrolling and image step can be swapped with the "Mouse wheel scrolls image" option located on the
           <link linkend="GuideOptionsBehavior">Behaviour tab</link>
@@ -89,7 +89,7 @@
       <para />
       <section id="SmoothScroll">
         <title>Smooth Scroll</title>
-        <para>To start the smooth scroll function hold down the Shift key and click the primary mouse button. An icon will appear at the location of the mouse pointer, the mouse can then be positioned to pan the image. The image will pan in the direction of the mouse pointer relative to the icon. The pan speed will increase in proportion to the distance that the pointer is from the center of the icon. To end the smooth scroll function click the primary mouse button within the image pane.</para>
+        <para>To start the smooth scroll function hold down the Control key and click the left mouse button. An icon will appear at the location of the mouse pointer, the mouse can then be positioned to pan the image. The image will pan in the direction of the mouse pointer relative to the icon. The pan speed will increase in proportion to the distance that the pointer is from the center of the icon. To end the smooth scroll function click the left mouse button within the image pane.</para>
         <para />
       </section>
       <section id="MouseWheelMode">
index a2b159f..a13124d 100644 (file)
@@ -4,4 +4,5 @@
   <para>This dialogue enables changes to be be made to the default key short-cut allocated to menu items.</para>
   <para>The data displayed may be ordered by clicking at the top of each column.</para>
   <para>To change or create a new short-cut, double click on the KEY column of the relevant item. The text displayed will change to "New accelerator...". Press the key combination required for this action.</para>
+  <para>Only shortcuts in the main window can be redefined. Shortcuts in other windows are fixed.</para>
 </section>
diff --git a/doc/docbook/GuideReferenceCollectionsShortcuts.xml b/doc/docbook/GuideReferenceCollectionsShortcuts.xml
new file mode 100644 (file)
index 0000000..5c68fa7
--- /dev/null
@@ -0,0 +1,49 @@
+<table frame="all">
+
+<title>
+
+ <link linkend="GuideCollections">Collections window</link> 
+keyboard shortcuts
+
+</title>
+
+<tgroup cols="2" rowsep="1" colsep="1">
+
+<thead>
+
+<row>
+
+<entry>Shortcut</entry>
+
+<entry>Action</entry>
+
+</row>
+
+</thead>
+
+<tbody>
+
+ <row> <entry> <code>  Ctrl + <keycap>  C </keycap> </code> </entry> <entry>  Copy </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  M </keycap> </code> </entry> <entry>  Move </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  R </keycap> </code> </entry> <entry>  Rename </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  D </keycap> </code> </entry> <entry>  Move to Trash </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  W </keycap> </code> </entry> <entry>  Close window </entry> </row>
+<row> <entry> <code>    <keycap> Delete </keycap> </code> </entry> <entry>  Remove </entry> </row>
+<row> <entry> <code>    <keycap> Return </keycap> </code> </entry> <entry>  View </entry> </row>
+<row> <entry> <code>    <keycap>  V </keycap> </code> </entry> <entry>  View in new window </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  A </keycap> </code> </entry> <entry>  Select all </entry> </row>
+<row> <entry> <code>   Ctrl + Shift + <keycap>  A </keycap> </code> </entry> <entry>  Select none </entry> </row>
+<row> <entry> <code>   Alt + <keycap>  R </keycap> </code> </entry> <entry>  Rectangular selection </entry> </row>
+<row> <entry> <code>    <keycap> space </keycap> </code> </entry> <entry>  Select single file </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap> space </keycap> </code> </entry> <entry>  Toggle select image </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  L </keycap> </code> </entry> <entry>  Append from file selection </entry> </row>
+<row> <entry> <code>    <keycap>  A </keycap> </code> </entry> <entry>  Append from collection </entry> </row>
+<row> <entry> <code>    <keycap>  S </keycap> </code> </entry> <entry>  Save collection </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  S </keycap> </code> </entry> <entry>  Save collection as </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  T </keycap> </code> </entry> <entry>  Show filename text </entry> </row>
+<row> <entry> <code>    <keycap>  N </keycap> </code> </entry> <entry>  Sort by name </entry> </row>
+<row> <entry> <code>    <keycap>  I </keycap> </code> </entry> <entry>  Sort by number </entry> </row>
+<row> <entry> <code>    <keycap>  D </keycap> </code> </entry> <entry>  Sort by date </entry> </row>
+<row> <entry> <code>    <keycap>  B </keycap> </code> </entry> <entry>  Sort by size </entry> </row>
+<row> <entry> <code>    <keycap>  P </keycap> </code> </entry> <entry>  Sort by path </entry> </row>
+<row> <entry> <code>   Shift + <keycap>  P </keycap> </code> </entry> <entry>  Print </entry> </row> </tbody></tgroup></table>
diff --git a/doc/docbook/GuideReferenceDuplicatesShortcuts.xml b/doc/docbook/GuideReferenceDuplicatesShortcuts.xml
new file mode 100644 (file)
index 0000000..6882730
--- /dev/null
@@ -0,0 +1,43 @@
+<table frame="all">
+
+<title>
+
+ <link linkend="GuideImageSearchFindingDuplicates">Duplicates window</link> 
+keyboard shortcuts
+
+</title>
+
+<tgroup cols="2" rowsep="1" colsep="1">
+
+<thead>
+
+<row>
+
+<entry>Shortcut</entry>
+
+<entry>Action</entry>
+
+</row>
+
+</thead>
+
+<tbody>
+
+ <row> <entry> <code>  Ctrl + <keycap>  C </keycap> </code> </entry> <entry>  Copy </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  M </keycap> </code> </entry> <entry>  Move </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  R </keycap> </code> </entry> <entry>  Rename </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  D </keycap> </code> </entry> <entry>  Move to Trash </entry> </row>
+<row> <entry> <code>   Shift + <keycap> Delete </keycap> </code> </entry> <entry>  Delete </entry> </row>
+<row> <entry> <code>    <keycap> Delete </keycap> </code> </entry> <entry>  Remove </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap> Delete </keycap> </code> </entry> <entry>  Clear </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  A </keycap> </code> </entry> <entry>  Select all </entry> </row>
+<row> <entry> <code>   Ctrl + Shift + <keycap>  A </keycap> </code> </entry> <entry>  Select none </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  T </keycap> </code> </entry> <entry>  Toggle thumbs </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  W </keycap> </code> </entry> <entry>  Close window </entry> </row>
+<row> <entry> <code>    <keycap> Return </keycap> </code> </entry> <entry>  View </entry> </row>
+<row> <entry> <code>    <keycap>  V </keycap> </code> </entry> <entry>  View in new window </entry> </row>
+<row> <entry> <code>    <keycap>  C </keycap> </code> </entry> <entry>  Collection from selection </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  L </keycap> </code> </entry> <entry>  Append list </entry> </row>
+<row> <entry> <code>    <keycap>  0 </keycap> </code> </entry> <entry>  Select none </entry> </row>
+<row> <entry> <code>    <keycap>  1 </keycap> </code> </entry> <entry>  Select group 1 duplicates </entry> </row>
+<row> <entry> <code>    <keycap>  2 </keycap> </code> </entry> <entry>  Select group 2 duplicates </entry> </row> </tbody></tgroup></table>
diff --git a/doc/docbook/GuideReferenceImageViewShortcuts.xml b/doc/docbook/GuideReferenceImageViewShortcuts.xml
new file mode 100644 (file)
index 0000000..7a1f613
--- /dev/null
@@ -0,0 +1,72 @@
+<table frame="all">
+
+<title>
+
+ <link linkend="GuideOtherWindowsImageWindow">Image view window</link> 
+keyboard shortcuts
+
+</title>
+
+<tgroup cols="2" rowsep="1" colsep="1">
+
+<thead>
+
+<row>
+
+<entry>Shortcut</entry>
+
+<entry>Action</entry>
+
+</row>
+
+</thead>
+
+<tbody>
+
+ <row> <entry> <code>  Ctrl + <keycap>  C </keycap> </code> </entry> <entry>  Copy </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  M </keycap> </code> </entry> <entry>  Move </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  R </keycap> </code> </entry> <entry>  Rename </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  D </keycap> </code> </entry> <entry>  Move to Trash </entry> </row>
+<row> <entry> <code>    <keycap> Delete </keycap> </code> </entry> <entry>  Move to Trash </entry> </row>
+<row> <entry> <code>   Shift + <keycap> Delete </keycap> </code> </entry> <entry>  Delete </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  W </keycap> </code> </entry> <entry>  Close window </entry> </row>
+<row> <entry> <code>   Shift + <keycap>  R </keycap> </code> </entry> <entry>  Rotate 180° </entry> </row>
+<row> <entry> <code>   Shift + <keycap>  M </keycap> </code> </entry> <entry>  Rotate mirror </entry> </row>
+<row> <entry> <code>   Shift + <keycap>  F </keycap> </code> </entry> <entry>  Rotate flip </entry> </row>
+<row> <entry> <code>    <keycap>  ] </keycap> </code> </entry> <entry>   Rotate counterclockwise 90° </entry> </row>
+<row> <entry> <code>    <keycap>  [ </keycap> </code> </entry> <entry>   Rotate clockwise 90° </entry> </row>
+<row> <entry> <code>    <keycap> Page_Up </keycap> </code> </entry> <entry>  Previous </entry> </row>
+<row> <entry> <code>    <keycap> KP_Page_Up </keycap> </code> </entry> <entry>  Previous </entry> </row>
+<row> <entry> <code>    <keycap> BackSpace </keycap> </code> </entry> <entry>  Previous </entry> </row>
+<row> <entry> <code>    <keycap>  B </keycap> </code> </entry> <entry>  Previous </entry> </row>
+<row> <entry> <code>    <keycap> Page_Down </keycap> </code> </entry> <entry>  Next </entry> </row>
+<row> <entry> <code>    <keycap> KP_Page_Down </keycap> </code> </entry> <entry>  Next </entry> </row>
+<row> <entry> <code>    <keycap> space </keycap> </code> </entry> <entry>  Next </entry> </row>
+<row> <entry> <code>    <keycap>  N </keycap> </code> </entry> <entry>  Next </entry> </row>
+<row> <entry> <code>    <keycap> equal </keycap> </code> </entry> <entry>  Zoom in </entry> </row>
+<row> <entry> <code>    <keycap> plus </keycap> </code> </entry> <entry>  Zoom in </entry> </row>
+<row> <entry> <code>    <keycap> minus </keycap> </code> </entry> <entry>  Zoom out </entry> </row>
+<row> <entry> <code>    <keycap>  X </keycap> </code> </entry> <entry>  Zoom to fit </entry> </row>
+<row> <entry> <code>    <keycap> KP_Multiply </keycap> </code> </entry> <entry>  Zoom to fit </entry> </row>
+<row> <entry> <code>    <keycap>  Z </keycap> </code> </entry> <entry>  Zoom 1:1 </entry> </row>
+<row> <entry> <code>    <keycap> KP_Divide </keycap> </code> </entry> <entry>  Zoom 1:1 </entry> </row>
+<row> <entry> <code>    <keycap> 1 </keycap> </code> </entry> <entry>  Zoom 1:1 </entry> </row>
+<row> <entry> <code>    <keycap>  2 </keycap> </code> </entry> <entry>  Zoom 2:1 </entry> </row>
+<row> <entry> <code>    <keycap>  3 </keycap> </code> </entry> <entry>  Zoom 3:1 </entry> </row>
+<row> <entry> <code>    <keycap>  4 </keycap> </code> </entry> <entry>  Zoom 4:1 </entry> </row>
+<row> <entry> <code>    <keycap>  7 </keycap> </code> </entry> <entry>  Zoom 1:4 </entry> </row>
+<row> <entry> <code>    <keycap>  8 </keycap> </code> </entry> <entry>  Zoom 1:3 </entry> </row>
+<row> <entry> <code>    <keycap>  9 </keycap> </code> </entry> <entry>  Zoom 1:2 </entry> </row>
+<row> <entry> <code>    <keycap>  W </keycap> </code> </entry> <entry>  Zoom fit window width </entry> </row>
+<row> <entry> <code>    <keycap>  H </keycap> </code> </entry> <entry>  Zoom fit window height </entry> </row>
+<row> <entry> <code>    <keycap>  S </keycap> </code> </entry> <entry>  Toggle slideshow </entry> </row>
+<row> <entry> <code>    <keycap>  P </keycap> </code> </entry> <entry>  Pause slideshow </entry> </row>
+<row> <entry> <code>    <keycap>  R </keycap> </code> </entry> <entry>  Reload image </entry> </row>
+<row> <entry> <code>    <keycap>  F </keycap> </code> </entry> <entry>  Full screen </entry> </row>
+<row> <entry> <code>    <keycap>  V </keycap> </code> </entry> <entry>  Fullscreen </entry> </row>
+<row> <entry> <code>    <keycap> F11 </keycap> </code> </entry> <entry>  Fullscreen </entry> </row>
+<row> <entry> <code>    <keycap>  I </keycap> </code> </entry> <entry>  Image overlay </entry> </row>
+<row> <entry> <code>    <keycap> Escape </keycap> </code> </entry> <entry>  Exit fullscreen </entry> </row>
+<row> <entry> <code>    <keycap> Escape </keycap> </code> </entry> <entry>  Close window </entry> </row>
+<row> <entry> <code>   Shift + <keycap>  G </keycap> </code> </entry> <entry>  Desaturate </entry> </row>
+<row> <entry> <code>   Shift + <keycap>  P </keycap> </code> </entry> <entry>  Print </entry> </row> </tbody></tgroup></table>
index 5c2d2d5..956aa6b 100644 (file)
@@ -2,12 +2,17 @@
 <section id="GuideReferenceKeyboardShortcuts">
   <title id="titleGuideReferenceKeyboardShortcuts">Keyboard and Mouse Shortcuts</title>
   <para>
-    The tables below shows the defaults for keyboard shortcuts. The current settings for all shortcuts may be found in the
+    The tables below shows the defaults for keyboard shortcuts. The current settings for shortcuts may be found in the
     <link linkend="GuideOptionsKeyboard" endterm="titleGuideOptionsKeyboard" />
     dialogue.
+    <para />
+    Only the main window shortcuts can be redefined in
+    <link linkend="GuideOptionsKeyboard" endterm="titleGuideOptionsKeyboard" />
+    . The shortcuts in other windows are fixed.
   </para>
+  <note>In the list below, KP means KeyPad</note>
   <section id="AllWindows">
-    <title>Keyboard shortcuts in all windows</title>
+    <title>Keyboard shortcuts in all windows, where relevant</title>
     <table frame="all">
       <title>Standard keyboard shortcuts</title>
       <tgroup cols="3" rowsep="1" colsep="1">
             <entry>
               <keycap>/</keycap>
             </entry>
-            <entry/>
+            <entry />
             <entry>Search and Run Commands.</entry>
           </row>
         </tbody>
       </tgroup>
     </table>
   </section>
-  <section id="mainKeyboard">
-    <title>Main window keyboard shortcuts</title>
+  <section id="MainWindow">
+    <title>Main window programmable keyboard shortcuts</title>
+    <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="GuideReferenceMainWindowShortcuts.xml" />
+  </section>
+  <section id="CollectionsKeyboardShortcuts">
+    <title>Collections window non-programmable keyboard shortcuts</title>
+    <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="GuideReferenceCollectionsShortcuts.xml" />
+  </section>
+  <section id="DuplicatesKeyboardShortcuts">
+    <title>Duplicates window non-programmable keyboard shortcuts</title>
+    <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="GuideReferenceDuplicatesShortcuts.xml" />
+  </section>
+  <section id="ImageViewKeyboardShortcuts">
+    <title>Image window non-programmable keyboard shortcuts</title>
+    <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="GuideReferenceImageViewShortcuts.xml" />
+  </section>
+  <section id="PanViewKeyboardShortcuts">
+    <title>Pan window non-programmable keyboard shortcuts</title>
+    <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="GuideReferencePanViewShortcuts.xml" />
+  </section>
+  <section id="SearchKeyboardShortcuts">
+    <title>Search window non-programmable keyboard shortcuts</title>
+    <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="GuideReferenceSearchShortcuts.xml" />
+  </section>
+  <section id="MouseActions">
+    <title>Mouse actions</title>
     <table frame="all">
-      <title>
-        <link linkend="GuideMainWindow">Main window</link>
-        keyboard shortcuts
-      </title>
-      <tgroup cols="3" rowsep="1" colsep="1">
+      <tgroup cols="2" rowsep="1" colsep="1">
         <thead>
           <row>
-            <entry>Shortcut</entry>
             <entry>Mouse</entry>
             <entry>Action</entry>
           </row>
         </thead>
         <tbody>
-          <row colsep="0">
-            <entry colsep="0">
-              <emphasis role="strong">Image Navigation</emphasis>
-            </entry>
-            <entry colsep="0" />
-            <entry />
-          </row>
           <row>
-            <entry>
-              <keycap>PageDown</keycap>
-            </entry>
             <entry>
               <code>Left Click</code>
               ,
                 </para>
               </footnote>
             </entry>
-            <entry>Change to next image.</entry>
+            <entry>Next image.</entry>
           </row>
           <row>
-            <entry>
-              <keycap>PageUp</keycap>
-            </entry>
             <entry>
               <code>Middle Click</code>
               ,
               <code>Mouse Wheel up</code>
               <footnoteref linkend='ref1' />
             </entry>
-            <entry>Change to previous image.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Home</keycap>
-            </entry>
-            <entry />
-            <entry>Change to first image.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>End</keycap>
-            </entry>
-            <entry />
-            <entry>Change to last image.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Space</keycap>
-            </entry>
-            <entry />
-            <entry>Change to next image.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Backspace</keycap>
-            </entry>
-            <entry />
-            <entry>Change to previous image.</entry>
-          </row>
-          <row rowsep="0">
-            <entry colsep="0" />
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-          <row>
-            <entry colsep="0">
-              <emphasis role="strong">Image viewing</emphasis>
-              (image has keyboard focus. Refer also to
-              <link linkend="MouseWheelMode">Mouse Wheel Mode</link>
-              )
-            </entry>
-            <entry colsep="0" />
-            <entry colsep="0" />
+            <entry>Previous image.</entry>
           </row>
           <row>
-            <entry>
-              <keycap>Arrow key</keycap>
-            </entry>
             <entry>
               <code>Left click and Drag</code>
               <footnoteref linkend='ref1' />
           </row>
           <row>
             <entry>
-              <code>Shift + Arrows</code>
+              <code>Ctrl + Mouse Wheel up</code>
             </entry>
-            <entry />
-            <entry>Pan Image faster.</entry>
+            <entry>Zoom image in.</entry>
           </row>
           <row>
             <entry>
-              <code>Ctrl + Arrow key</code>
+              <code>Ctrl + Mouse Wheel down</code>
             </entry>
-            <entry />
-            <entry>Pan to respective edge of image.</entry>
+            <entry>Zoom image out.</entry>
           </row>
           <row>
-            <entry />
             <entry>
               <code>Mouse button 8</code>
               <footnote id='ref2'>
             <entry>Forward</entry>
           </row>
           <row>
-            <entry />
             <entry>
               <code>Mouse button 9</code>
               <footnoteref linkend='ref2' />
             <entry>Back</entry>
           </row>
           <row>
-            <entry />
             <entry>
-              <code>Shift + right-click</code>
+              <code>Control + left-click</code>
             </entry>
             <entry>Smooth scroll</entry>
           </row>
+        </tbody>
+      </tgroup>
+    </table>
+  </section>
+  <section id="ArrowKeys">
+    <title>Arrow keys actions</title>
+    <table frame="all">
+      <tgroup cols="2" rowsep="1" colsep="1">
+        <thead>
           <row>
-            <entry>
-              <keycap>]</keycap>
-            </entry>
-            <entry />
-            <entry>Rotate image clockwise 90 degrees.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>[</keycap>
-            </entry>
-            <entry />
-            <entry>Rotate image counterclockwise 90 degree.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Shift + R</code>
-            </entry>
-            <entry />
-            <entry>Rotate image 180 degrees.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Shift + M</code>
-            </entry>
-            <entry />
-            <entry>Flip image horizontally (mirror).</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Shift + F</code>
-            </entry>
-            <entry />
-            <entry>Flip image vertically.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>+</keycap>
-              ,
-              <keycap>=</keycap>
-            </entry>
-            <entry>
-              <code>Ctrl + Mouse Wheel up</code>
-            </entry>
-            <entry>Zoom image in.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>-</keycap>
-            </entry>
-            <entry>
-              <code>Ctrl + Mouse Wheel down</code>
-            </entry>
-            <entry>Zoom image out.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Z</keycap>
-            </entry>
-            <entry />
-            <entry>Reset zoom to original size (1:1).</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>X</keycap>
-            </entry>
-            <entry />
-            <entry>Fit image to window size.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>W</keycap>
-            </entry>
-            <entry />
-            <entry>Zoom image to fit window width.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>H</keycap>
-            </entry>
-            <entry />
-            <entry>Zoom image to fit window height.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>1</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 1:1</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>2</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 2:1</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>3</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 3:1</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>4</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 4:1</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>7</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 1:4</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>8</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 1:3</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>9</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 1:2</entry>
-          </row>
-          <row rowsep="0">
-            <entry colsep="0" />
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-          <row>
-            <entry colsep="0">
-              <emphasis role="strong">For files with multiple pages e.g. tiff files</emphasis>
-            </entry>
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>Home</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Go to first page</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>End</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Go to last page</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>PageUp</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Go to previous page</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>PageDown</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Go to next page</entry>
-          </row>
-          <row>
-            <entry colsep="0">
-              <emphasis role="strong">File Menu</emphasis>
-            </entry>
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>N</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>New Window</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>C</keycap>
-            </entry>
-            <entry />
-            <entry>Open a new empty collection window.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>O</keycap>
-            </entry>
-            <entry />
-            <entry>Display open collection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>F3</keycap>
-            </entry>
-            <entry />
-            <entry>Open new search window.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Shift +
-                <keycap>P</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Open print dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>F</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Create new folder in current path.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>C</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Copy selected images, opens destination selection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>M</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Move selected images, opens destination selection dialog.</entry>
+            <entry>Shortcut</entry>
+            <entry>Action</entry>
           </row>
+        </thead>
+        <tbody>
           <row>
             <entry>
-              <code>
-                Ctrl +
-                <keycap>R</keycap>
-              </code>
+              <keycap>Arrow key</keycap>
             </entry>
-            <entry />
-            <entry>Rename selected images, opens rename dialog.</entry>
+            <entry>Pan image.</entry>
           </row>
           <row>
             <entry>
-              <code>
-                Ctrl +
-                <keycap>D</keycap>
-              </code>
+              <code>Shift + Arrow key</code>
             </entry>
-            <entry />
-            <entry>Move selected images to trash bin.</entry>
+            <entry>Pan Image faster.</entry>
           </row>
           <row>
             <entry>
-              <code>Shift + Delete</code>
+              <code>Ctrl + Arrow key</code>
             </entry>
-            <entry />
-            <entry>Permanently delete selected images.</entry>
+            <entry>Pan to respective edge of image.</entry>
           </row>
           <row>
             <entry>
-              <code>
-                Ctrl +
-                <keycap>W</keycap>
-              </code>
+              <code>Alt + Right Arrow</code>
             </entry>
-            <entry />
-            <entry>Close window, Geeqie exits when last window is closed.</entry>
+            <entry>Next split pane.</entry>
           </row>
           <row>
             <entry>
-              <code>
-                Ctrl +
-                <keycap>Q</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Quit Geeqie.</entry>
-          </row>
-          <row rowsep="0">
-            <entry colsep="0" />
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-          <row>
-            <entry colsep="0">
-              <emphasis role="strong">Edit Menu</emphasis>
+              <code>Alt + Left Arrow</code>
             </entry>
-            <entry colsep="0" />
-            <entry colsep="0" />
+            <entry>Previous split pane.</entry>
           </row>
           <row>
             <entry>
-              <code>
-                Ctrl +
-                <keycap>O</keycap>
-              </code>
+              <code>Alt + Up Arrow</code>
             </entry>
-            <entry />
-            <entry>Open Geeqie preferences window.</entry>
+            <entry>Up or previous split pane.</entry>
           </row>
           <row>
             <entry>
-              <code>
-                Ctrl +
-                <keycap>S</keycap>
-              </code>
+              <code>Alt + Down Arrow</code>
             </entry>
-            <entry />
-            <entry>Save metadata</entry>
-          </row>
-          <row rowsep="0">
-            <entry colsep="0" />
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-          <row>
-            <entry colsep="0">
-              <emphasis role="strong">Select Menu</emphasis>
-            </entry>
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-          <row>
-            <entry>
-              <keycap>1</keycap>
-              ...
-              <keycap>6</keycap>
-            </entry>
-            <entry />
-            <entry>Toggle mark 1 ... 6</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>1</keycap>
-              </code>
-              ...
-              <code>
-                Ctrl +
-                <keycap>6</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Select mark 1 ... 6</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>A</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Select all images.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl + SHIFT +
-                <keycap>A</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Unselect all images.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl + SHIFT +
-                <keycap>I</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Invert selection.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Alt +
-                <keycap>R</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle rectangular selection mode in icon view.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>M</keycap>
-            </entry>
-            <entry />
-            <entry>Show marks.</entry>
-          </row>
-          <row rowsep="0">
-            <entry colsep="0" />
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-          <row>
-            <entry colsep="0">
-              <emphasis role="strong">View Menu</emphasis>
-            </entry>
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-          <row>
-            <entry>
-              <keycap>T</keycap>
-            </entry>
-            <entry />
-            <entry>Toggle display of thumbnails when in list view.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>L</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Display file list as detailed list view.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>I</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Display file list as icon view.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>T</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle folder display between list and tree views.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>R</keycap>
-            </entry>
-            <entry />
-            <entry>Refresh file list.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>L</keycap>
-            </entry>
-            <entry />
-            <entry>Toggle floating of file display.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>H</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle hiding of file display.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>E</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle EXIF sidebar.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Shift +
-                <keycap>S</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle Sort Manager sidebar.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>K</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle Keywords sidebar.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Shift +
-                <keycap>E</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle highlighting of pixels that are over or under exposed.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>V</keycap>
-            </entry>
-            <entry />
-            <entry>Toggle full screen.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>I</keycap>
-            </entry>
-            <entry />
-            <entry>Toggle information overlay.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>S</keycap>
-            </entry>
-            <entry />
-            <entry>Toggle slideshow.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>P</keycap>
-            </entry>
-            <entry />
-            <entry>Pause slideshow.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>=</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Slideshow faster.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>-</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Slideshow slower.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>E</keycap>
-            </entry>
-            <entry />
-            <entry>Split panes horizontal.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>U</keycap>
-            </entry>
-            <entry />
-            <entry>Split panes vertical.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Y</keycap>
-            </entry>
-            <entry />
-            <entry>Single pane.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Alt + Right Arrow</code>
-            </entry>
-            <entry />
-            <entry>Next split pane.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Alt + Left Arrow</code>
-            </entry>
-            <entry />
-            <entry>Previous split pane.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Alt + Up Arrow</code>
-            </entry>
-            <entry />
-            <entry>Up or previous split pane.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Alt + Down Arrow</code>
-            </entry>
-            <entry />
             <entry>Down or next split pane.</entry>
           </row>
         </tbody>
       </tgroup>
     </table>
   </section>
-  <section id="CollectionsKeyboardShortcuts">
-    <title>Collections keyboard shortcuts</title>
-    <table frame="all">
-      <title>
-        <link linkend="GuideCollections">Collections window</link>
-        keyboard shortcuts
-      </title>
-      <tgroup cols="3" rowsep="1" colsep="1">
-        <thead>
-          <row>
-            <entry>Shortcut</entry>
-            <entry>Mouse</entry>
-            <entry>Action</entry>
-          </row>
-        </thead>
-        <tbody>
-          <entry colsep="0">
-            <emphasis role="strong">Collection Window</emphasis>
-          </entry>
-          <entry colsep="0" />
-          <entry colsep="0" />
-          <row>
-            <entry>
-              <keycap>Arrows</keycap>
-            </entry>
-            <entry />
-            <entry>Move selection.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Shift + Arrow key</code>
-            </entry>
-            <entry />
-            <entry>Select multiple images.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Alt +
-                <keycap>R</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle rectangular selection mode.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Space</keycap>
-            </entry>
-            <entry />
-            <entry>Select only image with focus.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Ctrl + Space</code>
-            </entry>
-            <entry />
-            <entry>Toggle selection of image with focus.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Home</keycap>
-            </entry>
-            <entry />
-            <entry>Move focus to first image.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>End</keycap>
-            </entry>
-            <entry />
-            <entry>Move focus to last image.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>A</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Select all images.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl + Shift +
-                <keycap>A</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Unselect all images.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Delete</keycap>
-            </entry>
-            <entry />
-            <entry>Remove selected image from collection, does not delete image from disk.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>L</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Add images from main window's file list.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>T</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle display of icon filenames.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>N</keycap>
-            </entry>
-            <entry />
-            <entry>Sort collection by name.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>D</keycap>
-            </entry>
-            <entry />
-            <entry>Sort collection by file date.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>B</keycap>
-            </entry>
-            <entry />
-            <entry>Sort collection by file size.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>P</keycap>
-            </entry>
-            <entry />
-            <entry>Sort collection by file path.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>I</keycap>
-            </entry>
-            <entry />
-            <entry>Sort collection by natural numerical order.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Enter</keycap>
-            </entry>
-            <entry />
-            <entry>View image with focus in main window.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>V</keycap>
-            </entry>
-            <entry />
-            <entry>View image with focus in new window.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Shift +
-                <keycap>P</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Open print dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>S</keycap>
-            </entry>
-            <entry />
-            <entry>Save collection.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>S</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Save collection as, opens destination dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>A</keycap>
-            </entry>
-            <entry />
-            <entry>Append to collection, opens append dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>C</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Copy selected images, opens destination selection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>M</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Move selected images, opens destination selection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>R</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Rename selected images, opens rename dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>D</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Delete selected images.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>W</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Close collection window.</entry>
-          </row>
-          <row rowsep="0">
-            <entry colsep="0" />
-            <entry colsep="0" />
-            <entry colsep="0" />
-          </row>
-        </tbody>
-      </tgroup>
-    </table>
-  </section>
-  <section id="DuplicatesKeyboardShortcuts">
-    <title>Duplicates keyboard shortcuts</title>
-    <table frame="all">
-      <title>
-        <link linkend="GuideImageSearchFindingDuplicates">Duplicates window</link>
-        keyboard shortcuts
-      </title>
-      <tgroup cols="3" rowsep="1" colsep="1">
-        <thead>
-          <row>
-            <entry>Shortcut</entry>
-            <entry>Mouse</entry>
-            <entry>Action</entry>
-          </row>
-        </thead>
-        <tbody>
-          <row>
-            <entry>
-              <keycap>0</keycap>
-            </entry>
-            <entry />
-            <entry>Select none.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>1</keycap>
-            </entry>
-            <entry />
-            <entry>Select group 1 duplicates.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>2</keycap>
-            </entry>
-            <entry />
-            <entry>Select group 2 duplicates.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>C</keycap>
-            </entry>
-            <entry />
-            <entry>Open new collection window and add selected images.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>L</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Add images from main window's list.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>V</keycap>
-            </entry>
-            <entry />
-            <entry>View selected item in new window.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>T</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle thumbnails.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>A</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Select all.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl + shift +
-                <keycap>A</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Deselect all.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>C</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Copy selected images, opens destination selection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>M</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Move selected images, opens destination selection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>R</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Rename selected images, opens rename dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>D</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Delete selected images.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Ctrl + Delete</code>
-            </entry>
-            <entry />
-            <entry>Remove all items from list.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>W</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Close window.</entry>
-          </row>
-          <row>
-            <entry />
-            <entry>
-              <code>Ctrl + shift + right-click</code>
-            </entry>
-            <entry>Show debug info.</entry>
-          </row>
-        </tbody>
-      </tgroup>
-    </table>
-  </section>
-  <section id="SearchKeyboardShortcuts">
-    <title>Search keyboard shortcuts</title>
-    <table frame="all">
-      <title>
-        <link linkend="GuideImageSearchSearch">Search window</link>
-        keyboard shortcuts
-      </title>
-      <tgroup cols="3" rowsep="1" colsep="1">
-        <thead>
-          <row>
-            <entry>Shortcut</entry>
-            <entry>Mouse</entry>
-            <entry>Action</entry>
-          </row>
-        </thead>
-        <tbody>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>C</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Copy selected images, opens destination selection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>M</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Move selected images, opens destination selection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>R</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Rename selected images, opens rename dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>D</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Delete selected images.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>A</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Select all.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl + shift +
-                <keycap>A</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Deselect all.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Delete</code>
-            </entry>
-            <entry />
-            <entry>Remove selected items from list.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>Ctrl + Delete</code>
-            </entry>
-            <entry />
-            <entry>Remove all items from list.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>V</keycap>
-            </entry>
-            <entry />
-            <entry>View selected item in new window.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>C</keycap>
-            </entry>
-            <entry />
-            <entry>Open new collection window and add selected images.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>T</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Toggle thumbnails.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>W</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Close window.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>Enter</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Start/Stop search.</entry>
-          </row>
-        </tbody>
-      </tgroup>
-    </table>
-  </section>
-  <section id="PanViewKeyboardShortcuts">
-    <title>Pan view keyboard shortcuts</title>
-    <table frame="all">
-      <title>
-        <link linkend="GuideOtherWindowsPanView">Pan View window</link>
-        keyboard shortcuts
-      </title>
-      <tgroup cols="3" rowsep="1" colsep="1">
-        <thead>
-          <row>
-            <entry>Shortcut</entry>
-            <entry>Mouse</entry>
-            <entry>Action</entry>
-          </row>
-        </thead>
-        <tbody>
-          <row>
-            <entry>
-              <keycap>Arrow key</keycap>
-            </entry>
-            <entry>
-              <code>Left click and Drag</code>
-              <footnoteref linkend='ref1' />
-            </entry>
-            <entry>Scroll display.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Page Up</keycap>
-            </entry>
-            <entry />
-            <entry>Scroll display half screen up.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Page Down</keycap>
-            </entry>
-            <entry />
-            <entry>Scroll display half screen down.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Home</keycap>
-            </entry>
-            <entry />
-            <entry>Scroll display half screen left.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>End</keycap>
-            </entry>
-            <entry />
-            <entry>Scroll display half screen right.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>F</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Display Find search bar.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>/</keycap>
-            </entry>
-            <entry />
-            <entry>Display Find search bar.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>G</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Start search.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>F11, F, V</keycap>
-            </entry>
-            <entry />
-            <entry>Toggle Fullscreen.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Esc</keycap>
-            </entry>
-            <entry />
-            <entry>Exit fullscreen or clear search bar.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>+</keycap>
-              ,
-              <keycap>=</keycap>
-            </entry>
-            <entry>
-              <code>Ctrl + Mouse Wheel up</code>
-            </entry>
-            <entry>Zoom image in.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>-</keycap>
-            </entry>
-            <entry>
-              <code>Ctrl + Mouse Wheel down</code>
-            </entry>
-            <entry>Zoom image out.</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>Z</keycap>
-            </entry>
-            <entry />
-            <entry>Reset zoom to original size (1:1).</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>1</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 1:1</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>2</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 2:1</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>3</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 3:1</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>4</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 4:1</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>7</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 1:4</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>8</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 1:3</entry>
-          </row>
-          <row>
-            <entry>
-              <keycap>9</keycap>
-            </entry>
-            <entry />
-            <entry>Set zoom to 1:2</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>C</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Copy selected image, opens destination selection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>M</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Move selected image, opens destination selection dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>R</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Rename selected image, opens rename dialog.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>D</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Delete selected image.</entry>
-          </row>
-          <row>
-            <entry>
-              <code>
-                Ctrl +
-                <keycap>W</keycap>
-              </code>
-            </entry>
-            <entry />
-            <entry>Close window.</entry>
-          </row>
-        </tbody>
-      </tgroup>
-    </table>
-  </section>
 </section>
diff --git a/doc/docbook/GuideReferenceMainWindowShortcuts.xml b/doc/docbook/GuideReferenceMainWindowShortcuts.xml
new file mode 100644 (file)
index 0000000..71b803b
--- /dev/null
@@ -0,0 +1,143 @@
+<table frame="all">
+
+<title>
+
+ <link linkend="GuideMainWindow">Main window</link> 
+keyboard shortcuts
+
+</title>
+
+<tgroup cols="2" rowsep="1" colsep="1">
+
+<thead>
+
+<row>
+
+<entry>Shortcut</entry>
+
+<entry>Action</entry>
+
+</row>
+
+</thead>
+
+<tbody>
+
+ <row> <entry> <code> <keycap> Ctrl + C </keycap> </code> </entry> <entry> Copy </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + M </keycap> </code> </entry> <entry> Move </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + R </keycap> </code> </entry> <entry> Rename </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + D </keycap> </code> </entry> <entry> Move to Trash </entry> </row>
+<row> <entry> <code> <keycap> Delete </keycap> </code> </entry> <entry> Move to Trash </entry> </row>
+<row> <entry> <code> <keycap> KP_Delete </keycap> </code> </entry> <entry> Move to Trash </entry> </row>
+<row> <entry> <code> <keycap> Shift + Delete </keycap> </code> </entry> <entry> Delete </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + A </keycap> </code> </entry> <entry> Select all </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + Shift + A </keycap> </code> </entry> <entry> Select none </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + Shift + I </keycap> </code> </entry> <entry> Invert Selection </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + W </keycap> </code> </entry> <entry> Close window </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + Q </keycap> </code> </entry> <entry> Quit </entry> </row>
+<row> <entry> <code> <keycap> Home </keycap> </code> </entry> <entry> First Image </entry> </row>
+<row> <entry> <code> <keycap> BackSpace </keycap> </code> </entry> <entry> Previous Image </entry> </row>
+<row> <entry> <code> <keycap> Page_Up </keycap> </code> </entry> <entry> Previous Image </entry> </row>
+<row> <entry> <code> <keycap> KP_Page_Up </keycap> </code> </entry> <entry> Previous Image </entry> </row>
+<row> <entry> <code> <keycap> space </keycap> </code> </entry> <entry> Next Image </entry> </row>
+<row> <entry> <code> <keycap> Page_Down </keycap> </code> </entry> <entry> Next Image </entry> </row>
+<row> <entry> <code> <keycap> KP_Page_Down </keycap> </code> </entry> <entry> Next Image </entry> </row>
+<row> <entry> <code> <keycap> End </keycap> </code> </entry> <entry> Last Image </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + N </keycap> </code> </entry> <entry> New window (default </entry> </row>
+<row> <entry> <code> <keycap> C </keycap> </code> </entry> <entry> New collection </entry> </row>
+<row> <entry> <code> <keycap> O </keycap> </code> </entry> <entry> Open collection </entry> </row>
+<row> <entry> <code> <keycap> F3 </keycap> </code> </entry> <entry> Search </entry> </row>
+<row> <entry> <code> <keycap> D </keycap> </code> </entry> <entry> Find duplicates </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + J </keycap> </code> </entry> <entry> Pan view </entry> </row>
+<row> <entry> <code> <keycap> Shift + P </keycap> </code> </entry> <entry> Print </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + F </keycap> </code> </entry> <entry> New folder </entry> </row>
+<row> <entry> <code> <keycap> Alt + KP_0 </keycap> </code> </entry> <entry> Rating 0 </entry> </row>
+<row> <entry> <code> <keycap> Alt + KP_1 </keycap> </code> </entry> <entry> Rating 1 </entry> </row>
+<row> <entry> <code> <keycap> Alt + KP_2 </keycap> </code> </entry> <entry> Rating 2 </entry> </row>
+<row> <entry> <code> <keycap> Alt + KP_3 </keycap> </code> </entry> <entry> Rating 3 </entry> </row>
+<row> <entry> <code> <keycap> Alt + KP_4 </keycap> </code> </entry> <entry> Rating 4 </entry> </row>
+<row> <entry> <code> <keycap> Alt + KP_5 </keycap> </code> </entry> <entry> Rating 5 </entry> </row>
+<row> <entry> <code> <keycap> Alt + KP_Subtract </keycap> </code> </entry> <entry> Rating -1 </entry> </row>
+<row> <entry> <code> <keycap> ] </keycap> </code> </entry> <entry> Image Rotate clockwise 90° </entry> </row>
+<row> <entry> <code> <keycap> [ </keycap> </code> </entry> <entry> Rotate counterclockwise 90° </entry> </row>
+<row> <entry> <code> <keycap> Shift + R </keycap> </code> </entry> <entry> Image Rotate 180° </entry> </row>
+<row> <entry> <code> <keycap> Shift + M </keycap> </code> </entry> <entry> Image Mirror </entry> </row>
+<row> <entry> <code> <keycap> Shift + F </keycap> </code> </entry> <entry> Image Flip </entry> </row>
+<row> <entry> <code> <keycap> Shift + O </keycap> </code> </entry> <entry> Image rotate Original state </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + O </keycap> </code> </entry> <entry> Preferences </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + S </keycap> </code> </entry> <entry> Save metadata </entry> </row>
+<row> <entry> <code> <keycap> Alt + K </keycap> </code> </entry> <entry> Keyword Autocomplete </entry> </row>
+<row> <entry> <code> <keycap> KP_Add </keycap> </code> </entry> <entry> Zoom in </entry> </row>
+<row> <entry> <code> <keycap> equal </keycap> </code> </entry> <entry> Zoom in </entry> </row>
+<row> <entry> <code> <keycap> minus </keycap> </code> </entry> <entry> Zoom out </entry> </row>
+<row> <entry> <code> <keycap> KP_Subtract </keycap> </code> </entry> <entry> Zoom out </entry> </row>
+<row> <entry> <code> <keycap> Z </keycap> </code> </entry> <entry> Zoom 1:1 </entry> </row>
+<row> <entry> <code> <keycap> KP_Divide </keycap> </code> </entry> <entry> Zoom 1:1 </entry> </row>
+<row> <entry> <code> <keycap> KP_Multiply </keycap> </code> </entry> <entry> Zoom to fit </entry> </row>
+<row> <entry> <code> <keycap> X </keycap> </code> </entry> <entry> Zoom to fit </entry> </row>
+<row> <entry> <code> <keycap> H </keycap> </code> </entry> <entry> Fit Horizontally </entry> </row>
+<row> <entry> <code> <keycap> W </keycap> </code> </entry> <entry> Fit Vertically </entry> </row>
+<row> <entry> <code> <keycap> plus </keycap> </code> </entry> <entry> Connected Zoom in </entry> </row>
+<row> <entry> <code> <keycap> Shift + KP_Add </keycap> </code> </entry> <entry> Connected Zoom in </entry> </row>
+<row> <entry> <code> <keycap> underscore </keycap> </code> </entry> <entry> Connected Zoom out </entry> </row>
+<row> <entry> <code> <keycap> Shift + KP_Subtract </keycap> </code> </entry> <entry> Connected Zoom out </entry> </row>
+<row> <entry> <code> <keycap> Shift + Z </keycap> </code> </entry> <entry> Connected Zoom 1:1 </entry> </row>
+<row> <entry> <code> <keycap> Shift + KP_Divide </keycap> </code> </entry> <entry> Connected Zoom 1:1 </entry> </row>
+<row> <entry> <code> <keycap> Shift + X </keycap> </code> </entry> <entry> Connected Zoom to fit </entry> </row>
+<row> <entry> <code> <keycap> Shift + KP_Multiply </keycap> </code> </entry> <entry> Connected Zoom to fit </entry> </row>
+<row> <entry> <code> <keycap> Shift + H </keycap> </code> </entry> <entry> Connected Fit Horizontally </entry> </row>
+<row> <entry> <code> <keycap> Shift + W </keycap> </code> </entry> <entry> Connected Fit Vertically </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + V </keycap> </code> </entry> <entry> View in new window </entry> </row>
+<row> <entry> <code> <keycap> F </keycap> </code> </entry> <entry> Full screen </entry> </row>
+<row> <entry> <code> <keycap> V </keycap> </code> </entry> <entry> Full screen </entry> </row>
+<row> <entry> <code> <keycap> F11 </keycap> </code> </entry> <entry> Full screen </entry> </row>
+<row> <entry> <code> <keycap> Escape </keycap> </code> </entry> <entry> Leave full screen </entry> </row>
+<row> <entry> <code> <keycap> Q </keycap> </code> </entry> <entry> Leave full screen </entry> </row>
+<row> <entry> <code> <keycap> I </keycap> </code> </entry> <entry> Cycle through Overlay modes </entry> </row>
+<row> <entry> <code> <keycap> K </keycap> </code> </entry> <entry> Cycle through histogram channels </entry> </row>
+<row> <entry> <code> <keycap> J </keycap> </code> </entry> <entry> Cycle through histogram modes </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + H </keycap> </code> </entry> <entry> Hide file list </entry> </row>
+<row> <entry> <code> <keycap> P </keycap> </code> </entry> <entry> Pause slideshow </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + equal </keycap> </code> </entry> <entry> Slideshow Faster </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + minus </keycap> </code> </entry> <entry> Slideshow Slower </entry> </row>
+<row> <entry> <code> <keycap> R </keycap> </code> </entry> <entry> Refresh </entry> </row>
+<row> <entry> <code> <keycap> F1 </keycap> </code> </entry> <entry> Help manual </entry> </row>
+<row> <entry> <code> <keycap> / </keycap> </code> </entry> <entry> Search commands by keyword and run them </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + E </keycap> </code> </entry> <entry> Exif window </entry> </row>
+<row> <entry> <code> <keycap> Alt + Right </keycap> </code> </entry> <entry> Next Split Pane </entry> </row>
+<row> <entry> <code> <keycap> Alt + Left </keycap> </code> </entry> <entry> Previous Split Pane </entry> </row>
+<row> <entry> <code> <keycap> Alt + Up </keycap> </code> </entry> <entry> Up Split Pane </entry> </row>
+<row> <entry> <code> <keycap> Alt + Down </keycap> </code> </entry> <entry> Down Split Pane </entry> </row>
+<row> <entry> <code> <keycap> T </keycap> </code> </entry> <entry> Show Thumbnails </entry> </row>
+<row> <entry> <code> <keycap> M </keycap> </code> </entry> <entry> Show Marks </entry> </row>
+<row> <entry> <code> <keycap> Shift + A </keycap> </code> </entry> <entry> Hide alpha channel </entry> </row>
+<row> <entry> <code> <keycap> L </keycap> </code> </entry> <entry> Float file list </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + K </keycap> </code> </entry> <entry> Info sidebar </entry> </row>
+<row> <entry> <code> <keycap> Shift + S </keycap> </code> </entry> <entry> Sort manager </entry> </row>
+<row> <entry> <code> <keycap> grave </keycap> </code> </entry> <entry> Hide Bars </entry> </row>
+<row> <entry> <code> <keycap> S </keycap> </code> </entry> <entry> Toggle slideshow </entry> </row>
+<row> <entry> <code> <keycap> Shift + G </keycap> </code> </entry> <entry> Toggle grayscale </entry> </row>
+<row> <entry> <code> <keycap> Alt + R </keycap> </code> </entry> <entry> Rectangular Selection </entry> </row>
+<row> <entry> <code> <keycap> A </keycap> </code> </entry> <entry> Toggle GIF animation </entry> </row>
+<row> <entry> <code> <keycap> Alt + X </keycap> </code> </entry> <entry> Toggle Exif rotate </entry> </row>
+<row> <entry> <code> <keycap> Shift + E </keycap> </code> </entry> <entry> Highlight over/under exposed </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + L </keycap> </code> </entry> <entry> View Images as List </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + I </keycap> </code> </entry> <entry> View Images as Icons </entry> </row>
+<row> <entry> <code> <keycap> Ctrl + T </keycap> </code> </entry> <entry> Toggle Folders View </entry> </row>
+<row> <entry> <code> <keycap> E </keycap> </code> </entry> <entry> Split panes horizontal. </entry> </row>
+<row> <entry> <code> <keycap> U </keycap> </code> </entry> <entry> Split panes vertical </entry> </row>
+<row> <entry> <code> <keycap> Y </keycap> </code> </entry> <entry> Single pane </entry> </row> 
+<row>
+<entry>
+<keycap>1</keycap>...<keycap>6</keycap>
+</entry>
+<entry>Toggle mark 1 ... 6</entry>
+</row>
+<row>
+<entry>
+<code>Ctrl +<keycap>1</keycap></code>...<code>Ctrl +<keycap>6</keycap></code>
+</entry>
+<entry>Select mark 1 ... 6</entry>
+</row>
+
+</tbody></tgroup></table>
diff --git a/doc/docbook/GuideReferencePanViewShortcuts.xml b/doc/docbook/GuideReferencePanViewShortcuts.xml
new file mode 100644 (file)
index 0000000..f7b6f8e
--- /dev/null
@@ -0,0 +1,62 @@
+<table frame="all">
+
+<title>
+
+ <link linkend="GuideOtherWindowsPanView">Pan view window</link> 
+keyboard shortcuts
+
+</title>
+
+<tgroup cols="2" rowsep="1" colsep="1">
+
+<thead>
+
+<row>
+
+<entry>Shortcut</entry>
+
+<entry>Action</entry>
+
+</row>
+
+</thead>
+
+<tbody>
+
+ <row> <entry> <code>  Ctrl + <keycap>  C </keycap> </code> </entry> <entry>  Copy </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  M </keycap> </code> </entry> <entry>  Move </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  R </keycap> </code> </entry> <entry>  Rename </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  D </keycap> </code> </entry> <entry>  Move to Trash </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  W </keycap> </code> </entry> <entry>  Close window </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  F </keycap> </code> </entry> <entry>  Display Find search bar </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  G </keycap> </code> </entry> <entry>  Start search </entry> </row>
+<row> <entry> <code>    <keycap> Escape </keycap> </code> </entry> <entry>  Exit fullscreen </entry> </row>
+<row> <entry> <code>    <keycap> Escape </keycap> </code> </entry> <entry>  Hide Find search bar </entry> </row>
+<row> <entry> <code>    <keycap> equal </keycap> </code> </entry> <entry>  Zoom in </entry> </row>
+<row> <entry> <code>    <keycap> plus </keycap> </code> </entry> <entry>  Zoom in </entry> </row>
+<row> <entry> <code>    <keycap> minus </keycap> </code> </entry> <entry>  Zoom out </entry> </row>
+<row> <entry> <code>    <keycap> Z </keycap> </code> </entry> <entry>  Zoom 1:1 </entry> </row>
+<row> <entry> <code>    <keycap> 1 </keycap> </code> </entry> <entry>  Zoom 1:1 </entry> </row>
+<row> <entry> <code>    <keycap> KP_Divide </keycap> </code> </entry> <entry>  Zoom 1:1 </entry> </row>
+<row> <entry> <code>    <keycap>  2 </keycap> </code> </entry> <entry>  Zoom 2:1 </entry> </row>
+<row> <entry> <code>    <keycap>  3 </keycap> </code> </entry> <entry>  Zoom 3:1 </entry> </row>
+<row> <entry> <code>    <keycap>  4 </keycap> </code> </entry> <entry>  Zoom 4:1 </entry> </row>
+<row> <entry> <code>    <keycap>  7 </keycap> </code> </entry> <entry>  Zoom 1:4 </entry> </row>
+<row> <entry> <code>    <keycap>  8 </keycap> </code> </entry> <entry>  Zoom 1:3 </entry> </row>
+<row> <entry> <code>    <keycap>  9 </keycap> </code> </entry> <entry>  Zoom 1:2 </entry> </row>
+<row> <entry> <code>    <keycap>  F </keycap> </code> </entry> <entry>  Full screen </entry> </row>
+<row> <entry> <code>    <keycap>  V </keycap> </code> </entry> <entry>  Full screen </entry> </row>
+<row> <entry> <code>    <keycap> F11 </keycap> </code> </entry> <entry>  Full screen </entry> </row>
+<row> <entry> <code>    <keycap>  / </keycap> </code> </entry> <entry>  Display Find search bar </entry> </row>
+<row> <entry> <code>    <keycap> Left </keycap> </code> </entry> <entry>  Scroll left </entry> </row>
+<row> <entry> <code>    <keycap> Right </keycap> </code> </entry> <entry>  Scroll right </entry> </row>
+<row> <entry> <code>    <keycap> Up </keycap> </code> </entry> <entry>  Scroll up </entry> </row>
+<row> <entry> <code>    <keycap> Down </keycap> </code> </entry> <entry>  Scroll down </entry> </row>
+<row> <entry> <code>   Shift + <keycap> Left </keycap> </code> </entry> <entry>  Scroll left faster </entry> </row>
+<row> <entry> <code>   Shift + <keycap> Right </keycap> </code> </entry> <entry>  Scroll right faster </entry> </row>
+<row> <entry> <code>   Shift + <keycap> Up </keycap> </code> </entry> <entry>  Scroll up faster </entry> </row>
+<row> <entry> <code>   Shift + <keycap> Down </keycap> </code> </entry> <entry>  Scroll down faster </entry> </row>
+<row> <entry> <code>    <keycap> Page_Up </keycap> </code> </entry> <entry>  Scroll display half screen up </entry> </row>
+<row> <entry> <code>    <keycap> Page_Down </keycap> </code> </entry> <entry>  Scroll display half screen down </entry> </row>
+<row> <entry> <code>    <keycap> Home </keycap> </code> </entry> <entry>  Scroll display half screen left </entry> </row>
+<row> <entry> <code>    <keycap> End </keycap> </code> </entry> <entry>  Scroll display half screen right </entry> </row> </tbody></tgroup></table>
diff --git a/doc/docbook/GuideReferenceSearchShortcuts.xml b/doc/docbook/GuideReferenceSearchShortcuts.xml
new file mode 100644 (file)
index 0000000..004f0dd
--- /dev/null
@@ -0,0 +1,41 @@
+<table frame="all">
+
+<title>
+
+ <link linkend="GuideImageSearchSearch">Search window</link> 
+keyboard shortcuts
+
+</title>
+
+<tgroup cols="2" rowsep="1" colsep="1">
+
+<thead>
+
+<row>
+
+<entry>Shortcut</entry>
+
+<entry>Action</entry>
+
+</row>
+
+</thead>
+
+<tbody>
+
+ <row> <entry> <code>  Ctrl + <keycap>  C </keycap> </code> </entry> <entry>  Copy </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  M </keycap> </code> </entry> <entry>  Move </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  R </keycap> </code> </entry> <entry>  Rename </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  D </keycap> </code> </entry> <entry>  Move to Trash </entry> </row>
+<row> <entry> <code>   Shift + <keycap> Delete </keycap> </code> </entry> <entry>  Delete </entry> </row>
+<row> <entry> <code>    <keycap> Delete </keycap> </code> </entry> <entry>  Remove </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  A </keycap> </code> </entry> <entry>  Select all </entry> </row>
+<row> <entry> <code>   Ctrl + Shift + <keycap>  A </keycap> </code> </entry> <entry>  Select none </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap> Delete </keycap> </code> </entry> <entry>  Clear </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  T </keycap> </code> </entry> <entry>  Toggle thumbs </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap>  W </keycap> </code> </entry> <entry>  Close window </entry> </row>
+<row> <entry> <code>    <keycap> Return </keycap> </code> </entry> <entry>  View </entry> </row>
+<row> <entry> <code>    <keycap>  V </keycap> </code> </entry> <entry>  View in new window </entry> </row>
+<row> <entry> <code>    <keycap>  C </keycap> </code> </entry> <entry>  Collection from selection </entry> </row>
+<row> <entry> <code>   Ctrl + <keycap> Return </keycap> </code> </entry> <entry>  Start/stop search </entry> </row>
+<row> <entry> <code>    <keycap> F3 </keycap> </code> </entry> <entry>  Find duplicates </entry> </row> </tbody></tgroup></table>
index 6bf85df..f07dead 100644 (file)
@@ -70,6 +70,41 @@ enum {
 
 static void collection_table_populate_at_new_size(CollectTable *ct, gint w, gint h, gboolean force);
 
+/**
+ * This array must be kept in sync with the contents of:\n
+ * @link collection_table_press_key_cb @endlink \n
+ * @link collection_window_keypress @endlink \n
+ * @link collection_table_popup_menu @endlink
+ *
+ * See also @link hard_coded_window_keys @endlink
+ **/
+hard_coded_window_keys collection_window_keys[] = {
+       {GDK_CONTROL_MASK, 'C', N_("Copy")},
+       {GDK_CONTROL_MASK, 'M', N_("Move")},
+       {GDK_CONTROL_MASK, 'R', N_("Rename")},
+       {GDK_CONTROL_MASK, 'D', N_("Move to Trash")},
+       {GDK_CONTROL_MASK, 'W', N_("Close window")},
+       {0, GDK_KEY_Delete, N_("Remove")},
+       {0, GDK_KEY_Return, N_("View")},
+       {0, 'V', N_("View in new window")},
+       {GDK_CONTROL_MASK, 'A', N_("Select all")},
+       {GDK_CONTROL_MASK + GDK_SHIFT_MASK, 'A', N_("Select none")},
+       {GDK_MOD1_MASK, 'R', N_("Rectangular selection")},
+       {0, GDK_KEY_space, N_("Select single file")},
+       {GDK_CONTROL_MASK, GDK_KEY_space, N_("Toggle select image")},
+       {GDK_CONTROL_MASK, 'L', N_("Append from file selection")},
+       {0, 'A', N_("Append from collection")},
+       {0, 'S', N_("Save collection")},
+       {GDK_CONTROL_MASK, 'S', N_("Save collection as")},
+       {GDK_CONTROL_MASK, 'T', N_("Show filename text")},
+       {0, 'N', N_("Sort by name")},
+       {0, 'I', N_("Sort by number")},
+       {0, 'D', N_("Sort by date")},
+       {0, 'B', N_("Sort by size")},
+       {0, 'P', N_("Sort by path")},
+       {GDK_SHIFT_MASK, 'P', N_("Print")},
+       {0, 0, NULL}
+};
 
 /*
  *-------------------------------------------------------------------
@@ -952,9 +987,16 @@ static GtkWidget *collection_table_popup_menu(CollectTable *ct, gboolean over_ic
        GtkWidget *menu;
        GtkWidget *item;
        GtkWidget *submenu;
+       GtkAccelGroup *accel_group;
 
        menu = popup_menu_short_lived();
 
+       accel_group = gtk_accel_group_new();
+       gtk_menu_set_accel_group(GTK_MENU(menu), accel_group);
+
+       g_object_set_data(G_OBJECT(menu), "window_keys", collection_window_keys);
+       g_object_set_data(G_OBJECT(menu), "accel_group", accel_group);
+
        g_signal_connect(G_OBJECT(menu), "destroy",
                         G_CALLBACK(collection_table_popup_destroy_cb), ct);
 
index f051dcb..a573d1b 100644 (file)
@@ -140,6 +140,35 @@ static gboolean dupe_insert_in_list_cache(DupeWindow *dw, FileData *fd);
 static void dupe_match_link(DupeItem *a, DupeItem *b, gdouble rank);
 static gint dupe_match_link_exists(DupeItem *child, DupeItem *parent);
 
+/**
+ * This array must be kept in sync with the contents of:\n
+ *  @link dupe_window_keypress_cb() @endlink \n
+ *  @link dupe_menu_popup_main() @endlink
+ *
+ * See also @link hard_coded_window_keys @endlink
+ **/
+hard_coded_window_keys dupe_window_keys[] = {
+       {GDK_CONTROL_MASK, 'C', N_("Copy")},
+       {GDK_CONTROL_MASK, 'M', N_("Move")},
+       {GDK_CONTROL_MASK, 'R', N_("Rename")},
+       {GDK_CONTROL_MASK, 'D', N_("Move to Trash")},
+       {GDK_SHIFT_MASK, GDK_KEY_Delete, N_("Delete")},
+       {0, GDK_KEY_Delete, N_("Remove")},
+       {GDK_CONTROL_MASK, GDK_KEY_Delete, N_("Clear")},
+       {GDK_CONTROL_MASK, 'A', N_("Select all")},
+       {GDK_CONTROL_MASK + GDK_SHIFT_MASK, 'A', N_("Select none")},
+       {GDK_CONTROL_MASK, 'T', N_("Toggle thumbs")},
+       {GDK_CONTROL_MASK, 'W', N_("Close window")},
+       {0, GDK_KEY_Return, N_("View")},
+       {0, 'V', N_("View in new window")},
+       {0, 'C', N_("Collection from selection")},
+       {GDK_CONTROL_MASK, 'L', N_("Append list")},
+       {0, '0', N_("Select none")},
+       {0, '1', N_("Select group 1 duplicates")},
+       {0, '2', N_("Select group 2 duplicates")},
+       {0, 0, NULL}
+};
+
 /**
  * @brief The function run in threads for similarity checks
  * @param d1 #DupeQueueItem
@@ -3481,11 +3510,18 @@ static GtkWidget *dupe_menu_popup_main(DupeWindow *dw, DupeItem *di)
        GtkWidget *item;
        gint on_row;
        GList *editmenu_fd_list;
+       GtkAccelGroup *accel_group;
 
        on_row = (di != NULL);
 
        menu = popup_menu_short_lived();
 
+       accel_group = gtk_accel_group_new();
+       gtk_menu_set_accel_group(GTK_MENU(menu), accel_group);
+
+       g_object_set_data(G_OBJECT(menu), "window_keys", dupe_window_keys);
+       g_object_set_data(G_OBJECT(menu), "accel_group", accel_group);
+
        menu_item_add_sensitive(menu, _("_View"), on_row,
                                G_CALLBACK(dupe_menu_view_cb), dw);
        menu_item_add_stock_sensitive(menu, _("View in _new window"), GTK_STOCK_NEW, on_row,
@@ -3815,8 +3851,15 @@ static GtkWidget *dupe_menu_popup_second(DupeWindow *dw, DupeItem *di)
        GtkWidget *menu;
        gboolean notempty = (dw->second_list != NULL);
        gboolean on_row = (di != NULL);
+       GtkAccelGroup *accel_group;
 
        menu = popup_menu_short_lived();
+       accel_group = gtk_accel_group_new();
+       gtk_menu_set_accel_group(GTK_MENU(menu), accel_group);
+
+       g_object_set_data(G_OBJECT(menu), "window_keys", dupe_window_keys);
+       g_object_set_data(G_OBJECT(menu), "accel_group", accel_group);
+
        menu_item_add_sensitive(menu, _("_View"), on_row,
                                G_CALLBACK(dupe_second_menu_view_cb), dw);
        menu_item_add_stock_sensitive(menu, _("View in _new window"), GTK_STOCK_NEW, on_row,
@@ -4737,6 +4780,7 @@ DupeWindow *dupe_window_new()
        dw->controls_box = controls_box;
 
        dw->button_thumbs = gtk_check_button_new_with_label(_("Thumbnails"));
+       gtk_widget_set_tooltip_text(GTK_WIDGET(dw->button_thumbs), "Ctrl-T");
        dw->show_thumbs = options->duplicates_thumbnails;
        gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dw->button_thumbs), dw->show_thumbs);
        g_signal_connect(G_OBJECT(dw->button_thumbs), "toggled",
@@ -4795,6 +4839,7 @@ DupeWindow *dupe_window_new()
        gtk_widget_show(hbox);
 
        button = pref_button_new(NULL, GTK_STOCK_HELP, NULL, FALSE, G_CALLBACK(dupe_help_cb), NULL);
+       gtk_widget_set_tooltip_text(GTK_WIDGET(button), "F1");
        gtk_container_add(GTK_CONTAINER(hbox), button);
        gtk_widget_set_can_default(button, TRUE);
        gtk_widget_show(button);
@@ -4805,6 +4850,7 @@ DupeWindow *dupe_window_new()
        gtk_widget_show(button);
 
        button = pref_button_new(NULL, GTK_STOCK_CLOSE, NULL, FALSE, G_CALLBACK(dupe_window_close_cb), dw);
+       gtk_widget_set_tooltip_text(GTK_WIDGET(button), "Ctrl-W");
        gtk_container_add(GTK_CONTAINER(hbox), button);
        gtk_widget_set_can_default(button, TRUE);
        gtk_widget_grab_default(button);
@@ -5395,7 +5441,7 @@ static GtkWidget *submenu_add_export(GtkWidget *menu, GtkWidget **menu_item, GCa
        GtkWidget *item;
        GtkWidget *submenu;
 
-       item = menu_item_add(menu, _("Export"), NULL, NULL);
+       item = menu_item_add(menu, _("_Export"), NULL, NULL);
 
        submenu = gtk_menu_new();
        g_object_set_data(G_OBJECT(submenu), "submenu_data", data);
index c6a241b..7439926 100644 (file)
@@ -80,6 +80,66 @@ static void view_window_dnd_init(ViewWindow *vw);
 
 static void view_window_notify_cb(FileData *fd, NotifyType type, gpointer data);
 
+
+/**
+ * This array must be kept in sync with the contents of:\n
+ *  @link view_popup_menu() @endlink \n
+ *  @link view_window_key_press_cb() @endlink
+ * 
+ * See also @link hard_coded_window_keys @endlink
+ **/
+hard_coded_window_keys image_window_keys[] = {
+       {GDK_CONTROL_MASK, 'C', N_("Copy")},
+       {GDK_CONTROL_MASK, 'M', N_("Move")},
+       {GDK_CONTROL_MASK, 'R', N_("Rename")},
+       {GDK_CONTROL_MASK, 'D', N_("Move to Trash")},
+       {0, GDK_KEY_Delete, N_("Move to Trash")},
+       {GDK_SHIFT_MASK, GDK_KEY_Delete, N_("Delete")},
+       {GDK_CONTROL_MASK, 'W', N_("Close window")},
+       {GDK_SHIFT_MASK, 'R', N_("Rotate 180°")},
+       {GDK_SHIFT_MASK, 'M', N_("Rotate mirror")},
+       {GDK_SHIFT_MASK, 'F', N_("Rotate flip")},
+       {0, ']', N_(" Rotate counterclockwise 90°")},
+       {0, '[', N_(" Rotate clockwise 90°")},
+       {0, GDK_KEY_Page_Up, N_("Previous")},
+       {0, GDK_KEY_KP_Page_Up, N_("Previous")},
+       {0, GDK_KEY_BackSpace, N_("Previous")},
+       {0, 'B', N_("Previous")},
+       {0, GDK_KEY_Page_Down, N_("Next")},
+       {0, GDK_KEY_KP_Page_Down, N_("Next")},
+       {0, GDK_KEY_space, N_("Next")},
+       {0, 'N', N_("Next")},
+       {0, GDK_KEY_equal, N_("Zoom in")},
+       {0, GDK_KEY_plus, N_("Zoom in")},
+       {0, GDK_KEY_minus, N_("Zoom out")},
+       {0, 'X', N_("Zoom to fit")},
+       {0, GDK_KEY_KP_Multiply, N_("Zoom to fit")},
+       {0, 'Z', N_("Zoom 1:1")},
+       {0, GDK_KEY_KP_Divide, N_("Zoom 1:1")},
+       {0, GDK_KEY_1, N_("Zoom 1:1")},
+       {0, '2', N_("Zoom 2:1")},
+       {0, '3', N_("Zoom 3:1")},
+       {0, '4', N_("Zoom 4:1")},
+       {0, '7', N_("Zoom 1:4")},
+       {0, '8', N_("Zoom 1:3")},
+       {0, '9', N_("Zoom 1:2")},
+       {0, 'W', N_("Zoom fit window width")},
+       {0, 'H', N_("Zoom fit window height")},
+       {0, 'S', N_("Toggle slideshow")},
+       {0, 'P', N_("Pause slideshow")},
+       {0, 'R', N_("Reload image")},
+       {0, 'F', N_("Full screen")},
+       {0, 'V', N_("Fullscreen")},
+       {0, GDK_KEY_F11, N_("Fullscreen")},
+       {0, 'I', N_("Image overlay")},
+       {0, GDK_KEY_Escape, N_("Exit fullscreen")},
+       {0, GDK_KEY_Escape, N_("Close window")},
+       {GDK_SHIFT_MASK, 'G', N_("Desaturate")},
+       {GDK_SHIFT_MASK, 'P', N_("Print")},
+       {0, 0, NULL}
+};
+
+
 /*
  *-----------------------------------------------------------------------------
  * misc
@@ -1337,14 +1397,20 @@ static GtkWidget *view_popup_menu(ViewWindow *vw)
        GtkWidget *menu;
        GtkWidget *item;
        GList *editmenu_fd_list;
+       GtkAccelGroup *accel_group;
 
        menu = popup_menu_short_lived();
 
+       accel_group = gtk_accel_group_new();
+       gtk_menu_set_accel_group(GTK_MENU(menu), accel_group);
+
+       g_object_set_data(G_OBJECT(menu), "window_keys", image_window_keys);
+       g_object_set_data(G_OBJECT(menu), "accel_group", accel_group);
 
        menu_item_add_stock(menu, _("Zoom _in"), GTK_STOCK_ZOOM_IN, G_CALLBACK(view_zoom_in_cb), vw);
        menu_item_add_stock(menu, _("Zoom _out"), GTK_STOCK_ZOOM_OUT, G_CALLBACK(view_zoom_out_cb), vw);
        menu_item_add_stock(menu, _("Zoom _1:1"), GTK_STOCK_ZOOM_100, G_CALLBACK(view_zoom_1_1_cb), vw);
-       menu_item_add_stock(menu, _("Fit image to _window"), GTK_STOCK_ZOOM_FIT, G_CALLBACK(view_zoom_fit_cb), vw);
+       menu_item_add_stock(menu, _("Zoom to fit"), GTK_STOCK_ZOOM_FIT, G_CALLBACK(view_zoom_fit_cb), vw);
        menu_item_add_divider(menu);
 
        editmenu_fd_list = view_window_get_fd_list(vw);
@@ -1386,7 +1452,7 @@ static GtkWidget *view_popup_menu(ViewWindow *vw)
 
        if (vw->ss)
                {
-               menu_item_add(menu, _("_Stop slideshow"), G_CALLBACK(view_slideshow_stop_cb), vw);
+               menu_item_add(menu, _("Toggle _slideshow"), G_CALLBACK(view_slideshow_stop_cb), vw);
                if (slideshow_paused(vw->ss))
                        {
                        item = menu_item_add(menu, _("Continue slides_how"),
@@ -1400,7 +1466,7 @@ static GtkWidget *view_popup_menu(ViewWindow *vw)
                }
        else
                {
-               item = menu_item_add(menu, _("_Start slideshow"), G_CALLBACK(view_slideshow_start_cb), vw);
+               item = menu_item_add(menu, _("Toggle _slideshow"), G_CALLBACK(view_slideshow_start_cb), vw);
                gtk_widget_set_sensitive(item, (vw->list != NULL) || view_window_contains_collection(vw));
                item = menu_item_add(menu, _("Pause slides_how"), G_CALLBACK(view_slideshow_pause_cb), vw);
                gtk_widget_set_sensitive(item, FALSE);
index 949b817..9c38f1f 100644 (file)
@@ -766,16 +766,23 @@ static GtkWidget *layout_image_pop_menu(LayoutWindow *lw)
        const gchar *path;
        gboolean fullscreen;
        GList *editmenu_fd_list;
+       GtkAccelGroup *accel_group;
 
        path = layout_image_get_path(lw);
        fullscreen = layout_image_full_screen_active(lw);
 
        menu = popup_menu_short_lived();
 
+       accel_group = gtk_accel_group_new();
+       gtk_menu_set_accel_group(GTK_MENU(menu), accel_group);
+
+       g_object_set_data(G_OBJECT(menu), "window_keys", NULL);
+       g_object_set_data(G_OBJECT(menu), "accel_group", accel_group);
+
        menu_item_add_stock(menu, _("Zoom _in"), GTK_STOCK_ZOOM_IN, G_CALLBACK(li_pop_menu_zoom_in_cb), lw);
        menu_item_add_stock(menu, _("Zoom _out"), GTK_STOCK_ZOOM_OUT, G_CALLBACK(li_pop_menu_zoom_out_cb), lw);
        menu_item_add_stock(menu, _("Zoom _1:1"), GTK_STOCK_ZOOM_100, G_CALLBACK(li_pop_menu_zoom_1_1_cb), lw);
-       menu_item_add_stock(menu, _("Fit image to _window"), GTK_STOCK_ZOOM_FIT, G_CALLBACK(li_pop_menu_zoom_fit_cb), lw);
+       menu_item_add_stock(menu, _("Zoom to fit"), GTK_STOCK_ZOOM_FIT, G_CALLBACK(li_pop_menu_zoom_fit_cb), lw);
        menu_item_add_divider(menu);
 
        editmenu_fd_list = layout_image_get_fd_list(lw);
@@ -809,9 +816,9 @@ static GtkWidget *layout_image_pop_menu(LayoutWindow *lw)
        if (!path) gtk_widget_set_sensitive(item, FALSE);
        item = menu_item_add(menu, _("_Rename..."), G_CALLBACK(li_pop_menu_rename_cb), lw);
        if (!path) gtk_widget_set_sensitive(item, FALSE);
-       item = menu_item_add(menu, _("_Copy path"), G_CALLBACK(li_pop_menu_copy_path_cb), lw);
-       item = menu_item_add(menu, _("_Copy path unquoted"), G_CALLBACK(li_pop_menu_copy_path_unquoted_cb), lw);
-       item = menu_item_add(menu, _("Copy _image"), G_CALLBACK(li_pop_menu_copy_image_cb), lw);
+       item = menu_item_add(menu, _("_Copy path to clipboard"), G_CALLBACK(li_pop_menu_copy_path_cb), lw);
+       item = menu_item_add(menu, _("_Copy path unquoted to clipboard"), G_CALLBACK(li_pop_menu_copy_path_unquoted_cb), lw);
+       item = menu_item_add(menu, _("Copy _image to clipboard"), G_CALLBACK(li_pop_menu_copy_image_cb), lw);
        if (!path) gtk_widget_set_sensitive(item, FALSE);
        menu_item_add_divider(menu);
 
@@ -834,7 +841,7 @@ static GtkWidget *layout_image_pop_menu(LayoutWindow *lw)
 
        if (layout_image_slideshow_active(lw))
                {
-               menu_item_add(menu, _("_Stop slideshow"), G_CALLBACK(li_pop_menu_slide_stop_cb), lw);
+               menu_item_add(menu, _("Toggle _slideshow"), G_CALLBACK(li_pop_menu_slide_stop_cb), lw);
                if (layout_image_slideshow_paused(lw))
                        {
                        item = menu_item_add(menu, _("Continue slides_how"),
@@ -848,7 +855,7 @@ static GtkWidget *layout_image_pop_menu(LayoutWindow *lw)
                }
        else
                {
-               menu_item_add(menu, _("_Start slideshow"), G_CALLBACK(li_pop_menu_slide_start_cb), lw);
+               menu_item_add(menu, _("Toggle _slideshow"), G_CALLBACK(li_pop_menu_slide_start_cb), lw);
                item = menu_item_add(menu, _("Pause slides_how"), G_CALLBACK(li_pop_menu_slide_pause_cb), lw);
                gtk_widget_set_sensitive(item, FALSE);
                }
@@ -862,7 +869,7 @@ static GtkWidget *layout_image_pop_menu(LayoutWindow *lw)
                menu_item_add(menu, _("Exit _full screen"), G_CALLBACK(li_pop_menu_full_screen_cb), lw);
                }
 
-       menu_item_add_check(menu, _("_Animate"), lw->options.animate, G_CALLBACK(li_pop_menu_animate_cb), lw);
+       menu_item_add_check(menu, _("GIF _animation"), lw->options.animate, G_CALLBACK(li_pop_menu_animate_cb), lw);
 
        menu_item_add_divider(menu);
 
index d23c8ec..7077a67 100644 (file)
@@ -2443,7 +2443,12 @@ static void layout_menu_window_delete_cb(GtkWidget *widget, gpointer data)
  */
 
 #define CB G_CALLBACK
-
+/**
+ * tooltip is used as the description field in the Help manual shortcuts documentation
+ *
+ * struct GtkActionEntry:
+ *  name, stock_id, label, accelerator, tooltip, callback
+ */
 static GtkActionEntry menu_entries[] = {
   { "FileMenu",                NULL,                   N_("_File"),                            NULL,                   NULL,                                   NULL },
   { "GoMenu",          NULL,                   N_("_Go"),                              NULL,                   NULL,                                   NULL },
@@ -2464,6 +2469,18 @@ static GtkActionEntry menu_entries[] = {
   { "WindowsMenu",             NULL,           N_("_Windows"),                         NULL,                   NULL,                                   CB(layout_menu_windows_menu_cb)  },
   { "HelpMenu",                NULL,                   N_("_Help"),                            NULL,                   NULL,                                   NULL },
 
+  { "Copy",            GTK_STOCK_COPY,         N_("_Copy..."),                         "<control>C",           N_("Copy..."),                          CB(layout_menu_copy_cb) },
+  { "Move",    PIXBUF_INLINE_ICON_MOVE,                        N_("_Move..."),                         "<control>M",           N_("Move..."),                          CB(layout_menu_move_cb) },
+  { "Rename",  PIXBUF_INLINE_ICON_RENAME,      N_("_Rename..."),                       "<control>R",           N_("Rename..."),                        CB(layout_menu_rename_cb) },
+  { "Delete",  PIXBUF_INLINE_ICON_TRASH,       N_("Move to Trash..."),         "<control>D",   N_("Move to Trash..."),         CB(layout_menu_move_to_trash_cb) },
+  { "DeleteAlt1",      PIXBUF_INLINE_ICON_TRASH,N_("Move to Trash..."),        "Delete",               N_("Move to Trash..."),         CB(layout_menu_move_to_trash_key_cb) },
+  { "DeleteAlt2",      PIXBUF_INLINE_ICON_TRASH,N_("Move to Trash..."),        "KP_Delete",    N_("Move to Trash..."),         CB(layout_menu_move_to_trash_key_cb) },
+  { "PermanentDelete", GTK_STOCK_DELETE,       N_("Delete..."),                        "<shift>Delete",N_("Delete..."),                        CB(layout_menu_delete_cb) }, 
+  { "SelectAll",       PIXBUF_INLINE_ICON_SELECT_ALL,                  N_("Select _all"),                      "<control>A",           N_("Select all"),                       CB(layout_menu_select_all_cb) },
+  { "SelectNone",      PIXBUF_INLINE_ICON_SELECT_NONE,                 N_("Select _none"),                     "<control><shift>A",    N_("Select none"),                      CB(layout_menu_unselect_all_cb) },
+  { "SelectInvert",    PIXBUF_INLINE_ICON_SELECT_INVERT,                       N_("_Invert Selection"),                "<control><shift>I",    N_("Invert Selection"),                 CB(layout_menu_invert_selection_cb) },
+  { "CloseWindow",     GTK_STOCK_CLOSE,        N_("C_lose window"),                    "<control>W",           N_("Close window"),                     CB(layout_menu_close_cb) },
+  { "Quit",            GTK_STOCK_QUIT,         N_("_Quit"),                            "<control>Q",           N_("Quit"),                             CB(layout_menu_exit_cb) },
   { "FirstImage",      GTK_STOCK_GOTO_TOP,     N_("_First Image"),                     "Home",                 N_("First Image"),                      CB(layout_menu_image_first_cb) },
   { "PrevImage",       GTK_STOCK_GO_UP,        N_("_Previous Image"),                  "BackSpace",            N_("Previous Image"),                   CB(layout_menu_image_prev_cb) },
   { "PrevImageAlt1",   GTK_STOCK_GO_UP,        N_("_Previous Image"),                  "Page_Up",              N_("Previous Image"),                   CB(layout_menu_image_prev_cb) },
@@ -2487,7 +2504,7 @@ static GtkActionEntry menu_entries[] = {
   { "Home",            GTK_STOCK_HOME,         N_("_Home"),                    NULL,   N_("Home"),                             CB(layout_menu_home_cb) },
   { "Up",              GTK_STOCK_GO_UP,        N_("_Up"),                              NULL,   N_("Up one folder"),                            CB(layout_menu_up_cb) },
   { "NewWindow",       NULL,           N_("New window"),                       NULL,           N_("New window"),       CB(layout_menu_window_cb) },
-  { "NewWindowDefault",        NULL,   N_("default"),                  "<control>N",           N_("default"),  CB(layout_menu_window_default_cb)  },
+  { "NewWindowDefault",        NULL,   N_("default"),                  "<control>N",           N_("New window (default)"),     CB(layout_menu_window_default_cb)  },
   { "NewWindowFromCurrent",    NULL,   N_("from current"),                     NULL,           N_("from current"),     CB(layout_menu_window_from_current_cb)  },
   { "RenameWindow",    GTK_STOCK_EDIT,         N_("Rename window"),    NULL,   N_("Rename window"),    CB(layout_menu_window_rename_cb) },
   { "DeleteWindow",    GTK_STOCK_DELETE,               N_("Delete window"),    NULL,   N_("Delete window"),    CB(layout_menu_window_delete_cb) },
@@ -2499,20 +2516,10 @@ static GtkActionEntry menu_entries[] = {
   { "PanView", PIXBUF_INLINE_ICON_PANORAMA,    N_("Pa_n view"),                        "<control>J",           N_("Pan view"),                         CB(layout_menu_pan_cb) },
   { "Print",           GTK_STOCK_PRINT,        N_("_Print..."),                        "<shift>P",             N_("Print..."),                         CB(layout_menu_print_cb) },
   { "NewFolder",       GTK_STOCK_DIRECTORY,    N_("N_ew folder..."),                   "<control>F",           N_("New folder..."),                    CB(layout_menu_dir_cb) },
-  { "Copy",            GTK_STOCK_COPY,         N_("_Copy..."),                         "<control>C",           N_("Copy..."),                          CB(layout_menu_copy_cb) },
-  { "Move",    PIXBUF_INLINE_ICON_MOVE,                        N_("_Move..."),                         "<control>M",           N_("Move..."),                          CB(layout_menu_move_cb) },
-  { "Rename",  PIXBUF_INLINE_ICON_RENAME,      N_("_Rename..."),                       "<control>R",           N_("Rename..."),                        CB(layout_menu_rename_cb) },
-  { "Delete",  PIXBUF_INLINE_ICON_TRASH,       N_("Move to Trash..."),         "<control>D",   N_("Move to Trash..."),         CB(layout_menu_move_to_trash_cb) },
-  { "DeleteAlt1",      PIXBUF_INLINE_ICON_TRASH,N_("Move to Trash..."),        "Delete",               N_("Move to Trash..."),         CB(layout_menu_move_to_trash_key_cb) },
-  { "DeleteAlt2",      PIXBUF_INLINE_ICON_TRASH,N_("Move to Trash..."),        "KP_Delete",    N_("Move to Trash..."),         CB(layout_menu_move_to_trash_key_cb) },
-  { "PermanentDelete", GTK_STOCK_DELETE,       N_("Delete..."),                        "<shift>Delete",N_("Delete..."),                        CB(layout_menu_delete_cb) }, 
   { "EnableGrouping",  NULL,                   N_("Enable file _grouping"),            NULL,                   N_("Enable file grouping"),             CB(layout_menu_enable_grouping_cb) },
   { "DisableGrouping", NULL,                   N_("Disable file groupi_ng"),           NULL,                   N_("Disable file grouping"),            CB(layout_menu_disable_grouping_cb) },
   { "CopyPath",                NULL,                   N_("_Copy path to clipboard"),          NULL,                   N_("Copy path to clipboard"),           CB(layout_menu_copy_path_cb) },
   { "CopyPathUnquoted",                NULL,                   N_("_Copy path unquoted to clipboard"),         NULL,                   N_("Copy path unquoted to clipboard"),          CB(layout_menu_copy_path_unquoted_cb) },
-  { "CloseWindow",     GTK_STOCK_CLOSE,        N_("C_lose window"),                    "<control>W",           N_("Close window"),                     CB(layout_menu_close_cb) },
-  { "Quit",            GTK_STOCK_QUIT,         N_("_Quit"),                            "<control>Q",           N_("Quit"),                             CB(layout_menu_exit_cb) },
-  { "RotateCW",                PIXBUF_INLINE_ICON_CW,                  N_("_Rotate clockwise 90°"),           "bracketright",         N_("Image Rotate clockwise 90°"),                      CB(layout_menu_alter_90_cb) },
   { "Rating0",         NULL,                   N_("_Rating 0"),        "<alt>KP_0",    N_("Rating 0"),                 CB(layout_menu_rating_0_cb) },
   { "Rating1",         NULL,                   N_("_Rating 1"),        "<alt>KP_1",    N_("Rating 1"),                 CB(layout_menu_rating_1_cb) },
   { "Rating2",         NULL,                   N_("_Rating 2"),        "<alt>KP_2",    N_("Rating 2"),                 CB(layout_menu_rating_2_cb) },
@@ -2520,14 +2527,12 @@ static GtkActionEntry menu_entries[] = {
   { "Rating4",         NULL,                   N_("_Rating 4"),        "<alt>KP_4",    N_("Rating 4"),                 CB(layout_menu_rating_4_cb) },
   { "Rating5",         NULL,                   N_("_Rating 5"),        "<alt>KP_5",    N_("Rating 5"),                 CB(layout_menu_rating_5_cb) },
   { "RatingM1",                NULL,                   N_("_Rating -1"),       "<alt>KP_Subtract",     N_("Rating -1"),        CB(layout_menu_rating_m1_cb) },
+  { "RotateCW",                PIXBUF_INLINE_ICON_CW,                  N_("_Rotate clockwise 90°"),           "bracketright",         N_("Image Rotate clockwise 90°"),                      CB(layout_menu_alter_90_cb) },
   { "RotateCCW",       PIXBUF_INLINE_ICON_CCW, N_("Rotate _counterclockwise 90°"),            "bracketleft",          N_("Rotate counterclockwise 90°"),             CB(layout_menu_alter_90cc_cb) },
   { "Rotate180",       PIXBUF_INLINE_ICON_180, N_("Rotate 1_80°"),    "<shift>R",             N_("Image Rotate 180°"),                       CB(layout_menu_alter_180_cb) },
   { "Mirror",          PIXBUF_INLINE_ICON_MIRROR,      N_("_Mirror"),  "<shift>M",             N_("Image Mirror"),                             CB(layout_menu_alter_mirror_cb) },
   { "Flip",            PIXBUF_INLINE_ICON_FLIP,        N_("_Flip"),    "<shift>F",             N_("Image Flip"),                               CB(layout_menu_alter_flip_cb) },
   { "AlterNone",       PIXBUF_INLINE_ICON_ORIGINAL,    N_("_Original state"),  "<shift>O",             N_("Image rotate Original state"),                      CB(layout_menu_alter_none_cb) },
-  { "SelectAll",       PIXBUF_INLINE_ICON_SELECT_ALL,                  N_("Select _all"),                      "<control>A",           N_("Select all"),                       CB(layout_menu_select_all_cb) },
-  { "SelectNone",      PIXBUF_INLINE_ICON_SELECT_NONE,                 N_("Select _none"),                     "<control><shift>A",    N_("Select none"),                      CB(layout_menu_unselect_all_cb) },
-  { "SelectInvert",    PIXBUF_INLINE_ICON_SELECT_INVERT,                       N_("_Invert Selection"),                "<control><shift>I",    N_("Invert Selection"),                 CB(layout_menu_invert_selection_cb) },
   { "Preferences",     GTK_STOCK_PREFERENCES,  N_("P_references..."),                  "<control>O",           N_("Preferences..."),                   CB(layout_menu_config_cb) },
   { "Plugins",         GTK_STOCK_PREFERENCES,  N_("Configure _Plugins..."),            NULL,                   N_("Configure Plugins..."),             CB(layout_menu_editors_cb) },
   { "LayoutConfig",    GTK_STOCK_PREFERENCES,  N_("_Configure this window..."),        NULL,                   N_("Configure this window..."),         CB(layout_menu_layout_config_cb) },
@@ -2535,14 +2540,14 @@ static GtkActionEntry menu_entries[] = {
   { "Wallpaper",       NULL,                   N_("Set as _wallpaper"),                NULL,                   N_("Set as wallpaper"),                 CB(layout_menu_wallpaper_cb) },
   { "SaveMetadata",    GTK_STOCK_SAVE,         N_("_Save metadata"),                   "<control>S",           N_("Save metadata"),                    CB(layout_menu_metadata_write_cb) },
   { "KeywordAutocomplete",     NULL,   N_("Keyword autocomplete"),             "<alt>K",               N_("Keyword Autocomplete"),                     CB(layout_menu_keyword_autocomplete_cb) },
-  { "ZoomIn",          GTK_STOCK_ZOOM_IN,      N_("Zoom _in"),                         "equal",                N_("Zoom in"),                          CB(layout_menu_zoom_in_cb) },
   { "ZoomInAlt1",      GTK_STOCK_ZOOM_IN,      N_("Zoom _in"),                         "KP_Add",               N_("Zoom in"),                          CB(layout_menu_zoom_in_cb) },
+  { "ZoomIn",          GTK_STOCK_ZOOM_IN,      N_("Zoom _in"),                         "equal",                N_("Zoom in"),                          CB(layout_menu_zoom_in_cb) },
   { "ZoomOut",         GTK_STOCK_ZOOM_OUT,     N_("Zoom _out"),                        "minus",                N_("Zoom out"),                         CB(layout_menu_zoom_out_cb) },
   { "ZoomOutAlt1",     GTK_STOCK_ZOOM_OUT,     N_("Zoom _out"),                        "KP_Subtract",          N_("Zoom out"),                         CB(layout_menu_zoom_out_cb) },
   { "Zoom100",         GTK_STOCK_ZOOM_100,     N_("Zoom _1:1"),                        "Z",                    N_("Zoom 1:1"),                         CB(layout_menu_zoom_1_1_cb) },
   { "Zoom100Alt1",     GTK_STOCK_ZOOM_100,     N_("Zoom _1:1"),                        "KP_Divide",            N_("Zoom 1:1"),                         CB(layout_menu_zoom_1_1_cb) },
-  { "ZoomFit",         GTK_STOCK_ZOOM_FIT,     N_("_Zoom to fit"),                     "X",                    N_("Zoom to fit"),                      CB(layout_menu_zoom_fit_cb) },
   { "ZoomFitAlt1",     GTK_STOCK_ZOOM_FIT,     N_("_Zoom to fit"),                     "KP_Multiply",          N_("Zoom to fit"),                      CB(layout_menu_zoom_fit_cb) },
+  { "ZoomFit",         GTK_STOCK_ZOOM_FIT,     N_("_Zoom to fit"),                     "X",                    N_("Zoom to fit"),                      CB(layout_menu_zoom_fit_cb) },
   { "ZoomFillHor",     PIXBUF_INLINE_ICON_ZOOMFILLHOR, N_("Fit _Horizontally"),                "H",                    N_("Fit Horizontally"),                 CB(layout_menu_zoom_fit_hor_cb) },
   { "ZoomFillVert",    PIXBUF_INLINE_ICON_ZOOMFILLVERT,        N_("Fit _Vertically"),                  "W",                    N_("Fit Vertically"),                   CB(layout_menu_zoom_fit_vert_cb) },
   { "Zoom200",         GTK_STOCK_FILE,                 N_("Zoom _2:1"),                        NULL,                   N_("Zoom 2:1"),                         CB(layout_menu_zoom_2_1_cb) },
@@ -2582,7 +2587,7 @@ static GtkActionEntry menu_entries[] = {
   { "SlideShowFaster", GTK_STOCK_FILE, N_("Faster"),           "<control>equal",                       N_("Slideshow Faster"),                         CB(layout_menu_slideshow_faster_cb) },
   { "SlideShowSlower", GTK_STOCK_FILE, N_("Slower"),           "<control>minus",                       N_("Slideshow Slower"),                         CB(layout_menu_slideshow_slower_cb) },
   { "Refresh",         GTK_STOCK_REFRESH,      N_("_Refresh"),                         "R",                    N_("Refresh"),                          CB(layout_menu_refresh_cb) },
-  { "HelpContents",    GTK_STOCK_HELP,         N_("_Contents"),                        "F1",                   N_("Contents"),                         CB(layout_menu_help_cb) },
+  { "HelpContents",    GTK_STOCK_HELP,         N_("_Help manual"),                     "F1",                   N_("Help manual"),                              CB(layout_menu_help_cb) },
   { "HelpSearch",      NULL,           N_("On-line help search"),                      NULL,                   N_("On-line help search"),                              CB(layout_menu_help_search_cb) },
   { "HelpShortcuts",   NULL,                   N_("_Keyboard shortcuts"),              NULL,                   N_("Keyboard shortcuts"),               CB(layout_menu_help_keys_cb) },
   { "HelpKbd",         NULL,                   N_("_Keyboard map"),                    NULL,                   N_("Keyboard map"),                     CB(layout_menu_kbd_map_cb) },
@@ -2621,15 +2626,15 @@ static GtkToggleActionEntry menu_toggle_entries[] = {
   { "ImageHistogram",  NULL,                   N_("_Show Histogram"),                  NULL,                   N_("Show Histogram"),                   CB(layout_menu_histogram_cb),    FALSE },
   { "RectangularSelection",    PIXBUF_INLINE_ICON_SELECT_RECTANGLE,    N_("Rectangular Selection"),                    "<alt>R",                       N_("Rectangular Selection"),                    CB(layout_menu_rectangular_selection_cb),        FALSE },
   { "Animate", NULL,   N_("GIF _animation"),           "A",                    N_("Toggle GIF animation"),                     CB(layout_menu_animate_cb),      FALSE  },
-  { "ExifRotate",      GTK_STOCK_ORIENTATION_PORTRAIT,                 N_("_Exif rotate"),             "<alt>X",               N_("Exif rotate"),                      CB(layout_menu_exif_rotate_cb), FALSE },
+  { "ExifRotate",      GTK_STOCK_ORIENTATION_PORTRAIT,                 N_("_Exif rotate"),             "<alt>X",               N_("Toggle Exif rotate"),                       CB(layout_menu_exif_rotate_cb), FALSE },
   { "DrawRectangle",   PIXBUF_INLINE_ICON_DRAW_RECTANGLE,                      N_("Draw Rectangle"),           NULL,           N_("Draw Rectangle"),                   CB(layout_menu_select_rectangle_cb), FALSE },
-  { "OverUnderExposed",        PIXBUF_INLINE_ICON_EXPOSURE,    N_("Over/Under Exposed"),       "<shift>E",             N_("Over/Under Exposed"),               CB(layout_menu_select_overunderexposed_cb), FALSE },
+  { "OverUnderExposed",        PIXBUF_INLINE_ICON_EXPOSURE,    N_("Over/Under Exposed"),       "<shift>E",             N_("Highlight over/under exposed"),             CB(layout_menu_select_overunderexposed_cb), FALSE },
   { "SplitPaneSync",   PIXBUF_INLINE_SPLIT_PANE_SYNC,                  N_("Split Pane Sync"),  NULL,           N_("Split Pane Sync"),  CB(layout_menu_split_pane_sync_cb), FALSE },
 };
 
 static GtkRadioActionEntry menu_radio_entries[] = {
-  { "ViewList",                NULL,                   N_("Image _List"),                      "<control>L",           N_("View Images as List"),              FILEVIEW_LIST },
-  { "ViewIcons",       NULL,                   N_("I_cons"),                           "<control>I",           N_("View Images as Icons"),             FILEVIEW_ICON }
+  { "ViewList",                NULL,                   N_("Images as _List"),                  "<control>L",           N_("View Images as List"),              FILEVIEW_LIST },
+  { "ViewIcons",       NULL,                   N_("Images as I_cons"),                 "<control>I",           N_("View Images as Icons"),             FILEVIEW_ICON }
 };
 
 static GtkToggleActionEntry menu_view_dir_toggle_entries[] = {
@@ -2637,10 +2642,10 @@ static GtkToggleActionEntry menu_view_dir_toggle_entries[] = {
 };
 
 static GtkRadioActionEntry menu_split_radio_entries[] = {
-  { "SplitHorizontal", NULL,                   N_("_Horizontal"),                      "E",                    N_("Split Horizontal"),                 SPLIT_HOR },
-  { "SplitVertical",   NULL,                   N_("_Vertical"),                        "U",                    N_("Split Vertical"),                           SPLIT_VERT },
-  { "SplitQuad",       NULL,                   N_("_Quad"),                            NULL,                   N_("Split Quad"),                               SPLIT_QUAD },
-  { "SplitSingle",     NULL,                   N_("_Single"),                          "Y",                    N_("Split Single"),                             SPLIT_NONE }
+  { "SplitHorizontal", NULL,                   N_("_Horizontal"),                      "E",                    N_("Split panes horizontal."),                  SPLIT_HOR },
+  { "SplitVertical",   NULL,                   N_("_Vertical"),                        "U",                    N_("Split panes vertical"),                             SPLIT_VERT },
+  { "SplitQuad",       NULL,                   N_("_Quad"),                            NULL,                   N_("Split panes quad"),                         SPLIT_QUAD },
+  { "SplitSingle",     NULL,                   N_("_Single"),                          "Y",                    N_("Single pane"),                              SPLIT_NONE }
 };
 
 static GtkRadioActionEntry menu_color_radio_entries[] = {
index 64f6fa2..f57fffe 100644 (file)
@@ -116,7 +116,7 @@ GtkWidget *submenu_add_edit(GtkWidget *menu, GtkWidget **menu_item, GCallback fu
        GtkWidget *item;
        GtkWidget *submenu;
 
-       item = menu_item_add(menu, _("Plugins"), NULL, NULL);
+       item = menu_item_add(menu, _("_Plugins"), NULL, NULL);
 
        submenu = gtk_menu_new();
        g_object_set_data(G_OBJECT(submenu), "submenu_data", data);
@@ -345,22 +345,22 @@ gchar *alter_type_get_text(AlterType type)
        switch (type)
                {
                case ALTER_ROTATE_90:
-                       return _("_Rotate clockwise 90°");
+                       return _("Rotate clockwise 90°");
                        break;
                case ALTER_ROTATE_90_CC:
-                       return _("Rotate _counterclockwise 90°");
+                       return _("Rotate counterclockwise 90°");
                        break;
                case ALTER_ROTATE_180:
-                       return _("Rotate _180°");
+                       return _("Rotate 180°");
                        break;
                case ALTER_MIRROR:
-                       return _("_Mirror");
+                       return _("Mirror");
                        break;
                case ALTER_FLIP:
-                       return _("_Flip");
+                       return _("Flip");
                        break;
                case ALTER_NONE:
-                       return _("_Original state");
+                       return _("Original state");
                        break;
                default:
                        break;
@@ -413,7 +413,10 @@ static GtkWidget *real_submenu_add_alter(GtkWidget *menu, GCallback func, gpoint
 
 GtkWidget *submenu_add_alter(GtkWidget *menu, GCallback func, gpointer data)
 {
-       return real_submenu_add_alter(menu, func, data, NULL);
+       GtkAccelGroup *accel;
+
+       accel = gtk_accel_group_new();
+       return real_submenu_add_alter(menu, func, data, accel); //last accel gr
 }
 
 /*
index a17962e..7868eca 100644 (file)
@@ -87,6 +87,53 @@ static GtkWidget *pan_popup_menu(PanWindow *pw);
 
 static void pan_window_dnd_init(PanWindow *pw);
 
+/**
+ * This array must be kept in sync with the contents of:\n
+ * @link pan_window_key_press_cb @endlink \n
+ * @link pan_popup_menu @endlink
+ *
+ * See also @link hard_coded_window_keys @endlink
+ **/
+hard_coded_window_keys pan_view_window_keys[] = {
+       {GDK_CONTROL_MASK, 'C', N_("Copy")},
+       {GDK_CONTROL_MASK, 'M', N_("Move")},
+       {GDK_CONTROL_MASK, 'R', N_("Rename")},
+       {GDK_CONTROL_MASK, 'D', N_("Move to Trash")},
+       {GDK_CONTROL_MASK, 'W', N_("Close window")},
+       {GDK_CONTROL_MASK, 'F', N_("Display Find search bar")},
+       {GDK_CONTROL_MASK, 'G', N_("Start search")},
+       {0, GDK_KEY_Escape, N_("Exit fullscreen")},
+       {0, GDK_KEY_Escape, N_("Hide Find search bar")},
+       {0, GDK_KEY_equal, N_("Zoom in")},
+       {0, GDK_KEY_plus, N_("Zoom in")},
+       {0, GDK_KEY_minus, N_("Zoom out")},
+       {0, GDK_KEY_Z, N_("Zoom 1:1")},
+       {0, GDK_KEY_1, N_("Zoom 1:1")},
+       {0, GDK_KEY_KP_Divide, N_("Zoom 1:1")},
+       {0, '2', N_("Zoom 2:1")},
+       {0, '3', N_("Zoom 3:1")},
+       {0, '4', N_("Zoom 4:1")},
+       {0, '7', N_("Zoom 1:4")},
+       {0, '8', N_("Zoom 1:3")},
+       {0, '9', N_("Zoom 1:2")},
+       {0, 'F', N_("Full screen")},
+       {0, 'V', N_("Full screen")},
+       {0, GDK_KEY_F11, N_("Full screen")},
+       {0, '/', N_("Display Find search bar")},
+       {0, GDK_KEY_Left, N_("Scroll left")},
+       {0, GDK_KEY_Right, N_("Scroll right")},
+       {0, GDK_KEY_Up, N_("Scroll up")},
+       {0, GDK_KEY_Down, N_("Scroll down")},
+       {GDK_SHIFT_MASK, GDK_KEY_Left, N_("Scroll left faster")},
+       {GDK_SHIFT_MASK, GDK_KEY_Right, N_("Scroll right faster")},
+       {GDK_SHIFT_MASK, GDK_KEY_Up, N_("Scroll up faster")},
+       {GDK_SHIFT_MASK, GDK_KEY_Down, N_("Scroll down faster")},
+       {0, GDK_KEY_Page_Up, N_("Scroll display half screen up")},
+       {0, GDK_KEY_Page_Down, N_("Scroll display half screen down")},
+       {0, GDK_KEY_Home, N_("Scroll display half screen left")},
+       {0, GDK_KEY_End, N_("Scroll display half screen right")},
+       {0, 0, NULL}
+};
 
 /*
  *-----------------------------------------------------------------------------
@@ -2315,11 +2362,17 @@ static GtkWidget *pan_popup_menu(PanWindow *pw)
        GtkWidget *item;
        gboolean active, video;
        GList *editmenu_fd_list;
+       GtkAccelGroup *accel_group;
 
        active = (pw->click_pi != NULL);
        video = (active && pw->click_pi->fd && pw->click_pi->fd->format_class == FORMAT_CLASS_VIDEO);
 
        menu = popup_menu_short_lived();
+       accel_group = gtk_accel_group_new();
+       gtk_menu_set_accel_group(GTK_MENU(menu), accel_group);
+
+       g_object_set_data(G_OBJECT(menu), "window_keys", pan_view_window_keys);
+       g_object_set_data(G_OBJECT(menu), "accel_group", accel_group);
 
        menu_item_add_stock_sensitive(menu, _("_Play"), GTK_STOCK_MEDIA_PLAY, video,
                            G_CALLBACK(pan_play_cb), pw);
@@ -2352,9 +2405,9 @@ static GtkWidget *pan_popup_menu(PanWindow *pw)
                                G_CALLBACK(pan_move_cb), pw);
        menu_item_add_sensitive(menu, _("_Rename..."), active,
                                G_CALLBACK(pan_rename_cb), pw);
-       menu_item_add_sensitive(menu, _("_Copy path"), active,
+       menu_item_add_sensitive(menu, _("_Copy path to clipboard"), active,
                                G_CALLBACK(pan_copy_path_cb), pw);
-       menu_item_add_sensitive(menu, _("_Copy path unquoted"), active,
+       menu_item_add_sensitive(menu, _("_Copy path unquoted to clipboard"), active,
                                G_CALLBACK(pan_copy_path_unquoted_cb), pw);
 
        menu_item_add_divider(menu);
index f46e94d..0aaf658 100644 (file)
@@ -340,6 +340,35 @@ static void search_notify_cb(FileData *fd, NotifyType type, gpointer data);
 static void search_start_cb(GtkWidget *widget, gpointer data);
 void mfd_list_free(GList *list);
 
+
+/**
+ * This array must be kept in sync with the contents of:\n
+ * @link search_result_press_cb @endlink \n
+ * @link search_window_keypress_cb @endlink \n
+ * @link search_result_menu @endlink
+ * 
+ * See also @link hard_coded_window_keys @endlink
+ **/
+
+hard_coded_window_keys search_window_keys[] = {
+       {GDK_CONTROL_MASK, 'C', N_("Copy")},
+       {GDK_CONTROL_MASK, 'M', N_("Move")},
+       {GDK_CONTROL_MASK, 'R', N_("Rename")},
+       {GDK_CONTROL_MASK, 'D', N_("Move to Trash")},
+       {GDK_SHIFT_MASK, GDK_KEY_Delete, N_("Delete")},
+       {0, GDK_KEY_Delete, N_("Remove")},
+       {GDK_CONTROL_MASK, 'A', N_("Select all")},
+       {GDK_CONTROL_MASK + GDK_SHIFT_MASK, 'A', N_("Select none")},
+       {GDK_CONTROL_MASK, GDK_KEY_Delete, N_("Clear")},
+       {GDK_CONTROL_MASK, 'T', N_("Toggle thumbs")},
+       {GDK_CONTROL_MASK, 'W', N_("Close window")},
+       {0, GDK_KEY_Return, N_("View")},
+       {0, 'V', N_("View in new window")},
+       {0, 'C', N_("Collection from selection")},
+       {GDK_CONTROL_MASK, GDK_KEY_Return, N_("Start/stop search")},
+       {0, GDK_KEY_F3, N_("Find duplicates")},
+       {0, 0, NULL}
+};
 /*
  *-------------------------------------------------------------------
  * utils
@@ -1107,8 +1136,14 @@ static GtkWidget *search_result_menu(SearchData *sd, gboolean on_row, gboolean e
        GtkWidget *item;
        GList *editmenu_fd_list;
        gboolean video;
+       GtkAccelGroup *accel_group;
 
        menu = popup_menu_short_lived();
+       accel_group = gtk_accel_group_new();
+       gtk_menu_set_accel_group(GTK_MENU(menu), accel_group);
+
+       g_object_set_data(G_OBJECT(menu), "window_keys", search_window_keys);
+       g_object_set_data(G_OBJECT(menu), "accel_group", accel_group);
 
        video = (on_row && sd->click_fd && sd->click_fd->format_class == FORMAT_CLASS_VIDEO);
        menu_item_add_stock_sensitive(menu, _("_Play"), GTK_STOCK_MEDIA_PLAY, video,
@@ -3674,6 +3709,7 @@ void search_new(FileData *dir_fd, FileData *example_file)
 
        sd->button_thumbs = pref_checkbox_new(hbox, _("Thumbnails"), FALSE,
                                              G_CALLBACK(search_thumb_toggle_cb), sd);
+       gtk_widget_set_tooltip_text(GTK_WIDGET(sd->button_thumbs), "Ctrl-T");
 
        frame = gtk_frame_new(NULL);
        DEBUG_NAME(frame);
@@ -3700,16 +3736,20 @@ void search_new(FileData *dir_fd, FileData *example_file)
        gtk_widget_show(sd->spinner);
 
        sd->button_help = pref_button_new(hbox, GTK_STOCK_HELP, NULL, FALSE, G_CALLBACK(search_window_help_cb), sd);
+       gtk_widget_set_tooltip_text(GTK_WIDGET(sd->button_help), "F1");
        gtk_widget_set_sensitive(sd->button_help, TRUE);
        pref_spacer(hbox, PREF_PAD_BUTTON_GAP);
        sd->button_start = pref_button_new(hbox, GTK_STOCK_FIND, NULL, FALSE,
                                           G_CALLBACK(search_start_cb), sd);
+       gtk_widget_set_tooltip_text(GTK_WIDGET(sd->button_start), "Ctrl-Return");
        pref_spacer(hbox, PREF_PAD_BUTTON_GAP);
        sd->button_stop = pref_button_new(hbox, GTK_STOCK_STOP, NULL, FALSE,
                                          G_CALLBACK(search_start_cb), sd);
+       gtk_widget_set_tooltip_text(GTK_WIDGET(sd->button_stop), "Ctrl-Return");
        gtk_widget_set_sensitive(sd->button_stop, FALSE);
        pref_spacer(hbox, PREF_PAD_BUTTON_GAP);
        sd->button_close = pref_button_new(hbox, GTK_STOCK_CLOSE, NULL, FALSE, G_CALLBACK(search_window_close_cb), sd);
+       gtk_widget_set_tooltip_text(GTK_WIDGET(sd->button_close), "Ctrl-W");
        gtk_widget_set_sensitive(sd->button_close, TRUE);
 
        search_result_thumb_enable(sd, TRUE);
index 2d9901b..167c59a 100644 (file)
@@ -1118,5 +1118,21 @@ struct _CommandLine
        gboolean new_instance;
 };
 
+/**
+ * @struct _hard_coded_window_keys
+ * @brief hard coded window shortcut keys
+ * 
+ * Used for two purposes:\n
+ * to display the shortcuts keys in popup menus\n
+ * used by ./doc/create-shortcuts-xml.sh to generate shortcut documentation in the Help files
+ * 
+ */
+typedef struct _hard_coded_window_keys hard_coded_window_keys;
+struct _hard_coded_window_keys {
+       GdkModifierType mask; /**< modifier key mask */
+       guint key_value;  /**< GDK_keyval */
+       gchar *text;  /**< menu item label - NULL if end of list */
+};
+
 #endif
 /* vim: set shiftwidth=8 softtabstop=0 cindent cinoptions={1s: */
index 9e0505c..56426d2 100644 (file)
@@ -30,6 +30,8 @@
 
 #include <gtk/gtk.h>
 
+#include "main.h"
+#include "layout.h"
 #include "ui_menu.h"
 
 
  *-----------------------------------------------------------------------------
  */
 
+/**
+ * @brief Add accelerator key to a window popup menu
+ * @param menu
+ * @param accel_group
+ * @param window_keys
+ *
+ * This is used only so that the user can see the applicable
+ * shortcut key displayed in the menu. The actual handling of
+ * the keystroke is done elsewhere in the code.
+ */
+static void menu_item_add_accelerator(GtkWidget *menu, GtkAccelGroup *accel_group, hard_coded_window_keys *window_keys)
+{
+       gchar *label;
+       gchar *label_text;
+       gchar **label_stripped;
+       gint i = 0;
+
+       label = g_strdup(gtk_menu_item_get_label(GTK_MENU_ITEM(menu)));
+
+       pango_parse_markup(label, -1, '_', NULL, &label_text, NULL, NULL);
+
+       label_stripped = g_strsplit(label_text, "...", 2);
+
+       while (window_keys[i].text != NULL)
+               {
+               if (g_strcmp0(window_keys[i].text, label_stripped[0]) == 0)
+                       {
+                       gtk_widget_add_accelerator(menu, "activate", accel_group, window_keys[i].key_value, (GdkModifierType)window_keys[i].mask, GTK_ACCEL_VISIBLE);
+
+                       break;
+                       }
+               i++;
+               }
+
+       g_free(label);
+       g_free(label_text);
+       g_strfreev(label_stripped);
+}
+
+/**
+ * @brief Callback for the actions GList sort function
+ * @param a
+ * @param b
+ * @returns
+ *
+ * Sort the action entries so that the non-shifted and non-control
+ * entries are at the start of the list. The user then sees the basic
+ * non-modified key shortcuts displayed in the menus.
+ */
+static gint actions_sort_cb(gconstpointer a, gconstpointer b)
+{
+       const gchar *accel_path_a;
+       GtkAccelKey key_a;
+       const gchar *accel_path_b;
+       GtkAccelKey key_b;
+
+       accel_path_a = gtk_action_get_accel_path(GTK_ACTION(a));
+       accel_path_b = gtk_action_get_accel_path(GTK_ACTION(b));
+
+       if (accel_path_a && gtk_accel_map_lookup_entry(accel_path_a, &key_a) && accel_path_b && gtk_accel_map_lookup_entry(accel_path_b, &key_b))
+               {
+               if (key_a.accel_mods < key_b.accel_mods) return -1;
+               if (key_a.accel_mods > key_b.accel_mods) return 1;
+               }
+
+       return 0;
+}
+
+/**
+ * @brief Add accelerator key to main window popup menu
+ * @param menu
+ * @param accel_group
+ *
+ * This is used only so that the user can see the applicable
+ * shortcut key displayed in the menu. The actual handling of
+ * the keystroke is done elsewhere in the code.
+ */
+static void menu_item_add_main_window_accelerator(GtkWidget *menu, GtkAccelGroup *accel_group)
+{
+       gchar *menu_label;
+       gchar *menu_label_text;
+       gchar *action_label;
+       gchar *action_label_text;
+       LayoutWindow *lw;
+       GList *groups;
+       GList *actions;
+       GtkAction *action;
+       const gchar *accel_path;
+       GtkAccelKey key;
+
+       menu_label = g_strdup(gtk_menu_item_get_label(GTK_MENU_ITEM(menu)));
+
+       pango_parse_markup(menu_label, -1, '_', NULL, &menu_label_text, NULL, NULL);
+
+       lw = layout_window_list->data; /* get the actions from the first window, it should not matter, they should be the same in all windows */
+
+       g_assert(lw && lw->ui_manager);
+       groups = gtk_ui_manager_get_action_groups(lw->ui_manager);
+       actions = gtk_action_group_list_actions(GTK_ACTION_GROUP(groups->data)); // Only the first group required
+       actions = g_list_sort(actions, actions_sort_cb);
+
+       while (actions)
+               {
+               action = GTK_ACTION(actions->data);
+               accel_path = gtk_action_get_accel_path(action);
+               if (accel_path && gtk_accel_map_lookup_entry(accel_path, &key))
+                       {
+                       g_object_get(action, "label", &action_label, NULL);
+
+                       pango_parse_markup(action_label, -1, '_', NULL, &action_label_text, NULL, NULL);
+
+                       if (g_strcmp0(action_label_text, menu_label_text) == 0)
+                               {
+                               if (key.accel_key != 0)
+                                       {
+                                       gtk_widget_add_accelerator(menu, "activate", accel_group, key.accel_key, key.accel_mods, GTK_ACCEL_VISIBLE);
+
+                                       break;
+                                       }
+                               }
+
+                       g_free(action_label_text);
+                       g_free(action_label);
+                       }
+               actions = actions->next;
+               }
+
+       g_free(menu_label);
+       g_free(menu_label_text);
+}
+
 static void menu_item_finish(GtkWidget *menu, GtkWidget *item, GCallback func, gpointer data)
 {
        if (func) g_signal_connect(G_OBJECT(item), "activate", func, data);
@@ -50,8 +183,22 @@ GtkWidget *menu_item_add(GtkWidget *menu, const gchar *label,
                         GCallback func, gpointer data)
 {
        GtkWidget *item;
+       GtkAccelGroup *accel_group;
+       hard_coded_window_keys *window_keys;
 
        item = gtk_menu_item_new_with_mnemonic(label);
+       window_keys = g_object_get_data(G_OBJECT(menu), "window_keys");
+       accel_group = g_object_get_data(G_OBJECT(menu), "accel_group");
+
+       if (accel_group && window_keys)
+               {
+               menu_item_add_accelerator(item, accel_group, window_keys);
+               }
+       else if (accel_group)
+               {
+               menu_item_add_main_window_accelerator(item, accel_group);
+               }
+
        menu_item_finish(menu, item, func, data);
 
        return item;
@@ -62,10 +209,25 @@ GtkWidget *menu_item_add_stock(GtkWidget *menu, const gchar *label, const gchar
 {
        GtkWidget *item;
        GtkWidget *image;
+       GtkAccelGroup *accel_group;
+       hard_coded_window_keys *window_keys;
 
        item = gtk_image_menu_item_new_with_mnemonic(label);
+       window_keys = g_object_get_data(G_OBJECT(menu), "window_keys");
+       accel_group = g_object_get_data(G_OBJECT(menu), "accel_group");
+
        image = gtk_image_new_from_stock(stock_id, GTK_ICON_SIZE_MENU);
        gtk_image_menu_item_set_image(GTK_IMAGE_MENU_ITEM(item), image);
+
+       if (accel_group && window_keys)
+               {
+               menu_item_add_accelerator(item, accel_group, window_keys);
+               }
+       else if (accel_group)
+               {
+               menu_item_add_main_window_accelerator(item, accel_group);
+               }
+
        gtk_widget_show(image);
        menu_item_finish(menu, item, func, data);
 
@@ -76,9 +238,21 @@ GtkWidget *menu_item_add_sensitive(GtkWidget *menu, const gchar *label, gboolean
                                   GCallback func, gpointer data)
 {
        GtkWidget *item;
+       GtkAccelGroup *accel_group;
+       hard_coded_window_keys *window_keys;
 
        item = menu_item_add(menu, label, func, data);
        gtk_widget_set_sensitive(item, sensitive);
+       window_keys = g_object_get_data(G_OBJECT(menu), "window_keys");
+       accel_group = g_object_get_data(G_OBJECT(menu), "accel_group");
+       if (accel_group && window_keys)
+               {
+               menu_item_add_accelerator(item, accel_group, window_keys);
+               }
+       else if (accel_group)
+               {
+               menu_item_add_main_window_accelerator(item, accel_group);
+               }
 
        return item;
 }
@@ -87,9 +261,21 @@ GtkWidget *menu_item_add_stock_sensitive(GtkWidget *menu, const gchar *label, co
                                         GCallback func, gpointer data)
 {
        GtkWidget *item;
+       GtkAccelGroup *accel_group;
+       hard_coded_window_keys *window_keys;
 
        item = menu_item_add_stock(menu, label, stock_id, func, data);
        gtk_widget_set_sensitive(item, sensitive);
+       window_keys = g_object_get_data(G_OBJECT(menu), "window_keys");
+       accel_group = g_object_get_data(G_OBJECT(menu), "accel_group");
+       if (accel_group && window_keys)
+               {
+               menu_item_add_accelerator(item, accel_group, window_keys);
+               }
+       else if (accel_group)
+               {
+               menu_item_add_main_window_accelerator(item, accel_group);
+               }
 
        return item;
 }
@@ -98,8 +284,22 @@ GtkWidget *menu_item_add_check(GtkWidget *menu, const gchar *label, gboolean act
                               GCallback func, gpointer data)
 {
        GtkWidget *item;
+       GtkAccelGroup *accel_group;
+       hard_coded_window_keys *window_keys;
 
        item = gtk_check_menu_item_new_with_mnemonic(label);
+       window_keys = g_object_get_data(G_OBJECT(menu), "window_keys");
+       accel_group = g_object_get_data(G_OBJECT(menu), "accel_group");
+
+       if (accel_group && window_keys)
+               {
+               menu_item_add_accelerator(item, accel_group, window_keys);
+               }
+       else if (accel_group)
+               {
+               menu_item_add_main_window_accelerator(item, accel_group);
+               }
+
        gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(item), active);
        menu_item_finish(menu, item, func, data);
 
@@ -109,10 +309,24 @@ GtkWidget *menu_item_add_check(GtkWidget *menu, const gchar *label, gboolean act
 GtkWidget *menu_item_add_radio(GtkWidget *menu, const gchar *label, gpointer item_data, gboolean active,
                               GCallback func, gpointer data)
 {
+       GtkAccelGroup *accel_group;
+       hard_coded_window_keys *window_keys;
+
        GtkWidget *item = menu_item_add_check(menu, label, active, func, data);
        g_object_set_data(G_OBJECT(item), "menu_item_radio_data", item_data);
        g_object_set(G_OBJECT(item), "draw-as-radio", TRUE, NULL);
 
+       window_keys = g_object_get_data(G_OBJECT(menu), "window_keys");
+       accel_group = g_object_get_data(G_OBJECT(menu), "accel_group");
+       if (accel_group && window_keys)
+               {
+               menu_item_add_accelerator(item, accel_group, window_keys);
+               }
+       else if (accel_group)
+               {
+               menu_item_add_main_window_accelerator(item, accel_group);
+               }
+
        return item;
 }
 
index 1d4eaf3..ba0f51e 100644 (file)
@@ -618,6 +618,7 @@ GtkWidget *vf_pop_menu(ViewFile *vf)
        GtkWidget *submenu;
        gboolean active = FALSE;
        gboolean class_archive = FALSE;
+       GtkAccelGroup *accel_group;
 
        switch (vf->type)
        {
@@ -634,6 +635,12 @@ GtkWidget *vf_pop_menu(ViewFile *vf)
 
        menu = popup_menu_short_lived();
 
+       accel_group = gtk_accel_group_new();
+       gtk_menu_set_accel_group(GTK_MENU(menu), accel_group);
+
+       g_object_set_data(G_OBJECT(menu), "window_keys", NULL);
+       g_object_set_data(G_OBJECT(menu), "accel_group", accel_group);
+
        g_signal_connect(G_OBJECT(menu), "destroy",
                         G_CALLBACK(vf_popup_destroy_cb), vf);
 
@@ -700,9 +707,9 @@ GtkWidget *vf_pop_menu(ViewFile *vf)
                                G_CALLBACK(vf_pop_menu_move_cb), vf);
        menu_item_add_sensitive(menu, _("_Rename..."), active,
                                G_CALLBACK(vf_pop_menu_rename_cb), vf);
-       menu_item_add_sensitive(menu, _("_Copy path"), active,
+       menu_item_add_sensitive(menu, _("_Copy path to clipboard"), active,
                                G_CALLBACK(vf_pop_menu_copy_path_cb), vf);
-       menu_item_add_sensitive(menu, _("_Copy path unquoted"), active,
+       menu_item_add_sensitive(menu, _("_Copy path unquoted to clipboard"), active,
                                G_CALLBACK(vf_pop_menu_copy_path_unquoted_cb), vf);
        menu_item_add_divider(menu);
        menu_item_add_stock_sensitive(menu,
@@ -739,10 +746,10 @@ GtkWidget *vf_pop_menu(ViewFile *vf)
        item = menu_item_add(menu, _("_Sort"), NULL, NULL);
        gtk_menu_item_set_submenu(GTK_MENU_ITEM(item), submenu);
 
-       item = menu_item_add_radio(menu, _("View as _List"), GINT_TO_POINTER(FILEVIEW_LIST), vf->type == FILEVIEW_LIST,
+       item = menu_item_add_radio(menu, _("Images as List"), GINT_TO_POINTER(FILEVIEW_LIST), vf->type == FILEVIEW_LIST,
                                            G_CALLBACK(vf_pop_menu_toggle_view_type_cb), vf);
 
-       item = menu_item_add_radio(menu, _("View as _Icons"), GINT_TO_POINTER(FILEVIEW_ICON), vf->type == FILEVIEW_ICON,
+       item = menu_item_add_radio(menu, _("Images as Icons"), GINT_TO_POINTER(FILEVIEW_ICON), vf->type == FILEVIEW_ICON,
                                            G_CALLBACK(vf_pop_menu_toggle_view_type_cb), vf);
 
        switch (vf->type)