Issue 63399 - Pasting Draw objects with hyperlink fails
Summary: Pasting Draw objects with hyperlink fails
Status: CLOSED FIXED
Alias: None
Product: Draw
Classification: Application
Component: editing (show other issues)
Version: OOo 2.0.2
Hardware: All All
: P3 Trivial with 2 votes (vote)
Target Milestone: 4.2.0
Assignee: Armin Le Grand
QA Contact:
URL:
Keywords: oooqa
Depends on:
Blocks:
 
Reported: 2006-03-20 15:41 UTC by Joe Smith
Modified: 2017-05-20 10:35 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Joe Smith 2006-03-20 15:41:28 UTC
If I copy & paste a Draw object which contains a hyperlink into Writer, only the
URL text is pasted.

Paste Special lists 'Draw8' as the source, but only 'Netscape bookmark' or
'Unformatted text' as the available formats.

Steps to reproduce:
1. New Drawing
2. Create graphic object
3. Edit text (F2, but don't type anything--see issue 29431)
4. Insert > Hyperlink ... set target to "www.google.com" and text to "Google"
5. Select object; Edit > Copy
6. New Writer document
7. Edit > Paste
8. Only "http://www.google.com/" is pasted
Comment 1 Joe Smith 2006-03-20 16:23:29 UTC
PS: May be a 'framework' problem, but pasting same object from Draw into Impress
works fine; pasting object from Impress to Writer fails in the same way, so I
posted it as a Writer bug.
Comment 2 lars 2006-03-20 17:21:13 UTC
confirmed with 680_m158 on WinXP Pro SP2
Comment 3 michael.ruess 2006-03-21 09:12:05 UTC
Reassigned to ES.
Comment 4 eric.savary 2006-03-21 09:32:26 UTC
ES->CL:

- this only happens when the shape *only* contains a hyperlink (no other text,
blank, carriage return...). In this case, the shape is ignored when copied and
only the hyperlink text is sent from Draw to the clipboard (see Windows'
clpbrd.exe).
- No regression. OOo 1.1.5 does it the same.
Comment 5 eric.savary 2006-03-21 09:50:40 UTC
Changed component
Comment 6 syzygy 2010-06-11 13:11:00 UTC
Hello!
To bug 4 years, and an insert of the object with a hyperlink till now it is 
impossible. Perhaps, in the version 3.х there will be improvements?
Comment 7 Joe Smith 2014-04-17 20:41:39 UTC
Tested with AOO 4.0.1/4.1 (beta). Problem no longer occurs--pasted object has intact text & working hyperlink.

Closing as FIXED
Comment 8 Joe Smith 2014-04-17 20:44:07 UTC
Bah. I just noticed that the paste goes into a text document.

Problem still happens in latest versions.

Change back ...
Comment 9 Armin Le Grand 2014-04-22 10:17:51 UTC
Happens as described, looks as if the clipboard code has some specials to choose only the URL from a GraphicObject when it has text, ignoring fill and other stuff. This may have been added in the past to cleanly copy 'pure' URLs, in draw this would be a text frame (no fill, no border) with only the URL as text.
Of course this is bad when a GraphicObject like an Arrow CustomShape is used and disappears unexpectedly when copying it.
Workaround: Select the object, F2, add a space before or after the URL
Comment 10 SVN Robot 2014-04-22 11:45:26 UTC
"alg" committed SVN revision 1589094 into trunk:
i63399 add to clipboard as URL only when no fill and no line style, just a si...
Comment 11 Armin Le Grand 2014-04-22 11:45:34 UTC
Found the special, it's in sd/source/ui/app/sdxfer.cxx. Changed to accept only when no line and fill style, works as intended. Also checked with 'naked' URL TextFrames (click text, insert URL, ...), these still get copied as URLs to the clipboard (as intended).
Committing change, done.