Question

I have required styles (from designer) applied on my TABs used in Actionbar for navigation and I use Actionbar Sherlock. They look perfectly from ldpi to xhdpi devices, but situation changes on xxhdpi devices. I have only 2tabs and except mentioned styling, I have the same code as Sherlock DEMO app in "Tab Navigation". I found 2 older simmilar questions not answered yet.

Stacked ActionBar tab bar not filling parent (I've got a simmilar problem, centered tabs. Sorry for inconvenience, I can't attach images because of rep points.) and action bar tabs not fill screen in android

Since the time of their posts, this is not only the issue of tablets, but now, there are many FULLHD (flagship) smartphones and this is becomming the big "design" issue.

I want my 2tabs to fill/match the full width of ANY device size, so in my case to fill 50% width each. Default Holo styled tabs doesn't look that bad (as shown in previous link), but my styled tabs on this big screen look much worse.

PS: Situation doesn't change if I make a text in tabs bigger or longer. Tabs don't adujst their width, instead they change their height and text takes 2 lines.

Was it helpful?

Solution

Unfortunatelly, this is a another JB changes: https://android.googlesource.com/platform/frameworks/base/+/b8139af3dcae80c0030afd0354dc424a7c72c3d9

One of solution: set target SDK 15 or lower.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top