get screen width and height
prevent completion candidates popup from showing outside screen