Kevin Wolf <kw...@redhat.com> writes: > On Mon, Feb 18, 2013 at 05:57:02PM -0600, Anthony Liguori wrote: >> Basic menu items to enter full screen mode and zoom in/out. Unlike SDL, we >> don't allow arbitrary scaling based on window resizing. The current behavior >> with SDL causes a lot of problems for me. >> >> Sometimes I accidentally resize the window a tiny bit while trying to move it >> (Ubuntu's 1-pixel window decorations don't help here). After that, scaling >> is >> now active and if the screen changes size again, badness ensues since the >> aspect ratio is skewed. >> >> Allowing zooming by 25% in and out should cover most use cases. We can add a >> more flexible scaling later but for now, I think this is a more friendly >> behavior. >> >> Signed-off-by: Anthony Liguori <aligu...@us.ibm.com> > > Zoom to fit doesn't only change whether the contents of the window is > scaled or not, but it also resizes the window to 100% when it's toggled. > I don't think this is the right behaviour.
This behavior is controlled by two lines in gd_menu_zoom_fit: s->scale_x = 1.0; s->scale_y = 1.0; If you remove them, it keeps the window size from zooming but works you're expecting. I'm not sure what the Right Way is from a Gnome point of view but evince's "Best Fit" doesn't alter the window size which I think is a close analogy. So I'm inclined to agree with your assessment. I'll remove these lines from the next revision. Regards, Anthony Liguori > > Kevin