ComponentOne Basic Library for WPF and Silverlight
TestPosition(FrameworkElement,Anchor,FrameworkElement,Anchor,Point,Double,Double,FlowDirection) Method


C1.Silverlight Namespace > PopupUtil Class > TestPosition Method : TestPosition(FrameworkElement,Anchor,FrameworkElement,Anchor,Point,Double,Double,FlowDirection) Method
The element to position.
An Anchor value specifying the point in the element to position.
The System.Windows.FrameworkElement to use as reference.
An Anchor value specifying the point in the FrameworkElement used as reference.
The offset (absolute position) of the reference element.
The horizontal overlap between the elements (used for corner matching's).
The vertical overlap between the elements (used for corner matching's).
The FlowDirection used for the calculations.
Calculates the position of a System.Windows.FrameworkElement so that the specified point in the FrameworkElement matches the specified point of another FrameworkElement.
Syntax
'Declaration
 
Public Overloads Shared Function TestPosition( _
   ByVal positionElement As System.Windows.FrameworkElement, _
   ByVal positionAnchor As Anchor, _
   ByVal element As System.Windows.FrameworkElement, _
   ByVal elementAnchor As Anchor, _
   ByVal elementOffset As System.Windows.Point, _
   ByVal overlapHorizontal As System.Double, _
   ByVal overlapVertical As System.Double, _
   ByVal flowDir As System.Windows.FlowDirection _
) As System.Windows.Point
'Usage
 
Dim positionElement As System.Windows.FrameworkElement
Dim positionAnchor As Anchor
Dim element As System.Windows.FrameworkElement
Dim elementAnchor As Anchor
Dim elementOffset As System.Windows.Point
Dim overlapHorizontal As System.Double
Dim overlapVertical As System.Double
Dim flowDir As System.Windows.FlowDirection
Dim value As System.Windows.Point
 
value = PopupUtil.TestPosition(positionElement, positionAnchor, element, elementAnchor, elementOffset, overlapHorizontal, overlapVertical, flowDir)
public static System.Windows.Point TestPosition( 
   System.Windows.FrameworkElement positionElement,
   Anchor positionAnchor,
   System.Windows.FrameworkElement element,
   Anchor elementAnchor,
   System.Windows.Point elementOffset,
   System.double overlapHorizontal,
   System.double overlapVertical,
   System.Windows.FlowDirection flowDir
)

Parameters

positionElement
The element to position.
positionAnchor
An Anchor value specifying the point in the element to position.
element
The System.Windows.FrameworkElement to use as reference.
elementAnchor
An Anchor value specifying the point in the FrameworkElement used as reference.
elementOffset
The offset (absolute position) of the reference element.
overlapHorizontal
The horizontal overlap between the elements (used for corner matching's).
overlapVertical
The vertical overlap between the elements (used for corner matching's).
flowDir
The FlowDirection used for the calculations.

Return Value

The absolute point where the FrameworkElement would be located.
See Also

Reference

PopupUtil Class
PopupUtil Members
Overload List