ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Lorenz <lorenz@fastmail.com>
To: ntg-context@ntg.nl
Subject: Custom pretty printer pass option to buff-imp-<mycustomformat>.lua
Date: Sun, 22 Jan 2017 14:35:37 -0500	[thread overview]
Message-ID: <1485113737.438258.855778584.7BE1E247@webmail.messagingengine.com> (raw)

I'm customizing a pretty printer and referencing the buff-imp-lua.lua
and buff-imp-lua.mkiv files.  

I'd like to add a conditional to the .lua file say buff-imp-custom.lua. 
What is a good way to pass an option from my .tex file to conditionally
format with the pretty printer?   I'd like to use the same
buff-imp-custom.lua and .mkiv pairs of files instead of creating
multiple files.

The .mkiv file defines e.g.:

    \definetyping
        [CUSTOM1]
        [\c!option=custom]

I'd like to add say CUSTOM2 but pass an option that would be visible to
the same buff-imp-custom.lua file.  Perhaps something like this?:

    \definetyping
        [CUSTOM2]
        [\c!option=custom,<option visible to same lua file as CUSTOM1?>]


Thanks 

--
Lorenz
___________________________________________________________________________________
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

             reply	other threads:[~2017-01-22 19:35 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-22 19:35 Lorenz [this message]
2017-01-22 21:49 ` Lorenz

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=1485113737.438258.855778584.7BE1E247@webmail.messagingengine.com \
    --to=lorenz@fastmail.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).