如何在NativeScript中设置固定宽度列?

如何在NativeScript中设置固定宽度列?,nativescript,angular2-nativescript,Nativescript,Angular2 Nativescript,我有一个三列的gridLayout,如何设置中间列的固定宽度(百分比)和其他自动宽度 我试过这个: <GridLayout class="profiles" rows="auto, auto, auto" columns="*, 90%, *"> </GridLayout> 您可以为第一列设置固定宽度,第二列可以为第三列设置9次 <GridLayout columns="60, 9*, *" rows="*, *" height="230"

我有一个三列的gridLayout,如何设置中间列的固定宽度(百分比)和其他自动宽度

我试过这个:

<GridLayout class="profiles" rows="auto, auto, auto" columns="*, 90%, *">
</GridLayout>

您可以为第一列设置固定宽度,第二列可以为第三列设置9次

<GridLayout columns="60, 9*, *" rows="*, *" height="230"
            backgroundColor="lightgray">
            <Label text="Label 1" row="0" col="0" backgroundColor="red"></Label>
            <Label text="Label 2" row="0" col="1" backgroundColor="green"></Label>
            <Label text="Label 3" row="0" col="2" backgroundColor="blue"></Label>

            <Label text="Label 4" row="1" col="0" backgroundColor="yellow"></Label>
            <Label text="Label 5" row="1" col="1" backgroundColor="orange"></Label>
            <Label text="Label 6" row="1" col="2" backgroundColor="pink"></Label>

        </GridLayout>


我已经为您创建了一个游乐场。

如果您提供了一个更完整的示例,说明您所需的布局,并指出哪些布局与您所需的布局完全不同,那么将很容易为您提供帮助。我已经更新了问题我认为GridLayout列中不支持百分比宽度,另一种方法是找到其容器的90%宽度表单,并将其分配为绝对数。