Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flickable (Scrollview) does not update viewport when content changes #7487

Open
jmEvoqua opened this issue Jan 28, 2025 · 0 comments
Open

Flickable (Scrollview) does not update viewport when content changes #7487

jmEvoqua opened this issue Jan 28, 2025 · 0 comments
Labels
a:flickable The implementation of the Flickable (mO) bug Something isn't working need triaging Issue that the owner of the area still need to triage

Comments

@jmEvoqua
Copy link

Bug Description

If there is dynamically visible content inside a flickable, the viewport does not respond to content changes. It will only update on scrolling.

For example:
When scrolling down and hide some content the viewport stays at that position and the screen could get potentially empty, which is confusing to the user.

Flickable.webm

Reproducible Code (if applicable)

import { AboutSlint, Button, VerticalBox, ScrollView } from "std-widgets.slint";

export component Demo {
    property <bool> hidden;
    ScrollView {
        VerticalBox {
            alignment: start;
            Text {
                text: "Hello World!";
                font-size: 24px;
                horizontal-alignment: center;
            }

            if !root.hidden: AboutSlint {
                preferred-height: 150px;
            }

            HorizontalLayout {
                alignment: center;
                Button {
                    text: "Toggle";
                    clicked => {
                        root.hidden = !root.hidden;
                    }
                }
            }
        }
    }
}

Environment Details

  • Slint Version: 1.9.2

Product Impact

No response

@jmEvoqua jmEvoqua added bug Something isn't working need triaging Issue that the owner of the area still need to triage labels Jan 28, 2025
@ogoffart ogoffart added the a:flickable The implementation of the Flickable (mO) label Jan 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
a:flickable The implementation of the Flickable (mO) bug Something isn't working need triaging Issue that the owner of the area still need to triage
Projects
None yet
Development

No branches or pull requests

2 participants