I am looking at the chrisbanes/cheesesquare and I am trying to put TabLayout with a Toolbar inside a CollapsingToolbarLayout, and here is my code
Here is my idea of doing this.
I place tab layout outside the AppBar and wrap it with vertical Linear Layout and set the position like this
If you don't wrap TabLayout with another twice height Layout. When you set layout_anchor to AppBar, only half of TabLayout will be in AppBar.
Here is my whole XML file.
I'm not sure if these set of dp value will fit your screen size but it do with mine. If anyone has better answer please share.
Sorry if i make a mistake on my code or my english.Thank you!!