It is late and I'm tired but I think I've figured out something that might work and give me and others more flexibility:
Do not lock the Zoom controls.
Allow users to Zoom in, Zoom out, and Zoom Normal, irrespective of the main View mode.
This would result in only a temporarly change of zoom level and then when you move to the next page you would be back to Height/Width/Best/Manual again. (I'm pretty sure what I'm trying to describe is just consistent with what many image viewers do and should seem pretty ordinary.)
I'll ponder this further when I've had sleep and I'm thinking more clearly. I'll see if I can bang out a patch and try it properly and compare to other programs.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
To tell the truth, I've heard other people complain in the past about Zoom being locked to "Custom" zoom mode. Thinking about it, it doesn't really make much sense from the outside, but I can see where herrekberg came from when he made that decision back in Comix. The computation of image width and hight in main/_draw_image is largely dependent on which zoom mode was selected.
Maybe this should be changed: Strip away all the conditional branches, and only compute the zoom factor once when switching images, depending on zoom mode. For example, when "Fit to height" is selected, the zoom factor would be set to 76.64787237%, so that the whole image fits to the screen's height.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Or, alternatively, interpret base image size differently depending on zoom mode. So, when fit to width is selected, 100% would be as much as needed to show the complete image's width, while 100% in custom zoom mode would be the original image size. Looking at the code, this might be easier to implement.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
But then it wouldn't be ``Fit to height'' and ``Fit to width'' anymore. Those modes aren't supposed to scale up images, but to scale them down.
I was not the original submitter of this request.
It is late and I'm tired but I think I've figured out something that might work and give me and others more flexibility:
Do not lock the Zoom controls.
Allow users to Zoom in, Zoom out, and Zoom Normal, irrespective of the main View mode.
This would result in only a temporarly change of zoom level and then when you move to the next page you would be back to Height/Width/Best/Manual again. (I'm pretty sure what I'm trying to describe is just consistent with what many image viewers do and should seem pretty ordinary.)
I'll ponder this further when I've had sleep and I'm thinking more clearly. I'll see if I can bang out a patch and try it properly and compare to other programs.
To tell the truth, I've heard other people complain in the past about Zoom being locked to "Custom" zoom mode. Thinking about it, it doesn't really make much sense from the outside, but I can see where herrekberg came from when he made that decision back in Comix. The computation of image width and hight in main/_draw_image is largely dependent on which zoom mode was selected.
Maybe this should be changed: Strip away all the conditional branches, and only compute the zoom factor once when switching images, depending on zoom mode. For example, when "Fit to height" is selected, the zoom factor would be set to 76.64787237%, so that the whole image fits to the screen's height.
Or, alternatively, interpret base image size differently depending on zoom mode. So, when fit to width is selected, 100% would be as much as needed to show the complete image's width, while 100% in custom zoom mode would be the original image size. Looking at the code, this might be easier to implement.