Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)   
Deprecated in [API level 31](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels) Summary: [Constants](https://developer.android.com/reference/android/provider/FontsContract.Columns#constants) \| [Inherited Constants](https://developer.android.com/reference/android/provider/FontsContract.Columns#inhconstants) \| [Inherited Methods](https://developer.android.com/reference/android/provider/FontsContract.Columns#inhmethods)

# FontsContract.Columns

*** ** * ** ***

` public static final class FontsContract.Columns `   
` extends https://developer.android.com/reference/java/lang/Object ` ` implements https://developer.android.com/reference/android/provider/BaseColumns `

|---|---|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object) ||
| ↳ | android.provider.FontsContract.Columns |

<br />

*** ** * ** ***

<br />

**This class was deprecated in API level 31.**   

Use the `https://developer.android.com/reference/androidx/core/provider/FontsContractCompat.Columns.html` for consistent behavior across all devices.

Defines the constants used in a response from a Font Provider. The cursor returned from the query should have the ID column populated with the content uri ID for the resulting font. This should point to a real file or shared memory, as the client will mmap the given file descriptor. Pipes, sockets and other non-mmap-able file descriptors will fail to load in the client application.

## Summary

| ### Constants ||
|---|---|
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#FILE_ID` Constant used to request data from a font provider. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#ITALIC` Constant used to request data from a font provider. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE` Constant used to request data from a font provider. |
| `int` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE_FONT_NOT_FOUND` Constant used to represent a result was not found. |
| `int` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE_FONT_UNAVAILABLE` Constant used to represent a result was found, but cannot be provided at this moment. |
| `int` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE_MALFORMED_QUERY` Constant used to represent that the query was not in a supported format by the provider. |
| `int` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE_OK` Constant used to represent a result was retrieved successfully. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#TTC_INDEX` Constant used to request data from a font provider. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#VARIATION_SETTINGS` Constant used to request data from a font provider. |
| `https://developer.android.com/reference/java/lang/String` | `https://developer.android.com/reference/android/provider/FontsContract.Columns#WEIGHT` Constant used to request data from a font provider. |

### Inherited constants

From interface `https://developer.android.com/reference/android/provider/BaseColumns` `https://developer.android.com/reference/java/lang/String` `https://developer.android.com/reference/android/provider/BaseColumns#_COUNT`

The count of rows in a directory.
`https://developer.android.com/reference/java/lang/String` `https://developer.android.com/reference/android/provider/BaseColumns#_ID`

The unique ID for a row.

### Inherited methods

From class ` https://developer.android.com/reference/java/lang/Object ` ` https://developer.android.com/reference/java/lang/Object` ` https://developer.android.com/reference/java/lang/Object#clone()() `

Creates and returns a copy of this object.
` boolean` ` https://developer.android.com/reference/java/lang/Object#equals(java.lang.Object)(https://developer.android.com/reference/java/lang/Object obj) `

Indicates whether some other object is "equal to" this one.
` void` ` https://developer.android.com/reference/java/lang/Object#finalize()() `

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.
` final https://developer.android.com/reference/java/lang/Class<?>` ` https://developer.android.com/reference/java/lang/Object#getClass()() `

Returns the runtime class of this `Object`.
` int` ` https://developer.android.com/reference/java/lang/Object#hashCode()() `

Returns a hash code value for the object.
` final void` ` https://developer.android.com/reference/java/lang/Object#notify()() `

Wakes up a single thread that is waiting on this object's monitor.
` final void` ` https://developer.android.com/reference/java/lang/Object#notifyAll()() `

Wakes up all threads that are waiting on this object's monitor.
` https://developer.android.com/reference/java/lang/String` ` https://developer.android.com/reference/java/lang/Object#toString()() `

Returns a string representation of the object.
` final void` ` https://developer.android.com/reference/java/lang/Object#wait(long,%20int)(long timeoutMillis, int nanos) `

Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed.
` final void` ` https://developer.android.com/reference/java/lang/Object#wait(long)(long timeoutMillis) `

Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*, or until a certain amount of real time has elapsed.
` final void` ` https://developer.android.com/reference/java/lang/Object#wait()() `

Causes the current thread to wait until it is awakened, typically by being *notified* or *interrupted*.

## Constants

### FILE_ID

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final String FILE_ID
```

Constant used to request data from a font provider. The cursor returned from the query may populate this column with a long for the font file ID. The client will request a file descriptor to "file/FILE_ID" with this ID immediately under the top-level content URI. If not present, the client will request a file descriptor to the top-level URI with the given base font ID. Note that several results may return the same file ID, e.g. for TTC files with different indices.

<br />

Constant Value: "file_id"

### ITALIC

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final String ITALIC
```

Constant used to request data from a font provider. The cursor returned from the query should have this column populated with the int italic for the resulting font. This should be 0 for regular style and 1 for italic.

<br />

Constant Value: "font_italic"

### RESULT_CODE

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final String RESULT_CODE
```

Constant used to request data from a font provider. The cursor returned from the query should have this column populated to indicate the result status of the query. This will be checked before any other data in the cursor. Possible values are `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE_OK`, `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE_FONT_NOT_FOUND`, `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE_MALFORMED_QUERY` and `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE_FONT_UNAVAILABLE` for system defined values. You may also define your own values in the 0x000010000..0xFFFF0000 range. If not present, `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE_OK` will be assumed.

<br />

Constant Value: "result_code"

### RESULT_CODE_FONT_NOT_FOUND

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final int RESULT_CODE_FONT_NOT_FOUND
```

Constant used to represent a result was not found. See `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE`.

<br />

Constant Value: 1 (0x00000001)

### RESULT_CODE_FONT_UNAVAILABLE

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final int RESULT_CODE_FONT_UNAVAILABLE
```

Constant used to represent a result was found, but cannot be provided at this moment. Use this to indicate, for example, that a font needs to be fetched from the network. See `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE`.

<br />

Constant Value: 2 (0x00000002)

### RESULT_CODE_MALFORMED_QUERY

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final int RESULT_CODE_MALFORMED_QUERY
```

Constant used to represent that the query was not in a supported format by the provider. See `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE`.

<br />

Constant Value: 3 (0x00000003)

### RESULT_CODE_OK

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final int RESULT_CODE_OK
```

Constant used to represent a result was retrieved successfully. The given fonts will be attempted to retrieve immediately via `https://developer.android.com/reference/android/content/ContentProvider#openFile(android.net.Uri,%20java.lang.String)`. See `https://developer.android.com/reference/android/provider/FontsContract.Columns#RESULT_CODE`.

<br />

Constant Value: 0 (0x00000000)

### TTC_INDEX

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final String TTC_INDEX
```

Constant used to request data from a font provider. The cursor returned from the query should have this column populated with an int for the ttc index for the resulting font.

<br />

Constant Value: "font_ttc_index"

### VARIATION_SETTINGS

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final String VARIATION_SETTINGS
```

Constant used to request data from a font provider. The cursor returned from the query may populate this column with the font variation settings String information for the font.

<br />

Constant Value: "font_variation_settings"

### WEIGHT

Added in [API level 26](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)

```
public static final String WEIGHT
```

Constant used to request data from a font provider. The cursor returned from the query should have this column populated with the int weight for the resulting font. This value should be between 100 and 900. The most common values are 400 for regular weight and 700 for bold weight.

<br />

Constant Value: "font_weight"