ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* page breakes in \bTD \eTD / \chapter in \bTD
@ 2002-12-12 17:22 Tobias Burnus
  2002-12-13  8:21 ` Hans Hagen
  0 siblings, 1 reply; 4+ messages in thread
From: Tobias Burnus @ 2002-12-12 17:22 UTC (permalink / raw)


Hi,

I try to HTML->PDF some HTML pages using ConTeXt. Unfortunally, some of
them contain tables for layout reasons. Seemingly there is no pagebreak
possible within a \bTD. Any ideas what to do in this case?

An additional problem is that <td><h2>foo</h2></td> appear.

which gets translated as:
\defineXMLsingular[h2] \section

\defineXMLenvironment[table] \bTABLE \eTABLE
\defineXMLnested[tr] \bTR \eTR
\defineXMLnested[td] \bTD \eTD
\defineXMLnested[th] \bTH \eTH


How should I define "h2" in order to get a section (bookmarks, table of
contents) within that bTD ... eTD, currently 'foo' is rendered in the
normal textsize.

Tobias

PS: If you want to play with the very premature version:
http://www.physik.fu-berlin.de/~tburnus/html2pdf-2/?url1=http%3A%2F%2Fwww.physik.fu-berlin.de%2F&url2=en-pdf%2Fportrait%2F
-- 
This above all: To thine own self be true / And it must follow as
the night the day / Thou canst not then be false to any man.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: page breakes in \bTD \eTD / \chapter in \bTD
  2002-12-12 17:22 page breakes in \bTD \eTD / \chapter in \bTD Tobias Burnus
@ 2002-12-13  8:21 ` Hans Hagen
  2002-12-13 10:18   ` Tobias Burnus
  0 siblings, 1 reply; 4+ messages in thread
From: Hans Hagen @ 2002-12-13  8:21 UTC (permalink / raw)


At 06:22 PM 12/12/2002 +0100, you wrote:
>Hi,
>
>I try to HTML->PDF some HTML pages using ConTeXt. Unfortunally, some of
>them contain tables for layout reasons. Seemingly there is no pagebreak
>possible within a \bTD. Any ideas what to do in this case?
>
>An additional problem is that <td><h2>foo</h2></td> appear.
>
>which gets translated as:
>\defineXMLsingular[h2] \section
>
>\defineXMLenvironment[table] \bTABLE \eTABLE
>\defineXMLnested[tr] \bTR \eTR
>\defineXMLnested[td] \bTD \eTD
>\defineXMLnested[th] \bTH \eTH
>
>
>How should I define "h2" in order to get a section (bookmarks, table of
>contents) within that bTD ... eTD, currently 'foo' is rendered in the
>normal textsize.

[[ beware: singular is meant for empty elements (this way you can treat 'm 
different) ]]

\starttext

\usemodule[contml] \autoXMLnamespace [context] \setupTABLE[split=yes]

\defineXMLcommand[h1]
   {\ifinner \expandafter \bfd \else \expandafter \section \fi}

\startbuffer
<table>
   <tr> <td> <h1> misusing tags </h1> </td> </tr>
   <tr> <td> misusing the h1 tag for  </td> </tr>
   <tr> <td> getting a larger font is </td> </tr>
   <tr> <td> a typical example of how </td> </tr>
   <tr> <td> html tags are misused    </td> </tr>
</table>
\stopbuffer

\dorecurse{20}{\processXMLbuffer}

\stoptext

-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: page breakes in \bTD \eTD / \chapter in \bTD
  2002-12-13  8:21 ` Hans Hagen
@ 2002-12-13 10:18   ` Tobias Burnus
  2002-12-13 10:49     ` Hans Hagen
  0 siblings, 1 reply; 4+ messages in thread
From: Tobias Burnus @ 2002-12-13 10:18 UTC (permalink / raw)


Hi,


Hans Hagen wrote:
> At 06:22 PM 12/12/2002 +0100, you wrote:
> \usemodule[contml] \autoXMLnamespace [context]
Need to look why this spoils the table width to about 3em.

> \setupTABLE[split=yes]
This only breaks between </tr><tr> not within a single cell. Which
creates a problem for the HTML-pages which use tables for Layout. (I
know, they shouldn't, but they do!)

Gruß,

Tobias
-- 
This above all: To thine own self be true / And it must follow as
the night the day / Thou canst not then be false to any man.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: page breakes in \bTD \eTD / \chapter in \bTD
  2002-12-13 10:18   ` Tobias Burnus
@ 2002-12-13 10:49     ` Hans Hagen
  0 siblings, 0 replies; 4+ messages in thread
From: Hans Hagen @ 2002-12-13 10:49 UTC (permalink / raw)


At 11:18 AM 12/13/2002 +0100, you wrote:
>Hi,
>
>
>Hans Hagen wrote:
> > At 06:22 PM 12/12/2002 +0100, you wrote:
> > \usemodule[contml] \autoXMLnamespace [context]
>Need to look why this spoils the table width to about 3em.
>
> > \setupTABLE[split=yes]
>This only breaks between </tr><tr> not within a single cell. Which
>creates a problem for the HTML-pages which use tables for Layout. (I
>know, they shouldn't, but they do!)

an TD is a framed which is by nature unbreakable

Hans


-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2002-12-13 10:49 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-12-12 17:22 page breakes in \bTD \eTD / \chapter in \bTD Tobias Burnus
2002-12-13  8:21 ` Hans Hagen
2002-12-13 10:18   ` Tobias Burnus
2002-12-13 10:49     ` Hans Hagen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).