! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Enable locate desktop icons on primary or any monitor in multi-display setup
Status:
RESOLVED: FIXED
Priority:
Very High
Severity:
enhancement
Product:
Xfdesktop
Component:
General

Comments

Description rjrich 2014-02-12 21:32:48 CET
Please add functionality to the window and/or desktop manager to enable keeping desktop icons and the panel on the primary monitor when the primary monitor is located on the far right or the center of a dual- or triple-monitor setup.

This can be done in KDE using FolderView. It would be great if Xfce would implement this feature.

Currently, in Xfce, if you set the primary monitor to the center or far right, even if the panel is assigned to the center or far-right monitor, the desktop icons jump to the far-left monitor.

Thank you for your consideration.
Comment 1 rjrich 2017-08-28 17:55:32 CEST
(In reply to rjrich from comment #0)
> Please add functionality to the window and/or desktop manager to enable
> keeping desktop icons and the panel on the primary monitor when the primary
> monitor is located on the far right or the center of a dual- or
> triple-monitor setup.
> 
> This can be done in KDE using FolderView. It would be great if Xfce would
> implement this feature.
> 
> Currently, in Xfce, if you set the primary monitor to the center or far
> right, even if the panel is assigned to the center or far-right monitor, the
> desktop icons jump to the far-left monitor.
> 
> Thank you for your consideration.

Please note that this functionality has been implemented in KDE for some time and more recently in Cinnamon.
Comment 2 Petebacher 2018-03-03 14:07:18 CET
I'll also add my request for this feature.  Please update the Target Milestone if you think there's a serious chance of this being implemented (it wasn't in 4.6).

Thanks

-Pete
Comment 3 Simon Dedman 2018-08-01 07:40:13 CEST
+1 for this. I know there are only 3 people on this bug report thus far but this has come up countless times over the last decade in loads of fora. Please please someone sort it out. Cheers guys!
Comment 4 Lorenzo 2018-10-25 09:36:14 CEST
Also +1 for this! I have a set-up with a laptop as primary display and an external monitor *to the left* as secondary and it's a real (including this desktop icons problem) to work with it in XFCE :(
Comment 5 personxyz 2018-11-07 15:00:09 CET
+1 for this.

It would be super helpful to have this implemented.
Comment 6 Simon Steinbeiss editbugs 2018-11-08 00:09:10 CET
Created attachment 8094 
Add support for RandRs primary monitor

I put together a patch which basically works.

What currently doesn't work: The Net_Wm_Struts are not taken into account, i.e. panels on the primary monitor could overlap the desktop icons. This definitely has to be fixed before the patch can be merged.

Caveat: Xfdesktop has a 7sec timeout for updating icon location. This also affects the changes to the primary monitor, so don't expect to change the primary monitor bit in xfce4-display-settings to have an immediate effect. Maybe this can be fixed by switching from Net_Workarea to Net_Wm_Struts.
Comment 7 Simon Steinbeiss editbugs 2018-11-09 01:00:31 CET
Created attachment 8099 
Additional patch (fix struts/positioning)

I added another patch which builds up on the first one and fixes the struts.

Remaining caveat: you need to toggle the "primary" setting in the desktop settings once, then everything should work as expected.
Comment 8 personxyz 2018-11-09 07:44:02 CET
(In reply to Simon Steinbeiss from comment #7)
> Created attachment 8099 
> Additional patch (fix struts/positioning)
> 
> I added another patch which builds up on the first one and fixes the struts.
> 
> Remaining caveat: you need to toggle the "primary" setting in the desktop
> settings once, then everything should work as expected.

Both patches work as expected THANK YOU :)
Comment 9 personxyz 2018-11-09 07:53:06 CET
(In reply to Simon Steinbeiss from comment #7)
> Created attachment 8099 
> Additional patch (fix struts/positioning)
> 
> I added another patch which builds up on the first one and fixes the struts.
> 
> Remaining caveat: you need to toggle the "primary" setting in the desktop
> settings once, then everything should work as expected.

I forgot to apply the 2nd patch, 1st works as expected, 2nd patch applies fails to compile though :

/usr/bin/ld: xfdesktop-xfdesktop-file-icon-manager.o: in function `xfdesktop_file_icon_manager_save_icons':
/home/lemonade/source/xfdesktop/src/xfdesktop-file-icon-manager.c:1909: undefined reference to `xfdesktop_get_workarea_single'
/usr/bin/ld: xfdesktop-xfdesktop-file-icon-manager.o: in function `xfdesktop_file_icon_manager_get_cached_icon_position':
/home/lemonade/source/xfdesktop/src/xfdesktop-file-icon-manager.c:2010: undefined reference to `xfdesktop_get_workarea_single'

Compiling xfdesktop master from the github repo.
Comment 10 Skunnyk editbugs 2018-11-09 14:26:13 CET
Thank you Simon for the patch :)
In your 2nd patch, you removed xfdesktop_get_workarea_single function but it is still used in other parts of xfdesktop, that's why compilation failed.
Comment 11 Simon Steinbeiss editbugs 2018-11-09 20:11:06 CET
Interesting that it worked for me... Well anyway, that function is crap and needs to go.
As I said, this isn't finished yet, the setting needs to be initialised correctly still and more dead code pruning would be good.

But good to hear it generally works for you!
Comment 12 Simon Steinbeiss editbugs 2018-11-10 23:24:40 CET
Created attachment 8100 
3rd patch that fixes the build issue

Added a third patch that goes on top of the two earlier ones to fix the build issue. Please test if things still work ok! (Especially the saving of icon locations)
Comment 13 Simon Steinbeiss editbugs 2018-11-10 23:43:23 CET
Created attachment 8101 
4th patch that fixes initializing the primary display value

If you apply all 4 patches, everything *should* work as expected now. The primary value is initialized correctly so even without toggling the setting in the desktop settings dialog the iconview should be on the correct display.
Comment 14 personxyz 2018-11-11 10:29:00 CET
Compiles correctly, had to toggle monitor BUT this could be due to the icons being on the left monitor prior to them "moving" to the center one.

Nice work and thank you :)
Comment 15 Git Bot editbugs 2018-11-16 19:12:42 CET
Simon Steinbeiss referenced this bugreport in commit b49f648fc7df64cd8f88f3ec10ed700bce36833a

Add support for RandR's primary monitor (Bug #10688)

https://git.xfce.org/xfce/xfdesktop/commit?id=b49f648fc7df64cd8f88f3ec10ed700bce36833a

Bug #10688

Reported by:
rjrich
Reported on: 2014-02-12
Last modified on: 2018-11-16

People

Assignee:
Simon Steinbeiss
CC List:
8 users

Version

Version:
4.13.2

Attachments

Additional information