Android five big layouts

Source: Internet
Author: User

With the growing number of Android technology, and all aspects of the continuous improvement in the interview process, ask more and more, but the most basic things are necessary,

In particular, the four components of Android, five storage and five major layouts, today to summarize these things, convenient for future interview reference:

One or five large layouts:

The so-called five layouts are the layouts we use when drawing the UI interface: Framelayout (frame layout), LinearLayout (linear layout), Absolutelayout (absolute layout), relativelayout (relative layout), Tablelayout (table layout);

1. Framelayout (frame layout):

Features: The simple is that the sub-layout superimposed together, and then the layout will cover the previous layout, the default position in the upper left corner;

2. LinearLayout (linear layout):

Features: There are two vertical and horizontal arrangements: if arranged horizontally, only one row, the sub-layout is arranged horizontally from left to right;

column, you can set weights to distribute the layout proportionally;

3, Relativelayout (relative layout):

Features: The default position in the upper left corner, is a certain element as a reference, to locate the layout mode

4, Absolutelayout (absolute layout):

Features: with x, y coordinates to specify the position of the element, layout is also relatively simple, but in the vertical random switch, often problems, and multiple elements of the time, the calculation

More trouble, seldom used in the development process;

5, Tablelayout (table layout):

Features: There is a table row Tablerow,tablerow inside can be specific definition of each element, each table is equivalent to a row, in the development process is seldom used;

The above is my summary of the five major layout, there are shortcomings, but also hope that:

Android five big layouts

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.