First checkin, AXE release 0.2
[AXE.git] / doc / button.html
1 <HTML>
2 <HEAD>
3 <TITLE>button - ANDROMEDA X-windows Encapsulation</TITLE>
4 <!--Created by Applixware HTML Authoring System, Release 4.3 on Sat Aug  8 17:05:23 1998-->
5 </HEAD>
6 <BODY BGCOLOR="#ff7b00">
7 <H1>class button</H1>
8 <HR>
9 <H2>NAME</H2>
10 <P>button - Base class for clickable buttons</P>
11 <H2>SYNOPSIS</H2>
12 <P>class button : public frame</P>
13 <H2>DESCRIPTION</H2>
14 <P>A button adds input actions to a frame. When a button contains a label, it
15 will center the label's text in its window. An extra indicator (like a LED)
16 may also be included in a button. When clicked with the left mouse button, the
17 button performs some action. At least, it provides visible feedback to the
18 user. When a mouse button is pressed on a button, its 3D effect is reversed.
19 When the mouse button is released, the 3D effect returns to its original
20 state. Further actions depends on the type of button.</P>
21 <P>Variaties of buttons:</P>
22 <UL>
23 <LI>touch button: performs an action, immediately when it is pressed. A
24 release has no effect. The action of a touch button should not remove the
25 button from the screen. If it does, the release event will be sent to an other window.
26 <P>A touch button has a virtual function: click(). This function is called on
27 a ButtonPress event.</P>
28 <LI>command button: send a command to the application when clicked. It
29 perfroms its action when pressed AND released.
30 <LI>toggle button: toggles on or off when clicked. It adds a state and an
31 indicator to the touch button. The state of the toggle button reverses when
32 pressed. The indicator shows the current state.
33 <P>A toggle button overrides the touch button's function click() and overrides
34 the frame's virtual function redraw(). click() reverses the state of the
35 button. redraw() draws the indicator, which depends on the state.</P>
36 <LI>radio button: when pressed, turns itself on and its sibling buttons off.
37 The indicator shows the state of the radio button. The parent window of a
38 group of radio buttons can determine the index of the radio button that is 'On'.
39 </UL>
40 <H2>SEE ALSO</H2>
41 <H2>DIAGNOSTICS</H2>
42 </BODY>
43 </HTML>