Add Bounds, InnerBounds to Window

Closes #22
This commit is contained in:
Sasha Koshka 2024-08-16 17:03:24 -04:00
parent e23a688103
commit d08fe845fc

View File

@ -287,6 +287,13 @@ type BoxArranger interface {
// themselves are completely transparent, and become opaque once an opaque
// object is added as their root.
type Window interface {
// Bounds returns the bounds of the window including its frame, if
// possible. This means that the top-left point of the bounds will be
// either zero or negative.
Bounds () image.Rectangle
// InnerBounds returns the inner bounds of the window, not including its
// frame. This means that the top-left point of the bounds will be zero.
InnerBounds () image.Rectangle
// SetRoot sets the root child of the window. There can only be one at
// a time, and setting it will remove the current child if there is one.
SetRoot (Object)