Recent Changes

The following features and bug fixes were recently checked in. For complete details, see the git changelogs at

ConstraintLayout 1.0 is now available

posted by Nicolas Roard

After months of intensive development, we are delighted to announce the 1.0 release of the ConstraintLayout library. It's available as a small unbundled library, in the Android Studio SDK Manager (under the "Support Repository" section), compatible with API level 9 (Gingerbread and above). We recommend updating to this version, particularly if used in production.


Note: with Android Studio 2.3 reaching release candidate status, we also encourage people to switch to it for editing layouts (ConstraintLayout included). Many improvements have been made since 2.2, providing a smoother experience.


The ConstraintLayout library allows you to create complex layouts easily, avoiding deep nested hierarchies and providing many powerful features for designing UIs:


  • Relative positioning of widgets to parent or siblings

  • Centering positioning and bias control

  • Flexible size control (min/max/wrap/constrained)

  • Per axis group behavior (chains, weights)

  • Advanced visibility behavior (gone handling and margins)

  • Horizontal and Vertical virtual guidelines (fixed positions or percentage-based)

  • Aspect Ratio support

  • Advanced API to set constraints programmatically, allowing easy animations between layouts


A code lab is available as an introduction to ConstraintLayout as well as a developer guide. A complete online documentation is also available. Many excellent tutorials have also been created by the developers’ community; you can find them on YouTube, Medium, or your favorite search engine.  


Changes since beta5: bug fixes related to wrap_content, support for MEASURE_STATE_TOO_SMALL.

Android Studio 2.3 RC 1 is Now Available

posted Feb 17, 2017, 9:20 PM by Tor Norbye

We have just released Android Studio 2.3 RC 1 to the Canary channel. Assuming no surprises, we will promote this to the beta channel in the next few days. This build contains a small set of important bug fixes.
Please continue to submit feedback as we are nearing a close to the 2.3 release sprint.


ConstraintLayout beta 5 is now available

posted Feb 9, 2017, 6:20 PM by Nicolas Roard   [ updated Feb 10, 2017, 7:46 AM ]

We just published ConstraintLayout beta 5. As always, it's available in the SDK Manager (under the "Support Repository" section). We recommend to update to this version -- it will be the last beta before 1.0 and is considered as the release candidate.


Key Changes:

  • Use of MATCH_PARENT now throws exception

  • Improved performance in wrap_content use cases (30-40%)

  • Better view dimension control (6 new attributes)

  • Improved behaviour of gone in chains

  • Aspect ratio enhancements

  • Increased coverage of apis in ConstraintSet (chains, transforms, etc.). See documentation.


Note: if you are using Android Studio 2.2, you might have to do File->Invalidate Caches & restart studio after installing this version (the editor behavior may not be correct, with widgets temporarily snapping to the top left corner or not shown). Using Android Studio 2.3 is strongly encouraged.


MATCH_PARENT


MATCH_PARENT is not valid in ConstraintLayout when set on its children, and its behavior undefined. To reduce the risk of errors we now throws an exception if we encounter it.


Improved performance


This release fixes a few issues and performance improvements (notably, wrap_content measure on the layout got a ~30-40% speed bump).


Better view dimension controls


The new available behaviors when a dimension is set to 0dp (MATCH_CONSTRAINT). As before, both endpoints (left/right or top/bottom) need to be connected to targets.


  • layout_constraintWidth_default = spread (default, similar to the previous behavior)

  • layout_constraintWidth_default = wrap

  • layout_constraintHeight_default = spread

  • layout_constraintHeight_default = wrap


Additionally, minimum and maximum dimensions can be specified (they will only apply to MATCH_CONSTRAINT widgets):


  • layout_constraintWidth_min = [dimension]

  • layout_constraintWidth_max = [dimension]

  • layout_constraintHeight_min = [dimension]

  • layout_constraintHeight_max = [dimension]


Spread provides the previous behaviour of expanding to fill the area defined by the constraints.

Wrap provides a significant new behaviour, with the widget resizing as if wrap_content was used, but limited by the connected constraints. A widget will thus not grow beyond the endpoints.

match_parent.png

Gone Behavior in Chains


Previously, this was not handled -- views in a Chain would disappear but still take space. Now, if a view in a chain is marked as GONE, the chain will react as if the view didn’t exist.

gone-behavior.gif

Improved Ratio Support


Here the widget has both dimension set to MATCH_CONSTRAINT (0dp), and the attribute layout_constraintDimensionRatio=”16:9”


ratio.gif



Android Studio 2.3 Beta 4 is now available

posted Feb 9, 2017, 2:32 PM by Chris Iremonger   [ updated Feb 9, 2017, 6:37 PM ]

We have just released Android Studio 2.3 Beta 4 to the Canary and Dev Channels.

Android Studio 2.3 Beta 4 has already completed the first level of testing and wanted to share the bits with as soon as possible. Once the build passes all testing we will release it to the Beta channel.

Fixed Issues

Please continue to submit feedback as we are nearing a close to the 2.3 release sprint.

Android Emulator Revision 25.3.0 (Feb 2017)

posted Feb 8, 2017, 5:20 PM by Chris Iremonger   [ updated Feb 11, 2017, 9:20 AM by J. Eason ]

First release upon separating the emulator from SDK Tools in the Canary and Dev channel. There have been changes to SDK Tools 25.3 which is also released to the Canary channel with this Emulator update.

Dependencies:
  • Android SDK Platform-tools revision 24 or later.
  • Android SDK tools 25.3.0
New Android Emulator features and Bug Fixes:
  • Fully GLES 2.0 compliant. Given a host GPU that has conformant desktop OpenGL drivers, the emulator now passes 100% of CTS dEQP-GLES2 must-pass.
  • Swiftshader as a pure software renderer on the host
  • Initial IPV6 support.
  • Improved pipe performance - Android Pipe, the main communication channel between the emulator and Android OS, is much (order of magnitude) faster, has lower latency and has better threading performance (especially noticeable on x64 images). This improves ADB push/pull speed, 3D acceleration support and overall responsiveness of the emulator.
  • Improved audio support
  • Improved video playback performance. The emulator now stores all video color buffers in host/guest shared memory and performs any needed final YUV->RGB conversion in the GPU. 1080p30 (even 60) should be well within reach of most systems now. (but only when new images are released)
  • Faster disk IO - Emulator now uses separate thread to dispatch disk IO, resulting in much lower latency and improved throughput (~1.5x sequential, ~5x random access).
  • Improved graphics performance. Android Pipe improvements have also increased graphics performance! In addition, the emulator will use GPU-side buffers (glBindBuffers / glBufferData) when the guest requests them, decreasing CPU overhead in some apps. More to come when new system images are released.
  • Various GUI enhancement

Android SDK Tools Revision 25.3.0 (Feb 2017)

posted Feb 8, 2017, 5:19 PM by Chris Iremonger   [ updated Feb 9, 2017, 10:14 AM ]

We have just released Android SDK Tools 25.3.0 to the canary channel to give developers an early look at some of our changes.

Dependencies:
  • Android SDK Platform-tools revision 24 or later.
Changes:
  • Android Emulator is removed from this package and moved to a different SDK directory. See the new Android Emulator Release Notes. This change is backward compatible with older studio versions.
  • "android avd" command-line functionality replaced with new avdmanager tool. 
  • Obsolete/deprecated tools have been removed:
    • android
    • ddms
    • draw9patch
    • hierarchyviewer
    • traceview
    • ant scripts
    • Project and activity templates
  • Executables have been moved to bin/
    • jobb
    • lint
    • monkeyrunner
    • screenshot2
    • Uiautomatorviewer
  • Enhanced sdkmanager
    • View and accept all licenses from the command line
    • Improved verbose-mode package list
Please file feedback on b.android.com for any issues you find in this update.

Post Updates:
  • February 9: 
    • It appears the verbose mode did not make it into this release and should come in the next update. [bug: 229373]
    • Running "avdmanager --list" results in a ClassCastException [bug: 233816]

Android Studio 2.3 Beta 3 is now available

posted Jan 25, 2017, 7:13 PM by Chris Iremonger   [ updated Jan 31, 2017, 5:21 PM ]

We have just released Android Studio 2.3 Beta 3 to the Canary, Dev, and Beta Channels.


Android Studio 2.3 Beta 3 has already completed the first level of testing and wanted to share the bits with as soon as possible. Once the build passes all testing we will release it to the Beta channel. Is now live in the Beta Channel


Fixed Issues


Please continue to submit feedback as we are nearing a close to the 2.3 updates as we work to a stable release.

Update Jan 31st: Text updated to reflect the Beta channel release.

Android Studio 2.3 Beta 2 is now available

posted Jan 10, 2017, 1:50 PM by Chris Iremonger

We have just released Android Studio 2.3 Beta 2 to the Canary, Dev, and Beta Channels.


New or Noteworthy Changes

  • Moved to Gradle 3.3 Stable from 3.3 RC1 in Android Studio 2.3 Beta 1

  • If you do native development, please also update LLDB to 2.3.3614996


Fixed Issues

  • Performance Improvements in Project Sync and general Gradle integration with the IDE.

  • App Indexing

  • Lint Fixes

  • And a few General updates


Known Issues

  • Debugging: Issue 231497 - When a debug session is launched with instant run enabled, and if the application pauses at a breakpoint on the main thread, you may notice an ANR dialog pop up on the device. In beta 2, simply ignore the dialog, or press 'Wait'. The issue will disappear once you allow the main thread to continue execution, and it happens only once during application startup. We are adding a workaround for it in beta 3 and will have a full solution in the next major update of Android Studio.


We are very close to an RC build, so please continue to file bugs you are finding in the Beta releases of Android Studio.

Android Studio 2.3 Beta 1 is now available

posted Dec 15, 2016, 6:21 PM by Chris Iremonger

We have just released Android Studio 2.3 Beta 1 to the Canary, Dev, and Beta channels. In addition to the usual plethora of bug fixes, there are a number of noteworthy changes just in time for the holidays.


For those in the Beta Channel here are many of the changes since Android Studio 2.2.


Instant Run. In Android Studio 2.3 Canary 3, we introduced big change to how Instant Run works. Applying changes to a running applications play.png is no longer tied to the Run button. The Run button will now always perform an application restart. To apply code and resource changes in the running process, there is a new button hot-reload.png right next to it,  "Apply Changes", which attempts to hotswap the changes into the app. (The keyboard shortcut for Apply Changes is Control-F10 on Windows and Linux, and Cmd-Ctrl-R on Mac.)toolbar.png

The goal of this change is to make the Run button completely reliable. When you press Run, you can always be certain that your changes are reflected in the running app. Applying changes is now a separate action you take when you've made a tweak you want to see immediately. The Run button continues to use "cold swap" to build the app more quickly than a full APK reinstall, but we've limited it to Lollipop and above where we don't need to rely on unsafe mechanisms to do so.


IDE: In Android Studio 2.3 Canary 1 we upgraded the base IDE from IntelliJ 2016.1 to 2016.2, which adds a number of new features -- ligatures, breadcrumbs, editor background images, revamped UI for inspections, notifications and the debugger, and more. In Beta 1 we include a few additional fixes in OpenJDK that should help Mac users running Sierra.


Build Cache. In Android Studio 2.3 Canary 1,  we have enabled a new build cache (which uses a shared directory across projects to extract and compile libraries) by default. This turned out to break several features in the IDE that were making assumptions about the locations of libraries. In Android Studio 2.3 Canary 3, most of these bugs have been fixed; there are a few cosmetic ones remaining (such as listing library versions in the merged manifest editor and in documentation popups etc) that we'll be fixing next. Known issue.

new-palette.png


Layout Editor. There are several new features in the layout editor. First, the palette has been completely rewritten. The new palette offers previews of the widgets, better sorting, as well as search and filtering: click on the search icon findPlain.png to find a widget. Second, search and filtering now also works in the property inspector. And third, you can now customize the set of properties shown for a given widget type in the inspector. In the all properties table, click on the star icon favorites.pngto favorite the properties you want to see for this type of widget, and from now on these properties will be shown in the Favorites section in the component inspector.


Additionally, Since Android Studio 2.3 Canary 1, the layout editor now supports chains and ratios for ConstraintLayout.


In Android Studio 2.3 Canary 3 we reworked the internal architecture to improve the performance and reliability, in Beta 1 we included a number of bug fixes and further refinements. We are working hard to offer a solid solution for our stable release. Please continue to file bugs and feedback at b.android.com.


App Links Assistant. Android App Links allow your users to seamlessly deep link into your app experience. Adding Android App Links support in your app is now easier with this new experience in Android Studio. Just go to Tools > App Links Assistant in Android Studio to get started.


Lint. In Android Studio 2.3 Canary 3, the command line HTML reports have been overhauled -- instead of the old dark Holo look, they now have a Material design look, and the included code snippets are syntax highlighted etc.

From Android Studio 2.2, lint now has "baseline support" which lets you check in a current set of warnings -- and from now on, only new issues are reported. This lets a project with a lot of technical debt set a baseline and then break the build only when new issues are introduced, without having to go and fix all existing issues first. In order not to forget about the technical debt though it creates an info-level issue which tells you that you've filtered out bugs.lint-html.png


Additionally, there are many new lint checks. Some examples include enforcing the new @RestrictTo and @VisibleForTesting(otherwise=intended) annotations in support library 25, flagging obsolete SDK_INT checks, making sure animated properties are valid and not renamed in release builds,flagging potential wifi manager memory leaks, and many more.


Learn more about the new lint checks, and the baseline support, in this tech doc.


Data binding: Several editor bugs were fixed, among them the frequently reported problem with functional expressions. The editor parser now handles these properly.


Dual debugger: In Android Studio 2.3 Canary 3, the Hybrid debugger has been renamed to Dual debugger.


Known Issues: In addition to the known issue around build caches, we also found an Instant Run issue when you don't define a version in your build.gradle file the App won't install. A fix is already in place and should be available in Beta 2.

You can find a full list of Android Studio 2.3 bug fixes including work that is already underway for Beta 2.


As always we value ever bug filed, so please test out our new features and let us know if you run into any problems on b.android.com.

Android Studio 2.3 Canary 3 is now Available

posted Dec 12, 2016, 8:01 PM by Chris Iremonger

We have just released Android Studio 2.3 Canary 3 to the Canary and Dev channels. The gradle plugin should be available from JCenter within the next 24 hours.


In addition to the usual plethora of bug fixes, there are a number of noteworthy changes in this release:


Instant Run. We've made a big change to how Instant Run works in this release. Applying changes to a running applications is no longer tied to the play.png Run button. The Run button will now always perform an application restart. To apply code and resource changes in the running process, there is a new hot-reload.png button right next to it,  "Apply Changes", which attempts to hotswap the changes into the app. (The keyboard shortcut for Apply Changes is Control-F10 on Windows and Linux, and Cmd-Ctrl-R on Mac.)

toolbar.png

The goal of this change is to make the Run button completely reliable. When you press Run, you can always be certain that your changes are reflected in the running app. Applying changes is now a separate action you take when you've made a tweak you want to see immediately. The Run button continues to use "cold swap" to build the app more quickly than a full APK reinstall, but we've limited it to Lollipop and above where we don't need to rely on unsafe mechanisms to do so.


Build Cache. In Android Studio 2.3 Canary 1,  we have enabled a new build cache (which uses a shared directory across projects to extract and compile libraries) by default. This turned out to break several features in the IDE that were making assumptions about the locations of libraries. In Android Studio 2.3 Canary 3, most of these bugs have been fixed; there are a few cosmetic ones remaining (such as listing library versions in the merged manifest editor and in documentation popups etc) that we'll be fixing next. Known issue.


new-palette.png

Layout Editor. There are several new features in the layout editor. First, the palette has been completely rewritten. The new palette offers previews of the widgets, better sorting, as well as search and filtering: click on the search icon findPlain.png to find a widget. Second, search and filtering now also works in the property inspector. And third, you can now customize the set of properties shown for a given widget type in the inspector. In the all properties table, click on the star icon favorites.pngto favorite the properties you want to see for this type of widget, and from now on these properties will be shown in the Favorites section in the component inspector.

In this build we've reworked the internal architecture to improve the performance and reliability, and there are some rough edges remaining that we'll be addressing in the next build. For example, the blue print mode is missing labels.


App Links Assistant. Android App Links allow your users to seamlessly deep link into your app experience. Adding Android App Links support in your app is now easier with this new experience in Android Studio. Just go to Tools > App Links Assistant in Android Studio to get started.



Lint. The command line HTML reports have been been overhauled -- instead of the old dark Holo look, they now have a Material design look, and the included code snippets are syntax highlighted etc.


lint-html.png

Data binding: Several editor bugs were fixed, among them the frequently reported problem with functional expressions. The editor parser now handles these properly.


Dual debugger: The Hybrid debugger has been renamed to Dual debugger.


ProGuard version update: We have upgraded the ProGuard version that the Android Plugin for Gradle uses to ProGuard 5.3.2.

SDK Patches: After running into a patching issue with SDK updates, I happy to report that we are now serving patches for the SDK again. Over the coming weeks, we will continue to offer more patches on more components.

As always please let us know if you run into an issue. We are very close to moving this build to our beta channel and would love your feedback on this build.

1-10 of 313