After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 606090 - Take default settings from last document opened
Take default settings from last document opened
Status: RESOLVED OBSOLETE
Product: evince
Classification: Core
Component: general
3.8.x
Other Linux
: Normal normal
: ---
Assigned To: Evince Maintainers
Evince Maintainers
: 607475 613695 614402 614573 614578 615411 630735 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2010-01-05 10:16 UTC by Tobias Wolf
Modified: 2018-05-22 13:44 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Tobias Wolf 2010-01-05 10:16:37 UTC
Evince used to remember the state of the sidebar – on or off.
Now it always starts with an open sidebar, which is unfortunate.
Comment 1 Carlos Garcia Campos 2010-01-05 10:25:06 UTC
Do you mean for the same document? or by default for new documents?
Comment 2 Tobias Wolf 2010-01-05 20:07:38 UTC
When I re-open a document in which I had disabled the sidebar before closing Evince starts with a sidebar momentarily and then hides it (within about 100-200ms).

But that it displays the sidebar by default is the problem. I think sidebar or not should not be document dependent. It should be a user specified toggle, like in Nautilus and EOG. I rarely use sidebar at all. I find horizontal resolution tremendously more important to get readable text than gimmicky table of contents or thumbnails. What for is a miniature thumbnail for plain document pages anyway?
Comment 3 Juanjo Marín 2010-03-18 17:23:43 UTC
Maybe is good idea to set the default state of the sidebar (for new documents) as the state without any document.

Does it sounds sensible or is a usability ugly hack ?
Comment 4 Carlos Garcia Campos 2010-03-18 17:49:11 UTC
This a regression caused by the new metadata system. I would fix it as soon as we migrate from gconf to gsettings.
Comment 5 Carlos Garcia Campos 2010-03-31 09:40:38 UTC
*** Bug 614402 has been marked as a duplicate of this bug. ***
Comment 6 Carlos Garcia Campos 2010-04-01 13:06:56 UTC
*** Bug 614578 has been marked as a duplicate of this bug. ***
Comment 7 Carlos Garcia Campos 2010-04-01 13:07:05 UTC
*** Bug 614573 has been marked as a duplicate of this bug. ***
Comment 8 Carlos Garcia Campos 2010-04-04 10:39:12 UTC
*** Bug 607475 has been marked as a duplicate of this bug. ***
Comment 9 Carlos Garcia Campos 2010-04-11 08:22:33 UTC
*** Bug 615411 has been marked as a duplicate of this bug. ***
Comment 10 Carlos Garcia Campos 2010-04-14 18:51:20 UTC
*** Bug 613695 has been marked as a duplicate of this bug. ***
Comment 11 Sebastien Bacher 2010-04-16 19:48:52 UTC
the bug is not going to be fixed in the current GNOME version and users will have to deal with this being broken for one cycle or several if you consider distributions as Debian which will ship the current version in their stable
Comment 12 Carlos Garcia Campos 2010-04-18 09:33:37 UTC
I was thinking about implementing a workaround for 2.30.1
Comment 13 Carlos Garcia Campos 2010-04-20 09:33:08 UTC
I've just pushed a workaround to gnome-2-30 branch. However, not all settings we used to save are saved now, only toolbar and sidebar visibility and window size are used as default values for new documents. I'll fix it in master too by using gsettings.
Comment 14 Evangelos Foutras 2010-04-25 16:26:10 UTC
Thank you, Carlos, for implementing a temporary workaround for this issue. It's a huge time saver for people that open lots of PDFs off of the web, and don't have to resize the Evince windows every time.

May I suggest that the "maximized" setting is saved as well? Even though with commit 1c26547 applied new windows will start almost full sized, a few more pixels can be gained when the window is maximized. :>
Comment 15 Tobias Wolf 2010-04-29 12:36:18 UTC
The sidebar still momentarily flashes when a document is opened. Is this intentional?

Wouldn’t it be better if the sidebar were off by default for an empty window?
Comment 16 Carlos Garcia Campos 2010-04-30 08:04:32 UTC
(In reply to comment #15)
> Wouldn’t it be better if the sidebar were off by default for an empty window?

Yes, fixed now, thanks :-)
Comment 17 biotex 2010-05-03 21:10:51 UTC
This is a pretty huge annoyance for people who spend a lot of time reading science papers, etc.  I always want them to open fullscreen, dual-view, no sidebar or toolbar.  Could you make a workaround by adding command-line options to evince?  There's already -f for fullscreen, but if you add options for dual-view and sidebar I could just replace the evince symlink with a script that calls it with those options set.
Comment 18 Carlos Garcia Campos 2010-05-04 09:00:42 UTC
I've just fixed it in git master too.
Comment 19 Stefan Bethge 2011-02-20 14:36:07 UTC
It seems this bug is still present in 2.32.0 (with default evince on ubuntu maverick).
Even explicitly selecting "save current settings as default" from the menu, some of the new documents have sidebars, different window sizes and fullscreen states.
As far as I recall, there is a way to save settings in a pdf, are they used by evince? It seems as if some new documents use the default while others don't. It would be best if all new files open with the same default and not someone elses preferences.
Comment 20 Ian Dalton 2011-09-30 04:54:33 UTC
This bug should be reopened, because it doesn't work.

1. open evince w/ no PDF
2. resize the windows
3. quit
4. one of:
   a. open evince w/ no PDF
   b. open a never-before-opened PDF

expected result:
window size and location is the same as the no-document window's last set

actual result:
window doesn't remember user-set size or location; no-document windows' size is different than document-holding windows' size
Comment 21 Jim Avera 2012-10-12 23:39:51 UTC
Edit->Save Current Settings As Default

still does not seem to do anything as of version 3.4.0 (in Ubuntu 12.04).

REPRO: 
1. Open a pdf (seemingly always opens a small window at 70% scaling).
2. Resize the window larger and set scaling to 100%
3. Edit->Save Current Settings As Default
4. Close
5. Re-open the same doc

Results: The doc is opened in the small window at70% again.
Expected Results: Should open at large size and 100% scale.
Comment 22 Jim Avera 2012-10-12 23:41:27 UTC
Would someone who has permissions please re-open this (not really fixed) bug?  Thanks.
Comment 23 Akkana Peck 2012-10-13 01:53:02 UTC
I agree, it's not fixed. It no longer shows a sidebar every time, but it still doesn't remember window size. I don't know if Save Current Settings As Default would help, because when I tried that, it crashed my X server. Evince 3.4.0 on Ubuntu pangolin.
Comment 24 Lalo Martins 2013-06-21 15:32:05 UTC
As of this writing, this bug still exists. “Save Current Settings as Default” does nothing; every document is opened with the same completely unusable defaults — tiny window, sidebar on, continuous, fit width. So my PDF-reading routine is: open the file, resize the window, close the sidebar, use the toolbar drop-down to choose “best fit”, disable continuous, and then depending on the nature of the document, possibly enable Dual. It's very painful.
Comment 25 Christian Persch 2013-06-21 15:38:38 UTC
(In reply to comment #24)
> As of this writing, this bug still exists.

That's not very helpful; please specify the exact *version* of evince used.
Comment 26 Lalo Martins 2013-06-21 16:04:29 UTC
Sorry. I'm a little frustrated because this bug is really basic and embarrassing, and it's been there for years. I have reproduced it on 3.6.1 (Ubuntu 13.04) and 3.8.2 (Ubuntu 13.04 with Gnome3 PPA). I attempted both opening the same document where I had “saved” my settings, and a different document. I have “saved” the settings with 3.8.2 before I closed and reopened evince to verify the bug. (Of course in 3.8.2 it's no longer called “Best fit” but rather the more clear “Fit page”.) If there's any additional information about my system and setup you imagine could be useful, please feel free to ask.
Comment 27 Germán Poo-Caamaño 2013-06-21 20:16:34 UTC
(In reply to comment #26)
> Sorry. I'm a little frustrated because this bug is really basic and
> embarrassing, and it's been there for years. I have reproduced it on 3.6.1
> (Ubuntu 13.04) and 3.8.2 (Ubuntu 13.04 with Gnome3 PPA). I attempted both
> opening the same document where I had “saved” my settings, and a different
> document. I have “saved” the settings with 3.8.2 before I closed and reopened
> evince to verify the bug. (Of course in 3.8.2 it's no longer called “Best fit”
> but rather the more clear “Fit page”.) If there's any additional information
> about my system and setup you imagine could be useful, please feel free to ask.

It sounds like a problem with dconf or gvfs.  If you run evince from a terminal, what do you see?
Comment 28 James Cloos 2013-06-21 21:27:58 UTC
I also see this, running master (I last compiled 4021e53643bcbfda9a0e129c).

strace(8) shows that nothing happens when selecting save as defaults from the drop-down menu, other than the expected X11 traffic.  It also shows that evince doesn’t try to load defaults from anywhere at startup.

It does update recent files, though, via ${HOME}/.local/share/recently-used.xbel

I run gentoo with USE=-gnome, and use their ebuild, so the configure call is:

./configure --prefix=/usr --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --libdir=/usr/lib64 --disable-silent-rules --disable-dependency-tracking --disable-schemas-compile --disable-maintainer-mode --disable-gtk-doc --disable-static --disable-tests --enable-pdf --enable-comics --enable-thumbnailer --with-smclient=xsmp --with-platform=gnome --enable-dbus --enable-djvu --enable-dvi --without-keyring --enable-introspection --disable-nautilus --enable-ps --enable-t1lib --enable-tiff --enable-xps

I only run evince from bash.  With this compile, evince does not send anything to STDOUT or STDERR when run.

The dconf and gvfs packages are installed, and something started /usr/libexec/dconf-service.  strace(8)ing that shows some activity when trying to save defaults (which updated ${HOME}/.config/dconf/user), but none when evince first starts.

So perhaps the bug isn’t that it doesn’t save the defaults, but just that it never *reads* them.

This, and the insistence on calling chdir(2) at startup are the only big annoyances now.  (When I open a pdf to edit, I want to be able to save it in the same dir w/o having to root through the filesystem to get back where I started.  I also don’t want the dialog to load in a large(!) directory like $HOME every time; gtk+ is particularly inefficient at doing that, compared to ls(1) or the like.)

Otherwise, evince has come a *long* way.
Comment 29 Lalo Martins 2013-06-21 21:36:33 UTC
SUCCESS! Thank you. It turns out my home dir is not under /home. A little googling and I found this: http://blog.jl42.de/2010/06/ubuntu-apparmor-and-moved-home-dirs/ — now it works correctly, all aspects: sidebar, view mode (continuous, dual, etc), window size. So as far as I can see I can confirm the bug fixed, at least on 3.8, and leave this comment as a tip for other people who still have the issue.
Comment 30 Germán Poo-Caamaño 2013-06-21 23:39:36 UTC
(In reply to comment #28)
> I also see this, running master (I last compiled 4021e53643bcbfda9a0e129c).
> 
> strace(8) shows that nothing happens when selecting save as defaults from the
> drop-down menu, other than the expected X11 traffic.  It also shows that evince
> doesn’t try to load defaults from anywhere at startup.
>
> It does update recent files, though, via
> ${HOME}/.local/share/recently-used.xbel

evince uses gsettings for that, which is done via IPC.

> [...]
> I only run evince from bash.  With this compile, evince does not send anything
> to STDOUT or STDERR when run.
> 
> The dconf and gvfs packages are installed, and something started
> /usr/libexec/dconf-service.  strace(8)ing that shows some activity when trying
> to save defaults (which updated ${HOME}/.config/dconf/user), but none when
> evince first starts.
> 
> So perhaps the bug isn’t that it doesn’t save the defaults, but just that it
> never *reads* them.

Evince reads the defaults. You can try changing a value, for instance:

$ gsettings get org.gnome.Evince.Default fullscreen
false
$ gsettings set org.gnome.Evince.Default fullscreen true

(or the opposite depending of what you get first).

and open a new pdf with no evince metadata (you can check that with `gvfs-info filename`).

> This, and the insistence on calling chdir(2) at startup are the only big
> annoyances now.  (When I open a pdf to edit, I want to be able to save it in
> the same dir w/o having to root through the filesystem to get back where I
> started.  I also don’t want the dialog to load in a large(!) directory like
> $HOME every time; gtk+ is particularly inefficient at doing that, compared to
> ls(1) or the like.)

This should be filed as a different bug.
Comment 31 Germán Poo-Caamaño 2013-06-21 23:40:52 UTC
*** Bug 630735 has been marked as a duplicate of this bug. ***
Comment 32 James Cloos 2013-06-22 16:49:03 UTC
After:

 :; gsettings set org.gnome.Evince.Default fullscreen true
 :; gsettings get org.gnome.Evince.Default fullscreen 
 true

evince still opens just as before.  No fullscreen.  I even picked a file I previously had never opened in evince.

The dconf-service daemon it not contacted at all when evince starts, only when I tell evince to save default settings.

And the recent files info must have been done by evince, not via ipc, else it wouldn't have shown up in an strace of evince.  (And an strace w/o -f or -ff at that.)

(My side-comment complaint already has a bug.)
Comment 33 Christian Persch 2013-06-22 16:52:14 UTC
(In reply to comment #32)
> The dconf-service daemon it not contacted at all when evince starts, only when
> I tell evince to save default settings.

That's because gsettings *reads* are direct, never through the dconf demon.
Comment 34 Carlos Garcia Campos 2013-06-23 06:35:51 UTC
Or because the gsettings memory backend is used instead for some reason?
Comment 35 Akkana Peck 2013-06-25 16:37:33 UTC
In 3.6.1 (Ubuntu 13.04), the settings seem to be working inconsistently. Evince always opens with a small window -- I haven't found any way to get it to change the default window size. Initially it was using "fit page width), but I tried changing it to 100% and resizing the window larger, then doing "Save current settings as default". When I quit and restarted on the same document, it opened at 70% (and the same small window size). I was able to it back to "fit page width", though.

This is under openbox, no Gnome, with dconf but no gvfs, and when I quit after trying to save settings, I get two errors on stderr:

(evince:6806): GLib-GObject-WARNING **: /build/buildd/glib2.0-2.36.0/./gobject/gsignal.c:2593: instance `0xb901fa00' has no handler with id `2073'

(evince:6806): GLib-GObject-WARNING **: /build/buildd/glib2.0-2.36.0/./gobject/gsignal.c:2593: instance `0xb901fa00' has no handler with id `2074'
Comment 36 GNOME Infrastructure Team 2018-05-22 13:44:45 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/evince/issues/126.