1 Toggle Screen:
The file name is the same and the folder is different.
layout-port/Stands for vertical screen
layout-land/Representative Horizontal screen
layout/represents any layout folder that has no modifiers.
The final implementation of the product plan:
Two sets of identical names, one folder for different layouts.
2 when the screen switch:
The code needs to be judged by direction.
Because different layout.xml are used.
Therefore, code checking is required.
3 for the size of the setting. Recommended Use:
Layout + style + dimension form
Layout screen
Style to set the dimensions cannot describe the Shuxin g:march_parent
Dimension to define a fixed size
4 Screen Adaptation principles:
What about 1 Jin ke linerlayout relativelayout
The properties of the layout in. Weapons are aligned using Margin_parent, warp_conent, margin or relationlayout project layouts.
2 If you cannot use a comfortable size, use the DP property as much as possible.
5 SW screen will never rotate only focus on the shortest side!
1 large screens and small screens
The width is adapted in a values-w<xxx>dp manner.
A high degree of adaptation is performed using the VALUES-H<XXX>DP method.
Suitable for the shortest side length using the VALUES-SW<XXX>DP method
2 when SW<XXX>DP and H<XXX>DP all match,
Choose the resources of SW<XXX>DP!
Android Screen Adaptation course notes