Skybound Rebar

RebarBand.ClientRectangle Property

Gets a value that specifies the bounds of the client area of the band.

[Visual Basic]
Public ReadOnly Property ClientRectangle As Rectangle
[C#]
public System.Drawing.Rectangle ClientRectangle {get;}

Property Value

A Rectangle that represents the bounding rectangle of the client area of the band.

Remarks

The client area is the space in which the band's buttons are positioned.

In left-to-right layouts, the client area spans from the far edge of the right-most element, either the text, image or size grip, depending on which are visible for the current band, to the right edge of the band. In right-to-left layouts, the client area spans from the left edge of the band to the left-most element, either the text, image or size grip.

Example

This example handles the ClientRectangleChanged event of a rebar band and dynamically sets the caption text of the form to the value of the ClientRectangle property when the size of the band changes.

private void rebarBand1_ClientRectangleChanged(object sender, System.EventArgs e)
{
    this.Text = (sender as RebarBand).ClientRectangle.ToString();
}
            

See Also

RebarBand Class | Skybound.Rebar Namespace