Class FontFace3
- Namespace
- SharpDX.DirectWrite
- Assembly
- SharpDX.Direct2D1.dll
[Guid("D37D7598-09BE-4222-A236-2081341CC1F2")]
public class FontFace3 : FontFace2
- Inheritance
-
FontFace3
- Derived
- Inherited Members
Constructors
FontFace3(nint)
public FontFace3(nint nativePtr)
Parameters
nativePtr
nint
Properties
FaceNames
Creates a localized strings object that contains the face names for the font (for example, Regular or Bold), indexed by locale name.
public LocalizedStrings FaceNames { get; }
Property Value
FamilyNames
Creates a localized strings object that contains the family names for the font family, indexed by locale name.
public LocalizedStrings FamilyNames { get; }
Property Value
FontFaceReference
Gets a font face reference that identifies this font.
public FontFaceReference FontFaceReference { get; }
Property Value
Panose
Gets the PANOSE values from the font, used for font selection and matching.
public Panose Panose { get; }
Property Value
Remarks
This method doesn't simulate these values, such as substituting a weight or proportion inferred on other values. If the font doesn't specify them, they are all set to 'any' (0).
Stretch
Gets the stretch (also known as width) of this font.
public FontStretch Stretch { get; }
Property Value
Style
Gets the style (also known as slope) of this font.
public FontStyle Style { get; }
Property Value
Weight
Gets the weight of this font.
public FontWeight Weight { get; }
Property Value
Methods
AreCharactersLocal(string, int, RawBool, out RawBool)
Determines whether the specified characters are local.
public void AreCharactersLocal(string characters, int characterCount, RawBool enqueueIfNotLocal, out RawBool isLocal)
Parameters
characters
stringArray of characters.
characterCount
intThe number of elements in the character array.
enqueueIfNotLocal
RawBoolSpecifies whether to enqueue a download request if any of the specified characters are not local.
isLocal
RawBoolReceives TRUE if all of the specified characters are local, SharpDX.Result.False if any of the specified characters are remote.
AreGlyphsLocal(short[], int, RawBool, out RawBool)
Determines whether the specified glyphs are local.
public void AreGlyphsLocal(short[] glyphIndices, int glyphCount, RawBool enqueueIfNotLocal, out RawBool isLocal)
Parameters
glyphIndices
short[]Array of glyph indices.
glyphCount
intThe number of elements in the glyph index array.
enqueueIfNotLocal
RawBoolSpecifies whether to enqueue a download request if any of the specified glyphs are not local.
isLocal
RawBoolReceives TRUE if all of the specified glyphs are local, SharpDX.Result.False if any of the specified glyphs are remote.
GetInformationalStrings(InformationalStringId, out LocalizedStrings, out RawBool)
Gets a localized strings collection that contains the specified informational strings, indexed by locale name.
public void GetInformationalStrings(InformationalStringId informationalStringID, out LocalizedStrings informationalStrings, out RawBool exists)
Parameters
informationalStringID
InformationalStringIdA InformationalStringId-typed value that identifies the strings to get.
informationalStrings
LocalizedStringsA reference to a memory block that receives a reference to a LocalizedStrings interface for the newly created localized strings object.
exists
RawBoolA reference to a variable that receives whether the font contains the specified string ID. TRUE if the font contains the specified string ID; otherwise, SharpDX.Result.False.
GetRecommendedRenderingMode(float, float, float, RawMatrix3x2?, RawBool, OutlineThreshold, MeasuringMode, RenderingParams, out RenderingMode1, out GridFitMode)
Determines the recommended text rendering and grid-fit mode to be used based on the font, size, world transform, and measuring mode.
public void GetRecommendedRenderingMode(float fontEmSize, float dpiX, float dpiY, RawMatrix3x2? transform, RawBool isSideways, OutlineThreshold outlineThreshold, MeasuringMode measuringMode, RenderingParams renderingParams, out RenderingMode1 renderingMode, out GridFitMode gridFitMode)
Parameters
fontEmSize
floatLogical font size in DIPs.
dpiX
floatNumber of pixels per logical inch in the horizontal direction.
dpiY
floatNumber of pixels per logical inch in the vertical direction.
transform
RawMatrix3x2?A SharpDX.Mathematics.Interop.RawMatrix3x2 structure that describes the world transform.
isSideways
RawBoolSpecifies whether the font is sideways. TRUE if the font is sideways; otherwise, SharpDX.Result.False.
outlineThreshold
OutlineThresholdA OutlineThreshold-typed value that specifies the quality of the graphics system's outline rendering, affects the size threshold above which outline rendering is used.
measuringMode
MeasuringModeA MeasuringMode-typed value that specifies the method used to measure during text layout. For proper glyph spacing, this method returns a rendering mode that is compatible with the specified measuring mode.
renderingParams
RenderingParamsA reference to a RenderingParams interface for the rendering parameters object. This parameter is necessary in case the rendering parameters object overrides the rendering mode.
renderingMode
RenderingMode1A reference to a variable that receives a RenderingMode1-typed value for the recommended rendering mode.
gridFitMode
GridFitModeA reference to a variable that receives a GridFitMode-typed value for the recommended grid-fit mode.
HasCharacter(int)
Determines whether the font supports the specified character.
public RawBool HasCharacter(int unicodeValue)
Parameters
unicodeValue
intA Unicode (UCS-4) character value.
Returns
- RawBool
Returns whether the font supports the specified character. Returns TRUE if the font has the specified character; otherwise, SharpDX.Result.False.
IsCharacterLocal(int)
Determines whether the character is locally downloaded from the font.
public RawBool IsCharacterLocal(int unicodeValue)
Parameters
unicodeValue
intA Unicode (UCS-4) character value.
Returns
- RawBool
Returns TRUE if the font has the specified character locally available, SharpDX.Result.False if not or if the font does not support that character.
IsGlyphLocal(short)
Determines whether the glyph is locally downloaded from the font.
public RawBool IsGlyphLocal(short glyphId)
Parameters
glyphId
shortGlyph identifier.
Returns
- RawBool
Returns TRUE if the font has the specified glyph locally available.
Operators
explicit operator FontFace3(nint)
public static explicit operator FontFace3(nint nativePtr)
Parameters
nativePtr
nint