class fwt::Window
sys::Obj fwt::Widget fwt::Pane fwt::ContentPane fwt::Window
Window is the base class for widgets which represent top level windows.
- activate
-
Void activate()
Set this Window to be the active window for the application.
- alwaysOnTop
-
const Bool alwaysOnTop := false
Force window to always be on top of the desktop. Default is false. This field cannot be changed once the window is constructed.
- close
-
virtual Void close(Obj? result := null)
Close the window.
- icon
-
Image? icon
Icon if window is a frame.
- make
-
new make(Window? parent := null, |This|? f := null)
Construct the window with an option parent window.
-
Menu? menuBar
Child menu bar widget if top level frame.
- mode
-
const WindowMode mode := ...
Window mode defines the modal state of the window:
- modeless: no blocking of other windows
- windowModal: input is blocked to parent window
- appModal: input is blocked to all other windows of application
- sysModal: input is blocked to all windows of all applications The default is appModel for Dialogs and modeless for all other window types. This field cannot be changed once the window is constructed.
- onActive
-
EventListeners onActive()
Callback function when window becomes the active window on the desktop with focus.
Event id fired:
Event fields:
- none
- onClose
-
EventListeners onClose()
Callback function when window is closed. Consume the event to prevent the window from closing.
Event id fired:
Event fields:
- none
- onDeiconified
-
EventListeners onDeiconified()
Callback function when window is deiconified from the taskbar.
Event id fired:
Event fields:
- none
- onIconified
-
EventListeners onIconified()
Callback function when window is iconified to the taskbar.
Event id fired:
Event fields:
- none
- onInactive
-
EventListeners onInactive()
Callback function when window becomes an inactive window on the desktop and loses focus.
Event id fired:
Event fields:
- none
- onOpen
-
EventListeners onOpen()
Callback function when window is opended.
Event id fired:
Event fields:
- none
- open
-
virtual Obj? open()
Open the window. If this is a dialog, then return result passed to the
close
method (typically the Command). Return null if canceled or closed without a result.If the windows has not had its size explicitly set, then it is packed to use its preferred size. If the position is not explicitly set, then the windows is centered over its parent window (or primary monitor if no parent).
- resizable
-
const Bool resizable := true
Can this window be resizable. Default is true. This field cannot be changed once the window is constructed.
- showTrim
-
const Bool showTrim := true
Show all normal window decorations, such as the titlebar, and frame border. If false, only the window content will be visible. Defaults to true. This field cannot be changed once the window is constructed.
- title
-
Str title
Title string if window is a frame. Defaults to "".