Questions tagged [android-design-library]

The Design package provides APIs to support adding material design components and patterns to your apps.

The Design Support library adds support for various material design components and patterns for app developers to build upon, such as navigation drawers, floating action buttons (FAB), snackbars, and tabs.

744 questions
110
votes
13 answers

How can I be notified when a Snackbar has dismissed itself?

I'm using a Snackbar from the com.android.support:design:22.2.0 library. I'm using it to undo deletions. To make my life easier, I'm going to make the UI look like things are actually deleted from the data source, and if the undo button in the snack…
108
votes
7 answers

What is CoordinatorLayout?

Just had a look at the demo app of new Android support design library. It's provided by Chris Banes on github. Throught the app, CoordinatorLayout is used Heavily. Also, many of the support design library classes such as FloatingActionButton,…
106
votes
2 answers

Overlap scrolling view with AppBarLayout

I want to implement the 'Flexible Space with overlapping content' pattern from the Material design scrolling techniques, such as in this video: My XML layout right now looks like:
105
votes
20 answers

Android Multiline Snackbar

I'm trying to leverage new Snackbar from Android Design Support Library to display multiline snackbar, as shown in http://www.google.com/design/spec/components/snackbars-toasts.html#snackbars-toasts-specs: import…
104
votes
24 answers

How to set support library snackbar text color to something other than android:textColor?

So I've started using the new Snackbar in the Design Support Library, but I found that when you define "android:textColor" in your theme, it applies to the text color of the snackbar. This is obviously a problem if your primary text color is…
100
votes
17 answers

TextInputLayout not showing EditText hint before user focus on it

I am using recently released Android Design Support Library to show floating label with EditTexts. But i am facing the problem that the Hint on the EditText is not showing when UI is rendered, but i see the Hint after i focus on the EditTexts. My…
Shajeel Afzal
  • 5,913
  • 6
  • 43
  • 70
91
votes
6 answers

TabLayout Tab Title text in Lower Case

I have used android.support.design.widget.TabLayout in my application with Min SDK 15. By default it takes Tab title in capitals but I want it to make in "textCapsWord". I tried adding Style as suggested here and here. But unfortunate both doesn't…
89
votes
2 answers

NavigationView and custom Layout

I'm using the Designs Support Libraries NavigationView like this:
85
votes
9 answers

TabLayout (Android Design Library) Text Color

I'm using the new TabLayout from the Android Design library. I managed to set the textcolor statelist using tabLayout.setTabTextColors(colorstatelist) How can i achieve the same using styles.xml?
sebastian
  • 2,610
  • 2
  • 17
  • 28
79
votes
9 answers

How to customize item background and item text color inside NavigationView?

I wanna achieve something like this shown in the Material Design Docs. colorControlHighlight is used for the Background on checked items. I need to customize: background unchecked text color checked text color unchecked
74
votes
15 answers

How to set custom typeface to items in NavigationView?

With the new NavigationView, we are able to set a drawer's items through a menu resource in XML. With that, we can set each item with something like
Júlio Zynger
  • 1,168
  • 1
  • 9
  • 12
72
votes
5 answers

Android NavigationView menu group divider

Android support design library provide NavigationView: menu/navigation_drawer_items:
Shaddow
  • 3,175
  • 3
  • 22
  • 42
71
votes
4 answers

TabLayout tab style

I use new TabLayout from com.android.support:design library. I want to change background of the selected/unselected tabs. I look at sources and found only tabBackground attribute that change all tabs colour and does not control selected tab…
IliaEremin
  • 3,338
  • 3
  • 26
  • 35
65
votes
2 answers

How to disable scrolling of NestedScrollView&CollapsingToolbarLayout, for example when there is no more content below?

Background I try to add the same functionality as shown on many apps, where the upper area of the screen shrinks&expands according to the scrolled content. For this, I use Google's design library, as shown on the CheeseSquare sample. The…
62
votes
9 answers

Android - footer scrolls off screen when used in CoordinatorLayout

I have an AppBarLayout that scrolls off screen when scrolling a RecyclerView. Below the RecyclerView there is a RelativeLayout that is a footer. The footer is shown only after scrolling up - it behave like it has…
1
2
3
49 50