[NTG-context] Centering the last line in combination subcaptions
Hello Everyone, I try to fill the entire page with two images with their captions. The final page should be floating, keeping both images together and not containing any other text. I found this solution. It work fine for short captions / wide images. \starttext test \startplacefigure[location=page, number=no, title={}] %\setupcombinations[align={hz, hanging}] %\setuptolerance[strict] {\startcombination[1*2] {\externalfigure[cow]} {\input{ward}} {\externalfigure[cow]} {\input{ward}} \stopcombination} \stopplacefigure \stoptext If captions are long and the image narrow, they are typeset on multiple lines. Default centering produces the ragged column - both not very nice and difficult to read. When the alignment is set to hanging, it looks better except the last line which is not centered. Is there any settings for centering the last line? Can the 'column' width be somehow extended to e.g. 80% of text width? If not via the 'combination', are there any better alternatives for my use case? Any hint is appreciated. Thanks, Jan ___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
[NTG-context] XML and ConTeXt - no XML text showing up in output
I'm following the instructions in http://pragma-ade.com/general/manuals/xml-mkiv.pdf for using XML in ConTeXt. When I run the first example, I get a PDF, but only the hard-coded text string "Contents" is in the PDF; none of the strings from the XML file are in the PDF. Any ideas? - Steve Mac OSX 10.7.5, MacTEX-2013 I've created the following two files: == demo.xml == Some title a paragraph of text another paragraph of text == demo-converter.tex == \startxmlsetups xml:demo:base \xmlsetsetup{demo}{*}{-} \xmlsetsetup{demo}{document|section|p}{xml:demo:*} \stopxmlsetups \xmlregisterdocumentsetup{demo}{xml:demo:base} \startxmlsetups xml:demo:document \title{Contents} \placelist[chapter] \page \xmlflush{#1} \stopxmlsetups \startxmlsetups xml:demo:section \chapter{\xmlfirst{#1}{/title}} \xmlfirst{#1}{/content} \stopxmlsetups \startxmlsetups xml:demo:p \xmlflush{#1}\endgraf \stopxmlsetups \xmlprocessfile{demo}{demo.xml}{} == and the command I'm running is context demo-converter.tex Standard out is: == ConTeXt ver: 2013.04.20 01:15 MKIV current fmt: 2013.12.26 int: english/english system > 'cont-new.mkiv' loaded (/usr/local/texlive/2013/texmf-dist/tex/context/base/cont-new.mkiv) system > files > jobname 'demo-converter', input './demo-converter', result 'demo-converter' fonts > latin modern fonts are not preloaded languages > language 'en' is active (/Users/sanderson/dev/doc/main/feature/texml/content/demo-converter.tex structure > sectioning > title @ level 2 : 0.0 -> Contents fonts > beware: no fonts are loaded yet, using 'lm mono' in box backend > xmp > using file '/usr/local/texlive/2013/texmf-dist/tex/context/base/lpdf-pdx.xml' pages > flushing realpage 1, userpage 1 structure > sectioning > chapter @ level 2 : 0.1 -> \xmlfirst {demo::5}{/title} ) system > invalid \starttext ... \stoptext structure pages > flushing realpage 2, userpage 2 ) mkiv lua stats > used config file: selfautoparent:/texmfcnf.lua;selfautoparent:/texmf-dist/web2c/texmfcnf.lua mkiv lua stats > used cache path: readable: '/usr/local/texlive/2013/texmf-var/luatex-cache/context/a86c089b384a3076dc514ba966a1fac9' | readable+writable: '/Users/sanderson/Library/texlive/2013/texmf-var/luatex-cache/context/a86c089b384a3076dc514ba966a1fac9' mkiv lua stats > resource resolver: loadtime 0.415 seconds, 0 scans with scantime 0.000 seconds, 0 shared scans, 7 found files, scanned paths: mkiv lua stats > stored bytecode data: 326 modules (0.207 sec), 69 tables (0.003 sec), 395 chunks (0.210 sec) mkiv lua stats > cleaned up reserved nodes: 41 nodes, 9 lists of 441 mkiv lua stats > node memory usage: 2 glue, 3 penalty, 12 attribute, 36 glue_spec, 3 attribute_list mkiv lua stats > node list callback tasks: 6 unique task lists, 5 instances (re)created, 103 calls mkiv lua stats > used backend: pdf (backend for directly generating pdf output) mkiv lua stats > loaded patterns: en::2 mkiv lua stats > jobdata time: 0.005 seconds saving, 0.001 seconds loading mkiv lua stats > callbacks: 290 direct, 197 indirect, 487 total mkiv lua stats > randomizer: resumed with value 0.88342237327407 mkiv lua stats > xml load time: 0.002 seconds, 1 files, 1 converted mkiv lua stats > lxml preparation time: 0.000 seconds, 9 nodes, 20 lpath calls, 1 cached calls mkiv lua stats > result saved in file: demo-converter.pdf, compresslevel 3, objectcompreslevel 3 mkiv lua stats > loaded fonts: 1 files: lmmono10-regular.otf mkiv lua stats > fonts load time: 0.042 seconds mkiv lua stats > luatex banner: this is luatex, version beta-0.76.0-2013052718 (tex live 2013) (rev 4627) mkiv lua stats > control sequences: 35558 of 65536 + 10 mkiv lua stats > current memory usage: 47 MB (ctx: 47 MB) mkiv lua stats > runtime: 0.676 seconds, 2 processed pages, 2 shipped pages, 2.959 pages/second system | total runtime: 1.382 == and here's the log file == (/usr/local/texlive/2013/texmf-dist/tex/context/base/cont-yes.mkiv ConTeXt ver: 2013.04.20 01:15 MKIV current fmt: 2013.12.26 int: english/english system > 'cont-new.mkiv' loaded (/usr/local/texlive/2013/texmf-dist/tex/context/base/cont-new.mkiv) system > files > jobname 'demo-converter', input './demo-converter', result 'demo-converter' fonts > latin modern fonts are not preloaded languages > language 'en' is active (/Users/sanderson/dev/doc/main/feature/texml/content/demo-converter.tex structure > sectioning > title @ level 2 : 0.0 -> Contents fonts > beware: no fonts are loaded yet, using 'lm mono' in box backend > xmp > using file '/usr/local/texlive/2013/texmf-dist/tex/context/base/lpdf-pdx.xml' pages > flushing realpage 1, userpage 1 structure > sectioning > chapter
[NTG-context] missing underbrace using palatino with latest beta (2013.12.26)
A minimal example: --- cut --- \setupbodyfont[palatino,12pt] \starttext \startformula \underbrace{x}_{1} \stopformula \stoptext --- cut --- It works fine with 2013.05.28 00:36 MKIV current. With 2013.12.26 12:50 MKIV beta, the underbrace disappears. With a bigger target (e.g. "xyz" instead of "x") or with the default font, the underbrace returns. -- -Sanjoy ___ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___
[NTG-context] underbrace under stacked math error with latest beta (2013.12.26)
A minimal example: --- cut \def\2#1#2{\vcenter{\halign{\hfil ##\hfil\cr #1\cr#2\cr}}} \def\ptwo#1#2{\left(\2{#1}{#2}\right)} \starttext \startformula \underbrace{\ptwo{specific}{heat}}_{1} \stopformula \stoptext --- cut It works with 2013.05.28 00:36 MKIV current, correctly producing ( specific ) heat (with bigger parens) with an underbrace and a 1 underneath the brace. With 2013.12.26 12:50 MKIV beta, I get this error: ! Illegal parameter number in definition of \m_math_stackers_text_middle. system > tex > error on line 7 in file /home/sanjoy/sfse/test3.tex: Illegal parameter number in definition of ... 1 \def\2#1#2{\vcenter{\halign{\hfil ##\hfil\cr #1\cr#2\cr}}} 2 \def\ptwo#1#2{\left(\2{#1}{#2}\right)} 3 4 \starttext 5 6 \startformula 7 >> \underbrace{\ptwo{specific}{heat}}_{1} 8 \stopformula 9 10 \stoptext 11 \hfil \2#1#2l-\vcenter {\halign {\hfil ##\hfil \cr #1\cr #2\cr }} \ptwo #1#2l-\left (\2{#1}{#2} \right ) \math_stackers_make_double ...kers_text_middle {#6 }\edef \p_offset {\mathsta... l.7 \underbrace{\ptwo{specific}{heat}} _{1} I've attached the log file. The "\ptwo{specific}{heat}" by itself is fine. Only when it is wrapped in the \underbrace does the problem occur. -Sanjoy (/home/sanjoy/context/tex/texmf-context/tex/context/base/cont-yes.mkiv ConTeXt ver: 2013.12.26 12:50 MKIV beta fmt: 2013.12.26 int: english/english system > 'cont-new.mkiv' loaded (/home/sanjoy/context/tex/texmf-context/tex/context/base/cont-new.mkiv) system > files > jobname 'test3', input './test3', result 'test3' fonts > latin modern fonts are not preloaded languages > language 'en' is active (/home/sanjoy/sfse/test3.tex{/home/sanjoy/context/tex/texmf-context/fonts/map/pdftex/context/mkiv-base.map} fonts > preloading latin modern fonts (second stage) fonts > typescripts > unknown library 'loc' {/home/sanjoy/context/tex/texmf/fonts/map/dvips/lm/lm-math.map}{/home/sanjoy/context/tex/texmf/fonts/map/dvips/lm/lm-rm.map} fonts > 'fallback modern rm 12pt' is loaded backend > xmp > using file '/home/sanjoy/context/tex/texmf-context/tex/context/base/lpdf-pdx.xml' pages > flushing realpage 1, userpage 1 ) ) system > structure > start used structure used structure > text: test3 system > structure > stop used structure system > files > start used files used file >1: filename=cont-yes.mkiv filetype=tex foundname=/home/sanjoy/context/tex/texmf-context/tex/context/base/cont-yes.mkiv usedmethod=otherwise used file >2: filename=cont-new.mkiv filetype=tex foundname=/home/sanjoy/context/tex/texmf-context/tex/context/base/cont-new.mkiv usedmethod=otherwise used file >3: filename=lang-us.lua filetype=scripts foundname=/home/sanjoy/context/tex/texmf-context/tex/context/patterns/lang-us.lua usedmethod=otherwise used file >4: filename=/home/sanjoy/sfse/test3.tex foundname=/home/sanjoy/sfse/test3.tex usedmethod=direct used file >5: filename=mkiv-base.map filetype=map format=map foundname=/home/sanjoy/context/tex/texmf-context/fonts/map/pdftex/context/mkiv-base.map usedmethod=database used file >6: filename=lm.lfg filetype=tex foundname=/home/sanjoy/context/tex/texmf-context/tex/context/fonts/lm.lfg usedmethod=otherwise used file >7: filename=lm-math.lfg filetype=tex foundname=/home/sanjoy/context/tex/texmf-context/tex/context/fonts/lm-math.lfg usedmethod=otherwise used file >8: filename=lm-math.map filetype=map format=map foundname=/home/sanjoy/context/tex/texmf/fonts/map/dvips/lm/lm-math.map usedmethod=database used file >9: filename=lm-rm.map filetype=map format=map foundname=/home/sanjoy/context/tex/texmf/fonts/map/dvips/lm/lm-rm.map usedmethod=database used file > 10: filename=lmroman12-regular filetype=otf format=otf foundname=/home/sanjoy/context/tex/texmf/fonts/opentype/public/lm/lmroman12-regular.otf usedmethod=database used file > 11: filename=latinmodern-math.otf filetype=opentypefonts foundname=/home/sanjoy/context/tex/texmf/fonts/opentype/public/lm-math/latinmodern-math.otf usedmethod=database used file > 12: filename=latinmodern-math.otf filetype=otf format=otf foundname=/home/sanjoy/context/tex/texmf/fonts/opentype/public/lm-math/latinmodern-math.otf usedmethod=database used file > 13: filename=lpdf-pdx.xml filetype=tex foundname=/home/sanjoy/context/tex/texmf-context/tex/context/base/lpdf-pdx.xml usedmethod=otherwise system > files > stop used files system > options > start commandline options