Modifica

Condividi tramite


SplitContainer.SplitterRectangle Property

Definition

Gets the size and location of the splitter relative to the SplitContainer.

public:
 property System::Drawing::Rectangle SplitterRectangle { System::Drawing::Rectangle get(); };
[System.ComponentModel.Browsable(false)]
public System.Drawing.Rectangle SplitterRectangle { get; }
[<System.ComponentModel.Browsable(false)>]
member this.SplitterRectangle : System.Drawing.Rectangle
Public ReadOnly Property SplitterRectangle As Rectangle

Property Value

A Rectangle that specifies the size and location of the splitter relative to the SplitContainer.

Attributes

Remarks

Use SplitterRectangle to get the width and height of the splitter relative to the SplitContainer. The OnKeyDown, OnKeyUp, OnMouseDown, OnMouseUp, and OnMouseMove event handlers draw the SplitterRectangle to show the current position of the splitter while it is moving.

The meaning of the SplitterRectangle values vary depending on the Orientation. The output of SplitterRectangle is in the format {X, Y, Width, Height}. The following table shows the meaning of the SplitterRectangle values for vertical and horizontal splitters.

Dimension Vertical Splitter Horizontal Splitter
X The distance in pixels of the splitter from the left edge of the SplitContainer. This value is always 0 for a horizontal splitter, indicating that the splitter is flush with the left edge of the SplitContainer.
Y This value is always 0 for a vertical splitter, indicating that the splitter is flush with the top edge of the SplitContainer. The distance in pixels of the splitter from the top edge of the SplitContainer.
Width The width of the splitter. The height of the splitter, which is equivalent to the height of the SplitContainer control.
Height The height of the splitter, which is equivalent to the height of the SplitContainer control. The width of the splitter.

Applies to

See also