Sizers Replacements
For the following discussion please examine the
contents of the 'Sizers' folder found in the 'Later
Breaking' folder.
Some of the convenience view sizers implemented
in USizer.h/.cp had not been fully tested and do
not work as intended. These two files have been
changed and replacements provided in the 'for
MacApp/Libraries/Views/' folder. Simply place them
into the proper 'Sources' and 'Includes' folders.
We are also providing an early sample
application. To use the example drop the 'S' folder
found insize the 'for CodeWarrior/Examples/A-Z/'
folder into your 'MacApp & ACS Release 13:
MacApp:CodeWarrior Support:Examples:A-Z:' folder.
Now drop the 'S' folder found insize the 'for
MacApp/Examples/A-Z/' folder into your 'MacApp
& ACS Release 13: MacApp:MacApp:Examples:A-Z:'
folder. Then open the 'for Ad Lib for MacApp
Preferenc:' folder and drop the four templates and
one palette into the 'Ad Lib for MacApp
Preferences:' folder of your System's
'Preferences:' folder.
When Ad Lib is restarted after installing these
preferences you should see a 'Sizer' palette with
several sizer objects. If the palette doesn't show
choose 'Sizers' from the Window:Objects menu.
Here are some handy constants you may want to
know. For those sizers which require that you
identify the target view which is to be watched for
size changes you also have to specify what that
view's relationship (child, peer or parent) is to
the view to which the sizer behavior is attached.
The constants you should use for this field are:
- 0 = Child (eChildAssociation)
- 1 = Peer (ePeerAssociation)
- 2 = Parent (eParentAssociation)
The TMultiSizer allows you to specify a reaction
for all four aspects of the base view and requires
that you specify the reaction which takes place for
a change in the top, left, height and width of the
target view. Use one of the following for these
four settings:
- 0 = Do not adjust (eDontAdjust)
- 1 = Offset by change in top or left
(eAdjPosByTopOrLeft)
- -1 = Offset negatively by change in top or
left (eAdjNegByTopOrLeft)
- 2 = Offset by change in bottom or right
(eAdjPosByBotOrRight)
- -2 = Offset negatively by change in bottom
or right (eAdjNegByBotOrRight)
The TSizer allows you to specify a single aspect
of the base view which is to react to a change in
the target view. That aspect is specified by one of
the following constants:
- 0 = No aspect is to be changed (eNoMode)
- 1 = Change the top (eTopMode)
- 2 = Change the left (eLeftMode)
- 3 = Change the height (eHeightMode)
- 4 = Change the width (eWidthMode)
TSizer also requires one of the adjustment
settings as specified for TMultiSizer except that
it allows for a sixth value:
- 3 = Proportional (eAdjProportional)
This setting indicates that the selected aspect
of the base view is to be adjusted proportionally
to the height or width. The top or left coordinate
of the base view can be made proportional to any
parent's width and the height or width can be
proportional to any other view's width.
Complete instructions on how to use the sizer
behaviors will be forthcoming. Please check out web
page for announcements.
[We will be providing custom Ad Lib templates
with popup settings for these in the future, making
your job of specifying these values much easier.]
|