Ticket #532 (closed Task: fixed)
Menu Refactoring
Reported by: | jri | Owned by: | jri |
---|---|---|---|
Priority: | Major | Milestone: | Release 4.1.3 |
Component: | DeepaMehta Standard Distribution | Version: | 4.1.2 |
Keywords: | Cc: | dgf, Malte, JuergeN, ziegi | |
Complexity: | 5 | Area: | |
Module: | deepamehta-webclient |
Description
Currently the canvas context menu makes no use of DM GUI Toolkit's menus. As a consequence the canvas context menus do not scroll when not fitting the screen.
Subject of this ticket is:
- Realize the canvas context menu through DM's GUI Toolkit and drop the proprietary canvas context menu code.
-OR-
- Utilize jQuery UI's Menu widget throughout and drop DM GUI Toolkit's menu code (and the canvas context menu code as well). Does anybody know weather the jQuery UI menus support scrolling when not fitting the screen (like DM GUI Toolkit's menus do) as this would be a KO criteria for using jQuery UI menus.
The trigger for this ticket is #529.
Attachments
Change History
comment:2 Changed 11 years ago by Jörg Richter
comment:3 Changed 11 years ago by Jörg Richter
comment:4 Changed 11 years ago by Jörg Richter
comment:5 Changed 11 years ago by Jörg Richter
Webclient: refactor menus, pt.4 (#532, #534).
The canvas context menus do scroll when invoked near screen bottom.
DEVELOPER NOTES
DM's GUITookit now supports context menus.
dm4c.ui.context_menu()
All DM menus are now unified and based on GUITookit.
The proprietory canvas context menu code is dropped along with all menu related CSS.
The GUIToolkit menus and context menus rely on the jQuery UI Menu widget.
Menu refactoring is basically done.
Minor issues remain.
BREAKING CHANGE
All menu selection handlers are unified and receive 3 arguments:
menu_item - the selected menu item
x, y - coordinates of the selecting mouse click
This applies to toolbar menus as well as context menus.
If your plugin provides topic/association/canvas commands resp. places commands in the toolbar menus it must be possibly adapted. Check your command handler arguments.
comment:6 Changed 11 years ago by Jörg Richter
Webclient: fix long menus (#532, #534).
In long menus, when a (vertical) scrollbar appears:
- the menu items are not line wrapped (the menu is wide enough).
- no horizontal scrollbar appears.
=> If one or both is not true for your OS or windowing system please send me an unscaled screenshot of the menu.
Note: you can use the mouse wheel or whatever scrolling gesture to scroll through long menus.
The former upper/lower "scrolling areas" are gone.
comment:7 Changed 11 years ago by Jörg Richter
comment:8 Changed 11 years ago by Jörg Richter
comment:9 Changed 11 years ago by Jörg Richter
comment:10 Changed 11 years ago by Jörg Richter
Webclient: refactor menus, pt.4 (#532, #534).
The canvas context menus do scroll when invoked near screen bottom.
DEVELOPER NOTES
DM's GUITookit now supports context menus.
dm4c.ui.context_menu()
All DM menus are now unified and based on GUITookit.
The proprietory canvas context menu code is dropped along with all menu related CSS.
The GUIToolkit menus and context menus rely on the jQuery UI Menu widget.
Menu refactoring is basically done.
Minor issues remain.
BREAKING CHANGE
All menu selection handlers are unified and receive 3 arguments:
menu_item - the selected menu item
x, y - coordinates of the selecting mouse click
This applies to toolbar menus as well as context menus.
If your plugin provides topic/association/canvas commands resp. places commands in the toolbar menus it must be possibly adapted. Check your command handler arguments.
comment:11 Changed 11 years ago by Jörg Richter
Webclient: fix long menus (#532, #534).
In long menus, when a (vertical) scrollbar appears:
- the menu items are not line wrapped (the menu is wide enough).
- no horizontal scrollbar appears.
=> If one or both is not true for your OS or windowing system please send me an unscaled screenshot of the menu.
Note: you can use the mouse wheel or whatever scrolling gesture to scroll through long menus.
The former upper/lower "scrolling areas" are gone.
comment:12 Changed 11 years ago by Jörg Richter
comment:13 Changed 11 years ago by Jörg Richter
comment:14 Changed 11 years ago by Jörg Richter
comment:15 Changed 11 years ago by Jörg Richter
Webclient: refactor menus, pt.4 (#532, #534).
The canvas context menus do scroll when invoked near screen bottom.
DEVELOPER NOTES
DM's GUITookit now supports context menus.
dm4c.ui.context_menu()
All DM menus are now unified and based on GUITookit.
The proprietory canvas context menu code is dropped along with all menu related CSS.
The GUIToolkit menus and context menus rely on the jQuery UI Menu widget.
Menu refactoring is basically done.
Minor issues remain.
BREAKING CHANGE
All menu selection handlers are unified and receive 3 arguments:
menu_item - the selected menu item
x, y - coordinates of the selecting mouse click
This applies to toolbar menus as well as context menus.
If your plugin provides topic/association/canvas commands resp. places commands in the toolbar menus it must be possibly adapted. Check your command handler arguments.
comment:16 Changed 11 years ago by Jörg Richter
Webclient: fix long menus (#532, #534).
In long menus, when a (vertical) scrollbar appears:
- the menu items are not line wrapped (the menu is wide enough).
- no horizontal scrollbar appears.
=> If one or both is not true for your OS or windowing system please send me an unscaled screenshot of the menu.
Note: you can use the mouse wheel or whatever scrolling gesture to scroll through long menus.
The former upper/lower "scrolling areas" are gone.
comment:17 Changed 11 years ago by Jörg Richter
comment:18 follow-ups: ↓ 22 ↓ 23 Changed 11 years ago by Malte
Some minor remarks, since I just checked out this brand new stuff:
- In a topics context menus the first and the last menu-item have somehow ugly (top and bottom) paddings
- When using webclient in chromium with a horizontal scrollbar (as reported), the last menu-item is partially hidden, but can be used.
- The gradient deployed by jquery-ui as a hover (over a menu-item) looks ugly to me, I did like the previous (more clean) style better
As an advantage of the new menus: Scrolling the "all types search menu" is much more efficient by now.
And yes, within a menu layout looks good to menu, no horizontal scrollbar appears and no line-break appears, neither in FFox nor in Chromium.
Nice greetings.
comment:19 Changed 11 years ago by Jörg Richter
Webclient GUIToolkit: change button API (#532).
BREAKING CHANGE
dm4c.ui.button() takes a single config argument instead of 4. All are optional. Thus the caller must no longer pass useless undefined arguments. Furthermore the button() API is better extendable.
You must transform your plugin code:
dm4c.ui.button(my_handler, "my label", "my icon", false)
becomes
dm4c.ui.button({ on_click: my_handler, label: "my label", icon: "my icon", is_submit: false })
In preparation of 1-click menus.
See #532.
comment:20 Changed 11 years ago by Jörg Richter
comment:21 Changed 11 years ago by Jörg Richter
Webclient GUIToolkit: change button API (#532).
BREAKING CHANGE
dm4c.ui.button() takes a single config argument instead of 4. All are optional. Thus the caller must no longer pass useless undefined arguments. Furthermore the button() API is better extendable.
You must transform your plugin code:
dm4c.ui.button(my_handler, "my label", "my icon", false)
becomes
dm4c.ui.button({ on_click: my_handler, label: "my label", icon: "my icon", is_submit: false })
In preparation of 1-click menus.
See #532.
comment:23 in reply to: ↑ 18 Changed 11 years ago by jri
Replying to Malte:
Some minor remarks, since I just checked out this brand new stuff:
- In a topics context menus the first and the last menu-item have somehow ugly (top and bottom) paddings
Is this still an issue for you? For me everything looks OK. Can you send me a screenshot illustrating your problem?
- When using webclient in chromium with a horizontal scrollbar (as reported), the last menu-item is partially hidden, but can be used.
Since window scrollbar do not appear anymore (#543), this issue is gone, right?
- The gradient deployed by jquery-ui as a hover (over a menu-item) looks ugly to me, I did like the previous (more clean) style better
I don't like the proliferating gradients either.
I'll customize the jQuery UI theme to remove the gradients.
Thank you, for the suggestion!
As an advantage of the new menus: Scrolling the "all types search menu" is much more efficient by now.
Thank you for feedback!
And yes, within a menu layout looks good to menu, no horizontal scrollbar appears and no line-break appears, neither in FFox nor in Chromium.
Nice to hear :-)
comment:24 Changed 11 years ago by Jörg Richter
Changed 11 years ago by Malte
- Attachment top_menu_item.png added
See top-padding, it is about 1-2px to narrow compared to bottom padding
comment:25 Changed 11 years ago by jri
Oh, there are new attachments! Thanks!
(Trac does not inform me when there are new attachments without a comment.)
Line wrap in "By Type" Menu
I have to check this.
See top-padding, it is about 1-2px to narrow compared to bottom padding.
I think you mean the top/bottom margin of the menu dividers (5px in jQuery default style). Above the first menu item there is no divider line, so it might look "too narrow".
We could reduce the top/bottom divider margin.
comment:26 Changed 11 years ago by Jörg Richter
comment:27 Changed 11 years ago by jri
Malte wrote:
Line wrap in "By Type" Menu
Did this happen when the browser window is too small? In this case I consider the wrapping OK. (What whould be the alternative?)
Just to clearify: my original wrapping question (comment:6) was aimed at wrapping as a reaction to a vertical menu scrollbar (not as a reaction to a small browser window):
In long menus, when a (vertical) scrollbar appears:
- the menu items are not line wrapped (the menu is wide enough).
- no horizontal scrollbar appears.
=> If one or both is not true for your OS or windowing system please send me an unscaled screenshot of the menu.
I would consider this ticket as solved.
comment:28 Changed 11 years ago by jri
- Status changed from accepted to closed
- Resolution set to fixed