Documentation on anchoring and PageHeader is confusing

Bug #1566778 reported by Stuart Langridge
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ubuntu-ui-toolkit (Ubuntu)
Confirmed
Low
Tim Peeters

Bug Description

It is not very clear how one is best to have, for example, a Page with a PageHeader and a ListView, and have the ListView take up the whole page.

Page {
    header:PageHeader {}
    ListView {}
}

This has changed quite a lot in different versions of the UITK -- should the ListView be set to anchors.fill: parent? Or anchors.top: page.top? Or anchors.top: pageheader.bottom? Should Page.flickable be set to the ListView, or will that be set automatically, or is it deprecated in favour of PageHeader.flickable, and does that have to be set explicitly or will it be set automatically? Should one set the ListView to anchors.fill:parent with a topMargin of pageheader.height as the UITK gallery does?

It would be very useful to have a series of examples with diagrams showing how to achieve various standard effects, for example:

1. a page with a header and a listview, where the listview takes up the whole page and the header scrolls away as the listview is scrolled
2. a page with a header and a listview, where the listview takes up the whole page and the header does not scroll away but stays fixed
3. a page with a header and a button which stays fixed under the header, and a listview which takes up the rest of the page and scrolls
etc.

Stuart Langridge (sil)
description: updated
Andrea Bernabei (faenil)
Changed in ubuntu-ui-toolkit (Ubuntu):
assignee: nobody → Tim Peeters (tpeeters)
Stuart Langridge (sil)
description: updated
Tim Peeters (tpeeters)
Changed in ubuntu-ui-toolkit (Ubuntu):
importance: Undecided → Medium
status: New → Confirmed
Tim Peeters (tpeeters)
Changed in ubuntu-ui-toolkit (Ubuntu):
importance: Medium → Low
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.