I\'m trying to detect the size of the screen I\'m starting emacs on, and adjust the size and position the window it is starting in (I guess that\'s the frame in emacs-speak)
On ubuntu do:
(defun toggle-fullscreen () (interactive) (x-send-client-message nil 0 nil "_NET_WM_STATE" 32 '(2 "_NET_WM_STATE_MAXIMIZED_VERT" 0)) (x-send-client-message nil 0 nil "_NET_WM_STATE" 32 '(2 "_NET_WM_STATE_MAXIMIZED_HORZ" 0)) ) (toggle-fullscreen)