mirror of
https://github.com/Stone-Red-Code/docs-desktop.git
synced 2026-09-04 09:06:04 +02:00
* Reset branch for WPF changes * Convert BMP to PNG; fix link-out-of-scope err * Add snippets for WPF... 6794 files!!!! * Add missing snippets * update file updated between migration * Fix paths to include * update breadcrumb and toc * fix index links * fix index links * fix index links * fix markdown
25 lines
1.4 KiB
Markdown
25 lines
1.4 KiB
Markdown
---
|
|
title: "Draw Text Using Glyphs"
|
|
ms.date: "03/30/2017"
|
|
helpviewer_keywords:
|
|
- "text [WPF], drawing with Glyphs objects"
|
|
- "Glyphs objects [WPF], drawing text"
|
|
- "typography [WPF], Glyphs objects"
|
|
ms.assetid: 587ab17e-a419-4ad5-b6da-8933a8e83d97
|
|
---
|
|
# Draw Text Using Glyphs
|
|
This topic explains how to use the low-level <xref:System.Windows.Documents.Glyphs> object to display text in [!INCLUDE[TLA#tla_xaml](../../../includes/tlasharptla-xaml-md.md)].
|
|
|
|
## Example
|
|
The following examples show how to define properties for a <xref:System.Windows.Documents.Glyphs> object in [!INCLUDE[TLA#tla_xaml](../../../includes/tlasharptla-xaml-md.md)]. The <xref:System.Windows.Documents.Glyphs> object represents the output of a <xref:System.Windows.Media.GlyphRun> in [!INCLUDE[TLA2#tla_xaml](../../../includes/tla2sharptla-xaml-md.md)]. The examples assume that the Arial, Courier New, and Times New Roman fonts are installed in the C:\WINDOWS\Fonts folder on the local computer.
|
|
|
|
[!code-xaml[GlyphsOvwSample1#1](~/samples/snippets/csharp/VS_Snippets_Wpf/GlyphsOvwSample1/CS/default.xaml#1)]
|
|
|
|
This example shows how to define other properties of <xref:System.Windows.Documents.Glyphs> objects in [!INCLUDE[TLA2#tla_xaml](../../../includes/tla2sharptla-xaml-md.md)].
|
|
|
|
[!code-xaml[GlyphsOvwSamp2#1](~/samples/snippets/csharp/VS_Snippets_Wpf/GlyphsOvwSamp2/CS/default.xaml#1)]
|
|
|
|
## See also
|
|
|
|
- [Typography in WPF](typography-in-wpf.md)
|