GNU bug report logs -
#46554
27.1; 180 degree rotated image is displayed in slightly different position
Previous Next
Reported by: ynyaaa <at> gmail.com
Date: Tue, 16 Feb 2021 09:46:01 UTC
Severity: minor
Found in version 27.1
Full log
View this message in rfc822 format
On Tue, Feb 16, 2021 at 06:45:30PM +0900, ynyaaa <at> gmail.com wrote:
>
> THe form below displays same image with different :rotation.
> The third image is rotated by 180 degree and is displayed in slightly
> different position. There is one pixel gap on the top and left edges of
> the image.
>
> (let ((buf (generate-new-buffer "tmp"))
> (svg "<svg width=\"50\" height=\"50\"
> version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\">
> <rect x=\"0.5\" y=\"0.5\" width=\"49\" height=\"49\"
> stroke-width=\"1\" stroke=\"red\"/>
> </svg>"))
> (switch-to-buffer buf)
> (insert " ")
> (insert-image (create-image svg 'svg t :scale 1))
> (insert " ")
> (insert-image (create-image svg 'svg t :scale 1 :rotation 90))
> (insert " ")
> (insert-image (create-image svg 'svg t :scale 1 :rotation 180))
> (insert " ")
> (insert-image (create-image svg 'svg t :scale 1 :rotation 270))
> (insert " ")
> (put-text-property (point-min) (point-max) 'face '(:background "grey"))
> )
Does this only happen with SVG files, or do you see the same thing
with other image types?
(Windows and NS use the same rotation logic, so I'd be surprised if
some rounding error manifested on one but not the other, although
perhaps there's some difference in compilers... Seems unlikely.)
--
Alan Third
This bug report was last modified 4 years and 218 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.