AndroidThe mobile phone operating system needs to write and implement various functions in the simulator. More prominent in interface operations
The andorid interface needs to be written in the XML of RES/layout. Generally, an XML corresponds to an interface.
The layout of the android interface is similar to HTML (including code annotation). The step is to first customize the android framework and put controls in the framework.
Framework provided by Android: absolutelayout
Linearlayout
Relativelayout
Tablelayout
Framelayout
Framelayout: there is only one control in it, and the position of the control cannot be designed. The control is placed in the upper left corner.
Linearlayout: Multiple controls can be placed, but only one control can be placed in one row.
Tablelayout: this should be used with tablerow, much like the table in HTML
Absolutelayout
Relativelayout: Multiple controls can be placed in the control, but the control positions are relative positions.
(The layout of the android interface seems to be able to directly reference some views, such as scrollview)
The XML of the Framework is as follows:
1. Android: Id = "@ + ID/widget36"
2. Android: layout_width = "fill_parent"
3. Android: layout_height = "fill_parent"
CodeAndroid: Indicates the property of the Control. fill_parent indicates the maximum width or height. wrap_content indicates the proper width or height.
Divided by three attributes, for example, Android: Background = "# ff0000ff", set the background color of the Framework, androidrientation = "vertical" to set the attributes of the framework content.