title: How to customize vertical distance in 'underlying'

text: This seems to be a dummy one but I haven't found anything that works good for me. I'm working in an article and I need to get an underlined expression, like this ![enter image description here](http://i.stack.imgur.com/Iy1Dc.jpg) I mean REALLY CLOSE, but, so far, the available options such as `\underlying{x}` or `\underset{_}{x}` haven't worked so good because it left a huge vertical space. I need it to be real close of `x`. Any ideas? Thanks in advance.


title: How to insert images in a table's colum?

text: I want to display my testing on some images. And i want to display it in the table. so the table has 3 column. first : number 2nd: image 3rd:sentence                 \begin{table}[!h]       \centering       \caption{Properties} \begin{tabular}{|c|c|c|}     \hline         1. & \begin{figure}[!h]         \begin{center}         \includegraphics[width=3.5cm, height=3.5cm]{EPS_Thesis_Farhat/Plat_sukses/B5IB.eps}          \end{center}         \end{figure} & sentence\tabularnewline         \hline        \end{tabular}     \label{Properties in Regionprops}         \end{table}      How to do it??


title: Drawing a hyperbolic trajectory

text: In Drawing the Celestial Sphere with Tikz Package, they use `pspicture`. Is there a way to use `pspicture` inside of `tikz`? I want to have a hyberbola pass by the Earth with a periapsis of 500km (scaled to the paper of course).               \documentclass{article}     \usepackage{pst-map3d, tikz, pgf}     \begin{document}          \begin{center}       \begin{tikzpicture}         \pgfmathsetmacro{\e}{1.44022}         \pgfmathsetmacro{\a}{1}         \pgfmathsetmacro{\b}{\a*sqrt((\e)^2 - 1)}         \draw plot[domain = -2:2] ({\a*cosh(\x)}, {\b*sinh(\x)});         \begin{pspicture}(-4,-4)(4,4)           \psset{RotX = -23, RotZ = 30, PHI = 46.5833, THETA = 0.3333,                  visibility = false, Decran = 15,                  path                  = /usr/local/texlive/2012/texmf-dist/tex/generic/pst-geo/data}           \WorldMapThreeD[circles = false, blueEarth = false]           \WorldMapThreeD[circles = false, visibility = true, opacity = 0.7]           \psmeridien[visibility = true]{13.33}           \psparallel[visibility = true]{52.51}           \mapputIIID(13.33,52.51){Berlin}           \psparallel[visibility = true]{0}         \end{pspicture}       \end{tikzpicture}     \end{center}     \end{document}


title: Changing the baselineskip in marginpar

text: I’m adding explanations for definitions in the margin paragraph. I have a macro which looks as follows (simplified):               \newcommand*\define[2]{%       \marginpar{{\sffamily\footnotesize\textbf{#1}: #2}}}      This works fine, but unfortunately it uses the baseline skip from the main text, which is of course much too large for the footnote-sized font. So I tried changing the inter-line spacing, but to no avail. These are the two alternatives that I have tried:   1. Using `\fontsize` instead of `\footnotesize`:              \marginpar{{\sffamily\fontsize{8}{8}\selectfont\textbf{#1}: #2}}        2. Setting `\baselineskip`:              \marginpar{{%       \sffamily\footnotesize%       \setlength\baselineskip{1ex}%       \textbf{#1}: #2}}      Neither variant works (and I’ve tried other values: the inter-line spacing won’t budge). So here’s my question: **How do I re-assign the baseline skip for margin paragraphs?**


title: Avoiding placing `,\,` everywhere in mathmode

text: Whenever I write ", " (with a space after the comma) in mathmode, I _really_ want a space there. usually, this is either something like > the points, $a, b$, and $c$.... or in an explicit vector: > Let the vector $x=(x_1, x_2, x_3)$ be... Since TeX removes this space, my text is often riddled with explicit short spaces: `$x_1,\,x_2,\,x_3)$`. Is there a way to tell TeX that this is not desirable or to hack TeX into submission?


title: Changing the default TeXlipse compiler to PDFLatex

text: I just installed TeXlipse, and want to make my `.tex`-file alongside my Java- code (in the same Java-project). Right now, I can compile, but only to `.dvi`, which I dislike because of the bad viewer. Is it possible to change the default extension to `.pdf`, for every project? I already tried to disable the `.dvi` and `.ps` compilers by removing their program file path, but then I'm getting the error:               Error: Builder (#0) for dvi output format has an invalid configuration: <project-name>.


title: Change the background color of a frame in Beamer

text: How can I change the background color of one frame in my Beamer document? I tried doing               \begin{frame}       \setbeamercolor{background canvas}{bg=violet}       % frame contents here     \end{frame}      but it seemed to have no effect. Anyone know what the problem is?


title: Add line before Begin algorithm 'Début'

text: This is a follow-up question to Option in the algorithm with Latex. This is my algorithm:                \usepackage{algorithm}      \usepackage{algorithmic}      \begin{document}      \begin{algorithm}[H]      \caption{My algo}      \begin{algorithmic}[1]      \Debut      \LState instruction 1      \LState instruction 2       \Fin      \end{algorithmic}      \end{algorithm}      \end{document}      ![enter image description here](http://i.stack.imgur.com/7xkUj.png) Please how can I add "Données" before "Début" ?


title: How to get rid of the page numbers on pdf pages?

text: I was writing up a cover letter for a company I am applying to and after writing the letter, when I scrolled to the bottom, for some reason the number that automatically appears to number the pdf pages did not look good to me in this case being that the letter is only a page long. What I was wondering was, are (or is) there any way possible to do away with the page numbers at the bottom of pdf file pages.


title: Creating Multiple Choice Questions Without using 'Exam' Class

text: I am working on a document with class `article` and I want to have multiple choice questions in it. Is this hard enough to do that I should change it to `exam` class? If not, how do I accomplish this? Any and all help is greatly appreciated!


title: Spacing around \text{} in mathmode

text: Inspired by this question, here's my mathmode spacing bugbear. I quite often have equations that look like this:               \begin{equation}       \text{If}\ B_1 \succeq B_2 \ \text{and}\ B_2 \succeq B_3 \ \text{then}\ B_1 \succeq B_3     \end{equation}      Now, you might notice that before and after each bit of `\text{...}` there is a "normal sized space". I can't imagine why I wouldn't want that space there, but I have to add it manually. Surely this should be the default behaviour of mathmode's text macro? Why isn't it, and how could I make it so?


title: Dashed down arrow

text: I am looking for a solution for **dashed down arrow**. Have already tried packages like `lucidabr` and `MnSymbol`, but these turn my whole stuff upside down, producing a lot errors like > " _Something is not ok in line XY_ ". I have also tried `\rotatebox` for `\dashrightarrow` (which is available in `ams`), and it just didn't do neither the rotation nor the placing.. I was thinking, maybe the best if I can produce it for myself. Any help?


title: Combine columns of a csv

text: I'm attempting to use `\pgfplotstabletypeset` but with no luck. I have a CSV file like the following:               Name, Age, stDev     Adam, 15, 3      When I output in this into my PDF, I would like the last two columns be combined such that I end up with `15 +/- 3`. I would also like to name that column Age.


title: Comma separator for \citet and semicolon separator for \citep (in the last reference with \citet)

text: I need an answer about this problem and many of the accepted solution herein (StackExchange) do not work for me! For example   1. A comma separator for \citet and a semicolon separator for \citep simultaneously?   2. natbib, hyperref and citation inside a float figure The `\citet` command doesn't changes to add commas when there are multiple references and LaTeX keeps adding semicolons.. If I have `\citet{Mark:2001a,John:2003a,Bob:2011b,Chris:2012a}` -> I would like to get Bob (2011), Chris (2012), Mark (2001) and John (2003) **Note, how LaTeX could add an and in the last reference as above - automatically?!** while if I have `\citep{Mark:2001a,John:2003a,Bob:2011b,Chris:2012a}` -> I would like to get (Bob, 2011; Chris, 2012; Mark, 2001; John, 2003) Thanks a ton for your answers!


title: Missing $ Error in aligned equations

text: I think here's the problematic code The series expansion of `$e^z$` is given by               \[ e^z = \displaystyle \sum^{\infty}_{n=0} \dfrac{z^n}{n!}\]      Then we can write the given function as               \begin*{align}     \frac{e^z - 1}{z^2} &= \frac{e^z}{z^2} - \frac{1}{z^2} \\                     &= \frac{1}{z^2} \left( 1 + z + \frac{z^2}{2!} + \frac{z^3}{3!} +    \cdots \right) + \frac{1}{z^2} \\                     &= \frac{z}{z^2} + \frac{1}{2} + \frac{z}{3!} + \frac{z^2}{4!} + \cdots \\                     &= \frac{1}{z} + \frac{1}{2} \frac{z}{3!} + \displaystyle                          \sum^{\infty}_{k=2} \frac{z^k}{(k+2)!}     \end*{align}      The error messages include `"! extra } or missing $" and "! Misplaced alignment tab character &"`. It's 3 AM here, so I apologize if I’ve missed a missing `$` or `{}` but I really don't see what the error is here. I have tried changing the formatting so that I delete all the white space but it doesn't seem to help either. Thank you


title: Formatting verse: How to change indent for all even lines?

text: Is it possible to format a verse like this: ![Example of desired formatiing](http://i.stack.imgur.com/kcoms.png) (sorry for an example that is not in English, I just don't have English text with such formatting on hand. ) I mean the following formatting: each even line of the verse has an indent, while odd lines haven't. I would like to make it automatically for the verses of different length, so that I don't need to manually change indent for each even line.


title: why are the overarrows too short and the sqrt missing its vinculum?

text: ![the not-quite-right results](http://i.stack.imgur.com/dtmze.png) I've been fighting with XeLaTeX (from a full TeX Live 2011 install on a linux box) for the past few hours and am finally almost at the result I want, but (as shown above) the overarrows aren't stretching to cover all the letters and the sqrt doesn't have its vinculum/overbar and I'm at a loss. What can I do to fix it?               \documentclass{article}     \usepackage{geometry}     \geometry{papersize={350pt,45pt},margin=0pt}          % no page numbers (and maybe other cleanness?)     \pagestyle{empty}          % don't hyphenate, don't indent     \hyphenpenalty=100000     \setlength{\parindent}{0mm}               % color     \usepackage{color}     \pagecolor{black}          % XeTeX fonts     \usepackage{unicode-math}     \usepackage{amsmath}     \usepackage{xltxtra}     \usepackage{sfmath}          \setmainfont[Mapping=tex-text]{Bera Sans}     \setmathfont{STIXGeneral}     \setmathfont[range=\mathup]{Bera Sans}     \setmathfont[range=\mathbfup]{Bera Sans Bold}     \setmathfont[range=\mathbfit]{Bera Sans Bold Oblique}     \setmathfont[range=\mathit]{Bera Sans Oblique}          \begin{document}\fontsize{9}{13}\selectfont\color{white}     This means that $\overleftrightarrow{AD}$ contains $F$  We write that as $3=\sqrt{9}$.  The \emph{square root} symbol is sometimes called a \emph{radical} symbol.     \end{document}


title: Use Nomenclature package twice for list of abbreviations and nomenclature. Win 7, miktex, Texmaker 3.5.2

text: I have a short question to ask: Is it possible to use the nomenclature environment twice in the same document? I want to use it once for Nomenclature and one for a list of abbreviations. So after I print the nomenclature once               \printnomenclature[2 cm]      I will use `\renewcommand{\nomname}{Abbreviations}` and then               \printnomenclature[2 cm]{Abbreviations}       will print the abbreviation list only? Thanks a lot, Vagelis


title: Beginner―Texmaker: generate HTML, MathML

text: I am very new to LaTeX and everything connected to it,but since I come from the HTML, I know what it means to use a markup language. I try to setup Texmaker that I can generate MathML and or HTML files, on the Homepage of Texmaker there is an image that shows a kind of wizard for this, but I cannot find it. I am working on ubuntu linux 12.04, I have `texlive-full` installed and I am searching for help to find the »export« button.


title: Force a caption to be on the same page as a figure

text: I'm using the `overpic` environment to include figures, and the `memoir` class to add captions. How do I force the caption to always stay on the same page as its corresponding figure? Below is my MWE. If the image is big enough, the caption appears on the following page.               \documentclass[11pt,a4paper]{memoir}          \usepackage{fouriernc} % use the Arev font     \usepackage{overpic} % use the overpic package          % caption images outside the figure environment     \newfixedcaption{\figcaption}{figure} \captionnamefont{\normalfont} \captiontitlefont{\normalfont}          \begin{document}          This is some text.          \begin{center}     \begin{overpic}[width=0.9\textwidth]{./myfig.pdf}     \put(10, 10){Here is text superimposed on the figure.}     \end{overpic}     \figcaption{I want this caption on the same page as the corresponding figure.}     \end{center}          \end{document}


title: How to shorten \hline in a matrix

text: I indicate blocks in a matrix using `\hline`:               \documentclass{article}     \usepackage{amsmath}     \begin{document}       \begin{equation*}         \begin{bmatrix}           a & b\\           \hline           c & d         \end{bmatrix}       \end{equation*}     \end{document}     \endinput      ![example image](http://i.stack.imgur.com/aJD2n.png) However, for normal point sizes the document is generated in (11pt), the rule drawn crosses over the matrix borders. (For poster sizes, this is not the case.) How can I shorten the rule on both sides so that this does not occur, while still preserving the vertical spacing provided by `\hline`?


title: Using a different font in overpic

text: I'm using the `overpic` package in the `memoir` class to include figures and superimpose text on them. Is there a simple way to tell overpic to use a different font than the main font of my text? (I still want the figure captions to be in the main font, though.) Here's a MWE:               \documentclass[11pt,a4paper]{memoir}          \usepackage{fouriernc} % use the Arev font     \usepackage{overpic} % use the overpic package          % caption images outside the figure environment     \newfixedcaption{\figcaption}{figure} \captionnamefont{\normalfont} \captiontitlefont{\normalfont}          \begin{document}          This is the font of my main text.          \begin{center}     \begin{overpic}[width=0.5\textwidth]{./myfig.pdf}     \put(10, 10){This should be a different font}     \end{overpic}     \figcaption{This should be the same font as my main text.}     \end{center}          \end{document}


title: New command doesn't work the same as in-line code

text: I have a feeling that this is a profoundly stupid question but I cannot seem to solve it myself. I am trying to write an own macro to create a boxed paragraph. The code works fine in-line but when I try to define the command it just creates a small box in the same place that I wrote the command. My codes are below. I am pretty much a complete newbie at this and any help would be greatly appreciated.               \fbox{\parbox{\linewidth}{Inline this works perfectly.}}          \newcommand{\note}{\fbox{\parbox{\linewidth}{}}}


title: Spacing and the use of \twoacc

text: When I use the `\twoacc` command it sometimes puts unwanted space before and after a phonetic symbol. This happens with, for example, with `[p\twoacc[\r|\tr{\textturnr}]p]`. The correct spacing occurs when I type `[p\tr{\textturnr}p]`. How do I get rid of the unwanted spacing?


title: How to align vertically a matrix on nodes in Tikz?

text: I have prepared a series of illustrated tables for a technical brochure, and I have finally elected to use the option "matrix of nodes" of Tikz. I could not manage however to center (on the same vertical center line) the large labels such as "40" or "40C1" with the graphics above. How to do this? Strangely, the bottom labels, such a s "40 contacts #20" are perfectly aligned.               \documentclass{article}     \usepackage[draft]{graphicx}      \usepackage{tikz}     \begin{document}     \centering     \begin{tikzpicture} [font=\sf,     mynode/.style={rectangle, text width = 4.5 cm, anchor=north, inner sep=0pt},     myheader/.style={rectangle, fill, color=blue!20, text width = 4.55cm, text=black, text centered, font={\Huge, \sf}, inner sep=5pt},     mylabel/.style={rectangle, fill, minimum height=10ex, color=black!10, text=black, text width = 4.55 cm, anchor=north, inner sep=5pt},     ]     \matrix [column sep=0pt , row sep=0mm, align=center, draw, rectangle]     {     \node {\includegraphics[width=0.3\textwidth]{40Insert.pdf}}; &     \node {\includegraphics[width=0.3\textwidth]{40C1Inser.pdf}};     &\node {\includegraphics[width=0.3\textwidth]{45Insert.pdf}}; \\     \node [myheader]{40};&\node [myheader]{40C1};&\node [myheader]{45}; \\     \node [mylabel] {40 contacts \#20 };     &\node [mylabel] {39 contacts \#20 \\ 1 coax or triax contact \#5 \\ or 1 contact \#10};     &\node [mylabel] {45 contacts \#20};\\     \node [mynode] {};& \node [mynode]{}; &\node [mynode]{};\\          \node [mynode] {};& \node [mynode]{}; &\node [mynode]{};\\     };     \end{tikzpicture}     \end {document}


title: TikZ: positioning label at the end of a path

text: I'm trying in TikZ to find a general way to draw an arrow and label it at the end. Something like this works reasonably well:               \draw[->] (0, 0) -- (1, 3) node[pos=1.1]{$\vec{v}$};      However, depending on the orientation, if the label is too long, then the label can overlap the arrow:               \draw[->] (0, 0) -- (3, 0) node[pos=1.1]{$\vec{v} + \vec{w}$};      What I would ideally like is, for the latter arrow, the left side is at pos=1.1. I know I can do this in this specific case by using `node[pos=1.1, anchor=west]`, but I'm looking for something more general (so that I could abstract this all and define a command to do it automatically). One approach I considered was trying to find the width and height of the label and move the label using those values. So, 2 questions: Is there a way to find the width/height? Or, alternatively, is there a better approach?


title: Different marker at specific intervals using pgfplots

text: I have a number of large data files with x rows in the range of 0 to z. Is there an easy way to set a different marker at specific intervals using `pgfplots`/`TikZ`? How can I produce a figure such that the marker for the plot at intervals 0, 10, 20, ..., z is for example a cross but a circle for the rest of the points? Here's a MWE that can get you started:               \documentclass{article}          \usepackage{tikz,pgfplots}     \pgfplotsset{compat=1.8}          \begin{filecontents*}{thePlot.dat}     x y     0 20.44     1 20.06     2 19.76     3 19.54     4 19.40     5 19.34     6 19.36     7 19.46     8 19.64     9 19.90     10  20.24     \end{filecontents*}          \begin{document}       \begin{figure}[]         \centering         \begin{tikzpicture}           \begin{axis}[             xlabel={$x$},             ylabel={$y$},]                  \addplot+[only marks,mark=x]               table[x=x,y=y] {thePlot.dat};           \end{axis}         \end{tikzpicture}%         \caption{The caption.}       \end{figure}     \end{document}


title: Temporarily undefining a "starred" command

text: I would like to temporarily undefine a command. The reason for this is that I need to use a specific class file which defines the equation* using \@namedef and I would also really like to use the amsmath package as it in particular defines the align environment, but it also defines the equation* environment, so this leads to an error at compilation. I have found how to temporarily disable a command without a star, i.e. by doing               \makeatletter     \let\oldequation\equation     \let\equation\@undefined     \makeatother      and then loading the amsmath package. This doesn't work for equation* for reasons I don't quite understand, but apparently * at the end starts a new lexeme. So how would I achieve a similar result for equation*? The class and style files are not under my control.


title: Equation errors - I want to use units in the equation

text: I´m trying to get some simple equations into my document. However it seems my used units are not equation friendly.               \documentclass[a4paper,DIV10,12pt,headsepline,headings=small]{scrreprt}     \usepackage{lmodern}     %\usepackage[ngerman]{babel}     \usepackage[english]{babel}     \usepackage{cite}     \usepackage[margin=10pt,font=small,labelfont=bf,     labelsep=endash,singlelinecheck=off]{caption}     \usepackage{longtable}      \usepackage{threeparttable}     \usepackage{booktabs}     \usepackage{graphicx}      \usepackage{float}     \usepackage{parskip}     \usepackage{setspace}     \usepackage{graphicx}     \onehalfspacing     \pagestyle{headings}     \setcounter{secnumdepth}{3}      \setcounter{tocdepth}{3}     \usepackage{tocloft}     \usepackage{ragged2e}     \usepackage{array}      \usepackage{amsmath}     \usepackage {picins}          \begin{gather}     Thickness&=\frac{100 $\mu$g/$\mathrm{cm}^{2}$}{8.38 $\mu$g/$\mathrm{cm}^{3}$} \\[1ex]     Thickness&=0.199 $\mu$m     \end{gather}      The equation should give me something like: Thickness = (100 µg/cm²) / (8.38 µg /cm³) [without brackets of course] It seems that my unit definitions are not working properly in equations. There is no problem while using them in a normal text. I really appreciate any hints! (hope I used the correct tags)


title: Reducing space between backreference and entry in bibliography

text: is it possible to reduce the space between "page" and the bibliography entry? A negative vspace is to unreliable. Answer: `\hfill` does the trick ![enter image description here](http://i.stack.imgur.com/k2lRK.png)               \documentclass[12pt]{report}     \usepackage{fontspec}     \usepackage{xunicode}     \usepackage{xltxtra}     \usepackage[english]{babel}     \usepackage[round]{natbib}     \usepackage{nohyperref}     \usepackage[pageref]{backref}          \renewcommand*{\backref}[1]{}     \renewcommand*{\backrefalt}[4]{         \ifcase #1 (Not cited.)         \or         \hfill(page~#2.)         \else   \\(pages~#2.)%        \fi     }          \bibliographystyle{plainnat}          \begin{document}          \citep{brown1960}          \bibliography{sources}          \end{document}      sources.bib               @incollection{brown1960,       title={The Pronouns of Power and Solidarity},       author={Brown, Roger and Gilman, Albert},       booktitle={Style in Language},       editor={Sebeok, Thomas A.},       pages={253–76},       publisher={MIT Press},       address={Cambridge},       year={1960}     }


title: Get the same numbering to the right of each equations in two different ''alignes"

text: I want to use this code               \begin{align}     & \cos(90^\circ-v) = \sin(v)\\ & \sin(90^\circ-v) = \cos(v).     \end{align}      ....twice, and have the same numbering of the equations appear to the right of in both ''aligned''. Now, when i put down this code one more time in the same document i get numbering (3) and (4), But I want it to be (1) and (2) as in the first ''align''.


title: PNG and JPG quality loss inserting webpage screenshot into LaTeX document

text: I have tried using both a png and jpg file format for my images but I still loose a significant amount of quality when I run pdflatex. Is there some way to work around this?               \documentclass[12pt, a4paper, twoside]{article}     \usepackage[margin=1in,bindingoffset=15.5mm,heightrounded]{geometry}     \usepackage[T1]{fontenc}     \usepackage{graphicx}     \begin{document}     I have some text here.  Then pics.     \newpage     \begin{figure}[ht!]     \centering     \includegraphics[scale=0.75, angle=90, width=\textwidth]{hamlet.jpg}     \caption{cool picture}     \end{figure}     \newpage     \begin{figure}[ht!]     \centering     \includegraphics[scale=0.75, angle=270, width=\textwidth]{kinglear.jpg}     \caption{cool picture 2}     \end{figure}     \newpage     some more text here     \end{document}      Here is my png image ![king lear png](http://i.stack.imgur.com/qQdwE.jpg) and here is the output of my pdflatex run (the rotation is intentional in the pdf) ![king lear pdf](http://i.stack.imgur.com/4XeAh.png)


title: How to change the \fboxsep and \fboxrule of LTXexample's rframe?

text: The formatted output is enclosed by `rframe`. But for a certain case, the grid label of `pspicture` goes beyond the frame. The grid label of `pspicture` might be rendered outside TeX engine so TeX does not know the exact dimension for it. Shortly speaking, how to enlarge `\fboxsep` for `rframe`? Bonus: Also let me know how to change its `\fboxrule`. ![enter image description here](http://i.stack.imgur.com/qHg7V.png)               \documentclass{article}     \usepackage[paperwidth=13cm,paperheight=8cm,margin=0.5cm]{geometry}     \pagestyle{empty}     \usepackage{accsupp}     \newcommand*{\noaccsupp}[1]{\BeginAccSupp{ActualText={}}#1\EndAccSupp{}}          \usepackage{xcolor}               \usepackage{showexpl}     \makeatletter          % Add [t] to the parbox     \renewcommand\SX@CodeArea[2]{%        \parbox[t]{#1}{#2}        \rlap{\parbox[t]{#1}{\SX@attachfile}}}          % Add [t] to the parbox     \renewcommand\SX@ResultArea[2]{%       \SX@justification%       \parbox[t]{#1}{#2}%     }          % Add \hbox{} at the creation of \SX@ResBox, look up the comment     \renewcommand*\SX@put@code@result{%       \begingroup         \expandafter\lstset\expandafter{\SX@explpreset}%         \let\lst@float=\relax\let\SX@float=\relax         \expandafter\lstset\expandafter{\SX@@explpreset}%         \ifx\lst@float\relax\else           \let\SX@float=\lst@float\let\lst@float=\relax           \g@addto@macro\SX@@explpreset{,float=false}%           \edef\@tempa{\noexpand\lst@beginfloat{lstlisting}[\SX@float]}%           \expandafter\@tempa         \fi         \ifx\lst@caption\@empty           \lstset{nolol=true}%         \fi         \if@SX@wide\def\SX@overhang{\marginparwidth+\marginparsep}\fi         \trivlist\item\relax           \stepcounter{ltxexample}\label{\SX@IDENT}%           \SX@defaultWD\SX@width{\SX@width}%           \ifdim\SX@width<\z@             \@tempswatrue             \def\@tempa{t}%             \ifx\@tempa\SX@pos\@tempswafalse\fi             \def\@tempa{b}%             \ifx\@tempa\SX@pos\@tempswafalse\fi             \setlength\@tempdima{\linewidth+\SX@overhang}%             \if@tempswa\@tempdima=.5\@tempdima\fi%             \edef\SX@width{\the\@tempdima}%           \fi           \ifx\SX@rframe\@empty             \long\def\SX@frame##1{##1}%           \else             \let\SX@frame\fbox             \setlength\@tempdima{\SX@width-2\fboxsep-2\fboxrule}%             \edef\SX@width{\the\@tempdima}%           \fi           \isSX@odd{\def\@tempa{l}}{\def\@tempa{r}}%           \makebox[\linewidth][\@tempa]{%             \parbox{\linewidth+\SX@overhang}{%               \let\@addtofilelist\@gobble               \let\lst@ifdisplaystyle=\iftrue               \SX@KillAboveCaptionskip\lst@MakeCaption{t}%               \lst@belowskip=\z@               \let\SX@MakeCaption\lst@MakeCaption               \let\lst@MakeCaption\@gobble               \setbox\SX@ResBox\vtop{\hbox{}\hbox{%    <---- HERE, modified line                 \SX@frame{%                   \@nameuse{\if@SX@varwidth varwidth\else minipage\fi}%                     \SX@width\relax\SX@resultInput%                     \@nameuse{end\if@SX@varwidth varwidth\else minipage\fi}}}}% <-- Also here, to close a brace               \edef\SX@width{\the\wd\SX@ResBox}%               \@ifundefined{SX@put@\SX@pos}%                 {\@latex@error{Parameter `\SX@pos' undefined}\@ehd}%               {\@nameuse{SX@put@\SX@pos}%                 {\SX@width}{\box\SX@ResBox}{\SX@codeInput}}%               \let\lst@MakeCaption\SX@MakeCaption               \lst@MakeCaption{b}\SX@KillBelowCaptionskip             }%           }%         \endtrivlist         \ifx\SX@float\relax\else\expandafter\lst@endfloat\fi         \gdef\SX@@explpreset{}%       \endgroup     }     \makeatother          \lstset     {         language={[LaTeX]TeX},         alsolanguage={PSTricks},         numbers=left,         numbersep=1em,         numberstyle=\tiny\color{red}\noaccsupp,         frame=single,         framesep=\fboxsep,         framerule=\fboxrule,         rulecolor=\color{red},         xleftmargin=\dimexpr\fboxsep+\fboxrule\relax,         xrightmargin=\dimexpr\fboxsep+\fboxrule\relax,         breaklines=true,         basicstyle=\scriptsize\ttfamily\null,% <--- Add \hbox{} here too         keywordstyle=\color{blue},         %identifierstyle=\color{magenta},         commentstyle=\color[rgb]{0.13,0.54,0.13},         backgroundcolor=\color{yellow!10},         tabsize=2,         columns=flexible,         explpreset={pos=r,hsep=2\fboxsep,preset=\centering},         morekeywords={             graphicspath,             includegraphics,         },         ,        }          \usepackage{pstricks}          \begin{document}          \LTXexample     \begin{pspicture}[showgrid](5,5)          \end{pspicture}     \endLTXexample          \end{document}      If we can change `rframe`'s `\fboxsep=12pt`, for example, we can have an output as follows: ![enter image description here](http://i.stack.imgur.com/rzHip.png)


title: TeX Live 2013 throwing up errors when using updmap and fmutil

text: I run TeX Live 2013 on Win 7(x64) and was doing fine with updates and everything until today. I went for another update, when suddenly the following error message popped up when the updater tried to run `updmap-sys`:               The program can't start because runscript.dll is missing from your computer. Try reinstalling the program to fix this problem.      The same happened with `fmtutil-sys`. So I did a reinstall of the whole distribution and the same error occurred during the install. Same error message and all after the installation tried to run `updmap-sys`. So I am asking myself, what I can do and what is going on. Can someone help me out?


title: firstname lastname for additional authors in BibTeX

text: I am still struggling with the de gruyter citation style. I know that I can produce one from scratch with `tex makebst`, but I have one that is almost working and I had to make a lot of funny changes, which I had to redo on the automatically created file. The editors require me to have > Meier, Max and Klaus Meier 2009 My first paper ...               \documentclass{article}          \usepackage{natbib}          \usepackage{filecontents}          \begin{filecontents}{SM.bib}       @article{a,         author={Max Meier and Klaus Meier},         title={My first paper},         journal={Journal of Googelology},         volume=3123,         number=1,         pages={3--45},         year=2009}     \end{filecontents}          \begin{document}          \nocite{*}          \bibliographystyle{degruyter-hsk}      \bibliography{SM}          \end{document}      I know it is format.names, but how do I do it? De Gruyter `.bst` is here: degruyter-hsk.bst


title: pdflatex embed font names

text: I have been using some embedded fonts (AMS, Times) in my PDF document. Last time when I browsed the document in PDF Viewer (Evince, in that particular case) I noticed that most of embedded fonts were marked as _"Noname"_ in the _"Document properties"_ dialog. Although it doesn't bring any problems with browsing and printing, I wonder if there is a way to tell `pdfLatex` to include embedded fonts real names? ![Properties Window](http://i.stack.imgur.com/oOSqV.png)


title: Does writing to a property list take longer than writing to a token list?

text: In the question Write a column selectively to the appropriate row using pgfplotstable? I offered the following:               \documentclass{article}          \usepackage{xparse}     \usepackage{booktabs}     \usepackage{longtable}     \usepackage{filecontents}          \begin{filecontents*}{namespgfa.csv}     5501,Kathirvelu A     5502,Gugan K     5503,Kalaitchelvi S     5504,Suresh S     5505,Mahesh K     \end{filecontents*}     %     \begin{filecontents*}{markspgfa.csv}     5501,67     5502,25     5503,62     5505,95     \end{filecontents*}          \ExplSyntaxOn     \tl_new:N \g_tab_rows_tl     \ior_new:N \g_names_ior     \ior_new:N \g_marks_ior     \prop_new:N \g_names_prop          \ior_open:Nn \g_names_ior {namespgfa.csv}     \ior_open:Nn \g_marks_ior {markspgfa.csv}          \cs_new:Npn \set_name_keys:w #1,#2\q_stop         {             \prop_put:Nnn \g_names_prop {#1} {#2}         }          \cs_new:Npn \tab_write_keys:w #1,#2\q_stop          {             \prop_gpop:NnN \g_names_prop {#1} \l_tmpa_tl              \tl_gput_right:Nn \g_tab_rows_tl {#1&}              \tl_gput_right:NV \g_tab_rows_tl \l_tmpa_tl             \tl_gput_right:Nn \g_tab_rows_tl {&#2\\}          }     %replacing the above two control sequences with the following slows compilation substantially     %\cs_new:Npn \set_name_keys:w #1,#2\q_stop     %   {     %        \prop_put:Nnn \g_names_prop {#1} {#1&#2&}     %   }     %     %\cs_new:Npn \tab_write_keys:w #1,#2\q_stop     %    {     %        \prop_gpop:NnN \g_names_prop {#1} \l_tmpa_tl     %        \tl_gput_right:NV \g_tab_rows_tl \l_tmpa_tl     %        \tl_gput_right:Nn \g_tab_rows_tl {#2\\}     %    }          \ior_str_map_inline:Nn \g_names_ior         {             \set_name_keys:w #1\q_stop         }          \ior_str_map_inline:Nn \g_marks_ior         {             \tab_write_keys:w #1\q_stop         }          \ior_close:N \g_names_ior     \ior_close:N \g_marks_ior          \NewDocumentCommand { \WriteRows } {}         {             \tl_use:N \g_tab_rows_tl         }          \ExplSyntaxOff          \begin{document}          \begin{longtable}{clc}     Reg.No.&Name&Marks\\     \toprule     \WriteRows     \bottomrule     \end{longtable}          \end{document}      **Background:** The first column of both `namespgfa.csv` and `markspgfa.csv` contains id numbers, while the second column contains a corresponding name and mark respectively. The idea was very basic: associate each id with a name, and insert that name between the corresponding id and mark in a table. Since speed was an issue, I thought that the commented changes in the above code might speed things up. My thinking was that on for `.csv` with `n` lines, `\set_name_keys:w` will get called `n` times regardless, therefore using that cs to write some extra information would save `~n` calls to `\tl_gput_right:Nn \g_tab_rows_tl {#1&}`. However, on test `.csv's` with 4000 lines, the second method took ~30s while the first took ~25. **My question is: why is there such a substantial difference in compile times?** Here are the test files I used:   1. markspgf http://www.smallfiles.org/download/1451/markspgf.csv.html   2. namespgf http://www.smallfiles.org/download/1452/namespgf.csv.html To use these, remove the "a" from the filenames in `\ior_open:Nn \g_names_ior {namespgfa.csv}` and `\ior_open:Nn \g_marks_ior {markspgfa.csv}`.


title: Subtables using r+hmisc

text: I'm not absolutly sure if it is the right place to ask my question. I use R+knitr to produce a weekly report(s) from a large database. For my tables I find very convenient to use hmisc's `latex` command. I would like to know if it is possible to arrange two tables side by side using the `latex` function from `hmisc`. I understand the LaTeX commands to do it, but the issue is that `hmisc` creates those commands.


title: Using beamer frame title in document text

text: I use `beamer` to create a set of slides that are used to present the contents of a document. Both the slides and the printable document contents are contained in a single set of source files; I use the `\mode` commands to switch between presentation and printout mode. In contrast to some of the `beamer` examples I have seen so far, the printable version does not contain the complete slides as images. The slides and the printable version share some graphics and other contents, and I use a `\marginpar` to create a kind of link between the slides and the printable version, just to let the audience keep track. Here is a MWE, consisting of three files:               % === printable.tex =======================================     \documentclass{scrartcl}     \usepackage{beamerarticle}          \begin{document}     \input{contents}     \end{document}     % === end of printable.tex ================================          % === slides.tex ==========================================     \documentclass{beamer}          \begin{document}     \input{contents}     \end{document}     % === end of slides.tex ===================================          % === contents.tex =======================================     \mode*          Lorem ipsum dolor sit amet, consectetur adipiscing elit.      Fusce laoreet dui vestibulum tortor luctus porttitor.      Aliquam dictum ipsum condimentum, auctor augue in,      consectetur lacus. Morbi auctor posuere scelerisque.     Aenean vel enim sit met orci rutrum fermentum faucibus et      mauris. Pellentesque tempor felis in imperdiet accumsan.     Mauris auctor pretium nulla et tincidunt.          \mode<presentation>     \begin{frame}       \frametitle{Foo Bar}       \begin{itemize}         \item Foo         \item Bar         \item Baz       \end{itemize}     \end{frame}     \mode*          Mauris\marginpar{Foo Bar} malesuada nisl sit amet nisl      eleifend tincidunt. Sed sed libero scelerisque, ultrices      elit a, lacinia mi. Mauris nec semper metus, eget      pellentesque leo. Donec volutpat aliquam aliquam. Nunc      vel neque scelerisque, aliquam augue eget, gravida felis.      Suspendisse vel molestie libero.           % === end of contents.tex =================================      As you can see, I have to manually repeat the frame title `Foo Bar` in the `\marginpar`. I tend to forget to do that, and I especially tend to forget to update the repetition when the title changes. Is there a way to specify the title only once and use it for the `\frametitle` as well for the `\marginpar`?


title: Problem inserting picture into latex/pdflatex using figure environment

text: I am having trouble inserting pictures into my latex document at a specific point. Currently I have the two figure environments in the text but they are printed at the back of the document, after the bibliography. Am I missing something? The pictures are both supposed to be full page-sized rather than a traditional smaller figure or float. I might be wrong in using the figure environment in this case, but I am not sure.               \documentclass[12pt, a4paper, twoside]{article}     \usepackage[margin=1in,bindingoffset=15.5mm,heightrounded]{geometry}     \usepackage[T1]{fontenc}     \usepackage{graphicx}     \begin{document}     I have some text here.  Then pics.     \newpage     \begin{figure}[ht!]     \centering     \includegraphics[scale=0.75, angle=90, width=\textwidth]{hamlet.jpg}     \caption{cool picture}     \end{figure}     \newpage     \begin{figure}[ht!]     \centering     \includegraphics[scale=0.75, angle=270, width=\textwidth]{kinglear.jpg}     \caption{cool picture 2}     \end{figure}     \newpage     some more text here     \end{document}


title: Too many lines on the page and too many characters in the lines

text: I have converted a word document to Tex using Word2Tex. With the tex document in 12 point, the corresponding pdf document has 38 lines on each page, and about 77 characters per line. However, I would prefer it if there were fewer lines on each page and fewer characters in each line. How can I achieve this?


title: Distiller-option in TeXShop: Ghostscript vs. Apple

text: Today I noticed that in the last panel of the TeXShop options I can choose between `Ghostscript` and `Apple Distiller` as the "Distiller" of my Document. ![enter image description here](http://i.stack.imgur.com/xfb8L.png) Any pros and cons for these alternatives? Is there any difference in quality, font embedding, file-size, available and supported PDF-features, microtype stuff, etc.? I am using the `lualatexmk` engine. Is this engine already deciding for me, i.e., would it change anything at all if I edit the options of TeXShop?


title: Theorem starting with a list

text: I want a robust way to handle theorems which starts by a list environment, with the first item being on a new line. I don't want to distinguish between theorems with lists and those without by using different theorem styles. I don't want any page break between the theorem head and the first item of the list. This topic has been dealt with many times already, for example:   * Is it possible to skip the first line in a theorem environment?   * Enumerate alignment problem in theorem environment   * amsthm: \newtheoremstyle, headspace, \mbox{}, and lists   * Page-breaking over titles of theorems that have lists These lead me to test the following fixes with amsthm:               \documentclass{article}     \usepackage{lipsum}     \usepackage{amsthm}          \theoremstyle{plain}      \newtheorem{theorem}{Theorem}[section]           \title{Theorem lists test}     \begin{document}     \maketitle     \section{test}          \lipsum[1-3]          \vspace{1cm}          \begin{theorem}\leavevmode     \begin{enumerate}     \item first     \item second.     \end{enumerate}     \end{theorem}          \end{document}      or               \documentclass{article}          \usepackage{lipsum}     \usepackage{amsthm}     \theoremstyle{plain}          \newtheorem{theorem}{Theorem}[section]           \makeatletter     \def\enumfix{%     \if@inlabel      \noindent \par\nobreak\vskip-\parskip\vskip-\parskip\hrule\@height\z@     \fi}     \let\oldenumerate\enumerate     \def\enumerate{\enumfix\oldenumerate}          \title{Theorem lists test}     \begin{document}     \maketitle     \section{test}          \lipsum[1-3]     \vspace{1cm}          \begin{theorem}\label{mythm}     \begin{enumerate}     \item first     \item second.     \end{enumerate}     \end{theorem}          \end{document}      All these MWEs yields the same disappointing result, namely the page break right after the theorem header. Moreover, I don't find the solution using Needspace in the spirit of the theorem environment. Of course the \hfill command in place of \leavevmode yields the same result. I observed the same behaviour using the ntheorem package. Any idea?


title: Wrapfigs adds delta's to intertext

text: I'm trying to use a wrapfig in my text an paragraph before an align*-envirement but by doing so, my intertexts all get a delta-sign. Here's my code:               \documentclass{report}          \usepackage[dutch]{babel}     \usepackage{amsmath}     \usepackage{graphicx}     \usepackage{wrapfig}     \usepackage{textcomp}     \usepackage{xspace}     \usepackage{parskip}     \usepackage{tabu}          \begin{align*}         W & = F \, d\\          \Delta W & = q\vec{E} \cdot \Delta\vec{s}\\     \end{align*}               \begin{wrapfigure}{r}{0.69\linewidth}     \begin{center}     \includegraphics[width=0.68\linewidth]{../Foto's/Ele1.jpg}     \caption{Potentiaal en arbeid}     \label{potarb}     \end{center}     \end{wrapfigure}          Splits de veldsterkte in zijn componenten. Bedenk dat de component loodrecht op de verplaatsing geen arbeid uitvoert. Verduidelijking in figuur \ref{potarb}.          \begin{align*}     \Delta W & = q\vec{E_1} \cdot \Delta\vec{s} \\     & = qE_1 \Delta s \cos\alpha     \intertext{Daarna gaan we over naar de volledige tekening bij \ref{potarb}. Hierbij willen we berekenen welke arbeid wordt geleverd tussen A en B.}     W^{\textsc{b}}_{\textsc{a}}     &= \sum^{B}_A \Delta W\\     &= q \sum^B_A \vec{E_1} \cdot \Delta s\\     &= q \lim_{\Delta s \to 0} \sum^B_A \vec{E} \cdot \Delta s\\     &= q \int_A^B \vec{E} \cdot \, \vec{ds}\\     &= q \int_A^B \frac{Q \cos \alpha}{4 \pi \varepsilon r^2} \, ds\\     \intertext{We gaan over van ds naar dr. Zie figuur}     &= \frac{q Q}{4 \pi \varepsilon } \int_{r_a}^{r_b} \frac{1}{r^2} \, dr     \intertext{bedenk dat de integraal van een macht, \'e\'en over 'de nieuwe macht' maal de variabele tot de 'oude macht plus \'e\'en' wordt.}     & = \frac{q Q}{4 \pi \varepsilon } \left[-\frac{1}{r_b} - (-\frac{1}{r_a})\right]\\     &= \frac{q Q}{4 \pi \varepsilon } \left[\frac{1}{r_a} - \frac{1}{r_b}\right]\\     \intertext{ Per definitie is het potentiaalveschil V = $\frac{Q}{4 \pi \varepsilon r}$}     & = q(V_a-V_b)     \end{align*}      Am I doing something wrong or is it in compatibility issue somewhere?


title: How can I replicate a command name as an argument?

text: I've searched for but not found an answer to this. I am using two layers of `\newcommand`s to create symbols inline with text, using `\includegraphics`. (It's for music symbols.) At present, I have this as the generic command:               \newcommand*{\inlineImage}[2]{\raisebox{#1pt}{\fbox{\includegraphics{__#2__}}}}      And then many commands of the form:               \newcommand*{\Eighth}{\inlineImage{0}{Eighth}}     \newcommand*{\Sixteenth}{\inlineImage{-1.5}{Sixteenth}}      This works, but it is cumbersome to type the same text twice during set up. Of course, I could employ a command with arguments in my document body, but I don't want to do that. Is there a way to replace the specific commands with something of the form:               \newcommand*{\Sixteenth}{\inlineImage{-1.5}{<thecommandname>}}


title: Point coordinates inside "add"

text: I'm a begginner in asymptote.   I want to make a line(curve with arrow) from point B to point A that has more tension than normal (causing a smaller loop). I decided to create a function to calculate a point C that is between A and B, and then creating a path that passes in that point like so: B..C..A. Using "dot" to draw the point I see it's well positioned. But, using "dot" inside add(...) the point is positioned in a diferent place and so the (red) line. What am I missing? Here's the code and the image I get:               real u = 8cm;     unitsize(u);     real m = 3mm;          pair inbetween(pair a, pair b, real y)     {         return ( (b.x - a.x)*0.5 + a.x, y );     }               pair pos3 = (3,0);     pair pos4 = (4,0);          object n3 = draw("n3",box,pos3,m);     object n4 = draw("n4",box,pos4,m);          pair p4_3 = inbetween(pos3, pos4, -1);     dot(p4_3);          add(new void(picture pic, transform t) {             path c = point(n4,E,t){SE}..{NE}point(n3,W,t);         draw(pic, c, Arrow );              dot(pic,p4_3,red);         path c = point(n4,E,t){SE}..p4_3..{NE}point(n3,W,t);         draw(pic, c, red, Arrow );     });      ![Here's the output.](http://i.stack.imgur.com/YEaYc.png)


title: How to create a Leontief-Gozintograph with tikz?

text: I'm looking for a way to create a leontief-gozintograph that looks similar to this one: ![enter image description here](http://i.stack.imgur.com/urIgf.png) I searched at http://www.texample.net/tikz/examples/ without success. Is there anyone who already have been creating something like this?


title: Building evaluated arrays

text: I'm trying to build an array dynamically in latex then use it in tikz. I'm a little confused about how to create an array and add evaluated mathematical expressions to it (I'm trying arrayjob). Here's what I have so far; for some reason, I cannot access the values in the second foreach, getting the error (! Undefined control sequence. \pntAngles1~ ->\val), the first commented print in the first foreach works btw:               \documentclass{article}          \usepackage{tikz}          \usepackage{calc}     \usepackage{fp}     \usepackage{arrayjob}     \usepackage{ifthen}     \usepackage{amsmath}     % \usetikzlibrary{arrows,intersections}          \begin{document}          \def\n{8} % number of points     \FPeval{\lastn}{\n-1}     \FPeval{\angleOffset}{clip(360/\n)} % angle offset between dots          \newarray\pntAngles          \foreach \i in {0,...,\lastn} {       \FPeval{\val}{clip(\i*\angleOffset)}       \pntAngles(\i)= {\val}       % \pntAngles(\i)     }          \foreach \i in {0,...,\lastn} {       \pntAngles(\i)     }          \end{document}          Would appreciate any advice. Thanks


title: Biblatex create a \citejournal command with journaltitle, date, title

text: Hello latex community! I'm trying to set a specific command to cite journal articles which doesn't show the author but the journal title, the date and then the article title. I've found this answer: How to create a \citejournal, \citebooktitle, \cite... command in biblatex? My problem is that it doesn't not provide the date nor the article title so I've modified it a bit:               \DeclareCiteCommand{\citejournal}       {\usebibmacro{prenote}}       {\usebibmacro{citeindex}%         \usebibmacro{journal}          \usebibmacro{date}            \usebibmacro{title}}       {\multicitedelim}       {\usebibmacro{postnote}}      It's now almost perfect as I see the journal and the article title but the date does not show. Here is a short MWE with the citation I'm using:               \documentclass{article}     \usepackage[style=authoryear,backend=biber]{biblatex}          \DeclareCiteCommand{\citejournal}           {\usebibmacro{prenote}}           {\usebibmacro{citeindex}%             \usebibmacro{journal}              \usebibmacro{date}                \usebibmacro{title}}           {\multicitedelim}           {\usebibmacro{postnote}}          \usepackage{filecontents}          \begin{filecontents}{\jobname.bib}     @article{test,       author = {Author, A.},       date = {2011-06-12},       title = {Some relevant article},       journal = {Test journal}     }     \end{filecontents}          \bibliography{\jobname}          \begin{document}          Some text~\citejournal{test}          \printbibliography          \end{document}


title: Biblatex reordering year in alphabetic bibstyle

text: I'm trying to create a format for my references. So far so good but i can't figure out how to put the year and the editor in parentheses after the authors without a comma. I'm using the alphabetic bibstyle. Can someone tell me how to approach this? Here is what i have got so far: ![enter image description here](http://i.stack.imgur.com/ck4wO.png) What i'd like to have is somehting like this: Nielsen, Jakob und Mack, Robert L. (Hrsg.) (1994): Usability inspection methods. New York, NY, USA: John Wiley & Sons, Inc.


title: Tikz - Thick line by overlapping rectangles - How to improve the diagram

text: I create my diagram with the following code.               \documentclass{article}     %     \usepackage[ngerman]{babel}     \usepackage{tikz}     \usetikzlibrary{calc,trees,positioning,arrows,chains,shapes.geometric,%         decorations.pathreplacing,decorations.pathmorphing,shapes,%         matrix,shapes.symbols,patterns}     %     \pagestyle{empty}     %     \begin{document}     %     \tikzset{     bar cross/.style={rectangle, pattern=north east lines, minimum height=50mm, minimum width=10mm, draw=black,                        anchor=north},     bar/.style={rectangle, minimum height=50mm, minimum width=10mm, draw=black,anchor=north}     }     %     \begin{tikzpicture}       \node(01)[bar,minimum height=30mm]at(0.0,0){};       \node[above]at(01.north){$m_1$};       \node(011)[bar cross,minimum height=20mm]at(0.0,-3){};            \node(02)[bar,minimum height=5mm]at(1.5,0){};       \node[above]at(02.north){$m_1$};       \node(021)[bar cross,minimum height=10mm]at(1.5,-0.5){};       \node(022)[bar,minimum height=5mm]at(1.5,-1.5){};       \node(023)[bar cross,minimum height=15mm]at(1.5,-2.0){};       \node(024)[bar,minimum height=15mm]at(1.5,-3.5){};            \node(03)[bar cross,minimum height=2.5mm]at(3.0,0){};       \node[above]at(03.north){$m_3$};       \node(031)[bar,minimum height=25mm]at(3.0,-0.25){};       \node(031)[bar cross,minimum height=22.5mm]at(3.0,-2.75){};            \node(04)[bar,minimum height=32mm]at(4.5,0){};       \node[above]at(04.north){$m_4$};       \node(041)[bar cross,minimum height=2.5mm]at(4.5,-3.2){};       \node(042)[bar,minimum height=15.5mm]at(4.5,-3.45){};            \node(05)[bar cross,minimum height=10mm]at(6.0,0){};       \node[above]at(05.north){$m_5$};       \node(055)[bar,minimum height=40mm]at(6.0,-1){};            \node(beob)[bar,minimum height=5mm]at(7.5,-2.5){};       \node[right]at(beob.east){type 1};            \node(fehl)[bar cross,minimum height=5mm]at(7.5,-3.5){};       \node[right]at(fehl.east){type 2};            \draw[->](-5,-5) -- (2.5,-2.75);     \end{tikzpicture}     %     \end{document}     %      I think, that lines where rectangles overlap seem to me very thick, is this right or only my opinion? The arrow shows such a line. The second question is, how can I improve my diagram, I'm `tikz` beginner and I think the code could be improved.


title: Automatically squashing subentries in indexes

text: I have a long LaTeX file use to generate several variants of a document, including or excluding a different collection of sections. The document has an index of people generated with `\index{Doe!John}` which are turned into an index using `makeindex`. However, if there's only one person surnamed Doe, I'd like to collapse this to a single line, as if it were generated with `\index{Doe, John}`. I can't easily modify the `\index` invocations in the document because often the number of people named Doe will depend on which sections are being excluded. Is there a way of automating this? **Edit** Example code:               \documentclass{article}     \usepackage{makeidx,comment,xspace}     \makeindex     \newcommand{\name}[2]{#1\ #2\index{#2!#1}\xspace}          % Either include or exclude this section     \includecomment{extra}      %\excludecomment{extra}          \begin{document}         \name{John}{Doe} and \name{Joe}{Bloggs}.          \begin{extra}     \name{Jane}{Doe}.     \end{extra}          \printindex     \end{document}      I'd like the index to read as follows when `extra` is included:               Bloggs, Joe, 1     Doe,         Jane, 1          John, 1      and as follows when `extra` is excluded:               Bloggs, Joe, 1     Doe, John, 1


title: Patch tabular environment with colorbox

text: I'm trying to quickly add a colored background using `colorbox` to all tables as shown in this answer. While I could just update all the TeX by hand, I am trying to patch the `tabular` environment to keep the TeX content as "clean" as possible (and there are 200+ tables to update). I've tried two different methods, but they are giving me the same error:               ! Extra }, or forgotten \endgroup.     \color@b@x ...hbox {\kern \fboxsep {\set@color #3}                                                       \kern \fboxsep }\dimen@ \h...     l.22     \begin{tabular}                             {ll}      TeX:               \documentclass[10pt,twoside,letterpaper,openright]{scrbook}                                                                                \usepackage[usenames,dvipsnames]{xcolor}                                                                                \usepackage{booktabs}                                                                                % Method One:                                                                                \usepackage{etoolbox}                                                                                \BeforeBeginEnvironment{tabular}{\colorbox{gray}\begingroup}                                                                                \AfterEndEnvironment{tabular}{\endgroup}                                                                                % Method Two                                                                                %\usepackage{xpatch}                                                                                %xpretocmd{\tabular}{\begingroup\setlength{\fboxsep}{0pt}\colorbox{gray}\begingroup}{}{\patchfailed}                                                                                %xapptocmd{\endtabular}{\endgroup\endgroup}{}{\patchfailed}                                                                                \begin{document}                                                                                \chapter{Lorem Ipsum}                                                                                \begin{table}[h]                                                                                \caption{Test Table}                                                                                \label{testtable}                                                                                \begin{tabular}{ll}                                                                                \toprule                                                                                Test 1 & Test 2 \\                                                                                Test 3 & Test 4 \\                                                                                \bottomrule                                                                                \end{tabular}                                                                                \end{table}                                                                                \end{document}


title: Where can I share useful but unpolished code / hacks?

text: During the course of writing my thesis I've come up with loads of useful macros and hacks and implemented them for my own use. For a few of them I've actually written and published packages. But others are unfinished, unpolished, undocumented or otherwise unsuitable for CTAN. I've come to realize that I may never have the time to turn them all into proper packages. But they have been quite useful to me, and might be useful to others. I would certainly be willing to put them online with minimal descriptions. People could copy/paste them; perhaps package them up in my stead. TeX.se is the most active TeX community I know. But as a Q&A site, it is not suitable for sharing code-snippets. I guess I could artificially create questions and answers around them, but that feels a bit silly. **Question:** Is there a place to put (references to) my TeX code where many interested users / package-authors could find them? Here's an incomplete list of the kind of code I mean:   * Extensions to `\cref`, such as **(1)** `\crefOr` to typeset "Equation 1, 2 or 3" **(2)** `\crefPrevNext` to typeset things like "the previous section", "this section" or "the next section" when appropriate, and otherwise falls back to "Section 3.2" (also works for chapters, etc.) and **(3)** `\MyCrefAlias`, which globally makes one label-type an alias to another (also works with ranges).   * Convenience commands for locally manipulating word-stretch/shrink.   * A number of tikz commands to draw (fragments of) Venn diagrams.   * A package to automatically generate chapter/section labels based on the directory structure.


title: How is the spirit of LaTeX different from writing in MS-Word?

text: I am learning the use of LaTeX by porting an 12-page LibreOffice Writer file to a set of `pdflatex` input files. The ability to separate the source in different files and later generate a single output file is nice. Automatic chapter/section/subsection numbering and index generation is also cool. However, here the benefits that I am seeing stop. When transferring **bolded** text, I do `{\bfText}` (which seems to be actually incorrect). When inserting pictures, I do `/insertgraphics{../images/picture}`. When doing _italics_ , I do `\emph{Text}`. I feel that I am missing something huge. There is a common problem among programmers, when someone has to quickly do some development in an unknown programming language, they would learn the syntax, but not the `idiomatic` way to do things, and write very bad code. I feel the same is happening to me here. Is it correct to use `\emph` to make whole paragraphs italics? Is it correct to use `\insertgraphics` to place an illustration **exactly here** , because it is related to a certain paragraph, and would make less sense if using `\figure` latex moves it wherever it decides? EDIT: My goals are:   * When the text is being skimmed, the most important words and numbers should stand out. That is, if someone has read the text, by skimming it, they should be able to find concrete information rapidly. I am currently using `{\bfText}` for this.   * Some paragraphs are short stories, while the rest of the text is rules and numbers. I want the stories to look different, so that the person from the previous point skips them entirely, while a new reader would know that this is just a story and he doesn't need to pay much attention and look for important information in it. I am using `\emph{TheWholeParagraph}` for this.   * Figures are illustration, associated with the start of a new section. As such, they should be somewhere around the heading. Their purpose it to invoke atmosphere, related to the new content.


title: How can I reuse the same table alignment specifications in many tables?

text: \documentclass{article}     \usepackage{array}          \begin{document}          \begin{table}       \begin{tabular}{|>{$}c<{$}|>{$}c<{$}|}          1 & 2 \\       \end{tabular}     \end{table}          \begin{table}       \begin{tabular}{|>{$}c<{$}|>{$}c<{$}|}         3 & 4 \\       \end{tabular}     \end{table}          \end{document}      I am new to LaTeX. I have a LaTeX file containing many large tables, each containing large number of columns. All the tables have the same kind of columns, and need similar alignment and column widths. I am looking for an easy way to specify a common alignment instruction for all of them (`|>{$}c<{$}|>{$}c<{$}|` in the above example). Is there a way to specify and reuse the string `|>{$}c<{$}|>{$}c<{$}|` (using `\newcommand` or `\let` or `\def` etc), so that I can easily replicate the behavior in all my tables?


title: geometry package is not working in all pages

text: The `geometry` package in combination with `amsmath`'s `align` environment is not working in all pages. When many lines are within the `align` environment they get automatically shifted onto the next page and the bottom of the previous is left blank.


title: Short referencing for a presentation

text: I am preparing a presentation such that there are some references on the slides and I am placing them as foot notes. In order to manage my references I am using the `biblatex` package with the following configuration:               \usepackage     [   style=numeric-comp,                         autocite=superscript,                          sortcites,                         backend=bibtex,                         maxcitenames=3                     ]{biblatex}      Even though I am using a compact display collapsing authors when more than 3 etc, sometimes the reference is still too long. Is there any form to call `\fullcite` with parameters so that for a particular reference I can control something to make it shorter like _J.Bond et al._ instead of _James Bond et al._ or eliminate the pages field or suchlike. I don't want to applied it to all just to dose references that one line long plus 2 characters.


title: File ended while scanning use of \frame

text: I am a beginner in Latex. My code:               \documentclass[xcolor=dvipsnames]{beamer}     \mode<presentation>          \usetheme{Antibes}     \usecolortheme[named=Green]{structure}          \title[HUM-THE SABHAl]{Training And Placement Cell}     \subtitle{Industrial Training Report }     \author{MADE BY-\bigskip\\Mudita Tripathi\\1150810904\\Heena Tabassum\\1050810017\\Amandeep Kaur\\1050810007\\Anoop Kumar singh\\1050810009\\Sameeksha Tandon\\1050810042}     \institute{BBDESGI,CS-4}                    \begin{document}     \begin{frame}     \titlepage     \end{frame}     \begin{frame}         \frametitle{Table of contents}              \tableofcontents     \end{frame}               \section{ABSTRACT}         \begin{frame}{ABSTRACT}             \begin{block}{}                          \begin{itemize}                             \item The national website , "HUM-THE SABHA" , is designed to address the problems of comman man\bigskip.                             \item It presents a virtual parliament on the internet\bigskip.                             \item  It is an easy to interact website whereby the public can easily interact and retreive the dezired information\bigskip.                             \item The website is designed to deliver all sorts of political information needed for the overall development of the country and to satisfy the needs of the people\bigskip.                     \end{itemize}             \end{block}         \end{frame}                    \section{INTRODUCTION}         \begin{frame}{INTRODUCTION}             \begin{block}{}                 \begin{itemize}                     \item Our website displays several departmental works to make people aware of the official proceedings\bigskip.                     \item We have given provisions about good work appreciation, undertaken by people. This will create competence among the people for consideration of their problems\bigskip.                                                   \item There is a law and order section in our website where the registered users can attain several information about our constitution\bigskip.                                              \item The registered users can also address their problems in this section.                      \end{itemizeir dedication towards development\bigskip.                                                \item To address the government with the necessities of the comman man\bigskip.                                                \item To bring out new enthusiastic leaders and support them in their nation development movement .                      \end{itemize}             \end{block}             \end{block}          \end{frame}          \section{MISSION}         \begin{frame}{OBJECTIVES}             \begin{block}{}                 \begin{itemize}                     \item To Screen out all political parties and th         \end{frame}          \section{TOOLS USED}         \begin{frame}{TOOLS USED}             \definecolor{DarkBlue}{rgb}{0,0.08,0.45}                 \begin{itemize}                     \fontsize{15pt}{15pt}\selectfont                     \color{DarkBlue}                                         \item \textbf{Hardware Requirements:}                     \begin{itemize}                         \fontsize{13pt}{13pt}\selectfont                         \item  Processor                                :     Pentium Dual Core                                                       \item  Ram                                        :     2 GB                                                    \item   Hardware Disk Requirement   :     80 GB\bigskip                     \end{itemize}                                                \fontsize{15pt}{15pt}\selectfont                                                \color{DarkBlue}                     \item \textbf{Software Requirements:}                     \begin{itemize}                              \item Operating Sytem                     :  Windows 8                                                           \item Back End                                 : SQL Server                                                           \item Front End                               : ASP.Net                                                         \end{itemize}                     \end{itemize}              \end{frame}               \section{PROJECT DIVISION}         \begin{frame}{PROJECT DIVISION}                      \begin{figure}{}                     \centering                     \includegraphics[width=0.65]{lfc.jpg}                 \end{figure}              \end{frame}          \section{ADMIN PANEL}         \begin{frame}{ADMIN PANEL}             \begin{block}{}                 \begin{itemize}                     \item Admin login \bigskip                     \item Students detail record.\bigskip                     \item Generate list for selected companies.\bigskip                     \item Calculate placement percentage.\bigskip                     \item Make announcements.                 \end{itemize}             \end{block}         \end{frame}          \section{USER PANEL}         \begin{frame}{USER PANEL}             \begin{block}{}                 \begin{itemize}                     \item Enter detail of each student \bigskip                     \item Update student detail \bigskip                     \item Generate students contact detail for each year and each department.                 \end{itemize}             \end{block}         \end{frame}          \section{WORKING AND SCREENSHOTS OF THE PROJECT}         \begin{frame}{WORKING AND SCREENSHOTS OF THE PROJECT}                      \centerline{\huge \textcolor{blue}{WORKING AND SCREENSHOTS}}                  \bigskip                 \centerline{\huge \textcolor{blue}{OF THE PROJECT}}         \end{frame}          \section{LOGIN PAGE}         \begin{frame}{LOGIN PAGE}             \begin{block}{}                 \begin{itemize}                     \item This is the homepage of the application. \bigskip                     \item On the page several links are given to go to other pages of the website \bigskip                 \end{itemize}             \end{block}         \end{frame}              \begin{figure}{}             \bigskip             \centering                 \includegraphics[width=.98\linewidth]{bbd1.png}         \end{figure}          \section{STUDENT LOGIN PAGE}         \begin{frame}{STUDENT LOGIN PAGE}             \begin{block}{}                 \begin{itemize}                     \item The left side includes a view detail link to view the student details.                     \item The right side includes important posts and below it is the query section where students can ask any query regarding placement.                 \end{itemize}             \end{block}         \end{frame}         \begin{figure}{}             \bigskip             \centering                 \includegraphics[width=.98\linewidth]{bbd2.png}         \end{figure}          \section{STUDENT DETAIL PAGE}         \begin{frame}{STUDENT DETAIL PAGE}             \begin{block}{}                 \begin{itemize}                     \item When a student wants to see the record , he / she can click on the view button on the homepage and the student detail page will appear. \bigskip                     \item This page includes information like : year , branch ,student resume  , achievements , name , ID.                 \end{itemize}             \end{block}         \end{frame}         \begin{figure}{}             \bigskip             \centering                 \includegraphics[width=.98\linewidth]{bbd3.png}         \end{figure}          \section{ADMIN LOGIN PAGE}         \begin{frame}{ADMIN LOGIN PAGE}             \begin{block}{}                 \begin{itemize}                     \item After admin login, the admin login page will appear. \bigskip                     \item This page includes links like: enter notice where the manager can enter the important details about the companies , placement notifications etc.                 \end{itemize}             \end{block}         \end{frame}         \begin{figure}{}             \bigskip             \centering                 \includegraphics[width=.98\linewidth]{bbd4.png}         \end{figure}     \begin{figure}{}             \bigskip             \centering                 \includegraphics[width=.98\linewidth]{preparation.PNG}         \end{figure}     \begin{frame}{company}     \begin{figure}{}             \bigskip             \centering                 \includegraphics[width=.98\linewidth]{home2.PNG}         \end{figure}     \end{frame}     \section{CONCLUSION}         \begin{frame}{CONCLUSION}             \begin{block}{}                 \begin{itemize}                     \item The project has been developed using VISUAL STUDIO. \bigskip                     \item Project attention has been given to make this project user friendly.\bigskip                                               \item It successfully stores all the details submitted by the students as well as admin.\bigskip                                               \item Every new entry in the database will send a mail to the aspirants.                 \end{itemize}             \end{block}         \end{frame}     \section{FUTURE SCOPE}         \begin{frame}{FUTURE SCOPE}             \begin{block}{}                 \begin{itemize}                     \item This application can be modified from time to time as per the changing user requirements with less cost.\bigskip     \item The limitation with this application can be looked into and the enhancement can be made as per the requirement.                         \end{itemize}             \end{block}         \end{frame}     \section{LIMITATIONS}         \begin{frame}{LIMITATIONS}             \begin{block}{}                 \begin{itemize}                     \item The only limitation of this project is that it connects us to the database and make the details about training and placement accessible to the students only according to the branch.\bigskip     \item It has to be according to marks eligibility.\bigskip     \item Rest the project satisfies all the project objectives.                        \end{itemize}             \end{block}         \end{frame}     \section{}         \begin{figure}{}                 \bigskip                 \centering                     \includegraphics[width=.98\linewidth]{t1.jpg}         \end{figure}     \end{document}      I suspect the error is somewhere here:               \section{PROJECT DIVISION}             \begin{frame}{PROJECT DIVISION}                          \begin{figure}{}                         \centering                         \includegraphics[width=0.65]{lfc.jpg}                     \end{figure}                  \end{frame}      But can't figure out the exact problem. Please help. Thanks.


title: Clever beamer animation? Writing a script that changes a tikz picture in beamer?

text: Here is a start of an answer to this "challenge":               \documentstyle[beamer]     \usepackage{tikz}          \begin{document}     \begin{frame}     \tikzset{click/.style={draw}}          \begin{tikzpicture}[start chain=going right,         node distance=4mm,     every node/.style={on chain,draw}]          \node(A)  {Alpha};     \node(B)  {Bravo};     \node(C)  {Charlie};     \node(D) {Delta};     \node(E)  {Echo};     \node(F) {Foxtrot};     \end{tikzpicture}               \play{F,E,E,D}     \play{D,E,A,F}     \play{B,E,D}          \end{frame}     \end{document}      The question is how to define ''click'' so that in each overlay, the highlighted node, would change. In pseudo code, "click" should be defined to:               If currentStep = myNodeName then        add "ultra thick", or "fill=green", or whatever        to the current node.     fi      Ideally, the [click] macro should apply to any path, not just to nodes. At the same time, "\play" should translate to               Foreach currentStep in argumentList do       \only<+> {           invoke the above tikzpicture while setting currentStep        }     od      * _MORE INFORMATION *_ Here is something that almost works               tikzset{       Z/.code={         \ifthenelse{\equal{\noexpand\pc}{#1}}{%       \tikzset{rectangle}%         }{%       \tikzset{circle}%         }       }     }     \begin{frame}[fragile,label=current]{my frame}       \foreach \pc in {A,B,A,D,C,A} {        \only<+>{         \begin{tikzpicture}[start chain=going right,node distance=1cm]           \node[on chain][draw,Z=A] {A\pc};           \node[on chain][draw,Z=B] {B\pc};           \node[on chain][draw,Z=C] {C\pc};           \node[on chain][draw,Z=D] {D\pc};         \end{tikzpicture}       }     }     \end{frame}      But, there must be something I miss in the expansion process. The logic seems right, the document compiles nicely, but the true branch of the conditional is never executed. Any ideas?


title: Convert color name to pdfliteral code

text: How can I convert a color name (such as used with the `xcolor` package) to a pdfliteral code, like `q 1 0 0 rg` (for red)?


title: Using pdfliteral to highlight text

text: Using `pdfliteral`, one can color text like the following:                     w1_prev = node.new("whatsit","pdf_literal")           w1_prev.data = "q 1 0 0 rg"           w1_prev.mode = 1                w2_prev = node.new("whatsit","pdf_literal")           w2_prev.data = "Q"           w2_prev.mode = 1                node.insert_after(prev_line.prev,prev_line.prev,w1_prev) --color text between prev_line.prev...           node.insert_before(prev_line,prev_head,w2_prev) -- and prev_head      Is there a code similar to `q 1 0 0 rg` which highlights text instead of coloring the letters?


title: Multiline text in multiline equation

text: I have an assignment to copy the picture below in LaTeX. I got stuck with the (A.4) equation in attached picture. Specifically, I need the text part of that equation to be in two lines but the way I did it the text just goes through the margins. I used `itemize` for the numbering and `dcases*` for the equation. Also as a bonus question, I'm not sure how to do the footer copyright exactly as on the picture. ![enter image description here](http://i.stack.imgur.com/dI0pa.png)


title: Text displacement with line numbering in eledmac package

text: I'm using the package `eledmac`, and when I use line numbering I have a text displacement, with a disruption of the correct vertical alignment:               \documentclass[a4paper, 12pt, twoside, draft]{article}          \usepackage[top=25mm,bottom=30mm,left=30mm,right=30mm]{geometry}          \usepackage{fontspec}     \setmainfont[AutoFakeBold=1, AutoFakeSlant=0.3, Ligatures=TeX]{times.ttf}     \usepackage{polyglossia}          \usepackage{setspace}     \usepackage{eledmac}               \begin{document}          \beginnumbering     \pstart     \firstlinenum{1}     \linenumincrement{1}          Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum venenatis elit non pellentesque placerat. In dignissim massa a mauris congue, quis varius tellus ornare. Integer cursus tempus sapien, eu convallis sapien posuere eu. Praesent tempor leo sed neque vestibulum congue. Ut varius consectetur nibh in consequat. Sed et magna eget sapien dictum sagittis. Pellentesque nec lobortis quam, eu commodo ipsum. Nam fringilla nisi id elit ultricies tempus. Duis convallis egestas elit, vel vehicula nunc ultricies sed.           \pend     \endnumbering               \setlength\parindent{0pt}     \line(1,0){50}     \vspace{8pt}     \end{document}      Here's the result with line numbering: ![enter image description here](http://i.stack.imgur.com/RyyMc.jpg) and without line numbering: ![enter image description here](http://i.stack.imgur.com/KY0nC.jpg) I added an horizontal line in order to make visible the displacement of the text and the bad vertical alignment. I'm using xelatex. To be clear my goal is to obtain the output that gives the package `lineno`: ![enter image description here](http://i.stack.imgur.com/jCWXs.jpg) EDIT: In the last version of eledmac package this problem is fixed. I have updated it through MiKTeX Update Wizard and now it works correctly. Thanks to http://tex.stackexchange.com/users/27635/karlkoeller


title: Is it possible to have a two head arrow as a decorator?

text: I would like to have the analogue of `\overrightarrow{x}` but with a two headed arrow (as in `\twoheadrightarrow`, but above the variable). Is this possible?


title: modify bibliography style

text: Hi I want to modify biliographystyle unsrt, this style return : Einstein journal paper [1]. But I want : Einstein journal paper (Einstein 1905, [1]). With the same entry in the bibliography section. I have test citep but it doesn't work, and I have chose other biliographystyle but I prefer the unsrt bibliographystyle. example.tex source :               \documentclass[12pt,a4paper]{report}     \usepackage[latin1]{inputenc}     \usepackage{amsmath}     \usepackage{amsfonts}     \usepackage{amssymb}       \bibliographystyle{unsrt}          \begin{document}     Einstein journal paper \cite{einstein}.     \bibliography{example}     \end{document}      example.bib source :               @article{einstein,       author =       "Albert Einstein",       title =        "{Zur Elektrodynamik bewegter K{\"o}rper}. ({German})                      [{On} the electrodynamics of moving bodies]",       journal =      "Annalen der Physik",       volume =       "322",       number =       "10",       pages =        "891--921",       year =         "1905",       DOI =          "http://dx.doi.org/10.1002/andp.19053221004"     }


title: Adjust space between acronym and glossary description

text: I'm using the glossaries package and I would like to get the acronym descriptions to line up with the nomenclature section above it. Tried using the column styles for the glossary, but none of those allow adjustment of the first column (with the acronyms). See picture for misalignment. Any way around this? ![Misalignment](http://i.stack.imgur.com/5MEWm.png)


title: TeXlive on ubuntu - fonts in Plain TeX

text: I've reinstalled my system recently (now I use ubuntu 12.04) and have problem with fonts in Plain TeX I use texlive and texlive-lang-czechslovak. Apparently with UTF-8 encoding (pdf)csplain is not able to translate czech chars such as žščř. In the resulting pdf (or dvi) these chars appear as some strange scrawl. Here is the log file:               This is pdfTeX, Version 3.1415926-2.4-1.40.13 (TeX Live 2012/Debian) (format=csplain 2014.3.3)  3 MAR 2014 12:54     entering extended mode     restricted \write18 enabled.     %&-line parsing enabled.     **pokus     (./pokus.tex The format: csplain <Sep. 2005>.     The cs-fonts are preloaded and A4 size implicitly defined.     Missing character: There is no Ã in font csr10!     Missing character: There is no œ in font csr10!     Missing character: There is no ¯ in font csr10!     Missing character: There is no  in font csr10!     Missing character: There is no Ã in font csr10!     Missing character: There is no ¡ in font csr10! [1] )     Output written on pokus.dvi (1 page, 272 bytes).      with iso-8859-2 encoding are all chars translated just fine. The strange thing for me is that if I add to the file in iso-8859-2               \input ctimes.tex      pdf stays the same but in dvi žščř is translated to zscr Why is that happening and is there any way to make things work with UTF-8? Because I've somehow managed to install TeX correctly on my previous system (ubuntu 13.10) and as I remember it worked fine with UTF-8 but I forgot how I've done that. Thank you for reply.


title: BibTeX bibliography not printing

text: I was unable to find a previous post about this - perhaps too simple? I just came across the BibTeX and am trying to use it with an EndNote library. I have exported to the .bib file (which looks good as far as I can tell), but no bibliography is printed and the references aren't being cited. Obviously there is something major missing. My document looks as follows.               \documentclass[11pt, fceqn]{article}     \usepackage{epsfig}     \usepackage{setspace, titlesec, caption, floatrow}            \usepackage{amsmath, amssymb, amsfonts, amsthm, cite, mathtools, lineno, subfig, natbib}          \begin{document}           Some text \cite{Alo_1}.          \bibliography{bib}     \bibliographystyle{plain}          \end{document}      Any thoughts would be greatly appreciated.


title: Drawing vectorized digital logic circuits

text: I'm looking for a tool to draw vectorized digital logical circuits. I first wanted to use Circuitikz, but found out that their are only two input lines for AND and OR gates. Are there any options to use a LaTeX package where gates have more input lines. Or are there some usefull tools that can produce vectorized pdf files. I need these tools for a course I'm writing about digital electronics and processors. thanks in advance.


title: Always print full author name biblatex

text: I'm currently writing my thesis, and I've a problem, because when I print a cite more one time via `\footcite` command, the author first name is hidden. But I must print every time the full name of the author. I've read this post About biblatex repeated citations but I can't solve my problem. I call `biblatex` package with these options               \RequirePackage[%     style=verbose-trad2,     backend=biber,     dashed=false,     hyperref,     firstinits=false,     alldates=comp,     abbreviate=false,     idemtracker=false,     opcittracker=false,     language=french%     ]{biblatex}      ## mwe.tex               \documentclass{ownclass}%scrbook base (KOMA)     % Don't forget to parse with biber backend     \title{MWE}     \addbibresource{mwe.bib}     \begin{document}     some text\footcite["quote"][2]{Dupont:2012fk}     \clearpage     some other text on a new page with another reference\footcite[21]{Me:2012uq} and another extract from the previous cite\footcite["quote"][2]{Dupont:2012fk}     My problem: firstnames (Tim \& Jean) aren't printed     \end{document}      ## ownclass.cls               \NeedsTeXFormat{LaTeX2e}     \ProvidesClass{ownclass}[15/11/2012 v1.0]     \LoadClass[12pt, oneside, a4paper]{book}     \RequirePackage[latin1,applemac,utf8]{inputenc}     \RequirePackage[T1]{fontenc}     \RequirePackage{textcomp}          %Biber backend     \RequirePackage[%     style=verbose-trad2,     backend=biber,     dashed=false,     hyperref,     firstinits=false,     alldates=comp,     abbreviate=false,     idemtracker=false,     opcittracker=false,     language=french%     ]{biblatex}          \renewcommand*{\newunitpunct}{\addcomma\space} % ,          %Français     \RequirePackage[francais,frenchb]{babel}          \RequirePackage[babel]{csquotes} % Guillemets     \selectlanguage{french}     \frenchspacing     \FrenchFootnotes      ## bib entries               @book{Me:2012uq,         Author = {Me},         Date-Added = {2012-11-05 23:58:33 +0000},         Date-Modified = {2012-11-05 23:59:00 +0000},         Publisher = {SMB},         Title = {Tex and Biblatex},         Year = {2012}}          @book{Dupont:2012fk,         Author = {Dupont, Jean and Burton, Tim},         Date-Added = {2012-11-05 23:49:22 +0000},         Date-Modified = {2012-11-05 23:52:46 +0000},         Publisher = {Publisher},         Title = {Tintin},         Year = {2012}}


title: Make "Reference" in Bibliography Smaller / Spacing in Bibliography

text: I have trouble making my bibliography section smaller. This is important because I am applying for the NSF Graduate Fellowship and they want everything to fit 2 pages. Here is what it looks like right now:               \documentclass[12pt]{article}     \usepackage[margin=1in]{geometry}     \usepackage{setspace}     \usepackage{placeins}     \usepackage[abbr]{harvard}     \usepackage{bib}     \usepackage{fancyhdr}     \usepackage{graphicx}          This is the body of my essay.               \bibliographystyle{apsr}     \bibliography{bibtex}          \end{document}      Note I am using the `apsr` bibliography style. Unfortunately, the bibliography that pops out takes too much space. The word `References` is huge and there exists a space between each work cited. How do I make `References` smaller and/or delete the blank space between each work cited?


title: Animated Merge sort example

text: I would like to create a merge sort example like this one on Wikipedia:Merge Sort. Can someone help me? ![enter image description here](http://i.stack.imgur.com/rQNjw.gif) * * * here is what I've done so far, but it doesn't work properly and effects are not like in this wikipedia example. Any improvement ? Thanks               \documentclass{beamer}     \usepackage{pgfpages}     \usepackage[ngerman]{babel}     \usepackage{animate}     \usepackage{tikz}     \usetikzlibrary{arrows,decorations.pathmorphing,through,backgrounds,positioning,fit,petri}     \usetikzlibrary{shapes,shadows}     \usetikzlibrary{shapes.multipart}     \usetikzlibrary{calc}     \usetikzlibrary{decorations.pathreplacing}     \newcounter{angle}     \setcounter{angle}{0}     \begin{document}          \begin{frame}     \begin{animateinline}[       begin={%     \begin{tikzpicture}     \node[shape=rectangle, draw=black, minimum size=0.5cm](1) at (1,1) {6};     \node[shape=rectangle, draw=black, minimum size=0.5cm](2) at (1.5,1) {5};     \node[shape=rectangle, draw=black, minimum size=0.5cm](3) at (2,1) {3};     \node[shape=rectangle, draw=black, minimum size=0.5cm](4) at (2.5,1) {1};     \node[shape=rectangle, draw=black, minimum size=0.5cm](5) at (3,1) {8};     \node[shape=rectangle, draw=black, minimum size=0.5cm](6) at (3.5,1) {7};     \node[shape=rectangle, draw=black, minimum size=0.5cm](7) at (4,1) {2};     \node[shape=rectangle, draw=black, minimum size=0.5cm](8) at (4.5,1) {4};     \node(9) at (5.0,1) {};     \useasboundingbox (-0.5,-0.5) rectangle (10,9.5);},       end={\end{tikzpicture}}     ]{10}          \newframe*     \multiframe{2}{iCount=1+1}{         \node[shape=rectangle, draw=black, minimum size=0.5cm] (1) at (1,\iCount) {6};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (2) at (1.5,\iCount) {5};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (3) at (2,\iCount) {3};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (4) at (2.5,\iCount) {1};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (5) at (3.2,\iCount) {8};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (6) at (3.7,\iCount) {7};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (7) at (4.2,\iCount) {2};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (8) at (4.7,\iCount) {4};      }          \newframe*     \multiframe{2}{iCount=2+1}{         \node[shape=rectangle, draw=black, minimum size=0.5cm] (1) at (1,\iCount) {6};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (2) at (1.5,\iCount) {5};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (3) at (2.1,\iCount) {3};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (4) at (2.6,\iCount) {1};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (5) at (3.2,\iCount) {8};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (6) at (3.7,\iCount) {7};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (7) at (4.3,\iCount) {2};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (8) at (4.8,\iCount) {4};      }          \newframe*     \multiframe{2}{iCount=3+1}{         \node[shape=rectangle, draw=black, minimum size=0.5cm] (1) at (1,\iCount) {5};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (2) at (1.5,\iCount) {6};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (3) at (2.1,\iCount) {1};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (4) at (2.6,\iCount) {3};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (5) at (3.2,\iCount) {7};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (6) at (3.7,\iCount) {8};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (7) at (4.3,\iCount) {2};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (8) at (4.8,\iCount) {4};      }          \newframe*     \multiframe{2}{iCount=4+1}{         \node[shape=rectangle, draw=black, minimum size=0.5cm] (1) at (1,\iCount) {1};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (2) at (1.5,\iCount) {3};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (3) at (2.0,\iCount) {5};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (4) at (2.5,\iCount) {6};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (5) at (3.2,\iCount) {2};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (6) at (3.7,\iCount) {4};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (7) at (4.2,\iCount) {7};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (8) at (4.7,\iCount) {8};      }          \newframe*     \multiframe{2}{iCount=5+1}{         \node[shape=rectangle, draw=black, minimum size=0.5cm] (1) at (1,\iCount) {1};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (2) at (1.5,\iCount) {2};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (3) at (2.0,\iCount) {3};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (4) at (2.5,\iCount) {4};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (5) at (3.0,\iCount) {5};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (6) at (3.5,\iCount) {6};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (7) at (4.0,\iCount) {7};         \node[shape=rectangle, draw=black, minimum size=0.5cm] (8) at (4.5,\iCount) {8};      }     \end{animateinline}     \end{frame}          \end{document}


title: Define same command with different amount of parameters

text: I want to define two versions of the command `\Set`, depending if I provide one or two parameters. I.e. like this:               \newcommand{\Set}[1]{\bigl\{ #1 \bigr\}}     \newcommand{\Set}[2]{\bigl\{ #1 \bigm| #2 \bigr\}}      But that doesn't work. It complains about the redefinition of the command.


title: TikZ 3.0.0 and Hobby

text: Compiling the following MWE:               \documentclass[tikz,border=10pt]{standalone}     \usepackage{tikz}     \usetikzlibrary{hobby}          \begin{document}          \begin{tikzpicture}     \draw[help lines] (0,0) grid[step=0.25] (1,1);     \draw[very thick,red!85!black]      (0,0)     to[curve through={(0.15,0.35) ..                        (0.5,0.5)   ..                        (0.8,0.6)                       }       ]       (1,1);     \end{tikzpicture}     \end{document}      with TikZ version 3.0.0 gives: ![enter image description here](http://i.stack.imgur.com/uZl4I.png) The same MWE, with TikZ 2.10 leads to something _more expected_ : ![enter image description here](http://i.stack.imgur.com/Ha0s4.png) Why this difference?


title: Is there a collection of national flags in TikZ?

text: I have tried to search, but I have not been able to found any repository with the flags of the most common countries defined with TikZ. It must be very possible as most flags are really vectors.


title: Drawing a trend line on a bar chart

text: For the MWE below:               \documentclass{report}     \usepackage[left=2.5cm,right=2cm,top=2cm,bottom=2cm]{geometry}     \usepackage[T1]{fontenc}     \usepackage{pgfplots}               \begin{document}          \begin{figure}[H]     \centering     \begin{tikzpicture}     \begin{axis}[xmode=normal,ymode=log,     ybar,     scaled y ticks = true,     grid=both,     minor y tick num=5,     ylabel={Elapsed Time (in hours)},     xlabel={Number of Constraints},     width=1*\textwidth,     height=9cm,     bar width=3.5pt,     symbolic x coords={3,4,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35     },     xtick=data,     ymin=0     %nodes near coords,     %nodes near coords align={vertical},     ]          \addplot [fill=red]     coordinates {(3,38.9575) (4,166.897) (6,53.63835) (7,39.6594) (8,82.1631) (9,40.22045) (10,37.2932) (11,131.62625) (12,472.6995) (13,149.837) (14,113.445) (15,108.474) (16,155.24455) (17,95.41392) (18,186.819) (19,153.383) (20,313.361) (21,180.1305) (22,401.3485) (23,1621.092) (24,1929.3) (25,899.283) (26,726.926) (27,1624.4) (28,870.348) (29,979.472) (30,869.418) (31,274.83) (32,1945.87) (33,1359.09) (34,891.24) (35,1625.31)     };         \end{axis}     \end{tikzpicture}     \caption{The Elapsed Time vs. The Number of Constraints for the Halving Method}     \end{figure}          \end{document}      How can I draw a trend line on top of the bar chart ? By trend line I mean a line that touches to the top point of each bar on the chart.


title: How adjust the vertical space in aligned equations (in the Preamble)?

text: I always find the standard `\\\` to be too little in aligned equations. I used to do `\\\\[5mm]` or similar in the past, but there must be some automatic way to do this once and for all in the preamble. Is there?


title: Essential files to run LaTeX

text: > **Possible Duplicate:**   >  Portable minimal distribution Which files are essential to run LaTeX? Is possible for example, make a copy of these files and also of the packages used in my document to run pdfLaTeX without install all the TeXLive distribution? I use TeXLive 2012 and Windows 8.


title: lines with variable width in TikZ (to convert handwritten Xournal files to tikz)

text: I am trying to convert handwritten text or handdrawn sketches to TikZ. Usually the thickness of a pen stroke varies when the writer applies more or less pressure to the surface.   I am looking for a _short_ way to map that to TikZ, e.g. this syntax would be awesome:               \draw (1,1) --[2pt] (1,3) --[1pt] (2,3);      To draw a 2pt line from (1,1) to (1,3) and a 1pt line from (1,3) to (2,3). I know that this:               \draw[line width=2pt] (1,1) -- (1,3);     \draw[line width=2pt] (1,1) -- (1,3);      would work, but it's not very practical for lots and lots of coordinates. **Update:**   Thanks to Andrew Staceys answer, I was able to finish the tool, which converts handdrawn Xournal sketches to TikZ code.   If you find it useful for your purposes, you can download the tool on https://github.com/flyser/xoj2tikz and read the announcement here. Have fun :-)


title: No LaTeX in MiKTeX TeXworks

text: I don't have the option of compiling using LaTeX engine in TeXworks, which I installed from MiKTeX. Take a look at the options I have: ![enter image description here](http://i.stack.imgur.com/fHxQL.jpg) How do I compile that TeX document using LaTeX?