Module Geyser.Container
Represents a generic container with positional information.
Has no notion of contents and is used to contain other windows
and impose some sense of order.
See also: Mudlet Manual
Info:
- Author: guy
Functions
Geyser.Container:flash (time[, onHidden=true]) | Flashes a white box over the dimensions of this container. |
Geyser.Container:hide (auto) | Hides this window and all its contained windows. |
Geyser.Container:lower (changeWindowIndex) | Lowers the window to the bottom of the z-order stack, displaying behind all other windows |
Geyser.Container:lowerAll () | Lowers the window and all its containing elements to the bottom of the z-order stack, displaying behind all other windows |
Geyser.Container:move (x, y) | Moves this window according to the new x and y constraints set. |
Geyser.Container:new (cons, container) | Constructor for containers. |
Geyser.Container:new2 (cons, container) | Overridden constructor to use add2 |
Geyser.Container:raise (changeWindowIndex) | Raises the window to the top of the z-order stack, displaying in front of all other windows |
Geyser.Container:raiseAll (container, me) | Raises the window and all its containing elements to the top of the z-order stack, displaying in front of all other windows. |
Geyser.Container:reposition () | Responsible for placing/moving/resizing this window to the correct place/size. |
Geyser.Container:resize (width, height) | Resizes this window according to the new width and height constraints set. |
Geyser.Container:setFontSize (fontSize) | Sets the default font size for this window. |
Geyser.Container:set_constraints (cons) | Sets all constraints (x, y, width, height) for this window. |
Geyser.Container:show (auto) | Shows this window and all windows it contains. |
Functions
- Geyser.Container:flash (time[, onHidden=true])
-
Flashes a white box over the dimensions of this container.
This is very useful to see where a container actually is if you've
forgotten its details or as an alert function to notify the user.
Parameters:
- time Time in seconds to flash for, default is 1.0s.
- onHidden Optional, use as an alert function and don't flash hidden containers. (default true)
- Geyser.Container:hide (auto)
-
Hides this window and all its contained windows.
Parameters:
- auto
- Geyser.Container:lower (changeWindowIndex)
-
Lowers the window to the bottom of the z-order stack, displaying behind all other windows
Parameters:
- changeWindowIndex used internally
See also:
- Geyser.Container:lowerAll ()
-
Lowers the window and all its containing elements to the bottom of the z-order stack, displaying behind all other windows
See also:
- Geyser.Container:move (x, y)
-
Moves this window according to the new x and y constraints set.
Parameters:
- x New x constraint to use. If nil, uses current value.
- y New y constraint to use. If nil, uses current value.
- Geyser.Container:new (cons, container)
-
Constructor for containers.
This function creates a new container/window
Parameters:
- cons Any Lua table that contains appropriate constraint entries. Include any parameter such as name or fontSize in cons that are to be used for the new window.
- container The parent container.
- Geyser.Container:new2 (cons, container)
-
Overridden constructor to use add2
Parameters:
- cons
- container
- Geyser.Container:raise (changeWindowIndex)
-
Raises the window to the top of the z-order stack, displaying in front of all other windows
Parameters:
- changeWindowIndex used internally
See also:
- Geyser.Container:raiseAll (container, me)
-
Raises the window and all its containing elements to the top of the z-order stack, displaying in front of all other windows.
Parameters:
- container used internally
- me used internally
See also:
- Geyser.Container:reposition ()
- Responsible for placing/moving/resizing this window to the correct place/size. Called on window resize events.
- Geyser.Container:resize (width, height)
-
Resizes this window according to the new width and height constraints set.
Parameters:
- width New width constraint to use. If nil, uses current value.
- height New height constraint to use. If nil, uses current value.
- Geyser.Container:setFontSize (fontSize)
-
Sets the default font size for this window.
Will resizes this window if necessary to meet constraints.
Parameters:
- fontSize The new font size to use.
- Geyser.Container:set_constraints (cons)
-
Sets all constraints (x, y, width, height) for this window.
Parameters:
- cons Any Lua table that contains appropriate constraint entries.
- Geyser.Container:show (auto)
-
Shows this window and all windows it contains.
Parameters:
- auto