I have 5 buttons on tab widget, 2 from left and 2 from right are the same size as background of tabwidget. The central button needs to be twice higher than tabwidget.
if I put all buttons into tabhost, tabhost’s size rises equels to the biggest button (central button).
How to prevent it?
I want to make something like this. The background height of tabbar needs to be equel to red square’s height.

Yes, you can do this by following Xml code –
center_tab_indicator.xml
tab_indicator.xml
By use of above two XML You can get your desired output. For more, have a look at here You will get an out put like below –
Have a look at that. There will be sample project also available. Hope it helps you.