Re: New pseudoclass, :first-use

> I use DFN in the same way, and usually the DFN is indeed the first
> occurrence of some term, but not always. Sometimes I use a term twice in
> the same paragraph and only the second one should have the DFN.
>
>     "Next we describe wuzmagigles. A <dfn>wuzmagigle</dfn> is..."

  Good point. I should also point out that I use my stylesheet to make a
definition list's DT's be in italic so they match the style of the DFN's -
as (IMHO) they should.

  That said this example doesn't really address the point.  The key is that
for my use DFN isn't really the right tag - in fact the same "problem"
exists no matter the tag - I may want the first P tag to have certain styles
for instance.

  Yes, I know that you can get close using :first-child, but it does not
appear you can simulate "first-use" via this.

> Another problem is that you try to use the style sheet to add semantics
> that should have been in the document itself.

  Quite the opposite, that is _exactly_ what I am trying to avoid!
Consider...

<P><DFN>Spacewar</DFN> is important in history because it is the world's
first real video game. No mere clone of an existing game like Tic-Tac-Toe,
Spacewar was completely original and had no parallel in the "real
world".</P>

  So as you see, the semantics are enbedded right in the code. However what
I'd really like to do is...

<P><GAME>Spacewar</GAME> is important in history because it is the world's
first real video game. No mere clone of an existing game like Tic-Tac-Toe,
<GAME>Spacewar</GAME> was completely original and had no parallel in the
"real world".</P>

  Now I have removed the semantics from the code. After all, all instances
of the name "Spacewar" _really_are_ the title of the game, yet from a
_style_ point of view only the first should appear with a particular style
on it. It also has the property of degrading nicely, as we want.

> In practice, definitions are most useful

  It appears that I should have left the discussion of DFN out of my post -
my post was about avoiding the use of DFN. I believe that first-use is a
general purpose pseudo-class that would have a variety of uses in exactly
the same fashion as first-line and first-letter.

> With a good hypertext editor (I use Amaya)

  Wow, I continue to gasp when I see "Amaya" and "good" in the same
sentance.  YMMV, as always.

Maury

Received on Saturday, 26 August 2000 11:44:27 UTC