[Contents] [Prev. Chapter] [Next Section] [Next Chapter] [Index] [Help]

19    Program Visualizer

This chapter provides an overview of the Program Visualizer's features and capabilities. For more detailed information on how to use this tool, choose Help: On Program Visualizer. You can print Help topics using the HyperHelp Viewer.

The Program Visualizer provides the ability to display large amounts of data in a condensed format. The Program Visualizer main window uses file pictographs (vertical, rectangular graphics) to give a visual representation of the size and content of source files.

Figure Figure 19-1 shows the Program Visualizer main window.

Figure 19-1:  Program Visualizer Main Window

Key elements are the major window panes running from the top to the bottom of the window:

Configuration area

Displays the current project and the working directory.

Display area

Shows the pictographs of the files you are examining. These pictographs give a visual representation of the size and content of the files.

Information area

Displays information messages and Quick Help on menu items when you press and hold MB1 on the item.


[Contents] [Prev. Chapter] [Next Section] [Next Chapter] [Index] [Help]

19.1    Summary of Features

You can use the Program Visualizer to do the following:


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.2    Using the Program Visualizer with Other Tools

You can use the Program Visualizer with a number of the FUSE tools. For example, you might want to run the Heap Analyzer to find any memory leaks in your code. If you have the Program Visualizer running simultaneously, you can have the results from the Heap Analyzer go directly to the Program Visualizer, thus producing a visualized graphic highlighting the location of the memory leaks within your source code files.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.2.1    Heap Analyzer

You can use the Program Visualizer with the Heap Analyzer to:


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.2.2    Profiler

You can use the Program Visualizer with the Profiler to:


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.2.3    Search

You can use the Program Visualizer with the Search tool in these ways:


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.2.4    Editors

You can use the Program Visualizer with the editors by double clicking on any line in a file pictograph and displaying the source code for that line in an editor.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.3    Starting the Program Visualizer

You can start the Program Visualizer in several ways:


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.3.1    Use the Command Line

You can start the Program Visualizer from the command line using the following command:

% fusepv [-Xt-options] [-cwd] [path...]

See Appendix Appendix D and the specific reference pages for the command syntax and options.

If the Control Panel is not running, it starts automatically as a minimized icon. If FUSE is already running, the Program Visualizer is placed in the current project.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.3.2    Use the Program Visualizer Icon from CDE

When you have CDE installed, FUSE provides a FUSE application group icon and icons for the individual tools that make up the FUSE environment.

To invoke the Program Visualizer:

  1. Double click on the Application Manager icon in the CDE Front Panel to display the application group icons.

  2. Double click on the FUSE application group icon to display the icons in the FUSE application group.

  3. Double click on the Program Visualizer icon to start the tool.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.3.3    Use the FUSE Control Panel

To start the Program Visualizer from the FUSE Control Panel, select Porting Assistant from the Tools menu in the Control Panel. FUSE first lists the tool in the Control Panel under the current project. Then the tool main window appears.

Like all tools, the Program Visualizer inherits its working directory from that set for the current project.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.3.4    Use the Tools Menu from Most FUSE Tools

Most FUSE tools have a Tools menu. To start a tool, select the tool from the Tools menu.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.4    Program Visualizer Terminology

The Program Visualizer uses some terminology with which you might not be familiar. The following table defines some Program Visualizer terms:

Term Definition

File Pictograph

A vertical, rectangular graphic that represents information about a file in a nontextual manner. Each pictograph represents a single file. The size of a pictograph is scaled to the size of the source file, that is, the number of lines within the file.

DataSet

A container file used for grouping data that is passed to the Program Visualizer for display. FUSE tools that send data to the Program Visualizer logically group and encapsulate their data into a DataSet.

The Program Visualizer can display multiple DataSets in the display area.

Event

The results of some action. For example, if you perform a search inquiry that searches each source file for a particular string, each instance in which the string is found is considered an event.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.5    Visualizing Data

You can visualize data in two ways: using the Program Visualizer in conjunction with another FUSE tool, or opening the Program Visualizer and specifying the data that you want to visualize.

When you use the Program Visualizer in conjunction with another FUSE tool, that tool performs its operation, creates a DataSet file that contains the results of its operation, and then starts the Program Visualizer and opens the DataSet file it created. When you start the Program Visualizer without using another FUSE tool, the Program Visualizer's display area is blank. After you start the Program Visualizer, you must specify the data you want to visualize.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.5.1    Specifying Data to Visualize

The Program Visualizer can visualize multiple DataSets and multiple files at one time:


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.5.2    Types of Files That Can Be Visualized

The Program Visualizer can visualize data from the following file types:


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.5.3    Identifying Data Objects in the Display Area

When you open a file or a DataSet, the Program Visualizer uses file pictographs to represent your source files. If you have a color monitor, the file pictographs might have a number of colored lines within them. These colored lines represent the different data objects within the source files. Table Table 19-1 lists the data objects that can be displayed and their corresponding default color.

Table 19-1:  Color Representation of Data Objects Using LIne Details Format

This data object... Displays as this color...

Start of a function

Red

Comments

Green

Executable code

Gray

Events

Colors differ depending on the type of event and the color settings in the DataSet Control window

In addition to the color coding of data objects, the Program Visualizer indents the gray executable code to help identify programming structures, such as if-then-else statements.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.5.4    Saving the Current Display to a DataSet File

The Program Visualizer allows you to save the current contents of the Program Visualizer display area to a DataSet file. All the DataSets and files currently being displayed are saved into the specified DataSet, without affecting the original DataSets or files. For example, if you have the DataSets memoryleaks.vds and search1.vds open, you can save this display into a new DataSet file called searchleaks.vds. When you open the DataSet searchleaks.vds, it contains everything you were viewing from memoryleaks.vds and search1.vds at the time you performed the save.

To save the current display to a DataSet file, choose Save DataSet from the DataSet menu and enter the desired name and directory for the new DataSet file you want to create.

When you open the new DataSet, you must use the Open DataSet option on the DataSet menu.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.6    Event Operations

Events are the results of some action. Examples are:

An event is typically associated with a single line in a file. However, an event could be associated with a range of lines or a complete function.

The following sections discuss how you can display information about an event and how you can easily keep track of those events that you have reviewed.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.6.1    Displaying Event Information Using the Flyby Window

When you press MB1 while the cursor is over an event, a small, horizontal, rectangular flyby window is displayed. The flyby window usually gives you a one-line description of the event.

When multiple events are associated with a line, only the top event is displayed.

Figure Figure 19-2 is an example of the Event Description Flyby window.

Figure 19-2:  Event Description Flyby Window


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.6.2    Choosing the Events to Display

When you choose the Open DataSet Control window option from the Control menu, the DataSet Control window is displayed. This window allows you to choose which events you want displayed in the main window. The DataSet Control window also allows you to turn on and turn off syntax coloring.

To turn on or turn off the display of events, click on the toggle button next to the desired event. When the event is turned on, the toggle button is depressed.


[Contents] [Prev. Chapter] [Prev. Section] [Next Section] [Next Chapter] [Index] [Help]

19.6.3    Displaying Event Information Using the Event Window

When you choose the Open Event Window... option from the Control menu, all the events for the first file shown in the main window are displayed in the Event window along with the following information:

When the Event window is displayed, an Event Selection slider also appears in the main window display area. When you press and hold MB1 while dragging the slider over an event, the Event window is updated to contain information about the events within the file that the slider is on.


[Contents] [Prev. Chapter] [Prev. Section] [Next Chapter] [Index] [Help]

19.6.4    Tracking Events

The Program Visualizer allows you to maintain a status on which events you marked and which events you have not marked. You can see the status of an event from the Event window. Marked events have a check mark between the line number and the event description.

To mark an event, click on the check box beside the event in the Event window. To change a marked event to an unmarked status, click on the check box beside the event. The check mark should disappear.


[Contents] [Prev. Chapter] [Prev. Section] [Next Chapter] [Index] [Help]