Re: Overlaying inline images

Dave Raggett (dsr@hplb.hpl.hp.com)
Wed, 23 Nov 94 18:31:21 GMT


From: Dave Raggett <dsr@hplb.hpl.hp.com>
Message-Id: <9411231831.AA25279@dragget.hpl.hp.com>
Subject: Re: Overlaying inline images
To: www-talk.info.cern.ch%dragget.hpl.hp.com@hplb.hpl.hp.com
Date: Wed, 23 Nov 94 18:31:21 GMT
Cc: www-html@www0.cern.ch

David Koblas writes re: graphics overlays:

> ps.  I don't remember what the FIG element is/was in HTML+, but
> I think there is some similarities here.

I am busily working on preparing an initial draft for HTML 3.0 prior
to the IETF meeting in early December. The declaration for FIG and
OVERLAY is given below, and full explanations will be given in the
online documentation.

Can we move further discussion of this topic to www-html?

The current idea is to allow a sequence of overlays to be positioned
at given offsets on the underlying figure. The desired figure width
and height can be specified via attributes. This is intended to
support a simple negotiation mechanism for the image size when inlining
data using some form of OLE or OpenDoc style embedding.

The advantage of providing explicit overlays in HTML is that you can
cache each layer independently. We could go on to define attributes
for say delayed loading of overlays. What do people think?

I am also very interested in identifying opportunities for a new graphics
format which meets the special needs of the Web. For example, using object
oriented techniques to blur the distinction between painting and drawing
and doing more work at the client to reconstruct the image. This new format
would itself allow inlining (or sharing) of objects from different parts
of the network, e.g. objects that can draw fractal texture gradients in 
2D or 3D. Perhaps we should aim at extending VRML to support this role?

The following is an extract from the draft HTML 3.0 DTD:

<!--
  The element contains text for use in non-graphical displays. Note that
  you can use the shape attribute in anchors to specify hotzones on images.
  This provides for local processing of pointer clicks and a unified method
  for dealing with graphical and non-graphical displays.

  Text is flowed around figures when the figure is left or right aligned.
  You can request the browser to move down until there is enough room for
  the next element, see the CLEAR and NEED attributes (in %needs)

  Note that units (em's or pixels) are specified as part of the %needs entity.
-->

<!ELEMENT FIG - - (OVERLAY*, CAPTION?, %flow;)>
<!ATTLIST FIG
        %attrs;
        src  %URI;  #REQUIRED  -- URI of document to embed --
        base IDREF  #IMPLIED   -- for resolving relative links --
        urn CDATA   #IMPLIED   -- universal resource name --
        align  (left|center|right|justify) #IMPLIED
        width  NUMBER #IMPLIED -- desired width in units --
        height NUMBER #IMPLIED -- desired height in units --
        hspace NUMBER #IMPLIED -- whitespace above/below fig in units --
        vspace NUMBER #IMPLIED -- whitespace to left/right in units --
        ismap (ismap) #IMPLIED -- pass clicks to server --
        %needs; -- for control of text flow --
        >

<!ELEMENT OVERLAY - O EMPTY -- image overlay -->
<!ATTLIST OVERLAY
        seq    NUMBER    0     -- display order, 0 is immediate --
        src  %URI;  #REQUIRED  -- URI of image overlay --
        base IDREF  #IMPLIED   -- for resolving relative links --
        urn CDATA   #IMPLIED   -- universal resource name --
        x      %FLOAT;   0     -- offset (0 - 1.0) from left --
        y      %FLOAT;   0     -- offset (0 - 1.0) from top --
        width  NUMBER #IMPLIED -- desired width in units --
        height NUMBER #IMPLIED -- desired height in units --
        units (em|pixel) pixel -- specifies units as em's or pixels --
        ismap (ismap) #IMPLIED -- pass clicks to server --
        >

--
Best wishes,

Dave Raggett
-----------------------------------------------------------------------------
Hewlett Packard Laboratories              email: dsr@hplb.hpl.hp.com
Filton Road, Stoke Gifford                tel:   +44 272 228046
Bristol BS12 6QZ                          fax:   +44 272 228003
United Kingdom