title: .aux file not found or empty while cross-referencing between files

text: I have an issue similar to this one. In oppose to that thread, I use xelatex. Don't know, though, if this is the issue or not. I have two files. In the first one (Characteristics.tex) I have:               % Language specific stuff     \usepackage[cm-default]{fontspec}     \defaultfontfeatures{Ligatures=TeX}     \setmainfont{Times New Roman}     \newfontfamily\cyrillicfont{Times New Roman}     \usepackage{polyglossia}     \setdefaultlanguage{russian}     \setotherlanguage{english}          % Cross-referencing stuff     \usepackage{hyperref}     \usepackage{nameref}     \usepackage{zref-xr,zref-user}     \zexternaldocument*{Names}      Similarly in the second one (Names.tex):               % Language specific stuff     \usepackage[cm-default]{fontspec}     \defaultfontfeatures{Ligatures=TeX}     \setmainfont{Times New Roman}     \newfontfamily\cyrillicfont{Times New Roman}     \usepackage{polyglossia}     \setdefaultlanguage{russian}     \setotherlanguage{english}          % Cross-referencing stuff     \usepackage{hyperref}     \usepackage{nameref}     \usepackage{zref-xr,zref-user}     \zexternaldocument*{Characteristics}      Actually, it is only second file that contains references to the first file so far. So when I compile it with xelatex I get               Package zref-xr Warning: File `Characteristics.aux' not found or empty      that results into               LaTeX Warning: There were undefined references.      I have checked, the .aux file exists and is not empty. In case this is important, I use `\label{}` to indicate the label (only in Characteristics.tex so far) and `\ref{}`,`\zref{}` or `\nameref{}` to call the reference. These work perfect in the same file, but do not work for cross-referencing between two files. Does anyone know how to resolve the issue?


title: hyperref error using latex: "Illegal parameter number in definition of \Hy@temp"

text: I have a new laptop and installed Ubuntu 14.04 including TeX Live. A LaTeX file which worked well under Ubuntu 12.04 now gives error "Illegal parameter number in definition of `\Hy@temp`" when calling latex at every `\citeads` command (but not for pdflatex). The file is `example.tex` at `http://www.staff.science.uu.nl/~rutte101/Report_recipe.html` and is a decades-old latex primer, more recently expanded with bibtex cite macros that turn in-text citations into web browser openers for the astronomy literature database at NASA. These macros were contributed and are recommended by the journal Astronomy & Astrophysics. The errors are non-fatal (answering with "s" produces the proper `example.dvi` result). Has something changed in `hyperref`? Is there a mistake in the `citeads` macros in that file? MWE:               \documentclass{article}     \usepackage{natbib}     \usepackage{twoopt}     \usepackage{hyperref}          \makeatletter     \newcommandtwoopt{\citetads}[3][][]{%       \href{http://adsabs.harvard.edu/abs/#3}{%         \def\hyper@linkstart##1##2{}%         \let\hyper@linkend\@empty         \citet[#1][#2]{#3}%       }%     }     \makeatother          \begin{document}       \citetads{1981ApJ...247L..97M}     \end{document}


title: Quotation marks in TexWorks

text: I pasted a lot of text with quotation marks into TexWorks, expecting to have to change all the opening quotation marks to ``. But only about half of them actually look wrong when I compile. Is there an explanation for why they sometimes work and sometimes not?


title: Is possible give the handwrite aspect to other thing?, as ncline, rectangles,... in PStricks?

text: Viewing doc, I realized that there is an option (similar to linestyle=¿handwrited? ;-) ) to simulate handwriting. Is possible give this aspect to other elements as triangles, poligons, curves, nclines,... ? ![enter image description here](http://i.stack.imgur.com/ZwUHy.png)


title: Customization of TOC in KOMA

text: I would like to customize the listing of the chapters given in the table of contents in a `scrbook` document. Given the following example:               \documentclass{scrbook}     \begin{document}     \tableofcontents     \chapter{Alpha}     \chapter{Beta}     \chapter{Gamma}     \end{document}      My TOC currently looks like this: ![TOC](http://i.stack.imgur.com/4GVUY.png) How can I customize the text printed in the TOC in the following two regards:   * add a prefix/suffix to the number, e.g. write "Chapter 1" instead of "1"   * increase letter spacing of the chapter title using `microtype`'s `textls`


title: What´s the best/practical way to do trees with pstricks pictures in nodes?, with PSTricks, Pst-node

text: I have test that psmatrix is a good way to do diagrams, but ... to do diagrams where the nodes is not displayed as a "perfect matrix/table". What is the recommended way to do any similar to, with ps pictures in the nodes?, with fully liberty for place where I want the center of the node. ![enter image description here](http://i.stack.imgur.com/kjPrX.jpg) Code example with psmatrix:               \documentclass[12pt,a4paper,x11names]{article}     \usepackage{pstricks,pst-node,pst-blur,pstricks-add}     \usepackage{graphicx}     \usepackage{subcaption}     \usepackage[utf8]{inputenc}     \usepackage{eurosym}     \newpsobject{psframegray}{psframe}{fillcolor=lightgray,linestyle=none,shadow,blur}     \definecolor{azultenue}{RGB}{65,170,193}     \definecolor{rojotenue}{RGB}{192,2,3}     \definecolor{naranjatenue}{RGB}{241,101,35}     \definecolor{verdetenue}{RGB}{144,169,61}     \definecolor{gris135}{RGB}{135,135,135}          \begin{document}          \vspace{2.1cm}      \begin{figure}[h!]     \centering          \resizebox{10cm}{!}{          \psset{framearc=0.2, shadowcolor=black!70, shadowangle=-90, unit=1.0cm,nodesep=0.12cm}     %     \def\pscolhookii{\hskip 1cm}     \def\pscolhookiii{\hskip 1cm}     \begin{psmatrix}[rowsep=0.2, colsep=5.2]% defines the distance between two frames     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     &     &     \\[2.5cm]     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%      [name=Inicio]      \psframegray(-2.5,-2.5)(2.5,2.5)     %      \rput(0,1.5){\circlenode[fillstyle=solid,fillcolor=azultenue]{p1}{\textcolor{black}{$p_1$}}}     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %     %     &[name=Conjunto]     \psframegray(-2.5,-2.5)(2.5,2.5)     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %     %     &[name=EM]     \psframegray(-2.5,-2.5)(2.5,2.5)     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %     %     \end{psmatrix}     %     {\psset{linewidth=3pt, linecolor=red, arrows=->, nodesep=4pt,  linearc=0.25, angleB=180, shortput=nab, npos = 0.4,nodesep=2.6cm}     \ncline{Inicio}{Conjunto}     \ncline{Conjunto}{EM}     }          }     %\vspace{3.85cm}     \vspace{2.85cm}     \caption{Esquema $(1 + \lambda)$}\label{1maslambda-ilustracion}     \end{figure}          \vspace{1cm}          \end{document}


title: Descriptive label for gantttitle

text: I'm using pgfgantt within MikTeX (both latest version) running fine.   In my gantt diagramm I have three title-lines: First year, than month and beneath the project month.   I'd like to place the text `project month` in the last title line just aligned like the titles produced by `ganttbar`. For better understanding here is a mwe (okay, the progress issues could further be removed)               \documentclass{standalone}     \usepackage{pgfgantt}     \begin{document}     \begin{ganttchart}[vgrid={draw=none,dotted,draw=none},%                     today=15,%                     today offset=.5,%                     today label=Heute,%                     progress=today,%                     bar incomplete/.append style={fill=red},%                     progress label text={\quad\pgfmathprintnumber[precision=0,verbatim]{#1}\%}%                     ]{1}{36}     \gantttitlecalendar*[compress calendar,time slot format=isodate]{2012-5-1}{2015-4-30}{year, month} \\     \gantttitlelist{1,...,36}{1}\\     \ganttbar{Arbeitspaket 1}{1}{4}\\     \ganttbar{Arbeitspaket 2}{3}{24}\\     \ganttbar{Arbeitspaket 3}{17}{36}\\     \end{ganttchart}     \end{document}      and the corresponding result: ![typesetted mwe](http://i.stack.imgur.com/0SvIM.png)


title: Set line spacing everywhere but in verbatim blocks

text: Is it possible to change the linespacing of a document except for inside verbatim blocks?               \usepackage{setspace}     \onehalfspacing      The above results in more readable paragraphs, but the code snippets are too large for my taste.


title: Setpartpreamble and indent

text: how can I enforce an indent in a `\setpartpreamble` enviroment? Seems like `\indent` ain't working and a solution with `\hspace` seems to me like guessing the correct length of an indent. Any idea on how to achieve this? Minimal example:               \documentclass[a4paper,12pt,twoside,final]{scrbook}          \begin{document}          \setcounter{part}{0}     \setpartpreamble{     \vspace*{4\baselineskip}          In the first part of this book we shall become familiar with the central ingredients of the description of classical electrodynamics, that is the Maxwell equations. We first follow a “derivation” of these equations, suggested by Richard P. Feynman, and then introduce the scalar and the vector potential.          \hspace{0.1cm} Appropriate combinations of their derivatives represent solutions of the homogeneous Maxwell equations. The inhomogeneous ones provide us with coupled inhomogeneous wave equations for these potentials which are determined by the charge and the current densities. We can decouple these equations by taking advantage of the gauge freedom of electrodynamics. In the non-relativistic limit the Coulomb gauge is convenient and allows us to obtain a rather intuitive picture for the energy of the electromagnetic field as a sum of the energies of a continuous superposition of harmonic oscillators.           The gauge freedom inherent in the Maxwell equations is also crucial in constructing the interaction of a charged particle with an electromagnetic field in quantum theory. The invariance of the Schrödinger equation under local phase transformation leads us to the minimal substitution which is at the very heart of Feynman’s derivation, as well as at the construction of the Lagrangian and the Hamiltonian of a charged particle in an electromagnetic field described by classical mechanics.       }     \part{Maxwell equations}     \end{document}


title: Combine minted and tcolorbox

text: I have the idea to combine `minted` with `tcolorbox`. At first, I have created my own minted environments:               \newminted[mycsharp]{csharp}{tabsize=2,fontsize=\footnotesize}     \newminted[myjson]{js}{tabsize=2,fontsize=\footnotesize}     \newminted[myxml]{xml}{tabsize=2,fontsize=\footnotesize}     \newminted[myshell]{shell-session}{tabsize=2,fontsize=\footnotesize}     \newminted[mycode]{text}{tabsize=2,fontsize=\footnotesize}      With them I do highlight my code:               \begin{myshell}     [root@localhost ~]# vi /etc/sysconfig/network     \end{myshell}     \captionof{listing}{Load network configuration with vi}      So I get the following: ![Example output](http://i.stack.imgur.com/vVz5C.png) Now I want to have a nice frame around. Since minted is not so powerful here, I want to use tcolorbox, so I did this:               \begin{tcolorbox}     \begin{myshell}     [root@localhost ~]# vi /etc/sysconfig/network     \end{myshell}     \end{tcolorbox}     \captionof{listing}{Load network configuration with vi}      And I get this one here: ![Example #2](http://i.stack.imgur.com/qonhD.png) This is nice, but not what I want. After looking in the package documentation of `tcolorbox` I found out that it supports titles: ![Exmaple #3](http://i.stack.imgur.com/FhDWM.png) It's getting better. After reading some more, `tcolorbox` also has supported for auto numbered titles and a "list of"-support. Unfortunately the provided examples in the documentation do not work, but that's another question. Okay, now. What do I want to have? I want to have something like:               \begin{listingsbox}{myshell}{A nice title}     [root@localhost ~]# vi /etc/sysconfig/network     \end{listingsbox}      to get the following output: ![Final example](http://i.stack.imgur.com/5m17S.png) Unfortunately I'm not able to write this by self. I tried it using the `\newenvironment` macro, but after googeling, it is not easy to integrate minted into a new environment. Can anyone help me out here?


The following document:               \documentclass[]{article}     \usepackage{tikz}     \usepackage{tikzscale}     \usetikzlibrary{trees}     \usetikzlibrary{calc}     \begin{document}     \tikzset{     block/.style = {draw, fill=white, rectangle,          minimum height=3em, minimum width=3em},     tmp/.style  = {coordinate},      sum/.style= {draw, fill=white, circle, node distance=1cm},     input/.style = {coordinate},     output/.style= {coordinate},     pinstyle/.style = {pin edge={to-,thin,black}}     }     \usetikzlibrary{shapes,arrows,positioning,calc}     \begin{figure}[ht]     \begin{tikzpicture}[auto, node distance=2cm,>=latex',every node/.style={transform shape}]     \tikzstyle{every node}=[font=\large]         \node [input, name=rinput] (rinput) {};         \node [sum, right of=rinput] (sum1) {-};           \draw [->] (rinput) -- node{$\beta_c$} (sum1);     \end{tikzpicture}     \end{figure}     \end{document}      Works fine. Now, I have a parent document of class book, and a child document (/subfile). If I put the above figure code (whether directly or using subfile) in the parent, it works fine. If I put it in the child, it give me errors:               Package pgf Error: Arrow end type ``latex''' unknown. ...tex',every node/.style={transform shape}]     Package pgf Error: Arrow end type ``latex''' unknown. ...tex',every node/.style={transform shape}]     Package pgf Error: Arrow end type ``latex''' unknown. ...tex',every node/.style={transform shape}]     Package pgf Error: Arrow end type ``latex''' unknown. ...tex',every node/.style={transform shape}]     Package pgf Error: Arrow end type ``tikze@>>@latex''' unknown. ...tex',every node/.style={transform shape}]     Package pgf Error: Arrow end type ``tikze@>@latex''' unknown. \draw [->]     Cannot patch \document,(auxhook) using \AtBeginDocument instead.     Unused global option(s): [english].     Overfull \hbox (13.70734pt too wide) in paragraph     Token not allowed in a PDF string (Unicode):(hyperref) removing `\textenglish'     Token not allowed in a PDF string (Unicode):(hyperref) removing `math shift'     Token not allowed in a PDF string (Unicode):(hyperref) removing `\phi'     Token not allowed in a PDF string (Unicode):(hyperref) removing `math shift'     Font shape `EU1/SimplifiedArabic(0)/m/sl' undefined(Font) using `EU1/SimplifiedArabic(0)/m/n' instead     \headheight is too small (12.0pt): Make it at least 13.9141pt.     Token not allowed in a PDF string (Unicode):(hyperref) removing `\textenglish'     Token not allowed in a PDF string (Unicode):(hyperref) removing `math shift'     Token not allowed in a PDF string (Unicode):(hyperref) removing `\chi'     Token not allowed in a PDF string (Unicode):(hyperref) removing `math shift'     Underfull \vbox (badness 1895) has occurred while \output is active []     \headheight is too small (12.0pt): Make it at least 13.9141pt.     Token not allowed in a PDF string (Unicode):(hyperref) removing `\textenglish'     Token not allowed in a PDF string (Unicode):(hyperref) removing `math shift'     Token not allowed in a PDF string (Unicode):(hyperref) removing `\beta'     Token not allowed in a PDF string (Unicode):(hyperref) removing `math shift'     \headheight is too small (12.0pt): Make it at least 13.9141pt.     \headheight is too small (12.0pt): Make it at least 13.9141pt.     Some font shapes were not available, defaults substituted.


title: Is there a (free) alternative to WinEdt that handles projects in a similar way?

text: The title pretty much says it all-- I'm trying to get myself onto open source, or at least freely available, software. I've been using WinEdt forever, and despite its faults, it has one killer feature that I can't seem to go without: the way it handles projects. I'm sure I am not using it exactly as it was intended: I teach several classes, and I like to save all of the quizzes/exams/syllabi/etc. for each class in its own project file. That way, when I switch from thinking about class A to thinking about class B, I can switch projects and have all of my tex files from class B open up at the same time. WinEdt handles this perfectly by saving all the open files as a project and storing recently used projects in a drop-down menu. Are there any other LaTeX editors that save projects similarly?


title: embedding movies using media9 does not work. compiles without errors

text: Embedding movies using `media9` does not work. Linking to online movies does. I am sure that I am using the correct mp4 format and h264 encoding so the problem should not be with the movie files. The document compiles without errors, however when I open the document there is either a blank space or a grey rectangle. How can this problem be solved? Have others experienced similar problems? I can view the movies and 3d content in the `\media9` package documentation.               \documentclass[12pt,landscape]{article}          \usepackage{media9}     \usepackage{hyperref}          \begin{document}     the beginning of the document          \includemedia[     activate=pageopen,     height=170pt,     addresource=video.mp4,     flashvars={%     source=video.mp4     &scaleMode=stretch}     ]{}{VPlayer.swf}          the end of the document     \end{document}


title: Why does a tikz spy specified as a chamfered rectangle show up as a simple rectangle?

text: I'd like to use a tikz spy shaped like a chamfered rectangle. The code runs without complaining, but the result is a plain rectangle. "rounded rectangle" works as expected, as does chamfered-rectangle-shaped non-spy nodes. How could I fix this? The code below should demonstrate my problem. Unfortunately I don't have enough rep to add a picture.. pdflatex Version 3.1415926-2.4-1.40.13 (TeX Live 2012/Debian) I had the same issue in Windows yesterday, I believe that was Tex Live 2012 as well. tikz 2010/10/13 v2.10 (rcs-revision 1.76)               \documentclass{article}     \usepackage{tikz}     \usetikzlibrary{spy,decorations.fractals,shapes.misc}          \begin{document}          \tikz\node[draw, circle] {circle};     \begin{tikzpicture}       [spy using outlines={circle, magnification=3, size=1cm, connect spies}]       \draw [decoration=Koch curve type 1]         decorate{ decorate{ decorate{ (0,0) -- (2,0) }}};       \spy [red] on (1.6,0.3) in node at (3,1);     \end{tikzpicture}          \tikz\node[draw, rounded rectangle] {rounded rectangle};     \begin{tikzpicture}       [spy using outlines={rounded rectangle, magnification=3, width=2cm, height=1cm, connect spies}]       \draw [decoration=Koch curve type 1]         decorate{ decorate{ decorate{ (0,0) -- (2,0) }}};       \spy [red] on (1.6,0.3) in node at (3,1);     \end{tikzpicture}          \tikz\node[draw, chamfered rectangle] {chamfered rectangle};     \begin{tikzpicture}       [spy using outlines={chamfered rectangle, magnification=3, width=2cm, height=1cm, connect spies}]       \draw [decoration=Koch curve type 1]         decorate{ decorate{ decorate{ (0,0) -- (2,0) }}};       \spy [red] on (1.6,0.3) in node at (3,1);     \end{tikzpicture}          \end{document}      Here's what it produces for me: ![enter image description here](http://i.stack.imgur.com/pwGcO.png)


title: Editor with Word like "word completion" feature

text: Besides defining longer technical words by               \newcommand{\trimam}{trans-impedance-amplifier}      to save typing time. Is there a Latex Editor (can be Linux or Windows) that offers "word completion" https://help.libreoffice.org/Writer/Word_Completion_for_Text_Documents similar like Libreoffice or Word. For technical documents \newcommand might be better changing a technical term afterwards through the whole document. But for prose text I would prefer a "word completion" feature indexing already used words and offering shortcut completion when typing first three letters.


title: TikZ- best practice for line starting on a circle's edge?

text: I'd like to know how I can achieve the best seamless crossover between a node (in this case, a circle) and a line starting on that node. I would like the line to only touch the circle's edge. So far I have found 2 methods to achieve some mere results:   * `shorten <=`: It works in a somewhat satisfying fashion after some T & E runs.   * `\begin{pgfonlayer}{background}`: puts the enclosed contentin the background. Does not work very well as it puts the corresponding content (in this case, 2 lines) under other, already existing content (in this case, the "grid"). ![enter image description here](http://i.stack.imgur.com/YHIyG.png) **MWE:**               \documentclass[     11pt     ]{scrartcl}          \usepackage{     tikz,     relsize,     amsmath     }          \usepackage[T1]{fontenc}     \usepackage[utf8]{inputenc}     \usepackage{lmodern}               %% from here on forth TikZ-stuff          \usetikzlibrary{     calc,trees,shadows,positioning,arrows,chains,shapes.geometric,     decorations.pathreplacing,decorations.pathmorphing,shapes,     matrix,shapes.symbols,patterns,intersections,fit     }          \pgfdeclarelayer{background layer}     \pgfdeclarelayer{foreground layer}     \pgfsetlayers{background layer,main,foreground layer}          \tikzset{     >=latex     }          \begin{document}          \begin{center}     \begin{tikzpicture}[font=\sffamily\small]     %     \draw[style=help lines,step=0.5cm] (0,0) grid (8,6);     %     \draw[->,thick] (-0.1,0) -- (8.5,0) node[anchor=west]{x}; %X-Achse     \draw[->,thick] (0,-0.1) -- (0,6.5) node[anchor=south]{y}; %Y-Achse     %     \draw     (0,0) coordinate (orig)     (3,3) coordinate (B)     (4.5,4.5) coordinate (C)     ;     %     \foreach \pt/\labpos in {B/below right,C/below right}{       \filldraw (\pt) circle (3pt) node[\labpos=3pt,fill=white]{\pt};     };     %     \path[name path=Segment] (B) -- (C);     %highlight segment     \draw     ($(B) + (-0.75,0.75)$) coordinate (BPoint)     ($(B) + (-0.25,0.25)$) coordinate (BPointExtra)     ($(C) + (-0.75,0.75)$) coordinate (CPoint)     ;     %\begin{pgfonlayer}{background layer}     \draw[black!60,thick,shorten <=3pt] (B) -- (BPoint);     \draw[black!60,thick,shorten <=2pt] (C) -- (CPoint);     %\end{pgfonlayer}     \draw[black!60,thick,<->,shorten >=2pt,shorten <=2pt] (BPointExtra) -- ($(C)!(BPointExtra)!(CPoint)$) node[black!60,above=3pt,midway,rotate=45,fill=white]{Segment};     \end{tikzpicture}     \end{center}          \end{document}


title: latex command to genenerate output similar to this website

text: How can I generate latex with the following format in latex? I know about `tex4ht` and I know about `latex4html` but couldn't get similar output. Source Website is here and a snapshot from the page is given below ![enter image description here](http://i.stack.imgur.com/1R7re.png) Sample Tex File (Notice the tables in the above link)               \documentclass[ebook,10pt,oneside,openany,final]{memoir}          \usepackage[american]                {babel}        % needed for iso dates     \usepackage[iso,american]                {isodate}      % use iso format for dates     \usepackage[final]                {listings}     % code listings               \setcounter{totalnumber}{10}          % Base definitions for tables     \newenvironment{TableBase}     {      \renewcommand{\tcode}[1]{{\CodeStylex{##1}}}      \newcommand{\topline}{}      \newcommand{\capsep}{}      \newcommand{\rowsep}{}      \newcommand{\bottomline}{}          %% vertical alignment      \newcommand{\rb}[1]{\raisebox{1.5ex}[0pt]{##1}}    % move argument up half a row          %% header helpers      \newcommand{\hdstyle}[1]{\textbf{##1}}             % set header style      \newcommand{\Head}[3]{\multicolumn{##1}{##2}{\hdstyle{##3}}}   % add title spanning multiple columns      \newcommand{\lhdrx}[2]{\Head{##1}{|c}{##2}}        % set header for left column spanning #1 columns      \newcommand{\chdrx}[2]{\Head{##1}{c}{##2}}         % set header for center column spanning #1 columns      \newcommand{\rhdrx}[2]{\Head{##1}{c|}{##2}}        % set header for right column spanning #1 columns      \newcommand{\ohdrx}[2]{\Head{##1}{|c|}{##2}}       % set header for only column spanning #1 columns      \newcommand{\lhdr}[1]{\lhdrx{1}{##1}}              % set header for single left column      \newcommand{\chdr}[1]{\chdrx{1}{##1}}              % set header for single center column      \newcommand{\rhdr}[1]{\rhdrx{1}{##1}}              % set header for single right column      \newcommand{\ohdr}[1]{\ohdrx{1}{##1}}      \newcommand{\br}{\hfill\break}                     % force newline within table entry          %% column styles      \newcolumntype{x}[1]{>{\raggedright\let\\=\tabularnewline}p{##1}}  % word-wrapped ragged-right                                                                         % column, width specified by #1      % \newcolumntype{m}[1]{>{\CodeStyle}l{##1}}              % variable width column, all entries in CodeStyle      \newcolumntype{m}[1]{l{##1}}                           % variable width column, all entries in CodeStyle     }     {     }          % General Usage: TITLE is the title of the table, XREF is the     % cross-reference for the table. LAYOUT is a sequence of column     % type specifiers (e.g. cp{1.0}c), without '|' for the left edge     % or right edge.          % usage: \begin{floattablebase}{TITLE}{XREF}{COLUMNS}{PLACEMENT}     % produces floating table, location determined within limits     % by LaTeX.     \newenvironment{floattablebase}[4]     {      \begin{TableBase}      \begin{table}[#4]      \caption{\label{#2}#1}      \begin{center}      \begin{tabular}{|#3|}     }     {      \bottomline      \end{tabular}      \end{center}      \end{table}      \end{TableBase}     }          % usage: \begin{floattable}{TITLE}{XREF}{COLUMNS}     % produces floating table, location determined within limits     % by LaTeX.     \newenvironment{floattable}[3]     {      \begin{floattablebase}{#1}{#2}{#3}{htbp}     }     {      \end{floattablebase}     }               \newcommand{\CodeStylex}[1]{\texttt{#1}}     \newcommand{\tcode}[1]{\CodeStylex{#1}}          \begin{document}     \begin{floattable}     {Potential \tcode{setlocale} data races}     {tab:setlocale.data.races}     {lllll}     \topline          \tcode{fprintf}     &     \tcode{isprint}     &     \tcode{iswdigit}    &     \tcode{localeconv}  &     \tcode{tolower}     \\          \end{floattable}          \end{document}


title: How to make a tabular in a header ignore the environment set by the currently processed longtable

text: I have a tabular in my header, using `fancyhdr` and a `longtable` that take multiple pages. The `longtable` has been created by an environment that also sets some variables:               \newcolumntype{|}{!{\color{white}\vline}}     \rowcolors{2}{greylight}{greynormal}%     \setlength{\tabcolsep}{12pt}%                                  \setlength{\extrarowheight}{5pt}%                                            \setlength{\arrayrulewidth}{2pt}%      The problem I am facing is that on all pages where the longtable is not finished yet, the tabular in the header will use theses changes. Is there a convenient way, inside my header, to reset all thoses variables that could have been set ? For now, I redefined those specific variables in the header, but I find it quite dirty and not very robust.


title: Defining the minimal amount of space around an operator

text: How do I define the minimal (and possibly maximal) amount of horizontal space around an operator? Something similar to wrapping the operator with `\,`s. Here's a picture: ![$\\C \\setminus A$](http://i.stack.imgur.com/vpBN2.png) And a minimal example (sorry, I have no idea how to do this with `standalone`):               \documentclass[12pt]{article}     \usepackage[paperwidth=4.25in,paperheight=5.5in]{geometry}          \usepackage{amssymb}     \usepackage{savetrees}          \begin{document}         Ut consequat place sollicitudin, at sollicitudin nisi          vestibulum varius $\mathbb{C} \setminus A$ semper dolor          lectus, quis lacinia sem hendrerit.     \end{document}


title: Adding slides to previous section - Beamer

text: My presentation is consisted of 4 consecutive slides. I want to divide them in 2 sections. My code:                   \documentclass{beamer}                 \mode<presentation>                         {\usetheme{Frankfurt}                          \usecolortheme{lily}                          \usefonttheme{professionalfonts}}         \usepackage[english]{babel}         \beamertemplatenavigationsymbolsempty         \setbeamerfont{page number in head/foot}{size=\tiny}         \setbeamertemplate{footline}[frame number]              \begin{document}              \section{Numerical examples}         \begin{frame}         Example 1         \end{frame}              \section{Results}         \begin{frame}         Results 1         \end{frame}              \section{Numerical examples}         \begin{frame}         Example 2         \end{frame}              \section{Results}         \begin{frame}         Results 2         \end{frame}              \end{document}      I have something like this: ![enter image description here](http://i.stack.imgur.com/wiE5b.png) Because they have the same names, I would like to achieve the following results: ![enter image description here](http://i.stack.imgur.com/hYY56.png) How can I add slide to the previous section?


title: Arrow tip center with TikZ (and pgfplots)

text: The arrow default behaviour is shown on the left picture part. How can I achieve that the “circle” arrow tips (see the picture below) end at their center, as drawn in the right image, but without manual tweaking? If it is important: I need it to mark beginning and end of a curve in pgfplots, but I missed this feature so many times in TikZ as well that I post the more general question. ![Arrow behaviour: state of the art and what I need.](http://i.stack.imgur.com/gDBEm.png)               \documentclass[tikz,border=5mm,convert]{standalone}          \usetikzlibrary{arrows}          \begin{document}          \begin{tikzpicture}     \draw [black!20] (-.2,-.2) grid (1.2,1.2);     \draw [<->] (0,0) -- (1,1);     \draw [o-*] (0,1) -- (1,0);     \begin{scope}[xshift=1.5cm]       \draw [black!20] (-.2,-.2) grid (1.2,1.2);       \draw [<->] (0,0) -- (1,1);       \draw [o-*] (-.06,1.06) -- (1.06,-.06);     \end{scope}     \end{tikzpicture}          \end{document}      * * * Ignasi posted a solution that works with pgfplots as well (thanks for that) but it does not integrate in the arrows “system” and lengths have to be given manually. Is there a solution that provides these features? * * * Using the solution with pgfplots results in strange looking graphs if there are plot coordinates inside the arrow tip: ![Strange looking plot](http://i.stack.imgur.com/BvMF6.png) I consider this being a feature but a different behaviour could be beneficial. So, is there a possibility to automatically skip coordinates inside the arrow tip? Using a fill for the ring is no solution since it will remove other objects as well. Here the code for the plot:               \documentclass[tikz,convert]{standalone}          \usetikzlibrary{arrows.meta}     \usepackage{pgfplots}          \begin{document}          \begin{tikzpicture}[markstart/.style={{Circle[open, length=4mm]}-,shorten <=-2mm}]     \begin{axis}[width=5cm]     \addplot [markstart] coordinates { (0,0) (0.01,0) (0.01,0.01) (0.04,0.03) (.5,.5) };     \end{axis}     \end{tikzpicture}          \end{document}


title: Wrapping Lyx Graphic

text: I'm very new to this whole LaTeX system, but I love the typesetting, it looks so much better than Word, but i'm currently preparing an article with multiple columns using a \start{multicols} script i found on the net, but i'm having huge difficulty inserting an image so it wraps around the text. It kind of works for the first column but then it doesn't see the rest of the text. I tried the setting for the 'float image wrap' to right, left, inner, outer, overhang but they don't make much of a difference. Is there any way to get around this? (I have enclosed a picture, sorry about the woeful Adobe Acrobat snapshot quality...) Thanks in advance, ![enter image description here](http://i.stack.imgur.com/aG5d4.png)


title: Availability of LaTeX packages' functionality in ConTeXt, XeTeX, and LuaTeX

text: I am considering trying out ConTeXt, XeTeX, and LuaTeX, but one concern of mine is the fact that I am using a large number of LaTeX packages. There are a number of questions comparing these TeX derivatives with LaTeX. These two (here and here) seem relevant to this question of mine. What I am especially interested in is the functionality I presently get. Put in the simplest possible terms: The large number of LaTeX packages exists because they provide valuable functionality. It would seem hard to believe that ConTeXt is so advanced that all of these packages' functionality is not needed within ConTeXt. Similarly, I am wondering about present-day compatibility of LaTeX packages with XeTeX and LuaTeX. **So, how much LaTeX functionality is easily available or needed in each of ConTeXt, XeTeX, and LuaTeX, and how do I make it available?**


title: how to disable automatic highlighting of texStudio for matched Latex tokens?

text: This question is different that the following question TeXStudio : Disable auto-completion of parentheses The above question asks how to disable automatic completion of parentheses (which I have disabled). I am not able to find how to disable another very annoying feature. When the mouse is on a "(" or a "$" or "{" any token that requires a corresponding token on the other side, TexStudio jumps in and highlights these with a yellow box and changes the letter to red. I spend long time and googling and not able to find what I need to turn off. I think I turned off almost everything, and it still does it. Turned of all syntax highlighting I can see. Here is an example: ![enter image description here](http://i.stack.imgur.com/wobKI.gif) Here is my configuration ![Mathematica graphics](http://i.stack.imgur.com/ot8u4.png) ![Mathematica graphics](http://i.stack.imgur.com/rYwHI.png) ![Mathematica graphics](http://i.stack.imgur.com/Hqy5U.png) ![Mathematica graphics](http://i.stack.imgur.com/g1o2e.png) ![Mathematica graphics](http://i.stack.imgur.com/QSSQV.png) I am ready to uninstall this software, but thought to ask here first. (or may be I should just use emacs and be done with it) ![Mathematica graphics](http://i.stack.imgur.com/VaM6K.png) Windows 7, 64 bit. Miktex 9 (latest) thank you


title: page number does not appear on first page of bibliography

text: When I make my bibliography, something strange happens. If the bibliography is more than one page, the page number is not included on the first page. I want the page number on bottom-center of the first page, just like it is in the following pages. If I take out a few of the citations in chapter one so that the bibliography fits on one page, the first page of the bibliography has a page number. Here's a MWE:               \documentclass[11pt, letterpaper]{thesis}          \usepackage[lmargin=1.5in, rmargin=1.0in, tmargin=2.0in, bmargin=1.25in, footskip=0.35in]{geometry}     \usepackage{fancyhdr}     \pagestyle{fancy}     \renewcommand{\headrulewidth}{0pt}     \fancyhf{}     \cfoot{\thepage}          \renewcommand{\thechapter}{\Roman{chapter}}     \usepackage{titlesec}     \assignpagestyle{\chapter}{fancy}     \titleformat{\chapter}[display]{\normalfont \centering}{CHAPTER \chaptertitlename\ \thechapter}{11 pt}{}               \begin{document}          \chapter{Chapter One}     \thispagestyle{fancy}          \cite{ClusteringBook}     \cite{HSOM}     \cite{ImageSegClustering}     \cite{Conscience}     \cite{Iris}     \cite{Kohonen}     \cite{LabelSOM}     \cite{kMeans1}     \cite{GrowingGrid}     \cite{UstarClustering}     \cite{GA_SOM}               \newpage     \addcontentsline{toc}{chapter}{REFERENCES}     \renewcommand{\bibname}{REFERENCES}          \bibliographystyle{ieeetr}     \bibliography{references}     \thispagestyle{fancy}     \clearpage               \end{document}      I don't know how to add the `references.bib` file so I'll just paste it in here - I apologize for this as I'm sure there is a better way of doing this. Feel free to tell me a better way of including my references (maybe a dummy reference file) and I can change this.               @book{Kohonen,      editor = {Teuvo Kohonen and Manfred Schroeder and Thomas Huang},      title = {Self-{O}rganizing {M}aps},      year = {2001},      isbn = {3540679219},      edition = {3rd},      publisher = {Springer-Verlag New York, Inc.},      address = {Secaucus, NJ, USA},     }           @book{ClusteringBook,       author = {Gan, Guojun and Ma, Chaoqun and Wu, Jianhong},       howpublished = {Paperback},       isbn = {0898716233},       posted-at = {2010-05-21 23:59:45},       priority = {2},       publisher = {SIAM, Society for Industrial and Applied Mathematics},       title = {{Data {C}lustering: {T}heory, {A}lgorithms, and {A}pplications ({ASA-SIAM} {S}eries on {S}tatistics and {A}pplied {P}robability)}},       year = {2007}     }          % Data          @Article{Iris,       author =  "R. A. Fisher",       title = {{T}he {U}se of {M}ultiple {M}easurements in {T}axonomic {P}roblems},       journal = "Annals of Eugenics",       year =    "1936",       volume =  "7",       pages =   "179--188"     }          @TechReport{Wine,       author = {S. Aeberhard and D. Coomans and O. de Vel},       title = {{C}omparison of {C}lassifiers in {H}igh {D}imensional {S}ettings},       year = {1992},        institution =  {Dept. of Computer Science and Dept. of Mathematics and Statistics, James Cook University of North Queensland},       number = {92-2}     }          @InProceedings{Glass,       author =  "I. W. Evett and E. J. Spiehler",       title =   "{R}ule {I}nduction in {F}orensic {S}cience",       booktitle =   "KBS in Goverment",       year =    "1987",       pages =   "107--118",       publisher_address = "Pinner, UK",       publisher = "Online Publications"     }          @INPROCEEDINGS{ControlChart,         author = {R. J. Alcock and Y. Manolopoulos},         title = {{T}ime-series {S}imilarity {Q}ueries {E}mploying a {F}eature-{B}ased {A}pproach},         booktitle = {In 7 th Hellenic Conference on Informatics, Ioannina},         year = {1999},         pages = {27--29}     }          @article{ColonCancer,         address = {Department of Molecular Biology, Princeton University, Princeton, NJ 08540, USA.},         author = {U. Alon, and N. Barkai and D. A. Notterman and K. Gish and S. Ybarra and D. Mack and A. J. Levine},         day = {8},         doi = {10.1073/pnas.96.12.6745},         issn = {0027-8424},         journal = {Proceedings of the National Academy of Sciences of the United States of America},         month = jun,         number = {12},         pages = {6745--6750},         pmid = {10359783},         posted-at = {2010-07-02 02:37:07},         priority = {0},         title = {{B}road patterns of gene expression revealed by clustering analysis of tumor and normal colon tissues probed by oligonucleotide arrays},         volume = {96},         year = {1999}     }          % Software          @misc{SOMtoolbox,           author = {Esa Alhoniemi and Johan Himberg and Juha Parhankangas and Juha Vesanto},           title = "{SOM} {T}oolbox",           year = 2005,           url = "http://www.cis.hut.fi/projects/somtoolbox",           note = "Accessed: 5/02/2011"     }          @book{MATLAB:2010,       year = {2010},       author = {MATLAB},       title = {version 7.10.0 (R2010a)},       publisher = {The MathWorks Inc.},       address = {Natick, Massachusetts}     }          @misc{jfree,         author = {Gilbert, David and Morgner, Thomas},         citeulike-article-id = {1104142},         keywords = {bibtex-import},         posted-at = {2007-02-13 04:22:04},         priority = {0},         title = {{JFreeChart}},         year = {2003 - 2005}     }               % Quality Measures          @InCollection{TEfirstsecondBMU,       author =  "K. Kiviluoto",       title =   "{T}opology {P}reservation in {S}elf-{O}rganizing {M}aps",       booktitle =   "International Conference on Neural Networks",       pages =   "294--299",       year =    "1996",       publisher =   "IEEE Press",     }          @Article{TEtopProd,       author =  "Hans-Ulrich Bauer and Klaus R. Pawelzik",       title =   "{Q}uantifying the {N}eighborhood {P}reservation of              {S}elf-{O}rganizing {F}eature {M}aps",       type =    "Paper",       journal = "IEEE Transactions on Neural Networks",       year =    "1992",       volume =  "3",       number =  "4",       pages =   "570--579",       month =   jul,     }          % Learning Rate & Paramters          @Article{PLSOM,       title = "{I}mproved {PLSOM} {A}lgorithm",       author = "Erik Berglund",       journal = "Appl. Intell",       year = "2010",       number = "1",       volume = "32",       pages = "122--130",     }          @InProceedings{Conscience,       author = "D. DeSieno",       title = "{A}dding a {C}onscience to {C}ompetitive {L}earning",       pages = "117--124",       booktitle = "IEEE International Conference on Neural Networks",       volume = "1",       organization = "(San Diego 1988)",       publisher = "IEEE",       address = "New York",       year = "1988",     }               % Clustering/Classification          @Article{SOMclustering,         author = {Juha Vesanto and Esa Alhoniemi},         title = {{C}lustering of the {S}elf-{O}rganizing {M}ap},          journal = {IEEE Transactions on Neural Networks},          publisher = {IEEE},         year = {2000},         volume = {11},         number = {3},         month = {May},         pages = {586--600},         note = {},         annote = {}     }          @InProceedings{ImageSegClustering,         author = {D. Opolon and F. Moutarde},       booktitle = {In Proc. of ESANN'2004, Bruges},       pages = {507-512},       title = {{F}ast semi-automatic segmentation algorithm for {S}elf-{O}rganizing {M}aps},       year = {2004},     }          @INPROCEEDINGS{LabelSOM,         author = {Andreas Rauber},         title = {{L}abel{SOM}: {O}n the {L}abeling of {S}elf-{O}rganizing {M}aps},         booktitle = {In Proc. International Joint Conference on Neural Networks},         year = {1999},         pages = {1--6}     }          @InProceedings{Pmatrix,       author = "A. Ultsch",       booktitle = "In Proceedings Workshop on Self-Organizing Maps (WSOM 2003)",       pages = "225--230",       title = "{M}aps for the {V}isualization of high-dimensional {D}ata {S}paces",       address = "Kyushu, Japan",         year = 2003     }          @techreport{UstarMatrix,         author = {Ultsch, Alfred},       title = {U*-{M}atrix: a {T}ool to visualize {C}lusters in high dimensional {D}ata},       school = {CS Department, Philipps-University Marburg, Germany},       address = {Marburg, Germany},         number = {36},       year = 2004     }          @InProceedings{UstarClustering,       author = "Alfred Ultsch and Fabian. Moutarde",       booktitle = "Workshop on Self-Organizing Maps (WSOM'2005), Paris",       pages = " 25-32",       title = "{U}*{F} {CLUSTERING: A NEW PERFORMANT CLUSTER-MINING METHOD BASED ON SEGMENTATION OF SELF-ORGANIZING MAPS}",       address = "Paris, France",       year = 2005     }          @InProceedings{LabelProp,       author = {Alfred Ultsch and Lutz Herrmann},       booktitle = {Proceedings of the 6th International Workshop on Self-Organizing Maps (WSOM 2007)},       title = {Label {P}ropagation for {S}emi-{S}upervised {L}earning in {S}elf-{O}rganizing {M}aps},       publisher = {Neuroinformatics Group Bienfeld University, Germany},       address = {Germany},       year = 2007     }               % Fast BMU searches          @TechReport{FastBMUsearch1,     author = {T. Kohonen},     title = {Report {A}33},     institution = {Laboratory of Computer and Information Sciene, Helsinki University of Technology},     year = {1996},     OPTaddress = {Espoo, Finland},     }               @InProceedings{FastBMUsearch2,       author =       {Makoto KINOUCHI and KUDO Yoshihiro},       title =        {{M}uch faster learning algorithm for {B}atch-{L}earning {SOM} and its application to {B}ioinformatics},       booktitle =    {Proceedings of the Workshop on Self-Organizing Maps ({WSOM}'03)},       pages =        {},       year =         {2003},       address =      {Kitakyushu, Japan},       month =        {September},     }          % Supervised Methods          @ARTICLE{Phonetic,     AUTHOR = "Teuvo Kohonen",     TITLE = "{T}he {N}eural {P}honetic {T}ypewriter",     JOURNAL = "IEEE Computer",     PAGES = {11-22},     YEAR = {1988},     }          @inproceedings{Phonotopic,         address = {Silver Spring, MD},         author = {Kohonen, Teuvo and M{\"a}kisara, Kai and Saram{\"a}ki, Tapio},         booktitle = {Proceedings of the 6th International Conference on Pattern Recognition},         pages = {182--185},         posted-at = {2008-03-11 13:01:28},         priority = {2},         publisher = {{IEEE} Computer Society Press},         title = {Phonotopic Maps---{I}nsightful {R}epresentation of {P}honological {F}eatures for {S}peech {R}ecognition},         year = {1984}     }          @inproceedings{kMeans1,      author = {Ba\c{c}\~{a}o, Fernando and Lobo, Victor and Painho, Marco},      title = {Self-organizing maps as substitutes for k-means clustering},      booktitle = {Proceedings of the 5th international conference on Computational Science - Volume Part III},      series = {ICCS'05},      year = {2005},      pages = {476--483},      publisher = {Springer-Verlag},      address = {Berlin, Heidelberg},     }           % GAs          @inproceedings{GA_SOM,      author = {Cateni, Silvia and Colla, Valentina and Vannucci, Marco},      title = {A {G}enetic {A}lgorithms-based {A}pproach for {S}electing the {M}ost {R}elevant {I}nput {V}ariables in {C}lassification {T}asks},      booktitle = {Proceedings of the 2010 Fourth UKSim European Symposium on Computer Modeling and Simulation},      series = {EMS '10},      year = {2010},      isbn = {978-0-7695-4308-6},      pages = {63--67},      numpages = {5},      url = {http://dx.doi.org/10.1109/EMS.2010.23},      doi = {10.1109/EMS.2010.23},      acmid = {1932715},      publisher = {IEEE Computer Society},      address = {Washington, DC, USA},      keywords = {variable selection, calssification, genetic algorithms, self organizing maps},      }          @ARTICLE{HSOM,         author = {Risto Miikkulainen},         title = {{S}cript {R}ecognition with {H}ierarchical {F}eature {M}aps},         journal = {Connection Science},         year = {1990},         volume = {2},         pages = {83--101}     }          @ARTICLE{GrowingGrid,         author = {Bernd Fritzke},          title = {{G}rowing {G}rid - a {S}elf-{O}rganizing {N}etwork with constant neighborhood range and adaptation strength},          journal = {Neural Processing Letters},          year = {1995},          volume = {2},          pages = {9--13}      }


title: How do I pass the index style file to makeindex using arara?

text: I am running `arara` like this: `% arara: makeindex: { options: -s "%tm.ist" -t "%tm.glg" -o "%tm.gls" "tm.glo" }` to produce glossaries with the package `gloassaries`. I took this options from my IDE settings, where they have been working. Now, when running `arara`, it stops telling me:               Running MakeIndex...           Index style file %tm.ist not found.     Usage: makeindex [-ilqrcgLT] [-s sty] [-o ind] [-t log] [-p num] [idx0 idx1 ...]     FAILURE     make: *** [ararabuild] Fehler 1      Sorry, but that is too cryptic for me. What is happening? `main.ist` does exist in the main folder.


title: restricted write18 is preventing the command: runsystem(gnuplot filename.gnuplot) from being executed

text: That pretty much says it all. I'm on a mac, using Texmaker, `gnuplot` works well with `aquaterm`, I can pass code for diagrams from GeoGebra (geometry package) that works fine. It seems like using `gnuplot` is the issue. I get the following in my log file:               runsystem(gnuplot kjhgf.func0.gnuplot)...disabled (restricted).     Package pgf Warning: Plot data file `kjhgf.func0.table' not found. on input      line 22.      I am wondering how to "unrestrict" `gnuplot` (I assume `runsystem` is not the offender) or fully enable `\write18`. I've tried `-shell-escape` (and `-enable-write18`) and many of its variants, although I have a lot of options in Texmaker's preferences.


title: Preventing to start a new page with the temporary change to landscape mode

text: When I use ![enter image description here](http://i.stack.imgur.com/YBrYx.png) When I insert a picture with landscape mode, the new page break is introduced to make a big blank. Can I prevent this?               \section{A}     \label{sec:flow-data-through}          Figure \ref{df} shows the data flow diagram of \system.           <-- New page begins               \begin{figure}[htpb]       \centering       \includegraphics[width=1.2\textwidth]{fig/flow.pdf}       \caption{The flow of data through the system}     \lable{df}     \end{figure}          abcdef


title: Change page margins in LyX

text: I use LyX 2.1, and I want to change the margins of a document as follows:   * Top and bottom: 2.5   * Right: 2   * Left: 3 How can I do this? Thanks.


title: Errors when trying to use chemfig

text: When trying to use chemfig I get two errors.First there is a "two documentclass" error and second a "undefined control sequence \chemfig".What can be done about this? Uninstall/reinstall doesn't help.


title: Why do these two rectangles not coincide?

text: Here is the code with tikz:               \documentclass{article}     \usepackage{tikz}     \usetikzlibrary{calc}          \begin{document}     \begin{tikzpicture}[x=.8mm, y=30mm][remember picture]     \tikzstyle{reverseclip}=[insert path={       (current page.north east) --       (current page.south east) --       (current page.south west) --       (current page.north west) --       (current page.north east)}     ]     \coordinate (lowerleft) at (-2mm, 2mm);     \coordinate (upperright) at (120, 2.6);              % \input{pts}     % \path [fill=orange, draw=orange] (lowerleft) rectangle (upperright);     \fill [orange] (lowerleft) rectangle (upperright);          \begin{pgfinterruptboundingbox}     \path  [clip] (20, 1) circle [radius=2mm] [reverseclip];     \path  [clip] (30, 1.5) circle [radius=2mm] [reverseclip];     \path  [clip] (40, 1.3) circle [radius=2mm] [reverseclip];     \end{pgfinterruptboundingbox}          % \path [fill=white, draw=white] (lowerleft) rectangle (upperright);     \fill [white] (lowerleft) rectangle (upperright);     % \draw [help lines, opacity=.2] (lowerleft) grid (upperright);         \end{tikzpicture}     \end{document}      The result: ![enter image description here](http://i.stack.imgur.com/Qpc08.png) I would expect the second retangle to completely cover the first except for the 3 round spots.


title: Condensed comment font in listings

text: I'm trying to condense the size of my comments by using a condensed font however its not working correctly. The font shape looks fine with `ttfamily` enabled in `basicstyle`, however, there is a huge amount of space between the letters for comments. How can I get rid of this spacing?               \documentclass{article}     \usepackage[T1]{fontenc}     \usepackage{lmodern}          \begin{document}         \begin{lstlisting}[language=Prolog,basicstyle=\ttfamily\footnotesize,commentstyle=\fontseries{lc}\selectfont\itshape]         hello :- world         % This is a comment         \end{lstlisting}         \end{document}      Edit: How do I get the source of this post to compile like I've seen in other threads?


title: setting the font size for page number in memoir class

text: The requirement for my document is to have times new roman font type with font size of 12 at the main body and size 8 for page number. I'm new to latex and I've looked it up in the documentation for memoir class but got even more confused than ever as I found different class option for different types of text size and options as shown in Table 3.7 of the attached linked documentation. http://www.tex.ac.uk/ctan/macros/latex/contrib/memoir/memman.pdf Can anyone please enlighten me on this matter? Many thanks in advance


title: Weird list formatting with xwatermark and refstepcounter

text: I discovered some weird behaviour with `xwatermark` and `\refstepcounter` which I cannot explain. I created a list and the indentation of the first item is correct, but all others are too much indented. If instead `\stepcounter` is used, it's working again. Also if the `xwatermark` package is not loaded. The question is not how to fix this, but why this happens. The package `xwatermark` is not supposed to influence the layout in any way. And the connection to `\refstepcounter` is completely incomprehensible to me.               \documentclass{article}     \setlength{\parindent}{0pt}     \newcounter{num}     \newcommand{\ta}{\refstepcounter{num} \makebox[10mm][l]{\Roman{num})}test\\       \hspace*{185,5mm}       \begin{minipage}{15mm}       \end{minipage}     }     \usepackage{xwatermark}     \begin{document}       Test            \ta       \ta       \ta     \end{document}      ![only first item aligned correctly with xwatermark loaded or refstepcounter used instead](http://i.stack.imgur.com/I8gEk.png)                    *File List*      article.cls    2007/10/19 v1.4h Standard LaTeX document class       size10.clo    2007/10/19 v1.4h Standard LaTeX file (size option)     xwatermark.sty    2012/10/23 v1.5.2d A dynamic watermarking scheme (Ahmed Musa)          catoptions.sty    2012/11/22 v0.2.7f Securing catcodes and parsing options (AM)            fix-cm.sty    2006/09/13 v1.1m fixes to LaTeX       ts1enc.def    2001/06/05 v3.0e (jk/car/fm) Standard LaTeX file      picture.sty    2009/10/11 v1.3 Dimens for picture macros (HO)     graphicx.sty    1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)       keyval.sty    1999/03/16 v1.13 key=value parser (DPC)     graphics.sty    2009/02/05 v1.0o Standard LaTeX Graphics (DPC,SPQR)         trig.sty    1999/03/16 v1.09 sin cos tan (DPC)     graphics.cfg    2010/04/23 v1.9 graphics configuration of TeX Live       pdftex.def    2011/05/27 v0.06d Graphics/color for pdfTeX     infwarerr.sty    2010/04/08 v1.3 Providing info/warning/error messages (HO)      ltxcmds.sty    2011/11/09 v1.22 LaTeX kernel commands for general use (HO)     atbegshi.sty    2011/10/05 v1.16 At begin shipout hook (HO)        ifpdf.sty    2011/01/30 v2.3 Provides the ifpdf switch (HO)     fancyhdr.sty         atveryend.sty    2011/06/30 v1.8 Hooks at the very end of document (HO)      ltxkeys.sty    2012/11/17 v0.0.3c A robust key-value parser (AM) (Ahmed Musa)       framed.sty    2011/10/22 v 0.96: framed or shaded text with page breaks         Test.xwm     hyperref.sty    2012/11/06 v6.83m Hypertext links for LaTeX     hobsub-hyperref.sty    2012/05/28 v1.13 Bundle oberdiek, subset hyperref (HO)     hobsub-generic.sty    2012/05/28 v1.13 Bundle oberdiek, subset generic (HO)       hobsub.sty    2012/05/28 v1.13 Construct package bundles (HO)     ifluatex.sty    2010/03/01 v1.3 Provides the ifluatex switch (HO)       ifvtex.sty    2010/03/01 v1.5 Detect VTeX and its facilities (HO)      intcalc.sty    2007/09/27 v1.1 Expandable calculations with integers (HO)     etexcmds.sty    2011/02/16 v1.5 Avoid name clashes with e-TeX commands (HO)     kvsetkeys.sty    2012/04/25 v1.16 Key value parser (HO)     kvdefinekeys.sty    2011/04/07 v1.3 Define keys (HO)     pdftexcmds.sty    2011/11/29 v0.20 Utility functions of pdfTeX for LuaTeX (HO)     pdfescape.sty    2011/11/25 v1.13 Implements pdfTeX's escape features (HO)     bigintcalc.sty    2012/04/08 v1.3 Expandable calculations on big integers (HO)       bitset.sty    2011/01/30 v1.1 Handle bit-vector datatype (HO)     uniquecounter.sty    2011/01/30 v1.2 Provide unlimited unique counter (HO)     letltxmacro.sty    2010/09/02 v1.4 Let assignment for LaTeX macros (HO)      hopatch.sty    2012/05/28 v1.2 Wrapper for package hooks (HO)     xcolor-patch.sty    2011/01/30 xcolor patch     refcount.sty    2011/10/16 v3.4 Data extraction from label references (HO)      hycolor.sty    2011/01/30 v1.7 Color options for hyperref/bookmark (HO)      ifxetex.sty    2010/09/12 v0.6 Provides ifxetex conditional      auxhook.sty    2011/03/04 v1.3 Hooks for auxiliary files (HO)     kvoptions.sty    2011/06/30 v3.11 Key value format for package options (HO)       pd1enc.def    2012/11/06 v6.83m Hyperref: PDFDocEncoding definition (HO)     hyperref.cfg    2002/06/06 v1.2 hyperref configuration of TeXLive          url.sty    2013/09/16  ver 3.4  Verb mode for urls, etc.      hpdftex.def    2012/11/06 v6.83m Hyperref driver for pdfTeX     rerunfilecheck.sty    2011/04/15 v1.7 Rerun checks for auxiliary files (HO)     supp-pdf.mkii     epstopdf-base.sty    2010/02/09 v2.5 Base part for package epstopdf       grfext.sty    2010/08/19 v1.1 Manage graphics extensions (HO)     epstopdf-sys.cfg    2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live      nameref.sty    2012/10/27 v2.43 Cross-referencing by name of section     gettitlestring.sty    2010/12/03 v1.4 Cleanup title references (HO)


title: Can I draw horizontal braces to annotate parts of sentences?

text: I need to explain the structure of a URL. I would like to do this with braces. To produce the following               http://www.example.com/page.html?foo=bar&bar=foo     --v---|-------v-------|----v----|-v-|-v-|-v-|-v-|     service     address      page    parameter      the ---v--- are to represent the braces. I tried to do this by guessing the coordinates where to start, but already fail when I need to graphically draw the brace. I didn't even get to position the braces accordingly. Is there an easy way to achieve this, without punctional positioning of the brace?


title: How do I draw horizontal and vertical lines for a TikZ matrix

text: I want to use a TikZ matrix to draw a table with empty cells. But no matter what I do I run into errors. In particular, LaTeX complains about               ! Package pgf Error: No shape named ae-5-4 is known.      Here's the code (far from what I really want):               \documentclass{article}     \usepackage[margin=0.5in]{geometry}     \usepackage{tikz}     \usetikzlibrary{calc}     \usetikzlibrary{matrix}     \usetikzlibrary{decorations.pathreplacing}     \begin{document}          \begin{tikzpicture}[         %%---------------------------------------         dm/.style={decoration={brace,mirror},decorate},         dd/.style={decoration={brace},decorate},         %%---------------------------------------         nlble/.style={inner sep=0pt,anchor=east},         nlblw/.style={inner sep=0pt,anchor=west},         %%---------------------------------------       ]       \matrix (ae) [matrix of nodes,                     column 1/.style={anchor=west},                     minimum width=2cm,                     column sep=2.5ex,                     row sep=2.5ex,                     matrix of nodes/.style={execute at empty cell=\node {AAA};}                     ]       {             & column A & column B & column C & g                 \\       Row A &          &          &          & a \node (cc)  {}; \\       Row B &          &          &          &   \node (ss)  {}; \\       Row C &          &          &          &   \node (alt) {}; \\       Row D &          &          &          &                   \\       };       \foreach \row in {1,2,3,4,5} {%         \draw[blue,line width=0.4pt] ($(ae-\row-2.base west)-(0,2ex)$) -- ($(ae-\row-4.base east)-(0,2ex)$);        }     %  \foreach \col in {1,2,3,4}{%     %    \draw[blue,line width=0.4pt] ($(ae-1-\col.base east)-(0,2ex)$) -- ($(ae-4-\col.base east)-(0,2ex)$);     %  }       \draw[dm]  ($(ae-2-1.west)+(0,2.5ex)$) -- ($(ae-3-1.west)-(0,2.5ex)$) node [midway,anchor=east] (A) {};       \draw[dm]  ($(ae-4-1.west)+(0,2.5ex)$) -- ($(ae-4-1.west)-(0,2.5ex)$) node [midway,anchor=east] (B) {};       \draw[dd]  ($(cc.east)+(0,2.5ex)$)     -- ($(cc.east)+(0,-2.5ex)$)    node [midway,anchor=west] (C) {};       \draw[dd]  ($(ss.east)+(0,2.5ex)$)     -- ($(alt.east)+(0,-2.5ex)$)   node [midway,anchor=west] (D) {};            \node[nlble] at ($(A)+(-1ex,0)$) {\parbox{1.35in}{\footnotesize\centering Instructions for material to be put in Rows A and B.}};       \node[nlble] at ($(B)+(-1ex,0)$) {\parbox{1.35in}{\footnotesize\centering Instructions for material to be put in Row C.}};       \node[nlblw] at ($(C)+(1ex,0)$)  {\parbox{1.5in}{\footnotesize\centering Additional instructions for Row A.}};           \node[nlblw] at ($(D)+(1ex,0)$)  {\parbox{1.5in}{\footnotesize\centering Additional instructions for Rows B and C.}};         \end{tikzpicture}          \end{document}      What I'm most interested in knowing is how to automate drawing horizontal and vertical lines. I'd prefer to do it using the node names that TikZ creates for the cells of a matrix. Of secondary interest,   * I would like to know why when I try to add text before the `\node {cc};` in the last column of `Row A`, I get an `undefined command` error from LaTeX.   * I would also like to know whether there's a way to define the style for a range of columns (such as columns 2, 3, and 4) without having to declare the style for each individual column or define a style universally for all columns. For example, I only want to set the `minimum width` for columns 1, 2, and 3.


title: Questions about using package `qasm2circ`

text: The package qasm2circ can be find here, which is a package to draw quantum circuit. I download it and follow the file `Installation instructions`. My OS is Ubuntu. I have the following problems:   1. When I run the command `qasm2png` in the terminal in the folder `qasm2circ-v1.4`, it outputs that`qasm2png: command not found`.    2. The tex file in the folder `samples` can only be compiled from terminal with command `xelatex` but not editor. How strange! My editor is gedit with gedit-latex plugin and the configuration is ![](http://t.imget.com/OriginalPicture/Soloman/geditlatexplugin.png) PS：I tried to add path but failed ![](http://t.imget.com/OriginalPicture/Soloman/ubuntuquestionqasm.png)


title: Customized bonus questions in exam class

text: I'm using the `exam` class (with the `addpoints` option) to create assignments, and I want to create some bonus questions. I have a customized question format that looks like this:               \qformat{Question \thequestion: [\totalpoints]}      which works fine for regular questions. However, the \totalpoints command doesn't return a value for bonus questions, and so those questions are incorrectly marked as having 0 points. I hacked this by redefining \qformat (before the bonus questions) to be               \qformat{Question \thequestion: [\totalbonuspoints]}      which works fine. But I'd rather have a single designation that works for all question (bonus or not). How might I do that ? note: I could have used \thepoints in the definition, but some of my questions have parts, and so \totalpoints is needed to add up the points.


title: tree-dvips Alternative for Linguistics Document with pdftex

text: I'm attempting to find a way of linking two objects in avm.sty together. The result I want is exactly that specified here: http://www.essex.ac.uk/linguistics/external/clmt/latex4ling/avms/#4 I'm using pdftex so tree-dvips does not work. How can the same effect be achieved in pdftex? I assume it could be done with tikz, but I cannot for the life of me work out how. Sample code is here:               \begin{avm}     \[{} PRED `avoid <SUBJ, OBJ>'; TNS $\neq$ PAST \\          TOPIC \[ PRED `kind<COMP>' \\                         DEF +; LOC FAR; NUM SG \\                         COMP \[ PRED `of <OBJ>' \\                                 OBJ \[ PRED `cake'\] \] \] \\          SUBJ \[ PRED `pro'; NUM SG; PERS 1; CASE NOM\] \\          OBJ \[ $\qquad$ \] \\          ADJ \[ PRED `usually'\] \]     \end{avm}      A tree-dvips implementation would be as follows:               \begin{avm}     \[{} PRED `avoid <SUBJ, OBJ>'; TNS $\neq$ PAST \\          \node{topic}{TOPIC \[ PRED `kind<COMP>' \\                         DEF +; LOC FAR; NUM SG \\                         COMP \[ PRED `of <OBJ>' \\                                 OBJ \[ PRED `cake'\] \] \]} \\          SUBJ \[ PRED `pro'; NUM SG; PERS 1; CASE NOM\] \\          \node{object}{OBJ \[ $\qquad$ \]} \\          ADJ \[ PRED `usually'\] \]     \end{avm}     \nodecurve[r]{topic}[r]{object}{2in}      The best I've been able to come up with using tikz is:               \begin{avm}     \[{} PRED `avoid <SUBJ, OBJ>'; TNS $\neq$ PAST \\          \tikz \node (topic) {TOPIC \[ PRED `kind<COMP>' \\                         DEF +; LOC FAR; NUM SG \\                         COMP \[ PRED `of <OBJ>' \\                                 OBJ \[ PRED `cake'\] \] \]}; \\          SUBJ \[ PRED `pro'; NUM SG; PERS 1; CASE NOM\] \\          \tikz \node (object) {OBJ \[ $\qquad$ \]}; \\          ADJ \[ PRED `usually'\] \] \tikz \node (viapoint) {};     \end{avm}          \tikz[overlay] \draw[-] (topic) to[out=0,in=90  ] (viapoint)                             (viapoint) to[out=270,in=0] (object);      However this results in two disconnected lines, one of which goes through other text. Any help on improvement would be greatly appreciated.


title: moderncv \cvitemwithcomment without bold font for the second argument

text: Is it possible to use the `\cvitemwithcomment` without bold font for the second argument ? MWE:               % compile with LuaLaTeX          \documentclass[11pt,a4paper,sans]{moderncv}      \moderncvstyle{classic}      \moderncvcolor{blue}           \usepackage[ngerman]{babel}                               \firstname{John}     \familyname{Doe}          \begin{document}          \cvitemwithcomment{German}{Native}{Mother Tongue}     \cvitemwithcomment{Frensh}{Native}{Mother Tongue}          \end{document}      ![enter image description here](http://i.stack.imgur.com/pdCwz.png)


title: Mac - styles apparently not installed, yet working

text: New to LaTeX, running Mountain Lion on Mac. I have seen plenty of posts which all suggest that to use packages, they should be included in the ~/Library/texmf/tex/latex/ folder, such as on this question: Installing new style packages on a Mac However, I have been using various packages and they've been working fine, such as natbib and the apalike style, even though I didn't have a texmf folder until just a moment ago when I created it. My bibliography was working, but as far as I can tell, I didn't have the apalike style on my Mac anywhere (including hidden files), so it shouldn't have been? Firstly, how can LaTeX use natbib's apalike style if, apparently, it's not on my Mac? Secondly, how can I go about locating, and editing, whichever apalike style I'm actually using? I'm struggling a little with some of the logic around LaTeX, like its use of a style file which is apparently not on my Mac. Edit: The reason this is bugging me is because I'd actually like to edit the apalike style, but all of the instructional guides I can find talk about editing the existing file (which also makes more sense than a newbie like me trying to write it from scratch).


title: Color leak from multicols within a figure

text: ![colorleak page one](http://i.stack.imgur.com/ptJtP.png) ![colorleak page two](http://i.stack.imgur.com/I4fxO.png) The text at the bottom of page 2 is red, despite the fact that the color change in the code below originates from `\color{red}\normalcolor` within the `multicols` within the `figure` and should naively not have had such an impact. No effect is seen if either:   1. one comments out the `\begin{multicols}` and `\end{multicols}` lines,   2. one comments out the `\begin{figure*}` and `\end{figure*}` lines. My question is why does this happen? (I expect to hear about some kind of `whatsit` subtlety). and is there a work-around ? (in my context I have `\color{red}` and later `\normalcolor` before the text, more or less as here, and I can not change that, so the solution should not change anything to the inside of the `multicols` and the only customizing possibility would be to add extra stuff either before or after the multicols environment or both). **Update** David's proposal to add a group or brace pair inside the `multicols` cures the problem (I initially thought I had no access to these contents, but I had forgotten my own hooks) and another way is to add `\normalcolor` or even `\color{green}` (sic) inside the `figure*` environment _before_ the `multicols` environment. This second medicine avoids to have to insert anything inside the `multicols`.               \documentclass{article}     \usepackage[paperheight=6cm]{geometry}     \usepackage{multicol}     \usepackage{color}     % COLOR LEAK IF COLOR WITHIN MULTICOLS WITHIN FIGURE     \begin{document}     Hello World World World World World World World     World World World World World World World     World World World World World World World     World World World World World World World     World World     World World World      World World World World World World World     World World World World World World World     World World World World World World World     World World World World World World World     World World     \begin{figure*}[ht!]       \begin{multicols}{2}         \color{red}\normalcolor         Hello. World World World         World World World World World World         World World World World World World         World World World World World World         World World World World World World         World World World World World World         World World World World         World World World World World World         World World World World World World         World World World World World World         World World World World World World         World World World World World\par       \end{multicols}     \end{figure*}     World World World      World World World World World World World     World World World World World World World     World World World World World World World     World World World World World World World     World World     World World World      World World World World World World World     World World World World World World World     World World World World World World World     World World World World World World World     World World     World World World      World World World World World World World     World World World World World World World     World World World World World World World     World World World World World World World     World I AM RED, WHY?          \end{document}


title: Font-awesome disturbing commands of moderncv

text: The usage of `\moderncvicons{awesome}` lowers the item symboles (blue circle) of `\cvlistdoubleitem` and `\cvlistitem`. How can they be raised to normal level again? MWE:               % compile with LuaLaTeX          \documentclass[11pt,a4paper,sans]{moderncv}      \moderncvstyle{classic}      \moderncvcolor{blue}           \usepackage[ngerman]{babel}                          \moderncvicons{awesome}          \firstname{John}     \familyname{Doe}          \begin{document}          \cvlistdoubleitem{Ultimate Frisbee}{Climbing}     \cvlistitem{Travelling in Europe, Asia and North America}          \end{document}      ![enter image description here](http://i.stack.imgur.com/z8YH9.png)


title: How to put a symbol always in the right margin, even in twoside mode, like line numbers of lineno?

text: I discovered the package lineno which in twoside mode of the class article can force to put the line numbers on the right. I really like that because I want me QED symbol to do the same. Currently, mine is inside the page and lies a line below the last word of my paragraph but it is not so great when the paragraph finishes by a math formula finishing a page;sometimes the QED symbol is on a new page. I don't want the QED to be on the same line as my text unless it is actually in the margin outside the page and **actually as close to the text as the numbers are from the package.** Anyway, even in general, it can be useful to get that. But I do not understand the logic of the package well enough to see what is going on. LIneno pdf is here http://texdoc.net/texmf-dist/doc/latex/lineno/ulineno.pdf but the new version is on CTAN which is down presently. and on page 10 bottom it says one can customize the command \makeLineNumber creating the line number               \begin{runninglinenumbers}     i     \renewcommand\makeLineNumber     ii     {\hss$\rightarrow$\ \rlap{\hskip\textwidth\ $\leftarrow$}}     iii     \end{runninglinenumbers}      On page 12 of http://www.putlocker.com/file/5FC5CB241A3E947F [the new version]               \def\MakeLineNo{%     56 \@LN@maybe@normalLineNumber % v4.31     57 \boxmaxdepth\maxdimen\setbox\z@\vbox{\unvbox\@cclv}%     58 \@tempdima\dp\z@ \unvbox\z@     59 \sbox\@tempboxa{\hb@xt@\z@{\makeLineNumber}}%      But I do not see the mechanism of forcing something on the right very close to the text....


title: Problem using \begin{titlepage}

text: I want to make a front-page to something I've been writing in LyX but everytime I use `\begin{titlepage}\text {This is a sample title}\end{titlepage}`, I get in the first page this line only instead of real title: ![enter image description here](http://i.stack.imgur.com/YJfOW.png) How can I solve it?


title: Wrap word in table cell

text: I have such table:               \begin{tabularx}{\textwidth}{ |p{0.5cm}|X|p{1cm}|p{0.8cm}|p{1.1cm}|p{0.9cm}|p{0.9cm}|p{1.2cm}|p{0.9cm}|p{0.9cm}|p{1.5cm}| }                                                                                \hline                                                                                No. & Compound & Storage place & Shelf & Number & Calc mol & Cacl wt & Calc amount & Real mol & Real wt & Real amount \\                                                                                \hline                                                                                1 & lasdsdasdasdasdasddasdllasfsdjfsd & Lab1 & 2 & 355235 & 85.000 & 92.006 & 1.33620 & 85.000 & 92.006 & 1.33620 g \\                                                                                \hline                                                                                \end{tabularx}      How to wrap long word in second column? I would like to have table where text never ever overflow. What I have now is: ![enter image description here](http://i.stack.imgur.com/Vq55M.png) What I would like to have: ![enter image description here](http://i.stack.imgur.com/69Yl6.png) Note: I'm using xelatex as compiler, I dont know if it makes difference.


title: How to select a default frame for `\animategraphics` when the viewer doesn't support animation?

text: I made a beamer with some animations. Here is a sample of my code:               \usepackage{animate}     \begin{document}     \begin{figure}[!ht]         \centering         \animategraphics[autoplay,loop,width=\textwidth]{2}{../figures/sim_scan/res_scan_sim_}{0}{50}         \caption{Simulation of the \textit{ScanSAR} mode}         \label{res_scan_animation}     \end{figure}     \end{document}      I want to know, is there is a way to **select which frame is displayed** when the pdf **viewer doesn't support animations** or when it is printed?


title: backref for tables and figures

text: How to automatically locate the place referring to the table or figure when clicking the caption of table or figure, that is, backref for the table or figure. I know how to achieve this similar function for references using hyperref package. Any advice will be appreciated.


title: How can I use brackets for serial numbers like 1, 2, 3

text: I want to write the reference numbers like the following in MS WORD. How can I write in such a manner? > [1] Brattin WJ, Glenda EA. 1 Free Radical Biol Med 1985;1:27. > > [2] Osawa T, Kavakishi S, Namiki M. In: Kuroda Y, Shankal DM, Waters MD, > editors. > > [3] Subramoniam A, Evans DA, Kajasekharan S, Pushpangadan P. Indian J Exp > Biol 1998;3h:385. > > [4] Lakshmi M, Rajalaksbmi S, Parani M, Anuratha CS, Ajay parida A. > Theoretical Appl Genetics


title: How to use arrow instead of underbrace?

text: In the following example instead of `\underbrace`, I want to use something like `\text bar\leftarrow j+1\rightarrow\textbar`. `(p_{1},p_{2}\ldots,p_{m-j},\underbrace{m,m,\dots,m}_{j+1})` Is there any similar command?


title: Multiline Inferences / Rules / Axioms in Bussproofs

text: I have a proof that I need to set in LaTeX, and to do so I am using the `bussproofs` package. However my proof has large amounts of free text in it, which makes the proof overly wide. Is there a way to use multi-line inferences? neither `\\` nor `\newline` seem to do the trick. MWE:               \documentclass{standalone}     \usepackage{bussproofs}     \begin{document}         \AxiomC{Very long piece of text}                 \AxiomC{Even longer piece of text}             \LeftLabel{Absurdly long rule name}             \BinaryInfC{Another piece of excessively wordy text}         \DisplayProof     \end{document}      ![A very wide rule](http://i.stack.imgur.com/1Nv7c.png) N.B. I am not using any `math` environments so using `align` or `gather` is not appropriate.


title: Citations with same first author and date with apa style: no letter generated

text: I use the package `biblatex` with `biber` to generate my bibliography. I have some references with the same first author and the same year but no letter is inserted to make the distinction possible. I saw the same problem here with biblatex-chicago. Here is my code:               \documentclass[american]{book}          \usepackage[utf8]{inputenc}     \usepackage[autostyle]{csquotes}     \usepackage[american]{babel}          \usepackage[backend=biber,     uniquename=false,     uniquelist=false,     style=apa,     doi=false,     isbn=false,     url=false,     maxcitenames=3,     uniquelist=false,     natbib]{biblatex}              %%Bibliography format     \addbibresource{test.bib}     \DeclareLanguageMapping{american}{american-apa}     \AtEveryBibitem{\clearfield{labelmonth}}     \AtEveryBibitem{\clearfield{note}}     \DefineBibliographyStrings{american}{bibliography = {Bibliographie}, references = {Références},}          \begin{document}          An example of citation: the first time, all authors \parencite{Saffran1996}, \parencite{Saffran1996a}.          After the first time, citations are simplified \parencite{Saffran1996}, \parencite{Saffran1996a}.          But no letter are inserted to distinguish the citations...          \printbibliography     \end{document}      with this test.bib file :               % This file was created with JabRef 2.10.     % Encoding: ISO8859_1               @Article{Saffran1996a,       Title                    = {Statistical Learning by 8-Month-Old Infants},       Author                   = {Saffran, Jenny R. and Aslin, Richard N. and Newport, Elissa L.},       Year                     = {1996},       Doi                      = {10.1126/science.274.5294.1926},       ISSN                     = {0036-8075, 1095-9203},       Language                 = {en},       Month                    = dec,       Note                     = {{PMID:} 8943209},       Number                   = {5294},       Pages                    = {1926--1928},       Url                      = {http://www.sciencemag.org/content/274/5294/1926},       Urldate                  = {2014-01-19},       Volume                   = {274},            Abstract                 = {Learners rely on a combination of experience-independent and experience-dependent mechanisms to extract information from the environment. Language acquisition involves both types of mechanisms, but most theorists emphasize the relative importance of experience-independent mechanisms. The present study shows that a fundamental task of language acquisition, segmentation of words from fluent speech, can be accomplished by 8-month-old infants based solely on the statistical relationships between neighboring speech sounds. Moreover, this word segmentation was based on statistical learning from only 2 minutes of exposure, suggesting that infants have access to a powerful mechanism for the computation of statistical properties of the language input.},       File                     = {Saffran, Aslin & Newport (1996) Statistical Learning by 8-Month-Old Infants.pdf:/Users/Croche_8/Library/Application Support/Zotero/Profiles/bmql718o.default/zotero/storage/87H7TDZF/Saffran, Aslin & Newport (1996) Statistical Learning by 8-Month-Old Infants.pdf:application/pdf;Snapshot:/Users/Croche_8/Library/Application Support/Zotero/Profiles/bmql718o.default/zotero/storage/7X7QIAE7/1926.html:text/html},       Journal                  = {Science},       Owner                    = {Croche_8},       Timestamp                = {2014.03.27}     }               @Article{Saffran1996,       Title                    = {Word Segmentation: The Role of Distributional Cues},       Author                   = {Saffran, Jenny R. and Newport, Elissa L. and Aslin, Richard N.},       Year                     = {1996},       Doi                      = {10.1006/jmla.1996.0032},       ISSN                     = {0749-{596X}},       Month                    = aug,       Number                   = {4},       Pages                    = {606--621},       Url                      = {http://www.sciencedirect.com/science/article/pii/S0749596X96900327},       Urldate                  = {2014-03-18},       Volume                   = {35},            Abstract                 = {One of the infant's first tasks in language acquisition is to discover the words embedded in a mostly continuous speech stream. This learning problem might be solved by using distributional cues to word boundaries—for example, by computing the transitional probabilities between sounds in the language input and using the relative strengths of these probabilities to hypothesize word boundaries. The learner might be further aided by language-specific prosodic cues correlated with word boundaries. As a first step in testing these hypotheses, we briefly exposed adults to an artificial language in which the only cues available for word segmentation were the transitional probabilities between syllables. Subjects were able to learn the words of this language. Furthermore, the addition of certain prosodic cues served to enhance performance. These results suggest that distributional cues may play an important role in the initial word segmentation of language learners.},       File                     = {ScienceDirect Full Text PDF:/Users/Croche_8/Library/Application Support/Zotero/Profiles/bmql718o.default/zotero/storage/3WG62WGP/Saffran et al. - 1996 - Word Segmentation The Role of Distributional Cues.pdf:application/pdf;ScienceDirect Snapshot:/Users/Croche_8/Library/Application Support/Zotero/Profiles/bmql718o.default/zotero/storage/FRRTV6HA/S0749596X96900327.html:text/html},       Journal                  = {Journal of Memory and Language},       Owner                    = {Croche_8},       Shorttitle               = {Word Segmentation},       Timestamp                = {2014.03.27}     }      which gives the following result: ![enter image description here](http://i.stack.imgur.com/fFLWG.png) **Question:** How could I generate letters to distinguish the citations with the same first author/date ?


title: including chapters in mdframed references

text: I'd like to have chapter.theorem numbers for an `mdframed` theorem environment. I can modify the environment definition to include this, as in:               \documentclass{memoir}          \usepackage{amsmath}     \usepackage[english]{cleveref}     \usepackage[svgnames]{xcolor}     \usepackage[framemethod=tikz]{mdframed}          \newcounter{Theorem}[chapter]     \newenvironment{Theorem}[1][]{%       \refstepcounter{Theorem}%       \ifstrempty{#1}%       {\mdfsetup{%         frametitle={%           \tikz[baseline=(current bounding box.east),outer sep=0pt]           \node[line width=1pt,anchor=east,rectangle,draw=DarkOliveGreen,fill=white]         {\strut \color{DarkOliveGreen}{Theorem}~\thechapter.\theTheorem};}}       }%       {\mdfsetup{%         frametitle={%           \tikz[baseline=(current bounding box.east),outer sep=0pt]           \node[line width=1pt,anchor=east,rectangle,draw=DarkOliveGreen,fill=white]         {\strut \color{DarkOliveGreen}{Theorem}~\thechapter.\theTheorem:~\color{Maroon}{#1}};}}%       }%       \mdfsetup{innertopmargin=10pt,linecolor=DarkOliveGreen,%                 linewidth=1pt,topline=true,%                 frametitleaboveskip=\dimexpr-\ht\strutbox\relax,}       \begin{mdframed}[]\relax%       }{\end{mdframed}}          \crefname{Theorem}{theorem}{theorems}      \Crefname{Theorem}{Theorem}{Theorems}           \begin{document}          \chapter{blah}          \begin{Theorem}[Distribution of inner products]\label{thm:stokesTheoremGeometricAlgebraII:1420}     Given two blades $A_s, B_r$ with grades subject to $0 < r < s$, and a vector $b$, the inner product distributes according to     \begin{equation*}         A_s \cdot \left( b \wedge B_r \right) = \left( A_s \cdot b \right) \cdot B_r.     \end{equation*}     \end{Theorem}          Reference to \cref{thm:stokesTheoremGeometricAlgebraII:1420}.          \end{document}      To get cleveref to find the label, this was modified to use `refstepcounter` instead of `stepcounter` as shown in cleveref-doesnt-find-the-label. This produces: ![cref to fix](http://i.stack.imgur.com/ZNDYA.png) How can I modify things so that the cref output shows up as 'theorem 1.1' (i.e. including the chapter number as in the theorem title text)?


title: Missing mathtools.sty

text: I'm really new to LaTeX and am having a problem with `mathtools.sty`. I am using MikTeX and Texmaker. When I try to create the pdf (compile?) it gives me the error: > ! LaTeX Error: File `mathtools.sty' not found.Type X to quit or to > proceed,or enter new name. (Default extension: sty)Enter file name:! > Emergency stop. \usepackage I looked this problem up on Google, and found a thread on this place. It said to open the Package Manager and download it there. I opened the Package manager, downloaded `mathtools` from it by pressing the "+". After doing this it still comes up with the same error, that `mathtools.sty` is missing. I have tried reinstalling everything and still nothing works. I really hope you can help and explain in a simple manner, so that even I can understand :)


title: Scaling of landscape figures (images)

text: I'm trying to insert a landscape figure, which I want to scale down. I'm currently using:               \begin{figure*}[tb]      \centering     \includegraphics[width=\textwidth,height=\textheight,keepaspectratio]{fig/proposed.pdf}%     \caption{The SAP data model based on an UML class diagram: classes and relationships.}     \label{fig:Fig5}     \end{figure*}      This creates the figure and includes the graphic, however, the image is really big and goes out of bounds in the document.


title: collision with fonts in EPS graphics

text: I am using `\Pisymbol` from the pifont package to make item markers for lists, as shown below. Here I use the bullet from the Symbol font (psy):               \documentclass[12pt, a4paper]{article}     \usepackage{epsfig, pifont}     \usepackage[german, english]{babel}          \begin{document}     \selectlanguage{german}     \sffamily\mdseries\upshape\normalsize     \begin{figure}[b!]     \begin{center}     \epsfig{file=diagram.eps,height=11.0cm}     \end{center}     \end{figure}          \begin{list}{\Pisymbol{psy}{183}}{     \setlength{\leftmargin}{0pt}\addtolength{\leftmargin}{20pt}}     \item x     \item y     \end{list}     \end{document}      This works nicely, except that in the included diagram characters printed with the Symbol font are lost. There is no error message, neither from LaTeX nor from the PostScript viewer. Here is the file `diagram.eps`:               %!PS-Adobe-2.0 EPSF-2.0     %%Title: Cartesian diagram     %%Creator: Grafix-3.0 by ukd     %%BoundingBox:  85 85 510 510     %%Pages: 1     %%DocumentFonts: Symbol Helvetica Helvetica-Oblique     %%+ Helvetica-Bold Helvetica-BoldOblique     %%+ Courier Courier-Oblique     %%+ Courier-Bold Courier-BoldOblique     %%+ Times-Bold Times-BoldItalic Times-Roman Times-Italic     %%EndComments     %!          % BEGIN PREAMBLE (definitions of macros, fonts, etc.)     /mm {2.83465 mul} def     /cm {28.3465 mul} def     /mm {72 mul} def     /ru {425 mul} def     /xu {0 sub 25 div 0.1 add 425 mul} def     /yu {0 sub 50 div 0.1 add 425 mul} def     %!          % some abbreviations     /l { lineto } def     /m { moveto } def     /L { rlineto } def     /M { rmoveto } def          % END PREAMBLE     85 85 translate          gsave       0.000000 0.000000 0.000000 setrgbcolor       0.5 ru 0.02 ru translate 0 0 m       /MixedText       { /final exch def         /Times-Roman findfont 16 scalefont setfont         () final { show } { false charpath } ifelse     /Symbol findfont 16 scalefont setfont     (D) final { show } { false charpath } ifelse     /Times-Roman findfont 16 scalefont setfont     () final { show } { false charpath } ifelse     0 -5.600000 M     /Times-Roman findfont 11 scalefont setfont     (vap) final { show } { false charpath } ifelse     currentpoint m 0 5.600000 M     /Times-Roman findfont 16 scalefont setfont     () final { show } { false charpath } ifelse     /Times-Italic findfont 16 scalefont setfont     (H) final { show } { false charpath } ifelse     /Times-Roman findfont 16 scalefont setfont     () final { show } { false charpath } ifelse     0 -5.600000 M     /Times-Roman findfont 11 scalefont setfont     (m) final { show } { false charpath } ifelse     currentpoint m 0 5.600000 M     /Times-Roman findfont 16 scalefont setfont     (/\050) final { show } { false charpath } ifelse     /Times-Italic findfont 16 scalefont setfont     (RT) final { show } { false charpath } ifelse     /Times-Roman findfont 16 scalefont setfont     (\051) final { show } { false charpath } ifelse       } def       false MixedText       flattenpath pathbbox       exch 4 -1 roll sub -0.5 mul     3 1 roll   pop pop 0 0 0 m M true MixedText     grestore               showpage     %%Trailer     %%Pages: 1     %%EndTrailer      In the final output, the Delta symbol in the diagram is missing in the PostScript file (generated with dvips), at least on my computer (openSUSE 13.1, standard TeXLive installation). The DVI file looks OK. The problem may not limited to the pifont package. I see it also when I include an EPS diagram with `\special{}` as a background graphic. The problem did not occur two or three years ago. What has changed? And how can I get `\Pisymbol` (or dvips?) to work correctly again?


title: Scrolling with TexShop

text: I just udpated to TexShop 3.41 (and Maverick). When I scroll on the pdf file I get stuck at the end/begin of every page : I can only scroll within one page but not go from page to page. Any idea how to fix it ? Many thanks.


title: Undefined control sequence \subfloat

text: This is odd, my code was working just fine, then I literally just step out of the room and when I come back and compile I get the error undefined control sequence \subfloat. Basically I am trying to arrange 3 images, cc.png, bb.png and tt.png in a document side by side rather than in a column as latex was trying to make it. This is the relevant section of my code:               \documentclass{article}     \usepackage[top=0.5in]{geometry}     \usepackage{fullpage}     \usepackage{graphicx}     \usepackage{auto-pst-pdf}     \usepackage{epstopdf}     \usepackage{float}     \usepackage{subfloat}     \usepackage{caption}     \usepackage{axodraw4j}     \usepackage{pstricks}     \usepackage{color}          \DeclareMathSizes{10}{12}{10}{6}               \begin{document}           \title{Higgs Boson Deacay}      \author{name}      \maketitle                    \begin{figure}[h!t]             \centering             \subfloat{\includegraphics[scale=0.7]{cc}}             \subfloat{\includegraphics[scale=0.7]{bb}}             \subfloat{\includegraphics[scale=0.7]{tt}}         \end{figure}          \end{document}      My output was fine and I'm sure I didn't change anything (although I concede I must have done otherwise there would be no problem) but this code now keeps giving me the error I have stated. I've looked at this for so long that the problem is probably staring me in the face but I can't see it. Any help would be greatly appreciated.


title: why is this equation not left aligned?

text: I wonder why all the multilines of the equation are not left aligned? I tried to use align instead but the equation got too long and I could not manage to break it.                \documentclass[11pt,a4paper,oneside]{report}       \usepackage[T1]{fontenc}      \usepackage{fouriernc}      \usepackage{mathtools}      \usepackage{amsthm}      \usepackage{amsfonts}      \usepackage{amssymb}      \begin{document}      \begin{eqnarray*}      N =&\frac{\theta _{1}-\theta _{2}}{f}\left( \left( \theta _{1}+\theta      _{2}+t\right) x-fy\right) \frac{\theta _{1}-\theta _{3}}{f}\left( \left(      \theta _{1}+\theta _{3}+t\right) x-fy\right) \frac{\theta _{2}-\theta _{3}}{f%      }\left( \left( \theta _{2}+\theta _{3}+t\right) x-fy\right)  \\     =&\frac{\left( \theta _{1}-\theta _{2}\right) \left( \theta _{1}-\theta     _{3}\right) \left( \theta _{2}-\theta _{3}\right) }{f^{3}}\left( \left(     \theta _{1}+\theta _{2}+t\right) x-fy\right) \left( \left( \theta     _{1}+\theta _{3}+t\right) x-fy\right) \left( \left( \theta _{2}+\theta     _{3}+t\right) x-fy\right)  \\     =&\frac{\sqrt{discr\left( \phi \right) }}{f^{3}}\left( \left( \theta     _{1}+\theta _{2}+t\right) x-fy\right) \left( \left( \theta _{1}+\theta     _{3}+t\right) x-fy\right) \left( \left( \theta _{2}+\theta _{3}+t\right)     x-fy\right) \\     =&\sqrt{discr\left( \phi \right) }\left( \frac{t^{3}-2pt^{2}+\left(     p^{2}+q\right) t+\left( r-qp\right) }{f^{3}}x^{3}-\frac{3t^{2}-4pt+\left(     p^{2}+q\right) }{f^{2}}x^{2}y+\frac{3t-2p}{f}xy^{2}-y^{3}\right)      \end{eqnarray*}      and the output ![enter image description here](http://i.stack.imgur.com/ICiBU.jpg) Thank you Using \begin{align*} the equation exceeds the margins ![enter image description here](http://i.stack.imgur.com/rGtnM.jpg)


title: \storeglosentry --> Undefined control sequence

text: I am trying to write a report for school in LaTeX. Therefore I am using MacTeX and Texshop and normally it works pretty fine. But at the moment I have some trouble with the `glossary` package:               \usepackage[style=long,border=plain,header=plain,cols=3,hyper=true]{glossary}     \makeglossary      when I use               \glossary{name={entry name},description={entry description}}      I get no errors and the glossary is printed right. But when I use               \storeglosentry{label}{{entry name},description={entry description}}          \useGlosentry{label}{Text}      I get the error > Undefined control sequence. Do you have any idea what is going wrong?


title: Artefacts in 3D-Plots when z-values exceed z-axis limits?

text: When plotting an expression using `pgfplots`, there are strange artefacts in places where the z-values are too big for the current axis. How do I fix it? Is there an equivalent to `y domain` for the z-axis?               \documentclass{article}          \usepackage{pgfplots}          \begin{document}       \begin{tikzpicture}       \begin{axis}[         xmin=-1.5,xmax=1.5,         ymin=-1.5,ymax=1.5,         zmin=0, zmax=1,         view={40}{20}]         \addplot3[domain=-1.5:1.5, y domain=-1.5:1.5,         surf,samples=40,opacity=0.3]         {1-x^2-y^2};       \end{axis}       \end{tikzpicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/Tx2iK.jpg)


title: Beamer long frame items not presented

text: I am using `beamer` and have a frame too long to fit in a single frame, so I use the option               \begin{frame}[allowframebreaks]      Because I want my list items to be exposed gradually, I am using               \beamerdefaultoverlayspecification{<+->}      before everything. However, this causes only my first item in the first frame to be exposed. The rest are just shaded, for some reason... How can I fix this? (have both long frames and gradual presentation)? Here is a MWE:               \documentclass{beamer}          \mode<presentation>     {       \usetheme{Warsaw}       \setbeamercovered{transparent}     }          \usepackage[english]{babel}     \usepackage[latin1]{inputenc}     \usepackage{times}     \usepackage[T1]{fontenc}     \title[]{Hello World}          \AtBeginSubsection[]     {       \begin{frame}<beamer>{Outline}         \tableofcontents[currentsection,currentsubsection]       \end{frame}     }          \beamerdefaultoverlayspecification{<+->}          \begin{document}          \begin{frame}[allowframebreaks]{Hello}         This is a very long frame:         \begin{itemize}             \item              line\\ line\\ line\\ line\\ line\\ line\\ line\\ line\\ line\\ line\\              \item              line\\ line\\ line\\ line\\ line\\ line\\ line\\ line\\ line\\ line\\              \item              line\\ line\\ line\\ line\\ line\\ line\\ line\\ line\\ line\\ line\\          \end{itemize}     \end{frame}          \end{document}


title: Reach another folder with \input

text: How do I reach a file in another folder when using `\input`? E.g. I have my main document `frontpage.tex` in a folder called `main` and a file `chapter1.tex` in a folder `chapters`. How do I in `frontpage.tex` reach the `chapter1.tex` with a command like the following, which I can't get working:               \input{..\chapters\chapter1}