Adding images to a document

From Apache OpenOffice Wiki
Jump to: navigation, search



Creating and Editing Images

You might create images (also called ‘pictures’ in OpenOffice.org) using a graphics program, scan them, or download them from the Internet (make sure you have permission to use them), or use photos taken with a digital camera. Writer can import various vector (line drawing) and raster (bitmap) file formats. The most common are GIF, JPG, PNG, and BMP. See the Help for a full list. Some things to consider when choosing or creating pictures include image quality and whether the picture will be printed in color or black and white (grayscale).

To edit photos and other bitmap images, use a bitmap editor. To edit line drawings, use a vector drawing program. You do not need to buy expensive programs. Open-source (and usually no-cost) tools such as Gimp (bitmap editor) and Inkscape (vector drawing program) are excellent. For many graphics, OOo Draw is sufficient. These and many other programs work on Windows, Macintosh OS X, and Linux.

For best results:

  • Create images that have the exact dimensions required for the document, or use an appropriate graphics package to scale photographs and large drawings to the required dimensions. Do not scale images with Writer, even though Writer has tools for doing this, because the results might not be as clear as you would like.
  • Do any other required image manipulation (brightness and contrast, color balance, cropping, conversion to grayscale, and so on) in a graphics package, not in Writer, even though Writer has the tools to do a lot of these things too.
  • If the document is meant for screen use only, there is no need to use high resolution images of 300 or more dpi (dots per inch). Most computer monitors work at between 72 and 96 dpi, reducing the resolution (and the file size) has no negative impact on what is displayed but does make Writer more responsive.

Preparing Images for Black-and-White Printing

If color images are to be printed in grayscale, check that any adjacent colors have good contrast and print dark enough. Test by printing on a black-and-white printer using a grayscale setting. Better still: change the “mode” of the image to grayscale, either in a photo editor or in Writer itself (see Modifying an Image).

For example, the following diagram looks good in color. The circle is dark red and the square is dark blue. In grayscale, the difference between the two is not so clear. A third element in the diagram is a yellow arrow, which is almost invisible in grayscale.

Original Drawing Colour to Printed Grayscale.

Changing the colors of the circle and the arrow improves the contrast and visibility of the resulting grayscale image.

Original Drawing Colour to Printed Grayscale.

If the document will be available in black-and-white print only, a better result can often be obtained by choosing grayscale fills, not color fills — and you don’t have to guess and test to see if you’ve made good choices.

Adding Images to a Document

Images can be added to a document in several ways: by inserting an image file, directly from a graphics program or a scanner, or from the OOo Gallery.


Inserting an image file

When the image is in a file stored on the computer, you can insert it into an OOo document using either of the following methods.


Drag and drop

  1. Open a file browser window and locate the image you want to insert.
  2. Drag the image into the Writer document and drop it where you want it to appear. A faint vertical line marks where the image will be dropped.

This method embeds (saves a copy of) the image file in the Writer document. To link the file instead of embedding it, hold down the Control+Shift keys while dragging the image.


Insert Picture dialog

  1. Click in the OOo document where you want the image to appear.
  2. Choose Insert > Picture > From File from the menu bar.
  3. On the Insert Picture dialog, navigate to the file to be inserted, select it, and click Open. At the bottom of the dialog are two options, Preview and Link. Select Preview to view a thumbnail of the selected image on the right, so you can verify that you have the correct file. See below for the use of Link.
Insert Picture Dialog.
Documentation note.png OOo can import various vector (line drawing) and raster (bitmap) file formats. The most common are GIF, JPEG or JPG, PNG, and BMP. See Graphic file types supported for a full list of supported graphic file types.


Linking an image file

If the Link option in the Insert picture dialog box is selected, Writer creates a link to the file containing the image, instead of saving a copy of the image in the document. The result is that the image is displayed in the document, but when the document is saved, it will contain only a reference to the image file—not the image itself. The document and the image remain as two separate files, and they are merged together only when you open the document again.

Linking an image has two advantages and one disadvantage:

  • Advantage – Linking can reduce the size of the document when it is saved, because the image file itself is not included. The file size is usually not a problem on a modern computer with a reasonable amount of memory, unless the document includes many large graphics files. Writer can handle quite large files.
  • Advantage – You can modify the image file separately without changing the document because the link to the file remains valid, and the modified image will appear when you next open the document. This can be a big advantage if you (or someone else, perhaps, a graphic artist) is updating images.
  • Disadvantage – If you send the document to someone else, or move it to a different computer, you must also send the image files, or the receiver will not be able to see the linked images. You need to keep track of the location of the images and make sure the recipient knows where to put them on another machine, so the document can find them. For example, you might keep images in a subfolder named Images (under the folder containing the document); the recipient of the file needs to put the images in a subfolder with the same name (under the folder containing the document).
Documentation note.png When inserting the same image several times in the document, it might appear beneficial to create links; however, this is not necessary as OOo embeds in the document only one copy of the image file.

Embedding linked images

If you originally linked the images, you can easily embed one or more of them later if you wish. To do so:

  1. Open the Writer document in OOo and choose Edit > Links.
  2. The Edit Links dialog box shows all the linked files. In the Source file list, select the files you want to change from linked to embedded.

  3. Click the Break Link button.
  4. Save the document.
  5. The Edit Links dialog box.
Documentation note.png Going the other way, from embedded to linked, is not so easy—you must delete and reinsert each image, one at a time, selecting the Link option when you do so.


Inserting an image from the clipboard

Using the clipboard, you can copy images into an OOo document from another OOo document and from other programs. To do this:

  1. Open both the source document and the target document.
  2. In the source document, select the image to be copied.
  3. Move the mouse pointer over the selected image and press Control+C to copy the image to the clipboard.
  4. Switch to the target document.
  5. Click to place the cursor where the graphic is to be inserted.
  6. Press Control+V to insert the image.
Using a graphics program.
Documentation caution.png If the application from which the graphic was copied is closed before the graphic is pasted into the target, the image stored on the clipboard could be lost.

Inserting an Image using a Scanner

If a scanner is connected to your computer, OOo can call the scanning application and insert the scanned item into the Writer document page as an image. To start this procedure, place the cursor where the graphic is to be inserted and select Insert > Picture > Scan > Select Source.

Although this practice is quick and easy, it is unlikely to result in a high-quality image of the correct size. You may get better results by scanning material into a graphics program and cleaning it up there before inserting the resulting image into Writer.

Inserting an Image from the Gallery

The Gallery provides a convenient way to group reusable objects such as graphics and sounds that you can insert into your documents. The Gallery is available in all components of OOo. It does not come with many graphics, but you can add your own pictures or find extensions containing more graphics. The Gallery is explained in more detail in in Chapter 11 (Graphics, the Gallery, and Fontwork) in the Getting Started guide. For more about extensions, see Customizing Writer.

This section explains the basics of inserting a Gallery image into a Writer document:

  1. To open the Gallery, click on the Gallery icon CH8 GalleryIcon.png (located in the right side of the Standard toolbar) or choose Tools > Gallery from the menu bar.
  2. Navigate through the Gallery to find the desired picture.
  3. To insert the picture, click and drag it from the Gallery into the Writer document. You can also right-click on the picture and choose Insert > Copy. The figure below shows an example of an image dragged from the Gallery.
    Inserting an image from the Gallery.


    By default, the Gallery is docked above the Writer workspace. To expand the Gallery, position the pointer over the line that divides it from the top of the workspace. When the pointer changes to parallel lines with arrows, click and drag downward. The workspace resizes in response.

    To expand the Gallery without affecting the workspace, undock it so it floats over the workspace. To do so, hold down the Control key and double-click on the upper part of the Gallery next to the View icons. Double-click in the same area while holding down the Control key to dock it again (restore it to its position over the workspace).

    When the Gallery is docked, to hide it and view the full Writer workspace, click the Hide/Show button in the middle of the thin bar separating the Gallery from the workspace.

    To close the Gallery, choose Tools > Gallery to uncheck the Gallery entry, or click on the Gallery icon again.


    Content on this page is licensed under the Creative Common Attribution 3.0 license (CC-BY).
Personal tools