commands, like \bTABLEhead,
\eTABLEhead, bTABLEbody or \eTABLEbody: it seems impossible to
incapsulate them into lua functions. For example, the following is not
compiled:
\starttext
\bTABLE
\ctxlua{context.bTABLEbody()}
\bTR
\bTD Cell 1\eTD
\bTD Cell 2\eTD
\eTR
\ctxlua{context.eTABLEbody()}
\eTABLE
Hi,
I am trying to generate a table representation for some xml source.
As the data structure doesn't directly correspond to the desired table
structure, some manipulations via lua are required. So far everything
works OK except table sectioning commands, like \bTABLEhead,
\eTABLEhead, bTABLEbody
r=red], body and foot
>> are formatted, but not the same column in header. I couldn’t find how to
>> format columns in header.
If you disregard the Wiki page instructions to use \bTH...\eTH then you can
format the header using:
\bTABLEhead
\bTR \bTH Column 1 \eTH \bTD[color=bl
[1]{\RtH}{\rotate{#1}}
\starttext
\setupTABLE[offset=3pt]
\setupTABLE[header][background=color,backgroundcolor=yellow,align=bottom]
\bTABLE
\bTABLEhead
\bTR \bTH\RtH{animal}\eTH \bTH\RtH{size}\eTH \bTH\RtH{weight}\eTH
\bTH\RtH{average speed}\eTH \eTR
You can change the vertical alignment
find an option to do that.
> Tried \dontleavehmode or \hfill in my \RtH macro to no avail.
> Is it possible?
>
>
> \define[1]{\RtH}{\rotate{#1}}
>
> \starttext
>
> \setupTABLE[offset=3pt]
> \setupTABLE[header][background=color,backgroundcolor=yellow,align=bottom]
>
\dontleavehmode or \hfill in my \RtH macro to no avail.
> Is it possible?
>
>
> \define[1]{\RtH}{\rotate{#1}}
>
> \starttext
>
> \setupTABLE[offset=3pt]
> \setupTABLE[header][background=color,backgroundcolor=yellow,align=bottom]
> \bTABLE
> \bTABLEhead
> \bTR \bTH
]
\setupTABLE[header][background=color,backgroundcolor=yellow,align=bottom]
\bTABLE
\bTABLEhead
\bTR \bTH\RtH{animal}\eTH \bTH\RtH{size}\eTH \bTH\RtH{weight}\eTH
\bTH\RtH{average speed}\eTH \eTR
\eTABLEhead
\bTABLEbody
\bTR \bTD sparrow \eTD \bTD small \eTD \bTD light \eTD \bTD high \eTD \eTR
\bTR \bTD dog
rtsTable]
[separator=comma,left=\bTD,right=\eTD,first=\bTR,last=\eTR,before={
\bTABLE[split=repeat,option=stretch]
\bTABLEhead
\bTR
\bTH Ref. No. \eTH \bTH Part No. \eTH \bTH Description \eTH \bTH Remarks
\eTH
\eTR
\eTABLEhead
\bTABLEbody
},
after={
\eTABLEbody
\eTABLE
}]
\s
ight}]
> \stopxmlsetups
>
> \startxmlsetups xml:document
> \xmlflush{#1}
> \stopxmlsetups
>
> \startxmlsetups xml:table-wrap
> \startplacetable
> \xmlflush{#1}
> \stopplacetable
> \stopxmlsetups
>
> \startxmlsetups xml:table
&g
d)}
\xmlfilter{#1}{/tbody/command(xml:table:tbody)}
\eTABLE
\stopxmlsetups
\startxmlsetups xml:table:thead
\bTABLEhead
\xmlfilter{#1}{/tr/command(xml:table:thead:tr)}
\eTABLEhead
\stopxmlsetups
\startxmlsetups xml:table:thead:tr
\bTR
(xml:table:tbody)}
\eTABLE
\stopxmlsetups
\startxmlsetups xml:table:thead
\bTABLEhead
\xmlfilter{#1}{/tr/command(xml:table:thead:tr)}
\eTABLEhead
\stopxmlsetups
\startxmlsetups xml:table:thead:tr
\bTR
LE in your
> header. I have modified your example file (see attached). With that you
> get the
> attached PDF.
>
> By the way, your example was missing a \bTABLEhead. Moreover, I believe
> cells
> in TABLE head entries should be enclosed by \bTH \eTH instead of \(b|e)TD.
> I
&
xample was missing a \bTABLEhead. Moreover, I believe cells
in TABLE head entries should be enclosed by \bTH \eTH instead of \(b|e)TD. I
have made these changes as well.
[Also, I hope you are aware that you can use style=\tt, style=\bf per row/
column/cell with \setupTABLE; that will significantly reduce ma
> \startxmlsetups xml:table-wrap
> \startplacetable
> % \contextversion \par
> \xmlflush{#1}
> \stopplacetable
> \stopxmlsetups
>
> \startxmlsetups xml:table
> \bTABLE
> \xmlflush{#1}
> \eTABLE
> \stopxml
xml:colgroup
\xmlflush{#1}
\stopxmlsetups
\startxmlsetups xml:col
\xmlpos{#1} \xmlatt{#1}{align}\par
\stopxmlsetups
\startxmlsetups xml:table:thead
\bTABLEhead
\xmlflush{#1}
\eTABLEhead
\stopxmlsetups
\startxmlsetups xml:table:tr
\bTR
\xmlflush{#1}
\eTR
natural tables
I found this code on the wiki
% mode=mkiv
\setuppapersize[A5]
\bTABLE
\setupTABLE[c][each][alignmentcharacter={number->.},aligncharacter=yes,align=middle]
\bTABLEhead
\bTR
\bTH Same-Width Prefix \eTH \bTH Varying-Width Prefix \eTH
\bTH Same-Width Suffix \eTH \bTH Varying-Width Suf
ables
I found this code on the wiki
% mode=mkiv
\setuppapersize[A5]
\bTABLE
\setupTABLE[c][each][alignmentcharacter={number->.},aligncharacter=yes,align=middle]
\bTABLEhead
\bTR
\bTH Same-Width Prefix \eTH \bTH Varying-Width Prefix \eTH
\bTH Same-Width Suffix \eTH \bTH Varying-Width Suffix \eTH
\eTR
\
][corner=07]
\setupTABLE[last][last][corner=06]
\setupTABLE[column][last][style={\setcharacterspacing[frenchpunctuation]}]
\stopsetups
\bTABLE[setups=tablesettings]
%\bTABLEhead
\bTR
\bTH espéranto \eTH
\bTH exemple \eTH
\bTH équivalent en français \eTH
\eTR
%\eTABLEhead
%\bTABLEbody
This worked for me a couple of versions ago but not under 2020.11.24 00:41. The
headings are being printed as ordinary text at the top of the table rather than
framed.
\starttext
\bTABLE[split=yes, header=repeat]
\bTABLEhead
\bTR
\bTH A \eTH
\bTH B \eTH
\eTR
of times, but I couldn't find an answer.
If this doesn't help you have to provide a example.
[...]
Ok:
=
\setupcaption[table]
[location=top]
\starttext
\startplacetable[location=split,title={Title\footnote{footnote}}]
\bTABLE[split=yes]
\bTABLEhead
.
If this doesn't help you have to provide a example.
[...]
Ok:
=
\setupcaption[table]
[location=top]
\starttext
\startplacetable[location=split,title={Title\footnote{footnote}}]
\bTABLE[split=yes]
\bTABLEhead
\bTR \bTD Header 1 \eTD \bTD Header 2 \eTD \eTR
.
\starttext
\bTABLE[split=yes]
\bTABLEhead
\bTR \bTD Header 1 \eTD \bTD Header 2 \eTD \eTR
\eTABLEhead
\bTABLEbody
\dorecurse{100}{\bTR \bTD Column 1 \eTD \bTD Column 2 \eTD \eTR}
\eTABLEbody
\eTABLE
\stoptext
Wolfgang
get tagging in general and thought that natural tables would
> work because of \bTABLEhead ... \eTABLEhead would do the job, but it
> doesn't.
>
> I'd appreciate any feedback.
>
> David
>
>
> Sent with ProtonMai
Hello.
Is there any way to pdf-tag table headers to assist screen readers and the
like? I can get tagging in general and thought that natural tables would work
because of \bTABLEhead ... \eTABLEhead would do the job, but it doesn't.
I'd appreciate any feedback.
David
Sent with [ProtonMail
...
l.114 \eTABLE
My table is:
\setupTABLE[header][each][background=color,backgroundcolor=white,
width=broad]
\bTABLE[split=repeat,option={stretch}, align={flushright}, frame=off]
\bTABLEhead[align=flushright]
\bTR
\bTH [offset=none, align={flushleft},
=color,backgroundcolor=white,
width=broad]
\bTABLE[split=repeat,option={stretch}, align={flushright}, frame=off]
\bTABLEhead[align=flushright]
\bTR
\bTH [offset=none, align={flushleft}, nc=39]
.
\eTH
...
\bTR[strut=no]
\bTD[align={flushleft,lohi}
I have got the following two minimal non-working examples (on TeXlive 2018):
# >
# >\starttext\setupTABLE[split=yes]
# > \bTABLE
# > \bTABLEhead\bTR\bTH head \eTH\eTR\eTABLEhead
# > \bTABLEbody
# > \dorecurse{100}{\bTR\bTD \currentTABLErow xxx \eTD\eTR}
# > \eTA
]
\bTABLE
\bTABLEhead\bTR\bTH head \eTH\eTR\eTABLEhead
\bTABLEbody
\dorecurse{100}{\bTR\bTD \currentTABLErow xxx \eTD\eTR}
\eTABLEbody
\eTABLE
\stoptext
In this case, the head-line is alse counted which makes no sense
and I do not know how to supress it.
Even though
Hi all,
at https://wiki.contextgarden.net/Command/currentTABLEcolumn I learnt
about \currentTABLErow etc. for counting lines in natural tables.
I have got the following two minimal non-working examples (on TeXlive 2018):
\starttext\setupTABLE[split=yes]
\bTABLE
\bTABLEhead\bTR\bTH head
\setupTABLE[c][1,3][align=left]
\setupTABLE[c][2,4][loffset=1em,roffset=1em]
\setupTABLE[r][each][offset=0pt]
\bTABLE[frame=off]
\bTABLEhead
\bTR[align=center,bottomframe=on]
\bTH[nc=2] Non-compound\eTH
\bTH[nc=2] Compound\eTH
\eTR
) it fails with bare
%% hyphen and all shown compounds except |=|.
\starttext
\setupTABLE[c][1,3][align=left]
\setupTABLE[c][2,4][loffset=1em,roffset=1em]
\setupTABLE[r][each][offset=0pt]
\bTABLE[frame=off]
\bTABLEhead
\bTR[align=center,bottomframe
=off,align=left]
\setupTABLE[c][2][style=\tfx\it,align=left]
\bTABLE
\bTABLEhead
\bTR\bTH Col1 \eTH\bTH Col2 \eTH\bTH Col3 \eTH\eTR
\eTABLEhead
\bTABLEnext
\bTR\bTH Col1 \eTH\bTH Col2 \eTH\bTH Col3 \eTH\eTR
\eTABLEnext
\bTABLEbody
\bTR\bTC \eTC\bTC NightShift \eTC\bTC Tension Lines 146 - 150 \eTC\eTR
=off,rightframe=off,align=right]
\setupTABLE[c][first][frame=off,align=left]
\setupTABLE[c][2][style=\tfx\it,align=left]
\bTABLE
\bTABLEhead
\bTR\bTH Col1 \eTH\bTH Col2 \eTH\bTH Col3 \eTH\eTR
\eTABLEhead
\bTABLEnext
\bTR\bTH Col1 \eTH\bTH Col2 \eTH\bTH Col3 \eTH\eTR
\eTABLEnext
\bTABLEbody
\bTR\bTC
m 07:59
Place the table as float and disable the caption, e.g.
\startplacetable[location={split,force,none}]
...
\stopplacetable
Wolfgang
Procházka Lukáš Ing. <mailto:l...@pontex.cz>
21. Juni 2018 um 11:10
Hello,
thanks, it works:
\startalignment[middle]
\startplacetable[locatio
Hello,
thanks, it works:
\startalignment[middle]
\startplacetable[location={split,force,none}]
\bTABLE[split=repeat]
\bTABLEhead
\bTR\bTH A\eTH\bTH B\eTH\eTR
\eTABLEhead
\bTABLEbody
\dorecurse{60}{
\bTR
\bTD
SET}{b}}
\define\C{\getvariable{#SET}{c}}
\bTR
\expanded{\bTC\A\eTC}
\expanded{\bTC\B\eTC}
\expanded{\bTC\C\eTC}
\eTR
\stoptexdefinition
\starttext
\processcommacommand[\Sets]\doInlineText
\bTABLE[frame=off]
\bTAB
\bTC\B\eTC
\eTR
\stoptexdefinition
\starttext
\starttext
\expandafter\processcommalist\expandafter[\Sets]\doInlineText
\bTABLE[frame=off]
\bTABLEhead
\bTR[nc=2]
\bTH Direct\eTH
\eTR
\eTABLEhead
Hi, I have several long and slenders tables like this:
---8<---
\starttext
Some Text at start.
% Point bA
\placetable[split]{My long table}{
% Point bB
\bTABLE[split=repeat]
\bTABLEhead
\bTR\bTD one \eTD\bTD two \eTD\bTD three \eTD\eTR
\eTABLEhead
\bTABLEbody
\dorecurse{100}{\
=3.0in]
\setupTABLE[c][2][width=0.5in, align=flushright]
\setupTABLE[c][3][width=0.5in, align=flushright]
\setupTABLE[c][4][width=2.5in]
\bTABLE
\bTABLEhead
\bTR[topframe=on, bottomframe=on]
\bTH {\bf Unit Description} \eTH
\bTH {\bf Weight} \eTH
\bTH {\bf Mark} \eTH
\bTH \eTH
\eTR
\eTABLEhead
\bTAB
]
\setupTABLE[c][2][width=0.5in, align=flushright]
\setupTABLE[c][3][width=0.5in, align=flushright]
\setupTABLE[c][4][width=2.5in]
\bTABLE
\bTABLEhead
\bTR[topframe=on, bottomframe=on]
\bTH {\bf Unit Description} \eTH
\bTH {\bf Weight} \eTH
\bTH {\bf Mark} \eTH
\bTH
n=flushright]
\setupTABLE[c][3][width=0.5in, align=flushright]
\setupTABLE[c][4][width=2.5in]
\bTABLE
\bTABLEhead
\bTR[topframe=on, bottomframe=on]
\bTH {\bf Unit Description} \eTH
\bTH {\bf Weight} \eTH
\bTH {\bf Mark} \eTH
\bTH \eTH
\eTR
[column][last][width=broad]
\setupTABLE[row][first][style=bold]
\setupTABLE[offset=.2em]
\setupwhitespace[medium]
\setuptolerance[verytolerant]
\starttext
\dorecurse{2}{\input knuth\par}
\placetable[here,split][]{Test}{
\bTABLE
\bTABLEhead
\bTR \bTD Col1 \eTD \bTD Col2 \eTD \eTR
I found out that the command is \bTABLEhead and not \bTABLEheader, but I
don't know why my saved example had ...header instead of head.
Thanks.
Forwarded Message
Subject:\bTABLEheader used to work?
Date: Sun, 18 Oct 2015 00:06:38 -0700
From: Henman <d
]
\setupfooter[style=\tx]
\setupfootertexts[\setups{s:footer}][][][\setups{s:footer}]
\startchapter[title={Test}]
\placetable[split]{Test}{
\bTABLE[split=repeat]
\bTABLEhead
\bTR \bTD Col1 \eTD \bTD Col2 \eTD \eTR
\eTABLEhead
\bTABLEbody
\dorecurse{50}{\bTR \bTD Value1 \eTD \bTD
[title={Test}]
\placetable[split]{Test}{
\bTABLE[split=repeat]
\bTABLEhead
\bTR \bTD Col1 \eTD \bTD Col2 \eTD \eTR
\eTABLEhead
\bTABLEbody
\dorecurse{50}{\bTR \bTD Value1 \eTD \bTD Value2 \eTD \eTR}
\eTABLEbody
\eTABLE}
\stopchapter
\stoptext
of the trials I made:
\defineipsum[tf][alternative=lines,n=2]
\starttext
\setupTABLE[r][first][style=\tf]
\bTABLE[split=repeat,option=stretch,frame=off,bottomframe=on]
\bTABLEhead
\bTR
\bTH[nc=2] This is the first page header \eTH
\eTR
\bTR
\bTH Column 1 \eTH
\bTH Column 2 \eTH
\eTR
]
\bTABLEhead
\bTR\bTH Thing \eTH\bTH Desc \eTH\eTR
\eTABLEhead
\bTABLEbody
\dorecurse{40}{\bTR\bTD Foo \eTD\bTD Text. \eTD\eTR}
\eTABLEbody
\eTABLE
\stopalignment
\stoptext
Thank you for any help.
Christoph
=no.
\starttext
\startalignment[middle]\dontleavehmode%
\bTABLE[split=yes]
\bTABLEhead
\bTR\bTH Thing \eTH\bTH Desc \eTH\eTR
\eTABLEhead
\bTABLEbody
\dorecurse{40}{\bTR\bTD Foo \eTD\bTD Text. \eTD\eTR}
\eTABLEbody
\eTABLE
\stopalignment
\stoptext
Thank
=middle]
\setupTABLE [header] [topframe=on,bottomframe=on]
\setupTABLE [row] [first] [topframe=on]
\setupTABLE [row] [last] [bottomframe=on]
\stopsetups
\starttext
\bTABLE[setups=table:rules]
\bTABLEhead
\bTR
\bTD Letters
]
\setupTABLE [start] [frame=off,align=middle]
\setupTABLE [header] [topframe=on,bottomframe=on]
\setupTABLE [row] [first] [topframe=on]
\setupTABLE [row] [last] [bottomframe=on]
\stopsetups
\starttext
\bTABLE[setups=table:rules]
\bTABLEhead
\bTR
[table:rules]
\setupTABLE [start] [frame=off,align=middle]
\setupTABLE [header] [topframe=on,bottomframe=on]
\setupTABLE [row] [first] [topframe=on]
\setupTABLE [row] [last] [bottomframe=on]
\stopsetups
\starttext
\bTABLE[setups=table:rules]
\bTABLEhead
tufte \par
}
\setuplayout[WithoutMarginnotes]
\placetable[split][]{Big table object}
{
\setupTABLE[row][1][width=\textwidth]
\bTABLE[split=repeat]
\bTABLEhead
\bTR \bTD XXX \eTD \eTR
\eTABLEhead
\bTABLEbody
\dorecurse{20}{
\bTR \bTD XXX \eTD \eTR}
\eTABLEbody
\eTABLE
}
\setuplayout
=on]
\setupTABLE[column][last][rightframe=on]
\stopsetups
\placefigure[here]{Diverses mesures}{
\bTABLE[setups={table:header, table:frame, table:style}]
\bTABLEhead
\bTR \bTD Esdeveniment \eTD \bTD Mesura (m) \eTD \eTR
\eTABLEhead
\bTABLEbody
\bTR \bTD Distància mitjana Terra-Lluna \eTD
={table:header, table:frame, table:style}]
\bTABLEhead
\bTR \bTD Esdeveniment \eTD \bTD Mesura (m) \eTD \eTR
\eTABLEhead
\bTABLEbody
\bTR \bTD Distà ncia mitjana Terra-Lluna \eTD \bTD 150.000.000.000 \eTD \eTR
\bTR \bTD Dià metre mitjà terrestre \eTD \bTD 12 800.000 \eTD \eTR
\bTR \bTD Distà ncia Palma
={table:header, table:frame, table:style}]
\bTABLEhead
\bTR \bTD Esdeveniment \eTD \bTD Mesura (m) \eTD \eTR
\eTABLEhead
\bTABLEbody
\bTR \bTD Distància mitjana Terra-Lluna \eTD \bTD 150.000.000.000 \eTD \eTR
\bTR \bTD Diàmetre mitjà terrestre \eTD \bTD 12 800.000 \eTD \eTR
\bTR \bTD Distància Palma
=on]
\stopsetups
\placefigure[here]{Diverses mesures}{
\bTABLE[setups={table:header, table:frame, table:style}]
\bTABLEhead
\bTR \bTD Esdeveniment \eTD \bTD Mesura (m) \eTD \eTR
\eTABLEhead
\bTABLEbody
\bTR \bTD Distància mitjana Terra-Lluna \eTD \bTD 150.000.000.000 \eTD \eTR
\bTR \bTD
=on]
\bTABLEhead
\bTR
\bTD[nr=3] Trial \eTD
\bTD[nr=3] Author \eTD
\bTD[nr=3] Year \eTD
\bTD[nc=4] Infected when\eTD
\bTD[nr=3] {Absolute\\ latitute}\eTD
\eTR
\bTR
\bTD[nc=2] vaccinated \eTD
\bTD[nc=2] not vaccinated \eTD
\eTR
\bTR
\bTD yes \eTD
\bTD no \eTD
\bTD yes \eTD
\bTD
\defineoverlay[OL:thickBtm][\useMPgraphic{MP:thickBtm}]
\starttext
\bTABLE
\setupTABLE[align=middle]
\setupTABLE[header][background={foreground,OL:thickBtm}]
%
\bTABLEhead\bTR\dorecurse{3}{\bTH#1\eTH}\eTR\eTABLEhead
\bTABLEbody\dorecurse{6}{\bTR\dorecurse{3}{\bTD#1-##1\eTD}\eTR
={center,lohi},style={\bfx}]
\setupTABLE[r][1][align={hilo,center},style={\bfx}]
\setupTABLE[c][2][width=20em,style={\tfx}]
\bTABLEhead
\bTR\bTH Row number \eTH\bTH Content \eTH\eTR
\eTABLEhead
\bTABLEbody
\bTR\bTC 1 \eTC\bTC \input{knuth} \eTC\eTR
\bTR\bTC 2 \eTC\bTC \input{knuth
Hello,
I naively tried using
\bTD\numexpr\currentTABLErow\minusone\relax\dTD
in a TABLE.
As I do not master even simple calculations under TeX, I do not see
what I am missing in order to label TABLE rows, starting from 0?
(Row 1 is a heading, set off by \bTABLEhead\eTABLEhead, which
]
%
\bTABLEhead\bTR\dorecurse{3}{\bTH#1\eTH}\eTR\eTABLEhead
\bTABLEbody\dorecurse{6}{\bTR\dorecurse{3}{\bTD#1-##1\eTD}\eTR}\eTABLEbody
\eTABLE
\stoptext
Best regards,
Lukas
--
Ing. Lukáš Procházka [mailto:l...@pontex.cz]
Pontex s. r. o. [mailto:pon...@pontex.cz] [http://www.pontex.cz
},bottomrulethickness=1.5mm,
boffset=.55mm]
%
\bTABLEhead\bTR\dorecurse{3}{\bTH#1\eTH}\eTR\eTABLEhead
\bTABLEbody\dorecurse{6}{\bTR\dorecurse{3}{\bTD#1-##1\eTD}\eTR}\eTABLEbody
\eTABLE
\stoptext
This e-mail message (including any attachments) is for the sole
][background={OL:thickBtm},bottomrulethickness=3mm,boffset=1.3mm]
\setupTABLE[row][4][background={OL:thickBtm},bottomrulethickness=1.5mm,
boffset=.55mm]
%
\bTABLEhead\bTR\dorecurse{3}{\bTH#1\eTH}\eTR\eTABLEhead
\bTABLEbody\dorecurse{6}{\bTR\dorecurse{3}{\bTD#1-##1\eTD}\eTR}\eTABLEbody
Hello,
how to achieve the table header to have a thick bottom line?
Here are my two attempts:
\starttext
\bTABLE
\setupTABLE[width=broad]
\setupTABLE[header][align=middle]
\bTABLEhead
\bTR[bottomframe=on,rulethickness=2mm]\bTH a\eTH\bTH b\eTH\eTR
\eTABLEhead
On Mon, 22 Oct 2012, Procházka Lukáš Ing. - Pontex s. r. o. wrote:
Hello,
how to achieve the table header to have a thick bottom line?
Here are my two attempts:
\starttext
\bTABLE
\setupTABLE[width=broad]
\setupTABLE[header][align=middle]
\bTABLEhead
\bTR[bottomframe
] % Settings for ALL columns in the row 1
should be overwritten ... [2]
\bTABLEhead
\bTR
\bTH a\eTH
\bTH b\eTH
\eTR
\eTABLEhead
\bTABLEbody
\bTR
\bTD a\eTD
\bTD b\eTD
\eTR
\eTABLEbody
\eTABLE
}
\starttext
No column specification
] %
... [1]
\setupTABLE[row][1][align=middle] % Settings for ALL columns in the row 1
should be overwritten ... [2]
\bTABLEhead
\bTR
\bTH a\eTH
\bTH b\eTH
\eTR
\eTABLEhead
\bTABLEbody
\bTR
\bTD a\eTD
with a particular column settings to work:
\starttext
\bTABLE
\setupTABLE[width=2cm]
\setupTABLE[column][2][align=flushright]
\setupTABLE[row][1][align=middle] % Settings for ALL columns in the row 1
should be overwritten; but are not (?!)
\bTABLEhead[align=middle]
\bTR
in the row 1
should be overwritten; but are not (?!)
\bTABLEhead[align=middle]
\bTR
\bTH[align=middle] a\eTH
\bTH[align=middle] b\eTH
\eTR
\eTABLEhead
\bTABLEbody
\bTR
\bTD a\eTD
\bTD b\eTD
\eTR
\eTABLEbody
\eTABLE
Hello
how to center a table over several pages?
Suppose the following code:
\def\TAB{%
\bTABLE[split=repeat]
\bTABLEhead
\bTR
\bTH head1 \eTH
\eTR
\eTABLEhead
%
\bTABLEbody
\dorecurse{40}{%
\bTR
\bTD body \eTD
\eTR
Am 20.09.2012 um 09:26 schrieb Procházka Lukáš Ing. - Pontex s. r. o.
l...@pontex.cz:
Hello
how to center a table over several pages?
Suppose the following code:
\def\TAB{%
\bTABLE[split=repeat]
\bTABLEhead
\bTR
\bTH head1 \eTH
\eTR
\eTABLEhead
Hello,
On Thu, 20 Sep 2012 15:51:23 +0200, Wolfgang Schuster
wolfgang.schus...@gmail.com wrote:
Use \placetable[force]{}{…} and omit the caption with the “none” keyword when
you don’t want it.
WOlfgang
did you mean this?
\def\TAB{%
\bTABLE[split=repeat]
\bTABLEhead
\bTR
it.
WOlfgang
did you mean this?
\def\TAB{%
\bTABLE[split=repeat]
\bTABLEhead
\bTR
\bTH head1 \eTH
\eTR
\eTABLEhead
%
\bTABLEbody
\dorecurse{40}{%
\bTR
\bTD body \eTD
\eTR
}
\eTABLEbody
\eTABLE
}
\starttext
You need also the “split” keyword for the float.
\starttext
\startplacetable[location={force,split,none}]
\bTABLE[split=repeat]
\bTABLEhead
\bTR
\bTH head1 \eTH
\eTR
\eTABLEhead
%
\bTABLEbody
\dorecurse{40}{%
\bTR
\bTD body \eTD
\eTR
]%
\bTABLEhead%
\bTR%
\bTH[nc=23]{\setupinterlinespace\strut Freddie Mac Fixed 30yr
3.0\strut\par}\eTH%
\eTR%
\bTR%
\bTH[]{\setupinterlinespace\strut \strut\par}\eTH%
\bTH[]{\setupinterlinespace\strut \strut\par}\eTH%
\bTH[]{\setupinterlinespace\strut \strut\par}\eTH%
\bTH[nc=4]{\setupinterlinespace\strut
=on]
\bTABLEhead[bottomframe=on]
\bTR\bTD Head \eTD\eTR
\bTR\bTD Head \eTD\eTR
\eTABLEhead
\bTABLEbody
\bTR\bTD 11\eTD\bTD 12\eTD\eTR
\bTR\bTD 21\eTD\bTD 22\eTD\eTR
\eTABLEbody
\eTABLE
\stoptext
How to specify rules (frame) to get the desired look?
TIA
:
\starttext
\bTABLE[split=repeat,option=stretch,align=middle,frame=off,leftframe=on,rightframe=on]
\bTABLEhead[bottomframe=on]
\bTR\bTD Head \eTD\eTR
\bTR\bTD Head \eTD\eTR
\eTABLEhead
\bTABLEbody
\bTR\bTD 11\eTD\bTD 12\eTD\eTR
\bTR\bTD 21\eTD\bTD 22
:
\starttext
\bTABLE[split=repeat,option=stretch,align=middle,frame=off,leftframe=on,rightframe=on]
\bTABLEhead[bottomframe=on]
\bTR\bTD Head \eTD\eTR
\bTR\bTD Head \eTD\eTR
\eTABLEhead
\bTABLEbody
\bTR\bTD 11\eTD\bTD 12\eTD\eTR
\bTR\bTD 21\eTD\bTD 22\eTD\eTR
=off,leftframe=on,rightframe=on]
\setupTABLE[header][frame=on]
\setupTABLE[row][first][topframe=on]
\setupTABLE[row][last][bottomframe=on]
\bTABLE[split=repeat,option=stretch]
\bTABLEhead
\bTR\bTD Head \eTD\bTD Head \eTD\eTR
\eTABLEhead
\bTABLEbody
\bTR\bTD 11\eTD\bTD 12\eTD\eTR
\bTR
\dorecurse{35}{some text some text some text some text some text\crlf}
\subsubsubject{Some Table}
\bTABLE[split=repeat]
\bTABLEhead
\bTR \bTD Col1 \eTD \bTD Col2 \eTD \bTD Col3 \eTD \eTR
\eTABLEhead
\bTABLEbody
\bTR \bTD foo \eTD \bTD bar \eTD \bTD \eTD \eTR
\bTR \bTD test \eTD \bTD test \eTD \bTD
},bottomframe=on] % Styling 2
\starttext
\placetable
[here][tab:example]
{A very simple example of a table.}{
\bTABLE
\bTABLEhead
\bTR
\bTH col1 \eTH
\bTH col2 \eTH
\eTR
\eTABLEhead
\bTABLEbody
\bTR
\bTC this \eTC
\bTC is \eTC
\eTR
\bTR
\bTC a \eTC
\bTC
]% Styling 1
\setupTABLE[r][first][style={\ss},bottomframe=on] % Styling 2
\starttext
\placetable
[here][tab:example]
{A very simple example of a table.}{
\bTABLE
\bTABLEhead
\bTR
\bTH col1 \eTH
\bTH col2 \eTH
\eTR
\eTABLEhead
\bTABLEbody
\bTR
\bTC this \eTC
this gives me a nice gray background, it still uses a serif font. Since
the background is applied I guess it somehow drops anything which is defined
as style.
Any other ideas or is this a bug?
Don’t use \bTH when you use put the header in a \bTABLEhead … \eTABLEhead block
because the \bTH
Am 15.03.2012 um 15:36 schrieb Wolfgang Schuster:
Don’t use \bTH when you use put the header in a \bTABLEhead … \eTABLEhead
block because the \bTH command applies a format the the cells, when you use
\bTD instead no formatting is applied and the \setupTABLE setting is used.
Thanks Wolfgang
Am 15.03.2012 um 15:59 schrieb Steffen Fritzsche:
Am 15.03.2012 um 15:36 schrieb Wolfgang Schuster:
Don’t use \bTH when you use put the header in a \bTABLEhead … \eTABLEhead
block because the \bTH command applies a format the the cells, when you use
\bTD instead no formatting is applied
I've ended up delving into the dark art that is Lua for this solution:
\define[0]\SummaryTable{%
\placetable[force, none]{}{%
\setupTABLE[frame=off]
\bTABLE
\bTABLEhead
\bTR\bTH Reference\eTH\bTH Title\eTH\bTH Page\eTH\eTR
\eTABLEhead
\bTABLEbody
\startluacode
for k, v in ipairs
On 14-12-2011 17:50, Felix Ingram wrote:
I've ended up delving into the dark art that is Lua for this solution:
\define[0]\SummaryTable{%
\placetable[force, none]{}{%
\setupTABLE[frame=off]
\bTABLE
\bTABLEhead
\bTR\bTH Reference\eTH\bTH Title\eTH\bTH Page\eTH\eTR
\eTABLEhead
\bTABLEbody
]
\starttext
\startchapter[title=Chapter]
\startsection[title=section]
\dorecurse{2}{\input knuth }
\startplacetable[title={My Table},location=split]
\bTABLE[option=stretch]
\bTABLEhead
\bTR
\bTH C1 \eTH
\bTH C2 \eTH
\eTR
\eTABLEhead
[table][location=top]
\setuplabeltext[table={Tabelle ,:}]
\starttext
\startchapter[title=Chapter]
\startsection[title=section]
\dorecurse{2}{\input knuth }
\startplacetable[title={My Table},location=split]
\bTABLE[option=stretch]
\bTABLEhead
\bTR
\bTH C1 \eTH
?
Examle (table is not split, but could be):
\starttext
\dorecurse{2}{\input knuth }
\startplacetable[title={My Table}]
\bTABLE[option=stretch,split=repeat]
\bTABLEhead
\bTR
\bTH C1 \eTH
\bTH C2 \eTH
\eTR
\eTABLEhead
\bTABLEbody
}) ;
\stopuniqueMPgraphic
\defineoverlay[shaded][\useMPgraphic{LinearShade}]
\setupTABLE[row][1][background={shaded},backgroundcolor=blue,foregroundcolor=white]
\starttext
\framed[background={shaded}, width=\textwidth, frame=off]{}
\bTABLE
\bTABLEhead
\bTR \bTH 1 \eTH \bTH 1 \eTH \bTH 1 \eTH
]{}
\bTABLE
\bTABLEhead
\bTR \bTH 1 \eTH \bTH 1 \eTH \bTH 1 \eTH \bTH 1 \eTH \bTH Page \eTH \eTR
\eTABLEhead
\bTABLEbody
\bTR \bTD 1 \eTD \bTD 1 \eTD \bTD 1 \eTD \bTD 1 \eTD \bTD 1 \eTD \eTR
\eTABLEbody
\eTABLE
\stoptext
The output shows a framed element which is similar to what I want to
achieve
]
\setupTABLE[c][1][align=right,width=.30\textwidth]
\setupTABLE[c][2][width=.70\textwidth]
\stopsetups
\starttext
\bTABLE[setups=mytable]
\bTABLEhead
\bTR \bTD[nx=2] The most important commands \eTD \eTR
\eTABLEhead
\bTABLEbody
\bTR
\bTD \type{\completecontent} \eTD
\bTD This generates a Table
]
\setupTABLE[c][1][align=right,width=.30\textwidth]
\setupTABLE[c][2][width=.70\textwidth]
\stopsetups
\starttext
\bTABLE[setups=mytable]
\bTABLEhead
\bTR \bTD[nx=2] The most important commands \eTD \eTR
\eTABLEhead
\bTABLEbody
\bTR
\bTD \type{\completecontent} \eTD
\bTD
Am 10.04.2011 um 18:40 schrieb Florian Wobbe:
2) How do I get a small and bold header? This does not work:
\bTABLE
\setupTABLE[style=\tfx]
\setupTABLE[row][1][style=\bfx] % redundant w/ line 5
\bTABLEhead
\bTR[style=\bfx] \bTH Header \eTH \eTR
\eTABLEhead
\bTABLEbody
\bTR \bTD hello
2) How do I get a small and bold header? This does not work:
\bTABLE
\setupTABLE[style=\tfx]
\setupTABLE[row][1][style=\bfx] % redundant w/ line 5
\bTABLEhead
\bTR[style=\bfx] \bTH Header \eTH \eTR
\eTABLEhead
\bTABLEbody
\bTR \bTD hello \eTD \eTR
\bTR \bTD world \eTD \eTR
\eTABLEbody
Hi,
1) how can I auto-stretch a natural table to a defined width? The default seems
to be the line width, which I don't want. Setting width=... will change the per
column width, which I don't like either. I'd like to set the per table width.
\bTABLE[option=stretch,width=80mm]
\bTABLEhead
\bTR
.
\bTABLE[option=stretch,width=80mm]
\bTABLEhead
\bTR \bTD Col1 \eTD \bTD Col2 \eTD \bTD Col3 \eTD \bTD Col4 \eTD \eTR
\eTABLEhead
\bTABLEbody
\dorecurse{5}{\bTR \bTD 1 \eTD \bTD 2 \eTD \bTD 3 \eTD \bTD 4 \eTD \eTR}
\eTABLEbody
\eTABLE
Or is there maybe the possibility to enforce
3) Consider this example:
\bTABLE[option=stretch]
\setupTABLE[frame=off,offset=0pt]
\bTABLEhead
\bTR[bottomframe=on] \bTD Col1 \eTD \bTD Col2 \eTD \bTD Col3 \eTD \bTD Col4
\eTD \eTR
\eTABLEhead
\bTABLEbody
\dorecurse{5}{\bTR \bTD 1 \eTD \bTD 2 \eTD \bTD 3 \eTD \bTD this is a long
still works in 2010.12.21 10:50.
Anyone got an idea which setups might cause this issue?
2) How do I get a small and bold header? This does not work:
\bTABLE
\setupTABLE[style=\tfx]
\setupTABLE[row][1][style=\bfx] % redundant w/ line 5
\bTABLEhead
\bTR[style=\bfx] \bTH Header \eTH \eTR
\eTABLEhead
1 - 100 of 196 matches
Mail list logo