Bug 470471 - Search input field animation when opening krunner seems out of place
Summary: Search input field animation when opening krunner seems out of place
Status: RESOLVED DUPLICATE of bug 472391
Alias: None
Product: libplasma
Classification: Frameworks and Libraries
Component: components (other bugs)
Version First Reported In: 5.106.0
Platform: Arch Linux Linux
: NOR minor
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-05-30 21:28 UTC by Frank Steinmetzger
Modified: 2023-07-25 16:12 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Frank Steinmetzger 2023-05-30 21:28:48 UTC
SUMMARY
When krunner is opened and slides in from the top, at the same time the input cursor and the “Search ...“ text in the input field slide from right to left. After investigation I now know this comes from the default behaviour of a search input widget, which does this when it receives input focus, because it then hides its looking-glass icon.

But to me (I set global animation speed rather high, which also means it is not always butter-smooth) it looks like the GUI is still being constructed while the panel slides in. Partly this is because the icon starts vanishing as soon as krunner moves in, which makes the icon—and thus the reason for the animation in the first place—practically imperceptible.

What’s your opinion on avoiding this particular animation? Perhaps the focus can be pre-set, or the icon is set only after creating the widget (I don’t know the particulars on how the GUI is constructed). I think it would give an impression of a seemingly faster responding GUI.

Cheers.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.27.5
KDE Frameworks Version: 5.106.0
Qt Version: 5.15.9
Comment 1 Nate Graham 2023-06-05 15:22:26 UTC
This should be fixed now for Kirigami.SearchField, but I see that PlasmaExtras.SearchField has drifted out of sync with it and probably needs the same fix done there.

For components that are mirrored across Kirigami and PlasmaExtras (PlaceholderMessage, ActionTextField, SearchField, PasswordField) we need to make sure we're applying any changes made to both, until the time when we can delete the PlasmaExtras versions and use Kirigami visual components in Plasma and have the styling work properly.
Comment 2 ratijas 2023-06-05 16:19:35 UTC
To the best of my knowledge, the patch in Kirigami got reverted. I had no idea about Plasma counterpart, which is totally my bad.

The trick with disabling Behavior components that David merged didn't really work for two reasons: a) code in that patch was querying Window attached property on a wrong object, so it couldn't possibly work as intended; b) even when querying the right object it would simply not work, due the dynamic and non-deterministic nature of signal propagation (and property evaluation), so animation Behavior was getting enabled back before the focus is given, so it just animated anyway.

TL;DR a different approach based on imperative code hooked up to a window lifecycle is required to make it work. Meanwhile, revert plasma as well.
Comment 3 Nate Graham 2023-07-25 16:12:12 UTC
Forward-duping to Bug 472391 since that bug report has an open merge request to resolve it.

*** This bug has been marked as a duplicate of bug 472391 ***