From: Bruce Horrocks <ntg@scorecrow.com>
To: ntg-context mailing list <ntg-context@ntg.nl>
Subject: [NTG-context] Re: How to stop
Date: Mon, 29 Jan 2024 00:18:20 +0000 [thread overview]
Message-ID: <0C4FC83F-01C5-4E9A-8CB1-EAA98330CDF9@scorecrow.com> (raw)
In-Reply-To: <679125479.963582.1706390984390@mail.yahoo.com>
> On 27 Jan 2024, at 21:29, Joel via ntg-context <ntg-context@ntg.nl> wrote:
>
> I have a document that uses ~40 different TABLE configurations, each with their own special requirements, such as these below, and in total, perhaps 2000 tables appear in a file, using one of the configurations.
>
> \setupTABLE[r][1][align=raggedleft]
> \setupTABLE[c][1][width=.1\textwidth]
> \setupTABLE[c][2][width=.33\textwidth]
> \setupTABLE[c][3][width=.37\textwidth]
> \setupTABLE[c][4][width=.1\textwidth]
> \setupTABLE[c][5][width=.1\textwidth]
> \setupTABLE[c][1,2,3,4,5][align=raggedleft, frame=off]
> %\setupTABLE[r][2,3,4,5,6,8,9,11,12,14][bottomframe=off]
> \setupTABLE[r][1][bottomframe=on]
> \bTABLE[split=yes]
> \bTR\bTD {\it Lesson} \eTD\bTD {\it Time} \\eTD\bTD {\it Date} \eTD\bTD {\it Page} \eTD\eTR
> \eTABLE
>
> What I've been finding is that previous settings on TABLES appearing earlier in the document is impacting later tables. For instance, if one has a frame to the right of column 1, then the next table seems to acquire this setting as well, even if it isn't expected to have any frames at all.
>
> Note that each unique table is defined inside a macro.
>
> How can I make these table settings only apply to the a specific table?
Use setups, one for each of your 40 variations:
e.g:
\startsetup formatA
\setupTABLE[r][1][align=raggedleft]
\setupTABLE[c][1][width=.1\textwidth]
\stopsetup
\startsetup formatB
\setupTABLE[c][1,2,3,4,5][align=raggedleft, frame=off]
\stopsetup
\bTABLE[setups=formatA]
...
\eTABLE
\bTABLE[setups=formatB]
...
\eTABLE
—
Bruce Horrocks
Hampshire, UK
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___________________________________________________________________________________
prev parent reply other threads:[~2024-01-29 0:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <679125479.963582.1706390984390.ref@mail.yahoo.com>
2024-01-27 21:29 ` [NTG-context] " Joel via ntg-context
2024-01-27 21:49 ` [NTG-context] " Hraban Ramm
2024-01-29 0:18 ` Bruce Horrocks [this message]
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=0C4FC83F-01C5-4E9A-8CB1-EAA98330CDF9@scorecrow.com \
--to=ntg@scorecrow.com \
--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).