Namespaces

Enumerations

enum class FallbackGroup : uint32_t
Name Value
kNone 0u
kSerif 1u
kSansSerif 2u
kMonospace 3u
kCursive 4u
kFantasy 5u

Deprecated. See `GenericFontFamily`.

Defined at line 117 of file fidling/gen/sdk/fidl/fuchsia.fonts/fuchsia.fonts/cpp/fidl/fuchsia.fonts/cpp/common_types.h

enum class CacheMissPolicy : uint32_t
Name Value Comments
kBlockUntilDownloaded 1u

The server will attempt to load the uncached typeface before providing a response. This is
the *default* behavior.

This option is not recommended for synchronous clients that block rendering while waiting
for a font.

kReturnEmptyResponse 2u

The server will tell the client that the uncached typeface is unavailable, by returning an
empty [`fuchsia.fonts/TypefaceResponse`]. The uncached typeface may be downloaded
asynchronously to be available for future requests.

This is similar to `font-display: block` in CSS.

kReturnFallback 3u

The server will attempt to provide a cached fallback typeface (if allowed by the fallback
restrictions in [`fuchsia.fonts/TypefaceRequestFlags`]). The uncached typeface may be
downloaded asynchronously to be available for future requests.

This is similar to `font-display: swap` in CSS.

Options for what the font server should do if the client requests a typeface that is not yet

cached.

Defined at line 150 of file fidling/gen/sdk/fidl/fuchsia.fonts/fuchsia.fonts/cpp/fidl/fuchsia.fonts/cpp/common_types.h

enum class Slant : uint32_t
Name Value Comments
kUpright 1u

The default; upright glyphs.

kItalic 2u

Specially designed, slanted and slightly calligraphic glyphs.

kOblique 3u

Skewed glyphs. Oblique usually means an geometric transformation of the upright variant,
rather than a custom-designed variant.

The type of slant of a type face.

Defined at line 191 of file fidling/gen/sdk/fidl/fuchsia.fonts/fuchsia.fonts/cpp/fidl/fuchsia.fonts/cpp/common_types.h

enum class Width : uint32_t
Name Value Comments
kUltraCondensed 1u

50% of normal width

kExtraCondensed 2u

62.5% of normal width

kCondensed 3u

75% of normal width

kSemiCondensed 4u

87.5% of normal width

kNormal 5u

Normal width

kSemiExpanded 6u

112.5% of normal width

kExpanded 7u

125% of normal width

kExtraExpanded 8u

150% of normal width

kUltraExpanded 9u

200% of normal width

Horizontal width class of the glyphs.

See https://docs.microsoft.com/en-us/typography/opentype/spec/os2#uswidthclass.

Defined at line 223 of file fidling/gen/sdk/fidl/fuchsia.fonts/fuchsia.fonts/cpp/fidl/fuchsia.fonts/cpp/common_types.h

enum class GenericFontFamily : uint32_t
Name Value Comments
kSerif 1u

Glyphs have little "serifs", hooks, or notches at the ends of most strokes.
Examples: Georgia, Noto Serif, Times New Roman.

kSansSerif 2u

Glyphs that have no serifs at the ends of most strokes.
Examples: Arial, Noto Sans, Roboto, Tahoma.

kMonospace 3u

Fixed-width fonts.
Examples: Consolas, Courier New, Inconsolata.

kCursive 4u

Handwritten or cursive fonts.
Examples: Brush Script, Comic Sans, Lucida Calligraphy.

kFantasy 5u

Decorative fonts.
Examples: Impact, Papyrus.

kSystemUi 6u

The default user interface font on the target platform.
This is included for completeness with the CSS specification; font manifests should not
declare that a font belongs to the `SYSTEM_UI` generic family, but instead should declare a
more specific option (e.g. `SERIF` for Roboto).

Not commonly used.

kEmoji 7u

Fonts that are used specifically for rendering emoji code points.
Examples: Noto Color Emoji.

kMath 8u

Fonts that are used primarily for rendering mathematical expressions.

Not commonly used.

kFangsong 9u

A group of Chinese fonts between serif and cursive, often used for official Chinese
Government documents.

Not commonly used.

Generic groups of font families that can serve as fallbacks for a specific family.

Every font family belongs to some _generic_ font family (see examples below).

If an exact requested family is unavailable but a fallback group is specified in the request,

the provider may return some other family that belongs to the fallback group. For example, if

the client requests the "Arial" family with a `SANS_SERIF` fallback, and "Arial" is unavailable,

the provider may return another available sans serif family, such as "Roboto Regular", instead.

See also:

https://www.w3.org/TR/css-fonts-4/#generic-font-families

Defined at line 280 of file fidling/gen/sdk/fidl/fuchsia.fonts/fuchsia.fonts/cpp/fidl/fuchsia.fonts/cpp/common_types.h

Records