slint-ui/slint

The internal components of the animation were not rendered

Open

#4,787 建立於 2024年3月7日

在 GitHub 查看
 (5 留言) (0 反應) (0 負責人)Rust (881 fork)batch import
a:tool classes & property systemgood first issue

倉庫指標

Star
 (22,596 star)
PR 合併指標
 (平均合併 4天 18小時) (30 天內合併 254 個 PR)

描述

  1. I used animation components in the animation component, but the internal components were not rendered
  2. Internal animation components width I use percentage. If I don't use percentages, it can render successfully
  3. If I don't use debug(self. width) in init, internal components won't render, see slintpad, code from @jui/drawer/drawer_left.slint
  4. But if I use debug(self. width) in init, internal components render success, see slintpad
  5. Difference code(On line 79 of slintpad)
// render success
export component AL inherits DrawerLeft {
    width: 100%;
    show: true;
    background: red;

    init => {
       debug(self.width)
    }
}
// won't render
export component AL inherits DrawerLeft {
    width: 100%;
    show: true;
    background: red;

    init => {
       // debug(self.width)
    }
}

貢獻者指南