다음을 통해 공유


Keyboard Constructors

Definition

Overloads

Keyboard(Context, Int32)

Creates a keyboard from the given xml key layout file.

Keyboard(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

Keyboard(Context, Int32, Int32)

Creates a keyboard from the given xml key layout file.

Keyboard(Context, Int32, ICharSequence, Int32, Int32)

Creates a blank keyboard from the given resource file and populates it with the specified characters in left-to-right, top-to-bottom fashion, using the specified number of columns.

Keyboard(Context, Int32, Int32, Int32, Int32)

Creates a keyboard from the given xml key layout file.

Keyboard(Context, Int32, String, Int32, Int32)

Keyboard(Context, Int32)

Creates a keyboard from the given xml key layout file.

[Android.Runtime.Register(".ctor", "(Landroid/content/Context;I)V", "")]
public Keyboard (Android.Content.Context? context, int xmlLayoutResId);
[<Android.Runtime.Register(".ctor", "(Landroid/content/Context;I)V", "")>]
new Android.InputMethodServices.Keyboard : Android.Content.Context * int -> Android.InputMethodServices.Keyboard

Parameters

context
Context

the application or service context

xmlLayoutResId
Int32

the resource file that contains the keyboard layout and keys.

Attributes

Remarks

Creates a keyboard from the given xml key layout file.

Java documentation for android.inputmethodservice.Keyboard.Keyboard(android.content.Context, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Keyboard(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

protected Keyboard (IntPtr javaReference, Android.Runtime.JniHandleOwnership transfer);
new Android.InputMethodServices.Keyboard : nativeint * Android.Runtime.JniHandleOwnership -> Android.InputMethodServices.Keyboard

Parameters

javaReference
IntPtr

nativeint

A IntPtrcontaining a Java Native Interface (JNI) object reference.

transfer
JniHandleOwnership

A JniHandleOwnershipindicating how to handle javaReference

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Keyboard(Context, Int32, Int32)

Creates a keyboard from the given xml key layout file.

[Android.Runtime.Register(".ctor", "(Landroid/content/Context;II)V", "")]
public Keyboard (Android.Content.Context? context, int xmlLayoutResId, int modeId);
[<Android.Runtime.Register(".ctor", "(Landroid/content/Context;II)V", "")>]
new Android.InputMethodServices.Keyboard : Android.Content.Context * int * int -> Android.InputMethodServices.Keyboard

Parameters

context
Context

the application or service context

xmlLayoutResId
Int32

the resource file that contains the keyboard layout and keys.

modeId
Int32

keyboard mode identifier

Attributes

Remarks

Creates a keyboard from the given xml key layout file. Weeds out rows that have a keyboard mode defined but don't match the specified mode.

Java documentation for android.inputmethodservice.Keyboard.Keyboard(android.content.Context, int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Keyboard(Context, Int32, ICharSequence, Int32, Int32)

Creates a blank keyboard from the given resource file and populates it with the specified characters in left-to-right, top-to-bottom fashion, using the specified number of columns.

[Android.Runtime.Register(".ctor", "(Landroid/content/Context;ILjava/lang/CharSequence;II)V", "")]
public Keyboard (Android.Content.Context? context, int layoutTemplateResId, Java.Lang.ICharSequence? characters, int columns, int horizontalPadding);
[<Android.Runtime.Register(".ctor", "(Landroid/content/Context;ILjava/lang/CharSequence;II)V", "")>]
new Android.InputMethodServices.Keyboard : Android.Content.Context * int * Java.Lang.ICharSequence * int * int -> Android.InputMethodServices.Keyboard

Parameters

context
Context

the application or service context

layoutTemplateResId
Int32

the layout template file, containing no keys.

characters
ICharSequence

the list of characters to display on the keyboard. One key will be created for each character.

columns
Int32

the number of columns of keys to display. If this number is greater than the number of keys that can fit in a row, it will be ignored. If this number is -1, the keyboard will fit as many keys as possible in each row.

horizontalPadding
Int32
Attributes

Remarks

Creates a blank keyboard from the given resource file and populates it with the specified characters in left-to-right, top-to-bottom fashion, using the specified number of columns.

If the specified number of columns is -1, then the keyboard will fit as many keys as possible in each row.

Java documentation for android.inputmethodservice.Keyboard.Keyboard(android.content.Context, int, java.lang.CharSequence, int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Keyboard(Context, Int32, Int32, Int32, Int32)

Creates a keyboard from the given xml key layout file.

[Android.Runtime.Register(".ctor", "(Landroid/content/Context;IIII)V", "")]
public Keyboard (Android.Content.Context? context, int xmlLayoutResId, int modeId, int width, int height);
[<Android.Runtime.Register(".ctor", "(Landroid/content/Context;IIII)V", "")>]
new Android.InputMethodServices.Keyboard : Android.Content.Context * int * int * int * int -> Android.InputMethodServices.Keyboard

Parameters

context
Context

the application or service context

xmlLayoutResId
Int32

the resource file that contains the keyboard layout and keys.

modeId
Int32

keyboard mode identifier

width
Int32

sets width of keyboard

height
Int32

sets height of keyboard

Attributes

Remarks

Creates a keyboard from the given xml key layout file. Weeds out rows that have a keyboard mode defined but don't match the specified mode.

Java documentation for android.inputmethodservice.Keyboard.Keyboard(android.content.Context, int, int, int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Keyboard(Context, Int32, String, Int32, Int32)

[Android.Runtime.Register(".ctor", "(Landroid/content/Context;ILjava/lang/CharSequence;II)V", "")]
public Keyboard (Android.Content.Context? context, int layoutTemplateResId, string? characters, int columns, int horizontalPadding);
[<Android.Runtime.Register(".ctor", "(Landroid/content/Context;ILjava/lang/CharSequence;II)V", "")>]
new Android.InputMethodServices.Keyboard : Android.Content.Context * int * string * int * int -> Android.InputMethodServices.Keyboard

Parameters

context
Context
layoutTemplateResId
Int32
characters
String
columns
Int32
horizontalPadding
Int32
Attributes

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to