Help Menu
Fri Mar 17 19:39:21 WET 2006 Miguel Vilaca <jmvilaca@di.uminho.pt>
* Help Menu
Adds About window
Adds help in tool
{
adddir ./html
addfile ./html/HowToUse.html
hunk ./html/HowToUse.html 1
+<html>
+<head>
+ <title>INblobs editor</title>
+ <meta name="keywords" content="IN, Interaction Nets, editor, INblobs" />
+ <meta name="description" content="Free Interaction Nets editor." />
+</head>
+
+<body>
+<h3>How to use INblobs</h3>
+<p>
+<ul>
+<li> Select on agent by pressing its button in the left panel with a visible palette
+<li> Right click on one canvas, nodes, and edges for context menus.
+<li> To create a node, shift click on some blank canvas.
+<li> To create an edge, select (click) the source port then shift-click
+ the target port.
+<li> To delete a node or edge, select it and press backspace.
+<li> To rearrange the diagram, click and drag nodes to where you want them.
+<li> To make an edge look tidier, add a control-point from its context menu,
+ and drag the point to where you want it.
+<li> You can add multiple items into the current selection by meta-clicking
+ the extra nodes and control points. (Meta = Apple key, or Alt key.)
+ A multiple selection can be dragged just like a single selection.
+<li> Interface is explicitly defined by means of an interface agent
+<li> The net on the bottom is the net to be reduced
+<li> The two nets in the top are the left hand side and right hand side of an interaction rule; the one selected in the tree of rules
+<li> To add a new rule do mouse right-click in <b>Rules</b> (the root of the tree of rules) and press <b>Add new rule</b>. Then add agents to the canvas on the top.
+<li> Since Interation Rules left hand side is always only one active pair, together with <b>Add new rule</b> is an option <b>Create new Interaction Net rule</b>. Pressing this option will made one dialog appear where the user can choose the two agents that will interact. The tool will automatically generate the left hand side of the rule. Also
+is possible to choose what is generated in the right hand side of such rule:
+<ul>
+<li> a copy of the left hand side to be manually edited after (usefull for rules it similar sides)
+<li> just copy the interface agents from left to right hand sides
+<li> generate a blank right hand side (not recommended)
+</ul>
+<li> Match inteface agents in a rule by selecting the desirable interface agent in the left hand side and SHIFT-clicking the corresponding interface agent in the right hand side. A box with the same number will appear in both agents.
+</ul>
+<a href="index.html">back to main page</a>
+</body>
+</html>
hunk ./src/NetworkUI.hs 356
+ -- Help menu
+ ; helpMenu <- menuPane [ text := "&Help" ]
+ ; menuItem helpMenu [_$_]
+ [ text := "How to use?"
+ , on command := createHelpWindow [_$_]
+ ]
+ ; menuItem helpMenu [_$_]
+ [ text := "About"
+ , on command := createAboutWindow theFrame
+ ]
+
hunk ./src/NetworkUI.hs 404
- [ menuBar := [ fileMenu, editMenu, viewMenu, opsMenu, palMenu ]
+ [ menuBar := [ fileMenu, editMenu, viewMenu, opsMenu, palMenu, helpMenu ]
hunk ./src/NetworkUI.hs 1243
+
+createHelpWindow :: IO () [_$_]
+createHelpWindow =
+ do f <- frame [ text := "Interaction Nets editor help"
+ , position := pt 200 20
+ , clientSize := sz 300 240 ]
+
+ hw <- htmlWindowCreate f 1 (Rect 50 150 500 150) 5 "theWindow"
+ htmlWindowLoadPage hw "html/HowToUse.html"
+ set f [layout := fill $ widget hw]
+
+createAboutWindow :: Frame () -> IO ()
+createAboutWindow f = [_$_]
+ do infoDialog f ("About " ++ toolName) $ [_$_]
+ toolName ++ " is an Interaction Nets Editor.\n"
+ ++ "The project is mainly developed by\n"
+ ++ "Miguel Vilaca < " ++ "jmvilaca@di.uminho.pt" ++" >\n" [_$_]
+ ++ "See the project webpage at\n"
+ ++ "http://haskell.di.uminho.pt/jmvilaca/INblobs"
+
}