Android TextView Center Align Text secara terprogram

yourTextView.setGravity(Gravity.CENTER);
Fedeboss