[NTG-context] Preserve line height with TABLE

2011-12-21 Thread Andreas Harder
Hi,

is there a way to mimic the tabulate behavior with TABLE (or xtable)?

\starttext

\def\HtTest#1%
  {\setbox\scratchbox\vbox{#1}hight=\the\ht\scratchbox\par\vbox{#1}\blank}

\HtTest{\strut
(Äg) first line\par
second line\par
(Äg) third line}

\setuptabulate[before=,after=,]
\HtTest{\starttabulate[|l|]
\NC (Äg) first line  \NC\NR
\NC second line  \NC\NR
\NC (Äg) third line  \NC\NR
\stoptabulate}

\HtTest{\bTABLE[frame=off,offset=overlay,left=\strut] % ,rulethickness=0pt
\bTR\bTD (Äg) first line  \eTD\eTR
\bTR\bTD second line  \eTD\eTR
\bTR\bTD (Äg) third line  \eTD\eTR
\eTABLE}

\HtTest{\startembeddedxtable[frame=off,offset=overlay]
  \startxrow \startxcell (Äg) first line \stopxcell \stopxrow
  \startxrow \startxcell second line \stopxcell \stopxrow
  \startxrow \startxcell (Äg) third line \stopxcell \stopxrow
\stopembeddedxtable}

\stoptext


Thanks in advance
Andreas
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Preserve line height with TABLE

2011-12-21 Thread Wolfgang Schuster

Am 21.12.2011 um 13:24 schrieb Andreas Harder:

 Hi,
 
 is there a way to mimic the tabulate behavior with TABLE (or stable)?

You need “offset=0pt” and “strut=yes” (not left=\strut).

Wolfgang
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Preserve line height with TABLE

2011-12-21 Thread Andreas Harder

On 21.12.2011, at 14:20, Wolfgang Schuster wrote:

 
 Am 21.12.2011 um 13:24 schrieb Andreas Harder:
 
 Hi,
 
 is there a way to mimic the tabulate behavior with TABLE (or stable)?
 
 You need “offset=0pt” and “strut=yes” (not left=\strut).

Thanks Wolfgang,

but it still not the hight from tabulate …

Andreas
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Preserve line height with TABLE

2011-12-21 Thread Wolfgang Schuster

Am 21.12.2011 um 14:28 schrieb Andreas Harder:

 
 On 21.12.2011, at 14:20, Wolfgang Schuster wrote:
 
 
 Am 21.12.2011 um 13:24 schrieb Andreas Harder:
 
 Hi,
 
 is there a way to mimic the tabulate behavior with TABLE (or stable)?
 
 You need “offset=0pt” and “strut=yes” (not left=\strut).
 
 Thanks Wolfgang,
 
 but it still not the hight from tabulate …

The here and also in your other question is that \begstrut is broken, when you 
add (the definition of \begstrut)

\starttexcode
\unexpanded\def\begstrut
  {\relax\ifcase\strutht
 % \ignorespaces % maybe
   \else
 \spacing_begstrut
   \fi}
\stoptexcode

at the begin of your example you get a output for TABLE and stable which comes 
close to tabulate.

Wolfgang

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Preserve line height with TABLE

2011-12-21 Thread Andreas Harder

On 21.12.2011, at 14:39, Wolfgang Schuster wrote:

 
 Am 21.12.2011 um 14:28 schrieb Andreas Harder:
 
 
 On 21.12.2011, at 14:20, Wolfgang Schuster wrote:
 
 
 Am 21.12.2011 um 13:24 schrieb Andreas Harder:
 
 Hi,
 
 is there a way to mimic the tabulate behavior with TABLE (or stable)?
 
 You need “offset=0pt” and “strut=yes” (not left=\strut).
 
 Thanks Wolfgang,
 
 but it still not the hight from tabulate …
 
 The here and also in your other question is that \begstrut is broken, when 
 you add (the definition of \begstrut)
 
 \starttexcode
 \unexpanded\def\begstrut
  {\relax\ifcase\strutht
 % \ignorespaces % maybe
   \else
 \spacing_begstrut
   \fi}
 \stoptexcode
 
 at the begin of your example you get a output for TABLE and stable which 
 comes close to tabulate.

Thank you very much!

Andreas
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___