Creating LinearLayout Programmatically/Dynamically with Multiple Views

前端 未结 4 1216
太阳男子
太阳男子 2020-12-05 09:46

I have a hierarchy that is like this:

  • LinearLayout(horizontal)
    • ImageView
    • LinearLayout(vertical)
      • TextView
      • TextView
4条回答
  •  伪装坚强ぢ
    2020-12-05 10:13

    In the XML File LinearLayout already has child view. So there is not need to add them in code.

提交回复
热议问题