user3738332
user3738332

Reputation: 41

What is the difference between the two syntaxes?

android:textAppearance="@android:style/TextAppearance.Small"
android:textAppearance="?android:textAppearanceSmall"

Both are giving the same result. Is there any difference in there compilation efficiency.

Upvotes: 0

Views: 52

Answers (1)

DeanJie
DeanJie

Reputation: 26

 android:textAppearance="@android:style/TextAppearance.Small"

is text style setting directly.

android:textAppearance="?android:textAppearanceSmall"

is the refrence text style that set value on this Activity or this TextView's Theme . Like this:

<style name="MyStyle">
<item name="textAppearanceSmall">@style/textStyle</item>
</style>

Upvotes: 1

Related Questions