Bug #13956
openWPopupMenu not visible if popped up at itemWidget of (a narrow) WTableView with vertical scrollbar
0%
Description
WPopuMenu::popup(WWidget *location, orientation = Orientation::Vertical) seems to reparent the menu to some layout container if the WTableView has a vertical scrollbar.
This just results in the horizontal scrollbar becoming added and the popup menu being invisible until that scrollbar is moved. Unacceptable UX.
(If the WTableView does not have a vertical scrollbar, the menu uses the full height of the screen, i.e. is not restricted to and hidden in a container. Good.)
CSS path without vscrollbar: html.Wt-layout body.Wt-layout.Wt-ltr div#ojansmv.Wt-domRoot ul#ojaovc7.Wt-popup.DevSwitching.dropdown-menu.wt-reparented
CSS path with vscrollbar: html.Wt-layout body.Wt-layout.Wt-ltr div#ojansmv.Wt-domRoot div#ojansmx div#ojansnz.SystemSummary div#ojanso0.Wt-stack div#ojaothf div#ojaovbc.Wt-itemview.Wt-tableview.DevSwitching.wt-fixedc1.unselectable div#ojaovbw div#ojaovbn.tcontainer ul#ojaovc7.Wt-popup.DevSwitching.dropdown-menu.wt-reparented
Files
Updated by Michael Seibt about 2 months ago
High: Still reproducible with Wt 4.12.2 (and former versions, checked down to 4.11.4).
STR:
- run attached
main.cppwithreload-is-new-session = false - open http://127.0.0.1:8080
- click "Popup menu"
--> WPopupMenu is not visible without scrolling. Just cell "42,1" is selected and the horizontal scrollbar of the left WTableView gets longer.
Popping up the menu with Orientation::Vertical (tick the checkbox) does not make it better - particularly if row 42 was not visible.
Then the context menu pops up above the - now top-visible - cell.
The layout gets totally messed up by
- reloading the page (worse than before with Wt 4.12.2)
- adding many menu items (button "Add many context menu items")
Most of this issues will be resolved if the context menu is not popped up inside that container - as it is done for the right WTableView (with less rows) if it has no scrollbar.
Updated by Michael Seibt 13 days ago
Thank you for fixing many layout issues in 4.12.6!
But this important one is still reproducible.
Updated by Romain Mardulyn 11 days ago
- Status changed from New to InProgress
- Assignee set to Romain Mardulyn