LinkPanel

StockSharp.Xaml.Diagram.GXDiagram

A LinkPanel is a Panel used to position and orient elements along the route of a Link.

Inherits: Panel

Constructors

LinkPanel
public LinkPanel()
linkPanel = LinkPanel()

Construct an empty LinkPanel.

Properties

Implementation
public LinkPanelImplementation Implementation { get; set; }
value = linkPanel.Implementation
linkPanel.Implementation = value

Gets or sets the nature of the link implementation.

Path
public Shape Path { get; }
value = linkPanel.Path

Gets the LinkShape that represents the visual path of the Route of the Link.

Methods

ArrangeOverride
protected override Size ArrangeOverride(Size finalSize)
result = linkPanel.ArrangeOverride(finalSize)

Arrange the child elements of this panel and of any label nodes.

finalSize
ComputeAngle
protected virtual double ComputeAngle(UIElement elt, LabelOrientation orient, double angle)
result = linkPanel.ComputeAngle(elt, orient, angle)

Dynamically compute the desired angle of an element along a segment of the route.

elt
the UIElement being rotated
orient
the LabelOrientation declared for the element
angle
the angle of the segment of the route where the element is attached

Returns: the intended angle for the element

ComputeOffset
protected virtual Point ComputeOffset(UIElement elt, int index, double segangle, Size sz, double labelangle)
result = linkPanel.ComputeOffset(elt, index, segangle, sz, labelangle)

Compute the offset to use in determining the position of a label.

elt
the label being positioned, either a child element of the LinkPanel or the VisualElement of a label Node
index
the segment of the link, or a negative value if the label should be at the MidPoint
segangle
the angle of the th segment, or the MidAngle
sz
the size of the label
labelangle
the angle at which the label is rotated, from calling Double)

Returns: an offset that is rotated according to the angle of the segment; this will be added to the midpoint of the link or to the fractional point along the segment

GetAlignment
public static Spot GetAlignment(DependencyObject d)
result = LinkPanel.GetAlignment(d)

Gets an element's alignment spot, which controls the point of the element that is positioned at a distance of the way along a particular segment of the route.

d
a child element of a LinkPanel

Returns: The default value is Center.

GetFraction
public static double GetFraction(DependencyObject d)
result = LinkPanel.GetFraction(d)

Gets the fractional distance along a segment at which the element should be positioned.

d
a child element of a LinkPanel

Returns: The default value is zero. For negative indexes, the fraction increases from zero to one as the point moves from the "to" end towards the "from" end.

GetFromArrow
public static Arrowhead GetFromArrow(DependencyObject d)
result = LinkPanel.GetFromArrow(d)

Gets the Arrowhead on a Path, at the FromNode end.

d
a child element of a LinkPanel

Returns: The default value is None, meaning there is no Arrowhead on the element.

GetFromArrowScale
public static double GetFromArrowScale(DependencyObject d)
result = LinkPanel.GetFromArrowScale(d)

Gets the size of the Arrowhead on an element, at the FromNode end, as a scale multiple of its base size.

d
a child element of a LinkPanel

Returns: The default value is 1.0, indicating the base size defined in Generic.xaml.

GetIndex
public static int GetIndex(DependencyObject d)
result = LinkPanel.GetIndex(d)

Gets an element's segment index along the link's route.

d
a child element of a LinkPanel

Returns: Zero identifies the segment closest to the "from" end of the route. Positive values identify segments further along the route. Negative values identify segments starting at the "to" end of the route; -1 is the last segment, -2 is the next to last, etc. If the index is not specified for an element, the LinkPanel will arrange it to be at the Route's MidPoint.

GetIsLinkShape
public static bool GetIsLinkShape(DependencyObject d)
result = LinkPanel.GetIsLinkShape(d)

Gets whether a LinkShape is the primary stroke for the link.

GetOffset
public static Point GetOffset(DependencyObject d)
result = LinkPanel.GetOffset(d)

Gets the distances from the fractional point of a link segment at which the element should be positioned.

d
a child element of a LinkPanel

Returns: The default value is (0, 0). The offset distances are in model coordinates. The offset is rotated to the angle of the link segment. Positive X values result in the element being positioned farther along the link segment; negative values are closer. Positive Y values result in the element being positioned away from the link segment on the right side of the path; negative values go toward the left side.

GetOrientation
public static LabelOrientation GetOrientation(DependencyObject d)
result = LinkPanel.GetOrientation(d)

Gets an element's intended rotation policy.

d
a child element of a LinkPanel

Returns: The default value is None, meaning the element is not to be rotated.

GetToArrow
public static Arrowhead GetToArrow(DependencyObject d)
result = LinkPanel.GetToArrow(d)

Gets the Arrowhead on a Path, at the ToNode end.

d
a child element of a LinkPanel

Returns: The default value is None, meaning there is no Arrowhead on the element.

GetToArrowScale
public static double GetToArrowScale(DependencyObject d)
result = LinkPanel.GetToArrowScale(d)

Gets the size of the Arrowhead on an element, at the ToNode end, as a scale multiple of its base size.

d
a child element of a LinkPanel

Returns: The default value is 1.0, indicating the base size defined in the xaml.

IsFilled
public static bool IsFilled(Arrowhead arrow)
result = LinkPanel.IsFilled(arrow)

Returns whether an Arrowhead should be filled.

arrow
The Arrowhead which should or should not be filled.

Returns: True if the Arrowhead should be filled.

MeasureOverride
protected override Size MeasureOverride(Size availableSize)
result = linkPanel.MeasureOverride(availableSize)

Determine the size of the union of the bounds of the positioned and rotated child elements.

availableSize
SetAlignment
public static void SetAlignment(DependencyObject d, Spot v)
LinkPanel.SetAlignment(d, v)

Sets an element's alignment spot, which controls the point of the element that is positioned at a distance of the way along a particular segment of the route.

d
a child element of a LinkPanel
v
SetFraction
public static void SetFraction(DependencyObject d, double v)
LinkPanel.SetFraction(d, v)

Sets the fractional distance along a segment at which the element should be positioned.

d
a child element of a LinkPanel
v
The fraction should be between zero and one, inclusive. For non-negative indexes, the fraction increases from zero to one as the point moves from the "from" end toward the "to" end. For negative indexes, the fraction increases from zero to one as the point moves from the "to" end towards the "from" end.
SetFromArrow
public static void SetFromArrow(DependencyObject d, Arrowhead v)
LinkPanel.SetFromArrow(d, v)

Sets the Arrowhead on a Path, at the FromNode end.

d
a child element of a LinkPanel
v
the constant of the Arrowhead enum to which FromArrowProperty is being set.
SetFromArrowScale
public static void SetFromArrowScale(DependencyObject d, double v)
LinkPanel.SetFromArrowScale(d, v)

Sets the size of the Arrowhead on an element at the FromNode end as a scale multiple of its base size.

d
a child element of a LinkPanel
v
the scale factor. Acceptable values are real numbers between zero and infinity.
SetIndex
public static void SetIndex(DependencyObject d, int v)
LinkPanel.SetIndex(d, v)

Sets an element's segment index along the link's route.

d
a child element of a LinkPanel
v
Zero identifies the segment closest to the "from" end of the route. Positive values identify segments further along the route. Negative values identify segments starting at the "to" end of the route; -1 is the last segment, -2 is the next to last, etc. If the index is not specified for an element, the LinkPanel will arrange it to be at the Route's MidPoint.
SetIsLinkShape
public static void SetIsLinkShape(DependencyObject d, bool v)
LinkPanel.SetIsLinkShape(d, v)

Sets whether a LinkShape is the primary stroke for the link.

SetOffset
public static void SetOffset(DependencyObject d, Point v)
LinkPanel.SetOffset(d, v)

Sets the distances from the fractional point of a link segment at which the element should be positioned.

d
a child element of a LinkPanel
v
The offset distances are in model coordinates. The offset is rotated to the angle of the link segment. Positive X values result in the element being positioned farther along the link segment; negative values are closer. Positive Y values result in the element being positioned away from the link segment on the right side of the path; negative values go toward the left side.
SetOrientation
public static void SetOrientation(DependencyObject d, LabelOrientation v)
LinkPanel.SetOrientation(d, v)

Sets an element's intended rotation policy.

d
a child element of a LinkPanel
v
SetToArrow
public static void SetToArrow(DependencyObject d, Arrowhead v)
LinkPanel.SetToArrow(d, v)

Sets the Arrowhead on a Path, at the ToNode end.

d
a child element of a LinkPanel
v
the constant of the Arrowhead enum to which ToArrowProperty is being set.
SetToArrowScale
public static void SetToArrowScale(DependencyObject d, double v)
LinkPanel.SetToArrowScale(d, v)

Sets the size of the Arrowhead on an element, at the ToNode end, as a scale multiple of its base size.

d
a child element of a LinkPanel
v
the scale factor. Acceptable values are real numbers between zero and infinity.

Fields

AlignmentProperty
public static readonly DependencyProperty AlignmentProperty
value = LinkPanel.AlignmentProperty

Identifies the Alignment attached dependency property.

FractionProperty
public static readonly DependencyProperty FractionProperty
value = LinkPanel.FractionProperty

Identifies the Fraction attached dependency property.

FromArrowProperty
public static readonly DependencyProperty FromArrowProperty
value = LinkPanel.FromArrowProperty

Identifies the FromArrow attached dependency property.

FromArrowScaleProperty
public static readonly DependencyProperty FromArrowScaleProperty
value = LinkPanel.FromArrowScaleProperty

Identifies the FromArrowScale attached dependency property.

ImplementationProperty
public static readonly DependencyProperty ImplementationProperty
value = LinkPanel.ImplementationProperty

Identifies the Implementation dependency property.

IndexProperty
public static readonly DependencyProperty IndexProperty
value = LinkPanel.IndexProperty

Identifies the Index attached dependency property.

IsLinkShapeProperty
public static readonly DependencyProperty IsLinkShapeProperty
value = LinkPanel.IsLinkShapeProperty

Identifies the IsLinkShape dependency property.

OffsetProperty
public static readonly DependencyProperty OffsetProperty
value = LinkPanel.OffsetProperty

Identifies the Offset attached dependency property.

OrientationProperty
public static readonly DependencyProperty OrientationProperty
value = LinkPanel.OrientationProperty

Identifies the Orientation attached dependency property.

ToArrowProperty
public static readonly DependencyProperty ToArrowProperty
value = LinkPanel.ToArrowProperty

Identifies the ToArrow attached dependency property.

ToArrowScaleProperty
public static readonly DependencyProperty ToArrowScaleProperty
value = LinkPanel.ToArrowScaleProperty

Identifies the ToArrowScale attached dependency property.