title: Problem with dash using XeLaTeX

text: I am writting with LaTeX my bachelor thesis. I am using XeLaTeX because you can easily highlight text with the `xesearch` package. My problem is that words with a dash like **HTML-Request** are not broken properly. In the PDF file there are two dashes at the end of the line. I suppose the problem is the usage of `\UndoBoundary{-}`. I am using it because otherwise notionssuch as **Web-Verifier** won't be highlighted. Could you help me, please? I post the full head maybe you could give me some other hints, too. I am using KomaScript.               %\documentclass[a4paper, twoside,12pt,abstracton,parskip=half]{scrreprt}     \documentclass[a4paper,12pt,abstracton,parskip=half]{scrreprt}          \usepackage[ngerman]{babel}     \usepackage[babel, german=quotes]{csquotes}          \usepackage[german=quotes]{csquotes}          \MakeOuterQuote{"}          \usepackage{graphicx}     \usepackage{url}     \usepackage{extsizes}     \usepackage{hyperref}     \usepackage{xltxtra}     \usepackage{xesearch}     \usepackage{tabularx}     \usepackage{microtype}     \usepackage{titleref}          \usepackage[textwidth=16cm]{geometry}          \usepackage{xcolor}               \usepackage{fontspec}     \defaultfontfeatures{Mapping=tex-text}     \setmainfont[Ligatures=TeX]{Arial}               %\setmainfont{Times New Roman}          \usepackage[     backend=biber,     style=numeric,     sortlocale=de_DE,     natbib=true,     url=false,      doi=true,     eprint=false     ]{biblatex}          \usepackage[automark,headsepline]{scrlayer-scrpage}          \clearpairofpagestyles     \cfoot[\pagemark]{\pagemark}     \lehead{\headmark}     \rohead{\headmark}     \pagestyle{scrheadings}          \setlength{\headheight}{14.5pt}     \setlength{\parindent}{0pt}               \addbibresource{citations.bib}          \UndoBoundary{-}     \SearchList{i4}{\textit{#1}}{Web-Verifier}     \SearchList{i5}{\textit{#1}}{Web-Verifiers}     \SearchList{i6}{\textit{#1}}{Single Page Web Application}          %\SearchList{i8}{\textit{#1}}{}     %\SearchList{i9}{\textit{#1}}{}               \hyphenation{Web-Verifier}     \hyphenation{Web-Verifiers}               \newcounter{savepage}     \begin{document}          \thispagestyle{empty}          \begin{abstract}     \thispagestyle{plain}     Web-Verifier HTTP-Request HTTP-Response HTTP-Request HTTP-Response HTTP-Request HTTP-Response     HTTP-Request HTTP-Response HTTP-Request HTTP-Response HTTP-Request HTTP-Response     \end{abstract}     \end{document}      **EDIT:** I commented `\UndoBoundary{-}` and `\SearchList` out. The dash at the end of the line works as expected, now. But I would like to highlight words with dashes (e.g. Web-Verifier) in my document with `\SearchList`. Could anybody help me with this problem? PS: @admins Sorry for the inconvenience.


title: Problem with pmatrix

text: I'm trying to use pmatrix as follows:               \begin{equation}\label{Eq.11}     J =     \begin{pmatrix}       \frac{\partial c_{1}(t+1)}{\partial c_{1}(t)} & \frac{\partial c_{1}(t+1)}{\partial c_{2}(t)} & \cdots & \frac{\partial c_{1}(t+1)}{\partial c_{L}(t)} \\       \frac{\partial c_{2}(t+1)}{\partial c_{1}(t)} & \frac{\partial c_{2}(t+1)}{\partial c_{2}(t)} & \cdots & \frac{\partial c_{2}(t+1)}{\partial c_{L}(t)} \\       \vdots  & \vdots  & \ddots & \vdots  \\       \frac{\partial c_{L}(t+1)}{\partial c_{1}(t)} & \frac{\partial c_{L}(t+1)}{\partial c_{2}(t)} & \cdots & \frac{\partial c_{L}(t+1)}{\partial c_{L}(t)}       \end{pmatrix}.     \end{equation}      The following errors appears:               ! Extra \right.\endpmatrix -> \endmatrix \right ) \end{pmatrix}     ! Missing $ inserted.<inserted text>$ \end{pmatrix}     ! Missing } inserted.<inserted text>} \end{pmatrix}     ! You can't use `\eqno' in math mode.\endmathdisplay@a ...\df@tag \@empty \else \veqno\alt@tag \df@tag \fi \ifx ... \end{equation}     ! Missing \right. inserted.<inserted text>\right . \end{equation}     ! Missing \endgroup inserted.<inserted text>\endgroup \end{equation}      This code works fine in other documents, but the last document I'm working on consists of several files each of which represents a chapter in the document. Any suggestion will be greatly appreciated. Thanks


title: Annotating Tables With Tikz; Adding Arrows

text: I'd like to be able to draw an arrow with some text on top connecting two arbitrary (i.e. possibly non-right-/left-most, possibly nonadjacent) cells of a table with a left-looking arrow. In particular, I'm trying to get an arrow on the top of a table similar in looks to what you get here, though my tables don't contain numbers in their cells, and I'm looking for a solution that doesn't connect all and only pairwise adjacent cells. I'm not sure what the right way to modify this is. I'm working with `beamer`, and using `tikz` (though I'm quite new to it) and `tabularx`. Is there a way to do this? Edit: Here's a code like the one I'm messing with. I'm not sure how to fix.                   \documentclass[pdf]{beamer}         \mode<presentation>{}         \usepackage[english]{babel}         \usepackage{natbib}         \usepackage{color, colortbl}         \renewcommand{\bibnumfmt}[1]{#1.}         \usepackage{ marvosym }         \usepackage{ tikzsymbols }         \usepackage{ wasysym }         \usepackage{tikz}         \usetikzlibrary{tikzmark, positioning, fit,shapes.misc}              \usetikzlibrary{decorations.pathreplacing, calc}                        \newcommand{\tikzmark}[2][-3pt]{\tikz[remember picture, overlay, baseline=-0.5ex]\node[#1](#2){};}                   \tikzset{brace/.style={decorate, decoration={brace}},              brace mirrored/.style={decorate, decoration={brace,mirror}},             }                    \newcounter{brace}               \setcounter{brace}{0}               \newcommand{\drawbrace}[3][brace]{%               \refstepcounter{brace}              \tikz[remember picture, overlay]\draw[#1] (#2.center)--(#3.center)node[pos=0.5, name=brace-\thebrace]{};            }                \newcounter{arrow}           \setcounter{arrow}{0}           \newcommand{\drawcurvedarrow}[3][]{%           \refstepcounter{arrow}           \tikz[remember picture, overlay]\draw (#2.center)edge[#1]node[coordinate,pos=0.5, name=arrow-\thearrow]{}(#3.center);            }                 \newcommand{\annote}[3][]{%            \tikz[remember picture, overlay]\node[#1] at (#2) {#3};            }                           \newcommand\marktopleft[1]{             \tikz[overlay,remember picture]              \node (marker-#1-a) at (0,1.5ex) {};           }            \newcommand\markbottomright[1]{            \tikz[overlay,remember picture]            \node (marker-#1-b) at (0,0) {};           \tikz[overlay,remember picture,thick,dashed,inner sep=3pt]           \node[draw,rounded rectangle,fit=(marker-#1-a.center) (marker-#1-b.center)] {};           }               \usepackage{tabularx}          \usepackage{stmaryrd}          \usepackage{amsmath}         \usepackage{mathtools}         \usepackage{xcolor}             \makeatletter        \newcommand{\redub}{}         \def\redub#1{%         \@ifnextchar_%           {\@redub{#1}}           {\@latex@warning{Missing argument for \string\redub}\@redub{#1}_{}}%          }           \def\@redub#1_#2{%           \colorlet{currentcolor}{.}%           \color{red}%           \underbrace{\color{currentcolor}#1}_{\color{red}#2}%           \color{currentcolor}%          }                \newcounter{savedenumi}           \newenvironment{moreenum}{%            \setcounter{savedenumi}{\value{enumi}}%            \begin{enumerate}\setcounter{enumi}{\value{savedenumi}}%         }{%           \end{enumerate}%          }           \AtBeginSection[]        {         \begin{frame}<beamer>             \frametitle{}             \tableofcontents[currentsection]          \end{frame}         }                        \newcolumntype{g}{>{\columncolor{red}}c}                    \begin{document}          \begin{frame}          \begin{tabular}{ | l | l |}             \hline             letter & number \\ \hline             \tikzmark[xshift=-8pt,yshift=1ex]{x}A &  1\tikzmark[xshift=3.5em]{a} \\ \hline              A &  2 \\ \hline             \tikzmark[xshift=-8pt,yshift=-1ex]{y}A &  1\tikzmark[xshift=3.5em]{b} \\ \hline             \tikzmark[xshift=-8pt,yshift=1ex]{w}B &  1 \\ \hline             \tikzmark[xshift=-8pt,yshift=-1ex]{z}B &  2 \\ \hline         \end{tabular}        \drawcurvedarrow[bend left=60,-stealth]{a}{b}        \drawbrace[brace mirrored, thick]{x}{y}        \drawbrace[brace mirrored, thick]{w}{z}        \annote[right]{arrow-1}{Duplicate}        \annote[left]{brace-1}{A}        \annote[left]{brace-2}{B}                 \tikzset{       every picture/.style={remember picture,baseline},       every node/.style={         inner sep=0pt,         anchor=base,         minimum width=1.8cm,         align=center,         text depth=.25ex,         outer sep=1.5pt},       every path/.style={       thick,        rounded corners       }      }             \begin{table}        \centering         \begin{tabular}{|c|c|c|g|c|}          \hline         bla   &  bla  & bla   & $b_1$\tikzmark{a} \\ \hline         bla   &  bla  & bla   & bla \\\hline            bla   &  bla  & bla   & bla \\\hline            bla   &  bla  & bla   & bla \\\hline         bla   &  bla  & bla   & bla \\\hline           \end{tabular}       \end{table}     \begin{tikzpicture}[remember picture,overlay]     \node [right=2cm,above=2cm,minimum width=0pt] at (pic cs:a) (A) {A};     \draw [<-,out=5,in=180] ([xshift=15pt]{pic cs:a}) to (A);     \end{tikzpicture}     \end{frame}          \end{document}


title: Text color in natural table heading in ConTeXt

text: I'm new to ConTeXt and having a problem with colors of header in a "natural table". I want to have the text in the header displayed as white, and not gray. Here is what I have right now               \setuppapersize[letter]     \language[fr]     \setupbodyfont[12pt,ss]     \enableregime[utf]     \setupcolors[state=start]     \definecolor[white][r=1,g=1,b=1]     \definecolor[darkblue][r=.22,g=.42,b=.52]     \definecolor[grayWriting][r=.31,g=.31,b=.31]     \definecolor[grayPale][r=.92,g=.94,b=.95]     \definecolor[graySub][r=.75,g=.83,b=.87]          \starttext     \startcolor[grayWriting]     \setuphead[subject][style=bold,14pt,rm]     \subject{Subject}     \setupTABLE[row][even]     [background=color,backgroundcolor=white,frame=off]     \setupTABLE[row][odd]     [background=color,backgroundcolor=grayPale,frame=off]     \setupTABLE[header][each]     [background=color,backgroundcolor=darkblue,textcolor=white,style=bold]     \setupTABLE[c][each][width=.25\textwidth]     \bTABLE[frame=off,align=right,split=repeat,option=stretch]% head on every page,     \bTABLEhead     \bTR     \bTH ~ \eTH     \bTH H2 \eTH     \bTH H3 \eTH     \bTH H4 \eTH     \eTR     \eTABLEhead     \bTABLEnext % setup for next table head     \bTR     \bTH ~ \eTH     \bTH H2 \eTH     \bTH H3 \eTH     \bTH H4 \eTH     \eTR     \eTABLEnext     \bTABLEbody     \bTR     \bTD 1 \eTD     \bTD 2 \eTD     \bTD 3 \eTD     \bTD 4 \eTD     \eTR     \bTR     \bTD 1 \eTD     \bTD 2 \eTD     \bTD 3 \eTD     \bTD 4 \eTD     \eTR     \bTR     \bTD 1 \eTD     \bTD 2 \eTD     \bTD 3 \eTD     \bTD 4 \eTD     \eTR     \bTR     \bTD 1 \eTD     \bTD 2 \eTD     \bTD 3 \eTD     \bTD 4 \eTD     \eTR     \eTABLEbody     \eTABLE     \stoptext      which gives an output of ![output](http://i.stack.imgur.com/3m1RA.png) Any help would be appreciated. I know that I could write `{\color[white] H1}` in my heading cells, but I really want to avoid it.


title: \left( and \right) too big when surrounding a sum (etc.) with no superscript; exacerbated by substack

text: When I write               \varphi^{-1}\left(\bigcap_{\substack{\mathfrak{p} < B \\ p \text{ prime}}} \mathfrak{p}\right)      I get something like this: ![enter image description here](http://i.stack.imgur.com/ExaNV.jpg) Apparently it's leaving symmetric amounts of room for the sub- and superscripts. How do I get rid of all that excess space at the top? EDIT: It's not so clear from the closeup I posted, but here's an example of how ridiculous it looks in context: ![enter image description here](http://i.stack.imgur.com/y3ooF.jpg)


title: How to use \checkmark and Cambria Math?

text: In a document I need to use Cambria Math but at the same time be able to use `\checkmark` for an `itemize` environment. But as soon as I load `unicode- math` the checkmark disappears. Is there a work around for this? I am compiling the following MWE with `lualatex` (TeX Live 2013/dev):               \documentclass{article}     \usepackage{amsfonts} % for the \checkmark command      \usepackage{unicode-math} % hides \checkmark?      \usepackage{fontspec}     \setmainfont{Cambria}     \setsansfont{Calibri}     %\setmathfont{Cambria Math}               \begin{document}      $a + b$     \begin{itemize}     \item[\checkmark] a     \item[\checkmark] b      \item[\checkmark] c     \end{itemize}          \end{document}


title: Remove (Tech.Rep.) from Bibliography

text: I have a case similar to this one : Remove "Tech. Rep." Output from SIAM bibtex style but using apacite. When I did what was advised in the above-mentioned topic, the result was the () but without the words in them, i.e from ".....(Tech.Rep.)..." to "...()...". Is there a way to get rid of the brackets and to apply this globally for the entire bibliography rather than entry by entry?               \documentclass[12pt,twoside,a4paper]{book}     \usepackage[english]{babel}     \usepackage{apacite}          \begin{document}     \cite{iso3}     \bibliographystyle{apacite}     \bibliography{alternative}     \end{document}               @techreport{iso3,     Author = {ISO/IEC },     Date-Added = {2013-04-10 19:39:43 +0000},     Date-Modified = {2013-04-14 05:05:06 +0000},     Institution = { International Organization for Standardization, Geneva, Switzerland.},     Title = {{ISO}/{IEC} 9126-1:2001, {S}oftware engineering - {P}roduct quality, {P}art 1:{Q}uality model},     Year = {2001}}


title: Tikz: Drawing railway tracks

text: I like to draw a double line such that the gap between the two lines is transparent. My purpose is to draw railway tracks:                \documentclass[tikz]{standalone}           \tikzstyle{track}=[        postaction={draw=gray,densely dashed,line width=14pt},        postaction={draw=black,double distance=8pt,line width=2pt},        postaction={draw=gray,densely dashed,line width=8pt},]           \begin{document}           \begin{tikzpicture}           \draw[track] (-5,27) to[out=  0,in=180] ( 5,33)                            to[out=  0,in= 90] ( 7,25)                            to[out=270,in=  0] (-5,27);           \draw[track] (-4,10) to (0,10) to[out=  0,in=270] (4,16);      \draw[track] (12,10) to (8,10) to[out=180,in=270] (4,16) to (4,20);           \draw[track] (-4,0) to (12,0);           \draw[track] (0,0) to[out=  0,in=270] (3,2)                          to[out= 90,in=270] (1,4)                         to[out= 90,in=180] (4,6)                          to[out=  0,in=120] (8,5)                          to[out=300,in=  0] (4,0);      \end{tikzpicture}           \end{document}      The second postaction draws a double line, but the gap between the two lines is not transparent. Therefore, I made the third postaction. But I expect that the tracks will look much more realistic (in particular at the switches) if the gap of the double lines is transparent. Any ideas? ![](http://i.stack.imgur.com/Wb0xK.png)


title: misplaced & in equation using non-ams format

text: the following code works with ams environment, however I am trying to use it using aip conference template found here: http://scitation.aip.org/content/aip/proceeding/aipcp/info/authors and it is complaining about a misplaced alignment tab character in the 3rd line.               \begin{equation}\label{eq:sinuramp}     I(x)=      \begin{cases} s(x) & \text{if $x \le L/n$,}      \\     s'(L/n)*x - s'(L/n)*L/n+s(L/n) &\text{if $x>L/2$.}     \end{cases}     \end{equation}      Additionally, this code was output with mathematica.. and other equations work just fine as long as they do not have the '&' character. thank you.


title: EulerVm and Maketitle

text: I am unable to use the `eulervm` package with `maketitle`. If I comment out the `\usepackage{eulervm}` the LaTeX renders fine, but as soon as I include it, I get the following > ! Math formula deleted: Insufficient symbol fonts. \endtabular ->\crcr > \egroup \egroup $ \egroup l.16 \maketitle Are these not compatible? Is there any way to make them so? Or is there another command that would substitute for maketitle?    Minimal Working Example as asked for in comments.               \documentclass[a4paper,10pt]{article}               \usepackage{eulervm}               \title{The Cave}     \author{Batman, Robin}     \date{}     \begin{document}          \maketitle     \end{document}


title: Lyx IEEEtran template copyright overlaps text, authors not appearing

text: How do you make certain that the copyright and publisher id mark are correctly located at the bottom of an IEEEtran template Lyx document when rendered as PDF? I've tried a couple of suggestions but no matter what it always appears to overlap with the text of the document at the bottom of page 1 (see first image). Also, although it specifies in the template that your name and paper title will appear next to the name of the journal it doesn't render in the pdf even for the example that comes with a fresh install of Lyx. How do you get the authors and paper title to appear with the journal title in the upper left corner of the pdf? (see 2nd image). issue with copyright overlapping and author names as programmed in the Lyx example that do not show in the pdf in the upper left corner with the journal name: ![copyright](http://i.stack.imgur.com/uQkOm.png) ![enter image description here](http://i.stack.imgur.com/scHPF.png) Here's some suggestions I attempted but none worked: problem having copyright notice and header at the same time in IEEEtrans template http://www.michaelshell.org/tex/ieeetran/ (see publisher ID mark)


title: Overlapping ticks and figure not centered with matlab2tikz

text: See the printscreen. What I want is that the figure is centered, now that is not the case with using `\setlength\figurewidth{1.0\textwidth}`. Besides that the ticks with negative signs on the x-axis are overlapping. How can I solve these issues? Thanks :) How it now looks: ![enter image description here](http://i.stack.imgur.com/SrIYa.png) Code               \begin{tikzpicture}          \begin{axis}[%     width=\figurewidth,     height=\figureheight,     %scale only axis, % Commented out as suggested in the answer     xmin=-2000,     xmax=500,     ymin=-1000,     ymax=400,     xtick={-1600,-1200,-800,-400,0,400}, % Now added to solve     ytick={-800,-400,0,400} % Now added     ]     \addplot [color=red,solid,forget plot]       table[row sep=crcr]{%     0   0\\     0.198854299827786   -3.4314342957753e-05\\     0.390189269262637   0.000572951530544596\\     0.580159224048429   0.00169575075199724\\     0.776528090033777   0.00282710506604467\\     0.984098727468267   0.00371200672468541\\


title: How to align Matrix and Tikzpicture on the same horizontal line

text: I'm using subfloat to try to align my diagram with the matrix array. I want them to be next to each other, and per suggestion, used the subfloats to try to align them. I'm getting error messages. While this is a relatively uncomplicated code, I cannot figure out the problem.                   \documentclass[11pt,oneside]{article}     \usepackage[demo]{graphicx}     \usepackage{subfig}     \usepackage{tikz}     \usetikzlibrary{matrix}     \usetikzlibrary{positioning,shapes}               \begin{document}                    \begin{figure}[H]     \centering      \subfloat[label 1]{     \begin{tikzpicture}[scale=3,line width=1pt]     \tikzstyle{every node}=[draw=black,fill=yellow!50!white,thick,       shape=circle,minimum height=0.0001cm       ];      \draw (.5773502693, 0.)--(-.2886751347, .5000000000);     \draw (.5773502693, 0.)--(-.2886751347, -.5000000000);     \draw (.5773502693, 0.)--(.2886751347, .9574271080);     \draw (-.2886751347, .5000000000)--(-.2886751347, -.5000000000);     \draw (-.2886751347, .5000000000)--(-.9734937648, -.2287135539);     \draw (-.2886751347, -.5000000000)--(.6848186302, -.7287135539);     \draw (.2886751347, .5000000000)--(-.5773502693, 0.);     \draw (.2886751347, .5000000000)--(.2886751347, -.5000000000);     \draw (.2886751347, .5000000000)--(-.6848186302, .7287135539);     \draw (-.5773502693, 0.)--(.2886751347, -.5000000000);     \draw (-.5773502693, 0.)--(-.2886751347, -.9574271080);     \draw (.2886751347, -.5000000000)--(.9734937648, .2287135539);     \draw (.2886751347, .9574271080)--(-.6848186302, .7287135539);     \draw (.2886751347, .9574271080)--(.9734937648, .2287135539);     \draw (-.6848186302, .7287135539)--(-.9734937648, -.2287135539);     \draw (-.9734937648, -.2287135539)--(-.2886751347, -.9574271080);     \draw (-.2886751347, -.9574271080)--(.6848186302, -.7287135539);     \draw (.6848186302, -.7287135539)--(.9734937648, .2287135539);     \node at (.5773502693, 0) {1};     \node at (-.2886751347, .5000000000) {2};     \node at (-.2886751347, -.5000000000) {3};     \node at (.2886751347, .5000000000) {4};     \node at (-.5773502693, 0.) {5};     \node at (.2886751347, -.5000000000) {6};     \node at (.2886751347, .9574271080) {7};     \node at (-.6848186302, .7287135539) {8};     \node at (-.9734937648, -.2287135539) {9};     \node at (-.2886751347, -.9574271080) {10};     \node at (.6848186302, -.7287135539) {11};     \node at (.9734937648, .2287135539) {12};     \end{tikzpicture}}          \begin{tikzpicture}     \tikzset{         table/.style={             matrix of nodes,             row sep=-\pgflinewidth,             column sep=-\pgflinewidth,             nodes={                 rectangle,                 draw=black,                 align=center             },             minimum height=2.5em,             text depth=0.5ex,             text height=0.5ex,             nodes in empty cells,     %%             every even row/.style={                 nodes={fill=gray!20}             },             column 1/.style={                 nodes={text width=2em,font=\bfseries}             },             row 1/.style={                 nodes={                     fill=black,                     text=white,                     font=\bfseries                 }             }         }     }     \matrix (first) [table,text width=4cm]     {     & X & Y\\     1 & $\sqrt{3}/3$ & $0$ \\     2 & $-\sqrt{3}/6$ & $1/2$ \\     3 & $-\sqrt{3}/6$ & $-1/2$ \\     4 & $\sqrt{3}/6$ & $1/2$ \\     5 & $-\sqrt{3}/3$ & $0$ \\     6 & $\sqrt{3}/6$ & $-1/2$ \\     7 & $\sqrt{3}/6$ & $\sqrt{33}/6$ \\     8 & $\sqrt{3}/12-\sqrt{11}/4$ & $1/4+\sqrt{33}/12$ \\     9 & $-\sqrt{3}/12-\sqrt{11}/4$ & $1/4-\sqrt{33}/12$ \\     10 & $-\sqrt{3}/6$ & $-\sqrt{33}/6$ \\     11 & $-\sqrt{3}/12+\sqrt{11}/4$ & $-1/4-\sqrt{33}/12$ \\     12 & $\sqrt{3}/12+\sqrt{11}/4$ & $-1/4+\sqrt{33}/12$ \\     };          \end{tikzpicture}%               \end{figure}     \end{document}


title: Change the way XeTeX sees a string before running/building PDF

text: For some reason, I'm really struggling to articulate my question, so let me apologise in advance. I may not be approaching this from the right angle. I'm working in XeTeX (and it's far too late to change to LuaTeX). The font I've chosen has the problem with ligatures displaying properly, but containing garbage when copy-and-pasted from the resulting PDF. This also makes the PDF much less searchable, since, e.g., "flow" won't be found because of the "fl" ligature. After a significant amount of googling, it appears to me that there is no proper solution to address this yet. One less-than-ideal option is to use the `accsupp` package, and to provide XeTeX and the PDF with different strings. For example, this works:               \documentclass{article}     \usepackage{fontspec}     \setmainfont{Minion Pro}          \usepackage{accsupp}          \newcommand\ligfl{\BeginAccSupp{method=escape,ActualText=fl}fl\EndAccSupp{}}          \begin{document}     flow vs. {\ligfl}ow     \end{document}      (Before anyone suggests it, I'm not actually using Minion Pro, so `\usepackage{MinionPro}` is not the way to go for me.) One option would be to do a find-and-replace on "fi", "ffi", "fl", and "ffl" to change them to commands like the `\ligfl` above. This is doable, and I may have to resort to it, but before I do, is there a more flexible, elegant way to do it than the hard-coding above? What I would ideally like to do is either:   1. make the "ligaturisable" character pairs or triplets active, and have, e.g., each `fl` automatically interpreted as `{\ligfl}`. I may have been searching incorrectly, but there appears to be no way to do this; or   2. use some sort of pre-processor or similar which would change all `fl`s to `{\ligfl}`s just before the document is built. (Realistically, though, I think I'd struggle with this option as I'm working in LyX.) or, of course, a third option I haven't thought of. Any help would be greatly appreciated.


title: Hyperref and hyperlinks

text: With the following MWE:               \documentclass[a4paper]{report}     \usepackage{hyperref}          \begin{document}     \href{en.wikipedia.org}{\emph{gungumapu}}     \href{en.wikipedia.org}{gungumapu}     \end{document}      I would expect "gungumapu" to appear in `emph` (italic) typeface and in plain upright typeface, both times with a link under it, i.e. if I click on either appearance of "gungumapu", I'd expect `en.wikipedia.org` to open in my browser. Only that doesn't happen. Why is that? Is my expectation wrong? If so, how do I put a hyperlink in my document?


title: How to create following block diagram structure in LaTeX

text: ![Cascading Blocks](http://i.stack.imgur.com/pVaQQ.jpg) How can i create this kind of connected and cascading block diagram in Latex?


title: Evenly distributing column widths

text: Consider the following hunk of code:               \begin{tabular}{| c | c | c | c | c | c | c | }     \cline{2-7}     \multicolumn{1}{c}{} & \multicolumn{3}{|c|}{Fantastical aardvarks}       & \multicolumn{3}{c|}{Spelunking elephants}\\     \hline      Foo bar & A & B & C & A & B & C\\     \hline      5 & 87 &  5 &  2 & 82 & 18 & 48\\      6  & 5 & 43 &  4 & 7 & 47 & 4\\      7 &  7 &  18 & 63 & 2 & 9 & 99\\     \hline     \end{tabular}      ![misaligned tables](http://i.stack.imgur.com/krDyg.png) Is there a way to have the three columns under "Fantastical aardvarks" and, separately, under "Spelunking elephants" have widths that are evenly distributed? I'm particularly interested in an _automated_ way of doing this, without needing to directly specify column widths.


title: How to stack limits for maths operators?

text: I have a question on how is it possible to create a `\sum` with two lower limits directly positioned right underneath each other. I have tried hard and cant seem to get anywhere with it.


title: Positioning tikz nodes to the top

text: I have four circles in a beamer frame,               \begin{tikzpicture}[% common options for the circles:     ball/.style = {circle, draw, align=center, anchor=north, inner sep=0}]          \node<1>[ball,text width=1.5cm,fill=blue!20,draw=blue!20] (Post) at (6,2) {Post};     \node<2,3,4>[ball,text width=1.5cm,fill=purple!20,draw=purple!20] (A) at (6,2) {A};               \node<2>[ball,text width=1.5cm,fill=blue!20,draw=blue!20] (B) at (9,2) {B};     \node<1,3,4>[ball,text width=1.5cm,fill=purple!20,draw=purple!20] (B) at (9,2) {B};               \node<3>[ball,text width=1.5cm,fill=blue!20,draw=blue!20] (C) at (12,2) {C};     \node<1,2,4>[ball,text width=1.5cm,fill=purple!20,draw=purple!20] (C) at (12,2) {C};          \node<4>[ball,text width=1.5cm,fill=blue!20,draw=blue!20] (D) at (15,2) {D};     \node<1,2,3>[ball,text width=1.5cm,fill=purple!20,draw=purple!20] (D) at (15,2) {D};               \end{tikzpicture}      The problem is, when I change the y-coordinate of a node, it shifts up relative to the others. But as soon as I change it to the same value for all of them-- they all come back to the center. How can I make them all shift to the top of the slide/frame?


title: Why is biber so slow?

text: I have a simple document, about 20 pages long with some mathematics and a couple of tikz diagrams. I use biblatex and biber (0.9.9 MacTeX 2011) to compile my references, of which there are currently 2, with maybe 10 citations. When using the bibtex backend the bibliography stage of my compilation takes under a second. Biber takes over 5 seconds to process exactly the same file. I use TeXShop and with biber the console window appears but none of biber's command line output appears for at least 4 seconds. Is there a problem with my setup or is biber slow by design? EDIT: yes, it is slow every time. I've done some digging into the folders where biber unpacks its perl dependencies and I think TeXShop might be unpacking it every time. Perhaps something deletes the unpacked binary after each use. The way I've made TeXShop use biber is to change the bibTeX engine field in the preferences to `biber'.


title: Custom table of contents with appendices, how to get 'Chapter' and 'Appendix'

text: I try to generate a table of contents which hopefully should look something like > **Chapter 1** First chapter .... > > **Chapter 2** Second chapter .... > > **Appendix A** First appendix .... > > **Appendix B** Second appendix .... So far I have tried the following,               \documentclass{book}     \usepackage{titlesec}     \usepackage{titletoc}     \usepackage[titletoc]{appendix}          \titlecontents{chapter}%      [0em]%       {\addvspace{2em}}%      {\bfseries\chaptername\ \thecontentslabel\quad}%       {\hspace{-0em}}%       {\hfill\contentspage}%       [\addvspace{0pt}]%           \usepackage{lipsum}     %     \begin{document}     \tableofcontents     \chapter{First chapter}\lipsum[1]     \section{First section}\lipsum[2]     \subsection{First subsection}\lipsum[3]     \chapter{Second chapter}\lipsum[4]     \section{Second section}\lipsum[5]     \subsection{Second subsection}\lipsum[6]     \subsection{Third subsection}\lipsum[7]     %appendices      \begin{appendices}     \chapter{First appendix}\lipsum[1]     \section{Some section}\lipsum[2]     \subsection{Some subsection}\lipsum[3]     \subsection{Some subsection}\lipsum[4]     \chapter{Second appendix}\lipsum[5]     \section{Some section}\lipsum[6]     \subsection{Some subsection}\lipsum[7]     \end{appendices}     %     \end{document}      But this seems to give the output ![Table of contents](http://i.stack.imgur.com/ppsj6.png) So, it is clear that there have to be something like `if 'appendix', write Appendix`, but I do not know how to put this into LaTeX logic. However it seems to be even more problems to my approach. Do anyone know how to solve this? Or have tricks how to create nice looking table of contents?


title: editing the counting of section

text: I've found this .cls template on the web and modified it a little bit (I deleted the title page part, otherwise my post would be to long):               %%      %% This file is part of the LaTeX2e system.      %% ----------------------------------------      %%      \NeedsTeXFormat{LaTeX2e}     \ProvidesClass{thesis}[2009/01/06 Rensselaer Polytechnic Institute]     %  Note that the setspace package is built in (code included near the end of      %  this file) to provide "line-and-a half spacing" (1.4 by default) and also     %  the singlespace environment.           % RPI option chap:     \newif\ifchap  % true for chap option       \chapfalse   % false by default     \DeclareOption{chap}{\chaptrue} % option to print "Chapter" at each new chapter     \newcommand\docsize{}  % to allow 10pt or 11pt to be specified as option     \DeclareOption{10pt}{\renewcommand\docsize{10pt}}     \DeclareOption{11pt}{\renewcommand\docsize{11pt}}     \DeclareOption{12pt}{\renewcommand\docsize{12pt}}     %  Prepare to load the standard report class (12pt):     \DeclareOption*{\PassOptionsToClass{\CurrentOption}{report}}     \ExecuteOptions{12pt}         % define 12pt as the default doc size     \ProcessOptions     \LoadClass[\docsize]{report}  % load report.cls     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%               %  The following sections are revisions or additions to report.cls     %     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %  FOOTNOTES:   make them continuously numbered throughout document     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     % define command that can undo having footnotes reset with each chapter:     % (taken from removefr.sty by Donald Arseneau)      \def\@removefromreset#1#2{\let\@tempb\@elt        \expandafter\let\expandafter\@tempa\csname c@#1\endcsname        \def\@elt##1{\expandafter\ifx\csname c@##1\endcsname\@tempa\else              \noexpand\@elt{##1}\fi}%        \expandafter\edef\csname cl@#2\endcsname{\csname cl@#2\endcsname}%        \let\@elt\@tempb}     % use the command \@removefromreset to undo the \@addtoreset in report.cls:     \@removefromreset{footnote}{chapter}     %     % define command to allow people to reset footnote counter at will:      \def\resetfootnote{\setcounter{footnote}{0}}  % definition to reset footnote               %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     % PAGE LAYOUT     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     % SIDE MARGINS:     \if@twoside                 % Values for two-sided printing:        \oddsidemargin .55in     %   Left margin on odd-numbered pages.        \evensidemargin .05in    %   Left margin on even-numbered pages.        \marginparwidth 40pt     %   Width of marginal notes.     \else                       % Values for one-sided printing:        \oddsidemargin 0.55in    %   Note that \oddsidemargin = \evensidemargin        \evensidemargin 0.55in        \marginparwidth 40pt     \fi     \marginparsep 10pt          % Horizontal space between outer margin and                                 % marginal note     \textwidth 5.9in            % width of text          % VERTICAL SPACING:                              % Top of page:     \topmargin -.5in         %    distance from top of page to running head     \headheight 14pt         %    Height of box containing running head.     \headsep .4in            %    Space between running head and text.     \textheight 8.8in        %    space for text     \footskip 30pt           %    Distance from baseline of box containing foot                              %    to baseline of last line of text.               %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %                            SECTION HEADINGS     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%      \newcommand\chaptersize{\large}     \newcommand\sectionsize{\large}     \newcommand\subsectionsize{\normalsize}     \newcommand\subsubsectionsize{\normalsize}     \newcounter{firstchapter}     \setcounter{firstchapter}{0}          \setcounter{secnumdepth}{3}    % Number subsubsections in the chapters     \setcounter{tocdepth}{3}       % Put subsubsections in the table of contents          % Print "CHAPTER" if chap option is specified:     \ifchap       \renewcommand\@chapapp{\chaptername}     \else       \renewcommand\@chapapp{}     \fi          \def\specialhead#1{%   GENERAL HEADING WITHOUT A NUMBER (for abstract, etc.)          \ifx\phantomsection\undefined          \else             \clearpage\phantomsection          \fi          \addcontentsline{toc}{chapter}{#1}          \chapter*{\centering #1 \@mkboth{#1}{#1}}}               \def\@chapter[#1]#2{\ifnum\c@firstchapter=0    % start of rpi added stuff                           \if@twoside\cleardoublepage\suppressfloats[t]\fi                           \pagenumbering{arabic}                            \setcounter{firstchapter}{1}                         \fi                         \renewcommand{\thepage}{\arabic{page}}                         \thispagestyle{plain}                         \pagestyle{myheadings}      % end of rpi added stuff                         \ifnum \c@secnumdepth >\m@ne                              \refstepcounter{chapter}%                              \typeout{\@chapapp\space\thechapter.}%                              \addcontentsline{toc}{chapter}%                                        {\protect\numberline{\thechapter.}#1}%                         \else                           \addcontentsline{toc}{chapter}{#1}%                         \fi                         \chaptermark{#1}%      %                    \addtocontents{lof}{\protect\addvspace{10\p@}}%     %                    \addtocontents{lot}{\protect\addvspace{10\p@}}%                         \if@twocolumn                           \@topnewpage[\@makechapterhead{#2}]%                         \else                           \@makechapterhead{#2}%                           \@afterheading                         \fi}     \def\@makechapterhead#1{%       \vspace*{0\p@}%       {\parindent \z@ \raggedright \centering \normalfont \chaptersize         \ifnum \c@secnumdepth >\m@ne           \ifchap              \bfseries \@chapapp{} \thechapter    % print "Chapter" and number              \vskip -3pt           %\par\nobreak (original)            \else              \bfseries \thechapter.             \fi         \fi         \interlinepenalty\@M         \bfseries #1\par\nobreak         \vskip 15\p@       }}          \def\@makeschapterhead#1{%    heading for chapter* command (no numbering)       \vspace*{0\p@}%       {\parindent \z@ \raggedright \centering         \normalfont  \chaptersize          \interlinepenalty\@M         \bfseries  #1\par\nobreak         \vskip 15\p@       }}          \renewcommand\section{\@startsection {section}{1}{\z@}%                                        {3.5ex \@plus 1ex \@minus .2ex}%                                        {.5ex \@plus .3ex}%{1.4ex \@plus.2ex}%                                        {\normalfont\sectionsize\bfseries}}     \renewcommand\subsection{\@startsection{subsection}{2}{\z@}%                                          {3.25ex\@plus 1ex \@minus .2ex}%                                          {.3ex \@plus .2ex}%{1.2ex \@plus .2ex}%                                          {\normalfont\subsectionsize\bfseries}}     \renewcommand\subsubsection{\@startsection{subsubsection}{3}{\z@}%                                          {3.25ex\@plus 1ex \@minus .2ex}%                                          {.2ex \@plus .1ex}%{1ex \@plus .2ex}%                                          {\normalfont\subsubsectionsize\bfseries}}     % \paragraph and \subparagraph headings unchanged from report.cls.               %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %  APPENDIX     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     \renewcommand\appendix{\par       \setcounter{chapter}{0}%       \setcounter{section}{0}%       \chaptrue       \renewcommand\@chapapp{\appendixname}%       \renewcommand\thechapter{\@Alph\c@chapter}}               %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %  FIGURES and TABLES     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %control float placement:     %     \setcounter{topnumber}{2}     \renewcommand\topfraction{.8}     \setcounter{bottomnumber}{2}     \renewcommand\bottomfraction{.8}     \setcounter{totalnumber}{4}     \renewcommand\textfraction{.2}     \renewcommand\floatpagefraction{.8}     \setcounter{dbltopnumber}{2}     \renewcommand\dbltopfraction{.8}     \renewcommand\dblfloatpagefraction{.8}          \long\def\@makecaption#1#2{%       \vskip\abovecaptionskip       \sbox\@tempboxa{\bfseries#1:~~#2}%   Make caption bold       \ifdim \wd\@tempboxa >\hsize        {\bfseries #1:~~#2}\par%            Make caption bold       \else         \global \@minipagefalse         \hb@xt@\hsize{\hfil\box\@tempboxa\hfil}%       \fi       \vskip\belowcaptionskip}          %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %  TABLE of CONTENTS,  LIST OF TABLES,  LIST OF FIGURES      %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%          \renewcommand\tableofcontents{%         \if@twocolumn           \@restonecoltrue\onecolumn         \else           \@restonecolfalse         \fi         \chapter*{\contentsname             \@mkboth{%                \MakeUppercase\contentsname}{\MakeUppercase\contentsname}}%         \vskip -1em \begin{singlespace}      % singlespacing         \@starttoc{toc}%         \if@restonecol\twocolumn\fi         \end{singlespace}         }          \renewcommand*\l@chapter{\pagebreak[3]\vskip 10pt plus 1pt minus 1pt                              \@dottedtocline{0}{0em}{1.4em}}     \renewcommand*\l@section{\vskip 6pt plus 1pt minus 1pt                              \@dottedtocline{1}{1.5em}{2.3em}}     \renewcommand*\l@subsection{\ifnum\c@tocdepth>1\vskip 4pt minus 1pt \fi                              \@dottedtocline{2}{3.8em}{3.2em}}     \renewcommand*\l@subsubsection{\ifnum\c@tocdepth>2 \vskip 3pt minus 1pt \fi                              \@dottedtocline{3}{7.0em}{4.1em}}          % The following removed because it's not consistent with entries from longtable     %% modify the definition below (taken from latex.ltx) to include      %% "Table" and "Figure" in entries for lot and lof:      %\long\def\@caption#1[#2]#3{%\baselineskip 14.5 pt     %  \addcontentsline{\csname ext@#1\endcsname}{#1}%     %  {\protect\numberline{\csname fnum@#1\endcsname}{\ignorespaces #2}}%     %  \begingroup     %    \@parboxrestore     %    \normalsize     %    \@makecaption{\csname fnum@#1\endcsname}{\ignorespaces #3}\par     %  \endgroup}          \renewcommand\listoffigures{%         \if@twocolumn           \@restonecoltrue\onecolumn         \else           \@restonecolfalse         \fi         \ifx\phantomsection\undefined           \else             \clearpage\phantomsection           \fi         \addcontentsline{toc}{chapter}{\listfigurename}  % add lof to toc         \chapter*{\centering\listfigurename  % center it           \@mkboth{\MakeUppercase\listfigurename}%                   {\MakeUppercase\listfigurename}}%         \vskip -1em \begin{singlespace}  % singlespacing         \@starttoc{lof}%         \if@restonecol\twocolumn\fi         \end{singlespace}         }          \renewcommand\listoftables{%         \if@twocolumn           \@restonecoltrue\onecolumn         \else           \@restonecolfalse         \fi         \ifx\phantomsection\undefined           \else             \clearpage\phantomsection           \fi         \addcontentsline{toc}{chapter}{\listtablename}  % add lot to toc         \chapter*{\centering\listtablename  % center it           \@mkboth{\MakeUppercase\listtablename}%                   {\MakeUppercase\listtablename}}%             \vskip -1em \begin{singlespace}  % singlespacing         \@starttoc{lot}%         \if@restonecol\twocolumn\fi         \end{singlespace}         }          %remove following at same time as remove code to put "Figure" in LOF     %\renewcommand*\l@figure{\vskip 10pt plus 1pt minus 1pt     %                       \@dottedtocline{1}{0em}{5.8em}}          \renewcommand*\l@figure{\vskip 10pt plus 1pt minus 1pt                            \@dottedtocline{1}{0em}{2.8em}}     \let\l@table\l@figure          \let\rpicaption\caption     \let\lrpicaption\caption               %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %  BIBLIOGRAPHY     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     % RPI def: for use in making an unnumbered bibliography with hanging indents     \def\bibentry{\vskip10pt\par\noindent\hangindent=40pt\frenchspacing}          % report definition modified for no automatic heading and use ragged right     \newcommand{\bibalign}{\raggedright}          \renewenvironment{thebibliography}[1]          {\bibalign\frenchspacing           \list{\@biblabel{\@arabic\c@enumiv}}%                {\settowidth\labelwidth{\@biblabel{#1}}%                 \leftmargin\labelwidth                 \advance\leftmargin\labelsep                 \@openbib@code                 \usecounter{enumiv}%                 \let\p@enumiv\@empty                 \renewcommand\theenumiv{\@arabic\c@enumiv}}%           \sloppy\clubpenalty4000\widowpenalty4000%           \sfcode`\.=\@m}          {\def\@noitemerr            {\@latex@warning{Empty `thebibliography' environment}}%           \endlist}               %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     % SOME INITIALIZATIONS:     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     % make the following names uppercase:     \renewcommand\contentsname{CONTENTS}     \renewcommand\listfigurename{LIST OF FIGURES}     \renewcommand\listtablename{LIST OF TABLES}     \renewcommand\bibname{BIBLIOGRAPHY}     \renewcommand\indexname{INDEX}     \renewcommand\partname{PART}     \renewcommand\chaptername{CHAPTER}     \renewcommand\appendixname{APPENDIX}     \renewcommand\abstractname{ABSTRACT}          \renewcommand\chaptersize{\large}     \renewcommand\sectionsize{\large}     \renewcommand\subsectionsize{\normalsize}     \renewcommand\subsubsectionsize{\normalsize}          \raggedbottom          \setstretch{1.4}        % at 11 or 12pt this is line-and-a-half spacing     \parindent .4in         % Width of paragraph indentation          \markboth{}{}           % Do not include chapter titles in headers;     \pagestyle{myheadings}  % include just page numbers in upper right          \renewcommand{\bibalign}{\raggedright}  %  bibliography is ragged right     % for fully justified bibliography: \renewcommand{\bibalign}{}          \endinput     %%      %% End of file `thesis.cls'.      The problem is the following: The numbering of the theorem is like this: 1.0.3, where 1 (chapter). 0 (section) 3.(the number of the object in this section). I would like to modify the .cls template in such a way, that section starts counting at 1 instead of 0. How could I fix this, which means what do I have to change in this template? Thanks for your help math


title: Fitting TikZ picture in beamer: Difference between using \resizebox and \adjustbox?

text: \documentclass[10pt]{beamer}       \usepackage{amsmath}       \usepackage{amssymb}       \usepackage[english]{babel}       \usepackage{color}       \usepackage{float}       \usepackage[T1]{fontenc}       \usepackage[latin1]{inputenc}       \usepackage{pgf}       \usepackage{setspace}       \usepackage{textcomp}       \usepackage{tikz}       \usepackage{verbatim}       \usepackage{mathrsfs}       \usetikzlibrary{arrows,shapes}       \usepackage{adjustbox}       \usepackage{pgf,tikz}            \mode<presentation>{         \usetheme{Warsaw}         \usecolortheme{crane}         \setbeamertemplate{navigation symbols}{}         \setbeamercovered{transparent}       }            \title{Disks}            \AtBeginSubsection[]{         \begin{frame}<beamer>{Outline}         \tableofcontents[currentsection,currentsubsection]         \end{frame}       }            \begin{document}       \begin{frame}{Initial solution}       %\begin{adjustbox}{max size={.95\textwidth}{.8\textheight}}       \resizebox{11.5cm}{!}{%       \begin{tikzpicture}[line cap=round,line join=round,>=triangle 45,x=1cm,y=1cm]%, scale=0.5]           \coordinate (b) at (13,3) ;           \coordinate (c) at (14,3) ;           \coordinate (d) at (15,3) ;           \coordinate (i) at (9,5)  ;           \coordinate (g) at (9,4)  ;           \coordinate (e) at (9,3)  ;           \coordinate (n) at (5,3)  ;         \coordinate (o) at (4,3)  ;           \coordinate (p) at (3,3)  ;           \coordinate (a) at (12,3) ;           \coordinate (m) at (6,3)  ;           \coordinate (h) at (10,5) ;           \coordinate (j) at (10,4) ;           \coordinate (f) at (10,3) ;           \draw (p) circle [radius = 3];           \draw (d) circle [radius = 3];       \end{tikzpicture}           }%       %\end{adjustbox}       \end{frame}       \end{document}      In the MWE above,   * When I use `\resizebox` to scale the picture, the entire picture (2 disks) are visible, provided I do not exceed 11.5cm (a value found out by trial-and-error, something I want to avoid) ![Using resizebox](http://i.stack.imgur.com/JaadX.png)   * Hence, I tried using `adjustbox` (as mentioned in the question here), but if I used `adjustbox` by commenting the `\resizebox` block and uncommenting the `adjustbox` line, the effect was as if I hadn't used it at all. (The disk on the right was completely left out of the picture.) ![Using adjustbox](http://i.stack.imgur.com/XOgYW.png) What am I doing wrong? I could finish my current slides using `\resizebox`, but I wanted to use the "better" way of "scaling only if required" using `adjustbox`, and wanted to understand why it isn't happening in my case...


title: Is there a way to make this graph look more like I would?

text: I have this graph, but, to be honest, it doesn't really look like a circle. Do you have any suggestions for making this graph look good and maybe more simply coded?               \documentclass{report}     \usepackage{tkz-berge}          \begin{document}     \begin{tikzpicture}[scale=2, every node/.style={draw,shape=circle,scale=0.5}]     \path     (0:1cm) node (p2) {}     (45:1cm) node (p3) {}     (120:1cm) node (p4) {}     (240:1cm) node (p5) {}     (300:1cm) node (p6) {}     (0:2cm) node (u1) {}     (32:1.65cm) node (u2) {}     (120:2cm) node (u3) {}     (47:3cm) node (u4) {}     (51:3.9cm) node (u5) {};     \draw (p4) -- (u3)     (p2) -- (u1)     (p2) -- (u2)     (u2) -- (u4)     (u4) -- (u5);     \draw [dashed] (p2) to[bend right=18] (p3)     (p3) to[bend right] (p4)     (p4) to[bend right=55] (p5)     (p5) to[bend right=25] (p6)     (p6) to[bend right=25] (p2)     (p3) -- (u4)     (p4) -- (u4);     \end{tikzpicture}     \end{document}


title: Drawing a mapping between arbitrary domains

text: I would like to draw a kind of diagram for mapping $\varphi:D\to D'$. Domains $D$ and $D'$ should look rather arbitrarily. I consider doing it with tikz but I do not know how to produce such nice curves for boundaries of domains. ![enter image description here](http://i.stack.imgur.com/f3QPN.png) After a while I got solution like this               \documentclass{article}     \usepackage{tikz}     \usepackage[active,tightpage]{preview}     \PreviewEnvironment{tikzpicture}     \setlength\PreviewBorder{5pt}     \begin{document}     \begin{tikzpicture}     \draw plot [smooth cycle] coordinates {(5,0.25) (6,0.35) (6.5, 0.2) (7,0.5) (7,1.65) (6.5,2.75) (5.8,2.75) (5.3,1.45) (4.8,0.85) } node at (6,1.7) {$D'$};     \path[->] (3.1,1.7) edge [bend left] node[above] {$\varphi$} (5.0,1.7);     \draw plot [smooth cycle] coordinates {(1.0,.1)(1.5,.2)(2.8,.5)(2.9,1.5)(2.8,2.8)(1.4,2.5)(0.5,0.5)} node at (1.8,1.7) {$D$};     \end{tikzpicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/X6GwP.png)


title: What documentation thoroughly explains how to use TeX conditionals?

text: I have a document which needs a large variety of plain TeX conditionals, e.g.:               IF #1 >= 1 AND #2 >= 10     IF #1 != “tree” OR #2 == “mountain”     IF 10 > #1 > 2      I have found limited documentation on this subject and most is quite terse and not easy to understand, or they just describe the individual components, but do not explain how they are used together. What documentation thoroughly describes how to create plain TeX conditionals, while providing ample example code, and showing how to avoid common mistakes?


title: Testing and modifying white space around an environment

text: I'm trying to create something similar to `marginpar` but without the hassle of floats (particularly because I'm going to have a lot of these). **First issue** These notes always appear at the beginning of a paragraph, and I would like to be able to take into account whether the paragraph has been indented or not (such as whether it's followed a `section` command). I really only need to know this so I can position the note correctly in the right hand margin. I suppose there may be so `tikz` trick for this. If you know of one, I'd greatly appreciate your suggestions for finding the position of the right margin of the current line. I'd also be very interested in non-`tikz` answers too. **Second issue** I want to be able to kill the extraneous whitespace after the environment. I know I can manually add `%` after the environment. But I'd like not to have to do this. I thought using `etoolbox` I could achieve this effect with the hook `\AtEndEnvironment`, but that's not working. Here's a MWE               \documentclass{article}     \usepackage[driver=dvips,                 top=0.5in,bottom=0.5in,                 left=0.5in,right=3.25in,                 headsep=0.5\baselineskip, headheight=\baselineskip,                 footskip=1.5\baselineskip,                 ]{geometry}     \pagestyle{empty}     \usepackage{xcolor}     \usepackage{etoolbox}     \usepackage{lipsum}     %%'     \newsavebox{\aemarginpar}     \newenvironment{mnote}         {%             \begin{lrbox}{\aemarginpar}\color{blue}%             \begin{minipage}[t]{\dimexpr 3.25in - 2em - 0.5in\relax}%\raggedright%         }{%             \end{minipage}%             \end{lrbox}%             \rule{0pt}{0pt}%             \hspace*{\linewidth}%             \raisebox{0pt}[0pt][0pt]{%                 \makebox[0pt][l]{\hspace*{2em}\usebox{\aemarginpar}}%             }%             \hspace*{-\linewidth}%         }     \AtEndEnvironment{mnote}{\ignorespaces}     \begin{document}          \section{Hello}          \begin{mnote}         First margin note.  I want to kill white space at the end of the         environment, but even with \verb=etoolbox=, I can't seem to get rid of         the extra white space.     \end{mnote}     \lipsum[1-2]          \begin{mnote}         My margin note is pushed too far to the left which is, of course,         because the paragraph has been indented.     \end{mnote}     \lipsum[3-4]          \end{document}      And here's the result: ![enter image description here](http://i.stack.imgur.com/2dn4g.png)


title: confproc one column

text: From what I've confproc is a great package for Conference Proceedings. What I would like to do is an Conference Abstract Book, so this would only have abstracts (1 page each). I want to make it 1 column, as it doesn't really make sense to have abstract only in two column. And there would be one page in each paper only. But I can't figure out if it actually is possible to use confproc with one column text only. EDIT: I finally came to realise that the one-column should be defined in the papers/abstracts themselves and not on the main .tex.


title: What is the recommended practice for making multi-article publications with LaTeX?

text: I would like to migrate the process of preparing a scientific journal at our department from MS Word to LaTeX. There is already a document class that could be used for individual articles. However it is not clear what is a proper way of combining multiple articles, which have their preambles, into a single document. Hence the question, what is the recommended practice for making multi-article publications with LaTeX?


title: Yap viewer getting slow

text: I switched recently from MikTeX 2.5 to MiKTeX 2.9 version for latex compilation. I'm getting the below issue with Yap viewer.   1. Performance of Yap viewer is very slow in opening and browsing through pages.   2. After each compilation, YAP viewer not showing the current opened page.


title: Turn off Section Numbering without Affecting TOC Indentation

text: I am new to LaTex and I am writing a document where I do not want my sections to be numbered. I did a quick google search and found this line of code to turn them off: `\setcounter{secnumdepth}{0} % Turns off numbering for sections.` However, when using this, I notice that my second level items in my TOC are not indenting properly. You can see here that I have a chapter and underneath that chapter is the first section; however, it is on the same indentation level as the chapter. Is there a way to correct this so my sections appear indented? Also if there is a better way to disable section numbering, please let me know. Thanks! ![The section "Solving Difficult Linear Equations" is not indented from the chapter "Fundamental Algebraic Skills"](http://i.stack.imgur.com/ZeLpb.png)


title: How can I change the horizontal spacing in a figure environment?

text: I want to put two figures, one at the top and one at the bottom, into one figure environment. I only want one common label and caption. How can I adjust the horizontal positioning of each of the figures? I tried               \begin{figure}[t]       \hspace{10pt}\includegraphics[width=12cm]{a.eps}\\[20pt]       \hspace{20pt}\includegraphics[width=12cm]{b.eps}\\       \caption{....}       \label{...}     \end{figure}      but it fails.


title: Usage of table/figures shown in caption

text: Is there a way to add the usage of a table/reference in the caption of the reference/table in LaTeX? For example:               \begin{table}         \begin{tabular}{ll}         \textbf{Name} & \textbf{Description} \\             Foo & bar \\             Foo & bar         \end{tabular}         \caption{Nice Table. Used on pages [2,3,4].}         \label{tab:table}     \end{table}      I would like the "Used on pages[2,3,4]." to appear automatically and linked to the correct reference, to all the locations in the document that use `\ref{tab:table}`. Anyone knows a package that takes care of this?


title: how to get the symbol like \neq with straight line crossed

text: how to get the symbol like this ,i had tried \textdoublebarpipe, but its works in text mode only, but not in equations math mode, not working inside $ $ and align ![enter image description here](http://i.stack.imgur.com/54oXI.jpg) need code for this symbol,


title: Inaccurate table numbering with LyX

text: I'm using LyX to create some tables, but the numbering is complete borked. In the LyX window, the table numbers are accurate. However, when I render to a PDF, they are evens only: 2, 4, 6 etc. (I'm sure I don't need to explain what even numbers are, but you get the point). ![enter image description here](http://i.stack.imgur.com/xtMJK.png) Delving into the source code generated:               \selectlanguage{english}%     ~\foreignlanguage{british}{}     \begin{table}[H]     \begin{raggedright}     \begin{longtable}[l]{|r|>{\raggedright}m{0.8\textwidth}|c|}     \hline      \selectlanguage{british}%     No.\selectlanguage{english}%      & \selectlanguage{british}%     Requirement\selectlanguage{english}%      & \selectlanguage{british}%     Priority\selectlanguage{english}%     \tabularnewline     \hline       &  & \tabularnewline     \hline       &  & \tabularnewline     \hline       &  & \tabularnewline     \hline       &  & \tabularnewline     \hline       &  & \tabularnewline     \hline       &  & \tabularnewline     \hline       &  & \tabularnewline     \hline       &  & \tabularnewline     \hline       &  & \tabularnewline     \hline      \end{longtable}     \par\end{raggedright}          \selectlanguage{british}%     \caption{Test table}     \selectlanguage{english}%     \end{table}      This is a test table, hence no data. But, I did notice `\begin{table}` and `\begin{longtable}`. Would I be correct in assuming this is the cause of the problem? If so, does any know how I can go about removing it? N.b. I've been into the table settings and the `long table` checkbox is ticked but greyed out, so that's not much use.


title: Use \usetikzlibrary{quotes} with \MakeOuterQuote{"} from csquots

text: Is there a way to use (disable) `\MakeOuterQuote{"}` in tikz while using `\usetikzlibrary{quotes}`? MWE:               \documentclass{article}          \usepackage{csquotes}     %\MakeOuterQuote{"} %breaks tikz library          \usepackage{tikz}     \usetikzlibrary{quotes}          \begin{document}     \tikz \node ["abc" draw] {node};     \end{document}


title: RefTeX won't find my .bib file in local library tree

text: RefTeX gives out the following error when trying to insert a citation: > >       No valid bibliography in this document, and no default available >   I keep a master `.bib` file in `~/Library/texmf/bibtex/bib/master_bib.bib`. Biblatex-biber recognize the file when I run it, so a bibliography is generated. The problem is that RefTeX does not recognize the file and yields the above error. I have also placed the `.bib` file in the same directory as the `.tex` file, with the same results. This post seemed promising RefTex won't detect my .bib file but that one self- resolved automagically. The RefTeX manual (p.20) says that > If you do not use BibTEX, but the document contains an explicit > `thebibliography` environment, RefTEX will collect its information from > there. however, I don't see where or how I could include this. How can I get this to work? Here's a MWE:               \documentclass{article}          \usepackage[         backend=biber,          style=authoryear,          maxcitenames=2,          sorting=nyt,         backref=true         ]{biblatex}         \addbibresource{master_bib.bib}          \begin{document}         Some text. \parencite{Mays:2005, Chow:1998}          \printbibliography     \end{document}          %%% Local Variables:      %%% mode: latex     %%% TeX-engine: xetex     %%% End:      I'm running Emacs 24, with AUCTeX 11.86, TeX Live 2011 from MacTeX.


title: How to choose a specific weight from a font family using fontspec and XeLaTeX

text: I have installed an open-type font on my OS and would like to use in a LaTeX document using XeLaTeX. It works fine, but when I define my font family like this:               \ifxetex       \newfontfamily{\neosans}{NeoSans}      \else     \fi      When I then use `\selectfont\neosans`it just selects the Regular version of that font. However, I would like to use the Light version! Even if I write `\newfontfamily{\neosans}{NeoSans-Light}` or `\newfontfamily{\neosans}{NeoSans Light}` it still chooses the Regular version. The specifications of the font I would like to use looks as follows (in Danish, though): ![Link to image](http://i.stack.imgur.com/A6cZ1.png) ## My question is How do use the Light version of the font?


title: Where should I define new command globally?

text: I'd like to define a command `\alert{}` by               \newcommand{\alert}[1]{\textcolor{red}{#1}}      in a way that I could use it on every new file. I was thinking to define it on some `cls` file (`amsart` for example). But if I create a new file using `report` class the new command will not work. Is there some internal file where I could define my command to work as a default LaTeX command. For example, using any class we can make use of some commands (`\textrm{}` for example). So I guess that there is some file to be loaded globally.


title: Figure fit pagewidth

text: Since the text in the figures are too small, it's better if I can enlarge them without putting each subfigure on a separate line. I can see only one way to do this is expand the figure to cover the spaces on the left and right side of the figure. Is there any way I can do this ? Here is the part of the page which contains the figure ![The figure](http://i.stack.imgur.com/ZEJb6.png) And the code to generate it.               \begin{figure*}[!h!t]     \centering          \subfigure[Panda - Week 2]{        \includegraphics[width=0.4\linewidth] {fig/thang_panda2.png}        \label{fig:esp1_3}     }     \subfigure[Panda - Week 3]{        \includegraphics[width=0.4\linewidth] {fig/thang_panda3.png}        \label{fig:esp1_4}     }          \subfigure[Penguin - Week 2]{        \includegraphics[width=0.4\linewidth] {fig/thang_penguin2.png}        \label{fig:esp1_5}      }     \subfigure[Penguin - Week 3]{        \includegraphics[width=0.4\linewidth] {fig/thang_penguin3.png}        \label{fig:esp1_6}     }        \caption{Collaboration using the whiteboard}        \label{fig:esp1}     \end{figure*}


title: Beamer newenvironment for theorems

text: I'm trying to define a new environment for theorems and I'm using this code:               % Theorem box     \pgfdeclarelayer{background}     \pgfsetlayers{background,main}     \tikzstyle{thmbox} = [inner sep=1em]     \tikzstyle{thmborder} = [draw=blue, fill=none,line width =1.pt, rounded corners=5pt]          \def\parchmentframe#1{     \tikz{     \node[thmbox] (A) {#1};     \begin{pgfonlayer}{background}     \fill[thmborder]          (A.south east) -- (A.south west) --          (A.north west) -- (A.north east) -- cycle;     \end{pgfonlayer}}}          \def\parchmentframetop#1{     \tikz{     \node[thmbox] (A) {#1};     \begin{pgfonlayer}{background}         \fill[thmborder]       (A.south west) -- (A.north west) --        (A.north east) -- (A.south east);     \end{pgfonlayer}}}          \def\parchmentframebottom#1{     \tikz{     \node[thmbox] (A) {#1};     \begin{pgfonlayer}{background}         \fill[thmborder]     (A.north west) -- (A.south west) --      (A.south east) -- (A.north east);     \end{pgfonlayer}}}          \def\parchmentframemiddle#1{     \tikz{     \node[thmbox] (A) {#1};     \begin{pgfonlayer}{background}         \fill[thmborder]     (A.north west) -- (A.south west);     \fill[thmborder]     (A.south east) -- (A.north east);     \end{pgfonlayer}}}          \newenvironment<>{myTheorem}{%       \def\FrameCommand{\parchmentframe}%       \def\FirstFrameCommand{\parchmentframetop}%       \def\LastFrameCommand{\parchmentframebottom}%       \def\MidFrameCommand{\parchmentframemiddle}%       \vskip\baselineskip       \MakeFramed{\FrameRestore}       \noindent\tikz\node[inner sep=1.2ex, draw=blue, fill=blue!10,     anchor=west, overlay, line width = 1.pt, rounded corners=4pt] at (0em, 1em)      {\color{LightBlue}{THEOREM}};\par\nobreak}%     {\endMakeFramed}          %%end theorem box      So, when I make the call `\begin{myTheorem}` I obtain a box with the word _THEOREM_ on top. However when the theorem has a name I would like to have it in my box, maybe with a call like `\begin{myTheorem}{Name of the theorem}` (similarly to what happens with blocks, where I can decide to have the title or not). How can i modify the code in order to obtain this effect?


title: bold table column in latex beamer

text: I'm trying to bold a single column of a table inside latex beamer. in latex i used               \begin{tabular}{|l|c|c|>{\bfseries}c|c|}      for example, to make the 4th column bold. in beamer, the bfseries macro does not apply. anyone knows why ?


title: How to merge several files in LaTeX

text: I am writing thesis in LaTeX and I am beginner in LaTeX. I read about combining files into main file, but it didn't help me much and my problem persists. I am giving minimal code what I am trying to do. Please help me with this problem. Compiler doesn't compile files when it encounters table or figure code and it seems that \usepackage is necessary for individual files as well.               %MAIN.tex          \documentclass[a4paper,12pt,oneside,openright,draft]{book}          \input{preamble}          \begin{document}          \frontmatter          \tableofcontents          \listoffigures          \listoftables          \mainmatter          \include{Chapter1}          \include{Chapter2}          \end{document}          %% end of MAIN.tex-------------------------     %%preamble.tex          \usepackage{microtype}          \usepackage[demo]{graphicx}          \usepackage{index}          \usepackage{ctable}          \usepackage{tabls}          \newcommand{\head}[1]{\textbf{#1}}          %%end of preamble.tex-------------------------          %%starting chapter1.tex          \chapter{Main chapter}          \section{First section of the first chapter}          \subsection{subsec 1}          \subsubsection{subsubsec 1}          \subsubsection{subsubsec 2}          \subsection{subsec 2}          {\Large Here's figure} \\          \begin{figure}[h!]          \centering                  \includegraphics{test}              \caption{test {\index {new figures}}}              \label{fig:test1}          \end{figure}          %%end of chapter1.tex-------------------------          %%starting chapter2.tex          \chapter{Tables}          \begin{tabular}{cccc}          & \multicolumn{2}{c}{Input} & \multicolumn{1}{c}{Output}\\          & \head{A} & \head{B} & \head{C} \\          \cmidrule[1pt](l){1-3} \cmidrule[1pt](lr){4-4}          \multirow{3}{*}{Data} & 10 & 20 & 30\\          & 40 & 60 & 100\\          & 25 & 50 & 75\\          \bottomrule[1.5pt]          \vspace{2mm}          \caption{My table}          \end{tabular}          %end      * * * Thanks for your suggestions. I modified my code, but still errors are there. I cannot figure out where I am going wrong. When I compile individual Chapter 2, there are no errors. But when I combine it to the main file, there is error               !missing \cr inserted      Main file:               \documentclass[a4paper,12pt,oneside,openright,draft]{book}     \input{preamble}     \begin{document}     \newcommand{\head}[1]{\textbf{#1}}     \frontmatter     \tableofcontents     \listoffigures     \listoftables          \mainmatter     \include{Chapter1}     \include{Chapter2}          \end{document}      Chapter 1               \chapter{Main chapter}     \section{First section of the first chapter}     \subsection{subsec 1}     \subsubsection{subsubsec 1}     \subsubsection{subsubsec 2}     \subsection{subsec 2}     {\Large Here's figure} \\          \begin{figure}[h!]     \centering     \includegraphics{test}     \caption{test}     \label{fig:test1}     \end{figure}      Chapter 2               \chapter{Tables}         \begin{table}     \begin{tabular}{cccc}     & \multicolumn{2}{c}{Input} & \multicolumn{1}{c}{Output}\\     & \head{A} & \head{B} & \head{C} \\     \cmidrule[1pt](l){1-3} \cmidrule[1pt](lr){4-4}     \multirow{3}{*}{Data} & 10 & 20 & 30\\     & 40 & 60 & 100\\     & 25 & 50 & 75\\     \bottomrule[1.5pt]     \end{tabular}     \vspace{2mm}     \caption{My table}


title: Problems in a table: thickness of line, multicolumn, optimal height of rows

text: I've written the following code, that produces the output I include below. I have three problems:   1. The vertical line of the colored rows is finer than the rest of rows.   2. The first row of the table has 2 columns, that I want to combine in only one. Apparently, the row is multcolumn, but it separates the first letter of the rest. What is my error?   3. What is the better way to get the optimal height of every row, with some space before of the text, and some space after the text?               \begin{table}[h]         \centering         \caption{UNIDAD DIDÁCTICA 1: NUESTRO CUERPO}         \begin{tabular}{|p{8cm}|p{8cm}|}         \hline     \multicolumn{2}{c}UNIDAD DIDÁCTICA 1: NUESTRO CUERPO\\\hline     \cellcolor{green!20} Objetivos & \cellcolor{green!20} Criterios de evaluación \\\hline      Identificar las partes del cuerpo. &       Diferencia las tres partes principales en las que se divide el cuerpo.\\\hline     Distinguir las partes del cuerpo que están en la espalda de las que están en el frente. &      Localiza en sí mismo y en los demás las principales partes del cuerpo.\\\hline     Diferenciar los estados de ánimo en las expresiones de la cara. &       Reconoce sus propias características físicas.\\\hline     Distinguir los diferentes movimientos que podemos hacer con el cuerpo. &     Identifica diferentes movimientos del cuerpo humano.\\\hline     Reconocer y respetar las diferencias físicas existentes entre las personas. &      Reflexiona sobre los cambios corporales de las personas a lo largo de la vida. \\\hline     Identificar los cambios corporales con el paso del tiempo. &       Nombra los dedos de las manos. \\\hline     Reconocer lesiones y medidas de protección corporal.  &     Indica las posiciones derecha e izquierda; de frente, de espaldas y de lado en el cuerpo. \\\hline      & Localiza en la cara diferentes órganos.\\\hline      & Identifica lesiones y medidas de protección del cuerpo.\\\hline     \cellcolor{green!20} Contenidos &      \cellcolor{green!20} Competencias básicas \\\hline     El cuerpo humano. & \\\hline     Las partes del cuerpo humano. &     Además de desarrollar la Competencia en el conocimiento e interacción con el mundo físico, en esta unidad se contribuye al desarrollo de las siguientes competencias:\\\hline     Las articulaciones. &      - Competencia cultural y artística.\\\hline     Los cambios corporales con el paso del tiempo. &      - Competencia lingüística.\\\hline     Observación y obtención de información a partir de fotografías, dibujos y obras pictóricas. &      - Autonomía e iniciativa personal.\\\hline     Observación e imitación de posturas corporales. &      - Competencia social y ciudadana\\\hline     Interpretación de escenas secuenciadas cronológicamente. & \\\hline     Respeto por todas las personas. & \\\hline     Interés por realizar actividades físicas y deportivas. & \\\hline     Fomento de actitudes tolerantes hacia las personas con discapacidades. &     \\\hline      & \\\hline      & \\\hline      & \\\hline     \end{tabular}     \end{table}      ![Fragment of the output](http://i.stack.imgur.com/esNKC.png)


title: How to change page numbering and section numbering?

text: I am pretty new to LaTeX. Right now I have this:               \documentclass[11pt]{scrbook}     \usepackage[a4paper,left=2.5cm,right=2.5cm,top=2.5cm,bottom= 3.2cm]{geometry}     %     %     %     \usepackage[pdftex]{graphicx}   %{graphicx} in order to load pictures.     \usepackage[english,german,ngerman]{babel}  %{babel} enables to choose a language.     \usepackage[utf8]{inputenc} %[utf8]{inputenc} enables UTF8-characters not only ASCII.     \usepackage{ae}     %Uses "Latin Modern" instead of "Computer Modern".     \usepackage[colorlinks=false,pdfborder={0 0 0}]{hyperref}%Automatically turns all internal references into "hyperlinks". "pdfborder={0 0 0}" disables red border around hyperrefs.               \begin{document}          \input{./Title.tex}     \input{./blabla.tex}          \tableofcontents                         \renewcommand{\thechapter}{\Roman{chapter}}     \renewcommand{\thesection}{\Roman{section}}     \pagenumbering{roman}     \input{./Abstract.tex}               \pagenumbering{arabic}     \renewcommand{\thechapter}{\arabic{chapter}}     \input{./Introduction.tex}     \input{./MyStuff.tex}               \end{document}      What I am trying to achieve with               \renewcommand{\thechapter}{\Roman{chapter}}     \renewcommand{\thesection}{\Roman{section}}      is a page numbering scheme like this: > I. Abstract.....I > >   1. Introduction..1 > >   2. MyStuff.......2 > > Plus I want the section I included into chapters to be numbered in **arabic** too. The current output is different though. All chapters, sections and pages are still numbered in arabic.


title: How to color the 'inner areas of this logo?'

text: Is it possible to color the 'inner' areas of this logo? ![enter image description here](http://i.stack.imgur.com/M3Z2w.png)               \documentclass{scrartcl}     \usepackage[german]{babel}     \usepackage[latin1]{inputenc}     \usepackage[T1]{fontenc}     \usepackage{textcomp}     \usepackage{bera}     \usepackage[svgnames]{xcolor}     \usepackage{tikz}     \usepackage{makecell}     \tikzset     {       shadeball/.style={circle,shading=ball, minimum size=0.6cm},       utedge/.style={->,ultra thick}     }     \begin{document}     \begin{tikzpicture}       \draw (0,0) rectangle (14,3);       \node at (1.8,2.3) {\Huge\textbf{\textsf{my\LaTeX}}};       \node at (10.6,0.8) {\LARGE\makecell[r]{line1 line1 line1 line1 li\\line2 line2 line2 line}};       \node[shadeball, ball color=LawnGreen] (b1) at (5.7,0.85) {};       \node[shadeball, ball color=Fuchsia] (b2) at (10.7,2.15) {};       \node[shadeball, ball color=Cyan] (b3) at (4.7,2.25) {};       \node[shadeball, ball color=Gold] (b4) at (2.1,0.55) {};       \node[shadeball, ball color=Tomato] (b5) at (0.7,1.65) {};       \node[shadeball, ball color=Chocolate] (b6) at (7.7,0.45) {};       \draw[utedge] (b2) to [bend right=20] (b1);       \draw[utedge] (b3) to [bend left=30] (b1);       \draw[utedge] (b4) to [bend right=10] (b1);       \draw[utedge] (b4) to [bend right=30] (b3);       \draw[utedge] (b3) to [bend left=20] (b2);       \draw[utedge] (b5) to [bend right=30] (b4);       \draw[utedge] (b5) to [bend right=20] (b3);       \draw[utedge] (b1) to [bend right=30] (b6);     \end{tikzpicture}     \end{document}


title: xypic: is it possible to change the slope of an arrow?

text: In this diagram, I want arrows from `\Delta X~` in the middle of the 2nd row goes to both `N\Delta X` and `(Delta X)~/D\Delta X`, how do I do that? (making columns very narrow and draw very fine lattices seems to be a solution, but I wonder if there is an easier way.) ![Diagram](http://i.stack.imgur.com/FnQCN.png)


title: SetFigFontNFSS vs. SetFigFont

text: I'm currently updating a LaTeX document which has about 300 xfig figures. To include the figures into LaTeX, all figures get converted to a `.pstex_t` with `fig2dev -L pstex_t`. To see if my system compiles the document different, I've recompiled it and made a diff. I saw that all occurcences of `\SetFigFontNFSS` in those .pstex_t files were replced by `\SetFigFont`. What does that mean? How do those commands differ?


title: How can I write multi line text on the foreground of pages, and how can I align it?

text: I'm using this to write on the foreground of individual pages of a large PDF (hopefully), i.e one with white spaces to enter in LaTeX notes.               \documentclass{article}     \usepackage{pdfpages}     \usepackage{eso-pic}     \begin{document}     \AddToShipoutPictureFG*{\AtPageCenter{     HERE IS SOME TEXT\     ohhello}     hi}     \includepdf[pages=11]{completenotes210pages.pdf}     \AddToShipoutPictureFG*{     \Huge HERE IS SOME TEXT.}     \includepdf[pages=12]{completenotes210pages.pdf}     \end{document}      and I'm trying to get `ohhello` on a separte line to HERE IS SOME TEXT on just the first page (or page11 from my 'master file'), usually all you would do is just put\ buuuuut it seems as though for some reason `eso-pic` doesn't like me doing that. In addition I'm just trying to type from the very left top of the page, write and use `\` for a new line and `\qquad` when i need some spaces etc. by default it writes from the bottom left and I don't think it even goes up a line when you get to the end. How do I just get it to behave like normal writing on a blank sheet? The positioning in `eso-pic.pdf` and `atbegshi.pdf` and all its other implementations are way too complicated for me. Ideally I'd always want to write from the left, like you do, and I'd just make some tags to start a few inches down or so with preset               \     \     \     \     \      and I'd just define how many lines I want to skip. I'm on this job 24 hours, if you know how and I can't do it properly straight away then lets team viewer and i swear you will be a saint. Almost 12 hours I've been at trying to implement this to large files, so hopefully I'll get it soon. Do I need prefix `\usepackage{atbegshi}`?


title: How to reduce space between heading (e.g. "List of figures") and contents in thesis

text: I have trouble reducing the space between the the title like LIST OF FIGURES, TABLE OF CONTENTS, etc., and the list body body in my thesis. I had the same problems with chapter headings, which I fixed by using `\vskip -2.5` in each chapter. However, since the table of contents etc. are fixed by document class itself (my guess), I am not able to do this. I will appreciate any help on this.


title: The IPA symbol for the labiodental flap (ⱱ)

text: I need the ⱱ character (prefereably with the advanced diacritic underneath it) for a phonetics paper, but the tipa package doesn't seem to contain it. I have at least one font with this character on my computer (Charis SIL). How do I get the character into my LaTeX document?


title: Glossary does not work on different platforms

text: I am writing my master thesis. When I compile and run the Tex file on Ubuntu everything works fine. When I do it on OSX and Windows it return the error:               Package glossaries Error: Glossary entry `...' has not been defined.      for all the `\gls{}` entries inserted. I do follow the procedure for makeindex from the console. (`makeindex main_body.glo -s main_body.ist -t main_body.glg -o main_body.gls`). Any hints? thank you in advance. Minimal Working Example               \documentclass[11pt,a4paper,bibtotoc,idxtotoc,headsepline,footsepline,                    footexclude,BCOR12mm,DIV13]{scrbook}     \input{components/info}     % include settings     \input{components/settings}     % include commands     \input{components/commands}          \makeindex     \makeglossary          \begin{document}             \frontmatter                 \input{components/cover}         \clearemptydoublepage         \input{components/titlepage}         \input{components/abstract}         \tableofcontents         \input{components/outline}         \part[Introduction, Motivation and Backdrop]{Introduction, Motivation and Backdrop}                   \part[Handbook and its Application]{Handbook and its Application}         \part*{Appendix}         \addcontentsline{toc}{part}{Appendix}              \input{chapters/7_Glossary/Acronyms}         \input{chapters/7_Glossary/Glossary}         \glsaddall         \printglossaries         \addcontentsline{toc}{chapter}{Glossary and Acronyms}              \clearemptydoublepage              \bibliography{bibliography/literature}          \end{document}


title: Looking for BibTeX style that doesn't include article's title

text: Please give a name of `.bst` file witch generates article reference entry like this:   > [1] A. Author, Journal_name, 2(3), 45(2014) 2 -- volume number   3 -- issue number   45 -- first page of article   2014 -- year   I guess this reference entry format should be popular. But I have failed to find the `.bst` file.


title: Align pictures in subfigure

text: I'm having troubles with the subfigure package and proper alignment of figures. I'm inexperienced with Latex so please apologize obvious mistakes. The top-left figure is not properly aligned with the figures that follow below. It should be more to the left (please see attached screenshot). Shortened code:               \begin{figure}[h]     hfill     \subfigure[CEO fixed / total]{\includegraphics[width=8cm]{figures/scatter_cash_CapIQ_CEOfixed_to_total.png}}     \hfill     \subfigure[CEO bonus / total]{\includegraphics[width=8cm{figures/scatter_cash_CapIQ_CEObonus_to_total.png}}     \hfill      \subfigure[CEO long-term / total]{\includegraphics[width=8cm]{figures/scatter_cash_CapIQ_CEOlongterm_to_total.png}}     \hfill     \caption{Compensation measures}     \end{figure}      ![enter image description here](http://i.stack.imgur.com/QpqQv.png)


title: Using Tikz in a figure, can I draw braces between nodes and control spacing between brace ends and the nodes?

text: This question is related to Draw curly braces in TikZ. Is there a way of making the solution more general for when you wish to use node names to define the end points? To illustrate, I've made a slight change to the code given by @Jake on the earlier question. In my figure below, the brace on the left is drawn to the nodes I've specified (rather than coordinates), but the result is drawn to touch the boxes. I would prefer to have a small space so that the brace doesn't touch the boxes, however, the `xshift` and `yshift` options don't seem to have any effect on how the brace is drawn. Is there a way of modifying the brace so that it looks more like the one on the right of the figure (has a small space between brace and boxes), without having to specify additional nodes to enforce the space I require?               \documentclass{article}          \usepackage{tikz}     \usetikzlibrary{decorations.pathreplacing}          \begin{document}     \begin{tikzpicture}[scale=1]     \draw[thick] (-1,0) rectangle +(6,7.5);     \filldraw[thick, top color=white,bottom color=red!50!] (0.5,0) rectangle node{$N_S$} +(1.3,0.5);     \filldraw[thick, top color=white,bottom color=red!50!] (2.2,0) rectangle node{$N_L$} +(1.3,0.65);     \filldraw[top color=white,bottom color=blue!50!] (0.5,0.5) rectangle node{$P_{1}$} +(1.3,0.5);     \filldraw[top color=white,bottom color=blue!50!] (2.2,0.65) rectangle node{$P_{2}$} +(1.3,1.0);     \filldraw[top color=white,bottom color=blue!50!] (0.5,1.0) rectangle node{$P_{3}$} +(1.3,1.5);     \filldraw[top color=white,bottom color=blue!50!] (2.2,1.65) rectangle node{$P_{4}$} +(1.3,2.0);     \filldraw[top color=white,bottom color=blue!50!] (0.5,2.5) rectangle node{$P_{5}$} +(1.3,2.5);     \filldraw[top color=white,bottom color=blue!50!] (2.2,3.65) rectangle node{$P_{6}$} +(1.3,3.0);          % defining nodes at the points that are the ends of the left brace on the figure     \node[draw] (TopLeftPoint) at (0.5,5.0){box 1};     \node[draw] (BottomLeftPoint) at (0.5,0.5){box 2};          %changing xshift and yshift values on next line doesn't seem to affect the brace at all     \draw [decorate,decoration={brace,amplitude=10pt},xshift=-400pt,yshift=1000pt]     (BottomLeftPoint.west) -- (TopLeftPoint.west) node [black,midway,xshift=-0.6cm]      {\footnotesize $P_1^*$};     \draw [decorate,decoration={brace,amplitude=10pt,mirror,raise=4pt},yshift=0pt]     (3.5,0.65) -- (3.5,6.5) node [black,midway,xshift=0.8cm] {\footnotesize     $P_2$};     \end{tikzpicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/2GRCt.jpg)


title: How to actually close a write-stream

text: I don't know too much about writing and reading to and from files. But I managed to create a nice command for me where I need to write something into a text-file and later-on read it again.               \newcommand{\customwrite}[1]{       \newwrite\tempfile%       \immediate\openout\tempfile=filename_#1.txt%       \immediate\write\tempfile{\the\figheight}%       \immediate\closeout\tempfile%     }      The reading is achieved by               \newcommand{\customread}[1]{       \newread\tempfile%       \openin\tempfile=filename_#1.txt%       \read\tempfile to \fileline%       \setlength\figheightex\fileline%       \closein\tempfile%     }      Both things works fine for me as long as I have not too much of this calls. Recently, I had a bigger document and everything failed and I got the message `No room for a new \write`. I searched for this error and what I found is, Latex is only capable of opening 16 write and 16 read streams. Apparently `\closeout` and `\closein` don't actually close these streams what I thought. My question is now: is it somehow possible to actually close these streams?


title: Vertical alignment of tikzpicture with text?

text: I have some text, and a corresponding `tikzpicture`, both of which are to be part of a test question, and which are thus included as part of an `\item` in an enumerate environment. Like this:               \item      \begin{minipage}[t]{0.55\linewidth}           description of question       \end{minipage}       \hspace*{1cm}       \begin{minipage}[ht]{0.35\linewidth}          \begin{tikzpicture}[scale=0.3]           question diagram         \end{tikzpicture}       \end{minipage}        What I want is for the text to be vertically aligned as it would be without a `minipage` environment, and for the top of the `tikzpicture` to be aligned with the top of the text. I can obtain this alignment with the option "`baseline=4cm`" in `tikzpicture`, but this has the result of putting in a large amount of vertical white space before the item, which then has to be countered with `\vspace*{-2cm}`. Is there a better, automatic, way rather than fiddling with vertical space?


title: Text in outer margin of multiple columns

text: I want to put some text in the outer margin (by which I mean on the left side of the page of even pages and on the right side of odd pages) of the page. My naive approach of using `\inoutermargin{Text}` fails when I use it with columns. Then the text is printed in the outer margin of the first column. Can somebody point me into the right direction? I am using ConTeXt ver: 2012.05.30 11:26 MKIV               \starttext          \setuppagenumbering[alternative=doublesided]          \startcolumns     \inoutermargin{More text}     \input knuth     \stopcolumns          \page[yes]          \startcolumns     \inoutermargin{Text}     \input knuth     \stopcolumns          \stoptext


title: How to fold \footnote code in TeXmaker?

text: I would like to fold the code inside a \footnote. With Emacs I use a command to hide the footnote and then by clicking over the label I can see it again. The procedure is describe in the image below: ![enter image description here](http://i.stack.imgur.com/6CnGu.gif) How can I do a similar thing in TeXmaker?


title: Is hyperref really the best way to add metadata to a TeX file?

text: So I know one of hyperref's features is that it can add metadata to you PDFs. This is a nice feature and if you're putting stuff online, it's good to include metadata. But is the `hyperref` package really the best way to do it? I mean, if you're using hyperref anyway, that's fine. But if you don't want hyperrefs in your document, it seems weird to include the package, and then turn off pretty much all its functionality. And given that hyperref is a shorthand for "package conflict nightmare", is seems insane that you should have to deal with it just for the sake of some metadata. So I have two questions.   1. Is there a good reason that hyperref includes this functionality which is apparently unrelated to its primary purpose?   2. Is there a better (smaller, less conflicty, easier...) option to include metadata in my PDFs?


title: Problems about drawing a map and learn to draw with TeX

text: I'm doing a beamer, and now I encounter a problem. I want to draw a map in my beamer like this ![enter image description here](http://i.stack.imgur.com/mvS3f.jpg) Who can help me? I'm now still not very familiar with these things. Also I want to learn some basic skills to draw with LaTeX. Could any one give me some materials or advice to learn?


title: Using \include with in Tabular / Array

text: I'm doing graphics using PStricks, writing each figure in it's own sub-file. I would like to order two of these figure vertically with a symbol in between. To that end, I've tried using a tabular and arrays environments. This, however, produces and error, even when the sub-file is empty. For PStricks, I compile using xelatex on Ubuntu. A minimal working example is               \documentclass{beamer}     \begin{document}     \begin{frame}          \begin{tabular}{ccc}     \include{test} & b & c\tabularnewline     \end{tabular}          \end{frame}     \end{document}      Here, the error is produced at `\end{frame}`. `test.tex` is empty and is in the same folder as the main file. Is there away to solve this problem?


title: Where can I report this Calc2LaTeX error?

text: A popular tool to generate tables/tabulars is Calc2LaTeX, an extension for OpenOffice.org/LibreOffice Calc. However ever since I installed version 4 of LibreOffice, an error occurrs. It still works, but there is some sort of "bug". Since the project site seems vacated, would anyone have a clue where to go with this? **Picture of error:** when selecting `Tabular`, the same windows opens again (same for newly opened windows). When I click `Convert` then, a LibreOffice Basic dialog opens which I can only close after closing the Calc2LaTeX popup. ![enter image description here](http://i.stack.imgur.com/uA9HH.png) ![enter image description here](http://i.stack.imgur.com/jME0O.png)


title: String diagrams for monoidal functors a la McCurdy

text: Almost surely you don't know who Micah McCurdy is, but here is a sample of his diagrams, on pages 20-21, for example, or page 27 for something fancier. I asked him how he did them, and unfortunately it is not a 'native' (La)TeX method, involving two separate software packages. I'd like to be able to do this in TikZ or PSTricks, but I know nothing about either of these. This project would be my opportunity to learn. I'd like to do something modular, to aid coding up of diagrams as a method of computation, rather than just drawing them all(on paper, say) by hand and then laboriously programming them. ![arXiv:1110.5542v1, page 20](http://i.stack.imgur.com/Gxi9O.png) EDIT: Thanks to Tom Bombadil for having a go at the example pasted in by canaaerus, which was a good example of the visual complexity possible, but I do need the graphical elements specified on pages 7 and 8 of the above linked pdf, in conjunction with things from page 3. (This is just so that there is a complete record of what I am after.) ![enter image description here](http://i.stack.imgur.com/khhuF.png)


title: Cross reference of a section that doesn't have a section number

text: I was using ACM CHI latex template in which sections do not have section numbers. For example: > BACKGROUND > > SubBackground > > SubSubBackground Now I want to cross reference, but I don't have a section number to refer to:               \section{Background}     \label{background}          \subsection{SubBackground}     see \ref{background}      > BACKGROUND > > SubBackground > > see How do I cross-reference here?


title: Customize |<->| arrowhead in Tikz

text: I am quite happy with the `|<->|` arrowhead in Tikz but I would like to control the length of the `|`. Is there a simple way to achieve this? In `tikz.code.tex`, I could find               \pgfarrowsdeclarecombine*{tikz@|<@#2}{tikz@>|@#2}{#1}{#2}{|}{|}      which is somehow related to the question but it looks like in `pgflibraryarrows.code.tex` there is nothing to grab. It would be nice if this `|` length could be a parameter.


title: Is a page modulo 4?

text: If I want to test whether a page is odd/even (i.e. modulo 2) then I can use the following:               \ifthenelse{\isodd{\thepage}}{}{}      What can I do if I want to test whether a page is modulo 4? A minimal example:               \documentclass{article}     \usepackage{ifthen}          \newcommand{\ismodfour}{???}          \begin{document}     Page 1: \ifthenelse{\ismodfour{\thepage}}{mod 4}{not mod 4} \newpage     Page 2: \ifthenelse{\ismodfour{\thepage}}{mod 4}{not mod 4} \newpage     Page 3: \ifthenelse{\ismodfour{\thepage}}{mod 4}{not mod 4} \newpage     Page 4: \ifthenelse{\ismodfour{\thepage}}{mod 4}{not mod 4} \newpage     Page 5: \ifthenelse{\ismodfour{\thepage}}{mod 4}{not mod 4} \newpage     \end{document}


title: Description environment redefined

text: I use the Latex templates from Springer for a project, and to my surprise, the description environment doesn't work correctly - the item labels are not bold. I don't know where this is customized in the templates, but would like the old (standard) behaviour. How can I redefine the redefined description environment to achieve this?