次の方法で共有


Font Struct

Definition

The font used to display text.

public value class Font : IEquatable<Microsoft::Maui::Font>
public readonly struct Font : IEquatable<Microsoft.Maui.Font>
type Font = struct
Public Structure Font
Implements IEquatable(Of Font)
Inheritance
Font
Implements

Remarks

The available fonts, and the matching between Font and real displayed fonts is device-dependent.

Properties

AutoScalingEnabled
Default

Gets the default font for the device.

Family

Gets the font family to which this font belongs.

IsDefault

Gets a value that tells whether this font has no attributes, belongs to the default family, and has no attributes set.

Size

Gets the size of the font.

Slant
Weight

Methods

Equals(Object)

Determine if the provided Object is equivalent to the current Font.

GetHashCode()

Get the Hashcode for this Object.

OfSize(String, Double, FontWeight, FontSlant, Boolean)

Returns a Font structure with the requested font and size.

SystemFontOfSize(Double, FontWeight, FontSlant, Boolean)

Returns an usable font instance representing the default font, in the requested size, for the device and platform.

SystemFontOfWeight(FontWeight, FontSlant, Boolean)
ToString()

Returns a string representation of this font structure.

WithAutoScaling(Boolean)
WithSize(Double)

Returns a new font structure with the size that was specified with size.

WithSlant(FontSlant)
WithWeight(FontWeight, FontSlant)
WithWeight(FontWeight)

Operators

Equality(Font, Font)
Inequality(Font, Font)

Explicit Interface Implementations

IEquatable<Font>.Equals(Font)

Extension Methods

GetFontAttributes(Font)
WithAttributes(Font, FontAttributes)

Applies to