Enaml Looper水平布局

时间:2015-11-18 02:03:24

标签: enaml

默认情况下,下面的代码将垂直堆叠每个GroupBox对象(一个在另一个下面)。

enamldef Main(Window):
    attr model

    Container:
        constraints = [ hbox(items) ]

        Container: items:
            Looper:
                iterable << model.l              # model.l = some list of atom objects
                    GroupBox:
                        title << loop_item.name                
                        CheckBox:
                            checked := loop_item.active

我如何将它们放在一个弯针中,使它们水平堆叠(从左到右)?

我在enaml docs / API中找不到任何相关信息。

1 个答案:

答案 0 :(得分:1)