Symbian3/SDK/Source/GUID-F3EE1000-71A6-4D48-A30B-3D2357BF20FB.dita
changeset 7 51a74ef9ed63
child 8 ae94777fff8f
equal deleted inserted replaced
6:43e37759235e 7:51a74ef9ed63
       
     1 <?xml version="1.0" encoding="utf-8"?>
       
     2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
       
     3 <!-- This component and the accompanying materials are made available under the terms of the License 
       
     4 "Eclipse Public License v1.0" which accompanies this distribution, 
       
     5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
       
     6 <!-- Initial Contributors:
       
     7     Nokia Corporation - initial contribution.
       
     8 Contributors: 
       
     9 -->
       
    10 <!DOCTYPE concept
       
    11   PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
       
    12 <concept id="GUID-F3EE1000-71A6-4D48-A30B-3D2357BF20FB" xml:lang="en"><title>Generic
       
    13 button API</title><shortdesc>The Generic button API is used for enabling touch support for buttons.</shortdesc><prolog><metadata><keywords/></metadata></prolog><conbody>
       
    14 <p>An Avkon button is a generic button component specifically designed for
       
    15 touch support. The generic button component (<xref href="jar:GUID-759FBC7F-5384-4487-8457-A8D4B76F6AA6.jar!/html/classCAknButton.html" format="application/java-archive"><codeph>CAknButton</codeph></xref>, defined in <codeph>aknbutton.h</codeph>) is used, for example, in
       
    16 a toolbar and a status pane. The button can contain text, an image, or both. </p>
       
    17 <p>Buttons can have multiple states, and each of the states can have three
       
    18 different states according to user actions. The possible user-action states
       
    19 for the button states are:</p>
       
    20 <ul>
       
    21 <li><p>Normal</p></li>
       
    22 <li><p>Pressed down</p></li>
       
    23 <li><p>Dimmed</p></li>
       
    24 </ul>
       
    25 <p>By default, the button has a frame, it responds to tap (press) event, has
       
    26 a latchable view in the pressed-down state, and has horizontally and vertically
       
    27 aligned text in it. Some default behavior can be changed with button flags
       
    28 or with the help of member functions. </p>
       
    29 <p>To observe the buttons in your application, use the <codeph>MCoeControlObserver</codeph> observer
       
    30 interface.</p>
       
    31 <fig id="GUID-EEC0C576-8EEC-481E-817F-6E137E4F6A7D">
       
    32 <title>Generic button used in a toolbar</title>
       
    33 <image href="GUID-ED823C5E-A59B-476A-BF88-0FCBA5D35FED_d0e77324_href.png" scale="50" placement="inline"/>
       
    34 </fig>
       
    35 <note><p> The Generic button API is used for creating buttons that are displayed
       
    36 as parts of container components, such as a toolbar. It is not used for creating
       
    37 CBA buttons displayed in the control pane at the bottom of the device screen.
       
    38 The API for creating CBA buttons is the <xref format="html" href="specs/guides/Buttons_API_Specification/Buttons_API_Specification.html" scope="peer">Buttons API</xref>.</p></note>
       
    39 <p>For look and feel guidelines on the generic button component as part of
       
    40 a toolbar, see the <xref href="GUID-EB212C35-5416-4CA7-8091-61B45D78E220.dita">toolbar
       
    41 UI component description</xref>.</p>
       
    42 <p>For information on using the API, see <xref href="GUID-97712509-84AD-462F-8FFB-E1E6D8278938.dita">Enabling
       
    43 touch support for buttons</xref>.</p>
       
    44 <p>For the Generic button API classes and header files, see Classes and Definitions.</p>
       
    45 <section id="GUID-3334EF0D-D9BF-468D-B218-27FA9A2492AC"><title>Constraints</title><p>This
       
    46 API is valid for all platforms running on Symbian OS v9.3 or later.</p></section>
       
    47 <section id="GUID-EA74FA6F-FA20-47D7-99F2-9A98A4F24CF1"><title>Emulator support</title><p>This
       
    48 API is supported in the WINS/WINSCW emulator environment, with the following
       
    49 exception:</p><ul>
       
    50 <li><p>Tactile feedback is not supported.</p></li>
       
    51 </ul></section>
       
    52 </conbody><related-links>
       
    53 <linklist><title>Related APIs</title>
       
    54 <link format="html" href="specs/guides/Skins_API_Specification/Skins_API_Specification.html" scope="peer"><linktext>Skins API</linktext>
       
    55 <desc> for adding skin support to the button</desc>
       
    56 </link>
       
    57 <link href="GUID-B05B61B8-1217-441F-BAFA-C209C8F123C5.dita"><linktext>Toolbar API</linktext>
       
    58 <desc> for creating a toolbar containing generic buttons</desc>
       
    59 </link>
       
    60 <link href="GUID-92018B6B-3CBB-434D-9E61-F271C67E98E3.dita"><linktext>Touch UI
       
    61 utilities API</linktext>
       
    62 <desc> for using long-tap events</desc>
       
    63 </link>
       
    64 </linklist>
       
    65 </related-links></concept>