frame-monitor-attributes

frame-monitor-attributes is a compiled Lisp function in `frame.el'.

(frame-monitor-attributes &optional FRAME)

Return the attributes of the physical monitor dominating FRAME.
If FRAME is omitted or nil, describe the currently selected frame.

A frame is dominated by a physical monitor when either the
largest area of the frame resides in the monitor, or the monitor
is the closest to the frame if the frame does not intersect any
physical monitors.

See `display-monitor-attributes-list' for the list of attribute
keys and their meanings.