check if using X11 or not before calling xprop