|
From: | Gregory Heytings |
Subject: | Re: Frame shifted upwards upon changing font size |
Date: | Tue, 13 Sep 2022 13:53:00 +0000 |
(defun frame-center (&optional frame display) (interactive) (set-frame-position frame (/ (- (display-pixel-width display) (frame-pixel-width frame)) 2) (/ (- (display-pixel-height display) (frame-pixel-height frame)) 2)))I have different monitors with different sizes, and the function is transferring the frame to a different monitor.
In that case you need to use display-monitor-attributes-list to get the size of the appropriate monitor.
[Prev in Thread] | Current Thread | [Next in Thread] |