2 Replies Latest reply on May 19, 2010 3:19 AM by manpakhong

    Flex 4 Mdi canvass, how to set background image..?

    Ling's

      Hi.,

       

           Now i try to use mdi canvass  background image,how to set  background image in mdi canvass in flex 4..

       

       

      With Regards

      LinFlex-

        • 1. Re: Flex 4 Mdi canvass, how to set background image..?
          manpakhong Level 1

          In the past flex 3 version, there is an attribute call <flexlib:MDICanvas  backgroundImage="@Embed(source='/imgFolder/imgFile.png')/>

          to set it. However it has problem in Flex 4 because of 'halo' and 'spark' theme library changed.

          The following is my post that still haven't found the answer.

           

           

          ----------------------------- ----------------------------------------------------------------------------------------- -------------------------------------------------------

           

          Dear all,

           

          We  have a project that doing migration from flex 3 to flex 4. We use  flexlib the latest version of
          flexlib - 2.5 - flex4.zip.

           

          However we  confronted problems that several of attributes that flex 4 doesn't  support:
          Constraints are listed as follows:

           

          1) <flexlib:MDICanvas  backgroundImage="@Embed(source='/imgFolder/imgFile.png')/>
          2)  <flexlib:MDICanvas backgroundSize="auto"/>
          3)  <mx:ApplicationControlBar barColor="#000000">

           

           

           

          original error message:
          ====================================================
          Description     Resource    Path    Location    Type
          The style 'backgroundImage' is  only supported by type 'flexlib.mdi.containers.MDICanvas' with the  theme(s) 'halo'.    MainView.mxml     /osss/flex_src/hk/gov/labour/osss/view    line 242    Flex Problem

           

          Description    Resource    Path     Location    Type
          The style 'backgroundSize' is only supported by type  'flexlib.mdi.containers.MDICanvas' with the theme(s) 'halo'.     MainView.mxml    /osss/flex_src/hk/gov/labour/osss/view    line 242     Flex Problem

           

          Description     Resource    Path    Location    Type
          The style 'barColor' is only  supported by type 'mx.containers.ApplicationControlBar' with the  theme(s) 'halo'.    MainView.mxml     /osss/flex_src/hk/gov/labour/osss/view    line 227    Flex Problem

           


          Regards,
          Man  Pak Hong, Dave
          manpakhong
          manpakhong@hotmail.com

          • 2. Re: Flex 4 Mdi canvass, how to set background image..?
            manpakhong Level 1

            We find the answer.
            The problem is that the project theme is using spark as default. But the  MDICanvas use Theme Halo. So that we need to change the theme from  Spark to Halo.

             

            Doing this by:


            Right-click  the Project --> Flex Theme --> Choose Halo from "Adobe Themes -  Halo"

             

             

            Man Pak Hong, Dave

            manpakhong

            manpakhong@hotmail.com