Layout a series of (input) widgets in a form. Example:

from flexx import ui

class Example(ui.Widget):
    def init(self):
        with ui.FormLayout():
            self.b1 = ui.LineEdit(title='Name:')
            self.b2 = ui.LineEdit(title="Age:")
            self.b3 = ui.LineEdit(title="Favorite color:")
            ui.Widget(flex=1)  # Spacing
open in new tab

Also see examples:

class flexx.ui.layouts._form.BaseTableLayout(*init_args, **kwargs)

Inherits from: Layout

Abstract base class for layouts that use an HTML table.

Layouts that use this approach don’t have good performance when resizing. This is not so much a problem when it is used as a leaf layout, but it’s not recommended to embed such layouts in each-other.


alias of BaseTableLayout

class flexx.ui.FormLayout(*init_args, **kwargs)

Inherits from: BaseTableLayout

A layout widget that vertically alligns its child widgets in a form. A label is placed to the left of each widget (based on the widget’s title).

The node of this widget is a <table>. (This may be changed to use a CSS layout instead.)


alias of FormLayout