Java tutorial
//package com.java2s; import android.app.Activity; import android.graphics.Point; import android.view.Display; public class Main { public static Point getScreenSize(final Activity a) { Display display = a.getWindowManager().getDefaultDisplay(); Point size = new Point(); display.getSize(size); return size; } }