美文网首页
flutter之Positioned

flutter之Positioned

作者: 不泯iOS | 来源:发表于2020-04-14 11:08 被阅读0次

    api:

    const Positioned({
        Key key,
        this.left,
        this.top,
        this.right,
        this.bottom,
        this.width,
        this.height,
        @required Widget child,
      })
    

    使用注意点:

    1.在同一个方向上,只能同时使用其中的两个属性,比如水平方向上只能使用left,right,width中的两个,第三个会自动计算。
    2.Positioned通常和Stack一起使用,left、top 、right、 bottom分别代表离Stack左、上、右、底四边的距离。

    相关文章

      网友评论

          本文标题:flutter之Positioned

          本文链接:https://www.haomeiwen.com/subject/gqdzmhtx.html