Refine tab to move focus even when the last item is a button#13938
Conversation
…ves focus to the next tab's field
# Conflicts: # jabgui/src/main/java/org/jabref/gui/entryeditor/EntryEditor.java # jabgui/src/main/java/org/jabref/gui/fieldeditors/EditorTextField.java
…ves focus to the next tab's field
…es focus to the next tab's field
Co-authored-by: Carl Christian Snethlage <50491877+calixtus@users.noreply.github.com>
…to fix-issue-11937 # Conflicts: # jabgui/src/main/java/org/jabref/gui/entryeditor/EntryEditor.java
|
|
||
| @Override | ||
| protected TextInputControl createTextInputControl() { | ||
| protected TextInputControl createTextInputControl(Field field) { |
There was a problem hiding this comment.
Would like if you could clarify, how is this change helping?
I don't see the field parameter being used anywhere here
There was a problem hiding this comment.
The parameter isn’t used in this override, but it’s required to match the parent method’s signature. I could add a suppress annotation here
There was a problem hiding this comment.
If one is having to do that, it's probably a bad use case for overriding
Will think over this
|
Tab nav works also now when with the ctie key button |
koppor
left a comment
There was a problem hiding this comment.
Small comments
Did not work for me on Windows 11
Maybe, we need LOGGER.trace statements and add enable trace for EntryEditor.java in tinylog.properties?
| ClipBoardManager.addX11Support(this); | ||
| } | ||
|
|
||
| public void setupTabNavigation(Predicate<TextField> isLastFieldChecker, Runnable nextTabSelector) { |
Co-authored-by: Oliver Kopp <kopp.dev@gmail.com>
Co-authored-by: Oliver Kopp <kopp.dev@gmail.com>
Co-authored-by: Oliver Kopp <kopp.dev@gmail.com>
|
@koppor Select the first field in required fields and then just hit tab jabrefjkeyboard.mov |
|
|
Does not work on Windows 10: https://www.loom.com/share/7c0d4090a9d24952a8e96bd937e299f7 I tried commit e32c12d |
|
I tried again with and it worked fine. 😅 |

Closes #11937
Description
Improve tab behavior to move focus even when the last item is a button
Limit focus changes to fields within the EntryEditor, preventing jumps to unrelated UI components.
Introduce static helper methods in EditorTextField to handle TAB key behavior.
Ensure all TextField instances in SimpleEditor, CitationKeyEditor, PersonsEditor, and MarkdownEditor have proper IDs, enabling correct detection of the last field.
Steps to test
Mandatory checks
CHANGELOG.mdin a way that is understandable for the average user (if change is visible to the user)Screen.Recording.2025-09-13.155910.mp4