From: Jeroen <contextntg@gmail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: [NTG-context] Re: Local alternative to \input
Date: Mon, 4 Mar 2024 06:14:39 +0100 [thread overview]
Message-ID: <CAPtmdbNE3dpMPqqfjLkMG584J9pQvM8O6AjMKjmfjv7NfrVMtg@mail.gmail.com> (raw)
In-Reply-To: <eb481107-aec9-43e3-a357-6c1a24fa669d@fiee.net>
[-- Attachment #1.1: Type: text/plain, Size: 1984 bytes --]
With a single environment it seems to work, though when I expand it to
multiple, it does not seem to work anymore
\starttext
SomeText \\
\environment aaa \\
SomeText \\
\environment bbb \\
SomeText \\
\startenvironment aaa
\samplefile{lorem}
\stopenvironment
\startenvironment bbb
\samplefile{tufte}
\stopenvironment
\stoptext
Op do 4 jan 2024 om 20:14 schreef Henning Hraban Ramm <texml@fiee.net>:
> Am 04.01.24 um 18:00 schrieb Jeroen:
> > I just would like to have a lot of mark-up for combined figures and
> > tables etc moved out of the way, similar to this. I am loosing the
> > general documetn flow because of all this markup. Would there be a
> > construction similar to this:
> >
> > \starttext
> >
> > \environment foo
> > \environment bar
> >
> > \startenvironment foo
> > this is a lot of text
> > \stopenvironment
> >
> > \startenvironment bar
> > and this is another piece of text
> > \stopenvironment
> >
> > \stoptext
>
> An environment is a separate file.
> \environment is like \input with a few more checks, e.g. it loads the
> file only once.
>
> e.g.
>
> -- file "env_foo.tex" --
> \startenvironment env_foo
> % settings
> \stopenvironment
> --
>
>
> -- file document.tex --
> \environment env_foo
>
> \starttext
> % whatever
> \stoptext
> --
>
> Instead of the call within your document, you can also call
>
> context --environment=env_foo.tex document
>
> (Usually that makes only sense in XML workflows.)
>
> Hraban
>
> ___________________________________________________________________________________
> 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
>
> ___________________________________________________________________________________
>
[-- Attachment #1.2: Type: text/html, Size: 3061 bytes --]
[-- Attachment #2: Type: text/plain, Size: 511 bytes --]
___________________________________________________________________________________
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
___________________________________________________________________________________
next prev parent reply other threads:[~2024-03-04 5:18 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-04 16:12 [NTG-context] " Jeroen
2024-01-04 16:21 ` [NTG-context] " Wolfgang Schuster
2024-01-04 16:27 ` Henning Hraban Ramm
[not found] ` <b8802a76-0411-427a-932d-59c4e3ae2abb@gmail.com>
2024-01-04 19:12 ` Henning Hraban Ramm
2024-03-04 5:14 ` Jeroen [this message]
2024-03-04 9:43 ` Denis Maier via ntg-context
2024-03-04 15:49 ` Henning Hraban Ramm
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=CAPtmdbNE3dpMPqqfjLkMG584J9pQvM8O6AjMKjmfjv7NfrVMtg@mail.gmail.com \
--to=contextntg@gmail.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).