1.3 layouts directory: D:\Qt\Qt5.9.0\5.9\Src\qtvirtualkeyboard\src\virtualkeyboard\content\layouts, A language+country has a corresponding sub-directory. The qml types inherit from KeyboardLayout or KeyboardLayoutLoader. They define the layout of the keys.
1.4 styles directory: D:\Qt\Qt5.9.0\5.9\Src\qtvirtualkeyboard\src\virtualkeyboard\content\styles A style has a corresponding sub-directory. The qml type inherits from KeyboardStyle. They define the UI style, such as background images, text fonts and colors.
3. Using qtvirtualkeyboard 3.1 In the main() function: qputenv("QT_IM_MODULE", QByteArray("qtvirtualkeyboard")); or, $ QT_IM_MODULE=qtvirtualkeyboard myapp
3.2 In the main() function: qputenv("QT_VIRTUALKEYBOARD_STYLE", QByteArray("retro")); Or, Component.onCompleted: VirtualKeyboardSettings.styleName = "retro";
3.3 Add the following lines to your .pro file static { QT += svg QTPLUGIN += qtvirtualkeyboardplugin }
3.3 Create InputPanel(Otherwise the virtual keyboard will be shown at the bottom of screen)
3.4 Change VirtualKeyboardSettings.locale, and current language will change correspondingly. 3.5 Property VirtualKeyboardSettings.activeLocales can be used to limit the list of available languages in the application lifetime.
4. Customize style 4.1 Create a directory, vss for example, in D:\Qt\Qt5.9.0\5.9\Src\qtvirtualkeyboard\src\virtualkeyboard\content\styles\;
4.2 Copy all files in D:\Qt\Qt5.9.0\5.9\Src\qtvirtualkeyboard\src\virtualkeyboard\content\styles\retro to vss, change the images files and modify style.qml;
4.2 Add following lines to file D:\Qt\Qt5.9.0\5.9\Src\qtvirtualkeyboard\src\virtualkeyboard\virtualkeyboard.pro RESOURCES += \ content/styles/vss/vss_style.qrc \
OTHER_FILES += \ content/styles/vss/*.qml \
4.3 Add following lines to style.qml to make a language selecting popup list languagePopupListEnabled: true