Bug 128332 - Paste image into empty content frame should work like clicking the center widget
Summary: Paste image into empty content frame should work like clicking the center widget
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
6.3.2.2 release
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-10-23 01:46 UTC by Shem Pasamba
Modified: 2019-11-28 13:22 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Showing the box (1.01 MB, image/png)
2019-11-26 00:25 UTC, Shem Pasamba
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Shem Pasamba 2019-10-23 01:46:48 UTC
Description:
Impress allows inserting of image into a textbox and sizes the image properly within the box. It would be nice if a picture from clipboard could be pasted into the box also so that the user won't need to resize the picture from the clipboard.

Steps to Reproduce:
1. Pick a picture from Wikipedia to paste into my presentation.
2. Copy that picture into clipboard.
3. Paste it into impress.
4. Then I need to delete the existing box container.
5. Then resize the picture that I pasted.

Actual Results:
I had to resize the image and delete the existing box container.

Expected Results:
It would be nice if the pasted clipboard image would fit into the text box container.


Reproducible: Always


User Profile Reset: Yes



Additional Info:
Comment 1 Xisco Faulí 2019-11-25 16:01:31 UTC
Hello Shem,
Which box container are you talking about? In my case, the image is pasted as a unit object.
Please attach a screenshot
Comment 2 Shem Pasamba 2019-11-26 00:25:35 UTC
It's the box where you can insert Table, Chart, Picture, Audio and Video. It would be nice if pasting an image would behave like when inserting a picture into the box. 

Please see attached screenshot.
Comment 3 Shem Pasamba 2019-11-26 00:25:58 UTC
Created attachment 156112 [details]
Showing the box
Comment 4 QA Administrators 2019-11-26 03:32:55 UTC Comment hidden (obsolete)
Comment 5 Heiko Tietze 2019-11-26 12:43:12 UTC
Per menu Insert > Image it works the same as with copy/paste: the image is inserted as a new object. The text/object frames have a small overlay widget that allows to insert a table, chart, audio/video, or image. And this image replaces the active frame using its width or height.

One part is whether or not it technically possible, the other if this behavior is wanted. Personally I would hate when I have to resize the five or so thumbnail-sized images I insert to illustrate some text. And even more relevant is the fact that the overlay widget is available only in case of empty frames. What happens when you insert the image after text has been entered?

So my take: WF.
Comment 6 Shem Pasamba 2019-11-26 14:36:37 UTC
I was actually thinking of a way to paste from the overlay (maybe another button or pressing CTRL while clicking the image button or a even a menu after clicking the insert image) so that instead of just having an option of inserting an image file, there would be an option to insert from clipboard.

It should behave the same way as when inserting an image from a while so that there won't be a problem of pasting into existing textboxes since those won't have an overlay.

This would greatly help in usability since copying and pasting from google images is easier and shorter than downloading the file, clicking insert image, then trying to find where the file was.

Thank you for your consideration.
Comment 7 Roman Kuznetsov 2019-11-26 20:25:22 UTC
hm...

Do you want to insert a image from clipboard that it will fit to area in the "box"?

I think it would be good feature.

Heiko, it could be looks as additional icon in center of slide, like "Insert from clipboard" =)
Comment 8 Heiko Tietze 2019-11-27 08:56:02 UTC
(In reply to Shem Pasamba from comment #6)
> paste from the overlay... so that instead of just having an option of
> inserting an image file, there would be an option to insert from clipboard.

I don't understand this. What overlay? And if you want to paste from clipboard the default ctrl+V/shift+ins is quite handy :-).

> ... the same way as when inserting an image from a while ...

Don't get this either. Perhaps describe step by step what you do, what happens, and what you expect. Like

* Add new slide with default master 
  => effective/expected: Title box and Context box are ready for text (or objects in case of the content)
* Copy the image https://en.wikipedia.org/wiki/File:Cat03.jpg (600 × 599px)
* Paste the image 
  => effective: the image is inserted somewhere in the middle exceeding the slide dimension; 
  => expected: 
  * if the content box is empty place it at top-center and size so it fits into the frame (don't stretch) - (the text box is exchanged by the image); 
  * if the content box is not empty place it at the same position with same size as before but keep the text box; 
  * if there are more boxes, place the image in the center and size like it was one box (no idea how this should work)
...


If your intended workflow is different you better describe what you do. Like "I want the inserted image to be resized and place at position <foo> in order to achieve <bar> because <baz>".
Comment 9 Shem Pasamba 2019-11-27 11:34:13 UTC
Let me try explaining it again: My aim is to be able to cut images from the browser and paste them into the textbox resized like when inserting an image into an empty textbox.

So my suggested workflow is:
1. Copy an image from the browser.
2. On Impress, pick blank a text/object to insert image in.
3. Click insert image from clipboard button in the "overlay widget".

> The text/object frames have a small overlay widget
> that allows to insert a table, chart, audio/video, or image.

(The new thing) instead of inserting an image, it would be nice, if I could just click a button in the "overlay widget" and it would insert that image from the clipboard into the text/object frame, behaving like when inserting an image as a file (I wrote *while last time, sorry).

Thank you for your patience and for considering this request.
Comment 10 Heiko Tietze 2019-11-27 14:11:14 UTC
How about a command that scales the selected image according the slide height / content box height?
Comment 11 Shem Pasamba 2019-11-27 14:30:57 UTC
> How about a command that scales the selected image according the slide height / 
> content box height?

I don't think the overlay widget should be used for pasting images to scale it to the "slide height" as the overlay widget is tied to the content box (text box).

I think we should not limit for height only but that the image fits inside the content box.

For simplicity in implementation and for less code, paste from clipboard fitting it into the text box (as previously explain) using the overlay widget would satisfy my workflow.

I might even be able to cook up a patch for that with:
1. add button to overlay widget
2. onclick new button get image from clipboard
3. make sure it resizes inside the textbox

if you guys would accept that that's the best way to do it.
Comment 12 QA Administrators 2019-11-28 04:09:30 UTC Comment hidden (obsolete)
Comment 13 Heiko Tietze 2019-11-28 13:22:26 UTC
The workflow is still not clear to me. I wouldn't add more UI controls for pasting content. The better solution here seems to be a macro that adjusts the size of the selected image.