|
List Info
Thread: Marks assignment for qandaentries
|
|
| Marks assignment for qandaentries |

|
2006-11-02 01:25:32 |
|
|
Hi Cameron,
There isn't a feature in DocBook to assign marks or
points to a question, because DocBook wasn't really designed for courseware. But
DocBook was designed to be customized and extended, in case you have specialized
needs.
For example, almost all elements include an
empty "local" parameter entity in the DTD for adding new attributes.
In your case, an attribute named "points" could be added to either the question
element or the qandaentry element, which contains the question element.
For example:
<!DOCTYPE book SYSTEM "docbook.dtd"
[
<!ENTITY % local.question.attrib "points CDATA
#IMPLIED">
]>
When the parser loads the DTD, it reads this
internal subset first, and uses this value of the parameter entity instead of
the empty one in the DTD. With this change, you
can add a points attribute to your question elements, and it will
validate.
Putting the entity declaration in the internal
subset of the DTD (in the XML file itself) is fine for a few documents, but if
you have lots, you might consider customizing the external DTD. See Norm
Walsh's book DocBook: The Definitive Guide (online version) chapter 5 for more
info on how to do that:
The DocBook XSL stylesheets won't know about the
new attribute, though, so if you want the points to show in the output, you
would need to customize the XSL template for question.
----- Original Message -----
Sent: Monday, October 30, 2006 5:49
PM
Subject: [docbook] Marks assignment for
qandaentries
I'm new to Docbook, and want to use it for most of my
University-level course documentation.
I've been looking through the specs, and I cannot find any way to assign
marks/points to a question. Can anyone point me in the right direction?
Thanks.
--
• Telecommunications Teaching Fellow & SysAdmin •
|
[1]
|
|
|
about | contact Other archives ( Real Estate discussion Medical topics )
|