https://bugs.documentfoundation.org/show_bug.cgi?id=152519

Michael Weghorn <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |NEW

--- Comment #10 from Michael Weghorn <[email protected]> ---
(In reply to trmdi from comment #6)
> Probably something's wrong with your setup. It does support that here on my
> openSUSE Tumbleweed, Kate 22.12.0

Indeed, was apparently some problem with my setup, since I was using the same
Kate version. It works now.

Interestingly, I explicitly have to unset GTK_IM_MODULE (or set it to an empty
string) because GTK_IM_MODULE=fcitx breaks the LO Writer use case with gtk3
(still works with Calc or gedit, though...).

(In reply to Xuetian Weng from comment #9)
> While it is possible to implement a polling like logic. Retrieving
> surrounding text is an expensive query, so I'd prefer libreoffice to notify
> the change instead of letting input method poll it.
> 
> Also, the implementation itself seems not working properly. Even if I tried
> to hack fcitx5-qt to poll the surrounding text by explicitly query the
> object, it return value for inputMethodQuery(Qt::ImSurroundingText) is still
> QVariant(Invalid).
> 
> So despite of adding qApp->inputMethod()->update(Qt::ImSurroundingText |
> Qt::ImCursorPosition | Qt::ImAnchorPosition) to a proper place maybe also
> check if this lcl_retrieveSurrounding actually works.
> https://github.com/LibreOffice/core/blob/
> d57836db76fcf3133e6eb54d264c774911015e08/vcl/qt5/QtWidget.cxx#L897
> 
> Gtk counterpart seems to use a different approach for retrieving surrounding
> https://github.com/LibreOffice/core/blob/
> 83485052e6cac574754191c59371dbc41383b810/vcl/unx/gtk3/gtkframe.cxx#L5824

Thank you so much, this is extremely helpful!

I have experimented a bit locally and have had a first quick-and-dirty version
that somewhat works (but breaks other things), but needs more work for a proper
solution.

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to