펌 OK (출처 표시), 상업적 이용 NO, 컨텐츠 변경 NO

Display dis = ((WindowManager)getSystemService(WINDOW_SERVICE)).getDefaultDisplay();

int x = dis.getWidth();

int y = dis.getHeight();


이렇게 하면 디바이스의 가로,세로 길이가 나온다. 단위는 픽셀