slint-ui / slint

Slint is a declarative GUI toolkit to build native user interfaces for Rust, C++, or JavaScript apps.
https://slint.dev
Other
16.94k stars 568 forks source link

LSP crashes when previewing if ProgressIndicator with 'width: parent.width;' inside VerticalBox #3944

Closed teminian closed 8 months ago

teminian commented 10 months ago

LSP crashes when loading preview with ProgressIndicator inside a VerticalBox with width: parent.width; option, which doesn't crash in the application itself(at least in VS Code).

Here goes the minimal source code to reproduce the problem.

import { VerticalBox, ProgressIndicator } from "std-widgets.slint";
export component Dashboard inherits Window {
    VerticalBox {
        ProgressIndicator {
            width: parent.width;
            height: 20pt;
            progress: 50%;
        }
    }
}
ogoffart commented 8 months ago

Seems to be fixed in nightly. I believe this was one of the recursion detected bug (duplicate of https://github.com/slint-ui/slint/issues/3989 )