Created
June 15, 2015 03:14
-
-
Save ar-android/f4b48a999fa4e5a3040b to your computer and use it in GitHub Desktop.
Set Style TextView
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
You can do programmatically using setTypeface(): | |
textView.setTypeface(null, Typeface.NORMAL); // for Normal Text | |
textView.setTypeface(null, Typeface.BOLD); // for Bold only | |
textView.setTypeface(null, Typeface.ITALIC); // for Italic | |
textView.setTypeface(null, Typeface.BOLD_ITALIC); // for Bold and Italic | |
XML: | |
You can set Directly in XML file in <TextView /> like: | |
android:textStyle="normal" | |
android:textStyle="normal|bold" | |
android:textStyle="normal|italic" | |
android:textStyle="bold" | |
android:textStyle="bold|italic" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment