Added in [API level 3](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels)   
Deprecated in [API level 29](https://developer.android.com/guide/topics/manifest/uses-sdk-element#ApiLevels) Summary: [XML Attrs](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#lattrs) \| [Fields](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#lfields) \| [Ctors](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#pubctors) \| [Inherited Methods](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#inhmethods)

# Keyboard.Row

*** ** * ** ***

` public static class Keyboard.Row `   
` extends https://developer.android.com/reference/java/lang/Object ` ` `

|---|---|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object) ||
| ↳ | android.inputmethodservice.Keyboard.Row |

<br />

*** ** * ** ***

Container for keys in the keyboard. All keys in a row are at the same Y-coordinate. Some of the key size defaults can be overridden per row from what the `https://developer.android.com/reference/android/inputmethodservice/Keyboard` defines.

## Summary

### XML attributes

[`android:horizontalGap`](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#attr_android:horizontalGap) *This is deprecated. Copy this definition into your own application project.
May be a dimension value, which is a floating point number appended with a unit such as "`14.5sp`". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), and mm (millimeters).*

*May be a fractional value, which is a floating point number appended with either % or %p, such as "`14.5%`". The % suffix always means a percentage of the base size; the optional %p suffix provides a size relative to some parent container.*
[`android:keyHeight`](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#attr_android:keyHeight) *This is deprecated. Copy this definition into your own application project.
May be a dimension value, which is a floating point number appended with a unit such as "`14.5sp`". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), and mm (millimeters).*

*May be a fractional value, which is a floating point number appended with either % or %p, such as "`14.5%`". The % suffix always means a percentage of the base size; the optional %p suffix provides a size relative to some parent container.*
[`android:keyWidth`](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#attr_android:keyWidth) *This is deprecated. Copy this definition into your own application project.
May be a dimension value, which is a floating point number appended with a unit such as "`14.5sp`". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), and mm (millimeters).*

*May be a fractional value, which is a floating point number appended with either % or %p, such as "`14.5%`". The % suffix always means a percentage of the base size; the optional %p suffix provides a size relative to some parent container.*
[`android:keyboardMode`](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#attr_android:keyboardMode) *This is deprecated. Copy this definition into your own application project.*

*May be a reference to another resource, in the form "`@[+][*package*:]*type*/*name*`" or a theme attribute in the form "`?[*package*:]*type*/*name*`".*
[`android:rowEdgeFlags`](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#attr_android:rowEdgeFlags) *This is deprecated. Copy this definition into your own application project.
Must be one or more (separated by '\|') of the following constant values.
Constant Value Description bottom 8 Row is anchored to the bottom of the keyboard.Copy this definition into your own application project. top 4 Row is anchored to the top of the keyboard.Copy this definition into your own application project.* [`android:verticalGap`](https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#attr_android:verticalGap) *This is deprecated. Copy this definition into your own application project.
May be a dimension value, which is a floating point number appended with a unit such as "`14.5sp`". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), and mm (millimeters).*

*May be a fractional value, which is a floating point number appended with either % or %p, such as "`14.5%`". The % suffix always means a percentage of the base size; the optional %p suffix provides a size relative to some parent container.*

| ### Fields ||
|---|---|
| ` public int` | `https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#defaultHeight` Default height of a key in this row. |
| ` public int` | `https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#defaultHorizontalGap` Default horizontal gap between keys in this row. |
| ` public int` | `https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#defaultWidth` Default width of a key in this row. |
| ` public int` | `https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#mode` The keyboard mode for this row |
| ` public int` | `https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#rowEdgeFlags` Edge flags for this row of keys. |
| ` public int` | `https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#verticalGap` Vertical gap following this row. |

| ### Public constructors ||
|---|---|
| ` https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#Row(android.content.res.Resources,%20android.inputmethodservice.Keyboard,%20android.content.res.XmlResourceParser)(https://developer.android.com/reference/android/content/res/Resources res, https://developer.android.com/reference/android/inputmethodservice/Keyboard parent, https://developer.android.com/reference/android/content/res/XmlResourceParser parser) ` |
| ` https://developer.android.com/reference/android/inputmethodservice/Keyboard.Row#Row(android.inputmethodservice.Keyboard)(https://developer.android.com/reference/android/inputmethodservice/Keyboard parent) ` |

### 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*.

## XML attributes

### android:horizontalGap

<br />

**This is deprecated.**   

Copy this definition into your own application project.

May be a dimension value, which is a floating point number appended with a unit such as "`14.5sp`". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), and mm (millimeters).

May be a fractional value, which is a floating point number appended with either % or %p, such as "`14.5%`". The % suffix always means a percentage of the base size; the optional %p suffix provides a size relative to some parent container.

Default horizontal gap between keys.

<br />

### android:keyHeight

<br />

**This is deprecated.**   

Copy this definition into your own application project.

May be a dimension value, which is a floating point number appended with a unit such as "`14.5sp`". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), and mm (millimeters).

May be a fractional value, which is a floating point number appended with either % or %p, such as "`14.5%`". The % suffix always means a percentage of the base size; the optional %p suffix provides a size relative to some parent container.

Default height of a key, in pixels or percentage of display width.

<br />

### android:keyWidth

<br />

**This is deprecated.**   

Copy this definition into your own application project.

May be a dimension value, which is a floating point number appended with a unit such as "`14.5sp`". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), and mm (millimeters).

May be a fractional value, which is a floating point number appended with either % or %p, such as "`14.5%`". The % suffix always means a percentage of the base size; the optional %p suffix provides a size relative to some parent container.

Default width of a key, in pixels or percentage of display width.

<br />

### android:keyboardMode

<br />

**This is deprecated.**   

Copy this definition into your own application project.

May be a reference to another resource, in the form "`@[+][*package*:]*type*/*name*`" or a theme attribute in the form "`?[*package*:]*type*/*name*`".

Mode of the keyboard. If the mode doesn't match the requested keyboard mode, the row will be skipped.

<br />

### android:rowEdgeFlags

<br />

**This is deprecated.**   

Copy this definition into your own application project.

Must be one or more (separated by '\|') of the following constant values.

| Constant | Value | Description |
|---|---|---|
| bottom | 8 | Row is anchored to the bottom of the keyboard.Copy this definition into your own application project. |
| top | 4 | Row is anchored to the top of the keyboard.Copy this definition into your own application project. |

<br />

Row edge flags.

<br />

### android:verticalGap

<br />

**This is deprecated.**   

Copy this definition into your own application project.

May be a dimension value, which is a floating point number appended with a unit such as "`14.5sp`". Available units are: px (pixels), dp (density-independent pixels), sp (scaled pixels based on preferred font size), in (inches), and mm (millimeters).

May be a fractional value, which is a floating point number appended with either % or %p, such as "`14.5%`". The % suffix always means a percentage of the base size; the optional %p suffix provides a size relative to some parent container.

Default vertical gap between rows of keys.

<br />

## Fields

### defaultHeight

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

```
public int defaultHeight
```

Default height of a key in this row.

<br />

### defaultHorizontalGap

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

```
public int defaultHorizontalGap
```

Default horizontal gap between keys in this row.

<br />

### defaultWidth

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

```
public int defaultWidth
```

Default width of a key in this row.

<br />

### mode

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

```
public int mode
```

The keyboard mode for this row

<br />

### rowEdgeFlags

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

```
public int rowEdgeFlags
```

Edge flags for this row of keys. Possible values that can be assigned are `https://developer.android.com/reference/android/inputmethodservice/Keyboard#EDGE_TOP` and `https://developer.android.com/reference/android/inputmethodservice/Keyboard#EDGE_BOTTOM`

<br />

### verticalGap

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

```
public int verticalGap
```

Vertical gap following this row.

<br />

## Public constructors

### Row

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

```
public Row (Resources res, 
                Keyboard parent, 
                XmlResourceParser parser)
```

<br />

<br />

| Parameters ||
|---|---|
| `res` | `Resources` <br /> |
| `parent` | `Keyboard` <br /> |
| `parser` | `XmlResourceParser` <br /> |

### Row

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

```
public Row (Keyboard parent)
```

<br />

<br />

| Parameters ||
|---|---|
| `parent` | `Keyboard` <br /> |