Build an Android integrated development environment using INTELLIJ Idea 13 (graphic tutorial)

Source: Internet
Author: User

Original: Using IntelliJ idea 13 to build an Android integrated development environment (graphic tutorial)

? "declaration"

Welcome reprint, but please keep the original source of the article →_→

Life One number: http://www.cnblogs.com/smyhvae/

Article Source: http://www.cnblogs.com/smyhvae/p/4013535.html

Contact information: [Email protected]

Body

"Development Environment"

Physical machine Version: Win 7 Ultimate Edition (32-bit)

Java SDK Version: jdk1.8.0_20 (32-bit)

Android SDK version: Android 4.4 (API 20)

IntelliJ idea version: IntelliJ idea 13.1

First, the introduction of IntelliJ idea:

In 2013, the IntelliJ idea Group had a very close relationship with many of the industry's leading development technologies, such as Android, Spring, Scala and Gradle. In this way, we can stay ahead of the vying and provide developers with the best development tools to experience the most cutting-edge development technologies. Let's start by introducing these key words:

  • Java EE 8: In order to deliver on our promise of "first" and "best" to provide new technical support to all Java developers, IntelliJ Idea 13 fully supports the latest enterprise Java platform from Java EE 8--oracle. In the latest version of IntelliJ idea, the code complement support is provided for CDI 1.1, JSF 2.2,jax-rs 2.0, batch processing, and other new specifications. It also provides support for the new version of the application server, such as GlassFish 4, Wildfly (the original famous JBoss), Tomcat 8, and so on.
  • Spring: Spring Development This time gets more help than ever in the new version of IntelliJ idea, with a new Spring tool window that makes it easier for users to navigate between context configurations and their corresponding bean classes in a project. This new tool window also allows users to easily browse the MVC controller and its corresponding URL mappings. IntelliJ Idea 13 also optimizes performance and simplifies the configuration of spring projects.
  • Android: One of the most amazing places in the 2013 Google I/O Conference was the preview version of Android Studio, a new Android integrated development environment. Android Studio was developed on the basis of the IntelliJ idea Open source community version. The introduction of this weapon attracted a large number of enthusiastic Android developers who helped IntelliJ platform make great strides and enriched many features. IntelliJ Idea 13 is the first major release to be launched with the Help and urge of Android developers, and it has been greatly improved in many respects, such as code Editor, UI designer, SQLite database access support, etc.
  • Gradle: Another important enhancement to IntelliJ idea 13 is the redefinition of support for Gradle, including improved synchronization of projects, automatic completion of dependencies and plug-ins, fast document functionality, and code generation capabilities. IntelliJ idea 13 can even automatically configure Web faces and war release packages via Gradle file. Users can browse through the Gradle support feature from this introductory video.

Idea includes a free community version (open source) and a paid Ultimate version that can be used on JetBrains's website. The ultimate version is much better for Java EE development than the community version. But for Android development of children's shoes, community version is enough. IDEA is developed using Java, and like Eclipse, supports Windows, Linux, and Mac OS X.

Eclipse requires an ADT plugin to support Android development. And idea's support for Android development is built-in and no other plugins are needed. Of course, the Android SDK and JDK are still indispensable. Admittedly eclipse is a great open source software, but if you're looking for more development efficiency and a more innovative GUI interface, this is arguably the best Java development tool you have.

I've seen several blogs about how to use IntelliJ idea to build an Android integrated development environment, but I don't feel detailed, so I want to organize a detailed tutorial, hoping to help the novice (including myself) .

Second, the preparation of software:

Since you are developing Android, the Java SDK and Android SDK are essential regardless of the development environment. After downloading, my package is as follows:

1. Installation of the Java SDK:

Download site: http://www.oracle.com/index.html

Since my operating system is 32-bit, I downloaded the 32-bit JDK version:

After the download is complete, start the installation:

Here, choose the installation path according to your preference.

The following need to configure the environment variables, specifically, you can refer to my other blog: Java Configuration----JDK development environment and environment variable configuration

2. Download the Android SDK:

Now the Android SDK is bundled with ADT and Eclipse, but it doesn't matter, we can download it directly, then we can see that the SDK is placed in a separate directory and can be used separately.

Download site: http://www.android.com/

Note: The Internet is a bit slow, how to get in you know.

Click on the text in the red box above to enter another link:

Click on the position of the Red Arrow section above to get the Android SDK:

After downloading, unzip the package and unzip the file as shown in the following:

The upper red box section is the Android SDK that we need.

3. Download and install IntelliJ idea:

Download site: http://www.jetbrains.com/idea/

As is done for Android development, so we choose the free community version on the right (if you are doing Java Web Development you can choose the Ultimate version on the right).

After the download is complete, you can install:

third, load the SDK in idea :

After the installation is complete IntelliJ idea, start running the software, the first time you run, the following dialog box appears:

is to remind you if you have a previous version of the idea settings file, which is an XML file generated by the actions of a user who has previously used idea, and can use the previous development habits directly after importing, and for new users, it is essential to select the I don T.

Then we clicked Create New project and created a project:

Note :project in IntelliJ idea is not really project, it is a concept with workspace in Eclipse, solution in Visual Studio .

Let's take a look at the following form to find out:

Eclipse Ieda/android Studio
Work area Workspace Project
Project Project Module
Reference Preference Module dependency

Then pop up like a dialog box:

, if you want to use Gradle to build your Android app (this is recommended, after all, the current trend), you can choose the first one: Gradle:android modle. Then the following dialog box appears:

, we need to load our previously downloaded Java SDK and Android SDK. Then select Next:

See this window above, I believe you are already familiar with, this is similar to our development in Eclipse plug-in ADT.

Again:application is the work area, and module is the individual project . Then choose Next:

Can see, idea this software is really too human, there are many layouts for us to choose from. Select Next:

In this way, our Android program is built:

"Programme II"

Or if you don't want to build an Android program with Gradle, we can choose the second: application Module when creating a new project. As shown in the following:

Click Next and the following dialog box appears:

Load the Android SDK, then choose Next, and the project is built:

Iv. installation of the Genymotion simulator:

1, the installation of genymotion:

Genymotion is undoubtedly the fastest and best simulator available. Official website: http://www.genymotion.cn/

The simplest way to register, then download, and install VirtualBox is to download the Genymotion package that contains the VirtualBox, as shown in:

When the download is complete, start the installation. Then run the Genymotion software, you will be prompted to create a virtual device, click the Yes button to start creating a virtual device:

Connect using a previously registered account:

Then select one of the versions of the emulator:

In this way, our simulator is built, and the simulator is then associated with the IntelliJ idea.

2, the simulator genymotion and IntelliJ idea associated:

First download the plugin on Genymotion's website:

Then, open Idea, select the menu bar "File---settings", the following interface appears, and select plugins:

, select "Install plugin from disk" to load the plug-in from the local, pop up the following interface:

, select the plugin that we downloaded earlier to load. In this way, we can see more of a genymotion plugin in the plugin list:

Restart the software and let the newly loaded plugin take effect. After restarting the software idea, select the menu bar "View--toolbar" and let the toolbar appear, and you can see that the toolbar has more than one Genymotion Device Manager icon:

Click on this icon to bring up the following screen:

, load our previously installed Genymotion folder. Then click on this icon to bring up the following screen:

, you can see the simulator we built earlier, click "Start" and the simulator starts up:

Done.

Of course, if you want to run the program on the emulator, make sure the emulator is loaded with the Android SDK:

Otherwise, the error will be as follows:

V. Simple setup of Idea:

Subject modification:

Perhaps people will think the software interface is not very good, we can change the theme. Select the menu bar "File--settings--apperance--theme", the theme Select Darcula:

Code Font Modification:

Select the menu bar "File--settings--editor--colors&fonts--font":

The default scheme is not changed, click "Save as" to create a new name (e.g. MyFont):

, you can choose the font we want.

You can also modify the console font:

More tips on how to use it will be discussed in the future.

Build an Android integrated development environment using INTELLIJ Idea 13 (graphic tutorial)

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.