我正在尝试创建一个表单,但在对齐 formItems 时遇到问题。
这是 mx:Form 命名空间。(xmlns:mx="http://www.adobe.com/2006/mxml")
有没有人对如何纠正这个有任何建议。任何帮助将不胜感激。
<mx:VBox paddingLeft="0" height="100%">
<form:Form width="100%"
textAlign="left">
<mx:VBox>
<mx:HBox id="snapShotSelect">
<form:FormItem label="My Label Here"
includeInLayout="{model.formItemVisible}"
visible="{model.formItemVisible}"/>
<mx:VBox>
<form:FormItem includeInLayout="{model.formItemVisible}"
visible="{model.formItemVisible}">
<components:SageTextInput textAlign="left"/>
</form:FormItem>
<form:FormItem label=""
visible="{model.formItemVisible}"
includeInLayout="{model.formItemVisible}"/>
<form:FormItem visible="{model.formItemVisible}"
includeInLayout="{model.formItemVisible}">
<components:SageList id="snaps"
allowMultipleSelection="false"
width="200"
rowCount="5"/>
</form:FormItem>
</mx:VBox>
</mx:HBox>
<mx:HBox>
<form:FormItem label="My Label Here"
width="100%"
visible="{model.formItemVisible}"
includeInLayout="{model.formItemVisible}"/>
<form:FormItem label=""
width="100%">
<components:SageComboBox dataProvider="{model.generations}"
textAlign="left"
enabled="{model.generations.length > 0}"/>
</form:FormItem>
</mx:HBox>
<mx:HBox id="radioSelectGroup">
<form:FormItem label="">
<components:SageRadioButtonGroup id="rbGroup"
groupId="rbGroup"
labelPlacement="right"/>
</form:FormItem>
</mx:HBox>
<mx:HBox id="radioNew">
<form:FormItem>
<components:SageRadioButton id="radioCopy" value="{model.RADIO_CREATE}"
group="{rbGroup}"
labelPlacement="right"
width="250"
label="Radio Button 1" />
</form:FormItem>
<form:FormItem>
<components:SageTextInput textAlign="left"
enabled="{rbGroup.selectedValue == model.RADIO_CREATE}"/>
</form:FormItem>
</mx:HBox>
<mx:HBox id="radioExisting">
<form:FormItem>
<components:SageRadioButton id="radioNoCopy" value="{model.RADIO_USE_EXISTING}"
group="{rbGroup}"
labelPlacement="right"
width="250"
label="Radio Button 2"/>
</form:FormItem>
<mx:VBox>
<form:FormItem label=""
paddingBottom="0">
<components:SageTextInput textAlign="left"
enabled="{rbGroup.selectedValue == model.RADIO_USE_EXISTING}"/>
</form:FormItem>
<form:FormItem label=""
indentationLevel="0"
paddingTop="0">
<components:SageList allowMultipleSelection="false"
width="200"
rowCount="5"
enabled="{rbGroup.selectedValue == model.RADIO_USE_EXISTING}"/>
</form:FormItem>
</mx:VBox>
</mx:HBox>
</mx:VBox>
</form:Form>
</mx:VBox>
目前看起来像这样。
但我希望它看起来像这样