Developer

API Reference

IPropContainer_SetPaddingProportional()

Brew Release
Brew MP 1.0.2
See Also
- IPropContainer_GetPadding()
- IPropContainer_SetPadding()
- IPropContainer_SetPaddingExact()
Description
This function is used to set a proportional spacer ahead and/or behind a given widget in a PropContainer. Values passed as the leading or trailing padding are interpreted as the numerator of the fraction of this spacers's extent to the combined extents of all other proportional objects managed by the container.
Parameters
  • pif
    []:
    A pointer to an IPropContainer object.
  • pw
    []:
    Identifies the widget within the prop container's widget stack that will serve as a reference point for the widget to be retrieved. This widget may be expressed explicitly as a widget pointer, or implicitly as a constant that identifies a relative position within the widget stack, as follows. WIDGET_ZNORMAL - Use the widget at the prop container's default location as the retrieval reference point. BREW interprets this to be the widget at the top of the widget stack. WIDGET_ZTOPMOST - Use the widget at the top of the widget stack as the retrieval reference point. WIDGET_ZBOTTOMMOST - Use the widget at the bottom of the widget stack as the retrieval reference point. When 'pw' is NULL, the function will return either the top or bottom widget on the stack depending on the value of 'd'. When 'pw' is NULL and 'd' is TRUE, IPropContainer_GetWidget() will return the bottommost widget. When 'pw' is NULL and 'd' is FALSE, the function will return the topmost widget.
  • dwBefore
    []:
    Specifies the proportional layout value of the padding to be applied ahead of the widget.
  • dwAfter
    []:
    Specifies the proportional layout value of the padding to be applied after of the widget.

Prototype
   int IPropContainer_SetPaddingProportional(
      IPropContainer *pif, 
      IWidget *pw, 
      int32 dwBefore, 
      int32 dwAfter);
Return
   
   AEE_SUCCESS   --  The spacing around the widget was successfully set.
   AEE_EBADPARM  --  The widget pointer passed in 'pw' either does not exist, or 
                 refers to a widget that is not in the prop container's widget 
                 stack.

Side Effect
Calling IPropContainer_SetPaddingProportional() will cause the PropContainer to adjust the object layout to include the newly added spacing.
Comment
Use this routine to add a proportionally-sized spacer before and/or after a widget in the PropContainer.
  • Follow