View Single Post
  #8  
Unread 01-03-2012, 09:08 AM
Alderway Alderway is offline
A Young Mystail Rat
 
Join Date: Dec 2011
Posts: 4
Default

Quote:
Originally Posted by TalTal View Post
cfc is center of object fixed to center of container.

So if your container is 250 wide and your object is 120 wide and your location is 0,0 you are telling it that you want pixel 60 of your object to stay fixed in relation to the center of the container (container center is 125, Object center is 60, so fixed distance is 125-60, or 65). If you were to resize the container to 300 wide it would move your object from 0,0 to 25,0(container center is now 150, 150-65 = 85, half object size is 60 so to make its center be at 85 the object has to reposition to 25).

To center the object via cfc You would want the object above to have a start location of 65,0. This would put the center of the object at the center of the container. When you resized it would still be at the center.
That means, regardless of relation, the location refers always to the left/top corner of the widget.

Other question: Does the widget has to be always within the parent location/ sizes to be displayed or is it possible to show a widget outside of predefined dimensions (to show development datas without desturbing the layout of object in work)?

Alderway
Reply With Quote