implemented full keyboard navigation support#10
Merged
ravindu2012 merged 5 commits intomasterfrom Mar 9, 2026
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Adds app-wide keyboard navigation support in the WPF shell by wiring global shortcuts and improving tab/Alt-key navigation across key views, addressing Issue #6’s “power user” keyboard workflow goal.
Changes:
- Added
Window.InputBindingsinMainWindowfor Home/Find/Close Tab/Save/New shortcuts. - Implemented code-behind command handlers for global actions (focus search, close tab, global save/new) plus a visual-tree helper.
- Updated shared DataTemplates to include
TabIndexordering and access keys (underscored button content).
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 6 comments.
| File | Description |
|---|---|
src/Presentation/QBD.WPF/Themes/DataTemplates.xaml |
Adds TabIndex values and access keys (_) for keyboard navigation within templates. |
src/Presentation/QBD.WPF/MainWindow.xaml |
Adds global KeyBindings for keyboard shortcuts at the window level. |
src/Presentation/QBD.WPF/MainWindow.xaml.cs |
Exposes commands for keybindings and implements global save/new/close/focus-search behaviors. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.
Comments suppressed due to low confidence (1)
src/Presentation/QBD.WPF/Themes/DataTemplates.xaml:116
- CenterTemplate: only the filter TextBox/Button/ListBox have explicit TabIndex values, but the adjacent New/Edit buttons still have the default TabIndex (0). In WPF that will typically place New/Edit earlier in the tab sequence than the intended search-first flow, making tab navigation inconsistent. Assign TabIndex values to New/Edit (and any other focusable controls in this panel) consistent with the intended order; similarly consider adding access keys if you want Alt+Key parity with ListTemplate.
<StackPanel DockPanel.Dock="Top" Orientation="Horizontal" Margin="8,4">
<Button Content="New" Command="{Binding NewEntityCommand}" Padding="8,2" Margin="0,0,4,0"/>
<Button Content="Edit" Command="{Binding EditEntityCommand}" Padding="8,2"/>
</StackPanel>
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Cache ICommand properties to avoid allocating on every binding access - Rename RelayCommand to ActionCommand to avoid conflict with CommunityToolkit.Mvvm - Fix FocusSearch to match TextBox by binding path (FilterText/SearchText) instead of TabIndex - Scope search to selected tab content instead of entire TabControl - Add InputGestureText hints for F5, Ctrl+F, and Esc shortcuts in menus
- Add F1 keybinding and Help > Keyboard Shortcuts menu item - Show themed dialog listing all shortcuts with their actions - Covers global shortcuts (F1, F5, Ctrl+N/S/F, Esc) and form-level access keys (Alt+S/P/L/V/R/N/E/D)
ravindu2012
added a commit
that referenced
this pull request
Mar 12, 2026
implemented full keyboard navigation support
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Brief description of the changes.
Type of Change
Related Issue
Fixes #6
Changes Made
added InputBindings to MainWindow for F5 (Home), Ctrl+F (Search), Ctrl+S (Save), Ctrl+N (New), and Esc (Close Tab).
developed a FindVisualChild utility in MainWindow.xaml.cs to programmatically focus the search TextBox within complex DataTemplates when Ctrl+F is pressed.
assigned logical TabIndex values to all interactive elements in CenterTemplate, ListTemplate, and TransactionFormTemplate.
added _ prefix to Content properties of primary buttons (Save, Clear, Void, New, Edit, etc.) to enable Alt + Key shortcuts.
connected global shortcuts to ViewModel commands using a custom RelayCommand implementation.
Screenshots
N/A
Checklist