Function: posframe--set-frame-size-and-position

posframe--set-frame-size-and-position is a byte-compiled function defined in posframe.el.

Signature

(posframe--set-frame-size-and-position SIZE-INFO POSITION PARENT-FRAME-WIDTH PARENT-FRAME-HEIGHT)

Source Code

;; Defined in ~/.emacs.d/elpa/posframe-20260415.14/posframe.el
(defun posframe--set-frame-size-and-position (size-info position parent-frame-width parent-frame-height)
  (let ((posframe (plist-get size-info :posframe))
        (width (plist-get size-info :width))
        (height (plist-get size-info :height)))
    (unless (and width height)
      (user-error "Width and height must be specified together"))
    (set-frame-size-and-position-pixelwise
     posframe
     (* (default-font-width) width)
     (* (default-line-height) height)
     (car position) (cdr position))
    (posframe--save-new-posframe-position posframe position
                                          parent-frame-width
                                          parent-frame-height)
    (posframe--make-frame-visible posframe)))