How can I get the available height of the screen in Android? I need to the height minus the status bar / menu bar or any other decorations that might be on screen and I need it
I haven't tried different API's but I'm using these values to figure out whether or not the onscreen keyboard is up. Maybe you can try this and something comparable for width to get what you need?
Rect r = new Rect();
view.getWindowVisibleDisplayFrame(r);
int
screenHeight = view.getRootView().getHeight(), // height of the entire screen
appHeight = r.bottom - r.top, // height of the entire app
statusBarHeight = r.top, // height of the statusbar
pageHeight = view.getHeight(), // height of the app without title
appTitleHeight = appHeight - pageHeight, // height of the only the app title
topHeight = statusBarHeight + appTitleHeight;