Drag[en]gine Script Module DragonScript  1.23
Dragengine.Gui.Layouts.FlowLayout Class Reference

Arrange widgets flowing along X or Y axis. More...

Inheritance diagram for Dragengine.Gui.Layouts.FlowLayout:
Dragengine.Gui.Layouts.BoxLayout Dragengine.Gui.Layout

Classes

enum  Stretch
 Stretching. More...
 

Public Member Functions

void doLayout (Container container)
 Layout widgets in container. More...
 
Stretch getStretch ()
 Stretch mode. More...
 
FlowLayout new (LayoutAxis axis)
 Create layout stretching no widget with 0 gap. More...
 
FlowLayout new (LayoutAxis axis, int gap)
 Create layout stretching no widget. More...
 
FlowLayout new (LayoutAxis axis, int gap, Stretch stretch)
 Create layout. More...
 
void setStretch (Stretch stretch)
 Set stretch mode. More...
 
- Public Member Functions inherited from Dragengine.Gui.Layouts.BoxLayout
void addWidget (Widget widget, Object settings)
 Add widget to layout using settings. More...
 
LayoutAxis getAxis ()
 Axis to arrange widgets along. More...
 
int getGap ()
 Gap between child widgets. More...
 
Point getMinimumSize (Container container)
 Minimal size required for layout in container. More...
 
Point getMinimumSizeForHeight (Container container, int height)
 Minimum size of layout using reference widget height and variable width. More...
 
Point getMinimumSizeForWidth (Container container, int width)
 Minimum size of layout using reference width and variable height. More...
 
void removeWidget (Widget widget)
 Remove widget from layout. More...
 
void setAxis (LayoutAxis axis)
 Set axis to arrange along. More...
 
void setGap (int gap)
 Set gap between child widgets. More...
 

Additional Inherited Members

- Protected Member Functions inherited from Dragengine.Gui.Layouts.BoxLayout
Point getMinimumSizeFor (Container container, int width, int height)
 Minimum size of layout using reference and variable size. More...
 

Detailed Description

Arrange widgets flowing along X or Y axis.

Widgets are resized to their minimum size along axis. Extra space is optionally added to the last or first widget.

Instances of this layout can be shared by multiple widgets.

Member Function Documentation

◆ doLayout()

void Dragengine.Gui.Layouts.FlowLayout.doLayout ( Container  container)

Layout widgets in container.

Reimplemented from Dragengine.Gui.Layouts.BoxLayout.

◆ getStretch()

Stretch Dragengine.Gui.Layouts.FlowLayout.getStretch ( )

Stretch mode.

◆ new() [1/3]

FlowLayout Dragengine.Gui.Layouts.FlowLayout.new ( LayoutAxis  axis)

Create layout stretching no widget with 0 gap.

Reimplemented from Dragengine.Gui.Layouts.BoxLayout.

◆ new() [2/3]

FlowLayout Dragengine.Gui.Layouts.FlowLayout.new ( LayoutAxis  axis,
int  gap 
)

Create layout stretching no widget.

Parameters
gapGap between widgets. Can be negative to overlap widgets.

Reimplemented from Dragengine.Gui.Layouts.BoxLayout.

◆ new() [3/3]

FlowLayout Dragengine.Gui.Layouts.FlowLayout.new ( LayoutAxis  axis,
int  gap,
Stretch  stretch 
)

Create layout.

Parameters
gapGap between widgets. Can be negative to overlap widgets.

◆ setStretch()

void Dragengine.Gui.Layouts.FlowLayout.setStretch ( Stretch  stretch)

Set stretch mode.


The documentation for this class was generated from the following file: