Bug 151992 - Resize images pasted from webpage to width of page if the image width exceeds that size
Summary: Resize images pasted from webpage to width of page if the image width exceeds...
Status: RESOLVED DUPLICATE of bug 151033
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.4.1.2 release
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-11-10 11:40 UTC by Dotan Cohen
Modified: 2022-11-11 01:15 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dotan Cohen 2022-11-10 11:40:51 UTC
When pasting rich text into Writer, images that are wider than the page width should be resized (preserving aspect ratio) to the width of the page.

How to reproduce:
1. Copy all the text of the following webpage: https://alanstorm.com/tracing-javascripts-prototype-chain/
2. Paste into LibreOffice Writer

What happens:
The single image on that page is truncated from the right, so that only the left portion of that image is visible on the page in Writer.

What one expects to happen:
The image should be resized preserving aspect ratio to display in the page.
Comment 2 Dotan Cohen 2022-11-10 16:50:41 UTC
In the linked discussion, a commenter noticed that the HTML of the page being copied sets an image width.

Other elements with explicit widths that exceed the Writer page, are in fact resized. Content divs are a good example. I would state that any element wider than the Writer page, should be reduced in width. Images specifically should be also reduced in height to maintain aspect ratio.
Comment 3 m_a_riosv 2022-11-11 01:15:57 UTC

*** This bug has been marked as a duplicate of bug 151033 ***