slint icon indicating copy to clipboard operation
slint copied to clipboard

The ListView's viewport-width is not working and no horizontal bar

Open wuanzhuan opened this issue 8 months ago • 2 comments

like this:

import { ListView } from "std-widgets.slint";

export component Demo {
    ListView {
        viewport-width: 10000px;

        private property <[string]> names: [
            "111111111111111111111111111111111",
            "222222222222222222222222222222222222",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333444444444444444444444",
            "3333333333333333333333333333333333333344444444444444444444444444444444444",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333",
            "33333333333333333333333333333333333333111111111111111111",
        ];

        for name[idx] in names: Rectangle {
            Text {
                text: name;
            }
        }
    }
}

wuanzhuan avatar Jun 26 '24 09:06 wuanzhuan