5

While in Ubuntu 16.04 this was the default and it was very convenient (at least for me), in Ubuntu 18.04 it always goes to "~/Documents" forcing to navigate to the chosen folder every time.

The use case is probably common: browsing the web reading pdf documents, one may want to keep some of them organized. The probability of several documents browsed in the same session going to the same folder is much higher than not.

This question "...make nautilus to automatically suggest the folder 'Documents'..." ask for the opposite in previous Ubuntu versions, but the solution requires changing the source code, recompiling evince and stop receiving updates for it. In another old question "Can I stop apps from selecting “Recently Used”...", file selector setup is mentioned but the options are outdated.

Is there a setting to control "Save as" behavior in evince or all programs?

arauzo
  • 998
  • This is not how it works for me in 19.04: there, the folder of the opened document is the default for Save (as) even with multiple windows open where other folders are in use. Anyone could confirm the described behaviour in 18.04? – vanadium Jun 27 '19 at 13:21
  • In 18.04 the current folder of the document is suggested when opening from a folder. However, when downloading from the web, the opened document folder is inside /tmp/ and it does not seem a good place to suggest storing a document. – arauzo Jun 28 '19 at 07:32
  • Same behaviour in 19.04. Seems fully consistent to me. A quick save elsewhere in a fixed location can still be achieved with the Places in the left of the dialog. – vanadium Jun 28 '19 at 15:00
  • 2
    Yes, it is consistent and it may be better for others. My question is if the old behavior can be setup, that is much better for the use cases I mentioned. Being more concrete, two use cases: First, I use it to store the copies of student works after correcting them in a folder for each year inside several folders for the subject and topic. Second, reading research papers, after initial overview I want to keep them in a structure of folders by topic. Evince was very useful for this because the last folder where a document was stored is the most probable location for the following in both cases. – arauzo Jul 01 '19 at 07:33

3 Answers3

2

It seems that the only solution to this problem is a modified source and recompiled application. I have created a version with an additional command line parameter (--documents-dir) that enables the user to specify the default save as directory. For details, see this post.

I have also created binary packages for 20.04, which are available from my PPA:

sudo add-apt-repository ppa:laczik/ppa
sudo apt-get update
sudo apt upgrade atril
ZJL
  • 41
  • 5
0

Use Xreader. It's one of the Xapps provided by the Linux Mint Team and a fork of Evince. It opens the same folder you saved your last document.

Forgot to mention: You can use i.e. this PPA to install: https://launchpad.net/~embrosyn/+archive/ubuntu/xapps

sudo add-apt-repository ppa:embrosyn/xapps
sudo apt-get update
sudo apt-get install xreader
syd
  • 17
  • Thanks but I can not choose this answer because it is not a direct answer but an alternative requiring to use another program. I will try myself but requiring to set up an external repository is not useful for the general public. Anyway I will vote for the effort. – arauzo Feb 10 '20 at 16:55
0

Maybe not exactly what you want, but the default save folder can be changed from ~/Documents to whatever you prefer by changing the variable XDG_DOCUMENTS_DIR in ~/.config/user-dirs.dirs. This can be done, e.g., by

xdg-user-dirs-update --set DOCUMENTS $HOME/foo/bar

(Tested with Fedora, I hope it also works in Ubuntu.)

Zanna
  • 70,465
  • Thank you. Yes, it works in Ubuntu. However, this changes the default Documents folder for all applications. It does not adapt automatically like the old behavior but it may be a convenient work around fix. One have to remember to restore the default folder after the session. – arauzo Apr 04 '21 at 09:22