Class TextGroupVisual3D
- Namespace
- HelixToolkit.Wpf
- Assembly
- HelixToolkit.Wpf.dll
Provides a visual element that shows a collection of text items.
public class TextGroupVisual3D : ModelVisual3D, IAnimatable, IAddChild
- Inheritance
-
TextGroupVisual3D
- Implements
- Inherited Members
- Extension Methods
Remarks
Set the Items property last to avoid multiple updates.
Fields
BackgroundProperty
Identifies the Background dependency property.
public static readonly DependencyProperty BackgroundProperty
Field Value
BorderBrushProperty
Identifies the BorderBrush dependency property.
public static readonly DependencyProperty BorderBrushProperty
Field Value
BorderThicknessProperty
Identifies the BorderThickness dependency property.
public static readonly DependencyProperty BorderThicknessProperty
Field Value
FontFamilyProperty
Identifies the FontFamily dependency property.
public static readonly DependencyProperty FontFamilyProperty
Field Value
FontSizeProperty
Identifies the FontSize dependency property.
public static readonly DependencyProperty FontSizeProperty
Field Value
FontWeightProperty
Identifies the FontWeight dependency property.
public static readonly DependencyProperty FontWeightProperty
Field Value
ForegroundProperty
Identifies the Foreground dependency property.
public static readonly DependencyProperty ForegroundProperty
Field Value
HeightProperty
Identifies the Height dependency property.
public static readonly DependencyProperty HeightProperty
Field Value
IsDoubleSidedProperty
Identifies the IsDoubleSided dependency property.
public static readonly DependencyProperty IsDoubleSidedProperty
Field Value
IsFlippedProperty
Identifies the IsFlipped dependency property.
public static readonly DependencyProperty IsFlippedProperty
Field Value
ItemsProperty
Identifies the Items dependency property.
public static readonly DependencyProperty ItemsProperty
Field Value
PaddingProperty
Identifies the Padding dependency property.
public static readonly DependencyProperty PaddingProperty
Field Value
Properties
Background
Gets or sets the background brush.
public Brush Background { get; set; }
Property Value
- Brush
The background.
BorderBrush
Gets or sets the border brush.
public Brush BorderBrush { get; set; }
Property Value
- Brush
The border brush.
BorderThickness
Gets or sets the border thickness.
public Thickness BorderThickness { get; set; }
Property Value
- Thickness
The border thickness.
FontFamily
Gets or sets the font family.
public FontFamily FontFamily { get; set; }
Property Value
- FontFamily
The font family.
FontSize
Gets or sets the size of the font (if not set, the Height property is used.
public double FontSize { get; set; }
Property Value
- double
The size of the font.
FontWeight
Gets or sets the font weight.
public FontWeight FontWeight { get; set; }
Property Value
- FontWeight
The font weight.
Foreground
Gets or sets the foreground (text) brush.
public Brush Foreground { get; set; }
Property Value
- Brush
The foreground brush.
Height
Gets or sets the height of the text.
public double Height { get; set; }
Property Value
- double
The text height.
IsDoubleSided
Gets or sets a value indicating whether this text visual is double sided.
public bool IsDoubleSided { get; set; }
Property Value
- bool
trueif this instance is double sided; otherwise,false.
IsFlipped
Gets or sets a value indicating whether the text should be flipped (mirrored horizontally).
public bool IsFlipped { get; set; }
Property Value
- bool
trueif text is flipped; otherwise,false.
Remarks
This may be useful when using a mirror transform on the text visual.
Items
Gets or sets the items.
public IList<SpatialTextItem> Items { get; set; }
Property Value
- IList<SpatialTextItem>
The items.
Padding
Gets or sets the padding.
public Thickness Padding { get; set; }
Property Value
- Thickness
The padding.
Methods
CreateTextMaterial(IEnumerable<TextItem>, Func<string, FrameworkElement>, Brush, bool, out Dictionary<string, FrameworkElement>, out Dictionary<FrameworkElement, Rect>)
Creates the text material.
public static Material CreateTextMaterial(IEnumerable<TextItem> items, Func<string, FrameworkElement> createElement, Brush background, bool useVisualBrush, out Dictionary<string, FrameworkElement> elementMap, out Dictionary<FrameworkElement, Rect> elementPositions)
Parameters
itemsIEnumerable<TextItem>The items.
createElementFunc<string, FrameworkElement>The create element.
backgroundBrushThe background.
useVisualBrushboolCreate a text material using VisualBrush
elementMapDictionary<string, FrameworkElement>The element map.
elementPositionsDictionary<FrameworkElement, Rect>The element positions.
Returns
- Material
A text material.