Export (0) Print
Expand All

TextDecoration.PenThicknessUnit Property

Gets the units in which the Thickness of the text decoration's Pen is expressed.

Namespace: System.Windows
Assembly: PresentationCore (in presentationcore.dll)
XML Namespace:  http://schemas.microsoft.com/winfx/2006/xaml/presentation

public TextDecorationUnit PenThicknessUnit { get; set; }
/** @property */
public TextDecorationUnit get_PenThicknessUnit ()

/** @property */
public void set_PenThicknessUnit (TextDecorationUnit value)

public function get PenThicknessUnit () : TextDecorationUnit

public function set PenThicknessUnit (value : TextDecorationUnit)

<object PenThicknessUnit="TextDecorationUnit" .../>

Property Value

The units in which the Thickness of the text decoration's Pen is expressed.

The default value is FontRecommended.

The following code example shows how to set the PenThicknessUnit property.

<!-- Move the text decoration lower using pixel value units. -->
<TextDecoration PenOffset="2" PenOffsetUnit="Pixel" PenThicknessUnit="Pixel" />

// Move the text decoration lower using pixel value units.
myUnderline.PenOffset = 2;
myUnderline.PenOffsetUnit = TextDecorationUnit.Pixel;
myUnderline.PenThicknessUnit = TextDecorationUnit.Pixel;

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0

Community Additions

ADD
Show:
© 2014 Microsoft