[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Adapting to changing X display size while Emacs is running
From: |
Ludwig, Mark |
Subject: |
Adapting to changing X display size while Emacs is running |
Date: |
Tue, 13 Jan 2015 21:44:28 +0000 |
Greetings,
Is there any way to get the current dimensions of the X
display on which Emacs is displaying one or more frames?
I'm looking to adapt to changing display size while Emacs is
running.
I'm actually using eXceed, and not sure if changing display
size is even a standard feature in X, but what I have for
startup geometry looks like:
Emacs*geometry: 141x51-5+5
It's the "-5" part that changes, since it's relative to the
width of the display. When the display has changed, I'd
like to be able to move the frame accordingly, so it's again
near the right edge of the display.
I've tried using: (set-frame-position frame -5 5)
That doesn't know the current size of the display; it works
off what the size of the display was when Emacs started,
apparently. This is also apparent in the output of:
(x-display-pixel-width)
Any way to update this without restarting Emacs?
Thanks!
Mark
- Adapting to changing X display size while Emacs is running,
Ludwig, Mark <=