Export (0) Print
Expand All

GlyphTypeface Class

Specifies a physical font face that corresponds to a font file on the disk.

System.Object
  System.Windows.Media.GlyphTypeface

Namespace:  System.Windows.Media
Assembly:  PresentationCore (in PresentationCore.dll)
XMLNS for XAML: http://schemas.microsoft.com/winfx/2006/xaml/presentation, http://schemas.microsoft.com/netfx/2007/xaml/presentation

'Declaration
Public Class GlyphTypeface _
	Implements ISupportInitialize

The GlyphTypeface type exposes the following members.

  NameDescription
Public methodGlyphTypefaceInitializes a new instance of the GlyphTypeface class.
Public methodGlyphTypeface(Uri)Initializes a new instance of the GlyphTypeface class using the specified font file location.
Public methodGlyphTypeface(Uri, StyleSimulations)Initializes a new instance of the GlyphTypeface class using the specified font file location and StyleSimulations value.
Top

  NameDescription
Public propertyAdvanceHeightsGets the advance heights for the glyphs represented by the GlyphTypeface object.
Public propertyAdvanceWidthsGets the advance widths for the glyphs represented by the GlyphTypeface object.
Public propertyBaselineGets the baseline value for the GlyphTypeface.
Public propertyBottomSideBearingsGets the distance from bottom edge of the black box to the bottom end of the advance vector for the glyphs represented by the GlyphTypeface object.
Public propertyCapsHeightGets the distance from the baseline to the top of an English capital, relative to em size, for the GlyphTypeface object.
Public propertyCharacterToGlyphMapGets the nominal mapping of a Unicode code point to a glyph index as defined by the font 'CMAP' table.
Public propertyCopyrightsGets the copyright information for the GlyphTypeface object.
Public propertyDescriptionsGets the description information for the GlyphTypeface object.
Public propertyDesignerNamesGets the designer information for the GlyphTypeface object.
Public propertyDesignerUrlsGets the designer URL information for the GlyphTypeface object.
Public propertyDistancesFromHorizontalBaselineToBlackBoxBottomGets the offset value from the horizontal Western baseline to the bottom of the glyph black box for the glyphs represented by the GlyphTypeface object.
Public propertyEmbeddingRightsGets the font embedding permission for the GlyphTypeface object.
Public propertyFaceNamesGets the face name for the GlyphTypeface object.
Public propertyFamilyNamesGets the family name for the GlyphTypeface object.
Public propertyFontUriGets or sets the URI for the GlyphTypeface object.
Public propertyGlyphCountGets the number of glyphs for the GlyphTypeface object.
Public propertyHeightGets the height of the character cell relative to the em size.
Public propertyLeftSideBearingsGets the distance from the leading end of the advance vector to the left edge of the black box for the glyphs represented by the GlyphTypeface object.
Public propertyLicenseDescriptionsGets the font license description information for the GlyphTypeface object.
Public propertyManufacturerNamesGets the font manufacturer information for the GlyphTypeface object.
Public propertyRightSideBearingsGets the distance from the right edge of the black box to the right end of the advance vector for the glyphs represented by the GlyphTypeface object.
Public propertySampleTextsGets the sample text information for the GlyphTypeface object.
Public propertyStretchGets the FontStretch value for the GlyphTypeface object.
Public propertyStrikethroughPositionGets a value that indicates the distance from the baseline to the strikethrough for the typeface.
Public propertyStrikethroughThicknessGets a value that indicates the thickness of the strikethrough relative to the font em size.
Public propertyStyleGets the style for the GlyphTypeface object.
Public propertyStyleSimulationsGets or sets the StyleSimulations for the GlyphTypeface object.
Public propertySymbolGets a value that indicates whether the GlyphTypeface font conforms to Unicode encoding.
Public propertyTopSideBearingsGets the distance from the top end of the vertical advance vector to the top edge of the black box for the glyphs represented by the GlyphTypeface object.
Public propertyTrademarksGets the trademark notice information for the GlyphTypeface object.
Public propertyUnderlinePositionGets the position of the underline in the GlyphTypeface.
Public propertyUnderlineThicknessGets the thickness of the underline relative to em size.
Public propertyVendorUrlsGets the vendor URL information for the GlyphTypeface object.
Public propertyVersionGets the font face version interpreted from the font's 'NAME' table.
Public propertyVersionStringsGets the version string information for the GlyphTypeface object interpreted from the font's 'NAME' table.
Public propertyWeightGets the designed weight of the font represented by the GlyphTypeface object.
Public propertyWin32FaceNamesGets the Win32 face name for the font represented by the GlyphTypeface object.
Public propertyWin32FamilyNamesGets the Win32 family name for the font represented by the GlyphTypeface object.
Public propertyXHeightGets the Western x-height relative to em size for the font represented by the GlyphTypeface object.
Top

  NameDescription
Public methodComputeSubsetReturns the binary image of the font subset based on a specified collection of glyphs.
Public methodEqualsDetermines whether the specified object is equal to the current GlyphTypeface object. (Overrides Object.Equals(Object).)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public methodGetFontStreamReturns the font file stream represented by the GlyphTypeface object.
Public methodGetGlyphOutlineReturns a Geometry value describing the path for a single glyph in the font.
Public methodGetHashCodeServes as a hash function for GlyphTypeface. (Overrides Object.GetHashCode.)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Top

The GlyphTypeface object is a low level text object that corresponds to a single face of a font family as represented by an OpenType font file, or serialized as a block of memory in a document. The correct GlyphTypeface to use for a run of characters in a given logical font is normally determined by the WPF font system and recorded in the GlyphRun objects generated by the FormattedText object and line formatting text APIs.

The GlyphTypeface provides properties and methods for:

  • Obtaining font face common metrics, such as the ratio of ascent and descent to em size.

  • Obtaining metrics, outlines, and bitmaps for individual glyphs.

  • Serialization in a document.

The following list describes the type of application scenarios that illustrate the value of using the low-level control that the GlyphTypeface object provides.

  • A fixed format document generator may use the GlyphTypeface to obtain a binary image of the font for embedding in a document container

  • A printer driver may use the GlyphTypeface to obtain font glyph outlines or bitmaps, or the entire font image for sending to the printer.

  • A GlyphTypeface viewer application may use the GlyphTypeface to obtain metric and bitmap information.

Each glyph defines metrics that specify how it aligns with other Glyphs. The following graphic defines metric values for glyph characters.

Metric values of glyph characters

Diagraph of glyph measurements

.NET Framework

Supported in: 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Show:
© 2014 Microsoft