Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
GetLayoutSlot Method
Collapse the table of content
Expand the table of content

LayoutInformation.GetLayoutSlot Method

Returns the layout slot, or bounding box, that contains the specified element.

Namespace:  System.Windows.Controls.Primitives
Assembly:  System.Windows (in System.Windows.dll)

'Declaration
Public Shared Function GetLayoutSlot ( _
	element As FrameworkElement _
) As Rect

Parameters

element
Type: System.Windows.FrameworkElement
The element whose layout slot is desired.

Return Value

Type: System.Windows.Rect
The area assigned to the element for layout.

The layout slot is the bounding box that defines the area that an element may occupy. If the element is smaller than the layout slot, it is positioned inside based on its alignment properties. If the element is larger than the layout slot, it is clipped. You can retrieve the visible area of that clipping by calling GetLayoutClip.

The following image shows the dimensions of a parent panel, its child element, and the layout slot that contains the child.

Layout Slot

Silverlight

Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1, Windows Phone OS 7.0

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

ADD
Show:
© 2015 Microsoft