I\'m trying to center an ImageView inside a LinearLayout horizontally and vertically, but I just can\'t do it. The main reason why I\'m not using a
ImageView
LinearLayout
Here's some sample code. This worked for me.
So you're designing the Linear Layout to place all its contents (TextView and Button) in its center, and then the TextView and Button are placed relative to the center of the Linear Layout.