What is the height of the Android Toolbar introduced in Lollipop? It\'s a quite simple question but I haven\'t found an answer here except for the ActionB
Call this method to get the value programmatically:
public int getToolBarHeight() {
int[] attrs = new int[] {R.attr.actionBarSize};
TypedArray ta = getContext().obtainStyledAttributes(attrs);
int toolBarHeight = ta.getDimensionPixelSize(0, -1);
ta.recycle();
return toolBarHeight;
}