Classes
Window | A top-level Window component. |
Bases: enaml.widgets.widget.Widget
A top-level Window component.
A Window component is represents of a top-level visible component with a frame decoration. It may have at most one child widget which is dubbed the ‘central widget’. The central widget is an instance of Container and is expanded to fit the size of the window.
A Window does not support features like MenuBars or DockPanes, for such functionality, use a MainWindow widget.
A static set of windows being used by the application. A window adds itself to this list when it is initialized, and removes itself when it is destroyed. This allows toplevel windows with no parent to persist without any other strong references.
The titlebar text.
The initial position of the window frame. A value of (-1, -1) indicates that the toolkit should choose the initial position.
The initial size of the window client area. A value of (-1, -1) indicates that the toolkit should choose the initial size.
An enum which indicates the modality of the window. The default value is ‘non_modal’.
If this value is set to True, the window will be destroyed on the completion of the closed event.
The title bar icon.
Whether the window styas on top of other windows on the desktop. Changes to this value after the window is shown will be ignored.
An event fired when the user request the window to be closed. This will happen when the user clicks on the “X” button in the title bar button, or when the ‘close’ method is called. The payload will be a CloseEvent object which will allow code to veto the close event and prevent the window from closing.
An event fired when the window is closed.
Windows are invisible by default.
A reference to the ProxyWindow object.
An overridden initializer method.
This method adds the window to the static set of Windows.
An overridden destructor method.
This method removes the window from the static set of Windows.
Get the central widget defined on the window.
The last Container child of the window is the central widget.
Get the position of the window frame.
Returns : | result : Pos
|
---|
Set the position of the window frame.
Parameters : | pos : Pos
|
---|
Get the size of the window client area.
Returns : | result : Size
|
---|
Set the size of the window client area.
Parameters : | size : Size
|
---|
Get the geometry of the window client area.
Returns : | result : Rect
|
---|
Set the geometry of the window client area.
Parameters : | rect : Rect
|
---|
Get the geometry of the window frame.
Returns : | result : Rect
|
---|
Send the window to the top of the Z-order.
This will only affect the Z-order of the window relative to the Z-order of other windows in the same application.
Send the window to the bottom of the Z-order.
This will only affect the Z-order of the window relative to the Z-order of other windows in the same application.
Set this window to be the active application window.
This performs the same operation as clicking the mouse on the title bar of the window, except that it will not effect the Z order of the window.
On Windows, this will cause the taskbar icon to flash if the window does not belong to the active application.
Center this window on another widget.
Parameters : | other : Widget
|
---|