Five la s for Android and five la s for android
Five la s of Android: FrameLayout (Framework layout), LinearLayout (linear layout), AbsoluteLayout (absolute layout), RelativeLayout (relative layout), and TableLayout (table layout ).
FrameLayout
All things are placed in the upper left corner in sequence, which will overlap. This layout is relatively simple, and you can only put a little simple things.
LinearLayout
Each LinearLayout can be divided into vertical layout (android: orientation = "vertical") and horizontal layout (android: orientation = "horizontal "). In vertical layout, each row has only one element, and multiple elements are vertical down in sequence. in horizontal layout, there is only one row, and each element is arranged to the right in sequence.
AbsoluteLayout
The absolute layout uses the X and Y coordinates to specify the position of the element. This layout method is also relatively simple, but when the screen is rotated, there are often problems, and when there are multiple elements, computing is troublesome.
RelativeLayout
The relative layout can be understood as the layout method for positioning an element as a reference object. Main attributes include: android: layout_below, android: layout_toLeftOf, android: layout_alignParentLeft, android: layout_alignParentRigh
TableLayout
Each TableLayout contains the table row TableRow, which can define each element.
Each layout has its own method. These five layout elements can be nested with each other to create a beautiful interface.