[Libreoffice-bugs] [Bug 140207] New: Qt's ImCursorRectangle is not correctly take device scale factor into account
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Sat Feb 6 08:37:27 UTC 2021
https://bugs.documentfoundation.org/show_bug.cgi?id=140207
Bug ID: 140207
Summary: Qt's ImCursorRectangle is not correctly take device
scale factor into account
Product: LibreOffice
Version: 7.1.0.3 release
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: UI
Assignee: libreoffice-bugs at lists.freedesktop.org
Reporter: wengxt at gmail.com
For regular Qt application, the ImCursorRectangle value returned by
inputMethodQuery is scaled with the corresponding QWindow's device scale
factor.
But libreoffice returns the non-scaled value which confuses the input method
and send the non-native coordinates.
To be more concrete, this is how the coordinates being transformed by fcitx:
(fcitx is expected to receive the native pixel value from application)
https://github.com/fcitx/fcitx5-qt/blob/cb48a057e1bcb0961a9eaaf12dda73f164b98b0c/qt5/platforminputcontext/qfcitxplatforminputcontext.cpp#L413
As you can see, the coordinates is up-scaled based on the input window's device
pixel ratio then sent to input method server. But libreoffice set the non-scale
value here, which makes it scaled wrongly in this code.
In this case, Libreoffice need to be fixed to behave consistently with other Qt
application on this value (dividing the value by window scale).
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20210206/bc521d8d/attachment.htm>
More information about the Libreoffice-bugs
mailing list