I've been looking for a summary of available commands in \setupTABLE, but can't find it. I had thought the following (modified from the nattab manual) would get me a table centered on the page, with spacing before and after, but it doesn't: \definecolor[back-1][r=.8,g=.8,b=.4] \definecolor[back-2][r=.8,g=.8,b=.6] \definecolor[back-3][r=.8,g=.8,b=.8] \setupTABLE[background=color, frame=off, framecolor=white, location=middle, spaecbefore=1*medium, spaceafter=1*medium] \setupTABLE[row][1] [rulethickness=2pt,bottomframe=on] \setupTABLE[row][1] [backgroundcolor=back-1] \setupTABLE[row][odd] [backgroundcolor=back-2] \setupTABLE[row][even][backgroundcolor=back-3] Bruce
"Bruce D'Arcus"
I've been looking for a summary of available commands in \setupTABLE, but can't find it. I had thought the following (modified from the nattab manual) would get me a table centered on the page,
if you mean centered horizontally, it works if you use midaligned
\definecolor[back-1][r=.8,g=.8,b=.4] \definecolor[back-2][r=.8,g=.8,b=.6] \definecolor[back-3][r=.8,g=.8,b=.8]
\midaligned{ \bTABLE
\setupTABLE[background=color, frame=off, framecolor=white, location=middle, spaecbefore=1*medium, spaceafter=1*medium] \setupTABLE[row][1] [rulethickness=2pt,bottomframe=on] \setupTABLE[row][1] [backgroundcolor=back-1] \setupTABLE[row][odd] [backgroundcolor=back-2] \setupTABLE[row][even][backgroundcolor=back-3] \bTR, etc \eTABLE }
looking for other good ways to accomplish same... Tomasz
Ah, I wasn't being too clear. i want to set up the table formatting in the document header, not within the text. Should I then be using the \setuptables command instead? I don't really understand the difference. Bruce On Friday, February 14, 2003, at 06:31 PM, Tomasz Kosinski wrote:
"Bruce D'Arcus"
writes: I've been looking for a summary of available commands in \setupTABLE, but can't find it. I had thought the following (modified from the nattab manual) would get me a table centered on the page,
if you mean centered horizontally, it works if you use midaligned
\definecolor[back-1][r=.8,g=.8,b=.4] \definecolor[back-2][r=.8,g=.8,b=.6] \definecolor[back-3][r=.8,g=.8,b=.8]
\midaligned{ \bTABLE
\setupTABLE[background=color, frame=off, framecolor=white, location=middle, spaecbefore=1*medium, spaceafter=1*medium] \setupTABLE[row][1] [rulethickness=2pt,bottomframe=on] \setupTABLE[row][1] [backgroundcolor=back-1] \setupTABLE[row][odd] [backgroundcolor=back-2] \setupTABLE[row][even][backgroundcolor=back-3] \bTR, etc \eTABLE }
looking for other good ways to accomplish same...
Tomasz _______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
"Bruce D'Arcus"
Ah, I wasn't being too clear. i want to set up the table formatting in the document header, not within the text. Should I then be using the \setuptables command instead? I don't really understand the difference.
I don't understand the mechanisms very well, I've just spent a week trying to figure out how to manipulate them... You can put all the setup commands in the header/preamble, but, as far as I can tell, its position on the page is not one of the properties a table can have. That is what you are looking for? Maybe someone knowledgable can correct my assumption. On the other hand, with the \setup commands located in the preamble you can still control the position of each table you insert. The position is controlled locally, to the table being placed. The following bit has your \setup commands, then three tables and a little text, and it works as I think you intend: %output=pdftex \setupcolors[state=start] \starttext \definecolor[back-1][r=.8,g=.8,b=.4] \definecolor[back-2][r=.8,g=.8,b=.6] \definecolor[back-3][r=.8,g=.8,b=.8] \setupTABLE[background=color, frame=off, framecolor=white, location=middle, spaecbefore=1*medium, spaceafter=1*medium] \setupTABLE[row][1] [rulethickness=2pt,bottomframe=on] \setupTABLE[row][1] [backgroundcolor=back-1] \setupTABLE[row][odd] [backgroundcolor=back-2] \setupTABLE[row][even][backgroundcolor=back-3] \midaligned{ \bTABLE \bTR \bTD 04400 \eTD \bTD lish exist arra mar fl \eTD \bTD 5000\eTD \eTR \bTR \bTD 04400 \eTD \bTD pair \& exisfloor \eTD \bTD 1,500\eTD \eTR \bTR \bTD 04400 \eTD \bTD x $\pm$ 4 5/8 arle bas \eTD \bTD 6,980 \eTD \eTR \eTABLE } The separation of any of these four components would have hurt \TeX\ significantly. If I had not participated fully in all these activities, {\rm literally hundreds of improvements would never have been made, because} I would never have thought of them or perceived why they were important. \bTABLE \bTR \bTD \eTD \bTD aaa\eTD \bTD b\eTD \eTR \bTR \bTD \eTD \bTD aaa\eTD \bTD b\eTD \eTR \bTR \bTD 11\eTD \bTD 111\eTD \bTD 5555\eTD \eTR \bTR \bTD 22\eTD \bTD 221\eTD \bTD 6655\eTD \eTR \eTABLE \midaligned{ \bTABLE \bTR \bTD \eTD \bTD aaa\eTD \bTD b\eTD \eTR \bTR \bTD \eTD \bTD aaa\eTD \bTD b\eTD \eTR \bTR \bTD 11\eTD \bTD 111\eTD \bTD 5555\eTD \eTR \bTR \bTD 22\eTD \bTD 221\eTD \bTD 6655\eTD \eTR \eTABLE } \stoptext Maybe a little closer... -- Tomasz
On Friday, February 14, 2003, at 07:56 PM, Tomasz Kosinski wrote:
You can put all the setup commands in the header/preamble, but, as far as I can tell, its position on the page is not one of the properties a table can have. That is what you are looking for?
Yes, and also the vertical spacing around the table. Since I'm interested in typesetting DocBook files, I'd like to avoid having to specify this stuff locally (though maybe Simon has an elegant solution for these issues?). The other reason I'm looking into tables now is because of these fonts I'm installing, which all have special tabular figures that I'd like to be able to use (in the same way I've set up the footnote fonts). Thanks for the example doc, BTW! Bruce
At 09:00 PM 2/14/2003 -0500, Bruce D'Arcus wrote:
On Friday, February 14, 2003, at 07:56 PM, Tomasz Kosinski wrote:
You can put all the setup commands in the header/preamble, but, as far as I can tell, its position on the page is not one of the properties a table can have. That is what you are looking for?
Yes, and also the vertical spacing around the table. Since I'm interested in typesetting DocBook files, I'd like to avoid having to specify this stuff locally (though maybe Simon has an elegant solution for these issues?).
you can do things like: \definefloat [mytable] [mytables] [table] \setupfloat[mytable][default={leftmargin,high,none},spacebefore=none,spaceafter=none] \placemytable{}{\getbuffer} (assuming that the table is in the buffer) 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 -------------------------------------------------------------------------
At 07:56 PM 2/14/2003 -0500, Tomasz Kosinski wrote:
\setupTABLE[background=color, frame=off, framecolor=white, location=middle, spaecbefore=1*medium, spaceafter=1*medium] \setupTABLE[row][1] [rulethickness=2pt,bottomframe=on] \setupTABLE[row][1] [backgroundcolor=back-1] \setupTABLE[row][odd] [backgroundcolor=back-2] \setupTABLE[row][even][backgroundcolor=back-3] \midaligned{ \bTABLE \bTR \bTD 04400 \eTD \bTD lish exist arra mar fl \eTD \bTD 5000\eTD \eTR \bTR \bTD 04400 \eTD \bTD pair \& exisfloor \eTD \bTD 1,500\eTD \eTR \bTR \bTD 04400 \eTD \bTD x $\pm$ 4 5/8 arle bas \eTD \bTD 6,980 \eTD \eTR \eTABLE }
\startbuffer \setup... \bTABLE ... \eTABLE \stopbuffer \placetable[none]{}{\getbuffer}
The separation of any of these four components would have hurt \TeX\ significantly. If I had not participated fully in all these activities, {\rm literally hundreds of improvements would never have been made, because} I would never have thought of them or perceived why they were important.
\startlinecorrection
\bTABLE \bTR \bTD \eTD \bTD aaa\eTD \bTD b\eTD \eTR \bTR \bTD \eTD \bTD aaa\eTD \bTD b\eTD \eTR \bTR \bTD 11\eTD \bTD 111\eTD \bTD 5555\eTD \eTR \bTR \bTD 22\eTD \bTD 221\eTD \bTD 6655\eTD \eTR \eTABLE \stoplinecorrection
\midaligned{
\placetable[none]{}{
\bTABLE \bTR \bTD \eTD \bTD aaa\eTD \bTD b\eTD \eTR \bTR \bTD \eTD \bTD aaa\eTD \bTD b\eTD \eTR \bTR \bTD 11\eTD \bTD 111\eTD \bTD 5555\eTD \eTR \bTR \bTD 22\eTD \bTD 221\eTD \bTD 6655\eTD \eTR \eTABLE }
------------------------------------------------------------------------- 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 -------------------------------------------------------------------------
Ah, I wasn't being too clear. i want to set up the table formatting in the document header, not within the text. Should I then be using the \setuptables command instead? I don't really understand the difference.
The bTABLE-eTABLE environment is a complete other environment than the \startable-\stoptable environment. I do not know whether \startable cum suis work in a header. I developed a header with a table with the \bTABLE environment. \setupheadertexts[][% {\hbox to \hsize {\switchtobodyfont[small]% %\setupframed % [align=right,top=\vfill,bottom=,width=\makeupwidth,frame=off]% {\bTABLE \setupTABLE[frame=on] \setupTABLE[column][1][width=.65\textwidth] \setupTABLE[column][2][width=.35\textwidth] \bTR \bTD Document: \bf\hfill\headnumber[part]~\getmarking[part][current] \eTD \bTD Page: \hfill \pagenumber~ of \aantalsubpaginas \eTD\eTR \eTABLE}}}] If you need special subsets of pagenumbers you might want to have a look into the mag-005.pdf in the /temp directory of the pragma site (see also mail sent by Hans yesterday) Willi I hope this can give you an idea how to proceed further.... Willi
At 12:41 PM 2/15/2003 +0100, you wrote:
Ah, I wasn't being too clear. i want to set up the table formatting in the document header, not within the text. Should I then be using the \setuptables command instead? I don't really understand the difference.
The bTABLE-eTABLE environment is a complete other environment than the \startable-\stoptable environment. I do not know whether \startable cum suis work in a header. I developed a header with a table with the \bTABLE environment.
\setupheadertexts[][% {\hbox to \hsize {\switchtobodyfont[small]% %\setupframed % [align=right,top=\vfill,bottom=,width=\makeupwidth,frame=off]% {\bTABLE \setupTABLE[frame=on] \setupTABLE[column][1][width=.65\textwidth] \setupTABLE[column][2][width=.35\textwidth] \bTR \bTD Document: \bf\hfill\headnumber[part]~\getmarking[part][current] \eTD \bTD Page: \hfill \pagenumber~ of \aantalsubpaginas \eTD\eTR \eTABLE}}}]
better use something \startbuffer[myheader] .... \stopbuffer with \setupheadertexts[... \getbuffer ....] or \startsetups[myheader] .... \stopsetups \setupheadertexts[... {\setups[myheader]} ...] 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 -------------------------------------------------------------------------
At 05:39 PM 2/14/2003 -0500, Bruce D'Arcus wrote:
I've been looking for a summary of available commands in \setupTABLE, but can't find it. I had thought the following (modified from the nattab manual) would get me a table centered on the page, with spacing before and after, but it doesn't:
\starttable \bTABLE \starttabulate etc deal with content \placetable etc deal with placement \startlinecorrection ... \stoplinecorrection can be used for special cases (in text flow) for framed stuff (not for tabulate) 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 -------------------------------------------------------------------------
participants (4)
-
Bruce D'Arcus
-
Hans Hagen
-
Tomasz Kosinski
-
Willi Egger