From 956b25a304207d06fe012f8c8efcb13cc66e3eec Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Sun, 1 Aug 2021 03:00:39 +0000 Subject: CTAN sync 202108010300 --- FILES.byname | 668 +++---- FILES.byname.gz | Bin 2329489 -> 2329777 bytes FILES.last07days | 694 ++++--- info/install-latex-guide-zh-cn/appendix/mirror.tex | 4 +- .../appendix/updateinfo.tex | 11 +- info/install-latex-guide-zh-cn/chapter/macos.tex | 2 +- info/install-latex-guide-zh-cn/chapter/ubuntu.tex | 12 +- info/install-latex-guide-zh-cn/chapter/windows.tex | 4 + info/install-latex-guide-zh-cn/chapter/wsl.tex | 2 +- .../install-latex-guide-zh-cn.pdf | Bin 742445 -> 744469 bytes .../exam-randomizechoices-doc.pdf | Bin 204825 -> 217081 bytes .../exam-randomizechoices-doc.tex | 288 ++- .../exam-randomizechoices.pdf | Bin 62606 -> 88494 bytes .../exam-randomizechoices.sty | 127 +- .../exam-randomizechoices.tex | 613 +++++- macros/latex/contrib/hvlogos/Changes | 2 + macros/latex/contrib/hvlogos/README | 9 + macros/latex/contrib/hvlogos/doc/hvlogos-doc.pdf | Bin 0 -> 76164 bytes macros/latex/contrib/hvlogos/doc/hvlogos-doc.tex | 133 ++ macros/latex/contrib/hvlogos/latex/hvlogos.sty | 200 ++ macros/latex/contrib/macrolist/README.md | 2 +- macros/latex/contrib/macrolist/macrolist.dtx | 37 +- macros/latex/contrib/macrolist/macrolist.pdf | Bin 193608 -> 194057 bytes .../contrib/pdfmanagement-testphase/CHANGELOG.md | 17 + .../contrib/pdfmanagement-testphase/README.md | 2 +- .../contrib/pdfmanagement-testphase/color-ltx.sty | 2 +- .../pdfmanagement-testphase/hyperref-generic.dtx | 139 +- .../pdfmanagement-testphase/hyperref-generic.pdf | Bin 949513 -> 948089 bytes .../hyperxmp-patches-tmp-ltx.sty | 2 +- .../l3backend-testphase.dtx | 116 +- .../l3backend-testphase.pdf | Bin 594809 -> 591169 bytes .../contrib/pdfmanagement-testphase/l3pdfannot.dtx | 4 +- .../contrib/pdfmanagement-testphase/l3pdfannot.pdf | Bin 577451 -> 577331 bytes .../contrib/pdfmanagement-testphase/l3pdfdict.dtx | 4 +- .../contrib/pdfmanagement-testphase/l3pdfdict.pdf | Bin 527225 -> 527111 bytes .../pdfmanagement-testphase/l3pdffield-action.dtx | 2 +- .../pdfmanagement-testphase/l3pdffield-action.pdf | Bin 548003 -> 547881 bytes .../l3pdffield-checkbox.dtx | 2 +- .../l3pdffield-checkbox.pdf | Bin 531031 -> 530911 bytes .../pdfmanagement-testphase/l3pdffield-choice.dtx | 2 +- .../pdfmanagement-testphase/l3pdffield-choice.pdf | Bin 534245 -> 534125 bytes .../l3pdffield-pushbutton.dtx | 2 +- .../l3pdffield-pushbutton.pdf | Bin 526426 -> 526311 bytes .../l3pdffield-radiobutton.dtx | 2 +- .../l3pdffield-radiobutton.pdf | Bin 576432 -> 576314 bytes .../l3pdffield-textfield.dtx | 2 +- .../l3pdffield-textfield.pdf | Bin 505665 -> 505534 bytes .../contrib/pdfmanagement-testphase/l3pdffield.dtx | 4 +- .../contrib/pdfmanagement-testphase/l3pdffield.pdf | Bin 739384 -> 739256 bytes .../contrib/pdfmanagement-testphase/l3pdffile.dtx | 4 +- .../contrib/pdfmanagement-testphase/l3pdffile.pdf | Bin 553454 -> 553330 bytes .../pdfmanagement-testphase/l3pdfmanagement.dtx | 254 ++- .../pdfmanagement-testphase/l3pdfmanagement.pdf | Bin 658859 -> 673135 bytes .../contrib/pdfmanagement-testphase/l3pdfmeta.dtx | 4 +- .../contrib/pdfmanagement-testphase/l3pdfmeta.pdf | Bin 664002 -> 663896 bytes .../contrib/pdfmanagement-testphase/l3pdftools.dtx | 4 +- .../contrib/pdfmanagement-testphase/l3pdftools.pdf | Bin 518408 -> 518296 bytes .../contrib/pdfmanagement-testphase/l3pdfxform.dtx | 4 +- .../contrib/pdfmanagement-testphase/l3pdfxform.pdf | Bin 418445 -> 418329 bytes .../contrib/pdfmanagement-testphase/ltdocinit.dtx | 4 +- .../contrib/pdfmanagement-testphase/ltdocinit.pdf | Bin 537047 -> 536935 bytes .../pdfmanagement-testphase/pdflscape-ltx.sty | 2 +- .../pdfmanagement-firstaid.dtx | 4 +- .../pdfmanagement-firstaid.pdf | Bin 421608 -> 421483 bytes .../pdfmanagement-testphase.dtx | 6 +- .../pdfmanagement-testphase.pdf | Bin 446478 -> 446355 bytes .../pdfmanagement-testphase/transparent-ltx.sty | 2 +- .../xcolor-patches-tmp-ltx.sty | 20 +- support/latexindent/LatexIndent/Document.pm | 40 +- support/latexindent/LatexIndent/GetYamlSettings.pm | 21 + .../latexindent/LatexIndent/ModifyLineBreaks.pm | 68 +- support/latexindent/LatexIndent/Version.pm | 4 +- support/latexindent/README | 2 +- support/latexindent/defaultSettings.yaml | 10 +- support/latexindent/documentation/appendices.tex | 85 +- .../latexindent/documentation/figure-schematic.tex | 24 +- support/latexindent/documentation/latexindent.pdf | Bin 946088 -> 949988 bytes support/latexindent/documentation/latexindent.tex | 123 +- .../sec-conclusions-know-limitations.tex | 27 +- .../documentation/sec-default-user-local.tex | 715 +++---- .../documentation/sec-demonstration.tex | 18 +- .../latexindent/documentation/sec-fine-tuning.tex | 51 +- .../latexindent/documentation/sec-how-to-use.tex | 230 ++- .../sec-indent-config-and-settings.tex | 132 +- .../latexindent/documentation/sec-introduction.tex | 62 +- .../latexindent/documentation/sec-replacements.tex | 107 +- .../latexindent/documentation/sec-the-m-switch.tex | 1947 +------------------- .../subsec-combine-text-wrap-para-line-breaks.tex | 112 ++ .../subsec-commands-and-their-options.tex | 141 +- .../subsec-conflicting-poly-switches.tex | 170 -- .../subsec-noAdditionalIndent-indentRules.tex | 16 +- .../documentation/subsec-one-sentence-per-line.tex | 404 ++++ .../subsec-partnering-poly-switches.tex | 54 - .../documentation/subsec-poly-switches.tex | 1101 +++++++++++ .../subsec-remove-para-line-breaks.tex | 217 +++ .../documentation/subsec-text-wrap-summary.tex | 26 + .../latexindent/documentation/subsec-text-wrap.tex | 359 ++++ .../subsubsec-commands-with-arguments.tex | 45 +- .../subsubsec-environments-and-their-arguments.tex | 114 +- .../subsubsec-environments-with-items.tex | 33 +- .../documentation/subsubsec-headings.tex | 37 +- .../documentation/subsubsec-ifelsefi.tex | 26 +- .../subsubsec-no-add-remaining-code-blocks.tex | 70 +- .../documentation/subsubsec-special.tex | 15 +- support/latexindent/documentation/title.tex | 4 +- support/latexindent/latexindent.pl | 2 +- systems/win32/miktex/tm/packages/next/pr.ini | 8 +- systems/win32/miktex/tm/packages/pr.ini | 8 +- timestamp | 2 +- 109 files changed, 5820 insertions(+), 4228 deletions(-) create mode 100644 macros/latex/contrib/hvlogos/Changes create mode 100644 macros/latex/contrib/hvlogos/README create mode 100644 macros/latex/contrib/hvlogos/doc/hvlogos-doc.pdf create mode 100644 macros/latex/contrib/hvlogos/doc/hvlogos-doc.tex create mode 100644 macros/latex/contrib/hvlogos/latex/hvlogos.sty create mode 100644 support/latexindent/documentation/subsec-combine-text-wrap-para-line-breaks.tex delete mode 100644 support/latexindent/documentation/subsec-conflicting-poly-switches.tex create mode 100644 support/latexindent/documentation/subsec-one-sentence-per-line.tex delete mode 100644 support/latexindent/documentation/subsec-partnering-poly-switches.tex create mode 100644 support/latexindent/documentation/subsec-poly-switches.tex create mode 100644 support/latexindent/documentation/subsec-remove-para-line-breaks.tex create mode 100644 support/latexindent/documentation/subsec-text-wrap-summary.tex create mode 100644 support/latexindent/documentation/subsec-text-wrap.tex diff --git a/FILES.byname b/FILES.byname index 84da59c5af..b812f52106 100644 --- a/FILES.byname +++ b/FILES.byname @@ -5100,7 +5100,7 @@ 1990/10/02 | 5440 | dviware/vutex/vaxvms.hlp 1990/10/02 | 812 | dviware/vutex/vaxvms.ins 1990/10/02 | 127576 | dviware/vutex/vutex.web -2021/07/30 | 92431 | FILES.last07days +2021/07/31 | 87257 | FILES.last07days 2021/07/24 | 1139410 | fonts/aboensis/Aboensis.glyphs 2021/07/24 | 18907382 | fonts/aboensis/aboensis.pdf 2021/07/24 | 137860 | fonts/aboensis/Aboensis-Regular.otf @@ -170048,24 +170048,24 @@ 2020/01/02 | 19176 | info/impatient/xmptext.tex 2020/01/06 | 30539045 | info/impatient.zip 1997/10/22 | 46895 | info/installing_psnfss_on_emtex.pdf -2021/04/06 | 4321 | info/install-latex-guide-zh-cn/appendix/mirror.tex +2021/07/13 | 4452 | info/install-latex-guide-zh-cn/appendix/mirror.tex 2020/11/14 | 2463 | info/install-latex-guide-zh-cn/appendix/offline.tex -2021/07/03 | 4457 | info/install-latex-guide-zh-cn/appendix/updateinfo.tex +2021/07/31 | 4685 | info/install-latex-guide-zh-cn/appendix/updateinfo.tex 2020/11/14 | 3610 | info/install-latex-guide-zh-cn/appendix/wsladdition.tex 2021/07/03 | 22938 | info/install-latex-guide-zh-cn/chapter/editor.tex -2020/11/14 | 5330 | info/install-latex-guide-zh-cn/chapter/macos.tex +2021/07/04 | 5339 | info/install-latex-guide-zh-cn/chapter/macos.tex 2021/04/06 | 3832 | info/install-latex-guide-zh-cn/chapter/overleaf.tex 2021/06/01 | 2526 | info/install-latex-guide-zh-cn/chapter/preface.tex -2021/06/01 | 13776 | info/install-latex-guide-zh-cn/chapter/ubuntu.tex -2021/07/03 | 20352 | info/install-latex-guide-zh-cn/chapter/windows.tex -2021/04/07 | 11913 | info/install-latex-guide-zh-cn/chapter/wsl.tex -2021/07/03 | 742445 | info/install-latex-guide-zh-cn/install-latex-guide-zh-cn.pdf +2021/07/04 | 13796 | info/install-latex-guide-zh-cn/chapter/ubuntu.tex +2021/07/31 | 20834 | info/install-latex-guide-zh-cn/chapter/windows.tex +2021/07/04 | 11903 | info/install-latex-guide-zh-cn/chapter/wsl.tex +2021/08/01 | 744469 | info/install-latex-guide-zh-cn/install-latex-guide-zh-cn.pdf 2020/11/14 | 3201 | info/install-latex-guide-zh-cn/install-latex-guide-zh-cn.tex 2020/11/14 | 19039 | info/install-latex-guide-zh-cn/LICENSE 2020/11/14 | 491 | info/install-latex-guide-zh-cn/make.bat 2020/11/14 | 596 | info/install-latex-guide-zh-cn/makefile 2021/05/08 | 2680 | info/install-latex-guide-zh-cn/README.md -2021/07/03 | 781800 | info/install-latex-guide-zh-cn.zip +2021/07/31 | 783736 | info/install-latex-guide-zh-cn.zip 2008/06/13 | 116805 | info/intro-scientific/earth-moon.pdf 2009/02/19 | 226 | info/intro-scientific/Makefile 2009/02/18 | 1350 | info/intro-scientific/README @@ -186489,7 +186489,7 @@ 2013/04/01 | 14776 | macros/context/contrib/context-visualcounter/tex/context/third/visualcounter/t-visualcounter.mkvi 2018/03/05 | 11 | macros/context/contrib/context-visualcounter/VERSION 2018/03/22 | 276789 | macros/context/contrib/context-visualcounter.zip -2021/07/27 | 117096237 | macros/context/latest/cont-tmf.zip +2021/07/29 | 116951144 | macros/context/latest/cont-tmf.zip 2016/04/21 | 32846 | macros/cstex/base/cmexb.tar.gz 2016/06/26 | 1728262 | macros/cstex/base/csfonts-t1.tar.gz 2007/03/01 | 187106 | macros/cstex/base/csfonts.tar.gz @@ -199241,13 +199241,13 @@ 2005/01/05 | 9646 | macros/latex/contrib/examplep/verbfwr.sty 2005/01/10 | 9400 | macros/latex/contrib/examplep/wrfiles.pl 2010/02/04 | 444659 | macros/latex/contrib/examplep.zip -2019/01/09 | 204825 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.pdf -2019/01/09 | 41875 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.tex -2019/01/09 | 62606 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.pdf -2019/01/09 | 21347 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.sty -2019/01/09 | 11713 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.tex -2019/01/09 | 3542 | macros/latex/contrib/exam-randomizechoices/README.md -2019/01/09 | 284368 | macros/latex/contrib/exam-randomizechoices.zip +2021/07/31 | 217081 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.pdf +2021/07/31 | 47023 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.tex +2021/07/31 | 88494 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.pdf +2021/07/31 | 22875 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.sty +2021/07/31 | 25321 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.tex +2021/07/31 | 3542 | macros/latex/contrib/exam-randomizechoices/README.md +2021/07/31 | 320254 | macros/latex/contrib/exam-randomizechoices.zip 2021/02/27 | 2224 | macros/latex/contrib/exam/README 1996/03/01 | 3240 | macros/latex/contrib/exams/exam.cfg 1998/12/15 | 63296 | macros/latex/contrib/exams/exam.dtx @@ -202660,6 +202660,12 @@ 2017/12/12 | 3708 | macros/latex/contrib/hvindex/latex/hvindex.sty 2017/12/12 | 724 | macros/latex/contrib/hvindex/README 2017/12/12 | 77756 | macros/latex/contrib/hvindex.zip +2021/07/30 | 55 | macros/latex/contrib/hvlogos/Changes +2021/07/30 | 76164 | macros/latex/contrib/hvlogos/doc/hvlogos-doc.pdf +2021/07/30 | 3373 | macros/latex/contrib/hvlogos/doc/hvlogos-doc.tex +2021/07/30 | 5250 | macros/latex/contrib/hvlogos/latex/hvlogos.sty +2021/07/30 | 244 | macros/latex/contrib/hvlogos/README +2021/07/31 | 77401 | macros/latex/contrib/hvlogos.zip 2021/05/18 | 223 | macros/latex/contrib/hvqrurl/Changes 2021/05/18 | 105059 | macros/latex/contrib/hvqrurl/doc/hvqrurl.pdf 2021/05/18 | 6429 | macros/latex/contrib/hvqrurl/doc/hvqrurl.tex @@ -205425,11 +205431,11 @@ 2006/09/11 | 4093 | macros/latex/contrib/lyx/sikumuna/article-sikumuna.layout 2006/09/11 | 781 | macros/latex/contrib/lyx/sikumuna/README 2006/09/11 | 1806 | macros/latex/contrib/lyx/sikumuna.zip -2021/07/29 | 14332 | macros/latex/contrib/macrolist/macrolist.dtx -2021/07/29 | 1878 | macros/latex/contrib/macrolist/macrolist.ins -2021/07/29 | 193608 | macros/latex/contrib/macrolist/macrolist.pdf -2021/07/29 | 1137 | macros/latex/contrib/macrolist/README.md -2021/07/30 | 193556 | macros/latex/contrib/macrolist.zip +2021/07/31 | 15661 | macros/latex/contrib/macrolist/macrolist.dtx +2021/07/31 | 1878 | macros/latex/contrib/macrolist/macrolist.ins +2021/07/31 | 194057 | macros/latex/contrib/macrolist/macrolist.pdf +2021/07/31 | 1137 | macros/latex/contrib/macrolist/README.md +2021/07/31 | 194141 | macros/latex/contrib/macrolist.zip 2013/08/21 | 6825 | macros/latex/contrib/macroswap/macroswap.dtx 2013/08/18 | 1785 | macros/latex/contrib/macroswap/macroswap.ins 2013/08/21 | 162297 | macros/latex/contrib/macroswap/macroswap.pdf @@ -208902,54 +208908,54 @@ 2019/12/05 | 299397 | macros/latex/contrib/pdflscape/pdflscape.pdf 2019/12/05 | 170 | macros/latex/contrib/pdflscape/README.md 2019/12/06 | 301872 | macros/latex/contrib/pdflscape.zip -2021/07/21 | 3872 | macros/latex/contrib/pdfmanagement-testphase/CHANGELOG.md -2021/07/21 | 7728 | macros/latex/contrib/pdfmanagement-testphase/color-ltx.sty -2021/07/21 | 173339 | macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.dtx -2021/07/21 | 949513 | macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.pdf -2021/07/21 | 4212 | macros/latex/contrib/pdfmanagement-testphase/hyperxmp-patches-tmp-ltx.sty -2021/07/21 | 57218 | macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.dtx -2021/07/21 | 594809 | macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.pdf -2021/07/21 | 27837 | macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.dtx -2021/07/21 | 577451 | macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.pdf -2021/07/21 | 17429 | macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.dtx -2021/07/21 | 527225 | macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.pdf -2021/07/21 | 26672 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.dtx -2021/07/21 | 548003 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.pdf -2021/07/21 | 18289 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.dtx -2021/07/21 | 531031 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.pdf -2021/07/21 | 20556 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.dtx -2021/07/21 | 534245 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.pdf -2021/07/21 | 67782 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield.dtx -2021/07/21 | 739384 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield.pdf -2021/07/21 | 26662 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.dtx -2021/07/21 | 526426 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.pdf -2021/07/21 | 27438 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.dtx -2021/07/21 | 576432 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.pdf -2021/07/21 | 22113 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.dtx -2021/07/21 | 505665 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.pdf -2021/07/21 | 28041 | macros/latex/contrib/pdfmanagement-testphase/l3pdffile.dtx -2021/07/21 | 553454 | macros/latex/contrib/pdfmanagement-testphase/l3pdffile.pdf -2021/07/21 | 55200 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.dtx -2021/07/21 | 658859 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.pdf -2021/07/21 | 30568 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.dtx -2021/07/21 | 664002 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.pdf -2021/07/21 | 15784 | macros/latex/contrib/pdfmanagement-testphase/l3pdftools.dtx -2021/07/21 | 518408 | macros/latex/contrib/pdfmanagement-testphase/l3pdftools.pdf -2021/07/21 | 6549 | macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.dtx -2021/07/21 | 418445 | macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.pdf +2021/07/31 | 4570 | macros/latex/contrib/pdfmanagement-testphase/CHANGELOG.md +2021/07/31 | 7728 | macros/latex/contrib/pdfmanagement-testphase/color-ltx.sty +2021/07/31 | 173067 | macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.dtx +2021/07/31 | 948089 | macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.pdf +2021/07/31 | 4212 | macros/latex/contrib/pdfmanagement-testphase/hyperxmp-patches-tmp-ltx.sty +2021/07/31 | 55632 | macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.dtx +2021/07/31 | 591169 | macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.pdf +2021/07/31 | 27837 | macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.dtx +2021/07/31 | 577331 | macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.pdf +2021/07/31 | 17429 | macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.dtx +2021/07/31 | 527111 | macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.pdf +2021/07/31 | 26672 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.dtx +2021/07/31 | 547881 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.pdf +2021/07/31 | 18289 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.dtx +2021/07/31 | 530911 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.pdf +2021/07/31 | 20556 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.dtx +2021/07/31 | 534125 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.pdf +2021/07/31 | 67782 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield.dtx +2021/07/31 | 739256 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield.pdf +2021/07/31 | 26662 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.dtx +2021/07/31 | 526311 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.pdf +2021/07/31 | 27438 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.dtx +2021/07/31 | 576314 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.pdf +2021/07/31 | 22113 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.dtx +2021/07/31 | 505534 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.pdf +2021/07/31 | 28041 | macros/latex/contrib/pdfmanagement-testphase/l3pdffile.dtx +2021/07/31 | 553330 | macros/latex/contrib/pdfmanagement-testphase/l3pdffile.pdf +2021/07/31 | 63320 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.dtx +2021/07/31 | 673135 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.pdf +2021/07/31 | 30568 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.dtx +2021/07/31 | 663896 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.pdf +2021/07/31 | 15784 | macros/latex/contrib/pdfmanagement-testphase/l3pdftools.dtx +2021/07/31 | 518296 | macros/latex/contrib/pdfmanagement-testphase/l3pdftools.pdf +2021/07/31 | 6549 | macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.dtx +2021/07/31 | 418329 | macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.pdf 2021/06/29 | 4041 | macros/latex/contrib/pdfmanagement-testphase/l3ref-tmp.sty -2021/07/21 | 15944 | macros/latex/contrib/pdfmanagement-testphase/ltdocinit.dtx -2021/07/21 | 537047 | macros/latex/contrib/pdfmanagement-testphase/ltdocinit.pdf -2021/07/21 | 1822 | macros/latex/contrib/pdfmanagement-testphase/pdflscape-ltx.sty -2021/07/21 | 11151 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.dtx -2021/07/21 | 421608 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.pdf -2021/07/21 | 17807 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.dtx +2021/07/31 | 15944 | macros/latex/contrib/pdfmanagement-testphase/ltdocinit.dtx +2021/07/31 | 536935 | macros/latex/contrib/pdfmanagement-testphase/ltdocinit.pdf +2021/07/31 | 1822 | macros/latex/contrib/pdfmanagement-testphase/pdflscape-ltx.sty +2021/07/31 | 11151 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.dtx +2021/07/31 | 421483 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.pdf +2021/07/31 | 17807 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.dtx 2021/06/14 | 4760 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.ins -2021/07/21 | 446478 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.pdf -2021/07/21 | 1195 | macros/latex/contrib/pdfmanagement-testphase/README.md -2021/07/21 | 580 | macros/latex/contrib/pdfmanagement-testphase/transparent-ltx.sty -2021/07/21 | 3959 | macros/latex/contrib/pdfmanagement-testphase/xcolor-patches-tmp-ltx.sty -2021/07/21 | 10657849 | macros/latex/contrib/pdfmanagement-testphase.zip +2021/07/31 | 446355 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.pdf +2021/07/31 | 1195 | macros/latex/contrib/pdfmanagement-testphase/README.md +2021/07/31 | 580 | macros/latex/contrib/pdfmanagement-testphase/transparent-ltx.sty +2021/07/31 | 4617 | macros/latex/contrib/pdfmanagement-testphase/xcolor-patches-tmp-ltx.sty +2021/07/31 | 10666138 | macros/latex/contrib/pdfmanagement-testphase.zip 2011/05/05 | 156 | macros/latex/contrib/pdfmarginpar/doc/pdfmarginparexample.aux 2011/05/05 | 3368 | macros/latex/contrib/pdfmarginpar/doc/pdfmarginparexample.log 2011/05/05 | 64982 | macros/latex/contrib/pdfmarginpar/doc/pdfmarginparexample.pdf @@ -259731,79 +259737,83 @@ 2018/04/15 | 1313 | support/latex-git-log/po/de.po 2020/02/26 | 3353 | support/latex-git-log/README.md 2020/02/27 | 87742 | support/latex-git-log.zip -2021/07/23 | 18453 | support/latexindent/defaultSettings.yaml -2021/07/23 | 13111 | support/latexindent/documentation/appendices.tex -2021/07/23 | 492 | support/latexindent/documentation/cmhlistings.tex -2021/07/23 | 7161 | support/latexindent/documentation/figure-schematic.png -2021/07/23 | 1896 | support/latexindent/documentation/figure-schematic.tex -2021/07/23 | 946088 | support/latexindent/documentation/latexindent.pdf -2021/07/23 | 23256 | support/latexindent/documentation/latexindent.tex -2021/07/23 | 44096 | support/latexindent/documentation/logo.png -2021/07/23 | 1664 | support/latexindent/documentation/logo.tex -2021/07/23 | 246 | support/latexindent/documentation/references.tex -2021/07/23 | 1686 | support/latexindent/documentation/sec-conclusions-know-limitations.tex -2021/07/23 | 68797 | support/latexindent/documentation/sec-default-user-local.tex -2021/07/23 | 2118 | support/latexindent/documentation/sec-demonstration.tex -2021/07/23 | 12053 | support/latexindent/documentation/sec-fine-tuning.tex -2021/07/23 | 18926 | support/latexindent/documentation/sec-how-to-use.tex -2021/07/23 | 10858 | support/latexindent/documentation/sec-indent-config-and-settings.tex -2021/07/23 | 7970 | support/latexindent/documentation/sec-introduction.tex -2021/07/23 | 21671 | support/latexindent/documentation/sec-replacements.tex -2021/07/23 | 109857 | support/latexindent/documentation/sec-the-m-switch.tex -2021/07/23 | 14049 | support/latexindent/documentation/subsec-commands-and-their-options.tex -2021/07/23 | 9353 | support/latexindent/documentation/subsec-conflicting-poly-switches.tex -2021/07/23 | 1891 | support/latexindent/documentation/subsec-noAdditionalIndent-indentRules.tex -2021/07/23 | 2902 | support/latexindent/documentation/subsec-partnering-poly-switches.tex -2021/07/23 | 5974 | support/latexindent/documentation/subsubsec-commands-with-arguments.tex -2021/07/23 | 16693 | support/latexindent/documentation/subsubsec-environments-and-their-arguments.tex -2021/07/23 | 3451 | support/latexindent/documentation/subsubsec-environments-with-items.tex -2021/07/23 | 5284 | support/latexindent/documentation/subsubsec-headings.tex -2021/07/23 | 4869 | support/latexindent/documentation/subsubsec-ifelsefi.tex -2021/07/23 | 7223 | support/latexindent/documentation/subsubsec-no-add-remaining-code-blocks.tex -2021/07/23 | 3847 | support/latexindent/documentation/subsubsec-special.tex -2021/07/23 | 1479 | support/latexindent/documentation/title.tex -2021/07/23 | 61612 | support/latexindent/LatexIndent/AlignmentAtAmpersand.pm -2021/07/23 | 23600 | support/latexindent/LatexIndent/Arguments.pm -2021/07/23 | 6042 | support/latexindent/LatexIndent/BackUpFileProcedure.pm -2021/07/23 | 4798 | support/latexindent/LatexIndent/BlankLines.pm -2021/07/23 | 12661 | support/latexindent/LatexIndent/Braces.pm -2021/07/23 | 10361 | support/latexindent/LatexIndent/Command.pm -2021/07/23 | 19993 | support/latexindent/LatexIndent/Document.pm -2021/07/23 | 1483 | support/latexindent/LatexIndent/DoubleBackSlash.pm -2021/07/23 | 5969 | support/latexindent/LatexIndent/Else.pm -2021/07/23 | 6335 | support/latexindent/LatexIndent/Environment.pm -2021/07/23 | 6375580 | support/latexindent/latexindent.exe -2021/07/23 | 11823 | support/latexindent/LatexIndent/FileContents.pm -2021/07/23 | 6589 | support/latexindent/LatexIndent/FileExtension.pm -2021/07/23 | 51706 | support/latexindent/LatexIndent/GetYamlSettings.pm -2021/07/23 | 10806 | support/latexindent/LatexIndent/Heading.pm -2021/07/23 | 12302 | support/latexindent/LatexIndent/HiddenChildren.pm -2021/07/23 | 3394 | support/latexindent/LatexIndent/HorizontalWhiteSpace.pm -2021/07/23 | 9541 | support/latexindent/LatexIndent/IfElseFi.pm -2021/07/23 | 20575 | support/latexindent/LatexIndent/Indent.pm -2021/07/23 | 6408 | support/latexindent/LatexIndent/Item.pm -2021/07/23 | 5312 | support/latexindent/LatexIndent/KeyEqualsValuesBraces.pm -2021/07/23 | 7881 | support/latexindent/LatexIndent/LogFile.pm -2021/07/23 | 2212 | support/latexindent/LatexIndent/Logger.pm -2021/07/23 | 6793 | support/latexindent/LatexIndent/MandatoryArgument.pm -2021/07/23 | 20812 | support/latexindent/LatexIndent/ModifyLineBreaks.pm -2021/07/23 | 1558 | support/latexindent/latexindent-module-installer.pl -2021/07/23 | 4284 | support/latexindent/LatexIndent/NamedGroupingBracesBrackets.pm -2021/07/23 | 6062 | support/latexindent/LatexIndent/OptionalArgument.pm -2021/07/23 | 2647 | support/latexindent/latexindent.pl -2021/07/23 | 3463 | support/latexindent/LatexIndent/Preamble.pm -2021/07/23 | 3618 | support/latexindent/LatexIndent/Replacement.pm -2021/07/23 | 4355 | support/latexindent/LatexIndent/RoundBrackets.pm -2021/07/23 | 19864 | support/latexindent/LatexIndent/Sentence.pm -2021/07/23 | 13572 | support/latexindent/LatexIndent/Special.pm -2021/07/23 | 1992 | support/latexindent/LatexIndent/Switches.pm -2021/07/23 | 3273 | support/latexindent/LatexIndent/Tokens.pm -2021/07/23 | 6385 | support/latexindent/LatexIndent/TrailingComments.pm -2021/07/23 | 5777 | support/latexindent/LatexIndent/UnNamedGroupingBracesBrackets.pm -2021/07/23 | 22855 | support/latexindent/LatexIndent/Verbatim.pm -2021/07/23 | 835 | support/latexindent/LatexIndent/Version.pm -2021/07/23 | 1876 | support/latexindent/README -2021/07/23 | 4659302 | support/latexindent.zip +2021/07/31 | 18760 | support/latexindent/defaultSettings.yaml +2021/07/31 | 13109 | support/latexindent/documentation/appendices.tex +2021/07/31 | 492 | support/latexindent/documentation/cmhlistings.tex +2021/07/31 | 7161 | support/latexindent/documentation/figure-schematic.png +2021/07/31 | 1879 | support/latexindent/documentation/figure-schematic.tex +2021/07/31 | 949988 | support/latexindent/documentation/latexindent.pdf +2021/07/31 | 23932 | support/latexindent/documentation/latexindent.tex +2021/07/31 | 44096 | support/latexindent/documentation/logo.png +2021/07/31 | 1664 | support/latexindent/documentation/logo.tex +2021/07/31 | 246 | support/latexindent/documentation/references.tex +2021/07/31 | 1688 | support/latexindent/documentation/sec-conclusions-know-limitations.tex +2021/07/31 | 68758 | support/latexindent/documentation/sec-default-user-local.tex +2021/07/31 | 2120 | support/latexindent/documentation/sec-demonstration.tex +2021/07/31 | 12024 | support/latexindent/documentation/sec-fine-tuning.tex +2021/07/31 | 18923 | support/latexindent/documentation/sec-how-to-use.tex +2021/07/31 | 10859 | support/latexindent/documentation/sec-indent-config-and-settings.tex +2021/07/31 | 7969 | support/latexindent/documentation/sec-introduction.tex +2021/07/31 | 21650 | support/latexindent/documentation/sec-replacements.tex +2021/07/31 | 3075 | support/latexindent/documentation/sec-the-m-switch.tex +2021/07/31 | 5736 | support/latexindent/documentation/subsec-combine-text-wrap-para-line-breaks.tex +2021/07/31 | 14050 | support/latexindent/documentation/subsec-commands-and-their-options.tex +2021/07/31 | 1909 | support/latexindent/documentation/subsec-noAdditionalIndent-indentRules.tex +2021/07/31 | 22107 | support/latexindent/documentation/subsec-one-sentence-per-line.tex +2021/07/31 | 66280 | support/latexindent/documentation/subsec-poly-switches.tex +2021/07/31 | 11600 | support/latexindent/documentation/subsec-remove-para-line-breaks.tex +2021/07/31 | 1442 | support/latexindent/documentation/subsec-text-wrap-summary.tex +2021/07/31 | 18082 | support/latexindent/documentation/subsec-text-wrap.tex +2021/07/31 | 5979 | support/latexindent/documentation/subsubsec-commands-with-arguments.tex +2021/07/31 | 16703 | support/latexindent/documentation/subsubsec-environments-and-their-arguments.tex +2021/07/31 | 3450 | support/latexindent/documentation/subsubsec-environments-with-items.tex +2021/07/31 | 5286 | support/latexindent/documentation/subsubsec-headings.tex +2021/07/31 | 4873 | support/latexindent/documentation/subsubsec-ifelsefi.tex +2021/07/31 | 7234 | support/latexindent/documentation/subsubsec-no-add-remaining-code-blocks.tex +2021/07/31 | 3850 | support/latexindent/documentation/subsubsec-special.tex +2021/07/31 | 1477 | support/latexindent/documentation/title.tex +2021/07/31 | 61612 | support/latexindent/LatexIndent/AlignmentAtAmpersand.pm +2021/07/31 | 23600 | support/latexindent/LatexIndent/Arguments.pm +2021/07/31 | 6042 | support/latexindent/LatexIndent/BackUpFileProcedure.pm +2021/07/31 | 4798 | support/latexindent/LatexIndent/BlankLines.pm +2021/07/31 | 12661 | support/latexindent/LatexIndent/Braces.pm +2021/07/31 | 10361 | support/latexindent/LatexIndent/Command.pm +2021/07/31 | 21217 | support/latexindent/LatexIndent/Document.pm +2021/07/31 | 1483 | support/latexindent/LatexIndent/DoubleBackSlash.pm +2021/07/31 | 5969 | support/latexindent/LatexIndent/Else.pm +2021/07/31 | 6335 | support/latexindent/LatexIndent/Environment.pm +2021/07/31 | 9803909 | support/latexindent/latexindent.exe +2021/07/31 | 11823 | support/latexindent/LatexIndent/FileContents.pm +2021/07/31 | 6589 | support/latexindent/LatexIndent/FileExtension.pm +2021/07/31 | 52738 | support/latexindent/LatexIndent/GetYamlSettings.pm +2021/07/31 | 10806 | support/latexindent/LatexIndent/Heading.pm +2021/07/31 | 12302 | support/latexindent/LatexIndent/HiddenChildren.pm +2021/07/31 | 3394 | support/latexindent/LatexIndent/HorizontalWhiteSpace.pm +2021/07/31 | 9541 | support/latexindent/LatexIndent/IfElseFi.pm +2021/07/31 | 20575 | support/latexindent/LatexIndent/Indent.pm +2021/07/31 | 6408 | support/latexindent/LatexIndent/Item.pm +2021/07/31 | 5312 | support/latexindent/LatexIndent/KeyEqualsValuesBraces.pm +2021/07/31 | 7881 | support/latexindent/LatexIndent/LogFile.pm +2021/07/31 | 2212 | support/latexindent/LatexIndent/Logger.pm +2021/07/31 | 6793 | support/latexindent/LatexIndent/MandatoryArgument.pm +2021/07/31 | 22938 | support/latexindent/LatexIndent/ModifyLineBreaks.pm +2021/07/31 | 1558 | support/latexindent/latexindent-module-installer.pl +2021/07/31 | 4284 | support/latexindent/LatexIndent/NamedGroupingBracesBrackets.pm +2021/07/31 | 6062 | support/latexindent/LatexIndent/OptionalArgument.pm +2021/07/31 | 2645 | support/latexindent/latexindent.pl +2021/07/31 | 3463 | support/latexindent/LatexIndent/Preamble.pm +2021/07/31 | 3618 | support/latexindent/LatexIndent/Replacement.pm +2021/07/31 | 4355 | support/latexindent/LatexIndent/RoundBrackets.pm +2021/07/31 | 19864 | support/latexindent/LatexIndent/Sentence.pm +2021/07/31 | 13572 | support/latexindent/LatexIndent/Special.pm +2021/07/31 | 1992 | support/latexindent/LatexIndent/Switches.pm +2021/07/31 | 3273 | support/latexindent/LatexIndent/Tokens.pm +2021/07/31 | 6385 | support/latexindent/LatexIndent/TrailingComments.pm +2021/07/31 | 5777 | support/latexindent/LatexIndent/UnNamedGroupingBracesBrackets.pm +2021/07/31 | 22855 | support/latexindent/LatexIndent/Verbatim.pm +2021/07/31 | 833 | support/latexindent/LatexIndent/Version.pm +2021/07/31 | 1874 | support/latexindent/README +2021/07/31 | 5992676 | support/latexindent.zip 2021/01/03 | 16380 | support/latex-make/figlatex.dtx 2021/01/03 | 221479 | support/latex-make/figlatex.pdf 2001/06/07 | 302 | support/latexmake/latexmake.diz @@ -284065,7 +284075,7 @@ 2020/10/03 | 318630 | systems/win32/miktex/tm/packages/filehook.tar.lzma 2012/12/04 | 924573 | systems/win32/miktex/tm/packages/fileinfo.tar.lzma 2011/09/21 | 281409 | systems/win32/miktex/tm/packages/filemod.tar.lzma -2021/07/30 | 592787 | systems/win32/miktex/tm/packages/files.csv.lzma +2021/07/31 | 592787 | systems/win32/miktex/tm/packages/files.csv.lzma 2001/05/14 | 5617 | systems/win32/miktex/tm/packages/finbib.tar.lzma 2015/10/20 | 44379 | systems/win32/miktex/tm/packages/findhyph.tar.lzma 2011/10/21 | 89323 | systems/win32/miktex/tm/packages/fink.tar.lzma @@ -285399,9 +285409,9 @@ 2018/01/12 | 157226 | systems/win32/miktex/tm/packages/miktex-zip-bin-x64.tar.lzma 2021/07/17 | 39091 | systems/win32/miktex/tm/packages/miktex-zlib-bin-2.9.tar.lzma 2021/07/17 | 43361 | systems/win32/miktex/tm/packages/miktex-zlib-bin-x64-2.9.tar.lzma -2021/07/30 | 231869 | systems/win32/miktex/tm/packages/miktex-zzdb1-2.9.tar.lzma -2021/07/30 | 1320514 | systems/win32/miktex/tm/packages/miktex-zzdb2-2.9.tar.lzma -2021/07/30 | 1228735 | systems/win32/miktex/tm/packages/miktex-zzdb3-2.9.tar.lzma +2021/07/31 | 231888 | systems/win32/miktex/tm/packages/miktex-zzdb1-2.9.tar.lzma +2021/07/31 | 1320637 | systems/win32/miktex/tm/packages/miktex-zzdb2-2.9.tar.lzma +2021/07/31 | 1227675 | systems/win32/miktex/tm/packages/miktex-zzdb3-2.9.tar.lzma 2021/07/17 | 13442 | systems/win32/miktex/tm/packages/miktex-zzip-bin-2.9.tar.lzma 2021/07/17 | 14316 | systems/win32/miktex/tm/packages/miktex-zzip-bin-x64-2.9.tar.lzma 2016/07/15 | 35914 | systems/win32/miktex/tm/packages/mil3.tar.lzma @@ -285598,189 +285608,189 @@ 2018/04/09 | 400132 | systems/win32/miktex/tm/packages/newunicodechar.tar.lzma 2011/09/19 | 101312 | systems/win32/miktex/tm/packages/newvbtm.tar.lzma 2021/03/17 | 232249 | systems/win32/miktex/tm/packages/newverbs.tar.lzma -2021/07/30 | 593220 | systems/win32/miktex/tm/packages/next/files.csv.lzma -2021/07/30 | 51113 | systems/win32/miktex/tm/packages/next/miktex-arctrl-bin-2.9.tar.lzma -2021/07/30 | 56477 | systems/win32/miktex/tm/packages/next/miktex-arctrl-bin-x64-2.9.tar.lzma -2021/07/30 | 975019 | systems/win32/miktex/tm/packages/next/miktex-asymptote-bin-2.9.tar.lzma -2021/07/30 | 1077990 | systems/win32/miktex/tm/packages/next/miktex-asymptote-bin-x64-2.9.tar.lzma -2021/07/30 | 29037 | systems/win32/miktex/tm/packages/next/miktex-autosp-bin-2.9.tar.lzma -2021/07/30 | 31351 | systems/win32/miktex/tm/packages/next/miktex-autosp-bin-x64-2.9.tar.lzma -2021/07/30 | 29842 | systems/win32/miktex/tm/packages/next/miktex-axohelp-bin-2.9.tar.lzma -2021/07/30 | 34665 | systems/win32/miktex/tm/packages/next/miktex-axohelp-bin-x64-2.9.tar.lzma -2021/07/30 | 50152 | systems/win32/miktex/tm/packages/next/miktex-bibarts-bin-2.9.tar.lzma -2021/07/30 | 57550 | systems/win32/miktex/tm/packages/next/miktex-bibarts-bin-x64-2.9.tar.lzma -2021/07/30 | 83540 | systems/win32/miktex/tm/packages/next/miktex-bibtex8bit-bin-2.9.tar.lzma -2021/07/30 | 95402 | systems/win32/miktex/tm/packages/next/miktex-bibtex8bit-bin-x64-2.9.tar.lzma -2021/07/30 | 67820 | systems/win32/miktex/tm/packages/next/miktex-bibtex-bin-2.9.tar.lzma -2021/07/30 | 75792 | systems/win32/miktex/tm/packages/next/miktex-bibtex-bin-x64-2.9.tar.lzma -2021/07/30 | 27200 | systems/win32/miktex/tm/packages/next/miktex-bzip2-bin-2.9.tar.lzma -2021/07/30 | 30824 | systems/win32/miktex/tm/packages/next/miktex-bzip2-bin-x64-2.9.tar.lzma -2021/07/30 | 330788 | systems/win32/miktex/tm/packages/next/miktex-cairo-bin-2.9.tar.lzma -2021/07/30 | 392793 | systems/win32/miktex/tm/packages/next/miktex-cairo-bin-x64-2.9.tar.lzma -2021/07/30 | 32674 | systems/win32/miktex/tm/packages/next/miktex-chktex-bin-2.9.tar.lzma -2021/07/30 | 36628 | systems/win32/miktex/tm/packages/next/miktex-chktex-bin-x64-2.9.tar.lzma -2021/07/30 | 51311 | systems/win32/miktex/tm/packages/next/miktex-cjkutils-bin-2.9.tar.lzma -2021/07/30 | 56684 | systems/win32/miktex/tm/packages/next/miktex-cjkutils-bin-x64-2.9.tar.lzma -2021/07/30 | 241810 | systems/win32/miktex/tm/packages/next/miktex-console-bin-2.9.tar.lzma -2021/07/30 | 263958 | systems/win32/miktex/tm/packages/next/miktex-console-bin-x64-2.9.tar.lzma -2021/07/30 | 180009 | systems/win32/miktex/tm/packages/next/miktex-curl-bin-2.9.tar.lzma -2021/07/30 | 195635 | systems/win32/miktex/tm/packages/next/miktex-curl-bin-x64-2.9.tar.lzma -2021/07/30 | 54632 | systems/win32/miktex/tm/packages/next/miktex-cweb-bin-2.9.tar.lzma -2021/07/30 | 61813 | systems/win32/miktex/tm/packages/next/miktex-cweb-bin-x64-2.9.tar.lzma -2021/07/30 | 21225 | systems/win32/miktex/tm/packages/next/miktex-devnag-bin-2.9.tar.lzma -2021/07/30 | 23364 | systems/win32/miktex/tm/packages/next/miktex-devnag-bin-x64-2.9.tar.lzma -2021/07/30 | 461813 | systems/win32/miktex/tm/packages/next/miktex-doc.tar.lzma -2021/07/30 | 45906 | systems/win32/miktex/tm/packages/next/miktex-dvicopy-bin-2.9.tar.lzma -2021/07/30 | 51201 | systems/win32/miktex/tm/packages/next/miktex-dvicopy-bin-x64-2.9.tar.lzma -2021/07/30 | 284579 | systems/win32/miktex/tm/packages/next/miktex-dvipdfmx-bin-2.9.tar.lzma -2021/07/30 | 325043 | systems/win32/miktex/tm/packages/next/miktex-dvipdfmx-bin-x64-2.9.tar.lzma -2021/07/30 | 41193 | systems/win32/miktex/tm/packages/next/miktex-dvipng-bin-2.9.tar.lzma -2021/07/30 | 45311 | systems/win32/miktex/tm/packages/next/miktex-dvipng-bin-x64-2.9.tar.lzma -2021/07/30 | 119820 | systems/win32/miktex/tm/packages/next/miktex-dvips-bin-2.9.tar.lzma -2021/07/30 | 133864 | systems/win32/miktex/tm/packages/next/miktex-dvips-bin-x64-2.9.tar.lzma -2021/07/30 | 1291300 | systems/win32/miktex/tm/packages/next/miktex-dvisvgm-bin-2.9.tar.lzma -2021/07/30 | 1421868 | systems/win32/miktex/tm/packages/next/miktex-dvisvgm-bin-x64-2.9.tar.lzma -2021/07/30 | 100625 | systems/win32/miktex/tm/packages/next/miktex-epstopdf-bin-2.9.tar.lzma -2021/07/30 | 112983 | systems/win32/miktex/tm/packages/next/miktex-epstopdf-bin-x64-2.9.tar.lzma -2021/07/30 | 43027 | systems/win32/miktex/tm/packages/next/miktex-expat-bin-2.9.tar.lzma -2021/07/30 | 48252 | systems/win32/miktex/tm/packages/next/miktex-expat-bin-x64-2.9.tar.lzma -2021/07/30 | 25020 | systems/win32/miktex/tm/packages/next/miktex-findtexmf-bin-2.9.tar.lzma -2021/07/30 | 28180 | systems/win32/miktex/tm/packages/next/miktex-findtexmf-bin-x64-2.9.tar.lzma -2021/07/30 | 56316 | systems/win32/miktex/tm/packages/next/miktex-fmt-bin-2.9.tar.lzma -2021/07/30 | 62784 | systems/win32/miktex/tm/packages/next/miktex-fmt-bin-x64-2.9.tar.lzma -2021/07/30 | 136817 | systems/win32/miktex/tm/packages/next/miktex-fontconfig-bin-2.9.tar.lzma -2021/07/30 | 154426 | systems/win32/miktex/tm/packages/next/miktex-fontconfig-bin-x64-2.9.tar.lzma -2021/07/30 | 73195 | systems/win32/miktex/tm/packages/next/miktex-fonts-bin-2.9.tar.lzma -2021/07/30 | 77952 | systems/win32/miktex/tm/packages/next/miktex-fonts-bin-x64-2.9.tar.lzma -2021/07/30 | 71670 | systems/win32/miktex/tm/packages/next/miktex-freeglut-bin-2.9.tar.lzma -2021/07/30 | 80450 | systems/win32/miktex/tm/packages/next/miktex-freeglut-bin-x64-2.9.tar.lzma -2021/07/30 | 258879 | systems/win32/miktex/tm/packages/next/miktex-freetype2-bin-2.9.tar.lzma -2021/07/30 | 295204 | systems/win32/miktex/tm/packages/next/miktex-freetype2-bin-x64-2.9.tar.lzma -2021/07/30 | 22048 | systems/win32/miktex/tm/packages/next/miktex-fribidixetex-bin-2.9.tar.lzma -2021/07/30 | 24995 | systems/win32/miktex/tm/packages/next/miktex-fribidixetex-bin-x64-2.9.tar.lzma -2021/07/30 | 97339 | systems/win32/miktex/tm/packages/next/miktex-gd-bin-2.9.tar.lzma -2021/07/30 | 112087 | systems/win32/miktex/tm/packages/next/miktex-gd-bin-x64-2.9.tar.lzma -2021/07/30 | 64426 | systems/win32/miktex/tm/packages/next/miktex-graphite2-bin-2.9.tar.lzma -2021/07/30 | 73149 | systems/win32/miktex/tm/packages/next/miktex-graphite2-bin-x64-2.9.tar.lzma -2021/07/30 | 96632 | systems/win32/miktex/tm/packages/next/miktex-gregorio-bin-2.9.tar.lzma -2021/07/30 | 115350 | systems/win32/miktex/tm/packages/next/miktex-gregorio-bin-x64-2.9.tar.lzma -2021/07/30 | 38141 | systems/win32/miktex/tm/packages/next/miktex-gsf2pk-bin-2.9.tar.lzma -2021/07/30 | 43003 | systems/win32/miktex/tm/packages/next/miktex-gsf2pk-bin-x64-2.9.tar.lzma -2021/07/30 | 483653 | systems/win32/miktex/tm/packages/next/miktex-harfbuzz-bin-2.9.tar.lzma -2021/07/30 | 566526 | systems/win32/miktex/tm/packages/next/miktex-harfbuzz-bin-x64-2.9.tar.lzma -2021/07/30 | 147373 | systems/win32/miktex/tm/packages/next/miktex-hunspell-bin-2.9.tar.lzma -2021/07/30 | 159578 | systems/win32/miktex/tm/packages/next/miktex-hunspell-bin-x64-2.9.tar.lzma -2021/07/30 | 94800 | systems/win32/miktex/tm/packages/next/miktex-jpeg-bin-2.9.tar.lzma -2021/07/30 | 109030 | systems/win32/miktex/tm/packages/next/miktex-jpeg-bin-x64-2.9.tar.lzma -2021/07/30 | 16357 | systems/win32/miktex/tm/packages/next/miktex-kpathsea-bin-2.9.tar.lzma -2021/07/30 | 17981 | systems/win32/miktex/tm/packages/next/miktex-kpathsea-bin-x64-2.9.tar.lzma -2021/07/30 | 28390 | systems/win32/miktex/tm/packages/next/miktex-lacheck-bin-2.9.tar.lzma -2021/07/30 | 30059 | systems/win32/miktex/tm/packages/next/miktex-lacheck-bin-x64-2.9.tar.lzma -2021/07/30 | 629400 | systems/win32/miktex/tm/packages/next/miktex-lcdf-typetools-bin-2.9.tar.lzma -2021/07/30 | 681252 | systems/win32/miktex/tm/packages/next/miktex-lcdf-typetools-bin-x64-2.9.tar.lzma -2021/07/30 | 531852 | systems/win32/miktex/tm/packages/next/miktex-libressl-bin-2.9.tar.lzma -2021/07/30 | 596931 | systems/win32/miktex/tm/packages/next/miktex-libressl-bin-x64-2.9.tar.lzma -2021/07/30 | 476918 | systems/win32/miktex/tm/packages/next/miktex-log4cxx-bin-2.9.tar.lzma -2021/07/30 | 510583 | systems/win32/miktex/tm/packages/next/miktex-log4cxx-bin-x64-2.9.tar.lzma -2021/07/30 | 94311 | systems/win32/miktex/tm/packages/next/miktex-lua53-bin-2.9.tar.lzma -2021/07/30 | 103399 | systems/win32/miktex/tm/packages/next/miktex-lua53-bin-x64-2.9.tar.lzma -2021/07/30 | 1713894 | systems/win32/miktex/tm/packages/next/miktex-luatex-bin-2.9.tar.lzma -2021/07/30 | 2009904 | systems/win32/miktex/tm/packages/next/miktex-luatex-bin-x64-2.9.tar.lzma -2021/07/30 | 67619 | systems/win32/miktex/tm/packages/next/miktex-lzma-bin-2.9.tar.lzma -2021/07/30 | 74208 | systems/win32/miktex/tm/packages/next/miktex-lzma-bin-x64-2.9.tar.lzma -2021/07/30 | 27357 | systems/win32/miktex/tm/packages/next/miktex-makeindex-bin-2.9.tar.lzma -2021/07/30 | 31619 | systems/win32/miktex/tm/packages/next/miktex-makeindex-bin-x64-2.9.tar.lzma -2021/07/30 | 7722 | systems/win32/miktex/tm/packages/next/miktex-md5-bin-2.9.tar.lzma -2021/07/30 | 8767 | systems/win32/miktex/tm/packages/next/miktex-md5-bin-x64-2.9.tar.lzma -2021/07/30 | 196872 | systems/win32/miktex/tm/packages/next/miktex-metafont-bin-2.9.tar.lzma -2021/07/30 | 215249 | systems/win32/miktex/tm/packages/next/miktex-metafont-bin-x64-2.9.tar.lzma -2021/07/30 | 250266 | systems/win32/miktex/tm/packages/next/miktex-metapost-bin-2.9.tar.lzma -2021/07/30 | 284025 | systems/win32/miktex/tm/packages/next/miktex-metapost-bin-x64-2.9.tar.lzma -2021/07/30 | 98381 | systems/win32/miktex/tm/packages/next/miktex-mfware-bin-2.9.tar.lzma -2021/07/30 | 103203 | systems/win32/miktex/tm/packages/next/miktex-mfware-bin-x64-2.9.tar.lzma -2021/07/30 | 60638 | systems/win32/miktex/tm/packages/next/miktex-mkfntmap-bin-2.9.tar.lzma -2021/07/30 | 68024 | systems/win32/miktex/tm/packages/next/miktex-mkfntmap-bin-x64-2.9.tar.lzma -2021/07/30 | 124281 | systems/win32/miktex/tm/packages/next/miktex-mktex-bin-2.9.tar.lzma -2021/07/30 | 136820 | systems/win32/miktex/tm/packages/next/miktex-mktex-bin-x64-2.9.tar.lzma -2021/07/30 | 178355 | systems/win32/miktex/tm/packages/next/miktex-mo-bin-2.9.tar.lzma -2021/07/30 | 196741 | systems/win32/miktex/tm/packages/next/miktex-mo-bin-x64-2.9.tar.lzma -2021/07/30 | 199733 | systems/win32/miktex/tm/packages/next/miktex-mpfr-bin-2.9.tar.lzma -2021/07/30 | 180120 | systems/win32/miktex/tm/packages/next/miktex-mpfr-bin-x64-2.9.tar.lzma -2021/07/30 | 67483 | systems/win32/miktex/tm/packages/next/miktex-mpmcli-bin-2.9.tar.lzma -2021/07/30 | 76827 | systems/win32/miktex/tm/packages/next/miktex-mpmcli-bin-x64-2.9.tar.lzma -2021/07/30 | 31231 | systems/win32/miktex/tm/packages/next/miktex-mspack-bin-2.9.tar.lzma -2021/07/30 | 35087 | systems/win32/miktex/tm/packages/next/miktex-mspack-bin-x64-2.9.tar.lzma -2021/07/30 | 37804 | systems/win32/miktex/tm/packages/next/miktex-mthelp-bin-2.9.tar.lzma -2021/07/30 | 42712 | systems/win32/miktex/tm/packages/next/miktex-mthelp-bin-x64-2.9.tar.lzma -2021/07/30 | 42891 | systems/win32/miktex/tm/packages/next/miktex-mtprint-bin-2.9.tar.lzma -2021/07/30 | 46907 | systems/win32/miktex/tm/packages/next/miktex-mtprint-bin-x64-2.9.tar.lzma -2021/07/30 | 45970 | systems/win32/miktex/tm/packages/next/miktex-m-tx-bin-2.9.tar.lzma -2021/07/30 | 52523 | systems/win32/miktex/tm/packages/next/miktex-m-tx-bin-x64-2.9.tar.lzma -2021/07/30 | 194384 | systems/win32/miktex/tm/packages/next/miktex-omegaware-bin-2.9.tar.lzma -2021/07/30 | 206606 | systems/win32/miktex/tm/packages/next/miktex-omegaware-bin-x64-2.9.tar.lzma -2021/07/30 | 35692 | systems/win32/miktex/tm/packages/next/miktex-patgen-bin.tar.lzma -2021/07/30 | 40230 | systems/win32/miktex/tm/packages/next/miktex-patgen-bin-x64.tar.lzma -2021/07/30 | 744116 | systems/win32/miktex/tm/packages/next/miktex-pdftex-bin-2.9.tar.lzma -2021/07/30 | 815245 | systems/win32/miktex/tm/packages/next/miktex-pdftex-bin-x64-2.9.tar.lzma -2021/07/30 | 198169 | systems/win32/miktex/tm/packages/next/miktex-pixman-bin-2.9.tar.lzma -2021/07/30 | 202795 | systems/win32/miktex/tm/packages/next/miktex-pixman-bin-x64-2.9.tar.lzma -2021/07/30 | 208049 | systems/win32/miktex/tm/packages/next/miktex-pmx-bin-2.9.tar.lzma -2021/07/30 | 243426 | systems/win32/miktex/tm/packages/next/miktex-pmx-bin-x64-2.9.tar.lzma -2021/07/30 | 78774 | systems/win32/miktex/tm/packages/next/miktex-png-bin-2.9.tar.lzma -2021/07/30 | 87777 | systems/win32/miktex/tm/packages/next/miktex-png-bin-x64-2.9.tar.lzma -2021/07/30 | 1169718 | systems/win32/miktex/tm/packages/next/miktex-poppler-bin-2.9.tar.lzma -2021/07/30 | 1301192 | systems/win32/miktex/tm/packages/next/miktex-poppler-bin-x64-2.9.tar.lzma -2021/07/30 | 20138 | systems/win32/miktex/tm/packages/next/miktex-popt-bin-2.9.tar.lzma -2021/07/30 | 23902 | systems/win32/miktex/tm/packages/next/miktex-popt-bin-x64-2.9.tar.lzma -2021/07/30 | 31535 | systems/win32/miktex/tm/packages/next/miktex-posix-bin-2.9.tar.lzma -2021/07/30 | 37242 | systems/win32/miktex/tm/packages/next/miktex-posix-bin-x64-2.9.tar.lzma -2021/07/30 | 64186 | systems/win32/miktex/tm/packages/next/miktex-ps2pk-bin-2.9.tar.lzma -2021/07/30 | 72206 | systems/win32/miktex/tm/packages/next/miktex-ps2pk-bin-x64-2.9.tar.lzma -2021/07/30 | 50396 | systems/win32/miktex/tm/packages/next/miktex-psutils-bin-2.9.tar.lzma -2021/07/30 | 57727 | systems/win32/miktex/tm/packages/next/miktex-psutils-bin-x64-2.9.tar.lzma -2021/07/30 | 1340931 | systems/win32/miktex/tm/packages/next/miktex-runtime-bin-2.9.tar.lzma -2021/07/30 | 1464202 | systems/win32/miktex/tm/packages/next/miktex-runtime-bin-x64-2.9.tar.lzma -2021/07/30 | 42386 | systems/win32/miktex/tm/packages/next/miktex-synctex-bin-2.9.tar.lzma -2021/07/30 | 51749 | systems/win32/miktex/tm/packages/next/miktex-synctex-bin-x64-2.9.tar.lzma -2021/07/30 | 56514 | systems/win32/miktex/tm/packages/next/miktex-tdsutil-bin.tar.lzma -2021/07/30 | 60039 | systems/win32/miktex/tm/packages/next/miktex-tdsutil-bin-x64.tar.lzma -2021/07/30 | 25290 | systems/win32/miktex/tm/packages/next/miktex-teckit-bin-2.9.tar.lzma -2021/07/30 | 27389 | systems/win32/miktex/tm/packages/next/miktex-teckit-bin-x64-2.9.tar.lzma -2021/07/30 | 16412 | systems/win32/miktex/tm/packages/next/miktex-tex2xindy-bin-2.9.tar.lzma -2021/07/30 | 18177 | systems/win32/miktex/tm/packages/next/miktex-tex2xindy-bin-x64-2.9.tar.lzma -2021/07/30 | 63778 | systems/win32/miktex/tm/packages/next/miktex-tex4ht-bin-2.9.tar.lzma -2021/07/30 | 69915 | systems/win32/miktex/tm/packages/next/miktex-tex4ht-bin-x64-2.9.tar.lzma -2021/07/30 | 154806 | systems/win32/miktex/tm/packages/next/miktex-tex-bin-2.9.tar.lzma -2021/07/30 | 169242 | systems/win32/miktex/tm/packages/next/miktex-tex-bin-x64-2.9.tar.lzma -2021/07/30 | 57014 | systems/win32/miktex/tm/packages/next/miktex-texify-bin-2.9.tar.lzma -2021/07/30 | 65787 | systems/win32/miktex/tm/packages/next/miktex-texify-bin-x64-2.9.tar.lzma -2021/07/30 | 98260 | systems/win32/miktex/tm/packages/next/miktex-texware-bin-2.9.tar.lzma -2021/07/30 | 105223 | systems/win32/miktex/tm/packages/next/miktex-texware-bin-x64-2.9.tar.lzma -2021/07/30 | 2672608 | systems/win32/miktex/tm/packages/next/miktex-texworks-bin-2.9.tar.lzma -2021/07/30 | 2796726 | systems/win32/miktex/tm/packages/next/miktex-texworks-bin-x64-2.9.tar.lzma -2021/07/30 | 56356 | systems/win32/miktex/tm/packages/next/miktex-ttf2pk2-bin-2.9.tar.lzma -2021/07/30 | 62228 | systems/win32/miktex/tm/packages/next/miktex-ttf2pk2-bin-x64-2.9.tar.lzma -2021/07/30 | 33544 | systems/win32/miktex/tm/packages/next/miktex-upmendex-bin.tar.lzma -2021/07/30 | 37359 | systems/win32/miktex/tm/packages/next/miktex-upmendex-bin-x64.tar.lzma -2021/07/30 | 27728 | systems/win32/miktex/tm/packages/next/miktex-uriparser-bin-2.9.tar.lzma -2021/07/30 | 33632 | systems/win32/miktex/tm/packages/next/miktex-uriparser-bin-x64-2.9.tar.lzma -2021/07/30 | 65619 | systems/win32/miktex/tm/packages/next/miktex-web-bin-2.9.tar.lzma -2021/07/30 | 70649 | systems/win32/miktex/tm/packages/next/miktex-web-bin-x64-2.9.tar.lzma -2021/07/30 | 312109 | systems/win32/miktex/tm/packages/next/miktex-xetex-bin-2.9.tar.lzma -2021/07/30 | 345739 | systems/win32/miktex/tm/packages/next/miktex-xetex-bin-x64-2.9.tar.lzma -2021/07/30 | 55499 | systems/win32/miktex/tm/packages/next/miktex-xml2pmx-bin.tar.lzma -2021/07/30 | 57140 | systems/win32/miktex/tm/packages/next/miktex-xml2pmx-bin-x64.tar.lzma -2021/07/30 | 589843 | systems/win32/miktex/tm/packages/next/miktex-yap-bin-2.9.tar.lzma -2021/07/30 | 624651 | systems/win32/miktex/tm/packages/next/miktex-yap-bin-x64-2.9.tar.lzma -2021/07/30 | 39127 | systems/win32/miktex/tm/packages/next/miktex-zlib-bin-2.9.tar.lzma -2021/07/30 | 43426 | systems/win32/miktex/tm/packages/next/miktex-zlib-bin-x64-2.9.tar.lzma -2021/07/30 | 231946 | systems/win32/miktex/tm/packages/next/miktex-zzdb1-2.9.tar.lzma -2021/07/30 | 1319880 | systems/win32/miktex/tm/packages/next/miktex-zzdb2-2.9.tar.lzma -2021/07/30 | 1228269 | systems/win32/miktex/tm/packages/next/miktex-zzdb3-2.9.tar.lzma -2021/07/30 | 13466 | systems/win32/miktex/tm/packages/next/miktex-zzip-bin-2.9.tar.lzma -2021/07/30 | 14348 | systems/win32/miktex/tm/packages/next/miktex-zzip-bin-x64-2.9.tar.lzma +2021/07/31 | 593220 | systems/win32/miktex/tm/packages/next/files.csv.lzma +2021/07/31 | 51113 | systems/win32/miktex/tm/packages/next/miktex-arctrl-bin-2.9.tar.lzma +2021/07/31 | 56477 | systems/win32/miktex/tm/packages/next/miktex-arctrl-bin-x64-2.9.tar.lzma +2021/07/31 | 975018 | systems/win32/miktex/tm/packages/next/miktex-asymptote-bin-2.9.tar.lzma +2021/07/31 | 1077990 | systems/win32/miktex/tm/packages/next/miktex-asymptote-bin-x64-2.9.tar.lzma +2021/07/31 | 29035 | systems/win32/miktex/tm/packages/next/miktex-autosp-bin-2.9.tar.lzma +2021/07/31 | 31352 | systems/win32/miktex/tm/packages/next/miktex-autosp-bin-x64-2.9.tar.lzma +2021/07/31 | 29840 | systems/win32/miktex/tm/packages/next/miktex-axohelp-bin-2.9.tar.lzma +2021/07/31 | 34666 | systems/win32/miktex/tm/packages/next/miktex-axohelp-bin-x64-2.9.tar.lzma +2021/07/31 | 50152 | systems/win32/miktex/tm/packages/next/miktex-bibarts-bin-2.9.tar.lzma +2021/07/31 | 57549 | systems/win32/miktex/tm/packages/next/miktex-bibarts-bin-x64-2.9.tar.lzma +2021/07/31 | 83540 | systems/win32/miktex/tm/packages/next/miktex-bibtex8bit-bin-2.9.tar.lzma +2021/07/31 | 95402 | systems/win32/miktex/tm/packages/next/miktex-bibtex8bit-bin-x64-2.9.tar.lzma +2021/07/31 | 67821 | systems/win32/miktex/tm/packages/next/miktex-bibtex-bin-2.9.tar.lzma +2021/07/31 | 75793 | systems/win32/miktex/tm/packages/next/miktex-bibtex-bin-x64-2.9.tar.lzma +2021/07/31 | 27199 | systems/win32/miktex/tm/packages/next/miktex-bzip2-bin-2.9.tar.lzma +2021/07/31 | 30823 | systems/win32/miktex/tm/packages/next/miktex-bzip2-bin-x64-2.9.tar.lzma +2021/07/31 | 330787 | systems/win32/miktex/tm/packages/next/miktex-cairo-bin-2.9.tar.lzma +2021/07/31 | 392793 | systems/win32/miktex/tm/packages/next/miktex-cairo-bin-x64-2.9.tar.lzma +2021/07/31 | 32674 | systems/win32/miktex/tm/packages/next/miktex-chktex-bin-2.9.tar.lzma +2021/07/31 | 36629 | systems/win32/miktex/tm/packages/next/miktex-chktex-bin-x64-2.9.tar.lzma +2021/07/31 | 51308 | systems/win32/miktex/tm/packages/next/miktex-cjkutils-bin-2.9.tar.lzma +2021/07/31 | 56684 | systems/win32/miktex/tm/packages/next/miktex-cjkutils-bin-x64-2.9.tar.lzma +2021/07/31 | 241811 | systems/win32/miktex/tm/packages/next/miktex-console-bin-2.9.tar.lzma +2021/07/31 | 263957 | systems/win32/miktex/tm/packages/next/miktex-console-bin-x64-2.9.tar.lzma +2021/07/31 | 180011 | systems/win32/miktex/tm/packages/next/miktex-curl-bin-2.9.tar.lzma +2021/07/31 | 195636 | systems/win32/miktex/tm/packages/next/miktex-curl-bin-x64-2.9.tar.lzma +2021/07/31 | 54633 | systems/win32/miktex/tm/packages/next/miktex-cweb-bin-2.9.tar.lzma +2021/07/31 | 61812 | systems/win32/miktex/tm/packages/next/miktex-cweb-bin-x64-2.9.tar.lzma +2021/07/31 | 21225 | systems/win32/miktex/tm/packages/next/miktex-devnag-bin-2.9.tar.lzma +2021/07/31 | 23365 | systems/win32/miktex/tm/packages/next/miktex-devnag-bin-x64-2.9.tar.lzma +2021/07/31 | 461813 | systems/win32/miktex/tm/packages/next/miktex-doc.tar.lzma +2021/07/31 | 45905 | systems/win32/miktex/tm/packages/next/miktex-dvicopy-bin-2.9.tar.lzma +2021/07/31 | 51201 | systems/win32/miktex/tm/packages/next/miktex-dvicopy-bin-x64-2.9.tar.lzma +2021/07/31 | 284581 | systems/win32/miktex/tm/packages/next/miktex-dvipdfmx-bin-2.9.tar.lzma +2021/07/31 | 325043 | systems/win32/miktex/tm/packages/next/miktex-dvipdfmx-bin-x64-2.9.tar.lzma +2021/07/31 | 41194 | systems/win32/miktex/tm/packages/next/miktex-dvipng-bin-2.9.tar.lzma +2021/07/31 | 45311 | systems/win32/miktex/tm/packages/next/miktex-dvipng-bin-x64-2.9.tar.lzma +2021/07/31 | 119819 | systems/win32/miktex/tm/packages/next/miktex-dvips-bin-2.9.tar.lzma +2021/07/31 | 133866 | systems/win32/miktex/tm/packages/next/miktex-dvips-bin-x64-2.9.tar.lzma +2021/07/31 | 1291297 | systems/win32/miktex/tm/packages/next/miktex-dvisvgm-bin-2.9.tar.lzma +2021/07/31 | 1421867 | systems/win32/miktex/tm/packages/next/miktex-dvisvgm-bin-x64-2.9.tar.lzma +2021/07/31 | 100625 | systems/win32/miktex/tm/packages/next/miktex-epstopdf-bin-2.9.tar.lzma +2021/07/31 | 112983 | systems/win32/miktex/tm/packages/next/miktex-epstopdf-bin-x64-2.9.tar.lzma +2021/07/31 | 43028 | systems/win32/miktex/tm/packages/next/miktex-expat-bin-2.9.tar.lzma +2021/07/31 | 48252 | systems/win32/miktex/tm/packages/next/miktex-expat-bin-x64-2.9.tar.lzma +2021/07/31 | 25021 | systems/win32/miktex/tm/packages/next/miktex-findtexmf-bin-2.9.tar.lzma +2021/07/31 | 28180 | systems/win32/miktex/tm/packages/next/miktex-findtexmf-bin-x64-2.9.tar.lzma +2021/07/31 | 56318 | systems/win32/miktex/tm/packages/next/miktex-fmt-bin-2.9.tar.lzma +2021/07/31 | 62786 | systems/win32/miktex/tm/packages/next/miktex-fmt-bin-x64-2.9.tar.lzma +2021/07/31 | 136817 | systems/win32/miktex/tm/packages/next/miktex-fontconfig-bin-2.9.tar.lzma +2021/07/31 | 154426 | systems/win32/miktex/tm/packages/next/miktex-fontconfig-bin-x64-2.9.tar.lzma +2021/07/31 | 73196 | systems/win32/miktex/tm/packages/next/miktex-fonts-bin-2.9.tar.lzma +2021/07/31 | 77952 | systems/win32/miktex/tm/packages/next/miktex-fonts-bin-x64-2.9.tar.lzma +2021/07/31 | 71668 | systems/win32/miktex/tm/packages/next/miktex-freeglut-bin-2.9.tar.lzma +2021/07/31 | 80451 | systems/win32/miktex/tm/packages/next/miktex-freeglut-bin-x64-2.9.tar.lzma +2021/07/31 | 258881 | systems/win32/miktex/tm/packages/next/miktex-freetype2-bin-2.9.tar.lzma +2021/07/31 | 295204 | systems/win32/miktex/tm/packages/next/miktex-freetype2-bin-x64-2.9.tar.lzma +2021/07/31 | 22050 | systems/win32/miktex/tm/packages/next/miktex-fribidixetex-bin-2.9.tar.lzma +2021/07/31 | 24996 | systems/win32/miktex/tm/packages/next/miktex-fribidixetex-bin-x64-2.9.tar.lzma +2021/07/31 | 97339 | systems/win32/miktex/tm/packages/next/miktex-gd-bin-2.9.tar.lzma +2021/07/31 | 112087 | systems/win32/miktex/tm/packages/next/miktex-gd-bin-x64-2.9.tar.lzma +2021/07/31 | 64426 | systems/win32/miktex/tm/packages/next/miktex-graphite2-bin-2.9.tar.lzma +2021/07/31 | 73148 | systems/win32/miktex/tm/packages/next/miktex-graphite2-bin-x64-2.9.tar.lzma +2021/07/31 | 96633 | systems/win32/miktex/tm/packages/next/miktex-gregorio-bin-2.9.tar.lzma +2021/07/31 | 115352 | systems/win32/miktex/tm/packages/next/miktex-gregorio-bin-x64-2.9.tar.lzma +2021/07/31 | 38141 | systems/win32/miktex/tm/packages/next/miktex-gsf2pk-bin-2.9.tar.lzma +2021/07/31 | 43003 | systems/win32/miktex/tm/packages/next/miktex-gsf2pk-bin-x64-2.9.tar.lzma +2021/07/31 | 483653 | systems/win32/miktex/tm/packages/next/miktex-harfbuzz-bin-2.9.tar.lzma +2021/07/31 | 566528 | systems/win32/miktex/tm/packages/next/miktex-harfbuzz-bin-x64-2.9.tar.lzma +2021/07/31 | 147370 | systems/win32/miktex/tm/packages/next/miktex-hunspell-bin-2.9.tar.lzma +2021/07/31 | 159579 | systems/win32/miktex/tm/packages/next/miktex-hunspell-bin-x64-2.9.tar.lzma +2021/07/31 | 94798 | systems/win32/miktex/tm/packages/next/miktex-jpeg-bin-2.9.tar.lzma +2021/07/31 | 109031 | systems/win32/miktex/tm/packages/next/miktex-jpeg-bin-x64-2.9.tar.lzma +2021/07/31 | 16356 | systems/win32/miktex/tm/packages/next/miktex-kpathsea-bin-2.9.tar.lzma +2021/07/31 | 17980 | systems/win32/miktex/tm/packages/next/miktex-kpathsea-bin-x64-2.9.tar.lzma +2021/07/31 | 28389 | systems/win32/miktex/tm/packages/next/miktex-lacheck-bin-2.9.tar.lzma +2021/07/31 | 30058 | systems/win32/miktex/tm/packages/next/miktex-lacheck-bin-x64-2.9.tar.lzma +2021/07/31 | 629399 | systems/win32/miktex/tm/packages/next/miktex-lcdf-typetools-bin-2.9.tar.lzma +2021/07/31 | 681252 | systems/win32/miktex/tm/packages/next/miktex-lcdf-typetools-bin-x64-2.9.tar.lzma +2021/07/31 | 531849 | systems/win32/miktex/tm/packages/next/miktex-libressl-bin-2.9.tar.lzma +2021/07/31 | 596929 | systems/win32/miktex/tm/packages/next/miktex-libressl-bin-x64-2.9.tar.lzma +2021/07/31 | 476922 | systems/win32/miktex/tm/packages/next/miktex-log4cxx-bin-2.9.tar.lzma +2021/07/31 | 510587 | systems/win32/miktex/tm/packages/next/miktex-log4cxx-bin-x64-2.9.tar.lzma +2021/07/31 | 94310 | systems/win32/miktex/tm/packages/next/miktex-lua53-bin-2.9.tar.lzma +2021/07/31 | 103400 | systems/win32/miktex/tm/packages/next/miktex-lua53-bin-x64-2.9.tar.lzma +2021/07/31 | 1713892 | systems/win32/miktex/tm/packages/next/miktex-luatex-bin-2.9.tar.lzma +2021/07/31 | 2009905 | systems/win32/miktex/tm/packages/next/miktex-luatex-bin-x64-2.9.tar.lzma +2021/07/31 | 67619 | systems/win32/miktex/tm/packages/next/miktex-lzma-bin-2.9.tar.lzma +2021/07/31 | 74210 | systems/win32/miktex/tm/packages/next/miktex-lzma-bin-x64-2.9.tar.lzma +2021/07/31 | 27358 | systems/win32/miktex/tm/packages/next/miktex-makeindex-bin-2.9.tar.lzma +2021/07/31 | 31620 | systems/win32/miktex/tm/packages/next/miktex-makeindex-bin-x64-2.9.tar.lzma +2021/07/31 | 7722 | systems/win32/miktex/tm/packages/next/miktex-md5-bin-2.9.tar.lzma +2021/07/31 | 8768 | systems/win32/miktex/tm/packages/next/miktex-md5-bin-x64-2.9.tar.lzma +2021/07/31 | 196872 | systems/win32/miktex/tm/packages/next/miktex-metafont-bin-2.9.tar.lzma +2021/07/31 | 215249 | systems/win32/miktex/tm/packages/next/miktex-metafont-bin-x64-2.9.tar.lzma +2021/07/31 | 250266 | systems/win32/miktex/tm/packages/next/miktex-metapost-bin-2.9.tar.lzma +2021/07/31 | 284025 | systems/win32/miktex/tm/packages/next/miktex-metapost-bin-x64-2.9.tar.lzma +2021/07/31 | 98380 | systems/win32/miktex/tm/packages/next/miktex-mfware-bin-2.9.tar.lzma +2021/07/31 | 103203 | systems/win32/miktex/tm/packages/next/miktex-mfware-bin-x64-2.9.tar.lzma +2021/07/31 | 60638 | systems/win32/miktex/tm/packages/next/miktex-mkfntmap-bin-2.9.tar.lzma +2021/07/31 | 68024 | systems/win32/miktex/tm/packages/next/miktex-mkfntmap-bin-x64-2.9.tar.lzma +2021/07/31 | 124282 | systems/win32/miktex/tm/packages/next/miktex-mktex-bin-2.9.tar.lzma +2021/07/31 | 136822 | systems/win32/miktex/tm/packages/next/miktex-mktex-bin-x64-2.9.tar.lzma +2021/07/31 | 178354 | systems/win32/miktex/tm/packages/next/miktex-mo-bin-2.9.tar.lzma +2021/07/31 | 196741 | systems/win32/miktex/tm/packages/next/miktex-mo-bin-x64-2.9.tar.lzma +2021/07/31 | 199733 | systems/win32/miktex/tm/packages/next/miktex-mpfr-bin-2.9.tar.lzma +2021/07/31 | 180121 | systems/win32/miktex/tm/packages/next/miktex-mpfr-bin-x64-2.9.tar.lzma +2021/07/31 | 67484 | systems/win32/miktex/tm/packages/next/miktex-mpmcli-bin-2.9.tar.lzma +2021/07/31 | 76825 | systems/win32/miktex/tm/packages/next/miktex-mpmcli-bin-x64-2.9.tar.lzma +2021/07/31 | 31231 | systems/win32/miktex/tm/packages/next/miktex-mspack-bin-2.9.tar.lzma +2021/07/31 | 35087 | systems/win32/miktex/tm/packages/next/miktex-mspack-bin-x64-2.9.tar.lzma +2021/07/31 | 37805 | systems/win32/miktex/tm/packages/next/miktex-mthelp-bin-2.9.tar.lzma +2021/07/31 | 42712 | systems/win32/miktex/tm/packages/next/miktex-mthelp-bin-x64-2.9.tar.lzma +2021/07/31 | 42892 | systems/win32/miktex/tm/packages/next/miktex-mtprint-bin-2.9.tar.lzma +2021/07/31 | 46907 | systems/win32/miktex/tm/packages/next/miktex-mtprint-bin-x64-2.9.tar.lzma +2021/07/31 | 45969 | systems/win32/miktex/tm/packages/next/miktex-m-tx-bin-2.9.tar.lzma +2021/07/31 | 52523 | systems/win32/miktex/tm/packages/next/miktex-m-tx-bin-x64-2.9.tar.lzma +2021/07/31 | 194382 | systems/win32/miktex/tm/packages/next/miktex-omegaware-bin-2.9.tar.lzma +2021/07/31 | 206604 | systems/win32/miktex/tm/packages/next/miktex-omegaware-bin-x64-2.9.tar.lzma +2021/07/31 | 35691 | systems/win32/miktex/tm/packages/next/miktex-patgen-bin.tar.lzma +2021/07/31 | 40229 | systems/win32/miktex/tm/packages/next/miktex-patgen-bin-x64.tar.lzma +2021/07/31 | 744117 | systems/win32/miktex/tm/packages/next/miktex-pdftex-bin-2.9.tar.lzma +2021/07/31 | 815242 | systems/win32/miktex/tm/packages/next/miktex-pdftex-bin-x64-2.9.tar.lzma +2021/07/31 | 198170 | systems/win32/miktex/tm/packages/next/miktex-pixman-bin-2.9.tar.lzma +2021/07/31 | 202797 | systems/win32/miktex/tm/packages/next/miktex-pixman-bin-x64-2.9.tar.lzma +2021/07/31 | 208048 | systems/win32/miktex/tm/packages/next/miktex-pmx-bin-2.9.tar.lzma +2021/07/31 | 243426 | systems/win32/miktex/tm/packages/next/miktex-pmx-bin-x64-2.9.tar.lzma +2021/07/31 | 78774 | systems/win32/miktex/tm/packages/next/miktex-png-bin-2.9.tar.lzma +2021/07/31 | 87777 | systems/win32/miktex/tm/packages/next/miktex-png-bin-x64-2.9.tar.lzma +2021/07/31 | 1169718 | systems/win32/miktex/tm/packages/next/miktex-poppler-bin-2.9.tar.lzma +2021/07/31 | 1301190 | systems/win32/miktex/tm/packages/next/miktex-poppler-bin-x64-2.9.tar.lzma +2021/07/31 | 20137 | systems/win32/miktex/tm/packages/next/miktex-popt-bin-2.9.tar.lzma +2021/07/31 | 23903 | systems/win32/miktex/tm/packages/next/miktex-popt-bin-x64-2.9.tar.lzma +2021/07/31 | 31540 | systems/win32/miktex/tm/packages/next/miktex-posix-bin-2.9.tar.lzma +2021/07/31 | 37239 | systems/win32/miktex/tm/packages/next/miktex-posix-bin-x64-2.9.tar.lzma +2021/07/31 | 64184 | systems/win32/miktex/tm/packages/next/miktex-ps2pk-bin-2.9.tar.lzma +2021/07/31 | 72207 | systems/win32/miktex/tm/packages/next/miktex-ps2pk-bin-x64-2.9.tar.lzma +2021/07/31 | 50394 | systems/win32/miktex/tm/packages/next/miktex-psutils-bin-2.9.tar.lzma +2021/07/31 | 57727 | systems/win32/miktex/tm/packages/next/miktex-psutils-bin-x64-2.9.tar.lzma +2021/07/31 | 1340931 | systems/win32/miktex/tm/packages/next/miktex-runtime-bin-2.9.tar.lzma +2021/07/31 | 1464203 | systems/win32/miktex/tm/packages/next/miktex-runtime-bin-x64-2.9.tar.lzma +2021/07/31 | 42386 | systems/win32/miktex/tm/packages/next/miktex-synctex-bin-2.9.tar.lzma +2021/07/31 | 51751 | systems/win32/miktex/tm/packages/next/miktex-synctex-bin-x64-2.9.tar.lzma +2021/07/31 | 56514 | systems/win32/miktex/tm/packages/next/miktex-tdsutil-bin.tar.lzma +2021/07/31 | 60039 | systems/win32/miktex/tm/packages/next/miktex-tdsutil-bin-x64.tar.lzma +2021/07/31 | 25291 | systems/win32/miktex/tm/packages/next/miktex-teckit-bin-2.9.tar.lzma +2021/07/31 | 27390 | systems/win32/miktex/tm/packages/next/miktex-teckit-bin-x64-2.9.tar.lzma +2021/07/31 | 16413 | systems/win32/miktex/tm/packages/next/miktex-tex2xindy-bin-2.9.tar.lzma +2021/07/31 | 18177 | systems/win32/miktex/tm/packages/next/miktex-tex2xindy-bin-x64-2.9.tar.lzma +2021/07/31 | 63777 | systems/win32/miktex/tm/packages/next/miktex-tex4ht-bin-2.9.tar.lzma +2021/07/31 | 69914 | systems/win32/miktex/tm/packages/next/miktex-tex4ht-bin-x64-2.9.tar.lzma +2021/07/31 | 154803 | systems/win32/miktex/tm/packages/next/miktex-tex-bin-2.9.tar.lzma +2021/07/31 | 169242 | systems/win32/miktex/tm/packages/next/miktex-tex-bin-x64-2.9.tar.lzma +2021/07/31 | 57012 | systems/win32/miktex/tm/packages/next/miktex-texify-bin-2.9.tar.lzma +2021/07/31 | 65787 | systems/win32/miktex/tm/packages/next/miktex-texify-bin-x64-2.9.tar.lzma +2021/07/31 | 98261 | systems/win32/miktex/tm/packages/next/miktex-texware-bin-2.9.tar.lzma +2021/07/31 | 105222 | systems/win32/miktex/tm/packages/next/miktex-texware-bin-x64-2.9.tar.lzma +2021/07/31 | 2672608 | systems/win32/miktex/tm/packages/next/miktex-texworks-bin-2.9.tar.lzma +2021/07/31 | 2796724 | systems/win32/miktex/tm/packages/next/miktex-texworks-bin-x64-2.9.tar.lzma +2021/07/31 | 56355 | systems/win32/miktex/tm/packages/next/miktex-ttf2pk2-bin-2.9.tar.lzma +2021/07/31 | 62229 | systems/win32/miktex/tm/packages/next/miktex-ttf2pk2-bin-x64-2.9.tar.lzma +2021/07/31 | 33544 | systems/win32/miktex/tm/packages/next/miktex-upmendex-bin.tar.lzma +2021/07/31 | 37357 | systems/win32/miktex/tm/packages/next/miktex-upmendex-bin-x64.tar.lzma +2021/07/31 | 27727 | systems/win32/miktex/tm/packages/next/miktex-uriparser-bin-2.9.tar.lzma +2021/07/31 | 33632 | systems/win32/miktex/tm/packages/next/miktex-uriparser-bin-x64-2.9.tar.lzma +2021/07/31 | 65618 | systems/win32/miktex/tm/packages/next/miktex-web-bin-2.9.tar.lzma +2021/07/31 | 70646 | systems/win32/miktex/tm/packages/next/miktex-web-bin-x64-2.9.tar.lzma +2021/07/31 | 312106 | systems/win32/miktex/tm/packages/next/miktex-xetex-bin-2.9.tar.lzma +2021/07/31 | 345738 | systems/win32/miktex/tm/packages/next/miktex-xetex-bin-x64-2.9.tar.lzma +2021/07/31 | 55496 | systems/win32/miktex/tm/packages/next/miktex-xml2pmx-bin.tar.lzma +2021/07/31 | 57139 | systems/win32/miktex/tm/packages/next/miktex-xml2pmx-bin-x64.tar.lzma +2021/07/31 | 589843 | systems/win32/miktex/tm/packages/next/miktex-yap-bin-2.9.tar.lzma +2021/07/31 | 624655 | systems/win32/miktex/tm/packages/next/miktex-yap-bin-x64-2.9.tar.lzma +2021/07/31 | 39127 | systems/win32/miktex/tm/packages/next/miktex-zlib-bin-2.9.tar.lzma +2021/07/31 | 43423 | systems/win32/miktex/tm/packages/next/miktex-zlib-bin-x64-2.9.tar.lzma +2021/07/31 | 231912 | systems/win32/miktex/tm/packages/next/miktex-zzdb1-2.9.tar.lzma +2021/07/31 | 1320701 | systems/win32/miktex/tm/packages/next/miktex-zzdb2-2.9.tar.lzma +2021/07/31 | 1228758 | systems/win32/miktex/tm/packages/next/miktex-zzdb3-2.9.tar.lzma +2021/07/31 | 13463 | systems/win32/miktex/tm/packages/next/miktex-zzip-bin-2.9.tar.lzma +2021/07/31 | 14347 | systems/win32/miktex/tm/packages/next/miktex-zzip-bin-x64-2.9.tar.lzma 2019/03/12 | 1412 | systems/win32/miktex/tm/packages/nextpage.tar.lzma -2021/07/30 | 1153 | systems/win32/miktex/tm/packages/next/pr.ini +2021/07/31 | 1153 | systems/win32/miktex/tm/packages/next/pr.ini 2018/07/06 | 145915 | systems/win32/miktex/tm/packages/nexus-otf.tar.lzma 2017/03/30 | 191149 | systems/win32/miktex/tm/packages/nfssext-cfr.tar.lzma 2012/12/20 | 612251 | systems/win32/miktex/tm/packages/nicefilelist.tar.lzma @@ -286151,7 +286161,7 @@ 2020/10/20 | 342254 | systems/win32/miktex/tm/packages/preview.tar.lzma 2019/06/20 | 375963 | systems/win32/miktex/tm/packages/prftree.tar.lzma 2021/04/23 | 274028 | systems/win32/miktex/tm/packages/principia.tar.lzma -2021/07/30 | 894 | systems/win32/miktex/tm/packages/pr.ini +2021/07/31 | 894 | systems/win32/miktex/tm/packages/pr.ini 2010/09/27 | 248469 | systems/win32/miktex/tm/packages/printlen.tar.lzma 2008/06/17 | 77313 | systems/win32/miktex/tm/packages/proba.tar.lzma 2017/07/12 | 988486 | systems/win32/miktex/tm/packages/probsoln.tar.lzma @@ -287561,7 +287571,7 @@ 2004/06/04 | 404 | tds/tds.sed 2004/06/23 | 65418 | tds/tds.tex 2019/05/29 | 304264 | tds.zip -2021/07/31 | 186 | timestamp +2021/08/01 | 186 | timestamp 2002/08/26 | 61898 | usergrps/dante/antrag.pdf 2002/08/26 | 118217 | usergrps/dante/antrag.ps 2017/06/30 | 917 | usergrps/dante/dtk/doc/beispiel.bib diff --git a/FILES.byname.gz b/FILES.byname.gz index f1ea214065..092bd76301 100644 Binary files a/FILES.byname.gz and b/FILES.byname.gz differ diff --git a/FILES.last07days b/FILES.last07days index 016d5587df..2af8403369 100644 --- a/FILES.last07days +++ b/FILES.last07days @@ -1,239 +1,423 @@ +2021/08/01 | 744469 | info/install-latex-guide-zh-cn/install-latex-guide-zh-cn.pdf +2021/07/31 | 98380 | systems/win32/miktex/tm/packages/next/miktex-mfware-bin-2.9.tar.lzma +2021/07/31 | 98261 | systems/win32/miktex/tm/packages/next/miktex-texware-bin-2.9.tar.lzma +2021/07/31 | 9803909 | support/latexindent/latexindent.exe +2021/07/31 | 975018 | systems/win32/miktex/tm/packages/next/miktex-asymptote-bin-2.9.tar.lzma +2021/07/31 | 97339 | systems/win32/miktex/tm/packages/next/miktex-gd-bin-2.9.tar.lzma +2021/07/31 | 96633 | systems/win32/miktex/tm/packages/next/miktex-gregorio-bin-2.9.tar.lzma +2021/07/31 | 9541 | support/latexindent/LatexIndent/IfElseFi.pm +2021/07/31 | 95402 | systems/win32/miktex/tm/packages/next/miktex-bibtex8bit-bin-x64-2.9.tar.lzma +2021/07/31 | 949988 | support/latexindent/documentation/latexindent.pdf +2021/07/31 | 948089 | macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.pdf +2021/07/31 | 94798 | systems/win32/miktex/tm/packages/next/miktex-jpeg-bin-2.9.tar.lzma +2021/07/31 | 94310 | systems/win32/miktex/tm/packages/next/miktex-lua53-bin-2.9.tar.lzma +2021/07/31 | 894 | systems/win32/miktex/tm/packages/pr.ini +2021/07/31 | 88494 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.pdf +2021/07/31 | 87777 | systems/win32/miktex/tm/packages/next/miktex-png-bin-x64-2.9.tar.lzma +2021/07/31 | 8768 | systems/win32/miktex/tm/packages/next/miktex-md5-bin-x64-2.9.tar.lzma +2021/07/31 | 83540 | systems/win32/miktex/tm/packages/next/miktex-bibtex8bit-bin-2.9.tar.lzma +2021/07/31 | 833 | support/latexindent/LatexIndent/Version.pm +2021/07/31 | 815242 | systems/win32/miktex/tm/packages/next/miktex-pdftex-bin-x64-2.9.tar.lzma +2021/07/31 | 80451 | systems/win32/miktex/tm/packages/next/miktex-freeglut-bin-x64-2.9.tar.lzma +2021/07/31 | 7969 | support/latexindent/documentation/sec-introduction.tex +2021/07/31 | 7881 | support/latexindent/LatexIndent/LogFile.pm +2021/07/31 | 78774 | systems/win32/miktex/tm/packages/next/miktex-png-bin-2.9.tar.lzma +2021/07/31 | 783736 | info/install-latex-guide-zh-cn.zip +2021/07/31 | 77952 | systems/win32/miktex/tm/packages/next/miktex-fonts-bin-x64-2.9.tar.lzma +2021/07/31 | 77401 | macros/latex/contrib/hvlogos.zip +2021/07/31 | 7728 | macros/latex/contrib/pdfmanagement-testphase/color-ltx.sty +2021/07/31 | 7722 | systems/win32/miktex/tm/packages/next/miktex-md5-bin-2.9.tar.lzma +2021/07/31 | 76825 | systems/win32/miktex/tm/packages/next/miktex-mpmcli-bin-x64-2.9.tar.lzma +2021/07/31 | 75793 | systems/win32/miktex/tm/packages/next/miktex-bibtex-bin-x64-2.9.tar.lzma +2021/07/31 | 744117 | systems/win32/miktex/tm/packages/next/miktex-pdftex-bin-2.9.tar.lzma +2021/07/31 | 74210 | systems/win32/miktex/tm/packages/next/miktex-lzma-bin-x64-2.9.tar.lzma +2021/07/31 | 739256 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield.pdf +2021/07/31 | 73196 | systems/win32/miktex/tm/packages/next/miktex-fonts-bin-2.9.tar.lzma +2021/07/31 | 73148 | systems/win32/miktex/tm/packages/next/miktex-graphite2-bin-x64-2.9.tar.lzma +2021/07/31 | 7234 | support/latexindent/documentation/subsubsec-no-add-remaining-code-blocks.tex +2021/07/31 | 72207 | systems/win32/miktex/tm/packages/next/miktex-ps2pk-bin-x64-2.9.tar.lzma +2021/07/31 | 71668 | systems/win32/miktex/tm/packages/next/miktex-freeglut-bin-2.9.tar.lzma +2021/07/31 | 7161 | support/latexindent/documentation/figure-schematic.png +2021/07/31 | 70646 | systems/win32/miktex/tm/packages/next/miktex-web-bin-x64-2.9.tar.lzma +2021/07/31 | 69914 | systems/win32/miktex/tm/packages/next/miktex-tex4ht-bin-x64-2.9.tar.lzma +2021/07/31 | 68758 | support/latexindent/documentation/sec-default-user-local.tex +2021/07/31 | 681252 | systems/win32/miktex/tm/packages/next/miktex-lcdf-typetools-bin-x64-2.9.tar.lzma +2021/07/31 | 68024 | systems/win32/miktex/tm/packages/next/miktex-mkfntmap-bin-x64-2.9.tar.lzma +2021/07/31 | 6793 | support/latexindent/LatexIndent/MandatoryArgument.pm +2021/07/31 | 67821 | systems/win32/miktex/tm/packages/next/miktex-bibtex-bin-2.9.tar.lzma +2021/07/31 | 67782 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield.dtx +2021/07/31 | 67619 | systems/win32/miktex/tm/packages/next/miktex-lzma-bin-2.9.tar.lzma +2021/07/31 | 67484 | systems/win32/miktex/tm/packages/next/miktex-mpmcli-bin-2.9.tar.lzma +2021/07/31 | 673135 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.pdf +2021/07/31 | 663896 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.pdf +2021/07/31 | 66280 | support/latexindent/documentation/subsec-poly-switches.tex +2021/07/31 | 6589 | support/latexindent/LatexIndent/FileExtension.pm +2021/07/31 | 65787 | systems/win32/miktex/tm/packages/next/miktex-texify-bin-x64-2.9.tar.lzma +2021/07/31 | 65618 | systems/win32/miktex/tm/packages/next/miktex-web-bin-2.9.tar.lzma +2021/07/31 | 6549 | macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.dtx +2021/07/31 | 64426 | systems/win32/miktex/tm/packages/next/miktex-graphite2-bin-2.9.tar.lzma +2021/07/31 | 64184 | systems/win32/miktex/tm/packages/next/miktex-ps2pk-bin-2.9.tar.lzma +2021/07/31 | 6408 | support/latexindent/LatexIndent/Item.pm +2021/07/31 | 6385 | support/latexindent/LatexIndent/TrailingComments.pm +2021/07/31 | 63777 | systems/win32/miktex/tm/packages/next/miktex-tex4ht-bin-2.9.tar.lzma +2021/07/31 | 6335 | support/latexindent/LatexIndent/Environment.pm +2021/07/31 | 63320 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.dtx +2021/07/31 | 629399 | systems/win32/miktex/tm/packages/next/miktex-lcdf-typetools-bin-2.9.tar.lzma +2021/07/31 | 62786 | systems/win32/miktex/tm/packages/next/miktex-fmt-bin-x64-2.9.tar.lzma +2021/07/31 | 624655 | systems/win32/miktex/tm/packages/next/miktex-yap-bin-x64-2.9.tar.lzma +2021/07/31 | 62229 | systems/win32/miktex/tm/packages/next/miktex-ttf2pk2-bin-x64-2.9.tar.lzma +2021/07/31 | 61812 | systems/win32/miktex/tm/packages/next/miktex-cweb-bin-x64-2.9.tar.lzma +2021/07/31 | 61612 | support/latexindent/LatexIndent/AlignmentAtAmpersand.pm +2021/07/31 | 60638 | systems/win32/miktex/tm/packages/next/miktex-mkfntmap-bin-2.9.tar.lzma +2021/07/31 | 6062 | support/latexindent/LatexIndent/OptionalArgument.pm +2021/07/31 | 6042 | support/latexindent/LatexIndent/BackUpFileProcedure.pm +2021/07/31 | 60039 | systems/win32/miktex/tm/packages/next/miktex-tdsutil-bin-x64.tar.lzma +2021/07/31 | 5992676 | support/latexindent.zip +2021/07/31 | 5979 | support/latexindent/documentation/subsubsec-commands-with-arguments.tex +2021/07/31 | 5969 | support/latexindent/LatexIndent/Else.pm +2021/07/31 | 596929 | systems/win32/miktex/tm/packages/next/miktex-libressl-bin-x64-2.9.tar.lzma +2021/07/31 | 593220 | systems/win32/miktex/tm/packages/next/files.csv.lzma +2021/07/31 | 592787 | systems/win32/miktex/tm/packages/files.csv.lzma +2021/07/31 | 591169 | macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.pdf +2021/07/31 | 589843 | systems/win32/miktex/tm/packages/next/miktex-yap-bin-2.9.tar.lzma +2021/07/31 | 580 | macros/latex/contrib/pdfmanagement-testphase/transparent-ltx.sty +2021/07/31 | 5777 | support/latexindent/LatexIndent/UnNamedGroupingBracesBrackets.pm +2021/07/31 | 577331 | macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.pdf +2021/07/31 | 57727 | systems/win32/miktex/tm/packages/next/miktex-psutils-bin-x64-2.9.tar.lzma +2021/07/31 | 576314 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.pdf +2021/07/31 | 57549 | systems/win32/miktex/tm/packages/next/miktex-bibarts-bin-x64-2.9.tar.lzma +2021/07/31 | 5736 | support/latexindent/documentation/subsec-combine-text-wrap-para-line-breaks.tex +2021/07/31 | 57139 | systems/win32/miktex/tm/packages/next/miktex-xml2pmx-bin-x64.tar.lzma +2021/07/31 | 57012 | systems/win32/miktex/tm/packages/next/miktex-texify-bin-2.9.tar.lzma +2021/07/31 | 56684 | systems/win32/miktex/tm/packages/next/miktex-cjkutils-bin-x64-2.9.tar.lzma +2021/07/31 | 566528 | systems/win32/miktex/tm/packages/next/miktex-harfbuzz-bin-x64-2.9.tar.lzma +2021/07/31 | 56514 | systems/win32/miktex/tm/packages/next/miktex-tdsutil-bin.tar.lzma +2021/07/31 | 56477 | systems/win32/miktex/tm/packages/next/miktex-arctrl-bin-x64-2.9.tar.lzma +2021/07/31 | 56355 | systems/win32/miktex/tm/packages/next/miktex-ttf2pk2-bin-2.9.tar.lzma +2021/07/31 | 56318 | systems/win32/miktex/tm/packages/next/miktex-fmt-bin-2.9.tar.lzma +2021/07/31 | 55632 | macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.dtx +2021/07/31 | 55496 | systems/win32/miktex/tm/packages/next/miktex-xml2pmx-bin.tar.lzma +2021/07/31 | 553330 | macros/latex/contrib/pdfmanagement-testphase/l3pdffile.pdf +2021/07/31 | 547881 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.pdf +2021/07/31 | 54633 | systems/win32/miktex/tm/packages/next/miktex-cweb-bin-2.9.tar.lzma +2021/07/31 | 536935 | macros/latex/contrib/pdfmanagement-testphase/ltdocinit.pdf +2021/07/31 | 534125 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.pdf +2021/07/31 | 531849 | systems/win32/miktex/tm/packages/next/miktex-libressl-bin-2.9.tar.lzma +2021/07/31 | 5312 | support/latexindent/LatexIndent/KeyEqualsValuesBraces.pm +2021/07/31 | 530911 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.pdf +2021/07/31 | 5286 | support/latexindent/documentation/subsubsec-headings.tex +2021/07/31 | 52738 | support/latexindent/LatexIndent/GetYamlSettings.pm +2021/07/31 | 527111 | macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.pdf +2021/07/31 | 526311 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.pdf +2021/07/31 | 52523 | systems/win32/miktex/tm/packages/next/miktex-m-tx-bin-x64-2.9.tar.lzma +2021/07/31 | 518296 | macros/latex/contrib/pdfmanagement-testphase/l3pdftools.pdf +2021/07/31 | 51751 | systems/win32/miktex/tm/packages/next/miktex-synctex-bin-x64-2.9.tar.lzma +2021/07/31 | 51308 | systems/win32/miktex/tm/packages/next/miktex-cjkutils-bin-2.9.tar.lzma +2021/07/31 | 51201 | systems/win32/miktex/tm/packages/next/miktex-dvicopy-bin-x64-2.9.tar.lzma +2021/07/31 | 51113 | systems/win32/miktex/tm/packages/next/miktex-arctrl-bin-2.9.tar.lzma +2021/07/31 | 510587 | systems/win32/miktex/tm/packages/next/miktex-log4cxx-bin-x64-2.9.tar.lzma +2021/07/31 | 505534 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.pdf +2021/07/31 | 50394 | systems/win32/miktex/tm/packages/next/miktex-psutils-bin-2.9.tar.lzma +2021/07/31 | 50152 | systems/win32/miktex/tm/packages/next/miktex-bibarts-bin-2.9.tar.lzma +2021/07/31 | 492 | support/latexindent/documentation/cmhlistings.tex +2021/07/31 | 4873 | support/latexindent/documentation/subsubsec-ifelsefi.tex +2021/07/31 | 483653 | systems/win32/miktex/tm/packages/next/miktex-harfbuzz-bin-2.9.tar.lzma +2021/07/31 | 48252 | systems/win32/miktex/tm/packages/next/miktex-expat-bin-x64-2.9.tar.lzma +2021/07/31 | 4798 | support/latexindent/LatexIndent/BlankLines.pm +2021/07/31 | 476922 | systems/win32/miktex/tm/packages/next/miktex-log4cxx-bin-2.9.tar.lzma +2021/07/31 | 47023 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.tex +2021/07/31 | 46907 | systems/win32/miktex/tm/packages/next/miktex-mtprint-bin-x64-2.9.tar.lzma +2021/07/31 | 4685 | info/install-latex-guide-zh-cn/appendix/updateinfo.tex +2021/07/31 | 461813 | systems/win32/miktex/tm/packages/next/miktex-doc.tar.lzma +2021/07/31 | 4617 | macros/latex/contrib/pdfmanagement-testphase/xcolor-patches-tmp-ltx.sty +2021/07/31 | 45969 | systems/win32/miktex/tm/packages/next/miktex-m-tx-bin-2.9.tar.lzma +2021/07/31 | 45905 | systems/win32/miktex/tm/packages/next/miktex-dvicopy-bin-2.9.tar.lzma +2021/07/31 | 4570 | macros/latex/contrib/pdfmanagement-testphase/CHANGELOG.md +2021/07/31 | 45311 | systems/win32/miktex/tm/packages/next/miktex-dvipng-bin-x64-2.9.tar.lzma +2021/07/31 | 446355 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.pdf +2021/07/31 | 44096 | support/latexindent/documentation/logo.png +2021/07/31 | 4355 | support/latexindent/LatexIndent/RoundBrackets.pm +2021/07/31 | 43423 | systems/win32/miktex/tm/packages/next/miktex-zlib-bin-x64-2.9.tar.lzma +2021/07/31 | 43028 | systems/win32/miktex/tm/packages/next/miktex-expat-bin-2.9.tar.lzma +2021/07/31 | 43003 | systems/win32/miktex/tm/packages/next/miktex-gsf2pk-bin-x64-2.9.tar.lzma +2021/07/31 | 42892 | systems/win32/miktex/tm/packages/next/miktex-mtprint-bin-2.9.tar.lzma +2021/07/31 | 4284 | support/latexindent/LatexIndent/NamedGroupingBracesBrackets.pm +2021/07/31 | 42712 | systems/win32/miktex/tm/packages/next/miktex-mthelp-bin-x64-2.9.tar.lzma +2021/07/31 | 42386 | systems/win32/miktex/tm/packages/next/miktex-synctex-bin-2.9.tar.lzma +2021/07/31 | 421483 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.pdf +2021/07/31 | 4212 | macros/latex/contrib/pdfmanagement-testphase/hyperxmp-patches-tmp-ltx.sty +2021/07/31 | 418329 | macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.pdf +2021/07/31 | 41194 | systems/win32/miktex/tm/packages/next/miktex-dvipng-bin-2.9.tar.lzma +2021/07/31 | 40229 | systems/win32/miktex/tm/packages/next/miktex-patgen-bin-x64.tar.lzma +2021/07/31 | 392793 | systems/win32/miktex/tm/packages/next/miktex-cairo-bin-x64-2.9.tar.lzma +2021/07/31 | 39127 | systems/win32/miktex/tm/packages/next/miktex-zlib-bin-2.9.tar.lzma +2021/07/31 | 3850 | support/latexindent/documentation/subsubsec-special.tex +2021/07/31 | 38141 | systems/win32/miktex/tm/packages/next/miktex-gsf2pk-bin-2.9.tar.lzma +2021/07/31 | 37805 | systems/win32/miktex/tm/packages/next/miktex-mthelp-bin-2.9.tar.lzma +2021/07/31 | 37357 | systems/win32/miktex/tm/packages/next/miktex-upmendex-bin-x64.tar.lzma +2021/07/31 | 37239 | systems/win32/miktex/tm/packages/next/miktex-posix-bin-x64-2.9.tar.lzma +2021/07/31 | 36629 | systems/win32/miktex/tm/packages/next/miktex-chktex-bin-x64-2.9.tar.lzma +2021/07/31 | 3618 | support/latexindent/LatexIndent/Replacement.pm +2021/07/31 | 35691 | systems/win32/miktex/tm/packages/next/miktex-patgen-bin.tar.lzma +2021/07/31 | 3542 | macros/latex/contrib/exam-randomizechoices/README.md +2021/07/31 | 35087 | systems/win32/miktex/tm/packages/next/miktex-mspack-bin-x64-2.9.tar.lzma +2021/07/31 | 34666 | systems/win32/miktex/tm/packages/next/miktex-axohelp-bin-x64-2.9.tar.lzma +2021/07/31 | 3463 | support/latexindent/LatexIndent/Preamble.pm +2021/07/31 | 345738 | systems/win32/miktex/tm/packages/next/miktex-xetex-bin-x64-2.9.tar.lzma +2021/07/31 | 3450 | support/latexindent/documentation/subsubsec-environments-with-items.tex +2021/07/31 | 3394 | support/latexindent/LatexIndent/HorizontalWhiteSpace.pm +2021/07/31 | 33632 | systems/win32/miktex/tm/packages/next/miktex-uriparser-bin-x64-2.9.tar.lzma +2021/07/31 | 33544 | systems/win32/miktex/tm/packages/next/miktex-upmendex-bin.tar.lzma +2021/07/31 | 330787 | systems/win32/miktex/tm/packages/next/miktex-cairo-bin-2.9.tar.lzma +2021/07/31 | 3273 | support/latexindent/LatexIndent/Tokens.pm +2021/07/31 | 32674 | systems/win32/miktex/tm/packages/next/miktex-chktex-bin-2.9.tar.lzma +2021/07/31 | 325043 | systems/win32/miktex/tm/packages/next/miktex-dvipdfmx-bin-x64-2.9.tar.lzma +2021/07/31 | 320254 | macros/latex/contrib/exam-randomizechoices.zip +2021/07/31 | 31620 | systems/win32/miktex/tm/packages/next/miktex-makeindex-bin-x64-2.9.tar.lzma +2021/07/31 | 31540 | systems/win32/miktex/tm/packages/next/miktex-posix-bin-2.9.tar.lzma +2021/07/31 | 31352 | systems/win32/miktex/tm/packages/next/miktex-autosp-bin-x64-2.9.tar.lzma +2021/07/31 | 31231 | systems/win32/miktex/tm/packages/next/miktex-mspack-bin-2.9.tar.lzma +2021/07/31 | 312106 | systems/win32/miktex/tm/packages/next/miktex-xetex-bin-2.9.tar.lzma +2021/07/31 | 30823 | systems/win32/miktex/tm/packages/next/miktex-bzip2-bin-x64-2.9.tar.lzma +2021/07/31 | 3075 | support/latexindent/documentation/sec-the-m-switch.tex +2021/07/31 | 30568 | macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.dtx +2021/07/31 | 30058 | systems/win32/miktex/tm/packages/next/miktex-lacheck-bin-x64-2.9.tar.lzma +2021/07/31 | 29840 | systems/win32/miktex/tm/packages/next/miktex-axohelp-bin-2.9.tar.lzma +2021/07/31 | 295204 | systems/win32/miktex/tm/packages/next/miktex-freetype2-bin-x64-2.9.tar.lzma +2021/07/31 | 29035 | systems/win32/miktex/tm/packages/next/miktex-autosp-bin-2.9.tar.lzma +2021/07/31 | 284581 | systems/win32/miktex/tm/packages/next/miktex-dvipdfmx-bin-2.9.tar.lzma +2021/07/31 | 284025 | systems/win32/miktex/tm/packages/next/miktex-metapost-bin-x64-2.9.tar.lzma +2021/07/31 | 28389 | systems/win32/miktex/tm/packages/next/miktex-lacheck-bin-2.9.tar.lzma +2021/07/31 | 28180 | systems/win32/miktex/tm/packages/next/miktex-findtexmf-bin-x64-2.9.tar.lzma +2021/07/31 | 28041 | macros/latex/contrib/pdfmanagement-testphase/l3pdffile.dtx +2021/07/31 | 2796724 | systems/win32/miktex/tm/packages/next/miktex-texworks-bin-x64-2.9.tar.lzma +2021/07/31 | 27837 | macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.dtx +2021/07/31 | 27727 | systems/win32/miktex/tm/packages/next/miktex-uriparser-bin-2.9.tar.lzma +2021/07/31 | 27438 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.dtx +2021/07/31 | 27390 | systems/win32/miktex/tm/packages/next/miktex-teckit-bin-x64-2.9.tar.lzma +2021/07/31 | 27358 | systems/win32/miktex/tm/packages/next/miktex-makeindex-bin-2.9.tar.lzma +2021/07/31 | 27199 | systems/win32/miktex/tm/packages/next/miktex-bzip2-bin-2.9.tar.lzma +2021/07/31 | 2672608 | systems/win32/miktex/tm/packages/next/miktex-texworks-bin-2.9.tar.lzma +2021/07/31 | 26672 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.dtx +2021/07/31 | 26662 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.dtx +2021/07/31 | 2645 | support/latexindent/latexindent.pl +2021/07/31 | 263957 | systems/win32/miktex/tm/packages/next/miktex-console-bin-x64-2.9.tar.lzma +2021/07/31 | 258881 | systems/win32/miktex/tm/packages/next/miktex-freetype2-bin-2.9.tar.lzma +2021/07/31 | 25321 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.tex +2021/07/31 | 25291 | systems/win32/miktex/tm/packages/next/miktex-teckit-bin-2.9.tar.lzma +2021/07/31 | 250266 | systems/win32/miktex/tm/packages/next/miktex-metapost-bin-2.9.tar.lzma +2021/07/31 | 25021 | systems/win32/miktex/tm/packages/next/miktex-findtexmf-bin-2.9.tar.lzma +2021/07/31 | 24996 | systems/win32/miktex/tm/packages/next/miktex-fribidixetex-bin-x64-2.9.tar.lzma +2021/07/31 | 246 | support/latexindent/documentation/references.tex +2021/07/31 | 243426 | systems/win32/miktex/tm/packages/next/miktex-pmx-bin-x64-2.9.tar.lzma +2021/07/31 | 241811 | systems/win32/miktex/tm/packages/next/miktex-console-bin-2.9.tar.lzma +2021/07/31 | 23932 | support/latexindent/documentation/latexindent.tex +2021/07/31 | 23903 | systems/win32/miktex/tm/packages/next/miktex-popt-bin-x64-2.9.tar.lzma +2021/07/31 | 23600 | support/latexindent/LatexIndent/Arguments.pm +2021/07/31 | 23365 | systems/win32/miktex/tm/packages/next/miktex-devnag-bin-x64-2.9.tar.lzma +2021/07/31 | 231912 | systems/win32/miktex/tm/packages/next/miktex-zzdb1-2.9.tar.lzma +2021/07/31 | 231888 | systems/win32/miktex/tm/packages/miktex-zzdb1-2.9.tar.lzma +2021/07/31 | 22938 | support/latexindent/LatexIndent/ModifyLineBreaks.pm +2021/07/31 | 22875 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.sty +2021/07/31 | 22855 | support/latexindent/LatexIndent/Verbatim.pm +2021/07/31 | 2212 | support/latexindent/LatexIndent/Logger.pm +2021/07/31 | 22113 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.dtx +2021/07/31 | 22107 | support/latexindent/documentation/subsec-one-sentence-per-line.tex +2021/07/31 | 22050 | systems/win32/miktex/tm/packages/next/miktex-fribidixetex-bin-2.9.tar.lzma +2021/07/31 | 217081 | macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.pdf +2021/07/31 | 21650 | support/latexindent/documentation/sec-replacements.tex +2021/07/31 | 215249 | systems/win32/miktex/tm/packages/next/miktex-metafont-bin-x64-2.9.tar.lzma +2021/07/31 | 21225 | systems/win32/miktex/tm/packages/next/miktex-devnag-bin-2.9.tar.lzma +2021/07/31 | 21217 | support/latexindent/LatexIndent/Document.pm +2021/07/31 | 2120 | support/latexindent/documentation/sec-demonstration.tex +2021/07/31 | 20834 | info/install-latex-guide-zh-cn/chapter/windows.tex +2021/07/31 | 208048 | systems/win32/miktex/tm/packages/next/miktex-pmx-bin-2.9.tar.lzma +2021/07/31 | 206604 | systems/win32/miktex/tm/packages/next/miktex-omegaware-bin-x64-2.9.tar.lzma +2021/07/31 | 20575 | support/latexindent/LatexIndent/Indent.pm +2021/07/31 | 20556 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.dtx +2021/07/31 | 202797 | systems/win32/miktex/tm/packages/next/miktex-pixman-bin-x64-2.9.tar.lzma +2021/07/31 | 20137 | systems/win32/miktex/tm/packages/next/miktex-popt-bin-2.9.tar.lzma +2021/07/31 | 2009905 | systems/win32/miktex/tm/packages/next/miktex-luatex-bin-x64-2.9.tar.lzma +2021/07/31 | 199733 | systems/win32/miktex/tm/packages/next/miktex-mpfr-bin-2.9.tar.lzma +2021/07/31 | 1992 | support/latexindent/LatexIndent/Switches.pm +2021/07/31 | 19864 | support/latexindent/LatexIndent/Sentence.pm +2021/07/31 | 198170 | systems/win32/miktex/tm/packages/next/miktex-pixman-bin-2.9.tar.lzma +2021/07/31 | 196872 | systems/win32/miktex/tm/packages/next/miktex-metafont-bin-2.9.tar.lzma +2021/07/31 | 196741 | systems/win32/miktex/tm/packages/next/miktex-mo-bin-x64-2.9.tar.lzma +2021/07/31 | 195636 | systems/win32/miktex/tm/packages/next/miktex-curl-bin-x64-2.9.tar.lzma +2021/07/31 | 194382 | systems/win32/miktex/tm/packages/next/miktex-omegaware-bin-2.9.tar.lzma +2021/07/31 | 194141 | macros/latex/contrib/macrolist.zip +2021/07/31 | 194057 | macros/latex/contrib/macrolist/macrolist.pdf +2021/07/31 | 1909 | support/latexindent/documentation/subsec-noAdditionalIndent-indentRules.tex +2021/07/31 | 18923 | support/latexindent/documentation/sec-how-to-use.tex +2021/07/31 | 1879 | support/latexindent/documentation/figure-schematic.tex +2021/07/31 | 1878 | macros/latex/contrib/macrolist/macrolist.ins +2021/07/31 | 18760 | support/latexindent/defaultSettings.yaml +2021/07/31 | 1874 | support/latexindent/README +2021/07/31 | 18289 | macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.dtx +2021/07/31 | 1822 | macros/latex/contrib/pdfmanagement-testphase/pdflscape-ltx.sty +2021/07/31 | 18177 | systems/win32/miktex/tm/packages/next/miktex-tex2xindy-bin-x64-2.9.tar.lzma +2021/07/31 | 18082 | support/latexindent/documentation/subsec-text-wrap.tex +2021/07/31 | 180121 | systems/win32/miktex/tm/packages/next/miktex-mpfr-bin-x64-2.9.tar.lzma +2021/07/31 | 180011 | systems/win32/miktex/tm/packages/next/miktex-curl-bin-2.9.tar.lzma +2021/07/31 | 17980 | systems/win32/miktex/tm/packages/next/miktex-kpathsea-bin-x64-2.9.tar.lzma +2021/07/31 | 178354 | systems/win32/miktex/tm/packages/next/miktex-mo-bin-2.9.tar.lzma +2021/07/31 | 17807 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.dtx +2021/07/31 | 17429 | macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.dtx +2021/07/31 | 173067 | macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.dtx +2021/07/31 | 1713892 | systems/win32/miktex/tm/packages/next/miktex-luatex-bin-2.9.tar.lzma +2021/07/31 | 169242 | systems/win32/miktex/tm/packages/next/miktex-tex-bin-x64-2.9.tar.lzma +2021/07/31 | 1688 | support/latexindent/documentation/sec-conclusions-know-limitations.tex +2021/07/31 | 16703 | support/latexindent/documentation/subsubsec-environments-and-their-arguments.tex +2021/07/31 | 1664 | support/latexindent/documentation/logo.tex +2021/07/31 | 16413 | systems/win32/miktex/tm/packages/next/miktex-tex2xindy-bin-2.9.tar.lzma +2021/07/31 | 16356 | systems/win32/miktex/tm/packages/next/miktex-kpathsea-bin-2.9.tar.lzma +2021/07/31 | 159579 | systems/win32/miktex/tm/packages/next/miktex-hunspell-bin-x64-2.9.tar.lzma +2021/07/31 | 15944 | macros/latex/contrib/pdfmanagement-testphase/ltdocinit.dtx +2021/07/31 | 15784 | macros/latex/contrib/pdfmanagement-testphase/l3pdftools.dtx +2021/07/31 | 15661 | macros/latex/contrib/macrolist/macrolist.dtx +2021/07/31 | 1558 | support/latexindent/latexindent-module-installer.pl +2021/07/31 | 154803 | systems/win32/miktex/tm/packages/next/miktex-tex-bin-2.9.tar.lzma +2021/07/31 | 154426 | systems/win32/miktex/tm/packages/next/miktex-fontconfig-bin-x64-2.9.tar.lzma +2021/07/31 | 1483 | support/latexindent/LatexIndent/DoubleBackSlash.pm +2021/07/31 | 1477 | support/latexindent/documentation/title.tex +2021/07/31 | 147370 | systems/win32/miktex/tm/packages/next/miktex-hunspell-bin-2.9.tar.lzma +2021/07/31 | 1464203 | systems/win32/miktex/tm/packages/next/miktex-runtime-bin-x64-2.9.tar.lzma +2021/07/31 | 1442 | support/latexindent/documentation/subsec-text-wrap-summary.tex +2021/07/31 | 14347 | systems/win32/miktex/tm/packages/next/miktex-zzip-bin-x64-2.9.tar.lzma +2021/07/31 | 1421867 | systems/win32/miktex/tm/packages/next/miktex-dvisvgm-bin-x64-2.9.tar.lzma +2021/07/31 | 14050 | support/latexindent/documentation/subsec-commands-and-their-options.tex +2021/07/31 | 136822 | systems/win32/miktex/tm/packages/next/miktex-mktex-bin-x64-2.9.tar.lzma +2021/07/31 | 136817 | systems/win32/miktex/tm/packages/next/miktex-fontconfig-bin-2.9.tar.lzma +2021/07/31 | 13572 | support/latexindent/LatexIndent/Special.pm +2021/07/31 | 13463 | systems/win32/miktex/tm/packages/next/miktex-zzip-bin-2.9.tar.lzma +2021/07/31 | 1340931 | systems/win32/miktex/tm/packages/next/miktex-runtime-bin-2.9.tar.lzma +2021/07/31 | 133866 | systems/win32/miktex/tm/packages/next/miktex-dvips-bin-x64-2.9.tar.lzma +2021/07/31 | 1320701 | systems/win32/miktex/tm/packages/next/miktex-zzdb2-2.9.tar.lzma +2021/07/31 | 1320637 | systems/win32/miktex/tm/packages/miktex-zzdb2-2.9.tar.lzma +2021/07/31 | 13109 | support/latexindent/documentation/appendices.tex +2021/07/31 | 1301190 | systems/win32/miktex/tm/packages/next/miktex-poppler-bin-x64-2.9.tar.lzma +2021/07/31 | 1291297 | systems/win32/miktex/tm/packages/next/miktex-dvisvgm-bin-2.9.tar.lzma +2021/07/31 | 12661 | support/latexindent/LatexIndent/Braces.pm +2021/07/31 | 124282 | systems/win32/miktex/tm/packages/next/miktex-mktex-bin-2.9.tar.lzma +2021/07/31 | 12302 | support/latexindent/LatexIndent/HiddenChildren.pm +2021/07/31 | 1228758 | systems/win32/miktex/tm/packages/next/miktex-zzdb3-2.9.tar.lzma +2021/07/31 | 1227675 | systems/win32/miktex/tm/packages/miktex-zzdb3-2.9.tar.lzma +2021/07/31 | 12024 | support/latexindent/documentation/sec-fine-tuning.tex +2021/07/31 | 119819 | systems/win32/miktex/tm/packages/next/miktex-dvips-bin-2.9.tar.lzma +2021/07/31 | 1195 | macros/latex/contrib/pdfmanagement-testphase/README.md +2021/07/31 | 11823 | support/latexindent/LatexIndent/FileContents.pm +2021/07/31 | 1169718 | systems/win32/miktex/tm/packages/next/miktex-poppler-bin-2.9.tar.lzma +2021/07/31 | 11600 | support/latexindent/documentation/subsec-remove-para-line-breaks.tex +2021/07/31 | 1153 | systems/win32/miktex/tm/packages/next/pr.ini +2021/07/31 | 115352 | systems/win32/miktex/tm/packages/next/miktex-gregorio-bin-x64-2.9.tar.lzma +2021/07/31 | 1137 | macros/latex/contrib/macrolist/README.md +2021/07/31 | 112983 | systems/win32/miktex/tm/packages/next/miktex-epstopdf-bin-x64-2.9.tar.lzma +2021/07/31 | 112087 | systems/win32/miktex/tm/packages/next/miktex-gd-bin-x64-2.9.tar.lzma +2021/07/31 | 11151 | macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.dtx +2021/07/31 | 109031 | systems/win32/miktex/tm/packages/next/miktex-jpeg-bin-x64-2.9.tar.lzma +2021/07/31 | 10859 | support/latexindent/documentation/sec-indent-config-and-settings.tex +2021/07/31 | 10806 | support/latexindent/LatexIndent/Heading.pm +2021/07/31 | 1077990 | systems/win32/miktex/tm/packages/next/miktex-asymptote-bin-x64-2.9.tar.lzma +2021/07/31 | 10666138 | macros/latex/contrib/pdfmanagement-testphase.zip +2021/07/31 | 105222 | systems/win32/miktex/tm/packages/next/miktex-texware-bin-x64-2.9.tar.lzma +2021/07/31 | 10361 | support/latexindent/LatexIndent/Command.pm +2021/07/31 | 103400 | systems/win32/miktex/tm/packages/next/miktex-lua53-bin-x64-2.9.tar.lzma +2021/07/31 | 103203 | systems/win32/miktex/tm/packages/next/miktex-mfware-bin-x64-2.9.tar.lzma +2021/07/31 | 100625 | systems/win32/miktex/tm/packages/next/miktex-epstopdf-bin-2.9.tar.lzma 2021/07/30 | 99 | graphics/pgf/contrib/pgf-pie/demo/legend.tex 2021/07/30 | 98659 | macros/latex/contrib/minimalist/minimalist-doc.pdf -2021/07/30 | 98381 | systems/win32/miktex/tm/packages/next/miktex-mfware-bin-2.9.tar.lzma -2021/07/30 | 98260 | systems/win32/miktex/tm/packages/next/miktex-texware-bin-2.9.tar.lzma -2021/07/30 | 975019 | systems/win32/miktex/tm/packages/next/miktex-asymptote-bin-2.9.tar.lzma -2021/07/30 | 97339 | systems/win32/miktex/tm/packages/next/miktex-gd-bin-2.9.tar.lzma -2021/07/30 | 96632 | systems/win32/miktex/tm/packages/next/miktex-gregorio-bin-2.9.tar.lzma -2021/07/30 | 95402 | systems/win32/miktex/tm/packages/next/miktex-bibtex8bit-bin-x64-2.9.tar.lzma 2021/07/30 | 95143 | macros/latex/contrib/colorist/colorist-doc.pdf 2021/07/30 | 94 | graphics/pgf/contrib/pgf-pie/demo/colorwheel.tex -2021/07/30 | 94800 | systems/win32/miktex/tm/packages/next/miktex-jpeg-bin-2.9.tar.lzma -2021/07/30 | 94311 | systems/win32/miktex/tm/packages/next/miktex-lua53-bin-2.9.tar.lzma 2021/07/30 | 9181 | graphics/pgf/contrib/pgf-pie/logo.png -2021/07/30 | 894 | systems/win32/miktex/tm/packages/pr.ini 2021/07/30 | 88485 | macros/latex/contrib/projlib/ProjLib.dtx 2021/07/30 | 88019 | macros/latex/contrib/projlib/ProjLib-doc.dtx -2021/07/30 | 87777 | systems/win32/miktex/tm/packages/next/miktex-png-bin-x64-2.9.tar.lzma -2021/07/30 | 8767 | systems/win32/miktex/tm/packages/next/miktex-md5-bin-x64-2.9.tar.lzma 2021/07/30 | 8541 | macros/latex/contrib/spbmark/spbmark.sty 2021/07/30 | 84942 | macros/latex/contrib/colorist/colorist.sty -2021/07/30 | 83540 | systems/win32/miktex/tm/packages/next/miktex-bibtex8bit-bin-2.9.tar.lzma 2021/07/30 | 82 | graphics/pgf/contrib/pgf-pie/demo/hide-number.tex 2021/07/30 | 8294 | macros/latex/contrib/spbmark/spbmark.tex 2021/07/30 | 8212 | systems/texlive/tlnet/archive/jlreq.source.r60109.tar.xz 2021/07/30 | 81 | graphics/pgf/contrib/pgf-pie/demo/text-inside.tex -2021/07/30 | 815245 | systems/win32/miktex/tm/packages/next/miktex-pdftex-bin-x64-2.9.tar.lzma 2021/07/30 | 80 | graphics/pgf/contrib/pgf-pie/demo/scalefont.tex -2021/07/30 | 80450 | systems/win32/miktex/tm/packages/next/miktex-freeglut-bin-x64-2.9.tar.lzma 2021/07/30 | 79106 | macros/latex/contrib/vhistory/doc/vh_set_example.pdf 2021/07/30 | 78 | graphics/pgf/contrib/pgf-pie/demo/text.tex -2021/07/30 | 78774 | systems/win32/miktex/tm/packages/next/miktex-png-bin-2.9.tar.lzma -2021/07/30 | 77952 | systems/win32/miktex/tm/packages/next/miktex-fonts-bin-x64-2.9.tar.lzma -2021/07/30 | 7722 | systems/win32/miktex/tm/packages/next/miktex-md5-bin-2.9.tar.lzma 2021/07/30 | 770628 | macros/latex/contrib/projlib.zip 2021/07/30 | 76 | graphics/pgf/contrib/pgf-pie/demo/square.tex -2021/07/30 | 76827 | systems/win32/miktex/tm/packages/next/miktex-mpmcli-bin-x64-2.9.tar.lzma +2021/07/30 | 76164 | macros/latex/contrib/hvlogos/doc/hvlogos-doc.pdf 2021/07/30 | 75 | graphics/pgf/contrib/pgf-pie/demo/polar.tex -2021/07/30 | 75792 | systems/win32/miktex/tm/packages/next/miktex-bibtex-bin-x64-2.9.tar.lzma 2021/07/30 | 75479 | macros/latex/contrib/easybook/easybook.dtx -2021/07/30 | 744116 | systems/win32/miktex/tm/packages/next/miktex-pdftex-bin-2.9.tar.lzma 2021/07/30 | 744096 | macros/unicodetex/latex/beaulivre.zip -2021/07/30 | 74208 | systems/win32/miktex/tm/packages/next/miktex-lzma-bin-x64-2.9.tar.lzma 2021/07/30 | 73283 | macros/latex/contrib/easybook/easybook.tex -2021/07/30 | 73195 | systems/win32/miktex/tm/packages/next/miktex-fonts-bin-2.9.tar.lzma -2021/07/30 | 73149 | systems/win32/miktex/tm/packages/next/miktex-graphite2-bin-x64-2.9.tar.lzma -2021/07/30 | 72206 | systems/win32/miktex/tm/packages/next/miktex-ps2pk-bin-x64-2.9.tar.lzma -2021/07/30 | 71670 | systems/win32/miktex/tm/packages/next/miktex-freeglut-bin-2.9.tar.lzma -2021/07/30 | 70649 | systems/win32/miktex/tm/packages/next/miktex-web-bin-x64-2.9.tar.lzma -2021/07/30 | 69915 | systems/win32/miktex/tm/packages/next/miktex-tex4ht-bin-x64-2.9.tar.lzma 2021/07/30 | 69089 | macros/latex/contrib/spbmark.zip 2021/07/30 | 68 | graphics/pgf/contrib/pgf-pie/demo/first-pie.tex 2021/07/30 | 684863 | macros/unicodetex/latex/simplivre.zip -2021/07/30 | 681252 | systems/win32/miktex/tm/packages/next/miktex-lcdf-typetools-bin-x64-2.9.tar.lzma 2021/07/30 | 6811525 | systems/texlive/tlnet/install-tl-unx.tar.gz -2021/07/30 | 68024 | systems/win32/miktex/tm/packages/next/miktex-mkfntmap-bin-x64-2.9.tar.lzma -2021/07/30 | 67820 | systems/win32/miktex/tm/packages/next/miktex-bibtex-bin-2.9.tar.lzma -2021/07/30 | 67619 | systems/win32/miktex/tm/packages/next/miktex-lzma-bin-2.9.tar.lzma 2021/07/30 | 67488 | systems/texlive/tlnet/archive/spbmark.doc.r60111.tar.xz -2021/07/30 | 67483 | systems/win32/miktex/tm/packages/next/miktex-mpmcli-bin-2.9.tar.lzma -2021/07/30 | 65787 | systems/win32/miktex/tm/packages/next/miktex-texify-bin-x64-2.9.tar.lzma -2021/07/30 | 65619 | systems/win32/miktex/tm/packages/next/miktex-web-bin-2.9.tar.lzma 2021/07/30 | 65290 | macros/latex/contrib/spbmark/spbmark.pdf 2021/07/30 | 652777 | macros/unicodetex/latex/lebhart.zip 2021/07/30 | 65246 | systems/win32/miktex/tm/packages/spbmark__doc.tar.lzma -2021/07/30 | 64426 | systems/win32/miktex/tm/packages/next/miktex-graphite2-bin-2.9.tar.lzma -2021/07/30 | 64186 | systems/win32/miktex/tm/packages/next/miktex-ps2pk-bin-2.9.tar.lzma -2021/07/30 | 63778 | systems/win32/miktex/tm/packages/next/miktex-tex4ht-bin-2.9.tar.lzma 2021/07/30 | 632 | macros/latex/contrib/palette/README.md -2021/07/30 | 629400 | systems/win32/miktex/tm/packages/next/miktex-lcdf-typetools-bin-2.9.tar.lzma -2021/07/30 | 62784 | systems/win32/miktex/tm/packages/next/miktex-fmt-bin-x64-2.9.tar.lzma -2021/07/30 | 624651 | systems/win32/miktex/tm/packages/next/miktex-yap-bin-x64-2.9.tar.lzma -2021/07/30 | 62228 | systems/win32/miktex/tm/packages/next/miktex-ttf2pk2-bin-x64-2.9.tar.lzma -2021/07/30 | 61813 | systems/win32/miktex/tm/packages/next/miktex-cweb-bin-x64-2.9.tar.lzma 2021/07/30 | 609838 | macros/unicodetex/latex/einfart.zip -2021/07/30 | 60638 | systems/win32/miktex/tm/packages/next/miktex-mkfntmap-bin-2.9.tar.lzma -2021/07/30 | 60039 | systems/win32/miktex/tm/packages/next/miktex-tdsutil-bin-x64.tar.lzma 2021/07/30 | 596 | graphics/pgf/contrib/pgf-pie/RELEASE_NOTES.md -2021/07/30 | 596931 | systems/win32/miktex/tm/packages/next/miktex-libressl-bin-x64-2.9.tar.lzma -2021/07/30 | 593220 | systems/win32/miktex/tm/packages/next/files.csv.lzma -2021/07/30 | 592787 | systems/win32/miktex/tm/packages/files.csv.lzma 2021/07/30 | 591528 | macros/latex/contrib/easybook.zip -2021/07/30 | 589843 | systems/win32/miktex/tm/packages/next/miktex-yap-bin-2.9.tar.lzma 2021/07/30 | 5855 | macros/latex/contrib/minimalist/minimart.cls 2021/07/30 | 5852 | macros/latex/contrib/minimalist/minimbook.cls -2021/07/30 | 57727 | systems/win32/miktex/tm/packages/next/miktex-psutils-bin-x64-2.9.tar.lzma -2021/07/30 | 57550 | systems/win32/miktex/tm/packages/next/miktex-bibarts-bin-x64-2.9.tar.lzma -2021/07/30 | 57140 | systems/win32/miktex/tm/packages/next/miktex-xml2pmx-bin-x64.tar.lzma -2021/07/30 | 57014 | systems/win32/miktex/tm/packages/next/miktex-texify-bin-2.9.tar.lzma -2021/07/30 | 56684 | systems/win32/miktex/tm/packages/next/miktex-cjkutils-bin-x64-2.9.tar.lzma -2021/07/30 | 566526 | systems/win32/miktex/tm/packages/next/miktex-harfbuzz-bin-x64-2.9.tar.lzma -2021/07/30 | 56514 | systems/win32/miktex/tm/packages/next/miktex-tdsutil-bin.tar.lzma -2021/07/30 | 56477 | systems/win32/miktex/tm/packages/next/miktex-arctrl-bin-x64-2.9.tar.lzma -2021/07/30 | 56356 | systems/win32/miktex/tm/packages/next/miktex-ttf2pk2-bin-2.9.tar.lzma -2021/07/30 | 56316 | systems/win32/miktex/tm/packages/next/miktex-fmt-bin-2.9.tar.lzma -2021/07/30 | 55499 | systems/win32/miktex/tm/packages/next/miktex-xml2pmx-bin.tar.lzma +2021/07/30 | 55 | macros/latex/contrib/hvlogos/Changes 2021/07/30 | 552330 | macros/latex/contrib/easybook/easybook.pdf 2021/07/30 | 5488 | macros/latex/contrib/colorist/colorart.cls 2021/07/30 | 5485 | macros/latex/contrib/colorist/colorbook.cls -2021/07/30 | 54632 | systems/win32/miktex/tm/packages/next/miktex-cweb-bin-2.9.tar.lzma -2021/07/30 | 531852 | systems/win32/miktex/tm/packages/next/miktex-libressl-bin-2.9.tar.lzma -2021/07/30 | 52523 | systems/win32/miktex/tm/packages/next/miktex-m-tx-bin-x64-2.9.tar.lzma -2021/07/30 | 51749 | systems/win32/miktex/tm/packages/next/miktex-synctex-bin-x64-2.9.tar.lzma +2021/07/30 | 5250 | macros/latex/contrib/hvlogos/latex/hvlogos.sty 2021/07/30 | 516261 | systems/win32/miktex/tm/packages/jlreq__doc.tar.lzma -2021/07/30 | 51311 | systems/win32/miktex/tm/packages/next/miktex-cjkutils-bin-2.9.tar.lzma 2021/07/30 | 513076 | systems/texlive/tlnet/archive/jlreq.doc.r60109.tar.xz -2021/07/30 | 51201 | systems/win32/miktex/tm/packages/next/miktex-dvicopy-bin-x64-2.9.tar.lzma -2021/07/30 | 51113 | systems/win32/miktex/tm/packages/next/miktex-arctrl-bin-2.9.tar.lzma -2021/07/30 | 510583 | systems/win32/miktex/tm/packages/next/miktex-log4cxx-bin-x64-2.9.tar.lzma -2021/07/30 | 50396 | systems/win32/miktex/tm/packages/next/miktex-psutils-bin-2.9.tar.lzma -2021/07/30 | 50152 | systems/win32/miktex/tm/packages/next/miktex-bibarts-bin-2.9.tar.lzma 2021/07/30 | 48 | systems/texlive/tlnet/tlpkg/texlive.tlpdb.md5 -2021/07/30 | 483653 | systems/win32/miktex/tm/packages/next/miktex-harfbuzz-bin-2.9.tar.lzma 2021/07/30 | 4830 | graphics/pgf/contrib/pgf-pie/pgf-pie-manual.tex 2021/07/30 | 482 | graphics/pgf/contrib/pgf-pie/README.md -2021/07/30 | 48252 | systems/win32/miktex/tm/packages/next/miktex-expat-bin-x64-2.9.tar.lzma -2021/07/30 | 476918 | systems/win32/miktex/tm/packages/next/miktex-log4cxx-bin-2.9.tar.lzma -2021/07/30 | 46907 | systems/win32/miktex/tm/packages/next/miktex-mtprint-bin-x64-2.9.tar.lzma -2021/07/30 | 461813 | systems/win32/miktex/tm/packages/next/miktex-doc.tar.lzma -2021/07/30 | 45970 | systems/win32/miktex/tm/packages/next/miktex-m-tx-bin-2.9.tar.lzma -2021/07/30 | 45906 | systems/win32/miktex/tm/packages/next/miktex-dvicopy-bin-2.9.tar.lzma 2021/07/30 | 455 | systems/texlive/tlnet/tlpkg/texlive.tlpdb.sha512.asc 2021/07/30 | 455 | systems/texlive/tlnet/install-tl.zip.sha512.asc 2021/07/30 | 455 | systems/texlive/tlnet/install-tl-windows.exe.sha512.asc 2021/07/30 | 455 | systems/texlive/tlnet/install-tl-unx.tar.gz.sha512.asc -2021/07/30 | 45311 | systems/win32/miktex/tm/packages/next/miktex-dvipng-bin-x64-2.9.tar.lzma -2021/07/30 | 43426 | systems/win32/miktex/tm/packages/next/miktex-zlib-bin-x64-2.9.tar.lzma -2021/07/30 | 43027 | systems/win32/miktex/tm/packages/next/miktex-expat-bin-2.9.tar.lzma -2021/07/30 | 43003 | systems/win32/miktex/tm/packages/next/miktex-gsf2pk-bin-x64-2.9.tar.lzma -2021/07/30 | 42891 | systems/win32/miktex/tm/packages/next/miktex-mtprint-bin-2.9.tar.lzma -2021/07/30 | 42712 | systems/win32/miktex/tm/packages/next/miktex-mthelp-bin-x64-2.9.tar.lzma 2021/07/30 | 426 | graphics/pgf/contrib/pgf-pie/COPYING -2021/07/30 | 42386 | systems/win32/miktex/tm/packages/next/miktex-synctex-bin-2.9.tar.lzma -2021/07/30 | 41193 | systems/win32/miktex/tm/packages/next/miktex-dvipng-bin-2.9.tar.lzma -2021/07/30 | 40230 | systems/win32/miktex/tm/packages/next/miktex-patgen-bin-x64.tar.lzma 2021/07/30 | 401776 | macros/latex/contrib/vhistory.zip 2021/07/30 | 398876 | systems/texlive/tlnet/archive/texlive-scripts.doc.r60108.tar.xz -2021/07/30 | 392793 | systems/win32/miktex/tm/packages/next/miktex-cairo-bin-x64-2.9.tar.lzma -2021/07/30 | 39127 | systems/win32/miktex/tm/packages/next/miktex-zlib-bin-2.9.tar.lzma -2021/07/30 | 38141 | systems/win32/miktex/tm/packages/next/miktex-gsf2pk-bin-2.9.tar.lzma -2021/07/30 | 37804 | systems/win32/miktex/tm/packages/next/miktex-mthelp-bin-2.9.tar.lzma 2021/07/30 | 3755903 | systems/win32/miktex/tm/packages/media9__doc.tar.lzma -2021/07/30 | 37359 | systems/win32/miktex/tm/packages/next/miktex-upmendex-bin-x64.tar.lzma 2021/07/30 | 3724824 | systems/texlive/tlnet/archive/media9.doc.r60110.tar.xz -2021/07/30 | 37242 | systems/win32/miktex/tm/packages/next/miktex-posix-bin-x64-2.9.tar.lzma -2021/07/30 | 36628 | systems/win32/miktex/tm/packages/next/miktex-chktex-bin-x64-2.9.tar.lzma 2021/07/30 | 3595 | systems/win32/miktex/tm/packages/tikztosvg__source.tar.lzma -2021/07/30 | 35692 | systems/win32/miktex/tm/packages/next/miktex-patgen-bin.tar.lzma -2021/07/30 | 35087 | systems/win32/miktex/tm/packages/next/miktex-mspack-bin-x64-2.9.tar.lzma -2021/07/30 | 34665 | systems/win32/miktex/tm/packages/next/miktex-axohelp-bin-x64-2.9.tar.lzma -2021/07/30 | 345739 | systems/win32/miktex/tm/packages/next/miktex-xetex-bin-x64-2.9.tar.lzma 2021/07/30 | 3414 | systems/win32/miktex/tm/packages/spbmark__source.tar.lzma -2021/07/30 | 33632 | systems/win32/miktex/tm/packages/next/miktex-uriparser-bin-x64-2.9.tar.lzma -2021/07/30 | 33544 | systems/win32/miktex/tm/packages/next/miktex-upmendex-bin.tar.lzma -2021/07/30 | 330788 | systems/win32/miktex/tm/packages/next/miktex-cairo-bin-2.9.tar.lzma +2021/07/30 | 3373 | macros/latex/contrib/hvlogos/doc/hvlogos-doc.tex 2021/07/30 | 327163 | macros/unicodetex/latex/beaulivre/beaulivre-doc-cn.pdf -2021/07/30 | 32674 | systems/win32/miktex/tm/packages/next/miktex-chktex-bin-2.9.tar.lzma 2021/07/30 | 325472 | macros/latex/contrib/projlib/ProjLib-doc-cn.pdf -2021/07/30 | 325043 | systems/win32/miktex/tm/packages/next/miktex-dvipdfmx-bin-x64-2.9.tar.lzma -2021/07/30 | 31619 | systems/win32/miktex/tm/packages/next/miktex-makeindex-bin-x64-2.9.tar.lzma -2021/07/30 | 31535 | systems/win32/miktex/tm/packages/next/miktex-posix-bin-2.9.tar.lzma -2021/07/30 | 31351 | systems/win32/miktex/tm/packages/next/miktex-autosp-bin-x64-2.9.tar.lzma -2021/07/30 | 31231 | systems/win32/miktex/tm/packages/next/miktex-mspack-bin-2.9.tar.lzma -2021/07/30 | 312109 | systems/win32/miktex/tm/packages/next/miktex-xetex-bin-2.9.tar.lzma 2021/07/30 | 30936 | macros/latex/contrib/minimalist/minimalist.sty -2021/07/30 | 30824 | systems/win32/miktex/tm/packages/next/miktex-bzip2-bin-x64-2.9.tar.lzma -2021/07/30 | 30059 | systems/win32/miktex/tm/packages/next/miktex-lacheck-bin-x64-2.9.tar.lzma -2021/07/30 | 29842 | systems/win32/miktex/tm/packages/next/miktex-axohelp-bin-2.9.tar.lzma 2021/07/30 | 297299 | macros/unicodetex/latex/lebhart/lebhart-doc-cn.pdf -2021/07/30 | 295204 | systems/win32/miktex/tm/packages/next/miktex-freetype2-bin-x64-2.9.tar.lzma 2021/07/30 | 29505 | macros/latex/contrib/minimalist/minimalist-doc.tex 2021/07/30 | 291386 | macros/unicodetex/latex/simplivre/simplivre-doc-cn.pdf -2021/07/30 | 29037 | systems/win32/miktex/tm/packages/next/miktex-autosp-bin-2.9.tar.lzma 2021/07/30 | 28895 | macros/unicodetex/latex/einfart/einfart-doc-fr.tex -2021/07/30 | 284579 | systems/win32/miktex/tm/packages/next/miktex-dvipdfmx-bin-2.9.tar.lzma -2021/07/30 | 284025 | systems/win32/miktex/tm/packages/next/miktex-metapost-bin-x64-2.9.tar.lzma -2021/07/30 | 28390 | systems/win32/miktex/tm/packages/next/miktex-lacheck-bin-2.9.tar.lzma -2021/07/30 | 28180 | systems/win32/miktex/tm/packages/next/miktex-findtexmf-bin-x64-2.9.tar.lzma 2021/07/30 | 28033 | macros/latex/contrib/colorist/colorist-doc.tex -2021/07/30 | 2796726 | systems/win32/miktex/tm/packages/next/miktex-texworks-bin-x64-2.9.tar.lzma -2021/07/30 | 27728 | systems/win32/miktex/tm/packages/next/miktex-uriparser-bin-2.9.tar.lzma 2021/07/30 | 27401 | macros/unicodetex/latex/simplivre/simplivre-doc-fr.tex -2021/07/30 | 27389 | systems/win32/miktex/tm/packages/next/miktex-teckit-bin-x64-2.9.tar.lzma -2021/07/30 | 27357 | systems/win32/miktex/tm/packages/next/miktex-makeindex-bin-2.9.tar.lzma 2021/07/30 | 27243 | macros/unicodetex/latex/lebhart/lebhart-doc-fr.tex -2021/07/30 | 27200 | systems/win32/miktex/tm/packages/next/miktex-bzip2-bin-2.9.tar.lzma 2021/07/30 | 2676 | systems/win32/miktex/tm/packages/spbmark.tar.lzma -2021/07/30 | 2672608 | systems/win32/miktex/tm/packages/next/miktex-texworks-bin-2.9.tar.lzma 2021/07/30 | 26619 | macros/unicodetex/latex/einfart/einfart-doc-en.tex -2021/07/30 | 263958 | systems/win32/miktex/tm/packages/next/miktex-console-bin-x64-2.9.tar.lzma 2021/07/30 | 259625 | macros/unicodetex/latex/einfart/einfart-doc-cn.pdf -2021/07/30 | 258879 | systems/win32/miktex/tm/packages/next/miktex-freetype2-bin-2.9.tar.lzma 2021/07/30 | 25738 | macros/unicodetex/latex/beaulivre/beaulivre-doc-fr.tex 2021/07/30 | 25585293 | systems/texlive/tlnet/install-tl.zip -2021/07/30 | 25290 | systems/win32/miktex/tm/packages/next/miktex-teckit-bin-2.9.tar.lzma 2021/07/30 | 25261 | macros/unicodetex/latex/simplivre/simplivre-doc-en.tex 2021/07/30 | 25193 | macros/unicodetex/latex/lebhart/lebhart-doc-en.tex -2021/07/30 | 250266 | systems/win32/miktex/tm/packages/next/miktex-metapost-bin-2.9.tar.lzma -2021/07/30 | 25020 | systems/win32/miktex/tm/packages/next/miktex-findtexmf-bin-2.9.tar.lzma -2021/07/30 | 24995 | systems/win32/miktex/tm/packages/next/miktex-fribidixetex-bin-x64-2.9.tar.lzma 2021/07/30 | 24747 | macros/unicodetex/latex/einfart/einfart-doc-cn.tex 2021/07/30 | 2456 | systems/texlive/tlnet/archive/spbmark.r60111.tar.xz -2021/07/30 | 243426 | systems/win32/miktex/tm/packages/next/miktex-pmx-bin-x64-2.9.tar.lzma -2021/07/30 | 241810 | systems/win32/miktex/tm/packages/next/miktex-console-bin-2.9.tar.lzma -2021/07/30 | 23902 | systems/win32/miktex/tm/packages/next/miktex-popt-bin-x64-2.9.tar.lzma +2021/07/30 | 244 | macros/latex/contrib/hvlogos/README 2021/07/30 | 23866 | macros/unicodetex/latex/beaulivre/beaulivre-doc-en.tex 2021/07/30 | 235 | graphics/pgf/contrib/pgf-pie/pgf-pie.sty 2021/07/30 | 235430 | graphics/pgf/contrib/pgf-pie.zip 2021/07/30 | 23525 | macros/unicodetex/latex/lebhart/lebhart-doc-cn.tex -2021/07/30 | 23364 | systems/win32/miktex/tm/packages/next/miktex-devnag-bin-x64-2.9.tar.lzma 2021/07/30 | 23360 | macros/unicodetex/latex/simplivre/simplivre-doc-cn.tex 2021/07/30 | 2324120 | systems/texlive/tlnet/tlpkg/texlive.tlpdb.xz -2021/07/30 | 231946 | systems/win32/miktex/tm/packages/next/miktex-zzdb1-2.9.tar.lzma -2021/07/30 | 231869 | systems/win32/miktex/tm/packages/miktex-zzdb1-2.9.tar.lzma 2021/07/30 | 22168 | macros/unicodetex/latex/beaulivre/beaulivre-doc-cn.tex -2021/07/30 | 22048 | systems/win32/miktex/tm/packages/next/miktex-fribidixetex-bin-2.9.tar.lzma 2021/07/30 | 21589 | graphics/pgf/contrib/pgf-pie/demo/cloud.svg -2021/07/30 | 215249 | systems/win32/miktex/tm/packages/next/miktex-metafont-bin-x64-2.9.tar.lzma 2021/07/30 | 2147 | systems/win32/miktex/tm/packages/tikztosvg.tar.lzma -2021/07/30 | 21225 | systems/win32/miktex/tm/packages/next/miktex-devnag-bin-2.9.tar.lzma 2021/07/30 | 20811380 | systems/texlive/tlnet/install-tl-windows.exe -2021/07/30 | 208049 | systems/win32/miktex/tm/packages/next/miktex-pmx-bin-2.9.tar.lzma -2021/07/30 | 206606 | systems/win32/miktex/tm/packages/next/miktex-omegaware-bin-x64-2.9.tar.lzma 2021/07/30 | 204097 | macros/latex/contrib/projlib/ProjLib-doc-fr.pdf 2021/07/30 | 203479 | macros/unicodetex/latex/beaulivre/beaulivre-doc-fr.pdf -2021/07/30 | 202795 | systems/win32/miktex/tm/packages/next/miktex-pixman-bin-x64-2.9.tar.lzma 2021/07/30 | 202001 | macros/latex/contrib/projlib/ProjLib-doc-en.pdf -2021/07/30 | 20138 | systems/win32/miktex/tm/packages/next/miktex-popt-bin-2.9.tar.lzma -2021/07/30 | 2009904 | systems/win32/miktex/tm/packages/next/miktex-luatex-bin-x64-2.9.tar.lzma -2021/07/30 | 199733 | systems/win32/miktex/tm/packages/next/miktex-mpfr-bin-2.9.tar.lzma 2021/07/30 | 199632 | macros/unicodetex/latex/beaulivre/beaulivre-doc-en.pdf -2021/07/30 | 198169 | systems/win32/miktex/tm/packages/next/miktex-pixman-bin-2.9.tar.lzma -2021/07/30 | 196872 | systems/win32/miktex/tm/packages/next/miktex-metafont-bin-2.9.tar.lzma -2021/07/30 | 196741 | systems/win32/miktex/tm/packages/next/miktex-mo-bin-x64-2.9.tar.lzma -2021/07/30 | 195635 | systems/win32/miktex/tm/packages/next/miktex-curl-bin-x64-2.9.tar.lzma -2021/07/30 | 194384 | systems/win32/miktex/tm/packages/next/miktex-omegaware-bin-2.9.tar.lzma -2021/07/30 | 193556 | macros/latex/contrib/macrolist.zip 2021/07/30 | 193458 | graphics/pgf/contrib/pgf-pie/pgf-pie-manual.pdf 2021/07/30 | 192390 | macros/unicodetex/latex/simplivre/simplivre-doc-fr.pdf 2021/07/30 | 19107 | graphics/pgf/contrib/pgf-pie/LICENSE-LPPL1.3c.txt @@ -245,87 +429,47 @@ 2021/07/30 | 183 | graphics/pgf/contrib/pgf-pie/demo/explode.tex 2021/07/30 | 182340 | macros/latex/contrib/palette/palette.pdf 2021/07/30 | 182104 | macros/latex/contrib/palette.zip -2021/07/30 | 18177 | systems/win32/miktex/tm/packages/next/miktex-tex2xindy-bin-x64-2.9.tar.lzma 2021/07/30 | 18093 | graphics/pgf/contrib/pgf-pie/LICENSE-GPL2.txt -2021/07/30 | 180120 | systems/win32/miktex/tm/packages/next/miktex-mpfr-bin-x64-2.9.tar.lzma -2021/07/30 | 180009 | systems/win32/miktex/tm/packages/next/miktex-curl-bin-2.9.tar.lzma 2021/07/30 | 179 | graphics/pgf/contrib/pgf-pie/demo/color.tex 2021/07/30 | 179877 | macros/latex/contrib/vhistory/doc/vh_sets_de.pdf -2021/07/30 | 17981 | systems/win32/miktex/tm/packages/next/miktex-kpathsea-bin-x64-2.9.tar.lzma -2021/07/30 | 178355 | systems/win32/miktex/tm/packages/next/miktex-mo-bin-2.9.tar.lzma 2021/07/30 | 1776596 | systems/texlive/tlnet/archive/media9.source.r60110.tar.xz 2021/07/30 | 174185 | macros/latex/contrib/vhistory/doc/vh_sets_en.pdf 2021/07/30 | 17339249 | systems/texlive/tlnet/tlpkg/texlive.tlpdb -2021/07/30 | 1713894 | systems/win32/miktex/tm/packages/next/miktex-luatex-bin-2.9.tar.lzma 2021/07/30 | 169642 | macros/unicodetex/latex/lebhart/lebhart-doc-fr.pdf -2021/07/30 | 169242 | systems/win32/miktex/tm/packages/next/miktex-tex-bin-x64-2.9.tar.lzma 2021/07/30 | 166029 | macros/unicodetex/latex/einfart/einfart-doc-fr.pdf 2021/07/30 | 165 | graphics/pgf/contrib/pgf-pie/demo/radius.tex -2021/07/30 | 16412 | systems/win32/miktex/tm/packages/next/miktex-tex2xindy-bin-2.9.tar.lzma -2021/07/30 | 16357 | systems/win32/miktex/tm/packages/next/miktex-kpathsea-bin-2.9.tar.lzma 2021/07/30 | 163033 | macros/unicodetex/latex/lebhart/lebhart-doc-en.pdf 2021/07/30 | 160194 | macros/unicodetex/latex/einfart/einfart-doc-en.pdf 2021/07/30 | 1596 | graphics/pgf/contrib/pgf-pie/demo/population.tex -2021/07/30 | 159578 | systems/win32/miktex/tm/packages/next/miktex-hunspell-bin-x64-2.9.tar.lzma 2021/07/30 | 15940 | macros/latex/contrib/vhistory/sets.sty 2021/07/30 | 158 | graphics/pgf/contrib/pgf-pie/demo/sum.tex -2021/07/30 | 154806 | systems/win32/miktex/tm/packages/next/miktex-tex-bin-2.9.tar.lzma -2021/07/30 | 154426 | systems/win32/miktex/tm/packages/next/miktex-fontconfig-bin-x64-2.9.tar.lzma 2021/07/30 | 153 | systems/texlive/tlnet/install-tl-windows.exe.sha512 2021/07/30 | 152 | systems/texlive/tlnet/install-tl-unx.tar.gz.sha512 2021/07/30 | 15183 | macros/latex/contrib/palette/palette.dtx -2021/07/30 | 147373 | systems/win32/miktex/tm/packages/next/miktex-hunspell-bin-2.9.tar.lzma 2021/07/30 | 146 | graphics/pgf/contrib/pgf-pie/description.html -2021/07/30 | 1464202 | systems/win32/miktex/tm/packages/next/miktex-runtime-bin-x64-2.9.tar.lzma 2021/07/30 | 145 | systems/texlive/tlnet/install-tl.zip.sha512 2021/07/30 | 144 | systems/texlive/tlnet/tlpkg/texlive.tlpdb.sha512 2021/07/30 | 144561 | systems/win32/miktex/tm/packages/jlreq.tar.lzma -2021/07/30 | 14348 | systems/win32/miktex/tm/packages/next/miktex-zzip-bin-x64-2.9.tar.lzma -2021/07/30 | 1421868 | systems/win32/miktex/tm/packages/next/miktex-dvisvgm-bin-x64-2.9.tar.lzma 2021/07/30 | 1413 | macros/latex/contrib/vhistory/doc/vh_set_example.tex 2021/07/30 | 13882 | macros/unicodetex/latex/simplivre/simplivre.cls 2021/07/30 | 13878 | macros/unicodetex/latex/einfart/einfart.cls 2021/07/30 | 137100 | systems/texlive/tlnet/archive/jlreq.r60109.tar.xz -2021/07/30 | 136820 | systems/win32/miktex/tm/packages/next/miktex-mktex-bin-x64-2.9.tar.lzma -2021/07/30 | 136817 | systems/win32/miktex/tm/packages/next/miktex-fontconfig-bin-2.9.tar.lzma 2021/07/30 | 1361 | macros/latex/contrib/vhistory/doc/de_beispiel.tex 2021/07/30 | 13564 | graphics/pgf/contrib/pgf-pie/tikzlibrarypie.code.tex -2021/07/30 | 13466 | systems/win32/miktex/tm/packages/next/miktex-zzip-bin-2.9.tar.lzma -2021/07/30 | 1340931 | systems/win32/miktex/tm/packages/next/miktex-runtime-bin-2.9.tar.lzma -2021/07/30 | 133864 | systems/win32/miktex/tm/packages/next/miktex-dvips-bin-x64-2.9.tar.lzma 2021/07/30 | 1328 | macros/latex/contrib/vhistory/doc/README 2021/07/30 | 1325 | macros/latex/contrib/vhistory/doc/en_example.tex -2021/07/30 | 1320514 | systems/win32/miktex/tm/packages/miktex-zzdb2-2.9.tar.lzma -2021/07/30 | 1319880 | systems/win32/miktex/tm/packages/next/miktex-zzdb2-2.9.tar.lzma 2021/07/30 | 13025 | macros/unicodetex/latex/beaulivre/beaulivre.cls 2021/07/30 | 13021 | macros/unicodetex/latex/lebhart/lebhart.cls -2021/07/30 | 1301192 | systems/win32/miktex/tm/packages/next/miktex-poppler-bin-x64-2.9.tar.lzma 2021/07/30 | 12954 | graphics/pgf/contrib/pgf-pie/demo/first-pie.svg -2021/07/30 | 1291300 | systems/win32/miktex/tm/packages/next/miktex-dvisvgm-bin-2.9.tar.lzma 2021/07/30 | 12840 | graphics/pgf/contrib/pgf-pie/demo/polar.svg 2021/07/30 | 12750 | graphics/pgf/contrib/pgf-pie/demo/square.svg -2021/07/30 | 124281 | systems/win32/miktex/tm/packages/next/miktex-mktex-bin-2.9.tar.lzma 2021/07/30 | 1228 | macros/latex/contrib/vhistory/CHANGES.md -2021/07/30 | 1228735 | systems/win32/miktex/tm/packages/miktex-zzdb3-2.9.tar.lzma -2021/07/30 | 1228269 | systems/win32/miktex/tm/packages/next/miktex-zzdb3-2.9.tar.lzma 2021/07/30 | 120480 | macros/latex/contrib/colorist.zip 2021/07/30 | 120181 | macros/latex/contrib/minimalist.zip -2021/07/30 | 119820 | systems/win32/miktex/tm/packages/next/miktex-dvips-bin-2.9.tar.lzma -2021/07/30 | 1169718 | systems/win32/miktex/tm/packages/next/miktex-poppler-bin-2.9.tar.lzma 2021/07/30 | 115 | graphics/pgf/contrib/pgf-pie/demo/shadow.tex -2021/07/30 | 1153 | systems/win32/miktex/tm/packages/next/pr.ini -2021/07/30 | 115350 | systems/win32/miktex/tm/packages/next/miktex-gregorio-bin-x64-2.9.tar.lzma -2021/07/30 | 112983 | systems/win32/miktex/tm/packages/next/miktex-epstopdf-bin-x64-2.9.tar.lzma -2021/07/30 | 112087 | systems/win32/miktex/tm/packages/next/miktex-gd-bin-x64-2.9.tar.lzma -2021/07/30 | 109030 | systems/win32/miktex/tm/packages/next/miktex-jpeg-bin-x64-2.9.tar.lzma 2021/07/30 | 108156 | systems/texlive/tlnet/archive/texlive-scripts.r60108.tar.xz -2021/07/30 | 1077990 | systems/win32/miktex/tm/packages/next/miktex-asymptote-bin-x64-2.9.tar.lzma -2021/07/30 | 105223 | systems/win32/miktex/tm/packages/next/miktex-texware-bin-x64-2.9.tar.lzma 2021/07/30 | 104 | graphics/pgf/contrib/pgf-pie/demo/before-after-number.tex -2021/07/30 | 103399 | systems/win32/miktex/tm/packages/next/miktex-lua53-bin-x64-2.9.tar.lzma -2021/07/30 | 103203 | systems/win32/miktex/tm/packages/next/miktex-mfware-bin-x64-2.9.tar.lzma 2021/07/30 | 100 | graphics/pgf/contrib/pgf-pie/demo/cloud.tex -2021/07/30 | 100625 | systems/win32/miktex/tm/packages/next/miktex-epstopdf-bin-2.9.tar.lzma 2021/07/29 | 98138 | macros/latex/contrib/media9/pdfbase.sty 2021/07/29 | 89821 | systems/win32/miktex/tm/packages/lacheck__source.tar.lzma 2021/07/29 | 842 | support/tikztosvg/Makefile @@ -367,10 +511,8 @@ 2021/07/29 | 23412 | language/japanese/jlreq/jlreq-helpers.sty 2021/07/29 | 2189256 | systems/texlive/tlnet/archive/logix.r60099.tar.xz 2021/07/29 | 2036 | systems/win32/miktex/tm/packages/palette.tar.lzma -2021/07/29 | 193608 | macros/latex/contrib/macrolist/macrolist.pdf 2021/07/29 | 193153 | support/tikztosvg.zip 2021/07/29 | 1887 | support/tikztosvg/man/man.adoc -2021/07/29 | 1878 | macros/latex/contrib/macrolist/macrolist.ins 2021/07/29 | 178675 | systems/win32/miktex/tm/packages/palette__doc.tar.lzma 2021/07/29 | 17847 | systems/win32/miktex/tm/packages/lipsum__source.tar.lzma 2021/07/29 | 178100 | systems/texlive/tlnet/archive/palette.doc.r60104.tar.xz @@ -381,14 +523,13 @@ 2021/07/29 | 153 | support/tikztosvg/example/example.tikz 2021/07/29 | 15075 | macros/latex/contrib/media9/ChangeLog 2021/07/29 | 1482 | support/tikztosvg/install.sh -2021/07/29 | 14332 | macros/latex/contrib/macrolist/macrolist.dtx 2021/07/29 | 132848 | systems/texlive/tlnet/archive/pst-arrow.doc.r60100.tar.xz 2021/07/29 | 126825 | systems/win32/miktex/tm/packages/pst-arrow__doc.tar.lzma 2021/07/29 | 125675 | systems/win32/miktex/tm/packages/lipsum.tar.lzma 2021/07/29 | 1254384 | systems/texlive/tlnet/archive/logix.doc.r60099.tar.xz 2021/07/29 | 125400 | systems/texlive/tlnet/archive/lipsum.r60101.tar.xz 2021/07/29 | 118627 | language/japanese/jlreq/jlreq.pdf -2021/07/29 | 1137 | macros/latex/contrib/macrolist/README.md +2021/07/29 | 116951144 | macros/context/latest/cont-tmf.zip 2021/07/29 | 10949624 | install/language/japanese/jlreq.tds.zip 2021/07/29 | 105970 | systems/win32/miktex/tm/packages/siunitx__source.tar.lzma 2021/07/29 | 105848 | systems/texlive/tlnet/archive/siunitx.source.r60105.tar.xz @@ -699,7 +840,6 @@ 2021/07/27 | 13710 | macros/latex/contrib/tuda-ci/tex/tudaleaflet.cls 2021/07/27 | 1259 | graphics/pgf/contrib/pfdicons/pfdicons-changelog.tex 2021/07/27 | 118305 | systems/win32/miktex/tm/packages/musixtex.tar.lzma -2021/07/27 | 117096237 | macros/context/latest/cont-tmf.zip 2021/07/27 | 105290 | support/texplate/doc/texplate-manual.pdf 2021/07/27 | 1045 | graphics/pgf/contrib/pfdicons/README.txt 2021/07/27 | 10078 | macros/latex/contrib/tuda-ci/tex/beamerthemeTUDa-mecheng.sty @@ -943,171 +1083,3 @@ 2021/07/25 | 12606 | graphics/pgf/contrib/tonevalue/tonevalue.tex 2021/07/25 | 1030844 | systems/texlive/tlnet/archive/latexindent.doc.r60045.tar.xz 2021/07/25 | 102368 | systems/texlive/tlnet/archive/nicematrix.source.r60042.tar.xz -2021/07/24 | 99417 | fonts/aboensis/doc/pics/rea-U.jpg -2021/07/24 | 9723 | systems/win32/miktex/tm/packages/luaxml__source.tar.lzma -2021/07/24 | 93007 | fonts/aboensis/doc/pics/rea-R.jpg -2021/07/24 | 9238 | systems/win32/miktex/tm/packages/libertinus-otf__source.tar.lzma -2021/07/24 | 919327 | systems/win32/miktex/tm/packages/latexindent__doc.tar.lzma -2021/07/24 | 917198 | fonts/aboensis/doc/pics/aboensis-e14v.jpg -2021/07/24 | 904546 | fonts/aboensis/doc/pics/aboensis-18v.png -2021/07/24 | 897 | fonts/aboensis/doc/Makefile -2021/07/24 | 897273 | systems/win32/miktex/tm/packages/mcf2graph__doc.tar.lzma -2021/07/24 | 889 | systems/win32/miktex/tm/packages/texdimens.tar.lzma -2021/07/24 | 8661 | systems/win32/miktex/tm/packages/jlreq__source.tar.lzma -2021/07/24 | 86341 | fonts/aboensis/doc/pics/rea-H.jpg -2021/07/24 | 849429 | info/latex2e-help-texinfo/latex2e.info -2021/07/24 | 84631 | fonts/aboensis/doc/pics/rea-P.jpg -2021/07/24 | 836249 | systems/win32/miktex/tm/packages/babel__doc.tar.lzma -2021/07/24 | 8163792 | systems/win32/miktex/tm/packages/pdfmanagement-testphase__doc.tar.lzma -2021/07/24 | 8138 | info/latex2e-help-texinfo/NEWS -2021/07/24 | 80644 | systems/win32/miktex/tm/packages/babel-french__source.tar.lzma -2021/07/24 | 794690 | info/latex2e-help-texinfo/latex2e.txt -2021/07/24 | 791920 | systems/win32/miktex/tm/packages/fithesis.tar.lzma -2021/07/24 | 76375 | fonts/aboensis/doc/pics/rea-J.jpg -2021/07/24 | 75014 | fonts/aboensis/doc/pics/rea-Y.jpg -2021/07/24 | 731729 | systems/win32/miktex/tm/packages/fithesis__doc.tar.lzma -2021/07/24 | 7216 | systems/win32/miktex/tm/packages/ut-thesis__source.tar.lzma -2021/07/24 | 71962 | systems/win32/miktex/tm/packages/spectralsequences.tar.lzma -2021/07/24 | 71126 | fonts/aboensis/doc/pics/rea-I.jpg -2021/07/24 | 706300 | info/latex2e-help-texinfo/latex2e.texi -2021/07/24 | 7032 | macros/musixtex/doc/musixtex-install.tex -2021/07/24 | 70227 | macros/musixtex/doc/musixdoc/extensions.tex -2021/07/24 | 69760 | fonts/aboensis/doc/pics/rea-F.jpg -2021/07/24 | 688037 | systems/win32/miktex/tm/packages/babel__source.tar.lzma -2021/07/24 | 68583 | fonts/aboensis/doc/pics/rea-V.jpg -2021/07/24 | 68219 | fonts/aboensis/doc/pics/fields.png -2021/07/24 | 6785 | systems/win32/miktex/tm/packages/catechis__source.tar.lzma -2021/07/24 | 67169 | fonts/aboensis/doc/pics/rea-G.jpg -2021/07/24 | 66751 | fonts/aboensis/doc/pics/rea-L.jpg -2021/07/24 | 65894 | fonts/aboensis/doc/pics/rea-Q.jpg -2021/07/24 | 650474 | fonts/aboensis/doc/pics/photoshop-two.png -2021/07/24 | 637939 | systems/win32/miktex/tm/packages/xstring__doc.tar.lzma -2021/07/24 | 62930 | systems/win32/miktex/tm/packages/latexindent.tar.lzma -2021/07/24 | 61916 | fonts/aboensis/doc/pics/rea-T.jpg -2021/07/24 | 61170 | fonts/aboensis/doc/pics/rea-N.jpg -2021/07/24 | 6024 | systems/win32/miktex/tm/packages/texdimens__doc.tar.lzma -2021/07/24 | 594072 | systems/texlive/tlnet/archive/libertinus-otf.doc.r60023.tar.xz -2021/07/24 | 5929 | systems/win32/miktex/tm/packages/texdimens__source.tar.lzma -2021/07/24 | 587676 | systems/win32/miktex/tm/packages/libertinus-otf__doc.tar.lzma -2021/07/24 | 58261 | fonts/aboensis/doc/pics/rea-D.jpg -2021/07/24 | 5727 | systems/win32/miktex/tm/packages/letterswitharrows__source.tar.lzma -2021/07/24 | 572243 | fonts/aboensis/doc/pics/aboensis-27r.jpg -2021/07/24 | 565709 | fonts/aboensis/doc/pics/kununx_balk.jpg -2021/07/24 | 56369 | fonts/aboensis/doc/pics/rea-B.jpg -2021/07/24 | 5627 | macros/musixtex/tex/musixftab.tex -2021/07/24 | 5621 | systems/win32/miktex/tm/packages/stackengine.tar.lzma -2021/07/24 | 5451 | macros/musixtex/doc/musixdoc/frontmatter.tex -2021/07/24 | 52671 | systems/win32/miktex/tm/packages/spectralsequences__source.tar.lzma -2021/07/24 | 52288 | systems/win32/miktex/tm/packages/fontools.tar.lzma -2021/07/24 | 5130 | fonts/aboensis/MANIFEST-Aboensis.txt -2021/07/24 | 5084 | fonts/aboensis/doc/aboensis.bib -2021/07/24 | 50299 | fonts/aboensis/doc/pics/rea-A.jpg -2021/07/24 | 496570 | fonts/aboensis/doc/pics/aboensis-27v.jpg -2021/07/24 | 484213 | fonts/aboensis/doc/pics/REA-001r.jpg -2021/07/24 | 482607 | systems/win32/miktex/tm/packages/letterswitharrows__doc.tar.lzma -2021/07/24 | 481712 | systems/win32/miktex/tm/packages/babel-french__doc.tar.lzma -2021/07/24 | 47458 | systems/win32/miktex/tm/packages/pdfmanagement-testphase.tar.lzma -2021/07/24 | 47310 | fonts/aboensis/doc/pics/rea-O.jpg -2021/07/24 | 4630 | systems/win32/miktex/tm/packages/beamertheme-focus.tar.lzma -2021/07/24 | 4575 | systems/win32/miktex/tm/packages/xistercian.tar.lzma -2021/07/24 | 44837 | systems/win32/miktex/tm/packages/fithesis__source.tar.lzma -2021/07/24 | 44722 | fonts/aboensis/doc/pics/rea-C.jpg -2021/07/24 | 4392 | fonts/aboensis/OFL.txt -2021/07/24 | 398081 | systems/win32/miktex/tm/packages/catechis__doc.tar.lzma -2021/07/24 | 3961 | systems/win32/miktex/tm/packages/libertinus-otf.tar.lzma -2021/07/24 | 3928970 | info/latex2e-help-texinfo.zip -2021/07/24 | 38389 | systems/win32/miktex/tm/packages/xstring__source.tar.lzma -2021/07/24 | 383009 | fonts/aboensis/doc/pics/aboensis-30v.jpg -2021/07/24 | 38136 | macros/musixtex/doc/musixdoc/miscellaneous.tex -2021/07/24 | 3762 | systems/win32/miktex/tm/packages/variablelm.tar.lzma -2021/07/24 | 3728 | systems/texlive/tlnet/archive/libertinus-otf.r60023.tar.xz -2021/07/24 | 36991 | fonts/aboensis/doc/pics/rea-S.jpg -2021/07/24 | 35 | macros/musixtex/map/frenchtab.map -2021/07/24 | 350480 | systems/win32/miktex/tm/packages/stackengine__doc.tar.lzma -2021/07/24 | 3488 | systems/win32/miktex/tm/packages/letterswitharrows.tar.lzma -2021/07/24 | 3487 | systems/win32/miktex/tm/packages/ifallfalse__source.tar.lzma -2021/07/24 | 3439 | macros/musixtex/README -2021/07/24 | 325086 | fonts/aboensis/doc/pics/kalliala_fol16r.jpg -2021/07/24 | 32214 | systems/win32/miktex/tm/packages/luaxml.tar.lzma -2021/07/24 | 32060 | systems/texlive/tlnet/archive/luaxml.r60030.tar.xz -2021/07/24 | 3084 | systems/texlive/tlnet/archive/ifallfalse.source.r60027.tar.xz -2021/07/24 | 307779 | systems/win32/miktex/tm/packages/xistercian__doc.tar.lzma -2021/07/24 | 30641 | systems/win32/miktex/tm/packages/nicematrix.tar.lzma -2021/07/24 | 30404 | systems/win32/miktex/tm/packages/mcf2graph__source.tar.lzma -2021/07/24 | 302252 | fonts/aboensis/doc/pics/photoshop-one.png -2021/07/24 | 3013 | systems/win32/miktex/tm/packages/ut-thesis.tar.lzma -2021/07/24 | 299765 | fonts/aboensis/doc/pics/photoshop-alternatives.png -2021/07/24 | 288825 | fonts/aboensis/doc/pics/DF1423.jpg -2021/07/24 | 288252 | systems/win32/miktex/tm/packages/beamertheme-focus__doc.tar.lzma -2021/07/24 | 27641 | fonts/aboensis/doc/ab_symbols.tex -2021/07/24 | 262869 | fonts/aboensis/doc/aboensis.tex -2021/07/24 | 252 | macros/musixtex/doc/ChangeLog-134.txt -2021/07/24 | 2525761 | install/macros/musixtex.tds.zip -2021/07/24 | 2484586 | macros/musixtex.zip -2021/07/24 | 2413156 | fonts/aboensis/doc/pics/budde-9v.png -2021/07/24 | 24002 | systems/win32/miktex/tm/packages/mcf2graph.tar.lzma -2021/07/24 | 238466 | fonts/aboensis/doc/pics/REA-001r2.jpg -2021/07/24 | 219380 | macros/latex/contrib/mindflow.zip -2021/07/24 | 21443 | macros/latex/contrib/mindflow/mindflow.dtx -2021/07/24 | 209314 | systems/win32/miktex/tm/packages/beamertheme-focus__source.tar.lzma -2021/07/24 | 2081350 | fonts/aboensis/doc/pics/puupuntari.png -2021/07/24 | 207664 | macros/latex/contrib/mindflow/mindflow.pdf -2021/07/24 | 2049088 | fonts/aboensis/doc/pics/viipuri.jpg -2021/07/24 | 2028 | systems/win32/miktex/tm/packages/tiscreen__source.tar.lzma -2021/07/24 | 2022 | systems/win32/miktex/tm/packages/to-be-determined__source.tar.lzma -2021/07/24 | 1975 | fonts/aboensis/README -2021/07/24 | 196127 | macros/musixtex/tex/musixtex.tex -2021/07/24 | 19110 | fonts/aboensis/lppl.txt -2021/07/24 | 1893 | systems/win32/miktex/tm/packages/catechis.tar.lzma -2021/07/24 | 18907382 | fonts/aboensis/aboensis.pdf -2021/07/24 | 18656 | fonts/aboensis/ccby4.txt -2021/07/24 | 186403 | systems/win32/miktex/tm/packages/to-be-determined__doc.tar.lzma -2021/07/24 | 185327 | fonts/aboensis/doc/pics/aboensis-37v.jpg -2021/07/24 | 180622 | systems/win32/miktex/tm/packages/babel.tar.lzma -2021/07/24 | 1788647 | systems/win32/miktex/tm/packages/spectralsequences__doc.tar.lzma -2021/07/24 | 175538 | systems/win32/miktex/tm/packages/ifallfalse__doc.tar.lzma -2021/07/24 | 175068 | systems/texlive/tlnet/archive/ifallfalse.doc.r60027.tar.xz -2021/07/24 | 1749428 | systems/win32/miktex/tm/packages/nicematrix__doc.tar.lzma -2021/07/24 | 16947 | fonts/aboensis/aboensis.sty -2021/07/24 | 1666 | systems/win32/miktex/tm/packages/to-be-determined.tar.lzma -2021/07/24 | 162349 | fonts/aboensis/doc/pics/aboensis-39v.jpg -2021/07/24 | 161438 | info/latex2e-help-texinfo/ChangeLog -2021/07/24 | 16067 | systems/win32/miktex/tm/packages/babel-french.tar.lzma -2021/07/24 | 160561 | fonts/aboensis/doc/pics/aboensis-38v.jpg -2021/07/24 | 158908 | fonts/aboensis/doc/pics/aboensis-39r.jpg -2021/07/24 | 1583057 | info/latex2e-help-texinfo/latex2e.html -2021/07/24 | 1531321 | fonts/aboensis/doc/pics/SDHK20000.jpg -2021/07/24 | 146564 | fonts/aboensis/doc/pics/DF3001_fol2r.jpg -2021/07/24 | 1454 | systems/win32/miktex/tm/packages/ifallfalse.tar.lzma -2021/07/24 | 14449 | macros/musixtex/type1/frenchtab.pfb -2021/07/24 | 1416764 | macros/musixtex/doc/musixdoc.pdf -2021/07/24 | 141365 | systems/win32/miktex/tm/packages/ut-thesis__doc.tar.lzma -2021/07/24 | 1391 | systems/win32/miktex/tm/packages/tiscreen.tar.lzma -2021/07/24 | 138961 | fonts/aboensis/doc/pics/rea-E.jpg -2021/07/24 | 137860 | fonts/aboensis/Aboensis-Regular.otf -2021/07/24 | 1361 | info/latex2e-help-texinfo/README -2021/07/24 | 1356806 | info/latex2e-help-texinfo/latex2e.xml -2021/07/24 | 135271 | systems/win32/miktex/tm/packages/variablelm__doc.tar.lzma -2021/07/24 | 134584 | systems/win32/miktex/tm/packages/tiscreen__doc.tar.lzma -2021/07/24 | 1345654 | info/latex2e-help-texinfo/latex2e.pdf -2021/07/24 | 131246 | systems/win32/miktex/tm/packages/nicematrix__source.tar.lzma -2021/07/24 | 1304 | macros/musixtex/tfm/frenchtab.tfm -2021/07/24 | 1302 | systems/win32/miktex/tm/packages/variablelm__source.tar.lzma -2021/07/24 | 1297476 | fonts/aboensis/doc/pics/SDHK27022.jpg -2021/07/24 | 12928 | systems/win32/miktex/tm/packages/xistercian__source.tar.lzma -2021/07/24 | 126391 | systems/win32/miktex/tm/packages/fontools__doc.tar.lzma -2021/07/24 | 1248 | systems/texlive/tlnet/archive/ifallfalse.r60027.tar.xz -2021/07/24 | 123408 | systems/texlive/tlnet/archive/luaxml.doc.r60030.tar.xz -2021/07/24 | 120102 | systems/win32/miktex/tm/packages/pdfmanagement-testphase__source.tar.lzma -2021/07/24 | 119810 | macros/musixtex/doc/musixtex-install.pdf -2021/07/24 | 119667 | fonts/aboensis/doc/pics/rea-K.jpg -2021/07/24 | 11494 | systems/win32/miktex/tm/packages/xstring.tar.lzma -2021/07/24 | 114774 | systems/win32/miktex/tm/packages/luaxml__doc.tar.lzma -2021/07/24 | 1139410 | fonts/aboensis/Aboensis.glyphs -2021/07/24 | 113493 | systems/win32/miktex/tm/packages/latexindent__source.tar.lzma -2021/07/24 | 1104027 | fonts/aboensis/doc/pics/aboensis-78v.png -2021/07/24 | 10808 | systems/texlive/tlnet/archive/context-vim.doc.r60025.tar.xz -2021/07/24 | 1041784 | info/latex2e-help-texinfo/latex2e.dbk -2021/07/24 | 10116 | systems/texlive/tlnet/archive/context-vim.r60025.tar.xz -2021/07/24 | 100901 | fonts/aboensis/doc/pics/rea-W.jpg -2021/07/24 | 100459 | fonts/aboensis/doc/pics/rea-M.jpg diff --git a/info/install-latex-guide-zh-cn/appendix/mirror.tex b/info/install-latex-guide-zh-cn/appendix/mirror.tex index 6271c40112..b53358a868 100644 --- a/info/install-latex-guide-zh-cn/appendix/mirror.tex +++ b/info/install-latex-guide-zh-cn/appendix/mirror.tex @@ -39,6 +39,8 @@ & \url{http://mirrors.hust.edu.cn/CTAN/systems/texlive/}\\ \href{https://mirror.lzu.edu.cn/}{兰州大学} & \url{https://mirror.lzu.edu.cn/CTAN/systems/texlive/}\\ + \href{https://mirrors.sustech.edu.cn/}{南方科技大学} + & \url{https://mirrors.sustech.edu.cn/CTAN/systems/texlive/}\\ \href{https://mirrors.nju.edu.cn/}{南京大学} & \url{https://mirrors.nju.edu.cn/CTAN/systems/texlive/}\\ \href{https://mirrors.tuna.tsinghua.edu.cn/}{清华大学} @@ -102,4 +104,4 @@ 那么设置将变为 \begin{lstlisting} tlmgr option repository https://mirrors.tuna.tsinghua.edu.cn/CTAN/systems/texlive/tlnet -\end{lstlisting} \ No newline at end of file +\end{lstlisting} diff --git a/info/install-latex-guide-zh-cn/appendix/updateinfo.tex b/info/install-latex-guide-zh-cn/appendix/updateinfo.tex index e4148089ec..7debec6c3a 100644 --- a/info/install-latex-guide-zh-cn/appendix/updateinfo.tex +++ b/info/install-latex-guide-zh-cn/appendix/updateinfo.tex @@ -2,6 +2,15 @@ \chapter{版本信息} +\section*{v2021.8.1} + +\begin{enumerate} + \item 改动一些文本上的小问题 + \item 改动错误的链接 + \item 添加南方科技大学镜像 + \item 添加 Windows 10 系统内注册表位置 +\end{enumerate} + \section*{v2021.7.3} \begin{enumerate} @@ -136,7 +145,7 @@ \item 添加版本信息列表 \item 改变 Windows 10 的 \TeX studio 的下载网址 \item 添加 macOS 中 \texttt{xelatex} 用字体名调用字体的方法 - \item 详述 WSL 中不懂 vim 的处理方法和阅读宏包手册的方法 + \item 详述 WSL 中不懂 \textsf{vim} 的处理方法和阅读宏包手册的方法 \item 强调路径为不带空格的英文 \item 订正若干拼写错误 \item 给出 \texttt{jdk} 环境变量的处理 diff --git a/info/install-latex-guide-zh-cn/chapter/macos.tex b/info/install-latex-guide-zh-cn/chapter/macos.tex index 400325a36e..ec188c6dba 100644 --- a/info/install-latex-guide-zh-cn/chapter/macos.tex +++ b/info/install-latex-guide-zh-cn/chapter/macos.tex @@ -11,7 +11,7 @@ Homebrew 是一个包管理, 类似 Ubuntu 上面的 \texttt{apt-get}. /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" \end{lstlisting} 将以上命令在\textsf{终端}\footnote{% - 打开方法为: \keys{\cmdmac + \SPACE}, 输入 terminal 并打开 \menu{终端} 应用}% + 打开方法为: \keys{\cmdmac + \SPACE}, 输入 \textsf{terminal} 并打开 \menu{终端} 应用}% 执行. 脚本会在执行前暂停, 并说明它将做什么. 依据屏幕指令执行即可. diff --git a/info/install-latex-guide-zh-cn/chapter/ubuntu.tex b/info/install-latex-guide-zh-cn/chapter/ubuntu.tex index 4f175c2aee..5f3dd174e1 100644 --- a/info/install-latex-guide-zh-cn/chapter/ubuntu.tex +++ b/info/install-latex-guide-zh-cn/chapter/ubuntu.tex @@ -217,7 +217,7 @@ \subsection{卸载源内的版本} 如果要卸载从源内安装的 \TeX{} Live, 个人比较推荐使用 synaptic package manager. -\textsf{terminal} 中执行 +在 \textsf{Terminal} 中执行 \begin{lstlisting}[language = bash] sudo apt install synaptic \end{lstlisting} @@ -242,7 +242,7 @@ 如果是从光盘镜像安装, 直接删除文件夹即可. -先在\textsf{terminal} 中执行 +先在\textsf{Terminal} 中执行 \begin{lstlisting}[language = bash] kpsewhich -var-value TEXMFROOT \end{lstlisting} @@ -289,7 +289,7 @@ please get the new TL by doing a new installation instead of proceeding here}. \section{升级宏包}\label{sec:ubuntu:update} 首次升级前, -在 \textsf{terminal} 中执行 +在 \textsf{Terminal} 中执行 \begin{lstlisting}[language = bash] sudo visudo \end{lstlisting} @@ -301,7 +301,7 @@ please get the new TL by doing a new installation instead of proceeding here}. \footnote{这里只讨论默认安装的情况}. 然后依次 \keys{\ctrl + X}, \keys{Y}, \keys{\enter} 保存退出. -接下来在 \textsf{terminal} 中执行 +接下来在 \textsf{Terminal} 中执行 \begin{lstlisting}[language = bash] sudo tlmgr option repository ctan \end{lstlisting} @@ -326,14 +326,14 @@ Ubuntu 20.04 下安装宏包的要求与 Windows 10 下没有多少区别, 只 \begin{lstlisting}[language = bash] sudo tlmgr install mcmthesis \end{lstlisting} -即安装了 mcmthesis. +即安装了 \texttt{mcmthesis} 宏包. \section{调出宏包手册}\label{sec:ubuntu:texdoc} 与 Windows 10 类似, 当正确安装后, 用户可以调出宏包手册以查阅相应内容. -例如在 \textsf{terminal} 中执行 +例如在 \textsf{Terminal} 中执行 \begin{lstlisting}[language=bash] texdoc texlive-zh-cn \end{lstlisting} diff --git a/info/install-latex-guide-zh-cn/chapter/windows.tex b/info/install-latex-guide-zh-cn/chapter/windows.tex index 987fac9a5c..04ef8e35a6 100644 --- a/info/install-latex-guide-zh-cn/chapter/windows.tex +++ b/info/install-latex-guide-zh-cn/chapter/windows.tex @@ -295,6 +295,10 @@ HKEY_CURRENT_USER\Software\Classes\TL.DVIOUT.view.2021 HKEY_CURRENT_USER\Software\Classes\TL.TeXworks.edit.2021 HKEY_CURRENT_USER\Software\Classes\TL.PSViewer.view.2021 + HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts\TL.bitmap2eps.convert.2021_.jpg + HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts\TL.bitmap2eps.convert.2021_.png + HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts\TL.TeXworks.edit.2021_.sty + HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts\TL.TeXworks.edit.2021_.tex \end{lstlisting} 但若在安装时使用管理员权限``为所有人安装'', 则注册表位置将变为 diff --git a/info/install-latex-guide-zh-cn/chapter/wsl.tex b/info/install-latex-guide-zh-cn/chapter/wsl.tex index 1f43e90035..cbb5787095 100644 --- a/info/install-latex-guide-zh-cn/chapter/wsl.tex +++ b/info/install-latex-guide-zh-cn/chapter/wsl.tex @@ -27,7 +27,7 @@ \end{lstlisting} 这些命令是为了处理日后使用中可能出现的字体问题. 为避免安装速度过慢, -可仿照 \ref{subsec:ubuntu:xelatexfail}~节更改文件 \texttt{sources.list}. +可仿照 \ref{subsec:fc-cache}~节更改文件 \texttt{sources.list}. 注意 WSL 中无法启动 \textsf{gedit}, 因此需要将其替换为 \textsf{vim}, 即 diff --git a/info/install-latex-guide-zh-cn/install-latex-guide-zh-cn.pdf b/info/install-latex-guide-zh-cn/install-latex-guide-zh-cn.pdf index 73340249d3..c6ad66c4b0 100644 Binary files a/info/install-latex-guide-zh-cn/install-latex-guide-zh-cn.pdf and b/info/install-latex-guide-zh-cn/install-latex-guide-zh-cn.pdf differ diff --git a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.pdf b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.pdf index 887c0c24d5..b3105ee177 100644 Binary files a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.pdf and b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.pdf differ diff --git a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.tex b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.tex index a8b00f9b10..9faf0c8ff5 100644 --- a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.tex +++ b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices-doc.tex @@ -1,3 +1,7 @@ +% !TeX encoding = UTF-8 +% !TeX TS-program = pdflatex +% !TeX spellcheck = en_GB + %%-------------------------------------------------------------------- %%-------------------------------------------------------------------- %% exam-randomizechoices-doc.tex @@ -8,7 +12,7 @@ %% The package itself is in the file exam-randomizechoices.sty. -%% Copyright (c)2019, Jesse E. J. op den Brouw +%% Copyright (c)2021, Jesse E. J. op den Brouw %% %% This work may be distributed and/or modified under the %% conditions of the LaTeX Project Public License, either version 1.3 @@ -34,28 +38,27 @@ %% J.E.J.opdenBrouw@hhs.nl %% The newest version of this package should always be available -%% from BitBucket: https://bitbucket.org/jesseopdenbrouw/exam-randomizechoices/src/master/ +%% from GitHub: https://github.com/jesseopdenbrouw/exam-randomizechoices %-------------------------------------------------------------------- %-------------------------------------------------------------------- \documentclass[12pt,a4paper]{exam} -\newcommand{\styversion}{\fileversion} -\newcommand{\stydate}{\filedate} -\newcommand{\docdate}{January 9, 2019} -%\newcommand{\docdate}{Draft: \today} +\newcommand{\styversion}{0.2} +\newcommand{\stydate}{July 31, 2021} +\newcommand{\docdate}{July 31, 2021} \usepackage{mathtools} %\usepackage{amssymb} %% Set input encoding to UTF-8 -\usepackage[utf8]{inputenc} +%\usepackage[utf8]{inputenc} %% Use T1 output font encoding \usepackage[T1]{fontenc} %% Set page layout -\usepackage[a4paper,left=1.0in,right=1.0in,top=1.0in,bottom=1.4in,footskip=0.5in]{geometry} +\usepackage[a4paper,left=1.0in,right=1.0in,top=1.0in,bottom=1.31in,footskip=0.4in]{geometry} %% Use package enumitem \usepackage{enumitem} @@ -96,9 +99,9 @@ breakatwhitespace=true, title=\lstname, upquote=true, - aboveskip=0.3\baselineskip, - belowskip=-.5\baselineskip, - escapeinside={(*}{*)} + aboveskip=0.99\baselineskip, + belowskip=-.99\baselineskip, + escapeinside={(*}{*)}, } \usepackage[colorlinks,linkcolor=blue]{hyperref} @@ -120,6 +123,9 @@ %% parskip et al. \usepackage{parskip} +%% filecontents +%\usepackage{filecontents} + %% The randomization package \usepackage[randomize,nokeeplast]{exam-randomizechoices} @@ -132,6 +138,20 @@ % without generating pdf warnings: \newcommand{\bs}{\texorpdfstring{\char`\\}{}} +% Redefine \LaTeX a bit... +\makeatletter +\DeclareRobustCommand{\LaTeX}{L\kern-.25em% + {\sbox\z@ T% + \vbox to\ht\z@{\hbox{\check@mathfonts + \fontsize\sf@size\z@ + \math@fontsfalse\selectfont + A}% + \vss}% + }% + \kern-.05em% + \TeX} +\makeatother + %--------------------------------------------------------------------- %--------------------------------------------------------------------- @@ -143,7 +163,7 @@ \cfoot[]{Page \thepage\ of \numpages} -\title{The \texttt{exam-randomizechoices} package\\[2ex]\normalsize LaTeX package for creating random placed choices in multiple choice \\environments using the \texttt{exam} document class} +\title{The \texttt{exam-randomizechoices} package\\[2ex]\normalsize \LaTeX{} package for creating random placed choices in multiple choice \\environments using the \texttt{exam} document class} \author{Jesse op den Brouw\\ Department of Electrical Engineering\\ @@ -165,7 +185,7 @@ \begin{center} \small This is the user's guide for version~\styversion{} [\stydate] of the - \verb|exam-randomizechoices| package. + \verb|exam-randomizechoices| package. \end{center} \clearpage @@ -205,9 +225,10 @@ implied warranties of merchantability and fitness for a particular purpose. \subsection{Where to find} -The development version of this package is available on BitBucket. See +The development version of this package is available on GitHub. See -\url{https://bitbucket.org/jesseopdenbrouw/exam-randomizechoices/} +%\url{https://bitbucket.org/jesseopdenbrouw/exam-randomizechoices/} +\url{https://github.com/jesseopdenbrouw/exam-randomizechoices} \subsection{Acknowledgements} The author wishes to thank the developers of the \verb|exam| document @@ -221,7 +242,7 @@ to the author. Please use a recent version of the \texttt{exam} document class. This package is tested with version 2.603 which is available in most distributions. -Testing with version 2.605\$\bs beta\$ is planned. +Testing with version 2.606\$\bs beta\$ is planned. \subsection{A word about reading this document} This document uses terminology which is described below: @@ -461,6 +482,7 @@ which typesets to: The \texttt{oneparcheckboxes} environment typesets the choices in al linear, horizontal way. An example is given below: + \begin{lstlisting} \question[5] What is the result of $1+2$? @@ -636,7 +658,7 @@ is the default behaviour of the package. \end{description} Sometimes you want the last given item to stick on its place. This is useful -if you want to use an choice item if none of the other choices are correct: +if you want to use a choice item if none of the other choices are correct: \begin{lstlisting} \question[5] What is the result of $2+5$? @@ -729,7 +751,7 @@ multiple choice environments now accept arguments just as their randomizing counterparts do. -\subsection{Seeding rhe pseudo random generator} +\subsection{Seeding the pseudo random generator} \label{sec:seeding} To get a consistent randomization, you must seed the pseudo random generator with the same seed every time you compile your document. You can set the @@ -738,7 +760,7 @@ argument that is an integer between 0 and $2^{31}-1$, \TeX's largest integer. Internally, the PGF macro \texttt{\bs pgfmathsetseed} is called, and it is flagged that you applied a seed. If you fail to do so, the seeding value is \texttt{\bs time}$\times$\texttt{\bs year} as stated by the PFG manual% -\footnote{Version 3.0.1a, page 940.}. \LaTeX\ compilers keep track of +\footnote{Version 3.1.9a, page 1046.}. \LaTeX\ compilers keep track of time by an integer that holds the minutes counted since midnight. The integer is incremented every time the time passes a minute boundary. So the scenario can be that you compile your document a couple of times with no apparent @@ -778,12 +800,28 @@ table entry will contain \textbf{??}, otherwise it will contain the used typeset The key table is typeset using the \texttt{tabular} environment, so it can be wrapped in a \texttt{table} environment. +The \texttt{\bs printkeytable} macro accepts an optional range as in: +\begin{lstlisting} +\printkeytable[21-40] +\end{lstlisting} + +It will typeset only the keys in this range. This is useful for generating +side-by-side key tables. The start question number may be omitted, in which +case the table starts at 1. The end question number may be omitted, in which +case the table will be typeset up to the last question. + An example of a key table is presented below. Note the \textbf{??} in the -Answer column. This is the result of using the standard multiple choice +Key column. This is the result of using the standard multiple choice environments (they are not overloaded, so no label is applied). +Usage of \texttt{\bs printkeytable} + \printkeytable +Usage of \texttt{\bs printkeytable[...-...]} + +\printkeytable[1-3]\quad\printkeytable[4-6]\quad\printkeytable[7-8] + The text in the table header row can be changed using two command: the command \texttt{\bs keylistquestionname} sets the text above the question numbers, which defaults to ``Question'', the command \texttt{\bs keylistkeyname} sets the text @@ -794,6 +832,39 @@ above the keys, which defaults to ``Key''. A typical use could be: \keylistkeyname{Answer Key} \end{lstlisting} +\subsection{Saving the keys to a macro} +It is possible to save the question numbers and the corresponding keys to +a macro. Please note that only the environments \texttt{randomizechoices}, +\texttt{randomizeoneparchoices}, \texttt{choices} (if overloaded) and +\texttt{oneparchoices} (if overloaded) can have valid keys in the key list. + +Saving a key list file is started by the command: + +\begin{lstlisting} +\savekeylist[(*\textsl{\textrm{command name}}*)] +\end{lstlisting} + +The optional argument is the macro name, including the \bs. if none is +supplied, it defaults to \texttt{\bs keylist} +The key list itself is constructed as a comma-separated list. The question +number and answer keys are separated with a `/'. This makes it easy to +parse the list with PGF's \texttt{\bs foreach} command (using \texttt{\bs +mykeylist} as command name): + +\savekeylist[\mykeylist] + +\begin{lstlisting} +\foreach \num/\key in \mykeylist { + \textcolor{green!\num0!red} {question \num\ has key \key} \\ +} +\end{lstlisting} + +which typesets to: + +\foreach \num/\key in \mykeylist { + \textcolor{green!\num0!red} {question \num\ has key \key} \\ +} + \subsection{Writing the keys to a file} The package provides the writing of the keys to the file. Please note that only the environments \texttt{randomizechoices}, @@ -815,7 +886,7 @@ that assigns the key list to the supplied command name (in this case \texttt{\bs mykeylist}). \writekeylist{\mykeylist} -\vspace*{\baselineskip} +%\vspace*{\baselineskip} \lstinputlisting[caption=]{\jobname.keylist} \vspace*{1.5\baselineskip} @@ -858,59 +929,160 @@ labelling mechanism supports only at the question level. \subsection{Verbatim environments} Verbatim environments such as \texttt{verbatim} and \texttt{lstlistings} -are currently \emph{not} supported in the new and (overloaded) standard multiple +are \emph{not} supported in the new and overloaded standard multiple choice environments. This is due to the way the contents of these environments -are collected. The \texttt{\bs verb} command is also not supported by the package -but \texttt{\bs lstinline} is. An example, translated to English from a Dutch exam -on the ATmega32 microcontroller chip: +are collected. The contents is first read by \TeX{} and spaces at the end +of a line are removed, and the end-of-line character is replaced by a space. +This will disrupt the formatted code in the verbatim environments. +There is extensive discussion on StackExchange on how to tackle this problem. +One could use a \texttt{verbatimbox} environment which puts the contents in +a box, or one could use the \texttt{VerbatimOut} environment which writes +the contents to a file for later inclusion. A portable solution would +be to write contents to (separate) files and include them. In the following +example using the \texttt{filecontents*} environment, four temporary files +are created and included using the \verb|\lstinputlisting| macro. \begin{lstlisting} +% Use \usepackage{filecontents} in preamble +% \question[5] -The individual pins of Port D can be configured as input or output. -The single bits of Port D are called PD7, PD6, PD5, PD4, PD3, PD2, -PD1 and PD0. Which of the following alternatives configures PD0, PD1, -PD6 and PD7 as output and the remaining pins as input? +Which of the four alternative computes the sum of the integers 1 +to 10 (inclusive)? + +\begin{filecontents*}{\jobname a.c} +sum = 0; +for (i=0; i<10; i++) { + sum += i; +} +\end{filecontents*} +\begin{filecontents*}{\jobname b.c} +sum = 0; +for (i=1; i<11; i++) { + sum += i; +} +\end{filecontents*} +\begin{filecontents*}{\jobname c.c} +sum = 0; i = 11; +while (i>0) { + sum +- i; + i--; +} +\end{filecontents*} +\begin{filecontents*}{\jobname d.c} +sum = 0; i = 0; +do { + sum += i; + i++; +} while (i<10); +\end{filecontents*} \begin{randomizechoices} -\choice \lstinline|out DDRD,0x3c| -\CorrectChoice \lstinline|ldi r20,0xc3| \par \lstinline|out DDRD,r20| -\choice \lstinline|out PORTD,0x3c| -\choice \lstinline|ldi r20,195| \par \lstinline|PORTD,r20| +\choice \lstinputlisting{\jobname a.c}\par % please use \par otherwise label get clobbered +\CorrectChoice \lstinputlisting{\jobname b.c}\par +\choice \lstinputlisting{\jobname c.c}\par +\choice \lstinputlisting{\jobname d.c}\par \end{randomizechoices} \end{lstlisting} -typesets possibly to: +which will typically typeset to: \begin{questions} -\setlength{\parskip}{0pt} \setcounter{question}{8} \question[5] -The individual pins of Port D can be configured as input or output. The single bits -of Port D are called PD7, PD6, PD5, PD4, PD3, PD2, PD1 and PD0. Which of the -following alternatives configures PD0, PD1, PD6 and PD7 as output and the remaining -pins as input? - -%%Original Dutch text -%%De individuele pinnen van Port D kunnen als ingang of uitgang geconfigureerd worden. De -%%enkelvoudige bits van Port D worden PD7, PD6, PD5, PD4, PD3, PD2, PD1, PD0 genoemd. -%%Welk van de volgende alternatieven configureert PD0, PD1, PD6 en PD7 als uitgang en de -%%overige pinnen als ingang? -% -%\hspace*{\baselineskip} +Which of the four alternative computes the sum of the integers 1 to 10 (inclusive)? + +\begin{filecontents*}{\jobname a.c} +sum = 0; +for (i=0; i<10; i++) { + sum += i; +} +\end{filecontents*} +\begin{filecontents*}{\jobname b.c} +sum = 0; +for (i=1; i<11; i++) { + sum += i; +} +\end{filecontents*} +\begin{filecontents*}{\jobname c.c} +sum = 0; i = 11; +while (i>0) { + sum +- i; + i--; +} +\end{filecontents*} +\begin{filecontents*}{\jobname d.c} +sum = 0; i = 0; +do { + sum += i; + i++; +} while (i<10); +\end{filecontents*} -\begin{randomizechoices}[norandomize] - \choice \lstinline|out DDRD,0x3c| - \CorrectChoice \lstinline|ldi r20,0xc3| \par \lstinline|out DDRD,r20| - \choice \lstinline|out PORTD,0x3c| - \choice \lstinline|ldi r20,195| \par \lstinline|PORTD,r20| +\begin{randomizechoices} +\choice \lstinputlisting[caption=,frame=none,numbers=none]{\jobname a.c}\par % please use \par otherwise label get clobbered +\CorrectChoice \lstinputlisting[caption=,frame=none,numbers=none]{\jobname b.c}\par +\choice \lstinputlisting[caption=,frame=none,numbers=none]{\jobname c.c}\par +\choice \lstinputlisting[caption=,frame=none,numbers=none,belowskip=0pt]{\jobname d.c}\par \end{randomizechoices} + \end{questions} +Please note that the \texttt{\bs verb} command is also not supported by the package +but \texttt{\bs lstinline} command is. + +%% An example, translated to English from a Dutch exam +%%on the ATmega32 microcontroller chip: +%% +%%\begin{lstlisting} +%%\question[5] +%%The individual pins of Port D can be configured as input or output. +%%The single bits of Port D are called PD7, PD6, PD5, PD4, PD3, PD2, +%%PD1 and PD0. Which of the following alternatives configures PD0, PD1, +%%PD6 and PD7 as output and the remaining pins as input? +%% +%%\begin{randomizechoices} +%%\choice \lstinline|out DDRD,0x3c| +%%\CorrectChoice \lstinline|ldi r20,0xc3| \par \lstinline|out DDRD,r20| +%%\choice \lstinline|out PORTD,0x3c| +%%\choice \lstinline|ldi r20,195| \par \lstinline|PORTD,r20| +%%\end{randomizechoices} +%%\end{lstlisting} +%% +%%typesets possibly to: +%% +%%\begin{questions} +%%\setlength{\parskip}{0pt} +%%\setcounter{question}{8} +%%\question[5] +%%The individual pins of Port D can be configured as input or output. The single bits +%%of Port D are called PD7, PD6, PD5, PD4, PD3, PD2, PD1 and PD0. Which of the +%%following alternatives configures PD0, PD1, PD6 and PD7 as output and the remaining +%%pins as input? +%% +%%%%Original Dutch text +%%%%De individuele pinnen van Port D kunnen als ingang of uitgang geconfigureerd worden. De +%%%%enkelvoudige bits van Port D worden PD7, PD6, PD5, PD4, PD3, PD2, PD1, PD0 genoemd. +%%%%Welk van de volgende alternatieven configureert PD0, PD1, PD6 en PD7 als uitgang en de +%%%%overige pinnen als ingang? +%%% +%%%\hspace*{\baselineskip} +%% +%%\begin{randomizechoices}[norandomize] +%% \choice \lstinline|out DDRD,0x3c| +%% \CorrectChoice \lstinline|ldi r20,0xc3| \par \lstinline|out DDRD,r20| +%% \choice \lstinline|out PORTD,0x3c| +%% \choice \lstinline|ldi r20,195| \par \lstinline|PORTD,r20| +%%\end{randomizechoices} +%%\end{questions} + \subsection{Accessing the internal labels} Each \texttt{\bs question} command is accompanied with a label of the form \texttt{question@}$x$ as provided by the \texttt{exam} document class, where -$x$ is the decimal number of the question. A \texttt{\bs CorrectChoice} -command is provided with a label (by this package) of the form \linebreak \texttt{question@}$x$% +$x$ is the decimal number of the question. Within the the environments +\texttt{randomizechoices}, \texttt{randomizeoneparchoices}, \texttt{choices} +(if overloaded) and \texttt{oneparchoices} (if overloaded), a +\texttt{\bs CorrectChoice} command is provided with a label (by this package) +of the form \texttt{question@}$x$% \texttt{@correctchoice} where $x$ is again the decimal number of the question. The user can access these labels by using the \texttt{\bs ref} command as shown below: @@ -925,7 +1097,7 @@ which typesets to: The question number is~\ref{question@9} and the correct answer is~\ref{question@9@correctchoice}. -There is no need to change the cat code of `@'. +%There is no need to change the cat code of `@'. \subsection{Error messages} The package will throw you some error messages in case something is wrong. The @@ -1015,10 +1187,10 @@ So when the environment is used as in: \choice two \CorrectChoice three \choice four -\end{randomizechoices +\end{randomizechoices} \end{lstlisting} -the \texttt{\bs BODY} command now contains (comments and newlines are stripped): +the \texttt{\bs BODY} command now contains (comments and newlines are stripped by \TeX): \begin{lstlisting} \choice one \choice two \CorrectChoice three \choice four @@ -1117,7 +1289,7 @@ I've been using the \texttt{exam} document class for five years now. What I like is the consistent typesetting of my exams. I don't use sub parts and sub-sub parts because in my opinion this not the right way to prepare an exam. I've written a department consistent class that provides the department's cover pages and some -other typesetting trickery. This class is used by a small core \TeX\ users. Regrettably, +other typesetting trickery. This class is used by a small core of \TeX\ users. Regrettably, the majority of my colleagues use Word *cough*. \end{document} \ No newline at end of file diff --git a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.pdf b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.pdf index 23bb5f5541..557f3e7b82 100644 Binary files a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.pdf and b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.pdf differ diff --git a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.sty b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.sty index 29779b1fc6..b64ae9982c 100644 --- a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.sty +++ b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.sty @@ -1,9 +1,9 @@ %% %% exam-randomizechoices.sty %% -%% Randomize mc choices using the exam class +%% Randomize m.c. choices using the exam class %% -%% Copyright (c)2019, Jesse E. J. op den Brouw +%% Copyright (c)2021, Jesse E. J. op den Brouw %% %% This work may be distributed and/or modified under the %% conditions of the LaTeX Project Public License, either version 1.3 @@ -29,7 +29,12 @@ %% J.E.J.opdenBrouw@hhs.nl %% The newest version of this package should always be available -%% from BitBucket: https://bitbucket.org/jesseopdenbrouw/exam-randomizechoices/src/master/ +%% from GitHub: https://github.com/jesseopdenbrouw/exam-randomizechoices + +%% Version 0.1 [09/01/2019]: Initial release +%% Version 0.2 [31/07/2021]: Added \savekeylist +%% Adapted \printkeytable to accept optional range +%% Minor cosmetic changes %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% @@ -38,8 +43,8 @@ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \NeedsTeXFormat{LaTeX2e}[1994/06/01] %% Version and date -\gdef\fileversion{0.1} -\gdef\filedate{2019/01/09} +\def\fileversion{0.2} +\def\filedate{2021/07/31} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% @@ -96,10 +101,9 @@ %% %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % http://ctan.org/pkg/{environ,etoolbox,pgffor} -\@ifpackageloaded{environ}{\if@@ercdebug\PackageWarning{exam-randomizechoicces}{Package environ already loaded}\fi}{\RequirePackage{environ}} -\@ifpackageloaded{etoolbox}{\if@@ercdebug\PackageWarning{exam-randomizechoicces}{Package etoolbox already loaded}\fi}{\RequirePackage{etoolbox}} -\@ifpackageloaded{pgffor}{\if@@ercdebug\PackageWarning{exam-randomizechoicces}{Package pgffor already loaded}\fi}{\RequirePackage{pgffor}} - +\RequirePackage{environ} +\RequirePackage{etoolbox} +\RequirePackage{pgffor} %% A scratch counter \newcounter{erc@counter} @@ -276,7 +280,7 @@ \fi \fi %% - %% We travel the list items. If an item begin with the special marker + %% We travel the list items. If an item begins with the special marker %% \inaccessible, we prepend it with \correctchoice, otherwise we prepend it %% with \choice. At the end we have all the list items prepended with %% either \choice or \correctchoice. Then we append the list item to @@ -321,8 +325,8 @@ \fi %% Save choices environment - \let\@oldchoices\choices - \let\end@oldchoices\endchoices + \let\erc@oldchoices\choices + \let\enderc@oldchoices\endchoices %% Renew the choices environment \RenewEnviron{choices}[1][]{ @@ -331,10 +335,10 @@ \erc@createrandomlist[#1]% %% %% Start the choices environment - \begin{@oldchoices}% + \begin{erc@oldchoices}% % Execute the list \erc@typesetchoices% - \end{@oldchoices}% + \end{erc@oldchoices}% } \NewEnviron{randomizechoices}[1][]{ @@ -343,10 +347,10 @@ \erc@createrandomlist[#1]% %% %% Start the choices environment - \begin{@oldchoices}% + \begin{erc@oldchoices}% % Execute the list \erc@typesetchoices% - \end{@oldchoices}% + \end{erc@oldchoices}% } \else \NewEnviron{randomizechoices}[1][]{ @@ -371,8 +375,8 @@ \fi %% Save oneparchoices environment - \let\@oldoneparchoices\oneparchoices - \let\end@oldoneparchoices\endoneparchoices + \let\erc@oldoneparchoices\oneparchoices + \let\enderc@oldoneparchoices\endoneparchoices %% Renew the oneparchoices environment \RenewEnviron{oneparchoices}[1][]{ @@ -381,10 +385,10 @@ \erc@createrandomlist[#1]% %% %% Start the oneparchoices environment - \begin{@oldoneparchoices}% + \begin{erc@oldoneparchoices}% % Execute the list \erc@typesetchoices - \end{@oldoneparchoices}% + \end{erc@oldoneparchoices}% } \NewEnviron{randomizeoneparchoices}[1][]{ @@ -393,10 +397,10 @@ \erc@createrandomlist[#1]% %% %% Start the oneparchoices environment - \begin{@oldoneparchoices}% + \begin{erc@oldoneparchoices}% % Execute the list \erc@typesetchoices% - \end{@oldoneparchoices}% + \end{erc@oldoneparchoices}% } \else \NewEnviron{randomizeoneparchoices}[1][]{ @@ -421,8 +425,8 @@ \fi %% Save choices environment - \let\@oldcheckboxes\checkboxes - \let\end@oldcheckboxes\endcheckboxes + \let\erc@oldcheckboxes\checkboxes + \let\enderc@oldcheckboxes\endcheckboxes %% Renew the oneparchoices environment \RenewEnviron{checkboxes}[1][]{ @@ -431,10 +435,10 @@ \erc@createrandomlist[#1,nolabel]% %% %% Start the choices environment - \begin{@oldcheckboxes}% + \begin{erc@oldcheckboxes}% % Execute the list \erc@typesetchoices% - \end{@oldcheckboxes}% + \end{erc@oldcheckboxes}% } \NewEnviron{randomizecheckboxes}[1][]{% @@ -443,10 +447,10 @@ \erc@createrandomlist[#1,nolabel]% %% %% Start the choices environment - \begin{@oldcheckboxes}% + \begin{erc@oldcheckboxes}% % Execute the list \erc@typesetchoices% - \end{@oldcheckboxes}% + \end{erc@oldcheckboxes}% } \else \NewEnviron{randomizecheckboxes}[1][]{ @@ -471,8 +475,8 @@ \fi %% Save oneparcheckboxes environment - \let\@oldoneparcheckboxes\oneparcheckboxes - \let\end@oldoneparcheckboxes\endoneparcheckboxes + \let\erc@oldoneparcheckboxes\oneparcheckboxes + \let\enderc@oldoneparcheckboxes\endoneparcheckboxes %% Renew the oneparcheckboxes environment \RenewEnviron{oneparcheckboxes}[1][]{ @@ -481,10 +485,10 @@ \erc@createrandomlist[#1,nolabel]% %% %% Start the oneparcheckboxes environment - \begin{@oldoneparcheckboxes}% + \begin{erc@oldoneparcheckboxes}% % Execute the list \erc@typesetchoices% - \end{@oldoneparcheckboxes}% + \end{erc@oldoneparcheckboxes}% } \NewEnviron{randomizeoneparcheckboxes}[1][]{% @@ -493,10 +497,10 @@ \erc@createrandomlist[#1,nolabel]% %% %% Start the oneparcheckboxes environment - \begin{@oldoneparcheckboxes}% + \begin{erc@oldoneparcheckboxes}% % Execute the list \erc@typesetchoices% - \end{@oldoneparcheckboxes}% + \end{erc@oldoneparcheckboxes}% } \else \NewEnviron{randomizeoneparcheckboxes}[1][]{% @@ -513,13 +517,28 @@ \fi %% -%% Simple key table printer +%% Simple key table printer, with key range %% %% Building a table with \foreach from the pgffor package is hard to do. %% See https://tex.stackexchange.com/questions/367979/latex-foreach-in-tabular-environment %% So we use \gappto and \xappto to build the table. At the end, we expand the macro %% -\newcommand{\printkeytable}{% + +\newcounter{erc@printstart}\setcounter{erc@printstart}{0} +\newcounter{erc@printstop}\setcounter{erc@printstop}{0} + +\newcommand{\printkeytable}[1][-]{% + \erc@printkeytable#1\@nil% +} + +\def\erc@printkeytable#1-#2\@nil{% + %% Grab arguments + \setcounter{erc@printstart}{0#1}% + \setcounter{erc@printstop}{0#2}% + %% Sanity check + \ifnum\value{erc@printstart}<1\setcounter{erc@printstart}{1}\fi% + \ifnum\value{erc@printstop}<1\setcounter{erc@printstop}{\thequestion}\fi% + \ifnum\value{erc@printstop}>\thequestion\setcounter{erc@printstop}{\thequestion}\fi% \if@@ercdebug \PackageWarning{exam-randomizechoices}{Writing key table}% \fi @@ -527,14 +546,15 @@ \xdef\erc@keytable{}% %% %% Add the preamble of the table {regular tabular} - \gappto\erc@keytable{\begin{tabular} {|c|c|} \hline}% + \gappto\erc@keytable{\begin{tabular}[t] {|c|c|} \hline}% \xappto\erc@keytable{\erc@keylistquestionname\space & \erc@keylistkeyname}% \gappto\erc@keytable{ \\ \hline}% %% %% Write the table entries. \ifnum\thequestion=0\relax \else - \foreach \x in {1,...,\thequestion} {% +% \foreach \x in {1,...,\thequestion} {% + \foreach \x in {\arabic{erc@printstart},...,\arabic{erc@printstop}} {% %% %% Add '\ref{question@\x} & ', \x should be expandend, \ref not \gappto\erc@keytable{\ref}% @@ -611,4 +631,35 @@ \fi } +%% +%% Simple key list saver. Saves the key list in a macro +%% +\def\savekeylist{\@ifnextchar[{\erc@savekeylist}{\erc@savekeylist[\keylist]}}% +\def\erc@savekeylist[#1]{% + %% + \if@@ercdebug + \PackageWarning{exam-randomizechoices}{Saving key list to macro}% + \fi + %% + %% Create a command that has all the question numbers / question keys + %% separated by a / (but nothing if there are no questions) + \ifnum\thequestion=0\relax + \gdef\erc@keylist{}% + \else + %% Write the list entries. + \gdef\erc@keylist{\@gobble}% + \foreach \x in {1,...,\thequestion} {% + \@ifundefined{r@question@\x @correctchoice}{% + %not found + \xdef\erc@keylist{\erc@keylist,\x/?}% + }{% + %found + \xdef\erc@keylist{\erc@keylist,\x/\getrefnumber{question@\x @correctchoice}}% + }% + }% + \fi% + %% Save the keylist in the supplied macro + \expandafter\xdef\expandafter#1\expandafter{\erc@keylist}% +} + \endinput diff --git a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.tex b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.tex index fe6650496d..925ca7f04f 100644 --- a/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.tex +++ b/macros/latex/contrib/exam-randomizechoices/exam-randomizechoices.tex @@ -3,7 +3,7 @@ %% %% Randomize mc choices using the exam class -- examples %% -%% Copyright (c)2019, Jesse E. J. op den Brouw +%% Copyright (c)2021, Jesse E. J. op den Brouw %% %% This work may be distributed and/or modified under the %% conditions of the LaTeX Project Public License, either version 1.3 @@ -29,21 +29,23 @@ %% J.E.J.opdenBrouw@hhs.nl %% The newest version of this package should always be available -%% from BitBucket: https://bitbucket.org/jesseopdenbrouw/exam-randomizechoices/src/master/ +%% from GitHub: https://github.com/jesseopdenbrouw/exam-randomizechoices \documentclass[answers,addpoints]{exam} \usepackage{parskip} \usepackage[colorlinks,linkcolor=blue]{hyperref} \usepackage{mathtools} - -\usepackage[debug,randomize,nokeeplast]{exam-randomizechoices} \usepackage[a4paper]{geometry} +\usepackage[debug,randomize,nokeeplast]{exam-randomizechoices} \setrandomizerseed{999} -%%\checkboxchar{\thecheckbox} -%%\checkedchar{\thecheckbox} + + +\usepackage{amssymb} +\checkboxchar{$\square$} +\checkedchar{$\raisebox{0.3ex}{\checkmark}\hspace{-0.95em}\square$} \CorrectChoiceEmphasis{\color{red}\slshape} @@ -351,7 +353,7 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{oneparchoices} -%%%%%%%%21 +%%%%%%%%23 \question[5] One of these things is not like the others; one of these things is not the same. Which one is different? @@ -365,7 +367,7 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{randomizechoices} -%%%%%%%%22 +%%%%%%%%24 \question[5] One of these things is not like the others; one of these things is not the same. Which one is different? @@ -379,7 +381,7 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{randomizechoices} -%%%%%%%%23 +%%%%%%%%25 \question[5] One of these things is not like the others; one of these things is not the same. Which one is different? @@ -392,7 +394,7 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{choices} -%%%%%%%%24 +%%%%%%%%26 \question[5] One of these things is not like the others; one of these things is not the same. Which one is different? @@ -405,7 +407,7 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{randomizeoneparchoices} -%%%%%%%%25 +%%%%%%%%27 \question[5] One of these things is not like the others; one of these things is not the same. Which one is different? @@ -418,7 +420,7 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{oneparchoices} -%%%%%%%%26 +%%%%%%%%28 \question[5] One of these things is not like the others; one of these things is not the same. Which one is different? @@ -431,7 +433,7 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{randomizecheckboxes} -%%%%%27 +%%%%%29 \question[5] One of these things is not like the others; one of these things is not the same. Which one is different? @@ -444,7 +446,7 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{checkboxes} -%%%%%%%%28 +%%%%%%%%30 \question[5] One of these things is not like the others; one of these things is not the same. Which one is different? @@ -457,7 +459,7 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{randomizeoneparcheckboxes} -%%%%%29 +%%%%%31 \question[5] One of these things is not like the others; one of these things is not the same. Which one is different? @@ -470,6 +472,582 @@ things is not the same. Which one is different? \CorrectChoice Socrates \end{oneparcheckboxes} +%%%%%32+ +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} + +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} +\question[5] +One of these things is not like the others; one of these +things is not the same. Which one is different? + +\begin{randomizeoneparchoices} +\choice John +\choice Paul +\choice George +\choice Ringo +\CorrectChoice Socrates +\end{randomizeoneparchoices} + + %%\question %%Proceed with the next sub-questions. %%\begin{parts} @@ -527,12 +1105,15 @@ things is not the same. Which one is different? Key table -\printkeytable +\printkeytable[1-30]\quad\printkeytable[31-60]\quad\printkeytable[61-83] \writekeylist[testfile.txt]{\mykeylist} \writekeylist{\mykeylist} +\savekeylist[\yesthekeylist] +{\color{red}\ttfamily\yesthekeylist} +That's all folks! \end{document} diff --git a/macros/latex/contrib/hvlogos/Changes b/macros/latex/contrib/hvlogos/Changes new file mode 100644 index 0000000000..4658700720 --- /dev/null +++ b/macros/latex/contrib/hvlogos/Changes @@ -0,0 +1,2 @@ +hvlogos.sty: +0.01 2021-07-30 - first CTAN version diff --git a/macros/latex/contrib/hvlogos/README b/macros/latex/contrib/hvlogos/README new file mode 100644 index 0000000000..5533d66103 --- /dev/null +++ b/macros/latex/contrib/hvlogos/README @@ -0,0 +1,9 @@ + +hvlogos +Printing TeX related names as a logo + +%% This program can be redistributed and/or modified under the terms +%% of the LaTeX Project Public License Distributed from CTAN archives +%% in directory macros/latex/base/lppl.txt. + +hvoss@tug.org \ No newline at end of file diff --git a/macros/latex/contrib/hvlogos/doc/hvlogos-doc.pdf b/macros/latex/contrib/hvlogos/doc/hvlogos-doc.pdf new file mode 100644 index 0000000000..c56c7e9522 Binary files /dev/null and b/macros/latex/contrib/hvlogos/doc/hvlogos-doc.pdf differ diff --git a/macros/latex/contrib/hvlogos/doc/hvlogos-doc.tex b/macros/latex/contrib/hvlogos/doc/hvlogos-doc.tex new file mode 100644 index 0000000000..77e83e2b21 --- /dev/null +++ b/macros/latex/contrib/hvlogos/doc/hvlogos-doc.tex @@ -0,0 +1,133 @@ +\documentclass[a4paper,english]{article} +\usepackage{libertinus-otf} +\setmonofont[Scale=MatchLowercase,FakeStretch=0.88]{AnonymousPro} +\usepackage{hvlogos} +\usepackage{longtable, booktabs} +\usepackage{babel} +\usepackage[autostyle]{csquotes} +\MakeAutoQuote{»}{«} + +\usepackage{makeidx}\makeindex +\def\Lcs#1{\texttt{\textbackslash#1}\index{#1@\texttt{\textbackslash#1}}} +\def\LPack#1{\texttt{#1}\index{#1@\texttt{#1} -- package}} + +\title{\texttt{hvlogos} -- Print \TeX-related Logos} +\author{Herbert Voß} +\begin{document} +\maketitle + +The package \LPack{hvlogos} loads by default the packages +\LPack{fetamont}, \LPack{hologo}, \LPack{dantelogo}, and \LPack{xspace}. + +\bigskip +\begin{longtable}{lll}\toprule +\emph{Macro} & \emph{Alias} & \emph{Output}\\\midrule +\endfirsthead + +\multicolumn{3}{l}{\ldots\ previous page}\\\midrule +\emph{Macro} & \emph{Alias} & \emph{Output}\\\midrule +\endhead + +\midrule +\multicolumn{3}{r}{next page \ldots}\\ +\endfoot + +\bottomrule +\endlastfoot + +\Lcs{ALEPH} && \ALEPH \\[5pt] + +\Lcs{AmS} & \Lcs{AMS} & \AMS\\ +\Lcs{AmSLaTeX} && \AmSLaTeX\\ +\Lcs{amsmath} && \amsmath\\ +\Lcs{AmSTeX} && \AmSTeX\\[5pt] + +\Lcs{biber} && \biber\\ +\Lcs{Biber} && \Biber \\ +\Lcs{BibLaTeX} & \Lcs{biblatex}& \BibLaTeX \\ +\Lcs{BibTeX} && \BibTeX \\ +\Lcs{BibTeX8} & \Lcs{BibTeXacht} & \BibTeX8\\ +\Lcs{BibTool} && \BibTool \\[5pt] + +\Lcs{ConTeXt} & \Lcs{context} & \ConTeXt \\ +\Lcs{CTAN} && \CTAN\\[5pt] + +\Lcs{dante} && \dante \\ +\Lcs{Dante} && \rlap{\Dante} \\ +\Lcs{DANTE} && \DANTE \\ +\Lcs{dtk} && \dtk \\ +\Lcs{DTK}\footnote{Quotes depends on the current language setting.} && \DTK \\[5pt] + +\Lcs{emTeX} && \emTeX\\ +\Lcs{eTeX} && \eTeX\\ +\Lcs{ExTeX} && \ExTeX\\ +\Lcs{eV} && \eV \\[5pt] + +\Lcs{HanTheThanh} & \Lcs{HTT} & \HanTheThanh\\[5pt] + +\Lcs{iniTeX} && \iniTeX \\ +\Lcs{KOMAScript} && \KOMAScript \\ +\Lcs{LaTeX} && \LaTeX \\ +\Lcs{LaTeXe} && \LaTeXe \\ +\Lcs{LaTeXIII} && \LaTeXIII \\ +\Lcs{LaTeXTeX} && \LaTeXTeX\\ +\Lcs{LaTeXML} && \LaTeXML \\ +\Lcs{LuaHBTeX} & \Lcs{luahbtex}, \Lcs{LuahbTeX} & \LuaHBTeX\\ +\Lcs{LuaLaTeX}& \Lcs{lualatex} & \LuaLaTeX \\ +\Lcs{LuaTeX} & \Lcs{luatex} & \LuaTeX\\ +\Lcs{LyX} && \LyX \\[5pt] + +\Lcs{macOS} && \macOS\\ +\Lcs{mpShort} && \mpShort\\ +\Lcs{mfShort} && \mfShort\\ +\Lcs{METAFONT} & \Lcs{MF}& \METAFONT \\ +\Lcs{MetaFun} &\Lcs{MFun} & \MetaFun\\ +\Lcs{METAPOST} & \Lcs{MetaPost}, \Lcs{MP}& \METAPOST \\ +\Lcs{MiKTeX} && \MiKTeX \\[5pt] + +\Lcs{NTS} && \NTS \\[5pt] + +\Lcs{OzMF} && \OzMF \\ +\Lcs{OzMP} && \OzMP \\ +\Lcs{OzTeX} && \OzTeX \\ +\Lcs{OzTtH} && \OzTtH \\[5pt] + +\Lcs{PCTeX} && \PCTeX \\ +\Lcs{pdfTeX} & \Lcs{pdftex} & \pdfTeX  \\ +\Lcs{pdfLaTeX} & \Lcs{pdflatex} & \pdfLaTeX\\ +\Lcs{pgf/tikz} & \Lcs{pgftikz} & \pgf/tikz \\[5pt] + +\Lcs{PiC} && \PiC \\ +\Lcs{PiCTeX} && \PiCTeX \\ +\Lcs{plainTeX} && \plainTeX \\ +\Lcs{PostScript} & \Lcs{PS}& \PostScript \\ +\Lcs{PSTricks} & \Lcs{pstricks}& \PSTricks\\[5pt] + +\Lcs{SageTeX} && \SageTeX \\ +\Lcs{SLiTeX} && \SLiTeX \\[5pt] + +\Lcs{teTeX} && \teTeX \\ +\Lcs{TeXivht} && \TeX4ht \\ +\Lcs{TeXLive} && \TeXLive\\[5pt] + +\Lcs{tikz} & \Lcs{TikZ}& \tikz \\ +\Lcs{TTH} && \TTH \\ +\Lcs{TUG} && \TUG\\ +\Lcs{TUGboat} && \TUGboat \\[5pt] + +\Lcs{virTeX} && \virTeX \\ +\Lcs{VTeX} && \VTeX \\[5pt] + +\Lcs{WikipediA}& \Lcs{Wikipedia}, \Lcs{wikipedia} & \WikipediA \\[5pt] + +\Lcs{XeLaTeX} && \XeLaTeX \\ +\Lcs{XeTeX} && \XeTeX \\ + +\end{longtable} + +\printindex + +\end{document} + + +\endinput diff --git a/macros/latex/contrib/hvlogos/latex/hvlogos.sty b/macros/latex/contrib/hvlogos/latex/hvlogos.sty new file mode 100644 index 0000000000..11116a6a99 --- /dev/null +++ b/macros/latex/contrib/hvlogos/latex/hvlogos.sty @@ -0,0 +1,200 @@ +%% Paket fuer Logos +%% +%% This is file `hvlogos.sty', +%% +%% Copyright (C) 2021 +%% Herbert Voss +%% +%% This program can be redistributed and/or modified under the terms +%% of the LaTeX Project Public License Distributed from CTAN archives +%% in directory macros/latex/base/lppl.txt. +% +% +% ------------------------------------- +\ProvidesPackage{hvlogos}[2021/07/28 v. 0.01 Logos (hv)] +% +\newif\if@dtk@newengine \@dtk@newenginetrue +% +\RequirePackage{fetamont,hologo,dantelogo,xspace} + +\ifluatex\else\ifxetex\else\@dtk@newenginefalse\fi\fi +\if@dtk@newengine + \RequirePackage{unicode-math} + \setmathfont{LatinModernMath-Regular} + \setmathfont[version=XITS]{XITSMath-Regular.otf} +\fi +% +\iffalse +\DeclareRobustCommand\ffmfamily{\not@math@alphabet\ffmfamily\relax + \fontencoding{T1}\fontfamily{ffm}\selectfont} +\DeclareTextFontCommand{\textffm}{\ffmfamily} +\def\MF{\textffm{META}\@dischyph\textffm{FONT}\@} +\def\MP{\textffm{META}\@dischyph\textffm{POST}\@} +\def\MT{\textffm{META}\@dischyph\textffm{TYPE1}\@} +\fi +\def\mpShort{\textffm{MP}\@} +\def\mfShort{\textffm{MF}\@} + +\def\HoLogo@La#1{% + L% + \ifx\f@family\sfdefault\kern-.15em\else\kern-.23em\fi + \begingroup + \setbox\ltx@zero\hbox{T}% + \vbox to\ht\ltx@zero{% + \hbox{% + \ltx@ifundefined{check@mathfonts}{% + \csname sevenrm\endcsname + }{% + \check@mathfonts + \fontsize\sf@size{0pt}% + \math@fontsfalse\selectfont + }% + A% + }% + \vss + }% + \endgroup +} + +%\edef\hologoList{% +% \hologoList% +% \hologoEntry{LuaHBTeX}{}{2020/07/13}% +%} + +\def\LaTeXTeX{\hologo{(La)TeX}} + +\def\AmS{\textsf{AMS}} +\let\AMS\AmS +%{\ifluatex\mathversion{XITS}\fi% +% $\mathcal{A}$\kern-.1667em\lower.5ex\hbox{$\mathcal{M}$}\kern-.125em$\mathcal{S}$}}% $ +\def\amsmath{\AMS\textsf{math}} +\def\AmSLaTeX{\mbox{\textsf{AMS}-\hologo{LaTeX}}} +\def\AmSTeX{\mbox{\textsf{AMS}-\hologo{TeX}}} +\def\biber{\textsf{biber}} +\def\Biber{\textsf{Biber}} +\def\BibTeX{\@ifnextchar8\@@BibTeX\@BibTeX} +\def\@BibTeX{{\hologoLogoSetup{BibTeX}{variant=sc}\hologo{BibTeX}}} +\def\BibTeXacht{{\hologoLogoSetup{BibTeX8}{variant=sc}\hologo{BibTeX8}}} +\def\@@BibTeX8{\hologo{BibTeX8}} +\def\ConTeXt{\hologo{ConTeXt}} +\let\context\ConTeXt +\def\emTeX{\hologo{emTeX}} +\def\eTeX{\hologo{eTeX}} +\def\ExTeX{\hologo{ExTeX}} +\def\HanTheThanh{\hologo{HanTheThanh}} +\let\HTT\HanTheThanh +\def\iniTeX{\hologo{iniTeX}} +\def\KOMAScript{\hologo{KOMAScript}} +\def\LaTeX{\hologo{LaTeX}} +\def\LaTeXe{\hologo{LaTeX2e}} +\def\LaTeXIII{\hologo{LaTeX3}} +\def\LaTeXML{\hologo{LaTeXML}} +\def\LuaLaTeX{\hologo{LuaLaTeX}} +\let\lualatex\LuaLaTeX +\def\LuaTeX{\hologo{LuaTeX}} + +\let\HoLogoHtml@LuaHBTeX\HoLogo@LuaHBTeX +\def\HoLogo@LuaHBTeX#1{% + \HOLOGO@mbox{% + LuaHB% + \hologo{TeX}% + }% +} + +\def\LuaHBTeX{\hologo{LuaHBTeX}} +\let\luahbtex\LuaHBTeX +\let\LuahbTeX\LuaHBTeX +\let\luatex\LuaTeX +\def\LyX{\hologo{LyX}} +\def\METAFONT{\hologo{METAFONT}} +\let\MF\METAFONT +\def\MetaFun{\textffm{METAFUN}} +\let\MFun\MetaFun +\def\METAPOST{\hologo{METAPOST}} +\def\MetaPost{\hologo{MetaPost}} +\let\MP\METAPOST +\def\MiKTeX{\hologo{MiKTeX}} +\def\NTS{\hologo{NTS}} +\def\OzMF{\hologo{OzMF}} +\def\OzMP{\hologo{OzMP}} +\def\OzTeX{\hologo{OzTeX}} +\def\OzTtH{\hologo{OzTtH}} +\def\PCTeX{\hologo{PCTeX}} +\def\pdfTeX{\hologo{pdfTeX}} +\let\pdftex\pdfTeX +\def\pdfLaTeX{\hologo{pdfLaTeX}} +\let\pdflatex\pdfLaTeX +\def\PiC{\hologo{PiC}} +\def\PiCTeX{\hologo{PiCTeX}} +\def\plainTeX{\hologo{plainTeX}} +\def\PostScript{Post\-Script} +\let\PS\PostScript +\def\SageTeX{\hologo{SageTeX}} +\def\SLiTeX{\hologo{SLiTeX}} +\def\teTeX{\hologo{teTeX}} +\def\TeXivht{\hologo{TeX4ht}} +\def\TTH{\hologo{TTH}} +\def\virTeX{\hologo{virTeX}} +\def\VTeX{\hologo{VTeX}} +\def\XeLaTeX{\hologo{XeLaTeX}} +\def\XeTeX{\hologo{XeTeX}} +%% +% +\newcommand\BibTool{\textsc{Bib\hskip-.1em + T\hskip-.15emo\hskip-.05emo\hskip-.05eml}\xspace} +\def\tikz{\textsf{Ti\textit{k}Z}} +\def\ALEPH{\ensuremath{\aleph}} +\let\TikZ\tikz + +\def\eV{e.\kern-0.1em V\kern-0.18em.} +\def\d@nte{\@ifnextchar.% + {\mbox{DANTE e.\kern-0.1em V\kern-0.18em}}% + {\mbox{DANTE e.\kern-0.1em V\kern-0.18em.}\xspace}% +} +\def\D@nte{\@ifnextchar.% + {DANTE, Deutschsprachige Anwendervereinigung~\mbox{\TeX~e.\kern-0.1em V\kern-0.18em}}% + {DANTE, Deutschsprachige Anwendervereinigung~\mbox{\TeX~e.\kern-0.1em V\kern-0.18em.}\xspace}% +} +\def\dante#1{% + \ifx#1\@empty + \d@nte + \else + \expandafter\d@nte#1% + \fi} + +\def\Dante#1{% + \ifx#1\@empty + \D@nte + \else + \expandafter\D@nte#1% + \fi} + +\providecommand\dtk{Die \TeX\-ni\-sche Ko\-mö\-die} +\providecommand\DTK{``\dtk''} +\providecommand\PS{Post\-Script} +\providecommand\TUG{\TeX{} Users Group} +\providecommand\TUGboat{\textsl{TUGboat}} +\let\DANTE\dantelogo +\def\pgf/tikz{\textsf{pgf/Ti\textit{k}Z}} +\def\pgftikz{\textsf{pgf/Ti\textit{k}Z}} +\def\TeXLive{\TeX{}Live\xspace} + +\def\BibLaTeX{Bib\hologo{LaTeX}} +\let\biblatex\BibLaTeX +\def\CTAN{\texttt{CTAN}\xspace} + +\def\PSTricks{\textsf{PSTricks}\xspace} +\let\pstricks\PSTricks + +\if@dtk@newengine + \newfontfamily\dtk@LinWikipedia{Linux Libertine O}% + \def\WikipediA{{\dtk@LinWikipedia\char"E02F\textsc{ikipediA}}} % hexadezimal +\else + \def\WikipediA{WikipediA}% +\fi +\let\Wikipedia\WikipediA +\let\wikipedia\WikipediA +% +\def\macOS{\textsf{macOS}\xspace} + +\endinput diff --git a/macros/latex/contrib/macrolist/README.md b/macros/latex/contrib/macrolist/README.md index 8aa1f2490a..b6aee00d3b 100644 --- a/macros/latex/contrib/macrolist/README.md +++ b/macros/latex/contrib/macrolist/README.md @@ -1,4 +1,4 @@ -# The LaTeX package macrolist - version 2.0.0 (2021/07/29) +# The LaTeX package macrolist - version 2.1.0 (2021/07/31) > Copyright (C) 2021 Dennis Chen > diff --git a/macros/latex/contrib/macrolist/macrolist.dtx b/macros/latex/contrib/macrolist/macrolist.dtx index 5074875ff0..f11af32bfd 100644 --- a/macros/latex/contrib/macrolist/macrolist.dtx +++ b/macros/latex/contrib/macrolist/macrolist.dtx @@ -16,7 +16,7 @@ %<*package> \NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{macrolist}[2021/07/29 v2.0.0 Create lists of macros and perform operations on them] +\ProvidesPackage{macrolist}[2021/07/31 v2.1.0 Create lists of macros and perform operations on them] \RequirePackage{pgffor} % @@ -123,7 +123,6 @@ % \fi % % \DescribeMacro{\macrolistcontains} -% % Writing |\macrolistcontains{listname}{element}{true branch}{false branch}| checks whether list \textsf{listname} contains \textsf{element}, executing \textsf{true branch} if it does and \textsf{false branch} if it does not. % % \iffalse @@ -147,7 +146,6 @@ % \fi % % \DescribeMacro{\macrolistadd} -% % To add something to the list \textsf{listname}, pass in |\macrolistadd{listname}[position]{element}|, where \textsf{position} is an optional argument. If nothing is passed in for \textsf{position}, then by default \textsf{element} will be added to the end of the list. % % \iffalse @@ -175,9 +173,35 @@ \fi } % \fi +% \changes{v2.1.0}{2021/07/31}{Add macrolisteadd} +% \DescribeMacro{\macrolisteadd} +% To fully expand |element| before adding it to list |listname|, pass in |\macrolisteadd{listname}[position]{element}|. This behaves similarly to |\edef|. % +% \iffalse +\newcommand{\macrolisteadd}[1]{ + \macrolist@exists{#1} + \def\macrolist@currlist{#1} + \macrolist@listeadd +} +\newcommand{\macrolist@listeadd}[2][]{ + \stepcounter{macrolist@list@\macrolist@currlist} + + \if\relax\detokenize{#1}\relax + \expandafter\xdef\csname macrolist@list@\macrolist@currlist\macrolistsize{\macrolist@currlist}\endcsname{#2} + \else + \expandafter\ifnum\csname themacrolist@list@\macrolist@currlist\endcsname=#1 + \expandafter\gdef\csname macrolist@list@\macrolist@currlist\macrolistsize{\macrolist@currlist}\endcsname{#2} + \else + \macrolist@inbounds{\macrolist@currlist}{#1} + \foreach \macrolist@index in {\macrolistsize{\macrolist@currlist}, ...,\the\numexpr #1+1\relax} { + \global\expandafter\let\csname macrolist@list@\macrolist@currlist\macrolist@index\expandafter\endcsname\csname macrolist@list@\macrolist@currlist\the\numexpr\macrolist@index-1\relax\endcsname + } + \expandafter\xdef\csname macrolist@list@\macrolist@currlist#1\endcsname{#2} + \fi + \fi +} +% \fi % \DescribeMacro{\macrolistremove} -% % To remove an element in a list, write |\macrolistremove{listname}{index}|. % % \iffalse @@ -197,7 +221,6 @@ % \fi % % \DescribeMacro{\macrolistremovelast} -% % To remove the last element in a list, write |\macrolistremovelast{listname}|. This behaves like C++'s |pop_back|. % % \iffalse @@ -209,7 +232,6 @@ % \fi % % \DescribeMacro{\macrolistclear} -% % To clear a list, write |\macrolistclear{listname}|. % % \iffalse @@ -225,7 +247,6 @@ % \fi % % \DescribeMacro{\macrolistsize} -% % To get the size of a list, write |\macrolistsize{listname}|. % % \iffalse @@ -237,7 +258,6 @@ % % \DescribeMacro{\macrolistforeach} % \changes{v1.1.1}{2021/07/23}{Fix foreach doc by removing incorrect begin} -% % To write a for each loop, write % \begin{verbatim} %\macrolistforeach{listname}{\element}[begin][end]{action} @@ -299,7 +319,6 @@ % \fi % % \DescribeMacro{\macrolistjoin} -% % Executing |\macrolistjoin{listname}{joiner}| returns all of the elements separated by \textsf{joiner}. This behaves like Javascript's \textsf{arr.join()}. % % \iffalse diff --git a/macros/latex/contrib/macrolist/macrolist.pdf b/macros/latex/contrib/macrolist/macrolist.pdf index 156a8323f3..300ea7518c 100644 Binary files a/macros/latex/contrib/macrolist/macrolist.pdf and b/macros/latex/contrib/macrolist/macrolist.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/CHANGELOG.md b/macros/latex/contrib/pdfmanagement-testphase/CHANGELOG.md index d22bc201ff..e9ff54953d 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/CHANGELOG.md +++ b/macros/latex/contrib/pdfmanagement-testphase/CHANGELOG.md @@ -4,6 +4,23 @@ first release 0.95a, 2021-02-23 will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), this project uses date-based 'snapshot' version identifiers. + + +## [2021-07-31] +### Added + - \IfPDFManagementActiveTF as copy of `\pdfmanagement_if_active:TF + - \PDFManagementAdd as copy of `\pdfmanagement_add:xxx` + - Support for name trees /AP and /JavaScript in Catalog/Names + - Support to add user file names to /EmbeddedFiles (beside the existing + way with automatically generated names) + - if xcolor is loaded the colors it predefines are now predefined also for l3color + +### Changed + - Implementation of the /EmbeddedFiles name tree, it is now more in line + with the other name trees. + - \Form no longer creates xform objects -- this affected spacing and produced + empty pages. The xform objects are now only created if fields are used. + ## [2021-07-21] ### Added - key `testphase` to \DeclareDocumentMetadata to load testphase packages like diff --git a/macros/latex/contrib/pdfmanagement-testphase/README.md b/macros/latex/contrib/pdfmanagement-testphase/README.md index e521f810db..fd565a6ea6 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/README.md +++ b/macros/latex/contrib/pdfmanagement-testphase/README.md @@ -1,6 +1,6 @@ # LaTeX PDF management testphase bundle -Version: 0.95g, 2021-07-21 +Version: 0.95h, 2021-07-31 This package is used during a test phase to load the new PDF management code of LaTeX. diff --git a/macros/latex/contrib/pdfmanagement-testphase/color-ltx.sty b/macros/latex/contrib/pdfmanagement-testphase/color-ltx.sty index b7765e97ed..fca7c1c3ac 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/color-ltx.sty +++ b/macros/latex/contrib/pdfmanagement-testphase/color-ltx.sty @@ -22,7 +22,7 @@ %% This file has the LPPL maintenance status "maintained". %% \NeedsTeXFormat{LaTeX2e}[1995/12/01] -\ProvidesPackage{color-ltx}[2021-07-21 v0.95g +\ProvidesPackage{color-ltx}[2021-07-31 v0.95h Standard LaTeX Color (patched for l3color, part of pdfmanagement-testphase, original version 2021/03/07 v1.2e) (DPC)] \edef\Gin@codes{% \catcode`\noexpand\^^A\the\catcode`\^^A\relax diff --git a/macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.dtx b/macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.dtx index e3d84d6ec6..4e0296c641 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.dtx @@ -86,7 +86,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -906,9 +906,6 @@ %^^A %% \l_@@_para_tmpa_tl %^^A %% \l_@@_text_tmpa_str %^^A %% \g_@@_text_tmpa_str -%^^A %% \l_@@_CheckmarkYes_tl -%^^A %% \l_@@_CheckmarkOff_tl -%^^A %% \l_@@_RadioYes_tl %^^A %% \g_@@_bordercolormodel_tl % %^^A %% \l_@@_dest_pdfview_tl @@ -921,7 +918,7 @@ %<@@=hyp> % \end{macrocode} % \begin{macrocode} -\ProvidesFile{hgeneric-testphase.def}[2021-07-21 v0.95g % +\ProvidesFile{hgeneric-testphase.def}[2021-07-31 v0.95h % generic Hyperref driver for the LaTeX PDF management testphase bundle] \RequirePackage{etoolbox} %why? @@ -2482,7 +2479,7 @@ % \end{hypkey} % \begin{hypkey}{colorurl,colorlink,colorrun,colormenu,colorfile} % \begin{hypkey}{urlcolor,linkcolor,runcolor,menucolor,filecolor} -% \begin{hypkey}{allcolor} +% \begin{hypkey}{allcolors} % \begin{macrocode} \seq_map_inline:Nn \c_@@_annot_types_seq { @@ -4215,14 +4212,9 @@ \ExplSyntaxOff \ExplSyntaxOn -\tl_new:N \l_@@_CheckmarkYes_tl -\tl_set:Nn \l_@@_CheckmarkYes_tl { @@_xform_CheckMarkYes } -\tl_new:N \l_@@_CheckmarkOff_tl -\tl_set:Nn \l_@@_CheckmarkOff_tl { @@_xform_CheckMarkOff } \def\@Form[#1] { - \@ifundefined{textcolor}{\let\textcolor\@gobble}{} \kvsetkeys{Form}{#1} \pdf@ifdraftmode{} { @@ -4240,8 +4232,7 @@ } \seq_sort:Nn \l_@@_tmpa_seq { - \int_compare:nNnTF { \pdf@strcmp{##1}{##2} } > { 0 } - %\str_compare:nNnTF {##1} > {##2} + \str_compare:nNnTF {##1} > {##2} { \sort_return_swapped: } { \sort_return_same: } } @@ -4271,64 +4262,6 @@ \pdfmanagement_remove:nn {Catalog / AcroForm }{NeedAppearances} } } - \MakeFieldObject - { - \group_begin: - \fontfamily{pzd} - \fontencoding{U} - \fontseries{m} - \fontshape{n} - \selectfont - \char123 - \group_end: - } - {@@_xform_Ding} - \MakeFieldObject - { - \group_begin: - \fontfamily{pzd} - \fontencoding{U} - \fontseries{m} - \fontshape{n} - \selectfont - \phantom{\char123} - \group_end: - } - {@@_xform_DingOff} - \MakeFieldObject - { - \group_begin: - \fontfamily{pzd} - \fontencoding{U} - \fontseries{m} - \fontshape{n} - \selectfont - \char51 - \group_end: - } - {@@_xform_CheckMarkYes} - \MakeFieldObject - { - \group_begin: - \fontfamily{pzd} - \fontencoding{U} - \fontseries{m} - \fontshape{n} - \selectfont - \phantom{\char51} %perhaps xetex needs some small glyph .. - \group_end: - } - {@@_xform_CheckMarkOff} - \MakeFieldObject - { - \fbox{\textcolor{yellow}{\textsf{Submit}}} %color? - } - {@@_xform_Submit} - \MakeFieldObject - { - \fbox{\textcolor{yellow}{\textsf{SubmitP}}} %color? - } - {@@_xform_SubmitP} } \ExplSyntaxOff \let\@endForm\ltx@empty @@ -4468,8 +4401,7 @@ }% \endgroup } -\tl_new:N \l_@@_RadioYes_tl -\tl_set:Nn \l_@@_RadioYes_tl { @@_xform_Ding } + \def\@@Radio#1{% \Fld@listcount=0~% %\show\Fld@default @@ -4484,7 +4416,21 @@ \leavevmode \HyAnn@AbsPageLabel \Hy@escapeform\PDFForm@Radio - \pdfannot_box:nnnn + \pdfxform_if_exist:nF { @@_xform_Ding } + { + \pdfxform_new:nnn { @@_xform_Ding } {} + { + \group_begin: + \fontfamily{pzd} + \fontencoding{U} + \fontseries{m} + \fontshape{n} + \selectfont + \char123 + \group_end: + } + } + \pdfannot_box:nnnx {\Fld@width} {\Fld@height} {0pt} %is this correct? @@ -4494,7 +4440,7 @@ << /N << - /\@currValue\c_space_tl \pdfxform_ref:o {@@_xform_Ding} + /\@currValue\c_space_tl \pdfxform_ref:n {@@_xform_Ding} %/Off \c_space_tl \pdfxform_ref:n {@@_xform_DingOff} %hm >> >> @@ -4582,6 +4528,18 @@ \HyAnn@AbsPageLabel \Hy@escapeform\PDFForm@Submit \hbox_set:Nn \l_tmpa_box { \MakeButtonField {#2}} + \pdfxform_if_exist:nF + { @@_xform_Submit } + { + \pdfxform_new:nnn { @@_xform_Submit }{} + { + \fbox{\color_select:n{yellow}\textsf{Submit}} + } + \pdfxform_new:nnn { @@_xform_SubmitP }{} + { + \fbox{\color_select:n{yellow}\textsf{SubmitP}} + } + } \pdfannot_box:nnnn {\box_wd:N\l_tmpa_box} {\box_ht:N\l_tmpa_box} @@ -4654,6 +4612,33 @@ \mode_leave_vertical: \HyAnn@AbsPageLabel \Hy@escapeform\PDFForm@Check + \pdfxform_if_exist:nF { @@_xform_CheckMarkYes } + { + \pdfxform_new:nnn + {@@_xform_CheckMarkYes}{} + { + \group_begin: + \fontfamily{pzd} + \fontencoding{U} + \fontseries{m} + \fontshape{n} + \selectfont + \char51 + \group_end: + } + \pdfxform_new:nnn + {@@_xform_CheckMarkOff}{} + { + \group_begin: + \fontfamily{pzd} + \fontencoding{U} + \fontseries{m} + \fontshape{n} + \selectfont + \phantom{\char51} %perhaps xetex needs some small glyph .. + \group_end: + } + } \pdfannot_box:nnnn {\Fld@width} {\Fld@height} @@ -4874,8 +4859,8 @@ << /N << - /Yes~\pdfxform_ref:o{\l_@@_CheckmarkYes_tl} - /Off~\pdfxform_ref:o{\l_@@_CheckmarkOff_tl} + /Yes~\pdfxform_ref:n{@@_xform_CheckMarkYes} + /Off~\pdfxform_ref:n{@@_xform_CheckMarkOff} >> >> /MK<< diff --git a/macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.pdf b/macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.pdf index de4dd81f09..1ec46ba75c 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.pdf and b/macros/latex/contrib/pdfmanagement-testphase/hyperref-generic.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/hyperxmp-patches-tmp-ltx.sty b/macros/latex/contrib/pdfmanagement-testphase/hyperxmp-patches-tmp-ltx.sty index 96e9d086a6..f948928f94 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/hyperxmp-patches-tmp-ltx.sty +++ b/macros/latex/contrib/pdfmanagement-testphase/hyperxmp-patches-tmp-ltx.sty @@ -19,7 +19,7 @@ % % for those people who are interested. \NeedsTeXFormat{LaTeX2e}[2020/10/01] -\ProvidesExplPackage{hyperxmp-patches-tmp-ltx}{2021-07-21}{0.95g} +\ProvidesExplPackage{hyperxmp-patches-tmp-ltx}{2021-07-31}{0.95h} {Store hyperref metadata in XMP format / temporay patches to test pdfresource management ... UF} \cs_if_exist:NT \pdfmanagement_add:nnn diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.dtx index 7b4aad8fe6..0102b1c574 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.dtx @@ -45,7 +45,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % @@ -56,27 +56,27 @@ % \begin{macrocode} %\ProvidesExplFile %<*dvipdfmx> - {l3backend-testphase-dvipdfmx.def}{2021-07-21}{} + {l3backend-testphase-dvipdfmx.def}{2021-07-31}{} {LaTeX~PDF~management~testphase~bundle~backend~support: dvipdfmx} % %<*dvips> - {l3backend-testphase-dvips.def}{2021-07-21}{} + {l3backend-testphase-dvips.def}{2021-07-31}{} {LaTeX~PDF~management~testphase~bundle~backend~support: dvips} % %<*dvisvgm> - {l3backend-testphase-dvisvgm.def}{2021-07-21}{} + {l3backend-testphase-dvisvgm.def}{2021-07-31}{} {LaTeX~PDF~management~testphase~bundle~backend~support: dvisvgm} % %<*luatex> - {l3backend-testphase-luatex.def}{2021-07-21}{} + {l3backend-testphase-luatex.def}{2021-07-31}{} {LaTeX~PDF~management~testphase~bundle~backend~support: PDF output (LuaTeX)} % %<*pdftex> - {l3backend-testphase-pdftex.def}{2021-07-21}{} + {l3backend-testphase-pdftex.def}{2021-07-31}{} {LaTeX~PDF~management~testphase~bundle~backend~support: PDF output (pdfTeX)} % %<*xdvipdfmx> - {l3backend-testphase-xetex.def}{2021-07-21}{} + {l3backend-testphase-xetex.def}{2021-07-31}{} {LaTeX~PDF~management~testphase~bundle~backend~support: XeTeX} % % \end{macrocode} @@ -1086,116 +1086,70 @@ % \subsubsection { Special case: the /Names/EmbeddedFiles dictionary } % Entries to /Names are handled differently, in part (/Desc) it is automatic, for % other special commands like \cs{pdfnames} must be used. For EmbeddedFiles -% we need some code to push the tree if files have been added. dvips wants code -% for every file and then creates the Name tree automatically. +% dvips wants code for every file and then creates the Name tree automatically. +% Other name trees are ignored. +% TODO: Currently the code for EmbeddedFiles is still a bit +% different but this should be merged, all name trees should be handled with the +% same code. % \begin{macrocode} % pdflatex %<*pdftex> -\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_gpush:n #1 %array content +\cs_new_protected:Npn \@@_backend_Names_gpush:nn #1 #2 %#1 name of name tree, #2 array content { - \pdf_object_unnamed_write:nn {dict} {/Names [#1] } - \tex_pdfnames:D {/EmbeddedFiles~\pdf_object_ref_last:} + \pdf_object_unnamed_write:nn {dict} {/Names [#2] } + \tex_pdfnames:D {/#1~\pdf_object_ref_last:} } % %<*luatex> -\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_gpush:n #1 %array content +\cs_new_protected:Npn \@@_backend_Names_gpush:nn #1 #2 %#1 name of name tree, #2 array content { - \pdf_object_unnamed_write:nn {dict} {/Names [#1] } - \tex_pdfextension:D~names~{/EmbeddedFiles~\pdf_object_ref_last: } + \pdf_object_unnamed_write:nn {dict} {/Names [#2] } + \tex_pdfextension:D~names~ {/#1~\pdf_object_ref_last:} } % %<*dvipdfmx|xdvipdfmx> -\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_gpush:n #1 %array content +\cs_new_protected:Npn \@@_backend_Names_gpush:nn #1 #2 %#1 name of name tree, #2 array content { - \pdf_object_unnamed_write:nn {dict} { /Names [#1] } - %n or x? - \@@_backend:x {put~@names~<>} + \pdf_object_unnamed_write:nn {dict} {/Names [#2] } + \@@_backend:x {put~@names~<>} } % %dvips: noop %<*dvips> -\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_gpush:n #1 {} +\cs_new_protected:Npn \@@_backend_Names_gpush:nn #1 #2 {} % %dvisvgm: noop %<*dvisvgm> -\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_gpush:n #1 {} +\cs_new_protected:Npn \@@_backend_Names_gpush:nn #1 #2 {} % - -% \end{macrocode} -% Names in the EmbeddedFiles name tree must sorted alphabetically, -% so we need commands to create this names. And we need a sequence to store -% the names and the objects. We use the prefix l3ef, and we assume that at -% most 9999 files will be used. -% \begin{variable}{\g_@@_backend_EmbeddedFiles_int} -% \end{variable} -% \begin{macro}{\@@_backend_EmbeddedFiles_name:} -% \begin{macrocode} -%<*drivers> -\int_new:N \g_@@_backend_EmbeddedFiles_int -\cs_new:Npn \@@_backend_EmbeddedFiles_name: - { - ( - l3ef - \int_compare:nNnT {\g_@@_backend_EmbeddedFiles_int} < {10} - {0} - \int_compare:nNnT {\g_@@_backend_EmbeddedFiles_int} < {100} - {0} - \int_compare:nNnT {\g_@@_backend_EmbeddedFiles_int} < {1000} - {0} - \int_use:N \g_@@_backend_EmbeddedFiles_int - ) - } -% -% \end{macrocode} -% \end{macro} -% \begin{variable}{\g_@@_backend_EmbeddedFiles_seq,\g_@@_backend_EmbeddedFiles_named_prop} -% The sequence will hold the content of the array that is pushed out at then -% end (not with dvips), the prop holds the obj names-names relation. -% \end{variable} -% \begin{macrocode} -%<*drivers> -\seq_new:N \g_@@_backend_EmbeddedFiles_seq -\prop_new:N \g_@@_backend_EmbeddedFiles_named_prop -% % \end{macrocode} -% \begin{macro}{\@@_backend_NamesEmbeddedFiles_add:n} -% This command saves an object reference of a filespec dictionary in the -% EmbeddedFiles name tree. We define a prop to store the relation between -% object name and name in the name tree. +% EmbeddedFiles is a bit special. +% For once we need backend commands for dvips. +% But we want also an option to create the name on the fly. +% \begin{macro}{\@@_backend_NamesEmbeddedFiles_add:nn} +% dvips need special backend code to create the name tree. +% With the other engines it does nothing. % \begin{macrocode} %<*pdftex|luatex|dvipdfmx|xdvipdfmx> -\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_add:n #1 - %#1 object ref - { - \int_gincr:N \g_@@_backend_EmbeddedFiles_int - \prop_gput:Nnx \g_@@_backend_EmbeddedFiles_named_prop - { #1 } - { \@@_backend_EmbeddedFiles_name: } - \seq_gput_right:Nx \g_@@_backend_EmbeddedFiles_seq - { \@@_backend_EmbeddedFiles_name: \c_space_tl #1 } - } - +\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_add:nn #1 #2 {} % %<*dvips> -\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_add:n #1 +\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_add:nn #1 #2 { - \int_gincr:N \g_@@_backend_EmbeddedFiles_int - \prop_gput:Nnx \g_@@_backend_EmbeddedFiles_named_prop - { #1 } - { \@@_backend_EmbeddedFiles_name: } \@@_backend_pdfmark:x { - /Name~\@@_backend_EmbeddedFiles_name:~ - /FS~#1~ + /Name~#1~ + /FS~#2~ /EMBED } } % %<*dvisvgm> %no op. Or is there any sensible use for it? -\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_add:n #1 +\cs_new_protected:Npn \@@_backend_NamesEmbeddedFiles_add:nn #1 #2 {} + % % \end{macrocode} % \end{macro} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.pdf index 452b140f99..9addd760c8 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3backend-testphase.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.dtx index 4f4778699a..8bd41b49c8 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.dtx @@ -52,7 +52,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -424,7 +424,7 @@ % \begin{macrocode} %<@@=pdfannot> %<*header> -\ProvidesExplPackage{l3pdfannot}{2021-07-21}{0.95g} +\ProvidesExplPackage{l3pdfannot}{2021-07-31}{0.95h} {PDF-annotations} \RequirePackage{l3pdfdict} % diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.pdf index 88bc60c05d..d2924f459a 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdfannot.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.dtx index ef283dd664..e80d6097cb 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.dtx @@ -53,7 +53,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -212,7 +212,7 @@ % \begin{macrocode} %<@@=pdfdict> %<*header> -\ProvidesExplPackage{l3pdfdict}{2021-07-21}{0.95g} +\ProvidesExplPackage{l3pdfdict}{2021-07-31}{0.95h} {Tools for PDF dictionaries (LaTeX PDF management testphase bundle)} % % \end{macrocode} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.pdf index 8df8e77e73..b548db0e6a 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdfdict.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.dtx index 146214c7f1..77bf53bd85 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.dtx @@ -53,7 +53,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.pdf index e1074881bc..8ca1a9bf06 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-action.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.dtx index 32f2f76ffe..a1386fcc08 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.dtx @@ -68,7 +68,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.pdf index 722ab053e6..6733f3ea39 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-checkbox.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.dtx index f247ef5142..de162d3ab7 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.dtx @@ -53,7 +53,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.pdf index bb9bd4816e..93a763cc9c 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-choice.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.dtx index 3d6ee2c6c2..02889ec5e3 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.dtx @@ -59,7 +59,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.pdf index 599400bd4e..5397bcb5e3 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-pushbutton.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.dtx index 3a451bcead..b25b7ead14 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.dtx @@ -87,7 +87,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.pdf index 4543748a37..045af32e84 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-radiobutton.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.dtx index 81330a6520..1289d54de9 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.dtx @@ -53,7 +53,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.pdf index 168a072993..1bacb22920 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield-textfield.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield.dtx index 36e4415eef..5a1d17809e 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield.dtx @@ -73,7 +73,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -970,7 +970,7 @@ %<*package> %<@@=pdffield> \NeedsTeXFormat{LaTeX2e} -\ProvidesExplPackage{l3pdffield-testphase}{2021-07-21}{0.95g}% +\ProvidesExplPackage{l3pdffield-testphase}{2021-07-31}{0.95h}% {form fields} % \end{macrocode} % \subsection{hyperref specific command} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield.pdf index b9d740e9f9..c271631238 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdffield.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdffield.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffile.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdffile.dtx index 0fadfbe46f..56e927b41d 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdffile.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdffile.dtx @@ -53,7 +53,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -400,7 +400,7 @@ % % \begin{macrocode} %<*header> -\ProvidesExplPackage{l3pdffile}{2021-07-21}{0.95g} +\ProvidesExplPackage{l3pdffile}{2021-07-31}{0.95h} {embedding and referencing files in PDF---LaTeX PDF management testphase bundle} \RequirePackage{l3pdftools} %temporarly!! % diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdffile.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdffile.pdf index faa18ada04..37cad7dd54 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdffile.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdffile.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.dtx index 0390980da5..c3de57b74c 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.dtx @@ -61,7 +61,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -137,9 +137,14 @@ % {\pdfmanagement_if_active:} % This conditional tests if the resource management code is active. % \end{function} -% -% \begin{function}[added = 2020-04-06] -% {\pdfmanagement_add:nnn,\pdfmanagement_add:nnx,\pdfmanagement_add:nxx} +% \begin{function}[added=2021-07-23] +% {\IfPDFManagementActiveTF} +% This is a LaTeX2e version of the conditional +% \end{function} + +% \begin{function}[added = 2020-04-06,updated=2021-07-23] +% {\pdfmanagement_add:nnn,\pdfmanagement_add:nnx,\pdfmanagement_add:nxx,\pdfmanagement_add:xxx, +% \PDFManagementAdd} % \begin{syntax} % \cs{pdfmanagement_add:nnn} \Arg{resource path} \Arg{name} \Arg{value} % \end{syntax} @@ -152,7 +157,8 @@ % keys used in PDF dictionaries (see the l3pdfdict module) the name is escaped % with \cs{str_convert_pdfname:n} when stored. % \Arg{value} should be a valid PDF value for this Name in the -% target dictionary. +% target dictionary. |\PDFManagementAdd| is a copy of |\pdfmanagement_add:xxx| +% and so expands all its arguments. % % % The code works with all major engines but not necessarily @@ -166,6 +172,10 @@ % backends. Some engines have to use labels and the aux-file to setup % the dictionaries and so need at least two compilations to put everything % in place. +% \item dvips doesn't support everything. It is for example not possible +% to add manually or through side effects +% a name tree like /AP or /JavaScript, pdfmark doesn't provide a handler +% here---at least I didn't find anything suitable. % \end{itemize} % \end{function} % @@ -549,6 +559,61 @@ % attach the file to the file panel. % \end{tabularx} % +% \paragraph{Catalog entries for name trees} +% +% \emph{Not supported in the dvips backend, pdfmark doesn't have an interface here}. +% +% In various places the PDF format allows to reference objects by name instead +% of by object reference. The relationship between a name and the object reference +% are store in so-called \emph{name trees}, which are stored in the +% Catalog/Names dictionary. The |/Dests| and the |/EmbeddedFiles| name trees are +% handled implicitly if destinations or files are added. Names to the other +% name trees can be added with |\pdfmanagement_add:nnn|, e.g. to add an value to +% the AP names (for appearance streams) use +% +% \begin{verbatim} +% \pdfmanagement_add:nnx { Catalog / Names / AP } {myAPname} {\pdf_object_ref_last:} +% \end{verbatim} +% +% Remarks: +% \begin{itemize} +% \item The name |myAPname| is processed through |\pdf_string_from_unicode:nnN{utf8/string}| +% and parentheses are added automatically. Ensure that the use of the name +% handles it in the same way. +% \item It is currently not possible to test if a name has already been used +% by another package or previous code, +% so use names where you can be confident that they are unique. +% (It would be possible to split up the first part and test, but it would slow +% down the compilation and I'm not sure if it is worth the trouble) +% \item The value is not preprocessed, it is up-to-you to ensure that it does the +% right thing. +% \item Currently the structure of the name tree is flat, it doesn't use +% Kids. But this can be changed if the need arise. +% \end{itemize} +% +% The following name trees can be filled with this method. Currently only the +% first three are activated. For the first, |EmbeddedFiles| there are two methods +% to add a value:\\ +% |\pdfmanagement_add:nnn{Catalog/Names/EmbeddedFiles}{name}{reference}| +% and +% |\pdfmanagement_add:nnn{Catalog/Names}{EmbeddedFiles}{reference}|. +% This is intended, the second methods creates a name on the fly (with the prefix l3ef) +% +% \medskip +% \noindent +% \begin{tabularx}{\linewidth}{ll>{\raggedright\arraybackslash}X} +% Catalog/Names/EmbeddedFiles & A name tree mapping name strings to file +% specifications for embedded file streams. The value should be a reference to a filespec +% dictionary\\ +% Catalog/Names/AP & A name tree mapping name strings to annotation appearance streams\\ +% Catalog/Names/JavaScript & A name tree mapping name strings to documentlevel ECMAScript actions\\ +% (inactive) Catalog/Names/Pages & A name tree mapping name strings to visible pages for use in interactive forms\\ +% (inactive) Catalog/Names/Templates & A name tree mapping name strings to invisible pages for use in interactive forms\\ +% (inactive) Catalog/Names/IDS & A name tree mapping digital identifiers to Web.Capture content sets\\ +% (inactive) Catalog/Names/URLS & A name tree mapping name strings to documentlevel ECMAScript actions\\ +% (inactive) Catalog/Names/Renditions & A name tree mapping name strings (which shall have Unicode encoding) to rendition objects +% (it is not quite clear yet, what unicode encoding means here. Perhaps this string will need special handling)\\ +% \end{tabularx} % \end{documentation} % % \begin{implementation} @@ -557,7 +622,7 @@ %<@@=pdfmanagement> %<*header> % -\ProvidesExplPackage{l3pdfmanagement}{2021-07-21}{0.95g} +\ProvidesExplPackage{l3pdfmanagement}{2021-07-31}{0.95h} {Management of core PDF dictionaries (LaTeX PDF management testphase bundle)} % % \end{macrocode} @@ -576,6 +641,9 @@ \msg_new:nnn { pdfmanagement } { no-show } { It~is~not~possible~to~show~the~content~of~'#1'.} +\msg_new:nnn { pdfmanagement } { name-exist } + { The~name~'#1'~has~already~been~used~for~name~tree~'#2'.} + \msg_new:nnn { pdfmanagement } { show-dict } { The~PDF~resource~'#1'~ @@ -593,6 +661,16 @@ command~'#1'~ignored. } % \end{macrocode} +% +% \begin{variable}{\l_@@_tmpa_tl,\l_@@_tmpb_tl,\l_@@_tmpa_seq} +% Some temp variables +% \begin{macrocode} +\tl_new:N \l_@@_tmpa_tl +\tl_new:N \l_@@_tmpb_tl +\seq_new:N \l_@@_tmpa_seq +% \end{macrocode} +% \end{variable} + % \begin{variable}{\g_@@_active_bool} % This boolean will control the activation of the management code. % It is used in the hooks, and in some backend files. @@ -612,6 +690,7 @@ \prg_set_eq_conditional:NNn \pdfmanagement_if_active: \@@_if_active: { p , T , F , TF } +\cs_set_eq:NN \IfPDFManagementActiveTF\pdfmanagement_if_active:TF % \end{macrocode} % We use a hook, to collect value added before the backend is ready. % \begin{macrocode} @@ -639,7 +718,8 @@ } } -\cs_generate_variant:Nn \pdfmanagement_add:nnn {nnx,nxx} +\cs_generate_variant:Nn \pdfmanagement_add:nnn {nnx,nxx,xxx} +\cs_set_eq:NN \PDFManagementAdd \pdfmanagement_add:xxx % \end{macrocode} % \subsection{Hooks -- shipout and end of run code} % Code is executed in three places: At shipout of every page, @@ -1006,6 +1086,7 @@ % \end{variable} % \begin{macro}{ \@@_catalog_XX_gput:n } % Various commands to handle subentries and special cases. +% At first we set up a few lists of the various types. % \begin{macrocode} \pdfdict_new:n { g__pdf_Core/Catalog} @@ -1059,8 +1140,24 @@ AcroForm/CO } - - +% \end{macrocode} +% Names trees in Catalog/Names. We prepare the full list +% but activate only AP and JavaScript for now. +% /EmbeddedFiles has special code and so is not in the name list. +% \begin{macrocode} +\clist_const:Nn \c_@@_Catalog_nametree_clist + { + AP, + JavaScript, +% Pages, +% Templates, +% IDS, +% URLS, +% Renditions + } +% \end{macrocode} +% now we create the handler. The entries in the seq-list store in a seq +% \begin{macrocode} \clist_map_inline:Nn \c_@@_Catalog_seq_clist { \seq_new:c { g_@@_/Catalog/#1_seq } % new name later @@ -1070,6 +1167,10 @@ } } +% \end{macrocode} +% OCProperties/D is special: it handles a default. This is done by adding to +% the left of the seq +% \begin{macrocode} \cs_new_protected:cpn { @@_handler/Catalog/OCProperties/D_gput:n } #1 { \seq_gput_left:cn @@ -1077,6 +1178,58 @@ { #1 } } % \end{macrocode} +% The name tree keys store in a property and check for duplicates. This is done +% with an auxiliary. +% \begin{macrocode} +\cs_new_protected:Npn \@@_nametree_add_aux:nnn #1 #2 #3 + %#1 name tree, #2 sanitized name #3 value + { + \prop_get:coNTF + { \__kernel_pdfdict_name:n { g__pdf_Core/Catalog/Names/#1 }} + { #2 } + \l_@@_tmpb_tl + { + \msg_error:nnnn{pdfmanagement}{name-exist}{#2}{#1} + } + { + \prop_gput:con + { \__kernel_pdfdict_name:n { g__pdf_Core/Catalog/Names/#1 }} + { #2 } + { #3 } + } + } +% \end{macrocode} +% This is the standard handler for most names trees: +% \begin{macrocode} +\clist_map_inline:Nn \c_@@_Catalog_nametree_clist + { + \pdfdict_new:n { g__pdf_Core/Catalog/Names/#1} + \cs_new_protected:cpn { @@_handler/Catalog/Names/#1/?_gput:nn } ##1 ##2 + { + \pdf_string_from_unicode:nnN {utf8/string}{##1}\l_@@_tmpa_tl + \exp_args:Nno + \@@_nametree_add_aux:nnn {#1}{\l_@@_tmpa_tl}{##2} + } + } +% \end{macrocode} +% EmbeddedFiles is a bit special. For once there is special backend code +% needed by dvips. Beside this we also want the option to create the file name +% on the fly, so they are actually two access methods: +% |\pdfmanagement_add:nnn{Catalog/Names/EmbeddedFiles}{name}{reference}| +% and +% |\pdfmanagement_add:nnn{Catalog/Names}{EmbeddedFiles}{reference}| +% \begin{macrocode} +\pdfdict_new:n { g__pdf_Core/Catalog/Names/EmbeddedFiles} +\cs_new_protected:cpn { @@_handler/Catalog/Names/EmbeddedFiles/?_gput:nn } #1 #2 + { + \pdf_string_from_unicode:nnN {utf8/string}{#1}\l_@@_tmpa_tl + \exp_args:Nno + \@@_nametree_add_aux:nnn + {EmbeddedFiles}{\l_@@_tmpa_tl}{#2} + \exp_args:No + \__pdf_backend_NamesEmbeddedFiles_add:nn {\l_@@_tmpa_tl}{#2} + } +% \end{macrocode} % \end{macro} % % \paragraph {Building the catalog: Push order} % \begin{macro}{\@@_Catalog_gpush:} @@ -1099,7 +1252,11 @@ { \__kernel_pdfdict_name:n { g__pdf_Core/Catalog} } \__pdf_backend_catalog_gput:nn % output names tree: - \use:c { @@_/Catalog/Names/EmbeddedFiles_gpush: } + \use:c{ @@_/Catalog/Names_gpush:n } {EmbeddedFiles} + \clist_map_inline:Nn \c_@@_Catalog_nametree_clist + { + \use:c{ @@_/Catalog/Names_gpush:n } {##1} + } } % \end{macrocode} % \end{macro} @@ -1283,12 +1440,12 @@ { 0 } { \__pdf_backend_object_new:nn { @@/Catalog/OCProperties } { dict } - \seq_gpop_left:cN { g_@@_/Catalog/OCProperties/Configs_seq} \l_tmpa_tl + \seq_gpop_left:cN { g_@@_/Catalog/OCProperties/Configs_seq} \l_@@_tmpa_tl \exp_args:Nnx \__pdf_backend_object_write:nn {@@/Catalog/OCProperties} { /OCGs~[ \seq_use:cn { g_@@_/Catalog/OCProperties/OCGs_seq } {~} ] - /D~\l_tmpa_tl~ + /D~\l_@@_tmpa_tl~ \seq_if_empty:cF { g_@@_/Catalog/OCProperties/Configs_seq } { /Configs~ @@ -1382,6 +1539,30 @@ % \begin{NOTE}{UF} % TODO access function for the name in the name tree % \end{NOTE} +% \begin{variable}{\g_@@_EmbeddedFiles_int} +% We want to create names for files on the fly. For this we use an int. +% \begin{macrocode} +\int_new:N \g_@@_EmbeddedFiles_int +% \end{macrocode} +% \end{variable} +% \begin{macro}{\@@_EmbeddedFiles_name:} +% We use the prefix l3ef, and pad numbers below 9999. +% \begin{macrocode} +\cs_new:Npn \@@_EmbeddedFiles_name: + { + ( + l3ef + \int_compare:nNnT {\g_@@_EmbeddedFiles_int} < {10} + {0} + \int_compare:nNnT {\g_@@_EmbeddedFiles_int} < {100} + {0} + \int_compare:nNnT {\g_@@_EmbeddedFiles_int} < {1000} + {0} + \int_use:N \g_@@_EmbeddedFiles_int + ) + } +% \end{macrocode} +% \end{macro} % \begin{macro}{ Handler} % EmbeddedFiles is an array and needs a special handler to add values. % \begin{macrocode} @@ -1389,25 +1570,44 @@ \cs_new_protected:cpn { @@_handler/Catalog/Names/EmbeddedFiles_gput:n } #1 { - \__pdf_backend_NamesEmbeddedFiles_add:n { #1 } + \int_gincr:N \g_@@_EmbeddedFiles_int + \exp_args:Nnx + \prop_gput:cnn + { \__kernel_pdfdict_name:n { g__pdf_Core/Catalog/Names/EmbeddedFiles }} + { \@@_EmbeddedFiles_name: } + { #1 } + \exp_args:Nx + \__pdf_backend_NamesEmbeddedFiles_add:nn {\@@_EmbeddedFiles_name:} { #1 } } % \end{macrocode} % \end{macro} -% The entry should only be added if there are actually embedded files. -% This can be tested by checking the names_seq -% \begin{macro}{\@@_/Catalog/Names/EmbeddedFiles_gpush:} +% This pushes out the other names trees (but not with dvips). +% TODO: currently it simply write in the root of the name tree. +% That is the fastest. +% If they get longer we perhaps need to build something with Kids and Limits. +% \begin{macro}{\@@_/Catalog/Names/?_gpush:} % \begin{macrocode} -% -\cs_new_protected:cpn { @@_/Catalog/Names/EmbeddedFiles_gpush: } - { - \seq_if_empty:NF \g__pdf_backend_EmbeddedFiles_seq - { - \exp_args:Nx \__pdf_backend_NamesEmbeddedFiles_gpush:n - { - \seq_use:Nn \g__pdf_backend_EmbeddedFiles_seq {~} - } - } - } +\cs_new_protected:cpn { @@_/Catalog/Names_gpush:n } #1 %#1 name of name tree + { + \pdfdict_if_empty:nF { g__pdf_Core/Catalog/Names/#1 } + { + \seq_clear:N \l_@@_tmpa_seq + \prop_map_inline:cn + {\__kernel_pdfdict_name:n { g__pdf_Core/Catalog/Names/#1 }} + { \seq_put_right:Nn \l_@@_tmpa_seq {##1~##2}} + \seq_sort:Nn \l_@@_tmpa_seq + { + \str_compare:nNnTF {##1} > {##2} + { \sort_return_swapped: } + { \sort_return_same: } + } + \exp_args:Nnx \__pdf_backend_Names_gpush:nn + {#1} + { + \seq_use:Nn \l_@@_tmpa_seq {~} + } + } + } % \end{macrocode} % \end{macro} % \begin{macro}{@@_handler/Catalog/?_show:} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.pdf index f017471217..5e1cb6535c 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdfmanagement.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.dtx index f590a2b897..3ca574f02a 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.dtx @@ -53,7 +53,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -343,7 +343,7 @@ % \begin{macrocode} %<@@=pdfmeta> %<*header> -\ProvidesExplPackage{l3pdfmeta}{2021-07-21}{0.95g} +\ProvidesExplPackage{l3pdfmeta}{2021-07-31}{0.95h} {PDF-Standards---LaTeX PDF management testphase bundle} % % \end{macrocode} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.pdf index 030b8f17d8..d85623dae6 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdfmeta.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdftools.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdftools.dtx index 2df7203e0f..efed778e78 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdftools.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdftools.dtx @@ -53,7 +53,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -215,7 +215,7 @@ % % \begin{macrocode} %<*header> -\ProvidesExplPackage{l3pdftools}{2021-07-21}{0.95g} +\ProvidesExplPackage{l3pdftools}{2021-07-31}{0.95h} {candidate commands for l3pdf---LaTeX PDF management testphase bundle} % % \end{macrocode} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdftools.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdftools.pdf index c322f0e976..ee977c642c 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdftools.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdftools.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.dtx b/macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.dtx index eef4ae7ee0..0591756bf0 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.dtx @@ -52,7 +52,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -136,7 +136,7 @@ % \begin{macrocode} %<@@=pdf> %<*header> -\ProvidesExplPackage{l3pdfxform}{2021-07-21}{0.95g} +\ProvidesExplPackage{l3pdfxform}{2021-07-31}{0.95h} {command to create xforms (beta)---LaTeX PDF management testphase bundle} % % \end{macrocode} diff --git a/macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.pdf b/macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.pdf index 7e6db80d8a..59336ced8e 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.pdf and b/macros/latex/contrib/pdfmanagement-testphase/l3pdfxform.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/ltdocinit.dtx b/macros/latex/contrib/pdfmanagement-testphase/ltdocinit.dtx index 0679203098..4e7eecc1ab 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/ltdocinit.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/ltdocinit.dtx @@ -51,7 +51,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -182,7 +182,7 @@ % \begin{macrocode} %<@@=pdfmanagement> %<*header> -\ProvidesExplPackage{ltdocinit}{2021-07-21}{0.95g} +\ProvidesExplPackage{ltdocinit}{2021-07-31}{0.95h} {Initialize document metadata} % % \end{macrocode} diff --git a/macros/latex/contrib/pdfmanagement-testphase/ltdocinit.pdf b/macros/latex/contrib/pdfmanagement-testphase/ltdocinit.pdf index ce3ecd37bb..4d155d2c4c 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/ltdocinit.pdf and b/macros/latex/contrib/pdfmanagement-testphase/ltdocinit.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/pdflscape-ltx.sty b/macros/latex/contrib/pdfmanagement-testphase/pdflscape-ltx.sty index d123a70115..fdfe7b4279 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/pdflscape-ltx.sty +++ b/macros/latex/contrib/pdfmanagement-testphase/pdflscape-ltx.sty @@ -22,7 +22,7 @@ %% This work consists of the main source file pdflscape-ltx.sty %% \NeedsTeXFormat{LaTeX2e} -\ProvidesExplPackage{pdflscape-ltx}{2021-07-21}{0.95g} +\ProvidesExplPackage{pdflscape-ltx}{2021-07-31}{0.95h} {Display of landscape pages in PDF - adaption of pdflscape to the PDFmanagement bundle (testphase)} \DeclareOption*{\PassOptionsToPackage\CurrentOption{graphics}} diff --git a/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.dtx b/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.dtx index 364304de2c..1295c4b6bf 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.dtx @@ -51,7 +51,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -67,7 +67,7 @@ % |firstaidoff={name1,name2,...}|. % \begin{macrocode} %<*package> -\ProvidesExplPackage{pdfmanagement-firstaid}{2021-07-21}{0.95g} +\ProvidesExplPackage{pdfmanagement-firstaid}{2021-07-31}{0.95h} {LaTeX PDF management testphase bundle / firstaid-patches} %<@@=pdfmanagement> diff --git a/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.pdf b/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.pdf index 0aeab401dd..5206d4027b 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.pdf and b/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-firstaid.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.dtx b/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.dtx index 7d0b20ee02..37dc11f65b 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.dtx +++ b/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.dtx @@ -51,7 +51,7 @@ % }^^A % } % -% \date{Version 0.95g, released 2021-07-21} +% \date{Version 0.95h, released 2021-07-31} % % \maketitle % \begin{documentation} @@ -384,7 +384,7 @@ % \begin{macrocode} %<@@=pdf> %<*package> -\ProvidesExplPackage{pdfmanagement-testphase}{2021-07-21}{0.95g} +\ProvidesExplPackage{pdfmanagement-testphase}{2021-07-31}{0.95h} {LaTeX PDF management testphase bundle} \providecommand\IfFormatAtLeastTF{\@ifl@t@r\fmtversion} \IfFormatAtLeastTF{2020-10-01}{}{ @@ -411,7 +411,7 @@ % to allow to set it in the document. % \begin{macrocode} %<*header> -\ProvidesExplFile{pdfmanagement-testphase.ltx}{2021-07-21}{0.95g} +\ProvidesExplFile{pdfmanagement-testphase.ltx}{2021-07-31}{0.95h} {PDF~management~code~(testphase)} % %<*package> diff --git a/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.pdf b/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.pdf index 4928dea1fc..64f1d65c19 100644 Binary files a/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.pdf and b/macros/latex/contrib/pdfmanagement-testphase/pdfmanagement-testphase.pdf differ diff --git a/macros/latex/contrib/pdfmanagement-testphase/transparent-ltx.sty b/macros/latex/contrib/pdfmanagement-testphase/transparent-ltx.sty index 5151ea4ff9..e7cf7c36e5 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/transparent-ltx.sty +++ b/macros/latex/contrib/pdfmanagement-testphase/transparent-ltx.sty @@ -3,7 +3,7 @@ %% a replacement for transparent sty from Heiko Oberdiek %% \NeedsTeXFormat{LaTeX2e}[2020/10/01] -\ProvidesExplPackage{transparent-ltx}{2021-07-21}{0.95g} +\ProvidesExplPackage{transparent-ltx}{2021-07-31}{0.95h} {Transparency with color stacks (replacement for transparent.sty from Heiko Oberdiek)}% \RequirePackage{l3opacity} diff --git a/macros/latex/contrib/pdfmanagement-testphase/xcolor-patches-tmp-ltx.sty b/macros/latex/contrib/pdfmanagement-testphase/xcolor-patches-tmp-ltx.sty index 0861462d6b..12c87fdd33 100644 --- a/macros/latex/contrib/pdfmanagement-testphase/xcolor-patches-tmp-ltx.sty +++ b/macros/latex/contrib/pdfmanagement-testphase/xcolor-patches-tmp-ltx.sty @@ -1,6 +1,6 @@ %% LaTeX2e file `xcolor-patches.sty' %% -\ProvidesPackage{xcolor-patches-tmp-ltx}[2021-07-21 v0.95g patch xcolor for l3color] +\ProvidesPackage{xcolor-patches-tmp-ltx}[2021-07-31 v0.95h patch xcolor for l3color] \@ifundefined{color_set:nn}{\RequirePackage{l3color}}{} \ExplSyntaxOn @@ -116,3 +116,21 @@ {\noexpand\xcolor@{\@@cls}{\the\toks@}{\@@mod}{\@@clr}}}% \fi}% \expandafter\endgroup\@@tmp\xglobal@stop} + +%re-predefine the colors +\definecolorset{rgb/hsb/cmyk/gray}{}{}% + {brown,.75,.5,.25/.083333,.66667,.75/0,.25,.5,.25/.5475;% + lime,.75,1,0/.20833,1,1/.25,0,1,0/.815;% + orange,1,.5,0/.083333,1,1/0,.5,1,0/.595;% + pink,1,.75,.75/0,.25,1/0,.25,.25,0/.825;% + purple,.75,0,.25/.94444,1,.75/0,.75,.5,.25/.2525;% + teal,0,.5,.5/.5,1,.5/.5,0,0,.5/.35;% + violet,.5,0,.5/.83333,1,.5/0,.5,0,.5/.205}% +\definecolorset{cmyk/rgb/hsb/gray}{}{}% + {olive,0,0,1,.5/.5,.5,0/.16667,1,.5/.39} +\definecolorset{gray/rgb/hsb/cmyk}{}{}% + {darkgray,.25/.25,.25,.25/0,0,.25/0,0,0,.75;% + gray,.5/.5,.5,.5/0,0,.5/0,0,0,.5;% + lightgray,.75/.75,.75,.75/0,0,.75/0,0,0,.25} + +\endinput diff --git a/support/latexindent/LatexIndent/Document.pm b/support/latexindent/LatexIndent/Document.pm index 85a0557950..4098d01813 100644 --- a/support/latexindent/LatexIndent/Document.pm +++ b/support/latexindent/LatexIndent/Document.pm @@ -222,6 +222,21 @@ sub find_objects{ # one sentence per line: sentences are objects, as of V3.5.1 $self->one_sentence_per_line if ($is_m_switch_active and ${$masterSettings{modifyLineBreaks}{oneSentencePerLine}}{manipulateSentences}); + if ($is_m_switch_active and !${$self}{preamblePresent}){ + $self->yaml_get_textwrap_removeparagraphline_breaks; + } + + if( $is_m_switch_active and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{beforeFindingChildCodeBlocks} == 1){ + # call the remove_paragraph_line_breaks and text_wrap routines + if(${$masterSettings{modifyLineBreaks}{removeParagraphLineBreaks}}{beforeTextWrap}){ + $self->remove_paragraph_line_breaks if ${$self}{removeParagraphLineBreaks}; + $self->text_wrap if (${$self}{textWrapOptions} and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{perCodeBlockBasis}); + } else { + $self->text_wrap if (${$self}{textWrapOptions} and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{perCodeBlockBasis}); + $self->remove_paragraph_line_breaks if ${$self}{removeParagraphLineBreaks}; + } + } + # search for environments $logger->trace('looking for ENVIRONMENTS') if $is_t_switch_active; $self->find_environments if ${$self}{body} =~ m/$environmentBasicRegExp/s; @@ -238,17 +253,15 @@ sub find_objects{ $self->find_commands_or_key_equals_values_braces_and_special if ${$self}{body} =~ m/$specialBeginAndBracesBracketsBasicRegExp/s; # documents without preamble need a manual call to the paragraph_one_line routine - if ($is_m_switch_active and !${$self}{preamblePresent}){ - $self->yaml_get_textwrap_removeparagraphline_breaks; - - # call the remove_paragraph_line_breaks and text_wrap routines - if(${$masterSettings{modifyLineBreaks}{removeParagraphLineBreaks}}{beforeTextWrap}){ - $self->remove_paragraph_line_breaks if ${$self}{removeParagraphLineBreaks}; - $self->text_wrap if (${$self}{textWrapOptions} and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{perCodeBlockBasis}); - } else { - $self->text_wrap if (${$self}{textWrapOptions} and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{perCodeBlockBasis}); - $self->remove_paragraph_line_breaks if ${$self}{removeParagraphLineBreaks}; - } + if ($is_m_switch_active and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{beforeFindingChildCodeBlocks} == 0 ){ + # call the remove_paragraph_line_breaks and text_wrap routines + if(${$masterSettings{modifyLineBreaks}{removeParagraphLineBreaks}}{beforeTextWrap}){ + $self->remove_paragraph_line_breaks if ${$self}{removeParagraphLineBreaks}; + $self->text_wrap if (${$self}{textWrapOptions} and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{perCodeBlockBasis}); + } else { + $self->text_wrap if (${$self}{textWrapOptions} and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{perCodeBlockBasis}); + $self->remove_paragraph_line_breaks if ${$self}{removeParagraphLineBreaks}; + } } # if there are no children, return @@ -303,12 +316,15 @@ sub get_settings_and_store_new_object{ # there are a number of tasks common to each object $latexIndentObject->tasks_common_to_each_object(%{$self}); + + # removeParagraphLineBreaks and textWrapping fun! + $latexIndentObject->text_wrap_remove_paragraph_line_breaks if( $is_m_switch_active and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{beforeFindingChildCodeBlocks} ); # tasks particular to each object $latexIndentObject->tasks_particular_to_each_object; # removeParagraphLineBreaks and textWrapping fun! - $latexIndentObject->text_wrap_remove_paragraph_line_breaks if($is_m_switch_active); + $latexIndentObject->text_wrap_remove_paragraph_line_breaks if($is_m_switch_active and !${$masterSettings{modifyLineBreaks}{textWrapOptions}}{beforeFindingChildCodeBlocks} ); # store children in special hash push(@{${$self}{children}},$latexIndentObject); diff --git a/support/latexindent/LatexIndent/GetYamlSettings.pm b/support/latexindent/LatexIndent/GetYamlSettings.pm index f28fdd6525..1529493d4f 100644 --- a/support/latexindent/LatexIndent/GetYamlSettings.pm +++ b/support/latexindent/LatexIndent/GetYamlSettings.pm @@ -570,6 +570,27 @@ sub yaml_read_settings{ $logger->info(Dumper(\%masterSettings)); } + if( $is_m_switch_active + and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{beforeFindingChildCodeBlocks} + and !${$masterSettings{modifyLineBreaks}{textWrapOptions}}{perCodeBlockBasis} ){ + + # the following settings don't make sense, so we change + # + # modifyLineBreaks: + # textWrapOptions: + # perCodeBlockBasis: 0 + # beforeFindingChildCodeBlocks: 1 + # into + # + # modifyLineBreaks: + # textWrapOptions: + # perCodeBlockBasis: 0 + # beforeFindingChildCodeBlocks: 0 + $logger->warn("*textWrapOptions:beforeFindingChildCodeBlocks:1 with textWrapOptions:perCodeBlockBasis:0"); + $logger->warn("turning off beforeFindingChildCodeBlocks by changing textWrapOptions:beforeFindingOtherCodeBlocks to be 0"); + $logger->warn("you need to set *both* values to be 1 to use the beforeFindingChildCodeBlocks feature"); + ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{beforeFindingChildCodeBlocks} = 0; + } return; } diff --git a/support/latexindent/LatexIndent/ModifyLineBreaks.pm b/support/latexindent/LatexIndent/ModifyLineBreaks.pm index 1b3f948645..f11221e25b 100644 --- a/support/latexindent/LatexIndent/ModifyLineBreaks.pm +++ b/support/latexindent/LatexIndent/ModifyLineBreaks.pm @@ -274,6 +274,7 @@ sub verbatim_modify_line_breaks{ } } } + sub text_wrap_remove_paragraph_line_breaks{ my $self = shift; @@ -293,6 +294,60 @@ sub text_wrap{ # alignment at ampersand can take priority return if(${$self}{lookForAlignDelims} and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{alignAtAmpersandTakesPriority}); + # goal: get an accurate measurement of verbatim objects; + # + # example: + # Lorem \verb!x+y! ipsum dolor sit amet + # + # is represented as + # + # Lorem LTXIN-TK-VERBATIM1-END ipsum dolor sit amet + # + # so we *measure* the verbatim token and replace it with + # an appropriate-length string + # + # Lorem a2A41233rt ipsum dolor sit amet + # + # and then put the body back to + # + # Lorem LTXIN-TK-VERBATIM1-END ipsum dolor sit amet + # + # following the text wrapping + my @putVerbatimBackIn; + + # check body for verbatim and get measurements + if (${$self}{body} =~ m/$tokens{verbatim}/s and ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{huge} eq "overflow"){ + + # reference: https://stackoverflow.com/questions/10336660/in-perl-how-can-i-generate-random-strings-consisting-of-eight-hex-digits + my @set = ('0' ..'9', 'A' .. 'Z', 'a' .. 'z'); + + # loop through verbatim objects + while( my ($verbatimID,$child)= each %verbatimStorage){ + my $verbatimThing = ${$child}{begin}.${$child}{body}.${$child}{end}; + + # if the object has line breaks, don't measure it + next if $verbatimThing =~ m/\R/s; + + if(${$self}{body} =~m/$verbatimID/s){ + + # measure length + my $verbatimLength = Unicode::GCString->new($verbatimThing)->columns(); + + # create temporary ID, and check that it is not contained in the body + my $verbatimTmpID = join '' => map $set[rand @set], 1 .. $verbatimLength; + while(${$self}{body} =~m/$verbatimTmpID/s){ + $verbatimTmpID = join '' => map $set[rand @set], 1 .. $verbatimLength; + } + + # store for use after the text wrapping + push(@putVerbatimBackIn,{origVerbatimID=>$verbatimID,tmpVerbatimID=>$verbatimTmpID}); + + # make the substitution + ${$self}{body} =~ s/$verbatimID/$verbatimTmpID/s; + } + } + } + # call the text wrapping routine my $columns; @@ -311,15 +366,20 @@ sub text_wrap{ $columns = 80; } + # vital Text::Wrap options $Text::Wrap::columns=$columns; - if(${$masterSettings{modifyLineBreaks}{textWrapOptions}}{separator} ne ''){ - $Text::Wrap::separator=${$masterSettings{modifyLineBreaks}{textWrapOptions}}{separator}; - } - $Text::Wrap::huge = ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{huge} if ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{huge}; + $Text::Wrap::huge = ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{huge}; + + # all other Text::Wrap options not usually needed/helpful, but available + $Text::Wrap::separator=${$masterSettings{modifyLineBreaks}{textWrapOptions}}{separator} if(${$masterSettings{modifyLineBreaks}{textWrapOptions}}{separator} ne ''); $Text::Wrap::break = ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{break} if ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{break}; $Text::Wrap::unexpand = ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{unexpand} if ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{unexpand}; $Text::Wrap::tabstop = ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{tabstop} if ${$masterSettings{modifyLineBreaks}{textWrapOptions}}{tabstop}; + + # perform the text wrapping ${$self}{body} = wrap('','',${$self}{body}); + + ${$self}{body} =~ s/${$_}{tmpVerbatimID}/${$_}{origVerbatimID}/s foreach (@putVerbatimBackIn); } sub construct_paragraph_reg_exp{ diff --git a/support/latexindent/LatexIndent/Version.pm b/support/latexindent/LatexIndent/Version.pm index 41ff54c12b..81a37b49c0 100644 --- a/support/latexindent/LatexIndent/Version.pm +++ b/support/latexindent/LatexIndent/Version.pm @@ -19,6 +19,6 @@ use warnings; use Exporter qw/import/; our @EXPORT_OK = qw/$versionNumber $versionDate/; -our $versionNumber = '3.10.1'; -our $versionDate = '2021-07-23'; +our $versionNumber = '3.11'; +our $versionDate = '2021-07-31'; 1 diff --git a/support/latexindent/README b/support/latexindent/README index a49f1a231f..04fd1c5b5f 100644 --- a/support/latexindent/README +++ b/support/latexindent/README @@ -1,5 +1,5 @@ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - latexindent.pl, version 3.10.1, 2021-07-23 + latexindent.pl, version 3.11, 2021-07-31 PERL script to indent code within environments, and align delimited environments in .tex files. diff --git a/support/latexindent/defaultSettings.yaml b/support/latexindent/defaultSettings.yaml index 94a3a9f4c6..edac9bad82 100644 --- a/support/latexindent/defaultSettings.yaml +++ b/support/latexindent/defaultSettings.yaml @@ -1,9 +1,10 @@ -# defaultSettings.yaml for latexindent.pl, version 3.10.1, 2021-07-23 +# defaultSettings.yaml for latexindent.pl, version 3.11, 2021-07-31 # a script that aims to # beautify .tex, .sty, .cls files # # (or latexindent.exe if you're on Windows) # +#--------------------------------------------------------------------------------------- # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or @@ -19,8 +20,8 @@ # Chris Hughes, 2017 # # For all communication, please visit: https://github.com/cmhughes/latexindent.pl - - +# +#--------------------------------------------------------------------------------------- # You should feel encouraged to change anything you like in these settings, but # it would probably be better to have your own user settings # files somewhere else - remember that this file may be overwritten @@ -31,6 +32,8 @@ # for details of how to create and configure your own settings files. # # Please read the manual (linked from above) first to understand what each switch does. +# +#--------------------------------------------------------------------------------------- # latexindent can be called to act on a file without using the file's extension, # e.g, simply @@ -512,6 +515,7 @@ modifyLineBreaks: huge: overflow # forbid mid-word line breaks separator: "" perCodeBlockBasis: 0 + beforeFindingChildCodeBlocks: 0 all: 0 alignAtAmpersandTakesPriority: 1 environments: diff --git a/support/latexindent/documentation/appendices.tex b/support/latexindent/documentation/appendices.tex index b6f1e9615c..bbeefb5fd1 100644 --- a/support/latexindent/documentation/appendices.tex +++ b/support/latexindent/documentation/appendices.tex @@ -1,11 +1,11 @@ % arara: pdflatex: {shell: yes, files: [latexindent]} \appendix \section{Required Perl modules}\label{sec:requiredmodules} - If you intend to use \texttt{latexindent.pl} and \emph{not} one of the - supplied standalone executable files, then you will need a few standard Perl modules -- - if you can run the minimum code in \cref{lst:helloworld} (\texttt{perl helloworld.pl}) then you will be able to run - \texttt{latexindent.pl}, otherwise you may need to install the missing modules -- see - \cref{sec:module-installer,sec:manual-module-instal}. + If you intend to use \texttt{latexindent.pl} and \emph{not} one of the supplied + standalone executable files, then you will need a few standard Perl modules -- if you can + run the minimum code in \cref{lst:helloworld} (\texttt{perl helloworld.pl}) then you will + be able to run \texttt{latexindent.pl}, otherwise you may need to install the missing + modules -- see \cref{sec:module-installer,sec:manual-module-instal}. \begin{cmhlistings}[style=tcblatex,language=Perl]{\texttt{helloworld.pl}}{lst:helloworld} #!/usr/bin/perl @@ -33,8 +33,9 @@ exit; \end{cmhlistings} \subsection{Module installer script}\label{sec:module-installer} - \announce{2018-01-13}{perl module helper script} \texttt{latexindent.pl} ships with a helper script that will - install any missing \texttt{perl} modules on your system; if you run + \announce{2018-01-13}{perl module helper script} \texttt{latexindent.pl} ships with a + helper script that will install any missing \texttt{perl} modules on your system; if you + run \begin{commandshell} perl latexindent-module-installer.pl \end{commandshell} @@ -42,8 +43,8 @@ perl latexindent-module-installer.pl \begin{dosprompt} perl latexindent-module-installer.pl \end{dosprompt} - then, once you have answered \texttt{Y}, the appropriate modules will be - installed onto your distribution. + then, once you have answered \texttt{Y}, the appropriate modules will be installed onto + your distribution. \subsection{Manually installed modules}\label{sec:manual-module-instal} Manually installing the modules given in \cref{lst:helloworld} will vary depending on @@ -77,10 +78,10 @@ sudo cpanm Unicode::GCString sudo perl -MCPAN -e'install "File::HomeDir"' \end{commandshell} - If you are using Alpine, some \texttt{Perl} modules are not build-compatible - with Alpine, but replacements are available through \texttt{apk}. For example, - you might use the commands given in \cref{lst:alpine-install}; thanks to - \cite{jun-sheaf} for providing these details. + If you are using Alpine, some \texttt{Perl} modules are not build-compatible with Alpine, + but replacements are available through \texttt{apk}. For example, you might use the + commands given in \cref{lst:alpine-install}; thanks to \cite{jun-sheaf} for providing + these details. \begin{cmhlistings}[style=tcblatex,language=Bash]{\texttt{alpine-install.sh}}{lst:alpine-install} # Installing perl @@ -106,7 +107,9 @@ cpanm -n YAML::Tiny cpanm -n Unicode::GCString \end{cmhlistings} - Users of NixOS might like to see \href{https://github.com/cmhughes/latexindent.pl/issues/222}{https://github.com/cmhughes/latexindent.pl/issues/222} for tips. + Users of NixOS might like to see + \href{https://github.com/cmhughes/latexindent.pl/issues/222}{https://github.com/cmhughes/latexindent.pl/issues/222} + for tips. \subsubsection{Mac} Users of the Macintosh operating system might like to explore the following commands, for example: @@ -124,7 +127,7 @@ cpanm Unicode::GCString readily available on CPAN \cite{cpan}. \texttt{indent.log} will contain details of the location - of the Perl modules on your system. \texttt{latexindent.exe} is a standalone executable + of the Perl modules on your system. \texttt{latexindent.exe} is a standalone executable for Windows (and therefore does not require a Perl distribution) and caches copies of the Perl modules onto your system; if you wish to see where they are cached, use the \texttt{trace} option, e.g @@ -134,14 +137,14 @@ latexindent.exe -t myfile.tex \section{Updating the path variable}\label{sec:updating-path} \texttt{latexindent.pl} has a few scripts (available at \cite{latexindent-home}) that can - update the \texttt{path} variables. Thank you to \cite{jasjuang} for this - feature. If you're on a Linux or Mac machine, then you'll want \texttt{CMakeLists.txt} - from \cite{latexindent-home}. + update the \texttt{path} variables. Thank you to \cite{jasjuang} for this feature. If + you're on a Linux or Mac machine, then you'll want \texttt{CMakeLists.txt} from + \cite{latexindent-home}. \subsection{Add to path for Linux} To add \texttt{latexindent.pl} to the path for Linux, follow these steps: \begin{enumerate} - \item download \texttt{latexindent.pl} and its associated modules, \texttt{defaultSettings.yaml}, to - your chosen directory from \cite{latexindent-home} ; + \item download \texttt{latexindent.pl} and its associated modules, + \texttt{defaultSettings.yaml}, to your chosen directory from \cite{latexindent-home} ; \item within your directory, create a directory called \texttt{path-helper-files} and download \texttt{CMakeLists.txt} and \lstinline!cmake_uninstall.cmake.in! from \cite{latexindent-home}/path-helper-files to this directory; @@ -162,8 +165,8 @@ sudo make install \begin{commandshell} ls /usr/local/bin \end{commandshell} - again to check that \texttt{latexindent.pl}, its modules and \texttt{defaultSettings.yaml} have - been added. + again to check that \texttt{latexindent.pl}, its modules and + \texttt{defaultSettings.yaml} have been added. \end{enumerate} To \emph{remove} the files, run \begin{commandshell} @@ -172,10 +175,10 @@ sudo make uninstall \subsection{Add to path for Windows} To add \texttt{latexindent.exe} to the path for Windows, follow these steps: \begin{enumerate} - \item download \texttt{latexindent.exe}, \texttt{defaultSettings.yaml}, \texttt{add-to-path.bat} from - \cite{latexindent-home} to your chosen directory; - \item open a command prompt and run the following command to see what is \emph{currently} - in your \lstinline!%path%! variable; + \item download \texttt{latexindent.exe}, \texttt{defaultSettings.yaml}, + \texttt{add-to-path.bat} from \cite{latexindent-home} to your chosen directory; + \item open a command prompt and run the following command to see what is \emph{currently} in + your \lstinline!%path%! variable; \begin{dosprompt} echo %path% \end{dosprompt} @@ -226,8 +229,8 @@ TRACE: Searching myenv for optional and mandatory arguments ... no arguments found ----- \end{cmhlistings} - Notice that the information given about \texttt{myenv} is `framed' using - \texttt{+++++} and \lstinline!-----! respectively. + Notice that the information given about \texttt{myenv} is `framed' using \texttt{+++++} + and \lstinline!-----! respectively. \section{Encoding indentconfig.yaml}\label{app:encoding} In relation to \vref{sec:indentconfig}, Windows users that encounter encoding issues with @@ -243,17 +246,17 @@ Active code page: 936 and can then use the settings given in \cref{lst:indentconfig-encoding1} within their \texttt{indentconfig.yaml}, where 936 is the result of the \texttt{chcp} command. - \cmhlistingsfromfile*{demonstrations/encoding1.yaml}[yaml-TCB]{\texttt{encoding} demonstration for \texttt{indentconfig.yaml}}{lst:indentconfig-encoding1} + \cmhlistingsfromfile{demonstrations/encoding1.yaml}[yaml-TCB]{\texttt{encoding} demonstration for \texttt{indentconfig.yaml}}{lst:indentconfig-encoding1} \section{dos2unix linebreak adjustment} \yamltitle{dos2unixlinebreaks}*{integer} If you use \texttt{latexindent.pl} on a dos-based Windows file on Linux - \announce*{2021-06-19}{dos2unix linebreaks} then you may find that trailing horizontal space is not removed - as you hope. + \announce{2021-06-19}{dos2unix linebreaks} then you may find that trailing horizontal + space is not removed as you hope. - In such a case, you may wish to try setting \texttt{dos2unixlinebreaks} to 1 and employing, - for example, the following command. + In such a case, you may wish to try setting \texttt{dos2unixlinebreaks} to 1 and + employing, for example, the following command. \begin{commandshell} latexindent.pl -y="dos2unixlinebreaks:1" myfile.tex @@ -278,11 +281,10 @@ latexindent.pl myfile.tex -o=outputfile.tex latexindent.pl myfile.tex -outputfile=outputfile.tex latexindent.pl myfile.tex -outputfile outputfile.tex \end{commandshell} - noting that the \emph{output} file is given \emph{next to} the - \texttt{-o} switch. + noting that the \emph{output} file is given \emph{next to} the \texttt{-o} switch. - The fields given in \cref{lst:obsoleteYaml} are \emph{obsolete} from Version 3.0 - onwards. \cmhlistingsfromfile{demonstrations/obsolete.yaml}[yaml-obsolete]{Obsolete YAML fields from Version 3.0}{lst:obsoleteYaml} + The fields given in \cref{lst:obsoleteYaml} are \emph{obsolete} from Version 3.0 onwards. + \cmhlistingsfromfile{demonstrations/obsolete.yaml}[yaml-obsolete]{Obsolete YAML fields from Version 3.0}{lst:obsoleteYaml} There is a slight difference when specifying indentation after headings; specifically, we now write \texttt{indentAfterThisHeading} instead of \texttt{indent}. See @@ -297,9 +299,9 @@ latexindent.pl myfile.tex -outputfile outputfile.tex \end{minipage}% To specify \texttt{noAdditionalIndent} for display-math environments in Version 2.2, you - would write YAML as in \cref{lst:noAdditionalIndentOld}; as of Version 3.0, you would write YAML - as in \cref{lst:indentAfterThisHeadingNew1} or, if you're using \texttt{-m} switch, - \cref{lst:indentAfterThisHeadingNew2}. + would write YAML as in \cref{lst:noAdditionalIndentOld}; as of Version 3.0, you would + write YAML as in \cref{lst:indentAfterThisHeadingNew1} or, if you're using \texttt{-m} + switch, \cref{lst:indentAfterThisHeadingNew2}. \index{specialBeginEnd!update to displaymath V3.0} \begin{minipage}{.45\textwidth} @@ -312,7 +314,8 @@ latexindent.pl myfile.tex -outputfile outputfile.tex \cmhlistingsfromfile{demonstrations/noAddtionalIndentNew1.yaml}[yaml-TCB]{\texttt{noAdditionalIndent} for \texttt{displayMath} in Version 3.0}{lst:indentAfterThisHeadingNew2} \end{minipage}% - \mbox{}\hfill \begin{minipage}{.25\textwidth} + \mbox{}\hfill + \begin{minipage}{.25\textwidth} \hrule \hfill\itshape End\\\mbox{}\hfill\mbox{}\rlap{\hfill\includegraphics{logo}} diff --git a/support/latexindent/documentation/figure-schematic.tex b/support/latexindent/documentation/figure-schematic.tex index 911f85f6ad..08fea69139 100644 --- a/support/latexindent/documentation/figure-schematic.tex +++ b/support/latexindent/documentation/figure-schematic.tex @@ -3,23 +3,21 @@ \usetikzlibrary{positioning} \begin{document} \begin{tikzpicture}[ - needed/.style={very thick, draw=blue,fill=blue!20, - text centered, minimum height=2.5em,rounded corners=1ex}, - optional/.style={draw=black, very thick,scale=0.8, - text centered, minimum height=2.5em,rounded corners=1ex}, + needed/.style={very thick, draw=blue,fill=blue!20, text centered, minimum height=2.5em,rounded corners=1ex}, + optional/.style={draw=black, very thick,scale=0.8, text centered, minimum height=2.5em,rounded corners=1ex}, optionalfill/.style={fill=black!10}, connections/.style={draw=black!30,dotted,line width=3pt,text=red}, ] % Draw diagram elements - \node (latexindent) [needed,circle] {\texttt{latexindent.pl}}; - \node (default) [needed,above right=.5cm of latexindent] {\texttt{defaultSettings.yaml}}; - \node (indentconfig) [optional,right=of latexindent] {\texttt{indentconfig.yaml}}; - \node (any) [optional,optionalfill,above right=of indentconfig] {\texttt{any.yaml}}; - \node (name) [optional,optionalfill,right=of indentconfig] {\texttt{name.yaml}}; - \node (you) [optional,optionalfill,below right=of indentconfig] {\texttt{you.yaml}}; - \node (want) [optional,optionalfill,below=of indentconfig] {\texttt{want.yaml}}; - \node (local) [optional,below=of latexindent] {\texttt{localSettings.yaml}}; - \node (yamlswitch) [optional,left=of latexindent] {\texttt{-y switch}}; + \node (latexindent) [needed,circle] {\texttt{latexindent.pl}}; + \node (default) [needed,above right=.5cm of latexindent] {\texttt{defaultSettings.yaml}}; + \node (indentconfig) [optional,right=of latexindent] {\texttt{indentconfig.yaml}}; + \node (any) [optional,optionalfill,above right=of indentconfig] {\texttt{any.yaml}}; + \node (name) [optional,optionalfill,right=of indentconfig] {\texttt{name.yaml}}; + \node (you) [optional,optionalfill,below right=of indentconfig] {\texttt{you.yaml}}; + \node (want) [optional,optionalfill,below=of indentconfig] {\texttt{want.yaml}}; + \node (local) [optional,below=of latexindent] {\texttt{localSettings.yaml}}; + \node (yamlswitch) [optional,left=of latexindent] {\texttt{-y switch}}; % Draw arrows between elements \draw[connections,solid] (latexindent) to[in=-90]node[pos=0.5,anchor=north]{1} (default.south) ; \draw[connections,optional] (latexindent) -- node[pos=0.5,anchor=north]{2} (indentconfig) ; diff --git a/support/latexindent/documentation/latexindent.pdf b/support/latexindent/documentation/latexindent.pdf index 09cd1d6f4f..dfb37e0b76 100644 Binary files a/support/latexindent/documentation/latexindent.pdf and b/support/latexindent/documentation/latexindent.pdf differ diff --git a/support/latexindent/documentation/latexindent.tex b/support/latexindent/documentation/latexindent.tex index 2691cfa9ec..9379dddcb0 100644 --- a/support/latexindent/documentation/latexindent.tex +++ b/support/latexindent/documentation/latexindent.tex @@ -12,12 +12,12 @@ % % This program is distributed in the hope that it will be useful, % but WITHOUT ANY WARRANTY; without even the implied warranty of -% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the % GNU General Public License for more details. % % See . \usepackage[left=4.5cm,right=2.5cm,showframe=false, - top=2cm,bottom=1.5cm,marginparsep=2cm]{geometry} % page setup + top=2cm,bottom=1.5cm,marginparsep=2cm]{geometry} % page setup \usepackage{lmodern} \usepackage{parskip} % paragraph skips \usepackage{booktabs} % beautiful tables @@ -31,7 +31,7 @@ \usepackage{fontawesome} \usepackage[sc,format=hang,font=small]{caption} % captions \usepackage[backend=bibtex]{biblatex} % bibliography -\usepackage{tcolorbox} % framed environments +\usepackage{tcolorbox} % framed environments \usepackage{tikz} \usepackage{xparse} \usepackage[charter]{mathdesign} % changes font @@ -79,9 +79,21 @@ \tcbset{doclang/new={{\bfseries\color{green!50!black}N\normalfont\color{black}}}} \tcbset{doclang/updated={{\bfseries\color{green!50!black}U\normalfont\color{black}}}} \tcbset{doc marginnote={width=1.6cm}} + +% \announce * { YYYY-MM-DD }*{ } +% +% NEW as of current version +% \announce*{date}*[text] means *updated* as of +% \announce*{date}[text] means *new* as of +% +% NOT new as of current version +% \announce{date}*[text] means *updated* as of +% \announce{date}[text] means *new* as of +% \NewDocumentCommand{\announce}{ s m s m }{% \IfBooleanTF{#1}% {% \announce* + % NEW in current version \tcbdocmarginnote[overlay={\node at ([yshift=0mm,xshift=1mm]frame.north east) {\stardemo}; }]{% \IfBooleanTF{#3}% {% \announce*{date}*[text] means *updated* as of @@ -100,6 +112,7 @@ }% }% {% \announce + % NOT new in current version \tcbdocmarginnote{% \IfBooleanTF{#3}% {% \announce{date}*[text] means *updated* as of @@ -223,18 +236,18 @@ raster valign=top,raster columns=2,#1]}{\end{tcbraster}} % \cmhlistingsfromfile -% * no star: not new, star: new +% * no star: not new, star: new % [ listing/minted options ] -% * no star: uses minted library, star: uses listings library star: +% * no star: uses minted library, star: uses listings library star: % {} % [] % {} % {<label>} % % for example, -% \cmhlistingsfromfile*[listing options]... uses listings library and is NEW -% \cmhlistingsfromfile[listing options]... uses listings library -% \cmhlistingsfromfile[listing options]*... uses minted library +% \cmhlistingsfromfile*[listing options]... uses listings library and is NEW +% \cmhlistingsfromfile[listing options]... uses listings library +% \cmhlistingsfromfile[listing options]*... uses minted library % \cmhlistingsfromfile*[listing options]*... uses minted library and is NEW \DeclareTCBInputListing[use counter=lstlisting]{\cmhlistingsfromfile}{s O{} s m O{} m m}{% cmhlistings, @@ -315,181 +328,181 @@ \lstdefinestyle{fileExtensionPreference}{ style=yaml-LST, - firstnumber=41,linerange={41-45}, + firstnumber=44,linerange={44-48}, numbers=left, } \lstdefinestyle{logFilePreferences}{ style=yaml-LST, - firstnumber=85,linerange={85-99}, + firstnumber=88,linerange={88-102}, numbers=left, } \lstdefinestyle{verbatimEnvironments}{ style=yaml-LST, - firstnumber=103,linerange={103-106}, + firstnumber=106,linerange={106-109}, numbers=left, } \lstdefinestyle{verbatimCommands}{ style=yaml-LST, - firstnumber=109,linerange={109-111}, + firstnumber=112,linerange={112-114}, numbers=left, } \lstdefinestyle{noIndentBlock}{ style=yaml-LST, - firstnumber=116,linerange={116-118}, + firstnumber=119,linerange={119-121}, numbers=left, } \lstdefinestyle{removeTrailingWhitespace}{ style=yaml-LST, - firstnumber=147,linerange={147-149}, + firstnumber=150,linerange={150-152}, numbers=left, } \lstdefinestyle{fileContentsEnvironments}{ style=yaml-LST, - firstnumber=122,linerange={122-124}, + firstnumber=125,linerange={125-127}, numbers=left, } \lstdefinestyle{lookForPreamble}{ style=yaml-LST, - firstnumber=130,linerange={130-134}, + firstnumber=133,linerange={133-137}, numbers=left, } \lstdefinestyle{lookForAlignDelims}{ style=yaml-LST, - firstnumber=152,linerange={152-168}, + firstnumber=155,linerange={155-171}, numbers=left, } \lstdefinestyle{indentAfterItems}{ style=yaml-LST, - firstnumber=225,linerange={225-229}, + firstnumber=228,linerange={228-232}, numbers=left, } \lstdefinestyle{itemNames}{ style=yaml-LST, - firstnumber=235,linerange={235-237}, + firstnumber=238,linerange={238-240}, numbers=left, } \lstdefinestyle{specialBeginEnd}{ style=yaml-LST, - firstnumber=241,linerange={241-254}, + firstnumber=244,linerange={244-257}, numbers=left, } \lstdefinestyle{indentAfterHeadings}{ style=yaml-LST, - firstnumber=264,linerange={264-273}, + firstnumber=267,linerange={267-276}, numbers=left, } \lstdefinestyle{noAdditionalIndentGlobalEnv}{ style=yaml-LST, - firstnumber=322,linerange={322-323}, + firstnumber=325,linerange={325-326}, numbers=left, } \lstdefinestyle{noAdditionalIndentGlobal}{ style=yaml-LST, - firstnumber=322,linerange={322-334}, + firstnumber=325,linerange={325-337}, numbers=left, } \lstdefinestyle{indentRulesGlobalEnv}{ style=yaml-LST, - firstnumber=338,linerange={338-339}, + firstnumber=341,linerange={341-342}, numbers=left, } \lstdefinestyle{indentRulesGlobal}{ style=yaml-LST, - firstnumber=338,linerange={338-350}, + firstnumber=341,linerange={341-353}, numbers=left, } \lstdefinestyle{commandCodeBlocks}{ style=yaml-LST, - firstnumber=353,linerange={353-368}, + firstnumber=356,linerange={356-371}, numbers=left, } \lstdefinestyle{modifylinebreaks}{ style=yaml-LST, - firstnumber=483,linerange={483-485}, + firstnumber=486,linerange={486-488}, numbers=left, } \lstdefinestyle{textWrapOptions}{ style=yaml-LST, - firstnumber=510,linerange={510-511}, + firstnumber=513,linerange={513-514}, numbers=left, } \lstdefinestyle{textWrapOptionsAll}{ style=yaml-LST, - firstnumber=510,linerange={510-527}, + firstnumber=513,linerange={513-531}, numbers=left, } \lstdefinestyle{removeParagraphLineBreaks}{ style=yaml-LST, - firstnumber=528,linerange={528-542}, + firstnumber=532,linerange={532-546}, numbers=left, } \lstdefinestyle{paragraphsStopAt}{ style=yaml-LST, - firstnumber=543,linerange={543-552}, + firstnumber=547,linerange={547-556}, numbers=left, } \lstdefinestyle{oneSentencePerLine}{ style=yaml-LST, - firstnumber=486,linerange={486-509}, + firstnumber=489,linerange={489-512}, numbers=left, } \lstdefinestyle{sentencesFollow}{ style=yaml-LST, - firstnumber=491,linerange={491-499}, + firstnumber=494,linerange={494-502}, numbers=left, } \lstdefinestyle{sentencesBeginWith}{ style=yaml-LST, - firstnumber=500,linerange={500-503}, + firstnumber=503,linerange={503-506}, numbers=left, } \lstdefinestyle{sentencesEndWith}{ style=yaml-LST, - firstnumber=504,linerange={504-509}, + firstnumber=507,linerange={507-512}, numbers=left, } \lstdefinestyle{modifylinebreaksEnv}{ style=yaml-LST, - firstnumber=553,linerange={553-562}, + firstnumber=557,linerange={557-566}, numbers=left, } \lstdefinestyle{replacements}{ style=yaml-LST, - firstnumber=614,linerange={614-622}, + firstnumber=618,linerange={618-626}, numbers=left, } \lstdefinestyle{fineTuning}{ style=yaml-LST, - firstnumber=625,linerange={625-648}, + firstnumber=629,linerange={629-652}, numbers=left, } @@ -521,12 +534,12 @@ \draw[inner sep=0,minimum size=rnd*15pt+2pt] decorate[decoration={stars,segment length=2cm}] { decorate[decoration={zigzag,segment length=2cm,amplitude=0.3cm}] { - ([xshift=-.5cm,yshift=0.1cm]frame.south west) -- ([xshift=-.5cm,yshift=0.4cm]frame.north west) + ([xshift=-.5cm,yshift=0.1cm]frame.south west) -- ([xshift=-.5cm,yshift=0.4cm]frame.north west) }}; \draw[inner sep=0,minimum size=rnd*15pt+2pt] decorate[decoration={stars,segment length=2cm}] { decorate[decoration={zigzag,segment length=2cm,amplitude=0.3cm}] { - ([xshift=.75cm,yshift=0.1cm]frame.south east) -- ([xshift=.75cm,yshift=0.6cm]frame.north east) + ([xshift=.75cm,yshift=0.1cm]frame.south east) -- ([xshift=.75cm,yshift=0.6cm]frame.north east) }}; \node[anchor=north west,outer sep=2pt,opacity=0.25] at ([xshift=-4.25cm]frame.north west) {\resizebox{3cm}{!}{\faGithub}}; }, @@ -607,18 +620,13 @@ \marginpar{\huge \color{red} \framebox{FIX}}% \typeout{FIXTHIS: p\thepage : #1^^J}% } -% custom section -\titleformat{\section} -{\normalfont\Large\bfseries} -{\llap{\thesection\hskip.5cm}} -{0pt} -{} \newcommand*\ruleline[1]{% \par\noindent\raisebox{.8ex}{\makebox[\linewidth]{\hrulefill\hspace{1ex}\raisebox{-1.8ex}{#1}\hspace{1ex}\hrulefill}}} \newcommand{\imagetouse}{logo-bw} +% custom section \titleformat% Formatting the header {\section} % command [block] % shape - Only managed to get it working with block @@ -634,6 +642,7 @@ {\llap{\thesubsection\hskip.5cm}} {0pt} {} + % custom subsubsection \titleformat{\subsubsection} {\normalfont\bfseries} @@ -641,9 +650,18 @@ {0pt} {} +% custom paragraph +\titleformat{\paragraph} +{\normalfont\bfseries} +{\llap{\theparagraph\hskip.5cm}} +{0pt} +{} + +% title spacing \titlespacing\section{0pt}{12pt plus 4pt minus 2pt}{34pt plus 2pt minus 2pt} \titlespacing\subsection{0pt}{12pt plus 4pt minus 2pt}{4pt plus 2pt minus 2pt} \titlespacing\subsubsection{0pt}{12pt plus 4pt minus 2pt}{4pt plus 2pt minus 2pt} +\titlespacing\paragraph{0pt}{12pt plus 4pt minus 2pt}{4pt plus 2pt minus 2pt} % list of listings \contentsuse{lstlisting}{lol} @@ -662,6 +680,7 @@ {\titlerule*[0.5em]{$\cdot$}\contentspage} [] \AtBeginDocument{\addtocontents{lol}{\protect\begin{widepage}\protect\begin{multicols}{2}}} +\preto{\printindex}{\addtocontents{lol}{\protect\end{multicols}\protect\end{widepage}}} % cleveref settings \crefname{table}{Table}{Tables} @@ -748,7 +767,8 @@ {}% <numberless-entry-format> {\titlerule*[0.5em]{$\cdot$}\contentspage} -\setcounter{secnumdepth}{5} +\setcounter{secnumdepth}{6} +\setcounter{tocdepth}{4} \makeindex \begin{document} \renewcommand*{\thefootnote}{\arabic{footnote}} @@ -773,14 +793,17 @@ \stopcontents[noAdditionalIndent] \input{subsec-commands-and-their-options} \input{sec-the-m-switch} + \input{subsec-text-wrap} + \input{subsec-remove-para-line-breaks} + \input{subsec-combine-text-wrap-para-line-breaks} + \input{subsec-text-wrap-summary} + \input{subsec-one-sentence-per-line} + \input{subsec-poly-switches} \stopcontents[the-m-switch] - \input{subsec-partnering-poly-switches} - \input{subsec-conflicting-poly-switches} \input{sec-replacements} \input{sec-fine-tuning} \input{sec-conclusions-know-limitations} \input{references} \input{appendices} - \addtocontents{lol}{\protect\end{multicols}\protect\end{widepage}} \printindex \end{document} diff --git a/support/latexindent/documentation/sec-conclusions-know-limitations.tex b/support/latexindent/documentation/sec-conclusions-know-limitations.tex index 938a0d6f53..990e001518 100644 --- a/support/latexindent/documentation/sec-conclusions-know-limitations.tex +++ b/support/latexindent/documentation/sec-conclusions-know-limitations.tex @@ -4,22 +4,25 @@ that are \emph{unknown}! For example, with reference to the multicolumn alignment routine in - \vref{lst:tabular2-mod2}), when working with code blocks in which multicolumn commands + \vref{lst:tabular2-mod2}, when working with code blocks in which multicolumn commands overlap, the algorithm can fail. - Another limitation is to do with efficiency, particularly when the \texttt{-m} - switch is active, as this adds many checks and processes. The current implementation - relies upon finding and storing \emph{every} code block (see the discussion on - \cpageref{page:phases}); I hope that, in a future version, only \emph{nested} code - blocks will need to be stored in the `packing' phase, and that this will improve the - efficiency of the script. + Another limitation is to do with efficiency, particularly when the \texttt{-m} switch is + active, as this adds many checks and processes. The current implementation relies upon + finding and storing \emph{every} code block (see the discussion on + \cpageref{page:phases}); I hope that, in a future version, only \emph{nested} code blocks + will need to be stored in the `packing' phase, and that this will improve the efficiency + of the script. You can run \texttt{latexindent} on any file;% - \announce{2019-07-13}*{ability to call latexindent on any file} if you don't specify an extension, then the extensions that you - specify in \lstinline[breaklines=true]!fileExtensionPreference! (see \vref{lst:fileExtensionPreference}) will be consulted. If you - find a case in which the script struggles, please feel free to report it at - \cite{latexindent-home}, and in the meantime, consider using a \texttt{noIndentBlock} (see \cpageref{lst:noIndentBlock}). + \announce{2019-07-13}*{ability to call latexindent on any file} if you don't specify an + extension, then the extensions that you specify in + \lstinline[breaklines=true]!fileExtensionPreference! (see + \vref{lst:fileExtensionPreference}) will be consulted. If you find a case in which the + script struggles, please feel free to report it at \cite{latexindent-home}, and in the + meantime, consider using a \texttt{noIndentBlock} (see \cpageref{lst:noIndentBlock}). I hope that this script is useful to some; if you find an example where the script does not behave as you think it should, the best way to contact me is to report an issue on - \cite{latexindent-home}; otherwise, feel free to find me on the \url{http://tex.stackexchange.com/users/6621/cmhughes}. + \cite{latexindent-home}; otherwise, feel free to find me on the + \url{http://tex.stackexchange.com/users/6621/cmhughes}. diff --git a/support/latexindent/documentation/sec-default-user-local.tex b/support/latexindent/documentation/sec-default-user-local.tex index 89a0596fd5..85738608b9 100644 --- a/support/latexindent/documentation/sec-default-user-local.tex +++ b/support/latexindent/documentation/sec-default-user-local.tex @@ -1,41 +1,40 @@ % arara: pdflatex: {shell: yes, files: [latexindent]} \section{defaultSettings.yaml}\label{sec:defuseloc} - \texttt{latexindent.pl} loads its settings from \texttt{defaultSettings.yaml}. The idea is to - separate the behaviour of the script from the internal working -- this is very similar to - the way that we separate content from form when writing our documents in \LaTeX. - - If you look in \texttt{defaultSettings.yaml} you'll find the switches that govern the behaviour - of \texttt{latexindent.pl}. If you're not sure where \texttt{defaultSettings.yaml} resides on - your computer, don't worry as \texttt{indent.log} will tell you where to find it. - \texttt{defaultSettings.yaml} is commented, but here is a description of what each switch is - designed to do. The default value is given in each case; whenever you see - \emph{integer} in \emph{this} section, assume that it must be - greater than or equal to \texttt{0} unless otherwise stated. - - For most of the settings in \texttt{defaultSettings.yaml} that are specified as integers, then - we understand \texttt{0} to represent `off' and \texttt{1} to - represent `on'. For fields that allow values other than \texttt{0} or - \texttt{1}, it is hoped that the specific context and associated commentary - should make it clear which values are allowed. + \texttt{latexindent.pl} loads its settings from \texttt{defaultSettings.yaml}. The idea + is to separate the behaviour of the script from the internal working -- this is very + similar to the way that we separate content from form when writing our documents in + \LaTeX. + + If you look in \texttt{defaultSettings.yaml} you'll find the switches that govern the + behaviour of \texttt{latexindent.pl}. If you're not sure where + \texttt{defaultSettings.yaml} resides on your computer, don't worry as + \texttt{indent.log} will tell you where to find it. \texttt{defaultSettings.yaml} is + commented, but here is a description of what each switch is designed to do. The default + value is given in each case; whenever you see \emph{integer} in \emph{this} section, + assume that it must be greater than or equal to \texttt{0} unless otherwise stated. + + For most of the settings in \texttt{defaultSettings.yaml} that are specified as integers, + then we understand \texttt{0} to represent `off' and \texttt{1} to represent `on'. For + fields that allow values other than \texttt{0} or \texttt{1}, it is hoped that the + specific context and associated commentary should make it clear which values are allowed. \yamltitle{fileExtensionPreference}*{fields} \texttt{latexindent.pl} can be called to - act on a file without specifying the file extension. For example we can call + act on a file without specifying the file extension. For example we can call \begin{commandshell} latexindent.pl myfile \end{commandshell} - in which case the script will look for \texttt{myfile} with the extensions - specified in \texttt{fileExtensionPreference} in their numeric order. If no match is found, the - script will exit. As with all of the fields, you should change and/or add to this as - necessary. + in which case the script will look for \texttt{myfile} with the extensions specified in + \texttt{fileExtensionPreference} in their numeric order. If no match is found, the script + will exit. As with all of the fields, you should change and/or add to this as necessary. \cmhlistingsfromfile[style=fileExtensionPreference]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{fileExtensionPreference}}{lst:fileExtensionPreference} Calling \texttt{latexindent.pl myfile} with the (default) settings specified in \cref{lst:fileExtensionPreference} means that the script will first look for - \texttt{myfile.tex}, then \texttt{myfile.sty}, \texttt{myfile.cls}, and - finally \texttt{myfile.bib} in order\footnote{Throughout this manual, listings shown with line numbers represent code - taken directly from \texttt{defaultSettings.yaml}.}. + \texttt{myfile.tex}, then \texttt{myfile.sty}, \texttt{myfile.cls}, and finally + \texttt{myfile.bib} in order\footnote{Throughout this manual, listings shown with line + numbers represent code taken directly from \texttt{defaultSettings.yaml}.}. \index{backup files!extension settings} @@ -43,40 +42,38 @@ latexindent.pl myfile \yamltitle{backupExtension}*{extension name} If you call \texttt{latexindent.pl} with the \texttt{-w} switch (to overwrite - \texttt{myfile.tex}) then it will create a backup file before doing any indentation; - the default extension is \texttt{.bak}, so, for example, - \texttt{myfile.bak0} would be created when calling \texttt{latexindent.pl myfile.tex} for the - first time. + \texttt{myfile.tex}) then it will create a backup file before doing any indentation; the + default extension is \texttt{.bak}, so, for example, \texttt{myfile.bak0} would be + created when calling \texttt{latexindent.pl myfile.tex} for the first time. - By default, every time you subsequently call \texttt{latexindent.pl} with the - \texttt{-w} to act upon \texttt{myfile.tex}, it will create successive - back up files: \texttt{myfile.bak1}, \texttt{myfile.bak2}, etc. + By default, every time you subsequently call \texttt{latexindent.pl} with the \texttt{-w} + to act upon \texttt{myfile.tex}, it will create successive back up files: + \texttt{myfile.bak1}, \texttt{myfile.bak2}, etc. \yamltitle{onlyOneBackUp}*{integer} \label{page:onlyonebackup} \index{backup files!number of backup files} - If you don't want a backup for every time that you call \texttt{latexindent.pl} (so - you don't want \texttt{myfile.bak1}, \texttt{myfile.bak2}, etc) and you - simply want \texttt{myfile.bak} (or whatever you chose \texttt{backupExtension} to be) then change \texttt{onlyOneBackUp} to - \texttt{1}; the default value of \texttt{onlyOneBackUp} is + If you don't want a backup for every time that you call \texttt{latexindent.pl} (so you + don't want \texttt{myfile.bak1}, \texttt{myfile.bak2}, etc) and you simply want + \texttt{myfile.bak} (or whatever you chose \texttt{backupExtension} to be) then change + \texttt{onlyOneBackUp} to \texttt{1}; the default value of \texttt{onlyOneBackUp} is \texttt{0}. \index{backup files!maximum number of backup files} \index{backup files!number of backup files} \yamltitle{maxNumberOfBackUps}*{integer} - Some users may only want a finite number of backup files, say at most - $3$, in which case, they can change this switch. The smallest value of - \texttt{maxNumberOfBackUps} is $0$ which will \emph{not} - prevent backup files being made; in this case, the behaviour will be dictated entirely by - \texttt{onlyOneBackUp}. The default value of \texttt{maxNumberOfBackUps} is - \texttt{0}. + Some users may only want a finite number of backup files, say at most $3$, in which case, + they can change this switch. The smallest value of \texttt{maxNumberOfBackUps} is $0$ + which will \emph{not} prevent backup files being made; in this case, the behaviour will + be dictated entirely by \texttt{onlyOneBackUp}. The default value of + \texttt{maxNumberOfBackUps} is \texttt{0}. \yamltitle{cycleThroughBackUps}*{integer} \index{backup files!cycle through} Some users may wish to cycle through backup files, by deleting the oldest backup file and keeping only the most recent; for example, with \texttt{maxNumberOfBackUps: 4}, and - \texttt{cycleThroughBackUps} set to \texttt{1} then the \texttt{copy} - procedure given below would be obeyed. + \texttt{cycleThroughBackUps} set to \texttt{1} then the \texttt{copy} procedure given + below would be obeyed. \begin{commandshell} copy myfile.bak1 to myfile.bak0 @@ -89,37 +86,38 @@ copy myfile.bak4 to myfile.bak3 \yamltitle{logFilePreferences}*{fields} \texttt{latexindent.pl} writes information to \texttt{indent.log}, some of which can be customized by changing \texttt{logFilePreferences}; see - \cref{lst:logFilePreferences}. If you load your own user settings (see \vref{sec:indentconfig}) - then \texttt{latexindent.pl} will detail them in \texttt{indent.log}; you can choose - not to have the details logged by switching \texttt{showEveryYamlRead} to - \texttt{0}. Once all of your settings have been loaded, you can see the - amalgamated settings in the log file by switching \texttt{showAmalgamatedSettings} to - \texttt{1}, if you wish. + \cref{lst:logFilePreferences}. If you load your own user settings (see + \vref{sec:indentconfig}) then \texttt{latexindent.pl} will detail them in + \texttt{indent.log}; you can choose not to have the details logged by switching + \texttt{showEveryYamlRead} to \texttt{0}. Once all of your settings have been loaded, you + can see the amalgamated settings in the log file by switching + \texttt{showAmalgamatedSettings} to \texttt{1}, if you wish. - \cmhlistingsfromfile*[style=logFilePreferences,]*{../defaultSettings.yaml}[width=.9\linewidth,before=\centering,yaml-TCB]{\texttt{logFilePreferences}}{lst:logFilePreferences} + \cmhlistingsfromfile[style=logFilePreferences,]*{../defaultSettings.yaml}[width=.9\linewidth,before=\centering,yaml-TCB]{\texttt{logFilePreferences}}{lst:logFilePreferences} When% - \announce{2018-01-13}{showDecorationStartCodeBlockTrace feature for log file} either of the - \texttt{trace} modes (see \cpageref{page:traceswitch}) are active, you will receive - detailed information in \texttt{indent.log}. You can specify character strings to - appear before and after the notification of a found code block using, respectively, - \texttt{showDecorationStartCodeBlockTrace} and \texttt{showDecorationFinishCodeBlockTrace}. A demonstration is given in + \announce{2018-01-13}{showDecorationStartCodeBlockTrace feature for log file} either of + the \texttt{trace} modes (see \cpageref{page:traceswitch}) are active, you will receive + detailed information in \texttt{indent.log}. You can specify character strings to appear + before and after the notification of a found code block using, respectively, + \texttt{showDecorationStartCodeBlockTrace} and + \texttt{showDecorationFinishCodeBlockTrace}. A demonstration is given in \vref{app:logfile-demo}. The log file will end with the characters given in \texttt{endLogFileWith}, and will report the \texttt{GitHub} address of \texttt{latexindent.pl} to the log file if \texttt{showGitHubInfoFooter} is set to \texttt{1}. - Note: \texttt{latexindent.pl} no longer uses the \texttt{log4perl} module to handle - the creation of the logfile.% + Note: \texttt{latexindent.pl} no longer uses the \texttt{log4perl} module to handle the + creation of the logfile.% \announce{2021-03-14}*{no longer using log4perl} Some of the options% - \announce*{2021-06-19}*{logFilePreferences updated to include Dumper options}for Perl's + \announce{2021-06-19}*{logFilePreferences updated to include Dumper options}for Perl's \texttt{Dumper} module can be specified in \cref{lst:logFilePreferences}; see - \cite{dumper} and \cite{dumperdemo} for more information. These options - will mostly be helpful for those calling \texttt{latexindent.pl} with the - \texttt{-tt} option described in \cref{sec:commandline}. + \cite{dumper} and \cite{dumperdemo} for more information. These options will mostly be + helpful for those calling \texttt{latexindent.pl} with the \texttt{-tt} option described + in \cref{sec:commandline}. \subsection{Verbatim code blocks} \yamltitle{verbatimEnvironments}*{fields} @@ -135,9 +133,9 @@ copy myfile.bak4 to myfile.bak3 \cmhlistingsfromfile[style=verbatimCommands]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{verbatimCommands}}{lst:verbatimCommands} \end{cmhtcbraster} - Note that if you put an environment in \texttt{verbatimEnvironments} and in other fields such - as \texttt{lookForAlignDelims} or \texttt{noAdditionalIndent} then \texttt{latexindent.pl} will - \emph{always} prioritize \texttt{verbatimEnvironments}. + Note that if you put an environment in \texttt{verbatimEnvironments} and in other fields + such as \texttt{lookForAlignDelims} or \texttt{noAdditionalIndent} then + \texttt{latexindent.pl} will \emph{always} prioritize \texttt{verbatimEnvironments}. \yamltitle{verbatimCommands}*{fields} A field that contains a list of commands that are verbatim commands, for example @@ -145,35 +143,35 @@ copy myfile.bak4 to myfile.bak3 breaking routines (only relevant if the \texttt{-m} is active, see \vref{sec:modifylinebreaks}). - With reference to \cref{lst:verbatimCommands}, by default \texttt{latexindent.pl} looks for + With reference to \cref{lst:verbatimCommands}, by default \texttt{latexindent.pl} looks + for \lstinline|\verb| immediately followed by another character, and then it takes the body as anything up to the next occurrence of the character; this means that, for example, \lstinline|\verb!x+3!| is treated as a \texttt{verbatimCommands}. \yamltitle{noIndentBlock}*{fields} If you have a block of code that you don't want \texttt{latexindent.pl} to touch (even if - \index{verbatim!noIndentBlock} it is \emph{not} a verbatim-like environment) then - you can wrap it in an environment from \texttt{noIndentBlock}; you can use any name you - like for this, provided you populate it as demonstrate in \cref{lst:noIndentBlock}. + \index{verbatim!noIndentBlock} it is \emph{not} a verbatim-like environment) then you can + wrap it in an environment from \texttt{noIndentBlock}; you can use any name you like for + this, provided you populate it as demonstrate in \cref{lst:noIndentBlock}. \cmhlistingsfromfile[style=noIndentBlock]*{../defaultSettings.yaml}[width=.4\linewidth,before=\centering,yaml-TCB]{\texttt{noIndentBlock}}{lst:noIndentBlock} Of course, you don't want to have to specify these as null environments in your code, so - you use them with a comment symbol, \lstinline!%!, followed by as many spaces - (possibly none) as you like; see \cref{lst:noIndentBlockdemo} for example. + you use them with a comment symbol, \lstinline!%!, followed by as many spaces (possibly + none) as you like; see \cref{lst:noIndentBlockdemo} for example. \cmhlistingsfromfile{demonstrations/noindentblock.tex}{\texttt{noIndentBlock.tex}}{lst:noIndentBlockdemo} - Important note: it is assumed that the \texttt{noindent} block statements specified - in this way appear on their own line. + Important note: it is assumed that the \texttt{noindent} block statements specified in + this way appear on their own line. The% - \announce*{2021-06-19}{noIndentBlock specified as regex} \texttt{noIndentBlock} - fields can also be specified in terms of \texttt{begin} and - \texttt{end} fields. We use the code in \cref{lst:noIndentBlock1} to demonstrate - this feature. + \announce{2021-06-19}{noIndentBlock specified as regex} \texttt{noIndentBlock} fields can also be specified in terms of \texttt{begin} and + \texttt{end} fields. We use the code in \cref{lst:noIndentBlock1} to demonstrate this + feature. - \cmhlistingsfromfile*{demonstrations/noindentblock1.tex}{\texttt{noIndentBlock1.tex}}{lst:noIndentBlock1} + \cmhlistingsfromfile{demonstrations/noindentblock1.tex}{\texttt{noIndentBlock1.tex}}{lst:noIndentBlock1} The settings given in \cref{lst:noindent1,lst:noindent2} are equivalent: @@ -181,9 +179,9 @@ copy myfile.bak4 to myfile.bak3 raster left skip=-3.5cm, raster right skip=-2cm, raster column skip=.03\linewidth] - \cmhlistingsfromfile*{demonstrations/noindent1.yaml}[yaml-TCB]{\texttt{noindent1.yaml}}{lst:noindent1} - \cmhlistingsfromfile*{demonstrations/noindent2.yaml}[yaml-TCB]{\texttt{noindent2.yaml}}{lst:noindent2} - \cmhlistingsfromfile*{demonstrations/noindent3.yaml}[yaml-TCB]{\texttt{noindent3.yaml}}{lst:noindent3} + \cmhlistingsfromfile{demonstrations/noindent1.yaml}[yaml-TCB]{\texttt{noindent1.yaml}}{lst:noindent1} + \cmhlistingsfromfile{demonstrations/noindent2.yaml}[yaml-TCB]{\texttt{noindent2.yaml}}{lst:noindent2} + \cmhlistingsfromfile{demonstrations/noindent3.yaml}[yaml-TCB]{\texttt{noindent3.yaml}}{lst:noindent3} \end{cmhtcbraster} Upon running the commands @@ -193,26 +191,26 @@ latexindent.pl -l noindent2.yaml noindent1 \end{commandshell} then we receive the output given in \cref{lst:noIndentBlock1-mod1}. - \cmhlistingsfromfile*{demonstrations/noindentblock1-mod1.tex}{\texttt{noIndentBlock1.tex} using \cref{lst:noindent1} or \cref{lst:noindent2}}{lst:noIndentBlock1-mod1} + \cmhlistingsfromfile{demonstrations/noindentblock1-mod1.tex}{\texttt{noIndentBlock1.tex} using \cref{lst:noindent1} or \cref{lst:noindent2}}{lst:noIndentBlock1-mod1} - The \texttt{begin}, \texttt{body} and \texttt{end} fields - for \texttt{noIndentBlock} are all \emph{regular expressions}. If the - \texttt{body} field is not specified, then it takes a default value of + The \texttt{begin}, \texttt{body} and \texttt{end} fields for \texttt{noIndentBlock} are + all \emph{regular expressions}. If the \texttt{body} field is not specified, then it + takes a default value of \lstinline!.*?! which is written explicitly in \cref{lst:noindent1}. In this - context, - we interpret \lstinline!.*?! in words as \emph{the fewest number of characters (possibly none) until the `end' field is reached}. + context, we interpret \lstinline!.*?! in words as \emph{the fewest number of characters + (possibly none) until the `end' field is reached}. - The \texttt{lookForThis} field is optional, and can take the values 0 (off) or 1 (on); - by default, it is assumed to be 1 (on). + The \texttt{lookForThis} field is optional, and can take the values 0 (off) or 1 (on); by + default, it is assumed to be 1 (on). - Using \cref{lst:noindent3} demonstrates setting \texttt{lookForThis} to 0 (off); - running the command + Using \cref{lst:noindent3} demonstrates setting \texttt{lookForThis} to 0 (off); running + the command \begin{commandshell} latexindent.pl -l noindent3.yaml noindent1 \end{commandshell} gives the output in \cref{lst:noIndentBlock1-mod3}. - \cmhlistingsfromfile*{demonstrations/noindentblock1-mod3.tex}{\texttt{noIndentBlock1.tex} using \cref{lst:noindent3}}{lst:noIndentBlock1-mod3} + \cmhlistingsfromfile{demonstrations/noindentblock1-mod3.tex}{\texttt{noIndentBlock1.tex} using \cref{lst:noindent3}}{lst:noIndentBlock1-mod3} We will demonstrate this feature later in the documentation in \cref{lst:href3}. @@ -221,9 +219,9 @@ latexindent.pl -l noindent3.yaml noindent1 Before \texttt{latexindent.pl} determines the difference between preamble (if any) and the main document, it first searches for any of the environments specified in - \texttt{fileContentsEnvironments}, see \cref{lst:fileContentsEnvironments}. The behaviour of - \texttt{latexindent.pl} on these environments is determined by their location (preamble - or not), and the value \texttt{indentPreamble}, discussed next. + \texttt{fileContentsEnvironments}, see \cref{lst:fileContentsEnvironments}. The behaviour + of \texttt{latexindent.pl} on these environments is determined by their location + (preamble or not), and the value \texttt{indentPreamble}, discussed next. \cmhlistingsfromfile[style=fileContentsEnvironments]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{fileContentsEnvironments}}{lst:fileContentsEnvironments} @@ -231,26 +229,25 @@ latexindent.pl -l noindent3.yaml noindent1 The preamble of a document can sometimes contain some trickier code for \texttt{latexindent.pl} to operate upon. By default, \texttt{latexindent.pl} won't try to - operate on the preamble (as \texttt{indentPreamble} is set to \texttt{0}, by - default), but if you'd like \texttt{latexindent.pl} to try then change - \texttt{indentPreamble} to \texttt{1}. + operate on the preamble (as \texttt{indentPreamble} is set to \texttt{0}, by default), + but if you'd like \texttt{latexindent.pl} to try then change \texttt{indentPreamble} to + \texttt{1}. \yamltitle{lookForPreamble}*{fields} - Not all files contain preamble; for example, \texttt{sty}, - \texttt{cls} and \texttt{bib} files typically do - \emph{not}. Referencing \cref{lst:lookForPreamble}, if you set, for example, - \texttt{.tex} to \texttt{0}, then regardless of the setting of the - value of \texttt{indentPreamble}, preamble will not be assumed when operating upon - \texttt{.tex} files. + Not all files contain preamble; for example, \texttt{sty}, \texttt{cls} and \texttt{bib} + files typically do \emph{not}. Referencing \cref{lst:lookForPreamble}, if you set, for + example, \texttt{.tex} to \texttt{0}, then regardless of the setting of the value of + \texttt{indentPreamble}, preamble will not be assumed when operating upon \texttt{.tex} + files. \cmhlistingsfromfile[style=lookForPreamble]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{lookForPreamble}{lst:lookForPreamble} \yamltitle{preambleCommandsBeforeEnvironments}{0|1} Assuming that \texttt{latexindent.pl} is asked to operate upon the preamble of a - document, when this switch is set to \texttt{0} then environment code blocks - will be sought first, and then command code blocks. When this switch is set to - \texttt{1}, commands will be sought first. The example that first motivated - this switch contained the code given in \cref{lst:motivatepreambleCommandsBeforeEnvironments}. + document, when this switch is set to \texttt{0} then environment code blocks will be + sought first, and then command code blocks. When this switch is set to \texttt{1}, + commands will be sought first. The example that first motivated this switch contained the + code given in \cref{lst:motivatepreambleCommandsBeforeEnvironments}. \begin{cmhlistings}{Motivating \texttt{preambleCommandsBeforeEnvironments}}{lst:motivatepreambleCommandsBeforeEnvironments} ... @@ -264,19 +261,19 @@ postfoothook=\end{mdframed}, \subsection{Indentation and horizontal space} \yamltitle{defaultIndent}*{horizontal space} This is the default indentation used in the absence of other details for the code block - with which we are working. The default value is \lstinline!\t! which means a tab; - we will explore customisation beyond \texttt{defaultIndent} in \vref{sec:noadd-indent-rules}. + with which we are working. The default value is \lstinline!\t! which means a tab; we will + explore customisation beyond \texttt{defaultIndent} in \vref{sec:noadd-indent-rules}. If you're interested in experimenting with \texttt{latexindent.pl} then you can \emph{remove} all indentation by setting \texttt{defaultIndent: ""}. \yamltitle{removeTrailingWhitespace}*{fields}\label{yaml:removeTrailingWhitespace} - Trailing white space can be removed both \emph{before} and - \emph{after} processing the document, as detailed in \cref{lst:removeTrailingWhitespace}; - each of the fields can take the values \texttt{0} or - \texttt{1}. See \vref{lst:removeTWS-before,lst:env-mlb5-modAll,lst:env-mlb5-modAll-remove-WS} for before and after results. Thanks - to \cite{vosskuhle} for providing this feature. + Trailing white space can be removed both \emph{before} and \emph{after} processing the + document, as detailed in \cref{lst:removeTrailingWhitespace}; each of the fields can take + the values \texttt{0} or \texttt{1}. See + \vref{lst:removeTWS-before,lst:env-mlb5-modAll,lst:env-mlb5-modAll-remove-WS} for before + and after results. Thanks to \cite{vosskuhle} for providing this feature. \begin{minipage}{.4\textwidth} \cmhlistingsfromfile[style=removeTrailingWhitespace]*{../defaultSettings.yaml}[before=\centering,yaml-TCB]{removeTrailingWhitespace}{lst:removeTrailingWhitespace} @@ -288,17 +285,18 @@ removeTrailingWhitespace: 1 \end{yaml} \end{minipage}% - You can specify \texttt{removeTrailingWhitespace} simply as \texttt{0} or - \texttt{1}, if you wish; in this case,% - \announce{2017-06-28}{removeTrailingWhitespace} \texttt{latexindent.pl} will set both \texttt{beforeProcessing} and - \texttt{afterProcessing} to the value you specify; see \cref{lst:removeTrailingWhitespace-alt}. + You can specify \texttt{removeTrailingWhitespace} simply as \texttt{0} or \texttt{1}, if + you wish; in this case,% + \announce{2017-06-28}{removeTrailingWhitespace} \texttt{latexindent.pl} will set both + \texttt{beforeProcessing} and \texttt{afterProcessing} to the value you specify; see + \cref{lst:removeTrailingWhitespace-alt}. \subsection{Aligning at delimiters} \yamltitle{lookForAlignDelims}*{fields} This contains a list of code blocks that are operated upon in a special way by - \texttt{latexindent.pl} (see \cref{lst:aligndelims:basic}). In fact, the fields in \texttt{lookForAlignDelims} can actually take - two different forms: the \emph{basic} version is shown in - \cref{lst:aligndelims:basic} and the \emph{advanced} version in + \texttt{latexindent.pl} (see \cref{lst:aligndelims:basic}). In fact, the fields in + \texttt{lookForAlignDelims} can actually take two different forms: the \emph{basic} + version is shown in \cref{lst:aligndelims:basic} and the \emph{advanced} version in \cref{lst:aligndelims:advanced}; we will discuss each in turn. \index{delimiters!advanced settings of lookForAlignDelims} @@ -314,14 +312,14 @@ lookForAlignDelims: Specifying code blocks in this field instructs \texttt{latexindent.pl} to try and align each column by its alignment delimiters. It does have some limitations (discussed further - in \cref{sec:knownlimitations}), but in many cases it will produce results such as those in - \cref{lst:tabularbefore:basic,lst:tabularafter:basic}. + in \cref{sec:knownlimitations}), but in many cases it will produce results such as those + in \cref{lst:tabularbefore:basic,lst:tabularafter:basic}. If you find that \texttt{latexindent.pl} does not perform satisfactorily on such environments then you can set the relevant key to \texttt{0}, for example - \texttt{tabular: 0}; alternatively, if you just want to ignore - \emph{specific} instances of the environment, you could wrap them in something - from \texttt{noIndentBlock} (see \vref{lst:noIndentBlock}). + \texttt{tabular: 0}; alternatively, if you just want to ignore \emph{specific} instances + of the environment, you could wrap them in something from \texttt{noIndentBlock} (see + \vref{lst:noIndentBlock}). \begin{cmhtcbraster} \cmhlistingsfromfile{demonstrations/tabular1.tex}{\texttt{tabular1.tex}}{lst:tabularbefore:basic} @@ -341,53 +339,54 @@ lookForAlignDelims: \cmhlistingsfromfile[style=lookForAlignDelims]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{lookForAlignDelims} (advanced)}{lst:aligndelims:advanced} Note that you can use a mixture of the basic and advanced form: in - \cref{lst:aligndelims:advanced} \texttt{tabular} and \texttt{tabularx} are advanced - and \texttt{longtable} is basic. When using the advanced form, each field should - receive at least 1 sub-field, and \emph{can} - (but does not have to) receive any of the following + \cref{lst:aligndelims:advanced} \texttt{tabular} and \texttt{tabularx} are advanced and + \texttt{longtable} is basic. When using the advanced form, each field should receive at + least 1 sub-field, and \emph{can} (but does not have to) receive any of the following fields: \begin{itemize} \item \texttt{delims}: binary switch (0 or 1) equivalent to simply specifying, for - example, \texttt{tabular: 1} in the basic version shown in \cref{lst:aligndelims:basic}. If - \texttt{delims} is set to \texttt{0} then the align at ampersand - routine will not be called for this code block (default: 1); - \item \texttt{alignDoubleBackSlash}: binary switch (0 or 1) to determine if \lstinline!\\! + example, \texttt{tabular: 1} in the basic version shown in \cref{lst:aligndelims:basic}. + If \texttt{delims} is set to \texttt{0} then the align at ampersand routine will not be + called for this code block (default: 1); + \item \texttt{alignDoubleBackSlash}: binary switch (0 or 1) to determine if + \lstinline!\\! should be aligned (default: 1); \item \texttt{spacesBeforeDoubleBackSlash}: optionally,% - \announce{2018-01-13}*{update to spacesBeforeDoubleBackSlash in ampersand alignment} specifies the number (integer $\geq$ 0) of spaces - to be inserted before \lstinline!\\! (default: 1); - %\footnote{Previously this only activated if \texttt{alignDoubleBackSlash} was set to \texttt{0}.} - \item \announce{2017-06-19}{multiColumnGrouping} \texttt{multiColumnGrouping}: binary switch (0 or 1) that details if - \texttt{latexindent.pl} should group columns - above and below a \lstinline!\multicolumn! command (default: 0); - \item \announce{2017-06-19}{alignRowsWithoutMaxDelims} \texttt{alignRowsWithoutMaxDelims}: binary switch (0 or 1) that details if - rows that do not contain the maximum number of delimeters should be formatted so as to - have the ampersands aligned (default: 1); - \item \announce{2018-01-13}{spacesBeforeAmpersand in ampersand alignment}\texttt{spacesBeforeAmpersand}: optionally specifies the number (integer - $\geq$ 0) of - spaces to be placed \emph{before} ampersands (default: 1); - \item \announce{2018-01-13}{spacesAfterAmpersand in ampersand alignment}\texttt{spacesAfterAmpersand}: optionally specifies the number (integer - $\geq$ 0) of - spaces to be placed \emph{After} ampersands (default: 1); - \item \announce{2018-01-13}{justification of cells in ampersand alignment}\texttt{justification}: optionally specifies the justification of - each cell as either \emph{left} or \emph{right} (default: left); - \item \announce{2020-03-21}{align final double back slash}{alignFinalDoubleBackSlash} optionally specifies if the - \emph{final} double back slash should be used for alignment (default: 0); + \announce{2018-01-13}*{update to spacesBeforeDoubleBackSlash in ampersand alignment} + specifies the number (integer $\geq$ 0) of spaces to be inserted before + \lstinline!\\! (default: 1); %\footnote{Previously this only activated if \texttt{alignDoubleBackSlash} was set to \texttt{0}.} + \item \announce{2017-06-19}{multiColumnGrouping} \texttt{multiColumnGrouping}: binary switch (0 + or 1) that details if \texttt{latexindent.pl} should group columns above and below a + \lstinline!\multicolumn! command (default: 0); + \item \announce{2017-06-19}{alignRowsWithoutMaxDelims} \texttt{alignRowsWithoutMaxDelims}: + binary switch (0 or 1) that details if rows that do not contain the maximum number of + delimeters should be formatted so as to have the ampersands aligned (default: 1); + \item \announce{2018-01-13}{spacesBeforeAmpersand in ampersand alignment}\texttt{spacesBeforeAmpersand}: optionally specifies the number (integer $\geq$ + 0) of spaces to be placed \emph{before} ampersands (default: 1); + \item \announce{2018-01-13}{spacesAfterAmpersand in ampersand alignment}\texttt{spacesAfterAmpersand}: optionally specifies the number (integer $\geq$ + 0) of spaces to be placed \emph{After} ampersands (default: 1); + \item \announce{2018-01-13}{justification of cells in ampersand alignment}\texttt{justification}: optionally specifies the justification of each cell as + either \emph{left} or \emph{right} (default: left); + \item \announce{2020-03-21}{align final double back slash}{alignFinalDoubleBackSlash} + optionally specifies if the \emph{final} double back slash should be used for alignment + (default: 0); \item \announce{2020-03-21}{don't measure feature}{dontMeasure} optionally specifies if - user-specified cells, rows or the largest entries should \emph{not} be - measured (default: 0); - \item \announce{2020-03-21}{delimiter RegEx feature}{delimiterRegEx} optionally specifies the pattern - matching to be used for the alignment delimeter (default: \lstinline3 '(?<!\\)(&)'3); - \item \announce{2020-03-21}{delimiter justification}{delimiterJustification} optionally specifies the justification - for the alignment delimeters (default: left); note that this feature is only useful if - you have delimiters of different lengths in the same column, discussed in - \cref{sec:delimiter-reg-ex}. + user-specified cells, rows or the largest entries should \emph{not} be measured (default: + 0); + \item \announce{2020-03-21}{delimiter RegEx feature}{delimiterRegEx} optionally specifies the + pattern matching to be used for the alignment delimeter (default: + \lstinline3 '(?<!\\)(&)'3); + \item \announce{2020-03-21}{delimiter justification}{delimiterJustification} optionally + specifies the justification for the alignment delimeters (default: left); note that this + feature is only useful if you have delimiters of different lengths in the same column, + discussed in \cref{sec:delimiter-reg-ex}. \end{itemize} We will explore most of these features using the file \texttt{tabular2.tex} in - \cref{lst:tabular2} (which contains a \lstinline!\multicolumn! command), and the YAML files in \crefrange{lst:tabular2YAML}{lst:tabular8YAML}; we will explore - \texttt{alignFinalDoubleBackSlash} in \cref{lst:tabular4}; the \texttt{dontMeasure} feature - will be described in \cref{sec:dontMeasure}, and \texttt{delimiterRegEx} in + \cref{lst:tabular2} (which contains a \lstinline!\multicolumn! command), and the YAML + files in \crefrange{lst:tabular2YAML}{lst:tabular8YAML}; we will explore + \texttt{alignFinalDoubleBackSlash} in \cref{lst:tabular4}; the \texttt{dontMeasure} + feature will be described in \cref{sec:dontMeasure}, and \texttt{delimiterRegEx} in \cref{sec:delimiter-reg-ex}. \cmhlistingsfromfile{demonstrations/tabular2.tex}{\texttt{tabular2.tex}}{lst:tabular2} @@ -432,7 +431,8 @@ latexindent.pl tabular2.tex -l tabular2.yaml,tabular6.yaml latexindent.pl tabular2.tex -l tabular2.yaml,tabular7.yaml latexindent.pl tabular2.tex -l tabular2.yaml,tabular8.yaml \end{commandshell} - we obtain the respective outputs given in \crefrange{lst:tabular2-default}{lst:tabular2-mod8}. + we obtain the respective outputs given in + \crefrange{lst:tabular2-default}{lst:tabular2-mod8}. \begin{widepage} \cmhlistingsfromfile{demonstrations/tabular2-default.tex}{\texttt{tabular2.tex} default output}{lst:tabular2-default} @@ -447,44 +447,43 @@ latexindent.pl tabular2.tex -l tabular2.yaml,tabular8.yaml Notice in particular: \begin{itemize} - \item in both \cref{lst:tabular2-default,lst:tabular2-mod2} all rows have been aligned at the ampersand, even those - that do not contain the maximum number of ampersands (3 ampersands, in this case); + \item in both \cref{lst:tabular2-default,lst:tabular2-mod2} all rows have been aligned at the + ampersand, even those that do not contain the maximum number of ampersands (3 ampersands, + in this case); \item in \cref{lst:tabular2-default} the columns have been aligned at the ampersand; - \item in \cref{lst:tabular2-mod2} the \lstinline!\multicolumn! command has grouped the - $2$ columns beneath \emph{and} above it, because - \texttt{multiColumnGrouping} is set to $1$ in \cref{lst:tabular2YAML}; - \item in \cref{lst:tabular2-mod3} rows~3 and~6 have \emph{not} been aligned at the - ampersand, because \texttt{alignRowsWithoutMaxDelims} has been to set to $0$ in - \cref{lst:tabular3YAML}; however, the \lstinline!\\! \emph{have} still - been aligned; + \item in \cref{lst:tabular2-mod2} the \lstinline!\multicolumn! command has grouped the $2$ + columns beneath \emph{and} above it, because \texttt{multiColumnGrouping} is set to $1$ + in \cref{lst:tabular2YAML}; + \item in \cref{lst:tabular2-mod3} rows~3 and~6 have \emph{not} been aligned at the ampersand, + because \texttt{alignRowsWithoutMaxDelims} has been to set to $0$ in + \cref{lst:tabular3YAML}; however, the \lstinline!\\! \emph{have} still been aligned; \item in \cref{lst:tabular2-mod4} the columns beneath and above the \lstinline!\multicolumn! - commands have been grouped (because \texttt{multiColumnGrouping} is set to - $1$), and there are at least $4$ spaces - \emph{before} each aligned ampersand because \texttt{spacesBeforeAmpersand} is set to - $4$; + commands have been grouped (because \texttt{multiColumnGrouping} is set to $1$), and + there are at least $4$ spaces \emph{before} each aligned ampersand because + \texttt{spacesBeforeAmpersand} is set to $4$; \item in \cref{lst:tabular2-mod5} the columns beneath and above the \lstinline!\multicolumn! - commands have been grouped (because \texttt{multiColumnGrouping} is set to - $1$), and there are at least $4$ spaces - \emph{after} each aligned ampersand because \texttt{spacesAfterAmpersand} is set to - $4$; - \item in \cref{lst:tabular2-mod6} the \lstinline!\\! have \emph{not} been - aligned, because \texttt{alignDoubleBackSlash} is set to \texttt{0}, otherwise the - output is the same as \cref{lst:tabular2-mod2}; - \item in \cref{lst:tabular2-mod7} the \lstinline!\\! \emph{have} been - aligned, and because \texttt{spacesBeforeDoubleBackSlash} is set to \texttt{0}, there are - no spaces ahead of them; the output is otherwise the same as \cref{lst:tabular2-mod2}; - \item in \cref{lst:tabular2-mod8} the cells have been \emph{right}-justified; note - that cells above and below the \lstinline!\multicol! statements have still been group - correctly, because of the settings in \cref{lst:tabular2YAML}. + commands have been grouped (because \texttt{multiColumnGrouping} is set to $1$), and + there are at least $4$ spaces \emph{after} each aligned ampersand because + \texttt{spacesAfterAmpersand} is set to $4$; + \item in \cref{lst:tabular2-mod6} the \lstinline!\\! have \emph{not} been aligned, because + \texttt{alignDoubleBackSlash} is set to \texttt{0}, otherwise the output is the same as + \cref{lst:tabular2-mod2}; + \item in \cref{lst:tabular2-mod7} the \lstinline!\\! \emph{have} been aligned, and because + \texttt{spacesBeforeDoubleBackSlash} is set to \texttt{0}, there are no spaces ahead of + them; the output is otherwise the same as \cref{lst:tabular2-mod2}; + \item in \cref{lst:tabular2-mod8} the cells have been \emph{right}-justified; note that cells + above and below the \lstinline!\multicol! statements have still been group correctly, + because of the settings in \cref{lst:tabular2YAML}. \end{itemize} \subsubsection{lookForAlignDelims: spacesBeforeAmpersand} The \texttt{spacesBeforeAmpersand}% - \announce*{2021-06-19}*{spacesBeforeAmpersand leading blank column upgrade} can be specified in a few different - ways. The \emph{basic} form is demonstrated in \cref{lst:tabular4YAML}, but we - can customise the behaviour further by specifying if we would like this value to change - if it encounters a \emph{leading blank column}; that is, when the first column contains only - zero-width entries. We refer to this as the \emph{advanced} form. + \announce{2021-06-19}*{spacesBeforeAmpersand leading blank column upgrade} can be + specified in a few different ways. The \emph{basic} form is demonstrated in + \cref{lst:tabular4YAML}, but we can customise the behaviour further by specifying if we + would like this value to change if it encounters a \emph{leading blank column}; that is, + when the first column contains only zero-width entries. We refer to this as the + \emph{advanced} form. We demonstrate this feature in relation to \cref{lst:aligned1}; upon running the following command @@ -494,18 +493,18 @@ latexindent.pl aligned1.tex -o=+-default then we receive the default output given in \cref{lst:aligned1-default}. \begin{cmhtcbraster} - \cmhlistingsfromfile*{demonstrations/aligned1.tex}{\texttt{aligned1.tex}}{lst:aligned1} - \cmhlistingsfromfile*{demonstrations/aligned1-default.tex}{\texttt{aligned1-default.tex}}{lst:aligned1-default} + \cmhlistingsfromfile{demonstrations/aligned1.tex}{\texttt{aligned1.tex}}{lst:aligned1} + \cmhlistingsfromfile{demonstrations/aligned1-default.tex}{\texttt{aligned1-default.tex}}{lst:aligned1-default} \end{cmhtcbraster} - The settings in \crefrange{lst:sba1}{lst:sba4} are all equivlanent; we have used the not-yet - discussed \texttt{noAdditionalIndent} field (see \vref{sec:noadd-indent-rules}) which will assist - in the demonstration in what follows. + The settings in \crefrange{lst:sba1}{lst:sba4} are all equivlanent; we have used the + not-yet discussed \texttt{noAdditionalIndent} field (see \vref{sec:noadd-indent-rules}) + which will assist in the demonstration in what follows. \begin{cmhtcbraster}[raster columns=2, ] - \cmhlistingsfromfile*{demonstrations/sba1.yaml}[yaml-TCB]{\texttt{sba1.yaml}}{lst:sba1} - \cmhlistingsfromfile*{demonstrations/sba2.yaml}[yaml-TCB]{\texttt{sba2.yaml}}{lst:sba2} - \cmhlistingsfromfile*{demonstrations/sba3.yaml}[yaml-TCB]{\texttt{sba3.yaml}}{lst:sba3} - \cmhlistingsfromfile*{demonstrations/sba4.yaml}[yaml-TCB]{\texttt{sba4.yaml}}{lst:sba4} + \cmhlistingsfromfile{demonstrations/sba1.yaml}[yaml-TCB]{\texttt{sba1.yaml}}{lst:sba1} + \cmhlistingsfromfile{demonstrations/sba2.yaml}[yaml-TCB]{\texttt{sba2.yaml}}{lst:sba2} + \cmhlistingsfromfile{demonstrations/sba3.yaml}[yaml-TCB]{\texttt{sba3.yaml}}{lst:sba3} + \cmhlistingsfromfile{demonstrations/sba4.yaml}[yaml-TCB]{\texttt{sba4.yaml}}{lst:sba4} \end{cmhtcbraster} Upon running the following commands \begin{commandshell} @@ -514,11 +513,11 @@ latexindent.pl aligned1.tex -l sba2.yaml latexindent.pl aligned1.tex -l sba3.yaml latexindent.pl aligned1.tex -l sba4.yaml \end{commandshell} - then we receive the (same) output given in \cref{lst:aligned1-mod1}; we note that there is - \emph{one space} before each ampersand. + then we receive the (same) output given in \cref{lst:aligned1-mod1}; we note that there + is \emph{one space} before each ampersand. \begin{cmhtcbraster} - \cmhlistingsfromfile*{demonstrations/aligned1-mod1.tex}{\texttt{aligned1-mod1.tex}}{lst:aligned1-mod1} + \cmhlistingsfromfile{demonstrations/aligned1-mod1.tex}{\texttt{aligned1-mod1.tex}}{lst:aligned1-mod1} \end{cmhtcbraster} We note in particular: @@ -531,23 +530,23 @@ latexindent.pl aligned1.tex -l sba4.yaml and specified \texttt{spacesBeforeAmpersand}. The default value is \texttt{1}; \item \cref{lst:sba3} demonstrates the new \emph{advanced} way to specify \texttt{spacesBeforeAmpersand}, and - for us to set the \texttt{default} value that sets the number of spaces before - ampersands which are \emph{not} in leading blank columns. The - default value is \texttt{1}. + for us to set the \texttt{default} value that sets the number of spaces before ampersands + which are \emph{not} in leading blank columns. The default value is \texttt{1}. - We note that \texttt{leadingBlankColumn} has not been specified in \cref{lst:sba3}, - and it will inherit the value from \texttt{default}; + We note that \texttt{leadingBlankColumn} has not been specified in \cref{lst:sba3}, and + it will inherit the value from \texttt{default}; \item \cref{lst:sba4} demonstrates spaces to be used before amperands for \emph{leading blank columns}. - We note that \emph{default} has not been specified, and it will be set to - \texttt{1} by default. + We note that \emph{default} has not been specified, and it will be set to \texttt{1} by + default. \end{itemize} We can customise the space before the ampersand in the \emph{leading blank column} of - \cref{lst:aligned1-mod1} by using either of \cref{lst:sba5,lst:sba6}, which are equivalent. + \cref{lst:aligned1-mod1} by using either of \cref{lst:sba5,lst:sba6}, which are + equivalent. \begin{cmhtcbraster} - \cmhlistingsfromfile*{demonstrations/sba5.yaml}[yaml-TCB]{\texttt{sba5.yaml}}{lst:sba5} - \cmhlistingsfromfile*{demonstrations/sba6.yaml}[yaml-TCB]{\texttt{sba6.yaml}}{lst:sba6} + \cmhlistingsfromfile{demonstrations/sba5.yaml}[yaml-TCB]{\texttt{sba5.yaml}}{lst:sba5} + \cmhlistingsfromfile{demonstrations/sba6.yaml}[yaml-TCB]{\texttt{sba6.yaml}}{lst:sba6} \end{cmhtcbraster} Upon running @@ -556,18 +555,18 @@ latexindent.pl aligned1.tex -l sba5.yaml latexindent.pl aligned1.tex -l sba6.yaml \end{commandshell} then we receive the (same) output given in \cref{lst:aligned1-mod5}. We note that the - space before the ampersand in the \emph{leading blank column} has been set to - \texttt{0} by \cref{lst:sba6}. + space before the ampersand in the \emph{leading blank column} has been set to \texttt{0} + by \cref{lst:sba6}. - We can demonstrated this feature further using the settings in \cref{lst:sba7} - which give the output in \cref{lst:aligned1-mod7}. + We can demonstrated this feature further using the settings in \cref{lst:sba7} which give + the output in \cref{lst:aligned1-mod7}. \begin{cmhtcbraster}[raster columns=3, raster left skip=-3.75cm, raster right skip=-2cm,] - \cmhlistingsfromfile*{demonstrations/aligned1-mod5.tex}{\texttt{aligned1-mod5.tex}}{lst:aligned1-mod5} - \cmhlistingsfromfile*{demonstrations/aligned1-mod7.tex}{\texttt{aligned1.tex} using \cref{lst:sba7}}{lst:aligned1-mod7} - \cmhlistingsfromfile*{demonstrations/sba7.yaml}[yaml-TCB]{\texttt{sba7.yaml}}{lst:sba7} + \cmhlistingsfromfile{demonstrations/aligned1-mod5.tex}{\texttt{aligned1-mod5.tex}}{lst:aligned1-mod5} + \cmhlistingsfromfile{demonstrations/aligned1-mod7.tex}{\texttt{aligned1.tex} using \cref{lst:sba7}}{lst:aligned1-mod7} + \cmhlistingsfromfile{demonstrations/sba7.yaml}[yaml-TCB]{\texttt{sba7.yaml}}{lst:sba7} \end{cmhtcbraster} \subsubsection{lookForAlignDelims: alignFinalDoubleBackSlash} We explore% @@ -604,13 +603,14 @@ latexindent.pl tabular4.tex -o=+-FDBS -y="lookForAlignDelims:tabular:alignFinalD As of Version 3.0, the alignment routine works on mandatory and optional arguments within commands, and also within `special' code blocks (see \texttt{specialBeginEnd} on \cpageref{yaml:specialBeginEnd}); for example, assuming that you have a command called - \lstinline!\matrix! and that it is populated within \texttt{lookForAlignDelims} (which it is, by default), and that + \lstinline!\matrix! and that it is populated within \texttt{lookForAlignDelims} + (which it is, by default), and that you run the command \begin{commandshell} latexindent.pl matrix1.tex \end{commandshell} - then the before-and-after results shown in \cref{lst:matrixbefore,lst:matrixafter} are achievable by - default. + then the before-and-after results shown in \cref{lst:matrixbefore,lst:matrixafter} are + achievable by default. \begin{cmhtcbraster} \cmhlistingsfromfile{demonstrations/matrix1.tex}{\texttt{matrix1.tex}}{lst:matrixbefore} @@ -620,9 +620,10 @@ latexindent.pl matrix1.tex If you have blocks of code that you wish to align at the \& character that are \emph{not} wrapped in, for example, \lstinline!\begin{tabular}! \ldots \lstinline!\end{tabular}!, then you can use the mark up illustrated in - \cref{lst:alignmentmarkup}; the default output is shown in \cref{lst:alignmentmarkup-default}. Note - that the \lstinline!%*! must be next to each other, but that there can be any - number of spaces (possibly none) between the + \cref{lst:alignmentmarkup}; the default output is shown in + \cref{lst:alignmentmarkup-default}. Note + that the \lstinline!%*! must be next to each other, but that there can be any number of + spaces (possibly none) between the \lstinline!*! and \lstinline!\begin{tabular}!; note also that you may use any environment name that you have specified in \texttt{lookForAlignDelims}. @@ -632,16 +633,16 @@ latexindent.pl matrix1.tex \end{cmhtcbraster} With reference to \vref{tab:code-blocks} and the, yet undiscussed, fields of - \texttt{noAdditionalIndent} and \texttt{indentRules} - (see \vref{sec:noadd-indent-rules}), these comment-marked blocks are - considered \texttt{environments}. + \texttt{noAdditionalIndent} and \texttt{indentRules} (see \vref{sec:noadd-indent-rules}), + these comment-marked blocks are considered \texttt{environments}. \subsubsection{lookForAlignDelims: the dontMeasure feature}\label{sec:dontMeasure} The% - \announce{2020-03-21}{don't measure feature} \texttt{lookForAlignDelims} - field can, optionally, receive the \texttt{dontMeasure} option which can be specified - in a few different ways. We will explore this feature in relation to the code given in - \cref{lst:tabular-DM}; the default output is shown in \cref{lst:tabular-DM-default}. + \announce{2020-03-21}{don't measure feature} + \texttt{lookForAlignDelims} field can, optionally, receive the \texttt{dontMeasure} + option which can be specified in a few different ways. We will explore this feature in + relation to the code given in \cref{lst:tabular-DM}; the default output is shown in + \cref{lst:tabular-DM-default}. \index{delimiters!dontMeasure feature} \begin{cmhtcbraster}[raster left skip=-1.5cm,] @@ -649,9 +650,9 @@ latexindent.pl matrix1.tex \cmhlistingsfromfile{demonstrations/tabular-DM-default.tex}{\texttt{tabular-DM.tex} default output}{lst:tabular-DM-default} \end{cmhtcbraster} - The \texttt{dontMeasure} field can be specified as \texttt{largest}, and in - which case, the largest element will not be measured; with reference to the YAML file - given in \cref{lst:dontMeasure1}, we can run the command + The \texttt{dontMeasure} field can be specified as \texttt{largest}, and in which case, + the largest element will not be measured; with reference to the YAML file given in + \cref{lst:dontMeasure1}, we can run the command \index{switches!-l demonstration} \begin{commandshell} latexindent.pl tabular-DM.tex -l=dontMeasure1.yaml @@ -663,8 +664,8 @@ latexindent.pl tabular-DM.tex -l=dontMeasure1.yaml \cmhlistingsfromfile{demonstrations/dontMeasure1.yaml}[yaml-TCB]{\texttt{dontMeasure1.yaml}}{lst:dontMeasure1} \end{cmhtcbraster} - We note that the \emph{largest} column entries have not contributed to the - measuring routine. + We note that the \emph{largest} column entries have not contributed to the measuring + routine. The \texttt{dontMeasure} field can also be specified in the form demonstrated in \cref{lst:dontMeasure2}. On running the following commands, @@ -704,19 +705,18 @@ latexindent.pl tabular-DM.tex -l=dontMeasure4.yaml \begin{itemize} \item \cref{lst:dontMeasure3} we have specified entries not to be measured, each one has a \emph{string} in the \texttt{this} - field, together with an optional specification of \texttt{applyTo} as - \texttt{cell}; + field, together with an optional specification of \texttt{applyTo} as \texttt{cell}; \item \cref{lst:dontMeasure4} we have specified entries not to be measured as a \emph{regular expression} using - the \texttt{regex} field, together with an optional specification of - \texttt{applyTo} as \texttt{cell} field, together with an optional - specification of \texttt{applyTo} as \texttt{cell}. + the \texttt{regex} field, together with an optional specification of \texttt{applyTo} as + \texttt{cell} field, together with an optional specification of \texttt{applyTo} as + \texttt{cell}. \end{itemize} - In both cases, the default value of \texttt{applyTo} is \texttt{cell}, - and does not need to be specified. + In both cases, the default value of \texttt{applyTo} is \texttt{cell}, and does not need + to be specified. - We may also specify the \texttt{applyTo} field as \texttt{row}, a - demonstration of which is given in \cref{lst:dontMeasure5}; upon running + We may also specify the \texttt{applyTo} field as \texttt{row}, a demonstration of which + is given in \cref{lst:dontMeasure5}; upon running \index{switches!-l demonstration} \begin{commandshell} latexindent.pl tabular-DM.tex -l=dontMeasure5.yaml @@ -727,9 +727,9 @@ latexindent.pl tabular-DM.tex -l=dontMeasure5.yaml \cmhlistingsfromfile{demonstrations/dontMeasure5.yaml}[yaml-TCB]{\texttt{dontMeasure5.yaml}}{lst:dontMeasure5} \end{cmhtcbraster} - Finally, the \texttt{applyTo} field can be specified as \texttt{row}, - together with a \texttt{regex} expression. For example, for the settings given - in \cref{lst:dontMeasure6}, upon running + Finally, the \texttt{applyTo} field can be specified as \texttt{row}, together with a + \texttt{regex} expression. For example, for the settings given in + \cref{lst:dontMeasure6}, upon running \index{switches!-l demonstration} \begin{commandshell} latexindent.pl tabular-DM.tex -l=dontMeasure6.yaml @@ -744,11 +744,13 @@ latexindent.pl tabular-DM.tex -l=dontMeasure6.yaml \end{cmhtcbraster} \subsubsection{lookForAlignDelims: the delimiterRegEx and delimiterJustification feature}\label{sec:delimiter-reg-ex} + The delimiter alignment% - \announce{2020-03-21}{delimiterRegEx feature} will, by - default, align code blocks at the ampersand character. The behaviour is controlled by the - \texttt{delimiterRegEx} field within \texttt{lookForAlignDelims}; the default value is - \lstinline3'(?<!\\)(&)'3, which can be read as: \emph{an ampersand, as long as it is not immediately preceeded by a backslash}. + \announce{2020-03-21}{delimiterRegEx feature} will, by default, align code blocks at the + ampersand character. The behaviour is controlled by the \texttt{delimiterRegEx} field + within \texttt{lookForAlignDelims}; the default value is + \lstinline3'(?<!\\)(&)'3, which can be read as: \emph{an ampersand, as long as it is not + immediately preceeded by a backslash}. \index{warning!capturing parenthesis for lookForAlignDelims} \index{capturing parenthesis (regex)} \index{regular expressions!capturing parenthesis} @@ -770,8 +772,8 @@ latexindent.pl tabular-DM.tex -l=dontMeasure6.yaml \end{cmhtcbraster} Let's say that we wish to align the code at either the \lstinline!\=! or - \lstinline!\>!. We employ the settings given in \cref{lst:delimiterRegEx1} and run - the command + \lstinline!\>!. We employ the settings given in \cref{lst:delimiterRegEx1} and + run the command \index{switches!-l demonstration} \begin{commandshell} latexindent.pl tabbing.tex -l=delimiterRegEx1.yaml @@ -787,9 +789,9 @@ latexindent.pl tabbing.tex -l=delimiterRegEx1.yaml \begin{itemize} \item in \cref{lst:tabbing-mod1} the code has been aligned, as intended, at both the \lstinline!\=! and \lstinline!\>!; - \item in \cref{lst:delimiterRegEx1} we have heeded the warning and captured the expression using - grouping parenthesis, specified a backslash using \lstinline!\\! and said that - it must be followed by either \lstinline!=! or \lstinline!>!. + \item in \cref{lst:delimiterRegEx1} we have heeded the warning and captured the expression + using grouping parenthesis, specified a backslash using \lstinline!\\! and said that it + must be followed by either \lstinline!=! or \lstinline!>!. \end{itemize} We can explore \texttt{delimiterRegEx} a little further using the settings in \cref{lst:delimiterRegEx2} and run the command @@ -808,8 +810,8 @@ latexindent.pl tabbing.tex -l=delimiterRegEx2.yaml Of course, the other lookForAlignDelims options can be used alongside the \texttt{delimiterRegEx}; regardless of the type of delimiter being used (ampersand or - anything else), the fields from \vref{lst:aligndelims:advanced} remain the same; for example, - using the settings in \cref{lst:delimiterRegEx3}, and running + anything else), the fields from \vref{lst:aligndelims:advanced} remain the same; for + example, using the settings in \cref{lst:delimiterRegEx3}, and running \index{switches!-l demonstration} \begin{commandshell} latexindent.pl tabbing.tex -l=delimiterRegEx3.yaml @@ -823,8 +825,8 @@ latexindent.pl tabbing.tex -l=delimiterRegEx3.yaml It is possible that delimiters specified within \texttt{delimiterRegEx} can be of different lengths. Consider the file in \cref{lst:tabbing1}, and associated YAML in - \cref{lst:delimiterRegEx4}. Note that the \cref{lst:delimiterRegEx4} specifies the option for - the delimiter to be either + \cref{lst:delimiterRegEx4}. Note that the \cref{lst:delimiterRegEx4} specifies the option + for the delimiter to be either \lstinline!#! or \lstinline!\>!, \emph{which are different lengths}. Upon running the command \index{switches!-l demonstration} @@ -844,10 +846,10 @@ latexindent.pl tabbing1.tex -l=delimiterRegEx4.yaml -o=+-mod4 \cmhlistingsfromfile{demonstrations/delimiterRegEx4.yaml}[yaml-TCB]{\texttt{delimiterRegEx4.yaml}}{lst:delimiterRegEx4} \end{cmhtcbraster} - You can set the \emph{delimiter} justification as either \texttt{left} (default) - or \texttt{right}, which will only have effect when delimiters in the same - column have different lengths. Using the settings in \cref{lst:delimiterRegEx5} and running - the command + You can set the \emph{delimiter} justification as either \texttt{left} (default) or + \texttt{right}, which will only have effect when delimiters in the same column have + different lengths. Using the settings in \cref{lst:delimiterRegEx5} and running the + command \index{switches!-l demonstration} \index{switches!-o demonstration} \begin{commandshell} @@ -861,15 +863,15 @@ latexindent.pl tabbing1.tex -l=delimiterRegEx5.yaml -o=+-mod5 \cmhlistingsfromfile{demonstrations/delimiterRegEx5.yaml}[yaml-TCB]{\texttt{delimiterRegEx5.yaml}}{lst:delimiterRegEx5} \end{cmhtcbraster} - Note that in \cref{lst:tabbing1-mod5} the second set of delimiters have been - \emph{right aligned} -- it is quite subtle! + Note that in \cref{lst:tabbing1-mod5} the second set of delimiters have been \emph{right + aligned} -- it is quite subtle! \subsection{Indent after items, specials and headings} \yamltitle{indentAfterItems}*{fields} The environment names specified in \texttt{indentAfterItems} tell \texttt{latexindent.pl} - to look for \lstinline!\item! commands; if these switches are set to - \texttt{1} then indentation will be performed so as indent the code after - each \texttt{item}. A demonstration is given in \cref{lst:itemsbefore,lst:itemsafter} + to look for \lstinline!\item! commands; if these switches are set to \texttt{1} then + indentation will be performed so as indent the code after each \texttt{item}. A + demonstration is given in \cref{lst:itemsbefore,lst:itemsafter} \begin{cmhtcbraster}[raster columns=3, raster left skip=-3.5cm, @@ -881,12 +883,11 @@ latexindent.pl tabbing1.tex -l=delimiterRegEx5.yaml -o=+-mod5 \end{cmhtcbraster} \yamltitle{itemNames}*{fields} - If you have your own \texttt{item} commands (perhaps you prefer to use - \texttt{myitem}, for example) then you can put populate them in - \texttt{itemNames}. For example, users of the \texttt{exam} document class - might like to add \texttt{parts} to \texttt{indentAfterItems} and - \texttt{part} to \texttt{itemNames} to their user settings (see - \vref{sec:indentconfig} for details of how to configure user settings, and + If you have your own \texttt{item} commands (perhaps you prefer to use \texttt{myitem}, + for example) then you can put populate them in \texttt{itemNames}. For example, users of + the \texttt{exam} document class might like to add \texttt{parts} to + \texttt{indentAfterItems} and \texttt{part} to \texttt{itemNames} to their user settings + (see \vref{sec:indentconfig} for details of how to configure user settings, and \vref{lst:mysettings} \\ in particular \label{page:examsettings}.) \cmhlistingsfromfile[style=itemNames]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{itemNames}}{lst:itemNames} @@ -894,41 +895,43 @@ latexindent.pl tabbing1.tex -l=delimiterRegEx5.yaml -o=+-mod5 \yamltitle{specialBeginEnd}*{fields}\label{yaml:specialBeginEnd} The fields specified \index{specialBeginEnd!introduction}% - \announce{2017-08-21}*{specialBeginEnd} in - \texttt{specialBeginEnd} are, in their default state, focused on math mode begin and end - statements, but there is no requirement for this to be the case; \cref{lst:specialBeginEnd} - shows the default settings of \texttt{specialBeginEnd}. + \announce{2017-08-21}*{specialBeginEnd} in \texttt{specialBeginEnd} are, in their default + state, focused on math mode begin and end statements, but there is no requirement for + this to be the case; \cref{lst:specialBeginEnd} shows the default settings of + \texttt{specialBeginEnd}. \index{specialBeginEnd!default settings} \cmhlistingsfromfile[style=specialBeginEnd]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{specialBeginEnd}}{lst:specialBeginEnd} - The field \texttt{displayMath} represents \lstinline!\[...\]!, - \texttt{inlineMath} represents + The field \texttt{displayMath} represents \lstinline!\[...\]!, \texttt{inlineMath} + represents \lstinline!$...$! and \texttt{displayMathTex} represents \lstinline!$$...$$!. You can, of course, rename these in your own YAML files (see \vref{sec:localsettings}); indeed, you might like to set up your own special begin and end statements. - A demonstration of the before-and-after results are shown in \cref{lst:specialbefore,lst:specialafter}. + A demonstration of the before-and-after results are shown in + \cref{lst:specialbefore,lst:specialafter}. \begin{cmhtcbraster} \cmhlistingsfromfile{demonstrations/special1.tex}{\texttt{special1.tex} before}{lst:specialbefore} \cmhlistingsfromfile{demonstrations/special1-default.tex}{\texttt{special1.tex} default output}{lst:specialafter} \end{cmhtcbraster} - For each field, \texttt{lookForThis} is set to \texttt{1} by default, - which means that \texttt{latexindent.pl} will look for this pattern; you can tell - \texttt{latexindent.pl} not to look for the pattern, by setting \texttt{lookForThis} - to \texttt{0}. + For each field, \texttt{lookForThis} is set to \texttt{1} by default, which means that + \texttt{latexindent.pl} will look for this pattern; you can tell \texttt{latexindent.pl} + not to look for the pattern, by setting \texttt{lookForThis} to \texttt{0}. There are% - \announce{2017-08-21}{specialBeforeCommand} examples in which it - is advantageous to search for \texttt{specialBeginEnd} fields \emph{before} - searching for commands, and the \texttt{specialBeforeCommand} switch controls this behaviour. - For example, consider the file shown in \cref{lst:specialLRbefore}. + \announce{2017-08-21}{specialBeforeCommand} + examples in which it is advantageous to search for \texttt{specialBeginEnd} fields + \emph{before} searching for commands, and the \texttt{specialBeforeCommand} switch + controls this behaviour. For example, consider the file shown in + \cref{lst:specialLRbefore}. \cmhlistingsfromfile{demonstrations/specialLR.tex}{\texttt{specialLR.tex}}{lst:specialLRbefore} - Now consider the YAML files shown in \cref{lst:specialsLeftRight-yaml,lst:specialBeforeCommand-yaml} + Now consider the YAML files shown in + \cref{lst:specialsLeftRight-yaml,lst:specialBeforeCommand-yaml} \index{specialBeginEnd!searching for special before commands} \begin{cmhtcbraster} @@ -944,7 +947,8 @@ latexindent.pl specialLR.tex -l=specialsLeftRight.yaml latexindent.pl specialLR.tex -l=specialsLeftRight.yaml,specialBeforeCommand.yaml \end{commandshell} \end{widepage} - we receive the respective outputs in \cref{lst:specialLR-comm-first-tex,lst:specialLR-special-first-tex}. + we receive the respective outputs in + \cref{lst:specialLR-comm-first-tex,lst:specialLR-special-first-tex}. \begin{minipage}{.49\linewidth} \cmhlistingsfromfile{demonstrations/specialLR-comm-first.tex}{\texttt{specialLR.tex} using \cref{lst:specialsLeftRight-yaml}}{lst:specialLR-comm-first-tex} @@ -958,21 +962,23 @@ latexindent.pl specialLR.tex -l=specialsLeftRight.yaml,specialBeforeCommand.yaml \begin{itemize} \item \cref{lst:specialLR-comm-first-tex} the \lstinline!\left! has been treated as a \emph{command}, with one optional argument; - \item \cref{lst:specialLR-special-first-tex} the \texttt{specialBeginEnd} pattern in \cref{lst:specialsLeftRight-yaml} + \item \cref{lst:specialLR-special-first-tex} the \texttt{specialBeginEnd} pattern in + \cref{lst:specialsLeftRight-yaml} has been obeyed because \cref{lst:specialBeforeCommand-yaml} specifies that the \texttt{specialBeginEnd} should be sought \emph{before} commands. \end{itemize} You can,optionally, specify% - \announce{2018-04-27}{update to specialBeginEnd} the - \texttt{middle} field for anything that you specify in \texttt{specialBeginEnd}. - For example, let's consider the \texttt{.tex} file in \cref{lst:special2}. + \announce{2018-04-27}{update to specialBeginEnd} the \texttt{middle} field for anything that you specify in + \texttt{specialBeginEnd}. For example, let's consider the \texttt{.tex} file in + \cref{lst:special2}. \index{specialBeginEnd!middle} \index{specialBeginEnd!IfElsFi example} \cmhlistingsfromfile{demonstrations/special2.tex}{\texttt{special2.tex}}{lst:special2} - Upon saving the YAML settings in \cref{lst:middle-yaml,lst:middle1-yaml} and running the commands + Upon saving the YAML settings in \cref{lst:middle-yaml,lst:middle1-yaml} and running the + commands \index{switches!-l demonstration} \begin{commandshell} latexindent.pl special2.tex -l=middle @@ -992,20 +998,19 @@ latexindent.pl special2.tex -l=middle1 We note that: \begin{itemize} - \item in \cref{lst:special2-mod1} the bodies of each of the \texttt{Elsif} statements - have been indented appropriately; - \item the \texttt{Else} statement has \emph{not} been indented - appropriately in \cref{lst:special2-mod1} -- read on! - \item we have specified multiple settings for the \texttt{middle} field using the - syntax demonstrated in \cref{lst:middle1-yaml} so that the body of the - \texttt{Else} statement has been indented appropriately in - \cref{lst:special2-mod2}. + \item in \cref{lst:special2-mod1} the bodies of each of the \texttt{Elsif} statements have been + indented appropriately; + \item the \texttt{Else} statement has \emph{not} been indented appropriately in + \cref{lst:special2-mod1} -- read on! + \item we have specified multiple settings for the \texttt{middle} field using the syntax + demonstrated in \cref{lst:middle1-yaml} so that the body of the \texttt{Else} statement + has been indented appropriately in \cref{lst:special2-mod2}. \end{itemize} You may% - \announce{2018-08-13}{specialBeginEnd verbatim} specify fields in - \texttt{specialBeginEnd} to be treated as verbatim code blocks by changing - \texttt{lookForThis} to be \texttt{verbatim}. + \announce{2018-08-13}{specialBeginEnd verbatim} + specify fields in \texttt{specialBeginEnd} to be treated as verbatim code blocks by + changing \texttt{lookForThis} to be \texttt{verbatim}. \index{verbatim!specialBeginEnd} For example, beginning with the code in \cref{lst:special3-mod1} and the YAML in @@ -1022,14 +1027,13 @@ latexindent.pl special3.tex -l=special-verb1 \cmhlistingsfromfile{demonstrations/special3-mod1.tex}{\texttt{special3.tex} and output using \cref{lst:special-verb1-yaml}}{lst:special3-mod1} \end{cmhtcbraster} - We can combine the \texttt{specialBeginEnd} with the \texttt{lookForAlignDelims} feature. We - begin with the code in \cref{lst:special-align}. + We can combine the \texttt{specialBeginEnd} with the \texttt{lookForAlignDelims} feature. + We begin with the code in \cref{lst:special-align}. \cmhlistingsfromfile{demonstrations/special-align.tex}{\texttt{special-align.tex}}{lst:special-align} - Let's assume that our goal is to align the code at the \texttt{edge} and - \texttt{node} text; we employ the code given in \cref{lst:edge-node1} and run - the command + Let's assume that our goal is to align the code at the \texttt{edge} and \texttt{node} + text; we employ the code given in \cref{lst:edge-node1} and run the command \index{switches!-l demonstration} \index{switches!-o demonstration} \begin{commandshell} @@ -1050,8 +1054,8 @@ latexindent.pl special-align.tex -l edge-node1.yaml -o=+-mod1 \end{cmhtcbraster} The output in \cref{lst:special-align-mod1} is not quite ideal. We can tweak the settings - within \cref{lst:edge-node1} in order to improve the output; in particular, we employ - the code in \cref{lst:edge-node2} and run the command + within \cref{lst:edge-node1} in order to improve the output; in particular, we employ the + code in \cref{lst:edge-node2} and run the command \index{switches!-l demonstration} \index{switches!-o demonstration} \index{regular expressions!uppercase alph A-Z} @@ -1064,41 +1068,42 @@ latexindent.pl special-align.tex -l edge-node2.yaml -o=+-mod2 \index{regular expressions!horizontal space \textbackslash{h}} \begin{cmhtcbraster}[ raster left skip=-3.5cm,] - \cmhlistingsfromfile*{demonstrations/edge-node2.yaml}[yaml-TCB]{\texttt{edge-node2.yaml}}{lst:edge-node2} + \cmhlistingsfromfile{demonstrations/edge-node2.yaml}[yaml-TCB]{\texttt{edge-node2.yaml}}{lst:edge-node2} \cmhlistingsfromfile{demonstrations/special-align-mod2.tex}{\texttt{special-align.tex} using \cref{lst:edge-node2}}{lst:special-align-mod2} \end{cmhtcbraster} The \texttt{lookForThis} field can be considered optional;% - \announce*{2021-06-19}*{lookForThis optional for specialBeginEnd} by default, it is - assumed to be 1, which is demonstrated in \cref{lst:edge-node2}. + \announce{2021-06-19}*{lookForThis optional for specialBeginEnd} by default, it is assumed to be 1, which is demonstrated in + \cref{lst:edge-node2}. \yamltitle{indentAfterHeadings}*{fields} This field enables the user to specify indentation rules that take effect after heading commands such as \lstinline!\part!, \lstinline!\chapter!, \lstinline!\section!, \lstinline!\subsection*!, or indeed any user-specified command - written in this field.\footnote{There is a slight - difference in interface for this field when comparing Version 2.2 to Version 3.0; see \vref{app:differences} for details.} + written in this field.\footnote{There is a slight difference in interface for this field + when comparing Version 2.2 to Version 3.0; see \vref{app:differences} for details.} \cmhlistingsfromfile[style=indentAfterHeadings]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{indentAfterHeadings}}{lst:indentAfterHeadings} - The default settings do \emph{not} place indentation after a heading, but - you can easily switch them on by changing \texttt{indentAfterThisHeading} from 0 to 1. The - \texttt{level} field tells \texttt{latexindent.pl} the hierarchy of the heading - structure in your document. You might, for example, like to have both - \texttt{section} and \texttt{subsection} set with \texttt{level: 3} - because you do not want the indentation to go too deep. + The default settings do \emph{not} place indentation after a heading, but you can easily + switch them on by changing \texttt{indentAfterThisHeading} from 0 to 1. The + \texttt{level} field tells \texttt{latexindent.pl} the hierarchy of the heading structure + in your document. You might, for example, like to have both \texttt{section} and + \texttt{subsection} set with \texttt{level: 3} because you do not want the indentation to + go too deep. You can add any of your own custom heading commands to this field, specifying the - \texttt{level} as appropriate. You can also specify your own indentation in - \texttt{indentRules} (see \vref{sec:noadd-indent-rules}); you will find the default \texttt{indentRules} contains + \texttt{level} as appropriate. You can also specify your own indentation in + \texttt{indentRules} (see \vref{sec:noadd-indent-rules}); you will find the default + \texttt{indentRules} contains \lstinline!chapter: " "! which tells \texttt{latexindent.pl} simply to use a space - character after \texttt{\chapter} headings (once \texttt{indent} is set to - \texttt{1} for \texttt{chapter}). + character after \texttt{\chapter} headings (once \texttt{indent} is set to \texttt{1} for + \texttt{chapter}). For example, assuming that you have the code in \cref{lst:headings1yaml} saved into - \texttt{headings1.yaml}, and that you have the text from \cref{lst:headings1} saved - into \texttt{headings1.tex}. + \texttt{headings1.yaml}, and that you have the text from \cref{lst:headings1} saved into + \texttt{headings1.tex}. \begin{cmhtcbraster} \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/headings1.yaml}[yaml-TCB]{\texttt{headings1.yaml}}{lst:headings1yaml} @@ -1120,9 +1125,8 @@ latexindent.pl headings1.tex -l=headings1.yaml \cmhlistingsfromfile[showtabs=true]{demonstrations/headings1-mod2.tex}{\texttt{headings1.tex} second modification}{lst:headings1-mod2} \end{minipage} - Now say that you modify the \texttt{YAML} from \cref{lst:headings1yaml} so that - the \texttt{paragraph} \texttt{level} is \texttt{1}; after - running + Now say that you modify the \texttt{YAML} from \cref{lst:headings1yaml} so that the + \texttt{paragraph} \texttt{level} is \texttt{1}; after running \index{switches!-l demonstration} \begin{commandshell} latexindent.pl headings1.tex -l=headings1.yaml @@ -1135,10 +1139,10 @@ latexindent.pl headings1.tex -l=headings1.yaml \yamltitle{maximumIndentation}*{horizontal space} You can control the maximum indentation given to your file by% - \announce{2017-08-21}{maximumIndentation} specifying the - \texttt{maximumIndentation} field as horizontal space (but \emph{not} including - tabs). This feature uses the \texttt{Text::Tabs} module \cite{texttabs}, and - is \emph{off} by default. + \announce{2017-08-21}{maximumIndentation} specifying + the \texttt{maximumIndentation} field as horizontal space (but \emph{not} including + tabs). This feature uses the \texttt{Text::Tabs} module \cite{texttabs}, and is + \emph{off} by default. For example, consider the example shown in \cref{lst:mult-nested} together with the default output shown in \cref{lst:mult-nested-default}. @@ -1161,14 +1165,16 @@ latexindent.pl mult-nested.tex -l=max-indentation1 \cmhlistingsfromfile[showspaces=true]{demonstrations/mult-nested-max-ind1.tex}{\texttt{mult-nested.tex} using \cref{lst:max-indentation1yaml}}{lst:mult-nested-max-ind1} \end{cmhtcbraster} - Comparing the output in \cref{lst:mult-nested-default,lst:mult-nested-max-ind1} we notice that the (default) tabs of - indentation have been replaced by a single space. + Comparing the output in \cref{lst:mult-nested-default,lst:mult-nested-max-ind1} we notice + that the (default) tabs of indentation have been replaced by a single space. In general, when using the \texttt{maximumIndentation} feature, any leading tabs will be - replaced by equivalent spaces except, of course, those found in \texttt{verbatimEnvironments} (see \vref{lst:verbatimEnvironments}) - or \texttt{noIndentBlock} (see \vref{lst:noIndentBlock}). + replaced by equivalent spaces except, of course, those found in + \texttt{verbatimEnvironments} (see \vref{lst:verbatimEnvironments}) or + \texttt{noIndentBlock} (see \vref{lst:noIndentBlock}). \subsection{The code blocks known latexindent.pl}\label{subsubsec:code-blocks} + As of Version 3.0, \texttt{latexindent.pl} processes documents using code blocks; each of these are shown in \cref{tab:code-blocks}. \index{regular expressions!uppercase alph A-Z} @@ -1247,5 +1253,6 @@ mand arg text \end{table} We will refer to these code blocks in what follows.% - \announce{2019-07-13}{fine tuning of code blocks} Note that the fine tuning of the definition of the code blocks - detailed in \cref{tab:code-blocks} is discussed in \vref{sec:finetuning}. + \announce{2019-07-13}{fine tuning of code blocks} Note that the fine tuning of the + definition of the code blocks detailed in \cref{tab:code-blocks} is discussed in + \vref{sec:finetuning}. diff --git a/support/latexindent/documentation/sec-demonstration.tex b/support/latexindent/documentation/sec-demonstration.tex index 18459edcda..0c8e12c154 100644 --- a/support/latexindent/documentation/sec-demonstration.tex +++ b/support/latexindent/documentation/sec-demonstration.tex @@ -4,15 +4,17 @@ want to try the script if you don't much like the results. You might also like to watch the video demonstration I made on youtube \cite{cmh:videodemo} - As you look at \crefrange{lst:filecontentsbefore}{lst:pstricksafter}, remember that \texttt{latexindent.pl} is just - following its rules, and there is nothing particular about these code snippets. All of - the rules can be modified so that you can personalise your indentation scheme. + As you look at \crefrange{lst:filecontentsbefore}{lst:pstricksafter}, remember that + \texttt{latexindent.pl} is just following its rules, and there is nothing particular + about these code snippets. All of the rules can be modified so that you can personalise + your indentation scheme. - In each of the samples given in \crefrange{lst:filecontentsbefore}{lst:pstricksafter} the `before' case is a `worst case - scenario' with no effort to make indentation. The `after' result would be the same, - regardless of the leading white space at the beginning of each line which is stripped by - \texttt{latexindent.pl} (unless a \texttt{verbatim}-like - environment or \texttt{noIndentBlock} is specified -- more on this in \cref{sec:defuseloc}). + In each of the samples given in \crefrange{lst:filecontentsbefore}{lst:pstricksafter} the + `before' case is a `worst case scenario' with no effort to make indentation. The `after' + result would be the same, regardless of the leading white space at the beginning of each + line which is stripped by \texttt{latexindent.pl} (unless a \texttt{verbatim}-like + environment or \texttt{noIndentBlock} is specified -- more on this in + \cref{sec:defuseloc}). \begin{widepage} \centering diff --git a/support/latexindent/documentation/sec-fine-tuning.tex b/support/latexindent/documentation/sec-fine-tuning.tex index 0510e8e66c..669bff5737 100644 --- a/support/latexindent/documentation/sec-fine-tuning.tex +++ b/support/latexindent/documentation/sec-fine-tuning.tex @@ -2,8 +2,9 @@ \section{Fine tuning}\label{sec:finetuning} \texttt{latexindent.pl} operates by looking for the code blocks detailed in \vref{tab:code-blocks}. - \announce{2019-07-13}{details of fine tuning of code blocks} The fine tuning of the details of such code blocks - is controlled by the \texttt{fineTuning} field, detailed in \cref{lst:fineTuning}. + \announce{2019-07-13}{details of fine tuning of code blocks} The fine tuning of the + details of such code blocks is controlled by the \texttt{fineTuning} field, detailed in + \cref{lst:fineTuning}. This field is for those that would like to peek under the bonnet/hood and make some fine tuning to \texttt{latexindent.pl}'s operating. @@ -29,7 +30,7 @@ \end{warning} \begin{widepage} - \cmhlistingsfromfile*[style=fineTuning]*{../defaultSettings.yaml}[width=.95\linewidth,before=\centering,yaml-TCB]{\texttt{fineTuning}}{lst:fineTuning} + \cmhlistingsfromfile[style=fineTuning]*{../defaultSettings.yaml}[width=.95\linewidth,before=\centering,yaml-TCB]{\texttt{fineTuning}}{lst:fineTuning} \end{widepage} The fields given in \cref{lst:fineTuning} are all \emph{regular expressions}. This manual @@ -38,8 +39,8 @@ We make the following comments with reference to \cref{lst:fineTuning}: \begin{enumerate} - \item the \texttt{environments:name} field details that the \emph{name} of an - environment can contain: + \item the \texttt{environments:name} field details that the \emph{name} of an environment can + contain: \begin{enumerate} \item \texttt{a-z} lower case letters \item \texttt{A-Z} upper case letters @@ -50,25 +51,23 @@ \item \lstinline!\! backslashes \end{enumerate} \index{regular expressions!at least one +} - The \texttt{+} at the end means \emph{at least one} of the above - characters. + The \texttt{+} at the end means \emph{at least one} of the above characters. \item the \texttt{ifElseFi:name} field: \begin{enumerate} \item \lstinline^@?^ means that it \emph{can possibly} begin with \lstinline^@^ \item followed by \texttt{if} - \item followed by 0 or more characters from \texttt{a-z}, \texttt{A-Z} and - \texttt{@} - \item the \texttt{?} the end means \emph{non-greedy}, which means `stop the - match as soon as possible' + \item followed by 0 or more characters from \texttt{a-z}, \texttt{A-Z} and \texttt{@} + \item the \texttt{?} the end means \emph{non-greedy}, which means `stop the match as soon as + possible' \end{enumerate} \item the \texttt{keyEqualsValuesBracesBrackets} contains some interesting syntax: \begin{enumerate} \item \lstinline!|! means `or' \item \lstinline^(?:(?<!\\)\{)^ the \lstinline^(?:...)^ uses a \emph{non-capturing} group -- you don't necessarily need to worry about what this means, but just know that for the - \texttt{fineTuning} feature you should only ever use \emph{non}-capturing - groups, and \emph{not} capturing groups, which are simply + \texttt{fineTuning} feature you should only ever use \emph{non}-capturing groups, and + \emph{not} capturing groups, which are simply \lstinline!(...)! \item \lstinline^(?<!\\)\{)^ means a \lstinline^{^ but it can \emph{not} be immediately preceded by a \lstinline!\! @@ -90,14 +89,14 @@ \texttt{DBSFinishesWithLineBreak} polyswitches surrounding double back slashes, see \vref{subsec:dbs} \item \texttt{comma} is in relation to the \texttt{CommaStartsOnOwnLine} and - \texttt{CommaFinishesWithLineBreak} polyswitches surrounding commas in optional and mandatory - arguments; see \vref{tab:poly-switch-mapping} + \texttt{CommaFinishesWithLineBreak} polyswitches surrounding commas in optional and + mandatory arguments; see \vref{tab:poly-switch-mapping} \end{enumerate} \end{enumerate} It is not obvious from \cref{lst:fineTuning}, but each of the \texttt{follow}, - \texttt{before} and \texttt{between} fields allow trailing comments, line - breaks, and horizontal spaces between each character. + \texttt{before} and \texttt{between} fields allow trailing comments, line breaks, and + horizontal spaces between each character. \begin{example} As a demonstration, consider the file given in \cref{lst:finetuning1}, together with its @@ -179,15 +178,15 @@ latexindent.pl -m -y='modifyLineBreaks:oneSentencePerLine:manipulateSentences: 1 We can tweak the \texttt{fineTuning} for how trailing comments are classified. For motivation, let's consider the code given in \cref{lst:finetuning4} - \cmhlistingsfromfile*{demonstrations/finetuning4.tex}{\texttt{finetuning4.tex}}{lst:finetuning4} + \cmhlistingsfromfile{demonstrations/finetuning4.tex}{\texttt{finetuning4.tex}}{lst:finetuning4} We will compare the settings given in \cref{lst:href1,lst:href2}. \begin{cmhtcbraster}[raster column skip=.01\linewidth, raster left skip=0cm, raster right skip=-0.5cm,] - \cmhlistingsfromfile*[style=yaml-LST]*{demonstrations/href1.yaml}[MLB-TCB]{\texttt{href1.yaml}}{lst:href1} - \cmhlistingsfromfile*[style=yaml-LST]*{demonstrations/href2.yaml}[MLB-TCB]{\texttt{href2.yaml}}{lst:href2} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/href1.yaml}[MLB-TCB]{\texttt{href1.yaml}}{lst:href1} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/href2.yaml}[MLB-TCB]{\texttt{href2.yaml}}{lst:href2} \end{cmhtcbraster} Upon running the following commands @@ -198,16 +197,16 @@ latexindent.pl -m finetuning4.tex -o=+-mod2 -l=href2 we receive the respective output in \cref{lst:finetuning4-mod1,lst:finetuning4-mod2}. \begin{widepage} - \cmhlistingsfromfile*{demonstrations/finetuning4-mod1.tex}{\texttt{finetuning4.tex} using \cref{lst:href1}}{lst:finetuning4-mod1} + \cmhlistingsfromfile{demonstrations/finetuning4-mod1.tex}{\texttt{finetuning4.tex} using \cref{lst:href1}}{lst:finetuning4-mod1} - \cmhlistingsfromfile*{demonstrations/finetuning4-mod2.tex}{\texttt{finetuning4.tex} using \cref{lst:href2}}{lst:finetuning4-mod2} + \cmhlistingsfromfile{demonstrations/finetuning4-mod2.tex}{\texttt{finetuning4.tex} using \cref{lst:href2}}{lst:finetuning4-mod2} \end{widepage} We note that in: \begin{itemize} - \item \cref{lst:finetuning4-mod1} the trailing comments are assumed to be everything following the - first comment symbol, which has meant that everything following it has been moved to the - end of the line; this is undesirable, clearly! + \item \cref{lst:finetuning4-mod1} the trailing comments are assumed to be everything following + the first comment symbol, which has meant that everything following it has been moved to + the end of the line; this is undesirable, clearly! \item \cref{lst:finetuning4-mod2} has fine-tuned the trailing comment matching, and says that \% cannot be immediately preceeded by the words `Handbook', `for' or `Spoken', which means that @@ -224,7 +223,7 @@ latexindent.pl -m finetuning4.tex -o=+-mod3 -l=href3 then we receive the same output given in \cref{lst:finetuning4-mod2}; see also \texttt{paragraphsStopAt} in \vref{lst:paragraphsStopAt}. - \cmhlistingsfromfile*[style=yaml-LST]*{demonstrations/href3.yaml}[MLB-TCB]{\texttt{href3.yaml}}{lst:href3} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/href3.yaml}[MLB-TCB]{\texttt{href3.yaml}}{lst:href3} With reference to the \texttt{body} field in \cref{lst:href3}, we note that the \texttt{body} field can be interpreted as: the fewest number of zero or more characters that are not right braces. This diff --git a/support/latexindent/documentation/sec-how-to-use.tex b/support/latexindent/documentation/sec-how-to-use.tex index ba35a04328..42553e037a 100644 --- a/support/latexindent/documentation/sec-how-to-use.tex +++ b/support/latexindent/documentation/sec-how-to-use.tex @@ -2,36 +2,36 @@ \section{How to use the script} \texttt{latexindent.pl} ships as part of the \TeX Live distribution for Linux and Mac users; \texttt{latexindent.exe} ships as part of the \TeX Live and - MiK\TeX{} distributions for Windows users. These files are also available - from github \cite{latexindent-home} should you wish to use them without a - \TeX{} distribution; in this case, you may like to read - \vref{sec:updating-path} which details how the \texttt{path} variable can be - updated. + MiK\TeX{} distributions for Windows users. These files are also available from github + \cite{latexindent-home} should you wish to use them without a \TeX{} distribution; in + this case, you may like to read \vref{sec:updating-path} which details how the + \texttt{path} variable can be updated. In what follows, we will always refer to \texttt{latexindent.pl}, but depending on your operating system and preference, you might substitute \texttt{latexindent.exe} or simply \texttt{latexindent}. There are two ways to use \texttt{latexindent.pl}: from the command line, and using - \texttt{arara}; we discuss these in \cref{sec:commandline} and - \cref{sec:arara} respectively. We will discuss how to change the settings and - behaviour of the script in \vref{sec:defuseloc}. + \texttt{arara}; we discuss these in \cref{sec:commandline} and \cref{sec:arara} + respectively. We will discuss how to change the settings and behaviour of the script in + \vref{sec:defuseloc}. \texttt{latexindent.pl} ships with \texttt{latexindent.exe} for Windows users, so that you can use the script with or without a Perl distribution. If you plan to - use \texttt{latexindent.pl} (i.e, the original Perl script) then you will need a few standard Perl modules -- see - \vref{sec:requiredmodules} for details;% - \announce{2018-01-13}{perl module installer helper script} in particular, note that a module installer helper script is - shipped with \texttt{latexindent.pl}. + use \texttt{latexindent.pl} (i.e, the original Perl script) then you will need a few + standard Perl modules -- see \vref{sec:requiredmodules} for + details;% + \announce{2018-01-13}{perl module installer helper script} in particular, note that a module installer helper script is shipped with + \texttt{latexindent.pl}. \subsection{From the command line}\label{sec:commandline} \texttt{latexindent.pl} has a number of different switches/flags/options, which can be combined in any way that you like, either in short or long form as detailed below. - \texttt{latexindent.pl} produces a \texttt{.log} file, \texttt{indent.log}, - every time it is run; the name of the log file can be customised, but we will refer to - the log file as \texttt{indent.log} throughout this document. There is a base of - information that is written to \texttt{indent.log}, but other additional information - will be written depending on which of the following options are used. + \texttt{latexindent.pl} produces a \texttt{.log} file, \texttt{indent.log}, every time it + is run; the name of the log file can be customised, but we will refer to the log file as + \texttt{indent.log} throughout this document. There is a base of information that is + written to \texttt{indent.log}, but other additional information will be written + depending on which of the following options are used. \flagbox{-v, --version} \index{switches!-v, --version definition and details} @@ -55,8 +55,8 @@ latexindent.pl myfile.tex \end{commandshell} This will operate on \texttt{myfile.tex}, but will simply output to your terminal; - \texttt{myfile.tex} will not be changed by \texttt{latexindent.pl} in any way using - this command. + \texttt{myfile.tex} will not be changed by \texttt{latexindent.pl} in any way using this + command. \flagbox{-w, --overwrite} \index{switches!-w, --overwrite definition and details} @@ -86,44 +86,43 @@ latexindent.pl --outputfile=output.tex myfile.tex latexindent.pl --outputfile output.tex myfile.tex \end{commandshell} - This will indent \texttt{myfile.tex} and output it to \texttt{output.tex}, - overwriting it (\texttt{output.tex}) if it already exists\footnote{Users of version 2.* should - note the subtle change in syntax}. Note - that if \texttt{latexindent.pl} is called with both the \texttt{-w} and - \texttt{-o} switches, then \texttt{-w} will be ignored and - \texttt{-o} will take priority (this seems safer than the other way round). + This will indent \texttt{myfile.tex} and output it to \texttt{output.tex}, overwriting it + (\texttt{output.tex}) if it already exists\footnote{Users of version 2.* should note the + subtle change in syntax}. Note that if \texttt{latexindent.pl} is called with both the + \texttt{-w} and \texttt{-o} switches, then \texttt{-w} will be ignored and \texttt{-o} + will take priority (this seems safer than the other way round). Note that using \texttt{-o} as above is equivalent to using \begin{commandshell} latexindent.pl myfile.tex > output.tex \end{commandshell} - You can call the \texttt{-o} switch with the name of the output file - \emph{without} an extension; in% - \announce{2017-06-25}{upgrade to -o switch} this case, \texttt{latexindent.pl} will use the extension from the - original file. For example, the following two calls to \texttt{latexindent.pl} are - equivalent: + You can call the \texttt{-o} switch with the name of the output file \emph{without} an + extension; in% + \announce{2017-06-25}{upgrade to -o switch} + this case, \texttt{latexindent.pl} will use the extension from the original file. For + example, the following two calls to \texttt{latexindent.pl} are equivalent: \begin{commandshell} latexindent.pl myfile.tex -o=output latexindent.pl myfile.tex -o=output.tex \end{commandshell} - You can call the \texttt{-o} switch using a \texttt{+} symbol at - the beginning; this will% + You can call the \texttt{-o} switch using a \texttt{+} symbol at the beginning; this + will% \announce{2017-06-25}{+ sign in o switch} - concatenate the name of the input file and the text given to the \texttt{-o} - switch. For example, the following two calls to \texttt{latexindent.pl} are equivalent: + concatenate the name of the input file and the text given to the \texttt{-o} switch. For + example, the following two calls to \texttt{latexindent.pl} are equivalent: \begin{commandshell} latexindent.pl myfile.tex -o=+new latexindent.pl myfile.tex -o=myfilenew.tex \end{commandshell} - You can call the \texttt{-o} switch using a \texttt{++} symbol at - the end of the name% + You can call the \texttt{-o} switch using a \texttt{++} symbol at the end of the + name% \announce{2017-06-25}{++ in o switch} of your output file; this tells \texttt{latexindent.pl} to search successively for the name of your - output file concatenated with $0, 1, \ldots$ while the name of the output file - exists. For example, + output file concatenated with $0, 1, \ldots$ while the name of the output file exists. + For example, \begin{commandshell} latexindent.pl myfile.tex -o=output++ \end{commandshell} @@ -137,17 +136,16 @@ latexindent.pl myfile.tex -o=++ tells it to output to \texttt{myfile0.tex}, but if it exists then output to \texttt{myfile1.tex} and so on. - The \texttt{+} and \texttt{++} feature of the - \texttt{-o} switch can be combined; for example, calling + The \texttt{+} and \texttt{++} feature of the \texttt{-o} switch can be combined; for + example, calling \begin{commandshell} latexindent.pl myfile.tex -o=+out++ \end{commandshell} - tells \texttt{latexindent.pl} to output to \texttt{myfileout0.tex}, but if it exists, then - try \texttt{myfileout1.tex}, and so on. + tells \texttt{latexindent.pl} to output to \texttt{myfileout0.tex}, but if it exists, + then try \texttt{myfileout1.tex}, and so on. - There is no need to specify a file extension when using the \texttt{++} - feature, but if you wish to, then you should include it \emph{after} the - \texttt{++} symbols, for example + There is no need to specify a file extension when using the \texttt{++} feature, but if + you wish to, then you should include it \emph{after} the \texttt{++} symbols, for example \begin{commandshell} latexindent.pl myfile.tex -o=+out++.tex \end{commandshell} @@ -186,9 +184,8 @@ latexindent.pl myfile.tex -tt \emph{More detailed} tracing mode: this option gives more details to \texttt{indent.log} - than the standard \texttt{trace} option (note that, even more so than with - \texttt{-t}, especially for large files, performance of the script will be - affected). + than the standard \texttt{trace} option (note that, even more so than with \texttt{-t}, + especially for large files, performance of the script will be affected). \flagbox{-l, --local[=myyaml.yaml,other.yaml,...]} \index{switches!-l, --local definition and details} @@ -202,29 +199,31 @@ latexindent.pl myfile.tex -l=first.yaml,second.yaml,third.yaml \end{commandshell} \label{page:localswitch} - \texttt{latexindent.pl} will always load \texttt{defaultSettings.yaml} (rhymes with camel) - and if it is called with the \texttt{-l} switch and it finds + \texttt{latexindent.pl} will always load \texttt{defaultSettings.yaml} (rhymes with + camel) and if it is called with the \texttt{-l} switch and it finds \texttt{localSettings.yaml} in the same directory as \texttt{myfile.tex}, then, if not - found, it looks for \texttt{localSettings.yaml} (and friends, see \vref{sec:localsettings}) in the current working directory, then these - \announce{2021-03-14}*{-l switch: localSettings and friends} settings will be added to the indentation scheme. Information - will be given in \texttt{indent.log} on the success or failure of loading - \texttt{localSettings.yaml}. - - The \texttt{-l} flag can take an \emph{optional} parameter which - details the name (or names separated by commas) of a YAML file(s) that resides in the - same directory as \texttt{myfile.tex}; you can use this option if you would like to - load a settings file in the current working directory that is \emph{not} - called \texttt{localSettings.yaml}.% - \announce{2017-08-21}*{-l switch absolute paths} - In fact, you can specify both \emph{relative} and \emph{absolute paths} for - your YAML files; for example + found, it looks for \texttt{localSettings.yaml} (and friends, see + \vref{sec:localsettings}) in the current working directory, then + these% + \announce{2021-03-14}*{-l switch: localSettings and + friends} settings will be added to the indentation scheme. Information will be given in + \texttt{indent.log} on the success or failure of loading \texttt{localSettings.yaml}. + + The \texttt{-l} flag can take an \emph{optional} parameter which details the name (or + names separated by commas) of a YAML file(s) that resides in the same directory as + \texttt{myfile.tex}; you can use this option if you would like to load a settings file in + the current working directory that is \emph{not} called + \texttt{localSettings.yaml}.% + \announce{2017-08-21}*{-l + switch absolute paths} In fact, you can specify both \emph{relative} and \emph{absolute + paths} for your YAML files; for example \begin{commandshell} latexindent.pl -l=../../myyaml.yaml myfile.tex latexindent.pl -l=/home/cmhughes/Desktop/myyaml.yaml myfile.tex latexindent.pl -l=C:\Users\cmhughes\Desktop\myyaml.yaml myfile.tex \end{commandshell} - You will find a lot of other explicit demonstrations of how to use the - \texttt{-l} switch throughout this documentation, + You will find a lot of other explicit demonstrations of how to use the \texttt{-l} switch + throughout this documentation, You can call the \texttt{-l} switch with a `+' symbol either before or after \announce{2017-06-25}{+ sign with -l switch} another YAML file; for example: @@ -247,11 +246,12 @@ latexindent.pl -l+myyaml.yaml myfile.tex \begin{commandshell} latexindent.pl -l + myyaml.yaml myfile.tex \end{commandshell} - will \emph{only} load \texttt{localSettings.yaml}, and \texttt{myyaml.yaml} - will be ignored. If you wish to use spaces between any of the YAML settings, then you - must wrap the entire list of YAML files in quotes, as demonstrated above. + will \emph{only} load \texttt{localSettings.yaml}, and \texttt{myyaml.yaml} will be + ignored. If you wish to use spaces between any of the YAML settings, then you must wrap + the entire list of YAML files in quotes, as demonstrated above. - You may also choose to omit the \texttt{yaml} extension, such as + You may also choose to omit the \texttt{yaml} extension, such + as% \announce{2017-06-25}{no extension for -l switch} \begin{commandshell} latexindent.pl -l=localSettings,myyaml myfile.tex @@ -268,31 +268,29 @@ latexindent.pl myfile.tex -y='modifyLineBreaks:environments:EndStartsOnOwnLine:3 latexindent.pl myfile.tex -y='modifyLineBreaks:environments:one:EndStartsOnOwnLine:3' -m \end{commandshell} \label{page:yamlswitch}You% - \announce{2017-08-21}{the -y switch} can specify YAML settings from the command line using the - \texttt{-y} or \texttt{--yaml} switch; - sample demonstrations are given above. Note, in particular, that multiple settings can - be specified by separating them via commas. There is a further option to use a - \texttt{;} to separate fields, which is demonstrated in - \vref{sec:yamlswitch}. - - Any settings specified via this switch will be loaded \emph{after} any - specified using the \texttt{-l} switch. This is discussed further in - \vref{sec:loadorder}. + \announce{2017-08-21}{the -y switch} can specify YAML settings from the command line + using the \texttt{-y} or \texttt{--yaml} switch; sample demonstrations are given above. + Note, in particular, that multiple settings can be specified by separating them via + commas. There is a further option to use a \texttt{;} to separate fields, which is + demonstrated in \vref{sec:yamlswitch}. + + Any settings specified via this switch will be loaded \emph{after} any specified using + the \texttt{-l} switch. This is discussed further in \vref{sec:loadorder}. \flagbox{-d, --onlydefault} \index{switches!-d, --onlydefault definition and details} \begin{commandshell} latexindent.pl -d myfile.tex \end{commandshell} - Only \texttt{defaultSettings.yaml}: you might like to read \cref{sec:defuseloc} before using - this switch. By default, \texttt{latexindent.pl} will always search for - \texttt{indentconfig.yaml} or \texttt{.indentconfig.yaml} in your home directory. If you would - prefer it not to do so then (instead of deleting or renaming \texttt{indentconfig.yaml} or - \texttt{.indentconfig.yaml}) you can simply call the script with the \texttt{-d} - switch; note that this will also tell the script to ignore \texttt{localSettings.yaml} even - if it has been called with the \texttt{-l} switch; \texttt{latexindent.pl}% - \announce{2017-08-21}*{updated -d switch} will also ignore any settings specified from the - \texttt{-y} switch. + Only \texttt{defaultSettings.yaml}: you might like to read \cref{sec:defuseloc} before + using this switch. By default, \texttt{latexindent.pl} will always search for + \texttt{indentconfig.yaml} or \texttt{.indentconfig.yaml} in your home directory. If you + would prefer it not to do so then (instead of deleting or renaming + \texttt{indentconfig.yaml} or \texttt{.indentconfig.yaml}) you can simply call the script + with the \texttt{-d} switch; note that this will also tell the script to ignore + \texttt{localSettings.yaml} even if it has been called with the \texttt{-l} switch; + \texttt{latexindent.pl}% + \announce{2017-08-21}*{updated -d switch} will also ignore any settings specified from the \texttt{-y} switch. \flagbox{-c, --cruft=<directory>} \index{switches!-c, --cruft definition and details} @@ -313,13 +311,13 @@ latexindent.pl --logfile other.log myfile.tex latexindent.pl myfile.tex -g other.log \end{commandshell} - By default, \texttt{latexindent.pl} reports information to \texttt{indent.log}, but - if you wish to change the name of this file, simply call the script with your chosen name + By default, \texttt{latexindent.pl} reports information to \texttt{indent.log}, but if + you wish to change the name of this file, simply call the script with your chosen name after the \texttt{-g} switch as demonstrated above. - \announce{2021-05-07}{log file creation updated} If \texttt{latexindent.pl} can not open the log file that you - specify, then the script will operate, and no log file will be produced; this might be - helpful to users who wish to specify the following, for example + \announce{2021-05-07}{log file creation updated} If \texttt{latexindent.pl} can not open + the log file that you specify, then the script will operate, and no log file will be + produced; this might be helpful to users who wish to specify the following, for example \begin{commandshell} latexindent.pl -g /dev/null myfile.tex \end{commandshell} @@ -331,9 +329,8 @@ latexindent.pl -sl myfile.tex latexindent.pl -screenlog myfile.tex \end{commandshell} Using this% - \announce{2018-01-13}{screenlog switch created} option tells - \texttt{latexindent.pl} to output the log file to the screen, as well as to your chosen - log file. + \announce{2018-01-13}{screenlog switch created} option tells \texttt{latexindent.pl} to output the log file to the screen, as + well as to your chosen log file. \flagbox{-m, --modifylinebreaks} \index{switches!-m, --modifylinebreaks definition and details} @@ -358,22 +355,20 @@ cat myfile.tex | latexindent.pl cat myfile.tex | latexindent.pl - \end{commandshell} \texttt{latexindent.pl} will% - \announce{2018-01-13}{STDIN allowed} allow input from STDIN, which means that you can pipe output from - other commands directly into the script. For example assuming that you have content in - \texttt{myfile.tex}, then the above command will output the results of operating upon - \texttt{myfile.tex}. + \announce{2018-01-13}{STDIN allowed} allow input from STDIN, which means that you can + pipe output from other commands directly into the script. For example assuming that you + have content in \texttt{myfile.tex}, then the above command will output the results of + operating upon \texttt{myfile.tex}. - If you wish to use this feature with your own local settings, via the - \texttt{-l} switch, then you should finish your call to - \texttt{latexindent.pl} with a \texttt{-} sign: + If you wish to use this feature with your own local settings, via the \texttt{-l} switch, + then you should finish your call to \texttt{latexindent.pl} with a \texttt{-} sign: \begin{commandshell} cat myfile.tex | latexindent.pl -l=mysettings.yaml - \end{commandshell} Similarly, if you% - \announce{2018-01-13}*{no options/filename updated} simply type - \texttt{latexindent.pl} at the command line, then it will expect (STDIN) input from the - command line. + \announce{2018-01-13}*{no options/filename updated} simply type \texttt{latexindent.pl} at the command line, then + it will expect (STDIN) input from the command line. \begin{commandshell} latexindent.pl \end{commandshell} @@ -383,8 +378,8 @@ latexindent.pl \item \texttt{CTRL+D} on Linux \item \texttt{CTRL+Z} followed by \texttt{ENTER} on Windows \end{itemize} - to signify that your input has finished. Thanks to \cite{xu-cheng} for an update - to this feature. + to signify that your input has finished. Thanks to \cite{xu-cheng} for an update to this + feature. \flagbox{-r, --replacement} \index{switches!-r, --replacement definition and details} \begin{commandshell} @@ -392,8 +387,8 @@ latexindent.pl -r myfile.tex latexindent.pl -replacement myfile.tex \end{commandshell} You can% - \announce{2019-07-13}{replacement mode switch} call - \texttt{latexindent.pl} with the \texttt{-r} switch to instruct it to perform + \announce{2019-07-13}{replacement mode switch} + call \texttt{latexindent.pl} with the \texttt{-r} switch to instruct it to perform replacements/substitutions on your file; full details and examples are given in \vref{sec:replacements}. \index{verbatim!rv, replacementrespectverb switch} @@ -405,10 +400,9 @@ latexindent.pl -rv myfile.tex latexindent.pl -replacementrespectverb myfile.tex \end{commandshell} You can% - \announce{2019-07-13}{replacement mode switch, respecting verbatim} instruct - \texttt{latexindent.pl} to perform replacements/substitutions by using the - \texttt{-rv} switch, but will \emph{respect verbatim code blocks}; full details and - examples are given in \vref{sec:replacements}. + \announce{2019-07-13}{replacement mode switch, respecting verbatim} instruct \texttt{latexindent.pl} to perform + replacements/substitutions by using the \texttt{-rv} switch, but will \emph{respect + verbatim code blocks}; full details and examples are given in \vref{sec:replacements}. \flagbox{-rr, --onlyreplacement} \index{switches!-rr, --onlyreplacement definition and details} @@ -417,11 +411,9 @@ latexindent.pl -rr myfile.tex latexindent.pl -onlyreplacement myfile.tex \end{commandshell} You can% - \announce{2019-07-13}{replacement (only) mode switch} instruct - \texttt{latexindent.pl} to skip all of its other indentation operations and - \emph{only} perform replacements/substitutions by using the - \texttt{-rr} switch; full details and examples are given in - \vref{sec:replacements}. + \announce{2019-07-13}{replacement (only) mode switch} instruct \texttt{latexindent.pl} to skip all of its other indentation operations + and \emph{only} perform replacements/substitutions by using the \texttt{-rr} switch; full + details and examples are given in \vref{sec:replacements}. \subsection{From arara}\label{sec:arara} Using \texttt{latexindent.pl} from the command line is fine for some folks, but others diff --git a/support/latexindent/documentation/sec-indent-config-and-settings.tex b/support/latexindent/documentation/sec-indent-config-and-settings.tex index ddce5c806b..f2084506cc 100644 --- a/support/latexindent/documentation/sec-indent-config-and-settings.tex +++ b/support/latexindent/documentation/sec-indent-config-and-settings.tex @@ -2,26 +2,26 @@ \section{indentconfig.yaml, local settings and the -y switch }\label{sec:indentconfig} The behaviour of \texttt{latexindent.pl} is controlled from the settings specified in any of the YAML files that you tell it to load. By default, \texttt{latexindent.pl} will only - load \texttt{defaultSettings.yaml}, but there are a few ways that you can tell it to load your - own settings files. + load \texttt{defaultSettings.yaml}, but there are a few ways that you can tell it to load + your own settings files. \subsection{indentconfig.yaml and .indentconfig.yaml} - \texttt{latexindent.pl} will always check your home directory for \texttt{indentconfig.yaml} - and \texttt{.indentconfig.yaml} (unless - it is called with the \texttt{-d} switch), which is a plain text file you can create that contains the - \emph{absolute} paths for any settings files that you wish \texttt{latexindent.pl} - to load. There is no difference between \texttt{indentconfig.yaml} and - \texttt{.indentconfig.yaml}, other than the fact that \texttt{.indentconfig.yaml} is a `hidden' - file; thank you to \cite{jacobo-diaz-hidden-config} for providing this feature. In what follows, we - will use \texttt{indentconfig.yaml}, but it is understood that this could equally represent - \texttt{.indentconfig.yaml}. If you have both files in existence then \texttt{indentconfig.yaml} - takes priority. - - For Mac and Linux users, their home directory is \texttt{~/username} while Windows - (Vista onwards) is \lstinline!C:\Users\username!\footnote{If you're not sure - where to put \texttt{indentconfig.yaml}, don't - worry \texttt{latexindent.pl} will tell you in the log file exactly where to - put it assuming it doesn't exist already.} \Cref{lst:indentconfig} + \texttt{latexindent.pl} will always check your home directory for + \texttt{indentconfig.yaml} + and \texttt{.indentconfig.yaml} (unless it is called with the \texttt{-d} switch), which + is a plain text file you can create that contains the \emph{absolute} paths for any + settings files that you wish \texttt{latexindent.pl} to load. There is no difference + between \texttt{indentconfig.yaml} and \texttt{.indentconfig.yaml}, other than the fact + that \texttt{.indentconfig.yaml} is a `hidden' file; thank you to + \cite{jacobo-diaz-hidden-config} for providing this feature. In what follows, we will use + \texttt{indentconfig.yaml}, but it is understood that this could equally represent + \texttt{.indentconfig.yaml}. If you have both files in existence then + \texttt{indentconfig.yaml} takes priority. + + For Mac and Linux users, their home directory is \texttt{~/username} while Windows (Vista + onwards) is \lstinline!C:\Users\username!\footnote{If you're not sure where to put + \texttt{indentconfig.yaml}, don't worry \texttt{latexindent.pl} will tell you in the log + file exactly where to put it assuming it doesn't exist already.} \Cref{lst:indentconfig} shows a sample \texttt{indentconfig.yaml} file. \begin{yaml}{\texttt{indentconfig.yaml} (sample)}{lst:indentconfig} @@ -41,14 +41,14 @@ paths: Note that the \texttt{.yaml} files you specify in \texttt{indentconfig.yaml} will be loaded in the order in which you write them. Each file doesn't have to have every switch - from \texttt{defaultSettings.yaml}; in fact, I recommend that you only keep the switches that - you want to \emph{change} in these settings files. + from \texttt{defaultSettings.yaml}; in fact, I recommend that you only keep the switches + that you want to \emph{change} in these settings files. To get started with your own settings file, you might like to save a copy of \texttt{defaultSettings.yaml} in another directory and call it, for example, - \texttt{mysettings.yaml}. Once you have added the path to \texttt{indentconfig.yaml} you can - change the switches and add more code-block names to it as you see fit -- have a look at - \cref{lst:mysettings} for an example that uses four tabs for the default indent, adds + \texttt{mysettings.yaml}. Once you have added the path to \texttt{indentconfig.yaml} you + can change the switches and add more code-block names to it as you see fit -- have a look + at \cref{lst:mysettings} for an example that uses four tabs for the default indent, adds the \texttt{tabbing} environment/command to the list of environments that contains alignment delimiters; you might also like to refer to the many YAML files detailed throughout the rest of this documentation. @@ -67,8 +67,8 @@ lookForAlignDelims: You can make sure that your settings are loaded by checking \texttt{indent.log} for details -- if you have specified a path that \texttt{latexindent.pl} doesn't recognise then you'll get a warning, otherwise you'll get confirmation that \texttt{latexindent.pl} - has read your settings file \footnote{Windows users - may find that they have to end \texttt{.yaml} files with a blank line}. + has read your settings file \footnote{Windows users may find that they have to end + \texttt{.yaml} files with a blank line}. \index{warning!editing YAML files} \begin{warning} @@ -82,23 +82,23 @@ lookForAlignDelims: \end{warning} If you find that% - \announce*{2021-06-19}{encoding option for indentconfig.yaml} - \texttt{latexindent.pl} does not read your YAML file, then it might be as a result of the - default commandline encoding not being UTF-8; normally this will only occcur for Windows - users. In this case, you might like to explore the \texttt{encoding} option for - \texttt{indentconfig.yaml} as demonstrated in \cref{lst:indentconfig-encoding}. + \announce{2021-06-19}{encoding option for indentconfig.yaml} \texttt{latexindent.pl} does not read your YAML file, then it + might be as a result of the default commandline encoding not being UTF-8; normally this + will only occcur for Windows users. In this case, you might like to explore the + \texttt{encoding} option for \texttt{indentconfig.yaml} as demonstrated in + \cref{lst:indentconfig-encoding}. - \cmhlistingsfromfile*{demonstrations/encoding.yaml}[yaml-TCB]{The \texttt{encoding} option for \texttt{indentconfig.yaml}}{lst:indentconfig-encoding} + \cmhlistingsfromfile{demonstrations/encoding.yaml}[yaml-TCB]{The \texttt{encoding} option for \texttt{indentconfig.yaml}}{lst:indentconfig-encoding} - Thank you to \cite{qiancy98} for this contribution; please see - \vref{app:encoding} and details within \cite{encoding} for further information. + Thank you to \cite{qiancy98} for this contribution; please see \vref{app:encoding} and + details within \cite{encoding} for further information. \subsection{localSettings.yaml and friends}\label{sec:localsettings} The \texttt{-l} switch tells \texttt{latexindent.pl} to look for \texttt{localSettings.yaml} and/or friends in the \emph{same directory} as - \texttt{myfile.tex}. For% - \announce{2021-03-14}*{-l switch: localSettings and friends} - example, if you use the following command + \texttt{myfile.tex}. For% + \announce{2021-03-14}*{-l + switch: localSettings and friends} example, if you use the following command \index{switches!-l demonstration} \begin{commandshell} latexindent.pl -l myfile.tex @@ -124,9 +124,9 @@ latexindent.pl -l myfile.tex latexindent.pl -l=mysettings.yaml myfile.tex \end{commandshell} - Any settings file(s) specified using the \texttt{-l} switch will be read - \emph{after} \texttt{defaultSettings.yaml} and, assuming they exist, any user setting - files specified in \texttt{indentconfig.yaml}. + Any settings file(s) specified using the \texttt{-l} switch will be read \emph{after} + \texttt{defaultSettings.yaml} and, assuming they exist, any user setting files specified + in \texttt{indentconfig.yaml}. Your settings file can contain any switches that you'd like to change; a sample is shown in \cref{lst:localSettings}, and you'll find plenty of further examples throughout this @@ -141,44 +141,41 @@ verbatimEnvironments: myenv: 1 \end{yaml} - You can make sure that your settings file has been loaded by checking - \texttt{indent.log} for details; if it can not be read then you receive a warning, - otherwise you'll get confirmation that \texttt{latexindent.pl} has read your settings - file. + You can make sure that your settings file has been loaded by checking \texttt{indent.log} + for details; if it can not be read then you receive a warning, otherwise you'll get + confirmation that \texttt{latexindent.pl} has read your settings file. \subsection{The -y|yaml switch}\label{sec:yamlswitch} You% - \announce{2017-08-21}{demonstration of the -y switch} may use the - \texttt{-y} switch to load your settings; for example, if you wished to - specify the settings from \cref{lst:localSettings} using the \texttt{-y} - switch, then you could use the following command: + \announce{2017-08-21}{demonstration of the -y switch} + may use the \texttt{-y} switch to load your settings; for example, if you wished to + specify the settings from \cref{lst:localSettings} using the \texttt{-y} switch, then you + could use the following command: \index{verbatim!verbatimEnvironments demonstration (-y switch)} \begin{commandshell} latexindent.pl -y="verbatimEnvironments:cmhenvironment:0;myenv:1" myfile.tex \end{commandshell} - Note the use of \texttt{;} to specify another field within - \texttt{verbatimEnvironments}. This is shorthand, and equivalent, to using the following - command: + Note the use of \texttt{;} to specify another field within \texttt{verbatimEnvironments}. + This is shorthand, and equivalent, to using the following command: \index{switches!-y demonstration} \begin{commandshell} latexindent.pl -y="verbatimEnvironments:cmhenvironment:0,verbatimEnvironments:myenv:1" myfile.tex \end{commandshell} - You may, of course, specify settings using the \texttt{-y} switch as well as, - for example, settings loaded using the \texttt{-l} switch; for example, + You may, of course, specify settings using the \texttt{-y} switch as well as, for + example, settings loaded using the \texttt{-l} switch; for example, \index{switches!-l demonstration} \index{switches!-y demonstration} \begin{commandshell} latexindent.pl -l=mysettings.yaml -y="verbatimEnvironments:cmhenvironment:0;myenv:1" myfile.tex \end{commandshell} - Any settings specified using the \texttt{-y} switch will be loaded - \emph{after} any specified using \texttt{indentconfig.yaml} and the - \texttt{-l} switch. + Any settings specified using the \texttt{-y} switch will be loaded \emph{after} any + specified using \texttt{indentconfig.yaml} and the \texttt{-l} switch. If you wish to specify any regex-based settings using the \texttt{-y} switch, - \index{regular expressions!using -y switch} it is important not to use quotes surrounding the regex; for - example, with reference to the `one sentence per line' feature (\vref{sec:onesentenceperline}) - and the listings within \vref{lst:sentencesEndWith}, the following settings give the option - to have sentences end with a semicolon + \index{regular expressions!using -y switch} it is important not to use quotes surrounding + the regex; for example, with reference to the `one sentence per line' feature + (\vref{sec:onesentenceperline}) and the listings within \vref{lst:sentencesEndWith}, the + following settings give the option to have sentences end with a semicolon \index{switches!-y demonstration} \begin{commandshell} latexindent.pl -m --yaml='modifyLineBreaks:oneSentencePerLine:sentencesEndWith:other:\;' @@ -191,15 +188,16 @@ latexindent.pl -m --yaml='modifyLineBreaks:oneSentencePerLine:sentencesEndWith:o \item \texttt{defaultSettings.yaml} is always loaded, and can not be renamed; \item \texttt{anyUserSettings.yaml} and any other arbitrarily-named files specified in \texttt{indentconfig.yaml}; - \item \texttt{localSettings.yaml} but only if found in the same directory as \texttt{myfile.tex} - and called with \texttt{-l} switch; this file can be renamed, provided that - the call to \texttt{latexindent.pl} is adjusted accordingly (see \cref{sec:localsettings}). - You may specify both relative and absolute% - \announce{2017-08-21}*{-l absolute paths} paths to other YAML files using the \texttt{-l} switch, - separating multiple files using commas; + \item \texttt{localSettings.yaml} but only if found in the same directory as + \texttt{myfile.tex} + and called with \texttt{-l} switch; this file can be renamed, provided that the call to + \texttt{latexindent.pl} is adjusted accordingly (see \cref{sec:localsettings}). You may + specify both relative and absolute% + \announce{2017-08-21}*{-l absolute paths} paths to other YAML files using the \texttt{-l} + switch, separating multiple files using commas; \item any settings% - \announce{2017-08-21}{-y switch load order} specified in the - \texttt{-y} switch. + \announce{2017-08-21}{-y switch load order} + specified in the \texttt{-y} switch. \end{enumerate} A visual representation of this is given in \cref{fig:loadorder}. diff --git a/support/latexindent/documentation/sec-introduction.tex b/support/latexindent/documentation/sec-introduction.tex index 887a096887..c9915e4fcc 100644 --- a/support/latexindent/documentation/sec-introduction.tex +++ b/support/latexindent/documentation/sec-introduction.tex @@ -2,17 +2,16 @@ \section{Introduction} \subsection{Thanks} I first created \texttt{latexindent.pl} to help me format chapter files in a big project. - After I blogged about it on the \TeX{} stack exchange - \cite{cmhblog} I received some positive feedback and follow-up feature requests. - A big thank you to Harish Kumar \cite{harish} who helped to develop and test the - initial versions of the script. + After I blogged about it on the \TeX{} stack exchange \cite{cmhblog} I received some + positive feedback and follow-up feature requests. A big thank you to Harish Kumar + \cite{harish} who helped to develop and test the initial versions of the script. The \texttt{YAML}-based interface of \texttt{latexindent.pl} was inspired by the - wonderful \texttt{arara} tool; any similarities are deliberate, and I hope that - it is perceived as the compliment that it is. Thank you to Paulo Cereda and the team for + wonderful \texttt{arara} tool; any similarities are deliberate, and I hope that it is + perceived as the compliment that it is. Thank you to Paulo Cereda and the team for releasing this awesome tool; I initially worried that I was going to have to make a GUI - for \texttt{latexindent.pl}, but the release of \texttt{arara} has meant there is - no need. + for \texttt{latexindent.pl}, but the release of \texttt{arara} has meant there is no + need. There have been several contributors to the project so far (and hopefully more in the future!); thank you very much to the people detailed in \vref{sec:contributors} for their @@ -24,17 +23,17 @@ is released under the GNU General Public License v3.0. Before you start using it on any important files, bear in mind that - \texttt{latexindent.pl} has the option to overwrite your \texttt{.tex} files. It - will always make at least one backup (you can choose how many it makes, see - \cpageref{page:onlyonebackup}) but you should still be careful when using it. The script has - been tested on many files, but there are some known limitations (see - \cref{sec:knownlimitations}). You, the user, are responsible for ensuring that you maintain - backups of your files before running \texttt{latexindent.pl} on them. I think it is - important at this stage to restate an important part of the license here: + \texttt{latexindent.pl} has the option to overwrite your \texttt{.tex} files. It will + always make at least one backup (you can choose how many it makes, see + \cpageref{page:onlyonebackup}) but you should still be careful when using it. The script + has been tested on many files, but there are some known limitations (see + \cref{sec:knownlimitations}). You, the user, are responsible for ensuring that you + maintain backups of your files before running \texttt{latexindent.pl} on them. I think it + is important at this stage to restate an important part of the license here: \begin{quote}\itshape This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. \end{quote} There is certainly no malicious intent in releasing this script, and I do hope that it @@ -101,16 +100,16 @@ % \begin{latexonly} You will occasionally see dates shown in the margin (for example, next to this paragraph!)% - \announce{2017-06-25}{announce} which detail the date - of the version in which the feature was implemented; the `N' stands for `new as of the - date shown' and `U' stands for `updated as of the date shown'. If you see \stardemo, it - means that the feature is either new (N) or updated (U) as of the release of the current - version; if you see \stardemo\, attached to a listing, then it means that listing is new - (N) or updated (U) as of the current version. If you have not read this document before - (and even if you have!), then you can ignore every occurrence of the \stardemo; they are - simply there to highlight new and updated features. The new and updated features in this - documentation (\gitRel) are on the following pages: \listOfNewFeatures - % \end{latexonly} + \announce{2017-06-25}{announce} which detail + the date of the version in which the feature was implemented; the `N' stands for `new as + of the date shown' and `U' stands for `updated as of the date shown'. If you see + \stardemo, it means that the feature is either new (N) or updated (U) as of the release + of the current version; if you see \stardemo\, attached to a listing, then it means that + listing is new (N) or updated (U) as of the current version. If you have not read this + document before (and even if you have!), then you can ignore every occurrence of the + \stardemo; they are simply there to highlight new and updated features. The new and + updated features in this documentation (\gitRel) are on the following pages: + \listOfNewFeatures % \end{latexonly} \subsection{Quick start}\label{sec:quickstart} If you'd like to get started with \texttt{latexindent.pl} then simply type @@ -128,12 +127,13 @@ BEGIN failed--compilation aborted at helloworld.pl line 10. \begin{commandshell} perl latexindent-module-installer.pl \end{commandshell} - You might also like to see \href{https://stackoverflow.com/questions/19590042/error-cant-locate-file-homedir-pm-in-inc}{https://stackoverflow.com/questions/19590042/error-cant-locate-file-homedir-pm-in-inc}, for example, as well as - \vref{sec:requiredmodules}. + You might also like to see + \href{https://stackoverflow.com/questions/19590042/error-cant-locate-file-homedir-pm-in-inc}{https://stackoverflow.com/questions/19590042/error-cant-locate-file-homedir-pm-in-inc}, + for example, as well as \vref{sec:requiredmodules}. \subsection{A word about regular expressions} \index{regular expressions!a word about} - As you read this documentation, you may encounter the term \emph{regular expressions}. I've - tried to write this documentation in such a way so as to allow you to engage with them or - not, as you prefer. This documentation is not designed to be a guide to regular + As you read this documentation, you may encounter the term \emph{regular expressions}. + I've tried to write this documentation in such a way so as to allow you to engage with + them or not, as you prefer. This documentation is not designed to be a guide to regular expressions, and if you'd like to read about them, I recommend \cite{masteringregexp}. diff --git a/support/latexindent/documentation/sec-replacements.tex b/support/latexindent/documentation/sec-replacements.tex index 4362f34720..a31ad0721b 100644 --- a/support/latexindent/documentation/sec-replacements.tex +++ b/support/latexindent/documentation/sec-replacements.tex @@ -10,16 +10,16 @@ \texttt{-rv} or \texttt{-rr} switches: \index{verbatim!rv, replacementrespectverb switch} \begin{itemize} - \item the \texttt{-r} switch will perform indentation and replacements, not - respecting verbatim code blocks; - \item the \texttt{-rv} switch will perform indentation and replacements, and - \emph{will} respect verbatim code blocks; - \item the \texttt{-rr} switch will \emph{not} perform indentation, and - will perform replacements not respecting verbatim code blocks. + \item the \texttt{-r} switch will perform indentation and replacements, not respecting verbatim + code blocks; + \item the \texttt{-rv} switch will perform indentation and replacements, and \emph{will} + respect verbatim code blocks; + \item the \texttt{-rr} switch will \emph{not} perform indentation, and will perform + replacements not respecting verbatim code blocks. \end{itemize} - We will demonstrate each of the \texttt{-r}, \texttt{-rv} and - \texttt{-rr} switches, but a summary is given in \cref{tab:replacementswitches}. + We will demonstrate each of the \texttt{-r}, \texttt{-rv} and \texttt{-rr} switches, but + a summary is given in \cref{tab:replacementswitches}. \begin{table}[!htb] \centering @@ -35,23 +35,22 @@ \end{tabular} \end{table} - The default value of the \texttt{replacements} field is shown in - \cref{lst:replacements}; as with all of the other fields, you are encouraged to customise - and change this as you see fit. The options in this field will \emph{only} be - considered if the \texttt{-r}, \texttt{-rv} or - \texttt{-rr} switches are active; when discussing YAML settings related to the - replacement-mode switches, we will use the style given in \cref{lst:replacements}. + The default value of the \texttt{replacements} field is shown in \cref{lst:replacements}; + as with all of the other fields, you are encouraged to customise and change this as you + see fit. The options in this field will \emph{only} be considered if the \texttt{-r}, + \texttt{-rv} or \texttt{-rr} switches are active; when discussing YAML settings related + to the replacement-mode switches, we will use the style given in \cref{lst:replacements}. \cmhlistingsfromfile[style=replacements]*{../defaultSettings.yaml}[width=0.95\linewidth,before=\centering,replace-TCB]{\texttt{replacements}}{lst:replacements} - The first entry within the \texttt{replacements} field is \texttt{amalgamate}, and - is \emph{optional}; by default it is set to 1, so that replacements will be - amalgamated from each settings file that you specify. As you'll see in the demonstrations - that follow, there is no need to specify this field. + The first entry within the \texttt{replacements} field is \texttt{amalgamate}, and is + \emph{optional}; by default it is set to 1, so that replacements will be amalgamated from + each settings file that you specify. As you'll see in the demonstrations that follow, + there is no need to specify this field. You'll notice that, by default, there is only \emph{one} entry in the - \texttt{replacements} field, but it can take as many entries as you would like; each - one needs to begin with a \texttt{-} on its own line. + \texttt{replacements} field, but it can take as many entries as you would like; each one + needs to begin with a \texttt{-} on its own line. \subsection{Introduction to replacements} Let's explore the action of the default settings, and then we'll demonstrate the feature @@ -71,8 +70,8 @@ latexindent.pl -r replace1.tex \end{cmhtcbraster} If we don't wish to perform this replacement, then we can tweak the default settings of - \vref{lst:replacements} by changing \texttt{lookForThis} to 0; we perform this action - in \cref{lst:replace1-yaml}, and run the command + \vref{lst:replacements} by changing \texttt{lookForThis} to 0; we perform this action in + \cref{lst:replace1-yaml}, and run the command \index{switches!-l demonstration} \index{switches!-r demonstration} \begin{commandshell} @@ -85,19 +84,19 @@ latexindent.pl -r replace1.tex -l=replace1.yaml \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/replace1.yaml}[replace-TCB]{\texttt{replace1.yaml}}{lst:replace1-yaml} \end{cmhtcbraster} - Note that in \cref{lst:replace1-yaml} we have specified \texttt{amalgamate} as 0 so - that the default replacements are overwritten. + Note that in \cref{lst:replace1-yaml} we have specified \texttt{amalgamate} as 0 so that + the default replacements are overwritten. - We haven't yet discussed the \texttt{when} field; don't worry, we'll get to it - as part of the discussion in what follows. + We haven't yet discussed the \texttt{when} field; don't worry, we'll get to it as part of + the discussion in what follows. \subsection{The two types of replacements} There are two types of replacements: \begin{enumerate} \item \emph{string}-based replacements, which replace the string in \emph{this} with the string in \emph{that}. - If you specify \texttt{this} and you do not specify \texttt{that}, then - the \texttt{that} field will be assumed to be empty. + If you specify \texttt{this} and you do not specify \texttt{that}, then the \texttt{that} + field will be assumed to be empty. \index{regular expressions!replacement switch, -r} \item \emph{regex}-based replacements, which use the \texttt{substitution} field. \end{enumerate} @@ -105,8 +104,8 @@ latexindent.pl -r replace1.tex -l=replace1.yaml \texttt{latexindent.pl} chooses which type of replacement to make based on which fields have been specified; if the \texttt{this} field is specified, then it will make - \emph{string}-based replacements, regardless of if \texttt{substitution} is - present or not. + \emph{string}-based replacements, regardless of if \texttt{substitution} is present or + not. \subsection{Examples of replacements} \begin{example} @@ -150,19 +149,20 @@ latexindent.pl -r colsep.tex -l=colsep1.yaml \end{cmhtcbraster} The code given in \cref{lst:colsep1} is an example of a \emph{regular expression}, which we may abbreviate to \emph{regex} - in what follows. This manual is not intended to be + in what follows. This manual is not intended to be a tutorial on regular expressions; you might like to read, for example, \cite{masteringregexp} for a detailed covering of the topic. With reference to \cref{lst:colsep1}, we do note the following: \begin{itemize} - \item the general form of the \texttt{substitution} field is \lstinline!s/regex/replacement/modifiers!. You can - place any regular expression you like within this; + \item the general form of the \texttt{substitution} field is + \lstinline!s/regex/replacement/modifiers!. You can place any regular expression you like + within this; \item we have `escaped' the backslash by using \lstinline!\\! \item we have used \lstinline!\d+! to represent \emph{at least} one digit - \item the \texttt{s} \emph{modifier} (in the \texttt{sg} at the end of the line) instructs \texttt{latexindent.pl} to - treat your file as one single line; - \item the \texttt{g} \emph{modifier} (in the \texttt{sg} at the end of the line) instructs \texttt{latexindent.pl} to - make the substitution \emph{globally} throughout your file; you might try removing - the \texttt{g} modifier from \cref{lst:colsep1} and observing the + \item the \texttt{s} \emph{modifier} (in the \texttt{sg} at the end of the line) instructs + \texttt{latexindent.pl} to treat your file as one single line; + \item the \texttt{g} \emph{modifier} (in the \texttt{sg} at the end of the line) instructs + \texttt{latexindent.pl} to make the substitution \emph{globally} throughout your file; + you might try removing the \texttt{g} modifier from \cref{lst:colsep1} and observing the difference in output. \end{itemize} You might like to see \href{https://perldoc.perl.org/perlre.html#Modifiers}{https://perldoc.perl.org/perlre.html\#Modifiers} @@ -241,12 +241,11 @@ latexindent.pl -r displaymath.tex -l=displaymath1.yaml A few notes about \cref{lst:displaymath1}: \begin{enumerate} - \item we have used the \texttt{x} modifier, which allows us to have white space - within the regex; - \item we have used a capture group, \lstinline!(.*?)! which captures the content between - the \lstinline!$$...$$! into the special variable, \lstinline!$1!; - \item we have used the content of the capture group, \lstinline!$1!, in the - replacement text. + \item we have used the \texttt{x} modifier, which allows us to have white space within the + regex; + \item we have used a capture group, \lstinline!(.*?)! which captures the content between the + \lstinline!$$...$$! into the special variable, \lstinline!$1!; + \item we have used the content of the capture group, \lstinline!$1!, in the replacement text. \end{enumerate} See \href{https://perldoc.perl.org/perlre.html#Capture-groups}{https://perldoc.perl.org/perlre.html\#Capture-groups} for a discussion of capture groups. @@ -355,11 +354,11 @@ latexindent.pl -rr verb1.tex -l=verbatim1.yaml -o=+-rr-mod1 \item in \cref{lst:verb1-mod1} indentation has been performed, and that the replacements specified in \cref{lst:verbatim1-yaml} have been performed, even within the verbatim code block; - \item in \cref{lst:verb1-rv-mod1} indentation has been performed, but that the replacements have - \emph{not} been performed within the verbatim environment, because the - \texttt{rv} switch is active; - \item in \cref{lst:verb1-rr-mod1} indentation has \emph{not} been performed, but - that replacements have been performed, not respecting the verbatim code block. + \item in \cref{lst:verb1-rv-mod1} indentation has been performed, but that the replacements + have \emph{not} been performed within the verbatim environment, because the \texttt{rv} + switch is active; + \item in \cref{lst:verb1-rr-mod1} indentation has \emph{not} been performed, but that + replacements have been performed, not respecting the verbatim code block. \end{enumerate} See the summary within \vref{tab:replacementswitches}. @@ -399,11 +398,9 @@ latexindent.pl -r amalg1.tex -l=amalg1-yaml,amalg2-yaml,amalg3-yaml We note that: \begin{enumerate} \item in \cref{lst:amalg1-mod1} the replacements from \cref{lst:amalg1-yaml} have been used; - \item in \cref{lst:amalg1-mod12} the replacements from \cref{lst:amalg1-yaml,lst:amalg2-yaml} have - \emph{both} been used, because the default value of \texttt{amalgamate} - is 1; - \item in \cref{lst:amalg1-mod123} \emph{only} the replacements from - \cref{lst:amalg3-yaml} have been used, because the value of \texttt{amalgamate} has - been set to 0. + \item in \cref{lst:amalg1-mod12} the replacements from \cref{lst:amalg1-yaml,lst:amalg2-yaml} + have \emph{both} been used, because the default value of \texttt{amalgamate} is 1; + \item in \cref{lst:amalg1-mod123} \emph{only} the replacements from \cref{lst:amalg3-yaml} have + been used, because the value of \texttt{amalgamate} has been set to 0. \end{enumerate} \end{example} diff --git a/support/latexindent/documentation/sec-the-m-switch.tex b/support/latexindent/documentation/sec-the-m-switch.tex index d8cdbe62c6..8a824987f6 100644 --- a/support/latexindent/documentation/sec-the-m-switch.tex +++ b/support/latexindent/documentation/sec-the-m-switch.tex @@ -5,8 +5,8 @@ \tikz[remember picture,overlay] { \node at (1,0){\includegraphics{logo}}; }} - All features described in this section will only be relevant if the - \texttt{-m} switch is used. + All features described in this section will only be relevant if the \texttt{-m} switch is + used. \startcontents[the-m-switch] \printcontents[the-m-switch]{}{0}{} @@ -17,16 +17,17 @@ \end{wrapfigure} \makebox[0pt][r]{% \raisebox{-\totalheight}[0pt][0pt]{% - \tikz\node[opacity=1] at (0,0) {\includegraphics[width=4cm]{logo}};}}% - As of Version 3.0, \texttt{latexindent.pl} has the \texttt{-m} - switch, which permits \texttt{latexindent.pl} to modify line breaks, according to the - specifications in the \texttt{modifyLineBreaks} field. \emph{The settings - in this field will only be considered if the \texttt{-m} switch has been used}. A - snippet of the default settings of this field is shown in \cref{lst:modifylinebreaks}. + \tikz\node[opacity=1] at (0,0) + {\includegraphics[width=4cm]{logo}};}}% + As of Version 3.0, \texttt{latexindent.pl} has the \texttt{-m} switch, which permits + \texttt{latexindent.pl} to modify line breaks, according to the specifications in the + \texttt{modifyLineBreaks} field. \emph{The settings in this field will only be considered + if the \texttt{-m} switch has been used}. A snippet of the default settings of this field + is shown in \cref{lst:modifylinebreaks}. Having read the previous paragraph, it should sound reasonable that, if you call - \texttt{latexindent.pl} using the \texttt{-m} switch, then you give - it permission to modify line breaks in your file, but let's be clear: + \texttt{latexindent.pl} using the \texttt{-m} switch, then you give it permission to + modify line breaks in your file, but let's be clear: \index{warning!the m switch} \begin{warning} @@ -37,1922 +38,26 @@ \end{warning} \yamltitle{preserveBlankLines}{0|1} - This field is directly related to \emph{poly-switches}, discussed below. By - default, it is set to \texttt{1}, which means that blank lines will be - protected from removal; however, regardless of this setting, multiple blank lines can be - condensed if \texttt{condenseMultipleBlankLinesInto} is greater than \texttt{0}, - discussed next. + This field is directly related to \emph{poly-switches}, discussed in + \cref{sec:poly-switches}. By default, it is set to \texttt{1}, which means that blank + lines will be \emph{protected} from removal; however, regardless of this setting, + multiple blank lines can be condensed if \texttt{condenseMultipleBlankLinesInto} is + greater than \texttt{0}, discussed next. \yamltitle{condenseMultipleBlankLinesInto}*{positive integer} - Assuming that this switch takes an integer value greater than - \texttt{0}, \texttt{latexindent.pl} will condense multiple blank - lines into the number of blank lines illustrated by this switch. As an example, - \cref{lst:mlb-bl} shows a sample file with blank lines; upon running + Assuming that this switch takes an integer value greater than \texttt{0}, + \texttt{latexindent.pl} will condense multiple blank lines into the number of blank lines + illustrated by this switch. As an example, \cref{lst:mlb-bl} shows a sample file with + blank lines; upon running \index{switches!-m demonstration} \begin{commandshell} -latexindent.pl myfile.tex -m +latexindent.pl myfile.tex -m -o=+-mod1 \end{commandshell} - the output is shown in \cref{lst:mlb-bl-out}; note that the multiple blank lines - have been condensed into one blank line, and note also that we have used the - \texttt{-m} switch! - - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile{demonstrations/mlb1.tex}{\texttt{mlb1.tex}}{lst:mlb-bl} - \end{minipage}% - \hfill - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile{demonstrations/mlb1-out.tex}{\texttt{mlb1.tex} out output}{lst:mlb-bl-out} - \end{minipage} - -\subsection{textWrapOptions: modifying line breaks by text wrapping}\label{subsec:textwrapping} - When the \texttt{-m} switch is active \texttt{latexindent.pl} has the - ability to wrap text using the options% - \announce{2017-05-27}{textWrapOptions} specified in the \texttt{textWrapOptions} field, see - \cref{lst:textWrapOptions}. The value of \texttt{columns} specifies the - column at which the text should be wrapped. By default, the value of - \texttt{columns} is \texttt{0}, so - \texttt{latexindent.pl} will \emph{not} wrap text; if you change it - to a value of \texttt{2} or more, then text will be wrapped after the - character in the specified column. - \index{modifying linebreaks! by text wrapping, globally} - - \cmhlistingsfromfile[style=textWrapOptions]*{../defaultSettings.yaml}[MLB-TCB,width=.85\linewidth,before=\centering]{\texttt{textWrapOptions}}{lst:textWrapOptions} - - For example, consider the file give in \cref{lst:textwrap1}. - - \begin{widepage} - \cmhlistingsfromfile{demonstrations/textwrap1.tex}{\texttt{textwrap1.tex}}{lst:textwrap1} - \end{widepage} - - Using the file \texttt{textwrap1.yaml} in \cref{lst:textwrap1-yaml}, and running - the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{commandshell} -latexindent.pl -m textwrap1.tex -o textwrap1-mod1.tex -l textwrap1.yaml -\end{commandshell} - we obtain the output in \cref{lst:textwrap1-mod1}. - - \begin{cmhtcbraster}[raster column skip=.1\linewidth] - \cmhlistingsfromfile{demonstrations/textwrap1-mod1.tex}{\texttt{textwrap1-mod1.tex}}{lst:textwrap1-mod1} - \cmhlistingsfromfile{demonstrations/textwrap1.yaml}[MLB-TCB]{\texttt{textwrap1.yaml}}{lst:textwrap1-yaml} - \end{cmhtcbraster} - - The text wrapping routine is performed \emph{after} verbatim environments - \index{verbatim!in relation to textWrapOptions} have been stored, so verbatim environments and verbatim - commands are exempt from the routine. For example, using the file in - \cref{lst:textwrap2}, - \begin{widepage} - \cmhlistingsfromfile{demonstrations/textwrap2.tex}{\texttt{textwrap2.tex}}{lst:textwrap2} - \end{widepage} - and running the following command and continuing to use \texttt{textwrap1.yaml} from - \cref{lst:textwrap1-yaml}, - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{commandshell} -latexindent.pl -m textwrap2.tex -o textwrap2-mod1.tex -l textwrap1.yaml -\end{commandshell} - then the output is as in \cref{lst:textwrap2-mod1}. - \begin{widepage} - \cmhlistingsfromfile{demonstrations/textwrap2-mod1.tex}{\texttt{textwrap2-mod1.tex}}{lst:textwrap2-mod1} - \end{widepage} - Furthermore, the text wrapping routine is performed after the trailing comments have been - stored, and they are also exempt from text wrapping. For example, using the file in - \cref{lst:textwrap3} - \begin{widepage} - \cmhlistingsfromfile{demonstrations/textwrap3.tex}{\texttt{textwrap3.tex}}{lst:textwrap3} - \end{widepage} - and running the following command and continuing to use \texttt{textwrap1.yaml} from - \cref{lst:textwrap1-yaml}, - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{commandshell} -latexindent.pl -m textwrap3.tex -o textwrap3-mod1.tex -l textwrap1.yaml -\end{commandshell} - then the output is as in \cref{lst:textwrap3-mod1}. - - \cmhlistingsfromfile{demonstrations/textwrap3-mod1.tex}{\texttt{textwrap3-mod1.tex}}{lst:textwrap3-mod1} - - The% - \announce*{2021-07-23}*{huge:overflow is now default} default value of - \texttt{huge} is \texttt{overflow}, which means that words will - \emph{not} be broken by the text wrapping routine, implemented by the - \texttt{Text::Wrap} \cite{textwrap}. There are options to change the - \texttt{huge} option for the \texttt{Text::Wrap} module to either - \texttt{wrap} or \texttt{die}. Before modifying the value of - \texttt{huge}, please bear in mind the following warning: - \index{warning!changing huge (textwrap)} - \begin{warning} - \raggedright - Changing the value of \texttt{huge} to anything other than \texttt{overflow} will slow down - \texttt{latexindent.pl} significantly when the \texttt{-m} switch is active. - - Furthermore, changing \texttt{huge} means that you may have some words \emph{or commands}(!) - split across lines in your .tex file, which may affect your output. I do not recommend - changing this field. - \end{warning} - - For example, using the settings in \cref{lst:textwrap2A-yaml,lst:textwrap2B-yaml} and running the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{commandshell} -latexindent.pl -m textwrap4.tex -o=+-mod2A -l textwrap2A.yaml -latexindent.pl -m textwrap4.tex -o=+-mod2B -l textwrap2B.yaml -\end{commandshell} - gives the respective output in \cref{lst:textwrap4-mod2A,lst:textwrap4-mod2B}. - - \begin{cmhtcbraster}[raster column skip=.1\linewidth] - \cmhlistingsfromfile{demonstrations/textwrap4-mod2A.tex}{\texttt{textwrap4-mod2A.tex}}{lst:textwrap4-mod2A} - \cmhlistingsfromfile*{demonstrations/textwrap2A.yaml}[MLB-TCB]{\texttt{textwrap2A.yaml}}{lst:textwrap2A-yaml} - - \cmhlistingsfromfile{demonstrations/textwrap4-mod2B.tex}{\texttt{textwrap4-mod2B.tex}}{lst:textwrap4-mod2B} - \cmhlistingsfromfile*{demonstrations/textwrap2B.yaml}[MLB-TCB]{\texttt{textwrap2B.yaml}}{lst:textwrap2B-yaml} - \end{cmhtcbraster} - - You can also specify the \texttt{tabstop} - field% - \announce{2020-11-06}{tabstop option for text wrap module} as an integer - value, which is passed to the text wrap module; see \cite{textwrap} for - details. Starting with the code in \cref{lst:textwrap-ts} with settings in - \cref{lst:tabstop}, and running the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{commandshell} -latexindent.pl -m textwrap-ts.tex -o=+-mod1 -l tabstop.yaml -\end{commandshell} - gives the code given in \cref{lst:textwrap-ts-mod1}. - \begin{cmhtcbraster}[raster columns=3, - raster left skip=-3.5cm, - raster right skip=-2cm, - raster column skip=.03\linewidth] - \cmhlistingsfromfile[showtabs=true]*{demonstrations/textwrap-ts.tex}{\texttt{textwrap-ts.tex}}{lst:textwrap-ts} - \cmhlistingsfromfile{demonstrations/tabstop.yaml}[MLB-TCB]{\texttt{tabstop.yaml}}{lst:tabstop} - \cmhlistingsfromfile[showtabs=true]*{demonstrations/textwrap-ts-mod1.tex}{\texttt{textwrap-ts-mod1.tex}}{lst:textwrap-ts-mod1} - \end{cmhtcbraster} - - You can specify \texttt{separator}, \texttt{break} and - \texttt{unexpand} options in your settings in analogous ways to those - demonstrated in \cref{lst:textwrap2B-yaml,lst:tabstop}, and they will be passed to the - \texttt{Text::Wrap} module. I have not found a useful reason to do this; see - \cite{textwrap} for more details. - -\subsubsection{text wrapping on a per-code-block basis} - By default, if the value of \texttt{columns} is greater than 0 and the - \texttt{-m} switch is active, then% - \announce{2018-08-13}*{updates to textWrapOptions} the text wrapping routine will operate before the code blocks - have been searched for. This behaviour is customisable; in particular, you can instead - instruct \texttt{latexindent.pl} to apply \texttt{textWrap} on a - per-code-block basis. Thanks to \cite{zoehneto} for their help in testing and - shaping this feature. - \index{modifying linebreaks! by text wrapping, per-code-block} - - The full details of \texttt{textWrapOptions} are shown in \cref{lst:textWrapOptionsAll}. - In particular, note the field \texttt{perCodeBlockBasis: 0}. - \index{specialBeginEnd!textWrapOptions} - - \cmhlistingsfromfile*[style=textWrapOptionsAll]*{../defaultSettings.yaml}[MLB-TCB,width=.85\linewidth,before=\centering]{\texttt{textWrapOptions}}{lst:textWrapOptionsAll} - - The code blocks detailed in \cref{lst:textWrapOptionsAll} are with direct reference to - those detailed in \vref{tab:code-blocks}. The only special case is the - \texttt{masterDocument} field; this is designed for `chapter'-type files that may - contain paragraphs that are not within any other code-blocks. The same notation is used - between this feature and the \texttt{removeParagraphLineBreaks} described in - \vref{lst:removeParagraphLineBreaks}; in fact, the two features can even be combined (this is - detailed in \vref{subsec:removeparagraphlinebreaks:and:textwrap}). - - Let's explore these switches with reference to the code given in - \cref{lst:textwrap5}; the text outside of the environment is considered part of - the \texttt{masterDocument}. - - \begin{widepage} - \cmhlistingsfromfile{demonstrations/textwrap5.tex}{\texttt{textwrap5.tex}}{lst:textwrap5} - \end{widepage} - - With reference to this code block, the settings given in \cref{lst:textwrap3-yaml,lst:textwrap4-yaml,lst:textwrap5-yaml} each - give the same output. - - \begin{cmhtcbraster}[raster columns=3, - raster left skip=-3.5cm, - raster right skip=-2cm, - raster column skip=.03\linewidth] - \cmhlistingsfromfile{demonstrations/textwrap3.yaml}[MLB-TCB]{\texttt{textwrap3.yaml}}{lst:textwrap3-yaml} - \cmhlistingsfromfile{demonstrations/textwrap4.yaml}[MLB-TCB]{\texttt{textwrap4.yaml}}{lst:textwrap4-yaml} - \cmhlistingsfromfile{demonstrations/textwrap5.yaml}[MLB-TCB]{\texttt{textwrap5.yaml}}{lst:textwrap5-yaml} - \end{cmhtcbraster} - - Let's explore the similarities and differences in the equivalent (with respect to - \cref{lst:textwrap5}) syntax specified in \cref{lst:textwrap3-yaml,lst:textwrap4-yaml,lst:textwrap5-yaml}: - \begin{itemize} - \item in each of \cref{lst:textwrap3-yaml,lst:textwrap4-yaml,lst:textwrap5-yaml} notice that \texttt{columns: 30}; - \item in each of \cref{lst:textwrap3-yaml,lst:textwrap4-yaml,lst:textwrap5-yaml} notice that \texttt{perCodeBlockBasis: 1}; - \item in \cref{lst:textwrap3-yaml} we have specified \texttt{all: 1} so that the - text wrapping will operate upon \emph{all} code blocks; - \item in \cref{lst:textwrap4-yaml} we have \emph{not} specified - \texttt{all}, and instead, have specified that text wrapping should be - applied to each of \texttt{environments} and \texttt{masterDocument}; - \item in \cref{lst:textwrap5-yaml} we have specified text wrapping for - \texttt{masterDocument} and on a \emph{per-name} basis for - \texttt{environments} code blocks. - \end{itemize} - - Upon running the following commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -s textwrap5.tex -l=textwrap3.yaml -m -latexindent.pl -s textwrap5.tex -l=textwrap4.yaml -m -latexindent.pl -s textwrap5.tex -l=textwrap5.yaml -m -\end{commandshell} - we obtain the output shown in \cref{lst:textwrap5-mod3}. - - \cmhlistingsfromfile{demonstrations/textwrap5-mod3.tex}{\texttt{textwrap5-mod3.tex}}{lst:textwrap5-mod3} - - We can explore the idea of per-name text wrapping given in \cref{lst:textwrap5-yaml} by - using \cref{lst:textwrap6}. - - \begin{widepage} - \cmhlistingsfromfile{demonstrations/textwrap6.tex}{\texttt{textwrap6.tex}}{lst:textwrap6} - \end{widepage} - - In particular, upon running - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -s textwrap6.tex -l=textwrap5.yaml -m -\end{commandshell} - we obtain the output given in \cref{lst:textwrap6-mod5}. - - \begin{widepage} - \cmhlistingsfromfile{demonstrations/textwrap6-mod5.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap5-yaml}}{lst:textwrap6-mod5} - \end{widepage} - - Notice that, because \texttt{environments} has been specified only for - \texttt{myenv} (in \cref{lst:textwrap5-yaml}) that the environment named \texttt{another} has - \emph{not} had text wrapping applied to it. - - The {all} field can be specified with exceptions which can either - be done on a per-code-block or per-name basis; we explore this in relation to - \cref{lst:textwrap6} in the settings given in \crefrange{lst:textwrap6-yaml}{lst:textwrap8-yaml}. - - \begin{adjustwidth}{-3.5cm}{-2.5cm} - \begin{minipage}{.33\linewidth} - \cmhlistingsfromfile{demonstrations/textwrap6.yaml}[MLB-TCB]{\texttt{textwrap6.yaml}}{lst:textwrap6-yaml} - \end{minipage}% - \begin{minipage}{.33\linewidth} - \cmhlistingsfromfile{demonstrations/textwrap7.yaml}[MLB-TCB]{\texttt{textwrap7.yaml}}{lst:textwrap7-yaml} - \end{minipage}% - \begin{minipage}{.33\linewidth} - \cmhlistingsfromfile{demonstrations/textwrap8.yaml}[MLB-TCB]{\texttt{textwrap8.yaml}}{lst:textwrap8-yaml} - \end{minipage} - \end{adjustwidth} - - Upon running the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -s textwrap6.tex -l=textwrap6.yaml -m -latexindent.pl -s textwrap6.tex -l=textwrap7.yaml -m -latexindent.pl -s textwrap6.tex -l=textwrap8.yaml -m -\end{commandshell} - we receive the respective output given in \crefrange{lst:textwrap6-mod6}{lst:textwrap6-mod8}. - \begin{widepage} - \cmhlistingsfromfile{demonstrations/textwrap6-mod6.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap6-yaml}}{lst:textwrap6-mod6} - - \cmhlistingsfromfile{demonstrations/textwrap6-mod7.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap7-yaml}}{lst:textwrap6-mod7} - - \cmhlistingsfromfile{demonstrations/textwrap6-mod8.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap8-yaml}}{lst:textwrap6-mod8} - \end{widepage} - - Notice that: - \begin{itemize} - \item in \cref{lst:textwrap6-mod6} the text wrapping routine has not been applied to any - \texttt{environments} because it has been switched off (per-code-block) in - \cref{lst:textwrap6-yaml}; - \item in \cref{lst:textwrap6-mod7} the text wrapping routine has not been applied to - \texttt{myenv} because it has been switched off (per-name) in - \cref{lst:textwrap7-yaml}; - \item in \cref{lst:textwrap6-mod8} the text wrapping routine has not been applied to - \texttt{masterDocument} because of the settings in \cref{lst:textwrap8-yaml}. - \end{itemize} - - The \texttt{columns} field has a variety of different ways that it can be - specified; we've seen two basic ways already: the default (set to - \texttt{0}) and a positive integer (see \vref{lst:textwrap6}, for - example). We explore further options in \crefrange{lst:textwrap9-yaml}{lst:textwrap11-yaml}. - - \begin{cmhtcbraster}[raster columns=3, - raster left skip=-3.5cm, - raster right skip=-2cm, - raster column skip=.03\linewidth] - \cmhlistingsfromfile{demonstrations/textwrap9.yaml}[MLB-TCB]{\texttt{textwrap9.yaml}}{lst:textwrap9-yaml} - \cmhlistingsfromfile{demonstrations/textwrap10.yaml}[MLB-TCB]{\texttt{textwrap10.yaml}}{lst:textwrap10-yaml} - \cmhlistingsfromfile{demonstrations/textwrap11.yaml}[MLB-TCB]{\texttt{textwrap11.yaml}}{lst:textwrap11-yaml} - \end{cmhtcbraster} - - \Cref{lst:textwrap9-yaml} and \cref{lst:textwrap10-yaml} are equivalent. Upon running - the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -s textwrap6.tex -l=textwrap9.yaml -m -latexindent.pl -s textwrap6.tex -l=textwrap11.yaml -m -\end{commandshell} - we receive the respective output given in \cref{lst:textwrap6-mod9,lst:textwrap6-mod11}. - - \begin{widepage} - \cmhlistingsfromfile{demonstrations/textwrap6-mod9.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap9-yaml}}{lst:textwrap6-mod9} - - \cmhlistingsfromfile*{demonstrations/textwrap6-mod11.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap11-yaml}}{lst:textwrap6-mod11} - \end{widepage} - - Notice that: - \begin{itemize} - \item in \cref{lst:textwrap6-mod9} the text for the \texttt{masterDocument} has been - wrapped using \texttt{30} columns, while \texttt{environments} has - been wrapped using \texttt{50} columns; - \item in \cref{lst:textwrap6-mod11} the text for \texttt{myenv} has been wrapped - using \texttt{50} columns, the text for \texttt{another} has - been wrapped using \texttt{15} columns, and \texttt{masterDocument} - has been wrapped using \texttt{30} columns. - \end{itemize} - If you don't specify a \texttt{default} value on per-code-block basis, then - the \texttt{default} value from \texttt{columns} will be inherited; - if you don't specify a default value for \texttt{columns} then - \texttt{80} will be used. - - \texttt{alignAtAmpersandTakesPriority} is set to \texttt{1} by default; assuming - that text wrapping is occurring on a per-code-block basis, and the current - environment/code block is specified within \vref{lst:aligndelims:basic} then text wrapping - will be disabled for this code block. - - If you wish to specify \texttt{afterHeading} commands (see - \vref{lst:indentAfterHeadings}) on a per-name basis, then you need to append the name with - \texttt{:heading}, for example, you might use \texttt{section:heading}. - -\subsubsection{Summary of text wrapping} - It is important to note the following: - \index{verbatim!within summary of text wrapping} - \begin{itemize} - \item Verbatim environments (\vref{lst:verbatimEnvironments}) and verbatim commands - (\vref{lst:verbatimCommands}) will \emph{not} be affected by the text - wrapping routine (see \vref{lst:textwrap2-mod1}); - \item comments will \emph{not} be affected by the text wrapping routine (see - \vref{lst:textwrap3-mod1}); - \item it is possible to wrap text on a per-code-block and a per-name basis; - \announce{2018-08-13}*{updates to textWrapOptions} - \item the text wrapping routine sets \texttt{preserveBlankLines} as - \texttt{1}; - \item indentation is performed \emph{after} the text wrapping routine; as such, - indented code will likely exceed any maximum value set in the \texttt{columns} - field. - \end{itemize} - -\subsection{oneSentencePerLine: modifying line breaks for sentences}\label{sec:onesentenceperline} - You can instruct \texttt{latexindent.pl} to - format% - \announce{2018-01-13}{one sentence per line} your file so that - it puts one sentence per line. Thank you to \cite{mlep} for helping to - shape and test this feature. The behaviour of this part of the script is controlled by - the switches detailed in \cref{lst:oneSentencePerLine}, all of which we discuss next. - \index{modifying linebreaks! by using one sentence per line} - \index{sentences!oneSentencePerLine} - \index{sentences!one sentence per line} - \index{regular expressions!lowercase alph a-z} - \index{regular expressions!uppercase alph A-Z} - - \cmhlistingsfromfile[style=oneSentencePerLine]*{../defaultSettings.yaml}[MLB-TCB,width=.85\linewidth,before=\centering]{\texttt{oneSentencePerLine}}{lst:oneSentencePerLine} - -\yamltitle{manipulateSentences}{0|1} - This is a binary switch that details if \texttt{latexindent.pl} should perform the - sentence manipulation routine; it is \emph{off} (set to \texttt{0}) by default, and you will - need to turn it on (by setting it to \texttt{1}) if you want the script - to modify line breaks surrounding and within sentences. - -\yamltitle{removeSentenceLineBreaks}{0|1} - When operating upon sentences \texttt{latexindent.pl} will, by default, remove - internal line breaks as \texttt{removeSentenceLineBreaks} is set to - \texttt{1}. Setting this switch to \texttt{0} instructs - \texttt{latexindent.pl} not to do so. - \index{sentences!removing sentence line breaks} - - For example, consider \texttt{multiple-sentences.tex} shown in \cref{lst:multiple-sentences}. - - \cmhlistingsfromfile{demonstrations/multiple-sentences.tex}{\texttt{multiple-sentences.tex}}{lst:multiple-sentences} - - If we use the YAML files in \cref{lst:manipulate-sentences-yaml,lst:keep-sen-line-breaks-yaml}, and run the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl multiple-sentences -m -l=manipulate-sentences.yaml -latexindent.pl multiple-sentences -m -l=keep-sen-line-breaks.yaml -\end{commandshell} - \end{widepage} - then we obtain the respective output given in \cref{lst:multiple-sentences-mod1,lst:multiple-sentences-mod2}. - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/multiple-sentences-mod1.tex}{\texttt{multiple-sentences.tex} using \cref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences-mod1} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/manipulate-sentences.yaml}[MLB-TCB]{\texttt{manipulate-sentences.yaml}}{lst:manipulate-sentences-yaml} - \end{cmhtcbraster} - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/multiple-sentences-mod2.tex}{\texttt{multiple-sentences.tex} using \cref{lst:keep-sen-line-breaks-yaml}}{lst:multiple-sentences-mod2} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/keep-sen-line-breaks.yaml}[MLB-TCB]{\texttt{keep-sen-line-breaks.yaml}}{lst:keep-sen-line-breaks-yaml} - \end{cmhtcbraster} - - Notice, in particular, that the `internal' sentence line breaks in - \cref{lst:multiple-sentences} have been removed in \cref{lst:multiple-sentences-mod1}, but have - not been removed in \cref{lst:multiple-sentences-mod2}. - - The remainder of the settings displayed in \vref{lst:oneSentencePerLine} instruct - \texttt{latexindent.pl} on how to define a sentence. From the perspective of - \texttt{latexindent.pl} a sentence must: - \index{sentences!follow} - \index{sentences!begin with} - \index{sentences!end with} - \begin{itemize} - \item \emph{follow} a certain character or set of characters (see - \cref{lst:sentencesFollow}); by default, this is either \lstinline!\par!, a - blank line, a full stop/period (.), exclamation mark (!), question mark (?) right brace - (\}) or a comment on the previous line; - \item \emph{begin} with a character type (see \cref{lst:sentencesBeginWith}); by - default, this is only capital letters; - \item \emph{end} with a character (see \cref{lst:sentencesEndWith}); by - default, these are full stop/period (.), exclamation mark (!) and question mark (?). - \end{itemize} - In each case, you can specify the \texttt{other} field to include any - pattern that you would like; you can specify anything in this field using the language of - regular expressions. - \index{regular expressions!lowercase alph a-z} - \index{regular expressions!uppercase alph A-Z} - - \begin{cmhtcbraster}[raster columns=3, - raster left skip=-3.5cm, - raster right skip=-2cm, - raster column skip=.06\linewidth] - \cmhlistingsfromfile[style=sentencesFollow]*{../defaultSettings.yaml}[MLB-TCB,width=.9\linewidth,before=\centering]{\texttt{sentencesFollow}}{lst:sentencesFollow} - \cmhlistingsfromfile[style=sentencesBeginWith]*{../defaultSettings.yaml}[MLB-TCB,width=.9\linewidth,before=\centering]{\texttt{sentencesBeginWith}}{lst:sentencesBeginWith} - \cmhlistingsfromfile[style=sentencesEndWith]*{../defaultSettings.yaml}[MLB-TCB,width=.9\linewidth,before=\centering]{\texttt{sentencesEndWith}}{lst:sentencesEndWith} - \end{cmhtcbraster} - -\subsubsection{sentencesFollow} - Let's explore a few of the switches in \texttt{sentencesFollow}; let's start with - \vref{lst:multiple-sentences}, and use the YAML settings given in - \cref{lst:sentences-follow1-yaml}. Using the command - \index{sentences!follow} - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl multiple-sentences -m -l=sentences-follow1.yaml -\end{commandshell} - we obtain the output given in \cref{lst:multiple-sentences-mod3}. - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/multiple-sentences-mod3.tex}{\texttt{multiple-sentences.tex} using \cref{lst:sentences-follow1-yaml}}{lst:multiple-sentences-mod3} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-follow1.yaml}[MLB-TCB]{\texttt{sentences-follow1.yaml}}{lst:sentences-follow1-yaml} - \end{cmhtcbraster} - - Notice that, because \texttt{blankLine} is set to \texttt{0}, - \texttt{latexindent.pl} will not seek sentences following a blank line, and so the - fourth sentence has not been accounted for. - - We can explore the \texttt{other} field in \cref{lst:sentencesFollow} with - the \texttt{.tex} file detailed in \cref{lst:multiple-sentences1}. - - \cmhlistingsfromfile{demonstrations/multiple-sentences1.tex}{\texttt{multiple-sentences1.tex}}{lst:multiple-sentences1} - - Upon running the following commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl multiple-sentences1 -m -l=manipulate-sentences.yaml -latexindent.pl multiple-sentences1 -m -l=manipulate-sentences.yaml,sentences-follow2.yaml -\end{commandshell} - \end{widepage} - then we obtain the respective output given in \cref{lst:multiple-sentences1-mod1,lst:multiple-sentences1-mod2}. - \cmhlistingsfromfile{demonstrations/multiple-sentences1-mod1.tex}{\texttt{multiple-sentences1.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences1-mod1} - - \begin{cmhtcbraster}[ - raster force size=false, - raster column 1/.style={add to width=1cm}, - ] - \cmhlistingsfromfile{demonstrations/multiple-sentences1-mod2.tex}{\texttt{multiple-sentences1.tex} using \cref{lst:sentences-follow2-yaml}}{lst:multiple-sentences1-mod2} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-follow2.yaml}[MLB-TCB,width=.45\textwidth]{\texttt{sentences-follow2.yaml}}{lst:sentences-follow2-yaml} - \end{cmhtcbraster} - - Notice that in \cref{lst:multiple-sentences1-mod1} the first sentence after the - \texttt{)} has not been accounted for, but that following the inclusion - of \cref{lst:sentences-follow2-yaml}, the output given in \cref{lst:multiple-sentences1-mod2} - demonstrates that the sentence \emph{has} been accounted for correctly. - -\subsubsection{sentencesBeginWith} - By default, \texttt{latexindent.pl} will only assume that sentences begin with the - upper case letters \texttt{A-Z}; you can instruct the script to define - sentences to begin with lower case letters (see \cref{lst:sentencesBeginWith}), and we can - use the \texttt{other} field to define sentences to begin with other - characters. - \index{sentences!begin with} - - \cmhlistingsfromfile{demonstrations/multiple-sentences2.tex}{\texttt{multiple-sentences2.tex}}{lst:multiple-sentences2} - - Upon running the following commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl multiple-sentences2 -m -l=manipulate-sentences.yaml -latexindent.pl multiple-sentences2 -m -l=manipulate-sentences.yaml,sentences-begin1.yaml -\end{commandshell} - \end{widepage} - then we obtain the respective output given in \cref{lst:multiple-sentences2-mod1,lst:multiple-sentences2-mod2}. - \cmhlistingsfromfile{demonstrations/multiple-sentences2-mod1.tex}{\texttt{multiple-sentences2.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences2-mod1} - \index{regular expressions!numeric 0-9} - - \begin{cmhtcbraster}[ - raster force size=false, - raster column 1/.style={add to width=1cm}, - ] - \cmhlistingsfromfile{demonstrations/multiple-sentences2-mod2.tex}{\texttt{multiple-sentences2.tex} using \cref{lst:sentences-begin1-yaml}}{lst:multiple-sentences2-mod2} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-begin1.yaml}[MLB-TCB,width=.45\textwidth]{\texttt{sentences-begin1.yaml}}{lst:sentences-begin1-yaml} - \end{cmhtcbraster} - Notice that in \cref{lst:multiple-sentences2-mod1}, the first sentence has been accounted for but - that the subsequent sentences have not. In \cref{lst:multiple-sentences2-mod2}, all of the - sentences have been accounted for, because the \texttt{other} field in - \cref{lst:sentences-begin1-yaml} has defined sentences to begin with either - \lstinline!$! or any numeric digit, \texttt{0} to - \texttt{9}. - -\subsubsection{sentencesEndWith} - Let's return to \vref{lst:multiple-sentences}; we have already seen the default way in - which \texttt{latexindent.pl} will operate on the sentences in this file in - \vref{lst:multiple-sentences-mod1}. We can populate the \texttt{other} field with - any character that we wish; for example, using the YAML specified in - \cref{lst:sentences-end1-yaml} and the command - \index{sentences!end with} - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl multiple-sentences -m -l=sentences-end1.yaml -latexindent.pl multiple-sentences -m -l=sentences-end2.yaml -\end{commandshell} - then we obtain the output in \cref{lst:multiple-sentences-mod4}. - \index{regular expressions!lowercase alph a-z} - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/multiple-sentences-mod4.tex}{\texttt{multiple-sentences.tex} using \cref{lst:sentences-end1-yaml}}{lst:multiple-sentences-mod4} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-end1.yaml}[MLB-TCB]{\texttt{sentences-end1.yaml}}{lst:sentences-end1-yaml} - \end{cmhtcbraster} - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/multiple-sentences-mod5.tex}{\texttt{multiple-sentences.tex} using \cref{lst:sentences-end2-yaml}}{lst:multiple-sentences-mod5} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-end2.yaml}[MLB-TCB]{\texttt{sentences-end2.yaml}}{lst:sentences-end2-yaml} - \end{cmhtcbraster} - - There is a subtle difference between the output in \cref{lst:multiple-sentences-mod4,lst:multiple-sentences-mod5}; in - particular, in \cref{lst:multiple-sentences-mod4} the word \texttt{sentence} has not - been defined as a sentence, because we have not instructed \texttt{latexindent.pl} to - begin sentences with lower case letters. We have changed this by using the settings in - \cref{lst:sentences-end2-yaml}, and the associated output in \cref{lst:multiple-sentences-mod5} - reflects this. - - Referencing \vref{lst:sentencesEndWith}, you'll notice that there is a field called - \texttt{basicFullStop}, which is set to \texttt{0}, and that the - \texttt{betterFullStop} is set to \texttt{1} by default. - - Let's consider the file shown in \cref{lst:url}. - - \cmhlistingsfromfile{demonstrations/url.tex}{\texttt{url.tex}}{lst:url} - - Upon running the following commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl url -m -l=manipulate-sentences.yaml -\end{commandshell} - we obtain the output given in \cref{lst:url-mod1}. - - \cmhlistingsfromfile{demonstrations/url-mod1.tex}{\texttt{url.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:url-mod1} - - Notice that the full stop within the url has been interpreted correctly. This is because, - within the \texttt{betterFullStop}, full stops at the end of sentences have the - following properties: - \begin{itemize} - \item they are ignored within \texttt{e.g.} and \texttt{i.e.}; - \item they can not be immediately followed by a lower case or upper case letter; - \item they can not be immediately followed by a hyphen, comma, or number. - \end{itemize} - If you find that the \texttt{betterFullStop} does not work for your purposes, then - you can switch it off by setting it to \texttt{0}, and you can - experiment with the \texttt{other} - field.% - \announce{2019-07-13}{fine tuning the betterFullStop} You can also seek - to customise the \texttt{betterFullStop} routine by using the - \emph{fine tuning}, detailed in \vref{lst:fineTuning}. - - The \texttt{basicFullStop} routine should probably be avoided in most situations, as - it does not accommodate the specifications above. For example, using the following - command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl url -m -l=alt-full-stop1.yaml -\end{commandshell} - and the YAML in \cref{lst:alt-full-stop1-yaml} gives the output in - \cref{lst:url-mod2}. - - \begin{cmhtcbraster}[ raster left skip=-3.5cm, - raster right skip=-2cm, - raster force size=false, - raster column 1/.style={add to width=.1\textwidth}, - raster column skip=.06\linewidth] - \cmhlistingsfromfile{demonstrations/url-mod2.tex}{\texttt{url.tex} using \cref{lst:alt-full-stop1-yaml}}{lst:url-mod2} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/alt-full-stop1.yaml}[MLB-TCB,width=.5\textwidth]{\texttt{alt-full-stop1.yaml}}{lst:alt-full-stop1-yaml} - \end{cmhtcbraster} - - Notice that the full stop within the URL has not been accommodated correctly because of - the non-default settings in \cref{lst:alt-full-stop1-yaml}. - -\subsubsection{Features of the oneSentencePerLine routine} - The sentence manipulation routine takes place \emph{after} verbatim - \index{verbatim!in relation to oneSentencePerLine} environments, preamble and trailing comments have been - accounted for; this means that any characters within these types of code blocks will not - be part of the sentence manipulation routine. - - For example, if we begin with the \texttt{.tex} file in - \cref{lst:multiple-sentences3}, and run the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl multiple-sentences3 -m -l=manipulate-sentences.yaml -\end{commandshell} - then we obtain the output in \cref{lst:multiple-sentences3-mod1}. \cmhlistingsfromfile{demonstrations/multiple-sentences3.tex}{\texttt{multiple-sentences3.tex}}{lst:multiple-sentences3} - \cmhlistingsfromfile{demonstrations/multiple-sentences3-mod1.tex}{\texttt{multiple-sentences3.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences3-mod1} - - Furthermore, if sentences run across environments then, by default, the line breaks - internal to the sentence will be removed. For example, if we use the - \texttt{.tex} file in \cref{lst:multiple-sentences4} and run the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl multiple-sentences4 -m -l=manipulate-sentences.yaml -latexindent.pl multiple-sentences4 -m -l=keep-sen-line-breaks.yaml -\end{commandshell} - then we obtain the output in \cref{lst:multiple-sentences4-mod1,lst:multiple-sentences4-mod2}. \cmhlistingsfromfile{demonstrations/multiple-sentences4.tex}{\texttt{multiple-sentences4.tex}}{lst:multiple-sentences4} - \begin{widepage} - \cmhlistingsfromfile{demonstrations/multiple-sentences4-mod1.tex}{\texttt{multiple-sentences4.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences4-mod1} - \end{widepage} - \cmhlistingsfromfile{demonstrations/multiple-sentences4-mod2.tex}{\texttt{multiple-sentences4.tex} using \vref{lst:keep-sen-line-breaks-yaml}}{lst:multiple-sentences4-mod2} - Once you've read \cref{sec:poly-switches}, you will know that you can accommodate the - removal of internal sentence line breaks by using the YAML in \cref{lst:item-rules2-yaml} - and the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl multiple-sentences4 -m -l=item-rules2.yaml -\end{commandshell} - the output of which is shown in \cref{lst:multiple-sentences4-mod3}. - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/multiple-sentences4-mod3.tex}{\texttt{multiple-sentences4.tex} using \cref{lst:item-rules2-yaml}}{lst:multiple-sentences4-mod3} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/item-rules2.yaml}[MLB-TCB]{\texttt{item-rules2.yaml}}{lst:item-rules2-yaml} - \end{cmhtcbraster} - -\subsubsection{text wrapping and indenting sentences} - The \texttt{oneSentencePerLine}% - \announce{2018-08-13}{oneSentencePerline text wrap and indent} can be instructed to perform - text wrapping and indentation upon sentences. - \index{sentences!text wrapping} - \index{sentences!indenting} - - Let's use the code in \cref{lst:multiple-sentences5}. - - \cmhlistingsfromfile{demonstrations/multiple-sentences5.tex}{\texttt{multiple-sentences5.tex}}{lst:multiple-sentences5} - - Referencing \cref{lst:sentence-wrap1-yaml}, and running the following command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl multiple-sentences5 -m -l=sentence-wrap1.yaml -\end{commandshell} - we receive the output given in \cref{lst:multiple-sentences5-mod1}. - - \begin{cmhtcbraster}[ raster left skip=-3.5cm, - raster right skip=-2cm, - raster force size=false, - raster column 1/.style={add to width=.1\textwidth}, - raster column skip=.06\linewidth] - \cmhlistingsfromfile{demonstrations/multiple-sentences5-mod1.tex}{\texttt{multiple-sentences5.tex} using \cref{lst:sentence-wrap1-yaml}}{lst:multiple-sentences5-mod1} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentence-wrap1.yaml}[MLB-TCB,width=0.5\textwidth]{\texttt{sentence-wrap1.yaml}}{lst:sentence-wrap1-yaml} - \end{cmhtcbraster} - - If you wish to specify the \texttt{columns} field on a per-code-block basis - for sentences, then you would use \texttt{sentence}; explicitly, starting with - \vref{lst:textwrap9-yaml}, for example, you would replace/append - \texttt{environments} with, for example, \texttt{sentence: 50}. - - If you specify \texttt{textWrapSentences} as 1, but do \emph{not} - specify a value for \texttt{columns} then the text wrapping will - \emph{not} operate on sentences, and you will see a warning in - \texttt{indent.log}. - - The indentation of sentences requires that sentences are stored as code blocks. This - means that you may need to tweak \vref{lst:sentencesEndWith}. Let's explore this in - relation to \cref{lst:multiple-sentences6}. - - \cmhlistingsfromfile{demonstrations/multiple-sentences6.tex}{\texttt{multiple-sentences6.tex}}{lst:multiple-sentences6} - - By default, \texttt{latexindent.pl} will find the full-stop within the first - \texttt{item}, which means that, upon running the following commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-y demonstration} - \begin{commandshell} -latexindent.pl multiple-sentences6 -m -l=sentence-wrap1.yaml -latexindent.pl multiple-sentences6 -m -l=sentence-wrap1.yaml -y="modifyLineBreaks:oneSentencePerLine:sentenceIndent:''" -\end{commandshell} - we receive the respective output in \cref{lst:multiple-sentences6-mod1} and - \cref{lst:multiple-sentences6-mod2}. - - \cmhlistingsfromfile{demonstrations/multiple-sentences6-mod1.tex}{\texttt{multiple-sentences6-mod1.tex} using \cref{lst:sentence-wrap1-yaml}}{lst:multiple-sentences6-mod1} - - \cmhlistingsfromfile{demonstrations/multiple-sentences6-mod2.tex}{\texttt{multiple-sentences6-mod2.tex} using \cref{lst:sentence-wrap1-yaml} and no sentence indentation}{lst:multiple-sentences6-mod2} - - We note that \cref{lst:multiple-sentences6-mod1} the \texttt{itemize} code block has - \emph{not} been indented appropriately. This is because the - oneSentencePerLine has been instructed to store sentences (because - \cref{lst:sentence-wrap1-yaml}); each sentence is then searched for code blocks. - - We can tweak the settings in \vref{lst:sentencesEndWith} to ensure that full stops are - not followed by \texttt{item} commands, and that the end of sentences - contains \lstinline!\end{itemize}! as in \cref{lst:itemize-yaml} (if you intend to use this, ensure that you - remove the line breaks from the \texttt{other} field). - \index{regular expressions!lowercase alph a-z} - \index{regular expressions!uppercase alph A-Z} - \index{regular expressions!numeric 0-9} - \index{regular expressions!horizontal space \textbackslash{h}} - - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/itemized.yaml}[MLB-TCB]{\texttt{itemize.yaml}}{lst:itemize-yaml} - - Upon running - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl multiple-sentences6 -m -l=sentence-wrap1.yaml,itemize.yaml -\end{commandshell} - we receive the output in \cref{lst:multiple-sentences6-mod3}. - - \cmhlistingsfromfile{demonstrations/multiple-sentences6-mod3.tex}{\texttt{multiple-sentences6-mod3.tex} using \cref{lst:sentence-wrap1-yaml} and \cref{lst:itemize-yaml}}{lst:multiple-sentences6-mod3} - - Notice that the sentence has received indentation, and that the - \texttt{itemize} code block has been found and indented correctly. - -\subsection{removeParagraphLineBreaks: modifying line breaks for paragraphs}\label{subsec:removeparagraphlinebreaks} - When the \texttt{-m} switch is active \texttt{latexindent.pl} has the - ability to remove line breaks% - \announce{2017-05-27}{removeParagraphLineBreaks} from within paragraphs; the behaviour is controlled by the - \texttt{removeParagraphLineBreaks} field, detailed in \cref{lst:removeParagraphLineBreaks}. Thank you to - \cite{jowens} for shaping and assisting with the testing of this feature. -\yamltitle{removeParagraphLineBreaks}*{fields} - This feature is considered complimentary to the \texttt{oneSentencePerLine} feature - described in \vref{sec:onesentenceperline}. - \index{specialBeginEnd!removeParagraphLineBreaks} - - \cmhlistingsfromfile[style=removeParagraphLineBreaks]*{../defaultSettings.yaml}[MLB-TCB,width=.85\linewidth,before=\centering]{\texttt{removeParagraphLineBreaks}}{lst:removeParagraphLineBreaks} - - This routine can be turned on \emph{globally} for \emph{every} - code block type known to \texttt{latexindent.pl} - (see \vref{tab:code-blocks}) by using the - \texttt{all} switch; by default, this switch is - \emph{off}. Assuming that the \texttt{all} switch is off, - then the routine can be controlled on a per-code-block-type basis, and within that, on a - per-name basis. We will consider examples of each of these in turn, but before we do, - let's specify what \texttt{latexindent.pl} considers as a paragraph: - \begin{itemize} - \item it must begin on its own line with either an alphabetic or numeric character, and not - with any of the code-block types detailed in \vref{tab:code-blocks}; - \item it can include line breaks, but finishes when it meets either a blank line, a - \lstinline!\par! command, or any of the user-specified settings in the - \texttt{paragraphsStopAt} field, detailed in \vref{lst:paragraphsStopAt}. - \end{itemize} - - Let's start with the \texttt{.tex} file in \cref{lst:shortlines}, - together with the YAML settings in \cref{lst:remove-para1-yaml}. - - \begin{cmhtcbraster} - \cmhlistingsfromfile[showspaces=true]{demonstrations/shortlines.tex}{\texttt{shortlines.tex}}{lst:shortlines} - \cmhlistingsfromfile{demonstrations/remove-para1.yaml}[MLB-TCB]{\texttt{remove-para1.yaml}}{lst:remove-para1-yaml} - \end{cmhtcbraster} - - Upon running the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{commandshell} -latexindent.pl -m shortlines.tex -o shortlines1.tex -l remove-para1.yaml -\end{commandshell} - then we obtain the output given in \cref{lst:shortlines1}. - - \cmhlistingsfromfile[showspaces=true]{demonstrations/shortlines1.tex}{\texttt{shortlines1.tex}}{lst:shortlines1} - - Keen readers may notice that some trailing white space must be present in the file in - \cref{lst:shortlines} which has crept in to the output in - \cref{lst:shortlines1}. This can be fixed using the YAML file in - \vref{lst:removeTWS-before} and running, for example, - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{commandshell} -latexindent.pl -m shortlines.tex -o shortlines1-tws.tex -l remove-para1.yaml,removeTWS-before.yaml -\end{commandshell} - in which case the output is as in \cref{lst:shortlines1-tws}; notice that the double - spaces present in \cref{lst:shortlines1} have been addressed. - - \cmhlistingsfromfile[showspaces=true]{demonstrations/shortlines1-tws.tex}{\texttt{shortlines1-tws.tex}}{lst:shortlines1-tws} - - Keeping with the settings in \cref{lst:remove-para1-yaml}, we note that the - \texttt{all} switch applies to \emph{all} code block - types. So, for example, let's consider the files in \cref{lst:shortlines-mand,lst:shortlines-opt} - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/shortlines-mand.tex}{\texttt{shortlines-mand.tex}}{lst:shortlines-mand} - \cmhlistingsfromfile{demonstrations/shortlines-opt.tex}{\texttt{shortlines-opt.tex}}{lst:shortlines-opt} - \end{cmhtcbraster} - - Upon running the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl -m shortlines-mand.tex -o shortlines-mand1.tex -l remove-para1.yaml -latexindent.pl -m shortlines-opt.tex -o shortlines-opt1.tex -l remove-para1.yaml -\end{commandshell} - \end{widepage} - - then we obtain the respective output given in \cref{lst:shortlines-mand1,lst:shortlines-opt1}. - - \cmhlistingsfromfile{demonstrations/shortlines-mand1.tex}{\texttt{shortlines-mand1.tex}}{lst:shortlines-mand1} - \cmhlistingsfromfile{demonstrations/shortlines-opt1.tex}{\texttt{shortlines-opt1.tex}}{lst:shortlines-opt1} - - Assuming that we turn \emph{off} the \texttt{all} switch - (by setting it to \texttt{0}), then we can control the behaviour of - \texttt{removeParagraphLineBreaks} either on a per-code-block-type basis, or on a per-name - basis. - - For example, let's use the code in \cref{lst:shortlines-envs}, and consider the settings - in \cref{lst:remove-para2-yaml,lst:remove-para3-yaml}; note that in \cref{lst:remove-para2-yaml} we specify that - \emph{every} environment should receive treatment from the routine, while - in \cref{lst:remove-para3-yaml} we specify that \emph{only} the - \texttt{one} environment should receive the treatment. - - \begin{minipage}{.45\linewidth} - \cmhlistingsfromfile{demonstrations/shortlines-envs.tex}{\texttt{shortlines-envs.tex}}{lst:shortlines-envs} - \end{minipage} - \hfill - \begin{minipage}{.49\linewidth} - \cmhlistingsfromfile{demonstrations/remove-para2.yaml}[MLB-TCB]{\texttt{remove-para2.yaml}}{lst:remove-para2-yaml} - \cmhlistingsfromfile{demonstrations/remove-para3.yaml}[MLB-TCB]{\texttt{remove-para3.yaml}}{lst:remove-para3-yaml} - \end{minipage} - - Upon running the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl -m shortlines-envs.tex -o shortlines-envs2.tex -l remove-para2.yaml -latexindent.pl -m shortlines-envs.tex -o shortlines-envs3.tex -l remove-para3.yaml -\end{commandshell} - \end{widepage} - then we obtain the respective output given in \cref{lst:shortlines-envs2,lst:shortlines-envs3}. - - \cmhlistingsfromfile{demonstrations/shortlines-envs2.tex}{\texttt{shortlines-envs2.tex}}{lst:shortlines-envs2} - \cmhlistingsfromfile{demonstrations/shortlines-envs3.tex}{\texttt{shortlines-envs3.tex}}{lst:shortlines-envs3} - - The remaining code-block types can be customised in analogous ways, although note that - \texttt{commands}, \texttt{keyEqualsValuesBracesBrackets}, \texttt{namedGroupingBracesBrackets}, - \texttt{UnNamedGroupingBracesBrackets} are controlled by the \texttt{optionalArguments} and the - \texttt{mandatoryArguments}. - - The only special case is the \texttt{masterDocument} field; this is designed for - `chapter'-type files that may contain paragraphs that are not within any other - code-blocks. For example, consider the file in \cref{lst:shortlines-md}, with the YAML - settings in \cref{lst:remove-para4-yaml}. - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/shortlines-md.tex}{\texttt{shortlines-md.tex}}{lst:shortlines-md} - \cmhlistingsfromfile{demonstrations/remove-para4.yaml}[MLB-TCB]{\texttt{remove-para4.yaml}}{lst:remove-para4-yaml} - \end{cmhtcbraster} - - Upon running the following command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl -m shortlines-md.tex -o shortlines-md4.tex -l remove-para4.yaml -\end{commandshell} - \end{widepage} - then we obtain the output in \cref{lst:shortlines-md4}. \cmhlistingsfromfile{demonstrations/shortlines-md4.tex}{\texttt{shortlines-md4.tex}}{lst:shortlines-md4} - - Note% - \announce{2018-08-13}*{updates to all in removeParagraphLineBreaks} that the - \texttt{all} field can take the same exceptions detailed in - \cref{lst:textwrap6-yaml}{lst:textwrap8-yaml}. - -\yamltitle{paragraphsStopAt}*{fields} - The paragraph line break routine considers blank lines and the - \lstinline|\par| command to be the end of a paragraph; - \announce{2017-05-27}{paragraphsStopAt} you can fine tune the behaviour of the routine further by - using the \texttt{paragraphsStopAt} fields, shown in \cref{lst:paragraphsStopAt}. - \index{specialBeginEnd!paragraphsStopAt} - \index{verbatim!in relation to paragraphsStopAt} - - \cmhlistingsfromfile[style=paragraphsStopAt]*{../defaultSettings.yaml}[MLB-TCB,width=.85\linewidth,before=\centering]{\texttt{paragraphsStopAt}}{lst:paragraphsStopAt} - - The fields specified in \texttt{paragraphsStopAt} tell \texttt{latexindent.pl} to - stop the current paragraph when it reaches a line that \emph{begins} with - any of the code-block types specified as \texttt{1} in - \cref{lst:paragraphsStopAt}. By default, you'll see that the paragraph line break - routine will stop when it reaches an environment or verbatim code block at the beginning - of a line. It is \emph{not} possible to specify these fields on a - per-name basis. - - Let's use the \texttt{.tex} file in \cref{lst:sl-stop}; we will, - in turn, consider the settings in \cref{lst:stop-command-yaml,lst:stop-comment-yaml}. - - \begin{minipage}{.45\linewidth} - \cmhlistingsfromfile{demonstrations/sl-stop.tex}{\texttt{sl-stop.tex}}{lst:sl-stop} - \end{minipage} - \hfill - \begin{minipage}{.49\linewidth} - \cmhlistingsfromfile{demonstrations/stop-command.yaml}[MLB-TCB]{\texttt{stop-command.yaml}}{lst:stop-command-yaml} - - \cmhlistingsfromfile{demonstrations/stop-comment.yaml}[MLB-TCB]{\texttt{stop-comment.yaml}}{lst:stop-comment-yaml} - \end{minipage} - - Upon using the settings from \vref{lst:remove-para4-yaml} and running the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl -m sl-stop.tex -o sl-stop4.tex -l remove-para4.yaml -latexindent.pl -m sl-stop.tex -o sl-stop4-command.tex -l=remove-para4.yaml,stop-command.yaml -latexindent.pl -m sl-stop.tex -o sl-stop4-comment.tex -l=remove-para4.yaml,stop-comment.yaml -\end{commandshell} - \end{widepage} - we obtain the respective outputs in \crefrange{lst:sl-stop4}{lst:sl-stop4-comment}; notice in particular - that: - \begin{itemize} - \item in \cref{lst:sl-stop4} the paragraph line break routine has included commands and - comments; - \item in \cref{lst:sl-stop4-command} the paragraph line break routine has - \emph{stopped} at the \texttt{emph} command, because in - \cref{lst:stop-command-yaml} we have specified \texttt{commands} to be - \texttt{1}, and \texttt{emph} is at the beginning of a - line; - \item in \cref{lst:sl-stop4-comment} the paragraph line break routine has - \emph{stopped} at the comments, because in \cref{lst:stop-comment-yaml} we - have specified \texttt{comments} to be \texttt{1}, and the - comment is at the beginning of a line. - \end{itemize} - In all outputs in \crefrange{lst:sl-stop4}{lst:sl-stop4-comment} we notice that the paragraph line break - routine has stopped at \lstinline!\begin{myenv}! because, by default, - \texttt{environments} is set to \texttt{1} in - \vref{lst:paragraphsStopAt}. - - \cmhlistingsfromfile{demonstrations/sl-stop4.tex}{\texttt{sl-stop4.tex}}{lst:sl-stop4} - \cmhlistingsfromfile{demonstrations/sl-stop4-command.tex}{\texttt{sl-stop4-command.tex}}{lst:sl-stop4-command} - \cmhlistingsfromfile{demonstrations/sl-stop4-comment.tex}{\texttt{sl-stop4-comment.tex}}{lst:sl-stop4-comment} - -\subsection{Combining removeParagraphLineBreaks and textWrapOptions}\label{subsec:removeparagraphlinebreaks:and:textwrap} - - The% - \announce{2018-08-13}{combine text wrap and remove paragraph line breaks} text wrapping - routine (\vref{subsec:textwrapping}) and remove paragraph line breaks routine - (\vref{subsec:removeparagraphlinebreaks}) can be combined. - - We motivate this feature with the code given in \cref{lst:textwrap7}. - - \cmhlistingsfromfile{demonstrations/textwrap7.tex}{\texttt{textwrap7.tex}}{lst:textwrap7} - - Applying the text wrap routine from \vref{subsec:textwrapping} with, for example, - \vref{lst:textwrap3-yaml} gives the output in \cref{lst:textwrap7-mod3}. - - \cmhlistingsfromfile{demonstrations/textwrap7-mod3.tex}{\texttt{textwrap7.tex} using \cref{lst:textwrap3-yaml}}{lst:textwrap7-mod3} - - The text wrapping routine has behaved as expected, but it may be desired to remove - paragraph line breaks \emph{before} performing the text wrapping routine. - The desired behaviour can be achieved by employing the \texttt{beforeTextWrap} - switch. - - Explicitly, using the settings in \cref{lst:textwrap12-yaml} and running the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \index{switches!-o demonstration} - \begin{commandshell} -latexindent.pl -m textwrap7.tex -l=textwrap12.yaml -o=+-mod12 -\end{commandshell} - we obtain the output in \cref{lst:textwrap7-mod12}. + the output is shown in \cref{lst:mlb-bl-out}; note that the multiple blank lines have + been condensed into one blank line, and note also that we have used the \texttt{-m} + switch! \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/textwrap7-mod12.tex}{\texttt{textwrap7-mod12.tex}}{lst:textwrap7-mod12} - \cmhlistingsfromfile{demonstrations/textwrap12.yaml}[MLB-TCB]{\texttt{textwrap12.yaml}}{lst:textwrap12-yaml} - \end{cmhtcbraster} - - In \cref{lst:textwrap7-mod12} the paragraph line breaks have first been removed from - \cref{lst:textwrap7}, and then the text wrapping routine has been applied. It is - envisaged that variants of \cref{lst:textwrap12-yaml} will be among the most useful - settings for these two features. - -\subsection{Poly-switches}\label{sec:poly-switches} - Every other field in the \texttt{modifyLineBreaks} field uses poly-switches, and can - take one of the following% - \announce{2017-08-21}*{blank line poly-switch} integer values: - \index{modifying linebreaks! using poly-switches} - \index{poly-switches!definition} - \index{poly-switches!values} - \index{poly-switches!off by default: set to 0} - \begin{description} - \item[$-1$] \emph{remove mode}: line breaks before or after the - \emph{<part of thing>} can be removed (assuming that \texttt{preserveBlankLines} is - set to \texttt{0}); - \item[0] \emph{off mode}: line breaks will not be modified for the - \emph{<part of thing>} under consideration; - \item[1] \emph{add mode}: a line break will be added before or after the - \emph{<part of thing>} under consideration, assuming that - there is not already a line break before or after the \emph{<part of thing>}; - \item[2] \emph{comment then add mode}: a comment symbol will be added, followed by a line break - before or after the \emph{<part of thing>} under consideration, assuming that there - is not already a comment and line break before or after the \emph{<part of thing>}; - \item[3] \emph{add then blank line mode}% - \announce{2017-08-21}{blank line poly-switch}: a line break will be added before or after the - \emph{<part of thing>} under consideration, assuming that - there is not already a line break before or after the \emph{<part of thing>}, - followed by a blank line; - \item[4] \emph{add blank line mode}% - \announce{2019-07-13}{blank line poly-switch}; a blank line will - be added before or after the \emph{<part of thing>} under consideration, even if the - \emph{<part of thing>} is already on its own line. - \end{description} - In the above, \emph{<part of thing>} refers to either the - \emph{begin statement}, \emph{body} or - \emph{end statement} of the code blocks detailed in \vref{tab:code-blocks}. - All poly-switches are \emph{off} by default; - \texttt{latexindent.pl} searches first of all for per-name settings, and then - followed by global per-thing settings. - -\subsection{modifyLineBreaks for environments}\label{sec:modifylinebreaks-environments} - We start by viewing a snippet of \texttt{defaultSettings.yaml} in - \cref{lst:environments-mlb}; note that it contains \emph{global} settings - (immediately after the \texttt{environments} field) and that - \emph{per-name} settings are also allowed -- in the case of - \cref{lst:environments-mlb}, settings for \texttt{equation*} have been - specified for demonstration. Note that all poly-switches are \emph{off} (set to 0) - by default. - \index{poly-switches!default values} - \index{poly-switches!environment global example} - \index{poly-switches!environment per-code block example} - - \cmhlistingsfromfile[style=modifylinebreaksEnv]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,MLB-TCB]{\texttt{environments}}{lst:environments-mlb} - - Let's begin with the simple example given in \cref{lst:env-mlb1-tex}; note that we - have annotated key parts of the file using $\BeginStartsOnOwnLine$, - $\BodyStartsOnOwnLine$, $\EndStartsOnOwnLine$ and $\EndFinishesWithLineBreak$, - these will be related to fields specified in \cref{lst:environments-mlb}. - \index{poly-switches!visualisation: $\BeginStartsOnOwnLine$, $\BodyStartsOnOwnLine$, $\EndStartsOnOwnLine$, $\EndFinishesWithLineBreak$} - - \begin{cmhlistings}[style=tcblatex,escapeinside={(*@}{@*)}]{\texttt{env-mlb1.tex}}{lst:env-mlb1-tex} -before words(*@$\BeginStartsOnOwnLine$@*) \begin{myenv}(*@$\BodyStartsOnOwnLine$@*)body of myenv(*@$\EndStartsOnOwnLine$@*)\end{myenv}(*@$\EndFinishesWithLineBreak$@*) after words -\end{cmhlistings} - -\subsubsection{Adding line breaks: BeginStartsOnOwnLine and BodyStartsOnOwnLine} - Let's explore \texttt{BeginStartsOnOwnLine} and \texttt{BodyStartsOnOwnLine} in - \cref{lst:env-mlb1,lst:env-mlb2}, and in particular, let's allow each of them in turn to take - a value of $1$. - \index{modifying linebreaks! at the \emph{beginning} of a code block} - \index{poly-switches!adding line breaks: set to 1} - - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb1.yaml}[MLB-TCB]{\texttt{env-mlb1.yaml}}{lst:env-mlb1} - \end{minipage} - \hfill - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb2.yaml}[MLB-TCB]{\texttt{env-mlb2.yaml}}{lst:env-mlb2} - \end{minipage} - - After running the following commands, - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m env-mlb.tex -l env-mlb1.yaml -latexindent.pl -m env-mlb.tex -l env-mlb2.yaml -\end{commandshell} - the output is as in \cref{lst:env-mlb-mod1,lst:env-mlb-mod2} respectively. - - \begin{widepage} - \begin{minipage}{.56\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod1.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb1}}{lst:env-mlb-mod1} - \end{minipage} - \hfill - \begin{minipage}{.43\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod2.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb2}}{lst:env-mlb-mod2} - \end{minipage} - \end{widepage} - - There are a couple of points to note: - \begin{itemize} - \item in \cref{lst:env-mlb-mod1} a line break has been added at the point denoted by - $\BeginStartsOnOwnLine$ in \cref{lst:env-mlb1-tex}; no other line breaks have been - changed; - \item in \cref{lst:env-mlb-mod2} a line break has been added at the point denoted by - $\BodyStartsOnOwnLine$ in \cref{lst:env-mlb1-tex}; furthermore, note that the - \emph{body} of \texttt{myenv} has received the appropriate - (default) indentation. - \end{itemize} - - Let's now change each of the \texttt{1} values in - \cref{lst:env-mlb1,lst:env-mlb2} so that they are $2$ and save them - into \texttt{env-mlb3.yaml} and \texttt{env-mlb4.yaml} respectively (see - \cref{lst:env-mlb3,lst:env-mlb4}). - \index{poly-switches!adding comments and then line breaks: set to 2} - - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb3.yaml}[MLB-TCB]{\texttt{env-mlb3.yaml}}{lst:env-mlb3} - \end{minipage} - \hfill - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb4.yaml}[MLB-TCB]{\texttt{env-mlb4.yaml}}{lst:env-mlb4} - \end{minipage} - - Upon running commands analogous to the above, we obtain \cref{lst:env-mlb-mod3,lst:env-mlb-mod4}. - - \begin{widepage} - \begin{minipage}{.56\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod3.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb3}}{lst:env-mlb-mod3} - \end{minipage} - \hfill - \begin{minipage}{.43\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod4.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb4}}{lst:env-mlb-mod4} - \end{minipage} - \end{widepage} - - Note that line breaks have been added as in \cref{lst:env-mlb-mod1,lst:env-mlb-mod2}, but this time a - comment symbol has been added before adding the line break; in both cases, trailing - horizontal space has been stripped before doing so. - - Let's% - \announce{2017-08-21}{demonstration of blank line poly-switch (3)} now change each - of the \texttt{1} values in \cref{lst:env-mlb1,lst:env-mlb2} so that they - are $3$ and save them into \texttt{env-mlb5.yaml} and - \texttt{env-mlb6.yaml} respectively (see \cref{lst:env-mlb5,lst:env-mlb6}). - \index{poly-switches!adding blank lines: set to 3} - - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb5.yaml}[MLB-TCB]{\texttt{env-mlb5.yaml}}{lst:env-mlb5} - \end{minipage} - \hfill - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb6.yaml}[MLB-TCB]{\texttt{env-mlb6.yaml}}{lst:env-mlb6} - \end{minipage} - - Upon running commands analogous to the above, we obtain \cref{lst:env-mlb-mod5,lst:env-mlb-mod6}. - - \begin{widepage} - \begin{minipage}{.56\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod5.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb5}}{lst:env-mlb-mod5} - \end{minipage} - \hfill - \begin{minipage}{.43\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod6.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb6}}{lst:env-mlb-mod6} - \end{minipage} - \end{widepage} - - Note that line breaks have been added as in \cref{lst:env-mlb-mod1,lst:env-mlb-mod2}, but this time a - \emph{blank line} has been added after adding the line break. - - Let's now change% - \announce{2019-07-13}{demonstration of new blank line poly-switch} each - of the \texttt{1} values in \cref{lst:env-mlb5,lst:env-mlb6} so that they - are $4$ and save them into \texttt{env-beg4.yaml} and - \texttt{env-body4.yaml} respectively (see \cref{lst:env-beg4,lst:env-body4}). - \index{poly-switches!adding blank lines (again"!): set to 4} - - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-beg4.yaml}[MLB-TCB]{\texttt{env-beg4.yaml}}{lst:env-beg4} - \end{minipage} - \hfill - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-body4.yaml}[MLB-TCB]{\texttt{env-body4.yaml}}{lst:env-body4} - \end{minipage} - - We will demonstrate this poly-switch value using the code in - \cref{lst:env-mlb1-text}. - - \cmhlistingsfromfile{demonstrations/env-mlb1.tex}{\texttt{env-mlb1.tex}}{lst:env-mlb1-text} - - Upon running the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m env-mlb1.tex -l env-beg4.yaml -latexindent.pl -m env-mlb.1tex -l env-body4.yaml -\end{commandshell} - - then we receive the respective outputs in \cref{lst:env-mlb1-beg4,lst:env-mlb1-body4}. - - \begin{cmhtcbraster}[raster column skip=.1\linewidth] - \cmhlistingsfromfile{demonstrations/env-mlb1-beg4.tex}{\texttt{env-mlb1.tex} using \cref{lst:env-beg4}}{lst:env-mlb1-beg4} - \cmhlistingsfromfile{demonstrations/env-mlb1-body4.tex}{\texttt{env-mlb1.tex} using \cref{lst:env-body4}}{lst:env-mlb1-body4} - \end{cmhtcbraster} - - We note in particular that, by design, for this value of the poly-switches: - \begin{enumerate} - \item in \cref{lst:env-mlb1-beg4} a blank line has been inserted before the - \lstinline!\begin! statement, even though the \lstinline!\begin! - statement was already on its own line; - \item in \cref{lst:env-mlb1-body4} a blank line has been inserted before the beginning of the - \emph{body}, even though it already began on its own line. - \end{enumerate} - -\subsubsection{Adding line breaks using EndStartsOnOwnLine and EndFinishesWithLineBreak} - Let's explore \texttt{EndStartsOnOwnLine} and \texttt{EndFinishesWithLineBreak} in - \cref{lst:env-mlb7,lst:env-mlb8}, and in particular, let's allow each of them in turn to take - a value of $1$. - \index{modifying linebreaks! at the \emph{end} of a code block} - \index{poly-switches!adding line breaks: set to 1} - - \begin{minipage}{.49\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb7.yaml}[MLB-TCB]{\texttt{env-mlb7.yaml}}{lst:env-mlb7} - \end{minipage} - \hfill - \begin{minipage}{.49\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb8.yaml}[MLB-TCB]{\texttt{env-mlb8.yaml}}{lst:env-mlb8} - \end{minipage} - - After running the following commands, - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m env-mlb.tex -l env-mlb7.yaml -latexindent.pl -m env-mlb.tex -l env-mlb8.yaml -\end{commandshell} - the output is as in \cref{lst:env-mlb-mod7,lst:env-mlb-mod8}. - - \begin{widepage} - \begin{minipage}{.42\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod7.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb7}}{lst:env-mlb-mod7} - \end{minipage} - \hfill - \begin{minipage}{.57\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod8.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb8}}{lst:env-mlb-mod8} - \end{minipage} - \end{widepage} - - There are a couple of points to note: - \begin{itemize} - \item in \cref{lst:env-mlb-mod7} a line break has been added at the point denoted by - $\EndStartsOnOwnLine$ in \vref{lst:env-mlb1-tex}; no other line breaks have been - changed and the \lstinline!\end{myenv}! statement has \emph{not} - received indentation (as intended); - \item in \cref{lst:env-mlb-mod8} a line break has been added at the point denoted by - $\EndFinishesWithLineBreak$ in \vref{lst:env-mlb1-tex}. - \end{itemize} - - Let's now change each of the \texttt{1} values in - \cref{lst:env-mlb7,lst:env-mlb8} so that they are $2$ and save them - into \texttt{env-mlb9.yaml} and \texttt{env-mlb10.yaml} respectively (see - \cref{lst:env-mlb9,lst:env-mlb10}). - \index{poly-switches!adding comments and then line breaks: set to 2} - - \begin{minipage}{.49\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb9.yaml}[MLB-TCB]{\texttt{env-mlb9.yaml}}{lst:env-mlb9} - \end{minipage} - \hfill - \begin{minipage}{.49\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb10.yaml}[MLB-TCB]{\texttt{env-mlb10.yaml}}{lst:env-mlb10} - \end{minipage} - - Upon running commands analogous to the above, we obtain \cref{lst:env-mlb-mod9,lst:env-mlb-mod10}. - - \begin{widepage} - \begin{minipage}{.43\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod9.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb9}}{lst:env-mlb-mod9} - \end{minipage} - \hfill - \begin{minipage}{.56\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod10.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb10}}{lst:env-mlb-mod10} - \end{minipage} - \end{widepage} - - Note that line breaks have been added as in \cref{lst:env-mlb-mod7,lst:env-mlb-mod8}, but this time a - comment symbol has been added before adding the line break; in both cases, trailing - horizontal space has been stripped before doing so. - - Let's% - \announce{2017-08-21}{demonstration of blank line poly-switch (3)} now change each - of the \texttt{1} values in \cref{lst:env-mlb7,lst:env-mlb8} so that they - are $3$ and save them into \texttt{env-mlb11.yaml} and - \texttt{env-mlb12.yaml} respectively (see \cref{lst:env-mlb11,lst:env-mlb12}). - \index{poly-switches!adding blank lines: set to 3} - - \begin{minipage}{.49\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb11.yaml}[MLB-TCB]{\texttt{env-mlb11.yaml}}{lst:env-mlb11} - \end{minipage} - \hfill - \begin{minipage}{.49\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb12.yaml}[MLB-TCB]{\texttt{env-mlb12.yaml}}{lst:env-mlb12} - \end{minipage} - - Upon running commands analogous to the above, we obtain \cref{lst:env-mlb-mod11,lst:env-mlb-mod12}. - - \begin{widepage} - \begin{minipage}{.42\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod11.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb11}}{lst:env-mlb-mod11} - \end{minipage} - \hfill - \begin{minipage}{.57\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb-mod12.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb12}}{lst:env-mlb-mod12} - \end{minipage} - \end{widepage} - - Note that line breaks have been added as in \cref{lst:env-mlb-mod7,lst:env-mlb-mod8}, and that a - \emph{blank line} has been added after the line break. - - Let's now change% - \announce{2019-07-13}{demonstration of new blank line poly-switch} each - of the \texttt{1} values in \cref{lst:env-mlb11,lst:env-mlb12} so that they - are $4$ and save them into \texttt{env-end4.yaml} and - \texttt{env-end-f4.yaml} respectively (see \cref{lst:env-end4,lst:env-end-f4}). - \index{poly-switches!adding blank lines (again"!): set to 4} - - \begin{minipage}{.45\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-end4.yaml}[MLB-TCB]{\texttt{env-end4.yaml}}{lst:env-end4} - \end{minipage} - \hfill - \begin{minipage}{.5\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-end-f4.yaml}[MLB-TCB]{\texttt{env-end-f4.yaml}}{lst:env-end-f4} - \end{minipage} - - We will demonstrate this poly-switch value using the code from - \vref{lst:env-mlb1-text}. - - Upon running the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m env-mlb1.tex -l env-end4.yaml -latexindent.pl -m env-mlb.1tex -l env-end-f4.yaml -\end{commandshell} - - then we receive the respective outputs in \cref{lst:env-mlb1-end4,lst:env-mlb1-end-f4}. - - \begin{cmhtcbraster}[raster column skip=.1\linewidth] - \cmhlistingsfromfile{demonstrations/env-mlb1-end4.tex}{\texttt{env-mlb1.tex} using \cref{lst:env-end4}}{lst:env-mlb1-end4} - \cmhlistingsfromfile{demonstrations/env-mlb1-end-f4.tex}{\texttt{env-mlb1.tex} using \cref{lst:env-end-f4}}{lst:env-mlb1-end-f4} - \end{cmhtcbraster} - - We note in particular that, by design, for this value of the poly-switches: - \begin{enumerate} - \item in \cref{lst:env-mlb1-end4} a blank line has been inserted before the - \lstinline!\end! statement, even though the \lstinline!\end! - statement was already on its own line; - \item in \cref{lst:env-mlb1-end-f4} a blank line has been inserted after the - \lstinline!\end! statement, even though it already began on its own line. - \end{enumerate} - -\subsubsection{poly-switches 1, 2, and 3 only add line breaks when necessary} - If you ask \texttt{latexindent.pl} to add a line break (possibly with a comment) - using a poly-switch value of $1$ (or $2$ - or $3$), it will only do so if necessary. For example, if you - process the file in \vref{lst:mlb2} using poly-switch values of 1, 2, or 3, - it will be left unchanged. - - \begin{minipage}{.45\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb2.tex}{\texttt{env-mlb2.tex}}{lst:mlb2} - \end{minipage} - \hfill - \begin{minipage}{.45\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb3.tex}{\texttt{env-mlb3.tex}}{lst:mlb3} - \end{minipage} - - Setting the poly-switches to a value of $4$ instructs - \texttt{latexindent.pl} to add a line break even if the \emph{<part of thing>} - is already on its own line; see \cref{lst:env-mlb1-beg4,lst:env-mlb1-body4} and - \cref{lst:env-mlb1-end4,lst:env-mlb1-end-f4}. - - In contrast, the output from processing the file in \cref{lst:mlb3} will - vary depending on the poly-switches used; in \cref{lst:env-mlb3-mod2} you'll see that - the comment symbol after the \lstinline!\begin{myenv}! has been moved to the next line, - as \texttt{BodyStartsOnOwnLine} is set to \texttt{1}. In - \cref{lst:env-mlb3-mod4} you'll see that the comment has been accounted for correctly - because \texttt{BodyStartsOnOwnLine} has been set to \texttt{2}, and - the comment symbol has \emph{not} been moved to its own line. You're - encouraged to experiment with \cref{lst:mlb3} and by setting the other - poly-switches considered so far to \texttt{2} in turn. - - \begin{cmhtcbraster}[raster column skip=.1\linewidth] - \cmhlistingsfromfile{demonstrations/env-mlb3-mod2.tex}{\texttt{env-mlb3.tex} using \vref{lst:env-mlb2}}{lst:env-mlb3-mod2} - \cmhlistingsfromfile{demonstrations/env-mlb3-mod4.tex}{\texttt{env-mlb3.tex} using \vref{lst:env-mlb4}}{lst:env-mlb3-mod4} - \end{cmhtcbraster} - - The details of the discussion in this section have concerned \emph{global} - poly-switches in the \texttt{environments} field; each switch can also be - specified on a \emph{per-name} basis, which would take priority over the - global values; with reference to \vref{lst:environments-mlb}, an example is shown for - the \texttt{equation*} environment. - -\subsubsection{Removing line breaks (poly-switches set to $-1$)} - Setting poly-switches to $-1$ tells \texttt{latexindent.pl} - to remove line breaks of the \emph{<part of the thing>}, if necessary. We will consider - the example code given in \cref{lst:mlb4}, noting in particular the - positions of the line break highlighters, $\BeginStartsOnOwnLine$, - $\BodyStartsOnOwnLine$, $\EndStartsOnOwnLine$ and $\EndFinishesWithLineBreak$, - together with the associated YAML files in \crefrange{lst:env-mlb13}{lst:env-mlb16}. - \index{poly-switches!removing line breaks: set to -1} - - \begin{minipage}{.45\linewidth} - \begin{cmhlistings}[style=tcblatex,escapeinside={(*@}{@*)}]{\texttt{env-mlb4.tex}}{lst:mlb4} -before words(*@$\BeginStartsOnOwnLine$@*) -\begin{myenv}(*@$\BodyStartsOnOwnLine$@*) -body of myenv(*@$\EndStartsOnOwnLine$@*) -\end{myenv}(*@$\EndFinishesWithLineBreak$@*) -after words -\end{cmhlistings} - \end{minipage}% - \hfill - \begin{minipage}{.51\textwidth} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb13.yaml}[MLB-TCB]{\texttt{env-mlb13.yaml}}{lst:env-mlb13} - - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb14.yaml}[MLB-TCB]{\texttt{env-mlb14.yaml}}{lst:env-mlb14} - - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb15.yaml}[MLB-TCB]{\texttt{env-mlb15.yaml}}{lst:env-mlb15} - - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb16.yaml}[MLB-TCB]{\texttt{env-mlb16.yaml}}{lst:env-mlb16} - \end{minipage} - - After running the commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m env-mlb4.tex -l env-mlb13.yaml -latexindent.pl -m env-mlb4.tex -l env-mlb14.yaml -latexindent.pl -m env-mlb4.tex -l env-mlb15.yaml -latexindent.pl -m env-mlb4.tex -l env-mlb16.yaml -\end{commandshell} - - we obtain the respective output in \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16}. - - \begin{minipage}{.45\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb4-mod13.tex}{\texttt{env-mlb4.tex} using \cref{lst:env-mlb13}}{lst:env-mlb4-mod13} - \end{minipage} - \hfill - \begin{minipage}{.45\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb4-mod14.tex}{\texttt{env-mlb4.tex} using \cref{lst:env-mlb14}}{lst:env-mlb4-mod14} - \end{minipage} - - \begin{minipage}{.45\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb4-mod15.tex}{\texttt{env-mlb4.tex} using \cref{lst:env-mlb15}}{lst:env-mlb4-mod15} - \end{minipage} - \hfill - \begin{minipage}{.45\linewidth} - \cmhlistingsfromfile{demonstrations/env-mlb4-mod16.tex}{\texttt{env-mlb4.tex} using \cref{lst:env-mlb16}}{lst:env-mlb4-mod16} - \end{minipage} - - Notice that in: - \begin{itemize} - \item \cref{lst:env-mlb4-mod13} the line break denoted by $\BeginStartsOnOwnLine$ in - \cref{lst:mlb4} has been removed; - \item \cref{lst:env-mlb4-mod14} the line break denoted by $\BodyStartsOnOwnLine$ in - \cref{lst:mlb4} has been removed; - \item \cref{lst:env-mlb4-mod15} the line break denoted by $\EndStartsOnOwnLine$ in - \cref{lst:mlb4} has been removed; - \item \cref{lst:env-mlb4-mod16} the line break denoted by $\EndFinishesWithLineBreak$ in - \cref{lst:mlb4} has been removed. - \end{itemize} - We examined each of these cases separately for clarity of explanation, but you can - combine all of the YAML settings in \crefrange{lst:env-mlb13}{lst:env-mlb16} into one file; - alternatively, you could tell \texttt{latexindent.pl} to load them all by using the - following command, for example - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl -m env-mlb4.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml -\end{commandshell} - \end{widepage} - which gives the output in \vref{lst:env-mlb1-tex}. - -\subsubsection{About trailing horizontal space} - Recall that on \cpageref{yaml:removeTrailingWhitespace} we discussed the YAML field - \texttt{removeTrailingWhitespace}, and that it has two (binary) switches to determine if - horizontal space should be removed \texttt{beforeProcessing} and - \texttt{afterProcessing}. The \texttt{beforeProcessing} is particularly relevant - when considering the \texttt{-m} switch; let's consider the file shown - in \cref{lst:mlb5}, which highlights trailing spaces. - - \begin{cmhtcbraster} - \begin{cmhlistings}[style=tcblatex,showspaces=true,escapeinside={(*@}{@*)}]{\texttt{env-mlb5.tex}}{lst:mlb5} -before words (*@$\BeginStartsOnOwnLine$@*) -\begin{myenv} (*@$\BodyStartsOnOwnLine$@*) -body of myenv (*@$\EndStartsOnOwnLine$@*) -\end{myenv} (*@$\EndFinishesWithLineBreak$@*) -after words -\end{cmhlistings} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/removeTWS-before.yaml}[yaml-TCB]{\texttt{removeTWS-before.yaml}}{lst:removeTWS-before} - \end{cmhtcbraster} - - The output from the following commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl -m env-mlb5.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml -latexindent.pl -m env-mlb5.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml,removeTWS-before.yaml -\end{commandshell} - \end{widepage} - is shown, respectively, in \cref{lst:env-mlb5-modAll,lst:env-mlb5-modAll-remove-WS}; note that the trailing - horizontal white space has been preserved (by default) in \cref{lst:env-mlb5-modAll}, - while in \cref{lst:env-mlb5-modAll-remove-WS}, it has been removed using the switch specified in - \cref{lst:removeTWS-before}. - - \begin{widepage} - \cmhlistingsfromfile[showspaces=true]{demonstrations/env-mlb5-modAll.tex}{\texttt{env-mlb5.tex} using \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16}}{lst:env-mlb5-modAll} - - \cmhlistingsfromfile[showspaces=true]{demonstrations/env-mlb5-modAll-remove-WS.tex}{\texttt{env-mlb5.tex} using \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16} \emph{and} \cref{lst:removeTWS-before}}{lst:env-mlb5-modAll-remove-WS} - \end{widepage} - -\subsubsection{poly-switch line break removal and blank lines} - Now let's consider the file in \cref{lst:mlb6}, which contains blank lines. - \index{poly-switches!blank lines} - - \begin{cmhtcbraster} - \begin{cmhlistings}[style=tcblatex,escapeinside={(*@}{@*)}]{\texttt{env-mlb6.tex}}{lst:mlb6} -before words(*@$\BeginStartsOnOwnLine$@*) - - -\begin{myenv}(*@$\BodyStartsOnOwnLine$@*) - - -body of myenv(*@$\EndStartsOnOwnLine$@*) - - -\end{myenv}(*@$\EndFinishesWithLineBreak$@*) - -after words -\end{cmhlistings} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/UnpreserveBlankLines.yaml}[MLB-TCB]{\texttt{UnpreserveBlankLines.yaml}}{lst:UnpreserveBlankLines} - \end{cmhtcbraster} - - Upon running the following commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{widepage} - \begin{commandshell} -latexindent.pl -m env-mlb6.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml -latexindent.pl -m env-mlb6.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml,UnpreserveBlankLines.yaml -\end{commandshell} - \end{widepage} - we receive the respective outputs in \cref{lst:env-mlb6-modAll,lst:env-mlb6-modAll-un-Preserve-Blank-Lines}. In - \cref{lst:env-mlb6-modAll} we see that the multiple blank lines have each been - condensed into one blank line, but that blank lines have \emph{not} - been removed by the poly-switches -- this is because, by default, - \texttt{preserveBlankLines} is set to \texttt{1}. By contrast, in - \cref{lst:env-mlb6-modAll-un-Preserve-Blank-Lines}, we have allowed the poly-switches to remove blank lines - because, in \cref{lst:UnpreserveBlankLines}, we have set \texttt{preserveBlankLines} to - \texttt{0}. - - \begin{cmhtcbraster}[ raster left skip=-3.5cm, - raster right skip=-2cm, - raster force size=false, - raster column 1/.style={add to width=-.2\textwidth}, - raster column 2/.style={add to width=.2\textwidth}, - raster column skip=.06\linewidth] - \cmhlistingsfromfile{demonstrations/env-mlb6-modAll.tex}{\texttt{env-mlb6.tex} using \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16}}{lst:env-mlb6-modAll} - \cmhlistingsfromfile{demonstrations/env-mlb6-modAll-un-Preserve-Blank-Lines.tex}{\texttt{env-mlb6.tex} using \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16} \emph{and} \cref{lst:UnpreserveBlankLines}}{lst:env-mlb6-modAll-un-Preserve-Blank-Lines} - \end{cmhtcbraster} - - We can explore this further using the blank-line poly-switch value of - $3$; let's use the file given in \cref{lst:env-mlb7-tex}. - - \cmhlistingsfromfile{demonstrations/env-mlb7.tex}{\texttt{env-mlb7.tex}}{lst:env-mlb7-tex} - - Upon running the following commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m env-mlb7.tex -l env-mlb12.yaml,env-mlb13.yaml -latexindent.pl -m env-mlb7.tex -l env-mlb13.yaml,env-mlb14.yaml,UnpreserveBlankLines.yaml -\end{commandshell} - we receive the outputs given in \cref{lst:env-mlb7-preserve,lst:env-mlb7-no-preserve}. - - \cmhlistingsfromfile{demonstrations/env-mlb7-preserve.tex}{\texttt{env-mlb7-preserve.tex}}{lst:env-mlb7-preserve} - \cmhlistingsfromfile{demonstrations/env-mlb7-no-preserve.tex}{\texttt{env-mlb7-no-preserve.tex}}{lst:env-mlb7-no-preserve} - - Notice that in: - \begin{itemize} - \item \cref{lst:env-mlb7-preserve} that \lstinline!\end{one}! has added a blank line, - because of the value of \texttt{EndFinishesWithLineBreak} in \vref{lst:env-mlb12}, and - even though the line break ahead of \lstinline!\begin{two}! should have been removed - (because of \texttt{BeginStartsOnOwnLine} in \vref{lst:env-mlb13}), the blank line - has been preserved by default; - \item \cref{lst:env-mlb7-no-preserve}, by contrast, has had the additional line-break removed, - because of the settings in \cref{lst:UnpreserveBlankLines}. - \end{itemize} - -\subsection{Poly-switches for double back slash}\label{subsec:dbs} - With reference to \texttt{lookForAlignDelims} (see \vref{lst:aligndelims:basic})% - \announce{2019-07-13}{poly-switch for double back slash} you can - specify poly-switches to dictate the line-break behaviour of double back slashes in - environments (\vref{lst:tabularafter:basic}), commands (\vref{lst:matrixafter}), or - special code blocks (\vref{lst:specialafter}). Note that for these poly-switches to - take effect, the name of the code block must necessarily be specified within - \texttt{lookForAlignDelims} (\vref{lst:aligndelims:basic}); we will demonstrate this in what follows. - \index{delimiters!poly-switches for double back slash} - \index{modifying linebreaks! surrounding double back slash} - \index{poly-switches!for double back slash (delimiters)} - - Consider the code given in \cref{lst:dbs-demo}. - \begin{cmhlistings}[style=tcblatex,escapeinside={(*@}{@*)}]{\texttt{tabular3.tex}}{lst:dbs-demo} -\begin{tabular}{cc} - 1 & 2 (*@$\ElseStartsOnOwnLine$@*)\\(*@$\ElseFinishesWithLineBreak$@*) 3 & 4 (*@$\ElseStartsOnOwnLine$@*)\\(*@$\ElseFinishesWithLineBreak$@*) -\end{tabular} -\end{cmhlistings} - Referencing \cref{lst:dbs-demo}: - \begin{itemize} - \item \texttt{DBS} stands for \emph{double back slash}; - \item line breaks ahead of the double back slash are annotated by $\ElseStartsOnOwnLine$, - and are controlled by \texttt{DBSStartsOnOwnLine}; - \item line breaks after the double back slash are annotated by $\ElseFinishesWithLineBreak$, and - are controlled by \texttt{DBSFinishesWithLineBreak}. - \end{itemize} - - Let's explore each of these in turn. - -\subsubsection{Double back slash starts on own line} - We explore \texttt{DBSStartsOnOwnLine} ($\ElseStartsOnOwnLine$ in \cref{lst:dbs-demo}); starting with the code in - \cref{lst:dbs-demo}, together with the YAML files given in - \cref{lst:DBS1} and \cref{lst:DBS2} and running the following - commands - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m tabular3.tex -l DBS1.yaml -latexindent.pl -m tabular3.tex -l DBS2.yaml -\end{commandshell} - then we receive the respective output given in \cref{lst:tabular3-DBS1} and - \cref{lst:tabular3-DBS2}. - - \begin{cmhtcbraster}[raster column skip=.01\linewidth] - \cmhlistingsfromfile{demonstrations/tabular3-mod1.tex}{\texttt{tabular3.tex} using \cref{lst:DBS1}}{lst:tabular3-DBS1} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS1.yaml}[MLB-TCB]{\texttt{DBS1.yaml}}{lst:DBS1} - \end{cmhtcbraster} - - \begin{cmhtcbraster}[raster column skip=.01\linewidth] - \cmhlistingsfromfile{demonstrations/tabular3-mod2.tex}{\texttt{tabular3.tex} using \cref{lst:DBS2}}{lst:tabular3-DBS2} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS2.yaml}[MLB-TCB]{\texttt{DBS2.yaml}}{lst:DBS2} - \end{cmhtcbraster} - - We note that - \begin{itemize} - \item \cref{lst:DBS1} specifies \texttt{DBSStartsOnOwnLine} for - \emph{every} environment (that is within \texttt{lookForAlignDelims}, - \vref{lst:aligndelims:advanced}); - the double back slashes from \cref{lst:dbs-demo} have been moved to their own - line in \cref{lst:tabular3-DBS1}; - \item \cref{lst:DBS2} specifies \texttt{DBSStartsOnOwnLine} on a - \emph{per-name} basis for \texttt{tabular} (that is within \texttt{lookForAlignDelims}, \vref{lst:aligndelims:advanced}); - the double back slashes from \cref{lst:dbs-demo} have been moved to their own - line in \cref{lst:tabular3-DBS2}, having added comment symbols before moving them. - \end{itemize} - -\subsubsection{Double back slash finishes with line break} - Let's now explore \texttt{DBSFinishesWithLineBreak} ($\ElseFinishesWithLineBreak$ in \cref{lst:dbs-demo}); starting with the code in - \cref{lst:dbs-demo}, together with the YAML files given in - \cref{lst:DBS3} and \cref{lst:DBS4} and running the following - commands - \index{poly-switches!for double back slash (delimiters)} - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m tabular3.tex -l DBS3.yaml -latexindent.pl -m tabular3.tex -l DBS4.yaml -\end{commandshell} - then we receive the respective output given in \cref{lst:tabular3-DBS3} and - \cref{lst:tabular3-DBS4}. - - \begin{cmhtcbraster}[raster column skip=.01\linewidth] - \cmhlistingsfromfile{demonstrations/tabular3-mod3.tex}{\texttt{tabular3.tex} using \cref{lst:DBS3}}{lst:tabular3-DBS3} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS3.yaml}[MLB-TCB]{\texttt{DBS3.yaml}}{lst:DBS3} - \end{cmhtcbraster} - - \begin{cmhtcbraster}[raster column skip=.01\linewidth] - \cmhlistingsfromfile{demonstrations/tabular3-mod4.tex}{\texttt{tabular3.tex} using \cref{lst:DBS4}}{lst:tabular3-DBS4} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS4.yaml}[MLB-TCB]{\texttt{DBS4.yaml}}{lst:DBS4} - \end{cmhtcbraster} - - We note that - \begin{itemize} - \item \cref{lst:DBS3} specifies \texttt{DBSFinishesWithLineBreak} for - \emph{every} environment (that is within \texttt{lookForAlignDelims}, - \vref{lst:aligndelims:advanced}); - the code following the double back slashes from \cref{lst:dbs-demo} has been - moved to their own line in \cref{lst:tabular3-DBS3}; - \item \cref{lst:DBS4} specifies \texttt{DBSFinishesWithLineBreak} on a - \emph{per-name} basis for \texttt{tabular} (that is within \texttt{lookForAlignDelims}, \vref{lst:aligndelims:advanced}); - the first double back slashes from \cref{lst:dbs-demo} have moved code following - them to their own line in \cref{lst:tabular3-DBS4}, having added comment symbols - before moving them; the final double back slashes have \emph{not} added - a line break as they are at the end of the body within the code block. - \end{itemize} - -\subsubsection{Double back slash poly-switches for specialBeginEnd} - Let's explore the double back slash poly-switches for code blocks within - \texttt{specialBeginEnd} code blocks (\vref{lst:specialBeginEnd}); we begin with - the code within \cref{lst:special4}. - \index{specialBeginEnd!double backslash poly-switch demonstration} - \index{poly-switches!double backslash} - \index{poly-switches!for double back slash (delimiters)} - \index{specialBeginEnd!lookForAlignDelims} - \index{delimiters} - \index{linebreaks!summary of poly-switches} - - \cmhlistingsfromfile{demonstrations/special4.tex}{\texttt{special4.tex}}{lst:special4} - - Upon using the YAML settings in \cref{lst:DBS5}, and running the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m special4.tex -l DBS5.yaml -\end{commandshell} - then we receive the output given in \cref{lst:special4-DBS5}. - \index{delimiters!with specialBeginEnd and the -m switch} - - \begin{cmhtcbraster}[ - raster force size=false, - raster column 1/.style={add to width=-.1\textwidth}, - raster column skip=.06\linewidth] - \cmhlistingsfromfile{demonstrations/special4-mod5.tex}{\texttt{special4.tex} using \cref{lst:DBS5}}{lst:special4-DBS5} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS5.yaml}[MLB-TCB,width=0.6\textwidth]{\texttt{DBS5.yaml}}{lst:DBS5} - \end{cmhtcbraster} - - There are a few things to note: - \begin{itemize} - \item in \cref{lst:DBS5} we have specified \texttt{cmhMath} within - \texttt{lookForAlignDelims}; without this, the double back slash poly-switches would be - ignored for this code block; - \item the \texttt{DBSFinishesWithLineBreak} poly-switch has controlled the line breaks following the - double back slashes; - \item the \texttt{SpecialEndStartsOnOwnLine} poly-switch has controlled the addition of a comment - symbol, followed by a line break, as it is set to a value of 2. - \end{itemize} - -\subsubsection{Double back slash poly-switches for optional and mandatory arguments} - For clarity, we provide a demonstration of controlling the double back slash - poly-switches for optional and mandatory arguments. We begin with the code in - \cref{lst:mycommand2}. - \index{poly-switches!for double back slash (delimiters)} - - \cmhlistingsfromfile{demonstrations/mycommand2.tex}{\texttt{mycommand2.tex}}{lst:mycommand2} - - Upon using the YAML settings in \cref{lst:DBS6,lst:DBS7}, and running the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m mycommand2.tex -l DBS6.yaml -latexindent.pl -m mycommand2.tex -l DBS7.yaml -\end{commandshell} - then we receive the output given in \cref{lst:mycommand2-DBS6,lst:mycommand2-DBS7}. - - \begin{cmhtcbraster}[ - raster force size=false, - raster column 1/.style={add to width=-.1\textwidth}, - raster column skip=.03\linewidth] - \cmhlistingsfromfile{demonstrations/mycommand2-mod6.tex}{\texttt{mycommand2.tex} using \cref{lst:DBS6}}{lst:mycommand2-DBS6} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS6.yaml}[MLB-TCB,width=0.6\textwidth]{\texttt{DBS6.yaml}}{lst:DBS6} - \end{cmhtcbraster} - - \begin{cmhtcbraster}[ - raster force size=false, - raster column 1/.style={add to width=-.1\textwidth}, - raster column skip=.03\linewidth] - \cmhlistingsfromfile{demonstrations/mycommand2-mod7.tex}{\texttt{mycommand2.tex} using \cref{lst:DBS7}}{lst:mycommand2-DBS7} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS7.yaml}[MLB-TCB,width=0.6\textwidth]{\texttt{DBS7.yaml}}{lst:DBS7} + \cmhlistingsfromfile{demonstrations/mlb1.tex}{\texttt{mlb1.tex}}{lst:mlb-bl} + \cmhlistingsfromfile{demonstrations/mlb1-out.tex}{\texttt{mlb1-mod1.tex}}{lst:mlb-bl-out} \end{cmhtcbraster} - -\subsubsection{Double back slash optional square brackets} - The pattern matching for the double back slash will also, optionally, allow trailing - square brackets that contain a measurement of vertical spacing, for example - \lstinline!\\[3pt]!. - \index{poly-switches!for double back slash (delimiters)} - - For example, beginning with the code in \cref{lst:pmatrix3} - - \cmhlistingsfromfile{demonstrations/pmatrix3.tex}{\texttt{pmatrix3.tex}}{lst:pmatrix3} - - and running the following command, using \cref{lst:DBS3}, - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m pmatrix3.tex -l DBS3.yaml -\end{commandshell} - then we receive the output given in \cref{lst:pmatrix3-DBS3}. - - \cmhlistingsfromfile{demonstrations/pmatrix3-mod3.tex}{\texttt{pmatrix3.tex} using \cref{lst:DBS3}}{lst:pmatrix3-DBS3} - - You can customise the pattern for the double back slash by exploring the - \emph{fine tuning} field detailed in \vref{lst:fineTuning}. - -\subsection{Poly-switches for other code blocks} - Rather than repeat the examples shown for the environment code blocks (in - \vref{sec:modifylinebreaks-environments}), we choose to detail the poly-switches for all other code - blocks in \cref{tab:poly-switch-mapping}; note that each and every one of these - poly-switches is \emph{off by default}, i.e, set to \texttt{0}. - - Note also that, by design, line breaks involving, \texttt{filecontents} and - `comment-marked' code blocks (\vref{lst:alignmentmarkup}) can - \emph{not} be modified using - \texttt{latexindent.pl}.% - \announce{2019-05-05}*{verbatim poly-switch} However, there are two poly-switches available for - \texttt{verbatim} code blocks: environments (\vref{lst:verbatimEnvironments}), - commands (\vref{lst:verbatimCommands}) and \texttt{specialBeginEnd} (\vref{lst:special-verb1-yaml}). - \index{specialBeginEnd!poly-switch summary} - \index{verbatim!poly-switch summary} - \index{poly-switches!summary of all poly-switches} - - \clearpage - \begin{longtable}{llll} - \caption{Poly-switch mappings for all code-block types}\label{tab:poly-switch-mapping} \\ - \toprule - Code block & Sample & \multicolumn{2}{c}{Poly-switch mapping} \\ - \midrule - environment & \verb!before words!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & BeginStartsOnOwnLine \\ - & \verb!\begin{myenv}!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & BodyStartsOnOwnLine \\ - & \verb!body of myenv!$\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & EndStartsOnOwnLine \\ - & \verb!\end{myenv}!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & EndFinishesWithLineBreak \\ - & \verb!after words! & & \\ - \cmidrule{2-4} - ifelsefi & \verb!before words!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & IfStartsOnOwnLine \\ - & \verb!\if...!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & BodyStartsOnOwnLine \\ - & \verb!body of if/or statement!$\OrStartsOnOwnLine$ & $\OrStartsOnOwnLine$ & OrStartsOnOwnLine % - \announce{2018-04-27}{new ifElseFi code block poly-switches} \\ - & \verb!\or!$\OrFinishesWithLineBreak$ & $\OrFinishesWithLineBreak$ & OrFinishesWithLineBreak \\ - & \verb!body of if/or statement!$\ElseStartsOnOwnLine$ & $\ElseStartsOnOwnLine$ & ElseStartsOnOwnLine \\ - & \verb!\else!$\ElseFinishesWithLineBreak$ & $\ElseFinishesWithLineBreak$ & ElseFinishesWithLineBreak \\ - & \verb!body of else statement!$\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & FiStartsOnOwnLine \\ - & \verb!\fi!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & FiFinishesWithLineBreak \\ - & \verb!after words! & & \\ - \cmidrule{2-4} - optionalArguments & \verb!...!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & LSqBStartsOnOwnLine\footnote{LSqB stands for Left Square Bracket} \\ - & \verb![!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & OptArgBodyStartsOnOwnLine \\ - \announce{2019-07-13}{new comma-related poly-switches} & \verb!value before comma!$\ElseStartsOnOwnLine$, & $\ElseStartsOnOwnLine$ & CommaStartsOnOwnLine \\ - & $\ElseFinishesWithLineBreak$ & $\ElseFinishesWithLineBreak$ & CommaFinishesWithLineBreak \\ - & \verb!end of body of opt arg!$\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & RSqBStartsOnOwnLine \\ - & \verb!]!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & RSqBFinishesWithLineBreak \\ - & \verb!...! & & \\ - \cmidrule{2-4} - mandatoryArguments & \verb!...!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & LCuBStartsOnOwnLine\footnote{LCuB stands for Left Curly Brace} \\ - & \verb!{!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & MandArgBodyStartsOnOwnLine \\ - \announce{2019-07-13}{new comma-related poly-switches} & \verb!value before comma!$\ElseStartsOnOwnLine$, & $\ElseStartsOnOwnLine$ & CommaStartsOnOwnLine \\ - & $\ElseFinishesWithLineBreak$ & $\ElseFinishesWithLineBreak$ & CommaFinishesWithLineBreak \\ - & \verb!end of body of mand arg!$\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & RCuBStartsOnOwnLine \\ - & \verb!}!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & RCuBFinishesWithLineBreak \\ - & \verb!...! & & \\ - \cmidrule{2-4} - commands & \verb!before words!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & CommandStartsOnOwnLine \\ - & \verb!\mycommand!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & CommandNameFinishesWithLineBreak \\ - & $\langle$\itshape{arguments}$\rangle$ & & \\ - \cmidrule{2-4} - namedGroupingBraces Brackets & before words$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & NameStartsOnOwnLine \\ - & myname$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & NameFinishesWithLineBreak \\ - & $\langle$\itshape{braces/brackets}$\rangle$ & & \\ - \cmidrule{2-4} - keyEqualsValuesBraces\newline Brackets & before words$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & KeyStartsOnOwnLine \\ - & key$\EqualsStartsOnOwnLine$=$\BodyStartsOnOwnLine$ & $\EqualsStartsOnOwnLine$ & EqualsStartsOnOwnLine \\ - & $\langle$\itshape{braces/brackets}$\rangle$ & $\BodyStartsOnOwnLine$ & EqualsFinishesWithLineBreak \\ - \cmidrule{2-4} - items & before words$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & ItemStartsOnOwnLine \\ - & \verb!\item!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & ItemFinishesWithLineBreak \\ - & \verb!...! & & \\ - \cmidrule{2-4} - specialBeginEnd & before words$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & SpecialBeginStartsOnOwnLine \\ - & \verb!\[!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & SpecialBodyStartsOnOwnLine \\ - & \verb!body of special/middle!$\ElseStartsOnOwnLine$ & $\ElseStartsOnOwnLine$ & SpecialMiddleStartsOnOwnLine % - \announce{2018-04-27}{new special code block poly-switches} \\ - & \verb!\middle!$\ElseFinishesWithLineBreak$ & $\ElseFinishesWithLineBreak$ & SpecialMiddleFinishesWithLineBreak \\ - & body of special/middle $\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & SpecialEndStartsOnOwnLine \\ - & \verb!\]!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & SpecialEndFinishesWithLineBreak \\ - & after words & & \\ - \cmidrule{2-4} - verbatim & before words$\BeginStartsOnOwnLine$\verb!\begin{verbatim}! & $\BeginStartsOnOwnLine$ & VerbatimBeginStartsOnOwnLine \\ - \announce{2019-05-05}{verbatim poly-switches} & body of verbatim \verb!\end{verbatim}!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & VerbatimEndFinishesWithLineBreak \\ - & after words & & \\ - \bottomrule - \end{longtable} diff --git a/support/latexindent/documentation/subsec-combine-text-wrap-para-line-breaks.tex b/support/latexindent/documentation/subsec-combine-text-wrap-para-line-breaks.tex new file mode 100644 index 0000000000..2c05d60dda --- /dev/null +++ b/support/latexindent/documentation/subsec-combine-text-wrap-para-line-breaks.tex @@ -0,0 +1,112 @@ +% arara: pdflatex: {shell: yes, files: [latexindent]} +\subsection{Combining removeParagraphLineBreaks and textWrapOptions}\label{subsec:removeparagraphlinebreaks:and:textwrap} + + The% + \announce{2018-08-13}{combine text wrap and remove paragraph line breaks} text wrapping routine (\vref{subsec:textwrapping}) and remove + paragraph line breaks routine (\vref{subsec:removeparagraphlinebreaks}) can be combined. + + We motivate this feature with the code given in \cref{lst:textwrap7}. + + \cmhlistingsfromfile{demonstrations/textwrap7.tex}{\texttt{textwrap7.tex}}{lst:textwrap7} + + Applying the text wrap routine from \vref{subsec:textwrapping} with, for example, + \vref{lst:textwrap3-yaml} gives the output in \cref{lst:textwrap7-mod3}. + + \cmhlistingsfromfile{demonstrations/textwrap7-mod3.tex}{\texttt{textwrap7.tex} using \cref{lst:textwrap3-yaml}}{lst:textwrap7-mod3} + + The text wrapping routine has behaved as expected, but it may be desired to remove + paragraph line breaks \emph{before} performing the text wrapping routine. The desired + behaviour can be achieved by employing the \texttt{beforeTextWrap} switch. + + Explicitly, using the settings in \cref{lst:textwrap12-yaml} and running the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{commandshell} +latexindent.pl -m textwrap7.tex -l=textwrap12.yaml -o=+-mod12 +\end{commandshell} + we obtain the output in \cref{lst:textwrap7-mod12}. + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/textwrap7-mod12.tex}{\texttt{textwrap7-mod12.tex}}{lst:textwrap7-mod12} + \cmhlistingsfromfile{demonstrations/textwrap12.yaml}[MLB-TCB]{\texttt{textwrap12.yaml}}{lst:textwrap12-yaml} + \end{cmhtcbraster} + + In \cref{lst:textwrap7-mod12} the paragraph line breaks have first been removed from + \cref{lst:textwrap7}, and then the text wrapping routine has been applied. It is + envisaged that variants of \cref{lst:textwrap12-yaml} will be among the most useful + settings for these two features. + +\subsubsection{text wrapping beforeFindingChildCodeBlocks}\label{subsubsec:text-wrap-remove-para-bfccb} + + \index{text wrap!recommended starting point} + + I% + \announce*{2021-07-31}{textWrapOptions new feature: beforeFindingChildCodeBlocks} think it likely that most users will wish to employ the + \texttt{beforeFindingChildCodeBlocks} option for the text wrap routine. + + To motivate its use, we begin with the file in \cref{lst:textwrap-bfccb}. + + \cmhlistingsfromfile*{demonstrations/textwrap-bfccb.tex}{\texttt{textwrap-bfccb.tex}}{lst:textwrap-bfccb} + + Using the settings in \cref{lst:textwrap12-yaml} and running + \begin{commandshell} +latexindent.pl -m textwrap-bfccb.tex -l=textwrap12.yaml -o=+-mod12 +\end{commandshell} + gives the output in \cref{lst:textwrap-bfccb-mod12} + + \cmhlistingsfromfile*{demonstrations/textwrap-bfccb-mod12.tex}{\texttt{textwrap-bfccb-mod12.tex}}{lst:textwrap-bfccb-mod12} + + Note that we have added a `ruler' to \cref{lst:textwrap-bfccb-mod12} to assist with + measuring. + + The output in \cref{lst:textwrap-bfccb-mod12} is not ideal, but it is \emph{expected}. + The reasoning is as follows: + \begin{itemize} + \item \texttt{latexindent.pl} first of all searches for code blocks (see + \vref{tab:code-blocks}); + \item it replaces each code block with a unique identifying string; + \item with the settings of \cref{lst:textwrap12-yaml} in place, it performs the paragraph line + break removal, and then the text wrapping routine first of all on the \texttt{text} + command, and then on the surrounding text; + \item the surrounding text does not know that \texttt{text} is a command. + \end{itemize} + + We can instruct \texttt{latexindent.pl} to perform text wrapping \emph{before searching + for child code blocks} by using the \texttt{beforeFindingChildCodeBlocks} field. + + We save the \emph{quick-start} settings from \cref{lst:textwrap-qs-yaml} into + \cref{lst:textwrap13-yaml} and change the value of \texttt{columns} for demonstration. + Upon running the command + \begin{commandshell} +latexindent.pl -m textwrap-bfccb.tex -l=textwrap13.yaml -o=+-mod13 +\end{commandshell} + we receive the output in \cref{lst:textwrap-bfccb-mod13}. + + \cmhlistingsfromfile*{demonstrations/textwrap13.yaml}[MLB-TCB,width=\linewidth]{\texttt{textwrap13.yaml} (tweaked quick start)}{lst:textwrap13-yaml} + + \cmhlistingsfromfile*{demonstrations/textwrap-bfccb-mod13.tex}{\texttt{textwrap-bfccb-mod13.tex}}{lst:textwrap-bfccb-mod13} + + This output is different from \cref{lst:textwrap-bfccb-mod12}, but is still not ideal, as + the \texttt{test} command has indented its mandatory argument. We can employ + \texttt{noAdditionalIndent} from \vref{sec:noadd-indent-rules} in + \cref{lst:textwrap14-yaml} and run the command + \begin{commandshell} +latexindent.pl -m textwrap-bfccb.tex -l=textwrap14.yaml -o=+-mod14 +\end{commandshell} + to receive the output in \cref{lst:textwrap-bfccb-mod14}. + + \begin{widepage} + \begin{cmhtcbraster} + \cmhlistingsfromfile*{demonstrations/textwrap-bfccb-mod14.tex}{\texttt{textwrap-bfccb-mod14.tex}}{lst:textwrap-bfccb-mod14} + \cmhlistingsfromfile*{demonstrations/textwrap14.yaml}[MLB-TCB]{\texttt{textwrap14.yaml}}{lst:textwrap14-yaml} + \end{cmhtcbraster} + \end{widepage} + + For reference, let's say that we had started from \cref{lst:textwrap12-yaml}, which + instructs \texttt{latexindent.pl} to apply the text-wrapping and + paragraph-line-break-removal routines to \emph{all} code blocks. In order to achieve the + output in \cref{lst:textwrap-bfccb-mod14}, then we would need to employ an exception, + which we demonstrate in \cref{lst:textwrap15-yaml}. + + \cmhlistingsfromfile*{demonstrations/textwrap15.yaml}[MLB-TCB]{\texttt{textwrap15.yaml}}{lst:textwrap15-yaml} diff --git a/support/latexindent/documentation/subsec-commands-and-their-options.tex b/support/latexindent/documentation/subsec-commands-and-their-options.tex index d38d4e3f54..79e0a288f0 100644 --- a/support/latexindent/documentation/subsec-commands-and-their-options.tex +++ b/support/latexindent/documentation/subsec-commands-and-their-options.tex @@ -1,23 +1,22 @@ % arara: pdflatex: {shell: yes, files: [latexindent]} -\subsection{Commands and the strings between their arguments}\label{subsec:commands-string-between} - The \texttt{command} code blocks will always look for optional (square bracketed) - and mandatory (curly braced) arguments which can contain comments, line breaks and - `beamer' commands \lstinline!<.*?>! between them. There are switches that can allow - them to contain other strings, which we discuss next. +\subsection{Commands and the strings between their arguments}\label{subsec:commands-string-between} The \texttt{command} code blocks will + always look for optional (square bracketed) and mandatory (curly braced) arguments which + can contain comments, line breaks and `beamer' commands \lstinline!<.*?>! between them. + There are switches that can allow them to contain other strings, which we discuss next. \yamltitle{commandCodeBlocks}*{fields} The \texttt{commandCodeBlocks} field% - \announce{2018-04-27}*{commandCodeBlocks} - contains a few switches detailed in \cref{lst:commandCodeBlocks}. + \announce{2018-04-27}*{commandCodeBlocks} contains a few switches detailed in + \cref{lst:commandCodeBlocks}. \cmhlistingsfromfile[style=commandCodeBlocks]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{commandCodeBlocks}}{lst:commandCodeBlocks} \yamltitle{roundParenthesesAllowed}{0|1} The need for this field was mostly motivated by commands found in code used to generate - images in \texttt{PSTricks} and \texttt{tikz}; for example, let's consider - the code given in \cref{lst:pstricks1}. + images in \texttt{PSTricks} and \texttt{tikz}; for example, let's consider the code given + in \cref{lst:pstricks1}. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile{demonstrations/pstricks1.tex}{\texttt{pstricks1.tex}}{lst:pstricks1} @@ -31,33 +30,35 @@ mandatory argument, followed by a round-parenthesis argument, $(u,v)$. By default, because \texttt{roundParenthesesAllowed} is set to $1$ in - \cref{lst:commandCodeBlocks}, then \texttt{latexindent.pl} will allow round parenthesis between - optional and mandatory arguments. In the case of the code in \cref{lst:pstricks1}, - \texttt{latexindent.pl} finds \emph{all} the arguments of + \cref{lst:commandCodeBlocks}, then \texttt{latexindent.pl} will allow round parenthesis + between optional and mandatory arguments. In the case of the code in + \cref{lst:pstricks1}, \texttt{latexindent.pl} finds \emph{all} the arguments of \lstinline!defFunction!, both before and after \lstinline!(u,v)!. The default output from running \texttt{latexindent.pl} on \cref{lst:pstricks1} actually - leaves it unchanged (see \cref{lst:pstricks1-default}); note in particular, this is because of - \texttt{noAdditionalIndentGlobal} as discussed on \cpageref{page:command:noAddGlobal}. + leaves it unchanged (see \cref{lst:pstricks1-default}); note in particular, this is + because of \texttt{noAdditionalIndentGlobal} as discussed on + \cpageref{page:command:noAddGlobal}. Upon using the YAML settings in \cref{lst:noRoundParentheses}, and running the command \index{switches!-l demonstration} \begin{commandshell} latexindent.pl pstricks1.tex -l noRoundParentheses.yaml \end{commandshell} - we obtain the output given in \cref{lst:pstricks1-nrp}. + we obtain the output given in \cref{lst:pstricks1-nrp}. \begin{cmhtcbraster}[raster column skip=.1\linewidth] \cmhlistingsfromfile{demonstrations/pstricks1-nrp.tex}{\texttt{pstricks1.tex} using \cref{lst:noRoundParentheses}}{lst:pstricks1-nrp} \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/noRoundParentheses.yaml}[yaml-TCB]{\texttt{noRoundParentheses.yaml}}{lst:noRoundParentheses} \end{cmhtcbraster} - Notice the difference between \cref{lst:pstricks1-default} and \cref{lst:pstricks1-nrp}; in - particular, in \cref{lst:pstricks1-nrp}, because round parentheses are - \emph{not} allowed, \texttt{latexindent.pl} finds that the - \lstinline!\defFunction! command finishes at the first opening round parenthesis. As such, - the remaining braced, mandatory, arguments are found to be \texttt{UnNamedGroupingBracesBrackets} (see \vref{tab:code-blocks}) which, - by default, assume indentation for their body, and hence the tabbed indentation in + Notice the difference between \cref{lst:pstricks1-default} and \cref{lst:pstricks1-nrp}; + in particular, in \cref{lst:pstricks1-nrp}, because round parentheses are \emph{not} + allowed, \texttt{latexindent.pl} finds that the + \lstinline!\defFunction! command finishes at the first opening round parenthesis. As + such, the remaining braced, mandatory, arguments are found to be + \texttt{UnNamedGroupingBracesBrackets} (see \vref{tab:code-blocks}) which, by default, + assume indentation for their body, and hence the tabbed indentation in \cref{lst:pstricks1-nrp}. Let's explore this using the YAML given in \cref{lst:defFunction} and run the command @@ -104,14 +105,13 @@ latexindent.pl pstricks1.tex -l defFunction.yaml \item the string \lstinline!to! (specified in \texttt{stringsAllowedBetweenArguments}) \item the optional argument \lstinline![in=110,out=-90]! \item the string \lstinline!++! (specified in \texttt{stringsAllowedBetweenArguments}) - \item the round-bracketed argument \lstinline!(0,-0.5cm)! because \texttt{roundParenthesesAllowed} is - $1$ by default + \item the round-bracketed argument \lstinline!(0,-0.5cm)! because + \texttt{roundParenthesesAllowed} is $1$ by default \item the string \lstinline!node! (specified in \texttt{stringsAllowedBetweenArguments}) \item the optional argument \lstinline![below,align=left,scale=0.5]! \end{itemize} - We can explore this further, for example using \cref{lst:draw} and running the - command + We can explore this further, for example using \cref{lst:draw} and running the command \index{switches!-l demonstration} \begin{commandshell} latexindent.pl tikz-node1.tex -l draw.yaml @@ -127,8 +127,8 @@ latexindent.pl tikz-node1.tex -l draw.yaml \cref{lst:tikz-node1-draw} has been given the appropriate two-spaces worth of indentation specified in \cref{lst:draw}. - Let's compare this with the output from using the YAML settings in - \cref{lst:no-strings}, and running the command + Let's compare this with the output from using the YAML settings in \cref{lst:no-strings}, + and running the command \index{switches!-l demonstration} \begin{commandshell} latexindent.pl tikz-node1.tex -l no-strings.yaml @@ -145,18 +145,19 @@ latexindent.pl tikz-node1.tex -l no-strings.yaml \item the \lstinline!\draw! command finishes after the \lstinline!(c)!, as \texttt{stringsAllowedBetweenArguments} has been set to $0$ so there are no strings allowed between arguments; - \item it finds a \texttt{namedGroupingBracesBrackets} called \texttt{to} (see \vref{tab:code-blocks}) \emph{with} - argument \lstinline![in=110,out=-90]! - \item it finds another \texttt{namedGroupingBracesBrackets} but this time called \texttt{node} with - argument \lstinline![below,align=left,scale=0.5]! + \item it finds a \texttt{namedGroupingBracesBrackets} called \texttt{to} (see + \vref{tab:code-blocks}) \emph{with} argument \lstinline![in=110,out=-90]! + \item it finds another \texttt{namedGroupingBracesBrackets} but this time called \texttt{node} + with argument \lstinline![below,align=left,scale=0.5]! \end{itemize} Referencing \vref{lst:commandCodeBlocks},% - \announce{2018-04-27}*{amalgamate feature in commandCodeBlocks}, we see that the first field in the \texttt{stringsAllowedBetweenArguments} is - \texttt{amalgamate} and is set to \texttt{1} by default. This is for - users who wish to specify their settings in multiple YAML files. For example, by using - the settings in either \cref{lst:amalgamate-demo} or\cref{lst:amalgamate-demo1} is equivalent to - using the settings in \cref{lst:amalgamate-demo2}. + \announce{2018-04-27}*{amalgamate feature in commandCodeBlocks}, we see that the first + field in the \texttt{stringsAllowedBetweenArguments} is \texttt{amalgamate} and is set to + \texttt{1} by default. This is for users who wish to specify their settings in multiple + YAML files. For example, by using the settings in either \cref{lst:amalgamate-demo} + or\cref{lst:amalgamate-demo1} is equivalent to using the settings in + \cref{lst:amalgamate-demo2}. \begin{cmhtcbraster}[raster columns=3, raster left skip=-3.5cm, @@ -167,26 +168,27 @@ latexindent.pl tikz-node1.tex -l no-strings.yaml \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/amalgamate-demo2.yaml}[yaml-TCB]{\texttt{amalgamate-demo2.yaml}}{lst:amalgamate-demo2} \end{cmhtcbraster} - We specify \texttt{amalgamate} to be set to \texttt{0} and in which case - any settings loaded prior to those specified, including the default, will be overwritten. - For example, using the settings in \cref{lst:amalgamate-demo3} means that only the strings - specified in that field will be used. + We specify \texttt{amalgamate} to be set to \texttt{0} and in which case any settings + loaded prior to those specified, including the default, will be overwritten. For example, + using the settings in \cref{lst:amalgamate-demo3} means that only the strings specified + in that field will be used. \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/amalgamate-demo3.yaml}[yaml-TCB]{\texttt{amalgamate-demo3.yaml}}{lst:amalgamate-demo3} - It is important to note that the \texttt{amalgamate} field, if used, must be in the - first field, and specified using the syntax given in \cref{lst:amalgamate-demo1,lst:amalgamate-demo2,lst:amalgamate-demo3}. + It is important to note that the \texttt{amalgamate} field, if used, must be in the first + field, and specified using the syntax given in + \cref{lst:amalgamate-demo1,lst:amalgamate-demo2,lst:amalgamate-demo3}. - We may explore this feature further with the code in \cref{lst:for-each}, whose - default output is given in \cref{lst:for-each-default}. + We may explore this feature further with the code in \cref{lst:for-each}, whose default + output is given in \cref{lst:for-each-default}. \begin{cmhtcbraster}[raster column skip=.1\linewidth] \cmhlistingsfromfile{demonstrations/for-each.tex}{\texttt{for-each.tex}}{lst:for-each} \cmhlistingsfromfile{demonstrations/for-each-default.tex}{\texttt{for-each} default output}{lst:for-each-default} \end{cmhtcbraster} - Let's compare this with the output from using the YAML settings in - \cref{lst:foreach}, and running the command + Let's compare this with the output from using the YAML settings in \cref{lst:foreach}, + and running the command \index{switches!-l demonstration} \begin{commandshell} latexindent.pl for-each.tex -l foreach.yaml @@ -200,41 +202,42 @@ latexindent.pl for-each.tex -l foreach.yaml You might like to compare the output given in \cref{lst:for-each-default} and \cref{lst:for-each-mod1}. Note,in particular, in \cref{lst:for-each-default} that the - \texttt{foreach} command has not included any of the subsequent strings, and that - the braces have been treated as a \texttt{namedGroupingBracesBrackets}. In \cref{lst:for-each-mod1} the - \texttt{foreach} command has been allowed to have \lstinline!\x/\y! and - \texttt{in} between arguments because of the settings given in - \cref{lst:foreach}. + \texttt{foreach} command has not included any of the subsequent strings, and that the + braces have been treated as a \texttt{namedGroupingBracesBrackets}. In + \cref{lst:for-each-mod1} the \texttt{foreach} command has been allowed to have + \lstinline!\x/\y! and \texttt{in} between arguments because of the settings given + in \cref{lst:foreach}. \yamltitle{commandNameSpecial}*{fields} There are some special command names% \announce{2018-04-27}*{commandNameSpecial} that do not fit within the names recognised by \texttt{latexindent.pl}, the first one of which is \lstinline!\@ifnextchar[!. From the - perspective of \texttt{latexindent.pl}, the whole of the text \lstinline!\@ifnextchar[! is - a command, because it is immediately followed by sets of mandatory arguments. However, - without the \texttt{commandNameSpecial} field, \texttt{latexindent.pl} would not be able to - label it as such, because the \lstinline![! is, necessarily, not matched by a - closing \lstinline!]!. + perspective of \texttt{latexindent.pl}, the whole of the text \lstinline!\@ifnextchar[! + is a command, because it is immediately followed by sets of mandatory arguments. However, + without the \texttt{commandNameSpecial} field, \texttt{latexindent.pl} would not be able + to label it as such, because the \lstinline![! is, necessarily, not matched by a closing + \lstinline!]!. - For example, consider the sample file in \cref{lst:ifnextchar}, which has default - output in \cref{lst:ifnextchar-default}. + For example, consider the sample file in \cref{lst:ifnextchar}, which has default output + in \cref{lst:ifnextchar-default}. \begin{cmhtcbraster}[raster column skip=.1\linewidth] \cmhlistingsfromfile{demonstrations/ifnextchar.tex}{\texttt{ifnextchar.tex}}{lst:ifnextchar} \cmhlistingsfromfile{demonstrations/ifnextchar-default.tex}{\texttt{ifnextchar.tex} default output}{lst:ifnextchar-default} \end{cmhtcbraster} - Notice that in \cref{lst:ifnextchar-default} the \texttt{parbox} command has been able - to indent its body, because \texttt{latexindent.pl} has successfully found the command + Notice that in \cref{lst:ifnextchar-default} the \texttt{parbox} command has been able to + indent its body, because \texttt{latexindent.pl} has successfully found the command \lstinline!\@ifnextchar! first; the pattern-matching of \texttt{latexindent.pl} starts - from \emph{the inner most <thing> and works outwards}, discussed in more detail on \cpageref{page:phases}. + from \emph{the inner most <thing> and works outwards}, discussed in more detail on + \cpageref{page:phases}. - For demonstration, we can compare this output with that given in \cref{lst:ifnextchar-off} - in which the settings from \cref{lst:no-ifnextchar} have dictated that no special command - names, including the \lstinline!\@ifnextchar[! command, should not be searched for - specially; as such, the \texttt{parbox} command has been \emph{unable} - to indent its body successfully, because the \lstinline!\@ifnextchar[! command has not been - found. + For demonstration, we can compare this output with that given in + \cref{lst:ifnextchar-off} in which the settings from \cref{lst:no-ifnextchar} have + dictated that no special command names, including the \lstinline!\@ifnextchar[! command, + should not be searched for specially; as such, the \texttt{parbox} command has been + \emph{unable} to indent its body successfully, because the \lstinline!\@ifnextchar[! + command has not been found. \begin{cmhtcbraster}[raster column skip=.1\linewidth] \cmhlistingsfromfile{demonstrations/ifnextchar-off.tex}{\texttt{ifnextchar.tex} using \cref{lst:no-ifnextchar}}{lst:ifnextchar-off} @@ -242,8 +245,8 @@ latexindent.pl for-each.tex -l foreach.yaml \end{cmhtcbraster} The \texttt{amalgamate} field can be used for \texttt{commandNameSpecial}, just as for - \texttt{stringsAllowedBetweenArguments}. The same condition holds as stated previously, which we state - again here: + \texttt{stringsAllowedBetweenArguments}. The same condition holds as stated previously, + which we state again here: \index{warning!amalgamate field} \begin{warning} diff --git a/support/latexindent/documentation/subsec-conflicting-poly-switches.tex b/support/latexindent/documentation/subsec-conflicting-poly-switches.tex deleted file mode 100644 index a4b98981d2..0000000000 --- a/support/latexindent/documentation/subsec-conflicting-poly-switches.tex +++ /dev/null @@ -1,170 +0,0 @@ -% arara: pdflatex: {shell: yes, files: [latexindent]} -\subsection{Conflicting poly-switches: sequential code blocks} - It is very easy to have conflicting poly-switches; if we use the example from - \vref{lst:mycommand1}, and consider the YAML settings given in \cref{lst:mycom-mlb4}. - The output from running - \index{poly-switches!conflicting switches} - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m -l=mycom-mlb4.yaml mycommand1.tex -\end{commandshell} - is given in \cref{lst:mycom-mlb4}. - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/mycommand1-mlb4.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb4}}{lst:mycommand1-mlb4} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb4.yaml}[MLB-TCB,width=\linewidth]{\texttt{mycom-mlb4.yaml}}{lst:mycom-mlb4} - \end{cmhtcbraster} - - Studying \cref{lst:mycom-mlb4}, we see that the two poly-switches are at opposition with - one another: - \begin{itemize} - \item on the one hand, \texttt{LCuBStartsOnOwnLine} should \emph{not} start on its own line - (as poly-switch is set to $-1$); - \item on the other hand, \texttt{RCuBFinishesWithLineBreak} \emph{should} finish with a line break. - \end{itemize} - So, which should win the conflict? As demonstrated in \cref{lst:mycommand1-mlb4}, it is clear - that \texttt{LCuBStartsOnOwnLine} won this conflict, and the reason is that - \emph{the second argument was processed after the first} -- in general, the most recently-processed code block and - associated poly-switch takes priority. - - We can explore this further by considering the YAML settings in \cref{lst:mycom-mlb5}; - upon running the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m -l=mycom-mlb5.yaml mycommand1.tex -\end{commandshell} - we obtain the output given in \cref{lst:mycommand1-mlb5}. - - \begin{cmhtcbraster}[raster column skip=.1\linewidth] - \cmhlistingsfromfile{demonstrations/mycommand1-mlb5.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb5}}{lst:mycommand1-mlb5} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb5.yaml}[MLB-TCB,width=\linewidth]{\texttt{mycom-mlb5.yaml}}{lst:mycom-mlb5} - \end{cmhtcbraster} - - As previously, the most-recently-processed code block takes priority -- as before, the - second (i.e, \emph{last}) argument. Exploring this further, we consider the - YAML settings in \cref{lst:mycom-mlb6}, which give associated output in - \cref{lst:mycommand1-mlb6}. - - \begin{cmhtcbraster}[raster column skip=.1\linewidth] - \cmhlistingsfromfile{demonstrations/mycommand1-mlb6.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb6}}{lst:mycommand1-mlb6} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb6.yaml}[MLB-TCB,width=\linewidth]{\texttt{mycom-mlb6.yaml}}{lst:mycom-mlb6} - \end{cmhtcbraster} - - Note that a \lstinline!%! \emph{has} been added to the trailing - first \lstinline!}!; this is because: - \begin{itemize} - \item while processing the \emph{first} argument, the trailing line break has been - removed (\texttt{RCuBFinishesWithLineBreak} set to $-1$); - \item while processing the \emph{second} argument, \texttt{latexindent.pl} finds that - it does \emph{not} begin on its own line, and so because - \texttt{LCuBStartsOnOwnLine} is set to $2$, it adds a comment, followed by a - line break. - \end{itemize} - -\subsection{Conflicting poly-switches: nested code blocks} - Now let's consider an example when nested code blocks have conflicting poly-switches; - we'll use the code in \cref{lst:nested-env}, noting that it contains nested - environments. - \index{poly-switches!conflicting switches} - - \cmhlistingsfromfile{demonstrations/nested-env.tex}{\texttt{nested-env.tex}}{lst:nested-env} - - Let's use the YAML settings given in \cref{lst:nested-env-mlb1-yaml}, which upon running the - command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m -l=nested-env-mlb1.yaml nested-env.tex -\end{commandshell} - gives the output in \cref{lst:nested-env-mlb1}. - - \begin{cmhtcbraster}[raster column skip=.05\linewidth] - \cmhlistingsfromfile{demonstrations/nested-env-mlb1.tex}{\texttt{nested-env.tex} using \cref{lst:nested-env-mlb1-yaml}}{lst:nested-env-mlb1} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/nested-env-mlb1.yaml}[MLB-TCB,width=\linewidth]{\texttt{nested-env-mlb1.yaml}}{lst:nested-env-mlb1-yaml} - \end{cmhtcbraster} - - In \cref{lst:nested-env-mlb1}, let's first of all note that both environments have received - the appropriate (default) indentation; secondly, note that the poly-switch - \texttt{EndStartsOnOwnLine} appears to have won the conflict, as \lstinline!\end{one}! has - had its leading line break removed. - - To understand it, let's talk about the three basic phases \label{page:phases}of - \texttt{latexindent.pl}: - \begin{enumerate} - \item Phase 1: packing, in which code blocks are replaced with unique ids, working from - \emph{the inside to the outside}, and then sequentially -- for example, in \cref{lst:nested-env}, - the \texttt{two} environment is found \emph{before} the - \texttt{one} environment; if the -m switch is active, then during this phase: - \begin{itemize} - \item line breaks at the beginning of the \texttt{body} can be added (if - \texttt{BodyStartsOnOwnLine} is $1$ or $2$) or removed (if - \texttt{BodyStartsOnOwnLine} is $-1$); - \item line breaks at the end of the body can be added (if \texttt{EndStartsOnOwnLine} is - $1$ or $2$) or removed (if \texttt{EndStartsOnOwnLine} is - $-1$); - \item line breaks after the end statement can be added (if \texttt{EndFinishesWithLineBreak} is - $1$ or $2$). - \end{itemize} - \item Phase 2: indentation, in which white space is added to the begin, body, and end - statements; - \item Phase 3: unpacking, in which unique ids are replaced by their \emph{indented} code - blocks; if the -m switch is active, then during this phase, - \begin{itemize} - \item line breaks before \texttt{begin} statements can be added or removed (depending - upon \texttt{BeginStartsOnOwnLine}); - \item line breaks after \emph{end} statements can be removed but - \emph{NOT} added (see \texttt{EndFinishesWithLineBreak}). - \end{itemize} - \end{enumerate} - - With reference to \cref{lst:nested-env-mlb1}, this means that during Phase 1: - \begin{itemize} - \item the \texttt{two} environment is found first, and the line break ahead of the - \lstinline!\end{two}! statement is removed because \texttt{EndStartsOnOwnLine} is set to - $-1$. Importantly, because, \emph{at this stage}, - \lstinline!\end{two}! \emph{does} finish with a line break, - \texttt{EndFinishesWithLineBreak} causes no action. - \item next, the \texttt{one} environment is found; the line break ahead of - \lstinline!\end{one}! is removed because \texttt{EndStartsOnOwnLine} is set to - $-1$. - \end{itemize} - The indentation is done in Phase 2; in Phase 3 \emph{there is no option to add a line break after the \lstinline!end! statements}. We can justify - this by remembering that during Phase 3, the \texttt{one} environment will be - found and processed first, followed by the \texttt{two} environment. If the - \texttt{two} environment were to add a line break after the - \lstinline!\end{two}! statement, then \texttt{latexindent.pl} would have no way of - knowing how much indentation to add to the subsequent text (in this case, - \lstinline!\end{one}!). - - We can explore this further using the poly-switches in \cref{lst:nested-env-mlb2}; upon - running the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m -l=nested-env-mlb2.yaml nested-env.tex -\end{commandshell} - we obtain the output given in \cref{lst:nested-env-mlb2-output}. - - \begin{cmhtcbraster} - \cmhlistingsfromfile{demonstrations/nested-env-mlb2.tex}{\texttt{nested-env.tex} using \cref{lst:nested-env-mlb2}}{lst:nested-env-mlb2-output} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/nested-env-mlb2.yaml}[MLB-TCB,width=\linewidth]{\texttt{nested-env-mlb2.yaml}}{lst:nested-env-mlb2} - \end{cmhtcbraster} - - During Phase 1: - \begin{itemize} - \item the \texttt{two} environment is found first, and the line break ahead of the - \lstinline!\end{two}! statement is not changed because \texttt{EndStartsOnOwnLine} is set to - $1$. Importantly, because, \emph{at this stage}, - \lstinline!\end{two}! \emph{does} finish with a line break, - \texttt{EndFinishesWithLineBreak} causes no action. - \item next, the \texttt{one} environment is found; the line break ahead of - \lstinline!\end{one}! is already present, and no action is needed. - \end{itemize} - The indentation is done in Phase 2, and then in Phase 3, the \texttt{one} - environment is found and processed first, followed by the \texttt{two} - environment. \emph{At this stage}, the \texttt{two} environment finds - \texttt{EndFinishesWithLineBreak} is $-1$, so it removes the trailing line break; - remember, at this point, \texttt{latexindent.pl} has completely finished with the - \texttt{one} environment. diff --git a/support/latexindent/documentation/subsec-noAdditionalIndent-indentRules.tex b/support/latexindent/documentation/subsec-noAdditionalIndent-indentRules.tex index 4bb5d127e5..56e5bed091 100644 --- a/support/latexindent/documentation/subsec-noAdditionalIndent-indentRules.tex +++ b/support/latexindent/documentation/subsec-noAdditionalIndent-indentRules.tex @@ -8,12 +8,15 @@ \subsection{noAdditionalIndent and indentRules}\label{sec:noadd-indent-rules} \texttt{latexindent.pl} operates on files by looking for code blocks, as detailed in \vref{subsubsec:code-blocks}; - for each type of code block in \vref{tab:code-blocks} (which we will call a \emph{$\langle$thing$\rangle$} in what follows) it searches YAML fields for - information in the following order: + for each type of code block in \vref{tab:code-blocks} (which we will call a + \emph{$\langle$thing$\rangle$} in what follows) it searches YAML fields for information + in the following order: \begin{enumerate} - \item \texttt{noAdditionalIndent} for the \emph{name} of the current \emph{$\langle$thing$\rangle$}; + \item \texttt{noAdditionalIndent} for the \emph{name} of the current + \emph{$\langle$thing$\rangle$}; \item \texttt{indentRules} for the \emph{name} of the current \emph{$\langle$thing$\rangle$}; - \item \texttt{noAdditionalIndentGlobal} for the \emph{type} of the current \emph{$\langle$thing$\rangle$}; + \item \texttt{noAdditionalIndentGlobal} for the \emph{type} of the current + \emph{$\langle$thing$\rangle$}; \item \texttt{indentRulesGlobal} for the \emph{type} of the current \emph{$\langle$thing$\rangle$}. \end{enumerate} @@ -21,8 +24,9 @@ Using the above list, the first piece of information to be found will be used; failing that, the value of \texttt{defaultIndent} is used. If information is found in multiple fields, the first one according to the list above will be used; for example, if - information is present in both \texttt{indentRules} and in \texttt{noAdditionalIndentGlobal}, then - the information from \texttt{indentRules} takes priority. + information is present in both \texttt{indentRules} and in + \texttt{noAdditionalIndentGlobal}, then the information from \texttt{indentRules} takes + priority. We now present details for the different type of code blocks known to \texttt{latexindent.pl}, as detailed in \vref{tab:code-blocks}; for reference, there diff --git a/support/latexindent/documentation/subsec-one-sentence-per-line.tex b/support/latexindent/documentation/subsec-one-sentence-per-line.tex new file mode 100644 index 0000000000..9fbaaade5d --- /dev/null +++ b/support/latexindent/documentation/subsec-one-sentence-per-line.tex @@ -0,0 +1,404 @@ +% arara: pdflatex: {shell: yes, files: [latexindent]} +\subsection{oneSentencePerLine: modifying line breaks for sentences}\label{sec:onesentenceperline} + + You can instruct \texttt{latexindent.pl} to format% + \announce{2018-01-13}{one sentence per line} your file so that it puts one sentence per + line. Thank you to \cite{mlep} for helping to shape and test this feature. The behaviour + of this part of the script is controlled by the switches detailed in + \cref{lst:oneSentencePerLine}, all of which we discuss next. + \index{modifying linebreaks! by using one sentence per line} + \index{sentences!oneSentencePerLine} + \index{sentences!one sentence per line} + \index{regular expressions!lowercase alph a-z} + \index{regular expressions!uppercase alph A-Z} + + \cmhlistingsfromfile[style=oneSentencePerLine]*{../defaultSettings.yaml}[MLB-TCB,width=.85\linewidth,before=\centering]{\texttt{oneSentencePerLine}}{lst:oneSentencePerLine} + +\yamltitle{manipulateSentences}{0|1} + This is a binary switch that details if \texttt{latexindent.pl} should perform the + sentence manipulation routine; it is \emph{off} (set to \texttt{0}) by default, and you + will need to turn it on (by setting it to \texttt{1}) if you want the script to modify + line breaks surrounding and within sentences. + +\yamltitle{removeSentenceLineBreaks}{0|1} + When operating upon sentences \texttt{latexindent.pl} will, by default, remove internal + line breaks as \texttt{removeSentenceLineBreaks} is set to \texttt{1}. Setting this + switch to \texttt{0} instructs \texttt{latexindent.pl} not to do so. + \index{sentences!removing sentence line breaks} + + For example, consider \texttt{multiple-sentences.tex} shown in + \cref{lst:multiple-sentences}. + + \cmhlistingsfromfile{demonstrations/multiple-sentences.tex}{\texttt{multiple-sentences.tex}}{lst:multiple-sentences} + + If we use the YAML files in + \cref{lst:manipulate-sentences-yaml,lst:keep-sen-line-breaks-yaml}, and run the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl multiple-sentences -m -l=manipulate-sentences.yaml +latexindent.pl multiple-sentences -m -l=keep-sen-line-breaks.yaml +\end{commandshell} + \end{widepage} + then we obtain the respective output given in + \cref{lst:multiple-sentences-mod1,lst:multiple-sentences-mod2}. + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/multiple-sentences-mod1.tex}{\texttt{multiple-sentences.tex} using \cref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences-mod1} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/manipulate-sentences.yaml}[MLB-TCB]{\texttt{manipulate-sentences.yaml}}{lst:manipulate-sentences-yaml} + \end{cmhtcbraster} + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/multiple-sentences-mod2.tex}{\texttt{multiple-sentences.tex} using \cref{lst:keep-sen-line-breaks-yaml}}{lst:multiple-sentences-mod2} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/keep-sen-line-breaks.yaml}[MLB-TCB]{\texttt{keep-sen-line-breaks.yaml}}{lst:keep-sen-line-breaks-yaml} + \end{cmhtcbraster} + + Notice, in particular, that the `internal' sentence line breaks in + \cref{lst:multiple-sentences} have been removed in \cref{lst:multiple-sentences-mod1}, + but have not been removed in \cref{lst:multiple-sentences-mod2}. + + The remainder of the settings displayed in \vref{lst:oneSentencePerLine} instruct + \texttt{latexindent.pl} on how to define a sentence. From the perspective of + \texttt{latexindent.pl} a sentence must: + \index{sentences!follow} + \index{sentences!begin with} + \index{sentences!end with} + \begin{itemize} + \item \emph{follow} a certain character or set of characters (see + \cref{lst:sentencesFollow}); by default, this is either \lstinline!\par!, a + blank line, a full stop/period (.), exclamation mark (!), question mark (?) right brace + (\}) or a comment on the previous line; + \item \emph{begin} with a character type (see \cref{lst:sentencesBeginWith}); by + default, this is only capital letters; + \item \emph{end} with a character (see \cref{lst:sentencesEndWith}); by + default, these are full stop/period (.), exclamation mark (!) and question mark (?). + \end{itemize} + In each case, you can specify the \texttt{other} field to include any pattern that you + would like; you can specify anything in this field using the language of regular + expressions. + \index{regular expressions!lowercase alph a-z} + \index{regular expressions!uppercase alph A-Z} + + \begin{cmhtcbraster}[raster columns=3, + raster left skip=-3.5cm, + raster right skip=-2cm, + raster column skip=.06\linewidth] + \cmhlistingsfromfile[style=sentencesFollow]*{../defaultSettings.yaml}[MLB-TCB,width=.9\linewidth,before=\centering]{\texttt{sentencesFollow}}{lst:sentencesFollow} + \cmhlistingsfromfile[style=sentencesBeginWith]*{../defaultSettings.yaml}[MLB-TCB,width=.9\linewidth,before=\centering]{\texttt{sentencesBeginWith}}{lst:sentencesBeginWith} + \cmhlistingsfromfile[style=sentencesEndWith]*{../defaultSettings.yaml}[MLB-TCB,width=.9\linewidth,before=\centering]{\texttt{sentencesEndWith}}{lst:sentencesEndWith} + \end{cmhtcbraster} + +\subsubsection{sentencesFollow} + Let's explore a few of the switches in \texttt{sentencesFollow}; let's start with + \vref{lst:multiple-sentences}, and use the YAML settings given in + \cref{lst:sentences-follow1-yaml}. Using the command + \index{sentences!follow} + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl multiple-sentences -m -l=sentences-follow1.yaml +\end{commandshell} + we obtain the output given in \cref{lst:multiple-sentences-mod3}. + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/multiple-sentences-mod3.tex}{\texttt{multiple-sentences.tex} using \cref{lst:sentences-follow1-yaml}}{lst:multiple-sentences-mod3} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-follow1.yaml}[MLB-TCB]{\texttt{sentences-follow1.yaml}}{lst:sentences-follow1-yaml} + \end{cmhtcbraster} + + Notice that, because \texttt{blankLine} is set to \texttt{0}, \texttt{latexindent.pl} + will not seek sentences following a blank line, and so the fourth sentence has not been + accounted for. + + We can explore the \texttt{other} field in \cref{lst:sentencesFollow} with the + \texttt{.tex} file detailed in \cref{lst:multiple-sentences1}. + + \cmhlistingsfromfile{demonstrations/multiple-sentences1.tex}{\texttt{multiple-sentences1.tex}}{lst:multiple-sentences1} + + Upon running the following commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl multiple-sentences1 -m -l=manipulate-sentences.yaml +latexindent.pl multiple-sentences1 -m -l=manipulate-sentences.yaml,sentences-follow2.yaml +\end{commandshell} + \end{widepage} + then we obtain the respective output given in + \cref{lst:multiple-sentences1-mod1,lst:multiple-sentences1-mod2}. + \cmhlistingsfromfile{demonstrations/multiple-sentences1-mod1.tex}{\texttt{multiple-sentences1.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences1-mod1} + + \begin{cmhtcbraster}[ + raster force size=false, + raster column 1/.style={add to width=1cm}, + ] + \cmhlistingsfromfile{demonstrations/multiple-sentences1-mod2.tex}{\texttt{multiple-sentences1.tex} using \cref{lst:sentences-follow2-yaml}}{lst:multiple-sentences1-mod2} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-follow2.yaml}[MLB-TCB,width=.45\textwidth]{\texttt{sentences-follow2.yaml}}{lst:sentences-follow2-yaml} + \end{cmhtcbraster} + + Notice that in \cref{lst:multiple-sentences1-mod1} the first sentence after the + \texttt{)} has not been accounted for, but that following the inclusion of + \cref{lst:sentences-follow2-yaml}, the output given in + \cref{lst:multiple-sentences1-mod2} demonstrates that the sentence \emph{has} been + accounted for correctly. + +\subsubsection{sentencesBeginWith} + By default, \texttt{latexindent.pl} will only assume that sentences begin with the upper + case letters \texttt{A-Z}; you can instruct the script to define sentences to begin with + lower case letters (see \cref{lst:sentencesBeginWith}), and we can use the \texttt{other} + field to define sentences to begin with other characters. + \index{sentences!begin with} + + \cmhlistingsfromfile{demonstrations/multiple-sentences2.tex}{\texttt{multiple-sentences2.tex}}{lst:multiple-sentences2} + + Upon running the following commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl multiple-sentences2 -m -l=manipulate-sentences.yaml +latexindent.pl multiple-sentences2 -m -l=manipulate-sentences.yaml,sentences-begin1.yaml +\end{commandshell} + \end{widepage} + then we obtain the respective output given in + \cref{lst:multiple-sentences2-mod1,lst:multiple-sentences2-mod2}. + \cmhlistingsfromfile{demonstrations/multiple-sentences2-mod1.tex}{\texttt{multiple-sentences2.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences2-mod1} + \index{regular expressions!numeric 0-9} + + \begin{cmhtcbraster}[ + raster force size=false, + raster column 1/.style={add to width=1cm}, + ] + \cmhlistingsfromfile{demonstrations/multiple-sentences2-mod2.tex}{\texttt{multiple-sentences2.tex} using \cref{lst:sentences-begin1-yaml}}{lst:multiple-sentences2-mod2} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-begin1.yaml}[MLB-TCB,width=.45\textwidth]{\texttt{sentences-begin1.yaml}}{lst:sentences-begin1-yaml} + \end{cmhtcbraster} + Notice that in \cref{lst:multiple-sentences2-mod1}, the first sentence has been accounted + for but that the subsequent sentences have not. In \cref{lst:multiple-sentences2-mod2}, + all of the sentences have been accounted for, because the \texttt{other} field in + \cref{lst:sentences-begin1-yaml} has defined sentences to begin with either + \lstinline!$! or any numeric digit, \texttt{0} to + \texttt{9}. + +\subsubsection{sentencesEndWith} + Let's return to \vref{lst:multiple-sentences}; we have already seen the default way in + which \texttt{latexindent.pl} will operate on the sentences in this file in + \vref{lst:multiple-sentences-mod1}. We can populate the \texttt{other} field with any + character that we wish; for example, using the YAML specified in + \cref{lst:sentences-end1-yaml} and the command + \index{sentences!end with} + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl multiple-sentences -m -l=sentences-end1.yaml +latexindent.pl multiple-sentences -m -l=sentences-end2.yaml +\end{commandshell} + then we obtain the output in \cref{lst:multiple-sentences-mod4}. + \index{regular expressions!lowercase alph a-z} + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/multiple-sentences-mod4.tex}{\texttt{multiple-sentences.tex} using \cref{lst:sentences-end1-yaml}}{lst:multiple-sentences-mod4} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-end1.yaml}[MLB-TCB]{\texttt{sentences-end1.yaml}}{lst:sentences-end1-yaml} + \end{cmhtcbraster} + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/multiple-sentences-mod5.tex}{\texttt{multiple-sentences.tex} using \cref{lst:sentences-end2-yaml}}{lst:multiple-sentences-mod5} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentences-end2.yaml}[MLB-TCB]{\texttt{sentences-end2.yaml}}{lst:sentences-end2-yaml} + \end{cmhtcbraster} + + There is a subtle difference between the output in + \cref{lst:multiple-sentences-mod4,lst:multiple-sentences-mod5}; in particular, in + \cref{lst:multiple-sentences-mod4} the word \texttt{sentence} has not been defined as a + sentence, because we have not instructed \texttt{latexindent.pl} to begin sentences with + lower case letters. We have changed this by using the settings in + \cref{lst:sentences-end2-yaml}, and the associated output in + \cref{lst:multiple-sentences-mod5} reflects this. + + Referencing \vref{lst:sentencesEndWith}, you'll notice that there is a field called + \texttt{basicFullStop}, which is set to \texttt{0}, and that the \texttt{betterFullStop} + is set to \texttt{1} by default. + + Let's consider the file shown in \cref{lst:url}. + + \cmhlistingsfromfile{demonstrations/url.tex}{\texttt{url.tex}}{lst:url} + + Upon running the following commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl url -m -l=manipulate-sentences.yaml +\end{commandshell} + we obtain the output given in \cref{lst:url-mod1}. + + \cmhlistingsfromfile{demonstrations/url-mod1.tex}{\texttt{url.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:url-mod1} + + Notice that the full stop within the url has been interpreted correctly. This is because, + within the \texttt{betterFullStop}, full stops at the end of sentences have the following + properties: + \begin{itemize} + \item they are ignored within \texttt{e.g.} and \texttt{i.e.}; + \item they can not be immediately followed by a lower case or upper case letter; + \item they can not be immediately followed by a hyphen, comma, or number. + \end{itemize} + If you find that the \texttt{betterFullStop} does not work for your purposes, then you + can switch it off by setting it to \texttt{0}, and you can experiment with the + \texttt{other} field.% + \announce{2019-07-13}{fine tuning the betterFullStop} You can also seek to customise the \texttt{betterFullStop} + routine by using the \emph{fine tuning}, detailed in \vref{lst:fineTuning}. + + The \texttt{basicFullStop} routine should probably be avoided in most situations, as it + does not accommodate the specifications above. For example, using the following command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl url -m -l=alt-full-stop1.yaml +\end{commandshell} + and the YAML in \cref{lst:alt-full-stop1-yaml} gives the output in \cref{lst:url-mod2}. + + \begin{cmhtcbraster}[ raster left skip=-3.5cm, + raster right skip=-2cm, + raster force size=false, + raster column 1/.style={add to width=.1\textwidth}, + raster column skip=.06\linewidth] + \cmhlistingsfromfile{demonstrations/url-mod2.tex}{\texttt{url.tex} using \cref{lst:alt-full-stop1-yaml}}{lst:url-mod2} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/alt-full-stop1.yaml}[MLB-TCB,width=.5\textwidth]{\texttt{alt-full-stop1.yaml}}{lst:alt-full-stop1-yaml} + \end{cmhtcbraster} + + Notice that the full stop within the URL has not been accommodated correctly because of + the non-default settings in \cref{lst:alt-full-stop1-yaml}. + +\subsubsection{Features of the oneSentencePerLine routine} + The sentence manipulation routine takes place \emph{after} verbatim + \index{verbatim!in relation to oneSentencePerLine} environments, preamble and trailing comments have been + accounted for; this means that any characters within these types of code blocks will not + be part of the sentence manipulation routine. + + For example, if we begin with the \texttt{.tex} file in \cref{lst:multiple-sentences3}, + and run the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl multiple-sentences3 -m -l=manipulate-sentences.yaml +\end{commandshell} + then we obtain the output in \cref{lst:multiple-sentences3-mod1}. + \cmhlistingsfromfile{demonstrations/multiple-sentences3.tex}{\texttt{multiple-sentences3.tex}}{lst:multiple-sentences3} + \cmhlistingsfromfile{demonstrations/multiple-sentences3-mod1.tex}{\texttt{multiple-sentences3.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences3-mod1} + + Furthermore, if sentences run across environments then, by default, the line breaks + internal to the sentence will be removed. For example, if we use the \texttt{.tex} file + in \cref{lst:multiple-sentences4} and run the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl multiple-sentences4 -m -l=manipulate-sentences.yaml +latexindent.pl multiple-sentences4 -m -l=keep-sen-line-breaks.yaml +\end{commandshell} + then we obtain the output in + \cref{lst:multiple-sentences4-mod1,lst:multiple-sentences4-mod2}. + \cmhlistingsfromfile{demonstrations/multiple-sentences4.tex}{\texttt{multiple-sentences4.tex}}{lst:multiple-sentences4} + \begin{widepage} + \cmhlistingsfromfile{demonstrations/multiple-sentences4-mod1.tex}{\texttt{multiple-sentences4.tex} using \vref{lst:manipulate-sentences-yaml}}{lst:multiple-sentences4-mod1} + \end{widepage} + \cmhlistingsfromfile{demonstrations/multiple-sentences4-mod2.tex}{\texttt{multiple-sentences4.tex} using \vref{lst:keep-sen-line-breaks-yaml}}{lst:multiple-sentences4-mod2} + + Once you've read \cref{sec:poly-switches}, you will know that you can accommodate the + removal of internal sentence line breaks by using the YAML in \cref{lst:item-rules2-yaml} + and the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl multiple-sentences4 -m -l=item-rules2.yaml +\end{commandshell} + the output of which is shown in \cref{lst:multiple-sentences4-mod3}. + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/multiple-sentences4-mod3.tex}{\texttt{multiple-sentences4.tex} using \cref{lst:item-rules2-yaml}}{lst:multiple-sentences4-mod3} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/item-rules2.yaml}[MLB-TCB]{\texttt{item-rules2.yaml}}{lst:item-rules2-yaml} + \end{cmhtcbraster} + +\subsubsection{Text wrapping and indenting sentences} + The \texttt{oneSentencePerLine}% + \announce{2018-08-13}{oneSentencePerline text wrap and indent} can be instructed to + perform text wrapping and indentation upon sentences. + \index{sentences!text wrapping} + \index{sentences!indenting} + + Let's use the code in \cref{lst:multiple-sentences5}. + + \cmhlistingsfromfile{demonstrations/multiple-sentences5.tex}{\texttt{multiple-sentences5.tex}}{lst:multiple-sentences5} + + Referencing \cref{lst:sentence-wrap1-yaml}, and running the following command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl multiple-sentences5 -m -l=sentence-wrap1.yaml +\end{commandshell} + we receive the output given in \cref{lst:multiple-sentences5-mod1}. + + \begin{cmhtcbraster}[ raster left skip=-3.5cm, + raster right skip=-2cm, + raster force size=false, + raster column 1/.style={add to width=.1\textwidth}, + raster column skip=.06\linewidth] + \cmhlistingsfromfile{demonstrations/multiple-sentences5-mod1.tex}{\texttt{multiple-sentences5.tex} using \cref{lst:sentence-wrap1-yaml}}{lst:multiple-sentences5-mod1} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/sentence-wrap1.yaml}[MLB-TCB,width=0.5\textwidth]{\texttt{sentence-wrap1.yaml}}{lst:sentence-wrap1-yaml} + \end{cmhtcbraster} + + If you wish to specify the \texttt{columns} field on a per-code-block basis for + sentences, then you would use \texttt{sentence}; explicitly, starting with + \vref{lst:textwrap9-yaml}, for example, you would replace/append \texttt{environments} + with, for example, \texttt{sentence: 50}. + + If you specify \texttt{textWrapSentences} as 1, but do \emph{not} specify a value for + \texttt{columns} then the text wrapping will \emph{not} operate on sentences, and you + will see a warning in \texttt{indent.log}. + + The indentation of sentences requires that sentences are stored as code blocks. This + means that you may need to tweak \vref{lst:sentencesEndWith}. Let's explore this in + relation to \cref{lst:multiple-sentences6}. + + \cmhlistingsfromfile{demonstrations/multiple-sentences6.tex}{\texttt{multiple-sentences6.tex}}{lst:multiple-sentences6} + + By default, \texttt{latexindent.pl} will find the full-stop within the first + \texttt{item}, which means that, upon running the following commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-y demonstration} + \begin{commandshell} +latexindent.pl multiple-sentences6 -m -l=sentence-wrap1.yaml +latexindent.pl multiple-sentences6 -m -l=sentence-wrap1.yaml -y="modifyLineBreaks:oneSentencePerLine:sentenceIndent:''" +\end{commandshell} + we receive the respective output in \cref{lst:multiple-sentences6-mod1} and + \cref{lst:multiple-sentences6-mod2}. + + \cmhlistingsfromfile{demonstrations/multiple-sentences6-mod1.tex}{\texttt{multiple-sentences6-mod1.tex} using \cref{lst:sentence-wrap1-yaml}}{lst:multiple-sentences6-mod1} + + \cmhlistingsfromfile{demonstrations/multiple-sentences6-mod2.tex}{\texttt{multiple-sentences6-mod2.tex} using \cref{lst:sentence-wrap1-yaml} and no sentence indentation}{lst:multiple-sentences6-mod2} + + We note that \cref{lst:multiple-sentences6-mod1} the \texttt{itemize} code block has + \emph{not} been indented appropriately. This is because the oneSentencePerLine has been + instructed to store sentences (because \cref{lst:sentence-wrap1-yaml}); each sentence is + then searched for code blocks. + + We can tweak the settings in \vref{lst:sentencesEndWith} to ensure that full stops are + not followed by \texttt{item} commands, and that the end of sentences contains + \lstinline!\end{itemize}! as in \cref{lst:itemize-yaml} (if you intend to use this, + ensure that you remove the line breaks from the \texttt{other} field). + \index{regular expressions!lowercase alph a-z} + \index{regular expressions!uppercase alph A-Z} + \index{regular expressions!numeric 0-9} + \index{regular expressions!horizontal space \textbackslash{h}} + + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/itemized.yaml}[MLB-TCB]{\texttt{itemize.yaml}}{lst:itemize-yaml} + + Upon running + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl multiple-sentences6 -m -l=sentence-wrap1.yaml,itemize.yaml +\end{commandshell} + we receive the output in \cref{lst:multiple-sentences6-mod3}. + + \cmhlistingsfromfile{demonstrations/multiple-sentences6-mod3.tex}{\texttt{multiple-sentences6-mod3.tex} using \cref{lst:sentence-wrap1-yaml} and \cref{lst:itemize-yaml}}{lst:multiple-sentences6-mod3} + + Notice that the sentence has received indentation, and that the \texttt{itemize} code + block has been found and indented correctly. diff --git a/support/latexindent/documentation/subsec-partnering-poly-switches.tex b/support/latexindent/documentation/subsec-partnering-poly-switches.tex deleted file mode 100644 index 4c0b7a8f05..0000000000 --- a/support/latexindent/documentation/subsec-partnering-poly-switches.tex +++ /dev/null @@ -1,54 +0,0 @@ -% arara: pdflatex: {shell: yes, files: [latexindent]} -\subsection{Partnering BodyStartsOnOwnLine with argument-based poly-switches} - Some poly-switches need to be partnered together; in particular, when line breaks - involving the \emph{first} argument of a code block need to be accounted for - using both \texttt{BodyStartsOnOwnLine} (or its equivalent, see \vref{tab:poly-switch-mapping}) and \texttt{LCuBStartsOnOwnLine} for mandatory arguments, and - \texttt{LSqBStartsOnOwnLine} for optional arguments. - \index{poly-switches!conflicting partnering} - - Let's begin with the code in \cref{lst:mycommand1} and the YAML settings in - \cref{lst:mycom-mlb1}; with reference to \vref{tab:poly-switch-mapping}, the key - \texttt{CommandNameFinishesWithLineBreak} is an alias for \texttt{BodyStartsOnOwnLine}. - - \cmhlistingsfromfile{demonstrations/mycommand1.tex}{\texttt{mycommand1.tex}}{lst:mycommand1} - - Upon running the command - \index{switches!-l demonstration} - \index{switches!-m demonstration} - \begin{commandshell} -latexindent.pl -m -l=mycom-mlb1.yaml mycommand1.tex -\end{commandshell} - we obtain \cref{lst:mycommand1-mlb1}; note that the \emph{second} mandatory argument - beginning brace \lstinline!{! has had its leading line break removed, but that - the \emph{first} brace has not. - - \begin{cmhtcbraster}[ - raster force size=false, - raster column 1/.style={add to width=-1cm}, - ] - \cmhlistingsfromfile{demonstrations/mycommand1-mlb1.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb1}}{lst:mycommand1-mlb1} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb1.yaml}[MLB-TCB,width=.6\textwidth]{\texttt{mycom-mlb1.yaml}}{lst:mycom-mlb1} - \end{cmhtcbraster} - - Now let's change the YAML file so that it is as in \cref{lst:mycom-mlb2}; upon running - the analogous command to that given above, we obtain \cref{lst:mycommand1-mlb2}; both - beginning braces \lstinline!{! have had their leading line breaks removed. - - \begin{cmhtcbraster}[ - raster force size=false, - raster column 1/.style={add to width=-1cm}, - ] - \cmhlistingsfromfile{demonstrations/mycommand1-mlb2.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb2}}{lst:mycommand1-mlb2} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb2.yaml}[MLB-TCB,width=.6\textwidth]{\texttt{mycom-mlb2.yaml}}{lst:mycom-mlb2} - \end{cmhtcbraster} - - Now let's change the YAML file so that it is as in \cref{lst:mycom-mlb3}; upon running - the analogous command to that given above, we obtain \cref{lst:mycommand1-mlb3}. - - \begin{cmhtcbraster}[ - raster force size=false, - raster column 1/.style={add to width=-1cm}, - ] - \cmhlistingsfromfile{demonstrations/mycommand1-mlb3.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb3}}{lst:mycommand1-mlb3} - \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb3.yaml}[MLB-TCB,width=.6\textwidth]{\texttt{mycom-mlb3.yaml}}{lst:mycom-mlb3} - \end{cmhtcbraster} diff --git a/support/latexindent/documentation/subsec-poly-switches.tex b/support/latexindent/documentation/subsec-poly-switches.tex new file mode 100644 index 0000000000..609e5ca748 --- /dev/null +++ b/support/latexindent/documentation/subsec-poly-switches.tex @@ -0,0 +1,1101 @@ +% arara: pdflatex: {shell: yes, files: [latexindent]} +\subsection{Poly-switches}\label{sec:poly-switches} + Every other field in the \texttt{modifyLineBreaks} field uses poly-switches, and can take + one of the following% + \announce{2017-08-21}*{blank line poly-switch} integer values: + \index{modifying linebreaks! using poly-switches} + \index{poly-switches!definition} + \index{poly-switches!values} + \index{poly-switches!off by default: set to 0} + \begin{description} + \item[$-1$] \emph{remove mode}: line breaks before or after the + \emph{<part of thing>} can be removed (assuming that \texttt{preserveBlankLines} is + set to \texttt{0}); + \item[0] \emph{off mode}: line breaks will not be modified for the + \emph{<part of thing>} under consideration; + \item[1] \emph{add mode}: a line break will be added before or after the + \emph{<part of thing>} under consideration, assuming that + there is not already a line break before or after the \emph{<part of thing>}; + \item[2] \emph{comment then add mode}: a comment symbol will be added, followed by a line break + before or after the \emph{<part of thing>} under consideration, assuming that there is + not already a comment and line break before or after the \emph{<part of thing>}; + \item[3] \emph{add then blank line mode}% + \announce{2017-08-21}{blank line poly-switch}: a line break will be added before or after + the \emph{<part of thing>} under consideration, assuming that there is not already a line + break before or after the \emph{<part of thing>}, followed by a blank line; + \item[4] \emph{add blank line mode}% + \announce{2019-07-13}{blank line poly-switch}; a blank line will + be added before or after the \emph{<part of thing>} under consideration, even if the + \emph{<part of thing>} is already on its own line. + \end{description} + In the above, \emph{<part of thing>} refers to either the \emph{begin statement}, + \emph{body} or \emph{end statement} of the code blocks detailed in + \vref{tab:code-blocks}. All poly-switches are \emph{off} by default; + \texttt{latexindent.pl} searches first of all for per-name settings, and then followed by + global per-thing settings. + +\subsubsection{Poly-switches for environments}\label{sec:modifylinebreaks-environments} + We start by viewing a snippet of \texttt{defaultSettings.yaml} in + \cref{lst:environments-mlb}; note that it contains \emph{global} settings (immediately + after the \texttt{environments} field) and that \emph{per-name} settings are also allowed + -- in the case of \cref{lst:environments-mlb}, settings for \texttt{equation*} have been + specified for demonstration. Note that all poly-switches are \emph{off} (set to 0) by + default. + \index{poly-switches!default values} + \index{poly-switches!environment global example} + \index{poly-switches!environment per-code block example} + + \cmhlistingsfromfile[style=modifylinebreaksEnv]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,MLB-TCB]{\texttt{environments}}{lst:environments-mlb} + + Let's begin with the simple example given in \cref{lst:env-mlb1-tex}; note that we have + annotated key parts of the file using $\BeginStartsOnOwnLine$, $\BodyStartsOnOwnLine$, + $\EndStartsOnOwnLine$ and $\EndFinishesWithLineBreak$, these will be related to fields + specified in \cref{lst:environments-mlb}. + \index{poly-switches!visualisation: $\BeginStartsOnOwnLine$, $\BodyStartsOnOwnLine$, $\EndStartsOnOwnLine$, $\EndFinishesWithLineBreak$} + + \begin{cmhlistings}[style=tcblatex,escapeinside={(*@}{@*)}]{\texttt{env-mlb1.tex}}{lst:env-mlb1-tex} +before words(*@$\BeginStartsOnOwnLine$@*) \begin{myenv}(*@$\BodyStartsOnOwnLine$@*)body of myenv(*@$\EndStartsOnOwnLine$@*)\end{myenv}(*@$\EndFinishesWithLineBreak$@*) after words +\end{cmhlistings} + + \paragraph{Adding line breaks: BeginStartsOnOwnLine and BodyStartsOnOwnLine} + Let's explore \texttt{BeginStartsOnOwnLine} and \texttt{BodyStartsOnOwnLine} in + \cref{lst:env-mlb1,lst:env-mlb2}, and in particular, let's allow each of them in turn to + take a value of $1$. + \index{modifying linebreaks! at the \emph{beginning} of a code block} + \index{poly-switches!adding line breaks: set to 1} + + \begin{minipage}{.45\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb1.yaml}[MLB-TCB]{\texttt{env-mlb1.yaml}}{lst:env-mlb1} + \end{minipage} + \hfill + \begin{minipage}{.45\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb2.yaml}[MLB-TCB]{\texttt{env-mlb2.yaml}}{lst:env-mlb2} + \end{minipage} + + After running the following commands, + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m env-mlb.tex -l env-mlb1.yaml +latexindent.pl -m env-mlb.tex -l env-mlb2.yaml +\end{commandshell} + the output is as in \cref{lst:env-mlb-mod1,lst:env-mlb-mod2} respectively. + + \begin{widepage} + \begin{minipage}{.56\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod1.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb1}}{lst:env-mlb-mod1} + \end{minipage} + \hfill + \begin{minipage}{.43\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod2.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb2}}{lst:env-mlb-mod2} + \end{minipage} + \end{widepage} + + There are a couple of points to note: + \begin{itemize} + \item in \cref{lst:env-mlb-mod1} a line break has been added at the point denoted by + $\BeginStartsOnOwnLine$ in \cref{lst:env-mlb1-tex}; no other line breaks have been + changed; + \item in \cref{lst:env-mlb-mod2} a line break has been added at the point denoted by + $\BodyStartsOnOwnLine$ in \cref{lst:env-mlb1-tex}; furthermore, note that the \emph{body} + of \texttt{myenv} has received the appropriate (default) indentation. + \end{itemize} + + Let's now change each of the \texttt{1} values in \cref{lst:env-mlb1,lst:env-mlb2} so + that they are $2$ and save them into \texttt{env-mlb3.yaml} and \texttt{env-mlb4.yaml} + respectively (see \cref{lst:env-mlb3,lst:env-mlb4}). + \index{poly-switches!adding comments and then line breaks: set to 2} + + \begin{minipage}{.45\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb3.yaml}[MLB-TCB]{\texttt{env-mlb3.yaml}}{lst:env-mlb3} + \end{minipage} + \hfill + \begin{minipage}{.45\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb4.yaml}[MLB-TCB]{\texttt{env-mlb4.yaml}}{lst:env-mlb4} + \end{minipage} + + Upon running commands analogous to the above, we obtain + \cref{lst:env-mlb-mod3,lst:env-mlb-mod4}. + + \begin{widepage} + \begin{minipage}{.56\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod3.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb3}}{lst:env-mlb-mod3} + \end{minipage} + \hfill + \begin{minipage}{.43\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod4.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb4}}{lst:env-mlb-mod4} + \end{minipage} + \end{widepage} + + Note that line breaks have been added as in \cref{lst:env-mlb-mod1,lst:env-mlb-mod2}, but + this time a comment symbol has been added before adding the line break; in both cases, + trailing horizontal space has been stripped before doing so. + + Let's% + \announce{2017-08-21}{demonstration of blank line poly-switch (3)} now change each of the \texttt{1} values in + \cref{lst:env-mlb1,lst:env-mlb2} so that they are $3$ and save them into + \texttt{env-mlb5.yaml} and \texttt{env-mlb6.yaml} respectively (see + \cref{lst:env-mlb5,lst:env-mlb6}). + \index{poly-switches!adding blank lines: set to 3} + + \begin{minipage}{.45\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb5.yaml}[MLB-TCB]{\texttt{env-mlb5.yaml}}{lst:env-mlb5} + \end{minipage} + \hfill + \begin{minipage}{.45\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb6.yaml}[MLB-TCB]{\texttt{env-mlb6.yaml}}{lst:env-mlb6} + \end{minipage} + + Upon running commands analogous to the above, we obtain + \cref{lst:env-mlb-mod5,lst:env-mlb-mod6}. + + \begin{widepage} + \begin{minipage}{.56\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod5.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb5}}{lst:env-mlb-mod5} + \end{minipage} + \hfill + \begin{minipage}{.43\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod6.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb6}}{lst:env-mlb-mod6} + \end{minipage} + \end{widepage} + + Note that line breaks have been added as in \cref{lst:env-mlb-mod1,lst:env-mlb-mod2}, but + this time a \emph{blank line} has been added after adding the line break. + + Let's now change% + \announce{2019-07-13}{demonstration of new blank line poly-switch} each of the \texttt{1} values in + \cref{lst:env-mlb5,lst:env-mlb6} so that they are $4$ and save them into + \texttt{env-beg4.yaml} and \texttt{env-body4.yaml} respectively (see + \cref{lst:env-beg4,lst:env-body4}). + \index{poly-switches!adding blank lines (again"!): set to 4} + + \begin{minipage}{.45\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-beg4.yaml}[MLB-TCB]{\texttt{env-beg4.yaml}}{lst:env-beg4} + \end{minipage} + \hfill + \begin{minipage}{.45\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-body4.yaml}[MLB-TCB]{\texttt{env-body4.yaml}}{lst:env-body4} + \end{minipage} + + We will demonstrate this poly-switch value using the code in \cref{lst:env-mlb1-text}. + + \cmhlistingsfromfile{demonstrations/env-mlb1.tex}{\texttt{env-mlb1.tex}}{lst:env-mlb1-text} + + Upon running the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m env-mlb1.tex -l env-beg4.yaml +latexindent.pl -m env-mlb.1tex -l env-body4.yaml +\end{commandshell} + + then we receive the respective outputs in \cref{lst:env-mlb1-beg4,lst:env-mlb1-body4}. + + \begin{cmhtcbraster}[raster column skip=.1\linewidth] + \cmhlistingsfromfile{demonstrations/env-mlb1-beg4.tex}{\texttt{env-mlb1.tex} using \cref{lst:env-beg4}}{lst:env-mlb1-beg4} + \cmhlistingsfromfile{demonstrations/env-mlb1-body4.tex}{\texttt{env-mlb1.tex} using \cref{lst:env-body4}}{lst:env-mlb1-body4} + \end{cmhtcbraster} + + We note in particular that, by design, for this value of the poly-switches: + \begin{enumerate} + \item in \cref{lst:env-mlb1-beg4} a blank line has been inserted before the + \lstinline!\begin! statement, even though the \lstinline!\begin! + statement was already on its own line; + \item in \cref{lst:env-mlb1-body4} a blank line has been inserted before the beginning of the + \emph{body}, even though it already began on its own line. + \end{enumerate} + + \paragraph{Adding line breaks using EndStartsOnOwnLine and EndFinishesWithLineBreak} + Let's explore \texttt{EndStartsOnOwnLine} and \texttt{EndFinishesWithLineBreak} in + \cref{lst:env-mlb7,lst:env-mlb8}, and in particular, let's allow each of them in turn to + take a value of $1$. + \index{modifying linebreaks! at the \emph{end} of a code block} + \index{poly-switches!adding line breaks: set to 1} + + \begin{minipage}{.49\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb7.yaml}[MLB-TCB]{\texttt{env-mlb7.yaml}}{lst:env-mlb7} + \end{minipage} + \hfill + \begin{minipage}{.49\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb8.yaml}[MLB-TCB]{\texttt{env-mlb8.yaml}}{lst:env-mlb8} + \end{minipage} + + After running the following commands, + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m env-mlb.tex -l env-mlb7.yaml +latexindent.pl -m env-mlb.tex -l env-mlb8.yaml +\end{commandshell} + the output is as in \cref{lst:env-mlb-mod7,lst:env-mlb-mod8}. + + \begin{widepage} + \begin{minipage}{.42\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod7.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb7}}{lst:env-mlb-mod7} + \end{minipage} + \hfill + \begin{minipage}{.57\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod8.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb8}}{lst:env-mlb-mod8} + \end{minipage} + \end{widepage} + + There are a couple of points to note: + \begin{itemize} + \item in \cref{lst:env-mlb-mod7} a line break has been added at the point denoted by + $\EndStartsOnOwnLine$ in \vref{lst:env-mlb1-tex}; no other line breaks have been changed + and the \lstinline!\end{myenv}! statement has \emph{not} received indentation (as + intended); + \item in \cref{lst:env-mlb-mod8} a line break has been added at the point denoted by + $\EndFinishesWithLineBreak$ in \vref{lst:env-mlb1-tex}. + \end{itemize} + + Let's now change each of the \texttt{1} values in \cref{lst:env-mlb7,lst:env-mlb8} so + that they are $2$ and save them into \texttt{env-mlb9.yaml} and \texttt{env-mlb10.yaml} + respectively (see \cref{lst:env-mlb9,lst:env-mlb10}). + \index{poly-switches!adding comments and then line breaks: set to 2} + + \begin{minipage}{.49\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb9.yaml}[MLB-TCB]{\texttt{env-mlb9.yaml}}{lst:env-mlb9} + \end{minipage} + \hfill + \begin{minipage}{.49\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb10.yaml}[MLB-TCB]{\texttt{env-mlb10.yaml}}{lst:env-mlb10} + \end{minipage} + + Upon running commands analogous to the above, we obtain + \cref{lst:env-mlb-mod9,lst:env-mlb-mod10}. + + \begin{widepage} + \begin{minipage}{.43\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod9.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb9}}{lst:env-mlb-mod9} + \end{minipage} + \hfill + \begin{minipage}{.56\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod10.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb10}}{lst:env-mlb-mod10} + \end{minipage} + \end{widepage} + + Note that line breaks have been added as in \cref{lst:env-mlb-mod7,lst:env-mlb-mod8}, but + this time a comment symbol has been added before adding the line break; in both cases, + trailing horizontal space has been stripped before doing so. + + Let's% + \announce{2017-08-21}{demonstration of blank line poly-switch (3)} now change each of the \texttt{1} values in + \cref{lst:env-mlb7,lst:env-mlb8} so that they are $3$ and save them into + \texttt{env-mlb11.yaml} and \texttt{env-mlb12.yaml} respectively (see + \cref{lst:env-mlb11,lst:env-mlb12}). + \index{poly-switches!adding blank lines: set to 3} + + \begin{minipage}{.49\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb11.yaml}[MLB-TCB]{\texttt{env-mlb11.yaml}}{lst:env-mlb11} + \end{minipage} + \hfill + \begin{minipage}{.49\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb12.yaml}[MLB-TCB]{\texttt{env-mlb12.yaml}}{lst:env-mlb12} + \end{minipage} + + Upon running commands analogous to the above, we obtain + \cref{lst:env-mlb-mod11,lst:env-mlb-mod12}. + + \begin{widepage} + \begin{minipage}{.42\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod11.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb11}}{lst:env-mlb-mod11} + \end{minipage} + \hfill + \begin{minipage}{.57\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb-mod12.tex}{\texttt{env-mlb.tex} using \cref{lst:env-mlb12}}{lst:env-mlb-mod12} + \end{minipage} + \end{widepage} + + Note that line breaks have been added as in \cref{lst:env-mlb-mod7,lst:env-mlb-mod8}, and + that a \emph{blank line} has been added after the line break. + + Let's now change% + \announce{2019-07-13}{demonstration of new blank line poly-switch} each of the \texttt{1} values in + \cref{lst:env-mlb11,lst:env-mlb12} so that they are $4$ and save them into + \texttt{env-end4.yaml} and \texttt{env-end-f4.yaml} respectively (see + \cref{lst:env-end4,lst:env-end-f4}). + \index{poly-switches!adding blank lines (again"!): set to 4} + + \begin{minipage}{.45\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-end4.yaml}[MLB-TCB]{\texttt{env-end4.yaml}}{lst:env-end4} + \end{minipage} + \hfill + \begin{minipage}{.5\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-end-f4.yaml}[MLB-TCB]{\texttt{env-end-f4.yaml}}{lst:env-end-f4} + \end{minipage} + + We will demonstrate this poly-switch value using the code from \vref{lst:env-mlb1-text}. + + Upon running the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m env-mlb1.tex -l env-end4.yaml +latexindent.pl -m env-mlb.1tex -l env-end-f4.yaml +\end{commandshell} + + then we receive the respective outputs in \cref{lst:env-mlb1-end4,lst:env-mlb1-end-f4}. + + \begin{cmhtcbraster}[raster column skip=.1\linewidth] + \cmhlistingsfromfile{demonstrations/env-mlb1-end4.tex}{\texttt{env-mlb1.tex} using \cref{lst:env-end4}}{lst:env-mlb1-end4} + \cmhlistingsfromfile{demonstrations/env-mlb1-end-f4.tex}{\texttt{env-mlb1.tex} using \cref{lst:env-end-f4}}{lst:env-mlb1-end-f4} + \end{cmhtcbraster} + + We note in particular that, by design, for this value of the poly-switches: + \begin{enumerate} + \item in \cref{lst:env-mlb1-end4} a blank line has been inserted before the + \lstinline!\end! statement, even though the \lstinline!\end! + statement was already on its own line; + \item in \cref{lst:env-mlb1-end-f4} a blank line has been inserted after the + \lstinline!\end! statement, even though it already began on its own line. + \end{enumerate} + + \paragraph{poly-switches 1, 2, and 3 only add line breaks when necessary} + If you ask \texttt{latexindent.pl} to add a line break (possibly with a comment) using a + poly-switch value of $1$ (or $2$ or $3$), it will only do so if necessary. For example, + if you process the file in \vref{lst:mlb2} using poly-switch values of 1, 2, or 3, it + will be left unchanged. + + \begin{minipage}{.45\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb2.tex}{\texttt{env-mlb2.tex}}{lst:mlb2} + \end{minipage} + \hfill + \begin{minipage}{.45\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb3.tex}{\texttt{env-mlb3.tex}}{lst:mlb3} + \end{minipage} + + Setting the poly-switches to a value of $4$ instructs \texttt{latexindent.pl} to add a + line break even if the \emph{<part of thing>} is already on its own line; see + \cref{lst:env-mlb1-beg4,lst:env-mlb1-body4} and + \cref{lst:env-mlb1-end4,lst:env-mlb1-end-f4}. + + In contrast, the output from processing the file in \cref{lst:mlb3} will vary depending + on the poly-switches used; in \cref{lst:env-mlb3-mod2} you'll see that the comment symbol + after the \lstinline!\begin{myenv}! has been moved to the next line, as + \texttt{BodyStartsOnOwnLine} is set to \texttt{1}. In \cref{lst:env-mlb3-mod4} you'll see + that the comment has been accounted for correctly because \texttt{BodyStartsOnOwnLine} + has been set to \texttt{2}, and the comment symbol has \emph{not} been moved to its own + line. You're encouraged to experiment with \cref{lst:mlb3} and by setting the other + poly-switches considered so far to \texttt{2} in turn. + + \begin{cmhtcbraster}[raster column skip=.1\linewidth] + \cmhlistingsfromfile{demonstrations/env-mlb3-mod2.tex}{\texttt{env-mlb3.tex} using \vref{lst:env-mlb2}}{lst:env-mlb3-mod2} + \cmhlistingsfromfile{demonstrations/env-mlb3-mod4.tex}{\texttt{env-mlb3.tex} using \vref{lst:env-mlb4}}{lst:env-mlb3-mod4} + \end{cmhtcbraster} + + The details of the discussion in this section have concerned \emph{global} poly-switches + in the \texttt{environments} field; each switch can also be specified on a + \emph{per-name} basis, which would take priority over the global values; with reference + to \vref{lst:environments-mlb}, an example is shown for the \texttt{equation*} + environment. + + \paragraph{Removing line breaks (poly-switches set to $-1$)} + Setting poly-switches to $-1$ tells \texttt{latexindent.pl} to remove line breaks of the + \emph{<part of the thing>}, if necessary. We will consider the example code given in + \cref{lst:mlb4}, noting in particular the positions of the line break highlighters, + $\BeginStartsOnOwnLine$, $\BodyStartsOnOwnLine$, $\EndStartsOnOwnLine$ and + $\EndFinishesWithLineBreak$, together with the associated YAML files in + \crefrange{lst:env-mlb13}{lst:env-mlb16}. + \index{poly-switches!removing line breaks: set to -1} + + \begin{minipage}{.45\linewidth} + \begin{cmhlistings}[style=tcblatex,escapeinside={(*@}{@*)}]{\texttt{env-mlb4.tex}}{lst:mlb4} +before words(*@$\BeginStartsOnOwnLine$@*) +\begin{myenv}(*@$\BodyStartsOnOwnLine$@*) +body of myenv(*@$\EndStartsOnOwnLine$@*) +\end{myenv}(*@$\EndFinishesWithLineBreak$@*) +after words +\end{cmhlistings} + \end{minipage}% + \hfill + \begin{minipage}{.51\textwidth} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb13.yaml}[MLB-TCB]{\texttt{env-mlb13.yaml}}{lst:env-mlb13} + + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb14.yaml}[MLB-TCB]{\texttt{env-mlb14.yaml}}{lst:env-mlb14} + + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb15.yaml}[MLB-TCB]{\texttt{env-mlb15.yaml}}{lst:env-mlb15} + + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/env-mlb16.yaml}[MLB-TCB]{\texttt{env-mlb16.yaml}}{lst:env-mlb16} + \end{minipage} + + After running the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m env-mlb4.tex -l env-mlb13.yaml +latexindent.pl -m env-mlb4.tex -l env-mlb14.yaml +latexindent.pl -m env-mlb4.tex -l env-mlb15.yaml +latexindent.pl -m env-mlb4.tex -l env-mlb16.yaml +\end{commandshell} + + we obtain the respective output in \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16}. + + \begin{minipage}{.45\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb4-mod13.tex}{\texttt{env-mlb4.tex} using \cref{lst:env-mlb13}}{lst:env-mlb4-mod13} + \end{minipage} + \hfill + \begin{minipage}{.45\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb4-mod14.tex}{\texttt{env-mlb4.tex} using \cref{lst:env-mlb14}}{lst:env-mlb4-mod14} + \end{minipage} + + \begin{minipage}{.45\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb4-mod15.tex}{\texttt{env-mlb4.tex} using \cref{lst:env-mlb15}}{lst:env-mlb4-mod15} + \end{minipage} + \hfill + \begin{minipage}{.45\linewidth} + \cmhlistingsfromfile{demonstrations/env-mlb4-mod16.tex}{\texttt{env-mlb4.tex} using \cref{lst:env-mlb16}}{lst:env-mlb4-mod16} + \end{minipage} + + Notice that in: + \begin{itemize} + \item \cref{lst:env-mlb4-mod13} the line break denoted by $\BeginStartsOnOwnLine$ in + \cref{lst:mlb4} has been removed; + \item \cref{lst:env-mlb4-mod14} the line break denoted by $\BodyStartsOnOwnLine$ in + \cref{lst:mlb4} has been removed; + \item \cref{lst:env-mlb4-mod15} the line break denoted by $\EndStartsOnOwnLine$ in + \cref{lst:mlb4} has been removed; + \item \cref{lst:env-mlb4-mod16} the line break denoted by $\EndFinishesWithLineBreak$ in + \cref{lst:mlb4} has been removed. + \end{itemize} + We examined each of these cases separately for clarity of explanation, but you can + combine all of the YAML settings in \crefrange{lst:env-mlb13}{lst:env-mlb16} into one + file; alternatively, you could tell \texttt{latexindent.pl} to load them all by using the + following command, for example + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl -m env-mlb4.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml +\end{commandshell} + \end{widepage} + which gives the output in \vref{lst:env-mlb1-tex}. + + \paragraph{About trailing horizontal space} + Recall that on \cpageref{yaml:removeTrailingWhitespace} we discussed the YAML field + \texttt{removeTrailingWhitespace}, and that it has two (binary) switches to determine if + horizontal space should be removed \texttt{beforeProcessing} and + \texttt{afterProcessing}. The \texttt{beforeProcessing} is particularly relevant when + considering the \texttt{-m} switch; let's consider the file shown in \cref{lst:mlb5}, + which highlights trailing spaces. + + \begin{cmhtcbraster} + \begin{cmhlistings}[style=tcblatex,showspaces=true,escapeinside={(*@}{@*)}]{\texttt{env-mlb5.tex}}{lst:mlb5} +before words (*@$\BeginStartsOnOwnLine$@*) +\begin{myenv} (*@$\BodyStartsOnOwnLine$@*) +body of myenv (*@$\EndStartsOnOwnLine$@*) +\end{myenv} (*@$\EndFinishesWithLineBreak$@*) +after words +\end{cmhlistings} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/removeTWS-before.yaml}[yaml-TCB]{\texttt{removeTWS-before.yaml}}{lst:removeTWS-before} + \end{cmhtcbraster} + + The output from the following commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl -m env-mlb5.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml +latexindent.pl -m env-mlb5.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml,removeTWS-before.yaml +\end{commandshell} + \end{widepage} + is shown, respectively, in \cref{lst:env-mlb5-modAll,lst:env-mlb5-modAll-remove-WS}; note + that the trailing horizontal white space has been preserved (by default) in + \cref{lst:env-mlb5-modAll}, while in \cref{lst:env-mlb5-modAll-remove-WS}, it has been + removed using the switch specified in \cref{lst:removeTWS-before}. + + \begin{widepage} + \cmhlistingsfromfile[showspaces=true]{demonstrations/env-mlb5-modAll.tex}{\texttt{env-mlb5.tex} using \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16}}{lst:env-mlb5-modAll} + + \cmhlistingsfromfile[showspaces=true]{demonstrations/env-mlb5-modAll-remove-WS.tex}{\texttt{env-mlb5.tex} using \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16} \emph{and} \cref{lst:removeTWS-before}}{lst:env-mlb5-modAll-remove-WS} + \end{widepage} + + \paragraph{poly-switch line break removal and blank lines} + Now let's consider the file in \cref{lst:mlb6}, which contains blank lines. + \index{poly-switches!blank lines} + + \begin{cmhtcbraster} + \begin{cmhlistings}[style=tcblatex,escapeinside={(*@}{@*)}]{\texttt{env-mlb6.tex}}{lst:mlb6} +before words(*@$\BeginStartsOnOwnLine$@*) + + +\begin{myenv}(*@$\BodyStartsOnOwnLine$@*) + + +body of myenv(*@$\EndStartsOnOwnLine$@*) + + +\end{myenv}(*@$\EndFinishesWithLineBreak$@*) + +after words +\end{cmhlistings} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/UnpreserveBlankLines.yaml}[MLB-TCB]{\texttt{UnpreserveBlankLines.yaml}}{lst:UnpreserveBlankLines} + \end{cmhtcbraster} + + Upon running the following commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl -m env-mlb6.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml +latexindent.pl -m env-mlb6.tex -l env-mlb13.yaml,env-mlb14.yaml,env-mlb15.yaml,env-mlb16.yaml,UnpreserveBlankLines.yaml +\end{commandshell} + \end{widepage} + we receive the respective outputs in + \cref{lst:env-mlb6-modAll,lst:env-mlb6-modAll-un-Preserve-Blank-Lines}. In + \cref{lst:env-mlb6-modAll} we see that the multiple blank lines have each been condensed + into one blank line, but that blank lines have \emph{not} been removed by the + poly-switches -- this is because, by default, \texttt{preserveBlankLines} is set to + \texttt{1}. By contrast, in \cref{lst:env-mlb6-modAll-un-Preserve-Blank-Lines}, we have + allowed the poly-switches to remove blank lines because, in + \cref{lst:UnpreserveBlankLines}, we have set \texttt{preserveBlankLines} to \texttt{0}. + + \begin{cmhtcbraster}[ raster left skip=-3.5cm, + raster right skip=-2cm, + raster force size=false, + raster column 1/.style={add to width=-.2\textwidth}, + raster column 2/.style={add to width=.2\textwidth}, + raster column skip=.06\linewidth] + \cmhlistingsfromfile{demonstrations/env-mlb6-modAll.tex}{\texttt{env-mlb6.tex} using \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16}}{lst:env-mlb6-modAll} + \cmhlistingsfromfile{demonstrations/env-mlb6-modAll-un-Preserve-Blank-Lines.tex}{\texttt{env-mlb6.tex} using \crefrange{lst:env-mlb4-mod13}{lst:env-mlb4-mod16} \emph{and} \cref{lst:UnpreserveBlankLines}}{lst:env-mlb6-modAll-un-Preserve-Blank-Lines} + \end{cmhtcbraster} + + We can explore this further using the blank-line poly-switch value of $3$; let's use the + file given in \cref{lst:env-mlb7-tex}. + + \cmhlistingsfromfile{demonstrations/env-mlb7.tex}{\texttt{env-mlb7.tex}}{lst:env-mlb7-tex} + + Upon running the following commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m env-mlb7.tex -l env-mlb12.yaml,env-mlb13.yaml +latexindent.pl -m env-mlb7.tex -l env-mlb13.yaml,env-mlb14.yaml,UnpreserveBlankLines.yaml +\end{commandshell} + we receive the outputs given in \cref{lst:env-mlb7-preserve,lst:env-mlb7-no-preserve}. + + \cmhlistingsfromfile{demonstrations/env-mlb7-preserve.tex}{\texttt{env-mlb7-preserve.tex}}{lst:env-mlb7-preserve} + \cmhlistingsfromfile{demonstrations/env-mlb7-no-preserve.tex}{\texttt{env-mlb7-no-preserve.tex}}{lst:env-mlb7-no-preserve} + + Notice that in: + \begin{itemize} + \item \cref{lst:env-mlb7-preserve} that \lstinline!\end{one}! has added a blank line, + because of the value of \texttt{EndFinishesWithLineBreak} in \vref{lst:env-mlb12}, and + even though the line break ahead of \lstinline!\begin{two}! should have been removed + (because of \texttt{BeginStartsOnOwnLine} in \vref{lst:env-mlb13}), the blank line has + been preserved by default; + \item \cref{lst:env-mlb7-no-preserve}, by contrast, has had the additional line-break removed, + because of the settings in \cref{lst:UnpreserveBlankLines}. + \end{itemize} + +\subsubsection{Poly-switches for double back slash}\label{subsec:dbs} + With reference to \texttt{lookForAlignDelims} (see + \vref{lst:aligndelims:basic})% + \announce{2019-07-13}{poly-switch for double back slash} you can specify poly-switches to + dictate the line-break behaviour of double back slashes in environments + (\vref{lst:tabularafter:basic}), commands (\vref{lst:matrixafter}), or special code + blocks (\vref{lst:specialafter}). Note that for these poly-switches to take effect, the + name of the code block must necessarily be specified within \texttt{lookForAlignDelims} + (\vref{lst:aligndelims:basic}); we will demonstrate this in what follows. + \index{delimiters!poly-switches for double back slash} + \index{modifying linebreaks! surrounding double back slash} + \index{poly-switches!for double back slash (delimiters)} + + Consider the code given in \cref{lst:dbs-demo}. + \begin{cmhlistings}[style=tcblatex,escapeinside={(*@}{@*)}]{\texttt{tabular3.tex}}{lst:dbs-demo} +\begin{tabular}{cc} + 1 & 2 (*@$\ElseStartsOnOwnLine$@*)\\(*@$\ElseFinishesWithLineBreak$@*) 3 & 4 (*@$\ElseStartsOnOwnLine$@*)\\(*@$\ElseFinishesWithLineBreak$@*) +\end{tabular} +\end{cmhlistings} + Referencing \cref{lst:dbs-demo}: + \begin{itemize} + \item \texttt{DBS} stands for \emph{double back slash}; + \item line breaks ahead of the double back slash are annotated by $\ElseStartsOnOwnLine$, and + are controlled by \texttt{DBSStartsOnOwnLine}; + \item line breaks after the double back slash are annotated by $\ElseFinishesWithLineBreak$, + and are controlled by \texttt{DBSFinishesWithLineBreak}. + \end{itemize} + + Let's explore each of these in turn. + + \paragraph{Double back slash starts on own line} + We explore \texttt{DBSStartsOnOwnLine} ($\ElseStartsOnOwnLine$ in \cref{lst:dbs-demo}); + starting with the code in \cref{lst:dbs-demo}, together with the YAML files given in + \cref{lst:DBS1} and \cref{lst:DBS2} and running the following commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m tabular3.tex -l DBS1.yaml +latexindent.pl -m tabular3.tex -l DBS2.yaml +\end{commandshell} + then we receive the respective output given in \cref{lst:tabular3-DBS1} and + \cref{lst:tabular3-DBS2}. + + \begin{cmhtcbraster}[raster column skip=.01\linewidth] + \cmhlistingsfromfile{demonstrations/tabular3-mod1.tex}{\texttt{tabular3.tex} using \cref{lst:DBS1}}{lst:tabular3-DBS1} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS1.yaml}[MLB-TCB]{\texttt{DBS1.yaml}}{lst:DBS1} + \end{cmhtcbraster} + + \begin{cmhtcbraster}[raster column skip=.01\linewidth] + \cmhlistingsfromfile{demonstrations/tabular3-mod2.tex}{\texttt{tabular3.tex} using \cref{lst:DBS2}}{lst:tabular3-DBS2} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS2.yaml}[MLB-TCB]{\texttt{DBS2.yaml}}{lst:DBS2} + \end{cmhtcbraster} + + We note that + \begin{itemize} + \item \cref{lst:DBS1} specifies \texttt{DBSStartsOnOwnLine} for + \emph{every} environment (that is within \texttt{lookForAlignDelims}, + \vref{lst:aligndelims:advanced}); + the double back slashes from \cref{lst:dbs-demo} have been moved to their own line in + \cref{lst:tabular3-DBS1}; + \item \cref{lst:DBS2} specifies \texttt{DBSStartsOnOwnLine} on a + \emph{per-name} basis for \texttt{tabular} (that is within \texttt{lookForAlignDelims}, + \vref{lst:aligndelims:advanced}); + the double back slashes from \cref{lst:dbs-demo} have been moved to their own line in + \cref{lst:tabular3-DBS2}, having added comment symbols before moving them. + \end{itemize} + + \paragraph{Double back slash finishes with line break} + Let's now explore \texttt{DBSFinishesWithLineBreak} ($\ElseFinishesWithLineBreak$ in + \cref{lst:dbs-demo}); starting with the code in \cref{lst:dbs-demo}, together with the + YAML files given in \cref{lst:DBS3} and \cref{lst:DBS4} and running the following + commands + \index{poly-switches!for double back slash (delimiters)} + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m tabular3.tex -l DBS3.yaml +latexindent.pl -m tabular3.tex -l DBS4.yaml +\end{commandshell} + then we receive the respective output given in \cref{lst:tabular3-DBS3} and + \cref{lst:tabular3-DBS4}. + + \begin{cmhtcbraster}[raster column skip=.01\linewidth] + \cmhlistingsfromfile{demonstrations/tabular3-mod3.tex}{\texttt{tabular3.tex} using \cref{lst:DBS3}}{lst:tabular3-DBS3} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS3.yaml}[MLB-TCB]{\texttt{DBS3.yaml}}{lst:DBS3} + \end{cmhtcbraster} + + \begin{cmhtcbraster}[raster column skip=.01\linewidth] + \cmhlistingsfromfile{demonstrations/tabular3-mod4.tex}{\texttt{tabular3.tex} using \cref{lst:DBS4}}{lst:tabular3-DBS4} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS4.yaml}[MLB-TCB]{\texttt{DBS4.yaml}}{lst:DBS4} + \end{cmhtcbraster} + + We note that + \begin{itemize} + \item \cref{lst:DBS3} specifies \texttt{DBSFinishesWithLineBreak} for + \emph{every} environment (that is within \texttt{lookForAlignDelims}, + \vref{lst:aligndelims:advanced}); + the code following the double back slashes from \cref{lst:dbs-demo} has been moved to + their own line in \cref{lst:tabular3-DBS3}; + \item \cref{lst:DBS4} specifies \texttt{DBSFinishesWithLineBreak} on a + \emph{per-name} basis for \texttt{tabular} (that is within \texttt{lookForAlignDelims}, + \vref{lst:aligndelims:advanced}); + the first double back slashes from \cref{lst:dbs-demo} have moved code following them to + their own line in \cref{lst:tabular3-DBS4}, having added comment symbols before moving + them; the final double back slashes have \emph{not} added a line break as they are at the + end of the body within the code block. + \end{itemize} + + \paragraph{Double back slash poly-switches for specialBeginEnd} + Let's explore the double back slash poly-switches for code blocks within + \texttt{specialBeginEnd} code blocks (\vref{lst:specialBeginEnd}); we begin with the code + within \cref{lst:special4}. + \index{specialBeginEnd!double backslash poly-switch demonstration} + \index{poly-switches!double backslash} + \index{poly-switches!for double back slash (delimiters)} + \index{specialBeginEnd!lookForAlignDelims} + \index{delimiters} + \index{linebreaks!summary of poly-switches} + + \cmhlistingsfromfile{demonstrations/special4.tex}{\texttt{special4.tex}}{lst:special4} + + Upon using the YAML settings in \cref{lst:DBS5}, and running the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m special4.tex -l DBS5.yaml +\end{commandshell} + then we receive the output given in \cref{lst:special4-DBS5}. + \index{delimiters!with specialBeginEnd and the -m switch} + + \begin{cmhtcbraster}[ + raster force size=false, + raster column 1/.style={add to width=-.1\textwidth}, + raster column skip=.06\linewidth] + \cmhlistingsfromfile{demonstrations/special4-mod5.tex}{\texttt{special4.tex} using \cref{lst:DBS5}}{lst:special4-DBS5} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS5.yaml}[MLB-TCB,width=0.6\textwidth]{\texttt{DBS5.yaml}}{lst:DBS5} + \end{cmhtcbraster} + + There are a few things to note: + \begin{itemize} + \item in \cref{lst:DBS5} we have specified \texttt{cmhMath} within \texttt{lookForAlignDelims}; + without this, the double back slash poly-switches would be ignored for this code block; + \item the \texttt{DBSFinishesWithLineBreak} poly-switch has controlled the line breaks + following the double back slashes; + \item the \texttt{SpecialEndStartsOnOwnLine} poly-switch has controlled the addition of a + comment symbol, followed by a line break, as it is set to a value of 2. + \end{itemize} + + \paragraph{Double back slash poly-switches for optional and mandatory arguments} + For clarity, we provide a demonstration of controlling the double back slash + poly-switches for optional and mandatory arguments. We begin with the code in + \cref{lst:mycommand2}. + \index{poly-switches!for double back slash (delimiters)} + + \cmhlistingsfromfile{demonstrations/mycommand2.tex}{\texttt{mycommand2.tex}}{lst:mycommand2} + + Upon using the YAML settings in \cref{lst:DBS6,lst:DBS7}, and running the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m mycommand2.tex -l DBS6.yaml +latexindent.pl -m mycommand2.tex -l DBS7.yaml +\end{commandshell} + then we receive the output given in \cref{lst:mycommand2-DBS6,lst:mycommand2-DBS7}. + + \begin{cmhtcbraster}[ + raster force size=false, + raster column 1/.style={add to width=-.1\textwidth}, + raster column skip=.03\linewidth] + \cmhlistingsfromfile{demonstrations/mycommand2-mod6.tex}{\texttt{mycommand2.tex} using \cref{lst:DBS6}}{lst:mycommand2-DBS6} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS6.yaml}[MLB-TCB,width=0.6\textwidth]{\texttt{DBS6.yaml}}{lst:DBS6} + \end{cmhtcbraster} + + \begin{cmhtcbraster}[ + raster force size=false, + raster column 1/.style={add to width=-.1\textwidth}, + raster column skip=.03\linewidth] + \cmhlistingsfromfile{demonstrations/mycommand2-mod7.tex}{\texttt{mycommand2.tex} using \cref{lst:DBS7}}{lst:mycommand2-DBS7} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/DBS7.yaml}[MLB-TCB,width=0.6\textwidth]{\texttt{DBS7.yaml}}{lst:DBS7} + \end{cmhtcbraster} + + \paragraph{Double back slash optional square brackets} + The pattern matching for the double back slash will also, optionally, allow trailing + square brackets that contain a measurement of vertical spacing, for example + \lstinline!\\[3pt]!. + \index{poly-switches!for double back slash (delimiters)} + + For example, beginning with the code in \cref{lst:pmatrix3} + + \cmhlistingsfromfile{demonstrations/pmatrix3.tex}{\texttt{pmatrix3.tex}}{lst:pmatrix3} + + and running the following command, using \cref{lst:DBS3}, + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m pmatrix3.tex -l DBS3.yaml +\end{commandshell} + then we receive the output given in \cref{lst:pmatrix3-DBS3}. + + \cmhlistingsfromfile{demonstrations/pmatrix3-mod3.tex}{\texttt{pmatrix3.tex} using \cref{lst:DBS3}}{lst:pmatrix3-DBS3} + + You can customise the pattern for the double back slash by exploring the \emph{fine + tuning} field detailed in \vref{lst:fineTuning}. + +\subsubsection{Poly-switches for other code blocks} + Rather than repeat the examples shown for the environment code blocks (in + \vref{sec:modifylinebreaks-environments}), we choose to detail the poly-switches for all + other code blocks in \cref{tab:poly-switch-mapping}; note that each and every one of + these poly-switches is \emph{off by default}, i.e, set to \texttt{0}. + + Note also that, by design, line breaks involving, \texttt{filecontents} and + `comment-marked' code blocks (\vref{lst:alignmentmarkup}) can \emph{not} be modified + using \texttt{latexindent.pl}.% + \announce{2019-05-05}*{verbatim poly-switch} However, there are two poly-switches + available for \texttt{verbatim} code blocks: environments + (\vref{lst:verbatimEnvironments}), commands (\vref{lst:verbatimCommands}) and + \texttt{specialBeginEnd} (\vref{lst:special-verb1-yaml}). + \index{specialBeginEnd!poly-switch summary} + \index{verbatim!poly-switch summary} + \index{poly-switches!summary of all poly-switches} + + \clearpage + \begin{longtable}{llll} + \caption{Poly-switch mappings for all code-block types}\label{tab:poly-switch-mapping} \\ + \toprule + Code block & Sample & \multicolumn{2}{c}{Poly-switch mapping} \\ + \midrule + environment & \verb!before words!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & BeginStartsOnOwnLine \\ + & \verb!\begin{myenv}!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & BodyStartsOnOwnLine \\ + & \verb!body of myenv!$\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & EndStartsOnOwnLine \\ + & \verb!\end{myenv}!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & EndFinishesWithLineBreak \\ + & \verb!after words! & & \\ + \cmidrule{2-4} + ifelsefi & \verb!before words!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & IfStartsOnOwnLine \\ + & \verb!\if...!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & BodyStartsOnOwnLine \\ + & \verb!body of if/or statement!$\OrStartsOnOwnLine$ & $\OrStartsOnOwnLine$ & OrStartsOnOwnLine % + \announce{2018-04-27}{new ifElseFi code block poly-switches} \\ + & \verb!\or!$\OrFinishesWithLineBreak$ & $\OrFinishesWithLineBreak$ & OrFinishesWithLineBreak \\ + & \verb!body of if/or statement!$\ElseStartsOnOwnLine$ & $\ElseStartsOnOwnLine$ & ElseStartsOnOwnLine \\ + & \verb!\else!$\ElseFinishesWithLineBreak$ & $\ElseFinishesWithLineBreak$ & ElseFinishesWithLineBreak \\ + & \verb!body of else statement!$\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & FiStartsOnOwnLine \\ + & \verb!\fi!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & FiFinishesWithLineBreak \\ + & \verb!after words! & & \\ + \cmidrule{2-4} + optionalArguments & \verb!...!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & LSqBStartsOnOwnLine\footnote{LSqB stands for Left Square Bracket} \\ + & \verb![!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & OptArgBodyStartsOnOwnLine \\ + \announce{2019-07-13}{new comma-related poly-switches} & \verb!value before comma!$\ElseStartsOnOwnLine$, & $\ElseStartsOnOwnLine$ & CommaStartsOnOwnLine \\ + & $\ElseFinishesWithLineBreak$ & $\ElseFinishesWithLineBreak$ & CommaFinishesWithLineBreak \\ + & \verb!end of body of opt arg!$\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & RSqBStartsOnOwnLine \\ + & \verb!]!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & RSqBFinishesWithLineBreak \\ + & \verb!...! & & \\ + \cmidrule{2-4} + mandatoryArguments & \verb!...!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & LCuBStartsOnOwnLine\footnote{LCuB stands for Left Curly Brace} \\ + & \verb!{!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & MandArgBodyStartsOnOwnLine \\ + \announce{2019-07-13}{new comma-related poly-switches} & \verb!value before comma!$\ElseStartsOnOwnLine$, & $\ElseStartsOnOwnLine$ & CommaStartsOnOwnLine \\ + & $\ElseFinishesWithLineBreak$ & $\ElseFinishesWithLineBreak$ & CommaFinishesWithLineBreak \\ + & \verb!end of body of mand arg!$\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & RCuBStartsOnOwnLine \\ + & \verb!}!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & RCuBFinishesWithLineBreak \\ + & \verb!...! & & \\ + \cmidrule{2-4} + commands & \verb!before words!$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & CommandStartsOnOwnLine \\ + & \verb!\mycommand!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & CommandNameFinishesWithLineBreak \\ + & $\langle$\itshape{arguments}$\rangle$ & & \\ + \cmidrule{2-4} + namedGroupingBraces Brackets & before words$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & NameStartsOnOwnLine \\ + & myname$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & NameFinishesWithLineBreak \\ + & $\langle$\itshape{braces/brackets}$\rangle$ & & \\ + \cmidrule{2-4} + keyEqualsValuesBraces\newline Brackets & before words$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & KeyStartsOnOwnLine \\ + & key$\EqualsStartsOnOwnLine$=$\BodyStartsOnOwnLine$ & $\EqualsStartsOnOwnLine$ & EqualsStartsOnOwnLine \\ + & $\langle$\itshape{braces/brackets}$\rangle$ & $\BodyStartsOnOwnLine$ & EqualsFinishesWithLineBreak \\ + \cmidrule{2-4} + items & before words$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & ItemStartsOnOwnLine \\ + & \verb!\item!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & ItemFinishesWithLineBreak \\ + & \verb!...! & & \\ + \cmidrule{2-4} + specialBeginEnd & before words$\BeginStartsOnOwnLine$ & $\BeginStartsOnOwnLine$ & SpecialBeginStartsOnOwnLine \\ + & \verb!\[!$\BodyStartsOnOwnLine$ & $\BodyStartsOnOwnLine$ & SpecialBodyStartsOnOwnLine \\ + & \verb!body of special/middle!$\ElseStartsOnOwnLine$ & $\ElseStartsOnOwnLine$ & SpecialMiddleStartsOnOwnLine % + \announce{2018-04-27}{new special code block poly-switches} \\ + & \verb!\middle!$\ElseFinishesWithLineBreak$ & $\ElseFinishesWithLineBreak$ & SpecialMiddleFinishesWithLineBreak \\ + & body of special/middle $\EndStartsOnOwnLine$ & $\EndStartsOnOwnLine$ & SpecialEndStartsOnOwnLine \\ + & \verb!\]!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & SpecialEndFinishesWithLineBreak \\ + & after words & & \\ + \cmidrule{2-4} + verbatim & before words$\BeginStartsOnOwnLine$\verb!\begin{verbatim}! & $\BeginStartsOnOwnLine$ & VerbatimBeginStartsOnOwnLine \\ + \announce{2019-05-05}{verbatim poly-switches} & body of verbatim \verb!\end{verbatim}!$\EndFinishesWithLineBreak$ & $\EndFinishesWithLineBreak$ & VerbatimEndFinishesWithLineBreak \\ + & after words & & \\ + \bottomrule + \end{longtable} +\subsubsection{Partnering BodyStartsOnOwnLine with argument-based poly-switches} + Some poly-switches need to be partnered together; in particular, when line breaks + involving the \emph{first} argument of a code block need to be accounted for using both + \texttt{BodyStartsOnOwnLine} (or its equivalent, see \vref{tab:poly-switch-mapping}) and + \texttt{LCuBStartsOnOwnLine} for mandatory arguments, and \texttt{LSqBStartsOnOwnLine} + for optional arguments. + \index{poly-switches!conflicting partnering} + + Let's begin with the code in \cref{lst:mycommand1} and the YAML settings in + \cref{lst:mycom-mlb1}; with reference to \vref{tab:poly-switch-mapping}, the key + \texttt{CommandNameFinishesWithLineBreak} is an alias for \texttt{BodyStartsOnOwnLine}. + + \cmhlistingsfromfile{demonstrations/mycommand1.tex}{\texttt{mycommand1.tex}}{lst:mycommand1} + + Upon running the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m -l=mycom-mlb1.yaml mycommand1.tex +\end{commandshell} + we obtain \cref{lst:mycommand1-mlb1}; note that the \emph{second} mandatory argument + beginning brace \lstinline!{! has had its leading line break removed, but that the + \emph{first} brace has not. + + \begin{cmhtcbraster}[ + raster force size=false, + raster column 1/.style={add to width=-1cm}, + ] + \cmhlistingsfromfile{demonstrations/mycommand1-mlb1.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb1}}{lst:mycommand1-mlb1} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb1.yaml}[MLB-TCB,width=.6\textwidth]{\texttt{mycom-mlb1.yaml}}{lst:mycom-mlb1} + \end{cmhtcbraster} + + Now let's change the YAML file so that it is as in \cref{lst:mycom-mlb2}; upon running + the analogous command to that given above, we obtain \cref{lst:mycommand1-mlb2}; both + beginning braces \lstinline!{! have had their leading line breaks removed. + + \begin{cmhtcbraster}[ + raster force size=false, + raster column 1/.style={add to width=-1cm}, + ] + \cmhlistingsfromfile{demonstrations/mycommand1-mlb2.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb2}}{lst:mycommand1-mlb2} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb2.yaml}[MLB-TCB,width=.6\textwidth]{\texttt{mycom-mlb2.yaml}}{lst:mycom-mlb2} + \end{cmhtcbraster} + + Now let's change the YAML file so that it is as in \cref{lst:mycom-mlb3}; upon running + the analogous command to that given above, we obtain \cref{lst:mycommand1-mlb3}. + + \begin{cmhtcbraster}[ + raster force size=false, + raster column 1/.style={add to width=-1cm}, + ] + \cmhlistingsfromfile{demonstrations/mycommand1-mlb3.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb3}}{lst:mycommand1-mlb3} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb3.yaml}[MLB-TCB,width=.6\textwidth]{\texttt{mycom-mlb3.yaml}}{lst:mycom-mlb3} + \end{cmhtcbraster} + +\subsubsection{Conflicting poly-switches: sequential code blocks} + It is very easy to have conflicting poly-switches; if we use the example from + \vref{lst:mycommand1}, and consider the YAML settings given in \cref{lst:mycom-mlb4}. The + output from running + \index{poly-switches!conflicting switches} + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m -l=mycom-mlb4.yaml mycommand1.tex +\end{commandshell} + is given in \cref{lst:mycom-mlb4}. + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/mycommand1-mlb4.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb4}}{lst:mycommand1-mlb4} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb4.yaml}[MLB-TCB,width=\linewidth]{\texttt{mycom-mlb4.yaml}}{lst:mycom-mlb4} + \end{cmhtcbraster} + + Studying \cref{lst:mycom-mlb4}, we see that the two poly-switches are at opposition with + one another: + \begin{itemize} + \item on the one hand, \texttt{LCuBStartsOnOwnLine} should \emph{not} start on its own line (as + poly-switch is set to $-1$); + \item on the other hand, \texttt{RCuBFinishesWithLineBreak} \emph{should} finish with a line + break. + \end{itemize} + So, which should win the conflict? As demonstrated in \cref{lst:mycommand1-mlb4}, it is + clear that \texttt{LCuBStartsOnOwnLine} won this conflict, and the reason is that + \emph{the second argument was processed after the first} -- in general, the most + recently-processed code block and associated poly-switch takes priority. + + We can explore this further by considering the YAML settings in \cref{lst:mycom-mlb5}; + upon running the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m -l=mycom-mlb5.yaml mycommand1.tex +\end{commandshell} + we obtain the output given in \cref{lst:mycommand1-mlb5}. + + \begin{cmhtcbraster}[raster column skip=.1\linewidth] + \cmhlistingsfromfile{demonstrations/mycommand1-mlb5.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb5}}{lst:mycommand1-mlb5} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb5.yaml}[MLB-TCB,width=\linewidth]{\texttt{mycom-mlb5.yaml}}{lst:mycom-mlb5} + \end{cmhtcbraster} + + As previously, the most-recently-processed code block takes priority -- as before, the + second (i.e, \emph{last}) argument. Exploring this further, we consider the YAML settings + in \cref{lst:mycom-mlb6}, which give associated output in \cref{lst:mycommand1-mlb6}. + + \begin{cmhtcbraster}[raster column skip=.1\linewidth] + \cmhlistingsfromfile{demonstrations/mycommand1-mlb6.tex}{\texttt{mycommand1.tex} using \cref{lst:mycom-mlb6}}{lst:mycommand1-mlb6} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycom-mlb6.yaml}[MLB-TCB,width=\linewidth]{\texttt{mycom-mlb6.yaml}}{lst:mycom-mlb6} + \end{cmhtcbraster} + + Note that a \lstinline!%! \emph{has} been added to the trailing first + \lstinline!}!; this is because: + \begin{itemize} + \item while processing the \emph{first} argument, the trailing line break has been removed + (\texttt{RCuBFinishesWithLineBreak} set to $-1$); + \item while processing the \emph{second} argument, \texttt{latexindent.pl} finds that it does + \emph{not} begin on its own line, and so because \texttt{LCuBStartsOnOwnLine} is set to + $2$, it adds a comment, followed by a line break. + \end{itemize} + +\subsubsection{Conflicting poly-switches: nested code blocks} + Now let's consider an example when nested code blocks have conflicting poly-switches; + we'll use the code in \cref{lst:nested-env}, noting that it contains nested environments. + \index{poly-switches!conflicting switches} + + \cmhlistingsfromfile{demonstrations/nested-env.tex}{\texttt{nested-env.tex}}{lst:nested-env} + + Let's use the YAML settings given in \cref{lst:nested-env-mlb1-yaml}, which upon running + the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m -l=nested-env-mlb1.yaml nested-env.tex +\end{commandshell} + gives the output in \cref{lst:nested-env-mlb1}. + + \begin{cmhtcbraster}[raster column skip=.05\linewidth] + \cmhlistingsfromfile{demonstrations/nested-env-mlb1.tex}{\texttt{nested-env.tex} using \cref{lst:nested-env-mlb1-yaml}}{lst:nested-env-mlb1} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/nested-env-mlb1.yaml}[MLB-TCB,width=\linewidth]{\texttt{nested-env-mlb1.yaml}}{lst:nested-env-mlb1-yaml} + \end{cmhtcbraster} + + In \cref{lst:nested-env-mlb1}, let's first of all note that both environments have + received the appropriate (default) indentation; secondly, note that the poly-switch + \texttt{EndStartsOnOwnLine} appears to have won the conflict, as \lstinline!\end{one}! + has had its leading line break removed. + + To understand it, let's talk about the three basic phases \label{page:phases}of + \texttt{latexindent.pl}: + \begin{enumerate} + \item Phase 1: packing, in which code blocks are replaced with unique ids, working from + \emph{the inside to the outside}, and then sequentially -- for example, in + \cref{lst:nested-env}, the \texttt{two} environment is found \emph{before} the + \texttt{one} environment; if the -m switch is active, then during this phase: + \begin{itemize} + \item line breaks at the beginning of the \texttt{body} can be added (if + \texttt{BodyStartsOnOwnLine} is $1$ or $2$) or removed (if \texttt{BodyStartsOnOwnLine} + is $-1$); + \item line breaks at the end of the body can be added (if \texttt{EndStartsOnOwnLine} is $1$ or + $2$) or removed (if \texttt{EndStartsOnOwnLine} is $-1$); + \item line breaks after the end statement can be added (if \texttt{EndFinishesWithLineBreak} is + $1$ or $2$). + \end{itemize} + \item Phase 2: indentation, in which white space is added to the begin, body, and end + statements; + \item Phase 3: unpacking, in which unique ids are replaced by their \emph{indented} code + blocks; if the -m switch is active, then during this phase, + \begin{itemize} + \item line breaks before \texttt{begin} statements can be added or removed (depending upon + \texttt{BeginStartsOnOwnLine}); + \item line breaks after \emph{end} statements can be removed but \emph{NOT} added (see + \texttt{EndFinishesWithLineBreak}). + \end{itemize} + \end{enumerate} + + With reference to \cref{lst:nested-env-mlb1}, this means that during Phase 1: + \begin{itemize} + \item the \texttt{two} environment is found first, and the line break ahead of the + \lstinline!\end{two}! statement is removed because \texttt{EndStartsOnOwnLine} is set to + $-1$. Importantly, because, \emph{at this stage}, + \lstinline!\end{two}! \emph{does} finish with a line break, + \texttt{EndFinishesWithLineBreak} causes no action. + \item next, the \texttt{one} environment is found; the line break ahead of + \lstinline!\end{one}! is removed because \texttt{EndStartsOnOwnLine} is set to + $-1$. + \end{itemize} + The indentation is done in Phase 2; in Phase 3 \emph{there is no option to add a line + break after the \lstinline!end! statements}. We can justify this by remembering that + during Phase 3, the \texttt{one} environment will be found and processed first, followed + by the \texttt{two} environment. If the \texttt{two} environment were to add a line break + after the + \lstinline!\end{two}! statement, then \texttt{latexindent.pl} would have no way of + knowing how much indentation to add to the subsequent text (in this case, + \lstinline!\end{one}!). + + We can explore this further using the poly-switches in \cref{lst:nested-env-mlb2}; upon + running the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -m -l=nested-env-mlb2.yaml nested-env.tex +\end{commandshell} + we obtain the output given in \cref{lst:nested-env-mlb2-output}. + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/nested-env-mlb2.tex}{\texttt{nested-env.tex} using \cref{lst:nested-env-mlb2}}{lst:nested-env-mlb2-output} + \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/nested-env-mlb2.yaml}[MLB-TCB,width=\linewidth]{\texttt{nested-env-mlb2.yaml}}{lst:nested-env-mlb2} + \end{cmhtcbraster} + + During Phase 1: + \begin{itemize} + \item the \texttt{two} environment is found first, and the line break ahead of the + \lstinline!\end{two}! statement is not changed because \texttt{EndStartsOnOwnLine} is + set to $1$. Importantly, because, \emph{at this stage}, + \lstinline!\end{two}! \emph{does} finish with a line break, + \texttt{EndFinishesWithLineBreak} causes no action. + \item next, the \texttt{one} environment is found; the line break ahead of + \lstinline!\end{one}! is already present, and no action is needed. + \end{itemize} + The indentation is done in Phase 2, and then in Phase 3, the \texttt{one} environment is + found and processed first, followed by the \texttt{two} environment. \emph{At this + stage}, the \texttt{two} environment finds \texttt{EndFinishesWithLineBreak} is $-1$, so + it removes the trailing line break; remember, at this point, \texttt{latexindent.pl} has + completely finished with the \texttt{one} environment. diff --git a/support/latexindent/documentation/subsec-remove-para-line-breaks.tex b/support/latexindent/documentation/subsec-remove-para-line-breaks.tex new file mode 100644 index 0000000000..f5531cbba4 --- /dev/null +++ b/support/latexindent/documentation/subsec-remove-para-line-breaks.tex @@ -0,0 +1,217 @@ +% arara: pdflatex: {shell: yes, files: [latexindent]} +\subsection{removeParagraphLineBreaks: modifying line breaks for paragraphs}\label{subsec:removeparagraphlinebreaks} When the \texttt{-m} switch is active + \texttt{latexindent.pl} has the ability to remove line + breaks% + \announce{2017-05-27}{removeParagraphLineBreaks} + from within paragraphs; the behaviour is controlled by the + \texttt{removeParagraphLineBreaks} field, detailed in + \cref{lst:removeParagraphLineBreaks}. Thank you to \cite{jowens} for shaping and + assisting with the testing of this feature. +\yamltitle{removeParagraphLineBreaks}*{fields} + This feature is considered complimentary to the \texttt{oneSentencePerLine} feature + described in \vref{sec:onesentenceperline}. + \index{specialBeginEnd!removeParagraphLineBreaks} + + \cmhlistingsfromfile[style=removeParagraphLineBreaks]*{../defaultSettings.yaml}[MLB-TCB,width=.85\linewidth,before=\centering]{\texttt{removeParagraphLineBreaks}}{lst:removeParagraphLineBreaks} + + This routine can be turned on \emph{globally} for \emph{every} code block type known to + \texttt{latexindent.pl} (see \vref{tab:code-blocks}) by using the \texttt{all} switch; by + default, this switch is \emph{off}. Assuming that the \texttt{all} switch is off, then + the routine can be controlled on a per-code-block-type basis, and within that, on a + per-name basis. We will consider examples of each of these in turn, but before we do, + let's specify what \texttt{latexindent.pl} considers as a paragraph: + \begin{itemize} + \item it must begin on its own line with either an alphabetic or numeric character, and not + with any of the code-block types detailed in \vref{tab:code-blocks}; + \item it can include line breaks, but finishes when it meets either a blank line, a + \lstinline!\par! command, or any of the user-specified settings in the + \texttt{paragraphsStopAt} field, detailed in \vref{lst:paragraphsStopAt}. + \end{itemize} + + Let's start with the \texttt{.tex} file in \cref{lst:shortlines}, together with the YAML + settings in \cref{lst:remove-para1-yaml}. + + \begin{cmhtcbraster} + \cmhlistingsfromfile[showspaces=true]{demonstrations/shortlines.tex}{\texttt{shortlines.tex}}{lst:shortlines} + \cmhlistingsfromfile{demonstrations/remove-para1.yaml}[MLB-TCB]{\texttt{remove-para1.yaml}}{lst:remove-para1-yaml} + \end{cmhtcbraster} + + Upon running the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{commandshell} +latexindent.pl -m shortlines.tex -o shortlines1.tex -l remove-para1.yaml +\end{commandshell} + then we obtain the output given in \cref{lst:shortlines1}. + + \cmhlistingsfromfile[showspaces=true]{demonstrations/shortlines1.tex}{\texttt{shortlines1.tex}}{lst:shortlines1} + + Keen readers may notice that some trailing white space must be present in the file in + \cref{lst:shortlines} which has crept in to the output in \cref{lst:shortlines1}. This + can be fixed using the YAML file in \vref{lst:removeTWS-before} and running, for example, + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{commandshell} +latexindent.pl -m shortlines.tex -o shortlines1-tws.tex -l remove-para1.yaml,removeTWS-before.yaml +\end{commandshell} + in which case the output is as in \cref{lst:shortlines1-tws}; notice that the double + spaces present in \cref{lst:shortlines1} have been addressed. + + \cmhlistingsfromfile[showspaces=true]{demonstrations/shortlines1-tws.tex}{\texttt{shortlines1-tws.tex}}{lst:shortlines1-tws} + + Keeping with the settings in \cref{lst:remove-para1-yaml}, we note that the \texttt{all} + switch applies to \emph{all} code block types. So, for example, let's consider the files + in \cref{lst:shortlines-mand,lst:shortlines-opt} + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/shortlines-mand.tex}{\texttt{shortlines-mand.tex}}{lst:shortlines-mand} + \cmhlistingsfromfile{demonstrations/shortlines-opt.tex}{\texttt{shortlines-opt.tex}}{lst:shortlines-opt} + \end{cmhtcbraster} + + Upon running the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl -m shortlines-mand.tex -o shortlines-mand1.tex -l remove-para1.yaml +latexindent.pl -m shortlines-opt.tex -o shortlines-opt1.tex -l remove-para1.yaml +\end{commandshell} + \end{widepage} + + then we obtain the respective output given in + \cref{lst:shortlines-mand1,lst:shortlines-opt1}. + + \cmhlistingsfromfile{demonstrations/shortlines-mand1.tex}{\texttt{shortlines-mand1.tex}}{lst:shortlines-mand1} + \cmhlistingsfromfile{demonstrations/shortlines-opt1.tex}{\texttt{shortlines-opt1.tex}}{lst:shortlines-opt1} + + Assuming that we turn \emph{off} the \texttt{all} switch (by setting it to \texttt{0}), + then we can control the behaviour of \texttt{removeParagraphLineBreaks} either on a + per-code-block-type basis, or on a per-name basis. + + For example, let's use the code in \cref{lst:shortlines-envs}, and consider the settings + in \cref{lst:remove-para2-yaml,lst:remove-para3-yaml}; note that in + \cref{lst:remove-para2-yaml} we specify that \emph{every} environment should receive + treatment from the routine, while in \cref{lst:remove-para3-yaml} we specify that + \emph{only} the \texttt{one} environment should receive the treatment. + + \begin{minipage}{.45\linewidth} + \cmhlistingsfromfile{demonstrations/shortlines-envs.tex}{\texttt{shortlines-envs.tex}}{lst:shortlines-envs} + \end{minipage} + \hfill + \begin{minipage}{.49\linewidth} + \cmhlistingsfromfile{demonstrations/remove-para2.yaml}[MLB-TCB]{\texttt{remove-para2.yaml}}{lst:remove-para2-yaml} + \cmhlistingsfromfile{demonstrations/remove-para3.yaml}[MLB-TCB]{\texttt{remove-para3.yaml}}{lst:remove-para3-yaml} + \end{minipage} + + Upon running the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl -m shortlines-envs.tex -o shortlines-envs2.tex -l remove-para2.yaml +latexindent.pl -m shortlines-envs.tex -o shortlines-envs3.tex -l remove-para3.yaml +\end{commandshell} + \end{widepage} + then we obtain the respective output given in + \cref{lst:shortlines-envs2,lst:shortlines-envs3}. + + \cmhlistingsfromfile{demonstrations/shortlines-envs2.tex}{\texttt{shortlines-envs2.tex}}{lst:shortlines-envs2} + \cmhlistingsfromfile{demonstrations/shortlines-envs3.tex}{\texttt{shortlines-envs3.tex}}{lst:shortlines-envs3} + + The remaining code-block types can be customised in analogous ways, although note that + \texttt{commands}, \texttt{keyEqualsValuesBracesBrackets}, + \texttt{namedGroupingBracesBrackets}, \texttt{UnNamedGroupingBracesBrackets} are + controlled by the \texttt{optionalArguments} and the \texttt{mandatoryArguments}. + + The only special case is the \texttt{masterDocument} field; this is designed for + `chapter'-type files that may contain paragraphs that are not within any other + code-blocks. For example, consider the file in \cref{lst:shortlines-md}, with the YAML + settings in \cref{lst:remove-para4-yaml}. + + \begin{cmhtcbraster} + \cmhlistingsfromfile{demonstrations/shortlines-md.tex}{\texttt{shortlines-md.tex}}{lst:shortlines-md} + \cmhlistingsfromfile{demonstrations/remove-para4.yaml}[MLB-TCB]{\texttt{remove-para4.yaml}}{lst:remove-para4-yaml} + \end{cmhtcbraster} + + Upon running the following command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl -m shortlines-md.tex -o shortlines-md4.tex -l remove-para4.yaml +\end{commandshell} + \end{widepage} + then we obtain the output in \cref{lst:shortlines-md4}. + \cmhlistingsfromfile{demonstrations/shortlines-md4.tex}{\texttt{shortlines-md4.tex}}{lst:shortlines-md4} + + Note% + \announce{2018-08-13}*{updates to all in removeParagraphLineBreaks} that the \texttt{all} field can take the same exceptions + detailed in \crefrange{lst:textwrap6-yaml}{lst:textwrap8-yaml}. + +\yamltitle{paragraphsStopAt}*{fields} + The paragraph line break routine considers blank lines and the + \lstinline|\par| command to be the end of a paragraph; + \announce{2017-05-27}{paragraphsStopAt} you can fine tune the behaviour of the routine + further by using the \texttt{paragraphsStopAt} fields, shown in + \cref{lst:paragraphsStopAt}. + \index{specialBeginEnd!paragraphsStopAt} + \index{verbatim!in relation to paragraphsStopAt} + + \cmhlistingsfromfile[style=paragraphsStopAt]*{../defaultSettings.yaml}[MLB-TCB,width=.85\linewidth,before=\centering]{\texttt{paragraphsStopAt}}{lst:paragraphsStopAt} + + The fields specified in \texttt{paragraphsStopAt} tell \texttt{latexindent.pl} to stop + the current paragraph when it reaches a line that \emph{begins} with any of the + code-block types specified as \texttt{1} in \cref{lst:paragraphsStopAt}. By default, + you'll see that the paragraph line break routine will stop when it reaches an environment + or verbatim code block at the beginning of a line. It is \emph{not} possible to specify + these fields on a per-name basis. + + Let's use the \texttt{.tex} file in \cref{lst:sl-stop}; we will, in turn, consider the + settings in \cref{lst:stop-command-yaml,lst:stop-comment-yaml}. + + \begin{minipage}{.45\linewidth} + \cmhlistingsfromfile{demonstrations/sl-stop.tex}{\texttt{sl-stop.tex}}{lst:sl-stop} + \end{minipage} + \hfill + \begin{minipage}{.49\linewidth} + \cmhlistingsfromfile{demonstrations/stop-command.yaml}[MLB-TCB]{\texttt{stop-command.yaml}}{lst:stop-command-yaml} + + \cmhlistingsfromfile{demonstrations/stop-comment.yaml}[MLB-TCB]{\texttt{stop-comment.yaml}}{lst:stop-comment-yaml} + \end{minipage} + + Upon using the settings from \vref{lst:remove-para4-yaml} and running the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{widepage} + \begin{commandshell} +latexindent.pl -m sl-stop.tex -o sl-stop4.tex -l remove-para4.yaml +latexindent.pl -m sl-stop.tex -o sl-stop4-command.tex -l=remove-para4.yaml,stop-command.yaml +latexindent.pl -m sl-stop.tex -o sl-stop4-comment.tex -l=remove-para4.yaml,stop-comment.yaml +\end{commandshell} + \end{widepage} + we obtain the respective outputs in \crefrange{lst:sl-stop4}{lst:sl-stop4-comment}; + notice in particular that: + \begin{itemize} + \item in \cref{lst:sl-stop4} the paragraph line break routine has included commands and + comments; + \item in \cref{lst:sl-stop4-command} the paragraph line break routine has \emph{stopped} at the + \texttt{emph} command, because in \cref{lst:stop-command-yaml} we have specified + \texttt{commands} to be \texttt{1}, and \texttt{emph} is at the beginning of a line; + \item in \cref{lst:sl-stop4-comment} the paragraph line break routine has \emph{stopped} at the + comments, because in \cref{lst:stop-comment-yaml} we have specified \texttt{comments} to + be \texttt{1}, and the comment is at the beginning of a line. + \end{itemize} + In all outputs in \crefrange{lst:sl-stop4}{lst:sl-stop4-comment} we notice that the + paragraph line break routine has stopped at \lstinline!\begin{myenv}! because, by + default, \texttt{environments} is set to \texttt{1} in \vref{lst:paragraphsStopAt}. + + \cmhlistingsfromfile{demonstrations/sl-stop4.tex}{\texttt{sl-stop4.tex}}{lst:sl-stop4} + \cmhlistingsfromfile{demonstrations/sl-stop4-command.tex}{\texttt{sl-stop4-command.tex}}{lst:sl-stop4-command} + \cmhlistingsfromfile{demonstrations/sl-stop4-comment.tex}{\texttt{sl-stop4-comment.tex}}{lst:sl-stop4-comment} + diff --git a/support/latexindent/documentation/subsec-text-wrap-summary.tex b/support/latexindent/documentation/subsec-text-wrap-summary.tex new file mode 100644 index 0000000000..89379eabbc --- /dev/null +++ b/support/latexindent/documentation/subsec-text-wrap-summary.tex @@ -0,0 +1,26 @@ +% arara: pdflatex: {shell: yes, files: [latexindent]} +\subsection{Summary of text wrapping} + I consider% + \announce*{2021-07-31}{text wrap quick start} + the most useful starting point for text wrapping to be given in + \cref{subsec:textwrapping-quick-start} and \cref{subsubsec:text-wrap-remove-para-bfccb}. + + Starting from \cref{lst:textwrap-qs-yaml}, it is likely that you will have to experiment + with making adjustments (such as that given in \cref{lst:textwrap14-yaml}) depending on + your preference. + + It is important to note the following: + \index{verbatim!within summary of text wrapping} + \begin{itemize} + \item verbatim code blocks of all types will \emph{not} be affected by the text wrapping + routine. See the demonstration in \vref{lst:textwrap2-mod1}, together with environments: + \vref{lst:verbatimEnvironments}, commands: \vref{lst:verbatimCommands}, + \texttt{noIndentBlock}: \cref{lst:noIndentBlock}, \texttt{specialBeginEnd}: + \vref{lst:special3-mod1}; + \item comments will \emph{not} be affected by the text wrapping routine (see + \vref{lst:textwrap3-mod1}); + \item it is possible to wrap text on a per-code-block and a per-name basis; + \announce{2018-08-13}*{updates to textWrapOptions} + \item indentation is performed \emph{after} the text wrapping routine; as such, indented code + will likely exceed any maximum value set in the \texttt{columns} field. + \end{itemize} diff --git a/support/latexindent/documentation/subsec-text-wrap.tex b/support/latexindent/documentation/subsec-text-wrap.tex new file mode 100644 index 0000000000..2e721cae1a --- /dev/null +++ b/support/latexindent/documentation/subsec-text-wrap.tex @@ -0,0 +1,359 @@ +% arara: pdflatex: {shell: yes, files: [latexindent]} +\subsection{Text Wrapping}\label{subsec:textwrapping} + There are \emph{many} different configuration options for the text wrapping routine of + \texttt{latexindent.pl}, perhaps \emph{too} many. The following sections are + comprehensive, but quite long; in an attempt to to be brief, you might begin with the + settings given in \cref{subsec:textwrapping-quick-start}. + +\subsubsection{Text wrap quick start}\label{subsec:textwrapping-quick-start} + + Of all the available text wrapping options, I consider \cref{lst:textwrap-qs-yaml} to be + among the most helpful starting points. + + \cmhlistingsfromfile*{demonstrations/textwrap-qs.yaml}[MLB-TCB,width=1\linewidth]{\texttt{textwrap-qs.yaml}}{lst:textwrap-qs-yaml} + + \index{text wrap!quick start} + + You can read about \texttt{perCodeBlockBasis} in \cref{subsec:text-wrap-per-code-block} + and \texttt{removeParagraphLineBreaks} in \cref{subsec:removeparagraphlinebreaks}. + + If the settings in \cref{lst:textwrap-qs-yaml} do not give your desired output, take a + look at the demonstration in \cref{subsubsec:text-wrap-remove-para-bfccb}, in particular + \cref{lst:textwrap-bfccb-mod14}. + +\subsubsection{textWrapOptions: modifying line breaks by text wrapping} + + When the \texttt{-m} switch is active \texttt{latexindent.pl} has the ability to wrap + text using the options% + \announce{2017-05-27}{textWrapOptions} specified in the \texttt{textWrapOptions} field, + see \cref{lst:textWrapOptions}. + + \index{modifying linebreaks! by text wrapping, globally} + + \cmhlistingsfromfile[style=textWrapOptions]*{../defaultSettings.yaml}[MLB-TCB,width=.85\linewidth,before=\centering]{\texttt{textWrapOptions}}{lst:textWrapOptions} + + The value of \texttt{columns} specifies the column at which the text should be wrapped. + + By default, the value of \texttt{columns} is \texttt{0}, so \texttt{latexindent.pl} will + \emph{not} wrap text; if you change it to a value of \texttt{2} or more, then text will + be wrapped after the character in the specified column. + + By default, the text wrapping routine will operate \emph{before} the code blocks have + been searched for; text wrapping on a \emph{per-code-block} basis is discussed in + \cref{subsec:text-wrap-per-code-block}. + + We consider the file give in \cref{lst:textwrap1} for demonstration. + + \begin{widepage} + \cmhlistingsfromfile{demonstrations/textwrap1.tex}{\texttt{textwrap1.tex}}{lst:textwrap1} + \end{widepage} + + Using the file \texttt{textwrap1.yaml} in \cref{lst:textwrap1-yaml}, and running the + command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{commandshell} +latexindent.pl -m textwrap1.tex -o textwrap1-mod1.tex -l textwrap1.yaml +\end{commandshell} + we obtain the output in \cref{lst:textwrap1-mod1}. + + \begin{cmhtcbraster}[raster column skip=.1\linewidth] + \cmhlistingsfromfile{demonstrations/textwrap1-mod1.tex}{\texttt{textwrap1-mod1.tex}}{lst:textwrap1-mod1} + \cmhlistingsfromfile{demonstrations/textwrap1.yaml}[MLB-TCB]{\texttt{textwrap1.yaml}}{lst:textwrap1-yaml} + \end{cmhtcbraster} + + The text wrapping routine is performed \emph{after} verbatim environments + \index{verbatim!in relation to textWrapOptions} have been stored, so verbatim + environments and verbatim commands are exempt from the routine. For example, using the + file in \cref{lst:textwrap2}, + \begin{widepage} + \cmhlistingsfromfile{demonstrations/textwrap2.tex}{\texttt{textwrap2.tex}}{lst:textwrap2} + \end{widepage} + and running the following command and continuing to use \texttt{textwrap1.yaml} from + \cref{lst:textwrap1-yaml}, + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{commandshell} +latexindent.pl -m textwrap2.tex -o textwrap2-mod1.tex -l textwrap1.yaml +\end{commandshell} + then the output is as in \cref{lst:textwrap2-mod1}. + \begin{widepage} + \cmhlistingsfromfile{demonstrations/textwrap2-mod1.tex}{\texttt{textwrap2-mod1.tex}}{lst:textwrap2-mod1} + \end{widepage} + Furthermore, the text wrapping routine is performed after the trailing comments have been + stored, and they are also exempt from text wrapping. For example, using the file in + \cref{lst:textwrap3} + \begin{widepage} + \cmhlistingsfromfile{demonstrations/textwrap3.tex}{\texttt{textwrap3.tex}}{lst:textwrap3} + \end{widepage} + and running the following command and continuing to use \texttt{textwrap1.yaml} from + \cref{lst:textwrap1-yaml}, + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{commandshell} +latexindent.pl -m textwrap3.tex -o textwrap3-mod1.tex -l textwrap1.yaml +\end{commandshell} + then the output is as in \cref{lst:textwrap3-mod1}. + + \cmhlistingsfromfile{demonstrations/textwrap3-mod1.tex}{\texttt{textwrap3-mod1.tex}}{lst:textwrap3-mod1} + + The% + \announce{2021-07-23}*{huge:overflow is now default} + default value of \texttt{huge} is \texttt{overflow}, which means that words will + \emph{not} be broken by the text wrapping routine, implemented by the \texttt{Text::Wrap} + \cite{textwrap}. There are options to change the \texttt{huge} option for the + \texttt{Text::Wrap} module to either \texttt{wrap} or \texttt{die}. Before modifying the + value of \texttt{huge}, please bear in mind the following warning: + \index{warning!changing huge (textwrap)} + \begin{warning} + \raggedright + Changing the value of \texttt{huge} to anything other than \texttt{overflow} will slow down + \texttt{latexindent.pl} significantly when the \texttt{-m} switch is active. + + Furthermore, changing \texttt{huge} means that you may have some words \emph{or commands}(!) + split across lines in your .tex file, which may affect your output. I do not recommend + changing this field. + \end{warning} + + For example, using the settings in \cref{lst:textwrap2A-yaml,lst:textwrap2B-yaml} and + running the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{commandshell} +latexindent.pl -m textwrap4.tex -o=+-mod2A -l textwrap2A.yaml +latexindent.pl -m textwrap4.tex -o=+-mod2B -l textwrap2B.yaml +\end{commandshell} + gives the respective output in \cref{lst:textwrap4-mod2A,lst:textwrap4-mod2B}. + + \begin{cmhtcbraster}[raster column skip=.1\linewidth] + \cmhlistingsfromfile{demonstrations/textwrap4-mod2A.tex}{\texttt{textwrap4-mod2A.tex}}{lst:textwrap4-mod2A} + \cmhlistingsfromfile{demonstrations/textwrap2A.yaml}[MLB-TCB]{\texttt{textwrap2A.yaml}}{lst:textwrap2A-yaml} + + \cmhlistingsfromfile{demonstrations/textwrap4-mod2B.tex}{\texttt{textwrap4-mod2B.tex}}{lst:textwrap4-mod2B} + \cmhlistingsfromfile{demonstrations/textwrap2B.yaml}[MLB-TCB]{\texttt{textwrap2B.yaml}}{lst:textwrap2B-yaml} + \end{cmhtcbraster} + + You can also specify the \texttt{tabstop} field% + \announce{2020-11-06}{tabstop option for text wrap module} as an integer value, which is + passed to the text wrap module; see \cite{textwrap} for details. Starting with the code + in \cref{lst:textwrap-ts} with settings in \cref{lst:tabstop}, and running the command + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \index{switches!-o demonstration} + \begin{commandshell} +latexindent.pl -m textwrap-ts.tex -o=+-mod1 -l tabstop.yaml +\end{commandshell} + gives the code given in \cref{lst:textwrap-ts-mod1}. + \begin{cmhtcbraster}[raster columns=3, + raster left skip=-3.5cm, + raster right skip=-2cm, + raster column skip=.03\linewidth] + \cmhlistingsfromfile[showtabs=true]*{demonstrations/textwrap-ts.tex}{\texttt{textwrap-ts.tex}}{lst:textwrap-ts} + \cmhlistingsfromfile{demonstrations/tabstop.yaml}[MLB-TCB]{\texttt{tabstop.yaml}}{lst:tabstop} + \cmhlistingsfromfile[showtabs=true]*{demonstrations/textwrap-ts-mod1.tex}{\texttt{textwrap-ts-mod1.tex}}{lst:textwrap-ts-mod1} + \end{cmhtcbraster} + + You can specify \texttt{separator}, \texttt{break} and \texttt{unexpand} options in your + settings in analogous ways to those demonstrated in + \cref{lst:textwrap2B-yaml,lst:tabstop}, and they will be passed to the + \texttt{Text::Wrap} module. I have not found a useful reason to do this; see + \cite{textwrap} for more details. + +\subsubsection{Text wrapping on a per-code-block basis}\label{subsec:text-wrap-per-code-block} By default, if the value of + \texttt{columns} is greater than 0 and the \texttt{-m} switch is active, + then% + \announce{2018-08-13}*{updates to textWrapOptions} + the text wrapping routine will operate before the code blocks have been searched for. + This behaviour is customisable; in particular, you can instead instruct + \texttt{latexindent.pl} to apply \texttt{textWrap} on a per-code-block basis. Thanks to + \cite{zoehneto} for their help in testing and shaping this feature. + \index{modifying linebreaks! by text wrapping, per-code-block} + + The full details of \texttt{textWrapOptions} are shown in \cref{lst:textWrapOptionsAll}. + In particular, note the field \texttt{perCodeBlockBasis: 0}. + \index{specialBeginEnd!textWrapOptions} + + \cmhlistingsfromfile*[style=textWrapOptionsAll]*{../defaultSettings.yaml}[MLB-TCB,width=.95\linewidth,before=\centering]{\texttt{textWrapOptions}}{lst:textWrapOptionsAll} + + The code blocks detailed in \cref{lst:textWrapOptionsAll} are with direct reference to + those detailed in \vref{tab:code-blocks}. + + The only special case is the \texttt{masterDocument} field; this is designed for + `chapter'-type files that may contain paragraphs that are not within any other + code-blocks. The same notation is used between this feature and the + \texttt{removeParagraphLineBreaks} described in \vref{lst:removeParagraphLineBreaks}; in + fact, the two features can even be combined (this is detailed in + \vref{subsec:removeparagraphlinebreaks:and:textwrap}). + + Let's explore these switches with reference to the code given in \cref{lst:textwrap5}; + the text outside of the environment is considered part of the \texttt{masterDocument}. + + \begin{widepage} + \cmhlistingsfromfile{demonstrations/textwrap5.tex}{\texttt{textwrap5.tex}}{lst:textwrap5} + \end{widepage} + + With reference to this code block, the settings given in + \cref{lst:textwrap3-yaml,lst:textwrap4-yaml,lst:textwrap5-yaml} each give the same + output. + + \begin{cmhtcbraster}[raster columns=3, + raster left skip=-3.5cm, + raster right skip=-2cm, + raster column skip=.03\linewidth] + \cmhlistingsfromfile{demonstrations/textwrap3.yaml}[MLB-TCB]{\texttt{textwrap3.yaml}}{lst:textwrap3-yaml} + \cmhlistingsfromfile{demonstrations/textwrap4.yaml}[MLB-TCB]{\texttt{textwrap4.yaml}}{lst:textwrap4-yaml} + \cmhlistingsfromfile{demonstrations/textwrap5.yaml}[MLB-TCB]{\texttt{textwrap5.yaml}}{lst:textwrap5-yaml} + \end{cmhtcbraster} + + Let's explore the similarities and differences in the equivalent (with respect to + \cref{lst:textwrap5}) syntax specified in + \cref{lst:textwrap3-yaml,lst:textwrap4-yaml,lst:textwrap5-yaml}: + \begin{itemize} + \item in each of \cref{lst:textwrap3-yaml,lst:textwrap4-yaml,lst:textwrap5-yaml} notice that + \texttt{columns: 30}; + \item in each of \cref{lst:textwrap3-yaml,lst:textwrap4-yaml,lst:textwrap5-yaml} notice that + \texttt{perCodeBlockBasis: 1}; + \item in \cref{lst:textwrap3-yaml} we have specified \texttt{all: 1} so that the text wrapping + will operate upon \emph{all} code blocks; + \item in \cref{lst:textwrap4-yaml} we have \emph{not} specified \texttt{all}, and instead, have + specified that text wrapping should be applied to each of \texttt{environments} and + \texttt{masterDocument}; + \item in \cref{lst:textwrap5-yaml} we have specified text wrapping for \texttt{masterDocument} + and on a \emph{per-name} basis for \texttt{environments} code blocks. + \end{itemize} + + Upon running the following commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -s textwrap5.tex -l=textwrap3.yaml -m +latexindent.pl -s textwrap5.tex -l=textwrap4.yaml -m +latexindent.pl -s textwrap5.tex -l=textwrap5.yaml -m +\end{commandshell} + we obtain the output shown in \cref{lst:textwrap5-mod3}. + + \cmhlistingsfromfile{demonstrations/textwrap5-mod3.tex}{\texttt{textwrap5-mod3.tex}}{lst:textwrap5-mod3} + + We can explore the idea of per-name text wrapping given in \cref{lst:textwrap5-yaml} by + using \cref{lst:textwrap6}. + + \begin{widepage} + \cmhlistingsfromfile{demonstrations/textwrap6.tex}{\texttt{textwrap6.tex}}{lst:textwrap6} + \end{widepage} + + In particular, upon running + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -s textwrap6.tex -l=textwrap5.yaml -m +\end{commandshell} + we obtain the output given in \cref{lst:textwrap6-mod5}. + + \begin{widepage} + \cmhlistingsfromfile{demonstrations/textwrap6-mod5.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap5-yaml}}{lst:textwrap6-mod5} + \end{widepage} + + Notice that, because \texttt{environments} has been specified only for \texttt{myenv} (in + \cref{lst:textwrap5-yaml}) that the environment named \texttt{another} has \emph{not} had + text wrapping applied to it. + + The {all} field can be specified with exceptions which can either be done on a + per-code-block or per-name basis; we explore this in relation to \cref{lst:textwrap6} in + the settings given in \crefrange{lst:textwrap6-yaml}{lst:textwrap8-yaml}. + + \begin{adjustwidth}{-3.5cm}{-2.5cm} + \begin{minipage}{.33\linewidth} + \cmhlistingsfromfile{demonstrations/textwrap6.yaml}[MLB-TCB]{\texttt{textwrap6.yaml}}{lst:textwrap6-yaml} + \end{minipage}% + \begin{minipage}{.33\linewidth} + \cmhlistingsfromfile{demonstrations/textwrap7.yaml}[MLB-TCB]{\texttt{textwrap7.yaml}}{lst:textwrap7-yaml} + \end{minipage}% + \begin{minipage}{.33\linewidth} + \cmhlistingsfromfile{demonstrations/textwrap8.yaml}[MLB-TCB]{\texttt{textwrap8.yaml}}{lst:textwrap8-yaml} + \end{minipage} + \end{adjustwidth} + + Upon running the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -s textwrap6.tex -l=textwrap6.yaml -m +latexindent.pl -s textwrap6.tex -l=textwrap7.yaml -m +latexindent.pl -s textwrap6.tex -l=textwrap8.yaml -m +\end{commandshell} + we receive the respective output given in + \crefrange{lst:textwrap6-mod6}{lst:textwrap6-mod8}. + \begin{widepage} + \cmhlistingsfromfile{demonstrations/textwrap6-mod6.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap6-yaml}}{lst:textwrap6-mod6} + + \cmhlistingsfromfile{demonstrations/textwrap6-mod7.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap7-yaml}}{lst:textwrap6-mod7} + + \cmhlistingsfromfile{demonstrations/textwrap6-mod8.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap8-yaml}}{lst:textwrap6-mod8} + \end{widepage} + + Notice that: + \begin{itemize} + \item in \cref{lst:textwrap6-mod6} the text wrapping routine has not been applied to any + \texttt{environments} because it has been switched off (per-code-block) in + \cref{lst:textwrap6-yaml}; + \item in \cref{lst:textwrap6-mod7} the text wrapping routine has not been applied to + \texttt{myenv} because it has been switched off (per-name) in \cref{lst:textwrap7-yaml}; + \item in \cref{lst:textwrap6-mod8} the text wrapping routine has not been applied to + \texttt{masterDocument} because of the settings in \cref{lst:textwrap8-yaml}. + \end{itemize} + + The \texttt{columns} field has a variety of different ways that it can be specified; + we've seen two basic ways already: the default (set to \texttt{0}) and a positive integer + (see \vref{lst:textwrap6}, for example). We explore further options in + \crefrange{lst:textwrap9-yaml}{lst:textwrap11-yaml}. + + \begin{cmhtcbraster}[raster columns=3, + raster left skip=-3.5cm, + raster right skip=-2cm, + raster column skip=.03\linewidth] + \cmhlistingsfromfile{demonstrations/textwrap9.yaml}[MLB-TCB]{\texttt{textwrap9.yaml}}{lst:textwrap9-yaml} + \cmhlistingsfromfile{demonstrations/textwrap10.yaml}[MLB-TCB]{\texttt{textwrap10.yaml}}{lst:textwrap10-yaml} + \cmhlistingsfromfile{demonstrations/textwrap11.yaml}[MLB-TCB]{\texttt{textwrap11.yaml}}{lst:textwrap11-yaml} + \end{cmhtcbraster} + + \Cref{lst:textwrap9-yaml} and \cref{lst:textwrap10-yaml} are equivalent. Upon running + the commands + \index{switches!-l demonstration} + \index{switches!-m demonstration} + \begin{commandshell} +latexindent.pl -s textwrap6.tex -l=textwrap9.yaml -m +latexindent.pl -s textwrap6.tex -l=textwrap11.yaml -m +\end{commandshell} + we receive the respective output given in \cref{lst:textwrap6-mod9,lst:textwrap6-mod11}. + + \begin{widepage} + \cmhlistingsfromfile{demonstrations/textwrap6-mod9.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap9-yaml}}{lst:textwrap6-mod9} + + \cmhlistingsfromfile{demonstrations/textwrap6-mod11.tex}{\texttt{textwrap6.tex} using \cref{lst:textwrap11-yaml}}{lst:textwrap6-mod11} + \end{widepage} + + Notice that: + \begin{itemize} + \item in \cref{lst:textwrap6-mod9} the text for the \texttt{masterDocument} has been wrapped + using \texttt{30} columns, while \texttt{environments} has been wrapped using \texttt{50} + columns; + \item in \cref{lst:textwrap6-mod11} the text for \texttt{myenv} has been wrapped using + \texttt{50} columns, the text for \texttt{another} has been wrapped using \texttt{15} + columns, and \texttt{masterDocument} has been wrapped using \texttt{30} columns. + \end{itemize} + If you don't specify a \texttt{default} value on per-code-block basis, then the + \texttt{default} value from \texttt{columns} will be inherited; if you don't specify a + default value for \texttt{columns} then \texttt{80} will be used. + + \texttt{alignAtAmpersandTakesPriority} is set to \texttt{1} by default; assuming + that text wrapping is occurring on a per-code-block basis, and the current + environment/code block is specified within \vref{lst:aligndelims:basic} then text + wrapping will be disabled for this code block. + + If you wish to specify \texttt{afterHeading} commands (see + \vref{lst:indentAfterHeadings}) on a per-name basis, then you need to append the name + with \texttt{:heading}, for example, you might use \texttt{section:heading}. diff --git a/support/latexindent/documentation/subsubsec-commands-with-arguments.tex b/support/latexindent/documentation/subsubsec-commands-with-arguments.tex index 5531e7eace..9521a04fb6 100644 --- a/support/latexindent/documentation/subsubsec-commands-with-arguments.tex +++ b/support/latexindent/documentation/subsubsec-commands-with-arguments.tex @@ -1,18 +1,18 @@ % arara: pdflatex: {shell: yes, files: [latexindent]} \subsubsection{Commands with arguments}\label{subsubsec:commands-arguments} - Let's begin with the simple example in \cref{lst:mycommand}; when - \texttt{latexindent.pl} operates on this file, the default output is shown in - \cref{lst:mycommand-default}. \footnote{The command code blocks - have quite a few subtleties, described in \vref{subsec:commands-string-between}.} + Let's begin with the simple example in \cref{lst:mycommand}; when \texttt{latexindent.pl} + operates on this file, the default output is shown in \cref{lst:mycommand-default}. + \footnote{The command code blocks have quite a few subtleties, described in + \vref{subsec:commands-string-between}.} \begin{cmhtcbraster}[raster column skip=.1\linewidth] \cmhlistingsfromfile{demonstrations/mycommand.tex}{\texttt{mycommand.tex}}{lst:mycommand} \cmhlistingsfromfile{demonstrations/mycommand-default.tex}{\texttt{mycommand.tex} default output}{lst:mycommand-default} \end{cmhtcbraster} - As in the environment-based case (see \vref{lst:myenv-noAdd1,lst:myenv-noAdd2}) we may specify - \texttt{noAdditionalIndent} either in `scalar' form, or in `field' form, as shown in - \cref{lst:mycommand-noAdd1,lst:mycommand-noAdd2} + As in the environment-based case (see \vref{lst:myenv-noAdd1,lst:myenv-noAdd2}) we may + specify \texttt{noAdditionalIndent} either in `scalar' form, or in `field' form, as shown + in \cref{lst:mycommand-noAdd1,lst:mycommand-noAdd2} \begin{minipage}{.45\textwidth} \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycommand-noAdd1.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{mycommand-noAdd1.yaml}}{lst:mycommand-noAdd1} @@ -28,7 +28,8 @@ latexindent.pl mycommand.tex -l mycommand-noAdd1.yaml latexindent.pl mycommand.tex -l mycommand-noAdd2.yaml \end{commandshell} - we receive the respective output given in \cref{lst:mycommand-output-noAdd1,lst:mycommand-output-noAdd2} + we receive the respective output given in + \cref{lst:mycommand-output-noAdd1,lst:mycommand-output-noAdd2} \begin{minipage}{.45\textwidth} \cmhlistingsfromfile{demonstrations/mycommand-noAdd1.tex}{\texttt{mycommand.tex} using \cref{lst:mycommand-noAdd1}}{lst:mycommand-output-noAdd1} @@ -39,13 +40,14 @@ latexindent.pl mycommand.tex -l mycommand-noAdd2.yaml \end{minipage} Note that in \cref{lst:mycommand-output-noAdd1} that the `body', optional argument - \emph{and} mandatory argument have \emph{all} received no - additional indentation, while in \cref{lst:mycommand-output-noAdd2}, only the `body' has not received - any additional indentation. We define the `body' of a command as any lines following the - command name that include its optional or mandatory arguments. + \emph{and} mandatory argument have \emph{all} received no additional indentation, while + in \cref{lst:mycommand-output-noAdd2}, only the `body' has not received any additional + indentation. We define the `body' of a command as any lines following the command name + that include its optional or mandatory arguments. We may further customise \texttt{noAdditionalIndent} for \texttt{mycommand} as we did in - \vref{lst:myenv-noAdd5,lst:myenv-noAdd6}; explicit examples are given in \cref{lst:mycommand-noAdd3,lst:mycommand-noAdd4}. + \vref{lst:myenv-noAdd5,lst:myenv-noAdd6}; explicit examples are given in + \cref{lst:mycommand-noAdd3,lst:mycommand-noAdd4}. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycommand-noAdd3.yaml}[width=.9\linewidth,before=\centering,yaml-TCB]{\texttt{mycommand-noAdd3.yaml}}{lst:mycommand-noAdd3} @@ -61,7 +63,8 @@ latexindent.pl mycommand.tex -l mycommand-noAdd2.yaml latexindent.pl mycommand.tex -l mycommand-noAdd3.yaml latexindent.pl mycommand.tex -l mycommand-noAdd4.yaml \end{commandshell} - we receive the respective output given in \cref{lst:mycommand-output-noAdd3,lst:mycommand-output-noAdd4}. + we receive the respective output given in + \cref{lst:mycommand-output-noAdd3,lst:mycommand-output-noAdd4}. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile{demonstrations/mycommand-noAdd3.tex}{\texttt{mycommand.tex} using \cref{lst:mycommand-noAdd3}}{lst:mycommand-output-noAdd3} @@ -72,11 +75,12 @@ latexindent.pl mycommand.tex -l mycommand-noAdd4.yaml \end{minipage} Attentive readers will note that the body of \texttt{mycommand} in both - \cref{lst:mycommand-output-noAdd3,lst:mycommand-output-noAdd4} has received no additional indent, even though - \texttt{body} is explicitly set to \texttt{0} in both - \cref{lst:mycommand-noAdd3,lst:mycommand-noAdd4}. This is because, by default, \texttt{noAdditionalIndentGlobal} for - \texttt{commands} is set to \texttt{1} by default; this can be easily - fixed as in \cref{lst:mycommand-noAdd5,lst:mycommand-noAdd6}.\label{page:command:noAddGlobal} + \cref{lst:mycommand-output-noAdd3,lst:mycommand-output-noAdd4} has received no additional + indent, even though \texttt{body} is explicitly set to \texttt{0} in both + \cref{lst:mycommand-noAdd3,lst:mycommand-noAdd4}. This is because, by default, + \texttt{noAdditionalIndentGlobal} for \texttt{commands} is set to \texttt{1} by default; + this can be easily fixed as in + \cref{lst:mycommand-noAdd5,lst:mycommand-noAdd6}.\label{page:command:noAddGlobal} \begin{minipage}{.45\textwidth} \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/mycommand-noAdd5.yaml}[width=.9\linewidth,before=\centering,yaml-TCB]{\texttt{mycommand-noAdd5.yaml}}{lst:mycommand-noAdd5} @@ -92,7 +96,8 @@ latexindent.pl mycommand.tex -l mycommand-noAdd4.yaml latexindent.pl mycommand.tex -l mycommand-noAdd5.yaml latexindent.pl mycommand.tex -l mycommand-noAdd6.yaml \end{commandshell} - we receive the respective output given in \cref{lst:mycommand-output-noAdd5,lst:mycommand-output-noAdd6}. + we receive the respective output given in + \cref{lst:mycommand-output-noAdd5,lst:mycommand-output-noAdd6}. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile{demonstrations/mycommand-noAdd5.tex}{\texttt{mycommand.tex} using \cref{lst:mycommand-noAdd5}}{lst:mycommand-output-noAdd5} diff --git a/support/latexindent/documentation/subsubsec-environments-and-their-arguments.tex b/support/latexindent/documentation/subsubsec-environments-and-their-arguments.tex index b151d2d767..ebd37ac4f0 100644 --- a/support/latexindent/documentation/subsubsec-environments-and-their-arguments.tex +++ b/support/latexindent/documentation/subsubsec-environments-and-their-arguments.tex @@ -6,8 +6,8 @@ \cmhlistingsfromfile{demonstrations/myenvironment-simple.tex}{\texttt{myenv.tex}}{lst:myenvtex} \yamltitle{noAdditionalIndent}*{fields} - If we do not wish \texttt{myenv} to receive any additional indentation, we have a - few choices available to us, as demonstrated in \cref{lst:myenv-noAdd1,lst:myenv-noAdd2}. + If we do not wish \texttt{myenv} to receive any additional indentation, we have a few + choices available to us, as demonstrated in \cref{lst:myenv-noAdd1,lst:myenv-noAdd2}. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/myenv-noAdd1.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{myenv-noAdd1.yaml}}{lst:myenv-noAdd1} @@ -24,13 +24,13 @@ latexindent.pl myenv.tex -l myenv-noAdd1.yaml latexindent.pl myenv.tex -l myenv-noAdd2.yaml \end{commandshell} we obtain the output given in \cref{lst:myenv-output}; note in particular that the - environment \texttt{myenv} has not received any \emph{additional} - indentation, but that the \texttt{outer} environment \emph{has} still - received indentation. + environment \texttt{myenv} has not received any \emph{additional} indentation, but that + the \texttt{outer} environment \emph{has} still received indentation. \cmhlistingsfromfile{demonstrations/myenvironment-simple-noAdd-body1.tex}{\texttt{myenv.tex} output (using either \cref{lst:myenv-noAdd1} or \cref{lst:myenv-noAdd2})}{lst:myenv-output} - Upon changing the YAML files to those shown in \cref{lst:myenv-noAdd3,lst:myenv-noAdd4}, and running either + Upon changing the YAML files to those shown in \cref{lst:myenv-noAdd3,lst:myenv-noAdd4}, + and running either \index{switches!-l demonstration} \begin{commandshell} latexindent.pl myenv.tex -l myenv-noAdd3.yaml @@ -48,8 +48,8 @@ latexindent.pl myenv.tex -l myenv-noAdd4.yaml \cmhlistingsfromfile{demonstrations/myenvironment-simple-noAdd-body4.tex}{\texttt{myenv.tex output} (using either \cref{lst:myenv-noAdd3} or \cref{lst:myenv-noAdd4})}{lst:myenv-output-4} - Let's now allow \texttt{myenv} to have some optional and mandatory arguments, as - in \cref{lst:myenv-args}. + Let's now allow \texttt{myenv} to have some optional and mandatory arguments, as in + \cref{lst:myenv-args}. \cmhlistingsfromfile{demonstrations/myenvironment-args.tex}{\texttt{myenv-args.tex}}{lst:myenv-args} @@ -58,15 +58,16 @@ latexindent.pl myenv.tex -l myenv-noAdd4.yaml \begin{commandshell} latexindent.pl -l=myenv-noAdd1.yaml myenv-args.tex \end{commandshell} - we obtain the output shown in \cref{lst:myenv-args-noAdd1}; note that the optional argument, - mandatory argument and body \emph{all} have received no additional indent. - This is because, when \texttt{noAdditionalIndent} is specified in `scalar' form (as in - \cref{lst:myenv-noAdd1}), then \emph{all} parts of the environment (body, - optional and mandatory arguments) are assumed to want no additional indent. + we obtain the output shown in \cref{lst:myenv-args-noAdd1}; note that the optional + argument, mandatory argument and body \emph{all} have received no additional indent. This + is because, when \texttt{noAdditionalIndent} is specified in `scalar' form (as in + \cref{lst:myenv-noAdd1}), then \emph{all} parts of the environment (body, optional and + mandatory arguments) are assumed to want no additional indent. \cmhlistingsfromfile{demonstrations/myenvironment-args-noAdd-body1.tex}{\texttt{myenv-args.tex} using \cref{lst:myenv-noAdd1}}{lst:myenv-args-noAdd1} We may customise \texttt{noAdditionalIndent} for optional and mandatory arguments of the - \texttt{myenv} environment, as shown in, for example, \cref{lst:myenv-noAdd5,lst:myenv-noAdd6}. + \texttt{myenv} environment, as shown in, for example, + \cref{lst:myenv-noAdd5,lst:myenv-noAdd6}. \begin{minipage}{.49\textwidth} \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/myenv-noAdd5.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{myenv-noAdd5.yaml}}{lst:myenv-noAdd5} @@ -82,11 +83,12 @@ latexindent.pl -l=myenv-noAdd1.yaml myenv-args.tex latexindent.pl myenv.tex -l myenv-noAdd5.yaml latexindent.pl myenv.tex -l myenv-noAdd6.yaml \end{commandshell} - we obtain the respective outputs given in \cref{lst:myenv-args-noAdd5,lst:myenv-args-noAdd6}. Note that in - \cref{lst:myenv-args-noAdd5} the text for the \emph{optional} argument has not - received any additional indentation, and that in \cref{lst:myenv-args-noAdd6} the - \emph{mandatory} argument has not received any additional indentation; in both - cases, the \emph{body} has not received any additional indentation. + we obtain the respective outputs given in + \cref{lst:myenv-args-noAdd5,lst:myenv-args-noAdd6}. Note that in + \cref{lst:myenv-args-noAdd5} the text for the \emph{optional} argument has not received + any additional indentation, and that in \cref{lst:myenv-args-noAdd6} the \emph{mandatory} + argument has not received any additional indentation; in both cases, the \emph{body} has + not received any additional indentation. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile{demonstrations/myenvironment-args-noAdd5.tex}{\texttt{myenv-args.tex} using \cref{lst:myenv-noAdd5}}{lst:myenv-args-noAdd5} @@ -112,9 +114,8 @@ latexindent.pl myenv.tex -l myenv-rules1.yaml latexindent.pl myenv.tex -l myenv-rules2.yaml \end{commandshell} we obtain the output given in \cref{lst:myenv-rules-output}; note in particular that the - environment \texttt{myenv} has received one tab (from the - \texttt{outer} environment) plus three spaces from \cref{lst:myenv-rules1} or - \ref{lst:myenv-rules2}. + environment \texttt{myenv} has received one tab (from the \texttt{outer} environment) + plus three spaces from \cref{lst:myenv-rules1} or \ref{lst:myenv-rules2}. \cmhlistingsfromfile[showtabs=true,showspaces=true]{demonstrations/myenv-rules1.tex}{\texttt{myenv.tex} output (using either \cref{lst:myenv-rules1} or \cref{lst:myenv-rules2})}{lst:myenv-rules-output} @@ -127,9 +128,10 @@ latexindent.pl myenv.tex -l myenv-rules2.yaml \begin{commandshell} latexindent.pl myenv-args.tex -l=myenv-rules1.yaml \end{commandshell} - we obtain the output in \cref{lst:myenv-args-rules1}; note that the body, optional argument - and mandatory argument of \texttt{myenv} have \emph{all} received - the same customised indentation. \cmhlistingsfromfile[showtabs=true,showspaces=true]{demonstrations/myenvironment-args-rules1.tex}{\texttt{myenv-args.tex} using \cref{lst:myenv-rules1}}{lst:myenv-args-rules1} + we obtain the output in \cref{lst:myenv-args-rules1}; note that the body, optional + argument and mandatory argument of \texttt{myenv} have \emph{all} received the same + customised indentation. + \cmhlistingsfromfile[showtabs=true,showspaces=true]{demonstrations/myenvironment-args-rules1.tex}{\texttt{myenv-args.tex} using \cref{lst:myenv-rules1}}{lst:myenv-args-rules1} You can specify different indentation rules for the different features using, for example, \cref{lst:myenv-rules3,lst:myenv-rules4} @@ -148,7 +150,8 @@ latexindent.pl myenv-args.tex -l=myenv-rules1.yaml latexindent.pl myenv-args.tex -l myenv-rules3.yaml latexindent.pl myenv-args.tex -l myenv-rules4.yaml \end{commandshell} - then we obtain the respective outputs given in \cref{lst:myenv-args-rules3,lst:myenv-args-rules4}. + then we obtain the respective outputs given in + \cref{lst:myenv-args-rules3,lst:myenv-args-rules4}. \begin{widepage} \begin{minipage}{.5\textwidth} @@ -160,8 +163,8 @@ latexindent.pl myenv-args.tex -l myenv-rules4.yaml \end{minipage} \end{widepage} - Note that in \cref{lst:myenv-args-rules3}, the optional argument has only received a single - space of indentation, while the mandatory argument has received the default (tab) + Note that in \cref{lst:myenv-args-rules3}, the optional argument has only received a + single space of indentation, while the mandatory argument has received the default (tab) indentation; the environment body has received three spaces of indentation. In \cref{lst:myenv-args-rules4}, the optional argument has received the default (tab) @@ -172,11 +175,12 @@ latexindent.pl myenv-args.tex -l myenv-rules4.yaml \begin{wrapfigure}[6]{r}[0pt]{7cm} \cmhlistingsfromfile[style=noAdditionalIndentGlobalEnv]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{noAdditionalIndentGlobal}}{lst:noAdditionalIndentGlobal:environments} \end{wrapfigure} - Assuming that your environment name is not found within neither \texttt{noAdditionalIndent} - nor \texttt{indentRules}, the next place that \texttt{latexindent.pl} will look is - \texttt{noAdditionalIndentGlobal}, and in particular \emph{for the environments} key (see - \cref{lst:noAdditionalIndentGlobal:environments}). Let's say that you change the value of \texttt{environments} - to \texttt{1} in \cref{lst:noAdditionalIndentGlobal:environments}, and that you run + Assuming that your environment name is not found within neither + \texttt{noAdditionalIndent} nor \texttt{indentRules}, the next place that + \texttt{latexindent.pl} will look is \texttt{noAdditionalIndentGlobal}, and in particular + \emph{for the environments} key (see \cref{lst:noAdditionalIndentGlobal:environments}). + Let's say that you change the value of \texttt{environments} to \texttt{1} in + \cref{lst:noAdditionalIndentGlobal:environments}, and that you run \index{switches!-l demonstration} \begin{widepage} @@ -186,12 +190,13 @@ latexindent.pl myenv-args.tex -l myenv-rules1.yaml,env-noAdditionalGlobal.yaml \end{commandshell} \end{widepage} - The respective output from these two commands are in \cref{lst:myenv-args-no-add-global1,lst:myenv-args-no-add-global2}; in + The respective output from these two commands are in + \cref{lst:myenv-args-no-add-global1,lst:myenv-args-no-add-global2}; in \cref{lst:myenv-args-no-add-global1} notice that \emph{both} environments receive no - additional indentation but that the arguments of \texttt{myenv} still - \emph{do} receive indentation. In \cref{lst:myenv-args-no-add-global2} notice that the - \emph{outer} environment does not receive additional indentation, but because - of the settings from \texttt{myenv-rules1.yaml} (in \vref{lst:myenv-rules1}), the \texttt{myenv} environment + additional indentation but that the arguments of \texttt{myenv} still \emph{do} receive + indentation. In \cref{lst:myenv-args-no-add-global2} notice that the \emph{outer} + environment does not receive additional indentation, but because of the settings from + \texttt{myenv-rules1.yaml} (in \vref{lst:myenv-rules1}), the \texttt{myenv} environment still \emph{does} receive indentation. \begin{minipage}{.45\textwidth} @@ -202,8 +207,9 @@ latexindent.pl myenv-args.tex -l myenv-rules1.yaml,env-noAdditionalGlobal.yaml \cmhlistingsfromfile{demonstrations/myenvironment-args-rules1-noAddGlobal2.tex}{\texttt{myenv-args.tex} using \cref{lst:noAdditionalIndentGlobal:environments,lst:myenv-rules1}}{lst:myenv-args-no-add-global2} \end{minipage} - In fact, \texttt{noAdditionalIndentGlobal} also contains keys that control the indentation of - optional and mandatory arguments; on referencing \cref{lst:opt-args-no-add-glob,lst:mand-args-no-add-glob} + In fact, \texttt{noAdditionalIndentGlobal} also contains keys that control the + indentation of optional and mandatory arguments; on referencing + \cref{lst:opt-args-no-add-glob,lst:mand-args-no-add-glob} \begin{minipage}{.49\textwidth} \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/opt-args-no-add-glob.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{opt-args-no-add-glob.yaml}}{lst:opt-args-no-add-glob} @@ -219,7 +225,8 @@ latexindent.pl myenv-args.tex -l myenv-rules1.yaml,env-noAdditionalGlobal.yaml latexindent.pl myenv-args.tex -local opt-args-no-add-glob.yaml latexindent.pl myenv-args.tex -local mand-args-no-add-glob.yaml \end{commandshell} - which produces the respective outputs given in \cref{lst:myenv-args-no-add-opt,lst:myenv-args-no-add-mand}. Notice that in + which produces the respective outputs given in + \cref{lst:myenv-args-no-add-opt,lst:myenv-args-no-add-mand}. Notice that in \cref{lst:myenv-args-no-add-opt} the \emph{optional} argument has not received any additional indentation, and in \cref{lst:myenv-args-no-add-mand} the \emph{mandatory} argument has not received any additional indentation. @@ -237,8 +244,8 @@ latexindent.pl myenv-args.tex -local mand-args-no-add-glob.yaml \cmhlistingsfromfile[style=indentRulesGlobalEnv]*{../defaultSettings.yaml}[width=.8\linewidth,before=\centering,yaml-TCB]{\texttt{indentRulesGlobal}}{lst:indentRulesGlobal:environments} \end{wrapfigure} The final check that \texttt{latexindent.pl} will make is to look for - \texttt{indentRulesGlobal} as detailed in \cref{lst:indentRulesGlobal:environments}; if you change the - \texttt{environments} field to anything involving horizontal space, say + \texttt{indentRulesGlobal} as detailed in \cref{lst:indentRulesGlobal:environments}; if + you change the \texttt{environments} field to anything involving horizontal space, say \lstinline!" "!, and then run the following commands \index{switches!-l demonstration} @@ -246,12 +253,14 @@ latexindent.pl myenv-args.tex -local mand-args-no-add-glob.yaml latexindent.pl myenv-args.tex -l env-indentRules.yaml latexindent.pl myenv-args.tex -l myenv-rules1.yaml,env-indentRules.yaml \end{commandshell} - then the respective output is shown in \cref{lst:myenv-args-indent-rules-global1,lst:myenv-args-indent-rules-global2}. Note that in - \cref{lst:myenv-args-indent-rules-global1}, both the environment blocks have received a single-space - indentation, whereas in \cref{lst:myenv-args-indent-rules-global2} the \texttt{outer} environment - has received single-space indentation (specified by \texttt{indentRulesGlobal}), but - \texttt{myenv} has received \lstinline!" "!, as specified by the - particular \texttt{indentRules} for \texttt{myenv} \vref{lst:myenv-rules1}. + then the respective output is shown in + \cref{lst:myenv-args-indent-rules-global1,lst:myenv-args-indent-rules-global2}. Note that + in \cref{lst:myenv-args-indent-rules-global1}, both the environment blocks have received + a single-space indentation, whereas in \cref{lst:myenv-args-indent-rules-global2} the + \texttt{outer} environment has received single-space indentation (specified by + \texttt{indentRulesGlobal}), but \texttt{myenv} has received \lstinline!" "!, as + specified by the particular \texttt{indentRules} for \texttt{myenv} + \vref{lst:myenv-rules1}. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile[showspaces=true]{demonstrations/myenvironment-args-global-rules1.tex}{\texttt{myenv-args.tex} using \cref{lst:indentRulesGlobal:environments}}{lst:myenv-args-indent-rules-global1} @@ -278,9 +287,10 @@ latexindent.pl myenv-args.tex -l myenv-rules1.yaml,env-indentRules.yaml latexindent.pl myenv-args.tex -local opt-args-indent-rules-glob.yaml latexindent.pl myenv-args.tex -local mand-args-indent-rules-glob.yaml \end{commandshell} - we obtain the respective outputs in \cref{lst:myenv-args-indent-rules-global3,lst:myenv-args-indent-rules-global4}. Note that the - \emph{optional} argument in \cref{lst:myenv-args-indent-rules-global3} has received two tabs worth - of indentation, while the \emph{mandatory} argument has done so in + we obtain the respective outputs in + \cref{lst:myenv-args-indent-rules-global3,lst:myenv-args-indent-rules-global4}. Note that + the \emph{optional} argument in \cref{lst:myenv-args-indent-rules-global3} has received + two tabs worth of indentation, while the \emph{mandatory} argument has done so in \cref{lst:myenv-args-indent-rules-global4}. \begin{widepage} diff --git a/support/latexindent/documentation/subsubsec-environments-with-items.tex b/support/latexindent/documentation/subsubsec-environments-with-items.tex index c615be110d..0a08b9b4c8 100644 --- a/support/latexindent/documentation/subsubsec-environments-with-items.tex +++ b/support/latexindent/documentation/subsubsec-environments-with-items.tex @@ -1,15 +1,14 @@ % arara: pdflatex: {shell: yes, files: [latexindent]} \subsubsection{Environments with items} With reference to \vref{lst:indentafteritems,lst:itemNames}, some commands may contain - \texttt{item} commands; for the purposes of this discussion, we will use the - code from \vref{lst:itemsbefore}. + \texttt{item} commands; for the purposes of this discussion, we will use the code from + \vref{lst:itemsbefore}. - Assuming that you've populated \texttt{itemNames} with the name of your - \texttt{item}, you can put the item name into \texttt{noAdditionalIndent} as in - \cref{lst:item-noAdd1}, although a more efficient approach may be to change the relevant - field in \texttt{itemNames} to \texttt{0}. Similarly, you can customise - the indentation that your \texttt{item} receives using \texttt{indentRules}, - as in \cref{lst:item-rules1} + Assuming that you've populated \texttt{itemNames} with the name of your \texttt{item}, + you can put the item name into \texttt{noAdditionalIndent} as in \cref{lst:item-noAdd1}, + although a more efficient approach may be to change the relevant field in + \texttt{itemNames} to \texttt{0}. Similarly, you can customise the indentation that your + \texttt{item} receives using \texttt{indentRules}, as in \cref{lst:item-rules1} \begin{cmhtcbraster}[raster column skip=.1\linewidth] \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/item-noAdd1.yaml}[yaml-TCB]{\texttt{item-noAdd1.yaml}}{lst:item-noAdd1} @@ -22,9 +21,9 @@ latexindent.pl items1.tex -local item-noAdd1.yaml latexindent.pl items1.tex -local item-rules1.yaml \end{commandshell} - the respective outputs are given in \cref{lst:items1-noAdd1,lst:items1-rules1}; note that in - \cref{lst:items1-noAdd1} that the text after each \texttt{item} has not received - any additional indentation, and in \cref{lst:items1-rules1}, the text after each + the respective outputs are given in \cref{lst:items1-noAdd1,lst:items1-rules1}; note that + in \cref{lst:items1-noAdd1} that the text after each \texttt{item} has not received any + additional indentation, and in \cref{lst:items1-rules1}, the text after each \texttt{item} has received a single space of indentation, specified by \cref{lst:item-rules1}. @@ -38,10 +37,10 @@ latexindent.pl items1.tex -local item-rules1.yaml Alternatively, you might like to populate \texttt{noAdditionalIndentGlobal} or \texttt{indentRulesGlobal} using the \texttt{items} key, as demonstrated in - \cref{lst:items-noAdditionalGlobal,lst:items-indentRulesGlobal}. Note that there is a need to `reset/remove' the - \texttt{item} field from \texttt{indentRules} in both cases (see the hierarchy - description given on \cpageref{sec:noadd-indent-rules}) as the \texttt{item} command is a - member of \texttt{indentRules} by default. + \cref{lst:items-noAdditionalGlobal,lst:items-indentRulesGlobal}. Note that there is a + need to `reset/remove' the \texttt{item} field from \texttt{indentRules} in both cases + (see the hierarchy description given on \cpageref{sec:noadd-indent-rules}) as the + \texttt{item} command is a member of \texttt{indentRules} by default. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/items-noAdditionalGlobal.yaml}[yaml-TCB]{\texttt{items-noAdditionalGlobal.yaml}}{lst:items-noAdditionalGlobal} @@ -57,7 +56,7 @@ latexindent.pl items1.tex -local item-rules1.yaml latexindent.pl items1.tex -local items-noAdditionalGlobal.yaml latexindent.pl items1.tex -local items-indentRulesGlobal.yaml \end{commandshell} - the respective outputs from \cref{lst:items1-noAdd1,lst:items1-rules1} are obtained; note, however, that - \emph{all} such \texttt{item} commands without their own individual + the respective outputs from \cref{lst:items1-noAdd1,lst:items1-rules1} are obtained; + note, however, that \emph{all} such \texttt{item} commands without their own individual \texttt{noAdditionalIndent} or \texttt{indentRules} settings would behave as in these listings. diff --git a/support/latexindent/documentation/subsubsec-headings.tex b/support/latexindent/documentation/subsubsec-headings.tex index 3cbe5996ea..de647cde5a 100644 --- a/support/latexindent/documentation/subsubsec-headings.tex +++ b/support/latexindent/documentation/subsubsec-headings.tex @@ -1,8 +1,9 @@ % arara: pdflatex: {shell: yes, files: [latexindent]} \subsubsection{afterHeading code blocks}\label{subsubsec-headings-no-add-indent-rules} Let's use the example \cref{lst:headings2} for demonstration throughout this - \namecref{subsubsec-headings-no-add-indent-rules}. As discussed on \cpageref{lst:headings1}, by default - \texttt{latexindent.pl} will not add indentation after headings. + \namecref{subsubsec-headings-no-add-indent-rules}. As discussed on + \cpageref{lst:headings1}, by default \texttt{latexindent.pl} will not add indentation + after headings. \cmhlistingsfromfile{demonstrations/headings2.tex}{\texttt{headings2.tex}}{lst:headings2} @@ -20,15 +21,15 @@ latexindent.pl headings2.tex -l headings3.yaml \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/headings3.yaml}[yaml-TCB]{\texttt{headings3.yaml}}{lst:headings3yaml} \end{cmhtcbraster} - If we specify \texttt{noAdditionalIndent} as in \cref{lst:headings4yaml} and run the command + If we specify \texttt{noAdditionalIndent} as in \cref{lst:headings4yaml} and run the + command \index{switches!-l demonstration} \begin{commandshell} latexindent.pl headings2.tex -l headings4.yaml \end{commandshell} then we receive the output in \cref{lst:headings2-mod4}. Note that the arguments - \emph{and} the body after the heading of \texttt{paragraph} has received - no additional indentation, because we have specified \texttt{noAdditionalIndent} in scalar - form. + \emph{and} the body after the heading of \texttt{paragraph} has received no additional + indentation, because we have specified \texttt{noAdditionalIndent} in scalar form. \begin{cmhtcbraster}[raster column skip=.1\linewidth] \cmhlistingsfromfile{demonstrations/headings2-mod4.tex}{\texttt{headings2.tex} using \cref{lst:headings4yaml}}{lst:headings2-mod4} @@ -36,10 +37,9 @@ latexindent.pl headings2.tex -l headings4.yaml \end{cmhtcbraster} Similarly, if we specify \texttt{indentRules} as in \cref{lst:headings5yaml} and run - analogous commands to those above, we receive the output in \cref{lst:headings2-mod5}; note - that the \emph{body}, \emph{mandatory argument} and content - \emph{after the heading} of \texttt{paragraph} have \emph{all} received - three tabs worth of indentation. + analogous commands to those above, we receive the output in \cref{lst:headings2-mod5}; + note that the \emph{body}, \emph{mandatory argument} and content \emph{after the heading} + of \texttt{paragraph} have \emph{all} received three tabs worth of indentation. \begin{cmhtcbraster}[raster force size=false, raster column 1/.style={add to width=1cm}, @@ -67,14 +67,15 @@ latexindent.pl headings2.tex -l headings4.yaml \cmhlistingsfromfile[style=yaml-LST]*{demonstrations/headings7.yaml}[yaml-TCB]{\texttt{headings7.yaml}}{lst:headings7yaml} \end{cmhtcbraster} - Finally, let's consider \texttt{noAdditionalIndentGlobal} and \texttt{indentRulesGlobal} shown in - \cref{lst:headings8yaml,lst:headings9yaml} respectively, with respective output in \cref{lst:headings2-mod8,lst:headings2-mod9}. - Note that in \cref{lst:headings8yaml} the \emph{mandatory argument} of \texttt{paragraph} - has received a (default) tab's worth of indentation, while the body after the heading has - received \emph{no additional indentation}. Similarly, in \cref{lst:headings2-mod9}, the - \emph{argument} has received both a (default) tab plus two spaces of indentation - (from the global rule specified in \cref{lst:headings9yaml}), and the remaining body after - \texttt{paragraph} has received just two spaces of indentation. + Finally, let's consider \texttt{noAdditionalIndentGlobal} and \texttt{indentRulesGlobal} + shown in \cref{lst:headings8yaml,lst:headings9yaml} respectively, with respective output + in \cref{lst:headings2-mod8,lst:headings2-mod9}. Note that in \cref{lst:headings8yaml} + the \emph{mandatory argument} of \texttt{paragraph} has received a (default) tab's worth + of indentation, while the body after the heading has received \emph{no additional + indentation}. Similarly, in \cref{lst:headings2-mod9}, the \emph{argument} has received + both a (default) tab plus two spaces of indentation (from the global rule specified in + \cref{lst:headings9yaml}), and the remaining body after \texttt{paragraph} has received + just two spaces of indentation. \begin{cmhtcbraster} \cmhlistingsfromfile{demonstrations/headings2-mod8.tex}{\texttt{headings2.tex} using \cref{lst:headings8yaml}}{lst:headings2-mod8} diff --git a/support/latexindent/documentation/subsubsec-ifelsefi.tex b/support/latexindent/documentation/subsubsec-ifelsefi.tex index 419fc0d53f..5f46af6326 100644 --- a/support/latexindent/documentation/subsubsec-ifelsefi.tex +++ b/support/latexindent/documentation/subsubsec-ifelsefi.tex @@ -1,8 +1,8 @@ % arara: pdflatex: {shell: yes, files: [latexindent]} \subsubsection{ifelsefi code blocks} Let's use the simple example shown in \cref{lst:ifelsefi1}; when \texttt{latexindent.pl} - operates on this file, the output as in \cref{lst:ifelsefi1-default}; note that the body of - each of the \lstinline!\if! statements have been indented, and that the + operates on this file, the output as in \cref{lst:ifelsefi1-default}; note that the body + of each of the \lstinline!\if! statements have been indented, and that the \lstinline!\else! statement has been accounted for correctly. \begin{minipage}{.45\textwidth} @@ -32,9 +32,10 @@ latexindent.pl ifelsefi1.tex -local ifnum-noAdd.yaml latexindent.pl ifelsefi1.tex -l ifnum-indent-rules.yaml \end{commandshell} - we receive the respective output given in \cref{lst:ifelsefi1-output-noAdd,lst:ifelsefi1-output-indent-rules}; note that in - \cref{lst:ifelsefi1-output-noAdd}, the \texttt{ifnum} code block has \emph{not} - received any additional indentation, while in \cref{lst:ifelsefi1-output-indent-rules}, the + we receive the respective output given in + \cref{lst:ifelsefi1-output-noAdd,lst:ifelsefi1-output-indent-rules}; note that in + \cref{lst:ifelsefi1-output-noAdd}, the \texttt{ifnum} code block has \emph{not} received + any additional indentation, while in \cref{lst:ifelsefi1-output-indent-rules}, the \texttt{ifnum} code block has received one tab and two spaces of indentation. \begin{minipage}{.45\textwidth} @@ -62,9 +63,12 @@ latexindent.pl ifelsefi1.tex -l ifnum-indent-rules.yaml latexindent.pl ifelsefi1.tex -local ifelsefi-noAdd-glob.yaml latexindent.pl ifelsefi1.tex -l ifelsefi-indent-rules-global.yaml \end{commandshell} - we receive the outputs in \cref{lst:ifelsefi1-output-noAdd-glob,lst:ifelsefi1-output-indent-rules-global}; notice that in \cref{lst:ifelsefi1-output-noAdd-glob} - neither of the \texttt{ifelsefi} code blocks have received indentation, while in - \cref{lst:ifelsefi1-output-indent-rules-global} both code blocks have received a single space of indentation. + we receive the outputs in + \cref{lst:ifelsefi1-output-noAdd-glob,lst:ifelsefi1-output-indent-rules-global}; notice + that in \cref{lst:ifelsefi1-output-noAdd-glob} neither of the \texttt{ifelsefi} code + blocks have received indentation, while in + \cref{lst:ifelsefi1-output-indent-rules-global} both code blocks have received a single + space of indentation. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile{demonstrations/ifelsefi1-noAdd-glob.tex}{\texttt{ifelsefi1.tex} using \cref{lst:ifelsefi-noAdd-glob}}{lst:ifelsefi1-output-noAdd-glob} @@ -76,9 +80,9 @@ latexindent.pl ifelsefi1.tex -l ifelsefi-indent-rules-global.yaml We can further explore the treatment of \texttt{ifElseFi} code blocks% - \announce{2018-04-27}*{updates to ifElseFi code blocks} in \cref{lst:ifelsefi2}, - and the associated default output given in \cref{lst:ifelsefi2-default}; note, in particular, - that the bodies of each of the `or statements' have been indented. + \announce{2018-04-27}*{updates to ifElseFi code blocks} in \cref{lst:ifelsefi2}, and the associated default output given in + \cref{lst:ifelsefi2-default}; note, in particular, that the bodies of each of the `or + statements' have been indented. \begin{cmhtcbraster}[raster column skip=.1\linewidth] \cmhlistingsfromfile{demonstrations/ifelsefi2.tex}{\texttt{ifelsefi2.tex}}{lst:ifelsefi2} diff --git a/support/latexindent/documentation/subsubsec-no-add-remaining-code-blocks.tex b/support/latexindent/documentation/subsubsec-no-add-remaining-code-blocks.tex index f72ac43d39..a6be17e6fa 100644 --- a/support/latexindent/documentation/subsubsec-no-add-remaining-code-blocks.tex +++ b/support/latexindent/documentation/subsubsec-no-add-remaining-code-blocks.tex @@ -1,9 +1,9 @@ % arara: pdflatex: {shell: yes, files: [latexindent]} \subsubsection{The remaining code blocks} Referencing the different types of code blocks in \vref{tab:code-blocks}, we have a few - code blocks yet to cover; these are very similar to the \texttt{commands} code block - type covered comprehensively in \vref{subsubsec:commands-arguments}, but a small discussion defining - these remaining code blocks is necessary. + code blocks yet to cover; these are very similar to the \texttt{commands} code block type + covered comprehensively in \vref{subsubsec:commands-arguments}, but a small discussion + defining these remaining code blocks is necessary. \paragraph{keyEqualsValuesBracesBrackets} \texttt{latexindent.pl} defines this type of code block by the following criteria: @@ -15,8 +15,9 @@ \item then at least one set of curly braces or square brackets (comments and line breaks allowed throughout). \end{itemize} - See the \texttt{keyEqualsValuesBracesBrackets: follow} and \texttt{keyEqualsValuesBracesBrackets: name} fields of the fine tuning - section in \vref{lst:fineTuning}% + See the \texttt{keyEqualsValuesBracesBrackets: follow} and + \texttt{keyEqualsValuesBracesBrackets: name} fields of the fine tuning section in + \vref{lst:fineTuning}% \announce{2019-07-13}{fine tuning: keyEqualsValuesBracesBrackets} An example is shown in \cref{lst:pgfkeysbefore}, with the default output given in @@ -30,29 +31,31 @@ \cmhlistingsfromfile[showtabs=true]{demonstrations/pgfkeys1-default.tex}{\texttt{pgfkeys1.tex} default output}{lst:pgfkeys1:default} \end{minipage}% - In \cref{lst:pgfkeys1:default}, note that the maximum indentation is three tabs, and these - come from: + In \cref{lst:pgfkeys1:default}, note that the maximum indentation is three tabs, and + these come from: \begin{itemize} \item the \lstinline!\pgfkeys! command's mandatory argument; \item the \lstinline!start coordinate/.initial! key's mandatory argument; - \item the \lstinline!start coordinate/.initial! key's body, which is defined as any lines following the name - of the key that include its arguments. This is the part controlled by the - \emph{body} field for \texttt{noAdditionalIndent} and friends from + \item the \lstinline!start coordinate/.initial! key's body, which is defined as any lines + following the name of the key that include its arguments. This is the part controlled by + the \emph{body} field for \texttt{noAdditionalIndent} and friends from \cpageref{sec:noadd-indent-rules}. \end{itemize} \paragraph{namedGroupingBracesBrackets} This type of code block is mostly motivated by tikz-based code; we define this code block as follows: \begin{itemize} - \item it must immediately follow either \emph{horizontal space} OR \emph{one or more line breaks} OR + \item it must immediately follow either \emph{horizontal space} OR \emph{one or more line + breaks} OR \lstinline!{! OR \lstinline![! OR \lstinline!$! OR \lstinline!)! OR \lstinline!(! \item the name may contain the characters detailed in \vref{tab:code-blocks}; \item then at least one set of curly braces or square brackets (comments and line breaks allowed throughout). \end{itemize} - See the \texttt{NamedGroupingBracesBrackets: follow} and \texttt{NamedGroupingBracesBrackets: name} fields of the fine tuning - section in \vref{lst:fineTuning}% + See the \texttt{NamedGroupingBracesBrackets: follow} and + \texttt{NamedGroupingBracesBrackets: name} fields of the fine tuning section in + \vref{lst:fineTuning}% \announce{2019-07-13}{fine tuning: namedGroupingBracesBrackets} A simple example is given in \cref{lst:child1}, with default output in @@ -66,21 +69,21 @@ \cmhlistingsfromfile[showtabs=true]{demonstrations/child1-default.tex}{\texttt{child1.tex} default output}{lst:child1:default} \end{minipage}% - In particular, \texttt{latexindent.pl} considers \texttt{child}, - \texttt{parent} and \texttt{node} all to be - \texttt{namedGroupingBracesBrackets}\footnote{ - You may like to verify this by using the \texttt{-tt} option and checking \texttt{indent.log}! }. Referencing \cref{lst:child1:default}, note - that the maximum indentation is two tabs, and these come from: + In particular, \texttt{latexindent.pl} considers \texttt{child}, \texttt{parent} and + \texttt{node} all to be \texttt{namedGroupingBracesBrackets}\footnote{ You may like to + verify this by using the \texttt{-tt} option and checking \texttt{indent.log}! }. + Referencing \cref{lst:child1:default}, note that the maximum indentation is two tabs, and + these come from: \begin{itemize} \item the \lstinline!child!'s mandatory argument; - \item the \lstinline!child!'s body, which is defined as any lines following the name of - the \texttt{namedGroupingBracesBrackets} that include its arguments. This is the part controlled by the - \emph{body} field for \texttt{noAdditionalIndent} and friends from + \item the \lstinline!child!'s body, which is defined as any lines following the name of the + \texttt{namedGroupingBracesBrackets} that include its arguments. This is the part + controlled by the \emph{body} field for \texttt{noAdditionalIndent} and friends from \cpageref{sec:noadd-indent-rules}. \end{itemize} - \paragraph{UnNamedGroupingBracesBrackets} occur in a variety of situations; specifically, we define - this type of code block as satisfying the following criteria: + \paragraph{UnNamedGroupingBracesBrackets} occur in a variety of situations; specifically, + we define this type of code block as satisfying the following criteria: \begin{itemize} \item it must immediately follow either \lstinline!{! OR \lstinline![! OR \lstinline!,! OR \lstinline!&! OR \lstinline!)! OR @@ -88,7 +91,8 @@ \item then at least one set of curly braces or square brackets (comments and line breaks allowed throughout). \end{itemize} - See the \texttt{UnNamedGroupingBracesBrackets: follow} field of the fine tuning section in \vref{lst:fineTuning}% + See the \texttt{UnNamedGroupingBracesBrackets: follow} field of the fine tuning section + in \vref{lst:fineTuning}% \announce{2019-07-13}{fine tuning: namedGroupingBracesBrackets} An example is shown in \cref{lst:psforeach1} with default output give in @@ -102,20 +106,18 @@ \cmhlistingsfromfile[showtabs=true]{demonstrations/psforeach1-default.tex}{\texttt{psforeach1.tex} default output}{lst:psforeach:default} \end{minipage}% - Referencing \cref{lst:psforeach:default}, there are \emph{three} sets of unnamed - braces. Note also that the maximum value of indentation is three tabs, and these come - from: + Referencing \cref{lst:psforeach:default}, there are \emph{three} sets of unnamed braces. + Note also that the maximum value of indentation is three tabs, and these come from: \begin{itemize} \item the \lstinline!\psforeach! command's mandatory argument; \item the \emph{first} un-named braces mandatory argument; - \item the \emph{first} un-named braces \emph{body}, which we define as any - lines following the first opening \lstinline!{! or \lstinline![! that - defined the code block. This is the part controlled by the \emph{body} field - for \texttt{noAdditionalIndent} and friends from \cpageref{sec:noadd-indent-rules}. + \item the \emph{first} un-named braces \emph{body}, which we define as any lines following the + first opening \lstinline!{! or \lstinline![! that defined the code block. This is the + part controlled by the \emph{body} field for \texttt{noAdditionalIndent} and friends from + \cpageref{sec:noadd-indent-rules}. \end{itemize} - Users wishing to customise the mandatory and/or optional arguments on a - \emph{per-name} basis for the \texttt{UnNamedGroupingBracesBrackets} should use - \texttt{always-un-named}. + Users wishing to customise the mandatory and/or optional arguments on a \emph{per-name} + basis for the \texttt{UnNamedGroupingBracesBrackets} should use \texttt{always-un-named}. \paragraph{filecontents} code blocks behave just as \texttt{environments}, except that neither arguments nor items are sought. diff --git a/support/latexindent/documentation/subsubsec-special.tex b/support/latexindent/documentation/subsubsec-special.tex index 7a97446165..410d3c3109 100644 --- a/support/latexindent/documentation/subsubsec-special.tex +++ b/support/latexindent/documentation/subsubsec-special.tex @@ -24,10 +24,11 @@ latexindent.pl special1.tex -local displayMath-noAdd.yaml latexindent.pl special1.tex -l displayMath-indent-rules.yaml \end{commandshell} - we receive the respective output given in \cref{lst:special1-output-noAdd,lst:special1-output-indent-rules}; note that in + we receive the respective output given in + \cref{lst:special1-output-noAdd,lst:special1-output-indent-rules}; note that in \cref{lst:special1-output-noAdd}, the \texttt{displayMath} code block has \emph{not} - received any additional indentation, while in \cref{lst:special1-output-indent-rules}, the - \texttt{displayMath} code block has received three tabs worth of indentation. + received any additional indentation, while in \cref{lst:special1-output-indent-rules}, + the \texttt{displayMath} code block has received three tabs worth of indentation. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile{demonstrations/special1-noAdd.tex}{\texttt{special1.tex} using \cref{lst:displayMath-noAdd}}{lst:special1-output-noAdd} @@ -54,9 +55,11 @@ latexindent.pl special1.tex -l displayMath-indent-rules.yaml latexindent.pl special1.tex -local special-noAdd-glob.yaml latexindent.pl special1.tex -l special-indent-rules-global.yaml \end{commandshell} - we receive the outputs in \cref{lst:special1-output-noAdd-glob,lst:special1-output-indent-rules-global}; notice that in \cref{lst:special1-output-noAdd-glob} - neither of the \texttt{special} code blocks have received indentation, while in - \cref{lst:special1-output-indent-rules-global} both code blocks have received a single space of indentation. + we receive the outputs in + \cref{lst:special1-output-noAdd-glob,lst:special1-output-indent-rules-global}; notice + that in \cref{lst:special1-output-noAdd-glob} neither of the \texttt{special} code blocks + have received indentation, while in \cref{lst:special1-output-indent-rules-global} both + code blocks have received a single space of indentation. \begin{minipage}{.45\textwidth} \cmhlistingsfromfile{demonstrations/special1-noAdd-glob.tex}{\texttt{special1.tex} using \cref{lst:special-noAdd-glob}}{lst:special1-output-noAdd-glob} diff --git a/support/latexindent/documentation/title.tex b/support/latexindent/documentation/title.tex index fcbb6f6324..39b50dc044 100644 --- a/support/latexindent/documentation/title.tex +++ b/support/latexindent/documentation/title.tex @@ -8,14 +8,14 @@ sharp corners, enhanced, overlay={\node[anchor=north east,outer sep=2pt] at ([xshift=3cm,yshift=4mm]frame.north east) {\includegraphics[width=3cm]{logo}}; }] - \centering\ttfamily\bfseries latexindent.pl\\[1cm] Version 3.10.1 + \centering\ttfamily\bfseries latexindent.pl\\[1cm] Version 3.11 \end{tcolorbox} } \author{Chris Hughes \thanks{and contributors! See \vref{sec:contributors}. For all communication, please visit \cite{latexindent-home}.}} -\date{2021-07-23} +\date{2021-07-31} \maketitle \begin{adjustwidth}{1cm}{1cm} \small diff --git a/support/latexindent/latexindent.pl b/support/latexindent/latexindent.pl index 7813b3a657..696fb2b7b8 100755 --- a/support/latexindent/latexindent.pl +++ b/support/latexindent/latexindent.pl @@ -1,5 +1,5 @@ #!/usr/bin/env perl -# latexindent.pl, version 3.10.1, 2021-07-23 +# latexindent.pl, version 3.11, 2021-07-31 # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by diff --git a/systems/win32/miktex/tm/packages/next/pr.ini b/systems/win32/miktex/tm/packages/next/pr.ini index a11c759474..63c883faaa 100644 --- a/systems/win32/miktex/tm/packages/next/pr.ini +++ b/systems/win32/miktex/tm/packages/next/pr.ini @@ -1,13 +1,13 @@ [repository] -date=1627676142 +date=1627762463 lastupd=miktex-arctrl-bin-2.9 miktex-arctrl-bin-x64-2.9 miktex-asymptote-bin-2.9 miktex-asymptote-bin-x64-2.9 miktex-autosp-bin-2.9 miktex-autosp-bin-x64-2.9 miktex-axohelp-bin-2.9 miktex-axohelp-bin-x64-2.9 miktex-bibarts-bin-2.9 miktex-bibarts-bin-x64-2.9 miktex-bibtex-bin-2.9 miktex-bibtex-bin-x64-2.9 miktex-bibtex8bit-bin-2.9 miktex-bibtex8bit-bin-x64-2.9 miktex-bzip2-bin-2.9 miktex-bzip2-bin-x64-2.9 miktex-cairo-bin-2.9 miktex-cairo-bin-x64-2.9 miktex-chktex-bin-2.9 miktex-chktex-bin-x64-2.9 -lstdigest=7b2f50385c5ab5742b2f9a7a41c7c9de +lstdigest=765ddc6669ade90d96c6e69f3a8f9e38 numpkg=4598 relstate=next -version=7881 +version=7882 ;;;;This configuration file is signed by a MiKTeX maintainer. The signature follows. ;;;;-----BEGIN MIKTEX SIGNATURE----- -;;;; signature/miktex: ikTeFmNP+BQiFeKjBiTNlxfpAEhfof1NLfi0XryR9uU4eWxsyiBPGgoLsa0qbF1a/rStVNrNn5rBJDgAYHijTKd5H7POJyWOVGFMon8JlFQmzoT2M9FCYxpW8cR6szwksSsyAARyIK/iCYWPzoqVvhIH+rViJPaHD5F9x9EdT/0zGqfbGv1fmVe6z5p+169lEmCicWFIPkMlmMF7+eRzNk72jy/y7IE5fQC2pTZP8TkS0C5Hfkyq0uzb9B7DLhiMLxixkAFfvLGp6UmEB3PqUJhMr60FnnHDDhBcYMKzm7NFUscOP0ER4V4OO+lxdDr3s2SZB0TVRqKpH7AnwXISjw== +;;;; signature/miktex: RnNSn8+I9safHRUnxsafwvAyKPiusmoV/SD0F32Gmpbc/mQSseLomcr75UoTYCzN87s5DmPUSCTh1xRCboeufIQFiBtbx7CdCumq6wZBWtnJZCxuEhVQ5OTyXYg8hhrsR1ZvU7F7m71DXWmfbOvLDsvUcolkUDsWUZJtiRkTHmZr8jpBn7kxWYwdpnyxbopKReZsGOOvKmvpgTeKfL2LGCGj+2mIVaj61DEctbUt6mA2RYSm2EAYXwmWJj2raLiCMO2LIyBCAx0EEjHpBTU7Q1m86ZXwD8iCYzid5e/SVfNu1l7INt9u6J3rRT+V9JmuRyoKjhlpfyMN586V3QJNJg== ;;;;-----END MIKTEX SIGNATURE----- diff --git a/systems/win32/miktex/tm/packages/pr.ini b/systems/win32/miktex/tm/packages/pr.ini index 9fb2a79fc1..84cd04e788 100644 --- a/systems/win32/miktex/tm/packages/pr.ini +++ b/systems/win32/miktex/tm/packages/pr.ini @@ -1,13 +1,13 @@ [repository] -date=1627675880 +date=1627762271 lastupd=jlreq jlreq__doc media9 media9__doc spbmark spbmark__doc spbmark__source tikztosvg tikztosvg__doc tikztosvg__source lacheck__doc lacheck__source lipsum lipsum__doc lipsum__source logix logix__doc logix__source moderncv moderncv__doc -lstdigest=16cc66b8cdca7cdefef9e9618a7e9ca6 +lstdigest=82bc47cec90dfb9071b184b48f70b951 numpkg=4598 relstate=stable -version=7881 +version=7882 ;;;;This configuration file is signed by a MiKTeX maintainer. The signature follows. ;;;;-----BEGIN MIKTEX SIGNATURE----- -;;;; signature/miktex: m/MEu47WPV3wASh3zduQd0I5H42s5w4sUuPPLFOwBplwQJfK0cvilCYKAA6dq0rQ/g7phVHClP3LoiUs2BqejVp9Su6A7o9auuke2XkKwB5xoVm9FYOBKTh9ZeMUfZ4KTwbUd7UlZXnYCL2jWJQ74pS9GO7fTvTnaTBlwPcKocE5g6/ki/WAEC5z20PgnCV3II4KxOGEHLI4JMPFQNkJ5Oqzp3LNv2SLwJXrUV4hHcochWqfR1cggPiAGA2k6aFcvCVsdkWneIIpY8d848yw6pQC9+SHN06X6EDg5W9SCtMYljzngC8s4zEP5fFsVTQ84lUPzhQgVHWoa8FeTlfEUA== +;;;; signature/miktex: nWxB7nztAg9RZ9/tJKCASA4U/zkHtNvigx/yFAljQW7bsl/3ODIfMrOgzE3hj3X8kZ2ZnlL5RbjRLYx8rb1smDWP3QTZ2fylzZzzpf5TkDmS7Hs6RQUMBm8DuRt8dW6NRHPxmIjirex54oDqDvZqCcupbFLvMUSdYf40XAjRMnrfMfYVRNTW0JmdktQMPr1i4vVOrzCdYkEmlZTj/zuJlFWxV3IOK6yrv/L78YXa/U9yJFNkpHHIyDg4LTthpgVvoP5CTT2ShwZkNDKrdzbu04oVPY6jcGNj4hzDhBebKdje9Dopbh8BrsfX+EgX9JsR7tW09znwcg8N8MCUxIAzTA== ;;;;-----END MIKTEX SIGNATURE----- diff --git a/timestamp b/timestamp index baeaa5a416..bb9d332823 100644 --- a/timestamp +++ b/timestamp @@ -2,4 +2,4 @@ # The source CTAN of this site's material: dante.ctan.org # The year-month-day-hour-minute of this site's material: -2021-07-31-02-02 +2021-08-01-02-02 -- cgit v1.2.3