VisualTreeHelper.GetContentBounds 메서드
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
에 대해 캐시된 경계 상자 사각형을 Visual반환합니다.
오버로드
| Name | Description |
|---|---|
| GetContentBounds(Visual3D) |
지정된 Visual3D경계 상자 사각형을 반환합니다. |
| GetContentBounds(Visual) |
지정된 Visual경계 상자 사각형을 반환합니다. |
GetContentBounds(Visual3D)
지정된 Visual3D경계 상자 사각형을 반환합니다.
public:
static System::Windows::Media::Media3D::Rect3D GetContentBounds(System::Windows::Media::Media3D::Visual3D ^ reference);
public static System.Windows.Media.Media3D.Rect3D GetContentBounds(System.Windows.Media.Media3D.Visual3D reference);
static member GetContentBounds : System.Windows.Media.Media3D.Visual3D -> System.Windows.Media.Media3D.Rect3D
Public Shared Function GetContentBounds (reference As Visual3D) As Rect3D
매개 변수
- reference
- Visual3D
경계 상자 값이 계산되는 3D 시각적 개체입니다.
반품
에 대한 Visual3D경계 상자 3D 사각형입니다.
설명
메서드를 GetDescendantBounds 사용 하 여 3D 시각적 개체의 모든 하위 항목에 대 한 모든 콘텐츠 경계 상자의 합합을 반환 하는 자체 포함 Visual3D 합니다.
추가 정보
적용 대상
GetContentBounds(Visual)
지정된 Visual경계 상자 사각형을 반환합니다.
public:
static System::Windows::Rect GetContentBounds(System::Windows::Media::Visual ^ reference);
public static System.Windows.Rect GetContentBounds(System.Windows.Media.Visual reference);
static member GetContentBounds : System.Windows.Media.Visual -> System.Windows.Rect
Public Shared Function GetContentBounds (reference As Visual) As Rect
매개 변수
반품
에 대한 경계 상자 사각형입니다 Visual.
예제
다음 예제에서는 개체의 Visual 경계 사각형을 검색하는 방법을 보여줍니다.
// Return the bounding rectangle of the parent visual object and all of its descendants.
Rect rectBounds = VisualTreeHelper.GetDescendantBounds(parentVisual);
' Return the bounding rectangle of the parent visual object and all of its descendants.
Dim rectBounds As Rect = VisualTreeHelper.GetDescendantBounds(parentVisual)
설명
메서드를 GetDescendantBounds 호출하여 개체 자체를 포함하는 시각적 개체의 모든 하위 항목에 대한 모든 콘텐츠 경계 상자의 합합을 Visual 반환합니다.