ComponentOne Sizer 8.0
Uneven Sizing

AutoSizeChildren = 2 - azUnevenHorz, 4 - azUnevenVert

Sometimes you do not want all the children controls to be the same size or to remain proportional. A typical example is a status bar, where you may reserve a few fixed-size spots to show keyboard status and use the remaining space to show help messages and prompts.

The pictures below show a form with an Elastic-based status bar, before and after resizing:

The Elastic shown above has the Align property set to 2 - asBottom and the AutoSizeChildren property set to 2 - azUnevenHorz. It also has a number of child controls used to display status information. When the form is resized, only the leftmost child gets resized.

How does the Elastic decide which child to resize? It always picks the topmost control. All you have to do to create unevenly spaced Elastics is:

  1. Create all the children and size them appropriately;

  2. Decide which one you would like the Elastic to resize for you, and make it the foremost control using Visual Basic's Format|Order|Bring to Front menu option (or pressing ctrl-J);

  3. Set the AutoSizeChildren property to one of the uneven settings.

That is all there is to uneven spacing. When the Elastic is resized, the foremost child gets stretched to fill the gap left by the others.

 

 


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

Product Support Forum  |  Documentation Feedback