Posted: Wed Sep 06, 2006 7:33 am Post subject: Drag & Drop in Writer inserts the URL and not the image
Mac OS X 10.4.7 and NeoOffice 2.0 Aqua Beta 3 Patch 1.
When I drag an image from a web browser (tested with Safari 2.0.4 and SeaMonkey 1.0.4) to a Writer document, NeoOffice inserts the URL of the image, not the image itself.
If the image has an hyperlink assigned, the link is inserted.
When I drag the same images in a Draw document, the images are inserted.
Even if I think this is the expected behaviour, it would be very useful having a modifier button, like Alt or Command, to force NeoOffice to always insert the image, even in Writer's documents. Or there could be an option in NeoOffice's preferences.
The more similar bug I found is drag and drop of images from web browser doesn't work in the OpenOffice.org's Bugzilla system but I suspect Patrick has already fixed that issue in the NeoOffice code because the reporter says that drag'n'drop inserts "a piece of HTML source code" and this is not the case with the current version of NeoOffice.
Should I file an enhancement request in the NeoOffice's Bugzilla system?
This is really a browser bug, since the browser puts two (or more) flavors on the clipboard (text, image) and the text (at least in the Gecko case) is put first.
So Writer, being a text app, grabs the text rather than the image, whereas Draw ignores the text and takes the image. (The work-around for Writer is to drag into a pre-constructed image frame).
The only bug you should file (except against Safari; there's already a bug against Gecko for putting the image first in the drag) is in the OOo IssueZilla asking for a drag-modifier that will choose an alternate flavor when drags contain several flavors.
Also note that if you copy/paste, you can in most browsers select "copy image" to only get the image, and "Paste Special" in Neo to choose which flavor to paste.
Smokey _________________ "[...] whether the duck drinks hot chocolate or coffee is irrelevant." -- ovvldc and sardisson in the NeoWiki
First, please to meet you here, too, Smokey.
I didn't imagine Internet could be so small!
sardisson wrote:
This is really a browser bug, since the browser puts two (or more) flavors on the clipboard (text, image) and the text (at least in the Gecko case) is put first.
Why do you think it's a bug?
If I would be a browser developer I would put how many flavors I can on the clipboard if I'm not sure what the user is asking for and I think that there isn't a "right" flavor to be put first.
It's the task of the destination application to choose the right data flavor.
sardisson wrote:
So Writer, being a text app, grabs the text rather than the image, whereas Draw ignores the text and takes the image. (The work-around for Writer is to drag into a pre-constructed image frame).
Could you tell me how I create a pre-constructed image frame in a Writer document?
sardisson wrote:
The only bug you should file (except against Safari; there's already a bug against Gecko for putting the image first in the drag) is in the OOo IssueZilla asking for a drag-modifier that will choose an alternate flavor when drags contain several flavors.
Could you point me to the Gecko bug you mentioned?
I'll insert the enhancement request in IssueZilla.
sardisson wrote:
Also note that if you copy/paste, you can in most browsers select "copy image" to only get the image, and "Paste Special" in Neo to choose which flavor to paste.
Yes, I know, but is less practical and quick than a simple drag 'n' drop.
Moreover, in Safari copy image copies both the image URL and the image itself, so it's always required to use Past Special.
First, please to meet you here, too, Smokey.
I didn't imagine Internet could be so small!
Nice to see you, too Indeed it is a small Internet
XFox wrote:
sardisson wrote:
This is really a browser bug, since the browser puts two (or more) flavors on the clipboard (text, image) and the text (at least in the Gecko case) is put first.
Why do you think it's a bug?
If I would be a browser developer I would put how many flavors I can on the clipboard if I'm not sure what the user is asking for and I think that there isn't a "right" flavor to be put first.
It's the task of the destination application to choose the right data flavor.
Well, it's a complex issue relating to flavor preferences and ordering...and based on the changes to the context menu (see below), I think it's a browser bug. It's certainly subject to debate. But it seems reasonable to me for Writer to prefer text in a drag, since Writer is in fact a text-processing app
XFox wrote:
sardisson wrote:
So Writer, being a text app, grabs the text rather than the image, whereas Draw ignores the text and takes the image. (The work-around for Writer is to drag into a pre-constructed image frame).
Could you tell me how I create a pre-constructed image frame in a Writer document?
I think it's Insert: Frame, but I don't have time to check atm....
XFox wrote:
Could you point me to the Gecko bug you mentioned?
I'll insert the enhancement request in IssueZilla.
Bug 287134 (there's another one, fixed, that I can't find atm where the context menu was changed specifically to put only the image on the clipboard, not the URL, too.
Smokey _________________ "[...] whether the duck drinks hot chocolate or coffee is irrelevant." -- ovvldc and sardisson in the NeoWiki
Joined: Jun 11, 2006 Posts: 481 Location: Great Britain
Posted: Fri Sep 08, 2006 4:06 pm Post subject:
sardisson wrote:
This is really a browser bug, since the browser puts two (or more) flavors on the clipboard (text, image) and the text (at least in the Gecko case) is put first.
XFox wrote:
Why do you think it's a bug?
If I would be a browser developer I would put how many flavors I can on the clipboard if I'm not sure what the user is asking for and I think that there isn't a "right" flavor to be put first.
It's the task of the destination application to choose the right data flavor.
URL is a distinct data type in the OS X clipboard - separate from text - so either NeoOffice is pasting url clipboard data as text or the browser is copying url data to the text clipboard. What happens if you paste into TextEdit? If you get the same url then it's the browser's fault.
Could you tell me how I create a pre-constructed image frame in a Writer document?
I think it's Insert: Frame, but I don't have time to check atm....
I tried Insert -> Frame and if I drop the image in the Index field the URL is pasted and when I click OK the image is copied in a new frame of the document.
However, what I get isn't the same that I get with Insert -> Image.
With Insert -> Frame I get a full-fledged frame with toolbars and grids,
with Insert -> Image I get only the image with the resizing control points and the floating Image toolbar.
djpimley wrote:
URL is a distinct data type in the OS X clipboard - separate from text - so either NeoOffice is pasting url clipboard data as text or the browser is copying url data to the text clipboard. What happens if you paste into TextEdit? If you get the same url then it's the browser's fault.
TextEdit behaves the same as NeoOffice, but what is the browser's fault, exactly?
Joined: Jun 11, 2006 Posts: 481 Location: Great Britain
Posted: Mon Sep 11, 2006 1:23 pm Post subject:
XFox wrote:
TextEdit behaves the same as NeoOffice, but what is the browser's fault, exactly?
It's a fuzzy issue: it depends on what your idea of "correct" behaviour is.
The browser copies the image's data into the image clipboard and the image's url into the url clipboard. The programmers have decided that it is "correct" (I disagree) for the browser also to copy the text of the image's url into the text clipboard. When NeoOffice looks for clipboard data to paste into a document, if there are multiple data types on the clipboard it can only choose one. NeoOffice correctly (in my opinion) prefers text over image data because, as Smokey said, it is primarily a text processing application.
So in my opinion the browser's behaviour is "incorrect" - not buggy, not wrong, just incorrect.
NeoOffice correctly (in my opinion) prefers text over image data because, as Smokey said, it is primarily a text processing application.
Just to clarify: Writer (and I think Calc) prefer text; Draw (and I think Impress, but not sure--50/50 anyway) prefer images, based on each module's primary function.
Smokey _________________ "[...] whether the duck drinks hot chocolate or coffee is irrelevant." -- ovvldc and sardisson in the NeoWiki
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum