I don't think I can wait till 3011 for a better implementation, so I guess I'll
make do with non-constant margins and continue to try to get my head around the
On Tue, Aug 16, 2011 at 4:36 PM, Oliver Sims <email@example.com>
I'm just getting to grips (I hope) with
re-sizable dialogs, and have been playing about with dlgAreaUDemoThree.rex
(from the ooDialog Samples folder). I
notice that when I size the dialog, the dialog margins also change. Is
there any way to prevent this? That is, can the margins be kept the same size
regardless of the size of the dialog (assuming that, like dlgAreaUDemo you set
a minimum size for the dialog)?
Not in the current implementation. You could probably enhance the
DlgAreaU class to do it.
Jon Wolfers wrote the class originally and it is a clever
implementation. However, it is has several restrictions and at some point
I would like to write a class, probably a mixin class, that removes the
DlgAreaU parses the source code to determine the dialog controls and their
original dimensions. Because of this, it will only work for UserDialog
dialogs that are not tokenized.
I would implement the functionality in native C++ code, which would
probably give better performance. The Rexx side, the class, would mostly
consist of methods that allow the programmer to specify how the resizing is
done. Things like minimum and maxim size would be set by the programmer
and enforced by the native code.
I would probably have a way to 'pin' a control, which I think is what you
mean by the margins. I.e., if you had a list-view in the upper left corner
you could 'pin' the top of the list-view to the top edge of the dialog and pin
the left edge of the list-view to the left edge of the dialog. This would
have the effect of keeping the top-left corner of the list-view at the same
point in the dialog and all the shrinking and expanding would take place on the
bottom and right.
For myself, not being able to use a ResDialog is a serious disadvantage,
but it is likely to be some time before I get to creating an enhancement.
It is one of the first things I'd like to do as soon as I get 4.2.0
released. Which may not be until the third millennium at my current