FontsContractCompat.FontFamilyResult

Added in 1.1.0

class FontsContractCompat.FontFamilyResult


Object returned from fetchFonts.

Summary

Constants

const Int

Constant represents that the font was successfully retrieved.

const Int

Constant represents that the provider returns unexpected data.

const Int

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

Constants

STATUS_OK

Added in 1.1.0
const val STATUS_OK = 0: Int

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.

STATUS_UNEXPECTED_DATA_PROVIDED

Added in 1.1.0
const val STATUS_UNEXPECTED_DATA_PROVIDED = 2: Int

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.

STATUS_WRONG_CERTIFICATES

Added in 1.1.0
const val STATUS_WRONG_CERTIFICATES = 1: Int

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

Public functions

getFonts

Added in 1.1.0
fun getFonts(): Array<FontsContractCompat.FontInfo!>!

getStatusCode

Added in 1.1.0
fun getStatusCode(): Int