ComponentOne Sizer 8.0
Even Sizing

AutoSizeChildren = 1 - azEvenHorz, 3 – azEvenVert

Use these settings when you want to distribute controls evenly within the Elastic. The picture below shows how these settings work when you resize a form.

The Elastic aligned to the top of the form has AutoSizeChildren set to azEvenHorz, and the vsElastic aligned to the left of the form has AutoSizeChildren set to azEvenVert. Notice how they resize the controls inside them as the form gets resized.

Changing the order of the children within the Elastic is easy, just drag controls to their new position with the mouse. The Elastic will automatically sort and align them for you. The resizing works at design time too.

If you want, you can also change the order of the children at runtime; all you have to do is move the control with code just like you would with the mouse. For example, to move button 4 to the left of button 3 on the form shown above, you would use; the following code:

Example Title
Copy Code
Button4.Left = (Button3.Left - Button2.Left) \ 2

The above code would move button 4 to a position between buttons 2 and 3. The Elastic would then take care of realigning the controls to the proper position.

 

 


Copyright (c) GrapeCity, inc. All rights reserved.

Product Support Forum  |  Documentation Feedback