2011-06-05 22 views
0

希望有人能帮助。 我有一个Flex(4.5 /对空)应用程序,已宣布这样的图形:停止火花缩放的图形孩子FlexBuilder4.5

<s:Graphic id="viewRect" width="200" height="200"> 
    <s:Rect id="border" width="200" height="200"> 
    <s:stroke > 
     <s:SolidColorStroke weight="1" color="#606060" /> 
    </s:stroke> 
    </s:Rect> 

    <s:Ellipse id="upperLeftHandle" height="8" width="8" left="-2" top="-2" > 
    <s:fill> 
    <s:SolidColor color="#FFFFFF"/> 
     </s:fill> 
    </s:Ellipse> 
</s:Graphic> 

当我调整图形编程,还扩展边界(矩形)以及椭圆(upperLeftHandle)。我需要调整图形对象的大小,但是Rect和Ellipse(以及图形内的其他任何内容)保持相同的比例。

任何人有任何想法?

回答

0

你必须使用Eclipse这样

<s:Ellipse id="upperLeftHandle" height="8" width="8" x="-2" y="-2" > 

希望能解决你的问题

+0

这绝对没有任何意义。粘贴相同的标签,相同的参数不是答案。如果你不明白这个问题 - 不要在你的帖子上浪费时间。 – JohnD 2011-06-07 18:12:41

0

是否有你需要使用图形标签的具体原因是什么?使用组标记可以让您获得所需的定位和调整大小功能。只要你只是改变组的宽度和高度,你会很好,没有缩放问题。

<s:Group id="viewRect" width="200" height="200"> 
    <s:Rect id="border" left="0" right="0" top="0" bottom="0"> 
     <s:stroke > 
      <s:SolidColorStroke weight="1" color="#606060" /> 
     </s:stroke> 
    </s:Rect> 

    <s:Ellipse id="upperLeftHandle" height="8" width="8" left="-2" top="-2" > 
     <s:fill> 
      <s:SolidColor color="#FFFFFF"/> 
     </s:fill> 
    </s:Ellipse> 
</s:Group>