https://bugs.documentfoundation.org/show_bug.cgi?id=144167

--- Comment #23 from Valerio Messina <[email protected]> ---
94 dpi = 94/25.4 = 3.7 px/mm
94 dpi = 94/2.54 = 37 px/cm
300 dpi = 300/25.4 = 11.811 px/mm
300 dpi = 300/2.54 = 118.11 px/cm
aspect ratio=Width/Height

same source drawing:
320x220 mm page     , aspect ratio=1.4545...
300x200 mm rectangle, aspect ratio=1.5

All test made on Debian 11 Bullseye 


I take the time to build the appImage from daily sources:

/opt/LibreOffice$ make_libreoffice_appimage.sh daily x86-64 N N N N Y

/opt/LibreOffice$ LibreOfficeDev-7.5.0.0.alpha0_2022-10-09-x86_64.AppImage


(tests 1-4 made setting size OR resolution)
1)
set size: 32x22 cm (or 320x220 mm)
resolution gray: 37 px/cm (or 3.7 px/mm)
==> PNG 1210x832 px, rectagle, aspect ratio=1.4543

2)
set resolution: 37 px/cm (or 3.7 px/mm)
==> PNG 1210x832 px, rectagle, aspect ratio=1.4543

3)
set resolution: 118 px/cm (or 11.811 px/mm)
gray size change to 102.54x70.61 mm
==> PNG 1210x832 px, rectagle, aspect ratio=1.4543

4)
set resolution: 300 dpi (or 11.811 px/mm)
gray size change to 102.28x70.33 mm
==> PNG 1210x832 px, rectagle, aspect ratio=1.4543

expected results:
32x22 cm @37 px/cm is 1184x814 px, page    , aspect ratio=1.4545...
30x20 cm @37 px/cm is 1110x740 px, rectagle, aspect ratio=1.5

-------------------------------------------------
(tests 5-7 made setting both resolution AND size)
5)
set resolution: 118 px/cm
gray size change to 102.28x70.33 mm
set size Width: 300 mm
Height resize to 206.27 mm (and not 200 mm)
==> PNG 3540x2434 px, rectagle, aspect ratio=1.454396

6)
set resolution: 300 dpi
gray size change to 102.28x70.33 mm
set size Width: 300 mm
Height resize to 206.26 mm (and not 200 mm)
==> PNG 3549x2440 px, rectagle, aspect ratio=1.4545

7)
set resolution: 300 dpi
set size Height: 200 mm
Width resize to 290.87 mm (and not 300 mm)
==> PNG 3441x2366 px, rectagle, aspect ratio=1.4544

expected results:
32x22 cm @118 px/cm is 3776x2596 px, page    , aspect ratio=1.4545...
30x20 cm @118 px/cm is 3540x2360 px, rectagle, aspect ratio=1.5

Comment:
1, 2, 3, 4) larger than expected on both WxH and aspect ratio is wrong
5) right Width, smaller that expected Height and so wrong aspect ratio
6) larger than expected on both WxH and aspect ratio is wrong
7) smaller that expected Width, larger than expected Height, wrong aspect ratio

So best result is get with method 5), setting both resolution and size Width,
at least one pixel size is right, but still got stretched PNG image

Repeated the test with a page with no page border, and the exported rectangle
is perfect, like happen with LO7.2

To me seems in no way this bug is fixed with LO7.5a, neither is better that 7.2
The bug is still unconfirmed

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to