mirror of
https://gitee.com/openharmony/interface_sdk-js
synced 2024-11-23 15:20:17 +00:00
【输入法框架】原子化绑定编辑框信息
Signed-off-by: Hollokin <taoyuxin2@huawei.com>
This commit is contained in:
parent
8e21ef83c2
commit
fc38c3ca49
27
api/@ohos.inputMethod.d.ts
vendored
27
api/@ohos.inputMethod.d.ts
vendored
@ -1433,6 +1433,33 @@ declare namespace inputMethod {
|
||||
* @since 10
|
||||
*/
|
||||
inputAttribute: InputAttribute;
|
||||
|
||||
/**
|
||||
* Cursor information.
|
||||
*
|
||||
* @type { ?CursorInfo }
|
||||
* @syscap SystemCapability.MiscServices.InputMethodFramework
|
||||
* @since 10
|
||||
*/
|
||||
cursorInfo?: CursorInfo;
|
||||
|
||||
/**
|
||||
* Selection information.
|
||||
*
|
||||
* @type { ?Range }
|
||||
* @syscap SystemCapability.MiscServices.InputMethodFramework
|
||||
* @since 10
|
||||
*/
|
||||
selection?: Range;
|
||||
|
||||
/**
|
||||
* The window ID of the application currently bound to the input method.
|
||||
*
|
||||
* @type { ?number }
|
||||
* @syscap SystemCapability.MiscServices.InputMethodFramework
|
||||
* @since 10
|
||||
*/
|
||||
windowId?: number;
|
||||
}
|
||||
|
||||
/**
|
||||
|
20
api/@ohos.inputMethodEngine.d.ts
vendored
20
api/@ohos.inputMethodEngine.d.ts
vendored
@ -1169,6 +1169,26 @@ declare namespace inputMethodEngine {
|
||||
* @since 8
|
||||
*/
|
||||
off(type: 'textChange', callback?: (text: string) => void): void;
|
||||
|
||||
/**
|
||||
* Subscribe input text attribute change
|
||||
*
|
||||
* @param { 'editorAttributeChanged' } type - indicates the type of subscribe event.
|
||||
* @param { function } callback - indicates the callback function of on('editorAttributeChanged').
|
||||
* @syscap SystemCapability.MiscServices.InputMethodFramework
|
||||
* @since 10
|
||||
*/
|
||||
on(type: 'editorAttributeChanged', callback: (attr: EditorAttribute) => void): void;
|
||||
|
||||
/**
|
||||
* Unsubscribe input text attribute change
|
||||
*
|
||||
* @param { 'editorAttributeChanged' } type - indicates the type of subscribe event.
|
||||
* @param { function } [callback] - indicates the callback function of off('editorAttributeChanged').
|
||||
* @syscap SystemCapability.MiscServices.InputMethodFramework
|
||||
* @since 10
|
||||
*/
|
||||
off(type: 'editorAttributeChanged', callback?: (attr: EditorAttribute) => void): void;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user