[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [docbook] Confusion with tables
Aidan Lister <aidanis@gmail.com> writes: > Firstly, I'm not subscribed (any more) to this list, so if you could > cc: me any replies that would be fantastic. > > I'm a bit unsure about tables and docbook. > Which model should I be using? > - row/entry etc, (CALS model?) > - Or tr/td, (HTML model?) I think it depends on what you are used to and on what kinds of editing applications you want to use. If you want to create and edit your tables using a graphical interface, there are some that support CALS, but many others only support HTML tables. > At the moment, I'm using row/entry. I'm having a couple of problems. I > need to make a heading column (as opposed to a heading row). There > seems to be no other way than wrapping each cell in <emphasis>. > > To make a heading row, I'd use <thead><row><entry...../></row><thead>. > As I can't put a column in thead, I'm at a loss. Do I use colspec > somehow? CALS does not have the concept of a "heading column". It only allows Entry (equivalent of TD) within Row (=TR). It has no equivalent of TH or (that I know of). It could be argued that not having something TH-like is a feature, not a limitation -- especially not having something equivalent within Row. Because the HTML model of allowing TH in TR lets you do things like this: <table> <tr><td></td><th></th><td></td></tr> <tr><th></th><td></td><td></td></tr> </table> Which doesn't make a lot of sense. But I think that since the practical effect of using TH vs. TD is just that TH contents get rendered in bold, you can get that effect just using CSS: TR TD[1] { font-weight: bold } -- or whatever the CSS syntax is for "boldface contents of the first TD child of each TR". Or you can just author your DocBook docs using HTML tables and TH, instead of CALS :-) > Next, If my table has subdivisions, i.e. half way down I have > another sub-heading saying "Other elements", for example, how > should I structure the html? > > Currently I've got a <row><entry namest= nameend=>... which spans the > table, but this probably isn't ideal. > > I've stuck an example table here: http://aidan.dotgeek.org/exampletable.htm Myself, I would probably just make them separate tables. --Mike -- Michael Smith http://logopoeia.com/ http://www.oreillynet.com/pub/au/890
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]