Bug 330052

Summary: muon-discover: layout changes unnecessarily when updates are found
Product: [Applications] Discover Reporter: Achim Bohnet <ach>
Component: discoverAssignee: Jonathan Thomas <echidnaman>
Status: RESOLVED FIXED    
Severity: wishlist CC: aleixpol, sitter, thomas.pfeiffer
Priority: NOR Flags: aleixpol: Usability+
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Achim Bohnet 2014-01-16 23:13:13 UTC
On startup, when the main window is already shown, muon-discover still checks if there are pkg updates available.  If updates are found the Button text 'Installed' changes to 'Installed (x updates)'

This has two irretating (at least for me) consequences as the layout changes suddenly:
1) button 'Sources' is moved to the right
2) search input filed shrinks.

This could be avoided, e.g. by 2 steps
1) Use 'Installed as the right most button so 'Source' is not moved when 'installed' resizes
2) as long as there is unused horizontal space between the 3 buttons and the search field,
make the size of the search field independent of the horizontal space used by the 3 buttons.

Reproducible: Always

Steps to Reproduce:
1. check with e.g. command line tool if updates are avaiable, if yes:
2. start muon-updater
3. have a look at the size of 'install' button and 'search' field
Actual Results:  
after some seconds, the text of install button get's longer and search field get's shorter.

Expected Results:  
only the layout of the 'install' button should change (one possible solution, see details above).
Or even better, find another way to indicate that there are updates without changing the size of the button at all.

Thx for the cool tool
Comment 1 Harald Sitter 2014-01-17 08:48:38 UTC
Marking wishlist.

This is actually something google chrome explicitly addressed WRT tab resizing-while-managing-tabs. Essentially for as long as the mouse is inside the tab bar (+random time for margin of error) the relative tab size will not change.
For Discover something similar ought to be handy:
Don't resize buttons for as long as the mouse is inside the tab bar (+random time) || the search field has focus.

There is however a general downside to indicating it by text in general. '(%1 updates)' may be some 50 characters long in some language which makes the button insanely long. Not necessarily related to the report at hand, but since Achim mentioned it I thought I'd bring that problem up. Perhaps instead of fixing this it would indeed be worthwhile to simply devise another way to indicate updates.
Comment 2 Aleix Pol 2015-01-09 15:32:54 UTC
This should probably be discussed together with the new design:
https://forum.kde.org/viewtopic.php?f=285&t=121810
Comment 3 Thomas Pfeiffer 2016-03-23 16:28:31 UTC
Could you test if the problem still occurs with Discover 5.6?
Comment 4 Aleix Pol 2016-09-14 10:35:42 UTC
Should not be a problem with the new design