ComponentOne Bitmap for WinForms
C1.Win.C1DX.4.8 Assembly / C1.Util.DX.DirectWrite Namespace / FontFallback Class / MapCharacters Method / MapCharacters(TextAnalysisSource,Int32,Int32,FontCollection,String,FontWeight,FontStyle,FontStretch,Int32,Single) Method
The text source implementation holds the text and locale.
Starting position to analyze.
Length of the text to analyze.
Default font collection to use.
Family name of the base font. If you pass null, no matching will be done against the family.
Desired weight.
Desired style.
Desired stretch.
Length of text mapped to the mapped font. This will always be less or equal to the input text length and greater than zero (if the text length is non-zero) so that the caller advances at least one character each call.
Scale factor to multiply the em size of the returned font by.

In This Topic
    MapCharacters(TextAnalysisSource,Int32,Int32,FontCollection,String,FontWeight,FontStyle,FontStretch,Int32,Single) Method
    In This Topic
    Determines an appropriate font to use to render the range of text.
    Syntax
    'Declaration
     
    Public Overloads Function MapCharacters( _
       ByVal source As TextAnalysisSource, _
       ByVal textPosition As System.Integer, _
       ByVal textLength As System.Integer, _
       ByVal baseFontCollection As FontCollection, _
       ByVal baseFamilyName As System.String, _
       ByVal baseWeight As FontWeight, _
       ByVal baseStyle As FontStyle, _
       ByVal baseStretch As FontStretch, _
       ByRef mappedLength As System.Integer, _
       ByRef scale As System.Single _
    ) As Font
    public Font MapCharacters( 
       TextAnalysisSource source,
       System.int textPosition,
       System.int textLength,
       FontCollection baseFontCollection,
       System.string baseFamilyName,
       FontWeight baseWeight,
       FontStyle baseStyle,
       FontStretch baseStretch,
       out System.int mappedLength,
       out System.float scale
    )

    Parameters

    source
    The text source implementation holds the text and locale.
    textPosition
    Starting position to analyze.
    textLength
    Length of the text to analyze.
    baseFontCollection
    Default font collection to use.
    baseFamilyName
    Family name of the base font. If you pass null, no matching will be done against the family.
    baseWeight
    Desired weight.
    baseStyle
    Desired style.
    baseStretch
    Desired stretch.
    mappedLength
    Length of text mapped to the mapped font. This will always be less or equal to the input text length and greater than zero (if the text length is non-zero) so that the caller advances at least one character each call.
    scale
    Scale factor to multiply the em size of the returned font by.

    Return Value

    The font that should be used to render the first mappedLength characters of the text. If it returns NULL, then no known font can render the text, and mappedLength is the number of unsupported characters to skip.
    See Also