Debian Codegraph @

texmf-dist/tex/luatex/nodetree/nodetree.tex

raw
1 %%
2 %% This is file `nodetree.tex',
3 %% generated with the docstrip utility.
4 %%
5 %% The original source files were:
6 %%
7 %% nodetree.dtx (with options: `tex')
8 %%
9 %% This is a generated file.
10 %%
11 %% Copyright (C) 2016-2025 by Josef Friedrich <[email protected]>
12 %% ----------------------------------------------------------------------
13 %% This work may be distributed and/or modified under the conditions of
14 %% the LaTeX Project Public License, either version 1.3c of this license
15 %% or (at your option) any later version. The latest version of this
16 %% license is in:
17 %%
18 %% http://www.latex-project.org/lppl.txt
19 %%
20 %% and version 1.3c or later is part of all distributions of LaTeX
21 %% version 2008/05/05 or later.
22 %%
23 \directlua{
24 nodetree = require('nodetree')
25 }
26 \def\NodetreeSetOption[#1]#2{
27 \directlua{
28 nodetree.set_option('#1', '#2')
29 }
30 }
31 \let\nodetreeoption\NodetreeSetOption
32 \def\NodetreeResetOption#1{
33 \NodetreeSetOption[#1]{%
34 \directlua{
35 tex.print(nodetree.get_default_option('#1'))
36 }%
37 }%
38 }
39 \def\NodetreeReset{
40 \NodetreeResetOption{callback}
41 \NodetreeResetOption{channel}
42 \NodetreeResetOption{color}
43 \NodetreeResetOption{decimalplaces}
44 \NodetreeResetOption{unit}
45 \NodetreeResetOption{verbosity}
46 }
47 \let\nodetreereset\NodetreeReset
48 \def\NodetreeRegisterCallback#1{
49 \directlua{
50 nodetree.set_option('callback', '#1')
51 nodetree.register_callbacks()
52 }
53 }
54 \let\nodetreeregister\NodetreeRegisterCallback
55 \def\NodetreeUnregisterCallback#1{
56 \directlua{
57 nodetree.set_option('callback', '#1')
58 nodetree.unregister_callbacks()
59 }
60 }
61 \let\nodetreeunregister\NodetreeUnregisterCallback
62 \endinput
63 %%
64 %% End of file `nodetree.tex'.