diff --git a/common/test/resources/keyboards/test_8568_deadkeys.html b/common/test/resources/keyboards/test_8568_deadkeys.html index 1b4cf31424..054f19b4f8 100644 --- a/common/test/resources/keyboards/test_8568_deadkeys.html +++ b/common/test/resources/keyboards/test_8568_deadkeys.html @@ -36,22 +36,20 @@ + }); + diff --git a/developer/docs/help/reference/kmc/cli/get-started.md b/developer/docs/help/reference/kmc/cli/get-started.md index 348bf4c4b9..2316abef38 100644 --- a/developer/docs/help/reference/kmc/cli/get-started.md +++ b/developer/docs/help/reference/kmc/cli/get-started.md @@ -110,7 +110,7 @@ hamburger menu in the Keyman app. **Web**: copy khmer_angkor.js to your website, then [load it with KeymanWeb][load-keymanweb-keyboard]: ```js -keyman.addKeyboards({ +await keyman.addKeyboards({ id:'khmer_angkor', // The keyboard's unique identification code. name:'Khmer Angkor', // The keyboard's user-readable name. language:{ diff --git a/developer/src/kmc/README.md b/developer/src/kmc/README.md index 0490998e4d..05fd265a50 100644 --- a/developer/src/kmc/README.md +++ b/developer/src/kmc/README.md @@ -109,7 +109,7 @@ hamburger menu in the Keyman app. **Web**: copy khmer_angkor.js to your website, then [load it with KeymanWeb][load-keymanweb-keyboard]: ```js -keyman.addKeyboards({ +await keyman.addKeyboards({ id:'khmer_angkor', // The keyboard's unique identification code. name:'Khmer Angkor', // The keyboard's user-readable name. language:{ diff --git a/web/docs/engine/guide/adding-keyboards.md b/web/docs/engine/guide/adding-keyboards.md index 221f495de1..2874d449bc 100644 --- a/web/docs/engine/guide/adding-keyboards.md +++ b/web/docs/engine/guide/adding-keyboards.md @@ -8,8 +8,8 @@ There are multiple ways to add and install keyboards into your KeymanWeb install The most efficient way to utilize a keyboard is to obtain a local copy of it and place this copy in a static location on your website. Once this is done, it can be directly linked into KeymanWeb as follows. -```c -keyman.addKeyboards({ +```typescript +await keyman.addKeyboards({ id:'us', // The keyboard's unique identification code. name:'English', // The keyboard's user-readable name. language:{ @@ -22,7 +22,7 @@ keyman.addKeyboards({ Custom fonts may also be utilized via the `language.font` property. For example: -```c +```typescript font:{ family:'LaoWeb', source:['../font/saysettha_web.ttf','../font/saysettha_web.woff','../font/saysettha_web.eot'] @@ -33,16 +33,16 @@ font:{ To obtain the default Keyman keyboard for a given language, call the following function. -```c -keyman.addKeyboardsForLanguage('Dzongkha'); +```typescript +await keyman.addKeyboardsForLanguage('Dzongkha'); ``` This example would find the default keyboard for the Dzongkha language. This method will fail if the name doesn't perfectly match any language found in the CDN's repository. Alternatively, languages may be looked up via their BCP 47 language code as follows: -```c -keyman.addKeyboards('@he') +```typescript +await keyman.addKeyboards('@he') ``` The `@` prefix indicates the use of the BCP 47 language code, which in this case corresponds with Hebrew. @@ -51,8 +51,8 @@ The `@` prefix indicates the use of the BCP 47 language code, which in this case To obtain a specific keyboard by name or by keyboard name and language code as a pair, see the following: -```c -keyman.addKeyboards('french','sil_euro_latin@sv','sil_euro_latin@no') +```typescript +await keyman.addKeyboards('french','sil_euro_latin@sv','sil_euro_latin@no') ``` This will install three keyboards - one for French (named, quite simply, "French") and two copies of the EuroLatin keyboard - one for Swedish and one for Norwegian. diff --git a/web/docs/engine/guide/examples/__auto-control.html b/web/docs/engine/guide/examples/__auto-control.html index efe5467bfd..c2a8b472b0 100644 --- a/web/docs/engine/guide/examples/__auto-control.html +++ b/web/docs/engine/guide/examples/__auto-control.html @@ -3,8 +3,8 @@
- @@ -20,8 +19,8 @@ // Disable KeymanWeb interaction on the 'Email to' TEXT control keyman.disableControl(document.f.address); - // Set the default keyboard for the 'Subject' TEXT control to 'off' (i.e. default - // browser keyboard) + // Set the default keyboard for the 'Subject' TEXT control to the first language + // added to KeymanWeb after initialization. keyman.setKeyboardForControl(document.f.subject, '', ''); // Set the default keyboard for the 'Message body' TEXTAREA to the LaoKeys keyboard keyman.setKeyboardForControl(document.f.text, 'Keyboard_laokeys', 'lo'); @@ -42,4 +41,4 @@ Back to Document -