I adding View (button) programally in Linearlayout.LinearLayout is layouted by XML in Fragment.
I want to get button width, but always return 0.
I googled this problem,
getWidth work only onWindowFocusChanged.
public void onWindowFocusChanged(boolean hasFocus) { }
but Fragment do not have this method.
How to get View width in Fragment?