After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 99897 - Screen Shot to clip board
Screen Shot to clip board
Status: RESOLVED FIXED
Product: gnome-utils
Classification: Deprecated
Component: screenshot
unspecified
Other other
: Normal enhancement
: ---
Assigned To: Jonathan Blandford
gnome-utils Maintainers
: 161357 164695 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2002-11-29 15:55 UTC by Sepehr Kiani
Modified: 2008-09-08 13:28 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Add copy button (21.53 KB, patch)
2008-07-27 15:34 UTC, Vincent Untz
committed Details | Review

Description Sepehr Kiani 2002-11-29 15:56:51 UTC
Package: gnome-panel
Severity: enhancement
Version: 2.0.6
Synopsis: Screen Shot to clip board
Bugzilla-Product: gnome-panel
Bugzilla-Component: Panel

Description:
Description of Problem:
When I use the screen shot applet, i.e. press print screen button, I
would like to have it put the screen shot bit map into the clipboard.
The is much more useful as is in Windows.

Steps to reproduce the problem:
1. Hit Print screen button or Alt print screen button (for just the
window).
2. Select target application, e.g. OOwriter, and paste.
3. 

Actual Results:
Nothing. Object not in clip board

Expected Results:
Paste the image from the screen shot.

How often does this happen?
All the time

Additional Information:
Without this functionality it adds many steps to making documents
generated from screen shots.

-- 
Sepehr (Sep) Kiani
************************************
Development Engineering
Teradyne Connection Systems
skiani@alum.mit.edu
http://pergatory.mit.edu/skiani




------- Bug moved to this database by unknown@bugzilla.gnome.org 2002-11-29 10:56 -------

Reassigning to the default owner of the component, gnome-panel-maint@bugzilla.gnome.org.

Comment 1 enewman 2002-12-05 20:38:02 UTC
This is really more of an enhancement, not a bug.
Comment 2 Vincent Untz 2004-12-19 15:21:24 UTC
*** Bug 161357 has been marked as a duplicate of this bug. ***
Comment 3 Vincent Untz 2005-01-20 13:32:41 UTC
*** Bug 164695 has been marked as a duplicate of this bug. ***
Comment 4 shimon 2005-03-20 13:47:52 UTC
This is a stupid feature people hate how you would need to open paint in windows
to save it.

If anything add the option to save it to clipboard do not get rid of that pretty
dialog!
Comment 5 shimon 2005-03-20 13:53:17 UTC
Also the image supports drag and drop so you can drag the image to what ever
program you want and I just tested it.

This can be closed.
Comment 6 Sven Neumann 2005-07-13 15:14:28 UTC
At the moment, drag and drop just passes the name of the temporary file, not the
image data. As long as that isn't fixed, this bug shouldn't be closed. Also,
there is really no good reason not to make Ctrl-C do the right thing here.
Especially since it's as simple as calling

 clipboard = gtk_clipboard_get_for_display (gtk_widget_get_display (dialog),   
        
                                            GDK_SELECTION_CLIPBOARD);
 gtk_clipboard_set_image (clipboard, pixbuf);
Comment 7 Andrew 2007-05-02 18:02:46 UTC
DnD and CTRL+C are not as intuitive and discoverable as a simple button "Copy to clipboard."
Comment 8 Sepehr Kiani 2007-05-02 18:48:23 UTC
Why add the extra steps? I want to copy the screen and paste in to my OOwrite page directly, no extra clicks or drags. Better general functionality would be a right click on a clipboard icon on the panel allowing you to save the clipboard contents to a file of the correct format, ie. bitmap, vector, OOwrite, OOcalc, asc text, etc.
Comment 9 Andrew 2007-05-02 19:11:12 UTC
Sepher,

IMO gnome-screenshot's function should be limited to (more-or-less) just bitmap, clipboard, printer, and maybe email because they are common and generic.  The extra functions (vector, text, OpenOffice.org) are specialized and add little value considering you can reuse the generic functions to accomplish the specialized.  

I /generally/ like how Dave Richards replaced gnome-screenshot with a simple utility:
http://davelargo.blogspot.com/2007/03/mime-tiles-testing.html
Comment 10 Emmanuele Bassi (:ebassi) 2007-05-02 19:15:10 UTC
I'm adding actions to the interactive dialog for gnome-screenshot; pther than directly saving the files, it will allow choosing to copy the image to the clipboard or to open it directly inside an application supporting the image/png MIME type.

it still needs polishing, and will have to wait the changes I'm doing to how the screenshot is taken, but it should definitely land in trunk in this cycle.
Comment 11 Alexander Gnodtke 2008-02-14 11:07:13 UTC
IMHO having the image copied to the clipboard is an important feature. As was said in an earlier post, taking screenshots and working with them on Windows is much easier (I had a Windows user miss this simplicity the other day). If you work a lot with screenshots, you want to be quick and that is not accomplished by dragging them around (DnD solution). And it is completely useless to first have to store the image as a file and insert the image from file in a Word Processor document.

The question is how you would do this:
1) Immediately copy to clipboard when pressing PRTSCR?
2) Enable CTRL-C in the dialog? (I implemented a copy to clipboard function along the lines of comment#6 that works as long as the dialog is still open)
3) Other implementations like there have been suggested above?

I would opt for solution 1) because this it seems to be the simplest solution which stays out of the users way and is a known behaviour to Windows users. The dialogue should pop open if the user wants to save the image as a file, but there should be no extra steps required copying the image to the clipboard.

I would like to get started in GNOME development so whoever is deciding on this feature please let me know if he would need my help implementing it. 


Comment 12 Tom Haddon 2008-06-06 14:27:15 UTC
I think the above comment about screenshots being immediately saved to the clipboard is just copying Windows functionality, which is fine for Windows users, but seems counterintuitive to a new user. If it's just copied to the clipboard, how do they know that has happened?

I'd suggest it would be better to add "Copy to the Clipboard" as an option on the dialogue that's presented when someone hits the "Print Screen" button. You could also have an option to "Always do this" so that a user doesn't have to continually do the extra click if they just want it copied to the clipboard every time. However, you'd need a way to reverse this decision - most likely candidate would be from within "Applications -> Take Screenshot" to add a dialogue that stores the preference for whether the screenshot is copied to the clipboard or saved to a file.
Comment 13 Vincent Untz 2008-07-27 15:34:19 UTC
Created attachment 115373 [details] [review]
Add copy button

Here's a simple patch (well, simple except for the glade rewrite :/) that we'll likely use in openSUSE. It also handles Ctrl+C (in case you don't want to use the button).
Comment 14 Sepehr Kiani 2008-07-29 19:06:00 UTC
What would be even more useful option to expand on comment #12 is to send the image to an application of choice. The most common thing to want to do is to crop what you just grabbed before pasting into a presentation, spreadsheet, etc. Lots of steps to do this with GIMP etc. Generalizing would allow you to send to GIMP etc or one could imaging writing a simple g-crop that is very lightweight and only does image cropping. 
Comment 15 Emmanuele Bassi (:ebassi) 2008-08-10 19:03:47 UTC
the patch looks good. I'm afraid it's UI/feature freeze time, though, so I don't know whether we can commit it right now or not. since Vincent is also on the release-team he can reply. :-)

as far as I'm concerned, this might go in as it is, but I'm marking the patch as "commit after freeze".
Comment 16 Cosimo Cecchi 2008-08-28 17:56:58 UTC
CC-ing Vincent.
Comment 17 Vincent Untz 2008-08-28 18:04:56 UTC
(In reply to comment #15)
> the patch looks good. I'm afraid it's UI/feature freeze time, though, so I
> don't know whether we can commit it right now or not. since Vincent is also on
> the release-team he can reply. :-)

We need to ask for freeze break. Want me to do it?
Comment 18 Emmanuele Bassi (:ebassi) 2008-08-28 18:07:41 UTC
I can send an email to r-t, i18n and doc.
Comment 19 Emmanuele Bassi (:ebassi) 2008-08-28 18:12:54 UTC
by the way:

 1. gnome-screenshot trunk now uses GtkBuilder and not libglade, so the patch
    will require a slight update (either I or Cosimo can do that before
    committing it and it doesn't change the logic)
 2. gtk-copy is nice, but maybe a full text 'Copy Screenshot to Clipboard' for
    the button should be used.
Comment 20 Vincent Untz 2008-08-28 22:15:56 UTC
(In reply to comment #19)
>  2. gtk-copy is nice, but maybe a full text 'Copy Screenshot to Clipboard' for
>     the button should be used.

Hrm, well, I agree, but this would make the button huge. I couldn't think of a good solution for this :/

Comment 21 Tom Haddon 2008-08-28 22:28:04 UTC
Perhaps just 'Copy to Clipboard' - not sure how obvious it is that this applies to a screenshot at the time...
Comment 22 Vincent Untz 2008-08-28 22:37:19 UTC
'Copy to Clipboard' is already a bit long in english, but would still be mostly fine. But it will break badly in other languages...
Comment 23 Emmanuele Bassi (:ebassi) 2008-08-30 03:30:21 UTC
(In reply to comment #22)
> 'Copy to Clipboard' is already a bit long in english, but would still be mostly
> fine. But it will break badly in other languages...

why?

just to report for the break request:

  - release-team: 2 approvals (bkor, andre)
  - gtp: 1 approval (gil)
Comment 24 Vincent Untz 2008-08-30 12:10:12 UTC
(In reply to comment #23)
> (In reply to comment #22)
> > 'Copy to Clipboard' is already a bit long in english, but would still be mostly
> > fine. But it will break badly in other languages...
> 
> why?

Some languages have generally longer text, so this would just make the button big. But well, feel free to do it :-)

> just to report for the break request:
> 
>   - release-team: 2 approvals (bkor, andre)
>   - gtp: 1 approval (gil)

You don't need gtp approval: we're not string-frozen yet (we'll be on Monday evening).
Comment 25 Emmanuele Bassi (:ebassi) 2008-09-08 13:28:33 UTC
committed to trunk, with the blessings of the release-team. everyone, say: "thanks, uncle Vincent" and remember to buy him ice cream at the next conference.

2008-09-08  Emmanuele Bassi  <ebassi@gnome.org>

	Bug 99897 – Screen Shot to clip board

	* gnome-screenshot.c:
	(screenshot_dialog_response_cb): Allow copying the screenshot
	image to the clipboard. Based on a patch by Vincent Untz.

	* gnome-screenshot.ui: Add the 'Copy to Clipboard' button.

	* screenshot-dialog.[ch]: Allow retrieving the GdkPixbuf
	of the screenshot from the dialog.