SelectionListModel QML Type
選択リストのデータモデルを提供します。詳細...
Import Statement: | import QtQuick.VirtualKeyboard |
In C++: | QVirtualKeyboardSelectionListModel |
シグナル
- void activeItemChanged(int index)
- void itemSelected(int index)
方法
- void removeItem(int index)
- void selectItem(int index)
詳細説明
SelectionListModel は、入力メソッドによって提供される単語候補のデータモデルです。
SelectionListModel のインスタンスを直接作成することはできません。代わりに、InputEngine がインスタンスを管理し、InputEngine::wordCandidateListModel プロパティによってモデルへのアクセスを提供します。
このモデルは、リストデリゲートに対して以下のデータの役割を公開します:
display
項目の表示テキスト。wordCompletionLength
項目の単語補完長。dictionaryType
単語の辞書タイプ。 を参照。QVirtualKeyboardSelectionListModel::DictionaryTypecanRemoveSuggestion
単語を辞書から削除できるかどうかを示すブール値。
activeItemChanged シグナルは、入力メソッドによって現在ハイライトされている項目を示します。ビューはこのシグナルに応答して、リスト内の対応する項目をハイライトする必要があります。
ユーザーの選択は、selectItem ()メソッドで処理される。ユーザがリストから項目を選択すると、ビューはこのメソッドを呼び出す必要があります。
シグナルの説明
void activeItemChanged(int index) |
このシグナルは、リスト内のアクティブな項目が変更されたときに発行されます。UIはこのシグナルに反応し、リスト内のindex 。
注: 対応するハンドラはonActiveItemChanged
です。
void itemSelected(int index) |
このシグナルは、index の項目がユーザーによって選択されたときに発行されます。
注 : 対応するハンドラはonItemSelected
です。
メソッド・ドキュメント
void removeItem(int index) |
このメソッドは、ユーザがindex の位置にある項目をリストから削除したときに呼び出されます。この削除は、さらなる処理のために input メソッドに転送されます。
void selectItem(int index) |
このメソッドは、ユーザがリストの位置index にある項目を選択したときに呼び出されます。この選択は、さらなる処理のために input メソッドに転送されます。
© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.