crop height xor width inconsistency
Posted: 2011-07-28T11:33:15-07:00
This problem involves specifying a single dimension for <crop> (height or width but not both)
consider
it will create and image with a height of 250 and the original width.
however
will not create an image with a width of 250 and the original height. Instead it will instead create a square 250x250 image. If this geometry is passed to ParseGravityGeometry, it will also cause gravity to be ignored.
On the command line the correct bahaviour applies.
Setting attribute height xor width instead of using geometry will produce correct output
EDIT:
I see in msl.c
So it would appear that this is in fact the intended behaviour, however it is still inconsistent with the command line.
consider
Code: Select all
<crop geometry='x250'/>
however
Code: Select all
<crop geometry='250x'/>
On the command line the correct bahaviour applies.
Setting attribute height xor width instead of using geometry will produce correct output
EDIT:
I see in msl.c
Code: Select all
if ((flags & HeightValue) == 0)
geometry.height=geometry.width;