Condividi tramite


GlyphTypeface.AdvanceHeights Proprietà

Definizione

Ottiene le altezze di avanzamento per i glifi rappresentati dall'oggetto GlyphTypeface .

public:
 property System::Collections::Generic::IDictionary<System::UInt16, double> ^ AdvanceHeights { System::Collections::Generic::IDictionary<System::UInt16, double> ^ get(); };
public System.Collections.Generic.IDictionary<ushort,double> AdvanceHeights { get; }
member this.AdvanceHeights : System.Collections.Generic.IDictionary<uint16, double>
Public ReadOnly Property AdvanceHeights As IDictionary(Of UShort, Double)

Valore della proprietà

Oggetto IDictionary<TKey,TValue> che contiene coppie chiave-valore che rappresenta informazioni avanzate sull'altezza per i glifi. La chiave è un UInt16 oggetto che identifica l'indice del glifo. Il valore è un Double oggetto che rappresenta l'altezza di avanzamento.

Esempio

Nell'esempio seguente viene illustrato come restituire la raccolta di altezze avanzate dai glifi nel tipo di carattere.

// Create a glyph typeface by referencing the Verdana font.
GlyphTypeface glyphTypeface = new GlyphTypeface(new Uri("file:///C:\\WINDOWS\\Fonts\\verdana.ttf"));

// Retrieve the advance heights for the glyphs in the Verdana font.
IDictionary<ushort, double> dictionary = glyphTypeface.AdvanceHeights;
foreach (KeyValuePair<ushort, double> kvp in dictionary)
{
    // Retrieve the key/value pair information.
}
' Create a glyph typeface by referencing the Verdana font.
Dim glyphTypeface As New GlyphTypeface(New Uri("file:///C:\WINDOWS\Fonts\verdana.ttf"))

' Retrieve the advance heights for the glyphs in the Verdana font.
Dim dictionary As IDictionary(Of UShort, Double) = glyphTypeface.AdvanceHeights
For Each kvp As KeyValuePair(Of UShort, Double) In dictionary
    ' Retrieve the key/value pair information.
Next kvp

Commenti

La AdvanceHeights proprietà viene utilizzata per il calcolo del layout verticale.

Si applica a

Vedi anche