From ef9cf85bfebbd3c57ad57afa9bdaf579e8c669f6 Mon Sep 17 00:00:00 2001 From: "ester.zhou" Date: Tue, 14 Mar 2023 14:10:16 +0800 Subject: [PATCH] Update docs (15736) Signed-off-by: ester.zhou --- .../js-apis-inputmethod-extension-context.md | 6 +-- .../reference/apis/js-apis-inputmethod.md | 6 +-- .../apis/js-apis-inputmethodengine.md | 50 +++++++++---------- 3 files changed, 29 insertions(+), 33 deletions(-) diff --git a/en/application-dev/reference/apis/js-apis-inputmethod-extension-context.md b/en/application-dev/reference/apis/js-apis-inputmethod-extension-context.md index 37dadd8e2c..d9d1bb8570 100644 --- a/en/application-dev/reference/apis/js-apis-inputmethod-extension-context.md +++ b/en/application-dev/reference/apis/js-apis-inputmethod-extension-context.md @@ -51,7 +51,7 @@ this.context.destroy((err) => { ## InputMethodExtensionContext.destroy -destroy(): Promise; Terminates this ability. This API uses a promise to return the result. @@ -61,13 +61,13 @@ Terminates this ability. This API uses a promise to return the result. | Type| Description| | -------- | -------- | -| Promise; | Promise that returns no value.| **Example** ```js this.context.destroy().then(() => { - console.log('Succeed in destroying context.'); + console.log('Succeeded in destroying context.'); }).catch((error) => { console.log('Failed to destroy context: ' + JSON.stringify(error)); }); diff --git a/en/application-dev/reference/apis/js-apis-inputmethod.md b/en/application-dev/reference/apis/js-apis-inputmethod.md index be7f5edb92..17bdc1697f 100644 --- a/en/application-dev/reference/apis/js-apis-inputmethod.md +++ b/en/application-dev/reference/apis/js-apis-inputmethod.md @@ -884,7 +884,7 @@ inputMethodController.off('selectByRange'); ### on('selectByMovement')10+ -on(type: 'selectByMovement', callback: Callback<Range>): void +on(type: 'selectByMovement', callback: Callback<Movement>): void Enables listening for the selection-by-cursor-movement event. This API uses an asynchronous callback to return the result. @@ -1235,8 +1235,6 @@ showOptionalInputMethods(callback: AsyncCallback<boolean>): void Displays a dialog box for selecting an input method. This API uses an asynchronous callback to return the result. -**Required permissions**: ohos.permission.CONNECT_IME_ABILITY (available only to system applications) - **System capability**: SystemCapability.MiscServices.InputMethodFramework **Parameters** @@ -1275,8 +1273,6 @@ showOptionalInputMethods(): Promise<boolean> Displays a dialog box for selecting an input method. This API uses a promise to return the result. -**Required permissions**: ohos.permission.CONNECT_IME_ABILITY (available only to system applications) - **System capability**: SystemCapability.MiscServices.InputMethodFramework **Return value** diff --git a/en/application-dev/reference/apis/js-apis-inputmethodengine.md b/en/application-dev/reference/apis/js-apis-inputmethodengine.md index fd98e98d1f..c13da820d4 100644 --- a/en/application-dev/reference/apis/js-apis-inputmethodengine.md +++ b/en/application-dev/reference/apis/js-apis-inputmethodengine.md @@ -708,7 +708,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -742,7 +742,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -837,7 +837,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -886,7 +886,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -928,7 +928,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | ------------------------------ | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | | 12800006 | Input method controller error. | **Example** @@ -974,7 +974,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | ------------------------------ | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | | 12800006 | Input method controller error. | **Example** @@ -1013,7 +1013,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | ------------------------------ | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | | 12800006 | Input method controller error. | **Example** @@ -1059,7 +1059,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | ------------------------------ | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | | 12800006 | Input method controller error. | **Example** @@ -1099,7 +1099,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 12800002 | Input method engine error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1149,7 +1149,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 12800002 | Input method engine error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1192,7 +1192,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 12800002 | Input method engine error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1242,7 +1242,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 12800002 | Input method engine error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1281,7 +1281,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 12800002 | Input method engine error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1326,7 +1326,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 12800002 | Input method engine error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1366,7 +1366,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1401,7 +1401,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1435,7 +1435,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1479,7 +1479,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1517,7 +1517,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 401 | parameter error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1562,7 +1562,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 401 | parameter error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1600,7 +1600,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 401 | parameter error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1620,7 +1620,7 @@ try { ### selectByMovement10+ -selectByMovement(range: Range): Promise<void> +selectByMovement(movement: Movement): Promise<void> Selects text based on the specified range. This API uses a promise to return the result. @@ -1645,7 +1645,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | -------------------------- | | 401 | parameter error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | **Example** @@ -1682,7 +1682,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | ------------------------------ | | 401 | parameter error. | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | | 12800006 | Input method controller error. | **Example** @@ -1717,7 +1717,7 @@ For details about the error codes, see [Input Method Framework Error Codes](../e | Error Code ID| Error Message | | -------- | ------------------------------ | -| 12800003 | Input method client error. | +| 12800003 | input method client error. | | 12800006 | Input method controller error. | **Example** -- GitLab