how to MODIFY a constraint layout programmatically?

前端 未结 4 816
离开以前
离开以前 2021-02-18 13:56

Ive got a view like below :

 

        
4条回答
  •  眼角桃花
    2021-02-18 14:41

    If you are using Kotlin and you have androidx-core-ktx lib you can simply do:

    someView.updateLayoutParams { horizontalBias = 0.5f }
    

提交回复
热议问题