Questions tagged [android-collapsingtoolbarlayout]

CollapsingToolbarLayout is a wrapper for Toolbar that provides several visual effects that are bind to the content scroll events.

CollapsingToolbarLayout is a ViewGroup that serves as a wrapper for Toolbar providing several visual effects to it. The class is part of the library.

The effects provided by the class include

  • Collapsing title
  • Content scrim
  • Status bar scrim
  • Parallax scrolling children
  • Pinned position children

For the correct behavior the CollapsingToolbarLayout has to be direct child of AppBarLayout placed within a CoordinatorLayout that contains a vertically scrollable View with app:layout_behavior parameter specified. The effects are bind to the vertical scrolling of this View.

For more information visit class reference or the Android developers blog.

1241 questions
17
votes
5 answers

RecycleView leaves empty space at the bottom because of toolbar

Update: Actual issue is with CoordinatorLayout not with RecycleView. Instead of using RecycleView I tried TextView inside ScrollView and it is the same issue. Something is not aligned if you have Toolbar as ActionBar and using CoordinatorLayout…
17
votes
3 answers

Title in expanded CollapsingToolbarLayout not displayed correctly

So, I got a wierd problem with my CollapsingToolbarLayout in my project. After my activity starts this is how my toolbar title appears: After collapsing the layout is like this: The original title text in the example is: "UPC VONALKODOS TERMEK" I…
17
votes
5 answers

Add icon with title in CollapsingToolbarLayout

I am using CoordinatorLayout to get this effect : Here is the layout code:
17
votes
2 answers

Smooth scroll and Fling with NestedScrollView,AppBarLayout and CoordinatorLayout

I am working on an application where I'm using AppBarLayout with CollapsingToolbarLayout and NestedScrollView. I have successfully implemented this and it is working fine. Now what i am trying to do is, that on fling(fast swipe up) on the …
17
votes
4 answers

How to put RecyclerView below Toolbar and above TabLayout and ViewPager also handling responses to scrolls in a custom manner?

I want to create a layout like the below image: A CoordinatorLayout which contain : CollapsingToolbarLayout( contain ImageView & Toolbar) RecyclerView TabLayout ViewPager( that each fragment of it contain a RecyclerView) I wanna responding to…
16
votes
1 answer

Extra space between Collapsing Toolbar Title and Home/Up button

I'm trying to use Collapsing Toolbar with Home/Up button. After toolbar collapses, there is an extra space between arrow and title text, which I'd like to get rid of. I attached two images, with and without layoutboundaries, to illustrate my…
Libelle
  • 806
  • 7
  • 14
16
votes
4 answers

Whatsapp like Collapsing Toolbar

In my app, I would like to implement Whatsapp home page like collapsible toolbar. That is, while scrolling down the list, the toolbar should go up and the tabs should pin at the top. How can I achieve this? Here is my appbar…
Jayakrishnan Salim
  • 977
  • 1
  • 10
  • 24
16
votes
3 answers

Multiline Text view in CollapsingToolbarLayout instead of Title

I want to display some text in Collapsing toolbar instead of title. Problem is that text may contain more than 1 line. So I need to use custom view, but can't understand how to implement it in proper way. Also, how to set minimal CollapsingToolbar…
16
votes
3 answers

Nested RecyclerView in ViewHolder breaks Collapsing Toolbar Layout

I have a vertical RecyclerView hosted in a CoordinatorLayout featuring a collapsing toolbar layout. The ViewHolder for this RecyclerView contains yet another RecyclerView with a GridLayoutManager. The reason for this nesting is that the inner…
15
votes
6 answers

Android Accessibility - Unable to focus on any element in the Appbar

I have this issue in 2 of my activities. When I navigate using keyboard Tab keys or arrow keys - I am unable to reach any element in the App bar. 1) Activity 1 -> My appbar has a hamburger menu icon to access the NavigationView. I am not able to…
15
votes
1 answer

Collapsing Toolbar bouncing glitch since support lib 26.0.0

Since update of Android Support libs from version 25.4.0 to 26.0.0 (up to 27.0.0) I'm experiencing some weird behaviour in Collapsing Toolbar inside activity. See difference on these gifs: 25.4.0 26.0.0 (+) When scrolling up you will see strange…
15
votes
4 answers

Custom Collapsing Toolbar smooth title resizing

I'm using a custom Collapsing Toolbar Layout, which has a Title and a Subtitle. I got the title to collapse and animate on a curved path, but the part of the title becoming smaller as collapsing isn't smooth. It resizes in a jagged sort of way. This…
amitairos
  • 2,907
  • 11
  • 50
  • 84
15
votes
4 answers

CollapsingToolbarLayout.setTitle(title) does not work after changing appbarLayout

I want to load a fragment with the collapsed collapsingToolbar (i.e. in its non-expanded form). When I set the title of the collapsingToolbar without altering the appbarLayout layout parameters, the title is set properly and I can see the title. The…
VIN
  • 6,385
  • 7
  • 38
  • 77
15
votes
6 answers

collapsing toolbar layout like google play store

i want to make a collapsing toolbar layout like google play store. like this: https://sendvid.com/ugjspx8r and here is my layout: http://sendvid.com/s4mx3xem how can i do that with new android support library? here is my layout xml…
15
votes
4 answers

Toolbar inside CollapsingToolbarLayout, Toolbar title not showing

I used CollapsingToolbarLayout as the parent of Toolbar, below it the layout