How to center a view or its content e.g. TextView or Button horizontally and vertically? layout_gravity can be used to position a view in the center of its parent. While gravity attribute is used to position view’s content e.g. “text” in the center of the view.
Welcome to my blog, this blog is about coding.
I believe starting with something practical, “in our case coding”, is much better than starting with explaining the concept.
Show me what does it do? and how to do it? Later I will decide if I need more details.
Here, we Code First!