CVB.Net 15.0
Loading...
Searching...
No Matches

Adorner hosting any FrameworkElement. More...

Inherited by ZoomAdorner.

Public Member Functions

 ContentAdorner (UIElement adornedElement)
 Creates an empty adorner for the given adornedElement .
 
 ContentAdorner (FrameworkElement content, UIElement adornedElement)
 Creates an adorner showing the given content on the given adornedElement .
 

Static Public Attributes

static readonly DependencyProperty ContentProperty
 Backing store of the Content property.
 
static readonly DependencyProperty XProperty
 Backing store for the X property.
 
static readonly DependencyProperty YProperty
 Backing store for the Y property.
 
static readonly DependencyProperty HasContentProperty
 Backing store of the HasContent property.
 

Protected Member Functions

override Size ArrangeOverride (Size finalSize)
 Places the content on the control.
 
override Visual GetVisualChild (int index)
 Gets the content as the visual child if present.
 
override Size MeasureOverride (Size constraint)
 Measures the content of this adorner.
 

Properties

FrameworkElement Content [get, set]
 Gets/sets the FrameworkElement to show as adorner.
 
double X [get, set]
 Gets/sets the x-coordinate of the content relative to the adorned element.
 
double Y [get, set]
 Gets/sets the y-coordinate of the content relative to the adorned element.
 
bool HasContent [get]
 Gets whether this adorner has a content element.
 
override int VisualChildrenCount [get]
 Gets the number of visual children.
 

Detailed Description

Adorner hosting any FrameworkElement.

Constructor & Destructor Documentation

◆ ContentAdorner() [1/2]

ContentAdorner ( UIElement adornedElement)

Creates an empty adorner for the given adornedElement .

Parameters
adornedElementElement to adorn.

◆ ContentAdorner() [2/2]

ContentAdorner ( FrameworkElement content,
UIElement adornedElement )

Creates an adorner showing the given content on the given adornedElement .

Parameters
contentElement to show.
adornedElementElement to adorn.

Member Function Documentation

◆ ArrangeOverride()

override Size ArrangeOverride ( Size finalSize)
protected

Places the content on the control.

Parameters
finalSizeActual size of the adorner.
Returns
Used size.

◆ GetVisualChild()

override Visual GetVisualChild ( int index)
protected

Gets the content as the visual child if present.

Parameters
indexOnly 0 is accepted if content is present.
Returns
The content as a Visual.

◆ MeasureOverride()

override Size MeasureOverride ( Size constraint)
protected

Measures the content of this adorner.

Parameters
constraintOuter limit.
Returns
Desired size.