Re: 'fixed' positioning [WAS: Header, Footer, and Sidebars]

On Nov 26, 11:21am, Andrew n marshall wrote:

> On Tuesday, November 25, 1997 11:06 PM, Todd Fahrner
> [SMTP:fahrner@pobox.com] wrote:
> > Hey that's brilliant Andrew! I'm stuck in Mac-land at home tonight, so
> > can't evaluate as closely as I'd like, but you know CSS2 proposes a means
> > to a similar end: the "fixed" property:

> With regards to 'fixed':
>
> First off, there is a Documentation error in the 4 Nov 1997 release.  At
> the below reference, 'fixed' got dropped from the value list.
> 	http://www.w3.org/TR/WD-CSS2/flowobj.html#propdef-position

Yep. Thanks.

> Secondly, 'fixed doesn't solve the problem.  For example, take my sidebar
> DIV.  If I wanted the width to just barely fit the content, I could do this
> by controlling overflow.  The problem this causes is the width and left
> edge of the main DIV are determined until render time.

OK, it sounds like you are asking for computed values (100% - 35em, for
example)

> I could specify widths in em units, but then there is a big difference
> between monospaced and non-monospaced fonts.

No, at the same point size both fonts will have the same size ems *as defined
by CSS*

>  How many em units is the word
> 'mammals'? 'lift'? 'LIFT'?  There isn't a good answer because it is font
> dependent.

OK, if you want to specify a size that just fits a single line of text
then you are out of luck (there was a proposal to have font-size: auto
which would deal with this, but it got hairy for multiple lines and similar
common cases).

> What I need is the concept of remaining space.  Then, for any reasonable
> length of the sidebar is, I could always be assured the main DIV lines up
> along side it properly.

Presumably setting the sidebar to 20% and the main DIV to 80% (or whatever)
doesn't meet your needs?


> Does it make sense to be able to set fixed positioning to an element deep
> within the document tree?
> Shouldn't fixed positioning be with respect to the closest absolutely
> positioned, fixed positioned, or scrollable parent, as opposed to just the
> canvas?

No - at least, that is not the current design

> If not, how do I fix something to my main <DIV> as a watermark?

Relative to the closest relatively positioned element, which sets up a new
coordinate system for it's children.

-- 
Chris Lilley, W3C                          [ http://www.w3.org/ ]
Graphics and Fonts Guy            The World Wide Web Consortium
http://www.w3.org/people/chris/              INRIA,  Projet W3C
chris@w3.org                       2004 Rt des Lucioles / BP 93
+33 (0)4 93 65 79 87       06902 Sophia Antipolis Cedex, France

Received on Thursday, 27 November 1997 11:16:27 UTC