This documentation is archived and is not being maintained.

FormattedText.BuildHighlightGeometry Method (Point, Int32, Int32)

Returns a Geometry object that represents the highlight bounding box for a specified substring of the formatted text.

Namespace: System.Windows.Media
Assembly: PresentationCore (in presentationcore.dll)

public Geometry BuildHighlightGeometry (
	Point origin,
	int startIndex,
	int count
)
public Geometry BuildHighlightGeometry (
	Point origin, 
	int startIndex, 
	int count
)
public function BuildHighlightGeometry (
	origin : Point, 
	startIndex : int, 
	count : int
) : Geometry
You cannot use methods in XAML.

Parameters

origin

The origin of the highlight region.

startIndex

The index of the initial character the highlight bounds should be obtained for.

count

The number of characters the highlight bounds should contain.

Return Value

The Geometry object that represents the highlight bounding box of the formatted text substring.

The returned Geometry object contains only the bounding box of the highlighted text and does not contain any rendered text.

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
Show: