Gambas Documentation
Application Repository
Code Snippets
Compilation & Installation from source code
Components
gb
gb.args
gb.cairo
gb.chart
gb.clipper
gb.complex
gb.compress
gb.crypt
gb.data
gb.db
gb.db.form
gb.db.mysql
gb.db.odbc
gb.db.postgresql
gb.db.sqlite2
gb.db.sqlite3
gb.db2
gb.dbus
gb.dbus.trayicon
gb.debug
gb.desktop
gb.desktop.gnome.keyring
gb.desktop.x11
gb.eval
gb.eval.highlight
gb.form
gb.form.dialog
gb.form.editor
gb.form.htmlview
gb.form.mdi
gb.form.print
gb.form.stock
gb.form.terminal
gb.gmp
gb.gsl
gb.gtk
Align
Button
ComboBox
Container
Control
Cursor
Draw
Embedder
Font
GridView
Key
ListView
Mouse
Panel
Picture
stock
trayicon
trayicons
Window
_new
Border
Resizable
gb.gtk.opengl
gb.gtk3
gb.gtk3.opengl
gb.gtk3.webview
gb.gui
gb.gui.opengl
gb.gui.qt
gb.gui.qt.ext
gb.gui.qt.opengl
gb.gui.qt.webkit
gb.gui.trayicon
gb.gui.webview
gb.hash
gb.highlight
gb.image
gb.image.effect
gb.image.imlib
gb.image.io
gb.inotify
gb.jit
gb.libxml
gb.logging
gb.map
gb.markdown
gb.media
gb.media.form
gb.memcached
gb.mime
gb.mongodb
gb.mysql
gb.ncurses
gb.net
gb.net.curl
gb.net.pop3
gb.net.smtp
gb.openal
gb.opengl
gb.opengl.glsl
gb.opengl.glu
gb.opengl.sge
gb.openssl
gb.option
gb.pcre
gb.pdf
gb.poppler
gb.qt4
gb.qt4.ext
gb.qt4.opengl
gb.qt4.webkit
gb.qt4.webview
gb.qt5
gb.qt5.ext
gb.qt5.opengl
gb.qt5.webkit
gb.qt5.webview
gb.qt6
gb.qt6.ext
gb.qt6.opengl
gb.qt6.webview
gb.report
gb.report2
gb.scanner
gb.sdl
gb.sdl.sound
gb.sdl2
gb.sdl2.audio
gb.settings
gb.signal
gb.term
gb.test
gb.util
gb.util.web
gb.v4l
gb.vb
gb.web
gb.web.feed
gb.web.form
gb.web.gui
gb.xml
gb.xml.html
gb.xml.rpc
gb.xml.xslt
Controls pictures
Deprecated components
Developer Documentation
Development Environment Documentation
Documents
Error Messages
Gambas Playground
How To's
Language Index
Language Overviews
Last Changes
Lexicon
README
Search the wiki
To Do
Topics
Tutorials
Wiki License
Wiki Manual

Window (gb.gtk)

This class implements a window.

This class inherits Container.

This class is creatable.

This class acts like a read-only array.

Constants
Above  
Below  
Normal  

Properties
Arrangement  
AutoResize  
Border   Return or set if the window has a border.
Caption  
Centered  
Closed  
Controls  
FullScreen  
Geometry  
Icon  
Indent  
Invert  
Margin  
Mask  
Maximized  
Menus  
MinH  
MinHeight  
MinW  
MinWidth  
Minimized  
Modal  
Opacity  
Padding  
Persistent  
Picture  
Resizable   Constant used by the Border property to indicate that the window is freely resizable.
Screen  
SkipTaskbar  
Spacing  
Stacking  
Sticky  
TakeFocus  
Text  
Title  
TopLevel  
TopOnly  
Transparent  
Utility  

Inherited properties
Action  
Background   Returns or sets the background color used by the control.
Children  
ClientH  
ClientHeight  
ClientW  
ClientWidth  
ClientX  
ClientY  
Cursor   Use this property for assigning a custom cursor to a control.
Design   Indicates that the control is in design mode.
Direction  
Drop   Returns or sets if a control accepts drops.
Enabled   Indicates that the control is enabled.
Expand   Returns or sets if a control will expand if included in a container that arranges its contents.
Font   Returns or sets the font used to draw text in the control.
Foreground   Returns or sets the foreground color used by the control.
H  
Handle  
HasFocus  
Height  
Hovered  
Id  
Ignore  
Left  
Mouse   Returns or sets the appearence of the cursor when it points inside the control.
Name  
Next  
NoAnimation  
NoTabFocus  
Parent  
PopupMenu  
Previous  
Proxy  
ProxyFor  
RightToLeft  
ScreenX  
ScreenY  
Tag  
Tooltip  
Top  
Tracking  
Visible  
W  
Width  
Window  
X  
Y  

Methods
Activate  
Center  
Close  
Raise  
Show  
ShowDialog  
ShowModal  
ShowPopup  

Inherited methods
Delete  
Drag  
FindChild  
Grab  
Hide  
Lower  
Move  
MoveScaled  
Refresh  
Reparent  
Resize  
ResizeScaled  
SetFocus  

Events
Activate  
Close  
Deactivate  
Font  
Hide  
Icon  
Move  
Open  
Resize  
Show  
State  
Title  

Inherited events
Arrange  
BeforeArrange  
DblClick  
Drag  
DragLeave  
DragMove  
Drop  
Enter  
GotFocus  
KeyPress  
KeyRelease  
Leave  
LostFocus  
Menu  
MouseDown  
MouseDrag  
MouseMove  
MouseUp  
MouseWheel  
NewChild  

Wayland Warning...

Properties/function/events related to positioning like Form.X, Form.Y, Form.Move() function, Form_Move() event will not work as expected or give correct information with wayland.

Gambas cannot see the main top level window (desktop screen) with wayland.
With wayland the compositor provides a window space the size of your window but it controls the positioning and sandboxes the application inside. the gambas applications main Form is then all that can be seen as the top level window.

This causes problems with Form_Move() events and getting/setting positions will not work as expected as nothing relates to the underlying screen size just the compositors provided space (Form.X and Form.X remain the same regardless of where you place the form on the desktop)

A Form can only be moved reliably by code with wayland if it is opened within it's own larger parent workspace.

There is nothing gambas can do about this, the Wayland developers insist we do not need to control window positions, the compositor should know best, and they will not provide any means to do so.

See also