Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 


Quelle  chap7.html   Sprache: HTML

 
 products/sources/formale Sprachen/GAP/pkg/francy/doc/chap7.html


<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
         "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>GAP (Francy) - Chapter 7: Francy Menus</title>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<meta name="generator" content="GAPDoc2HTML" />
<link rel="stylesheet" type="text/css" href="manual.css" />
<script src="manual.js" type="text/javascript"></script>
<script type="text/javascript">overwriteStyle();</script>
</head>
<body class="chap7"  onload="jscontent()">


<div class="chlinktop"><span class="chlink1">Goto Chapter: </span><a href="chap0.html">Top</a>  <a href="chap1.html">1</a>  <a href="chap2.html">2</a>  <a href="chap3.html">3</a>  <a href="chap4.html">4</a>  <a href="chap5.html">5</a>  <a href="chap6.html">6</a>  <a href="chap7.html">7</a>  <a href="chap8.html">8</a>  <a href="chap9.html">9</a>  <a href="chap10.html">10</a>  <a href="chapInd.html">Ind</a>  </div>

<div class="chlinkprevnexttop"> <a href="chap0.html">[Top of Book]</a>   <a href="chap0.html#contents">[Contents]</a>    <a href="chap6.html">[Previous Chapter]</a>    <a href="chap8.html">[Next Chapter]</a>   </div>

<p id="mathjaxlink" class="pcenter"><a href="chap7_mj.html">[MathJax on]</a></p>
<p><a id="X80EA9773809C0D61" name="X80EA9773809C0D61"></a></p>
<div class="ChapSects"><a href="chap7.html#X80EA9773809C0D61">7 <span class="Heading">Francy Menus</span></a>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap7.html#X7CC6903E78F24167">7.1 <span class="Heading">Categories</span></a>
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap7.html#X7D4F62FC7EE7D6CA">7.1-1 IsMenu</a></span>
</div></div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap7.html#X846063757EC05986">7.2 <span class="Heading">Families</span></a>
</span>
</div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap7.html#X7EABCC537D3BC549">7.3 <span class="Heading">Representations</span></a>
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap7.html#X78011B0D79E0AC29">7.3-1 IsMenuRep</a></span>
</div></div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap7.html#X7DE8E16C7C2D387B">7.4 <span class="Heading">Operations</span></a>
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap7.html#X80A4CF8778846969">7.4-1 Menu</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap7.html#X7EDDF1E97C71181B">7.4-2 Add</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap7.html#X874B7A668558AFB5">7.4-3 Remove</a></span>
</div></div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap7.html#X7C701DBF7BAE649A">7.5 <span class="Heading">Attributes</span></a>
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap7.html#X7BBE816B7B22D645">7.5-1 Title</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap7.html#X7BBE816B7B22D645">7.5-2 Title</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap7.html#X792C89BE80A7DA6E">7.5-3 SetTitle</a></span>
</div></div>
</div>

<h3>7 <span class="Heading">Francy Menus</span></h3>

<p>Menus are lists of actions that are rendered on the GUI. Menus can have SubMenus, and are constituted by a label Title and an action defined as a <code class="code">Callback</code>.</p>

<p>Please see Francy-JS for client implementation.</p>

<p><a id="X7CC6903E78F24167" name="X7CC6903E78F24167"></a></p>

<h4>7.1 <span class="Heading">Categories</span></h4>

<p>In this section we show all Francy Menu Categories.</p>

<p><a id="X7D4F62FC7EE7D6CA" name="X7D4F62FC7EE7D6CA"></a></p>

<h5>7.1-1 IsMenu</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ IsMenu</code>( <var class="Arg">arg</var> )</td><td class="tdright">( filter )</td></tr></table></div>
<p>Returns: <code class="keyw">true</code> or <code class="keyw">false</code></p>

<p>Identifies <code class="code">Menu</code> objects.</p>

<p><a id="X846063757EC05986" name="X846063757EC05986"></a></p>

<h4>7.2 <span class="Heading">Families</span></h4>

<p>In this section we show all Francy Menu Families.</p>

<p><a id="X7EABCC537D3BC549" name="X7EABCC537D3BC549"></a></p>

<h4>7.3 <span class="Heading">Representations</span></h4>

<p>In this section we show all Francy Menu Representations.</p>

<p><a id="X78011B0D79E0AC29" name="X78011B0D79E0AC29"></a></p>

<h5>7.3-1 IsMenuRep</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ IsMenuRep</code>( <var class="Arg">arg</var> )</td><td class="tdright">( filter )</td></tr></table></div>
<p>Returns: <code class="keyw">true</code> or <code class="keyw">false</code></p>

<p>Checks whether an <code class="code">Object</code> has a <code class="code">Menu</code> internal representation.</p>

<p><a id="X7DE8E16C7C2D387B" name="X7DE8E16C7C2D387B"></a></p>

<h4>7.4 <span class="Heading">Operations</span></h4>

<p>In this section we show all Francy Menu Operations.</p>

<p><a id="X80A4CF8778846969" name="X80A4CF8778846969"></a></p>

<h5>7.4-1 Menu</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ Menu</code>( <var class="Arg">IsString(title)</var>[, <var class="Arg">IsCallback</var>] )</td><td class="tdright">( operation )</td></tr></table></div>
<p>Returns: <code class="code">Menu</code></p>

<p>Creates a Menu with a label title and an action <code class="code">Callback</code>. Is up to the client implementation to sort out the Menu and invoke the <code class="code">Callback</code>. Examples:</p>

<p>Create a <code class="code">FrancyMenu</code>:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">canvas := Canvas("Callbacks in action");</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">SetHeight(canvas, 100);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">graph := Graph(GraphType.HASSE);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">shape := Shape(ShapeType.CIRCLE);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Add(graph, shape);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Add(canvas, graph);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">HelloWorld := function(name)</span>
<span class="GAPprompt">></span> <span class="GAPinput">    Add(canvas, FrancyMessage(Concatenation("Hello, ", name)));</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">    return Draw(canvas);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">end;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">callback1 := Callback(HelloWorld);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">arg1 := RequiredArg(ArgType.STRING, "Your Name?");</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Add(callback1, arg1);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">menu := Menu("Example Menu Holder");</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">menu1 := Menu("Hello Menu Action", callback1 );</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">menu2 := Menu("Hello Menu Action", callback1 );</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Add(menu, menu1);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Remove(menu, menu1);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Add(menu, [menu1, menu2]);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Remove(menu, [menu1, menu2]);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Add(canvas, [menu, menu1]);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Remove(canvas, menu1);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Add(canvas, menu1);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Add(shape, menu1);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Remove(shape, menu1);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Add(shape, [menu1, menu2]);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">Remove(shape, [menu1, menu2]);</span>
</pre></div>

<p><a id="X7EDDF1E97C71181B" name="X7EDDF1E97C71181B"></a></p>

<h5>7.4-2 Add</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ Add</code>( <var class="Arg">IsMenu</var>[, <var class="Arg">IsMenu</var>, <var class="Arg">List(IsMenu)</var>] )</td><td class="tdright">( operation )</td></tr></table></div>
<p>Returns: <code class="code">Menu</code></p>

<p>Add one <code class="code">Menu</code> to a specific <code class="code">Menu</code> creating a Submenu. Is up to the client implementation to handle this.</p>

<p><a id="X874B7A668558AFB5" name="X874B7A668558AFB5"></a></p>

<h5>7.4-3 Remove</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ Remove</code>( <var class="Arg">IsMenu</var>[, <var class="Arg">IsMenu</var>, <var class="Arg">List(IsMenu)</var>] )</td><td class="tdright">( operation )</td></tr></table></div>
<p>Returns: <code class="code">Menu</code></p>

<p>Remove a <code class="code">Menu</code> from a specific <code class="code">Menu</code>. Is up to the client implementation to handle this.</p>

<p><a id="X7C701DBF7BAE649A" name="X7C701DBF7BAE649A"></a></p>

<h4>7.5 <span class="Heading">Attributes</span></h4>

<p>In this section we show all Francy Core Attributes</p>

<p><a id="X7BBE816B7B22D645" name="X7BBE816B7B22D645"></a></p>

<h5>7.5-1 Title</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ Title</code>( <var class="Arg">arg</var> )</td><td class="tdright">( attribute )</td></tr></table></div>
<p>Returns: <code class="code">IsString</code> with the title of the object</p>

<p>A label title on a <code class="code">Menu</code> is used to identify what action it is about on a menu entry.</p>

<p><a id="X7BBE816B7B22D645" name="X7BBE816B7B22D645"></a></p>

<h5>7.5-2 Title</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ Title</code>( <var class="Arg">arg1</var> )</td><td class="tdright">( operation )</td></tr></table></div>
<p><a id="X792C89BE80A7DA6E" name="X792C89BE80A7DA6E"></a></p>

<h5>7.5-3 SetTitle</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ SetTitle</code>( <var class="Arg">IsMenu</var>, <var class="Arg">IsString</var> )</td><td class="tdright">( operation )</td></tr></table></div>
<p>Sets the title of the <code class="code">Menu</code>.</p>


<div class="chlinkprevnextbot"> <a href="chap0.html">[Top of Book]</a>   <a href="chap0.html#contents">[Contents]</a>    <a href="chap6.html">[Previous Chapter]</a>    <a href="chap8.html">[Next Chapter]</a>   </div>


<div class="chlinkbot"><span class="chlink1">Goto Chapter: </span><a href="chap0.html">Top</a>  <a href="chap1.html">1</a>  <a href="chap2.html">2</a>  <a href="chap3.html">3</a>  <a href="chap4.html">4</a>  <a href="chap5.html">5</a>  <a href="chap6.html">6</a>  <a href="chap7.html">7</a>  <a href="chap8.html">8</a>  <a href="chap9.html">9</a>  <a href="chap10.html">10</a>  <a href="chapInd.html">Ind</a>  </div>

<hr />
<p class="foot">generated by <a href="http://www.math.rwth-aachen.de/~Frank.Luebeck/GAPDoc">GAPDoc2HTML</a></p>
</body>
</html>

100%


¤ Dauer der Verarbeitung: 0.15 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung ist noch experimentell.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....

Besucherstatistik

Besucherstatistik

Monitoring

Montastic status badge