Add hover button to group rows for adding groups#15502
Add hover button to group rows for adding groups#15502Siedlerchr merged 10 commits intoJabRef:mainfrom
Conversation
Review Summary by QodoAdd hover button to group rows for adding groups
WalkthroughsDescription• Add hover button to group rows for adding new groups • Display "New Group" for root and "New Subgroup" for subgroups • Button appears on mouse hover over group rows • Adjust column widths and styling for new button column Diagramflowchart LR
A["Group Tree View"] -->|"Add Column"| B["Add Subgroup Column"]
B -->|"Cell Factory"| C["Hover Button"]
C -->|"Root Group"| D["New Group Button"]
C -->|"Subgroup"| E["New Subgroup Button"]
F["CSS Styling"] -->|"Alignment & Padding"| B
File Changes1. jabgui/src/main/java/org/jabref/gui/groups/GroupTreeView.java
|
Code Review by Qodo
|
|
Let me know if the UI and hover behavior feels right. There was a lot of context around the issue but I'm guessing this was the planned approach. |
| # Grouping | ||
| Groups=Groups | ||
| New\ group=New group | ||
| New\ subgroup=New subgroup |
There was a problem hiding this comment.
I was also confused whether to reuse the existing "Add subgroup" key or introduce a new one but I went with New subgroup to stay consistent with the existing New group key used by the bottom button.
| this.setCenter(groupTree); | ||
|
|
||
| mainColumn.prefWidthProperty().bind(groupTree.widthProperty().subtract(80d).subtract(15d)); | ||
| mainColumn.prefWidthProperty().bind(groupTree.widthProperty().subtract(80d).subtract(28d).subtract(15d)); |
There was a problem hiding this comment.
Magic numbers need some explanation. Best as constants.
There was a problem hiding this comment.
Implying, this might need both a constant as well as a comment explaining
|
Placement of the add button looks awkward. |
|
please test with long group names |
Works perfectly fine. |
|
The text of the subgroup titles are somehow not centered, they're leaning towards the top |


Related issues and pull requests
Closes #12289
PR Description
This PR applies the suggested proposal by @koppor showing the "+" button for adding groups on hovering over any group row. The "All Entries" row shows "New Group" and rest of the rows show "Add Subgroup" as expected.
Steps to test
2026-04-05.17-33-07.mp4
Checklist
CHANGELOG.mdin a way that can be understood by the average user (if change is visible to the user)