How to enforce original size when pasting images into Writer?

LO 25.2.5.2, Windows 11

By default, pasting an image (usually a screen shot) into Writer sets the anchor mode to “To character” and the image overflows the page margins. Hitting F4 and changing that to “As character” resizes the image to fit margins and it flows with the text. Works, but an additional step.

So I changed the default to “As character” (Options | LibreOffice Writer | Formatting Aids) and now it pastes anchored “As character” by default. Perfect.

Except it’s not. Now the size is reduced and I still have to hit F4 but this time click “Original size” to make the pasted image fill the margins. But then the aspect ratio is changed, distorting the image.

Is there a way to get an image to paste in, anchored as character and sized to fill the margin extents by default, without distorting the aspect ratio?

Thanks.

This might not seem directly relevant to your question but I think it’s important.

Pasting images always stores them as full colour PNG in Writer. Generally, you can save file size by saving in a suitable format and inserting the image through Insert - Image or by dragging from the file manager.

For screenshots, PNG is a good choice but considerable size savings can be made with minimal loss of quality by reducing them to 256 colours. While you are doing that in your graphics editor, you can set size and DPI.

For photographs, JPG offers the best compression but it’s only kept in that format if the image is inserted. Otherwise, it is posted as PNG with a massive increase in size. While preparing the JPG you can set physical size and resolution.

That could be a factor if I was doing anything at scale. But I’m a home user and use Writer somewhat rarely (I use Calc 25x more). So for me it’s not enough of a factor to be a factor.

A single JPG pasted instead of inserted could increase file size by a factor of 10.

Regardless of file size, when I insert an image that is too large for the margins, it gets shrunk proportionally to fit. I guess that pasting from clipboard might not do that, possibly depending on screenshot application.

I am afraid there is no way.

The distortion comes from hitting a limit. An image is a frame from Writer point of view. A frame size can’t exceed the print area dimension, i.e page size minus margins.

In your case, the original image is wider than the print area. Consequently, the expanded width is capped to the distance between the margins. The constraint on height is lighter since pages are commonly portrait-oriented leaving more room vertically. Then the height can expand to its original height.

Ideally, you would store all desired properties in a frame style. Unfortunately the size of a frame cannot be made dependent on its contents, here the image. If you know in advance the W/H ratio of your images and it is the same for all, you can store the fixed dimensions in the style.

When you consider images, you observe that they have additional properties compared to frame. The Crop tab would allow to set a Scale on H and W. But, again, you’d make a guess for all images and these settings cannot be recorded in a frame style.

The usual recommendation about images is to prepare them outside Writer: cropping, scaling, pixel density, … so that they can be used “as is” in Writer. This also facilitates the design of a “universal” frame style applied to all.

You’ll probably object that this is even more work than F4 and size adjustment. However, this is the more reliable and predictable method.

Well, I want the pasted image reduced until the relatively longest side fits its margin. I don’t care if it doesn’t exactly fit the entire page – In fact it’s unavoidable unless all my images are exactly the same aspect ratio as the page margins. I’d just like Writer to reduce the size (while preserving the aspect ratio) until the relatively longer side fits its margin. I’ve tried manually specifying one dimension or the other, but the distortion remains. Maybe I’d need to start over so the pasted images weren’t initially distorted but that’s not feasible now.

Thanks.

  1. Select the image
  2. Right clic and select Properties in the menu
  3. Clic on Crop Tab
  4. In Scale you must specify the same percent for Height and Width

Yep. I know how to fix it, I just wish it could be that way by default.

Thanks.