Addition of the PDK content and example code for Documentation_content according to Feature bug 1607 and bug 1608
<?xml version="1.0" encoding="utf-8"?><!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. --><!-- This component and the accompanying materials are made available under the terms of the License "Eclipse Public License v1.0" which accompanies this distribution, and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". --><!-- Initial Contributors: Nokia Corporation - initial contribution.Contributors: --> <!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd"><concept id="GUID-11C24609-3B6D-4B44-B003-FB0C07444A9E" xml:lang="en"><title>Scrollpane</title><prolog><metadata><keywords></keywords></metadata></prolog><conbody><p>With any list, grid or other component that can be scrolled vertically,a scrollbar appears on the right-hand side of the component. The scrollbaris displayed also on pop-up components.</p><fig id="GUID-BD8A5FCD-048E-41AF-BA17-A38B689141D9"><title>Scroll pane with scrollbar</title><image href="GUID-F8A7F4CB-011C-425D-83B4-13BD67AA21B7_d0e78907_href.png" scale="33" placement="inline"></image></fig><ul><li><p>The placement of the scroll handle on the scrollbar reflects the positionof the focus on the scrolling content.</p></li><li><p>The size of the scroll handle reflects the number of displayed itemsrelative to the total number of items on the scrolled component.</p></li><li><p>The scrollbar is displayed even when all items on the component canbe displayed in the same view without scrolling. When this is the case, thescroll handle is displayed at the maximum size. The only exception is theApplication Shell, where scrollbar is not displayed if all items fit the sameview.</p></li></ul><section id="GUID-054FE843-7681-40D9-ACA7-47122BC3107B"><title>Scrollbarsin Touch UI</title><p>In touch devices based on the Symbian platform,scrollbars (vertical and horizontal) have a touch-enabled scroll box. Thehardware keys (Arrow keys) can also be used for scrolling when the scrollbarsare visible. The scrolling movement on the screen is smooth.</p><p>In orderfor the scrollbar to be more usable with touch, the actual scrollbar areais wider than the visible scrollbar. When the user scrolls, the scrollbarhas a related effect to indicate the scrolling. Because the actual area ofscrollbar is wider, the items appearing on that area in scrollable list, grids,viewers etc. cannot be touch-enabled, e.g. list icons in column D cannot betapped.</p></section><section id="GUID-87093F25-CFC3-4D71-A5EF-006C6425C65D"><title>Usingscrollbars in C++ applications</title><p>The API to use for creating the scrollbarcomponent is the ScrollerAPI.</p><p>To use a scrollbar in your application, first create a scrollbarframe using the class <xref href="jar:GUID-759FBC7F-5384-4487-8457-A8D4B76F6AA6.jar!/html/classCEikScrollBarFrame.html" format="application/java-archive"><codeph>CEikScrollbarFrame</codeph></xref>. All scrollbar operations are executed via this scrollbar frame.These operations include creating and destroying the scrollbar, setting itsvisibility, and adjusting the scrollbar's model. The scrollbar itself canbe created using the method <xref href="jar:GUID-759FBC7F-5384-4487-8457-A8D4B76F6AA6.jar!/html/classCEikScrollBarFrame.html#81980f8db36253fc89fb7ebbfa316b4d" format="application/java-archive"><codeph>CreateDoubleSpanScrollBarsL()</codeph></xref> in the class <codeph>CEikScrollBarFrame</codeph>.The class for the scrollbar is <xref href="jar:GUID-759FBC7F-5384-4487-8457-A8D4B76F6AA6.jar!/html/classCAknDoubleSpanScrollBar.html" format="application/java-archive"><codeph>CAknDoubleSpanScrollBar</codeph></xref>. For implementation information, see Creatinga scrollbar.</p><p>Scrollbar models encapsulate the range of integerswhich a scrollbar can represent, from zero to n, and the current positionof the scrollbar thumb within that range. To set the scrollbar model, usethe class <xref href="jar:GUID-759FBC7F-5384-4487-8457-A8D4B76F6AA6.jar!/html/classTAknDoubleSpanScrollBarModel.html" format="application/java-archive"><codeph>TAknDoubleSpanScrollbarModel</codeph></xref>. For information on updating the scrollbar's position and size usingthe scrollbar model, see UpdatingArrowHead scrollbar attributes and UpdatingDoubleSpan scrollbar attributes.</p><p>You can control the scrollbarvisibility using the method <xref href="jar:GUID-759FBC7F-5384-4487-8457-A8D4B76F6AA6.jar!/html/classCEikScrollBarFrame.html#63d2cba6f1261f9c56dd7a98499fceda" format="application/java-archive"><codeph>SetScrollbarVisibilityL()</codeph></xref> in the class <xref href="jar:GUID-759FBC7F-5384-4487-8457-A8D4B76F6AA6.jar!/html/classCEikScrollBarFrame.html" format="application/java-archive"><codeph>CEikScrollbarFrame</codeph></xref>.</p><p>To observed scrollbar events,use the class <xref href="jar:GUID-759FBC7F-5384-4487-8457-A8D4B76F6AA6.jar!/html/classMEikScrollBarObserver.html" format="application/java-archive"><codeph>MEikScrollbarObserver</codeph></xref>. For implementation information, see Observingscrollbar events.</p></section></conbody></concept>