Bug 151033 - Automatically size the width (and height) of pasted images to fit the page in Writer (instead of exceeding the boundaries with no easy way to size it down)
Summary: Automatically size the width (and height) of pasted images to fit the page in...
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
(earliest affected)
Inherited From OOo
Hardware: All All
: medium enhancement
Assignee: Not Assigned
: 151992 (view as bug list)
Depends on:
Reported: 2022-09-17 14:47 UTC by Jeff Fortin Tam
Modified: 2022-11-11 01:15 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:
Regression By:

demonstration video (1.44 MB, video/mp4)
2022-09-17 14:48 UTC, Jeff Fortin Tam
demonstration video 2 (1.01 MB, video/mp4)
2022-09-17 15:23 UTC, Jeff Fortin Tam

Note You need to log in before you can comment on or make changes to this bug.
Description Jeff Fortin Tam 2022-09-17 14:47:55 UTC
Very often I archive interesting articles from the web by pasting their contents into LibreOffice Writer, as the browser's PDF printer rarely yields good-looking and compact results.

However, there is one major productivity pain point that has been bugging me for years: when there are large/high-resolution images among the contents being pasted, Writer typically pastes it in a way that the images exceed the size of the page, and as a result you then have to fight with the UI to size it down because the resizing handles on the right and bottom are outside the page boundaries (and thus not visible / not interactive), so you have to grab the top-left resizing handle, size a little (because if you resize it "too fast/significantly" from the top-left then Writer messes up the position of the image and throws it onto another page). The process is very tedious and error-prone.

Steps to Reproduce:
As an example to try for yourself, go to https://fixthephoto.com/male-poses.html and ctrl+F "country style" to get to photo no. 29, select the title text above the photo until the paragraph below the photo (including the photo) and copy+paste it into Writer.

Attached is a video demonstrating the issue for posterity.

Actual Results:
The image vastly exceeds the page width and height, making it difficult to see and to resize.

Note that it seems "less terrible than in really is" in the video, because Writer is half-tiled (and thus very tall) on my screen; when Writer is maximized on a landscape/wide screen, it is *infernal* to try to resize those images.

Expected Results:
Writer should auto-size paste images to fit the page's width and height (while respecting the image's aspect ratio, of course). Images that exceed the page's dimensions just don't make sense at all.

Making me incrementally resize images to fit on the page is meaningless extra work inflicted on the user, and the lack of resizing handles would also confuse non-technical users I mentor. The software/computer should be smart enough to figure out reasonable defaults.

Reproducible: Always

User Profile Reset: No

Additional Info:
Comment 1 Jeff Fortin Tam 2022-09-17 14:48:30 UTC
Created attachment 182525 [details]
demonstration video
Comment 2 Timur 2022-09-17 15:19:51 UTC
I think this request already exists, should be searched for!
Comment 3 Jeff Fortin Tam 2022-09-17 15:23:37 UTC
Created attachment 182526 [details]
demonstration video 2

In that article, photo no. 26, "Sitting on Unfolded Chair", is an even better example and testcase, because as you can see in this 2nd demonstration video, it _requires_ multiple steps to resize down due to some weird behavior in LibreOffice Writer where it "blocks" the resizing to a certain intermediate size first...

It also illustrates the jumping/scrolling problem quite well: when you initially downsize the image, it "jumps" two pages upwards so you have to guess that it's gone over there, scroll way up, and continue resizing. Writer should instead have auto-scrolled to the image's new position so that it stays in view.
Comment 4 Jeff Fortin Tam 2022-09-17 15:27:35 UTC
@Timur: yup, I searched around before filing this, but did not see a ticket clearly documenting this specific issue in a very applied/concrete/clear way, with demonstrations etc. Namely I saw bug #107703 but it gets lost in the noise of "can't reproduce" and "PPI" discussions; I don't care about PPI, it's not relevant to the user, I only care about the images being auto-sized to fit within the page width and height if they do exceed those boundaries, so not exactly the same thing in my opinion.
Comment 5 m.a.riosv 2022-09-18 11:06:25 UTC
Right-click on the image, Properties [F4] - Position & size - Relative to entire paragraph area (width+height) - Keep ratio.

In any case, IMO a request for enhancement, not a bug.
Comment 6 m.a.riosv 2022-11-11 01:15:57 UTC
*** Bug 151992 has been marked as a duplicate of this bug. ***