What I really want is a way to define styles based on other styles so that I don't have to reproduce most of the effects of that style. For instance, for my particular paragraph, I want a font style, size, line-spacing, etc. And I want a style based on that one which bolds and italicizes a section of text, and another based on the same one which does link text, redefining the text-decoration and color, but inheriting the other features of the style.
eg.
<span class="my_style">This text is in the font face, size, etc., which I have defined. <span class="my_style.em">This is emphasized text (or speech, or braille, etc., depending on the medium) inheriting the same font face, size, etc. as the base style.</span> <a href="link.html" class="my_style.link">Click here for more info!</a> The preceding link is blue and hovers as red and underlined, but has the same font face, size, and other features as the base style.</span>
It seems that this is somewhat possible given the method that Dean showed me, except that you cannot simply define sub-styles. Instead you have to associate it with a particular HTML tag. I'd rather not use <em> to define my text, but instead to use <span class="my_style.em">. This way I can define several levels of description and also not have to associate them with tags which may not describe my usage.
eg.
<span class="my_style">This is courier 10 italic.</span>
<span class="my_style.em">This is courier 10 italic bold</span>
<span class="my_style.em.blue">This is courier 10 italic bold blue</span>
<span class="my_style.small">This is courier 8 italic</span>
etc.
And then I can change all of these styles to Times New Roman instead of Courier by simply changing the font face specified in the definition of "my_style", rather than going to each sub-style and changing it in each of them.
Even better would be the addition of styles. For instance, let's say I defined .em to apply bold to the text, and I defined .blue to make the text blue. If I apply <span class="em.blue"> or <span class="blue.em"> then it would start with the first style defined and alter it according to the redefinitions in each succeeding style, both of the above examples producing blue, bolded text.
If any of this is remotely possible, particularly without necessarily attaching the style to a specific HTML tag, please inform me of this.
Sincerely,
Tom Anderson
CEO, Order amid Chaos, Inc.