Post Reply 

Script to save clipboard as a new image

Oct 28, 2011, 15:08
Post: #1
Script to save clipboard as a new image
Hi, I am looking for a gimp script to get the contents of the clipboard(*) (File -> Acquire -> Paste as New) and save the image as a png or jpg file (File -> Save As -> [cmd line argument, format obtained from extension]).

(*) The original image was copied from a pdf file in Adobe Reader using Copy Image. I have tried xclip and all that, but to no avail - gimp and openoffice are the only apps I found that grab the image off the right clipboard and I presume it's easier to write a script for gimp. (I want a script because I am gonna be doing this a hundred times - woe is me).

Any help will be greatly appreciated. Thank you.
Find all posts by this user
Quote this message in a reply
Oct 28, 2011, 16:40
Post: #2
RE: Script to save clipboard as a new image
(Oct 28, 2011 15:47)ofnuts Wrote:  For what system? If Windows, Paint will also accept image from the clipboard. In Linux, PDF browser apps such as Okular can save a screen selection to a PNG file directly.

Linux. Thanks, your post gave me an idea to hunt for direct extractors from pdf, and I found pdfimages which works for me!
Find all posts by this user
Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Run script on action rchav 2 503 Aug 13, 2018 14:57
Last Post: rchav
  Script Fu Errors Gimp 2.10.4 lightsaber jd3481 1 369 Aug 2, 2018 05:13
Last Post: paynekj
  Script-fu script to conversion pdf to image 4ever 12 8,378 Jul 17, 2018 16:01
Last Post: paynekj
  Problems with a bat script :( ThaUnknown_ 1 471 Mar 26, 2018 21:14
Last Post: paynekj
  Script-fu ordered file list vnicent 1 291 Mar 19, 2018 17:33
Last Post: paynekj

Forum Jump:


GIMP ForumPortalArchiveContactTermsRSS