android:rotation - Rotate a TextView/EditText

How to Rotate a TextView/EditText

added in API Level 11

rotation of the view, in degrees. Rotates both the text and the TextView object. If set to 180 degrees, will make the text upsize down. 90 degrees will make is vertical/sideways. Rotation starts from the middle of the TextView/EditView.

1. Add a TextView in your main.xml file.

2. Ensure to change the minSDKVersion to 11, or greater.

3. In the main.xml file, add the code below. This will rotate the TextView 25 degrees.

  <TextView
        ...
       android:rotation = "25"
  />

4. Compile and run!

Related Articles:

Resources:
http://developer.android.com/reference/android/view/View.html#attr_android:rotation
http://developer.android.com/reference/android/R.attr.html#rotation