Android Studio Tutorial: [2] Overall layout of the project

Source: Internet
Author: User

The previous article describes how to create a project, which will show how the created project presents itself to the developer, introducing the overall layout of the Android Studio development environment and letting you know the location and functionality of each module.

Tools/Materials
    • Android Studio
Method/Step
  1. First look at the newly created Project interface, in addition to the menu bar, toolbars, etc., there is nothing to edit the interface

  2. All project files can be opened through the project's file browser, so the file manager is very important throughout the development process.

    One of the most used is the app, the rest is the software automatically execute or generate related files;

    External libraries is used to save the class library of an external import, which can be called when used.

  3. The resources and configuration files required for project creation are included under the app item:

    First open layout, in src-"main-" res-"layout, this is the Android app interface design file, all the interface can be generated by the XML file here

  4. Double-click on the XML file to open the design interface, about the layout of the specific design later, here is only how to open layout.

    Steps to read
  5. The project's menu design is defined and designed in the XML file under menu items.

  6. String files are also important files in the project, and many string data are used in the app development process. It is recommended to strings.xml in the definition of the later call, so that in the Chinese or converted to other languages, as long as the backup strings.xml files, and then replaced with Chinese or other text can be. In fact, this is the way the software of other countries becomes Chinese.

  7. The design of the software icon is also very important, this is the purpose of the UI design, all the picture files should be saved under the Drawable-xxxx file

    Steps to read
  8. Another important document is Androidmanifest.xml, which defines the package name of the project, the title of the project, the theme, the icon and all the active items, the settings of the various access rights, and so on.

  9. Next is the most important part of the development of Android, the active program of the writing part, all the app contains at least one activity, which is used to implement the functions required by the app, to complete the function code to write, here can call other files defined in the interface to access the resources, the receiver or generator read and write, etc.

  10. Finally, the R file, r file under the App->build->source->r->debug under the second folder, to store all the activity, layout, control and other resources definition, which is automatically generated by the software, No modification or modification is required, and resources are generally accessed through r.id.xxx during programming.

    END
Precautions
    • R file does not need to be modified
    • The string data is finally saved in the Strings.xml file

Android Studio Tutorial: [2] Overall layout of the project

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.