Return-Path: Delivered-To: apmail-xml-forrest-dev-archive@www.apache.org Received: (qmail 60626 invoked from network); 28 Dec 2003 11:29:12 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 28 Dec 2003 11:29:12 -0000 Received: (qmail 84803 invoked by uid 500); 28 Dec 2003 11:28:44 -0000 Delivered-To: apmail-xml-forrest-dev-archive@xml.apache.org Received: (qmail 84727 invoked by uid 500); 28 Dec 2003 11:28:43 -0000 Mailing-List: contact forrest-dev-help@xml.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: forrest-dev@xml.apache.org Delivered-To: mailing list forrest-dev@xml.apache.org Received: (qmail 84716 invoked from network); 28 Dec 2003 11:28:43 -0000 Received: from unknown (HELO cmailm1.svr.pol.co.uk) (195.92.193.18) by daedalus.apache.org with SMTP; 28 Dec 2003 11:28:43 -0000 Received: from modem-2230.kawau.dialup.pol.co.uk ([81.78.152.182]) by cmailm1.svr.pol.co.uk with esmtp (Exim 4.14) id 1AaZ6N-0008RR-SQ for forrest-dev@xml.apache.org; Sun, 28 Dec 2003 11:28:56 +0000 Subject: Re: Allow "role" attribute in document DTD From: Peter Hargreaves To: forrest-dev@xml.apache.org In-Reply-To: <3FED8F6F.3080603@wkwyw.net> References: <3FECF5CF.8030109@wkwyw.net> <20031227052510.GB3190@expresso.localdomain> <3FED25D6.1020608@wkwyw.net> <20031227085930.GC5684@expresso.localdomain> <3FED8F6F.3080603@wkwyw.net> Content-Type: text/plain Message-Id: <1072611141.31895.34.camel@g6-350.local> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.5 Date: Sun, 28 Dec 2003 11:32:22 +0000 Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N On Sat, 2003-12-27 at 13:55, Ross Gardler wrote: > >>Since class is intended to describe display information I'm not sure if > >>it could be used for this same purpose, it may just confuse things as > >>we'd likely end up with classes that didn't affect display. > > > > > > That's fine, however there is already a 'role' attribute defined for > > . > > Yes, I forgot that, sorry, been a long time since I started using that, > so my example was a very poor one, perhaps below will be better. > > > So do you want to define @role more generally, to apply to other > > elements? If so, what is the use-case? > > At present the only plac my use case needs it is in the section element, > but perhaps more general would be useful. > > Now that you are forcing me into explaining the use case I am becoming > more convinced that you are right and this is in fact a class. However, > I also introduced another attribute recently. This one was origianlly > "level" as in level of detail (I use Forrest to deliver course support > materials). However, I have recently decided this should be part of the > role attribute. > > Basically, I tag some parts as being "BSc", "MSc", "MBA" etc. Other > parts are tagged as course focus, for example case studies have roles > such as "ECommerce_Analysis" or "MBA_Anaysis". I then use these to > select which part of the document should be displayed. So if I have an > MBA student veiwing the page they get the "BSc" + "MBA" content of > general pages and the "MBA_Analysis" of case studies. > > Since much of the content is shared I do not want to split it into > different documents, so I use role to enable me to do that dynamcally. > > > Isn't that use-case > > presentational? If presentational, why not use class? > > I have to admit I'm a little unsure if this is presentational or not. I > think of presentation as being *how* it is displayed whereas much of my > use for the role attribute is *what* is displayed (clearly I use Forrest > in a dynamic environment). IMO - In your document it is not presentation, it is just content and semantic markup, but your skin might later use the markup for presentational purposes - if it feels that way inclined. After all most of your dtd markup is used for presentational decisions. So, forget about thinking presentation in your dtd and think about what meaning you want to include in the document. So, why not:
or as you suggest
I've used things like
or
in my application. Hope my comments help. Peter. P.S. DocBook is great for inspiration on markup. > I have similar use cases with data from electronic sensor devices. The > engineers get one lot of data, the management another etc. > > Ross --