aboutsummaryrefslogtreecommitdiffstats
path: root/README.md
diff options
context:
space:
mode:
authorDanilo M. <danix@danix.xyz>2026-08-03 14:17:09 +0200
committerDanilo M. <danix@danix.xyz>2026-08-03 14:17:09 +0200
commit1f2eddff6afcbf4c24f06e982e9169219429a2ed (patch)
treeb809a3221d32e0276a3156ac2a2a45ea7f73b825 /README.md
parent188287f14f981ed3e8a08bc1514bb2ba6bb76809 (diff)
downloadqtmaildir-1f2eddff6afcbf4c24f06e982e9169219429a2ed.tar.gz
qtmaildir-1f2eddff6afcbf4c24f06e982e9169219429a2ed.zip
feat: add menus, a toolbar and a shortcut reference
Actions were a QHash of std::function dispatched by an event filter, which nothing could put in a menu. They are QActions now, bound from KeyMap so a [keys] override reaches the menus as well as the keyboard. Menu bar covers every action; the toolbar carries only Sync, Archive, Delete and Undo. Help > Keyboard shortcuts is generated from the actions, so it shows what the keys really do rather than a copy that drifts. spam and load_remote gained defaults, having been unreachable without a hand-written binding. The event filter is gone. Probing showed QAction shortcuts are dispatched before the focused widget sees the key, so they beat QAbstractItemView's type-to-search without one, and Qt already suppresses plain-letter shortcuts while an editable widget has focus. Dropping the filter's blanket guard also lets Ctrl+Q work while the query bar has focus. registeredActionNames() is derived from the actions rather than hand-maintained, so the two drift tests it needed are replaced by checks that a configured binding reaches its action. No confirmation dialogs: tag mutations still answer to undo.
Diffstat (limited to 'README.md')
-rw-r--r--README.md55
1 files changed, 31 insertions, 24 deletions
diff --git a/README.md b/README.md
index 4acd215..f7e2444 100644
--- a/README.md
+++ b/README.md
@@ -104,18 +104,10 @@ Unread = tag:unread
Flagged = tag:flagged
[keys]
+Ctrl+E = archive
+Ctrl+D = delete
j = next_thread
k = prev_thread
-Return = open_thread
-a = archive
-d = delete
-N = toggle_unread
-F = flag
-/ = focus_query
-h = toggle_html
-u = undo
-G = sync
-Ctrl+Q = quit
```
Saved-query buttons appear in alphabetical order rather than file order:
@@ -128,27 +120,42 @@ Defaults, all rebindable through `[keys]`:
| Key | Action | Does |
|---|---|---|
-| `j` | `next_thread` | Select the next thread |
-| `k` | `prev_thread` | Select the previous thread |
+| `Ctrl+J` | `next_thread` | Select the next thread |
+| `Ctrl+K` | `prev_thread` | Select the previous thread |
| `Return` | `open_thread` | Focus the thread list |
-| `a` | `archive` | Remove `inbox` from every selected thread |
-| `d` | `delete` | Add `deleted` |
-| `N` | `toggle_unread` | Toggle `unread` |
-| `F` | `flag` | Add `flagged` |
-| `/` | `focus_query` | Focus and select the query bar |
-| `h` | `toggle_html` | Switch the thread between HTML and plain text |
-| `u` | `undo` | Undo the last tag change |
-| `G` | `sync` | Run the configured sync command |
+| `Ctrl+E` | `archive` | Remove `inbox` from every selected thread |
+| `Ctrl+D` | `delete` | Add `deleted` |
+| `Ctrl+Shift+S` | `spam` | Add `spam`, remove `inbox` |
+| `Ctrl+U` | `toggle_unread` | Toggle `unread` |
+| `Ctrl+I` | `flag` | Add `flagged` |
+| `Ctrl+L` | `focus_query` | Focus and select the query bar |
+| `Ctrl+H` | `toggle_html` | Switch the thread between HTML and plain text |
+| `Ctrl+M` | `load_remote` | Load remote images for the current thread |
+| `Ctrl+Z` | `undo` | Undo the last tag change |
+| `Ctrl+G` | `sync` | Run the configured sync command |
| `Ctrl+Q` | `quit` | Quit |
-Two further actions exist but have **no default binding**, so they are
-unreachable until you bind them: `spam` (adds `spam`, removes `inbox`) and
-`load_remote` (the keyboard equivalent of the "Load remote content"
-button).
+Every action now carries a default binding, and every one appears in a menu.
+**Help > Keyboard shortcuts** lists the current bindings, generated from the
+actions themselves, so it shows your overrides rather than these defaults.
An unknown action name in `[keys]` produces a warning at startup rather than
binding silently, so a typo is visible.
+### Upgrading from 0.1.0
+
+0.1.0 used single letters (`j`, `k`, `a`, `d`, `N`, `F`, `h`, `u`, `G`, `/`).
+Those still work if you keep them in `[keys]`, and single letters remain safe
+to bind: Qt suppresses a plain-letter shortcut while the query bar has focus,
+so typing a query is unaffected.
+
+Three of the old defaults never actually fired. Typing a capital sends
+`Shift`+the key, but `N`, `F` and `G` were stored as the unshifted key, a
+combination no keystroke produces, so `toggle_unread`, `flag` and `sync` were
+dead. A bare capital in `[keys]` is now read as `Shift`+that letter, which is
+what you press, so those bindings work whether you keep the old names or move
+to the new defaults. Note this makes `y` and `Y` two different keys.
+
Tag actions apply to **every selected thread**, not only the focused one.
## Security posture of the message view