- From: poot <cvsmail@w3.org>
- Date: Mon, 17 Aug 2009 19:28:49 +0900 (JST)
- To: public-html-diffs@w3.org
hixie: Add a half-baked intro for <menu>. (whatwg r3646) http://dev.w3.org/cvsweb/html5/spec/Overview.html?r1=1.2831&r2=1.2832&f=h http://html5.org/tools/web-apps-tracker?from=3645&to=3646 =================================================================== RCS file: /sources/public/html5/spec/Overview.html,v retrieving revision 1.2831 retrieving revision 1.2832 diff -u -d -r1.2831 -r1.2832 --- Overview.html 17 Aug 2009 09:47:29 -0000 1.2831 +++ Overview.html 17 Aug 2009 10:28:25 -0000 1.2832 @@ -36016,10 +36016,10 @@ <a href="#reflect">reflect</a> the respective content attributes of the same name.</p> - </div><h5 id="menus-intro"><span class="secno">4.11.3.1 </span>Introduction</h5><p><i>This section is non-normative.</i><p class="XXX">...</p><!-- - - - <pre><menu type="commands"> + </div><h5 id="menus-intro"><span class="secno">4.11.3.1 </span>Introduction</h5><p><i>This section is non-normative.</i><p>The <code><a href="#menus">menu</a></code> element is used to define context menus and + tool bars.<p>For example, the following represents a toolbar with three menu + buttons on it, each of which has a dropdown menu with a series of + options:<pre><menu type="toolbar"> <li> <menu label="File"> <button type="button" onclick="fnew()">New...</button> @@ -36041,23 +36041,12 @@ <li><a href="about.html">About</a></li> </menu> </li> -</menu> - -... - -<input command="save"/> <!- - This will act exactly like the - Save button above, including reflecting - its <code>disabled</code> state dynamically - -> - -</pre> - - <p>Here's some markup that falls back on the traditional abuse of - the <code>select</code> element as a navigation menu, but which is - implemented as a semi-correct menu using the new techniques of this - document:</p> - -<pre><form action="redirect.cgi"> - <menu type="commands"> +</menu></pre><p>In a supporting user agent, this might look like this:<p><img alt="A toolbar with three buttons, labeled 'File', 'Edit', and 'Help'; where if you select the 'Edit' button you get a drop-down menu with three more options, 'Copy', 'Cut', and 'Paste'." src="images/sample-toolbar-1.png"><p>In a legacy user agent, the above would look like a bulleted list + with three items, the first of which has four buttons, the second of + which has three, and the third of which has two nested bullet points + with two items consisting of links.<hr><p>The following implements a similar toolbar, with a single button + whose values, when selected, redirect the user to Web sites.<pre><form action="redirect.cgi"> + <menu type="toolbar"> <label for="goto">Go to...</label> <menu label="Go"> <select id="goto" @@ -36071,46 +36060,12 @@ <span><input type="submit" value="Go"></span> </menu> </menu> -</form></pre> - -<form ...> - <menu type="toolbar"> - <li> - <select name="foo" onchange="form.submit()"> - ... - </select> - <button>Go</button> - </li> - <li> - <select name="bar" onchange="form.submit()"> - ... - </select> - <button>Go</button> - </li> - </menu> -</form> - -<form ...> - <menu type="toolbar"> - <menu label="Foo"> - <select name="foo" onchange="form.submit()"> - ... - </select> - <button>Go</button> - </menu> - <menu label="Bar"> - <select name="bar" onchange="form.submit()"> - ... - </select> - <button>Go</button> - </menu> - </menu> -</form> - - -explain that only direct children of the <menu> matter - ---><div class="impl"> +</form></pre><p>The behavior in supporting user agents is similar to the example + above, but here the legacy behaviour consists of a single + <code><a href="#the-select-element">select</a></code> element with a submit button. The submit button + doesn't appear in the toolbar, because it is not a direct child of + the <code><a href="#menus">menu</a></code> element or of its <code><a href="#the-li-element">li</a></code> + children.<div class="impl"> <h5 id="building-menus-and-tool-bars"><span class="secno">4.11.3.2 </span><dfn>Building menus and tool bars</dfn></h5>
Received on Monday, 17 August 2009 10:29:28 UTC