1 Reply Latest reply on Jun 2, 2010 5:14 AM by TeotiGraphix

    Positioning UI Elements

    samschauhan Level 1

      How is constraint-based layouts different from enhanced constraints wrt UI elements positioning?

       

      Basically I know what is constraint-based layout but not sure about enhanced constraints.

        • 1. Re: Positioning UI Elements
          TeotiGraphix Level 3

          Hi,

           

          Standard constraints use top, right, bottom and left Number values.

           

          Enhanced constraints use a string like [dentifier:numeric] col1:20 to defined a constraint column or row:50 to define a constraint row. You would declare these instances (IConstraintColumn, IConstraintRow) in MXML or create them in actionscript. The Canvas uses these properties.

           

          Then when you are using your constraints on a visual element instead of using a Number, you refer to the col1:20 string and as that column moves all constraints tied to that column move as well. The same applies for the rows.

           

          Mike