How do I resize to fit?

Moderators: XnTriq, helmut, cday, xnview, Dreamer

Post Reply
Sablesword
Posts: 10
Joined: Sat Oct 25, 2014 12:17 am

How do I resize to fit?

Post by Sablesword » Sat Dec 09, 2017 8:53 pm

With batch convert, I can resize images so that they fit within a 200x200 pixel box; so that the long side is 200 pixels and the short side is whatever shorter value preserves the image's original ratio.

But how do I do this with the Image->Resize command in the viewer? If I set a custom 200x200 pixel size, with "keep ratio" checked, then the image is resized so that the short side is 200 pixels and the long side is longer.

User avatar
xnview
Author of XnView
Posts: 29267
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: How do I resize to fit?

Post by xnview » Mon Dec 18, 2017 4:40 pm

yes, you need to change the height to update the width
Pierre.

Sablesword
Posts: 10
Joined: Sat Oct 25, 2014 12:17 am

Re: How do I resize to fit?

Post by Sablesword » Mon Feb 19, 2018 7:32 am

Actually, on rechecking the image->resize command, it sets the width at 200 pixels and changes the height to be either longer or shorter, depending on the ratio.

It's an odd choice and I'm inclined to call it a bug.

TommiG2
Posts: 14
Joined: Mon Feb 12, 2018 12:40 pm

Re: How do I resize to fit?

Post by TommiG2 » Wed Feb 28, 2018 9:33 am

Dear Sablesword,

If you say "resize my batch of photos fitting in a box of 200*200 pix" and using the menu "Tools / Batch convert" with an action "Longest side" to 200 pixel, then it works as you expect.

But if you want to resize a specific image, then the meaning is different from a simple "fitting in a box".
Here you have more options:
+ "resize width and height to specific values" or
+ "resize width to a specific value and the height accordingly"
+ "resize height to a specific value and the width accordingly"
This is because you work with only one image, which you know is landscape or portrait and you have full control with more options than in a batch job. Of course you can do the fitting in a box by yourself with them.

In contrast a batch job works with different kind of images (landscape, portrait) and here a simple "fitting in a box" command makes sense.

I see this as different kinds of using and not as a bug.
Best regards,
Thomas

Sablesword
Posts: 10
Joined: Sat Oct 25, 2014 12:17 am

Re: How do I resize to fit?

Post by Sablesword » Wed Feb 28, 2018 3:08 pm

TommiG2,

My problem is that to resize a specific image I often have to manually enter the desired height and/or width. The "preset" sizes work properly and as expected for

+ "resize width and height to specific values" or
+ "resize width to a specific value and the height accordingly"
+ "resize to a percentage of the original size, rather than to specific values"

The preset sizes do NOT work properly or as expected for

+ "resize height to a specific value and the width accordingly"
+ "resize the shorter side (whether height or width) to a specific value and the other side accordingly"
+ "resize the longer side (whether height or width) to a specific value and the other side accordingly"

It is the last of these which is by far my most commonly needed case, and it is the presets not working properly for the last three cases that is the bug.

User avatar
xnview
Author of XnView
Posts: 29267
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: How do I resize to fit?

Post by xnview » Sun Mar 04, 2018 5:02 pm

so like 'resize' in batch convert?
Pierre.

Sablesword
Posts: 10
Joined: Sat Oct 25, 2014 12:17 am

Re: How do I resize to fit?

Post by Sablesword » Sun Mar 04, 2018 5:30 pm

Yes.

User avatar
xnview
Author of XnView
Posts: 29267
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: How do I resize to fit?

Post by xnview » Fri Apr 20, 2018 10:55 am

See issue for current status and some details.
Pierre.

Post Reply