diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 1998-12-29 14:21:17 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 1998-12-29 14:21:17 +0000 |
| commit | 87dd7f0d23eba5c09e71ec6efeb34c6844f5e95f (patch) | |
| tree | ecd25b3fbecdd2d1c6abf106d0c94ac2b1e9926e /documentation/Fl_Menu_Bar.html | |
| parent | 20adb6834b22523e9d1fecdb7bb8a117f7b6179a (diff) | |
Revised documentation files.
git-svn-id: file:///fltk/svn/fltk/trunk@177 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'documentation/Fl_Menu_Bar.html')
| -rw-r--r-- | documentation/Fl_Menu_Bar.html | 85 |
1 files changed, 85 insertions, 0 deletions
diff --git a/documentation/Fl_Menu_Bar.html b/documentation/Fl_Menu_Bar.html new file mode 100644 index 000000000..d8ff312cf --- /dev/null +++ b/documentation/Fl_Menu_Bar.html @@ -0,0 +1,85 @@ +<html> +<body> + +<hr break> + +<h2><a name="Fl_Menu_Bar">class Fl_Menu_Bar</a></h2> + +<hr> + +<h3>Class Hierarchy</h3> + +<ul><pre> +<a href="#Fl_Menu_">Fl_Menu_</a> + | + +----<b>Fl_Menu_Bar</b> +</pre></ul> + +<h3>Include Files</h3> + +<ul><pre> +#include <FL/Fl_Menu_Bar.H> +</pre></ul> + +<h3>Description</h3> + +This widget provides a standard menubar interface. Usually you will +put this widget along the top edge of your window. The height of the +widget should be 30 for the menu titles to draw correctly with the default +font. + +<p>The items on the bar and the menus they bring up are defined by a +single <a href="#Fl_Menu_Item"><tt>Fl_Menu_Item</tt></a> array. Because a +<tt>Fl_Menu_Item</tt> array defines a hierarchy, the top level menu defines the +items in the menubar, while the submenus define the pull-down menus. +Sub-sub menus and lower pop up to the right of the submenus. + +<p><img src=menubar.gif> + +<P>If there is an item in the top menu that is not a title of a +submenu, then it acts like a "button" in the menubar. Clicking on +it will pick it. + +<P>When the user picks an item off the menu, the item's callback is +done with the menubar as the <tt>Fl_Widget*</tt> argument. If the item +does not have a callback the menubar's callback is done instead. + +<p>Submenus will also pop up in response to shortcuts indicated by +putting a '&' character in the name field of the menu item. If you +put a '&' character in a top-level "button" then the shortcut picks +it. The '&' character in submenus is ignored until the menu is popped +up. + +<p>Typing the <tt>shortcut()</tt> of any of the menu items will cause callbacks +exactly the same as when you pick the item with the mouse. + +<h3>Methods</h3> + +<ul> + <li><a href="#Fl_Menu_Bar.Fl_Menu_Bar">Fl_Menu_Bar</a> + <li><a href="#Fl_Menu_Bar.~Fl_Menu_Bar">~Fl_Menu_Bar</a> +</ul> + +<h4><a name="Fl_Menu_Bar.Fl_Menu_Bar">Fl_Menu_Bar::Fl_Menu_Bar(int x, int y, int w, int h, const char *label = 0)</a></h4> + +Creates a new <tt>Fl_Menu_Bar</tt> widget using the given position, size, and +label string. The default boxtype is <tt>FL_UP_BOX</tt>. + +<p>The constructor sets <tt>menu()</tt> to <tt>NULL</tt>. See <a +href="#Fl_Menu_"><tt>Fl_Menu_</tt></a> for the methods to set or change +the menu. + +<P><tt>labelsize()</tt>, <tt>labelfont()</tt>, and +<tt>labelcolor()</tt> are used to control how the menubar items are +drawn. They are initialized from the <tt>Fl_Menu</tt> static +variables, but you can change them if desired. + +<p><tt>label()</tt> is ignored unless you change <tt>align()</tt> to +put it outside the menubar. + +<h4><a name="Fl_Menu_Bar.~Fl_Menu_Bar">virtual Fl_Menu_Bar::~Fl_Menu_Bar()</a></h4> + +The destructor removes the <tt>Fl_Menu_Bar</tt> widget and all of its menu items. + +</body> +</html> |
