diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 1999-01-13 19:28:54 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 1999-01-13 19:28:54 +0000 |
| commit | d7b88a3bcc7e76f38ee5799be7722fd5a10781ef (patch) | |
| tree | d8984d45424c9b2cdb199c1918f38bfea4a8211d /documentation/Fl_Menu_Button.html | |
| parent | 30fa233681467b82b165e7d42cd0bea778b93768 (diff) | |
Updated all links so they work between files.
Revision 1.
git-svn-id: file:///fltk/svn/fltk/trunk@219 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'documentation/Fl_Menu_Button.html')
| -rw-r--r-- | documentation/Fl_Menu_Button.html | 176 |
1 files changed, 77 insertions, 99 deletions
diff --git a/documentation/Fl_Menu_Button.html b/documentation/Fl_Menu_Button.html index 43bd2d6a6..f3b7eaac0 100644 --- a/documentation/Fl_Menu_Button.html +++ b/documentation/Fl_Menu_Button.html @@ -1,101 +1,79 @@ -<html> -<body> - -<hr break> - -<h2><a name="Fl_Menu_Button">class Fl_Menu_Button</a></h2> - -<hr> - -<h3>Class Hierarchy</h3> - -<ul><pre> -<a href="#Fl_Menu_">Fl_Menu_</a> +<HTML><BODY> +<HR break> +<H2><A name=Fl_Menu_Button>class Fl_Menu_Button</A></H2> +<HR> +<H3>Class Hierarchy</H3> +<UL> +<PRE> +<A href=Fl_Menu_.html#Fl_Menu_>Fl_Menu_</A> | - +----<b>Fl_Menu_Button</b> -</pre></ul> - -<h3>Include Files</h3> - -<ul><pre> -#include <FL/Fl_Menu_Button.H> -</pre></ul> - -<h3>Description</h3> - -This is a button that when pushed pops up a menu (or hierarchy of -menus) defined by an array of <a href="#Fl_Menu_Item"><tt>Fl_Menu_Item</tt></a> -objects. - -<P><img src=menu_button.gif> - -<p>Normally any mouse button will pop up a menu and it is lined up -below the button as shown in the picture. However an <tt>Fl_Menu_Button</tt> -may also control a pop-up menu. This is done by setting the -<tt>type()</tt>, -see below. - -<p>The menu will also pop up in response to shortcuts indicated by -putting a '&' character in the <tt>label()</tt>. - -<p>Typing the <tt>shortcut()</tt> of any of the menu items will cause + +----<B>Fl_Menu_Button</B> +</PRE> +</UL> +<H3>Include Files</H3> +<UL> +<PRE> +#include <FL/Fl_Menu_Button.H> +</PRE> +</UL> +<H3>Description</H3> + This is a button that when pushed pops up a menu (or hierarchy of +menus) defined by an array of <A href=Fl_Menu_Item.html#Fl_Menu_Item><TT> +Fl_Menu_Item</TT></A> objects. +<P><IMG src=./menu_button.gif></P> +<P>Normally any mouse button will pop up a menu and it is lined up +below the button as shown in the picture. However an <TT>Fl_Menu_Button</TT> + may also control a pop-up menu. This is done by setting the <TT>type()</TT> +, see below. </P> +<P>The menu will also pop up in response to shortcuts indicated by +putting a ''character in the <TT>label()</TT>. </P> +<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. -The '&' character in menu item names are only looked at when the menu -is popped up, however. - -<P>When the user picks an item off the menu, the item's callback is -done with the menu_button as the <tt>Fl_Widget*</tt> argument. If the item -does not have a callback the menu_button's callback is done instead. - -<h3>Methods</h3> - -<ul> - <li><a href="#Fl_Menu_Button.Fl_Menu_Button">Fl_Menu_Button</a> - <li><a href="#Fl_Menu_Button.~Fl_Menu_Button">~Fl_Menu_Button</a> - <li><a href="#Fl_Menu_Button.popup">popup</a> - <li><a href="#Fl_Menu_Button.type">type</a> -</ul> - -<h4><a name="Fl_Menu_Button.Fl_Menu_Button">Fl_Menu_Button::Fl_Menu_Button(int x, int y, int w, int h, const char *label = 0)</a></h4> - -Creates a new <tt>Fl_Menu_Button</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. - -<h4><a name="Fl_Menu_Button.~Fl_Menu_Button">virtual Fl_Menu_Button::~Fl_Menu_Button()</a></h4> - -The destructor removes the <tt>Fl_Menu_Button</tt> widget and all of its menu items. - -<h4><a name="Fl_Menu_Button.popup">const Fl_Menu* Fl_Menu_Button::popup()</a></h4> - -Act exactly as though the user clicked the button or typed the shortcut -key. The menu appears, it waits for the user to pick an item, and if -they pick one it sets <tt>value()</tt> and does the callback or sets -<tt>changed()</tt> as described above. The menu item is returned or -<tt>NULL<tt> if the user dismisses the menu. - -<h4><a name="Fl_Menu_Button.type">void Fl_Widget::type(uchar)</a></h4> - -If <tt>type()</tt> is zero a normal menu button is produced. If it is -nonzero then this is a pop-up menu. The bits in <tt>type()</tt> -indicate what mouse buttons pop up the menu. For convienece the -constants <tt>Fl_Menu_Button::POPUP1, POPUP2, POPUP3, POPUP12, POPUP13, -POPUP23</tt>, and <tt>POPUP123</tt> are defined. -<tt>Fl_Menu_Button::POPUP3</tt> is usually what you want. - -<p>A popup menu button is invisible and does not interfere with any -events other than the mouse button specified (and any shortcuts). The -widget can be stretched to cover all your other widgets by putting it last -in the hierarchy so it is "on top". You can also make several widgets -covering different areas for context-sensitive popup menus. - -<p>The popup menus appear with the cursor pointing at the previously -selected item. This is a <i>feature</i>. If you don't like it, do -<tt>value(0)</tt> after the menu items are picked to forget the current -item. - -</body> -</html> + The ''character in menu item names are only looked at when the menu is +popped up, however. </P> +<P>When the user picks an item off the menu, the item's callback is +done with the menu_button as the <TT>Fl_Widget*</TT> argument. If the +item does not have a callback the menu_button's callback is done +instead. </P> +<H3>Methods</H3> +<UL> +<LI><A href=#Fl_Menu_Button.Fl_Menu_Button>Fl_Menu_Button</A></LI> +<LI><A href=#Fl_Menu_Button.~Fl_Menu_Button>~Fl_Menu_Button</A></LI> +<LI><A href=#Fl_Menu_Button.popup>popup</A></LI> +<LI><A href=#Fl_Menu_Button.type>type</A></LI> +</UL> +<H4><A name=Fl_Menu_Button.Fl_Menu_Button> +Fl_Menu_Button::Fl_Menu_Button(int x, int y, int w, int h, const char +*label = 0)</A></H4> + Creates a new <TT>Fl_Menu_Button</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_.html#Fl_Menu_> +<TT>Fl_Menu_</TT></A> for the methods to set or change the menu. </P> +<H4><A name=Fl_Menu_Button.~Fl_Menu_Button>virtual +Fl_Menu_Button::~Fl_Menu_Button()</A></H4> + The destructor removes the <TT>Fl_Menu_Button</TT> widget and all of +its menu items. +<H4><A name=Fl_Menu_Button.popup>const Fl_Menu* Fl_Menu_Button::popup()</A> +</H4> + Act exactly as though the user clicked the button or typed the +shortcut key. The menu appears, it waits for the user to pick an item, +and if they pick one it sets <TT>value()</TT> and does the callback or +sets <TT>changed()</TT> as described above. The menu item is returned +or <TT>NULL<TT>if the user dismisses the menu. +<H4><A name=Fl_Menu_Button.type>void Fl_Widget::type(uchar)</A></H4> + If <TT>type()</TT> is zero a normal menu button is produced. If it is +nonzero then this is a pop-up menu. The bits in <TT>type()</TT> + indicate what mouse buttons pop up the menu. For convienece the +constants <TT>Fl_Menu_Button::POPUP1, POPUP2, POPUP3, POPUP12, POPUP13, +POPUP23</TT>, and <TT>POPUP123</TT> are defined. <TT> +Fl_Menu_Button::POPUP3</TT> is usually what you want. +<P>A popup menu button is invisible and does not interfere with any +events other than the mouse button specified (and any shortcuts). The +widget can be stretched to cover all your other widgets by putting it +last in the hierarchy so it is "on top". You can also make several +widgets covering different areas for context-sensitive popup menus. </P> +<P>The popup menus appear with the cursor pointing at the previously +selected item. This is a <I>feature</I>. If you don't like it, do <TT> +value(0)</TT> after the menu items are picked to forget the current +item. </P> +</TT></TT></BODY></HTML>
\ No newline at end of file |
