IntelliJ IDEA




Download the way


Click me to download Android Studio 3.0


Android Studio Installation tutorial

1, download the package on this website, unzip the file, double-click “Android-Studio-IDE-171.4408382-Windows. exe”, the software installation wizard will pop up, click “Next” to start the installation;




2. Select the components to be installed according to your own needs. By default, select install Android virtual device and click “Next” to install;




3. Customize the software installation directory. The default installation path is “C:\Program Files\Android\Android Studio”. Click “Next” to continue installation;




4. Wait for the installation progress to complete, click “Finish” to complete the installation;





Android studio tutorial

1. After the installation, run the software, and the complete installation window will pop up. Customize whether to import the original installation Settings, select the second option, and click “OK” button to enter the software page;




2. Android SDK was not added to the specified path during startup, so we click “Cancel” to exit the prompt and specify the local path of SDK in the SDK Components Setup window. If the SDK already exists in the computer, you can specify the local path. You don’t need to download the SDK installation package later.




3. By default, we check to download the SDK installation package. Note that at this time, you need to ensure that the computer is connected to the Internet, and click “Finiish” to complete the installation.




4. After downloading the SDK, click “Start a new Android Studio Project” button to create a project;




5. Configure the first running environment of Android Studio, customize and edit the project information, and click “Next” to enter the Next configuration;




6. Set the target Android device and configure the Activity window;




7. After the project is established, Gradle components automatically synchronize the required component environment from the Internet.




New features

1. Kotlin programming language


Android Studio 3.0 now includes support for Kotlin, in response to an overwhelming chorus of developers. With this new language support, you can seamlessly add Kotlin code next to your existing Android application code and have access to all the great development tools available in Android Studio. You can choose to add Kotlin to your Project using the built-in conversion tool provided in Code → Convert Java File to Kotlin File, or you can choose to create a Kotlin-enabled Project using the New Project wizard. Learn more about Kotlin language support in Android and Android Studio.


2. Java 8 language features


Continue to improve support for Java 8 language features and apis. Due to the recent abandonment of the Jack tool chain and migration to a Javac-based tool chain, you can access many new features, such as Instant Run, in Android Studio for projects that use Java 8 language features. To update your Project to support the new Java 8 language tool chain, simply update your source code and object code compatibility levels to 1.8 in the Project Structure dialog.


3. Layout editor


In this version of Android Studio, you’ll find more enhancements to the layout editor. We’ve updated the component tree to provide better drag-and-drop view insertion and a new error panel. In conjunction with the update to ConstraintLayout, the layout editor also supports the creation of view barriers and groups, as well as enhanced chain creation.


4. Adaptive Icon Wizard


Android O introduces the adaptive launcher icon, which can be displayed in different shapes on different Android devices. The new Adaptive Launcher Icon wizard creates new and old versions of Launcher Icon resources and previews how Adaptive ICONS look on different Launcher screen Icon masks. To create a New resource, right click on the /res folder in your project and navigate to → New → Image Asset → Launcher Icons (Adaptive and Legacy).


XML fonts and downloadable fonts


It’s now easier to add custom fonts to your applications (for Android O) using the XML Font Preview and font selection tools in Android Studio. You can also create downloadable font resources for your application. With downloadable fonts, you can use custom fonts in your applications without having to bundle font resources in APK. To use downloadable fonts, make sure your device or emulator is running Google Play Services version 11.2.63 or higher.


6. Android Things support


With Android Studio 3.0, you can start developing Android Things using a New set of templates in the New Project and New Module wizards. Android Things allows you to extend your Android development knowledge into the Internet of Things (IoT) device category.


7. Improvement of construction speed


We continue to work on building speed. In this release, we focus on improving the build speed of projects with a large number of modules. To speed up the build of these projects and support future enhancements, we have made radical changes to the API of the Android Gradle plug-in used by Android Studio. If you rely on apis provided by previous versions of the plug-in, you should verify compatibility with the new plug-in and migrate to the applicable API. Test and update the plug-in version in your build.gradle file.


8. Google Play system image


In conjunction with updating the Android O Beta, we also updated the Android Emulator O system image to include the Google Play Store. Bundling the Google Play Store gives you the ability to test your apps end-to-end using Google Play, and it also makes it easy to keep the Google Play service up to date in Android Virtual Device (AVD). Just like the Google Play service update on the actual device, you can enable the same update on AVD.

Android Studio shortcut

1. Ctrl+G


At the same time, press Ctrl+G to pop up the quick positioning box. Enter the number of lines in the box and click OK to quickly switch to the corresponding number of lines, as shown in Fig.2.17.


2. Ctrl+E


At the same time, press Ctrl+E to display the list of recently opened files. You can quickly select the recently opened files


3. Ctrl+/


Annotate a line by selecting it and pressing the Ctrl+/ shortcut key, as shown in Figure 2.19.


4. Ctrl+F


At the same time, press Ctrl+F shortcut key, the quick search bar within the class will pop up at the top of the editing page, you can quickly locate a word in the class, support associative search


Typing prote will highlight protected, and notice that there are three check boxes in the search bar. Selecting the first Match Case check box will be case-sensitive.


5. Ctrl+R:


The Ctrl+F shortcut is often used with the Ctrl+R shortcut to quickly find and replace all


Use Ctrl+F to search for all protected items, then Ctrl+R to pop up the Replace bar. Enter the replaced word in the Replace bar input box and click Replace All to Replace all protected items in the class with public. However, use caution in real development to avoid introducing hidden problems.


6. Ctrl+J


Press Ctrl and J at the same time to pop up the shortcut code box


For some common code encapsulation in Android Studio, directly selected can be quickly generated, very practical in development, here to print log and pop-up Toast as an example. First press Ctrl+J to pop up the shortcut code box as shown in Figure 2.24, and then directly enter the “command” of the shortcut code logd, as shown in Figure 2.25.


A TAG is required to print logs. You can quickly generate a TAG by typing the shortcut logt at the top of the class, as shown in Figure 2.27.


Similarly, first Enter Ctrl+J to pop up the shortcut code box, then directly Enter toast and press Enter, or after you have toast, press Tab to quickly generate a line of toast statement and Enter the information to be displayed in quotation marks. Isn’t it very fast and convenient?


7. Ctrl + F12:


In the case of a large number of methods in the class, press Ctrl and F12 keys at the same time to quickly view all methods in the class. When this box pops up, you can directly enter the method you want to search for fast matching.


8. Ctrl+Alt+T


Select a piece of code and press Ctrl, Alt, and T at the same time to pop up the “Wrap” dialog box. Select the type of the package to wrap the selected code.


9. Ctrl+Alt+L


Formats all code for the current class


10.Ctrl+Alt+V


This shortcut allows quick declaration of a variable and local variable assignment


11.Ctrl+Alt+H


Click on one of the methods and press this shortcut key to pop up the calling relationship of this method on the left bar. This shortcut key is very common in development.


12.Ctrl+Alt+O


This shortcut can automatically guide packages or delete useless packages, press the shortcut key to automatically delete these useless packages.


13.Ctrl+Shift+/


Ctrl+Shift+/ comments a block of code. Press this shortcut again to uncomment that part of the code


This shortcut is often used in development to quickly search for information by keyword. Check the first box for case sensitivity. Click the TAB on the right to see a preview of the keyword


Ctrl+Shift+ plus/minus


If the method is folded, pressing Ctrl+Shift+ plus expands the method,


Conversely, if the method is expanded, pressing Ctrl+Shift+ minus at the same time will collapse the method


15.Alt+Insert


Pressing Alt and Insert at the same time brings up a quick code generation box with constructors, getter/setter methods, toString methods, and so on.


16. Alt + mouse


Press Alt and mouse to select multiple at the same time


Android Studio multi-line select


In the figure above, multiple lines can be edited if multiple lines are selected at one time


17.Ctrl+ left mouse button


This shortcut allows you to view the class or method selected with the mouse.