Bug 500435 - "Open Folder" (directory picker) does not save the sidebar width
Summary: "Open Folder" (directory picker) does not save the sidebar width
Status: RESOLVED FIXED
Alias: None
Product: plasma-integration
Classification: Plasma
Component: general (other bugs)
Version First Reported In: 6.3.1
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-02-19 22:08 UTC by Luke Horwell
Modified: 2025-03-15 16:36 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 6.3.4
Sentry Crash Report:


Attachments
Reference of what the directory selector looks like (80.79 KB, image/jpeg)
2025-02-19 22:08 UTC, Luke Horwell
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Luke Horwell 2025-02-19 22:08:50 UTC
Created attachment 178614 [details]
Reference of what the directory selector looks like

SUMMARY

The directory picker does not remember its width and is reset each time. This makes it inconsistent with others like the file picker and Dolphin sidebar, which do.

STEPS TO REPRODUCE
1. Perform a task that opens a directory picker, or run "kdialog --getexistingdirectory"
2. Resize the sidebar
3. Close the directory picker and open it again
4. Observe the size of the sidebar

OBSERVED RESULT
The size of the sidebar is not retained.

EXPECTED RESULT
The size of the sidebar is retained, with similar behaviour to the file picker.


SOFTWARE/OS VERSIONS
Arch Linux
KDE Plasma Version: 6.3.1
KDE Frameworks Version: 6.11.0
Qt Version: 6.8.2

ADDITIONAL INFORMATION
The relevant class is KDirSelectDialog from src/kdirselectdialog.cpp. It should be noted that icon size setting is remembered.

At this time, there is also BUG 499179 which is preventing the sidebar from being resized any smaller.
Comment 1 Luke Horwell 2025-02-20 17:28:08 UTC
I've created a merge request to fix this (and 2 other bugs):
https://invent.kde.org/plasma/plasma-integration/-/merge_requests/168
Comment 2 TraceyC 2025-02-20 17:43:46 UTC
I confirmed this on git-master using
Right-click desktop > Desktop & Wallpaper > Wallpaper type: Slideshow > Folders: Add
Comment 3 Bug Janitor Service 2025-03-11 16:32:16 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-integration/-/merge_requests/170
Comment 4 Nate Graham 2025-03-11 16:38:23 UTC
Git commit e803b44a2ae339182564932990c436f3c0d6c533 by Nate Graham, on behalf of Luke Horwell.
Committed on 11/03/2025 at 16:30.
Pushed by ngraham into branch 'master'.

KDirSelectDialog: Fix sidebar sizing bugs
Related: bug 421247, bug 499179

499179 can't be considered fully fixed yet, as it could still rarely happen
depending on the initial state.

M  +10   -4    qt5/src/platformtheme/kdirselectdialog.cpp
M  +10   -4    qt6/src/platformtheme/kdirselectdialog.cpp

https://invent.kde.org/plasma/plasma-integration/-/commit/e803b44a2ae339182564932990c436f3c0d6c533
Comment 5 Nate Graham 2025-03-11 16:45:28 UTC
Git commit 2885b098a2275ddce9021248b6bf788b4879f42e by Nate Graham.
Committed on 11/03/2025 at 16:31.
Pushed by ngraham into branch 'Plasma/6.3'.

KDirSelectDialog: Fix sidebar sizing bugs
Related: bug 421247, bug 499179

499179 can't be considered fully fixed yet, as it could still rarely happen
depending on the initial state.



(cherry picked from commit e803b44a2ae339182564932990c436f3c0d6c533)

5d91e668 KDirSelectDialog: Improve layout sizing issues
fd59d54c KDirSelectDialog: Save sidebar width

Co-authored-by: Luke Horwell <code@horwell.me>

M  +10   -4    qt5/src/platformtheme/kdirselectdialog.cpp
M  +10   -4    qt6/src/platformtheme/kdirselectdialog.cpp

https://invent.kde.org/plasma/plasma-integration/-/commit/2885b098a2275ddce9021248b6bf788b4879f42e