"Stewart Gordon" <smjg_1...@yahoo.com> wrote in message news:jcgkhi$2ohd$1...@digitalmars.com... > On 16/12/2011 18:26, Nick Sabalausky wrote: > <snip> >> For example, I have an articles section on my site that (currently) uses >> TangoCMS. I neither know nor care what doctype TangoCMS is sending out >> (and >> I have even less interest in mucking with it's internals to change it), >> and >> yet when I want to bold or italicize something in a post, I've started >> going >> back to<b> and<i>. Why? >> >> A. They're not as insanely verbose as<span style="font-weight: bold; >> font-style: italic"> > <snip> > > But you shouldn't be using <span style="font-weight: bold; font-style: > italic"> anyway. You should be looking at what the boldness or italicness > _means_, and either using the appropriate semantic HTML element or (if one > doesn't exist) defining a CSS class named after this semantic. > > This is also about making code self-documenting. >
If it's actually part of some <span class="concept">ui element</span>, or <span class="concept">widget</span>, or some <span class="concept">standard recurring concept</span>, etc, then yes, I would agree in that case, <span class="person">Stewart</span>. But if it's <i>just</i> ordinary text that simply needs to be <b>bolded</b> or <i>italicized</i>, then handling it in any roundabout way like that is just <i>ridiculous</i> (and "self-documenting" would be completely inapplicable). In such a situation, replacing hardcoded bold or italic with some vague concept of "emphasis" (old-school example: the <em> tag) or "extra-emphasis", etc, is not only a useless abstraction merely for the sake of abstraction, it <b><i>can</i></b> subtly change meaning/interpretation of the actual <i>content</i> because only the <i>author</i>, not the stylist, is able to look at the final result and know whether the result <b><i>correctly</i></b> depicts the amount/type of emphasis intended. Additionally, how does the stylist know if a given styling is going to cause too much visual noise? Or be too visually monotone? They <i>can't</i>, because it's <i>completely</i> dependent on the text that the <b><i>author</i></b> writes. It might be too much visual stuff for one article and just right for another. Only the text's author can know what's appropriate, not the stylesheet.