RE: Inheritance

by "Mark Martens" <mark.martens(at)emotion.com>

 Date:  Wed, 28 Mar 2001 13:09:19 -0500
 To:  "'Ed Peddycoart'" <ed(at)celticblues.com>,
"'HWG-Style'" <hwg-style(at)hwg.org>
 In-Reply-To:  celticblues
  todo: View Thread, Original
Yep...in that case you can simply create a class and assign it to whatever
tag you wish...

.mine {color:white; background:blue;}

then use the <H6 class = mine>...you can also use the same class for other
tags, unless you qualify it as such:

H6.mine {color:white; background:blue;}

in the style.  The former makes the class available to all tags, the latter
restricts it to being used (when you want it) by the H6 tag.

Hope this helps...

Mark

-----Original Message-----
From: owner-hwg-style(at)hwg.org [mailto:owner-hwg-style(at)hwg.org]On Behalf
Of Ed Peddycoart
Sent: Wednesday, Mar 28, 2001 12:08 PM
To: 'HWG-Style'
Subject: RE: Inheritance


I would like to keep the original H1, H2, etc. untouched.  If I do the
following...

H6 {color:white; background:blue;}

then won't all sections that are H6 have white text on blue background?  I
just want to use H? as a starting point.

Ed

>-----Original Message-----
>From: Mark Martens [mailto:mark.martens(at)emotion.com]
>Sent: Wednesday, March 28, 2001 10:58 AM
>To: 'Ed Peddycoart'; 'HWG-Style'
>Subject: RE: Inheritance
>
>
>How about just defining the H6 with those characteristics...
>
>H6 {color:white; background:blue;}
>
>It will keep the remaining characteristics of a H6 tag, but will "inherit"
>these additional characteristics.  Hope this helps.
>
>Mark
>
>-----Original Message-----
>From: owner-hwg-style(at)hwg.org [mailto:owner-hwg-style(at)hwg.org]On Behalf
>Of Ed Peddycoart
>Sent: Wednesday, Mar 28, 2001 10:25 AM
>To: HWG-Style
>Subject: Inheritance
>
>
>I have some HTML that I want to have the same style as H1, H2 etc. except,
>say, a different color, or maybe, a little bit different margin, for
>example.  I don't want to dink with the standard H1, H2, etc.
>parameters, so
>I thought this would be a good time to inherit (? is that the correct term)
>the properties of the headers into some new classes for my use.
>Can someone
>point me to a simple example for doing this?  For example...say I wanted to
>have a class name MyH6, which had the same style as H6, except the text is
>white, and the background is blue.  Thanks.
>
>Ed
>
>

HWG hwg-style mailing list archives, maintained by Webmasters @ IWA