W3C home > Mailing lists > Public > w3c-wai-ua@w3.org > April to June 2010

Clarification on viewports

From: Greg Lowney <gcl-0039@access-research.org>
Date: Fri, 04 Jun 2010 16:15:04 -0800
Message-ID: <4C099708.4030304@access-research.org>
To: Bert Bos <bert@w3.org>
CC: WAI-UA list <w3c-wai-ua@w3.org>
Hi Bert,

I'm on the UAWG and working on issues about content overflowing its 
container, and I want to make sure we're using terms like 'viewport' 
consistently with CSS and other W3 specs. I'm hoping you can help find 
us get clarification from appropriate working groups.

In particular, it's clear that document windows, document tabs, and 
frames would all be viewports, but:

   1. If a div with fixed dimensions has content that overflows, and
      overflow:scroll or overflow:auto cause it to support scrolling, is
      it a viewport? (Note that from the USER'S perspective there is no
      difference between a scrolling frame and a scrolling div, so it
      would seem odd to have different user-interface requirements for
      the two.)
   2. Are listboxes and text input controls viewports, as the user can
      scroll their contents?
   3. If these things that behave like viewports are not called
      viewports, is there another term that would be more appropriate?
   4. I'm also a little unclear as canvas: when the CSS 2.1 spec says
      that "There is at most one viewport per canvas, but user agents
      may render to more than one canvas (i.e., provide different views
      of the same document)."; does that mean that a scrolling div would
      be (a) a viewport viewing a separate canvas, or (b) something
      other than a viewport viewing the same canvas, or (c) neither of
      the above? Similarly, would the areas inside scrolling list boxes
      and text entry boxes be separate canvases?

For handy reference, here are some definitions which failed the clarify 
these issues for me:


  Viewports in CSS

(From Visual formatting model - 
http://www.w3.org/TR/CSS21/visuren.html#viewport)

    *9.1.1 The viewport*

    User agents for continuous media
    <http://www.w3.org/TR/CSS2/media.html#continuous-media-group>
    generally offer users a viewport (a window or other viewing area on
    the screen) through which users consult a document. User agents may
    change the document's layout when the viewport is resized (see the
    initial containing block
    <http://www.w3.org/TR/CSS2/visudet.html#containing-block-details>).

    When the viewport is smaller than the area of the canvas on which
    the document is rendered, the user agent should offer a scrolling
    mechanism. There is at most one viewport per canvas
    <http://www.w3.org/TR/CSS2/intro.html#canvas>, but user agents may
    render to more than one canvas (i.e., provide different views of the
    same document).

(From Introduction to CSS 2.1 - 
http://www.w3.org/TR/CSS21/intro.html#canvas)


          2.3.1 The canvas

    For all media, the term canvas describes "the space where the
    formatting structure is rendered." The canvas is infinite for each
    dimension of the space, but rendering generally occurs within a
    finite region of the canvas, established by the user agent according
    to the target medium. For instance, user agents rendering to a
    screen generally impose a minimum width and choose an initial width
    based on the dimensions of the viewport
    <http://www.w3.org/TR/CSS21/visuren.html#viewport>. User agents
    rendering to a page generally impose width and height constraints.
    Aural user agents may impose limits in audio space, but not in time.


  Viewports in WCAG

(From Web Content Accessibility Guidelines (WCAG) 2.0 - 
http://www.w3.org/TR/WCAG20/)

    *viewport*

        object in which the user agent presents content

        /Note 1: /The user agent
        <http://www.w3.org/TR/WCAG20/#useragentdef> presents content
        through one or more viewports. Viewports include windows,
        frames, loudspeakers, and virtual magnifying glasses. A viewport
        may contain another viewport (e.g., nested frames). Interface
        components created by the user agent such as prompts, menus, and
        alerts are not viewports.

        /Note 2: /This definition is based on User Agent Accessibility
        Guidelines 1.0 Glossary
        <http://www.w3.org/TR/WAI-USERAGENT/glossary.html>.


  Viewports in UAAG

(From User Agent Accessibility Guidelines 2.0 - 
http://www.w3.org/WAI/UA/2010/ED-IMPLEMENTING-UAAG20-20100521/#def-viewport-toplevel)

    *view, viewport*
        The user agent renders content
        <http://www.w3.org/WAI/UA/2010/ED-IMPLEMENTING-UAAG20-20100521/#def-rendered-content>
        through one or more viewports. Viewports include windows,
        frames, pieces of paper, loudspeakers, and virtual magnifying
        glasses. A viewport may contain another viewport (e.g., nested
        frames). User agent user interface controls
        <http://www.w3.org/WAI/UA/2010/ED-IMPLEMENTING-UAAG20-20100521/#def-ui-control>
        such as prompts, menus, and alerts are not viewports.

        Graphical and tactile viewports have two spatial dimensions. A
        viewport may also have temporal dimensions, for instance when
        audio, speech, animations, and movies are rendered. When the
        dimensions (spatial or temporal) of rendered content exceed the
        dimensions of the viewport, the user agent provides mechanisms
        such as scroll bars and advance and rewind controls so that the
        user can access the rendered content "outside" the viewport.
        Examples include: when the user can only view a portion of a
        large document through a small graphical viewport, or when audio
        content has already been played.

        When several viewports coexist, only one has the current focus
        <http://www.w3.org/WAI/UA/2010/ED-IMPLEMENTING-UAAG20-20100521/#def-current-focus>
        at a given moment. This viewport is highlighted
        <http://www.w3.org/WAI/UA/2010/ED-IMPLEMENTING-UAAG20-20100521/#def-highlight>
        to make it stand out.

        User agents may render the same content in a variety of ways;
        each rendering is called a /view/. For instance, a user agent
        may allow users to view an entire document or just a list of the
        document's headers. These are two different views of the document.

        "top-level" viewports are viewports that are not contained
        within other user agent viewports.


     Thanks,
     Greg
Received on Friday, 4 June 2010 23:15:50 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 4 June 2010 23:15:52 GMT