Commit graph

6 commits

Author SHA1 Message Date
Bhushan Shah
28d5a4e73b [virtualkeyboard] Fix the qtvirtualkeyboard with Qt 5.15
On 5.15, the VirtualKeyboard did not have a correct z-order which caused
the virtualkeyboard to hide as soon as key was pressed, upon
investigation it seems that upstream Qt changed behavior in following
changes.

https://codereview.qt-project.org/c/qt/qtvirtualkeyboard/+/292472
https://codereview.qt-project.org/c/qt/qtvirtualkeyboard/+/292674

Now when desktop-integration is used (i.e non-application embedded mode)
one need to set property desktopPanel to true so that it have correct
z-ordering and does not miss input events.

This is used in Component.onCompleted to avoid breaking it for the Qt
5.14.x qtvirtualkeyboard. When we switch to 5.15 property assignment can
be moved to InputPanel declaration.
2020-07-14 14:40:11 +05:30
Bhushan Shah
d7cfd0012a Revert "Load the keyboard on-demand"
This reverts commit 5c39795b88.

This unfortuntaely introduces the regression on the phone where there's
multiple bugs preset,

- Keyboard can no longer be closed using close button, or removing
  focus.
- Opening keyboard makes application get no input events, making it look
  like it is crashed/stuck or hung.

I failed to reproduce this bug on desktop unfortunately.

CCMAIL: Aleix Pol <aleixpol@kde.org>
2019-08-09 11:40:22 +05:30
Aleix Pol
5c39795b88 Load the keyboard on-demand
Summary: No need to load the keyboard view as soon as wayland starts. It's not a simple UI and it often will be unused.

Test Plan: played with the keyboard, still worked

Reviewers: #kwin, davidedmundson

Reviewed By: #kwin, davidedmundson

Subscribers: davidedmundson, graesslin, kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D22430
2019-08-01 17:21:00 +02:00
Marco Martin
4001834da8 fix virtual keyboard on Plasma Mobile
Summary:
the newly introduced resize button shouldn't be visible on the phone and
for some reason using a ToolButton prevents the qml to load at all on
the phone (the problem seems right into the C++ part of ToolButton as
is broken on every QQC2 style)

Test Plan: work again on phone, still work on laptop

Reviewers: #plasma, bshah

Reviewed By: #plasma, bshah

Subscribers: kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D17483
2018-12-10 16:50:06 +01:00
Martin Flöser
fa4f123fba Add button to dynamically resize virtual keyboard
Summary:
One of the things I dislike most about our virtual keyboard integration
is it's size. It's at least on my system covering too much vertical
space. Unfortuantely the keyboard API does not offer a way to control
the vertical space - one can only control the width. Thus it's also not
possible to just provide the keyboard in the optimal size.

This change tries to address the problem by adding a resize button. When
pressed one can dynamically decrease and increase the width of the
keyboard and thus also the height.

The button is added to the top/right corner. Ideally it would be added
to the symbol button row, but either I couldn't find the appropriate API
hooks or it's not possible.

Test Plan: Started KWin with the change and tested with touch input

Reviewers: #kwin

Subscribers: kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D16485
2018-12-01 12:13:01 +01:00
Martin Gräßlin
f26f2fe181 Integrate QtVirtualKeyboard into KWin/Wayland
Summary:
The idea is to have KWin provide a virtual keyboard. To support this
KWin uses the QT_IM_MODULE qtvirtualkeyboard and makes sure that the
QPA plugin loads it.

KWin has a new class VirtualKeyboard which acts as the focus object and
the "proxy" for input methods. The QPA plugin ensures that this is the
focusObject, so that all input method related events are sent to this
class. From there it will be possible to delegate to other applications
through the Wayland interfaces.

Reviewers: #plasma

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D1638
2016-06-02 11:26:53 +02:00