Android: Align Center Vertical In RelativeLayout

Users tend to mistake aligning a view vertically by using android:layout_gravity=”center_vertical”. This holds true in other layouts but does not work under a RelativeLayout.

You will have to use the attribute android:layout_centerVertical=”true to make this work.

Related Posts Plugin for WordPress, Blogger...

Leave a Reply

Your email address will not be published. Required fields are marked *