Celeb Glow
general | March 21, 2026

(QML) Flickable not working as supposed

So, while building an Ubuntu app I needed to use flickable for scrolling, so now I have code of the form

Page{ ... Flickable { anchors.fill: parent content.height: element1.height + element2.height ... ... }
}

When I run it on my phone (ubuntu utopic), the default position of the flickable is a few hundred pixels lower than the header. When I flick it up, it stays in the correct position it's supposed to stay from the start. Also, when using pagestack to push another page, then come back to this one it stays in the right position. Why is this and how can I fix it, so that it can be in the right position from the start.

Note: I've tried many combinations with anchors, width, height, everything. One time I did get it to stay in the position, but when flicking up it overlapped the header.

6

1 Answer

There's way to little qml to see what's going on, especially since all components positions affect each other.

One solution would be to do the thing you did to get your flickable in the correct position, and then add the clip: true property to stop it from overlapping the header.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy