ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Robert Zydenbos <context@zydenbos.net>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: Centering tabulate env. using \setuptabulate
Date: Fri, 23 May 2014 04:17:00 +0200	[thread overview]
Message-ID: <BB7860F1-3A0C-44B5-B66D-37FB0EEF41D3@zydenbos.net> (raw)
In-Reply-To: <FBD2E66C-815B-4159-B888-B8A7839DA598@gmail.com>

This is a topic that is of great interest to me. I have been trying to make tables in mkii (because I need XeTeX for my Indic fonts) that span across pages and in which cells are more than one line (so I use the 'p' parameter).

I'm enclosing a test file below. Any suggestions?

RZ

---start of test source---
% !TEX TS-program = ConTeXt (XeTeX)
\starttext

\input knuth

\setuptabulate[split=yes]

% ---> *** I WANT THIS TABLE TO BE CENTERED *** <---

\starttabulate [|p(.5\textwidth)|p(.2\textwidth)|]
\dorecurse{4}{
\NC 
Nu laat ik je iets zien in een tabel, die met tabulate gemaakt is. \NC Het is overigens maar een experiment, maar we zullen zien wat er gebeurt. {\bf And I want all this to be centered.} \NC \NR
\NR
\NC Als dit werkt, dan gaan we heel fanatiek hiermee verder. \NC Dan gaan we allerlei prachtige zaken in ConTeXt zetten, met XeTeX. \NC \NR
\NR
} % end of \dorecurse
\stoptabulate


En nu iets met een ander mechanisme. Maar we moeten zien in hoeverre al deze mooie dingen formatteerbaar zijn.
\blank


% ---> *** I WANT THIS TABLE TO BE CENTERED TOO, AND SPLIT ACROSS PAGES *** <---

\dorecurse{5}{
\setupTABLE[row][each][rulethickness=.5pt,distance=1.5em,offset=\dimexpr3mm,split=repeat]
\bTABLE
\bTR \bTD Dit is iets in een TABLE. Of ik het begrepen heb? \eTD  \bTD Misschien wel. \eTD \eTR
\bTR \bTD \eTD \bTD En als ik nu maar éen cel schrijf? Het zou namelijk kunnen, dat hiermee tegen de een of andere regel gezondigd wordt, die in documentatie niet te vinden is. En in dat geval gaat het hele experiment niet op, of, nou ja, slechts ten dele. {\bf But drat, I want this box to be split across pages!}\eTD \eTR
\eTABLE
\blank

} % end of \dorecurse

\midaligned {
\setupTABLE[row][each][rulethickness=1.5pt,distance=1mm,offset=\dimexpr2mm+2pt,split=repeat]
\startTABLE
\NC Text 1 \NC Text 2 \NC\NR
\NC Text 3 \NC Text 4 \NC\NR
\stopTABLE
}

\stoptext
---end of test source---

___________________________________________________________________________________
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
___________________________________________________________________________________


  reply	other threads:[~2014-05-23  2:17 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-13  3:28 Devendra Ghate
2014-05-13  5:03 ` Mikael P. Sundqvist
2014-05-13  7:22   ` Procházka Lukáš Ing. - Pontex s. r. o.
2014-05-13  7:30     ` Mikael P. Sundqvist
2014-05-13  8:36       ` Otared Kavian
2014-05-13  8:49         ` Mikael P. Sundqvist
2014-05-13  9:00           ` Mikael P. Sundqvist
2014-05-13 10:23       ` Wolfgang Schuster
2014-05-23  2:17         ` Robert Zydenbos [this message]
2014-05-23  3:05           ` Wolfgang Schuster
2014-05-27  8:57             ` Robert Zydenbos
2014-05-27 13:37               ` Wolfgang Schuster
2014-05-28  8:46                 ` Robert Zydenbos
2014-05-28 11:51                   ` Hans Hagen
2014-05-28 18:25                     ` Robert Zydenbos
2014-05-28 20:10                       ` Hans Hagen
2014-05-28 20:33                         ` Robert Zydenbos
2014-05-28 13:53                   ` Wolfgang Schuster

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=BB7860F1-3A0C-44B5-B66D-37FB0EEF41D3@zydenbos.net \
    --to=context@zydenbos.net \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).