Re: Bold and Formatting within a Table

Subject: Re: Bold and Formatting within a Table
From: Norman Walsh <norm@xxxxxxxxxxxxx>
Date: Thu, 19 Mar 1998 10:27:23 -0500
/ Chuck Darney <cdarney@xxxxxxxxxxxxxxxx> was heard to say:
| I've been trying to figure out why I can't use a bold markup tag in a
| table.  As it turns out, no other formatting of elements seems to be
| working in a table either.  Does anyone else have this problem?  

Yes.  Everyone does.  :-(

If you start an ENTRY with an inline tag, the inline tag (and
all subsequent tags) get ignored.  The quick solution is to put
a PARA wrapper around the content of the entry.

But...

The really good news is that I've reexamined the way I process
tables and I think I've found a way to avoid all the ugly
hacking nonsense that's currently done to format inline
vs. block elements correctly.

All that $process-cell-*-contents$ cruft can go away!

If you want to make it work right now, change two things in your
customization layer.  Add:

(element (ENTRY PARA)
  (make paragraph
    quadding: (inherited-quadding)
    (process-children)))

to get the quadding right in PARAs in an ENTRY.

And define $process-cell-contents$ as follows:

(define ($process-cell-contents$ entry colnum)
  (let ((font-name (if (have-ancestor? "THEAD" entry)
		       %title-font-family%
		       %body-font-family%))
	(weight    (if (have-ancestor? "THEAD" entry)
		       'bold
		       'medium))
	(align     (cell-align entry colnum)))
    (make sequence
      font-family-name: font-name
      font-weight: weight
      quadding: align
      (process-node-list (children entry)))))

If you try this, please report any troubles that you have.

--norm


 DSSSList info and archive:  http://www.mulberrytech.com/dsssl/dssslist


Current Thread
  • Bold and Formatting within a Table
    • Chuck Darney - from mail1.ability.netby web4.ability.net (8.8.5/8.6.12) with ESMTP id JAA19672Thu, 19 Mar 1998 09:54:32 -0500 (EST)
      • Norman Walsh - from mail1.ability.netby web4.ability.net (8.8.5/8.6.12) with ESMTP id KAA20817Thu, 19 Mar 1998 10:28:45 -0500 (EST) <=
      • <Possible follow-ups>
      • Jordi Mulet - from mail1.ability.netby web4.ability.net (8.8.5/8.6.12) with ESMTP id DAA08750Fri, 20 Mar 1998 03:42:04 -0500 (EST)
        • Norman Walsh - from mail1.ability.netby web4.ability.net (8.8.5/8.6.12) with ESMTP id HAA10429Fri, 20 Mar 1998 07:26:19 -0500 (EST)
      • Jordi Mulet - from mail1.ability.netby web4.ability.net (8.8.5/8.6.12) with ESMTP id LAA12801Fri, 20 Mar 1998 11:26:41 -0500 (EST)