Programming Tips - How can I horizontally center a TextView

Date: 2017mar8 OS: Android Q. How can I horizontally center a TextView A.
<TextView android:textAlignment="center" // Center the text in the view android:layout_gravity="center_vertical" // Make the view centered />
Details omitted for clarity.