{"action":"created","issue":{"url":"https://api.github.com/repos/mate-desktop/atril/issues/145","labels_url":"https://api.github.com/repos/mate-desktop/atril/issues/145/labels{/name}","comments_url":"https://api.github.com/repos/mate-desktop/atril/issues/145/comments","events_url":"https://api.github.com/repos/mate-desktop/atril/issues/145/events","html_url":"https://github.com/mate-desktop/atril/issues/145","id":96631613,"number":145,"title":"per-document view settings should not be saved when unmodified from user's default values","user":{"login":"IndichRMV","id":8524773,"avatar_url":"https://avatars.githubusercontent.com/u/8524773?v=3","gravatar_id":"","url":"https://api.github.com/users/IndichRMV","html_url":"https://github.com/IndichRMV","followers_url":"https://api.github.com/users/IndichRMV/followers","following_url":"https://api.github.com/users/IndichRMV/following{/other_user}","gists_url":"https://api.github.com/users/IndichRMV/gists{/gist_id}","starred_url":"https://api.github.com/users/IndichRMV/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IndichRMV/subscriptions","organizations_url":"https://api.github.com/users/IndichRMV/orgs","repos_url":"https://api.github.com/users/IndichRMV/repos","events_url":"https://api.github.com/users/IndichRMV/events{/privacy}","received_events_url":"https://api.github.com/users/IndichRMV/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/mate-desktop/atril/labels/confirmed","name":"confirmed","color":"f7c6c7"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-07-22T18:16:08Z","updated_at":"2015-07-27T21:50:23Z","closed_at":"2015-07-27T21:50:23Z","body":"The per-document view settings are getting saved regardless of whether the user changed the view settings in a particular document. This results in incorrect values being saved the first time a user closes a document if the user's default view settings are different from Atril's internal default view settings.\r\n\r\nFor example, I have applied the following changes to the default view settings:\r\ngsettings set org.mate.Atril.Default show-sidebar false;\r\ngsettings set org.mate.Atril.Default sizing-mode 'free';\r\n\r\nThe first obviously disables the sidebar; the second makes the zoom default to 100%.\r\n\r\nWhen I open a PDF file I've never opened before for the first time, both of these settings are respected. But if I close the file (without making any changes to the view settings) and open it again for the second time, the sidebar is shown and the zoom is set to \"Fit Page Width\" (incorrect values were saved for the per-document view settings, because Atril does not recognize the actual document view settings unless the user makes a change to them, and falls back to some internal default rather than the user's default as specified in dconf).\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/mate-desktop/atril/issues/comments/125352189","html_url":"https://github.com/mate-desktop/atril/issues/145#issuecomment-125352189","issue_url":"https://api.github.com/repos/mate-desktop/atril/issues/145","id":125352189,"user":{"login":"infirit","id":3465730,"avatar_url":"https://avatars.githubusercontent.com/u/3465730?v=3","gravatar_id":"","url":"https://api.github.com/users/infirit","html_url":"https://github.com/infirit","followers_url":"https://api.github.com/users/infirit/followers","following_url":"https://api.github.com/users/infirit/following{/other_user}","gists_url":"https://api.github.com/users/infirit/gists{/gist_id}","starred_url":"https://api.github.com/users/infirit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/infirit/subscriptions","organizations_url":"https://api.github.com/users/infirit/orgs","repos_url":"https://api.github.com/users/infirit/repos","events_url":"https://api.github.com/users/infirit/events{/privacy}","received_events_url":"https://api.github.com/users/infirit/received_events","type":"User","site_admin":false},"created_at":"2015-07-27T21:50:23Z","updated_at":"2015-07-27T21:50:23Z","body":"I pushed this into master. I am hesitant to cherry-pick this for 1.10, let's have it bake in master for a while and see how things go."}}