Updownquark / Quick

Quark's User Interface Creation Kit
0 stars 0 forks source link

Design mechanism for widgets that may need to "pop up" #14

Closed Updownquark closed 12 years ago

Updownquark commented 12 years ago

Right now widgets are given a set of bounds and can only paint and receive events within that boundary. But some widgets, e.g. tool tips, menus, and combo boxes, pop up a widget that needs to be able to render and receive events outside of those bounds somehow.

Some problems:

Updownquark commented 12 years ago

Added the "paint bounds" concept. The MuisElement.getPaintBounds() method returns a rectangle in element coordinates that describes where the element may draw. This rectangle is used to update the cached bounds as well (though this rectangle is in parent coordinates), which is used by the positional event (e.g. mouse) code; so widgets will also receive events that occur inside their paint bounds. This should enable all the functionality and meet all the requirements outlined in the OP.