diff options
author | Context Git Mirror Bot <phg42.2a@gmail.com> | 2016-01-12 17:15:07 +0100 |
---|---|---|
committer | Context Git Mirror Bot <phg42.2a@gmail.com> | 2016-01-12 17:15:07 +0100 |
commit | 8d8d528d2ad52599f11250cfc567fea4f37f2a8b (patch) | |
tree | 94286bc131ef7d994f9432febaf03fe23d10eef8 /tex/context/base/mtx-context-copy.tex | |
parent | f5aed2e51223c36c84c5f25a6cad238b2af59087 (diff) | |
download | context-8d8d528d2ad52599f11250cfc567fea4f37f2a8b.tar.gz |
2016-01-12 16:26:00
Diffstat (limited to 'tex/context/base/mtx-context-copy.tex')
-rw-r--r-- | tex/context/base/mtx-context-copy.tex | 151 |
1 files changed, 0 insertions, 151 deletions
diff --git a/tex/context/base/mtx-context-copy.tex b/tex/context/base/mtx-context-copy.tex deleted file mode 100644 index b798b3f8d..000000000 --- a/tex/context/base/mtx-context-copy.tex +++ /dev/null @@ -1,151 +0,0 @@ -% engine=luatex - -%D \module -%D [ file=mtx-context-copy, -%D version=2008.11.10, % about that time i started playing with this -%D title=\CONTEXT\ Extra Trickry, -%D subtitle=Copying Files, -%D author=Hans Hagen, -%D date=\currentdate, -%D copyright={PRAGMA ADE \& \CONTEXT\ Development Team}] -%C -%C This module is part of the \CONTEXT\ macro||package and is -%C therefore copyrighted by \PRAGMA. See mreadme.pdf for -%C details. - -%D This is a \TEXEXEC\ features that has been moved to \MKIV. - -% begin help -% -% usage: context --extra=copy [options] list-of-files -% -% --interaction : add hyperlinks -% -% end help - -\input mtx-context-common.tex - -\doif {\getdocumentargument{interaction}} {yes} { - \setupinteraction - [state=start] - \setupexternalfigures - [interaction=yes] -} - -\setupexternalfigures - [directory=] - -\definepapersize - [fit] - [width=\figurewidth, - height=\figureheight] - -\setuplayout - [page] - -% this will be an option to \copypages - -\unexpanded\def\CopyPages[#1]% - {\dorecurse - {\noffigurepages} - {\startTEXpage - \externalfigure[#1][page=\recurselevel]% - \stopTEXpage}} - -\starttext - -\startluacode - - if #document.files == 0 then - context("no files given") - else - for _, filename in ipairs(document.files) do - if not string.find(filename,"^mtx%-context%-") then - logs.report("copy",filename) - context.getfiguredimensions - { filename } - context.setuppapersize - { "fit" } - context.CopyPages - { filename } - end - end - end - -\stopluacode - -\stoptext - - -% def copyoutput -% copyortrim(false,'copy') -% end - -% def trimoutput -% copyortrim(true,'trim') -% end - -% def copyortrim(trim=false,what='unknown') -% if job = TEX.new(logger) then -% prepare(job) -% job.cleanuptemprunfiles -% files = if @commandline.option('sort') then @commandline.arguments.sort else @commandline.arguments end -% if files.length > 0 then -% if f = File.open(job.tempfilename('tex'),'w') then -% scale = @commandline.checkedoption('scale') -% begin -% scale = (scale.to_f * 1000.0).to_i if scale.to_i < 10 -% rescue -% scale = 1000 -% end -% scale = scale.to_i -% paperoffset = @commandline.checkedoption('paperoffset', '0cm') -% f << "\\starttext\n" -% files.each do |filename| -% result = @commandline.checkedoption('result','texexec') -% begin -% if (filename !~ /^texexec/io) && (filename !~ /^#{result}/) then -% report("copying file: #{filename}") -% f << "\\getfiguredimensions\n" -% f << " [#{filename}]\n" -% f << " [scale=#{scale},\n" -% f << " page=1,\n" -% f << " size=trimbox\n" if trim -% f << "]\n" -% f << "\\definepapersize\n" -% f << " [copy]\n" -% f << " [width=\\figurewidth,\n" -% f << " height=\\figureheight]\n" -% f << "\\setuppapersize\n" -% f << " [copy][copy]\n" -% f << "\\setuplayout\n" -% f << " [page]\n" -% f << "\\setupexternalfigures\n" -% f << " [directory=]\n" -% f << "\\copypages\n" -% f << " [#{filename}]\n" -% f << " [scale=#{scale},\n" -% f << " marking=on,\n" if @commandline.option('markings') -% f << " size=trimbox,\n" if trim -% f << " offset=#{paperoffset}]\n" -% end -% rescue -% report("wrong specification") -% end -% end -% f << "\\stoptext\n" -% f.close -% job.setvariable('interface','english') -% job.setvariable('simplerun',true) -% # job.setvariable('nooptionfile',true) -% job.setvariable('files',[job.tempfilename]) -% job.processtex -% else -% report("no files to #{what}") -% end -% else -% report("no files to #{what}") -% end -% job.cleanuptemprunfiles -% end -% end |