Android Developers Blog: Android Studio Narwhal Feature Drop is stable

Android Developers Blog: Android Studio Narwhal Feature Drop is stable

Home » News » Android Developers Blog: Android Studio Narwhal Feature Drop is stable
Table of Contents

Posted by Paris Hsu – Product Supervisor, Android Studio

The following wave of innovation is right here with Android Studio Narwhal Function Drop. We’re thrilled to announce that Gemini in Android Studio’s Agent Mode is now accessible within the secure launch, able to deal with your most complicated coding challenges. This launch additionally brings highly effective new instruments for XR growth, continued high quality enhancements, and key updates to boost your productiveness and show you how to construct high-quality apps.

Dive in to be taught extra about all of the updates and new options designed to supercharge your workflow.

moving image of Gemini in Android Studio: Agent Mode

Gemini in Android Studio: Agent Mode

Develop with Gemini

Check out Agent Mode

Transcend chat and assign duties to Gemini. Gemini in Android Studio’s Agent Mode is a robust AI characteristic designed to deal with complicated, multi-stage growth duties. To make use of Agent Mode, click on Gemini within the sidebar after which choose the Agent tab. You’ll be able to describe a high-level aim, like including a brand new characteristic, producing complete unit checks, or fixing a nuanced bug.

The agent analyzes your request, breaks it down into smaller steps, and formulates an execution plan that makes use of IDE instruments, comparable to studying and writing information and performing Gradle duties, and might span a number of information in your undertaking. It then iteratively suggests code adjustments, and also you’re at all times in management—you’ll be able to assessment, settle for, or reject the proposed adjustments and ask the agent to iterate primarily based in your suggestions. Let the agent deal with the heavy lifting whilst you concentrate on the larger image.

After releasing Agent Mode to Canary, we had optimistic suggestions from the builders who tried it. We have been so excited concerning the characteristic’s potential, we moved it to the secure channel sooner than ever earlier than, so that you could get your fingers on it. Strive it out and tell us what you construct.

screen grab of Gemini's Agent Mode in Android Studio

Gemini in Android Studio: Agent Mode

Presently, the default mannequin supplied within the free tier in Android Studio has a shorter context size, which might restrict the depth of response from some agent questions and duties. To be able to get the perfect efficiency from Agent Mode, you’ll be able to convey your individual key for the general public Gemini API. When you add your Gemini API key with a paid GCP undertaking, you’ll then be capable of use the most recent Gemini 2.5 Professional with a full 1M context window from Android Studio. Bear in mind to choose the “Gemini 2.5 Professional” from the mannequin picker within the chat and agent enter bins.

screen grab of Gemini's model selector in Android Studio

Gemini in Android Studio: mannequin selector

Guidelines in immediate library

Tailor the response from Gemini to suit your undertaking’s particular wants with Guidelines within the immediate library. You’ll be able to outline most popular coding types, tech stacks, languages, or output codecs to assist Gemini perceive your undertaking requirements for extra correct and customized code help. You’ll be able to set these preferences as soon as, they usually’ll be mechanically utilized to all subsequent prompts despatched to Gemini. For instance, you’ll be able to create a rule comparable to, “All the time present concise responses in Kotlin utilizing Jetpack Compose.” You may as well set guidelines on the IDE stage for private use throughout tasks, or on the undertaking stage, which will be shared with teammates by including the .thought folder to your model management system.

screen grab of Rules in Prompt Library in Android Studio

Guidelines in immediate library

Remodel UI with Gemini [Studio Labs]

Now you can remodel UI code inside the Compose Preview setting utilizing pure language, straight within the preview. This experimental characteristic, accessible via Studio Labs, hurries up UI growth by letting you iterate with easy textual content instructions. To make use of it, right-click within the Compose Preview and choose Remodel UI With Gemini. Then enter your pure language requests, comparable to “Middle align these buttons,” to information Gemini in adjusting your structure or styling, or choose particular UI parts within the preview for higher context. Gemini will then edit your Compose UI code in place, which you’ll be able to assessment and approve.

side by side screen captures of accessing the 'Transform UI with Gemini' menu on the left, and applying a natural language transformationto a Compose preview on the right in Android Studio

Immersive growth

XR Android Emulator and template

Kickstart your prolonged actuality growth! Android Studio now contains:

    • XR Android Emulator: The XR Android Emulator now launches embedded inside the IDE by default. You’ll be able to deploy your Jetpack app, navigate the 3D house, and use the Embedded Structure Inspector straight inside Android Studio.
    • XR template: Get a head begin in your subsequent undertaking with a brand new template particularly designed for Jetpack XR. This gives a strong basis with boilerplate code to start your immersive expertise growth journey straight away.

XR Android Emulator in Android Studio

XR Android Emulator

XR Android Emulator in Android Studio

XR Android template in new undertaking template

Embedded Structure Inspector for XR

The embedded Structure Inspector now helps XR functions, which helps you to examine and optimize your UI layouts inside the XR setting. Get detailed insights into your app’s part construction and determine potential structure points to create extra polished and performant experiences.

Embedded Layout Inspector for XR in Android Studio

Embedded Structure Inspector for XR

Android Associate System Labs accessible with Android System Streaming

Android Associate System Labs are system labs operated by Google OEM companions, comparable to Samsung, Xiaomi, OPPO, OnePlus, vivo, and others, and broaden the number of gadgets accessible in Android System Streaming. To be taught extra, see Hook up with Android Associate System Labs.

Embedded Layout Inspector for XR in Android Studio

Android System Streaming helps Android Associate System Labs

Optimize and refine

Jetpack Compose preview high quality enhancements

We have made a number of enhancements to Compose previews to make UI iteration sooner and extra intuitive:

    • Improved code navigation: Now you can click on on a preview’s identify to immediately soar to its @Preview definition, or click on a person part inside the preview to navigate on to the operate the place it is outlined. Hover states and improved keyboard arrow navigation make shifting via a number of previews a breeze.
    • Preview picker: The brand new Compose preview picker is now accessible. You’ll be able to click on any @Preview annotation in your Compose code to entry the picker and simply handle your previews.

improved code navigation in Compose preview in Android Studio

Compose preview: Improved code navigation

Compose preview picker in Android Studio

Compose preview picker

K2 mode by default

Android Studio now makes use of the K2 Kotlin compiler by default. This next-generation compiler brings vital efficiency enhancements to the IDE and your builds. By enabling K2, we’re paving the way in which for future Kotlin programming language options and an excellent sooner, extra strong growth expertise in Kotlin.

K2 mode setting in Android Studio

K2 mode setting

16 KB web page measurement help

That will help you put together for the way forward for Android {hardware}, this launch provides improved help for transitioning to 16 KB web page sizes. Android Studio now presents proactive warnings when constructing apps which can be incompatible with 16 KB gadgets. You should utilize the APK Analyzer to determine which particular libraries in your undertaking are incompatible. Lint checks additionally spotlight the native libraries which aren’t 16 KB aligned. To check your app on this new setting, a devoted 16 KB emulator goal can be accessible within the AVD Supervisor.

16 KB page size support: APK Analyzer indication

16 KB web page measurement help: APK Analyzer indication

16 KB page size support: APK Analyzer indication

16 KB web page measurement help: Lint checks

Providers compatibility coverage

Android Studio presents service integrations that show you how to and your staff make sooner progress as you develop, launch, and keep Android apps. Providers are always evolving and should develop into incompatible with older variations of Android Studio. Subsequently, we’re introducing a coverage the place options that rely on a Google Cloud service are supported for roughly a yr in every model of Android Studio. The IDE will notify you when the present model is inside 30 days of changing into incompatible so you’ll be able to replace it.

Example notification for services compatibility policy in Android Studio

Instance notification for companies compatibility coverage

Abstract

To recap, Android Studio Narwhal Function Drop contains the next enhancements and options:

Develop with Gemini

    • Gemini in Android Studio: agent mode: use Gemini for tackling complicated, multi-step coding duties.
    • Guidelines in Immediate Library: Customise Gemini’s output in your undertaking’s requirements.
    • Remodel preview with Gemini [Studio Labs]: Use pure language to iterate on Compose UI.

Immersive growth

    • Embedded XR Android Emulator: Check and debug XR apps straight inside the IDE.
    • XR template: A brand new undertaking template to kickstart XR growth.
    • Embedded Structure Inspector for XR: Debug and optimize your UI in an XR setting.
    • Android Associate System Labs accessible with Android System Streaming: entry extra Google OEM associate gadgets.

Optimize and refine

    • Compose preview enhancements: Higher navigation and a brand new picker for a smoother workflow.
    • K2 mode by default: Sooner efficiency with the next-gen Kotlin compiler.
    • 16KB web page measurement help: Lint warnings, evaluation, and an emulator to arrange for brand spanking new gadgets.
    • Providers compatibility coverage: Keep up-to-date for entry to built-in Google companies.

Get began

Able to speed up your growth? Obtain Android Studio Narwhal Function Drop and begin exploring these highly effective new options right now! As at all times, your suggestions is essential to us.

Examine recognized points, report bugs, recommend enhancements, and be a part of our vibrant neighborhood on LinkedIn Medium, YouTube, or X. Let’s construct the way forward for Android apps collectively!



Supply hyperlink

author avatar
roosho Senior Engineer (Technical Services)
I am Rakib Raihan RooSho, Jack of all IT Trades. You got it right. Good for nothing. I try a lot of things and fail more than that. That's how I learn. Whenever I succeed, I note that in my cookbook. Eventually, that became my blog. 

share this article.

Enjoying my articles?

Sign up to get new content delivered straight to your inbox.

Please enable JavaScript in your browser to complete this form.
Name