473,473 Members | 4,257 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

questions about CSS 2.1 spec?

I've bought two books on CSS, and found they're no good.
Now I'm reading "Cascading Style Sheets, level 2 revision 1
CSS 2.1 Specification" , but it's tough going.

I have lots of questions about parts in that spec. Does anyone know who can
answer them?
Is there maybe an "Annotated CSS 2.1 Spec" ? That is, one with extra
explanation added to every complex piece of text.

As an example of two of my questions:
In:
section 9.2 Block-level elements and block boxes
Text:
When an inline box contains a block box, the inline box (and its inline
ancestors within the same line box) are broken around the block. The line
boxes before the break and after the break are enclosed in anonymous boxes,
and the block box becomes a sibling of those anonymous boxes.
Question:
Should "... are enclosed in anonymous boxes ..." actually say "... are
enclosed in anonymous block boxes ..." !?
Question:
Could I please have an example of "inline ancestors within the same line
box" .

Note:
The two books that I bought, are:
"Cascading Style Sheets, The Definitive Guide", by Eric Meyer;
"Designing with Web Standards", by Jeffrey Zeldman .
Jul 20 '05 #1
5 1797
On Tue, 25 May 2004 13:56:21 +0200, Paul <pv******@xs4all.nl> wrote:

When an inline box contains a block box, the inline box (and its
inline
ancestors within the same line box) are broken around the block. The line
boxes before the break and after the break are enclosed in anonymous
boxes,
and the block box becomes a sibling of those anonymous boxes.

Question:
Should "... are enclosed in anonymous boxes ..." actually say "... are
enclosed in anonymous block boxes ..." !?
Question:
Could I please have an example of "inline ancestors within the same
line
box" .
I am pretty sure this means that

<span>lalala<p>lalala</p>lalala</span>

is really rendered as

<span>lalala</span><p><span>lalala</span></p><span>lalala</span>

Note:
The two books that I bought, are:
"Cascading Style Sheets, The Definitive Guide", by Eric Meyer;
"Designing with Web Standards", by Jeffrey Zeldman .


Those are quite reputable books. What do you find to be "no good" about
them?
Jul 20 '05 #2
"Paul" <pv******@xs4all.nl> wrote:
I've bought two books on CSS, and found they're no good.
Now I'm reading "Cascading Style Sheets, level 2 revision 1
CSS 2.1 Specification" , but it's tough going.
Note that CSS 2.1 is not yet a W3C Recommendation.
I have lots of questions about parts in that spec. Does anyone know who can
answer them?
Here is as good a place as any.
Is there maybe an "Annotated CSS 2.1 Spec" ? That is, one with extra
explanation added to every complex piece of text.
Not that I'm aware of.
As an example of two of my questions:
In:
section 9.2 Block-level elements and block boxes
Text:
When an inline box contains a block box, the inline box (and its inline
ancestors within the same line box) are broken around the block. The line
boxes before the break and after the break are enclosed in anonymous boxes,
and the block box becomes a sibling of those anonymous boxes.
Question:
Should "... are enclosed in anonymous boxes ..." actually say "... are
enclosed in anonymous block boxes ..." !?
I think that as the text in question is in a section headed "Anonymous
block boxes" then you can assume that.
Question:
Could I please have an example of "inline ancestors within the same line
box" .
here is <b>some bold <i>and italic</i> text</b>

The <b> element is an inline ancestor of the <i> element and if they
are both displayed on the same line then they are within the same line
box.
Note:
The two books that I bought, are:
"Cascading Style Sheets, The Definitive Guide", by Eric Meyer;
Probably one of the best guides to CSS in book form. Presumably you
bought this recently and have the second edition?
"Designing with Web Standards", by Jeffrey Zeldman .


An interesting opinion piece, but not a guide to actual code.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <st***@pugh.net> <http://steve.pugh.net/>
Jul 20 '05 #3
Neal <ne*****@yahoo.com> wrote:
On Tue, 25 May 2004 13:56:21 +0200, Paul <pv******@xs4all.nl> wrote:
When an inline box contains a block box, the inline box (and its
inline ancestors within the same line box) are broken around the block.
The line boxes before the break and after the break are enclosed in
anonymous boxes, and the block box becomes a sibling of those anonymous
boxes.

Question:
Should "... are enclosed in anonymous boxes ..." actually say "... are
enclosed in anonymous block boxes ..." !?


I am pretty sure this means that

<span>lalala<p>lalala</p>lalala</span>

is really rendered as

<span>lalala</span><p><span>lalala</span></p><span>lalala</span>


No. It is not the place of the CSS spec to say anything about how user
agents should fix broken markup; any such fixing should be done before
CSS is applied.

Further, span is not an anonymous box. Anonymous boxes are those that
are not associated with any HTML (or other markup language) element.

The example given in the spec for the text quoted by the OP is:

body { display: inline }
p { display: block }

<BODY>
This is anonymous text before the P.
<P>This is the content of P.</P>
This is anonymous text after the P.
</BODY>

cheers,
Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <st***@pugh.net> <http://steve.pugh.net/>
Jul 20 '05 #4
On Tue, 25 May 2004 13:17:59 +0100, Steve Pugh <st***@pugh.net> wrote:
Neal <ne*****@yahoo.com> wrote:
I am pretty sure

No.


Thanks for setting me straight. Still a lot to figure out...
Jul 20 '05 #5
Steve Pugh <st***@pugh.net> wrote:
I've bought two books on CSS, and found they're no good.
Now I'm reading "Cascading Style Sheets, level 2 revision 1
CSS 2.1 Specification" , but it's tough going.


Note that CSS 2.1 is not yet a W3C Recommendation.


Also note that it's a Candidate Recommendation, and imo generally a
better start than the 2.0 Rec.
--
Spartanicus
Jul 20 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Harold Howe | last post by:
Howdy, 1- Are property reads in effect volatile? Or is the compiler allowed to optimize property reads away? ie class foo { public int bar { get { return m_bar;}
21
by: Boris Ammerlaan | last post by:
This notice is posted about every week. I'll endeavor to use the same subject line so that those of you who have seen it can kill-file the subject; additionally, Supersedes: headers are used to...
19
by: Gérard Talbot | last post by:
posted to: alt.html and comp.infosystems.www.authoring.html followup-to: comp.infosystems.www.authoring.html Hello all, I have 2 questions about validations. 1- What's basically the...
2
by: Matthijs van Waveren | last post by:
"Your opportunity to be a RECOGNIZED EXPERT in the HPC Community" The SPEC High Performance Group is seeking candidates for a benchmark suite based on Message Passing Interface (MPI)...
6
by: Daniel O'Connell | last post by:
Two questions here: 1. Is there any particular reason why when using stackalloc, the code byte *buffer = stackalloc byte; works, but code like byte *buffer; buffer = stackalloc byte; is...
17
by: Eric Lindsay | last post by:
For years I have had links to a stylesheet done like <link rel=stylesheet type="text/css" href="style.css"> and these pages all validate with the W3C validator. However in looking at W3C, I...
17
by: djc | last post by:
I got great info on related question previously. This link <http://www.yoda.arachsys.com/csharp/threads/volatility.shtml> from Brian Gideon was especially informative. 1) the lock statement does...
11
by: Gérard Talbot | last post by:
Hello, <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <title></title> <style type="text/css"> body {background-color: white; color: black;}...
14
by: Robin Bowning | last post by:
Hi all, I have two questions I was hoping someone could answer regarding C#. First, I noticed C# does not allow local readonly variables. For example, the following is illegal: void X() {...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.