Bug 155251 - Relative size of image changes when opening image properties & pressing OK without touching anything
Summary: Relative size of image changes when opening image properties & pressing OK wi...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
6.3.0.4 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected, regression
Depends on:
Blocks: Writer-Images
  Show dependency treegraph
 
Reported: 2023-05-11 18:18 UTC by Telesto
Modified: 2024-06-04 00:39 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
Example (229.20 KB, application/vnd.oasis.opendocument.text)
2023-05-11 18:19 UTC, Telesto
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Telesto 2023-05-11 18:18:57 UTC
Description:
Height of image changes when opening image properties & pressing OK without touching anything

Steps to Reproduce:
1. Open the attached file
2. Right Click the smiley -> Image properties 
3. Open the 'Position and Size tab and press OK

Actual Results:
Height changes

Expected Results:
No change


Reproducible: Always


User Profile Reset: No

Additional Info:
Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: c4a58634753a84b09f20f7271d6525a6656522d3
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win
Locale: nl-NL (nl_NL); UI: en-US
Calc: CL threaded
Comment 1 Telesto 2023-05-11 18:19:12 UTC
Created attachment 187211 [details]
Example
Comment 2 Telesto 2023-05-11 18:20:09 UTC
Still OK with
Version: 7.0.7.0.0+ (x64)
Build ID: 626ea4e62a3e5005fe9825923a1c0c5bdb61cc08
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: default; VCL: win
Locale: nl-NL (nl_NL); UI: en-US
Calc: CL
Comment 3 m_a_riosv 2023-05-11 20:55:14 UTC
Reproducible
Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: daf30c29be67b8b8fa361b0efd1a6cdbe087b6f8
CPU threads: 16; OS: Windows 10.0 Build 22621; UI render: Skia/Raster; VCL: win
Locale: es-ES (es_ES); UI: en-US Calc: CL threaded
Comment 4 BogdanB 2023-05-12 04:45:55 UTC
In the sidebar the dimensions stays the same, but Undo is appearing, so something is changing.

Version: 7.6.0.0.alpha1+ (X86_64) / LibreOffice Community
Build ID: ca3bfa9bded6103d4d172ace486b697beeb191be
CPU threads: 16; OS: Linux 5.19; UI render: default; VCL: gtk3
Locale: ro-RO (ro_RO.UTF-8); UI: en-US
Calc: threaded
Comment 5 Stéphane Guillou (stragu) 2023-06-22 14:26:32 UTC
(In reply to BogdanB from comment #4)
> In the sidebar the dimensions stays the same, but Undo is appearing, so
> something is changing.

Same for me if I use cm as a measurement in Tools > Options > Writer > General. Can't see a height change, but undo action " available.
I can see the same in OOo 3.3, using right-click > Picture... > Type tab.

However, if I change the measurement unit to Points, I get a drastic change in width. Some weirdness in conversion between relative size values and points?
Telesto reported a change in height instead. Do you use a different measurement unit?

Started in 6.3 for me when using points. Telesto seeing it working in 7.0.7 might have to do with using different measurement units in the dev vs non-dev user profiles.

Bibisected with linux-64-6.3 bibisect repo to first bad commit ec98ba78d7ca832c6b92215169858cf0e9fe3172 which points to core commit:

commit 4b7e2b8a64eca337ea06f7d11fc9d2f66a9d555e
author	Caolán McNamara <caolanm@redhat.com>	Wed Nov 21 21:21:35 2018 +0000
committer	Caolán McNamara <caolanm@redhat.com>	Thu Nov 22 21:59:48 2018 +0100
weld SwFramePage
Reviewed-on: https://gerrit.libreoffice.org/63818

Before commit, relative width is at 116% when opening, confirming does not change size.
Since commit, relative width is at 12% when opening, confirming applies that different size and squeezes the shape

Caolán, can you please have a look?
Comment 6 Caolán McNamara 2024-06-03 19:43:02 UTC
This seems to be fixed now since:

commit a3150fc8a59662ce8630cfc64fec9cd083ac7d36 (HEAD)
Author: Miklos Vajna <vmiklos@collabora.com>
Date:   Fri May 24 12:06:55 2024 +0200

    tdf#145972 sw image dialog: fix bad rel width w/ pt units and kept aspect ratio
Comment 7 Stéphane Guillou (stragu) 2024-06-04 00:39:24 UTC
Verified in:

Version: 24.8.0.0.alpha1+ (X86_64) / LibreOffice Community
Build ID: 1f15d097cace14ca6e44e7652f460aa3fa7bd150
CPU threads: 8; OS: Linux 6.5; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: CL threaded

No change in size, but still an "Apply attributes" undo step - which I feel is pretty standard in many dialogs when clicking OK without changing anything. Not the focus here anyway.