<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
For example here is my old and very poor made UI with listview
inside flickable:
<a class="moz-txt-link-freetext" href="https://github.com/CODeRUS/harbour-mitakuuluu2/blob/master/client/qml/ConversationPage.qml#L234">https://github.com/CODeRUS/harbour-mitakuuluu2/blob/master/client/qml/ConversationPage.qml#L234</a><br>
<br>
And here is my latest monster page UI without using flickable:
<a class="moz-txt-link-freetext" href="https://gist.github.com/CODeRUS/d9033e440dd4da74dd77">https://gist.github.com/CODeRUS/d9033e440dd4da74dd77</a><br>
If someone will be interested i can explain how it working<br>
<br>
<div class="moz-cite-prefix">24.05.2015 22:45, Dmitriy Purgin пишет:<br>
</div>
<blockquote
cite="mid:CA+y33yQi3SPvxwiW8yyR_YsNZhVq8E3YBRnDiO7=Zy84j2epyQ@mail.gmail.com"
type="cite">
<div dir="ltr">
<div>
<div>Hi Andrey,<br>
<br>
</div>
can you please provide a case or a non-synthetic example? I've
never met a pressDelay yet and never used it myself, read
about it in the docs just now. I think it can be used in a
very complex interface but can't think of an example right
now. But, as you know, I'm not much of a GUI builder, doing
backend stuff mostly.<br>
<br>
</div>
Cheers<br>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">2015-05-24 23:31 GMT+06:00 Andrey
Kozhevnikov <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:coderusinbox@gmail.com" target="_blank">coderusinbox@gmail.com</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000"> Do not forget to set
proper pressDelay values for flickable and listview, if
you still want to put listview inside flickable.<br>
<br>
<div>24.05.2015 22:28, Dmitriy Purgin пишет:<br>
</div>
<div>
<div class="h5">
<blockquote type="cite">
<div dir="ltr">
<div>
<div>Привiт, Вiталiй!<br>
<br>
</div>
<div>If want to have something like a toolbar at
the bottom of the list, I'd go with
DockedPanel [1]. I guess it's the preferred
way of doing it. But you can also do this by
setting list view height explicitly if you do
it in column or anchoring. Consider the
following code, it lays out a header and a
button at top and bottom of page respectively,
and a list view in the middle:<br>
</div>
<br>
<span style="font-family:monospace,monospace">Page
{<br>
id: page<br>
<br>
SilicaFlickable {<br>
anchors.fill: parent<br>
<br>
</span></div>
<span style="font-family:monospace,monospace">
// test pull down menu<br>
</span>
<div><span style="font-family:monospace,monospace">
PullDownMenu {<br>
MenuItem {<br>
text: 'Item 1'<br>
}<br>
}<br>
<br>
</span></div>
<div><span style="font-family:monospace,monospace">
// test push up menu<br>
</span></div>
<div><span style="font-family:monospace,monospace">
PushUpMenu {<br>
MenuItem {<br>
text: 'Item 2'<br>
}<br>
}<br>
<br>
</span></div>
<div><span style="font-family:monospace,monospace">
// set this explicitly, otherwise you will
have<br>
</span></div>
<div><span style="font-family:monospace,monospace">
// weird problems with push and pull menus<br>
</span></div>
<div><span style="font-family:monospace,monospace">
contentHeight: column.height<br>
<br>
Column {<br>
id: column<br>
<br>
anchors.fill: parent<br>
<br>
PageHeader {<br>
id: header<br>
<br>
anchors.left: parent.left<br>
anchors.right: parent.right<br>
<br>
title: 'Header'<br>
}<br>
<br>
SilicaListView {<br>
id: listView<br>
<br>
</span></div>
<div><span style="font-family:monospace,monospace">
// fill all the space between header and
button<br>
</span></div>
<div><span style="font-family:monospace,monospace">
height: page.height - header.height -
button.height<br>
<br>
anchors.left: parent.left<br>
anchors.right: parent.right<br>
<br>
</span><span
style="font-family:monospace,monospace"><span
style="font-family:monospace,monospace">
// this is needed so that the list elements
<br>
// do not overlap with other
controls in column<br>
</span> clip: true <br>
<br>
model: 20<br>
<br>
delegate: ListItem {<br>
anchors.left: parent.left<br>
anchors.right:
parent.right<br>
<br>
Label {<br>
width: parent.width<br>
height: parent.height<br>
<br>
text: model.modelData<br>
}<br>
}<br>
}<br>
<br>
Button {<br>
id: button<br>
<br>
anchors.horizontalCenter:
parent.horizontalCenter<br>
<br>
text: 'Button'<br>
}<br>
}<br>
}<br>
}</span><br>
<br>
</div>
<div>If you'd do this using anchoring, you should
set contentHeight to sum of all the elements
included to flickable. <br>
<br>
</div>
<div>Please note that if you would set a view that
wouldn't fit to screen (by setting
listView.height to something larger than the
expression in the sample code), you would have
to either scroll the list all the way up or down
for the menus or begin dragging outside the
list. <br>
</div>
<div><br>
</div>
<div>Cheers<br>
</div>
<div>Dmitriy<br>
</div>
<div><br>
[1] <a moz-do-not-send="true"
href="https://sailfishos.org/develop/docs/silica/qml-sailfishsilica-dockedpanel.html/"
target="_blank">https://sailfishos.org/develop/docs/silica/qml-sailfishsilica-dockedpanel.html/</a><br>
</div>
<div><br>
</div>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">2015-05-23 22:57
GMT+06:00 Віталій Коренєв <span dir="ltr"><<a
moz-do-not-send="true"
href="mailto:nemish94@gmail.com"
target="_blank"><a class="moz-txt-link-abbreviated" href="mailto:nemish94@gmail.com">nemish94@gmail.com</a></a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0
0 0 .8ex;border-left:1px #ccc
solid;padding-left:1ex">
<div dir="ltr"><span lang="en"><span title="Я
тільки починаю вивчати qml, тому
виникають багато питань.">I'm just
starting to learn qml, and there are
many questions. <br>
</span><span title="Я маю ">I have<br>
</span><span title="XmlListModel{
">XmlListModel {<br>
</span><span title="id:
listModel ">id: listModel<br>
</span><span title="query:
"/colors/color" ">query:
"/ colors / color"<br>
</span><span title="XmlRole
{name: "id";">XmlRole {name:
"id"; </span><span title="query:
"id/string()"} ">query:
"id / string ()"}<br>
</span><span title="XmlRole
{name: "title";">XmlRole
{name: "title"; </span><span
title="query:
"title/string()"} ">query:
"title / string ()"}<br>
</span><span title="... ">...<br>
</span><span title="} ">}<br>
<br>
</span><span title="SilicaFlickable
{ ">SilicaFlickable {<br>
</span><span
title="anchors.fill: parent ">anchors.fill:
parent<br>
<br>
</span><span title="Column
">Column<br>
</span><span title="{
">{<br>
</span><span title="width:
parent.width;">width: parent.width; </span><span
title="height: parent.height
">height: parent.height<br>
</span><span title="id :
mainContainer ">id:
mainContainer<br>
<br>
</span><span
title="SilicaListView ">SilicaListView<br>
</span><span title="{
">{<br>
</span><span
title="width: parent.width;">width:
parent.width; </span><span
title="height: parent.height
">height: parent.height<br>
</span><span title="id :
list ">id: list<br>
</span><span
title="model : listModel
">model: listModel<br>
</span><span
title="delegate: BackgroundItem {
">delegate:
BackgroundItem {<br>
</span><span
title="width: parent.width;">width:
parent.width; </span><span
title="height: 120 ">height:
120<br>
</span><span
title="Image{ ">Image
{<br>
</span><span
title="source: imageUrl
">source:
imageUrl<br>
</span><span
title="anchors.fill: parent
">anchors.fill:
parent<br>
</span><span
title="} ">}<br>
</span><span
title="Label{ text: title }
">Label {text: title}<br>
</span><span title="}
">}<br>
</span><span
title="VerticalScrollDecorator {}
">VerticalScrollDecorator {}<br>
</span><span title="}
">}<br>
</span><span title="} ">}<br>
</span><span title="} ">}<br>
<br>
</span><span title="Яким чином я можу
додати інші елементи (buttons,
labels...) після всіх елементів
SilicaListView, якщо його height:
parent.height.">How can I add other
elements (buttons, labels ...) after all
elements of SilicaListView, if its
height: parent.height. </span><span
title="Якщо прибрати height:
parent.height для SilicaListView, він не
відображається.">If you remove line
height: parent.height for
SilicaListView, it is not displayed. </span><span
title="Були спроби додати перед
VerticalScrollDecorator {} та в інші
місця (експериментува з anchors), але
додані елементи знаходились в лівому
верхньому куту екрана або на останніх 10
пікселів екрана (під SilicaListView)">There
have been attempts to add other elements
before VerticalScrollDecorator {} and
other places (</span></span><span
lang="en"><span title="Були спроби додати
перед VerticalScrollDecorator {} та в
інші місця (експериментува з anchors),
але додані елементи знаходились в лівому
верхньому куту екрана або на останніх 10
пікселів екрана (під SilicaListView)"><span
lang="en"><span title="Були спроби
додати перед VerticalScrollDecorator
{} та в інші місця (експериментував
з anchors), але додані елементи
знаходились в лівому верхньому куту
екрана або на останніх 10 пікселів
екрана (під SilicaListView)">experimenting</span></span>
with anchors), but the added elements
were in the upper left corner of the
screen or on the last 10 points of the
screen (under SilicaListView)</span></span>.
<br clear="all">
<br>
<span lang="en"><span>Sorry for</span> <span>my</span>
<span>English.</span><br>
<span>PS.</span> <span>This is the only</span>
<span>way to get</span> <span>or give</span>
<span>help</span> <span>when working with</span>
<span>qml + Silica?</span> <span>No</span>
<span>forum</span> <span>for developers</span>
<span>Sailfish?</span></span></div>
<br>
_______________________________________________<br>
SailfishOS.org Devel mailing list<br>
To unsubscribe, please send a mail to <a
moz-do-not-send="true"
href="mailto:devel-unsubscribe@lists.sailfishos.org"
target="_blank"><a class="moz-txt-link-abbreviated" href="mailto:devel-unsubscribe@lists.sailfishos.org">devel-unsubscribe@lists.sailfishos.org</a></a><br>
</blockquote>
</div>
<br>
</div>
<br>
<fieldset></fieldset>
<br>
<pre>_______________________________________________
SailfishOS.org Devel mailing list
To unsubscribe, please send a mail to <a moz-do-not-send="true" href="mailto:devel-unsubscribe@lists.sailfishos.org" target="_blank">devel-unsubscribe@lists.sailfishos.org</a></pre>
</blockquote>
<br>
</div>
</div>
</div>
<br>
_______________________________________________<br>
SailfishOS.org Devel mailing list<br>
To unsubscribe, please send a mail to <a
moz-do-not-send="true"
href="mailto:devel-unsubscribe@lists.sailfishos.org"><a class="moz-txt-link-abbreviated" href="mailto:devel-unsubscribe@lists.sailfishos.org">devel-unsubscribe@lists.sailfishos.org</a></a><br>
</blockquote>
</div>
<br>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
SailfishOS.org Devel mailing list
To unsubscribe, please send a mail to <a class="moz-txt-link-abbreviated" href="mailto:devel-unsubscribe@lists.sailfishos.org">devel-unsubscribe@lists.sailfishos.org</a></pre>
</blockquote>
<br>
</body>
</html>