title: Trying to make sense of TeX decisions (stretching, tolerance)

text: For example, if I don't set stretch parameters (tolerance, badness, emergencystretch, sloppy, etc) I get some overfull boxes (full LaTeX code post at the end). ![enter image description here](http://i.stack.imgur.com/wklUo.jpg) Notice that TeX seems unwilling to hyphenate "dificultades", in spite of knowing perfectly how to do it (as shown in the last paragraph). It works well if I explicitly suggest the hypen (5th paragraph). Why? Things get a little better tweaking the stretch parameters (eg, using `\sloppy`), but it still is reluctant to hyphenate that word. And if I try `\tolerance=10000` I get something quite ridiculous: ![enter image description here](http://i.stack.imgur.com/SsG8o.jpg) I cannot make sense of the layout of the first paragraphs - nor of the drastic change that happens in the third, just by adding a dot. Now, that's certainly not a hyphenation thing. I know, that `\tolerance=10000` is not advisable in general, but I understand that it basically means: "use as much blank space (glue) as you want, even if it looks bad, don't overfull never"; but surely there are lots of many more reasonable layouts than that. Is there a simple explanation of why TeX uses this "strategy"?               \documentclass[a4paper, 11pt]{book}     \usepackage[spanish]{babel}     \usepackage[paperwidth=140mm, paperheight=210mm, top=21mm, left=14mm, right=10mm,textheight=173mm]{geometry}     %\tolerance=10000          \begin{document}     \begin{quotation}      Hola, llego desde muy lejos ---con grandes dificultades--- y le ruego quiera escucharme.          Hola,... llego desde muy lejos ---con grandes dificultades--- y le ruego  quiera escucharme.          Hola,...... llego desde muy lejos ---con grandes dificultades--- y le ruego quiera  escucharme.          Hola,....... llego desde muy lejos ---con grandes dificultades--- y le ruego quiera  escucharme.          Hola, llego desde muy lejos ---con grandes dificulta\-des--- y le ruego quiera escucharme.          dificultades dificultades dificultades dificultades       dificultades ... dificultades dificultades dificultades       dificultades dificultades .. dificultades dificultades       dificultades dificultades...... dificultades dificultades      dificultades dificultades dificultades dificultades      \end{quotation}      \end{document}


title: epstopdf outdir challenges

text: I'm currently working on setting up the appendices for a dissertation project, which are going to contain +100 figures from several individual parametric studies. The majority of the figures have are included as EPS-files hence the challenge relates to conversion of the many eps-files having. Note, the files have the same names across the subsets of the parametric studies. Therefore when having specified the epstopdf-outdir in the preamble** and consequently converting the picture files with epstopdf the files overwrite in some instances and others they don't so the result is a mess. Using `renewcommand` appears inapplicable when trying to specify a subdirectory in the document body to the initially specified conversion- folder. Any suggestions will be very appreciated. ** Suggested work-around to deal with error of converted files not found (Converted EPS not found with TeX Live 2012 and Windows 8). MWE:               \documentclass[]{report}     \usepackage[english]{babel}           \usepackage{blindtext}          \usepackage{graphicx}     \usepackage{epstopdf}     \epstopdfsetup{outdir=./figures/epstopdf_converted/}          \begin{document}     \chapter{Main report}     \blindtext\blindtext\blindtext\blindtext\blindtext          \appendix     \chapter{Parametric study}     \clearpage          \renewcommand{\epstopdfsetup}{outdir=./figures/epstopdf_converted/par_stud-A/}      \section{Subset A}     \begin{figure}[H]     \centering     \includegraphics[scale=0.45]{figures/par_stud-A/example.eps}     \caption{Parametric study - subset A.}     \label{fig:A-example}     \end{figure}     \clearpage          \renewcommand{\epstopdfsetup}{outdir=./figures/epstopdf_converted/par_stud-B/}     \section{Subset B}     \begin{figure}[H]     \centering     \includegraphics[scale=0.45]{figures/par_stud-B/example.eps}     \caption{Parametric study - subset B.}     \label{fig:B-example}     \end{figure}     \end{document}      Folder structure and examples of eps files can be obtained here: https://www.dropbox.com/s/fi3hwr93ylbpruo/epstopdf_outdir_example.zip


title: hyperref: can I control how to display the PDF?

text: I use the method described in this link for getting hyperlinks from different PDF files: Can you have hyperlinks to locations in different PDFs? I would like to remain with two open PDF files, source and destination. When I use the described method, the source PDF is replaced by the target PDF. Can I control how to display the PDF files?


In different place the distance between items under enumerate or itemize option. Please suggest to set them uniformly as all things in 1.5 line space as my draft.


title: Basic minted example prints out latex code, not source code

text: I have this very basic .tex file:               \documentclass{book}     \usepackage{vendor/minted}     \begin{document}          \title{My Book}     \author{Jonathan Lipps}     \maketitle          \begin{minted}{python}     def boring(args = None):         pass     \end{minted}          \end{document}      (vendor/minted is the version of minted.sty I just downloaded from the GitHub page) Rather than producing the expected output, I get a PDF with some very nicely highlighted latex gibberish, which appears to my eyes to be the latex code that should generate the python source display, not what should actually be displayed itself:               \makeatletter     \def\PY@reset{\let\PY@it=\relax \let\PY@bf=\relax%         \let\PY@ul=\relax \let\PY@tc=\relax%     \let\PY@bc=\relax \let\PY@ff=\relax} \def\PY@tok#1{\csname PY@tok@#1\endcsname} \def\PY@toks#1+{\ifx\relax#1\empty\else%     \PY@tok{#1}\expandafter\PY@toks\fi} \def\PY@do#1{\PY@bc{\PY@tc{\PY@ul{%     \PY@it{\PY@bf{\PY@ff{#1}}}}}}} \def\PY#1#2{\PY@reset\PY@toks#1+\relax+\PY@do{#2}}     \expandafter\def\csname PY@tok@gd\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.63,0.00,0.0 \expandafter\def\csname PY@tok@gu\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@gt\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.00,0.27,0.8 \expandafter\def\csname PY@tok@gs\endcsname{\let\PY@bf=\textbf}     \expandafter\def\csname PY@tok@gr\endcsname{\def\PY@tc##1{\textcolor[rgb]{1.00,0.00,0.0 \expandafter\def\csname PY@tok@cm\endcsname{\let\PY@it=\textit\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@vg\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.10,0.09,0.4 \expandafter\def\csname PY@tok@m\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.40,0.40,0.40 \expandafter\def\csname PY@tok@mh\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.40,0.40,0.4 \expandafter\def\csname PY@tok@go\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.53,0.53,0.5 \expandafter\def\csname PY@tok@ge\endcsname{\let\PY@it=\textit}     \expandafter\def\csname PY@tok@vc\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.10,0.09,0.4 \expandafter\def\csname PY@tok@il\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.40,0.40,0.4 \expandafter\def\csname PY@tok@cs\endcsname{\let\PY@it=\textit\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@cp\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.74,0.48,0.0 \expandafter\def\csname PY@tok@gi\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.00,0.63,0.0 \expandafter\def\csname PY@tok@gh\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@ni\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@nl\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.63,0.63,0.0 \expandafter\def\csname PY@tok@nn\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@no\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.53,0.00,0.0 \expandafter\def\csname PY@tok@na\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.49,0.56,0.1 \expandafter\def\csname PY@tok@nb\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.00,0.50,0.0 \expandafter\def\csname PY@tok@nc\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@nd\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.67,0.13,1.0 \expandafter\def\csname PY@tok@ne\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@nf\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.00,0.00,1.0 \expandafter\def\csname PY@tok@si\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@s2\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.73,0.13,0.1 \expandafter\def\csname PY@tok@vi\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.10,0.09,0.4 \expandafter\def\csname PY@tok@nt\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[ \expandafter\def\csname PY@tok@nv\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.10,0.09,0.4 \expandafter\def\csname PY@tok@s1\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.73,0.13,0.1 \expandafter\def\csname PY@tok@sh\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.73,0.13,0.1 \expandafter\def\csname PY@tok@sc\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.73,0.13,0.1     \expandafter\def\csname PY@tok@sx\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}} \expandafter\def\csname PY@tok@bp\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}} \expandafter\def\csname PY@tok@c1\endcsname{\let\PY@it=\textit\def\PY@tc##1{\textcolor[rgb]{0.25, \expandafter\def\csname PY@tok@kc\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[rgb]{0.00, \expandafter\def\csname PY@tok@c\endcsname{\let\PY@it=\textit\def\PY@tc##1{\textcolor[rgb]{0.25,0 \expandafter\def\csname PY@tok@mf\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}} \expandafter\def\csname PY@tok@err\endcsname{\def\PY@bc##1{\setlength{\fboxsep}{0pt}\fcolorbox[rg \expandafter\def\csname PY@tok@kd\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[rgb]{0.00, \expandafter\def\csname PY@tok@ss\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.10,0.09,0.49}{##1}}} \expandafter\def\csname PY@tok@sr\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.73,0.40,0.53}{##1}}} \expandafter\def\csname PY@tok@mo\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}} \expandafter\def\csname PY@tok@kn\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[rgb]{0.00, \expandafter\def\csname PY@tok@mi\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}} \expandafter\def\csname PY@tok@gp\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[rgb]{0.00, \expandafter\def\csname PY@tok@o\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}} \expandafter\def\csname PY@tok@kr\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[rgb]{0.00, \expandafter\def\csname PY@tok@s\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}} \expandafter\def\csname PY@tok@kp\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.00,0.50,0.00}{##1}}} \expandafter\def\csname PY@tok@w\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.73,0.73,0.73}{##1}}} \expandafter\def\csname PY@tok@kt\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.69,0.00,0.25}{##1}}} \expandafter\def\csname PY@tok@ow\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[rgb]{0.67, \expandafter\def\csname PY@tok@sb\endcsname{\def\PY@tc##1{\textcolor[rgb]{0.73,0.13,0.13}{##1}}} \expandafter\def\csname PY@tok@k\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[rgb]{0.00,0 \expandafter\def\csname PY@tok@se\endcsname{\let\PY@bf=\textbf\def\PY@tc##1{\textcolor[rgb]{0.73, \expandafter\def\csname PY@tok@sd\endcsname{\let\PY@it=\textit\def\PY@tc##1{\textcolor[rgb]{0.73,     \def\PYZbs{\char \\} \def\PYZus{\char \_} \def\PYZob{\char \{} \def\PYZcb{\char \}} \def\PYZca{\char \^} \def\PYZam{\char \&} \def\PYZlt{\char \<} \def\PYZgt{\char \>} \def\PYZsh{\char \#} \def\PYZpc{\char \%} \def\PYZdl{\char \ } \def\PYZhy{\char \-} \def\PYZsq{\char \’} \def\PYZdq{\char \"} \def\PYZti{\char \~}     % for compatibility with earlier versions \def\PYZat{ }     \def\PYZlb{[}     \def\PYZrb{]}     \makeatother      So my question is, how do I get it to do the right thing? Here's how I'm compiling the pdf:               xelatex -shell-escape myfile.tex      [UPDATE] And here are all the versions of everything:               xelatex --version     XeTeX 3.14159265-2.6-0.99991 (TeX Live 2014)          python --version     Python 2.7.5          pip freeze     Pygments==1.6      I tried both the regular `minted` that came with my TeX live distribution, and also the one I just downloaded from minted's master on GitHub (that's the one in `vendor`). I'm on a Mac, OS X 10.8. [UPDATE] I discovered that the problem is in the command I was using, which (contrary to what I wrote above) was actually:               xelatex -output-directory=build -shell-escape book/main.tex      Turns out the -output-directory flag causes this problem. When I run in the correct directory, everything works just fine. I'm curious though why -output- directory would cause things to fail! [UPDATE] This appears to be a duplicate of (at least) Error when using minted package and -output-directory option Perhaps this should be closed/merged?


title: Manually made folding marks in article don't appear as intended

text: I am writing a letter in the article documentclass in LyX. I tried Koma-script v2, and found it nice, but not quite fulfilling with customization, at any rate not within LyX. Most of my letter works as intended, but in order to get the folding marks, that characterize a small part of scrlttr2, I tried `\usepackage[absolute]{textpos}` Thus trying to position the folding marks at 1/3 and 2/3 of the page margins with the following commands:               \textblockorigin{0mm}{0mm}     \setlength{\TPHorizModule}{1mm}\setlength{\TPVertModule}{1mm}      \begin{textblock}{1}(0,99) \rule[0.5ex]{2mm}{1pt} \end{textblock}     \begin{textblock}{1}(0,178) \rule[0.5ex]{2mm}{1pt} \end{textblock}      The folding marks appear, but they don't appear where I want them to. And even though I set the blockorigin to 0,0 the folding marks don't touch the side of the paper (which is confusing, but not what I desire). Here is the preamble:               % Preview source code          %% LyX 2.0.5.1 created this file.  For more info, see http://www.lyx.org/.     %% Do not edit unless you really know what you are doing.     \documentclass[danish]{article}     \usepackage[T1]{fontenc}     \usepackage[latin9]{inputenc}     \usepackage[a4paper]{geometry}     \geometry{verbose,tmargin=2.5cm,bmargin=2.5cm,lmargin=3cm,rmargin=3cm}     \setcounter{secnumdepth}{-1}     \usepackage{verbatim}          \makeatletter     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.     \usepackage[nottoc]{tocbibind}     \usepackage{icomma}     \usepackage{pstricks}     \usepackage{pstricks-add}     \usepackage{pst-plot}     \usepackage{fancyhdr}     \renewcommand{\headrulewidth}{0pt}     \pagestyle{fancy}     \let\ps@plain\ps@fancy     \usepackage[all]{xy}     \usepackage{marvosym}     \usepackage[absolute]{textpos}          \makeatother          \usepackage{babel}     \begin{document}      This is were I try to make the folding marks:               \textblockorigin{0mm}{0mm}          \setlength{\TPHorizModule}{1mm}\setlength{\TPVertModule}{1mm}           \begin{textblock}{1}(0,99) \rule[0.5ex]{2mm}{1pt} \end{textblock}     \begin{textblock}{1}(0,178) \rule[0.5ex]{2mm}{1pt} \end{textblock}      And the rest:               \noindent \begin{center}     Name     \par\end{center}          \noindent \begin{center}     Title     \par\end{center}          \noindent Address\\     Address\\     Address\vspace{4ex}          \noindent \begin{flushright}     \today     \par\end{flushright}          \noindent Dear .. \vspace{4ex}          \noindent bla \vspace{2ex}          \noindent bla \vspace{4ex}          \noindent Sincerely,          \noindent Me          \cfoot{\noindent Myaddress \\     \Letter~bla@mail.com~\Telefon~+45 12\,34\,56\,78}     \end{document}


title: consistently increased line spacing when subscripts occur in paragraph

text: The question is about consistent vertical spacing in a paragraph of `text` that includes some math using `subscripts`. Concretely, in the example I feel that there is not enough `vertical space` between line 1 and line 2, due to the fact there is both a `subscript` in the math on line 1 and some math as well on line 2. In general, I would not want to fix this locally, but rather have a bit more vertical space consistently throughout the paragraph (whenever the situation occurs at least once in the pargraph). Since I have a quite a lot of paragraphs where this situation occurs, it would be useful if I did not have to request that for every single paragraph, but if this could be a default. Thanks for reading.               \documentclass[draft,11pt]{article}     \sloppy               \usepackage{amssymb}          \begin{document}          \newcommand{\diam}[1]{\ensuremath{\langle #1 \rangle}}     \newcommand{\model}{\mathbb{M}}     \newcommand{\N}{\ensuremath{\mathsf{N}}}          Assume $\model|_{\N(w_0)\cap\ldots\cap\N(w_n)},w\models \diam{a}\psi$.     It follows that there is a state $v\in \N(w_0)\cap\ldots\cap\N(w_n)$      with $w R_a v$ (1) and $\model|_{\N(w_0)\cap\ldots\cap\N(w_n)},v\models     \psi$ (2). Hence by IH  $\model|    _{\N(w_0)\cap\ldots\cap\N(w_n)},v\models     \psi$ (3). From (1) and the fact that $\model'$ is an $A$-generated     submodel of $\model$ we have $w R'_a v$, hence by (3) $\model'| _{\N(w_0)     \cap\ldots\cap\N(w_n)},w\models \diam{a}\psi$. The other direction is     trivial.               \end{document}


title: Adjusting width of ybar interval separator to width of histogram bars

text: I have an array of numbers for which I want to create a histogram for the first 22 entries. I want to show both the first few entries of the array as a bar plot as well as the histogram in two `subfigures`. For the the histogram I tried using `pgfplots`, `ybar interval` and `addplot+/table` starting with the example from the pgfplots-manual and adjusted it to my data. ![enter image description here](http://i.stack.imgur.com/jCnFt.png) My problem with the output is that the width of the interval separators is not the same as the width of my histogram bars. This results in seemingly wrong labeled bars, since the histogram is not as wide as the axis. I unsuccessfully tried following attempts to solve the problem:   1. Using `ybar` instead of `ybar interval` - This moves the ticks/labeling to the left bottom of the bar, while I'd like it centered   2. Not specifying `xticks` - This leads to the same width for the separators and the histogram bars, but the labeling changes to weird floating point numbers. Code:               \documentclass{article}     \usepackage{pgfplots}     \usepackage{subcaption}          \begin{document}          \begin{figure}     \begin{subfigure}[b]{0.7\textwidth}         \centering         \begin{tikzpicture}         \begin{axis}[         ybar,         bar width=7pt,         height=5 cm,         width=13cm,         xtick={1,3,...,30},         ytick={1,3,...,13},         xlabel={Frames},         ylabel={Class}]         \addplot coordinates {             (1,12) (2,9) (3,1) (4,11) (5,11) (6,1) (7,1) (8,12) (9,1) (10,12)              (11,12) (12,12) (13,12) (14,12) (15,12) (16,12) (17,12) (18,12) (19,12) (20,12)              (21,12) (22,13) (23,1) (24,1) (25,1) (26,11) (27,1) (28,1) (29,1)         };         \end{axis}     \end{tikzpicture}     \end{subfigure}          \begin{subfigure}[b]{0.7\textwidth}     \centering     \begin{tikzpicture}         \begin{axis}[         ybar interval,         height=5 cm,         width=13cm,         xlabel=Class,         ylabel=Counts,         xtick={1,...,14},         ]         \addplot+[hist={bins=13}]         table[row  sep=\\,y  index=0]  {         data\\         12 \\9 \\1 \\11 \\11 \\1 \\1 \\12 \\1 \\12 \\         12 \\12 \\12 \\12 \\12 \\12 \\12 \\12 \\12 \\12 \\         12 \\13 \\         };         \end{axis}     \end{tikzpicture}     \end{subfigure}     \end{figure}          \end{document}


title: Playing portions of MP3 in PDF

text: I'm working on a book which should allow the playing of MP3s at selected points. I've found a good solution for the general case (i.e. the entire file): Audio examples in phonetics project, however, I also want to play _portions_ of the files as well (e.g. words or phrases within sentences). One solution is to use audio software to split the file into the necessary sections, but this of course produces a lot of unnecessary duplication. The documentation for media9 mentions seek, which is half a solution (though I confess it isn't clear to me how to make this work). Hunting through JavaScript documentation has revealed this code, which suggests it is possible:               var player = app.media.openPlayer({       rendition: this.media.getRendition( "myAudio" ),       doc: this,       settings: {       startAt: 3,       endAt: 8       }     });      The MWE given in the link above is as follows:               \documentclass{article}     \usepackage{media9,graphicx}          \begin{document}     Sound sample: \includemedia[       addresource=sound_sample.mp3,       transparent,       flashvars={         source=sound_sample.mp3        &autoPlay=true       },     ]{\includegraphics[height=1.44ex]{speaker.png}}{APlayer.swf}     \end{document}      I'd be grateful for any suggestions on how to proceed.


title: How to automatically break "a long word with underscore" in a cell of table, using longtabu package?

text: I use `longtabu` package for creating tables, because the table can be very long (several pages) and i need automatic linebreak(or wordbreak) if the sentence(or a single word) in certain cell is too long. In most cases, `longtabu` works well for my purpose. But, if a long word contains underscore, for example, `AAA_BB_CCC_D_EEEEEE_FFF_GGGGG_HHHHHH` (I replace `_` as `\\\\_` in latex), then the word can not be linebreaked and it cross out of the border of the cell to the next cell. How can `longtabu` automatically break a long word with underscore? I want the very long word can automatically fit the length of a cell.


title: Footnote marker is rendered outside paragraph's bounding box

text: A word with a footnote marker is sticking out of my paragraph's bounding box: ![Paragraph overflow](http://i.stack.imgur.com/BltUz.png) Is there a clean way to fix my layout so that nothing sticks out of the paragraph?


title: How to set a picture with caption in table?

text: ![enter image description here](http://i.stack.imgur.com/BFki5.jpg) How to set caption for images in table? like this image.


title: acro package files in c:\Users\Bob\AppData\{Local,Roaming}\MiKTeX\2.9

text: I was perplexed by a message that acro.sty was missing, since I copied both of my root directories (2 localtexmf's) from one computer to another. The acro package does _not_ show up in the MiKTeX package manager. I recall installing it as a newbie in a haze of trial and error, but I was convinced that everything would be in the two roots. After grepping the log file, I found that there were acro package files distributed throughout the subtrees rooted at `c:\Users\Bob\AppData\\{Local,Roaming}\MiKTeX\2.9`, which are not my two roots. In MiKTeX settings, I found that these paths show up as roots when I check off the box to show MiKTeX maintained roots. I'm not sure what MiKTeX does in maintaining its own roots. The Roaming and Local paths are described as UserInstall and UserData, respectively. But I thought that was the point of my two roots, which is not maintained by MiKTeX. Since the roots in the AppData paths are maintained by MiKTeX, should I be avoiding the blythe practice of blindly copying these folder trees from one system to another? I don't want to be messing around with parts of the file system that MiKTeX doesn't expect me to mess with. I fear corrupting something, or having my installations clobbered. At present, the files in the old computer are located at               c:\Users\Bob\AppData\Roaming\MiKTeX\2.9\tex\latex\acro\acro.sty     c:\Users\Bob\AppData\Roaming\MiKTeX\2.9\tex\latex\acro\acro0.def     c:\Users\Bob\AppData\Roaming\MiKTeX\2.9\tex\latex\acro\acro1.def      In the new computer, it seems safest to put them in one of my roots at               myRoot1\tex\latex\acro\      There are additional files that are not part of the package zip file.               c:\Users\Bob\AppData\Local\MiKTeX\2.9\miktex\mthelp\acro.html     c:\Users\Bob\AppData\Roaming\MiKTeX\2.9\tpm\packages\acro.tpm      In the new computer, it seems to make sense to put the html file in               myRoot1\miktex\mthelp\      At the moment, I suspect that the tpm file is autogenerated by MiKTeX when file name database FNDB and format files are refreshed/updated via the MiKTeX settings tool. # Afternote: Interesting error the first time I refresh the FNDB (and only the 1st time)...               MiKTeX Problem Report     Message: Permission denied: C:\Users\ShortName\AppData\Local\MiKTeX\2.9\miktex/data/le\df2c24cb21984fa85003c1ecc818ff83.fndb     Data: C:\Users\ShortName\AppData\Local\MiKTeX\2.9\miktex/data/le\df2c24cb21984fa85003c1ecc818ff83.fndb     Source: Libraries\MiKTeX\Core\win\winFile.cpp     Line: 686     MiKTeX: 2.9     OS: Microsoft Windows 7 Enterprise Edition, 64-bit Service Pack 1 (build 7601)     Invokers: explorer     SystemAdmin: no     PowerUser: no     Root0: C:\Users\ShortName\AppData\Roaming\MiKTeX\2.9     Root1: C:\Users\ShortName\AppData\Local\MiKTeX\2.9     Root2: C:\cygwin\home\LongName\projects\projectName\path\to\my\1st\root     Root3: C:\Users\ShortName\Documents\LaTeX\localtexmf [this is my 2nd root]     Root4: C:\ProgramData\MiKTeX\2.9     Root5: C:\Program Files\MiKTeX 2.9     UserInstall: C:\Users\ShortName\AppData\Roaming\MiKTeX\2.9     UserConfig: C:\Users\ShortName\AppData\Roaming\MiKTeX\2.9     UserData: C:\Users\ShortName\AppData\Local\MiKTeX\2.9     CommonInstall: C:\Program Files\MiKTeX 2.9     CommonConfig: C:\ProgramData\MiKTeX\2.9     CommonData: C:\ProgramData\MiKTeX\2.9      This has been posted to the following two forums:   * latex-community.org   * stackexchange


title: How to read a character one by one from an external file, modify it, and save it back to another external file?

text: The purpose of this question is to learn how to read character by character of a fetched line of characters, modify it and save back to another file. For the sake of simplicity, let's take a simple application which is encrypting an external text file with a well-known simple algorithm, "shift cipher". I can only give you a skeleton as follows, the remaining is beyond my knowledge.               \documentclass{article}     \usepackage{filecontents}     \begin{filecontents*}{plain.txt}     Karl's students do not care about dashing patterns.     Karl's students do not care about arrow tips.     Karl's students, by the way, do not know what a transformation matrix is.     \end{filecontents*}          % shift parameter,      % positive value moves forward (for example, 1 makes A get shifted to B),     % negative value moves backward (for example, -1 makes B get shifted to A).     \def\offset{13}          \newread\reader     \newwrite\writer          \begin{document}     \openin\reader=plain.txt     \immediate\openout\writer=encrypted.txt         \loop             \read\reader to \data             \unless\ifeof\reader                 \immediate\write\writer{Do something here}         \repeat     \immediate\closeout\writer     \closein\reader     \end{document}      The interesting parts I want to learn:   * How to read a character one by one from a single line fetched from an external file.   * How to modify the single character.   * How to know the number of characters in a single line fetched from an external file. Please use the most simple method that newbies (like me) can easily digest the code.


title: Split a tabularx cell at its diagonal when the X column specification is used?

text: How do I split a cell diagonally, when I'm using `tabularx` with `X` column, i.e. `\begin{tabularx}{\textwidth}{X}`? I've seen many answers on this topic on TeX.SE, but none of them are applicable to cells with a fluid width (X column). I've currently solved my problem by using the `diagbox` package with a hard- coded width (found through trial-and-error). However, I would like to know how to solve it properly, i.e. a way to achieve the diagonal split without knowing the dimensions of the cell in advance. This is my current code, demonstrating the visually desired result, achieved by hard-coding the width of the `backslashbox`.               \documentclass{standalone}     \usepackage{tabularx}     \usepackage{diagbox}     \begin{document}       \begin{tabularx}{\textwidth}{|X|c|c|c|}       \hline         \backslashbox[92mm]{Task}{Question} & 1 & 2 & 3\\       \hline         What? & Yes & Yes & Yes \\       \hline       \end{tabularx}     \end{document}      Result: ![](http://i.stack.imgur.com/F8cKn.png)


title: Exam Class: Make math expressions in \correctchoice bold

text: I'm using the `exam` package to create a mathematics question paper. When printing answers, the `\correctchoice` command makes the choice letter as well as the text in the choice bold. However, it does not make any mathematic expressions bold. Is there a way to add this to the document? I think the commands `\boldmath` and `\unboldmath` when put around the text will make both normal text and mathematic expressions bold, but I do not know how to "merge" it with the `\correctchoice` command.


title: Chapter Dependency Diagram in Latex

text: Please look at the complex chapter dependency diagram **EXAMPLE** in the given image. It explains how each chapter is dependent on the previous one. I am sure diagrams of this type can be done (hard coded, I would say) in `Tikz`. **I DON'T NEED THE HELP TO IMPLEMENT IT IN TIKZ.** I was looking for more of a package kind of out-of-the-box solution, where you can mention the dependencies and the package will automatically generate the diagram for you. Is there any solution as such. I searched in TeX.SX for similar questions and found that in all cases, `TikZ` is the recommended option. This feature or package if implemented will be useful for people like me as we are required to include a chapter reading order or dependency diagram. ![enter image description here](http://i.stack.imgur.com/ySkUn.png) UPDATE: The ideal solution for the above diagram should be something like               \chapter{Chapter 1}     bla bla bla          \chapter{Chapter 2}     \RequiredDependency{chapter1_label}          \chapter{Chapter 3}          \chapter{Chapter 4}     \RequiredDependency{chapter1_label}     \RecommendedDependency{chapter2_label,chapter3_label}      and so on. Once I do this, the above diagram should be generated.


title: What is the difference between \vspace{\fill} and \vfill

text: What is the difference between `\vspace{\fill}` and `\vfill`? What about the starred version of them?


title: Auto-Compile after any modification in WinEdt

text: Is there any way to make WinEdt to automatically re-compile after any modification in TeX file? I know that it is possible to do it using third- party codes like it is explained here: Why can Bakoma process .tex files so fast? but, I am wondering if there is any way to do it with WinEdt itself?


title: Spacing issues with itemize in a table

text: I've been trying to use lists of items in a table. This was easy to do but I could not find a way to align them in the same way as plain text in a table. Let me give an example:               \documentclass{article}          \usepackage{paralist}          \begin{document}          \begin{tabular}{|p{2cm}|p{10cm}|}         \hline         Blah blah &          \begin{compactitem}             \item First             \item Second         \end{compactitem} \\             \hline     \end{tabular}          \end{document}      Instead of just itemize I used `paralist` so the list gets more compact, however there is still a lot of space added before and after the list. The result looks pretty awful, I would like to have the same spacing around "Blah Blah" as I have around the items in the right cell. ![enter image description here](http://i.stack.imgur.com/pSMM3.png) I've also found some tricks to reduce the space to the upper or lower `\hline` of the cell, but none of these could match the alignment with just plain text.


title: Declare additional Unicode characters in verbatim environments in a Pandoc-generated file

text: I generate a PDF document via LaTeX with Pandoc. I want to use some additional characters in verbatim environments that are not available by default. Here's a sample input:               Math: $\downarrow$          Verbatim:              stuff           ↓         thing          Text: ↓      Result of `pandoc -s -o mnwe.tex mnwe.md`:               \documentclass[]{article}     \usepackage{amssymb,amsmath}     \usepackage{ifxetex,ifluatex}     \ifxetex       \usepackage{fontspec,xltxtra,xunicode}       \defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}     \else       \ifluatex         \usepackage{fontspec}         \defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}       \else         \usepackage[utf8]{inputenc}       \fi     \fi     \ifxetex       \usepackage[setpagesize=false, % page size defined by xetex                   unicode=false, % unicode breaks when used with xetex                   xetex,                   colorlinks=true,                   linkcolor=blue]{hyperref}     \else       \usepackage[unicode=true,                   colorlinks=true,                   linkcolor=blue]{hyperref}     \fi     \hypersetup{breaklinks=true, pdfborder={0 0 0}}     \setlength{\parindent}{0pt}     \setlength{\parskip}{6pt plus 2pt minus 1pt}     \setlength{\emergencystretch}{3em}  % prevent overfull lines     \setcounter{secnumdepth}{0}      PDFLaTeX compilation log:               \begin{document}          Math: $\downarrow$          Verbatim:          \begin{verbatim}     stuff       ↓     thing     \end{verbatim}     Text: ↓          \end{document}          This is pdfTeX, Version 3.1415926-1.40.10 (TeX Live 2009/Debian)     entering extended mode     (./mnwe.tex     LaTeX2e <2009/09/24>     Babel <v3.8l> and hyphenation patterns for english, usenglishmax, dumylang, noh     yphenation, farsi, arabic, croatian, bulgarian, ukrainian, russian, czech, slov     ak, danish, dutch, finnish, french, basque, ngerman, german, german-x-2009-06-1     9, ngerman-x-2009-06-19, ibycus, monogreek, greek, ancientgreek, hungarian, san     skrit, italian, latin, latvian, lithuanian, mongolian2a, mongolian, bokmal, nyn     orsk, romanian, irish, coptic, serbian, turkish, welsh, esperanto, uppersorbian     , estonian, indonesian, interlingua, icelandic, kurmanji, slovenian, polish, po     rtuguese, spanish, galician, catalan, swedish, ukenglish, loaded.     (/usr/share/texmf-texlive/tex/latex/base/article.cls     Document Class: article 2007/10/19 v1.4h Standard LaTeX document class     (/usr/share/texmf-texlive/tex/latex/base/size10.clo))     (/usr/share/texmf-texlive/tex/latex/amsfonts/amssymb.sty     (/usr/share/texmf-texlive/tex/latex/amsfonts/amsfonts.sty))     (/usr/share/texmf-texlive/tex/latex/amsmath/amsmath.sty     For additional information on amsmath, use the `?' option.     (/usr/share/texmf-texlive/tex/latex/amsmath/amstext.sty     (/usr/share/texmf-texlive/tex/latex/amsmath/amsgen.sty))     (/usr/share/texmf-texlive/tex/latex/amsmath/amsbsy.sty)     (/usr/share/texmf-texlive/tex/latex/amsmath/amsopn.sty))     (/usr/share/texmf-texlive/tex/generic/ifxetex/ifxetex.sty)     (/usr/share/texmf-texlive/tex/generic/oberdiek/ifluatex.sty)     (/usr/share/texmf-texlive/tex/latex/base/inputenc.sty     (/usr/share/texmf-texlive/tex/latex/base/utf8.def     (/usr/share/texmf-texlive/tex/latex/base/t1enc.dfu)     (/usr/share/texmf-texlive/tex/latex/base/ot1enc.dfu)     (/usr/share/texmf-texlive/tex/latex/base/omsenc.dfu)))     (/usr/share/texmf-texlive/tex/latex/hyperref/hyperref.sty     (/usr/share/texmf-texlive/tex/latex/graphics/keyval.sty)     (/usr/share/texmf-texlive/tex/generic/oberdiek/ifpdf.sty)     (/usr/share/texmf-texlive/tex/generic/oberdiek/ifvtex.sty)     (/usr/share/texmf-texlive/tex/latex/oberdiek/hycolor.sty     (/usr/share/texmf-texlive/tex/latex/oberdiek/xcolor-patch.sty))     (/usr/share/texmf-texlive/tex/latex/hyperref/pd1enc.def)     (/usr/share/texmf-texlive/tex/generic/oberdiek/etexcmds.sty     (/usr/share/texmf-texlive/tex/generic/oberdiek/infwarerr.sty))     (/usr/share/texmf-texlive/tex/latex/latexconfig/hyperref.cfg)     (/usr/share/texmf-texlive/tex/latex/oberdiek/kvoptions.sty     (/usr/share/texmf-texlive/tex/generic/oberdiek/kvsetkeys.sty))     (/usr/share/texmf-texlive/tex/latex/hyperref/puenc.def)     Implicit mode ON; LaTeX internals redefined     (/usr/share/texmf-texlive/tex/latex/ltxmisc/url.sty)     (/usr/share/texmf-texlive/tex/generic/oberdiek/bitset.sty     (/usr/share/texmf-texlive/tex/generic/oberdiek/intcalc.sty)     (/usr/share/texmf-texlive/tex/generic/oberdiek/bigintcalc.sty     (/usr/share/texmf-texlive/tex/generic/oberdiek/pdftexcmds.sty     (/usr/share/texmf-texlive/tex/generic/oberdiek/ltxcmds.sty))))     (/usr/share/texmf-texlive/tex/generic/oberdiek/atbegshi.sty))     *hyperref using default driver hpdftex*     (/usr/share/texmf-texlive/tex/latex/hyperref/hpdftex.def) (./mnwe.aux)     (/usr/share/texmf-texlive/tex/latex/graphics/color.sty     (/etc/texmf/tex/latex/config/color.cfg)     (/usr/share/texmf-texlive/tex/latex/pdftex-def/pdftex.def     (/usr/share/texmf-texlive/tex/context/base/supp-pdf.mkii     [Loading MPS to PDF converter (version 2006.09.02).]     ))) (/usr/share/texmf-texlive/tex/latex/hyperref/nameref.sty     (/usr/share/texmf-texlive/tex/latex/oberdiek/refcount.sty)) (./mnwe.out)     (./mnwe.out) (/usr/share/texmf-texlive/tex/latex/amsfonts/umsa.fd)     (/usr/share/texmf-texlive/tex/latex/amsfonts/umsb.fd)          ! Package inputenc Error: Unicode char \u8:↓ not set up for use with LaTeX.          See the inputenc package documentation for explanation.     Type  H <return>  for immediate help.      ...                                                        l.43 \end{verbatim}          ? s     OK, entering \scrollmode...          ! Package inputenc Error: Unicode char \u8:↓ not set up for use with LaTeX.          See the inputenc package documentation for explanation.     Type  H <return>  for immediate help.      ...                                                        l.44 Text: ↓          [1{/var/lib/texmf/fonts/map/pdftex/updmap/pdftex.map}] (./mnwe.aux) )     (see the transcript file for additional information)</usr/share/texmf-texlive/f     onts/type1/public/amsfonts/cm/cmr10.pfb></usr/share/texmf-texlive/fonts/type1/p     ublic/amsfonts/cm/cmsy10.pfb></usr/share/texmf-texlive/fonts/type1/public/amsfo     nts/cm/cmtt10.pfb>     Output written on mnwe.pdf (1 page, 32085 bytes).     Transcript written on mnwe.log.      I'm using quick-and-dirty ASCII art diagrams, or rather Unicode art, in this document and I want them to stay that way, so using “proper” diagram packages is not an option. I can't change the way Pandoc generates a `verbatim` environment. I don't mind if the output is ugly, a box containing a `$\downarrow$` would do fine as long as the box has the proper size of the `tt` font. But it has to be entered as the literal character `↓` in the source code. This doesn't have to work in normal text, it's ok if the character can only be used verbatim environments. I can tell Pandoc to include extra arbitrary LaTeX commands in the header. What can I add to define the character `↓` (U+2193) to print as something resembling `↓` in the right size?


title: Margin overflow when setting the geometry \AtBeginDocument

text: Using the following minimal working example               \documentclass[12pt,a4paper]{article}          \usepackage[showframe]{geometry}     \geometry{hmargin={3.5cm,2.5cm}}          \AtBeginDocument{\geometry{vmargin={12cm,5cm}}}          \usepackage{lipsum}          \begin{document}     \lipsum[1-10]     \end{document}      Text on the first page overflows the lower margin. Other pages are fine, as illustrated by the figures below:   * first page margin (overflown) ![First page lower margin overflown](http://i.stack.imgur.com/IKJdx.png)   * other pages (as expected) ![Other pages are behaving correctly](http://i.stack.imgur.com/RrT8q.png) I need to use commands in MWE for a complicated sequence (creating a complex template as a document class, calculating some lenghts involved in the template, then putting appropriate margins on the text block to fit into the template), so redefining MWE as an answer is probably not desirable.


title: Four per page to print

text: I made an invitation for an event in LaTeX, with output at 4.25in x 5.5in. I'd like to place four of these in a 2x2 grid, and get an 8.5in x 11in document for printing. No margin changing, no resizing, just stick the pages together. One would think this should be easy, but I haven't had any luck actually doing it... Some utilities I've tried:   * `pdfjam --nup 2x2 out.pdf` (output has dimensions 8.27in x 11.69in. I can't tell what's gone wrong, but I don't want this off center)   * `imagemagick` with `+append` and `-append`. The PDF gets rasterized and the text doesn't come out well. Any ideas? The option to set the page size originally was               \usepackage[paperwidth=4.25in,paperheight=5.5in,margin=0.7in]{geometry}


title: Block with out title space in a specific position and certain length (for Title box in a poster)

text: I am working on a poster. As I need to draw a block in a specific position, I do that using `varblock`. All of this causes a banner at the top of my title block (see the picture). Is that possible to remove that only for my title box? Here I include some of my code.               \documentclass[final, 12pt]{beamer}     \usepackage[size=custom,width=77,height=107,scale=1.4,orientation=portrait]{beamerposter}      \usepackage[english]{babel}     \usepackage[pdftex]{graphicx}     \usepackage{wrapfig,xcolor}     \usepackage{array,booktabs,tabularx,amsthm,multirow,amsmath}     \usepackage[absolute,overlay]{textpos}     \usepackage{mdframed}     \usepackage{tikz}     \usepackage{pifont}     \usepackage{multicol}     \newenvironment<>{varblock}[2][\textwidth]{       \setlength{\textwidth}{#1}       \begin{actionenv}#3         \def\insertblocktitle{#2}         \par         \usebeamertemplate{block begin}}       {\par         \usebeamertemplate{block end}       \end{actionenv}}     \usecolortheme{rose}          \begin{document}     \begin{frame}          \begin{textblock}{}[0,0.1](1cm,1cm)     \begin{varblock}[75cm]{}     \vspace{-0.65cm}     \begin{center}     {\Large {\textbf{\textcolor{violet!90}{Anticipated Complexities of Landfill to Estimate Fugitive $\mathrm{CH_{4}}$  using Micro-Meteorological Method.}}}\\     \vspace{0.5cm}     \normalsize {\textbf{ M$^1$, T$^1$, J$^1$, R$^2$}}\\      \textcolor {black}  {1.Uof A 2.Agri-Food Canada}}     \end{center}     \end{varblock}     \end{textblock}               \begin{textblock}{50cm}[0,-0.58](1cm,0cm)     \begin{varblock}[35cm]{\textbf{1. Introduction}}          blah blah                \end{varblock}     \end{textblock}               \begin{textblock}{}[0,-1.4](1cm,0cm)%     \begin{varblock}[31cm]{\textbf{3. Site \& Equipment}}     blah blah      \end{varblock}     \end{textblock}          \end{frame}     \end{document}      ![enter image description here](http://i.stack.imgur.com/maAQw.png)


title: Lilypond-book with Xelatex fails to detect textwidth

text: I apologize if this sounds similar to other questions. Apparently I cannot find a solution in other posts, maybe some packages I use are conflicting (fontspec?). Even running lilypond-book with the correct option (--latex-program=xelatex) xelatex creates an output where music lines are not correctly broken at the textmargins but they are broken at the pagemargins. This causes the music overlappgin the sidepar notes. Thank you for any suggestion:               \documentclass[a3paper, 14pt, twoside, showtrims]{memoir}     \settrimmedsize{340mm}{210mm}{*}     \setlrmarginsandblock{23.3mm}{46.7mm}{*}     \setulmarginsandblock{23.3mm}{54.9mm}{*}     \setmarginnotes{2.8mm}{23.3mm}{1em}     \renewcommand{\sideparfont}{\normalfont\itshape\fontsize{12pt}{12pt}\selectfont\small}     \renewcommand{\footnotesize}{\normalfont\fontsize{12pt}{12pt}\selectfont\small}     \sideparmargin{outer}     \checkandfixthelayout      \settypeoutlayoutunit{mm}     \typeoutlayout          \usepackage{fontspec}     \setmainfont[Mapping=tex-text,Style=TitlingCaps,Ligatures={Common}]{Garamond Premier Pro} %\defaultfontfeatures{Ligatures=Historic}      \newfontfamily\greekfont[Script=Greek, Ligatures={Common}]{Garamond Premier Pro}     \newfontfamily\devanagarifont[Script=Devanagari]{Sanskrit 2003}               \usepackage{polyglossia}     \setdefaultlanguage{italian}     \setotherlanguage[variant=british]{english}     \setotherlanguage[variant=polytonic]{greek}     \setotherlanguage{sanskrit}          \usepackage{lipsum}               \begin{document}          Even running lilypond-book with the correct option (--latex-program=xelatex) xelatex creates an output where music lines are not correctly broken.\sidepar{\lipsum}          Apparently lilypond-book fails to detect textwidth from LaTex.           \noindent \begin{lilypond}[fragment,quote,staffsize=12]     \clef bass a,1 b c a b c a b c a b c a b  a b c a b c a b c a b c     \end{lilypond}          \lipsum           \end{document}


title: Getting "\andnext undefined" errors compiling latex code

text: When I try to use pdflatex to compile the following latex code, it throws errors:               [steevmi1@phusca-L24500][21:01]     [~/] % cat ./bar.tex     % Created 2012-05-02 Wed 20:57     \documentclass[11pt]{article}     \usepackage[utf8]{inputenc}     \usepackage[minted,minion]{org-preamble-pdflatex}     \usepackage{graphicx}     \usepackage{longtable}     \usepackage{float}     \providecommand{\alert}[1]{\textbf{#1}}          \title{bar}     \author{Steeves}     \date{\today}     \hypersetup{       pdfkeywords={},       pdfsubject={},       pdfcreator={Emacs Org-mode version 7.8.09}}          \begin{document}          \maketitle          % Org-mode is exporting headings to 3 levels.     \section{This is heading one}     \label{sec-1}          Some text     \subsection{This is heading two}     \label{sec-1-1}          Some more text          \end{document}%                                                                                [steevmi1@phusca-L24500][21:01]     [~/] % pdflatex ./bar.tex     This is pdfTeX, Version 3.1415926-2.3-1.40.12 (TeX Live 2011/MacPorts 2011_5)      restricted \write18 enabled.     entering extended mode     (./bar.tex     LaTeX2e <2009/09/24>     Babel <v3.8l> and hyphenation patterns for english, dumylang, nohyphenation, et     hiopic, arabic, farsi, pinyin, croatian, bulgarian, russian, ukrainian, czech,      slovak, danish, dutch, ukenglish, usenglishmax, finnish, basque, french, german     -x-2009-06-19, ngerman-x-2009-06-19, german, ngerman, swissgerman, monogreek, g     reek, ancientgreek, ibycus, hungarian, assamese, bengali, gujarati, hindi, kann     ada, malayalam, marathi, oriya, panjabi, tamil, telugu, sanskrit, italian, lati     n, latvian, lithuanian, mongolian, mongolianlmc, bokmal, nynorsk, afrikaans, ar     menian, coptic, esperanto, estonian, icelandic, indonesian, interlingua, irish,      kurmanji, lao, romanian, serbian, serbianc, slovenian, turkish, uppersorbian,      welsh, polish, portuguese, spanish, catalan, galician, swedish, turkmen, loaded     .     (/opt/local/share/texmf-texlive-dist/tex/latex/base/article.cls     Document Class: article 2007/10/19 v1.4h Standard LaTeX document class     (/opt/local/share/texmf-texlive-dist/tex/latex/base/size11.clo))     (/opt/local/share/texmf-texlive-dist/tex/latex/base/inputenc.sty     (/opt/local/share/texmf-texlive-dist/tex/latex/base/utf8.def     (/opt/local/share/texmf-texlive-dist/tex/latex/base/t1enc.dfu)     (/opt/local/share/texmf-texlive-dist/tex/latex/base/ot1enc.dfu)     (/opt/local/share/texmf-texlive-dist/tex/latex/base/omsenc.dfu)))     (/Users/steevmi1/Library/texmf/tex/kjhealy/org-preamble-pdflatex.sty     (/opt/local/share/texmf-texlive-dist/tex/latex/base/ifthen.sty)     (/opt/local/share/texmf-texlive-dist/tex/latex/base/fontenc.sty     (/opt/local/share/texmf-texlive-dist/tex/latex/base/t1enc.def))     (/opt/local/share/texmf-texlive-dist/tex/latex/base/fixltx2e.sty)     (/opt/local/share/texmf-texlive-dist/tex/latex/wrapfig/wrapfig.sty)     (/opt/local/share/texmf-texlive-dist/tex/latex/rotating/rotating.sty     (/opt/local/share/texmf-texlive-dist/tex/latex/graphics/graphicx.sty     (/opt/local/share/texmf-texlive-dist/tex/latex/graphics/keyval.sty)     (/opt/local/share/texmf-texlive-dist/tex/latex/graphics/graphics.sty     (/opt/local/share/texmf-texlive-dist/tex/latex/graphics/trig.sty)     (/opt/local/share/texmf-texlive-dist/tex/latex/latexconfig/graphics.cfg)     (/opt/local/share/texmf-texlive-dist/tex/latex/pdftex-def/pdftex.def     (/opt/local/share/texmf-texlive-dist/tex/generic/oberdiek/infwarerr.sty)     (/opt/local/share/texmf-texlive-dist/tex/generic/oberdiek/ltxcmds.sty)))))     (/Users/steevmi1/Library/texmf/tex/kjhealy/memoir-article-styles.sty          ! LaTeX Error: \andnext undefined.          See the LaTeX manual or LaTeX Companion for explanation.     Type  H <return>  for immediate help.      ...                                                        l.17 \renewcommand*{\andnext}                                  {%     ?           I'm assuming that this is an issue where it's looking at the "memoir-article-styles.sty" file before it's loaded the actual memoir class, but I'm not sure how to fix it.      The contents of the org-preamble-pdflatex.sty file:               %% Preamble/settings for documents exported from .org files to .tex files when the      %% tex engine is pdflatex.     %%     %% Usage: \usepackage{org-preamble-pdflatex} in your document     %% preamble. \usepackage[minion]{org-preamble-pdflatex}     %% activates the MinionPro package instead of Times New Roman. The     %% actual Minion Pro font files must be installed first, in accordance     %% with the instructions in the MinionPro package.          %% \usepackage[minted]{org-preamble-xelatex} activates the minted     %% package for code highlighting. Minted requires that pygments be     %% installed (http://pygments.org/) and that \write18 support be     %% enabled in your tex compiler.          %% Kieran Healy     %%          \NeedsTeXFormat{LaTeX2e}     \ProvidesPackage{org-preamble-pdflatex}[2011/02/21 v0.01 Bundling of Preamble items for Org to pdfLaTeX export (including MinionPro)]          \RequirePackage{ifthen}     \newboolean{@minion}     \newboolean{@minted}          \setboolean{@minion}{false} % minion is off by default     \setboolean{@minted}{false} % minted is off by default          \DeclareOption{minion}{       \setboolean{@minion}{true}     }          \DeclareOption{minted}{       \setboolean{@minted}{true}     }          \ProcessOptions          \RequirePackage[T1]{fontenc}     \RequirePackage[utf8]{inputenc}     \RequirePackage{fixltx2e}     \RequirePackage{wrapfig}     \RequirePackage{rotating}     \RequirePackage{memoir-article-styles}     \RequirePackage[american]{babel}     \RequirePackage[babel]{csquotes}     \RequirePackage[svgnames]{xcolor}     \RequirePackage{soul}          %%% If \RequirePackage[minion]{org-preamble-pdflatex} is set,     %%% MinionPro and microtype setup (requires full installation of MinionPro font)     %%% If MinionPro is not specified, use Times instead.     \ifthenelse{\boolean{@minion}}{       \RequirePackage[fullfamily,opticals,footnotefigures]{MinionPro}       \RequirePackage[scaled=0.78]{beramono}       \RequirePackage{microtype}       \RequirePackage[toc,eqno,enum]{tabfigures}       \renewcommand{\scdefault}{ssc} %% nicer small-caps headings       }{       \RequirePackage{times}       \RequirePackage[config=mt-ptm]{microtype}       \RequirePackage[scaled=0.74]{beramono}     }               \RequirePackage[colorlinks=true, urlcolor=DarkSlateBlue,     citecolor=DarkSlateBlue, filecolor=DarkSlateBlue, plainpages=false,     pdfpagelabels, bookmarksnumbered]{hyperref}     \RequirePackage{etoolbox}          %% Biblatex     % \RequirePackage[authordate, backend=biber, babel=hyphen, bibencoding=inputenc, strict, isbn=false, uniquename=false]{biblatex-chicago} % biblatex setup     \RequirePackage[style=authoryear,                 bibstyle=authoryear,                 citestyle=authoryear-comp,                 uniquename=false,                 hyperref=true,                 backend=biber, babel=hyphen, bibencoding=inputenc]{biblatex}          %% Fix biblatex's odd preference for using In: by default.     \renewbibmacro{in:}{%       \ifentrytype{article}{}{%       \printtext{\bibstring{}\intitlepunct}}}          %% Basic bibliography     \addbibresource{/Users/kjhealy/Documents/bibs/socbib.bib}            %% these tweak the biblatex-chicago format to conform to AJS style.       \DeclareFieldFormat[article]{title}{\mkbibquote{#1}}       \DeclareFieldFormat[book]{title}{%       \mkbibemph{#1}\isdot} % for books     \DeclareFieldFormat{booktitle}{\mkbibemph{#1}} % for edited volumes          %% bibnamedash: with Minion Pro the three-emdash lines in the     %% bibliogrpaphy end up separated from one another, which is very     %% annoying. Replace them with a line of appropriate size and weight.     \renewcommand{\bibnamedash}{\rule[3.5pt]{3em}{0.5pt}\,}               %% Pagestyle     \pagestyle{kjh}          %% If [minted] option is chosen, activate minted     \ifthenelse{\boolean{@minted}}{       \RequirePackage{minted}       \usemintedstyle{tango}        \definecolor{bg}{rgb}{0.95,0.95,0.95}       \setkeys{Gin}{width=1\@textwidth}      }{}          \endinput      For the sake of completeness, the contents of memoir-article-style.sty are at https://github.com/kjhealy/latex-custom-kjh/tree/master/needs-memoir (the file is fairly large at 551 lines, so I'm putting a link to it rather than the actual contents).


title: Color-coded chapter tabs to match flower colors in a field guide

text: I am working on a booklet for my wife who is a grade school teacher. The booklet is field guide about the plants in the fairly large playground area at Gemini Elementary. Tufte-Latex is my "go-to" template for everything these days - especially thanks to this fine group showing me the code to make a change to the color of chapter headings! I am befuddled by another chapter/color task. What I would like to do is assign a little tab of color to associate each chapter with the color of a flower, or green for trees and shrubs. Introductory chapters could just have a white tab so nothing shows up. The colored tabs would be in the table of contents and then at the top, maybe a cm or two from outer corner of each page. Am I nuts for even thinking about doing this?


title: How to use the "mover" command in Skak

text: I teach after school chess, and installed LaTeX on my computer just to make chess worksheets. I'm using `skak`. My documents start:               \documentclass[12pt]{article}     \usepackage{chess-workshop-symbols}     \usepackage{skak}     \usepackage[margin=0.2in]{geometry}     \begin{document}      and then have the problems I want to give the kids, like so:               % one solution, three checks     \fenboard{5rk1/pp3N1p/4P3/2P5/3Q1PK1/P7/1Pr3pq/R3R3 w - - 0 0}     \showboard      I would love to have the worksheets show whether it is black's move or white, but I haven't been able to get the command `\showmoverOn` to work (nor `\showmover` or `\moverOn` or `\mover`). Any idea what I'm doing wrong? When I try it, the console output says something like:               ! Undefined control sequence.     \ShowMoverBlackNormal ->\pscustom                                        [fillstyle=solid,fillcolor=gray]{\skak@tra...     l.23 \showboard          ?


title: Overlapping Arrows

text: I've been looking for arrow symbols that form a right angle, and 45' angles pointing to the upper-left and left of the symbol (combination of `\leftarrow` and `\nwarrow`, essentially). Generally, all combinations of the three arrows `\leftarrow`, `\uparrow` and `\nwarrow`.![enter image description here](http://i.stack.imgur.com/Oq2Xp.png) I tried \mathrlap...               $\mathrlap{\leftarrow}\uparrow$      but the results were less than satisfactory --the origin of the arrows should be the same point. Any advice would be appreciated.


title: How do I prevent \cellcolor from over effect of \hline

text: I'm trying to add HTML code based color to my table, like so:               \usepackage[table]{xcolor}          \begin{tabular}{ |>{\columncolor[HTML]{F2FAF8}}c| p{11cm} |}         \hline     CELL 1 & CELL 2\\ \hline     CELL 1 & CELL 2\\ \hline     CELL 1 & CELL 2\\ \hline      \end{tabular}      however, the cells seem to overflow on top of the \hline, like so: ![Bad table!](http://i.stack.imgur.com/7hdTp.png) How do I prevent this from happening? _UPDATE_ in response to comments: I tried: \setlength{\arrayrulewidth}{1pt} \begin{tabular}{ |>{\columncolor[HTML]{F2FAF8}}c| p{11cm} |} \hline CELL 1 & CELL 2\ \hline CELL 1 & CELL 2\ \hline CELL 1 & CELL 2\ \hline \end{tabular} no go: ![enter image description here](http://i.stack.imgur.com/LUGvG.png)


title: \today and language (babel, xepersian)

text: I'm using xepersian for my article but in one page I need to add Gregorian calendar date. so I add:               \usepackage[british]{babel}      and then where I want the date:               \selectlanguage{british}     {\large \today}      butthen where ever I use today it writes Gregorian instead of persian (still in persian but uses Gregorian calender) and figure caption texts (like Fig.) is in english instead of persian. EDIT:               \documentclass[14pt,a4paper]{article}          %\usepackage[british]{babel}     \usepackage{enumerate}     \usepackage{xepersian}     \settextfont{XB Niloofar}          \begin{document}     \today     \end{document}      Like this the printed date is from persian calendar like this (reads 16th of khordad 1393): ![enter image description here](http://i.stack.imgur.com/1DPYE.png) but when I uncomment that line it will be english language in persian like this(reads 6th of june 2014): ![enter image description here](http://i.stack.imgur.com/Ivud2.png)


title: bidi causes reversed parentheses in equation numbers

text: When writing a Hebrew document using `xelatex`, `bidi`, and `polyglossia`, equation numbers are in reverse parentheses. How can I fix this? MWE               \documentclass[a4paper, twoside, titlepage, 11pt]{report}     \usepackage{amsmath}     \usepackage{amsthm}     \usepackage{xltxtra}     \usepackage{polyglossia}     \usepackage{bidi}          \setmainfont{Arial}          \begin{document}          \begin{equation}     a=\frac{dx}{dt}     \end{equation}          \end{document}


title: How to set the font for a \section title (and chapter etc)

text: How do I specify the fonts, and general font size, for the titles, chapters and sections in my document **Update:** I can see how my question is confusing. I use `\section` and `\chapter` etc. to organise my document, and I would like to change the way the section and chapter titles are displayed.


title: Fonts: Arial Narrow (or equivalent)in LaTeX

text: I may be opening an old wound here...my University's preferred font is Arial Narrow. I have very little experience with working with fonts; I usually stick with CMR, which at least provides a perfect match across the entire document; mathematics and all. However, back to Arial Narrow. My first attempt was to put               \fontfamily{phv}\fontseries{mc}\selectfont      (following the instructions at LaTeX Arial Narrow font) straight after `\begin{document}`; this typeset the body of the text beautifully, but kept sections headings in cmr bold. I tried to download all the nonfreefonts with `getnonfreefonts` but for some reason they all ended up in the wrong directory. I tried using `\usepackage{helvet}` which certainly works across the entire document, but gives me an ordinary, not narrow, font. I'll try using `\usepackage{uarial}` once I move that new font tree out of `/usr/local/share/texmf` and into `/usr/share/texlive/texmf-dist/`. But if there's any better, or more straightforward way...?


title: Unbold section and subsection heading

text: I am using this format for my section and subsection headings (it is centered and numbers have dots):               \documentclass[12pt]{article}     \usepackage[center]{titlesec}          \titlelabel{\thetitle.\quad} %dots after title number      But I cannot unbold it by using most of the unbold commands because centering changes in most of them. Is there way to unbold the section and subsection headings with this format?


title: How to edit the properties of chapter and section headings (size of font, positions, indents)?

text: > **Possible Duplicate:**   >  How to set the font for a \section title (and chapter etc) How to edit the properties of `chapters`' and `sections`' headings (size of font, positions, indents) in `report` style?


title: draw a many edge from a node- Tree - tikz

text: i want to draw the tree in the following picture : ![enter image description here](http://i.stack.imgur.com/CKhYc.jpg) i have write :               \documentclass{article}     \usepackage{tikz}     \usepackage{color}           \definecolor{red}{rgb}{1,0,0}       \begin{document}            \begin{tikzpicture}       \tikzstyle{level 1}=[sibling distance=50mm]       \tikzstyle{level 2}=[sibling distance=30mm]        \node(a) {\textcolor{red}{2}|2}             child {node(b) {\textcolor{red}{2}|4}             child {node(f) {\textcolor{red}{2}|4}}                 child {node(g)[rectangle, draw] {                 \scalebox{0.6}{% size of the array                      \begin{tabular}{c|c|c|c|c|c}                                 \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4                             \end{tabular}                             }                 }}                 child {node(d) {\textcolor{red}{5} | 2}}                 }        child {node(c)[rectangle, draw] {     \scalebox{0.8}{% size of the array      \begin{tabular}{c|c|c|c|c|c}                 \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4             \end{tabular}             }     }}                 child {node(e) {\textcolor{red}{7} | 2}                 child {node(f) {\textcolor{red}{2}|4}}                 child {node(g)[rectangle, draw] {                 \scalebox{0.6}{%                      \begin{tabular}{c|c|c|c|c|c}                                 \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4 & \textcolor{red}{2}|4                             \end{tabular}                             }                   }}                   child {node(d) {\textcolor{red}{5} | 3}}                    }       ;            \draw[dashed] (a) -- (b);          \end{tikzpicture}     \end{document}      I get this result : ![enter image description here](http://i.stack.imgur.com/a63wL.png) How can i proceed to draw the many egde form the array child of the parent to the other child , thank u in advance


title: LaTeX - Cline - Amendment at the right end

text: Cline command in connection with a text at the right end. Is this possible? Concretely, I want to present via the `\cline` command a time bar within `tabular`, which has at its right end a `\triangleright` and the description "Time". The axis intercepts and the other lettering are just in order with the help of other rows. With regard to the questions: (1) Yes, it is in connection with `tabular`.   (2) The document class is `article`, and the desired result looks similar to the following:               |-----|-----|-----|-----|-----------|>  Time          (1) and (2) By the way, I would like to hint at the answer of David Carlisle, which already is a very great progress for solving my difficulty. To David Carlisle: I’m grateful to you for your answer containing the necessary program lines. What now still is failing, is that the `\triangleright` and the lettering “Time” are vertically not on the height of the time bar. Is it possible to avoid this optical deficit? In the meantime I have solved the difficulties with the vertical and the horizontal positioning with the commands `\raisebox` and `\hspace`.


title: Defining a dimension with or without @

text: If I am writing a TeX package (as one can find such on CTAN), there are following approaches to define a new dimension `length` _that should be changeable by a user_ of that package.   * Approach A: Define an inaccessible dimension with @ and an accessible macro for setting (see also meaning of @)              \newdimen\PKG@length \PKG@length=5pt     \def\setPKGlength#1{\PKG@length=#1}      and ask the user to modify the dimension with `\setPKGlength{7pt}`   * Approach B: Define an accessible dimension without @              \newdimen\PKGlength \PKGlength=5pt      and ask the user to modify the dimension with standard techniques like `\setlength{\PKGlength}{7pt}` in LaTeX or `\PKGlength{7pt}` in plain TeX (see also What is the right way to set a dimension parameter?). Which approach is safer to use or has more advantages? Any alternatives?


title: tikz - Multiple nodes with same content

text: I would like to know how to place multiple nodes with same content in TikZ. I've made a macro for it, but I think that it could have a different approach.               \usepackage{tikz}     \usepackage{bm}     \newcommand{\cross}{%         node {\LARGE\bm{$\times$}}%     }          \begin{document}           \begin{tikzpicture}     \draw[black]         (1,1) \cross         (3,1) \cross         (1,4) \cross         (3,4) \cross;     \end{tikzpicture}          \end{document}      So, my question is: is there any way to do something like this?               \cross{(1,1), (3,1), (1,4), (3,4)}


title: Column and row padding in tables

text: How do you guys go about controlling column padding in tables? ## Update To clarify, I'm looking for a way to control both vertical and horizontal padding. So, if I had a simple table like in the following code snippet, I could pad the columns and make them look a bit less... ugly. :P               \begin{tabular}{|l|l|}         \hline         column 1 & column 2 \\          \hline         I really would like this less & crammed\\         \hline     \end{tabular}      I tried this by using the command `\vspace` but it leaves gaps in the vertical lines.


title: \arraystretch both horizontally and vertically

text: I did an `\arraystretch` to get taller column vectors, but not the matrices are too small. How can I also stretch them horizontally so that the matrices become square-like again? Here's the code I used:               \renewcommand*{\arraystretch}{1.8}


title: Customizing the height of the cells in a table

text: I have the following table construction in LaTeX:               \begin{center}     \begin{minipage}[c]{0.3\textwidth}     \vspace{0pt}     \begin{tabular}[b]{l||c|c|c|c|c|c}                   \textbf{0} & \textbf{1} & \textbf{2} & \textbf{3} & \textbf{4} & \textbf{5} & \textbf{6}\\     \hline      \hline     \textbf{1}       & $\frac{1}{1}$ & $\frac{1}{2}$ & $\frac{1}{3}$ & $\frac{1}{4}$ & $\frac{1}{5}$ & $\frac{1}{6}$ \\     \hline     \textbf{2}       & $\frac{2}{1}$ & $\frac{2}{2}$ & $\frac{2}{3}$ & $\frac{2}{4}$ & $\frac{2}{5}$ & $\frac{2}{6}$ \\     \hline     \textbf{3}       & $\frac{3}{1}$ & $\frac{3}{2}$ & $\frac{3}{3}$ & $\frac{3}{4}$ & $\frac{3}{5}$ & $\frac{3}{6}$ \\     \hline     \textbf{4}       & $\frac{4}{1}$ & $\frac{4}{2}$ & $\frac{4}{3}$ & $\frac{4}{4}$ & $\frac{4}{5}$ & $\frac{4}{6}$ \\     \hline     \textbf{5}       & $\frac{5}{1}$ & $\frac{5}{2}$ & $\frac{5}{3}$ & $\frac{5}{4}$ & $\frac{5}{5}$ & $\frac{5}{6}$ \\     \hline     \textbf{6}       & $\frac{6}{1}$ & $\frac{6}{2}$ & $\frac{6}{3}$ & $\frac{6}{4}$ & $\frac{6}{5}$ & $\frac{6}{6}$ \\     \end{tabular}     \vspace{0pt}     \end{minipage}     \end{center}      The problem is clear by viewing the following output: ![Ugly table!](http://i.stack.imgur.com/OdCNo.png)   1. How can I modify the height of a cell in table?   2. I know that I can do p{' '} for the width what about the height? Thanks for all the help!


title: A matrix inside a table

text: > **Possible Duplicate:**   >  Column padding in tables I am trying to insert a matrix inside a table, and I am looking for a good way to do this. Usually when I write matrices in equations, I use array environment, so I naively defined an array inside tabular, and it sort of works. The only problem is that the matrix itself seems to take up a huge amount of space inside the cell. An example is               \begin{tabular}{|c|c|}     \hline     \textbf{EKF} & \textbf{UKF}\\     \hline     $Q = \left[ \begin{array}{cc} 0.1 & 0 \\ 0 & 0.1 \end{array}\right]$ & $Q = left[ \begin{array}{cc} 0.01 & 0 \\ 0 & 0.01  \end{array}\right]$\\     \hline     $R = 5 \times 10^{-3}$ & $R = 5 \times 10^{-5}$ \\     \hline     \end{tabular}      Is there any way to increase the spacing in the cell containing the matrix without that matrix taking up all the space?


title: Different vertical spacing just in header row of table

text: Does anyone know how to make the header row of a table of a different thickness than the body rows? I can control the standard 'thickness' of the rows via: `\renewcommand{\arraystretch}{1.25}`, where 1.25 is the multiple of standard thickness, but it doesn't seem to have any effect (in fact, throws error) if I try to change this value mid-way through the table construction. What I was hoping to be able to do, was something like this:               \documentclass{article}          \begin{document}         \begin{tabular}{|c|c|c|}         \renewcommand{\arraystretch}{2}         \hline         Header 1 & Header 2 & Header 3\\         \renewcommand{\arraystretch}{1.25}         \hline         A & B & C\\         \hline         D & E & F\\         \hline         \end{tabular}     \end{document}


title: Add more space between cells in a table

text: I'd like to add more space between the cells of the table below. I've tried the command `[2ex]` after `\\\` but this changes the vertical alignment, which I'd like to be centered.               \documentclass{article}     \begin{document}     \begin{table}     \footnotesize     \centering     \begin{tabular}{c|c|c|c}     \multicolumn{4}{c}{ } \\     Text text text text & Text text text text & Text text text text & Text text text text \\\hline     \multirow{2}{*}{Text text text}     & Text text text text & Text text text text & Text text text text \\[2ex]     & Text text text text & Text text text text & Text text text text \\[2ex]\hline     \multirow{2}{*}{Text text text}     & Text text text text & Text text text text & Text text text text \\[2ex]     & Text text text text & Text text text text & Text text text text \\[2ex]\hline     \end{tabular}     \end{table}     \end{document}


title: padding for table cells

text: > **Possible Duplicate:**   >  Column padding in tables I am unable to determine the padding for table cells. Here is my table so far:               \begin{center}     \begin{tabular}{ m{5cm}  m{12cm} }     \hline     \cellcolor[gray]{0.9} Poo & \cellcolor[gray]{0.9} Bar \\ \hline     Bla bla & Bla bla \\     \hline     \end{tabular}     \end{center}      Anyone has an idea?


title: Increase row height of tabularx

text: I'm using the `tabularx` package from within memoir for creating a table. I'm trying to set the row height and found for `tabular` the command               \setlength{\extrarowheight}{40pt}      However, with my `tabularx` table it doesn't seem to work and I can't find any way to do it (except maybe by manually setting each newline to a certain height) Is there a better way to set the row height of all rows within a `tabularx`?


title: Adding space between columns in a table

text: I notice that the space between each column of a table in LaTeX is not quite wide (at least for me). Is there any way to set this? I found the \hspace, but I don't get how to use this in the table. ADDED: Found the answer! put `\renewcommand{\tabcolsep}{3cm}` (the `3cm` is just an example) if you want to change the space in all table. If you want to change it on one or several, Stefan's answer will be the best.


title: tables: spaces between rows for a single row (top and bottom)

text: I have this silly question that might look like a duplicate, but I still cannot get it to work... I have the following table, and I just need more vertical spacing at the top and bottom of the 3rd row... Adding [3cm] after the end of the row would give me more space at the bottom of the row, but what about the space at the top? Many thanks! MWE:               \documentclass{standalone}          \usepackage{pbox}          \begin{document}          \renewcommand{\arraystretch}{2}     \begin{tabular}{|c|c|c|c|c|}         \cline{2-5}             \multicolumn{1}{c|}{}             & \textbf{group a}             & \textbf{group b}             & \textbf{group c}             & \textbf{group d}\\         \cline{1-5}             \textbf{classif1}             & A             & B             & A             & B\\         \cline{1-5}             \textbf{classif2}             & A             & B             & B             & A\\         \cline{1-5}             \textbf{IDs}             & \textit{\pbox{20cm}{ALK, APC,\\CDH1, EGFR,\\GPC3, HNF1A,\\MPL, PHOX2B,\\RET, TSHR}}             & \textit{\pbox{20cm}{AXIN1, BRCA2,\\BUB1B, CDKN2A,\\ERCC2, ERCC4,\\FANCC, FANCE,\\FH, HRAS,\\MLH1, MSH6,\\NF1, PMS2,\\PRKAR1A, RB1,\\SBDS, SDHAF2,\\SDHB, SDHD,\\SMAD4, SMARCB1,\\STK11, SUFU,\\TP53, TSC1,\\XPA, XPC}}             & \textit{\pbox{20cm}{ATM, BLM,\\BRCA1, BRIP1,\\CDC73, CDK4,\\CHEK2, CYLD,\\DDB2, DICER1,\\ERCC3, ERCC5,\\EXT1, EXT2,\\FANCA, FANCD2,\\FANCG, FLCN,\\MSH2, MUTYH,\\NF2, PALB2,\\PMS1, RECQL4,\\SDHC, SMARCE1,\\TSC2, VHL,\\WRN}}             & \textit{\pbox{20cm}{BMPR1A, FANCF,\\KCNJ5, KIT,\\LMO1, MAX,\\MEN1, NBN,\\PRF1, PTCH1,\\PTEN, TERT,\\WT1}}\\[3cm]         \cline{1-5}             \textbf{Number}             & 10             & 28             & 29             & 13\\         \cline{1-5}     \end{tabular}          \end{document}


title: How can I have a tabular flush with the margins?

text: Consider the following:               \documentclass{article}          \setlength\parindent{0pt}          \begin{document}     content \hfill content          \begin{tabular*}{\textwidth}{l@{\extracolsep{\fill}}r}       one   & two \\       three & four     \end{tabular*}          content \hfill content     \end{document}      > ![output](http://i.stack.imgur.com/g983q.png) How can I remove the whitespace at either side of the `tabular`?


title: Short hand for \\[space]

text: Hi I am following the method here How to specify the row height in LaTeX table? To increase the table row height, I was wondering is there a way to create a new command for               \\[space]      to something like `\\\\\` or similar so that I can change `[space]` globally?


title: Table margins and paddings

text: > **Possible Duplicate:**   >  Column padding in tables How do I adjust the padding in a table, meaning the distance between cell content and cell border? And how do I allow normal text flow so line breaks are added automatically, so the table doesn't stretch over the margin? These margin/padding problems are illustrated in the figure: ![Table example](http://i.stack.imgur.com/ykAwL.png)


title: Table cutting off fractions

text: I am having some problems with my table cutting the tops and bottoms off of my fractions. See image. The horizontal padding seems fine as is, but I couldn't figure out how to increase the vertical cell padding. ![](http://i.stack.imgur.com/3Ut4j.png)


title: Padding at the top of a table cell in LaTeX

text: I have a simple LaTeX `tabular` table:               \begin{tabular}{|l|l|l|}       \hline       A  & B  & C \\       \hline       A1 & B1 & C1 \\       \hline       A2 & B2 & C2 \\       \hline     \end{tabular}      ![the rendered table](http://i.stack.imgur.com/RCgZ2.png) Now the padding at the top of the cells is much smaller than the padding at the bottom, I guess because space for descenders is reserved. It makes the text look unaligned. How do I add some padding at the top of the table cells? I tried `\arraystretch` but it also adds padding at the bottom.


title: Formatting table

text: I have a table that is created with the following code:               \begin{table}[htdp]     \caption{Comparison of Elements in Air on the Space Station and sea level on Earth}         \centering     \begin{center}     \begin{tabular}{|c|c|c|c|}     \hline     Chemical Component & Percentage in Earth's Atomsphere & Ideal Values for the Space Station &         Astronaut Exhalation\\ \hline     Nitrogen      & 78.084\% & 78.000\% & 74.200\% \\ \hline     Oxygen        & 20.946\% & 21.000\% & 15.300\% \\ \hline     Argon         & 0.934\%  &  0.000\% & 0.000\% \\ \hline     Carbon Dioxide& 0.033\%  &  0.000\% & 3.600\% \\ \hline     Water Vapour  & 0.030\%  &  1.000\% & 0.800\% \\ \hline     Trace Elements& 0.003\%  &  0.000\% & 0.800\% \\ \hline     \end{tabular}     \end{center}     \label{default}     \end{table}      But it sticks over the page so how could i format it so that it fits on a page in portrait mode not landscape.


title: how can i add more space on Table

text: My code is here.               \begin{table}[t]      \centering     \begin{tabular}{|c|c|c|} \hline     Graph $G$ & Graph $H$ & An isomorphism between $G$ and $H$\\ \hline     \multirow{8}{*}{\includegraphics[height=4cm]{Graph_iso_a.eps}} & \multirow{8}{*}{\includegraphics[height=4cm]{Graph_iso_b.eps}} & $f(a)$ = 1\\&& $f(b)$ = 6\\ &&$f(c)$ = 8\\ &&$f(d)$ = 3\\ &&$f(g)$ = 5\\ &&$f(h)$ = 2\\ &&$f(i)$ = 4\\ &&$f(j)$ = 7\\ \hline     \end{tabular}     \caption{Graph isomorphism.}     \end{table}      ![enter image description here](http://i.stack.imgur.com/6Rj6z.gif) The problem is that that is not enough space then the line is covered by the image. How can I fix it? Thanks!


title: LaTeX \bar in table

text: I'm very new to Latex. So i want to put a `\bar W` in a table but the bar is covered by the horizontal line of table.So it becomes invisible. I tried adding `\noalign{\smallskip}` after `\hline` but it cuts the vertical line of the table. Any suggestion? Here is the code:               \begin{center}         \begin{tabular}{ | l |  l |}         \hline         $\bar W $ & $A$  \\ \hline  \noalign{\smallskip}           $\bar W $ & $A$  \\ \hline          ... & ... \\ \hline         \end{tabular}     \end{center}      First bar is invisible and second one cuts the table.


title: Quotes with speech balloons

text: I looking for a way to do that with TikZ : ![enter image description here](http://i.stack.imgur.com/Wvs8L.jpg) But I have no idea how to do this quote style.               \begin{sballoonquote}{\linewidth}{r}{color}{Donald Knuth}     An algorithm must be seen to be believed.     \end{sballoonquote}      Produce a ragged-right rounded quote, a `sballoonquote*` do the same but non- rounded. How can I do this. Someone have a solution ?


title: LaTeX adds an additional blank paragraph after the end of my custom environment

text: A friend, who is a LaTeX user but isn't very confident with customising it, told me that he would like to be able to put framed paragraphs and framed equations into his documents. So I took it upon myself to create environments "charlesbox" and "charlesboxmaths" to facilitate doing this. However, I have run into an odd issue with spacing after the maths environment specifically. In this test example, it appears as though LaTeX inserts an additional, completely empty line of text after the `\end{charlesboxmaths}` line. I have found that I can suppress this behaviour by eliminating the blank line before the following paragraph; adding a `%` to the end of the `\end{charlesboxmaths}` line; or just replacing the `\begin` and `\end` commands with the begin- and end-environment code itself. But how can my environment code take care of this problem?               \documentclass[a4paper]{article}          \newsavebox{\mysavebox}          \newlength{\charlesboxdefaultwidth}     \newenvironment{charlesbox}[1][\charlesboxdefaultwidth]%     {\begin{lrbox}{\mysavebox}\begin{minipage}{#1}}%     {\end{minipage}\end{lrbox}\begin{center}\fbox{\usebox{\mysavebox}}\end{center}}          \newenvironment{charlesboxmaths}%     {\begin{lrbox}{\mysavebox}\begin{math}}%     {\end{math}\end{lrbox}\[\fbox{\usebox{\mysavebox}}\]}          \setlength{\charlesboxdefaultwidth}{110mm}          \begin{document}          Lorem ipsum dolor sit amet, pede nunc aliquam. Dapibus urna turpis arcu, venenatis in nam nullam. Erat porttitor laoreet, nulla elit eu, pharetra duis litora ante condimentum aliquet lacus, bibendum lacus et ac eu. Massa mi vel. Metus mauris eu in aenean erat tincidunt, convallis odio, erat dui fermentum suspendisse in, nunc ante morbi vestibulum ullamcorper vel. Torquent vel augue habitasse ipsum egestas, non pede nam.          \begin{charlesbox}         Possimus pede inceptos vitae amet eu egestas, mi phasellus amet suscipit. Semper vehicula, hymenaeos a dignissim dis, nulla erat. Sed sem cras malesuada. At nonummy, velit nullam, vel ridiculus iaculis perferendis pretium erat a. Sapien sed blandit. Neque risus viverra, sit vitae gravida dignissim sed, ornare vehicula libero, erat accumsan.     \end{charlesbox}          Neque dolor, in odio natoque dolor eget ridiculus, eget quisque quis integer dolor, amet enim, tempus mollis. Dui per, amet quo nulla nisl ligula fusce. Feugiat dui eget nulla ultricies, sem in tincidunt quam, non ac erat. Lacinia cum cursus, eget elit et litora nibh quis sed, diam eros ad sit cras nisl, et pellentesque tincidunt lorem vivamus. Ac tellus phasellus libero, tempor eu, pretium consectetuer quis, dolorum et proin et elit aenean vel.          \begin{charlesboxmaths}         (x^2 + y^2)^3 = \sin(x)\sin(y) + e^{2xy}     \end{charlesboxmaths}          Vel curae congue a risus sit neque, velit quisque ante in aliquam pulvinar, aliquam interdum id amet dapibus ligula ut, neque eget, nullam risus sapien. Sed sed urna posuere vestibulum. Class felis est sit. Augue turpis dolor molestie, viverra in imperdiet viverra tincidunt faucibus, convallis magna sit, vitae augue tempus in aliquet aliquam. Vel commodo libero quis quam odio. Quia semper vitae velit placerat, lectus amet diam, porta ante taciti per nec, eu hac platea, amet ac venenatis pede.          \end{document}


I have a problem with the command \chemleft[ of chemfig. Someone of you can help me please? ![enter image description here](http://i.stack.imgur.com/MAVuc.png)


title: Problem using \DeclareLabelalphaTemplate in Biblatex

text: I'm trying to customize my bibliography list. So, I decide to use Biblatex, I visited CTAN page and I tried to compile the code; and I have reported problems with `\DeclareLabelalphaTemplate`. I read the manual, and to use this command, it's mandatory to use Biber; I did. But I can't find the cause. I use XeLaTeX in Texpad software. The code is the same of the CTAN page, also the bib. file, I've just changed the file name. > ./Example.tex:13: Undefined control sequence.   >  l.13 \DeclareLabelalphaTemplate   >  {   >  ./Example.tex:14: Undefined control sequence.   >  l.14 \labelelement   >  { ./Example.tex:15: Undefined control sequence.   >  l.15 \field   >  [final]{shorthand} > > ./Example.tex:15: LaTeX Error: Missing \begin{document}. Thank you in advance for your helping.               \documentclass[a4paper]{article}     \usepackage[T1]{fontenc}     \usepackage[american]{babel}     \usepackage{csquotes}     \usepackage[backend=biber,style=alphabetic,backend=biber]{biblatex}     \usepackage{hyperref}     \addbibresource{Untitled.bib}          \DeclareLabelalphaTemplate{       \labelelement{         \field[final]{shorthand}         \field{label}         \field[strwidth=3,strside=left,ifnames=1]{labelname}         \field[strwidth=1,strside=left]{labelname}       }       \labelelement{         \field[strwidth=2,strside=right]{year}       }     }          \begin{document}     Filler text \parencite{morales}.     \printbibliography     \end{document}


title: Unit-free ratios in \path let

text: I want to compute pure ratios of distances in a `\path let` construction; for example, in the document fragment               \path let \p1 = (1cm, 2cm), \n1 = {\y1 / \x1} in ...      I would like `\n1` to be the number 2, not the string `2pt`, which is what TikZ actually writes because the computation involves a unit _somewhere_ , even though they cancel out. One bad solution is to write `\expandafter\strip@pt\n1` everywhere, but is there a way to signal to the PGF math engine that `\ifpgfmathunitsdeclared` (which controls this decision and is set somewhere inside `\pgfmathparse`) should be let to `\iffalse`? I'm imagining a construction like               \path let \p1 = (1cm, 2cm), \n1 = {nounits(\y1 / \x1)} in ...      or some other thing that can be placed inside the math expression itself.


title: How do I put loops at an angle in TikZ?

text: I'm trying to draw a graph in TikZ that has self-loops, and I'd like to be able to specify their position not only as "right" or "above", but something like "above right", i.e. at a 45° angle. How do I do that?


title: Which packages that apply fixes should one load by default?

text: # The problem Throughout the years I have come across several packages that fix issues in (La)TeX. It seems like it would be a good idea to load these by default. However, I could not find an authoritative list giving a qualified recommendation for which packages one should load. With this question, I would like you to fill that gap. # What to answer Please give a list that is as complete as possible. You could mention:   * Package name   * The problems it addresses   * In which context it should be used   * Possible caveats # A first start ### Core fixes Just for a head start, here are a few packages that I know of:   * `fixltx2e`     * _Problems addressed:_ Fixes some fundamental bugs in LaTeX that cannot be included in the core version because they could break backwards compatibility     * _Use in:_ Any LaTeX document     * _Caveats:_ Load `amsthm` before this package; load `footmisc` after this package    * `mparhack`     * _Problems addressed:_ Fixes a problem where marginpars sometimes appear on the wrong side     * _Use in:_ Any LaTeX document (that uses marginpars)     * _Caveats:_ ??? ### Fixes to document classes   * `scrhack`     * _Problems addressed:_ Fixes several conflicts with other packages     * _Use in:_ Any document written with KOMA script classes (scrartcl, _etc._ )     * _Caveats:_ ??? ### Math fixes   * `mathtools`     * _Problems addressed:_ Fixes several issues in `amsmath` and introduces new commands. Load instead of `amsmath`     * _Use in:_ Any document with mathematics     * _Caveats:_ ???   * `lualatex-math`     * _Problems addressed:_ Fixes some problems that can occur when typesetting mathematics with LuaLaTeX     * _Use in:_ Documents that contain mathematics and are compiled with LuaLaTeX     * _Caveats:_ ??? ### Fonts   * `fix-cm`     * _Problems addressed:_ Fixes issues with the original computer modern fonts     * _Use in:_ Documents use the old computer modern fonts     * _Caveats:_ Do not use in new files, use it only for compatibility. Use `lmodern` instead. ### Potentially helpful / best practices   * `nag`     * _Problems addressed:_ Gives warnings for bad practices     * _Use in:_ Any document     * _Caveats:_ Can annoy you if you use old commands


title: Can I make an xbar plot based on an external file?

text: I'd like to use the, imho, most common value alignment of x- and y-values in an external file and then produce an `xbar` with it. It shall look like the examples here (the better example because there are two values for each `ytick`) or here. Is that possible? I'd rather not enter the data for the coordinates myself. The MWE is based upon this post and does not work. ## MWE               \documentclass[     a4paper     ]{scrartcl}          \usepackage{         lmodern,         amsmath     }     \usepackage[T1]{fontenc}     \usepackage[utf8]{inputenc}          \usepackage{         tikz,         pgfplots         }          \begin{filecontents}{data.csv}     Subjects;Min;Max     Test01;0.5;7     Test02;-2;4     Test03;-1;6     Test04;0;3     Test05;2;4     Test06;1;7     \end{filecontents}          \listfiles          \begin{document}     Test.     \begin{center}     \centering     \begin{tikzpicture}     \begin{axis}[     %     xbar,     xlabel={aaaa values},     ylabel={Subjects},     ytick=data,     nodes near coords, nodes near coords align={horizontal},     %yticklabels from table={data.csv}{Subjects},     %symbolic y coords={Test01,Test02,Test03,Test04,Test05,Test06}     ]     \addplot table [x index=1, y index=0, col sep=semicolon] {data.csv};     \end{axis}     \end{tikzpicture}     \end{center}          \end{document}      ## MWE 2 for aligning bars & labels This MWE is there to show that the alignment of the x-labels and bars is off.               \documentclass[     a4paper     ]{scrartcl}          \usepackage{         lmodern,         amsmath     }     \usepackage[T1]{fontenc}     \usepackage[utf8]{inputenc}          \usepackage{         tikz,         pgfplots         }          \begin{filecontents}{data.csv}     Subjects;Min;Max     Test01;0.5;7     Test02;-2;4     Test03;-1;6     Test04;0;3     Test05;2;4     Test06;1;7     \end{filecontents}          \pgfplotstableread[col sep=semicolon]{     Subjects;Min;Max     Test01;0.5;7     Test02;-2;4     Test03;-1;6     Test04;0;3     Test05;2;4     Test06;1;7     }\tableabcdef          \begin{document}     Test.     \begin{center}     \centering     \begin{tikzpicture}     \begin{axis}[     xbar,     xlabel={aaaa values},     xmin=0,     %ytick=data,     nodes near coords, nodes near coords align={horizontal},     yticklabels from table={\tableabcdef}{Subjects},     ]     %\addplot table [meta=Subjects, x=Min] {\tableabcdef};     \addplot table [meta=Subjects, x=Max] {\tableabcdef};     \end{axis}     \end{tikzpicture}     \end{center}          \end{document}      ## Picture for MWE 2 ![enter image description here](http://i.stack.imgur.com/MJIuR.png)


title: Overfull hbox on a tiny equation?

text: My microscopic equation is 2.8 points too wide for some reason, which is quite a lot. I am reluctant to ignore the warning because if I get more of them I'll start missing important things. Code is:               Applying Snell's law (Equation \eqref{eq:snell}) twice gives us:     \begin{align}         \theta_2 &= arcsin \left( \frac{n_{vacuum}}{n_{mylar}} sin(\theta_1) \right) \\         \theta_1 &= arcsin \left( \frac{n_{mylar}}{n_{vacuum}} sin(\theta_0) \right)     \end{align}     which simplifies to     \begin{equation}         \theta_2 = \theta_0     \end{equation}     We saw earlier that there was a critical angle [blah blah more text...]      And the warning is:               Overfull \hbox (2.80157pt too wide) (page 6)      on line 226, which is the line containing the tiny `\theta_2 = \theta_0`. I'm probably missing something relatively obvious but I just can't see it. Any idea ?


title: Latino Elongated, XeTeX and small capitals

text: I'm using the Latino Elongated LET font with XeTeX and I can't get small capitals to display:               \documentclass{scrbook}          \usepackage{fontspec}     \newfontfamily\lelong{Latino Elongated LET}     \newfontfamily\lelongsc[SmallCapsFeatures={Letters=SmallCaps}]{Latino Elongated LET}          \begin{document}          \lelong \scshape Small capitals          \lelongsc \scshape Small capitals          \newfontinstance\scshape[Letters=SmallCaps]{Latino Elongated LET}          \lelong \scshape Small capitals          \end{document}      gives me three lines with normal characters: ![small caps failure](http://i.stack.imgur.com/l5ir6.png) How can I get small capitals? It is possible that this font is lacking sc functionalities? **Note:** The third attempt (`\newfontinstance`) gives a warning in the logs: > Package fontspec Warning: OpenType feature 'Letters=SmallCaps' (+smcp) not > available for font "Latino Elongated LET Plain:1.0/ICU" at 10.95pt, with > script 'Latin', and language 'Default'.


title: Using brackets as delimiters for matrix in TikZ-PGF Matrix Library

text: The TikZ-PGF manual is clear that for the matrix library, the delimiters are parentheses and braces: > Delimiters are parentheses or braces to the left and right of a formula or a > matrix. I would like to use brackets as delimiters for a matrix of math nodes. I have tried `\left[` and `\right]` but they do not work. Is there any way to get brackets as delimiters for a matrix of math nodes? Thanks.