I have a layout that contains a custom layout. I would like to pass the style from one element to another. I have a class which inflates the layout, which I can post if required. This element of design is added by 2 different layouts, with different sizes depending on what is required.
Child layout
<TableLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_gravity="center_horizontal">
<TableRow android:layout_height="wrap_content" android:gravity="center_horizontal" android:layout_width="fill_parent" android:id="@+id/tableRow1">
<Button android:text="1" android:id="@+id/nb1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="40sp" android:layout_margin="1dip" android:minWidth="70dip"></Button>
<Button android:text="2" android:id="@+id/nb2" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="40sp" android:layout_margin="1dip" android:minWidth="70dip"></Button>
<Button android:text="3" android:id="@+id/nb3" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="40sp" android:layout_margin="1dip" android:minWidth="70dip"></Button>
</TableRow>
</TableLayout>
And here's the parent layout
Parent Layout
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<pearsonartphoto.AJEG.number_viewer android:id="@+id/numberviewer" style="@style/bigViewer" android:layout_alignParentRight="true" android:layout_alignParentBottom="true">
</pearsonartphoto.AJEG.number_viewer>
</RelativeLayout>
What I would like to do is to pass in a style, and have the style be repeated through all of the children, or at least the textView elements. What do I need to do to make this happen?