Function: hycontrol-set-frame-width

hycontrol-set-frame-width is a byte-compiled function defined in hycontrol.el.

Signature

(hycontrol-set-frame-width FRAME WIDTH &optional PRETEND PIXELWISE)

Documentation

Set text width of frame FRAME to WIDTH columns and fit it to the screen.

Optional third arg PRETEND non-nil means that redisplay should use WIDTH columns but that the idea of the actual width of the frame should not be changed.

Optional fourth argument PIXELWISE non-nil means that FRAME should be WIDTH pixels wide. Note: When `frame-resize-pixelwise’ is nil, some window managers may refuse to honor a WIDTH that is not an integer multiple of the default frame font width.

Source Code

;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/hycontrol.el
(defun hycontrol-set-frame-width (frame width &optional pretend pixelwise)
  "Set text width of frame FRAME to WIDTH columns and fit it to the screen.
Optional third arg PRETEND non-nil means that redisplay should use WIDTH
columns but that the idea of the actual width of the frame should not
be changed.

Optional fourth argument PIXELWISE non-nil means that FRAME should be
WIDTH pixels wide.  Note: When `frame-resize-pixelwise’ is nil, some
window managers may refuse to honor a WIDTH that is not an integer
multiple of the default frame font width."
  (let ((x-origin (hycontrol-frame-x-origin))
	(y-origin (hycontrol-frame-y-origin))
	(frame-resize-pixelwise t))
    (set-frame-width frame width pretend pixelwise)
    (hycontrol-frame-fit-to-screen frame x-origin y-origin)))