Lesson 11: Reusing image data

Copy - Cut - Paste

These three commands are typical on any computer and on any application, the three relative shortcuts being well know by every computer user. The "clipboard" is a temporary piece of memory where the computer stores temporarily anything you put there:

  • CTRL+C: puts selected content in the clipboard,
  • CTRL+X: puts selected content in the clipboard subtracting it from its "environment",
  • CTRL+V: pastes the content of the clipboard on the current "active environment" and in the current "position".

We have seen the shortcut CTRL+SHIFT+V as a quick way to see and/or use the clipboard. This command creates a new image with the contents of the clipboard (if any). The command resides in two positions in the GIMP's menu: File > Create > From Clipboard and Edit > Paste as > New Image.

Copy: Copy is quite straightforward:

  • If there is no selection, you copy the whole layer.
  • If there is a selection, you copy only the selection.

Cut: If there is no selection, the whole layer is cut to the clipboard, leaving nothing behind. If there is a selection, only the selection is cut, leaving a "hole" behind. Hole? What hole?

  • If the layer does not have transparency, what is left inside the hole is the current background color.
  • If the layer has transparency, a real hole remains with nothing in it so you can see through. If there is no active layer under the current layer you see nothing, if there are other active layers under you see them. It is simple and makes sense.

Paste: If you simply paste, GIMP creates a floating selection. We have seen the floating selection in the previous lesson, and the safest thing to do is probably to make it a new layer. Regarding the position of the paste, if you have a selection the paste is aligned with the center of your selection, instead if you do not have a selection the paste is put in the center of your image window. Edit > Paste as > New Layer [SHIFT+L] pastes directly as a new layer on the top left position of the canvas. As we have seen in lesson 8, Edit > Paste Into pastes as a floating selection inside the current selection.

Importing and exporting image data into and from GIMP

Importing and exporting image data to and from any application may naturally be part of any kind of workflow that has to do with image data. Different ways of importing and exporting image data into and out of the GIMP's application are exposed in Lesson 2, since importing image data is a logical first step when starting with GIMP as an image editor. I include them here as well:

Importing image data into the GIMP
Exporting image data from GIMP

Edit > Copy Visible

This is a very useful command, that enables you to selectively copy image data from inside GIMP. It differs from Copy in that it copies data from all visible layers, that is to say you copy "what you see". Like the Copy, Copy Visible acts either on the whole canvas or on part of it, depending if you have a selection or not. This practically means that you can have many layers with image data that you can save in your project and anytime you can deploy them in your workflow at will.

Sidenote: applying image data from GIMP to other applications

The way to use image data outside the GIMP is a matter of the application you work with. You just copy from GIMP in any way you can, and you paste your data in ways that your application offers.

The Clipboard Brush

Whenever you copy or cut image data inside the GIMP, GIMP puts a temporary copy of this image data in the beginning of the Brushes dialog as a usable brush. This brush has a life expectancy till your next action of copy or cut, and will certainly disappear at the end of your GIMP session. You can use this brush with any of the drawing tools, together with the other options of every tool. If you want to save a brush permanently in this way, you can use the command Edit > Paste as > New Brush....




The Named Buffers

GIMP offers one more way of reusing image data: Named Buffers are not saved across sessions though. You can manage them through the Buffers dialog, which is one more dockable dialog in the GIMP's interface: Windows > Dockable Dialogs > Buffers. The basic idea is to have a temporary repository of image data reusable inside your current session: whenever you copy or cut image data, it automatically passes in the Buffers dialog as the "global buffer".

But more than that, you can save a buffer with Edit > Buffer > Copy Named... or Edit > Buffer > Cut Named... From the Buffers dialog you can manage the items, and you can use them with Edit > Buffer > Paste Named... or DoubleClicking on a buffer. You may read the documentation about buffers, it is very easy to understand, i personally do not use them because of their temporary session scope, but they are indeed one more available tool offered.

Important, to keep in mind: data adjust to the drawable you work on

When copying data from one drawable to another, GIMP is quite smart to handle the type of data logically. For example if you copy from RGB and paste on a Grayscale image layer or on a quick mask, the pasted image data will be pasted as Grayscale in both these cases. If you copy from a Grayscale image and paste on a RGB image, the data will "seem to be" Grayscale but in reality they will be converted to RGB, so you will be able to go on working with color. Copying image data between images with different color models, you may find yourself in a situation to see nothing when pasting -- "where the hell is my image!", kind of. In this case first you would need to convert to another color model using the "Image > Mode > ..." submenu.

Another important sidenote could be this: if you want to copy color data and paste them on a Grayscale drawable, your best policy would be firstly to convert that data to Grayscale with the methods explained in Lesson 6, so that you have the control on the converting process. GIMP does always any job well, but of course it cannot know what you have in mind!

No comments:

Post a Comment