ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Procházka Lukáš Ing. - Pontex s. r. o." <LPr@pontex.cz>
To: "mailing list for ConTeXt users" <ntg-context@ntg.nl>
Subject: Re: Ctx: list of commands
Date: Tue, 18 Sep 2012 08:44:14 +0200	[thread overview]
Message-ID: <op.wktjn0vawshuv7@lpr> (raw)
In-Reply-To: <20120917192956.GA7316@phlegethon>

Hello,

@Philipp:

>> 1) is there a Ctx command/switch which would generate list of all current ConTeXt commands? E.g.
>
> Hi Lukáš, if you interpret “current Context commands” as “macros
> known to TeX”, you may try dumping the hashtable with these lines:
>
> ·······································································
> \starttext
>   \startluacode
>     table.print(tex.hashtokens())
>   \stopluacode
> \stoptext
> ·······································································

thanks for the idea.

Unfortunately, "current Context commands" don't need to be necessarily "macros known to TeX", as ConTeXt may have defined many macros that are not "for public use".

It seems that my question is not so straightforward - I didn't think it would it could be problem to separate "public macros" (= public ConTeXt commands = these that are cited in manuals, on wiki or simply - which "you can use").

Maybe - if I know ALL macros - it would be easy to distinguish between "public" ones and "protected" ones - supposing the latter have always at least one of the special chars - _@?! (or other?) in it.

I tried your idea, but in this part of the output:

"
...
["startJScode"]={ 127, 290597, 60096 },
["startJSpreamble"]={ 127, 290644, 49920 },
["startLUA"]={ 127, 245948, 28541 },
["startLuaSnippet"]={ 127, 244345, 530 },
["startLuaSnippetBoundary"]={ 127, 246417, 46341 },
["startLuaSnippetComment"]={ 127, 247113, 23071 },
["startLuaSnippetName"]={ 127, 246301, 9781 },
["startLuaSnippetNameBase"]={ 127, 244439, 46291 },
["startLuaSnippetNameCore"]={ 127, 245803, 61132 },
["startLuaSnippetNameLibraries"]={ 127, 246257, 38877 },
["startLuaSnippetQuote"]={ 127, 246898, 19907 },
["startLuaSnippetSpecial"]={ 127, 247006, 23901 },
["startLuaSnippetString"]={ 127, 246646, 61126 },
["startMP"]={ 127, 245820, 14236 },
...
"

- the command/macro "\startluacode" is missing (why?) and

- e.g. the macro "\startLuaSnippetNameBase" is not mentioned "for public use" I guess, but also is not detectable by presence of any special char (@_!?).

So I'm not sure this way is usable.

@Hans:

How exactly did you mean to use:

>> \starttext
>>    \startluacode
>>      table.print(tex.hashtokens())
>>    \stopluacode
>> \stoptext
>> ·······································································
>
> or
>
> \enabledirectives[system.dumphash]
>
> \enabledirectives[system.dumpdelta]

This:

"
\starttext
   \enabledirectives[system.dumphash]
   \enabledirectives[system.dumpdelta]
\stoptext
"

gives nothing useful.

How exactly to use the command/switch "--textpad" or "--text" with "context.exe"?

Best regards,

Lukas


-- 
Ing. Lukáš Procházka [mailto:LPr@pontex.cz]
Pontex s. r. o.      [mailto:pontex@pontex.cz] [http://www.pontex.cz]
Bezová 1658
147 14 Praha 4

Tel: +420 244 062 238
Fax: +420 244 461 038

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

  parent reply	other threads:[~2012-09-18  6:44 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-17 13:40 Procházka Lukáš Ing. - Pontex s. r. o.
2012-09-17 13:56 ` Marco Patzer
2012-09-17 14:20   ` Sietse Brouwer
2012-09-17 15:11     ` Procházka Lukáš Ing. - Pontex s. r. o.
2012-09-17 19:29 ` Philipp Gesang
2012-09-17 22:24   ` Hans Hagen
2012-09-18  9:52     ` output of token.command_name() [was: Ctx: list of commands] Philipp Gesang
2012-09-18 10:25       ` Hans Hagen
2012-09-18  6:44   ` Procházka Lukáš Ing. - Pontex s. r. o. [this message]
2012-09-18  7:36     ` Ctx: list of commands Peter Münster
2012-09-18  7:44       ` Procházka Lukáš Ing. - Pontex s. r. o.
2012-09-18  8:28     ` Hans Hagen
2012-09-18 13:49     ` Rogers, Michael K
2012-09-18 14:00       ` Procházka Lukáš Ing. - Pontex s. r. o.
2012-09-18 14:59         ` Hans Hagen
2012-09-18 16:44           ` Sietse Brouwer
2012-09-18 17:52             ` Hans Hagen
2012-09-18 14:58       ` Hans Hagen

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=op.wktjn0vawshuv7@lpr \
    --to=lpr@pontex.cz \
    --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).