0
是否有可能在標籤中覆蓋xml中的屬性?覆蓋xml <include ... />
parent.xml
<?xml version="1.0" encoding="utf-8"?>
<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<include
layout="@layout/button"
android:text="HAHAHAH"
/>
</TableLayout>
button.xml:
<?xml version="1.0" encoding="utf-8"?>
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="some string" />
是否有可能改變 「一些字符串」 到 「哈哈哈」?
什麼是你的終極目標是什麼? –
與java中的抽象類相似。按鈕只是一個容器,然後在父母我填寫一些細節。 – wtsang02