diff options
author | Hans Hagen <pragma@wxs.nl> | 2017-02-17 10:31:56 +0100 |
---|---|---|
committer | Context Git Mirror Bot <phg42.2a@gmail.com> | 2017-02-17 10:31:56 +0100 |
commit | b14f992ef5f4e868c9959b174278c86516d60dbc (patch) | |
tree | 28587bb46c025ea7b0d27ba93f09c93dcf53c73a /tex/context/base/mkiv/typo-fln.lua | |
parent | 95a1799032dc61dbca4a11e495be34b4397c8fec (diff) | |
download | context-b14f992ef5f4e868c9959b174278c86516d60dbc.tar.gz |
2017-02-17 10:23:00
Diffstat (limited to 'tex/context/base/mkiv/typo-fln.lua')
-rw-r--r-- | tex/context/base/mkiv/typo-fln.lua | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/tex/context/base/mkiv/typo-fln.lua b/tex/context/base/mkiv/typo-fln.lua index fcd9b2c1f..cef77cea1 100644 --- a/tex/context/base/mkiv/typo-fln.lua +++ b/tex/context/base/mkiv/typo-fln.lua @@ -21,7 +21,10 @@ typesetters.firstlines = typesetters.firstlines or { } local firstlines = typesetters.firstlines local nodes = nodes + local tasks = nodes.tasks +local enableaction = tasks.enableaction +local disableaction = tasks.disableaction local context = context local implement = interfaces.implement @@ -45,6 +48,7 @@ local getbox = nuts.getbox local getdisc = nuts.getdisc local setdisc = nuts.setdisc local setlink = nuts.setlink +local setfont = nuts.setfont local nodecodes = nodes.nodecodes local glyph_code = nodecodes.glyph @@ -87,7 +91,7 @@ local settings = nil function firstlines.set(specification) settings = specification or { } - tasks.enableaction("processors","typesetters.firstlines.handler") + enableaction("processors","typesetters.firstlines.handler") if trace_firstlines then report_firstlines("enabling firstlines") end @@ -131,7 +135,7 @@ actions[v_line] = function(head,setting) if dynamic > 0 then setattr(g,0,dynamic) end - setfield(g,"font",font) + setfont(g,font) end end @@ -207,7 +211,7 @@ actions[v_line] = function(head,setting) if dynamic > 0 then setattr(start,0,dynamic) end - setfield(start,"font",font) + setfont(start,font) if ca and ca > 0 then setattr(start,a_colormodel,ma == 0 and 1 or ma) setattr(start,a_color,ca) @@ -311,7 +315,7 @@ actions[v_word] = function(head,setting) if dynamic > 0 then setattr(start,0,dynamic) end - setfield(start,"font",font) + setfont(start,font) elseif id == disc_code then -- continue elseif id == kern_code then -- todo: fontkern @@ -345,7 +349,7 @@ function firstlines.handler(head) end if attr then -- here as we can process nested boxes first so we need to keep state - tasks.disableaction("processors","typesetters.firstlines.handler") + disableaction("processors","typesetters.firstlines.handler") -- texsetattribute(attribute,unsetvalue) local alternative = settings.alternative or v_default local action = actions[alternative] or actions[v_default] |