Closed (fixed)
Project:
Manual Crop (old)
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
12 Mar 2013 at 18:58 UTC
Updated:
4 Apr 2013 at 20:30 UTC
Jump to comment: Most recent file
Currently, visible width and height of manualcrop widget thumbnails are set to 100px, not depending on real image proportions:

It seems the problem is in the CSS declaration:
.manualcrop-style-thumb .manualcrop-preview img {
margin: 0px;
max-width: 100px;
max-height: 100px;
}
.manualcrop-style-thumb .manualcrop-preview-cropped img {
max-width: none;
max-height: none;
}
max-width & max-height do what they are asked to: limiting image size to the values of 100px. It's obvious that to let an image to keep it's aspect ratio only one dimension must be constrained:

Simple patch provided.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | manualcrop-1941012-1.patch | 784 bytes | OnkelTem |
| keep_thumb_aspect.patch | 412 bytes | OnkelTem | |
| Screenshot from 2013-03-12 22:55:25.png | 86.06 KB | OnkelTem | |
| Screenshot from 2013-03-12 22:50:58.png | 89.6 KB | OnkelTem |
Comments
Comment #1
OnkelTem commentedComment #2
OnkelTem commentedThe same as above, but created using
git format-patch origin/7.x-1.xComment #3
matthijsThanks, I've applied your patch and will push it later this evening!
Matthijs