I\'m working with the CollapsingToolbarLayout from the new Android Design Support Library.
I have set its title and it is working fine, the only problem I still have
That's a lot of work do achieve here by writing that much of code. I achieved that by 2 ways.
1 A simple workaround by using a View with TransparentBlack color
CODE>>
Code explaination:
1 The CollapsingToolbarLayout has a style with only a text size.
2 Default CollapsingToolbarLayout margin bottom is overridden to 16dp.
3. Our header with parallax collapseMode is a RelativeLayout with an ImaveView and a View.
4. This simple View with a BG at the bottom of the top header Relative layout with colour of contrast (here #77000000), acts as the BG for CollapsingToolbarLayout's collapsed Title in white color.
Images for style 1:
a) When CollapsingToolbarLayout Title is Expanded Fully:
b) When CollapsingToolbarLayout Title is shrinking upon scroll up:
2 Answer above
Method is mentioned already by Joao Ferreira.
Here is what it looks like with shadowRadius=16: Notice the Shadow
PS please update or ask more if any confusions :)