6

Sometimes, after logging out and in, Xubuntu forgets the positions of the desktop icons and re-arranges them on top-left as default.

I have tried a proposed solution on a similar subject. This locks the icons that were on desktop when I ran the command but not the newer icons.

What could I do to permanently fix this issue? I use Xubuntu 12.10 with xfce 4.12.

  • Please note that since 13.10 I don't use Xfce anymore, so I cannot try any newer answers. – MakisH Nov 10 '17 at 10:18
3

The problem seems to have been solved in the 13.04 edition, but the "semi-solution" I had used made the problem persist. If you have the same problem, try deactivating the lock:

sudo chattr -i ~/.config/xfce4/desktop/icons*

| improve this answer | |
  • For what it's worth, this just happened to me on Xubuntu 14.04, so if it was indeed fixed in 13.04, there's been a regression. – glibdud May 23 '14 at 16:51
0

There is a good solution on ubuntuforums from go4unkwn2: http://ubuntuforums.org/showthread.php?t=2232021

He wrote two scripts, one for backing up ~/.config/xfce4/desktop/icons* files, and second for writing them back from the backup.

I would just add a small enhancement - make an entry in /etc/lightdm/lightdm.conf to run the first script at xfce session end, so you don't have to run it manually every time you want to save icon positions: add or edit line:

session-cleanup-script=your_script_to_save_desktop_icons_position.sh

For restoring icon positions, you can run the second script at session startup, as go4unkwn2 suggests, by adding an entry in Settings/Session and Startup

| improve this answer | |
0

I'm on Xubuntu 14.04 and I had no lightdm.conf file. I put the session-cleanup-script line in /etc/lightdm/lightdm.conf.d/10-xubuntu.conf and it worked but the logout process now takes a while.

| improve this answer | |
0

Thanks Peter, I deleted all files except the latest one and edited it to look like this. Now its under control

[xfdesktop-version-4.10.3+-rcfile_format] 4.10.3+=true

[/home/dave/Desktop/USB Disk Storage Format Tool.desktop] row=7 col=0

[922E612D2E610C13] row=6 col=0

[F474B7AA74B76DCC] row=5 col=0

[FA6441B164417205] row=4 col=0

[8447-F1CD] row=3 col=0

[Trash] row=2 col=0

[/] row=0 col=0

[/home/dave] row=1 col=0

| improve this answer | |
  • Peter Newtons solution should be given at least a +1, because his solution is current and works. Why it is -1 seems as unfair as it is inaccurate. Moderators please note. – DLJonsson2008 Nov 9 '17 at 13:48
  • If one reads the post and follows his directions one can learn something. In my case I gained more control of my desktop icons. What I list above is the contents of a .rc file found in .config/xfce4/desktop/ in context of the discussion. If there is learning value in a post it should not be downgraded -- commented on with suggestions to improve-- but not downgraded. Downgrading such an informative entry will --- discourage volunteers who in the spirit of community constructively share their experiences and worse yet discourage people from reading an entry with solutions that work. – DLJonsson2008 Nov 26 '17 at 9:51
-1

Since Ubuntu 14.04, the Directory structure has changed in Ubuntu 16.04, the desktop Icon placement is no longer a collection of Icons kept in .config/xfce4/desktop/icons as it used to be, now Ubuntu uses a ".rc" file which contains information about desktop layout, found in .config/xfce4/desktop/. The files used to configure desktop Icon placement look like these - icons.screen0-1904x1014.rc - they are text files, when examined in a text editor, they show the name of the Icon and its position, designated by column and row [x,y co-ordinates].

I my case I discovered 16 seperate ".rc" files each one having a different screen resolution in its name, so the first task was to determine which of those 16 files was the current one in use for reference. By looking at the date accessed column in the file manager, this became apparent. Leaving the file manager window open, I highlighted the current file, I opened a terminal at the directory "desktop" with a right button click in the file manager. The directory path was displayed in terminal, and with "sudo -s" authenticated access to this directory, using "ls" the contents of "desktop" were listed in terminal, referring back to the open file manager window with the current file name highlighted, all other desktop configuration files ".rc" were deleted using "rm" leaving the one which was current, at this point the command line: sudo chattr -i ~/.config/xfce4/desktop/icons.screen0-1904x1014.rc can be used to make the file writable and removable [-i] I then rolled up all windows to arrange the Icons in the order of MY choice. I applied the [+i] variable to lock the file: sudo chattr +i ~/.config/xfce4/desktop/icons.screen0-1904x1014.rc

This appears to work, after days of battling with this annoying problem, I restarted the machine and to my delight all desktop Icons were for once, where I wanted them to be, although, quite why I had 16 seperate configuration files, I have no idea, I would imagine the system only needs one as a reference.

The Introduction of more Icons onto the desktop will require the file attributes to be changed again, so this procedure needs to be carried out with each desktop change.

I Hope this will help all other users of Ubuntu 16.04 to solve the wandering Icon problem - best wishes: Peter Newton

| improve this answer | |
  • Welcome to Ask Ubuntu! At the moment your answer is a bit difficult do read because you interlace prose with terminal commands and path names without much typographical distinction. It could benefit greatly if you edit it to apply code formatting to code, commands, and path names. See also How do I write a good answer? for general advice about what sorts of answers are considered most valuable on AskUbuntu. Thanks. – David Foerster May 4 '17 at 19:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.