4

The image below is what the PagerTitleStrip looks like when alpha value is set to 0.5:

enter image description here

I expect the title strip to be semi opaque. Instead, as you can see, the title strip is not transparent at all. Even if I set alpha value to 0, the title strip just reduces to same background color of view pager but is still blocking the scrollview below.

I have programmatically moved the scrollview to align with the top, so the title strip is indeed overlay on top of the scrollview. Among the things that I've tried (individually):

titleStrip.setBackground(null)  // doesn't work
titleStrip.setAlpha(0)          // doesn't work
titleStrip.getBackground.setAlpha(0) // doesn't work

android:alpha="0.0"             // set in layout xml of title strip, doesn't work
android:visibility="invisible"  // this will give a solid background color

How can I make the pagerTitleStrip to have transparent effect?

Neoh
  • 15,906
  • 14
  • 66
  • 78

0 Answers0