title: Author-year format for citations in a revtex document

text: I'm new to bibliographies in LaTeX and I want to be able to use the style as in this report. Basically `Rawle et al. (2013)` with and without parentheses so:               (Rawle et al. 2013)     Rawle et al.     Rawle et al. (2013)      I'm currently using `revtex4` and a `bibtex` file but all that does is just put `[1]` as the citation! Here's the master tex file:               \documentclass[twocolumn]{revtex4}     \begin{document}        \title{S0 Galaxies}         \date{\today}        \author{S. Read}        \affiliation{Department of Physics}        %\begin{abstract}        %\end{abstract}        \maketitle        %\include{Introduction}             \cite{dressler_rotational_1983}        \bibliography{Zotero}        \bibliographystyle{plainnat}     \end{document}      Here is the citation in the bib file (everything else in the bib file is just more citations):               @article{dressler_rotational_1983,     title = {Rotational velocities and central velocity dispersions for a sample of S0 galaxies},     volume = {265},     issn = {0004-{637X}},     url = {http://adsabs.harvard.edu/abs/1983ApJ...265..664D},     doi = {10.1086/160712},     abstract = {Field S0 galaxies have bulges exhibiting high rotational velocities similar to those of spiral galaxies, as well as rapidly rotating disks. The Tully-Fisher ({TF)} diagram for field S0s show significant scatter, which indicates that these galaxies are a heterogeneous group in light of disk kinematics. Their spread in the {TF} diagram is larger than that of all Hubble-type spirals, prompting as explanations for such large variation a variation in mass/light ratio, the contamination of disk light by bulge light, and the accidental inclusion of systems lacking true disks whose kinetic energy derives from velocity dispersion rather than rotation. While some S0 galaxies seem to have no disks, their light profiles mimic the extended envelope distinguishing S0s from ellipticals, and they are rotationally flattened. These transition objects may be useful in increasing the present understanding of the formation of spheroidal stellar systems.},     urldate = {2013-10-28},     journal = {The Astrophysical Journal},     author = {Dressler, A. and Sandage, A.},     month = feb,     year = {1983},     keywords = {{ANGULAR} {VELOCITY}, {DISK} {GALAXIES}, {ELLIPTICAL} {GALAXIES}, {GALACTIC} {ROTATION}, {GALACTIC} {STRUCTURE}, {HUBBLE} {DIAGRAM}, {LUMINOSITY}, {SPIRAL} {GALAXIES}, {STELLAR} {SYSTEMS}, {VELOCITY} {DISTRIBUTION}},     pages = {664--680},     file = {NASA/ADS Full Text PDF:C:\Users\User\AppData\Roaming\Zotero\Zotero\Profiles\1lsc8c6m.default\zotero\storage\UTE9FWCU\Dressler and Sandage - 1983 - Rotational velocities and central velocity dispers.pdf:application/pdf}     }      the `\section{introduction}` consists of: "S0"


title: Left-align entire document

text: I'd like to left align my entire document (latex default seems to be center justified). Is there a simple way to do this? I'm trying to use               \begin{flushleft}     ...     \end{flushleft}      but really don't want to have to do that on a paragraph by paragraph basis (and when I try to simply add that to the start and end of my document I get an error.


title: Full colored Triangle and Circle in Metapost

text: The question may be trivial, but I need your help, to draw a full colored triangle and circle (where the triangle will be inside the circle). Here is my file `pic_1.mp`:               input gjktc.mp;          u:=1mm;          beginfig(1);          z0=(0,0);     z1=(20u,0);     z2=(10u,20u);          draw z0..z1..z2..cycle withcolor green;     draw z0--z1--z2--cycle withcolor red;     endfig;     end;      And the next one, `pic_2.mp`, where the one line will be rotated, and the space between lines will be colored:               input gjktc.mp;          u:=1mm;          beginfig(1);          z0=(0,0);     z1=(20u,0);     z2=(10u,10u);          p1 = z0--z1--z2--cycle ;     draw p1 withcolor black;     draw (z2--z0) rotated 5 withcolor black;          endfig;     end;      Here is a picture of what I want to have: ![enter image description here](http://i.stack.imgur.com/rBcMG.png)


title: htlatex options

text: I'm using htlatex (Miktek 2.9, on windows command prompt) with the command:               htlatex source.tex "3" "" "" "--interaction==nonstopmode"      to generate HTML from existing documents written in LaTeX. I've been coming across a couple of major problems that have me stumped, so I hope someone here can help.   1. My output creates (very poor quality) `.gif` equations. I've made the equations into `png`'s in the past but for some reason the `convert` function (run by t4ht?) seems to be defaulting to `.gif`. Is there a way I can specify the creation of `.png`'s instead (I'm honestly not sure how they were created in the first place)?   2. I've tried to specify the HTML output and image output directory without luck. I've read that the `imgdir:(location)/` and `-d/(location)/` options as follows should change the output directory, but it hasn't seemed to work for me.              htlatex source.tex "3,imgdir:images/" "" -d/tmp/ "--interaction==nonstopmode"        3. The image (not equation) scaling is incorrect in the final HTML output. In the document, I use a custom command to place the images (for PDF output):              \newcommand{\pic}[4]{       \begin{figure}[htbp]         \centering           \includegraphics[scale=#2]{#1}           \caption{#3}\label{#4}        \end{figure}     }      and this works normally. After running htlatex, the scaling is not preserved and the images are out of proportion.


title: Page geometry discrepancies

text: In the Companion 2nd Edition Table 4.2 shows page geometry values for various font sizes of the letterpaper paper size. These differ sometimes substantially from current values of the standard classes. Is the Companion wrong here or did the values change over the years, if they did what prompted this change? I took the liberty to take an image of the table for convenience which is shown below: ![enter image description here](http://i.stack.imgur.com/ncaTJ.jpg) I also include a MWE for experimentation for those interested to print the values:               \documentclass[10pt]{book}     \usepackage{pgf}     \def\aspectratio{\pgfmathparse{\paperheight/\paperwidth} \pgfmathresult}     \def\printgeometryvalues{\leavevmode       paperwidth \the\paperwidth\\       paperheight \the\paperheight\\       theheadheight \the\headheight\\       theheadsep \the\headsep\\       thetopmargin \the\topmargin\\       theoddsidemargin \the\oddsidemargin\\       theevensidemargin\the\evensidemargin\\       thetextheight\the\textheight\\       thetextwidth \the\textwidth\\       themarginparsep \the\marginparsep\\       themarginparwidth \the\marginparwidth\\       themarginpush \the\marginparpush\\       thevoffset \the\voffset       thefootskip \the\footskip\\       aspect ratio \aspectratio\\       topskip \the\topskip\\       voffset \the\voffset\\       hoffset \the\hoffset\\       topmargin \the\topmargin}     \parindent0pt     \begin{document}     \null\newpage     \printgeometryvalues     \end{document}      Of interest is the values of `\topmargin`, which other classes normally set to a negative value. Also IMHO the use of _ditto_ in the table is very unusual.


How can I use link references using hyperref package within AMS latex environment? Is it possible to use it with \cite{} or need to use anything else? When i try to create a dvi file I have an error "Some PostScript specials could not be rendered." Also, after Pdftexify the reference is not linked with the citation i.e. by clicking on Zaho (2004), it does not go to reference list. Here is my code:               \documentclass [44pt]{tran-l}     \usepackage [dvips] {graphicx}     \usepackage{hyperref}     \usepackage [dvips] {graphicx}     \usepackage[super]{natbib}          \begin{document}     \cite{Z}     \bibliographystyle{vancouver}     \end{document}          \bibliographystyle{apalike}     @BOOK{Z,     author={Z, and W},      title={Growth},      publisher={Science Press},      year={1982},     }


title: Is it possible to change the \cite command in the following way?

text: I know this does not follow very good citation guidelines, but I want to change the cite command so that in addition to whatever the current bib file dictates, it will also print in the name of the title of the paper. So, for example,                   \cite{smith-86}      will lead to                   (Smith, 1986; Introduction to Linear Algebra)      Is that possible to do? I want the title name to be pulled out of the "title" field in the .bib file. EDIT: I want it to be done transparently, so I can still just use the regular \cite command, after changing whatever is needed in the preamble.


title: Move TikZ cloud in a better position using beamer

text: I am trying to manipulate the exact position of a TikZ `cloud` but I am not sure if I'm doing any effort at all. ![](http://i.imgur.com/RYKKI.jpg) As you see in the aforementioned picture the space between items is not beautiful. So I tried to add it outside the `itemize` enviroment. It seems, though that it's not following my commands. The code I am using is               \documentclass[slidestop,compress,mathserif,12pt,xcolor=dvipsnames]{beamer}     \graphicspath{{images/}}     \definecolor{LHCblue}{RGB}{4, 114, 255}     \usecolortheme[named=LHCblue]{structure}     \usepackage[bars]{beamerthemetree} % Beamer theme v 2.2     \usepackage{kerkis}     \usepackage{multimedia}     \usepackage{subfigure}     \mode<presentation>     %frame     \newcommand*\oldmacro{}%     \let\oldmacro\insertshorttitle%     \renewcommand*\insertshorttitle{%          \oldmacro\hfill%       \insertframenumber\,}%/\,\inserttotalframenumber     \setbeamertemplate{footline}[frame number]     %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~     \setbeamercovered{higly dynamic}     \usetheme[watermark=ntua-logo.jpg]{Ilmenau} % Beamer theme v 3.0     \useoutertheme[subsection=true]{smoothbars}%Beamer Outer Theme-circles on top          \useinnertheme{circles} %rectangle bullet points instead of circle ones     \usepackage{beamerthemebars}     \setbeamercolor{navigation symbols dimmed}{fg=red!80!black}     \setbeamercolor{navigation symbols}{fg=red!80!black}     %~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~     \title[July 2012 H4 Test Beam\hspace{3cm} Stony Brook, NYC]{July 2012 H4 Test Beam}     \author[Stamatopoulos N. Athanasios\hspace{2.5cm}{athanasios.stamatopoulos@cern.ch}]        {Stamatopoulos N. Athanasios}     \institute{NTUA/CERN}     \logo{%       \makebox[0.99\paperwidth]{%         \includegraphics[width=1cm,keepaspectratio]{cern_logo_white.jpg}%         \hfill%         \includegraphics[width=1cm,keepaspectratio]{ntua-logo.jpg}%       }%     }          \usepackage{textpos}     \usepackage{tikz}     \usetikzlibrary{%     calc,%     fadings,%     shadings%     }          \usetikzlibrary{arrows,snakes,shapes}     %\usepackage{enumitem}     %\usepackage{paralist}             \begin{document}              \begin{frame}     \begin{itemize}         \item XY Resistive MM         \item Manufactured by Rui de Oliveira \quad \uncover<1->{\begin{tikzpicture}     \node[align=center,draw,shading=ball,text=white,cloud callout,cloud puffs=17,cloud puff arc     =140,callout pointer segments=3,anchor=pointer,callout relative pointer={(200:2 cm )},     aspect =2.5,scale=0.5]     at(current page.east){Thank you Rui!};     \end{tikzpicture}}         \item bla bla bla     \end{itemize}     \begin{tikzpicture}     \node[align=center,draw,shading=ball,text=white,cloud callout,cloud puffs=17,cloud puff arc     =140,callout pointer segments=3,anchor=pointer,callout relative pointer={(200:2 cm )},     aspect =2.5,scale=0.5]     at(current page.north east){Thank you Rui!};     \end{tikzpicture}     \end{frame}          \end{document}      Any ideas for this?


title: Write equations VAR and VECM equations in R

text: \documentclass[10pt]{article}     \usepackage{graphicx}     \usepackage{amsmath}     \begin{document}          \title{Case studies: Long run relationship}          \maketitle           \begin{abstract}     The cointegrating approach is proposed     \end{abstract}          \section{introduction}               Over the last century          \section{Methods and Results}          The 9 prices indexes from each province            A VAR(p) is written as          \begin{equation}     k_{t } =  A_{0}+ A_1k_{t-1}+ A_{2}k_{t-2}+ A_{2} k_{t-2} +......A_nk_{t-n} + e_{t}     \end{equation}     ####################################################################################     where k_{n}  =  (k_{1t}, k_{2t},.....,m_{Kt))  for k=1,....., K time series. The key assumptions are in the VAR(p)     ##################################################################################     \begin{eqnarray}     \Delta k_{t} & = & \Delta\Gamma{1}k_{t-1}+\Delta\Gamma{2}k_{t-2}+...+\Delta\Gamma{n}k_{t-n}       \end{eqnarray}          #########################################################################################     Where \gamma_{i}=-(I-A_{1} - ...A_{i}),  i= 2,.....,p-1     \Pi= -(I - A_{1}-....-A_{p})  is a N-dimensional time series,  A_{0}  is the intercept term, e_{t} is white noise     ########################################################################################     \end{document}      Hi everybody, I'm trying to write this piece of article in latex but it doesn't work at all because of these 4 lines. If you remove this 4 following lines then the the article comes quite well. But when i insert them, latex doesn't recognize. However i must insert these explanation on my article. Please can you help me to add this 4 codes in order to have my formal article. I must insert as everybody must explain every sign on his mathematical model. Please help me to insert them on my article.               where k_{n}  =  (k_{1t}, k_{2t},.....,m_{Kt))  for k=1,....., K time series. The key assumptions are in the VAR(p)               Where \gamma_{i}=-(I-A_{1} - ...A_{i}),  i= 2,.....,p-1     \Pi= -(I - A_{1}-....-A_{p})  is a N-dimensional time series,  A_{0}  is the intercept term, e_{t} is white noise


title: beamerposter custom style with keyval definition

text: I'm creating a beamerposter style accordingly to my department specification. I would like to create a theme where the definitions of the blocks can vary accordingly to a keyword in the calling of the theme. I'm trying to explain with a MWE The custom style works like this               \ProvidesPackage{beamerthemeMYposter} % this style was created by David Vilar     % Define boolean options     % -----------------     \newif\if@shadowbox     \DeclareOption{shadowbox}{\@shadowboxtrue}     \DeclareOption*{\PackageWarning{beamerthemeMYposter}{Unknown option `\CurrentOption'}}     % process options     % ------------     \ProcessOptions     \mode<presentation>     \usepackage{tikz}       % for drawing the nice rounded boxes      \usetikzlibrary{arrows,backgrounds}     \newcommand{\makeruleinbox}{{\usebeamercolor[bg]{block alerted title}\centering\hspace*{-0.7cm}\rule{\inboxrule}{0.5cm}}}     \usepackage{ragged2e}      \newlength{\inboxwd}     \newlength{\iinboxwd}     \newlength{\inboxrule}     \makeatletter       \makeatother     \usepackage{xcolor}          % Block definition     \setbeamercolor*{block body}{fg=blue,bg=white}     \setbeamerfont{block title}{size=\large,series=\bf}     % conditional block body definition     \if@shadowbox     \setbeamercolor*{block title}{bg=white,fg=red}     \setbeamercolor*{block body}{fg=blue, bg=white}     \setbeamerfont{block title}{size=\large,series=\bf}     \setbeamertemplate{block begin}     {       \par\vskip\medskipamount       \begin{beamercolorbox}[colsep*=.5ex,dp={2ex},center]{block title}         \vskip-0.25cm         \usebeamerfont{block title}\large\insertblocktitle         \begin{flushleft}           \vskip-1cm           \begin{tikzpicture}[remember picture,overlay]             \shade [inner color=blue,outer color=white]             (0,0) rectangle (\textwidth,0.3cm);           \end{tikzpicture}         \end{flushleft}       \end{beamercolorbox}       {\parskip0pt\par}       \ifbeamercolorempty[bg]{block title}       {}       {\ifbeamercolorempty[bg]{block body}{}{\nointerlineskip\vskip-0.5pt}}       \usebeamerfont{block body}       \vskip-0.5cm       \begin{beamercolorbox}[colsep*=.5ex,vmode]{block body}         \justifying       }            \setbeamertemplate{block end}       {       \end{beamercolorbox}       \vskip\smallskipamount       }     \else     \setbeamercolor*{block title}{bg=blue,fg=white}     \setbeamertemplate{block begin}{     \vskip.75ex     \begin{beamercolorbox}[leftskip=1cm,colsep*=.75ex]{block title}%     \usebeamerfont*{block title}\insertblocktitle     \end{beamercolorbox}%     {\ifbeamercolorempty[bg]{block body}{}{\nointerlineskip\vskip-0.5pt}}%     \usebeamerfont{block body}%     \begin{beamercolorbox}[colsep*=.75ex,sep=.75ex,vmode]{block body}%     \ifbeamercolorempty[bg]{block body}{\vskip-.25ex}{\vskip-.75ex}\vbox{}%     }     \setbeamertemplate{block end}{     \end{beamercolorbox}     }     \fi          \mode<all>      Then in the document I'm trying to call like that               \documentclass[final]{beamer}     \mode<presentation> {     \usepackage[size=a0,orientation=landscape,debug]{beamerposter}  % e.g. custom size poster     \usetheme[shadowbox]{MYposter}     }     \begin{document}     \begin{frame}{}      \begin{block}{trial}     \end{block}     \end{frame}     \end{document}      If you try this MWE you can see that there is no way the option shadowbox is considered. I must admit this is my first attempt to use conditional keyword in package creation. Any suggestion is welcomed


title: Classicthesis and space between emphasized text

text: I'm using classicthesis and LyX to write my graduate project, but I'm having issues in the resulting PDF. If I have a word emphasized, in typewriter family, etc., the whitespace before and after is truncated. I have to fix this by adding `\xspace` or similar.


title: Create a document looping through images

text: I have about a hundred images named `001.png` to `123.png`. I want to create a document which includes each image in center of a page. i.e. a 123 page document with each image on a single page. I know that doing this is possible using macros but I have no clue how to do that. Any help is appreciated.


title: How to typeset the name of a category?

text: I'm LaTeXing some category theory, and typeset the names of my categories in boldface ( **Set** , **Rel** , ...). Since I might want to change that, I put               \newcommand{\catname}[1]{\textbf{#1}}     \newcommand{\Set}{\catname{Set}}     \newcommand{\Rel}{\catname{Rel}}     ...      in my document header. But `textbf` very kindly respects the italics elsewhere in the document, so that if I try to typeset a category inside a definition (say) I get **_Set_**. I don't want this -- I'd like the categories to be upright. I tried               \newcommand{\catname}[1]{{\bf #1}}     \newcommand{\catname}[1]{\ensuremath{\boldsymbol{\operatorname{#1}}}}      but these both ruin the spacing after the category name. Help! =)


title: How to open TeXworks' TeX root pdf result with arara?

text: Until now I've been using TeXworks to edit my `.tex` projects. When the project is divided in several subfiles I can use `% TeX root=my_main_file.tex` directive in order to compile the main file and not the one it's being edited. Once the file is compiled `my_main_file.pdf` is shown in TeXworks' pdf viewer. Yesterday I decided to test `arara` because I also wanted to use its `clean` rule. After installing it and (more or less) reading the manual I don't know how to automatically open `my_main_file.pdf` after typesetting `my_subfile`. `arara` typesetting engine is declared with `$fullname --verbose --log` and `view PDF after running` is marked. Rule `%arara: pdflatex` on `my_main_file.tex` works as expected: main file is processed and viewed. Rule `% arara: pdflatex: {files: [ my_main_file ] }` on `my_subfile.tex` works almost as expected: main file is processed but nothing is shown in viewer. What am I missing?


title: Biblatex citations first and last author only

text: I would like to include only the first and the last author in my citations within the text. In case, there are only two authors, they should be connected by 'and'. For more than two authors, the remaining author names should be replaced by dots.   * (1 author ) John Doe (2004)    * (2 authors) John Doe and Peter Noel (2004)    * (3 authors) John Doe, ..., Peter Noel (2004)  What I am looking for is some way of formatting it, so that the following commands, in particular 'FirstLast' gives me the desired output.               \DeclareCiteCommand{\longcite}{}{%      \printnames[FirstLast]{author} (\printfield{year}),          \printfield{journaltitle}}{;}{}      So my question is, what should FirstLast look like, to get the desired output?


title: Remove Appendices from table of content

text: I used this code to generate appendices               \documentclass [a4paper,12pt,oneside,final]{book}     \usepackage[title]{appendix}     \begin{document}     \dominitoc      \tableofcontents     \listoffigures \addcontentsline{toc}{chapter}{List of Figures} \mtcaddchapter     \listoftables \addcontentsline{toc}{chapter}{List of Tables} \mtcaddchapter     \begin{appendices}     \chapter{Appendix A}     \section{aaaa}     \end{appendices}     \end{document}      The appendices appear at the end of the table of contents How i can remove them so they will not appear any suggestion?


title: Custom table caption (Updated)

text: I'd like to achieve a custom table (figure) format with Table numbering and title (this is usually the title also used in the list of tables but does not have to be) in boldface, and the (longer) description below the title formatted like a paragraph, that means first line indented and next lines not. I have read the `caption` manual but there is no direct solution. Short Illustration: **Table 1: Title** (numbering + title) description formatted like a paragraph (second line to end, with first line indented, rest not) And here is my MWE:               \documentclass[a4paper, 12pt, headsepline, smallheadings,]{scrreprt}     \overfullrule=1mm     \DeclareRobustCommand{\captionpar}{\par}     \usepackage[labelfont={small,bf}, textfont=small, labelsep=colon,singlelinecheck=false,format=plain, parindent=1em]{caption}     \newlength\myindention     \DeclareCaptionFormat{myformat}%     {#1#2\\\hspace*{\myindention}#3}     \setlength\myindention{1em}     \captionsetup{format=myformat}          \begin{document}          \begin{table}     \caption{A table description description description description description    description description description description description description description description description description description description description description description description }     \centering     \fbox{Inhalt der Tabelle}     \end{table}          \end{document}      As you can see, the title in boldface is missing in the current format. Is there any way to add this separated from the rest of the describing text? Thanks.


title: Zero space between characters, decibel sign

text: My MWE,               \documentclass[a4paper,11pt]{scrbook}     \usepackage[T1]{fontenc}     \begin{document}     dB     \end{document}      output, ![enter image description here](http://i.stack.imgur.com/6xm8B.png) But I want zero (maybe negative) space between d and B. That is ![enter image description here](http://i.stack.imgur.com/zhqiD.png) I didn't find duplicate another question. So, does anyone know how to fix it?


title: Automatic line-break in tabular

text: Sorry if I've missed the answer in another post, but I've literally spent 3+ hours googling this problem now. I'm making a tabular and I'd like to to automatically do a like break rather than going beyond the page. This is my tabular code:               \begin{table}[h]     \begin{tabular}{|l|l|l|}     Use Case Navn:          & \multicolumn{2}{l}{Opret Server} \\     Scenarie:               & \multicolumn{2}{l}{At oprette en server med bestemte regler som tillader folk at spille sammen. More Text more text More Text} \\     \end{tabular}     \end{table}      This is my preamble:               \documentclass[danish,a4paper,twoside,11pt]{report}     \usepackage{babel}     \usepackage[utf8x]{inputenc}     \usepackage{natbib}     \usepackage{graphicx}     \usepackage{epstopdf}     \usepackage{titling}     \usepackage{color}     \usepackage{xcolor}     \usepackage{nag}     \usepackage{tabularx}          \newcommand{\myparagraph}[1]{\paragraph{#1}\mbox{}\\}      This is how it looks right now: ![image](http://i.stack.imgur.com/AeJbx.png) Anyway thanks, I appreciate you taking your time. Let me know if you need more info! Kind regards Alexander


title: FNDB or .CFG Help

text: Installed MikTex2.9 via Protext distribution on Windows Vista HP. Great, pdflatex, with almost all packages, ran out of the box. But ... My work is set in Baskerville. So, I stored my font definition file, t1pbv.fd (T1 coded baskerville) in MT/tex/latex/psnfss, as it was on my other PC. Also copied the various .ttf, .map, and .tfms in appropriate places. Then ran 'refresh FNDB'. Sadly, running pdflatex again, the file t1pbv is not found. There is no file named FNDB that I can examine like (the old?) LS-R? Something else must also be updated, a .cfg? Thanks for saving me an afternoon, Ernst


title: How to create pdf with command line using MiKTeX?

text: I downloaded and installed MikTeX on my machine (Windows 7), then when I run the command:               latex ex.tex       the outputs were:   1. ex.aux   2. ex.dvi   3. ex.log So my question is, what option could I use to produce `ex.pdf`? Any suggestion?


title: Why is there a \, space at the beginning of the "aligned" environment?

text: Near the beginning of the definition of the `amsmath` environments `aligned` and `gathered` (and also `mathtools`' `multlined`) there's an explicit thin space `\,`. This often has to be cancelled with `\!`, as has been observed various times: 1 2 3 4 5 6 7 I'd like to know _why_ this explicit `\,` is there - what would go wrong without it? * * * From `amsmath.dtx`:               \newcommand{\start@aligned}[2]{%         \RIfM@\else             \nonmatherr@{\begin{\@currenvir}}%         \fi         \savecolumn@ % Assumption: called inside a group     %    \end{macrocode}     %    The \cs{null} here is to keep the \cs{,} glue from causing the     %    invocation of the clause in \tex/'s built-in tag placement     %    algorithm that can cause an equation to be shifted all the way over     %    to the margin.     %    \begin{macrocode}         \null\,%


title: How to remove indentation when using the aligned environment?

text: I want to align equations inside an enumeration, so I use the `aligned` environment and its `[t]` option to make the first equation appear on the same baseline as the item label:               \documentclass{article}     \usepackage{amsmath, enumitem}          \begin{document}     \begin{enumerate}[align=left, leftmargin=*, label=\large\sffamily\bfseries \alph*)]       \item $a = 1$       \item       $       \begin{aligned}[t]         a &= 1\\         b &= 2\\         c &= 3       \end{aligned}       $     \end{enumerate}     \end{document}      This works quite well, but I noticed that the `aligned` environment introduces a small indentation (I added the red line for better visualization): ![aligned indentation](http://i.stack.imgur.com/KeRXW.png) How can this be solved? Or is there an even better alternative to `aligned`?


title: biblatex: No comma after et al

text: I am using Biblatex for my dissertation bibliography. The journal format I am using requires that et al, but in italic and have a period at the end. What I have:               Beadle et al.,      What I want: Beadle _et al_. Also, when only two authors are present, the citation need to be like this:               (Beadle and Tautum 1949)      But what I have right now is `(Beadle and Tautum, 1949)` (notice the comma) I looked at the biblatex manual, but could not figure out how to go about this. Also, search on stackexchange hasn't turned up anything useful either. Thanks.


title: How do I get "et al." to appear in italics when using \textcite or \citeauthor with biblatex

text: I'm using `biblatex` with the `chem-rsc` package option. I sometimes make use of the `\textcite{<key>}` or `\citeauthor{<key>}` commands to put the authors' name into text. When there are many, it writes "Bloke et al.", but I would like to make it put the "et al." in italics. I'm sure there are some hacky ways of doing this by rewriting parts of commands. I'm hoping that there is some fairly straight forward and robust method for it though.


title: Why are subitems in beamer columns spaced wider?

text: ![sub items of unequal spacing](http://i.stack.imgur.com/GmAwD.png) As seen in the picture, the sub-sub-items within the column are vertically spaced significantly wider than their counterparts outside any column. As I replaced the bullet points with depth numbers for better recognition, it can be clearly seen that they are on the same level. Here is the code.               \documentclass{beamer}     \setbeamertemplate{itemize item}{(1)}     \setbeamertemplate{itemize subitem}{(2)}     \setbeamertemplate{itemize subsubitem}{(3)}     \begin{document}     \begin{frame}       \begin{itemize}         \item a top item           \begin{itemize}             \begin{columns}               \begin{column}{.5\linewidth}                 \item a sub item                   \begin{itemize}                     \item deep subbed item a                     \item deep subbed item b                     \item deep subbed item c                   \end{itemize}                 \item another sub item               \end{column}               \begin{column}{.5\linewidth}                 \item another column               \end{column}             \end{columns}           \end{itemize}       \end{itemize}       \begin{itemize}         \item items outside columns           \begin{itemize}             \item sub items outside columns               \begin{itemize}                 \item deep subbed item d                 \item deep subbed item e                 \item deep subbed item f               \end{itemize}           \end{itemize}       \end{itemize}     \end{frame}     \end{document}      What causes the spacing to be modified in the column environment and how can it be corrected?


title: tabularx inside a \newenvironment

text: There's something wrong with this code:               \newenvironment{Tbl}     {\begin{tabularx}{\textwidth}{|l|X|} \hline}     {\end{tabularx}}      but this is fine:               \newenvironment{Tbl}     {\begin{tabular}{|l|l|} \hline}     {\end{tabular}}      Why? And how can I get the first to work? Here is the full LaTeX file:               \documentclass[a4paper, 12pt]{article}     \usepackage{tabularx}          \newenvironment{Tbl}     {\begin{tabularx}{\textwidth}{|l|X|} \hline}     {\end{tabularx}}          \begin{document}          \begin{Tbl}     \end{Tbl}          \end{document}      > `latex test.tex` produces:               This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6)      %&-line parsing enabled.     entering extended mode     (./test.tex     LaTeX2e <2005/12/01>     Babel <v3.8h> and hyphenation patterns for english, usenglishmax, dumylang, noh     yphenation, arabic, basque, bulgarian, coptic, welsh, czech, slovak, german, ng     erman, danish, esperanto, spanish, catalan, galician, estonian, farsi, finnish,      french, greek, monogreek, ancientgreek, croatian, hungarian, interlingua, ibyc     us, indonesian, icelandic, italian, latin, mongolian, dutch, norsk, polish, por     tuguese, pinyin, romanian, russian, slovenian, uppersorbian, serbian, swedish,      turkish, ukenglish, ukrainian, loaded.     (/usr/share/texmf/tex/latex/base/article.cls     Document Class: article 2005/09/16 v1.4f Standard LaTeX document class     (/usr/share/texmf/tex/latex/base/size12.clo))     (/usr/share/texmf/tex/latex/tools/tabularx.sty     (/usr/share/texmf/tex/latex/tools/array.sty)) (./test.aux))     Runaway argument?      \par      ! File ended while scanning use of \TX@get@body.     <inserted text>                      \par      <*> test.tex          ?


title: Different outputs with/ without \newenvironment

text: I'm trying to setup my own CV without Curve. To do so, I intend to separate sections the same way with a `\newenvironment`.               %[...]     \newlength{\margin}     \setlength{\margin}{.3\textwidth}          \newcommand{\alinea}{\hspace{0.1cm}}     \newcommand{\tn}{\tabularnewline}          \newcolumntype{M}[1]{>{\raggedright}m{#1}}          \newenvironment{rubrique}{     \begin{tabularx}{\textwidth}{M{\margin}|X}     } %     {\end{tabularx}}      But then in my document, the two blocks below give a different output :               % OKAY     \begin{tabularx}{\textwidth}{m{\margin}|X}     Aout 2006 & Lorem Ipsum...     \end{tabularx}      \--               % ERROR : File ended while scanning use of \TX@get@body     \begin{rubrique}     Aout 2006 & Lorem Ipsum...     \end{rubrique}      I am certain to miss a point about `\newenvironment`, but which one ?


title: How can I create a wrapper environment for a complicated usage of tabularx?

text: > **Possible Duplicate:**   >  tabularx inside a \newenvironment I know (at least basically) how to create my own environments using `\newenvironment`, but I recently encountered a problem trying to create an environment based on the `tabularx` environment. I had a complicated `tabularx` that was going to be repeated often, and I wanted to make an environment wrapper to save me time should I need to modify some aspect of this layout. For example,               \newenvironment{myspecialtable}{\begin{tabularx}{\textwidth}{r p{3in} X r}}{\end{tabularx}}      I get an error message when I try to use this environment. Can anyone tell me why this will not work?


title: Sum of values spread across tables in document? (like in Word)

text: My document is structured as follows:               * Bla bla bla            Quantity | Item     | Price per item | Total price       ---------+----------+----------------+------------              5 | Sandwich |           5.00 |       25.00               * More bla bla bla            Quantity | Item     | Price per item | Total price       ---------+----------+----------------+------------              3 | Coke     |           1.00 |        3.00          Grand total: 28.00      In the past, I have created a similar document with Word 2007 where I had all calculations done automatically. _Is that also possible with LaTeX?_ I am aware of spreadtab, which I frequently use for invoices. It works great if all the values are in one table. However, this is not the case here.


title: Special decoration for TikZ pin feature

text: I try to achieve the curvy pin style I sketched below. It would help to distinguish pin lines from grid and other lines in the diagram. ![Curvy pins](http://i.stack.imgur.com/2kFGP.png)   1. How can I realize a decoration that automatically draws such a curve?   2. How can I integrate this with the pin feature? The code for the picture:               \documentclass[tikz,convert]{standalone}          \usepackage{pgfplots}          \begin{document}          \begin{tikzpicture}[         pin distance=5mm,         every pin edge/.style={             decorate,             decoration={                 snake,                 pre length=4pt             }         }     ]       \begin{axis}[         width=12cm,         height=5cm,         xmin=0,xmax=4,         ]              \addplot coordinates {(1,1) (3,3)}         coordinate [pos=.5] (a) coordinate [pos=.7] (b);              \node [pin=135:From the manual] at (a) {};              \path (a) ++(-45:1cm) node (c) {What I want};         \draw [gray] (c) to[out=110,in=-70] (a);              \path (b) ++(-45:.8cm) node [right] (d) {What I want II};         \draw [gray] (d.west) to[out=160,in=-20] (b);            \end{axis}     \end{tikzpicture}     \end{document}      (I tagged with pgfplots as well since this would be a common application.)


title: Modifying the font head and size inside \section in emacs editor

text: I am running Emacs 23 with AUCTeX for editing LaTeX source files. I'd like to be able to customise the font head and size of the section name. To make things absolutely clear, the font inside the `\section{}` command, becomes slightly bigger in size and into a font head different from the rest of the buffer. Is it possible to customize this behaviour?


title: Manual font installation vs CTAN's metric files

text: I installed on my system some commercial PostScript fonts. For all of them, metrics were available on CTAN, namely in the Schmidt's collection http://www.ctan.org/pkg/w-a-schmidt. Now, most of the metrics were created a long time ago (about 2004), and most of them (according to the attached documentation) seems to need some revision, which was never implemented. Since their release, some updates to fontinst have occurred (the last in 2009), and version 1.9 is very well documented (see, e.g., http://www.ctan.org/tex- archive/info/Type1fonts/fontinstallationguide/). I was wondering what are (if any) the additional qualities of the CTAN's metrics as opposed to the metrics one could quite easily generate following closely the Font Installation Guide cited above. To be more concrete, consider for instance Tutorial 6 of the guide, where metrics for Minion (with Expert subset) are genereted. How do these compare to the ones provided by the pmn package from w-a-schmidt? I guess that they probably "look and feel" the same, but I suspect that there are some (small?) typographical differences that a trained eye (maybe not mine) can notice. In other words, do the metrics provided on CTAN contain some tricks that the most recent fontinst cannot reproduce easily? Of course, I know that for those who use LuaLaTeX and XeLaTeX most of this discussion seems useless. Nonetheless, I still prefer to use the "genuine" LaTeX (for a number of personal reasons). I am mostly interested in precise and technical answers. Thank you in advance!


title: Change to English, the subject of letteracdp

text: In letteracdp package, you write the letter subject, and when you compile the document, TeXLive will put `Oggetto:` before it. I would like to change it into `Subject:`


title: utf8 characters

text: I would like to include the output of the `npm list` command in a latex verbatim block:               jeroen@jeroen-ubuntu:~/Desktop$ npm install d3     jeroen@jeroen-ubuntu:~/Desktop$ npm list     /home/jeroen/Desktop     └─┬ d3@2.10.3       ├─┬ jsdom@0.2.14       │ ├─┬ contextify@0.1.3       │ │ └── bindings@1.0.0       │ ├── cssom@0.2.5       │ ├── htmlparser@1.7.6       │ └─┬ request@2.12.0       │   ├─┬ form-data@0.0.3       │   │ ├── async@0.1.9       │   │ └─┬ combined-stream@0.0.3       │   │   └── delayed-stream@0.0.5       │   └── mime@1.2.7       └── sizzle@1.1.0      However the funny little tree characters are non ascii. I tried saving the file as UTF8 and adding `\usepackage[utf8]{inputenc}` to my premable. However, it gives me the errors:                -Package inputenc Error: Unicode char \u8:â not set up for use with LaTeX      Is there any way I can use these characters?


title: Resume numbering the footnote

text: I use the following piece of code to put something as my footnote (borrowed from a friend).               {\let\thefootnote\relax\footnotetext <text> }      But what happens is after putting this, any further footnote will not have numbering with it. I was wondering how to resume the numbering. I believe `\relax` is the culprit here.


title: How to read a stream of tokens up to one of two different delimiters

text: # The core question How can I process text delimited by one of two terminators? For instance, if I want to process text up to the next `\A`, I can just write               \def\CmdA#1\A{...}      But suppose that `\A` might not be present, in which case `\B` should terminate processing instead. Is there a way to write a command               \def\CmdAB#1[\A|\B]{...} % Nonsense syntax      such that               \CmdAB\first\A\second\B      sets `#1` to `\first` and leaves `\second\B` in the input stream, and               \CmdAB\only\B      sets `#1` to `\only` and leaves nothing in the input stream? `\A` should take precedence over `\B`, so that               \CmdAB\other\B\order\A\after\B      sets `#1` to `\other\B\order` and leaves `\after\B` in the input stream. Furthermore, since my goal is to pre-process the text _and then use it_ , I need to know which of `\A` or `\B` was selected. * * * # What I've tried I had the idea to scan tokens one at a time, saving the scanned ones in a token register for later processing, and stop scanning when I saw either end token, but I couldn't get it to work. I wrote some simpler code which uses `\let` to pick characters out of the input, checking for a single terminator, and adding to a token register along the way, but this doesn't work because `\let` control sequences don't expand. The code is the following:               \newtoks\ScanToks     \newcommand*{\AddTok}[1]{\ScanToks\expandafter{\the\ScanToks#1}}          \newcommand*{\QScan}{\QScan}     \newcommand*{\Scan}{\afterassignment\DoScan\let\Scanned=}     \newcommand*{\DoScan}{%       \ifx\Scanned\QScan\else         \expandafter\AddTok\Scanned         \expandafter\Scan       \fi     }      This looks good, and _seems_ to work when you run it, but it doesn't quite when you look at the output:               *\Scan 1 2 3 \QScan          *\showthe\ScanToks     > \Scanned \Scanned \Scanned .      Once you think about it (and read the right parts of _The TeXbook_ and the right TeX.SE questions), this makes a frustrating sort of sense; if we have `\let\a=1` and `\let\b=\a`, then how could we possibly we tell that `\a` ought to "expand" into `1` but `\b` ought to "expand" into `\a`? But unfortunately, I don't see a way to write a `\def` which only absorbs one token from the input stream. If `\def` took arbitrary balanced text, I could probably work with that, but instead `\def` _requires_ a braced group, and otherwise parses things as being part of the argument specification. Also, this `\Scan` command isn't processing the spaces, but that's small potatoes in comparison. * * * # The motivation I'm trying to write a command which processes the first line of an `align`-like environment. This command needs to:   1. Absorb tokens up until the first `\\`.   2. Process those tokens (that is, count ampersands to determine the number of columns).   3. Place those tokens back in the input stream, preceded by the computed information (that is, the number of columns). However, the `\\` delimiter might not be present if the environment is only one line long; in that case, I'd need to instead process the whole environment, up through `\end{EnvName}` (and all the rest is the same). But at the start of an environment, I can't know which of these two situations is the case, and so I want to scan ahead to the next `\\` _or_ the `\end{EnvName}` (thus motivating the question).


title: Programming with pgf arrays : how to create an array?

text: I am trying to do some automatic drawing in tikz. The point is I want to be able to provide the minimal quantity of information to my macro, and still have it work. More precisely (but without entering useless details), I want to take an array of coordinates, perform some computations on them, and draw the picture based on the result of these computations. But whatever route I try to take, I face the same problem : I need to work with arrays of coordinates. Thanks to `\foreach` and to the `\myarray[index]` syntax, some things are (more or less) easy to do with such arrays. One good example is this question. However, as soon as you try to do more complicated stuff, difficulties arise. For example, how to sort an array? How to map a function on each element of an array? It seems it would all be easy to do, if we were able to easily create and/or modify an array. However, with the commands I know, it is only possible to read the array's content. So I have tried concentrating on the most easy task I can imagine yet not do : appending an element to the end of an array. Since I couldn't find any pure pgf way of doing it, I have tried some low- level hacks (which you can find below for the most part), but `pgf`'s syntax giving importance to braces makes it a hell to track the expansion process, let alone fix it.               \documentclass{article}          \usepackage{tikz}          \newcommand{\printarray}[1]{\noindent     \foreach \i in #1 {\i\\}     }          \begin{document}          \def\myarraywithonebrace{1,2,3,4}     \def\myarraywithtwobraces{{1,2,3,4}}          \printarray{\myarraywithonebrace}     \printarray{\myarraywithtwobraces}          % Ok... So according to the manual, it's supposed to work better with two braces,      % but then what am I doing wrong.          % Whatever, let's append an element     \def\mynewarraywithonebrace{\myarraywithonebrace,5}     \def\mynewarraywithtwobraces{\myarraywithtwobraces,5}          \printarray{\mynewarraywithonebrace}     \printarray{\mynewarraywithtwobraces}          % Ok, so it fails in both cases because it takes the array as a whole.     % Let's try appending sequencially each of its elements, then?          \def\mynewarraywithonebrace{\foreach \i in \myarraywithonebrace {\i, }5}     \def\mynewarraywithtwobraces{\foreach \i in \myarraywithtwobraces {\i, }5}          \printarray{\mynewarraywithonebrace}     \printarray{\mynewarraywithtwobraces}          % Now what... in each case I get a string instead of an array.          % Maybe it means it's time to add that extra pair of braces?          \def\mynewarraywithonebrace{{\foreach \i in \myarraywithonebrace {\i, }5}}     \def\mynewarraywithtwobraces{{\foreach \i in \myarraywithtwobraces {\i, }5}}          \printarray{\mynewarraywithonebrace}     \printarray{\mynewarraywithtwobraces}          % ... Nope          \end{document}      Is my quest hopeless?


title: How to define default options to a class?

text: I do not undestand how to pass options to the parent class when writting a child class. I tried several possibilities but I never get flush left aligned equations. I do understand the difference between `LoadClass` and `LoadClassWithOptions` but I think this is not the problem here. The uncommented lines correspond to what I understand from the document clsguide.pdf but it does not work.               \RequirePackage{filecontents}          % my class file     \begin{filecontents}{baz.cls}     \PassOptionsToClass{fleqn}{article}     \ProcessOptions\relax     %\LoadClass[fleqn]{article}     \LoadClass{article}     %\LoadClassWithOptions{article}     \RequirePackage{amsmath}     \end{filecontents}          \documentclass{baz}      %\documentclass[fleqn]{baz}           \usepackage{lipsum}          \begin{document}     \lipsum[1]     \begin{equation*}         e^{i\pi} + 1 = 0     \end{equation*}     \lipsum[2]     \end{document}


title: TikZ calendar shading opacity

text: When highlighting ranges in a calendar, I can't seem to get the overlapping area to blend as would normally happen with overlapping opaque objects. For example using the following code (compiled with XeLaTeX):               \documentclass{standalone}     \usepackage{tikz}     \usetikzlibrary{calendar}          \begin{document}          \begin{tikzpicture}       \begin{scope}[yshift=2em]         \draw [line width=5mm, opacity=0.75] (0,1) -- (2,1);         \draw [line width=5mm, opacity=0.5] (1,0) -- (1,2);       \end{scope}            \calendar [dates=2014-02-01 to 2014-02-last,       week list,       day xshift = 2em,       day yshift = 2em,       every day/.style={anchor=center, minimum width=2em, minimum height=2em},       if={(between=2014-02-10 and 2014-02-16)[days={fill=black, text=black, fill opacity=0.75, text opacity=1}]},       if={(Wednesday) [days={fill=black, text=black, fill opacity=0.5, text opacity=1}]},       ];          \end{tikzpicture}          \end{document}      I would like the 12 to have the same background fill as the middle of the cross. ![enter image description here](http://i.stack.imgur.com/0ukO5.png)


title: Using todonotes in math-mode

text: Is it possible to create notes via the package `todonotes` in a displayed math environment? Here is a minimal example where it fails:               \documentclass{minimal}          \usepackage{todonotes}          \begin{document}     \[     \todo{think about it twice}foo = bar     \]     \end{document}      Anyone an idea?


title: AUCTeX, preview-latex, and Ghostscript (Emacs)

text: I'll keep this short and sweet; Emacs can't find `gs`, which has been installed via _brew_ and works fine. **Error**   `PDF2DSC sentinel: Searching for program: No such file or directory, gs` **MWE**               \documentclass{article}     \begin{document}     This is a test.  $x^4$.     \end{document}      And my `PATH` after init: `"/usr/local/bin:/usr/texbin:/usr/local:/usr/bin:/bin:/usr/sbin:/sbin"` `brew` placed a symlink to Ghostscript under `/usr/local/bin` `->` `/usr/local/Cellar/ghostscript/9.06/bin/gs`. (Adding this directory doesn't help.) * * * Is this a problem with `preview` in some way, or is it a problem with Emacs itself? (I should note that running the shell command directly (`M-! gs`) works as expected, and running `psf2dsc` manually also seems to work as expected (no errors, `mwe.dsc` produced).) * * * Per @Charles' request, `echo $PATH` produces `/usr/local/bin:/usr/texbin:/usr/local:/usr/local/Cellar/ghostscript/9.06/bin:/usr/bin:/bin:/usr/sbin:/sbin` under `M-x eshell`. * * * Per @Charles' request, `M-x preview-report-bug` produces               Emacs  : GNU Emacs 24.2.1 (x86_64-apple-darwin, NS apple-appkit-1038.36)      of 2012-08-27 on bob.porkrind.org     Package: 11.86          current state:     ==============     (setq      AUCTeX-version "11.86"      LaTeX-command-style '(("" "%(PDF)%(latex) %S%(PDFout)"))      image-types '(png gif tiff jpeg xpm xbm pbm)      preview-image-type 'png      preview-image-creators '((dvipng                    (open preview-gs-open preview-dvipng-process-setup)                    (place preview-gs-place)                    (close preview-dvipng-close))                   (png (open preview-gs-open) (place preview-gs-place)                    (close preview-gs-close))                   (jpeg (open preview-gs-open)                    (place preview-gs-place) (close preview-gs-close))                   (pnm (open preview-gs-open) (place preview-gs-place)                    (close preview-gs-close))                   (tiff (open preview-gs-open)                    (place preview-gs-place) (close preview-gs-close))                   )      preview-dvipng-image-type 'png      preview-dvipng-command "dvipng -picky -noghostscript %d -o \"%m/prev%%03d.png\""      preview-pdf2dsc-command "pdf2dsc %s.pdf %m/preview.dsc"      preview-gs-command "gs"      preview-gs-options '("-q" "-dSAFER" "-dNOPAUSE" "-DNOPLATFONTS" "-dPrinted"                   "-dTextAlphaBits=4" "-dGraphicsAlphaBits=4")      preview-gs-image-type-alist '((png png "-sDEVICE=png16m")                        (dvipng png "-sDEVICE=png16m")                        (jpeg jpeg "-sDEVICE=jpeg")                        (pnm pbm "-sDEVICE=pnmraw")                        (tiff tiff "-sDEVICE=tiff12nc"))      preview-fast-conversion t      preview-prefer-TeX-bb nil      preview-dvips-command "dvips -Pwww -i -E %d -o %m/preview.000"      preview-fast-dvips-command "dvips -Pwww %d -o %m/preview.ps"      preview-scale-function 'preview-scale-from-face      preview-LaTeX-command '("%`%l \"\\nonstopmode\\nofiles\\PassOptionsToPackage{"                  ("," . preview-required-option-list)                  "}{preview}\\AtBeginDocument{\\ifx\\ifPreview\\undefined" preview-default-preamble "\\fi}\"%' %t")      preview-required-option-list '("active" "tightpage" "auctex"                     (preview-preserve-counters "counters"))      preview-preserve-counters nil      preview-default-option-list '("displaymath" "floats" "graphics" "textmath"                        "sections" "footnotes")      preview-default-preamble '("\\RequirePackage["                     ("," . preview-default-option-list)                     "]{preview}[2004/11/05]")      preview-LaTeX-command-replacements nil      preview-dump-replacements '(preview-LaTeX-command-replacements                      ("\\`\\([^ ]+\\)\\(\\( +-\\([^ \\\\\"]\\|\\\\\\.\\|\"[^\"]*\"\\)*\\)*\\)\\(.*\\)\\'" "\\1 -ini -interaction=nonstopmode \"&\\1\" " preview-format-name ".ini \\5")                      )      preview-undump-replacements '(("\\`\\([^ ]+\\) .*? \"\\\\input\" \\(.*\\)\\'"                     "\\1 -interaction=nonstopmode \"&"                     preview-format-name "\" \\2")                        )      preview-auto-cache-preamble 'ask      preview-TeX-style-dir "/Users/sean/.emacs.d/elpa/auctex-11.86/latex"      )          Output from running `gs -h':      Followed by a message: `Searching for program: No such file or directory, gs`


title: Tikz tree and position of single leaf in binary tree

text: I am constructing a binary tree which looks as follows:               \begin{tikzpicture}     \node {root}         child {  node {left}   }         child {  node {right}                         child { node {rightmost} }                  }  ;     \end{tikzpicture}      ![screenshot](http://i.stack.imgur.com/aiVpJ.png) In case of single children, as is the case with "rightmost", the edges are just pointing down. I'd like to influence the position of the single edge and node so that they are slanted as if they had a sibling: ![screenshot](http://i.stack.imgur.com/yeP0t.png) How would I do that?


I am having trouble compiling the attached mwe. I receive the following message: "Package pgfkeys Error: I do not know the key '/tikz/y error plus index' and I am going to ignore it. Perhaps you misspelled it." The tikz picture was created by matlab2tikz so I am surprised it doesn't compile. Can anyone please tell me what is wrong?               \documentclass[a4paper,titlepage,11pt]{article}     \usepackage{pgfplots}     \usepackage{tikz}     \usetikzlibrary{positioning, arrows}     \usetikzlibrary{external}          \begin{document}          \begin{tikzpicture}     \begin{axis}[%     width=4.30216535433071in,     height=3.3931594488189in,     scale only axis,     xmin=0,     xmax=12,     xlabel={x},     ymin=9000,     ymax=17000,     ylabel={y}     ]     \addplot [color=blue,only marks,mark=*,mark options={solid},forget plot]      plot [error bars/.cd, y dir = both, y explicit]      table[row sep=crcr, y error plus index=2, y error minus index=3]{1.84  16218   134.776481295696    134.776481295696\\     3.68    14575   127.048609378389    127.048609378389\\     5.52    13049   119.621537352246    119.621537352246\\     7.36    11775   113.088768071349    113.088768071349\\     9.2 10533   106.531395413076    106.531395413076\\     11.04   9374    100.152475255634    100.152475255634\\     };     \addplot [color=red,solid,forget plot]       table[row sep=crcr]{1.84  16243.611047826\\     3.68    14567.6214518194\\     5.52    13064.55775989\\     7.36    11716.5777560882\\     9.2 10507.6801555369\\     11.04   9423.51466013115\\     };     \end{axis}     \end{tikzpicture}     \end{document}


title: Calculating a common height for nodes with different amounts of text in Tikz

text: When using labelled nodes (e.g. for a flow chart), their sizes are automatically chosen. One can enforce the same size, which must be known a priori, for multiple nodes by using "large enough" values for `minimum height` and `minimum width`. In the following example the node width is restricted for spacial reasons. This leads to the boxes containing different numbers of lines and therefore different box sizes.                   \documentclass{beamer}         \usepackage{tikz}         \usetikzlibrary{positioning}              \begin{document}         \begin{frame}         \begin{tikzpicture}[node distance=2cm]             \node[rectangle,text width=5em,draw=black] (leftnode) {Short text};             \node[rectangle,text width=5em,draw=black,right=of leftnode] (rightnode) {A text longer than the other one};         \end{tikzpicture}         \end{frame}         \end{document}      Given two strings, that shall be written in two separate nodes of equal size: Is it possible to let LaTeX calculate the minimal node height that is large enough for both cases and use it as a parameter for the nodes?


title: Bluebook support in Latex?

text: I need to write a paper conforming with the blue book standards. Has there been any move on creating packages that support blue book-style formatting and citations? Or should I get ready to do a bunch of work on my own `bibtex` and `article` classes? If the latter, are there modern alternatives to `bibtex`? Are there any specific modern approaches to customised article classes?


title: Hyperref to external pdf that will open at particular label

text: Suppose you have a tex file (lets call it B) with some labels, and another one file (call it A) , xr package will allow us to make hyperref from A->B , but I previously found couple cases (I don't know if that done by LaTeX) in which clicking on the link that in file A , will automatically open the file B (if they was in the same directory) and jump to the particular label in that file B, is that possible to be done somehow in LaTeX ? P.S-1 Currently if we do that external ref. clicking on the link will only jump to the begening of the current file (I mean file A) and will not open anything (unless I'm doing something wrong) P.S-2 In other question I get this answer: > There is a recent post on the LyX users mailing list about this. It has no > answer yet, but you could watch it and see if anything pops up. mail- > archive.com/lyx-users@lists.lyx.org/msg93271.html – Torbjørn T. But that corespondance is very old (back to 2010) , are there is any difference?


title: Continue previous Roman page numbering after changing to Arabic

text: what I want to achieve is this continuous numbering with roman numbers: I, II, III, 1, 2, 3, n, IV, V But using:               \pagenumbering{Roman}      \pagenumbering{Arabic}     \pagenumbering{Roman}      Returns this: I, II, III, 1, 2, 3, n, I, II, III Help please!


title: Placing a line of typographic ornaments on page top with class memoir

text: Based on the utilities provided by the class `memoir`, I'd like to set a line of typographer's ornaments along the page top of a custom size stock paper (actually, along the four page edges, but my question refers only to the top edge). In order to do so, I thought of setting the baseline of my header right at the very top of the page by declaring a 0pt head height and a 0pt head drop -- terms introduced in the class documentation --, but for some reason I end up with a distance from the top of the page to the baseline of the header which amounts to my font's declared normalsize (in the MWE below, this is 11pt). What am I doing wrong?               \documentclass[11pt]{memoir}          \usepackage{calc,pstricks}          \setstocksize{20cm}{20cm}     \settrimmedsize{\stockheight}{\stockwidth}{*}     \setlrmarginsandblock{\paperwidth * 1/10}{*}{1}     \setulmarginsandblock{4\baselineskip}{3\baselineskip}{*}       \setheadfoot{0pt}{3\baselineskip}     \setheaderspaces{0pt}{*}{*}     \checkandfixthelayout          \setlength{\headwidth}{\paperwidth}     \makepagestyle{mainpage}     \makerunningwidth{mainpage}{\headwidth}     \makeheadposition{mainpage}{}{}{}{}     \makepsmarks{mainpage}{%     \nouppercaseheads     \makeoddhead{mainpage}{\rput[tl]{0}(0,0){Hello}}{}{}     \makeoddfoot{mainpage}{}{}{}     \makeevenhead{mainpage}{}{}{}     \makeevenfoot{mainpage}{}{}{}     }     \pagestyle{mainpage}          \begin{document}     Testing document     \end{document}       In the MWE above, the command `\rput` from `PSTricks` is used only to type the top left-hand corner of the box containing the header text ("Hello") on the header baseline.


title: libertineotf and xelatex - bold smallcaps broken?

text: It seems like bold smallcaps don't work with `libertineotf` any longer? I am currently adjusting an old template which I was using with `pdflatex`, and I need those bold small caps:               \documentclass{standalone}          \usepackage{libertineotf}          \begin{document}     \huge     Test          \bfseries     Test          \scshape     Test          \end{document}


title: includeonly command does not modify TOC

text: I have written 2 chapters an 1 appendix, and I would like to have 2 version of this book. So I use `\includeonly` in order to include only chapter 1 and 2, but the `TOC` also shows the appendix name. Probably, this is the natural behavior of `\includeonly`, but how can I do this? I mean, in the short version I just want to print the chapters 1 and 2 (including the `TOC`), and in long version to print everything.


title: How to create whitespace in LaTeX?

text: I'm trying to create a LaTeX document with several blocks of source code included. Between these blocks of code I want to add in a few lines of whitespace. I have tried using `\\` however this didn't work. Here is what I have at the moment...               \lstset{language=Java, caption=ClassA.java}     \begin{lstlisting}         % My code     \end{lstlisting}          \\ % This is where I want to make some whitespace          \lstset{language=Java, caption=ClassB.java}     \begin{lstlisting}         % My code     \end{lstlisting}


title: Theorem content right after theorem name in beamer

text: When we write a theorem in beamer, by default the theorem name and theorem content are in different lines, like this:               |-------------------------------------------     |Theorem 1     |-------------------------------------------     |Some theorem content.     |-------------------------------------------      How to make the theorem name and theorem content show in the same line? like this:               |---------------------------------------------     |Theorem 1: Some theorem content.     |---------------------------------------------


title: biblatex supercite wikipedia style with postnotes as footnotes

text: What i want to achieve is a wikipedia style citation (like so Biblatex supercite command with use of square brackets (like a reference style in Wikipedia) ). At the same time (to handle the problem with add. postnote information) i'd like to to have postnotes i passed along to be added as footnotes. A very nice code snippet for `\supercite` with footnotes has been posted: Biblatex cite with footnote only once, with use of brackets. So how can i extend the first code snippet to pass postnote arguments to footnotes (in a style that resembles the second code snippet)?


title: Multiply define a label on purpose

text: I'm working on a document that needs to have a cross-reference section at the start of the style: >   1. Evidence 1 found in Paragraph 1.1, 1.2, 1.3 >   2. Evidence 2 found in Paragraph 1.2, 2.3, 3.4 > etc I have my document formatted well, and can refer to individual paragraphs exactly as I wish using `\label` and `\ref`. However, I wish to be able to define a label multiple times so that when `\ref` is called it prints a list of all the labels - not just the last one (as is done currently). I've looked at using index for this, but can't seem to get it to work in its simplist format, let alone with custom outputs. Is there anyway to allow `\label` to be defined multiple times?


title: Image Dropping Down in MultiRow Table

text: I am trying to build a table of images in Latex. Two of my images are portrait, two are landscape. My end goal, is to have them look like this:               |   | B |   |     | A |---| D |     |   | C |   |      With my code being:               \begin{tabular}{|c|c|c|}          \multirow{2}{*}{\includegraphics[width=0.25\textwidth]{./2_ACES/images/widiStructures/h_back.eps}} & \includegraphics[width=0.25\textwidth]{./2_ACES/images/widiStructures/h_side.eps} & \multirow{2}{*}{\includegraphics[width=0.25\textwidth]{./2_ACES/images/widiStructures/h_front.eps}} \\     & \includegraphics[width=0.25\textwidth]{./2_ACES/images/widiStructures/h_side2.eps} & \\ \hline          \end{tabular}      However, the end result of my table is               |   | B |   |     |   |---|   |     | A | C | D |       A       D      Where the A and D image drop below the bottom of the table!


title: Individual/manual page numbers for table of contents

text: Question answered Example:               \documentclass[12pt]{article}     \setcounter{secnumdepth}{5}     \setcounter{tocdepth}{5}     \usepackage{tocloft}          \begin{document}          \tableofcontents     \newpage          \part{List of Figures} %(required page number "i")     \part{List of Tables}  %(required page number "ii")     \part{Abbreviations}   %(required page number "iii")     \part{Declaration}     %(required page number "iv")          \section{Introdution}                \subsection{Start}   %(required page number "1")     \subsection{Start2}      %(required page number "3")     \subsection{Start 3} %(required page number "5")     \subsection{Start 4} %(required page number "8")          \section{Literature Review} %(required page number "10")          \subsection{Focal theories} %(required page number "10")          \subsubsection{Theorie 1} %(required page number "11")          \paragraph{Theorie 1a} %(required page number "11")     \paragrap{Theorie 1b} %(required page number "25")     \paragraph{Theorie 1c} %(required page number "28")          \end{document}


title: Which constructs in TeX/LaTeX and their packages have classification \mathinner?

text: **Which constructs in (La)TeX and (La)TeX packages have classification`\mathinner`?** The TeXbook mentions:   * fractions   * `\left...\right` constructions   * `\ldots`, `\cdots`, `\ddots` Which fractions - all? Do other frequently used packages (e.g. AMS-LaTeX) define other constructs (e.g. I'm assuming all types of triple dots in AMS- LaTeX)? One might expect the following to generate `\mathinner`, but they don't:   * `\bigl...\bigr` (and the larger-size analogues)   * `\lvert...\rvert`


title: Spacing after derivative operator in the commath package

text: I am using the `commath` package to typeset the derivative operator "D" with the command `\Dif`. This work well _unless_ I want to add subscripts or superscripts. In this case, the spacing after operator is too small and the exponent / index "touches" the operator: ![enter image description here](http://i.stack.imgur.com/STq8y.png) where the first operator is created via `\Dif` and the second one via `\mathrm{D}` (full MWE see below). Is there some way to "redefine" the `\Dif` command in order to fix the spacing? * * *               \documentclass{article}     \usepackage{commath}          \begin{document}          \begin{align*}       \Dif^2_x f(x) \\       \mathrm{D}^2_x f(x)     \end{align*}          \end{document}


title: Forcing case in table

text: I was wondering if it was possible to force the case for a specific column in a table? Let's say the 3rd column of the following table to be lowercase.               \documentclass[10pt,a4paper]{article}     \usepackage[utf8]{inputenc}     \usepackage{amsmath}     \usepackage{amsfonts}     \usepackage{amssymb}     \usepackage{graphicx}     \usepackage{longtable}     \usepackage{array}          \begin{document}          {\tiny     \begin{longtable}[1]{>{\itshape}l>{\itshape}l>{\itshape}l>{\itshape}lrr}          \caption{Summary of fish species sampled in both biogeographic provinces.} \\        \hline          \textbf{Order} & \textbf{Family} & \textbf{Genus} & \textbf{Species} & \textbf{Mean abundance (catch per unit effort)} & \textbf{Mean length (cm)} \\        \hline     Acipenseriformes & Acipenseridae & Acipenser & Brevirostrum & 3.67 & 59.90 \\         &  &  & Oxyrinchus & 2.50 & 27.81 \\         & Polyodontidae & Polyodon & Spathula & 1.50 & 14.25 \\        Anguilliformes & Anguillidae & Anguilla & Rostrata & 1.38 & 43.64 \\         & Congridae & Conger & Oceanicus & 1.00 & 20.10 \\        Atheriniformes & Atherinopsidae & Membras & Martinica & 12.33 & 6.69 \\         &  & Menidia & Menidia & 2.50 & 6.72 \\        Aulopiformes & Synodontidae & Synodus & Foetens & 1.90 & 15.92 \\        Batrachoidiformes & Batrachoididae & Opsanus & Beta & 2.58 & 15.30 \\         &  &  & Pardus & 1.50 & 16.52 \\         &  &  & Tau & 4.05 & 19.29 \\         &  & Porichthys & Plectrodon & 1.20 & 28.51 \\        Beloniformes & Belonidae & Strongylura & Marina & 6.00 & 20.15 \\        Carcharhiniformes & Carcharhinidae & Carcharhinus & Isodon & 1.00 & 38.00 \\         &  &  & Limbatus & 1.00 & 39.20 \\         &  &  & Porosus & 1.00 & 50.50 \\         & Sphyrnidae & Sphyrna & Tiburo & 1.00 & 37.47 \\         & Triakidae & Mustelus & Canis & 4.67 & 53.95 \\        Clupeiformes & Clupeidae & Alosa & Aestivalis & 3.62 & 7.95 \\         &  &  & Pseudoharengus & 6.38 & 7.35 \\         &  &  & Sapidissima & 7.33 & 10.43 \\         &  & Brevoortia & Gunteri & 35.17 & 7.99 \\         &  &  & Patronus & 20.81 & 8.79 \\         &  &  & Smithi & 1.00 & 12.20 \\         &  &  & Tyrannus & 5.69 & 13.19 \\         &  & Clupea & Harengus & 21.11 & 10.08 \\         &  & Dorosoma & Cepedianum & 14.26 & 16.91 \\         &  &  & Petenense & 11.85 & 10.37 \\         &  & Etrumeus & Teres & 1.00 & 20.00 \\         &  & Harengula & Jaguana & 2.47 & 9.70 \\         &  & Opisthonema & Oglinum & 2.22 & 8.46 \\         &  & Sardinella & Aurita & 3.00 & 13.07 \\         & Engraulidae & Anchoa & Hepsetus & 8.66 & 6.81 \\         &  &  & Mitchilli & 14.00 & 5.12 \\        Cypriniformes & Catostomidae & Carpiodes & Cyprinus & 12.00 & 38.84 \\         &  & Catostomus & Commersoni & 2.00 & 22.07 \\         &  & Moxostoma & Macrolepidotum & 1.00 & 37.40 \\         & Cyprinidae & Carassius & Auratus & 2.50 & 26.49 \\         &  & Cyprinus & Carpio & 2.83 & 57.31 \\         &  & Notemigonus & Crysoleucas & 2.00 & 14.00 \\         &  & Notropis & Atherinoides & 10.00 & 9.71 \\         &  &  & Hudsonius & 2.67 & 8.17 \\        Cyprinodontiformes & Fundulidae & Fundulus & Grandis & 14.00 & 9.95 \\        Elopiformes & Elopidae & Elops & Saurus & 1.14 & 21.20 \\        Gadiformes & Gadidae & Microgadus & Tomcod & 10.30 & 9.41 \\         &  & Pollachius & Virens & 1.00 & 13.10 \\         & Lotidae & Enchelyopus & Cimbrius & 1.50 & 21.48 \\         & Merlucciidae & Merluccius & Bilinearis & 2.00 & 20.98 \\         & Phycidae & Urophycis & Chuss & 3.67 & 24.75 \\         &  &  & Regia & 4.62 & 21.65 \\         &  &  & Tenuis & 3.86 & 21.56 \\        Gasterosteiformes & Gasterosteidae & Gasterosteus & Aculeatus & 1.00 & 7.80 \\        Lampriformes & Trachipteridae & Desmodema & Polystictum & 1.00 & 16.95 \\        Lepisosteiformes & Lepisosteidae & Atractosteus & Spatula & 1.00 & 48.00 \\         &  & Lepisosteus & Oculatus & 1.00 & 47.00 \\         &  &  & Osseus & 4.00 & 91.18 \\        Lophiiformes & Ogcocephalidae & Ogcocephalus & Radiatus & 1.00 & 19.70 \\        Mugiliformes & Mugilidae & Mugil & Cephalus & 2.89 & 17.53 \\         &  &  & Curema & 1.57 & 12.21 \\        Ophidiiformes & Ophidiidae & Ophidion & Marginatum & 1.50 & 16.85 \\        Osmeriformes & Osmeridae & Osmerus & Mordax & 1.00 & 12.15 \\        Perciformes & Carangidae & Carangoides & Ruber & 6.00 & 6.48 \\         &  & Caranx & Crysos & 2.00 & 15.07 \\         &  &  & Hippos & 3.09 & 8.92 \\         &  &  & Latus & 2.00 & 8.91 \\         &  & Chloroscombrus & Chrysurus & 25.50 & 7.31 \\         &  & Decapterus & Punctatus & 7.00 & 13.21 \\         &  & Hemicaranx & Amblyrhynchus & 2.67 & 12.01 \\         &  & Selar & Crumenophthalmus & 7.00 & 9.40 \\         &  & Selene & Setapinnis & 1.62 & 6.00 \\         &  &  & Vomer & 2.14 & 5.60 \\         &  & Trachinotus & Carolinus & 2.00 & 9.89 \\         &  &  & Falcatus & 4.50 & 6.98 \\         & Centrarchidae & Lepomis & Gibbosus & 8.14 & 11.13 \\         &  &  & Macrochirus & 4.86 & 14.94 \\         &  &  & Microlophus & 3.00 & 10.13 \\         &  & Micropterus & Salmoides & 1.00 & 10.50 \\         &  & Pomoxis & Annularis & 1.40 & 15.12 \\         & Centropomidae & Centropomus & Undecimalis & 1.00 & 24.00 \\         & Chaetodontidae & Chaetodon & Ocellatus & 2.00 & 4.85 \\         & Ephippidae & Chaetodipterus & Faber & 3.13 & 7.47 \\         & Gerreidae & Eucinostomus & Argenteus & 3.20 & 7.03 \\         &  &  & Gula & 1.40 & 9.18 \\         &  &  & Lefroyi & 6.50 & 7.64 \\         & Gobiidae & Gobioides & Broussonneti & 1.00 & 19.60 \\         &  & Gobiosoma & Bosc & 3.00 & 3.63 \\         & Haemulidae & Haemulon & Plumieri & 9.50 & 8.96 \\         &  & Orthopristis & Chrysoptera & 7.60 & 12.00 \\         & Labridae & Halichoeres & Caudalis & 1.00 & 11.50 \\         &  & Lachnolaimus & Maximus & 5.00 & 6.80 \\         &  & Tautoga & Onitis & 10.60 & 17.06 \\         &  & Tautogolabrus & Adspersus & 4.11 & 10.22 \\         & Lutjanidae & Lutjanus & Griseus & 2.00 & 10.30 \\         &  &  & Synagris & 2.67 & 8.16 \\         \hline     \hline     \end{longtable}     }          \end{document}      Regards, Phil


title: Latex Block diagramm / draw Range

text: I want to use a Block diagram like in this document on page 9: http://texdoc.net/texmf-dist/doc/generic/pst-bar/pst-bar-docDE.pdf But I fail at doing this.   At the moment I am using this: Grouped bar chart               \definecolor{bblue}{HTML}{4F81BD}     \definecolor{rred}{HTML}{C0504D}     \definecolor{ggreen}{HTML}{9BBB59}          \begin{figure}[h]     \begin{tikzpicture}     \begin{axis}[         width  = 0.85*\textwidth,         height = 8cm,         major x tick style = transparent,         ybar=2*\pgflinewidth,         %ybar stacked,         bar width=14pt,         ymajorgrids = true,         ylabel = {Zeit in Sekunden},         symbolic x coords={lokal,1 Gerät, 2 Geräte},         xtick = data,         scaled y ticks = false,         enlarge x limits=0.25,         ymin=0,         nodes near coords,         legend cell align=left,         legend style={                 at={(1,1.05)},                 anchor=south east,                 column sep=1ex         }     ]         \addplot[style={bblue,fill=bblue,mark=none}]              coordinates {(lokal,973) (1 Gerät,1426) (2 Geräte,698)};         \addplot[style={rred,fill=rred,mark=none}]             coordinates {(lokal, 0.0) (1 Gerät,6.00) (2 Geräte,5.1)};         \addplot[style={ggreen,fill=ggreen,mark=none}]             coordinates {(lokal,52) (1 Gerät,276) (2 Geräte,169)};              \legend{Durchschnittliche Zeit zur Berechneung,Durchschnittliche Zeit zur Verteilung,Streuung gesamte Zeit}     \end{axis}     \end{tikzpicture}     \end{figure}      I want the diagram to be "block" style.   Alternatively I could draw a cross to show the Range of the results.   I need the horizontal line to be the average and the vertical line to be the range from minimum to maximum value. I have no idea what packages, or command I have to use, to get what I want, so any recommendation is appreciated.


title: How can I check in LaTeX (or plain TeX) whether a command exists, by name?

text: I'm looking for a LaTeX way to control macro expansion, contingent on some macro being defined or not. I'm looking for something like this (but then actually working):               \newcommand[1]{\checkfor}{       \if\isdef\csname{#1}       ... expand this if command exists ...       \else       ... expand this if command does not exist ...       \fi     }      which can then be called using               \checkfor{CommandName}      (this example is, of course, useless. The actual code I want to use this kind of expansion in is a package that dynamically creates a large number of macros from an even larger set of possible macros, with default behaviour for "all macros". Since not "all" macros may exist, I need some way to test whether a macro was declared, before I can expand based on its value).


title: Insert entry in WinEdt 8.1

text: How can I create a `Insert` menu entry for a new environment I created. For example, one can insert a figure by going to `Insert > Objects > Figure`. Of course, custom environments can be gotten by going to `Insert > Environments > New Environment` but I would like one that I can activate via a shortcut like `CTRL+ALT+E` or the like and even from the menu tab `Insert`. The result should look like the following: ![enter image description here](http://i.stack.imgur.com/d1dXg.png)


title: unescaped macros

text: Is there a way to define a macro that does not start with `\`? for example, I'd like to have `->` expand to `\rightarrow` since I like reading raw LaTeX and `$\eps -> 0$` reads much nicer (to me...) than `$\eps\rightarrow0$` or even (the solution I have now) `$\eps\goto0$`. I guess one could define `-` as an escape character and then use it to read the next character, if it is a `>` expand the whole shebang to `\rightarrow` and if not expand the `-` to a `-` and let the next character to its thing...I have no idea if what I just wrote makes any sense, nor how one would do it nor the possible pitfalls and reasons to avoid such behavior.... Ideas? Comments?


title: Longtabu total width, fixed left margin

text: I'm trying to make a `longtabu` that is wider than the `textwidth` at a certain moment. I've tried different things always ending up with a different problem: First possibility: If I use the `adjustwidth` environment the longtabu does not align correctly. The left margin stays fixed and the right margin gets out of the page. This in contrast, if I do the exact same thing to make a `tabu`(instead of `longtabu`), it works perfectly. I think using the `adjustwidth` is the best way to go, but I can't manage to get it working. Second possibility: I've found a solution using the `fullwidth` package. That package does the trick, but using endhead and endfirsthead is completely ignored. So it does not help me either, because I need that. Final possibility: Using the `geometry` package does the trick, but that package adds a pagebreak when I start using it, I can't have that. It has to be directly under some text, which has a narrower `textwidth`. Cheers. I add a little example:               \documentclass[a4paper]{article}     \usepackage{longtable}     \usepackage{chngpage}     \usepackage{lipsum}     \usepackage{tabu}          \begin{document}     \section{This is the original textwidth.}     \lipsum[1]          \section{This is the width I need for my longtabu}     \begin{adjustwidth}{-1in}{-1in}         \begin{tabu} to \linewidth {*{13}{|X[l]} |}         01 & 02 & 03 & 04 & 05 & 06 & 07 & 08 & 09 & 10 & 11 & 12 & 13 \\         01 & 02 & 03 & 04 & 05 & 06 & 07 & 08 & 09 & 10 & 11 & 12 & 13 \\         01 & 02 & 03 & 04 & 05 & 06 & 07 & 08 & 09 & 10 & 11 & 12 & 13 \\         01 & 02 & 03 & 04 & 05 & 06 & 07 & 08 & 09 & 10 & 11 & 12 & 13 \\        \end{tabu}     \end{adjustwidth}          \section{This is what happens}     \begin{adjustwidth}{-1in}{-1in}         \begin{longtabu} to \linewidth {*{13}{|X[l]} |}         01 & 02 & 03 & 04 & 05 & 06 & 07 & 08 & 09 & 10 & 11 & 12 & 13 \\         01 & 02 & 03 & 04 & 05 & 06 & 07 & 08 & 09 & 10 & 11 & 12 & 13 \\         01 & 02 & 03 & 04 & 05 & 06 & 07 & 08 & 09 & 10 & 11 & 12 & 13 \\         01 & 02 & 03 & 04 & 05 & 06 & 07 & 08 & 09 & 10 & 11 & 12 & 13 \\         \end{longtabu}     \end{adjustwidth}          \end{document}


title: Use the content of a counter in cline

text: consider the following example:               \newcounter{cnt}     \setcounter{cnt}{3}     \begin{tabular}{l|l|l|}         \cline{2-3}          a & b & c     \end{tabular}      I have a package that generates tables with a variable amount of columns. I want to use the `cline` command to draw a horizontal line that does not include the first cell The amount of cells is stored in a counter (example counter _cnt_ in the example). Is there any way I can use the content of the counter in the cline argument?


title: Correct indenting in a description environment

text: I would like to create a description enumeration which looks like the following:               keyword 1: Short Description of the keyword                A characterization of the keyword     keyword 2: Short Description of the keyword                A characterization of the keyword      As an example:               Animal 1: Lion               A lion is ...     Animal 2: Elephant               An elephant is ...      I tried the following               \begin{description}         \item[Animal1: Lion]\hfill \\         A lion is ...         \item[Animal2: Elephant]\hfill \\         An elephant is ...     \end{description}      The problem is that the text "A lion is ..." is not aligned with the word "Lion". Can you give me some advise how to create such an environment where I can give the item command a second parameter for the short description which is then correctly aligned with the characterization text? By the way I'm using the koma class scrbook.


title: How to disable the header at any page in ConTeXt?

text: I haven't written an article since I paid my attention to ConTeXt. Now it is a chance to do it. I have tried to set the header, but failed. The structure of this article is like this:               ... title ...(Line-Breaking Algorithm)     \section{...}     ...     \section{...}     ...     \section{...}     ...      My question is that how can I disable the header at page 1 but enable it other than page 1, and the header text is always `Line-Breaking Algorithm` ?


title: Extra large gap in article where figure code is, even though figure is at top of page

text: I writing an article using the `amsart` document class and whenever I use `\begin{figure}...\end{figure}` to put a figure into the article, it places the figure at the top of the page (which is fine), but leaves an extra space between the paragraphs. To be more specific:               Paragraph zero text...     Paragraph one text...     begin{figure}...\end{figure}     Paragraph two text...     Paragraph three text...      Produces:               Figure     Paragraph zero text...     Paragraph one text...          Paragraph two text...     Paragraph three text...      When I intend to have the paragraphs follow the same spacing as the others:               Figure     Paragraph zero text...     Paragraph one text...     Paragraph two text...     Paragraph three text...      Is there a way to adjust the document setting so that that extra space does not appear? **Edit: Preamble and specific code:**               \documentclass[reqno]{amsart}     \usepackage{amssymb,latexsym}     \usepackage{graphicx}     \usepackage{setspace}     \usepackage{cite}     \usepackage{fullpage}     \usepackage{subfig}     \captionsetup[subfigure]{margin=0pt, parskip=0pt, hangindent=0pt, indention=0pt, labelformat=parens, labelfont=rm}     \newtheorem{theorem}{Theorem}     \newtheorem{lemma}{Lemma}     \newtheorem{definition}{Definition}     \newtheorem{notation}{Notation}     \linespread{1.6}     \begin{document}     ...vertices arranged in a circle, one of Dante's favorite Euclidean shapes.           \begin{center}     \begin{figure}     \includegraphics[width=5.5in,height=5.5in]{graphn33}      \caption{A complete graph with 33 people in heaven, $K_{33}$.}     \label{fig:graphn33}      \end{figure}     \end{center}          This highly mathematical object displays...     \end{document}      If I don't have the spacing between the figure code and the paragraphs, the gap still remains but the paragraphs don't indent properly.


title: How does \fontsize{}{} work?

text: With the package `anyfontsize` I can use the command `\fontsize{}{}`. But the second argument seems to be without any effect. I read there that it is related to the line space. It doesn't work.               \documentclass{article}     \usepackage{anyfontsize}     \begin{document}          {\fontsize{1cm}{1cm}\selectfont First test : I need to put some text here.}          \bigskip          {\fontsize{1cm}{2cm}\selectfont Second test : I need to put some text here --- does it work?}          \end{document}      ![enter image description here](http://i.stack.imgur.com/KwHPj.png) **Any clue?**


title: How can I turn off margin notes in a LaTeX article?

text: I want to use LaTeX for typesetting astrology charts, and won't need to use any margin notes. What's the best way to disable margin notes so I can have the space for wheel charts?


title: xstring test for numbers within a range

text: I'm working on a document command that has a variety of optional arguments for different results. I need to add an option that yields 'true' for an optional argument within a range of numbers, for example 100-200. The command is as follows (MWE):               \documentclass{article}     \usepackage{xparse,xstring,xspace}          \NewDocumentCommand{\Foo}{ o }{%         \IfNoValueTF{#1} {%         \emph{Foo}\xspace}{%             \IfBeginWith{#1}%             {b}{\emph{Foo} Bar\xspace}{%                 \IfStrEqCase{#1}{%                     {f}{\emph{Foo}\xspace}%                     }%                     [\emph{Foo}~#1\xspace]%                 }%             }%         }          \begin{document}          \Foo          \Foo[b]          \Foo[3]          \end{document}      xstring does not appear to have a range option.


title: Author list goes outside margins in the ACM SIGCHI template

text: For some reason having 4 authors in this ACM SIGCHI template renders it outside the right margin. See more details and image here. I suspect the problem is with .cls but I have no idea where to start. Here are the relevant lines in the .tex source:               \numberofauthors{4}     \author{       \alignauthor Aaaaa Aaaaaaa\\         \affaddr{Affiliation}\\         \affaddr{Affiliation}\\         \email{author@a.com}       \alignauthor Bbbbbbb Bbbbbb\\         \affaddr{Affiliation}\\         \affaddr{Affiliation}\\         \email{author@b.com}       \alignauthor Cccccc Cccccc\\         \affaddr{Affiliation}\\         \affaddr{Affiliation}\\         \email{author@c.com}       \alignauthor Ddddddd Dddddddd\\         \affaddr{Affiliation}\\         \affaddr{Affiliation}\\         \email{author@d.com}     }          \maketitle


title: \pstree and crossed branches

text: Still a TeX newbie. I'm working with PSTricks pstree, and wish a tree whose branches cross:                       I            / \           G   H          / \ / \         F   /   E        / \ / \        /   /   \       /   / \   \      A   B   C   D       If it's not clear from the ASCII picture,               F -> A C     G -> F D     H -> B E          A < B < C < D.      My usual tree code looks like:               \pstree{ I }{       \pstree{ G }{ ... }       \pstree{ H }{ ... }     }


title: caption ruining figure placement in minipage

text: I have tiny problem. I'm using minipage to put two pictures side by side in a two column article. The code is               \begin{figure*}     \centering     \begin{minipage}[b]{.49\textwidth}     \includegraphics[clip,scale=0.32]{Graph1}     \caption{Ovisnost savijenosti šipke $\lambda$ o primjenjenoj sili $F$.}     \label{fig:graph1}     \end{minipage}\hfill     \begin{minipage}[b]{.49\textwidth}     \includegraphics[clip,scale=0.32]{Graph2}     \caption{Logaritamski graf ovisnosti savijenosti $\lambda$ o primjenjenoj sili $F$.}     \label{fig:graph2}     \end{minipage}     \end{figure*}      And the output is ![image](http://i.stack.imgur.com/0X6XZ.png) I have set the captions to small               \usepackage[font={small}]{caption}      The problem is that the captions are aligned, and not the pictures! And ofc I need the pictures to be aligned... So how can I correct this problem? I was thinking of adding a blank character or sth like that, in the first caption so that they would align, but I have no luck with that... Any help is appreciated...


title: List of url-links with \href

text: When trying to create a list of weblinks using               \documentclass{report}      \usepackage{hyperref}           \begin{document}            \begin{itemize}     \item \href{www.washingtonpost.com}     \item \href{www.newyorktimes.com}     \item \href{www.lemonde.fr}     \item \href{www.guardian.co.uk}     \item \href{www.spiegel.de}     \item \href{www.bbc.co.uk/news}     \end{itemize}          \end{document}      I run into an error stating `\pdfendlink cannot be used in vertical mode`. What is a better approach to achieve this, or how can I modify mine?


title: How to generate pdf without any Type3 fonts?

text: For a publisher I have to generate a pdf file which does not contain any Type3 fonts. Until now I thought that using `pdflatex` on current LaTeX distributions should be enough to get a pdf file without any Type3 fonts, but for the current document this is not true:               $ pdffonts paper.pdf     name                                 type              emb sub uni object ID     ------------------------------------ ----------------- --- --- --- ---------     ZFUCHW+NimbusRomNo9L-Medi            Type 1            yes yes no      41  0     VNQOQC+NimbusRomNo9L-Regu            Type 1            yes yes no      42  0     [none]                               Type 3            yes no  no      43  0     NXAFJF+NimbusRomNo9L-ReguItal        Type 1            yes yes no      46  0     CBNMRR+NimbusRomNo9L-MediItal        Type 1            yes yes no      48  0     MNSAJN+NimbusRomNo9L-Regu-Slant_167  Type 1            yes yes no      52  0     FJTKHV+CMSY7                         Type 1            yes yes no      53  0     VVITQE+CMMI9                         Type 1            yes yes no      54  0     CHSHRJ+CMR9                          Type 1            yes yes no      56  0     EAPUQB+CMR6                          Type 1            yes yes no      57  0     KBHVYI+CMMI6                         Type 1            yes yes no      58  0     EHULJT+CMTI9                         Type 1            yes yes no      59  0     JLLCEK+CMSY9                         Type 1            yes yes no      61  0     YEIEPQ+CMEX9                         Type 1            yes yes no      64  0     DFKMIY+CMSY8                         Type 1            yes yes no      84  0     NEDAGG+CMSY6                         Type 1            yes yes no      87  0     QDTWCG+MSBM10                        Type 1            yes yes no     127  0     [none]                               Type 3            yes no  no     198  0     OKAOPP+CMMI8                         Type 1            yes yes no     199  0     TIGOKK+CMR8                          Type 1            yes yes no     200  0     GWSFMB+CMTI8                         Type 1            yes yes no     201  0     [none]                               Type 3            yes no  no     397  0      I am surprised that all the Type3 fonts haven't a real name. The document uses the `sigplanconf` documentclass. For figures only the `tikz` and `listings` packages are used (no graphicx package is used, i.e. no `\includegraphics` is used and no postscript files are embedded). I am using Ubuntu 10.04 with TeX Live:               $ pdflatex --version     pdfTeX 3.1415926-1.40.10-2.2 (TeX Live 2009/Debian)      I have found an ACM FAQ about Type1 fonts, but it seems to be outdated and the suggested method still yield pdf files with Type3 fonts. **pk fonts:** Looking for `pk` fonts in the doc.log find I found this ouput:                75i,27n,56p,866b,2711s stack positions out of 5000i,500n,10000p,200000b,50000s      </mnt/max/.texmf-var/fonts/pk/ljfour/jknappen/ec/ectt0800.600pk> </mnt/max/.texmf-var/fonts      /pk/ljfour/jknappen/ec/ectt0900.600pk>{/usr/share/texmf-texlive/fonts/enc/dvips/base/8r.enc}       </mnt/max/.texmf-var/fonts/pk/ljfour/jknappen/ec/ecss0900.600pk>      What could be reasons for this? Is some font package missing? Or has it something to do with tikz?


title: How to position the reference fields line in scrlttr2

text: TeX newbie. I want to position the reference fields line in scrlttr2 to where the "supplemental data" is usually displayed (in the top right hand corner, below the header). I figured it would be as easy as               \makeatletter     \@setplength{refvpos}{\useplength{locvpos}}     \@setplength{refhpos}{\useplength{lochpos}}     \@setplength{refwidth}{\useplength{locwidth}}     \makeatother      but that doesn't work, the reference field line is rendered right at the top of the document. Any help would be greatly appreciated! I'm working on an invoice template.


title: How to insert an image with transparent background into PDF?

text: I set the background of my PDF reader to be light green in order to describe my question. I want to insert an image into the PDF using LaTeX and hope the inserted image become part of the PDF file. Just like this figure: ![enter image description here](http://i.stack.imgur.com/UG21M.png) However, I used the `graphicx` package and inserted one image (EPS figure) into the PDF. The result looks like this: ![enter image description here](http://i.stack.imgur.com/kJ9wg.png) How can I insert an image into a PDF file in LaTeX like the first figure? This is not `transparency`. It is a SVG problem.


title: Nomencl: how to remove indentation in two columns multiline entries

text: I'm using the `nomencl` package to write a two columns list of terms I frequently use in my thesis. Everything looks fine except that I don't like that whenever the explanation of a term takes more than one line a small indentation is inserted. What I have now is something that looks like:               MyTerm detailed explanation of my term.        and here follows the second line.      I'd like to have is so that it looks like:               MyTerm detailed explanation of my term.     and here follows the second line.      Can someone please help me? I've tried to go through the documentation of the package but I couldn't really get much out of it!


title: How can I know if a node is already defined?

text: I think I've seen this question before, but I can't find it. The problem is simple; before I assign a name to a node I would like to know if the name is already used. I think when a node is created `\node (name) {label};` some macros are defined from `name`.


title: Beamer animation misplaced in handout mode

text: While making slides for presentation involving `animateinline` environment from `animate` package, all slides are fine as expected in normal/presentation node, as shown below: ![enter image description here](http://i.stack.imgur.com/zQgwx.jpg) But I came across a problem when converting the slides into handout. As you can see in the output below, the animation is not in the correct place. (System: WinEdt on Windows Vista) ![enter image description here](http://i.stack.imgur.com/K9TRX.jpg) Any suggestions? Did I miss something in the process? MWE Code               \documentclass[12pt,handout]{beamer}      \usepackage{tikz}     \usepackage{animate,pgfpages}     \usetheme[secheader]{Boadilla}     \setbeamertemplate{navigation symbols}{}     \setbeamerfont*{frametitle}{size=\normalsize,series=\bfseries}     %\pgfpagesuselayout{4 on 1}[a4paper,border shrink=5mm]  % activate this line to show handout mode.               \begin{document}          \begin{frame}     \begin{columns}     \column{0.45\columnwidth}          Some text here on the left and an animation on the right for beamer presentation. The result is as expected.     However, when handout mode is used for 4 on 1 handout, then the animation does not stay on the right, but somewhere else.          \column{0.45\columnwidth}     \begin{animateinline}[poster=first,controls]{8}%       \multiframe{10}{rt=0+.1,icount=0+1}        {\fbox{\parbox{\columnwidth}{an animation shows here}}        }     \end{animateinline}          \end{columns}     \end{frame}     \end{document}


title: subsequent macro detection

text: I would like to detect subsequent macros, in order to insert superscript numbers. If two macros follow each other, a comma should be inserted in between. The minimal example (stripped of the useful stuff to make it minimal):               \documentclass{article}          \usepackage{xparse}          \providecommand*{\multiplefootnotemarker}{3sp}          \NewDocumentCommand \marker { } {%     \kern-\multiplefootnotemarker%     \kern\multiplefootnotemarker\relax%     }          \NewDocumentCommand \checker { } {%     \ifdim\lastkern=\multiplefootnotemarker\relax%           \textsuperscript{,}%     \fi%     }          \NewDocumentCommand \fullcite { m } {%     #1%     }          \NewDocumentCommand \margincite { m } {%     \sidenote{\fullcite{#1}}%     }          \NewDocumentCommand \sidenote { m } {%     \sidenotemark%     \sidenotetext{#1}%     }          \NewDocumentCommand \sidenotemark { } {%     \checker%     \textsuperscript{1}%     \marker%     }          \NewDocumentCommand \sidenotetext { m } {%     \marginpar{#1}%     \marker     }          \begin{document}     1 Text\sidenote{one}\sidenote{two}          2 Text\sidenote{one}\margincite{two}          3 Text\sidenote{one}\sidenotemark          4 Text\sidenotemark text\sidenotetext{one}\sidenotemark          \end{document}      However, the solution is borrowed from the `footmisc` package and some people might call it a hack. It becomes obvious when looking at the following example:               \documentclass{book}          \usepackage[multiple]{footmisc}          \begin{document}     Text\footnotemark text\footnotetext{one}\footnotemark     \end{document}      Which leads to ![footmisc](http://i.stack.imgur.com/Eni9L.png) My previous solution was based on `\ifnextchar\sidenote` constructions, which were described by Clemens Niederberger _I didn’t like some smaller things (not bugs) done by the sidenotes package such as inserting kerns and superscripted commas for multiple marks. I prefer to let my fnpct9 package handle these things_ This made me review my options. Also, `\ifnextchar` has to be inserted in every macro that is added such as `\margincite` and it does not allow user defined macros including the sidenote ones. `fnpct` has a solution by allowing several arguments: `\sidenote{aaa;bbb}` would print two notes. It does not work (well) if references are put in the game.               \sidenote{aaa;\fullcite{citekey};ccc}      does not seem right from a user perspective. Is any of the three solutions preferred? Is there another way to reliably detect subsequent macros?