How to add custom view to the layout?

后端 未结 7 1604
灰色年华
灰色年华 2020-11-30 07:35

I have a GraphicsView class that extends from the View class and I want to add this GraphicsView class to the main layout in my projec

相关标签:
7条回答
  • 2020-11-30 08:26

    You need to give complete path of your class that extends View,

    <com.blah.blah.GraphicsView
             android:id="@+id/view"
              android:layout_width="fill_parent"
            android:layout_height="wrap_content"/>
    
    0 讨论(0)
提交回复
热议问题