diff options
author | Karl Berry <karl@freefriends.org> | 2015-04-19 22:41:13 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2015-04-19 22:41:13 +0000 |
commit | 23cf0b808a389f0ca7db875f3b036de281ea26c7 (patch) | |
tree | bf8ad7535dd93ec90fb2c79a677209319436e0d4 /Master/texmf-dist/doc/support/latexindent | |
parent | 6c6ef8b97a77c8d79c7110b87fd8afd43d676cb1 (diff) |
latexindent (19apr15)
git-svn-id: svn://tug.org/texlive/trunk@36955 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/support/latexindent')
-rw-r--r-- | Master/texmf-dist/doc/support/latexindent/documentation/manual.pdf | bin | 236102 -> 237320 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/support/latexindent/documentation/manual.tex | 31 | ||||
-rw-r--r-- | Master/texmf-dist/doc/support/latexindent/success/figureValign.tex | 124 |
3 files changed, 146 insertions, 9 deletions
diff --git a/Master/texmf-dist/doc/support/latexindent/documentation/manual.pdf b/Master/texmf-dist/doc/support/latexindent/documentation/manual.pdf Binary files differindex c804d386db6..0fec7c336b1 100644 --- a/Master/texmf-dist/doc/support/latexindent/documentation/manual.pdf +++ b/Master/texmf-dist/doc/support/latexindent/documentation/manual.pdf diff --git a/Master/texmf-dist/doc/support/latexindent/documentation/manual.tex b/Master/texmf-dist/doc/support/latexindent/documentation/manual.tex index 812aae39eb8..a34339c06cd 100644 --- a/Master/texmf-dist/doc/support/latexindent/documentation/manual.tex +++ b/Master/texmf-dist/doc/support/latexindent/documentation/manual.tex @@ -2,6 +2,7 @@ % !arara: bibtex % !arara: pdflatex % !arara: pdflatex +% !arara: pdflatex % !arara: indent: {overwrite: no, trace: yes, localSettings: yes, silent: yes} % http://tex.stackexchange.com/questions/122135/how-to-add-a-png-icon-on-the-right-side-of-a-tcolorbox-title \begin{filecontents}{mybib.bib} @@ -163,7 +164,7 @@ top=2cm,bottom=1.5cm]{geometry} % page setup % \begin{noindent} \title{\lstinline[basicstyle=\huge\ttfamily]!latexindent.pl!\\[1cm] - Version 2.0R} + Version 2.1R} % \end{noindent} \author{Chris Hughes \footnote{smr01cmh AT users.sourceforge.net}} \maketitle @@ -394,8 +395,8 @@ on which of the following options are used. Only \lstinline!defaultSettings.yaml!: you might like to read \cref{sec:defuseloc} before using this switch. By default, \lstinline!latexindent.pl! will always search for - \lstinline!indentconfig.yaml! in your home directory. If you would prefer it not to do so - then (instead of deleting or renaming \lstinline!indentconfig.yaml!) you can simply + \lstinline!indentconfig.yaml! or \lstinline!.indentconfig.yaml! in your home directory. If you would prefer it not to do so + then (instead of deleting or renaming \lstinline!indentconfig.yaml!/\lstinline!.indentconfig.yaml!) you can simply call the script with the \lstinline!-d! switch; note that this will also tell the script to ignore \lstinline!localSettings.yaml! even if it has been called with the \lstinline!-l! switch. @@ -561,8 +562,8 @@ copy myfile.bak4 to myfile.bak3 which creates `trailing whitespace' feared by most version control systems. If this option is set to \lstinline!1!, trailing whitespace is removed from all lines, also non-empty ones. In general this should not create any problems, but - by precaution this option is turned off by default. \footnote{Thanks to \href{https://github.com/vosskuhle}{vosskuhle} for - providing this feature.} + by precaution this option is turned off by default. Thanks to \href{https://github.com/vosskuhle}{vosskuhle} for + providing this feature. \item[\verbitem{lookForAlignDelims}] This is the first example of a field in \lstinline!defaultSettings.yaml! that has more than one line; \cref{lst:aligndelims} @@ -906,18 +907,25 @@ following order: \item \lstinline!noAdditionalIndent! \item \lstinline!indentRules! \end{enumerate} -\subsection{\lstinline!indentconfig.yaml! (for user settings)}\label{sec:indentconfig} +\subsection{\lstinline!indentconfig.yaml! and \lstinline!.indentconfig.yaml! (for user settings)}\label{sec:indentconfig} Editing \lstinline!defaultSettings.yaml! is not ideal as it may be overwritten when updating your distribution--a better way to customize the settings to your liking is to set up your own settings file, \lstinline!mysettings.yaml! (or any name you like, provided it ends with \lstinline!.yaml!). The only thing you have to do is tell \lstinline!latexindent.pl! where to find it. -\lstinline!latexindent.pl! will always check your home directory for \lstinline!indentconfig.yaml! (unless +\lstinline!latexindent.pl! will always check your home directory for \lstinline!indentconfig.yaml! +and \lstinline!.indentconfig.yaml! (unless it is called with the \lstinline!-d! switch), which is a plain text file you can create that contains the \emph{absolute} -paths for any settings files that you wish \lstinline!latexindent.pl! to load. -Note that Mac and Linux users home directory is \lstinline!~/username! while +paths for any settings files that you wish \lstinline!latexindent.pl! to load. There is no difference +between \lstinline!indentconfig.yaml! and \lstinline!.indentconfig.yaml!, other than the +fact that \lstinline!.indentconfig.yaml! is a `hidden' file; thank you to \href{https://github.com/cmhughes/latexindent.pl/pull/23}{Jacobo Diaz} +for providing this feature. In what follows, we will use \lstinline!indentconfig.yaml!, but it +is understood that this equally represents \lstinline!.indentconfig.yaml! as well. If you +have both files in existence, \lstinline!indentconfig.yaml! takes priority. + +For Mac and Linux users, their home directory is \lstinline!~/username! while Windows (Vista onwards) is \lstinline!C:\Users\username! \footnote{If you're not sure where to put \lstinline!indentconfig.yaml!, don't worry \lstinline!latexindent.pl! will tell you in the log file exactly where to @@ -1162,6 +1170,11 @@ sudo perl -MCPAN -e 'install "File::HomeDir"' Strawberry Perl users on Windows might use \lstinline!CPAN client!. All of the modules are readily available on CPAN \cite{cpan}. +As of Version 2.1R, \lstinline!indent.log! will contain details of the location +of the Perl modules on your system. \lstinline!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 \lstinline!trace! option, e.g \lstinline!latexindent.exe -t myfile.tex!. + \section{The \lstinline!arara! rule} The \lstinline!arara! rule (\lstinline!indent.yaml!) contains lines such as those given in \cref{lst:arararule}. With this setup, the user \emph{always} has diff --git a/Master/texmf-dist/doc/support/latexindent/success/figureValign.tex b/Master/texmf-dist/doc/support/latexindent/success/figureValign.tex new file mode 100644 index 00000000000..8c2bc33281a --- /dev/null +++ b/Master/texmf-dist/doc/support/latexindent/success/figureValign.tex @@ -0,0 +1,124 @@ +% arara: pdflatex +% !arara: indent: {overwrite: yes} +\documentclass{article} +\usepackage{lipsum} +\usepackage{graphicx} +\usepackage{environ} +\usepackage[showframe=true]{geometry} + +\newsavebox{\vabox} + +\NewEnviron{verticallyaligned}{% + % temporarily set \vamaxheight to nothing during the measurements + \let\vamaxheight\relax + % measure the height of the body + \begin{lrbox}{\vabox} + \BODY% + \end{lrbox}% + % set the height of the minipage box + \newlength{\vamaxheight} + \setlength{\vamaxheight}{\ht\vabox} + % output the body, which now contains the new height :) + \noindent\makebox[\linewidth][c]{\mbox{}\hfill\BODY\hfill\mbox{}}% +} + +\begin{document} + +\sbox{\vabox}{% + \begin{minipage}[b][][b]{.10\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image-a} + \end{minipage}% + \begin{minipage}[b][][t]{.15\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image-b} + \end{minipage}% + \begin{minipage}[b][][t]{.20\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image-c} + \end{minipage}% + \begin{minipage}[b][][c]{.10\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image} + \end{minipage}% + \begin{minipage}[b][][t]{.20\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image} + \end{minipage}% +}% + +\noindent +\begin{minipage}[b][\ht\vabox][b]{.10\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image-a} +\end{minipage}% +\hfill +\begin{minipage}[b][\ht\vabox][t]{.15\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image-b} +\end{minipage}% +\hfill +\begin{minipage}[b][\ht\vabox][t]{.20\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image-c} +\end{minipage}% +\hfill +\begin{minipage}[b][\ht\vabox][c]{.10\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image} +\end{minipage}% +\hfill +\begin{minipage}[b][\ht\vabox][t]{.20\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image} +\end{minipage}% +\par\lipsum + + +\begin{verticallyaligned} + \noindent\begin{minipage}[b][\vamaxheight][b]{.30\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image-a} + \end{minipage}% + \hfill + \begin{minipage}[b][\vamaxheight][t]{.10\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image-b} + \end{minipage}% + \hfill + \begin{minipage}[b][\vamaxheight][t]{.20\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image-c} + \end{minipage}% + \hfill + \begin{minipage}[b][\vamaxheight][c]{.20\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image} + \end{minipage}% + \hfill + \begin{minipage}[b][\vamaxheight][t]{.20\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image} + \end{minipage}% +\end{verticallyaligned} + +\lipsum[1] + +\begin{figure} + \begin{verticallyaligned} + \noindent\begin{minipage}[b][\vamaxheight][c]{.50\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image} + \caption{} + \end{minipage}% + \hfill + \begin{minipage}[b][\vamaxheight][t]{.40\textwidth} + \centering + \includegraphics[width=\textwidth]{example-image} + \caption{} + \end{minipage}% + \end{verticallyaligned} + \caption{} +\end{figure} + +\end{document} |