wojtek kalicinski: choosingthe right tools for your app development is moreimportant than ever. and as the androidplatform matured, so have our needs as developers. making great appsis so much easier
Android ide, when you have a rich andcomplete dev environment. and this was the drivingdecision behind the creation of android studio. i an wojtek kalicinski,and i'm going
to show you why you should beusing this powerful new tool. android studio isgoogle's official ide for android development. we've combined a robust codeeditor with an entirely new build system based on gradle. let's talk aboutthe editor first. the getting started experienceis crucial for every app developer. so in android studio,we focus on making
it easy to create new projects,as well as adding modules to support android tv,android wear, glass, and even the google cloud backend. all you need this to useone of the provided wizards, and the selectedmodules will be added to your project, along withcode templates that let you dive into coding quickly. for those of youcoming from eclipse, we've included a tool that letsyou import legacy projects.
not only will it create a newgradle build configuration for your app and fixyour project structure behind the scenes,it also identifies commonly used libraries andbrings them in as dependencies, eliminating the horrible processof moving folders manually and getting your build to work. if you just want tocheck out our samples, there's now a one-clicksolution to import them directly from google'srepository on github
into a ready-to-buildand run project. one of my personalfavorites when working with android studiois the new project view. it offers a flattenedrepresentation of your project structure, giving quickaccess to code, resources, and build files. in fact, android studio will nowonly list each resource once, regardless of whichconfigurations like density or screen sizeare included in your project.
you can always expandthe resource node and check out all its versions. when it comes to gettingthings done and writing code, android studio helpsyou to stay productive, while at the same timemaking sure that you write clean and error-free code. apart from the usualhelpers you would expect from your ide, likecode completion and access to documentation, we've addedpowerful new code inspections
and refactorings, targetingperformance and compatibility. you can now easily extractstrings into resources, or even add right to leftsupport to all your layouts with one click. to make sure you never againpress the wrong resource type to a method, add one of theseannotations to its parameters. many of the framework methodsare annotated as well, so android studiowill show an error if it encounters, forexample, an rgb value where
a color resource is expected. android studio supportsyour development flow, which includes working withboth java and xml files. it's easy to switch between yourclasses and relevant resources by clicking thisicon, or control clicking any part of theresource name in your code. you even got handypreviews of bitmaps right there inthe editor window. to get a quick look atwhat your resource looks
like for differentconfigurations, or explore theme attributesin the layout editor, use the quickdocumentation view. you can access it bypressing control q or f1, depending on your settings. for editing layouts,there is the choice of using the visualdesign editor, where you can drag and dropviews on to the canvas and manipulate their properties.
or if you prefer,you can seamlessly switch to editing xml filesdirectly and see the preview update in real time. android studio willalert you whenever you forget to set the requiredattribute on your views, such as layout width orheight, and can even identify common performance problems. if you want to see howyour layouts behave on different screen sizes, orif your translated strings fit
correctly in otherlocales, you can switch to multi-preview mode. this will show yourlayout simultaneously, side-by-side on multipledevice configurations. you can even look at how yourcustom themes and styles behave across android versions,which i have to say is pretty useful when you'retargeting older devices. oh, and by the way,if you are thinking of localizing your app, justuse the brand new translation
editor that we've createdto streamline this task. as always, our android toolsare being built in the open. you can follow the progressand get more information at tools.android.com. if you haven't already doneso, download android studio from the android developer site. also, be sure to followour google + page,
and join the androidtools community for updates about newfeatures and releases.
tune into our next video inthe android studio devbytes series, where we'll takea closer look at the new