Adobe (Acrobat) Reader & clipboard graphics

Kevin Krammer kevin.krammer at gmx.at
Fri May 4 12:14:07 BST 2007


On Donnerstag, 3. Mai 2007 +0100, Ryo Furue wrote:
> Hi all,
>
> I'm wondering how the clipboard works with Adobe Reader.
> When you select a portion of text in Adobe Reader and copy it
> to the clipboard, you can paste it to anywhere including emacs,
> and kolourpaint.  But, when you select graphics, you can't paste
> it anywhere, although Adobe Reader says the graphics is copied
> to "the clipboard".  (kpdf works correctly, by the way.)
> I'm using Debian testing.

Where did you try pasting to? If you haven't, can you check another GKT+ based 
program, e.g. Gimp?

> So, what does Adobe Reader do incorrectly?  or what clipboard
> does it use?  What clipboard does KDE use?  Is there any
> standard, which enables KDE, Gnome, and other applications
> to share a common clipboard?  I could just file a bug report
> to Adobe, saying that their clipboard doesn't work on KDE,
> but I'm curious.

All applications usually use the same clipboard. Unless Adobe did their own 
clipboard handling, they will even use it the same way any other GTK+ 
application does.

However there can still be unfortunate "misunderstandings" between 
application: the application which copies something into the clipboard 
announces in which MIME types it can offer the content and the application 
which pastes chooses one of them and requests the content formatted according 
to this MIME type.

Sometimes it happens that the pasting application chooses a suboptimal MIME 
type, e.g. something that suits its needs better but does loose some of the 
content. Sometimes they just try a couple of known types and use the first 
that matches, without checking for a more appropriate one.
Sometimes the copying application puts too much information into one single 
MIME type offer, leading to recognition problems on the pasting application's 
side.

If you are interested in investigating, I've written a small test program 
which dumps the MIME type a Qt program will see on the clipboard.

% qmake clipboardtest.pro
% make

You have to run it from a console window, because it just writes its output to 
the console.

Run it, do the copy operation oin Adobe reader and then click the button in 
the test program. Should dump a list of MIME types currently offered on the 
clipboard to the console the test program was started in.

Cheers,
Kevin

-- 
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
-------------- next part --------------
A non-text attachment was scrubbed...
Name: clipboardtest.cpp
Type: text/x-c++src
Size: 798 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde/attachments/20070504/83a01d97/attachment.cpp>
-------------- next part --------------
TEMPLATE = app

CONFIG += qt console

TARGET = clipboardtest

SOURCES = clipboardtest.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde/attachments/20070504/83a01d97/attachment.sig>
-------------- next part --------------
___________________________________________________
This message is from the kde mailing list.
Account management:  https://mail.kde.org/mailman/listinfo/kde.
Archives: http://lists.kde.org/.
More info: http://www.kde.org/faq.html.


More information about the kde mailing list