Added in API level 26
Deprecated in API level 31

FontFamilyResult


open class FontFamilyResult
kotlin.Any
   ↳ android.provider.FontsContract.FontFamilyResult

Object returned from fetchFonts.

Summary

Constants
static Int

Constant represents that the font was successfully retrieved.

static Int

Constant represents that the fetching font data was rejected by system.

static Int

Constant represents that the provider returns unexpected data.

static Int

Constant represents that the given certificate was not matched with the provider's signature.

Public methods
open Array<FontsContract.FontInfo!>

open Int

Constants

STATUS_OK

Added in API level 26
static val STATUS_OK: Int

Deprecated: Deprecated in Java.

Constant represents that the font was successfully retrieved. Note that when this value is set and getFonts returns an empty array, it means there were no fonts matching the given query.

Value: 0

STATUS_REJECTED

Added in API level 26
static val STATUS_REJECTED: Int

Deprecated: Deprecated in Java.

Constant represents that the fetching font data was rejected by system. This happens if the passed context is restricted.

Value: 3

STATUS_UNEXPECTED_DATA_PROVIDED

Added in API level 26
static val STATUS_UNEXPECTED_DATA_PROVIDED: Int

Deprecated: Deprecated in Java.

Constant represents that the provider returns unexpected data. getFonts returns null if this status was set. For example, this value is set when the font provider gives invalid format of variation settings.

Value: 2

STATUS_WRONG_CERTIFICATES

Added in API level 26
static val STATUS_WRONG_CERTIFICATES: Int

Deprecated: Deprecated in Java.

Constant represents that the given certificate was not matched with the provider's signature. getFonts returns null if this status was set.

Value: 1

Public methods

getFonts

Added in API level 26
open fun getFonts(): Array<FontsContract.FontInfo!>

Deprecated: Deprecated in Java.

Return
Array<FontsContract.FontInfo!> This value cannot be null.