W3C home > Mailing lists > Public > www-style@w3.org > June 2006

Re: display: none

From: Jonathan Chetwynd <j.chetwynd@btinternet.com>
Date: Sun, 4 Jun 2006 17:38:10 +0100
Message-Id: <02017626-B4FB-45FF-8DDE-75B365908563@btinternet.com>
Cc: www-style@w3.org
To: Bjoern Hoehrmann <derhoermi@gmx.net>


thanks for your response, that was my appreciation, so how obtuse  
would it be to enable: body * {display:none;} h4 * {display:block;}

I'm considering CSS from a user perspective as per my previous  
thread: specificity and user style sheets.

The issue being that from an accessibility perspective this is pretty  
significant, say comparable with 'alt' content.

People with cognitive disabilities could benefit from a simple method  
to sort through links on complex pages.


Jonathan Chetwynd

On 4 Jun 2006, at 16:30, Bjoern Hoehrmann wrote:

* Jonathan Chetwynd wrote:
> how can I view only those elements marked h4?

There is no good way to do this using CSS, as visibility is insufficient
you would have to set display:none for all elements that have no h4 de-
scendants, visibility:hidden for h4 ancestors and visibility:visible for
the h4 elements. Since you cannot select e.g. all elements that do not
have a h4 descendant using CSS Selectors, you would need something else.

You could of course try some yet more complicated tricks, but you'd be
better of using script or XSLT to transform the document as desired.
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/
Received on Sunday, 4 June 2006 16:38:27 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:24 UTC