Instance to set textAppearance in XML
Instance to set textAppearance in XML:
1 | <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"<br /> xmlns:instruments="http://schemas.android.com/instruments"<br /> android:layout_width="match_parent"<br /> android:layout_height="match_parent"<br /> android:orientation="vertical"<br /> instruments:context="com.instance.androidtextappearance.MainActivity" ><br /><br /> <TextView<br /> android:layout_width="wrap_content"<br /> android:layout_height="wrap_content"<br /> android:textual content="android-coding.blogspot.com"<br /> android:textSize="24dp"<br /> android:textStyle="daring" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:textual content="textAppearance"<br /> android:textAppearance="?android:textAppearance" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:textual content="textAppearanceLarge"<br /> android:textAppearance="?android:textAppearanceLarge" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:textual content="textAppearanceMedium"<br /> android:textAppearance="?android:textAppearanceMedium" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:textual content="textAppearanceSmall"<br /> android:textAppearance="?android:textAppearanceSmall" /><br /> <br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:textual content="textAppearanceInverse"<br /> android:textAppearance="?android:textAppearanceInverse" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:textual content="textAppearanceLargeInverse"<br /> android:textAppearance="?android:textAppearanceLargeInverse" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:textual content="textAppearanceMediumInverse"<br /> android:textAppearance="?android:textAppearanceMediumInverse" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:textual content="textAppearanceSmallInverse"<br /> android:textAppearance="?android:textAppearanceSmallInverse" /><br /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:background="@android:colour/darker_gray"<br /> android:textual content="textAppearanceInverse"<br /> android:textAppearance="?android:textAppearanceInverse" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:background="@android:colour/darker_gray"<br /> android:textual content="textAppearanceLargeInverse"<br /> android:textAppearance="?android:textAppearanceLargeInverse" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:background="@android:colour/darker_gray"<br /> android:textual content="textAppearanceMediumInverse"<br /> android:textAppearance="?android:textAppearanceMediumInverse" /><br /> <TextView<br /> android:layout_width="match_parent"<br /> android:layout_height="wrap_content"<br /> android:background="@android:colour/darker_gray"<br /> android:textual content="textAppearanceSmallInverse"<br /> android:textAppearance="?android:textAppearanceSmallInverse" /><br /> <br /></LinearLayout><br /><br /> |