Function: window-width
window-width is a function alias for window-body-width, defined in
window.c.
Signature
(window-width &optional WINDOW PIXELWISE)
Documentation
Return the width of WINDOW's text area.
WINDOW must be a live window and defaults to the selected one. The return value does not include any vertical dividers, fringes or marginal areas, or scroll bars.
The optional argument PIXELWISE defines the units to use for the
width. If nil, return the largest integer smaller than WINDOW's pixel
width in units of the character width of WINDOW's frame. If PIXELWISE
is remap and the default face is remapped (see
face-remapping-alist), use the remapped face to determine the
character width. For any other non-nil value, return the width in
pixels.
Note that the returned value includes the column reserved for the continuation glyph.
Also see window-max-chars-per-line.
Probably introduced at or before Emacs version 24.1.