summaryrefslogtreecommitdiff
path: root/doc/context/sources/general
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2018-08-11 01:23:08 +0200
committerContext Git Mirror Bot <phg@phi-gamma.net>2018-08-11 01:23:08 +0200
commit1ef7a093aaf03b6327b3da94d47f53760c868c60 (patch)
tree228e6d4a5005598aaea191b3317c2fa21e22de75 /doc/context/sources/general
parentb61d5dd3555e906b21601ff75b3268c0f359283e (diff)
downloadcontext-1ef7a093aaf03b6327b3da94d47f53760c868c60.tar.gz
2018-08-10 16:58:00
Diffstat (limited to 'doc/context/sources/general')
-rw-r--r--doc/context/sources/general/manuals/luatex/luatex-nodes.tex34
-rw-r--r--doc/context/sources/general/manuals/luatex/luatex-style.tex2
2 files changed, 23 insertions, 13 deletions
diff --git a/doc/context/sources/general/manuals/luatex/luatex-nodes.tex b/doc/context/sources/general/manuals/luatex/luatex-nodes.tex
index 07f99ba00..114fa0d83 100644
--- a/doc/context/sources/general/manuals/luatex/luatex-nodes.tex
+++ b/doc/context/sources/general/manuals/luatex/luatex-nodes.tex
@@ -408,11 +408,11 @@ it considers some input to be text.
\NC \type{components} \NC node \NC pointer to ligature components \NC \NR
\NC \type{xoffset} \NC number \NC a virtual displacement in horizontal direction \NC \NR
\NC \type{yoffset} \NC number \NC a virtual displacement in vertical direction \NC \NR
-%NC \type{xadvance} \NC number \NC an additional advance after the glyph (experimental) \NC \NR
\NC \type{width} \NC number \NC the (original) width of the character \NC \NR
\NC \type{height} \NC number \NC the (original) height of the character\NC \NR
\NC \type{depth} \NC number \NC the (original) depth of the character\NC \NR
\NC \type{expansion_factor} \NC number \NC the to be applied expansion_factor \NC \NR
+\NC \type{data} \NC number \NC a general purpose field for users (we had room for it) \NC \NR
\LL
\stoptabulate
@@ -876,12 +876,12 @@ instead of \type {108}).
\subsection{\whs {late_lua}}
\starttabulate[|l|l|p|]
-\DB field \BC type \BC explanation \NC \NR
+\DB field \BC type \BC explanation \NC \NR
\TB
-\NC \type{attr} \NC node \NC list of attributes \NC \NR
-\NC \type{data} \NC string \NC data to execute \NC \NR
-\NC \type{string} \NC string \NC data to execute \NC \NR
-\NC \type{name} \NC string \NC the name to use for \LUA\ error reporting \NC \NR
+\NC \type{attr} \NC node \NC list of attributes \NC \NR
+\NC \type{data} \NC string or function \NC the to be written information stored as \LUA\ value \NC \NR
+\NC \type{token} \NC string \NC the to be written information stored as token list \NC \NR
+\NC \type{name} \NC string \NC the name to use for \LUA\ error reporting \NC \NR
\LL
\stoptabulate
@@ -913,11 +913,12 @@ output file.
\subsection{\whs {pdf_literal}}
\starttabulate[|l|l|p|]
-\DB field \BC type \BC explanation \NC \NR
+\DB field \BC type \BC explanation \NC \NR
\TB
-\NC \type{attr} \NC node \NC list of attributes \NC \NR
-\NC \type{mode} \NC number \NC the \quote {mode} setting of this literal \NC \NR
-\NC \type{data} \NC string \NC the \orm {pdfliteral} information \NC \NR
+\NC \type{attr} \NC node \NC list of attributes \NC \NR
+\NC \type{mode} \NC number \NC the \quote {mode} setting of this literal \NC \NR
+\NC \type{data} \NC string \NC the to be written information stored as \LUA\ string \NC \NR
+\NC \type{token} \NC string \NC the to be written information stored as token list \NC \NR
\LL
\stoptabulate
@@ -2355,6 +2356,7 @@ consistency. You can of course always define additional accessors using \type
\supported {getsubtype} \yes \yes
\supported {getsub} \nop \yes
\supported {getsup} \nop \yes
+\supported {getdata} \nop \yes
\supported {getwhd} \yes \yes
\supported {getwidth} \nop \yes
\supported {has_attribute} \yes \yes
@@ -2397,6 +2399,7 @@ consistency. You can of course always define additional accessors using \type
\supported {setfam} \nop \yes
\supported {setfield} \yes \yes
\supported {setfont} \nop \yes
+\supported {setexpansion} \nop \yes
\supported {setglue} \yes \yes
\supported {setheight} \nop \yes
\supported {setkern} \nop \yes
@@ -2448,6 +2451,13 @@ taken for providing meta information about nodes. Note: The getters do only basi
checking for valid keys. You should just stick to the keys mentioned in the
sections that describe node properties.
+Some of the getters and setters handle multiple node types, given that the field
+is relevant. In that case, some field names are considered similar (like \type
+{kern} and \type {width}, or \type {data} and \type {value}. In retrospect we
+could have normalized field names better but we decided to stick to the original
+(internal) names as much as possible. After all, at the \LUA\ end one can easily
+create synonyms.
+
Some nodes have indirect references. For instance a math character refers to a
family instead of a font. In that case we provide a virtual font field as
accessor. So, \type {getfont} and \type {.font} can be used on them. The same is
@@ -2462,9 +2472,9 @@ you can enable that with:
node.fix_node_lists(<boolean> b)
\stopfunctioncall
-You can set and query the synctex fields, a file number aka tag and a line
+You can set and query the \SYNCTEX\ fields, a file number aka tag and a line
number, for a glue, kern, hlist, vlist, rule and math nodes as well as glyph
-nodes (although this last one is not used in native synctex).
+nodes (although this last one is not used in native \SYNCTEX).
\startfunctioncall
node.set_synctex_fields(<integer> f, <integer> l)
diff --git a/doc/context/sources/general/manuals/luatex/luatex-style.tex b/doc/context/sources/general/manuals/luatex/luatex-style.tex
index 8fd0a6aa5..708f83ed6 100644
--- a/doc/context/sources/general/manuals/luatex/luatex-style.tex
+++ b/doc/context/sources/general/manuals/luatex/luatex-style.tex
@@ -232,7 +232,7 @@
\startuseMPgraphic{luanumber}
% luaextraangle := \luaextraangle;
- luaextraangle := if (LastPageNumber == 0) : 0 else : (RealPageNumber / LastPageNumber) * 360 fi;
+ luaextraangle := if (LastPageNumber < 10) : 10 else : (RealPageNumber / LastPageNumber) * 360 fi;
luaorbitfactor := 0.25 ;
picture p ; p := lualogo ;
setbounds p to boundingbox fullcircle ;