<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40"
xml:lang="en">
<head>
<meta http-equiv=Content-Type content="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Verdana;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:blue;
        text-decoration:underline;}
p
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
span.EmailStyle18
        {mso-style-type:personal;
        font-family:Arial;
        color:navy;}
span.EmailStyle19
        {mso-style-type:personal-reply;
        font-family:Arial;
        color:navy;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body bgcolor=white lang=EN-US link=blue vlink=blue style='background-position-x:
0%;
background-position-y:0%'>
<div class=Section1>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>Also make sure that the widget (imageLabel
on this example) is larger than the scrollarea contents - if you just load a
small image the scroll won’t work. <o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>Even when you set the scrollbarpolicy to
“show always” it will not scroll anything unless the widget used on
the QScrollArea::setWidget is larger than the contents area.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p> </o:p></span></font></p>
<div>
<div class=MsoNormal align=center style='text-align:center'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>
<hr size=2 width="100%" align=center tabindex=-1>
</span></font></div>
<p class=MsoNormal><b><font size=2 face=Tahoma><span style='font-size:10.0pt;
font-family:Tahoma;font-weight:bold'>From:</span></font></b><font size=2
face=Tahoma><span style='font-size:10.0pt;font-family:Tahoma'> Ram Kurvakat
[mailto:rkmaemo@gmx.com] <br>
<b><span style='font-weight:bold'>Sent:</span></b> Sunday, June 06, 2010 4:44
AM<br>
<b><span style='font-weight:bold'>To:</span></b> Maemo Dev Mailing List; Sudheer
K.; felipe@crochik.com; daniil.ivanov@gmail.com<br>
<b><span style='font-weight:bold'>Subject:</span></b> RE: How to get kinetic
scrolling working using Qt creator</span></font><o:p></o:p></p>
</div>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p><font size=3 face="Courier New"><span lang=EN style='font-size:12.0pt;
font-family:"Courier New"'>just a quick example that would work, see if it
helps.</span></font><font size=1 face=Verdana><span lang=EN style='font-size:
4.5pt;font-family:Verdana'><o:p></o:p></span></font></p>
<p><font size=1 face=Verdana><span lang=EN style='font-size:4.5pt;font-family:
Verdana'><o:p> </o:p></span></font></p>
<p><font size=3 color=blue face="Courier New"><span lang=EN style='font-size:
12.0pt;font-family:"Courier New";color:blue'> imageLabel =
new QLabel;</span></font><font face="Courier New"><span lang=EN
style='font-family:"Courier New"'><o:p></o:p></span></font></p>
<p><font size=3 color=blue face="Courier New"><span lang=EN style='font-size:
12.0pt;font-family:"Courier New";color:blue'> QImage
image(someimagefile);</span></font><font face="Courier New"><span lang=EN
style='font-family:"Courier New"'><o:p></o:p></span></font></p>
<p><font size=3 color=blue face="Courier New"><span lang=EN style='font-size:
12.0pt;font-family:"Courier New";color:blue'> imageLabel->setPixmap(QPixmap::fromImage(image));</span></font><font
face="Courier New"><span lang=EN style='font-family:"Courier New"'><o:p></o:p></span></font></p>
<p><font size=3 face="Courier New"><span lang=EN style='font-size:12.0pt;
font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p><font size=3 color=blue face="Courier New"><span lang=EN style='font-size:
12.0pt;font-family:"Courier New";color:blue'>
_scrollForMapPage = new QScrollArea;</span></font><font face="Courier New"><span
lang=EN style='font-family:"Courier New"'><o:p></o:p></span></font></p>
<p><font size=3 color=blue face="Courier New"><span lang=EN style='font-size:
12.0pt;font-family:"Courier New";color:blue'>
_scrollForMapPage->setWidget(imageLabel);</span></font><font
face="Courier New"><span lang=EN style='font-family:"Courier New"'><o:p></o:p></span></font></p>
<p><font size=3 face="Courier New"><span lang=EN style='font-size:12.0pt;
font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p><font size=3 color=blue face="Courier New"><span lang=EN style='font-size:
12.0pt;font-family:"Courier New";color:blue'> _mapWindow =
new QMainWindow ( this );</span></font><font face="Courier New"><span lang=EN
style='font-family:"Courier New"'><o:p></o:p></span></font></p>
<p><font size=3 color=blue face="Courier New"><span lang=EN style='font-size:
12.0pt;font-family:"Courier New";color:blue'>
_mapWindow->setCentralWidget(_scrollForMapPage);</span></font><font
face="Courier New"><span lang=EN style='font-family:"Courier New"'><o:p></o:p></span></font></p>
<p><font size=3 color=blue face="Courier New"><span lang=EN style='font-size:
12.0pt;font-family:"Courier New";color:blue'>
_mapWindow->show();</span></font><font face="Courier New"><span
lang=EN style='font-family:"Courier New"'><o:p></o:p></span></font></p>
<div>
<p class=MsoNormal><font size=3 face="Courier New"><span lang=EN
style='font-size:12.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
</div>
<div>
<p class=MsoNormal><font size=3 face="Courier New"><span lang=EN
style='font-size:12.0pt;font-family:"Courier New"'>you dont need to set any
property as Daniil set most widgets have kinetic scrolling by default like
ListWidget/TableWidget/ScrollArea.<o:p></o:p></span></font></p>
</div>
<div>
<p class=MsoNormal><font size=3 face="Courier New"><span lang=EN
style='font-size:12.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
</div>
<div>
<p class=MsoNormal><font size=3 face="Courier New"><span lang=EN
style='font-size:12.0pt;font-family:"Courier New"'>cheers<o:p></o:p></span></font></p>
</div>
<div>
<p class=MsoNormal><font size=3 face="Courier New"><span lang=EN
style='font-size:12.0pt;font-family:"Courier New"'>-krk969<o:p></o:p></span></font></p>
</div>
<div>
<p class=MsoNormal><font size=3 face="Courier New"><span lang=EN
style='font-size:12.0pt;font-family:"Courier New"'><o:p> </o:p></span></font></p>
</div>
</div>
</body>
</html>