1 Reply Latest reply on Jan 1, 2011 2:54 PM by Shongrunden

    Spark FormItem

    Zolotoj Level 3

      What's an equivalent of Halo's direction property?

       

      Thanks

        • 1. Re: Spark FormItem
          Shongrunden Adobe Employee

          The spark FormItem does not have a direction property.  Instead you would specify a different layout on the FormItem.  This layout is pushed down into the contentGroup of the FormItem's skin like any other SkinnableContainer.

           

          For example:

           

          <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"

                         xmlns:s="library://ns.adobe.com/flex/spark"

                         xmlns:mx="library://ns.adobe.com/flex/mx">

           

              <s:layout>

                  <s:VerticalLayout />

              </s:layout>

           

              <s:Form>

                  <s:FormItem label="Test 1">

                      <s:layout>

                          <s:VerticalLayout />

                      </s:layout>

           

                      <s:TextInput />

                      <s:TextInput />

                      <s:TextInput />

                  </s:FormItem>

                  <s:FormItem label="Test 2">

                      <s:layout>

                          <s:HorizontalLayout />

                      </s:layout>

           

                      <s:TextInput />

                      <s:TextInput />

                      <s:TextInput />

                  </s:FormItem>

              </s:Form>

           

              <mx:Form>

                  <mx:FormItem label="Test 1" direction="vertical">

                      <s:TextInput />

                      <s:TextInput />

                      <s:TextInput />

                  </mx:FormItem>

                  <mx:FormItem label="Test 2" direction="horizontal">

                      <s:TextInput />

                      <s:TextInput />

                      <s:TextInput />

                  </mx:FormItem>

              </mx:Form>

           

          </s:Application>

           

          Check out the spark Form spec for more details:

          https://opensource.adobe.com/wiki/display/flexsdk/Spark+Form