GUI Handler

by Aiota
A simplified way to handle UI interfaces.
ID:2417782
 
Resolved
Menus are now able to be limited to the screen edges. The Width and Height vars have been moved to /Menu, and client.NewMenu() now takes Width and Height arguments. Both of these have to be defined in order for the Menu to be limited to the screen edges. Two new #defines SCREEN_MAX_WIDTH and SCREEN_MAX_HEIGHT have been added to act as limiters to the Menu.screen_loc.
Applies to:Dream Maker
Status: Resolved (1.3.20181224)

This issue has been resolved.
Yo bro i like your work, keep it up.

What do you think about add property allow user move window just to screen edges?

Definitely feasible, but I will have to play around with it. At the moment, Menu objects don't actually track how big they are (since they are basically just positional containers) so the mouse can't determine a min/max screen_loc with the current implementation based on the Menu object alone.

The easiest way is to probably move the Width/Height vars to /Menu and allow the programmer to set these values so that they can be compared to the mouse position. The caveat to this is that if these vars are set to a value, then it's up to the programmer to abide the child window/table sizes to that parent size.
Aiota resolved issue with message:
Menus are now able to be limited to the screen edges. The Width and Height vars have been moved to /Menu, and client.NewMenu() now takes Width and Height arguments. Both of these have to be defined in order for the Menu to be limited to the screen edges. Two new #defines SCREEN_MAX_WIDTH and SCREEN_MAX_HEIGHT have been added to act as limiters to the Menu.screen_loc.