Description
Supported Script Types: Interface Scripts • Client Entity Scripts • Avatar Scripts
TheKeyboard
API provides facilities to use an in-world, virtual keyboard. When enabled, this keyboard is
displayed instead of the 2D keyboard that raises at the bottom of the tablet or Web entities when a text input field has
focus and you're in HMD mode.Properties
Name | Type | Summary |
---|---|---|
raised | boolean |
|
password | boolean |
|
use3DKeyboard | boolean |
|
preferMalletsOverLasers | boolean |
|
Methods
Name | Return Value | Summary |
---|---|---|
containsID
|
boolean |
Checks whether an entity is part of the virtual keyboard. |
disableLeftMallet
|
None |
Disables the left mallet so that it is not displayed when in HMD mode. |
disableRightMallet
|
None |
Disables the right mallet so that it is not displayed when in HMD mode. |
enableLeftMallet
|
None |
Enables the left mallet so that it is displayed when in HMD mode. |
enableRightMallet
|
None |
Enables the right mallet so that it is displayed when in HMD mode. |
loadKeyboardFile
|
None |
Loads a JSON file that defines the virtual keyboard's layout. The default JSON file used is https://github.com/highfidelity/hifi/.../keyboard.json. |
setLeftHandLaser
|
None |
Configures the virtual keyboard to recognize a ray pointer as the left hand's laser. |
setRightHandLaser
|
None |
Configures the virtual keyboard to recognize a ray pointer as the right hand's laser. |
Method Details
(static) containsID( entityID ) → {boolean}
Returns: true if the entity is part of the virtual keyboard, false if it isn't.
|
||||||
---|---|---|---|---|---|---|
Checks whether an entity is part of the virtual keyboard. Parameters
|
(static) disableLeftMallet( ) |
---|
Disables the left mallet so that it is not displayed when in HMD mode. |
(static) disableRightMallet( ) |
---|
Disables the right mallet so that it is not displayed when in HMD mode. |
(static) enableLeftMallet( ) |
---|
Enables the left mallet so that it is displayed when in HMD mode. |
(static) enableRightMallet( ) |
---|
Enables the right mallet so that it is displayed when in HMD mode. |
(static) loadKeyboardFile( path ) | ||||||
---|---|---|---|---|---|---|
Loads a JSON file that defines the virtual keyboard's layout. The default JSON file used is https://github.com/highfidelity/hifi/.../keyboard.json. Parameters
|
(static) setLeftHandLaser( leftHandLaser ) | ||||||
---|---|---|---|---|---|---|
Configures the virtual keyboard to recognize a ray pointer as the left hand's laser. Parameters
|
(static) setRightHandLaser( rightHandLaser ) | ||||||
---|---|---|---|---|---|---|
Configures the virtual keyboard to recognize a ray pointer as the right hand's laser. Parameters
|