3170
|
1 |
\chapter{Browsing theory graphs} \label{browse}
|
|
2 |
\index{browser|bold}
|
|
3 |
|
|
4 |
The graph browser {\tt browse} is a tool for visualizing
|
|
5 |
dependency graphs of Isabelle theories. Certain nodes of
|
|
6 |
the graph (i.e.~theories) can be grouped together in "directories",
|
|
7 |
whose contents may be hidden, thus enabling the user to filter out
|
|
8 |
irrelevant information. Because it is written in Java, the browser
|
|
9 |
can be used both as a stand-alone application and as an applet.
|
|
10 |
|
|
11 |
\section{Invoking the graph browser}
|
|
12 |
The browser can be invoked by the command
|
|
13 |
\begin{ttbox}
|
|
14 |
isatool browse [Filename]
|
|
15 |
\end{ttbox}
|
|
16 |
|
|
17 |
\section{Generating graph definition files}
|
|
18 |
Before browsing a theory dependency graph, a graph definition file
|
|
19 |
has to be generated. This works quite similar to the generation
|
|
20 |
of HTML files: $\ldots$ \\
|
|
21 |
A graph definition file has the following syntax:
|
|
22 |
\begin{eqnarray*}
|
|
23 |
\mbox{\it graph} & = & \{ \: \mbox{\it vertex \tt ;} \: \} ^ + \\
|
|
24 |
vertex & = & \mbox{\it vertexname} \: \mbox{\it dirname} \: [ \mbox{\tt +} ]
|
|
25 |
\: \mbox{\it path} \: [ \mbox{\tt <} | \mbox{\tt >} ] \: \{ \: \mbox{\it vertexname} \: \} ^ *
|
|
26 |
\end{eqnarray*}
|
|
27 |
The meaning of the items in a vertex description is as follows:
|
|
28 |
\begin{description}
|
|
29 |
\item[vertexname] The name of the vertex.
|
|
30 |
\item[dirname] The name of the "directory" the vertex should be placed in.
|
|
31 |
A "{\tt +}" sign after {\it dirname} indicates that the nodes in the directory
|
|
32 |
are initially visible. Directories are initially invisible by default.
|
|
33 |
\item[path] The path of the corresponding theory file. This is specified
|
|
34 |
relatively to the path of the graph definition file.
|
|
35 |
\item[List of successor/predecessor nodes] A "{\tt <}" sign before the list
|
|
36 |
means that successor nodes are listed, a "{\tt >}" sign means that predecessor
|
|
37 |
nodes are listed. If neither "{\tt <}" nor "{\tt >}" is found, the browser
|
|
38 |
assumes that successor nodes are listed.
|
|
39 |
\end{description}
|
|
40 |
All names should be put in quotation marks.
|
|
41 |
|
|
42 |
\section{Using the graph browser}
|
|
43 |
The browser's main window, which is shown in figure \ref{browserwindow},
|
|
44 |
consists of two subwindows: In the left subwindow, the directory tree
|
|
45 |
is displayed. The graph itself is displayed in the right subwindow.
|
|
46 |
\begin{figure}[h]
|
|
47 |
\setlength{\epsfxsize}{\textwidth}
|
|
48 |
\epsffile{browser_screenshot.eps}
|
|
49 |
\caption{\label{browserwindow} Browser main window}
|
|
50 |
\end{figure}
|
|
51 |
|
|
52 |
\subsection*{The directory tree window}
|
|
53 |
This section describes the usage of the directory browser and the
|
|
54 |
meaning of the different items in the browser window.
|
|
55 |
\begin{itemize}
|
|
56 |
\item A red arrow before a directory name indicates that the directory is
|
|
57 |
currently "folded", i.e.~the nodes in this directory
|
|
58 |
are collapsed to one single node. In the right subwindow, the names of
|
|
59 |
nodes corresponding to folded directories are enclosed in square brackets
|
|
60 |
and displayed in red colour.
|
|
61 |
\item A green downward arrow before a directory name indicates that the
|
|
62 |
directory is currently "unfolded". It can be folded by clicking on the
|
|
63 |
directory name.
|
|
64 |
Clicking on the name for a second time unfolds the directory again.
|
|
65 |
Alternatively, a directory can also be unfolded by clicking on the
|
|
66 |
corresponding node in the right subwindow.
|
|
67 |
\item Blue arrows stand before ordinary node (i.e.~theory) names. When
|
|
68 |
clicking on such a name, the graph display window focuses to the
|
|
69 |
corresponding node. Double clicking invokes a text viewer window in
|
|
70 |
which the contents of the theory file are displayed.
|
|
71 |
\end{itemize}
|
|
72 |
|
|
73 |
\subsection*{The graph display window}
|
|
74 |
When pointing on an ordinary node, an upward and a downward arrow is shown.
|
|
75 |
Initially, both of these arrows are coloured green. Clicking on the
|
|
76 |
upward or downward arrow collapses all predecessor or successor nodes,
|
|
77 |
respectively. The arrow's colour then changes to red, indicating that
|
|
78 |
the predecessor or successor nodes are currently collapsed. The node
|
|
79 |
corresponding to the collapsed nodes has the name "{\tt [....]}". To
|
|
80 |
uncollapse the nodes again, simply click on the red arrow or on the node
|
|
81 |
with the name "{\tt [....]}". Similar to the directory browser, the contents
|
|
82 |
of theory files can be displayed by double clicking on the corresponding
|
|
83 |
node.
|
|
84 |
|
|
85 |
\subsection*{The "File" menu}
|
|
86 |
Please note that, due to security restrictions, this menu is not available
|
|
87 |
in the applet version. The meaning of the menu items is as follows:
|
|
88 |
\begin{description}
|
|
89 |
\item[Open$\ldots$] Open a new graph file.
|
|
90 |
\item[Export to PostScript] Outputs the current graph in {\sc PostScript}
|
|
91 |
format, appropriately scaled to fit on one single sheet of paper.
|
|
92 |
The resulting file can be sent directly to a {\sc PostScript} capable printer.
|
|
93 |
\item[Export to EPS] Outputs the current graph in Encapsulated {\sc PostScript}
|
|
94 |
format. The resulting file can be included in other documents (e.g.~by using
|
|
95 |
the \LaTeX \ package "epsf").
|
|
96 |
\item[Quit] Quit the graph browser.
|
|
97 |
\end{description}
|
|
98 |
|
|
99 |
\section{The applet version of the graph browser}
|