Android:gravity:
This is for the elements in the control, to control where the element is displayed in the control. For example, set the following two properties in a button control
Android:gravity= "left" and android:text= "submit", then the text "Submit" on the button will be on the right side of the button.
Android:layout_gravity:
This is for the control itself , which controls the position of the control in the parent control that contains the control. Similarly, when we set the android:layout_gravity= "left" property in the button control, it means that the button will be located at the right-hand side of the interface.
Wrap_content
Set the size of a view to wrap_content will force the view to expand to show the whole content. With textview imageview Control as an example, set to wrap_content The text and images inside of it will be fully displayed. Layout elements will change size based on content. Set the size of a view to wrap_content Roughly equivalent to setting windows control Span style= "Font-family:times New Roman" >autosize true
Match_parent
The component is forced to be expanded to fill as much space as possible within the layout unit.
android2.2 match_parent and fill_parent is a meaning two parameter meaning, more apt, so from start two words can be used. So if you consider the use of the lower version you will need to use the
Layout_gravity,gravity,wrap_content,match_parent