W3C home > Mailing lists > Public > www-style@w3.org > July 1998

Re: OBJECT, inheritance, and rendering

From: David Baron <dbaron@netaxs.com>
Date: Thu, 30 Jul 1998 11:57:28 -0400 (EDT)
Message-Id: <199807301557.LAA20536@unix2.netaxs.com>
To: www-style@w3.org
Cc: dbaron@netaxs.com
[Replying to a little bit written by everyone, so I'm not going to 
quote all the little bits...]

It seems to me that there are really two different styles that need to
be specfied for an OBJECT tag, and that we really need a way of
specifying either or both.  I think that the normal mechanism should
apply only to the alternate contents between <OBJECT> and </OBJECT>, and
that there should be some other mechanism for handling the data included
by the object.  This is probably the most acceptable solution because
the data that are included are *usually* not in a form where CSS has
much application.

I agree with Nir Dagan and Braden McDaniel that there should *not* be
any inheritance from the CSS in a document to the OBJECT within that
document.  This implies that style information for an OBJECT should
apply to the alternate text.  However, I also think that style
information should be able to be specified for an OBJECT, probably by a
new CSS selector for objects (by type) and by an OBJSTYLE tag within
object.

Todd Fahrner wrote:
>If OBJECT should render truly as a thing unto itself, inheriting nothing
>from its parents, in what functional respects does OBJECT differ from
>IFRAME, other than the "alternate formats/markup" feature proposed for
>OBJECT?

I think OBJECT inclusion of an html file should not differ much from an
IFRAME ... I think there is no other way to do it that covers all the
various potential problems.  A text file (text/plain or text/html)
should be included in a frame that renders the document just as it would
be rendered alone in a window of that size (i.e., a text file would not
have lines wrapped but an html file would).  However, if that document
had a default background of transparent (the CSS default -- but maybe
the concept of the canvas actually changes this???) -- maybe the
background color of the document containing the object should show
through. (as Braden McDaniel suggested)  For some images, this is how
some parts of the image are designed.  In other words, I think
transparency should only be used when it is specified in the contained
OBJECT until new features of CSS are made to allow otherwise.  I think
thus that if one wants to set a background color for the OBJECT, then
the whole object should be enclosed in a DIV or SPAN.

Braden McDaniel wrote:
>Already, if I had the style
>
>	IMG { background-color: blue }
>
>... What would be the expected behavior using an image with an
>alphachannel?
>
>	<IMG SRC="myimage.png" ALT="My Image">
>
>Wouldn't you expect the transparent portions of the image to show through
>blue? I would. Therefore I'd also expect this code to render the same way:
>
>	<OBJECT DATA="myimage.png" TYPE="image/png"
>	STYLE="background-color: blue">My Image</OBJECT>

I wouldn't expect this to render the same way because object contains
two different things, the object itself and the alternate text, and is
therefore a very different animal.  It seems a little odd to put such a
big change into HTML from past methods, but it was done.

Finally, to put in my 2 cents about whether <H1> or <P> tags within an
object break up a <P> outside of the object... I would have to say that
I think the HTML standard is rather unclear on this.  It specifies the
contents within the OBJECT (the alternate text) to be %flow, but I'm not
sure what this means about rendering of anything, and anyway it probably
applies to the alternate text but not the OBJECT itself.  I tend to think
that the OBJECT itself should be treated as inline, so there should be a
<P> or a <DIV> around it if one wants to make it a block.

David Baron

--------------------------------------------------------------------
L. David Baron    | Entering Freshman, Harvard
dbaron@netaxs.com | < http://www.psych.upenn.edu/~baron/david/ >
Webmaster, International Weather Satellite Imagery Center, etc.
--------------------------------------------------------------------
Received on Thursday, 30 July 1998 12:11:48 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:53:55 GMT