A Flash Developer Resource Site

Results 1 to 6 of 6

Thread: 9 Scale issue for flex component

  1. #1
    Senior Member sakie's Avatar
    Join Date
    Apr 2005
    Location
    London
    Posts
    285

    9 Scale issue for flex component

    Hi

    I'm hoping that this is something simple and I'm missing something obvious but here it goes : Please download and review FLA from http://www.theverticalhorizon.com/TestButton.zip it has a flex component with 9 scale enabled. I've a small triangle icon. I want the triangle icon to retain its size when the width and height of this button is change so I've placed it in the third portion of 9 scale.Whats happening is really weird when I've just one triangle icon that spans all the frame 9 scale works perfectly fine however when I try creating multiple instances of the same icon for various states 9 scaling is screwed.

    Any help in this regard would be highly appreciated.

    Many thanks

    S.

  2. #2
    AS2 intolerant person
    Join Date
    Jan 2009
    Location
    Swansea
    Posts
    352
    I've taken a look, however there is nothing i can see thats strange.

    Can you upload the mxml and any scripts used to make the flex component please.

  3. #3
    Senior Member sakie's Avatar
    Join Date
    Apr 2005
    Location
    London
    Posts
    285
    Many thanks for your response. I've create this asset as movie clip in Flash and converted in to Flex component. The issue is that when you scale the height of this component the 9 scale doesn't work the way it should however if you edit the movie clip make the layer containing several different colors of triangle (which is currently active) guide layer and make the layer containing just one instance of triangle (currently set to guide) everything starts behaving the way it should

  4. #4
    AS2 intolerant person
    Join Date
    Jan 2009
    Location
    Swansea
    Posts
    352
    ok i found the 'cause' of the problem. whether you will find the solution useful is another matter.

    I got it working by redrawing the triangle and converting it to a graphic.

    I've only use the scale grid in flex applications so i dont know if it is possible to position a movieclip in one of the slices and make it unscalable.

    however if you can settle for redrawing the triangle as a 'shape' rather than a 'group' (which is what is it right now) and convert it to a graphic, then your problem is solved.

    EDIT:

    what are you making anyway? because for whatever reason you converted it to a flex component, surely you would benefit from actually making your application using Flash Builder.
    Last edited by flosculus; 06-24-2011 at 10:03 AM.

  5. #5
    Senior Member sakie's Avatar
    Join Date
    Apr 2005
    Location
    London
    Posts
    285

    Thumbs up

    It did fix the issue many thanks

  6. #6
    Senior Member
    Join Date
    Jun 2003
    Location
    Kent, WA
    Posts
    536
    Certain objects (such as bitmaps and movieclips) do not scale as you would expect them to under 9-slice. Maybe it was done for performance reasons, I dunno.

    3rd party companies such as Scaleform have implemented their own version of 9-slice that functions correctly. But those obviously do not work on the web.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center