DECdocument
Graphics Editor User's Guide
for Motif


Previous Contents Index

3.20 Saving Your Graphic

To save your graphic:

  1. Choose Save As ... from the File menu on the Drawing window to save your workstation drawing.
  2. In the Selection field, delete the current entry and enter WORKSTATION and press Return.

3.21 Graphics Editor Commands

After completing and saving your graphic, you have several options for processing Graphics Editor files. Table 3-6 explains how to use each command.

Table 3-6 Graphics Editor Commands
Command Use To
DOCUMENT/GRAPHICS=EDIT Invoke the interactive graphics editor to create or modify an illustration.
DOCUMENT/GRAPHICS=VIEW Preview Graphics Editor files, as well as sixel, Xbitmap, Bookreader, and DDIF images.
DOCUMENT/GRAPHICS=RENDER Create Encapsulated PostScript, Bookreader, sixel, Xbitmap, and DDIF output files from a Graphics Editor (source) file.
DOCUMENT/GRAPHICS=TEXT_FILTER Extract text from, and merge it back into, a Graphics Editor file (for translation purposes).

The following sections contain examples showing you how to use the previous commands except DOCUMENT/GRAPHICS=TEXT_FILTER. All examples are simplified. Each command has additional qualifiers that are not shown in these examples. See Appendix C for more information on all four commands.

3.21.1 Previewing a Graphics File

The DOCUMENT/GRAPHICS=VIEW command lets you preview a drawing outside of the Graphics Editor at the command line. This command lets you see what the drawing contains and see how it is cropped.

Enter the following command at the DCL command line to preview your graphic:


$ DOCUMENT/GRAPHICS=VIEW WORKSTATION.GRA 

The Graphics Editor creates a window the size of your workstation drawing and displays the drawing in that window.

To exit the previewer, choose the Exit menu item from the Control menu.

3.21.2 Formatting a Graphic for Printing

Before you can print a graphic created with the Graphics Editor, you must format it for printing using the DOCUMENT/GRAPHICS=RENDER command. These commands produce output files in the following formats:
Output Type File Extension
Graphics metafile .GRA
Bookreader .BRF
DDIF image .IMG
PostScript .EPS
Sixel .SIX
Xbitmap .XBM

There are other options on the Export dialog box and qualifiers for the VMS DOCUMENT/GRAPHICS=RENDER command. The exercises demonstrate the most common options and qualifiers for documentation figures. See the online help for more information on the Export dialog box. See Appendix A for more information on the DOCUMENT/GRAPHICS=RENDER qualifiers and the mops qualifiers.

There are two ways to format a graphics file for output. Use:

The VMS command-line utility is useful for formatting files in batch mode or from a non-DECwindows terminal that is pointing to a DECwindows display.

Identical formatting options are available with both the Export menu item and the command-line utility.

The following sections show you how to format your workstation graphic. They create the following files:
File Description
WORKSTATION.EPS A PostScript file, scaled 65 percent in both the horizontal and vertical directions
WORKSTATION.BRF A Bookreader file, not scaled
WORKSTATION.SDML An SDML file with <FIGURE_FILE> tags for inserting the graphic as a figure in a DECdocument file

3.21.3 Using the Export Menu Item

To format your workstation graphic using the Export ... menu item on the File menu:

  1. Choose the Export ... menu item from the File menu. Complete steps 2 and 3 to fill in the Export dialog box (see Figure 3-9) as follows:

    Figure 3-9 Export Dialog Box



  2. In the first column, Output Types:, do the following:
    1. Turn on the Bookreader and EPS toggle indicators.
    2. Turn on the Figure radio button. The SDML File toggle indicator is automatically turned on.
  3. In the second column, Processing Options: do the following:
    1. Turn on the Scale radio button, and enter 65 after both
      X % and Y % to scale the graphic 65 percent on both the X and Y axis.
    2. Turn on the Exclude Bookreader Type From Scaling toggle indicator.
  4. Click on OK. The Graphics Editor processes your graphic and creates the files specified.

3.21.4 Using Command-Line Utilities

To format your workstation graphic using command-line utilities:

  1. Enter the following command on the VMS command line:


     
    $ DOCUMENT/GRAPHICS=RENDER/TYPE=(EPS,BRF)/SDML=FIGURE - 
    _$ /SCALE=(X=65,Y=65,EXCLUDE=BRF) WORKSTATION.GRA 
     
    

    This command does the following:

  2. If you would like to see a printed copy of your workstation drawing, print the PostScript file (WORKSTATION.EPS) on a PostScript printer.

    The SDML file that results looks like the following:


     
    <comment> 
    This file was generated by DOCUMENT/GRAPHICS=RENDER with the 
    following commandline: 
    <endcomment> 
    <line> 
    DOCUMENT/GRAPHICS=RENDER /TYPE=(EPS,BRF) /SDML=FIGURE 
    /SCALE=(X=65,Y=65,EXCLUDE=BRF WORKSTATION.GRA 
    <FIGURE_FILE>(BOOKREADER\WORKSTATION.BRF\13.09) 
    <FIGURE_FILE>(LN03\SPACE\13.09) 
    <FIGURE_FILE>(LINE_PRINTER\SPACE\6.0) 
    <FIGURE_FILE>(PS\WORKSTATION.EPS\9.91) 
     
    

    Note

    To share files with other users, copy them. Do not mail files containing Graphics Editor graphics; mail often distorts the files or does not send them.


    Chapter 4
    Working with Images and Capturing Screens

    Images in the DECdocument Graphics Editor are bitonal, two-dimensional grids of pixels (picture elements) referred to as bitmaps or pixmaps. The pixels in the displayed image are arranged in rows and columns coinciding with the dots of the workstation screen. They are either on or off, typically meaning they are either black or white.

    Image objects in the DECdocument Graphics Editor are obtained in one of two ways:

    Images may be automatically created when a Version 8 GRA file is saved to an older Version 5 file if the Version 8 file contains objects, such as EPS objects, that are not identifiable to Version 5.

    Images are distinct from object-oriented or structured graphics such as lines, circles, arcs, and so on, in the following ways:

    This chapter explains how to:

    For information on formatting and printing screens, see Chapter 3.

    4.1 Using the Graphics Editor with Images

    There are two menu items for working with images:

    4.2 Importing an Image

    The Import ... menu item on the File menu lets you read in and display an image in the Drawing window.

    To import and display an image:

    1. Choose Import ... from the File menu. A File Selection dialog box appears.
    2. Choose the type of image by clicking MB1 on the appropriate option button.
    3. Enter the name of the file you want to display.
    4. Click MB1 on OK.
      An extent rectangle the size of the image appears in the Drawing window.
    5. Move the pointer to position the extent rectangle in the Drawing window where you want the image to appear.
    6. Click MB2 to display the image. Each image you include is treated as a separate object.

    4.3 Using Screen Capture

    The Screen Capture menu item on the View menu lets you capture and digitize areas of your workstation screen. For example, you can capture and digitize:

    After capturing a screen, you can crop it or white out sections not wanted, and save the image in several image file formats.

    The Graphics Editor does not digitize colors. All colored images you capture are converted to monochrome.

    To capture the DECwindows Session Manager screen:

    1. Move the Graphics Editor and Session Manager windows so your screen looks similar to Figure 4-1.

      Figure 4-1 Capturing the Session Manager Screen



      The window you are capturing (the Session Manager window) should not be touching any other window. The Drawing window can overlap the Control Panel. Only a small part of the Drawing window must be visible. The left half of the Hints window should be visible.
    2. Choose Screen Capture from the View menu.
    3. Press the Do or Return key.
    4. Move the pointer to a corner of the Session Manager window.
    5. Hold down MB1 and draw a rectangle around the Session Manager window. Before releasing MB1, use the arrow keys to position the rectangle close to the edge of the window. Move the pointer to position the two sides not affected by the arrow keys.
    6. Release MB1.
    7. Move the pointer to the Drawing window. Position the extent rectangle so the right side of the rectangle is at the right side of the Drawing window. The Drawing window should look similar to Figure 4-2.

      Figure 4-2 Displaying Captured Screen


    8. Click MB2 to display the captured screen in the Drawing window.
    9. Resize the Drawing window to be slightly wider than the Session Manager window you captured.
    10. Display the Pan Viewport submenu from the View menu, and choose CENTER.
      The Session Manager window you captured is centered in the Drawing window. Your screen should look similar to Figure 4-3.

      Figure 4-3 Centering a Captured Screen


    11. Choose Save As ... from the File menu.
    12. Enter EXAMPLE_1 in the Selection box of the Open dialog box. You will use this image in a later exercise to learn how to crop an image.

    4.4 Using Screen Capture ... to Capture Screens

    The Screen Capture ... option lets you control the appearance of color screens giving the resultant captured black and white image a more accurate and realistic appearance.

    When you choose Screen Capture ... from the View menu, a dialog box appears. Figure 4-4 shows the options on the dialog box, Table 4-1 explains each of the four options, and Figure 4-5 shows a comparison of the results from the six possible option combinations.

    Note

    The results of the Screen Capture operation varies with your choice of customized interface colors.

    Figure 4-4 Screen Capture ... Dialog Box


    Table 4-1 Screen Capture ... Dialog Box Options
    Option Explanation
    Threshold Colors in the captured image that have greater than 50 percent luminance become white when printed or viewed. Colors in the captured image that have fifty percent or less luminance become black when printed or viewed.
    Halftone
    (High Frequency)
    Simulates grey tones by using patterns of dots when the colors in the image to be captured tend to be different from pixel to pixel; for example, photographic-type or continuous tone images.
    Halftone
    (Low Frequency)
    Simulates grey tones by using patterns of dots when the colors in the image to be captured tend to be the same from pixel to pixel; for example, when capturing application interfaces.
    Convert Interface Colors Converts the colors in the image to be captured to simulate the appearance of a monochrome screen. This option is useful when capturing application interfaces. Use this option with the Low Frequency Halftone option.

    Figure 4-5 Comparison of Screen Capture ... Options


    To capture a dynamic menu, such as a pull-down menu for which you must hold down MB1 to display, similar to capturing a static screen:

    1. Choose Screen Capture ... from the View menu. The Screen Capture ... dialog box appears.
    2. Click MB1 on Halftone (Low Frequency).
    3. Click MB1 on Convert Interface Colors.
    4. Click MB1 on OK. These options are selected until you reset them. The pointer shape changes to a symbol of a finger pressing a key on a keyboard.
    5. Display the Session Manager Customize menu.
    6. Press the Do key. The pointer shape changes to a crosshair.
    7. Hold down MB1 and draw an extent rectangle around the Customize menu. Use the arrow keys to position the rectangle as close as possible to the sides of the menu. Release MB1.
    8. Move the pointer to the Drawing window and position the extent rectangle so the entire rectangle is displayed.
    9. Click MB2. The captured menu should resemble Figure 4-6.

      Figure 4-6 Captured Menu



      Any menu item you select when capturing a screen will be executed.
    10. Choose Save As ... from the File menu.
    11. Enter EXAMPLE_2. You will use this image in a later exercise to learn how to crop the word Print from the image.

    4.4.1 Redo Screen Capture

    The Redo Screen Capture option lets you recapture the previously captured area of the screen and place it into your drawing. Use this option when you need to repeatedly capture the same area of the screen. The Redo Screen Capture option uses the selected settings on the Screen Capture ... dialog box.

    Note

    Redo Screen Capture uses a previously captured screen; therefore, you must use Screen Capture or Screen Capture ... before you can use Redo Screen Capture.

    To use the Redo Screen Capture option:

    1. Use Screen Capture or Screen Capture ... to capture an image.
    2. Click MB1 on the Redo Screen Capture option on the View menu.
    3. The previously captured area of the screen is recaptured and placed into your drawing in the exact location as the previous capture. If you do not move the previous capture, the redigitized capture will be layered ontop of it.

    4.5 Cropping Images

    There are two ways to delete unwanted objects or text from an image:

    To crop the top line off the image of the Session Manager screen you captured:

    1. Choose Open ... from the File menu.
    2. Enter EXAMPLE_1 in the Open file selection box. See Figure 4-7.

      Figure 4-7 Example 1 Cropping



    3. Choose the Revise option on the Control Panel.
    4. Select the image to be revised (cropped).
    5. Click MB2 to confirm the selection.
    6. Click MB1 and draw a rectangle around the image you want to keep (all but the top line of the Session Manager screen). Use the arrow keys and pointer to position the rectangle around the area you want to keep.
    7. Click MB2 to confirm the selection.
      The top line of the Session Manager screen is cropped off and will not appear on the screen or in the saved file. The image should resemble Figure 4-8.

      Figure 4-8 Example 1 Cropping


    To recrop the original image:

    1. Redisplay the original image.
      1. With the Revise option selected, reselect the image.
      2. Click MB2 to confirm the selection. The original image before cropping is redisplayed.
    2. Do one of the following:
      1. To create a new image crop box, repeat steps 6 and 7 in the previous procedure.
      2. To keep the image at its original size before cropping and to complete the crop operation, click MB2.
      3. To return the image to the last crop size and to complete the crop operation, click MB3.

    To white out the word Print at the top of the Customize pull-down menu you captured:

    1. Choose Open ... from the File menu.
    2. Enter EXAMPLE_2 in the Open file selection box. The menu should look like Figure 4-9.

      Figure 4-9 Example 2 White Out



    3. Choose the Rectangle icon on the Control Panel.
    4. Turn on the White-Out option on the Control Panel.
    5. Turn on the Stack on Top option on the Control Panel.
    6. Draw a rectangle around the word Print. Use the arrow keys to position the rectangle as close as possible to the area you want to white out.
    7. Click MB2 to confirm the rectangle. A box the same color as your background overlays the area you want deleted. The area whited out will not appear on the screen or in the printed image.
      If the box is positioned incorrectly and you want to try again, use the Delete option to delete the box and redraw another rectangle.
    8. Choose the Group option from the Control Panel and group the white rectangle with the image, so they can be moved as one object.

    The finished image should look similar to Figure 4-10.

    Figure 4-10 Example 2 White-Out



    Previous Next Contents Index