- From: Terry Allen <terry@ora.com>
- Date: Tue, 12 Sep 1995 13:47:41 -0700
- To: evan@poirot.hpl.hp.com (Evan Kirshenbaum), www-style@w3.org
Thanks for the good example, Evan. I think this is part of a bigger problem (other parts of which include generated text that must be displayed, prohibitions on hiding certain elements, and legally required display characteristics of e.g. safety warnings), to which the only solution I can see is that authors must be able to specify that their style sheet be used or the document not be displayed. Somewhere there has to be a hook for the author to specify that. It probably doesn't belong in a style sheet. Similarly, authors should be able to specify that their documents may not be transcluded without permission. That needs a hook, but it doesn't belong in HTML or (perhaps) HTTP. Where in the architecture of the Internet does one specify conditions like this? Regards, --- Forwarded mail from evan@poirot.hpl.hp.com (Evan Kirshenbaum) Resent-Date: Tue, 12 Sep 1995 16:10:26 -0400 From: evan@poirot.hpl.hp.com (Evan Kirshenbaum) Date: Tue, 12 Sep 1995 13:10:15 -0700 Organization: Hewlett-Packard Laboratories Telephone: (415)857-7572 Fax: (415)852-8092 X-Mailer: Z-Mail (3.2.0 06sep94) To: www-style@w3.org Subject: Contrast specification in Style Sheets Resent-From: www-style@w3.org X-Mailing-List: <www-style@w3.org> archive/latest/186 X-Loop: www-style@w3.org Sender: www-style-request@w3.org Resent-Sender: www-style-request@w3.org Precedence: list When people suggest specifying typographic formatting in HTML, they are now rightly told that this is an issue that is better covered in style sheets, as HTML is concerned primarily with content, and, anyway, it is impossible to predict the rendering capabilities of any user agent. This is all perfectly correct, but there are times when the rendering of particular classes contain content in that whatever the display chosen it is important that they be distinguishable. Consider the following examples. <style> EM.removed : text-line = through EM.added : font-style = italic </style> ... The minimum fine will be <em class=removed>fifty</em> <em class=added>one hundred</em> dollars. [Yes, I know that explicit markup was added in HTML 3.0 to cover this case. Pretend that it hadn't been.] <style> P.king : align = left P.queen : align = right </style> ... <p class=king> King's line. </p> <p class=queen> Queen's line. </p> <p class=king> King's line. </p> In each of these cases, it does not really matter what markup is chosen for the contrasting content, but it is vitally important to the content that they contrast. Unfortunately, there appears to be nothing in the current draft which would tell a browser which contrasts are important if the requested style cannot be applied. Consider the case of a style sheet which defines classes to be rendered bold, italic and underlined on a device which can render bold and underlined, but not italic. The easiest solution is to punt on the italics and render the text in roman, but this may fail importantly to contrast with background text. Another solution might be to follow the typewriter convention and render the italics as underline, but this leaves the second and third classes indistinguishable. It seems reasonable to allow the author to specify "the second and third classes must contrast with each other and with background text, and the first need only contrast with background text". In this case, the browser would know that it should probably render the second class in bold to preserve the contrast with both the underlined and background text. The most straightforward way to do this is probably something like <style> EM.class1 : font-weight = bold EM.class1 : contrast-with = P EM.class2 : text-style = italic EM.class2 : contrast-with = P EM.class3 : text-line = under EM.class3 : contrast-with = P & EM.class2 </style> Another way would be something like: <style> HTML : contrast-class = background EM.class1 : font-weight = bold EM.class1 : contrast-with = background EM.class1 : contrast-class = c1 EM.class2 : text-style = italic EM.class2 : contrast-class = c2 EM.class2 : contrast-with = background & c3 EM.class3 : text-line = under EM.class3 : contrast-class = c3 EM.class3 : contrast-with = background & c2 </style> I'm not really satisfied with either of these solutions, but I think that something in this direction needs to be specifiable, so I throw the problem out. As a language designer, it seems more reasonable to define that a class is in a particular contrast group and that certain groups need to contrast with one another (rather than classes explicitly contrasting with other classes or groups), but I don't see an easy way to specify that in the CSS paradigm. What do you think? ---- Evan Kirshenbaum +------------------------------------ HP Laboratories |You gotta know when to code, 1500 Page Mill Road, Building 4A | Know when to log out, Palo Alto, CA 94304 |Know when to single step, | Know when you're through. kirshenbaum@hpl.hp.com |You don't write your program (415)857-7572 | When you're sittin' at the term'nal. |There'll be time enough for writin' | When you're in the queue. --- End of forwarded mail from evan@poirot.hpl.hp.com (Evan Kirshenbaum) -- Terry Allen (terry@songline.com) Songline Studios Online Books Editor 101 Morris St. affiliated with O'Reilly & Asso, Inc. Sebastopol, Calif., 95472 A Davenport Group sponsor. For information on the Davenport Group see ftp://ftp.ora.com/pub/davenport/README.html or http://www.ora.com/davenport/README.html Current HTML 2.0 spec: ftp://ds.internic.net/internet-drafts/draft-ietf-html-spec-05.txt "I thought many of the saucer photos were falsifications, using the techniques known in the lingo as `multimedia.'" --"Sightings"
Received on Tuesday, 12 September 1995 17:16:06 UTC