The Gnumeric Manual
Prev | Chapter 7. Copying and Moving | Next

# 7.2. Cut, Copy and Paste

Another, more flexible, way to copy or move a selection is to use cut, copy, and paste operations. These operations allow the user to copy or move selected cells to the clipboard buffer and then paste the contents of the clipboard buffer to a different location or a different workbook.

## 7.2.1. Cutting a Selection to the Clipboard

To cut a cell or a selection to the clipboard, you should select a cell or range of cells as described in Section 6.5 and then use one of the following methods:

- Use keyboard shortcut Ctrl-X.

- Choose Cut from the Edit menu.

- Click on Cut button in the toolbar.

- Right-click on the selection and choose Cut from the context menu.

The selection will be copied to the clipboard buffer. To remind you of this, the border of the selection will be shown as "marching ants". The selection will be moved to a new location as soon as you choose Paste command as described below.

| NOTE
| Please note that the selection will remain in its current location until you paste it. If you want to delete a selection without pasting it to a new location, use Delete command instead.

## 7.2.2. Copying a Selection to the Clipboard

To copy a cell or a selection to the clipboard, you should select a cell or range of cells as described in Section 6.5 and then use one of the following methods:

- Use keyboard shortcut Ctrl-C.

- Choose Copy from the Edit menu.

- Click on Copy button in the toolbar.

- Right-click on the selection and choose Copy from the context menu.

The selection will be copied to the clipboard buffer. To remind you of this, the selection will outlined by "marching ants" border. The selection will be copied to a new location as soon as you choose Paste command as described below.

## 7.2.3. Pasting the Clipboard

To paste the contents of the clipboard (i.e., previously cut or copied selection) to a new location, just click on a cell and use one of the following methods:

- Use keyboard shortcut Ctrl-V.

- Choose Paste from the Edit menu.

- Click on Paste button in the toolbar.

- Right-click on the cell and choose Paste from the context menu.

The contents of the clipboard will be pasted in the spreadsheet so that the selected cell becomes the top left corner of the selection. This will also copy the formatting of the original selection.

If you are pasting a selection which was copied to the clipboard buffer, all relative cell references in all formulas will change as described in Section 6.3. The selection remains in the clipboard buffer so that it can be pasted again. The original selection will remain outlined with "marching ants" border.

If you are pasting a selection which was cut to the clipboard buffer, all cell references in all formulas will remain unchanged. The original selection will be removed from the workbook and the clipboard buffer will be cleared.

## 7.2.4. Paste Special

Command Paste described in the previous section copies both contents and formatting of the orignal selection. If you need more options, use Paste Special... command. You can find it in the Edit menu or in the context menu obtained by right-clicking on a cell in the spreadsheet.

The Paste Special... menu item opens a dialog with three categories. The defaults make Paste Special... act as if it were the Paste menu item.

The first set of choices allow the user to control the data pasted.The user can chose to limit the pasting to only the cell contents (no cell formatting is copied) or the opposite only cell formats copied (no contents). Furthermore, the user can insert the selection while transforming all the contents into values only. Formulas will be replaced by their values.

A second set of choices allows the user to perform simple mathematical operations during the paste. These operations use the current contents of the cells in the paste range and the contents of the clipboard. For example, if you are pasting a cell containing number 5 to a cell that currently contains number 10 and choose option Divide, the result will be 10/5=2. Choosing option None will just replace the previous contents of the cells by the contents of the clipboard buffer (this is the default behavior).

The final choices contains the following options:

- Transpose. This option will transpose the selection, i.e. interchange the rows and columns. Thus, a range with k rows and n columns will become a range with n rows and k columns, so that the firs row becomes the first column, and so on.

- Skip Blanks. This option prevents Gnumeric from taking any action for the cells in the selection that are blank. For such cells, the existing contents of the cells in the paste range will be kept.

## 7.2.5. Cut and Paste Between Gnumeric and Other Applications

Cut and paste commands described above allow copying and moving selections from one location in a spreadsheet to another, or between different spreadsheets. However, you can also use cut and paste to exchange information between Gnumeric and other applications, using so-called X clipboard which is shared by all graphical applications.

Whenever you cut or copy a selection in Gnumeric, it is placed both in Gnumeric clipboard and in X clipboard. In X clipboard, it is placed as text, with formulas replaced by their values and contents of different cells separated by spaces.

To paste the selection from X clipboard to an application, click with middle mouse button (if you have two button mouse, you can emulate middle mouse by pressing left and right buttons simultaneously). Most applications also allow pasting from X clipboard by using keyboard shortcut (usually Ctrl-V) or by choosing Edit->Paste.

To paste a selection from another application to Gnumeric, place this selection in the X clipboard. Usually it is done by just selecting it with the mouse; some applications also allow you to use keyboard shortcut Ctrl-C, or choose Edit->Copy. After this, you can paste it in Gnumeric by using Paste command described above. This command will automatically paste the contents of X clipboard if Gnumeric's own clipboard is empty.

Pasting X clipboard in Gnumeric will launch Text Import druid which will assist you in imporitng the plain text contents of X clipboard into the spreadsheet. The Text Import druid is described in Section 10.3.13.2.

Prev | Home | Next
Copying and Moving | Up | Autofill