| 1 |
README.MarkIV |
| 2 |
============= |
| 3 |
|
| 4 |
Mark IV is the name of the LuaTeX-aware part of ConTeXt; that is, when you |
| 5 |
use ConTeXt over the LuaTeX engine instead of PDFTeX or XeTeX. You run it |
| 6 |
with |
| 7 |
context <filename> |
| 8 |
|
| 9 |
Current tex-common will try to call mtxrun when necessary. Users should |
| 10 |
not have the need to run anything, but a call as user of |
| 11 |
mtxrun --generate |
| 12 |
might help in certain cases. |
| 13 |
|
| 14 |
Now you can try some simple document like (thanks to Arthur Reutenauer) |
| 15 |
\starttext |
| 16 |
|
| 17 |
\ctxlua{a = 1.5 ; b = 1.8 ; c = a*b ; tex.print(c) ;} |
| 18 |
or the equivalent: |
| 19 |
\startlua |
| 20 |
a = 1.5 |
| 21 |
b = 1.8 |
| 22 |
c = a*b |
| 23 |
tex.print(c) |
| 24 |
\stoplua |
| 25 |
|
| 26 |
You can also do more elaborate calculations with the lua math library: |
| 27 |
\ctxlua{tex.print("$\string\\sqrt{2} = " .. math.sqrt(2) .. "$")} |
| 28 |
|
| 29 |
\stoptext |
| 30 |
and run it with |
| 31 |
context filename.tex |
| 32 |
|
| 33 |
More needs to be done, but we are happy to get feedback/ideas/suggestions |
| 34 |
on the integration, please contact |
| 35 |
[email protected] |
| 36 |
|
| 37 |
|
| 38 |
Norbert Preining |
| 39 |
2012-05-24 |
| 40 |
|