In a rebar control, each element is added as a band object. Bands may be organized into distinct rows called bars. Does anyone know of a method or tut or something to resize just one specific bar in a rebar?
Posted on 2001-02-15 13:22:00 by Ernie
Can this message help? RB_SIZETORECT Attempts to find the best layout of the bands for the given rectangle. RB_SIZETORECT wParam = 0; lParam = (LPARAM)(LPRECT) prc; Parameters prc Address of a RECT structure that specifies the rectangle to which the rebar control should be sized. Return Values Returns nonzero if a layout change occurred, or zero otherwise. Remarks The rebar bands will be arranged and wrapped as necessary to fit the rectangle. Bands that have the RBBS_VARIABLEHEIGHT style will be resized as evenly as possible to fit the rectangle. The height of a horizontal rebar or the width of a vertical rebar may change, depending on the new layout. Requirements Version 4.71 and later of Comctl32.dll
Posted on 2001-02-16 08:13:00 by RVA
RB_SIZETORECT resizes the entire rebar, not just a single bar, so the results are indeterminate. ...perhaps if I first walked thru the bands, determined which bar each is on (no direct function for this I can see, would need a RB_GETRECT, then region matching for each band), so those bands in the bar marked RBS_AUTOSIZE, those not marked NOT RBS_AUTOSIZE), THEN sending RB_SIZETORECT ... ...and don't forget to re-set the styles when done... That's why I asked... a ton of work for such a trivial thing.
Posted on 2001-02-16 11:30:00 by Ernie