summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2017-06-04 17:42:38 +0200
committerContext Git Mirror Bot <phg42.2a@gmail.com>2017-06-04 17:42:38 +0200
commit32f8047624c2fa49c3031a66edb5a039a813f276 (patch)
treed568ec496e3b4c95adc37ce435b0161a3f40c581 /doc
parent3ab20dbdfa095edd8c6bc00b8e3bdccd78900257 (diff)
downloadcontext-32f8047624c2fa49c3031a66edb5a039a813f276.tar.gz
2017-06-04 17:01:00
Diffstat (limited to 'doc')
-rw-r--r--doc/context/documents/general/manuals/rules-mkiv.pdfbin155730 -> 155746 bytes
-rw-r--r--doc/context/documents/general/qrcs/setup-cs.pdfbin843684 -> 845018 bytes
-rw-r--r--doc/context/documents/general/qrcs/setup-de.pdfbin841934 -> 842943 bytes
-rw-r--r--doc/context/documents/general/qrcs/setup-en.pdfbin846823 -> 847214 bytes
-rw-r--r--doc/context/documents/general/qrcs/setup-fr.pdfbin840815 -> 841488 bytes
-rw-r--r--doc/context/documents/general/qrcs/setup-it.pdfbin842897 -> 843081 bytes
-rw-r--r--doc/context/documents/general/qrcs/setup-nl.pdfbin839028 -> 840035 bytes
-rw-r--r--doc/context/documents/general/qrcs/setup-ro.pdfbin839482 -> 840119 bytes
-rw-r--r--doc/context/presentations/examples/present-weird-001.pdfbin0 -> 334905 bytes
-rw-r--r--doc/context/presentations/examples/present-weird-001.tex113
-rw-r--r--doc/context/sources/general/manuals/luatex/luatex-fonts.tex64
-rw-r--r--doc/context/sources/general/manuals/rules/rules-mkiv.tex2
12 files changed, 166 insertions, 13 deletions
diff --git a/doc/context/documents/general/manuals/rules-mkiv.pdf b/doc/context/documents/general/manuals/rules-mkiv.pdf
index 97ac2fe4d..6e4da3ec8 100644
--- a/doc/context/documents/general/manuals/rules-mkiv.pdf
+++ b/doc/context/documents/general/manuals/rules-mkiv.pdf
Binary files differ
diff --git a/doc/context/documents/general/qrcs/setup-cs.pdf b/doc/context/documents/general/qrcs/setup-cs.pdf
index 3fc137d65..b60b34a12 100644
--- a/doc/context/documents/general/qrcs/setup-cs.pdf
+++ b/doc/context/documents/general/qrcs/setup-cs.pdf
Binary files differ
diff --git a/doc/context/documents/general/qrcs/setup-de.pdf b/doc/context/documents/general/qrcs/setup-de.pdf
index 9c2207d89..8555bebb8 100644
--- a/doc/context/documents/general/qrcs/setup-de.pdf
+++ b/doc/context/documents/general/qrcs/setup-de.pdf
Binary files differ
diff --git a/doc/context/documents/general/qrcs/setup-en.pdf b/doc/context/documents/general/qrcs/setup-en.pdf
index ba034bb5c..068bac6cb 100644
--- a/doc/context/documents/general/qrcs/setup-en.pdf
+++ b/doc/context/documents/general/qrcs/setup-en.pdf
Binary files differ
diff --git a/doc/context/documents/general/qrcs/setup-fr.pdf b/doc/context/documents/general/qrcs/setup-fr.pdf
index 4c1affb39..576e2e9f5 100644
--- a/doc/context/documents/general/qrcs/setup-fr.pdf
+++ b/doc/context/documents/general/qrcs/setup-fr.pdf
Binary files differ
diff --git a/doc/context/documents/general/qrcs/setup-it.pdf b/doc/context/documents/general/qrcs/setup-it.pdf
index 1b39b9ed8..64554d876 100644
--- a/doc/context/documents/general/qrcs/setup-it.pdf
+++ b/doc/context/documents/general/qrcs/setup-it.pdf
Binary files differ
diff --git a/doc/context/documents/general/qrcs/setup-nl.pdf b/doc/context/documents/general/qrcs/setup-nl.pdf
index ccb328a6b..4aa4dc2f6 100644
--- a/doc/context/documents/general/qrcs/setup-nl.pdf
+++ b/doc/context/documents/general/qrcs/setup-nl.pdf
Binary files differ
diff --git a/doc/context/documents/general/qrcs/setup-ro.pdf b/doc/context/documents/general/qrcs/setup-ro.pdf
index d31367ab2..a21665aff 100644
--- a/doc/context/documents/general/qrcs/setup-ro.pdf
+++ b/doc/context/documents/general/qrcs/setup-ro.pdf
Binary files differ
diff --git a/doc/context/presentations/examples/present-weird-001.pdf b/doc/context/presentations/examples/present-weird-001.pdf
new file mode 100644
index 000000000..e3533a31e
--- /dev/null
+++ b/doc/context/presentations/examples/present-weird-001.pdf
Binary files differ
diff --git a/doc/context/presentations/examples/present-weird-001.tex b/doc/context/presentations/examples/present-weird-001.tex
new file mode 100644
index 000000000..7049bac59
--- /dev/null
+++ b/doc/context/presentations/examples/present-weird-001.tex
@@ -0,0 +1,113 @@
+\usemodule[present-weird]
+
+\starttext
+
+\TitlePage{About Text\\Today's Talk\\Hans Hagen}
+
+\StartPage{The First Page}
+
+ \StartTopic{Some Text}
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StartText \input knuth \StopText
+ \StopTopic
+
+ \StartTopic{Another Text}
+ \StartText \input tufte \StopText
+ \StartText \input zapf \StopText
+ \StartText \input knuth \StopText
+ \StopTopic
+
+ \StartTopic{Some More Text}
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StartText \input tufte \StopText
+ \StopTopic
+
+ \StartTopic{Some Text Again}
+ \StartText \input tufte \StopText
+ \StartText \input zapf \StopText
+ \StartText \input knuth \StopText
+ \StartText \input tufte \StopText
+ \StopTopic
+
+\StopPage
+
+\StartPage{The Second Page}
+
+ \StartTopic{Some Text}
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StopTopic
+
+ \StartTopic{Another Text}
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StopTopic
+
+ \StartTopic{Some Nice Text}
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StartText \input tufte \StopText
+ \StartText \input tufte \StopText
+ \StopTopic
+
+ \StartTopic{Some Funny Text}
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StopTopic
+
+ \StartTopic{Quite Some Text}
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StopTopic
+
+ \StartTopic{Even More Text}
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StopTopic
+
+\StopPage
+
+\StartPage{The Third Page}
+
+ \StartTopic{Some Short Text}
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StopTopic
+
+ \StartTopic{Some Minimal Text}
+ \StartText \input tufte \StopText
+ \StartText \input zapf \StopText
+ \StopTopic
+
+ \StartTopic{Some More Text}
+ \StartText \input tufte \StopText
+ \StartText \input knuth \StopText
+ \StartText \input zapf \StopText
+ \StartText \input tufte \StopText
+ \StartText \input tufte \StopText
+ \StopTopic
+
+\StopPage
+
+\stoptext
diff --git a/doc/context/sources/general/manuals/luatex/luatex-fonts.tex b/doc/context/sources/general/manuals/luatex/luatex-fonts.tex
index 221c0ce85..793189d1c 100644
--- a/doc/context/sources/general/manuals/luatex/luatex-fonts.tex
+++ b/doc/context/sources/general/manuals/luatex/luatex-fonts.tex
@@ -460,7 +460,7 @@ parameters to that command. The allowed commands and their arguments are:
and move right by the character's width\NC\NR
\NC node \NC 1 \NC node \NC output this node (list), and move right
by the width of this list\NC\NR
-\NC slot \NC 2 \NC number \NC a shortcut for the combination of a font and char command\NC\NR
+\NC slot \NC 2 \NC 2 numbers \NC a shortcut for the combination of a font and char command\NC\NR
\NC push \NC 0 \NC \NC save current position\NC\NR
\NC nop \NC 0 \NC \NC do nothing \NC\NR
\NC pop \NC 0 \NC \NC pop position \NC\NR
@@ -468,6 +468,8 @@ parameters to that command. The allowed commands and their arguments are:
\NC down \NC 1 \NC number \NC move down on the page\NC\NR
\NC right \NC 1 \NC number \NC move right on the page\NC\NR
\NC special \NC 1 \NC string \NC output a \type {\special} command\NC\NR
+\NC pdf \NC 2 \NC 2 strings \NC output a \PDF\ literal, the first string is one of \type {origin},
+ \type {page}, \type {direct} or \type {raw}\NC\NR
\NC lua \NC 1 \NC string \NC execute a \LUA\ script (at \type {\latelua} time)\NC\NR
\NC image \NC 1 \NC image \NC output an image (the argument can be either an \type
{<image>} variable or an \type {image_spec} table)\NC\NR
@@ -484,15 +486,17 @@ Here is a rather elaborate glyph commands example:
\starttyping
...
commands = {
- { 'push' }, -- remember where we are
- { 'right', 5000 }, -- move right about 0.08pt
- { 'font', 3 }, -- select the fonts[3] entry
- { 'char', 97 }, -- place character 97 (ASCII 'a')
- { 'pop' }, -- go all the way back
- { 'down', -200000 }, -- move upwards by about 3pt
- { 'special', 'pdf: 1 0 0 rg' } -- switch to red color
- { 'rule', 500000, 20000 } -- draw a bar
- { 'special','pdf: 0 g' } -- back to black
+ { "push" }, -- remember where we are
+ { "right", 5000 }, -- move right about 0.08pt
+ { "font", 3 }, -- select the fonts[3] entry
+ { "char", 97 }, -- place character 97 (ASCII 'a')
+ { "pop" }, -- go all the way back
+ { "down", -200000 }, -- move upwards by about 3pt
+ { "special", "pdf: 1 0 0 rg" } -- switch to red color
+ -- { "pdf", "origin", "1 0 0 rg" } -- switch to red color (alternative)
+ { "rule", 500000, 20000 } -- draw a bar
+ { "special", "pdf: 0 g" } -- back to black
+ -- { "pdf", "origin", "0 g" } -- back to black (alternative)
}
...
\stoptyping
@@ -511,6 +515,10 @@ output pointer will always move by exactly the width that was given in the \type
{width} key of the character hash. Any movements that take place inside the \type
{commands} array are ignored on the upper level.
+The special can have a \type {pdf:}, \type {pdf:origin:}, \type {pdf:page:},
+\type {pdf:direct:} or \type {pdf:raw:} prefix. When you have to concatenate
+strings using the \type {pdf} command might be more efficient.
+
\subsection{Artificial fonts}
Even in a \quote {real} font, there can be virtual characters. When \LUATEX\
@@ -662,7 +670,32 @@ You can define your own font into \type {font.fonts} by calling this function:
The return value is the internal id number of the defined font (the index into
\type {font.fonts}). If the font creation fails, an error is raised. The table
-is a font structure, as explained in \in {chapter} [fonts].
+is a font structure, as explained in \in {chapter} [fonts]. An alternative call
+is:
+
+\startfunctioncall
+<number> i =
+ font.define(<number> n, <table> f)
+\stopfunctioncall
+
+Where the first argument is a reserved font id (see below).
+
+\subsection{Extending a font}
+
+Within reasonable bounds you can extend a font after it has been defined. Because
+some properties are best left unchanged this is limited to adding characters.
+
+\startfunctioncall
+font.addcharacters(<number n>, <table> f)
+\stopfunctioncall
+
+The table passed can have the fields \type {characters} which is a (sub)table
+like the one used in define, and for virtual fonts a \type {fonts} table can be
+added. The characters defined in the \type {characters} table are added (when not
+yet present) or replace an existing entry. Keep in mind that replacing can have
+side effects because a character already can have been used. Instead of posing
+restrictions we expect the user to be careful. (The \type {setfont} helper is
+a more drastic replacer.)
\subsection{Projected next font id}
@@ -673,7 +706,14 @@ is a font structure, as explained in \in {chapter} [fonts].
This returns the font id number that would be returned by a \type {font.define}
call if it was executed at this spot in the code flow. This is useful for virtual
-fonts that need to reference themselves.
+fonts that need to reference themselves. If you pass \type {true} as argument,
+the id gets reserved and you can pass to \type {font.define} as first argument.
+This can be handy when you create complex virtual fonts.
+
+\startfunctioncall
+<number> i =
+ font.nextid(true)
+\stopfunctioncall
\subsection{Font id}
diff --git a/doc/context/sources/general/manuals/rules/rules-mkiv.tex b/doc/context/sources/general/manuals/rules/rules-mkiv.tex
index 536a37aea..00ab49c25 100644
--- a/doc/context/sources/general/manuals/rules/rules-mkiv.tex
+++ b/doc/context/sources/general/manuals/rules/rules-mkiv.tex
@@ -627,7 +627,7 @@ primitive here, so we follow the \TEX\ conventions of keywords.
\hskip-100mm
\darkred \frule width 100mm height 10mm depth 8mm radius 2mm line 2pt\relax
\hskip-100mm
- \hbox to 100mm{\white \bold \hfill some handy word with frames\hfill}
+ \hbox to 100mm{\white \bold \hfill some handy word with frames\hfill}%
\egroup
\stopbuffer