Support Library Revision Archive

This page provides details about older Support Library package releases. For the most recent Support Library releases, see Recent Support Library Revisions.

Revision 26.0.0 Beta 2

(June 2017)

Please note that 26.0.0-beta2 is a pre-release version. Its API surface is subject to change, and it does not necessarily include features or bug fixes from the latest stable versions of Support Library.

Important: The support libraries are now available through Google's Maven repository. You do not need to download the support repository from the SDK Manager. For more information, see Support Library Setup.

New APIs

API Diffs

Bug fixes

  • Android O SDK drop causes loss of italics in TextViews
  • Null pointer exception when connecting to MediaBrowserServiceCompat
  • TextInputLayout must set hints on onProvideAutofillStructure()
  • Stack overflow when using TextView autosize on O

Revision 26.0.0 Beta 1

(May 2017)

Please note that 26.0.0-beta1 is a pre-release version. Its API surface is subject to change, and it does not necessarily include features or bug fixes from the latest stable versions of Support Library.

Important: The support libraries are now available through Google's Maven repository. You do not need to download the support repository from the SDK Manager. For more information, see Support Library Setup.

Important changes

  • FragmentActivity.setSupportMediaController() and FragmentActivity.getSupportMediaController() have been removed. Please use the new static MediaControllerCompat.setMediaController() and MediaControllerCompat.getMediaController() methods.
  • BottomNavigationView now calls onNavigationItemReselected() when an already-selected item is selected, rather than calling onNavigationItemSelected().
  • All instances of the findViewById() method now return <T extends View> T instead of View. This change has the following implications:
    • This may result in existing code now having ambiguous return type, for example if there is both someMethod(View) and someMethod(TextView) that takes the result of a call to findViewById().
    • When using Java 8 source language, this requires an explicit cast to View when the return type is unconstrained (for example, assertNotNull(findViewById(...)).someViewMethod()).
    • Overrides of non-final findViewById() methods (for example, Activity.findViewById()) will need their return type updated.

New APIs

  • FragmentManager and Fragment have an isStateSaved() method to allow querying whether or not a transaction will be allowed without state loss. This is especially useful to check when handling an onClick() event before executing any transaction.
  • Path motion is supported in AnimatedVectorDrawableCompat. Path motion allows one object animator to change two properties at the same time based on one path; the path is specified as android:pathData in the animator’s XML).
  • Physics-based animation:
    • New FlingAnimation that supports animating with an initial velocity and smoothly slows down.
    • Subclasses of DynamicAnimation support animating custom property for any object.
    • Both SpringAnimation and FlingAnimation can now animate a float value without requiring a View or an Object to be associated with it.

    For more information, see the Spring animation and Fling animation preview pages.

  • Font support in XML:
    • ResourcesCompat.getFont allows loading font resources—including font-family XML—that may be used with TextView.setTypeface().
    • When using AppCompat, TextView supports specifying a font resource or font-family XML via the android:fontFamily XML attribute.
    • Use XML font-family to create families of fonts with style and weight variations. (If you use the support library classes to do this, use the app: attributes as well as the android: attributes.)
  • Downloadable fonts:
    • New FontsContractCompat that allows you to request fonts from a font provider instead of bundling them in your app.
    • Fonts can also be requested in XML and used in layouts.
  • Emoji compatibility library:
    • EmojiCompat can process a given CharSequence and add EmojiSpans.
    • EmojiTextView and other widgets to display emoji.
    • FontRequestEmojiCompatConfig to request emoji font from a font provider.
  • Autosizing TextView:
    • New methods in TextView