Class wibox.layout.flex
Usage:
wibox.widget {
generic_widget( 'first' ),
generic_widget( 'second' ),
generic_widget( 'third' ),
layout = wibox.layout.flex.horizontal
}
Info:
- Copyright: 2010 Uli Schlachter
- Author: Uli Schlachter
Object properties
-
wibox.layout.flex.max_widget_size
-
Set the maximum size the widgets in this layout will take.
That is, maximum width for horizontal and maximum height for vertical.
Type:
Methods
-
wibox.layout.flex:set_children (children)
-
Replace the layout children
- children
table
A table composed of valid widgets
-
wibox.layout.flex:add (layout, ...)
-
Add some widgets to the given fixed layout
- layout
The layout you are modifying.
- ...
widget
Widgets that should be added (must at least be one)
-
wibox.layout.flex:remove (The)
-
Remove a widget from the layout
- The
index
widget index to remove
Returns:
boolean
index If the operation is successful
-
wibox.layout.flex:remove_widgets (widget)
-
Remove one or more widgets from the layout
The last parameter can be a boolean, forcing a recursive seach of the
widget(s) to remove.
- widget
... Widgets that should be removed (must at least be one)
Returns:
boolean
If the operation is successful
-
wibox.layout.flex:insert (index, widget)
-
Insert a new widget in the layout at position
index
- index
number
The position
- widget
The widget
Returns:
boolean
If the operation is successful
-
wibox.layout.flex:horizontal (...)
-
Returns a new horizontal flex layout. A flex layout shares the available space
equally among all widgets. Widgets can be added via :add(widget).
- ...
widget
Widgets that should be added to the layout.
-
wibox.layout.flex:vertical (...)
-
Returns a new vertical flex layout. A flex layout shares the available space
equally among all widgets. Widgets can be added via :add(widget).
- ...
widget
Widgets that should be added to the layout.