summaryrefslogtreecommitdiff
path: root/tex
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2012-08-09 17:17:00 +0200
committerHans Hagen <pragma@wxs.nl>2012-08-09 17:17:00 +0200
commit440d4771bbcefc36fbff83487e8aa1076e3b82af (patch)
tree17b2d057f9205013f079dd59a60594db5e699d9f /tex
parent994ef322c591f7cae9b672844e96482723b89b4b (diff)
downloadcontext-440d4771bbcefc36fbff83487e8aa1076e3b82af.tar.gz
beta 2012.08.09 17:17
Diffstat (limited to 'tex')
-rw-r--r--tex/context/base/cont-new.mkii2
-rw-r--r--tex/context/base/cont-new.mkiv2
-rw-r--r--tex/context/base/context-version.pdfbin4084 -> 4083 bytes
-rw-r--r--tex/context/base/context-version.pngbin106531 -> 106124 bytes
-rw-r--r--tex/context/base/context.mkii2
-rw-r--r--tex/context/base/context.mkiv2
-rw-r--r--tex/context/base/file-job.lua64
-rw-r--r--tex/context/base/font-otn.lua6
-rw-r--r--tex/context/base/font-sty.mkvi2
-rw-r--r--tex/context/base/font-tra.mkiv12
-rw-r--r--tex/context/base/node-tra.lua2
-rw-r--r--tex/context/base/s-fnt-20.mkiv10
-rw-r--r--tex/context/base/status-files.pdfbin24431 -> 24459 bytes
-rw-r--r--tex/context/base/status-lua.pdfbin190363 -> 190370 bytes
-rw-r--r--tex/context/base/strc-flt.mkvi7
-rw-r--r--tex/context/base/strc-not.lua4
-rw-r--r--tex/context/base/strc-not.mkvi4
-rw-r--r--tex/context/base/typo-dir.lua2
-rw-r--r--tex/generic/context/luatex/luatex-fonts-merged.lua8
19 files changed, 75 insertions, 54 deletions
diff --git a/tex/context/base/cont-new.mkii b/tex/context/base/cont-new.mkii
index 408d2e3d7..2219a1944 100644
--- a/tex/context/base/cont-new.mkii
+++ b/tex/context/base/cont-new.mkii
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2012.08.08 23:45}
+\newcontextversion{2012.08.09 17:17}
%D This file is loaded at runtime, thereby providing an
%D excellent place for hacks, patches, extensions and new
diff --git a/tex/context/base/cont-new.mkiv b/tex/context/base/cont-new.mkiv
index 04638a53a..1b23be6db 100644
--- a/tex/context/base/cont-new.mkiv
+++ b/tex/context/base/cont-new.mkiv
@@ -11,7 +11,7 @@
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
-\newcontextversion{2012.08.08 23:45}
+\newcontextversion{2012.08.09 17:17}
%D This file is loaded at runtime, thereby providing an
%D excellent place for hacks, patches, extensions and new
diff --git a/tex/context/base/context-version.pdf b/tex/context/base/context-version.pdf
index a1e6cab61..4ed7baa36 100644
--- a/tex/context/base/context-version.pdf
+++ b/tex/context/base/context-version.pdf
Binary files differ
diff --git a/tex/context/base/context-version.png b/tex/context/base/context-version.png
index ab6e4b526..33390a965 100644
--- a/tex/context/base/context-version.png
+++ b/tex/context/base/context-version.png
Binary files differ
diff --git a/tex/context/base/context.mkii b/tex/context/base/context.mkii
index 0bd111eb3..5b9915753 100644
--- a/tex/context/base/context.mkii
+++ b/tex/context/base/context.mkii
@@ -20,7 +20,7 @@
%D your styles an modules.
\edef\contextformat {\jobname}
-\edef\contextversion{2012.08.08 23:45}
+\edef\contextversion{2012.08.09 17:17}
%D For those who want to use this:
diff --git a/tex/context/base/context.mkiv b/tex/context/base/context.mkiv
index 8fb3c8570..0061b73f0 100644
--- a/tex/context/base/context.mkiv
+++ b/tex/context/base/context.mkiv
@@ -25,7 +25,7 @@
%D up and the dependencies are more consistent.
\edef\contextformat {\jobname}
-\edef\contextversion{2012.08.08 23:45}
+\edef\contextversion{2012.08.09 17:17}
%D For those who want to use this:
diff --git a/tex/context/base/file-job.lua b/tex/context/base/file-job.lua
index 41f2a012c..168300767 100644
--- a/tex/context/base/file-job.lua
+++ b/tex/context/base/file-job.lua
@@ -444,48 +444,52 @@ job.register('job.structure.collected',root,initialize)
-- component: small unit, either or not components itself
-- product : combination of components
+local context_processfilemany = context.processfilemany
+local context_processfileonce = context.processfileonce
+local context_processfilenone = context.processfilenone
+
local processors = utilities.storage.allocate {
-- [v_outer] = {
- -- [v_text] = { "many", context.processfilemany },
- -- [v_project] = { "once", context.processfileonce },
- -- [v_environment] = { "once", context.processfileonce },
- -- [v_product] = { "many", context.processfileonce },
- -- [v_component] = { "many", context.processfilemany },
+ -- [v_text] = { "many", context_processfilemany },
+ -- [v_project] = { "once", context_processfileonce },
+ -- [v_environment] = { "once", context_processfileonce },
+ -- [v_product] = { "once", context_processfileonce },
+ -- [v_component] = { "many", context_processfilemany },
-- },
[v_text] = {
- [v_text] = { "many", context.processfilemany },
- [v_project] = { "none", context.processfileonce },
- [v_environment] = { "once", context.processfileonce },
- [v_product] = { "none", context.processfileonce },
- [v_component] = { "many", context.processfilemany },
+ [v_text] = { "many", context_processfilemany },
+ [v_project] = { "once", context_processfileonce }, -- dubious
+ [v_environment] = { "once", context_processfileonce },
+ [v_product] = { "many", context_processfilemany }, -- dubious
+ [v_component] = { "many", context_processfilemany },
},
[v_project] = {
- [v_text] = { "many", context.processfilemany },
- [v_project] = { "none", context.processfilenone },
- [v_environment] = { "once", context.processfileonce },
- [v_product] = { "once", context.processfilenone },
- [v_component] = { "none", context.processfilenone },
+ [v_text] = { "many", context_processfilemany },
+ [v_project] = { "none", context_processfilenone },
+ [v_environment] = { "once", context_processfileonce },
+ [v_product] = { "none", context_processfilenone },
+ [v_component] = { "none", context_processfilenone },
},
[v_environment] = {
- [v_text] = { "many", context.processfilemany },
- [v_project] = { "none", context.processfilenone },
- [v_environment] = { "once", context.processfileonce },
- [v_product] = { "none", context.processfilenone },
- [v_component] = { "none", context.processfilenone },
+ [v_text] = { "many", context_processfilemany },
+ [v_project] = { "none", context_processfilenone },
+ [v_environment] = { "once", context_processfileonce },
+ [v_product] = { "none", context_processfilenone },
+ [v_component] = { "none", context_processfilenone },
},
[v_product] = {
- [v_text] = { "many", context.processfilemany },
- [v_project] = { "once", context.processfileonce },
- [v_environment] = { "once", context.processfileonce },
- [v_product] = { "none", context.processfilemany },
- [v_component] = { "many", context.processfilemany },
+ [v_text] = { "many", context_processfilemany },
+ [v_project] = { "once", context_processfileonce },
+ [v_environment] = { "once", context_processfileonce },
+ [v_product] = { "many", context_processfilemany },
+ [v_component] = { "many", context_processfilemany },
},
[v_component] = {
- [v_text] = { "many", context.processfilemany },
- [v_project] = { "once", context.processfileonce },
- [v_environment] = { "once", context.processfileonce },
- [v_product] = { "none", context.processfilenone },
- [v_component] = { "many", context.processfilemany },
+ [v_text] = { "many", context_processfilemany },
+ [v_project] = { "once", context_processfileonce },
+ [v_environment] = { "once", context_processfileonce },
+ [v_product] = { "none", context_processfilenone },
+ [v_component] = { "many", context_processfilemany },
}
}
diff --git a/tex/context/base/font-otn.lua b/tex/context/base/font-otn.lua
index d97ef7363..9e233a7a7 100644
--- a/tex/context/base/font-otn.lua
+++ b/tex/context/base/font-otn.lua
@@ -488,12 +488,12 @@ function handlers.gsub_alternate(start,kind,lookupname,alternative,sequence)
local choice = get_alternative_glyph(start,alternative,value)
if choice then
if trace_alternatives then
- logprocess("%s: replacing %s by alternative %s (%s)",pref(kind,lookupname),gref(char),gref(choice),choice)
+ logprocess("%s: replacing %s by alternative %s (%s)",pref(kind,lookupname),gref(start.char),gref(choice),choice)
end
start.char = choice
else
if trace_alternatives then
- logwarning("%s: no variant %s for %s",pref(kind,lookupname),tostring(value),gref(char))
+ logwarning("%s: no variant %s for %s",pref(kind,lookupname),tostring(value),gref(start.char))
end
end
return start, true
@@ -2030,6 +2030,8 @@ end
-- start = start.next
-- end
+-- there will be a new direction parser (pre-parsed etc)
+
local function featuresprocessor(head,font,attr)
local lookuphash = lookuphashes[font] -- we can also check sequences here
diff --git a/tex/context/base/font-sty.mkvi b/tex/context/base/font-sty.mkvi
index d704aae8a..732d2b027 100644
--- a/tex/context/base/font-sty.mkvi
+++ b/tex/context/base/font-sty.mkvi
@@ -277,7 +277,7 @@
{\groupedcommand{\font_styles_use_defined{#name}}{}} % or {\font_styles_apply_grouped{#name}}
\setvalue{\??styleargument3}#specification%
- {\doifassignmentelse{#specification}\font_styles_assignment\font_styles_checked{#specification}}
+ {\doifassignmentelse{#specification}\font_styles_assignment\font_styles_direct{#specification}}
\def\font_styles_assignment#specification{\groupedcommand{\font_styles_use_generic{#specification}}{}}
\def\font_styles_direct #specification{\groupedcommand{\definedfont[#specification]}{}}
diff --git a/tex/context/base/font-tra.mkiv b/tex/context/base/font-tra.mkiv
index d0a562fbd..abe034d8a 100644
--- a/tex/context/base/font-tra.mkiv
+++ b/tex/context/base/font-tra.mkiv
@@ -186,6 +186,16 @@
\newbox\otfcompositionbox
+% this should go in spac-ali:
+
+\installcorenamespace{otfcompositiondir}
+
+\letvalue{\??otfcompositiondir -1}\righttoleft
+\letvalue{\??otfcompositiondir r2l}\righttoleft
+\letvalue{\??otfcompositiondir l2r}\lefttoright
+\letvalue{\??otfcompositiondir +1}\lefttoright
+\letvalue{\??otfcompositiondir 1}\lefttoright
+
\unexpanded\def\showotfcomposition#1#2#3% {font*features at size}, rl=-1, text
{\begingroup
\veryraggedright
@@ -193,7 +203,7 @@
\forgeteverypar
\setupcolors[\c!state=\v!start]% can be option
\startotfsample
- \global\setbox\otfcompositionbox\hbox{\definedfont[#1]\ifnum#2<0 \textdir TRT\else\ifnum#2>0 \textdir TLT\fi\fi\relax#3}%
+ \global\setbox\otfcompositionbox\hbox{\definedfont[#1]\relax\getvalue{\??otfcompositiondir#2}\relax#3}%
\stopotfsample
\endgroup}
diff --git a/tex/context/base/node-tra.lua b/tex/context/base/node-tra.lua
index 64b8e84fb..34d51529c 100644
--- a/tex/context/base/node-tra.lua
+++ b/tex/context/base/node-tra.lua
@@ -219,7 +219,7 @@ function step_tracers.nofsteps()
return context(#collection)
end
-function step_tracers.glyphs(n,i)
+function step_tracers.glyphs(n,i) -- no need for hpack
local c = collection[i]
if c then
tex.box[n] = hpack_node_list(copy_node_list(c))
diff --git a/tex/context/base/s-fnt-20.mkiv b/tex/context/base/s-fnt-20.mkiv
index a78f62555..54ed419c0 100644
--- a/tex/context/base/s-fnt-20.mkiv
+++ b/tex/context/base/s-fnt-20.mkiv
@@ -85,10 +85,10 @@
rlig=yes,liga=yes,dlig=yes,
mark=yes,mkmk=yes,kern=yes,curs=yes]
-\setvalue{otftracker-direction-arabtype}{-1}
-\setvalue{otftracker-direction-husayni}{-1}
-\setvalue{otftracker-direction-simplenaskhi}{-1}
-\setvalue{otftracker-direction-default}{0}
+\setvalue{otftracker-direction-arabtype}{r2l}
+\setvalue{otftracker-direction-husayni}{r2l}
+\setvalue{otftracker-direction-simplenaskhi}{r2l}
+\setvalue{otftracker-direction-default}{}
\setvariables
[otftracker]
@@ -129,7 +129,7 @@
\chapter{\getvariable{otftracker}{title}}
\doifsomething {\getvariable{otftracker}{figure}} {
\startlinecorrection
- \externalfigure[\getvariable{otftracker}{figure}]
+ \externalfigure[\getvariable{otftracker}{figure}][maxwidth=\hsize,frame=on]
\stoplinecorrection
}
\showotfcomposition
diff --git a/tex/context/base/status-files.pdf b/tex/context/base/status-files.pdf
index 00bbd4ee1..ecc283532 100644
--- a/tex/context/base/status-files.pdf
+++ b/tex/context/base/status-files.pdf
Binary files differ
diff --git a/tex/context/base/status-lua.pdf b/tex/context/base/status-lua.pdf
index 2d0693a79..129ade8a0 100644
--- a/tex/context/base/status-lua.pdf
+++ b/tex/context/base/status-lua.pdf
Binary files differ
diff --git a/tex/context/base/strc-flt.mkvi b/tex/context/base/strc-flt.mkvi
index 524cf0f11..e1e6e75a1 100644
--- a/tex/context/base/strc-flt.mkvi
+++ b/tex/context/base/strc-flt.mkvi
@@ -448,6 +448,7 @@
\ifx\currentfloat\empty
\let\currentfloat\v!figure % a bit of a hack
\fi
+ \let\m_strc_floats_saved_userdata\empty
\let\currentfloatcaption\currentfloat}
\def\strc_floats_reset_variables
@@ -493,6 +494,8 @@
\installsetuponlycommandhandler \??floatuserdata {floatuserdata}
+\let\m_strc_floats_saved_userdata\empty % todo: reset this in non start|stop cases
+
\unexpanded\def\strc_floats_start_place#tag%
{\flushnotes
\page_otr_command_flush_side_floats % here !
@@ -504,7 +507,7 @@
{\strc_floats_reset_variables
\edef\savedfloatlocation{\floatcaptionparameter\c!location}%
\setupcurrentfloatcaption[\c!location=,\c!reference=,\c!title=,\c!marking=,\c!list=,\c!bookmark=,#settings]%
- \def\savedfloatuserdata{#2}%
+ \def\m_strc_floats_saved_userdata{#2}%
\edef\floatlocation{\floatcaptionparameter\c!location}%
\setupcurrentfloatcaption[\c!location=\savedfloatlocation]%
\ifx\floatlocation\empty
@@ -770,7 +773,7 @@
\newconditional\usesamefloatnumber
\def\strc_floats_place_packaged_boxes
- {\expandafter\strc_floats_place_packaged_boxes_indeed\expandafter{\savedfloatuserdata}}
+ {\expandafter\strc_floats_place_packaged_boxes_indeed\expandafter{\m_strc_floats_saved_userdata}}
\def\strc_floats_place_packaged_boxes_indeed#userdata%
{\bgroup
diff --git a/tex/context/base/strc-not.lua b/tex/context/base/strc-not.lua
index df63650e3..a9f806721 100644
--- a/tex/context/base/strc-not.lua
+++ b/tex/context/base/strc-not.lua
@@ -179,8 +179,8 @@ function notes.restore(tag,forcedstate)
end
end
-commands.savenote = notes.save
-commands.restore = notes.restore
+commands.savenote = notes.save
+commands.restorenote = notes.restore
local function hascontent(tag)
local ok = notestates[tag]
diff --git a/tex/context/base/strc-not.mkvi b/tex/context/base/strc-not.mkvi
index f6be1ffb4..6daf4e9ad 100644
--- a/tex/context/base/strc-not.mkvi
+++ b/tex/context/base/strc-not.mkvi
@@ -1406,7 +1406,7 @@
\unexpanded\def\startlocalnotes
{\dosingleempty\strc_notes_local_start}
-\def\strc_notes_local_start[#1]%
+\def\strc_notes_local_start[#1]% grouping ? (we used to have a second argument ... settings)
{\def\localnoteslist{#1}%
\settrue\inlocalnotes
\processcommacommand[\localnoteslist]\strc_notes_local_start_step}
@@ -1443,7 +1443,7 @@
\edef\currentnote{#2}% is already set?
\the\everyplacelocalnotes
% beware, we cannot trust setting \currentnote here
- \setupcurrentnote[\c!width=\v!fit,\c!height=\v!fit,\c!strut=\v!no,\c!offset=\v!overlay,#1]% we only need a selective one
+ \setupcurrentnote[#1]% later we set height etc for framed
\strc_notes_place_local_alternative
\strc_notes_set_properties % restore globals (if needed)
\endgroup
diff --git a/tex/context/base/typo-dir.lua b/tex/context/base/typo-dir.lua
index 620862e85..27d4e939a 100644
--- a/tex/context/base/typo-dir.lua
+++ b/tex/context/base/typo-dir.lua
@@ -276,7 +276,7 @@ function directions.process(namespace,attribute,start) -- todo: make faster
end
end
elseif d == "l" or d == "en" then -- european number
- if autodir <= 0 then
+ if autodir <= 0 then -- could be option
force_auto_left_before()
end
elseif d == "r" or d == "al" then -- arabic number
diff --git a/tex/generic/context/luatex/luatex-fonts-merged.lua b/tex/generic/context/luatex/luatex-fonts-merged.lua
index 48800990d..0ca0f4732 100644
--- a/tex/generic/context/luatex/luatex-fonts-merged.lua
+++ b/tex/generic/context/luatex/luatex-fonts-merged.lua
@@ -1,6 +1,6 @@
-- merged file : luatex-fonts-merged.lua
-- parent file : luatex-fonts.lua
--- merge date : 08/08/12 23:45:30
+-- merge date : 08/09/12 17:17:04
do -- begin closure to overcome local limits and interference
@@ -9154,12 +9154,12 @@ function handlers.gsub_alternate(start,kind,lookupname,alternative,sequence)
local choice = get_alternative_glyph(start,alternative,value)
if choice then
if trace_alternatives then
- logprocess("%s: replacing %s by alternative %s (%s)",pref(kind,lookupname),gref(char),gref(choice),choice)
+ logprocess("%s: replacing %s by alternative %s (%s)",pref(kind,lookupname),gref(start.char),gref(choice),choice)
end
start.char = choice
else
if trace_alternatives then
- logwarning("%s: no variant %s for %s",pref(kind,lookupname),tostring(value),gref(char))
+ logwarning("%s: no variant %s for %s",pref(kind,lookupname),tostring(value),gref(start.char))
end
end
return start, true
@@ -10696,6 +10696,8 @@ end
-- start = start.next
-- end
+-- there will be a new direction parser (pre-parsed etc)
+
local function featuresprocessor(head,font,attr)
local lookuphash = lookuphashes[font] -- we can also check sequences here