Commit Graph

11 Commits (cba895e7239e5919aa15adfb4e71ad72fb6c0806)

Author SHA1 Message Date
Aleix Pol 3733e3e77f Remove embedded implementation of the Virtual Keyboard 2020-08-18 10:55:21 +00:00
Aleix Pol 7aabd45df9 Integrate input-method-unstable-v1 2020-08-18 10:55:21 +00:00
Vlad Zahorodnii 4ce853e8e4 Prettify license headers 2020-08-07 19:57:56 +00:00
Vlad Zahorodnii 1fb9f6f13a Switch to SPDX license markers
The main advantage of SPDX license identifiers over the traditional
license headers is that it's more difficult to overlook inappropriate
licenses for kwin, for example GPL 3. We also don't have to copy a
lot of boilerplate text.

In order to create this change, I ran licensedigger -r -c from the
toplevel source directory.
2020-08-07 19:57:56 +00:00
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
Vlad Zagorodniy 8af2fa73dc Run clang-tidy with modernize-use-override check
Summary:
Currently code base of kwin can be viewed as two pieces. One is very
ancient, and the other one is more modern, which uses new C++ features.

The main problem with the ancient code is that it was written before
C++11 era. So, no override or final keywords, lambdas, etc.

Quite recently, KDE compiler settings were changed to show a warning if
a virtual method has missing override keyword. As you might have already
guessed, this fired back at us because of that ancient code. We had
about 500 new compiler warnings.

A "solution" was proposed to that problem - disable -Wno-suggest-override
and the other similar warning for clang. It's hard to call a solution
because those warnings are disabled not only for the old code, but also
for new. This is not what we want!

The main argument for not actually fixing the problem was that git
history will be screwed as well because of human factor. While good git
history is a very important thing, we should not go crazy about it and
block every change that somehow alters git history. git blame allows to
specify starting revision for a reason.

The other argument (human factor) can be easily solved by using tools
such as clang-tidy. clang-tidy is a clang-based linter for C++. It can
be used for various things, e.g. fixing coding style(e.g. add missing
braces to if statements, readability-braces-around-statements check),
or in our case add missing override keywords.

Test Plan: Compiles.

Reviewers: #kwin, davidedmundson

Reviewed By: #kwin, davidedmundson

Subscribers: davidedmundson, apol, romangg, kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D22371
2019-07-22 20:03:22 +03:00
Marco Martin 6bc2ddd56a virtualkeyboard: resize the focused window to make room for the keyboard
Summary:
alternative approach: try to resize the winidow to make room for the keyboard.
the new input wayland protocol doesn't have anymore the overlap rectangle (and it would not be going to work with qwidget apps anyways)

in the future will probably be needed anextension to the input protocol v3 which partially gets back this, tough window resizing is needed regardless

what's missing: the resize should be "temporary" and the window should be restored to its previous geometry when the keyboard closes

Test Plan: tested with test QML code

Reviewers: #plasma, #kwin, bshah, graesslin, romangg, davidedmundson

Reviewed By: #plasma, #kwin, romangg, davidedmundson

Subscribers: nicolasfella, mart, kwin, davidedmundson, graesslin

Tags: #kwin

Maniphest Tasks: T9815

Differential Revision: https://phabricator.kde.org/D18818
2019-03-20 11:05:06 +01:00
Yuri Chornoivan bf58da3e9a Fix minor EBN issues 2018-08-29 21:02:16 +03:00
Martin Flöser 8c2b2faf9d Add DBus protocol to virtual keyboard
Summary:
This change adds a DBus API to query whether the virtual keyboard is
currently enabled and provides DBus methods to request that the virtual
keyboard gets enabled/disabled. This is useful for e.g. providing a
Plasmoid or for convertables where the tablet mode needs to be enabled.

Reviewers: #kwin, #plasma

Subscribers: plasma-devel, kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D8166
2017-10-19 17:59:19 +02: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