The Browser Viewport

The browser viewport is the window in the browser through which the document content is viewed. This is a fairly simple concept, but, again, it's a distinct one from containing blocks.

In positioning, in some cases, element boxes are positioned in relation to the viewport and not normal flow or containing blocks. So understanding the viewport is important (see Figure 12-4).

Figure 12-4. The Firefox browser with sidebar, menus, and status bar—the viewport is only the window through which you're seeing the document.

image

NOTE

It is considered conventional browser behavior to include a scrollbar in the viewport when the ...

Get Spring Into HTML and CSS now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.