2 Replies Latest reply on Jul 4, 2011 7:53 AM by daslicht

    Layout

    daslicht Level 2

      How do I create such layout behaviour:

       

      http://www.parikshalabs.com/

       

      They use a Flex Vertical  Scroller which is shown once the page rech a certain size.

      But at the same time they have a "infinite background" How is that working ?

       

      Cheers

      Marc

        • 1. Re: Layout
          daslicht Level 2
          <?xml version="1.0" encoding="utf-8"?>
          <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">
               
               <!--BIG Background-->
               <s:Rect left="0" right="0" top="0" bottom="0" minHeight="2500" height='1440'>
                    <s:fill>
                         <s:SolidColor  color="0x888888"/>
                    </s:fill>
               </s:Rect>
               
               <!--Content with minimum required Height-->
               <s:Group left="20" top="1" width="400" height="100%">
                    <s:Scroller  left="0" right="0" top="0" bottom="0">
                         <s:Group id="g"   >
                              <s:Rect left="0" right="0" top="0" bottom="0" minHeight="400" height='100%'>
                                   <s:fill>
                                        <s:SolidColor  color="0x000000"/>
                                   </s:fill>
                              </s:Rect>
                         </s:Group>
                    </s:Scroller>
               </s:Group>
               
          </s:Application>
          

           

           

           

          Good starting pount but how to use a fixed heigh content ? which show scrollbars one a minimum is reached :/

           

          [EDIT:]

          got it:) but how to prevent that the content jump to the left once the vertical scrollbar is shown ?

          • 2. Re: Layout
            daslicht Level 2

            I have the following Application, once the minimum size is reached the scrollbar is shown.

            Unfortunately each time the scrollbar is shown, the whole content jumps to the left size as wide as the scollbar is.

             

            How to create a horrizontal centered layout with out that jump ?

             the answer is to create acustom scroller skin
            

            [SOLVED]