title: Connecting line calculations with fitting node in 3D tikz?

text: Consider the following MWE:               \documentclass{standalone}          \usepackage{tikz}     \usetikzlibrary{calc}     \usetikzlibrary{positioning}     \usetikzlibrary{fit}     \usetikzlibrary{3d}          \makeatletter     \tikzset{       fitting node/.style={         inner sep=0pt,         fill=none,         draw=none,         reset transform,         fit={(\pgf@pathminx,\pgf@pathminy) (\pgf@pathmaxx,\pgf@pathmaxy)}       },       reset transform/.code={\pgftransformreset},     }     \makeatother     \tikzstyle{dr} = [draw, rectangle, line width=1pt, font=\Huge, align=left]     \tikzstyle{cl} = [>=latex,->,line width=1pt]          \begin{document}     \begin{tikzpicture}[     %   x={(0.5cm,0.5cm)}, y={(1cm,0cm)}, z={(0cm,1cm)},     %   every node/.append style={transform shape},     ]          \draw[very thick] (0,0) rectangle (18,8) node[fitting node] (starter) {};          \begin{scope}[       shift={(1,1)},     %   canvas is yx plane at z=0.25,     ]     \node[dr] (NodeA) at (1,5) {Node A};     \draw[dr] (4.5,2.5) rectangle (11,6.5) node [fitting node] (NodeB) {Node B\\Slightly bigger};     \node[dr] (NodeC) [above=10pt of NodeB.south, anchor=south] {Node C};          \draw[cl] (NodeA) -- (NodeB);     \draw[cl] (NodeA) |- ($(NodeB.north west)-(10pt,10pt)$) -- ($(NodeB.south west)-(10pt,7.5pt)$) -| ($(NodeC.south west)+(10pt,0)$);          \end{scope}     \end{tikzpicture}     \end{document}      If I compile it as it is, I get the expected arrangement of nodes and connecting lines: ![test41.png](http://i.stack.imgur.com/RoUl6.png) But if I enable 3D by uncommenting the commented lines in the MWE, I get this: ![test42.png](http://i.stack.imgur.com/P7tgo.png) The NodeB text not being in perspective doesn't bother me all that much; what bothers me is that coordinates based on the NodeB fitting node rectangle do not work properly under 3D transformations (note that all is OK between "proper" nodes, e.g. the piece of the line going right into NodeC). (I'm aware that this example, in particular, can be otherwise done without the fitting node rectangle - and so problem solved; the thing is, those are quite useful for GUI editing in TikzEdt, and so I have code with a ton of these all over the place; which is why I'd rather have a solution like a fix to the "fitting node" style instead. )


title: adjustbox and includegraphics page selection

text: I want to use `adjustbox` package to include graphics in beamer presentations. I prefer it over `graphicx` because it has `max size` option which only scale when figure size is larger than certain size. But I've found a problem when I need to select a page from a multipage figure (usually made with `\documentclass[tikz]{standalone}`). When using `\includegraphics` it's possible to use `page=x` (defined in `pdftex.def`) option to select which page to be included but this option is not available in `adjustbox`. Therefore the best command I could do to include certain page from a multipage pdf file with fixed maximum size in beamer is:               \newcommand{\mygraphic}[2][]{%          \par\centering          \adjustbox{max size={\textwidth}{.9\textheight}}%             {\includegraphics[#1]{#2}}\par}      where `#1` is an optional parameter used to fix page selection when needed and `#2` is the mandatory filename. My questions are:   1. Is it possible to avoid using `includegraphics` inside `adjustbox` if I want to use `page=x` option?   2. Is it possible to fix `max size` with a general `adjustboxset` command? (I think it isn't with `export` class option but I'm not sure)


title: How to include URL to paper and presentation in bibtex?

text: I'd like to include 2 URLs in a bibtex entry: to the paper and to the presentation. I think it's common practice to have such 2 files for papers presented at conferences. Eg at this workshop I organized http://ceur- ws.org/Vol-1117/, each author gave 2 files. Is there any way to do that in Bibtex?   * This question explains how to hack splitting on ";" in latex, but such separator is not "standard".   * I'm not looking for latex hacks: I don't use latex at present, I use things like Zotero, bib2xhtml, bibtexml. Putting `\href{}` in a `note` won't work: Zotero won't grok this.   * That question explains how to a presentation (`@misc`) but I want **both** paper and presentation


title: Conference Announcement poster help

text: I have been asked to create a poster announcing a conference ( **Please note that this is not a poster presenting a topic at a conference but the announcement of the conference itself** ). I was wondering if anybody had a template lying around or knew where I might find one? The question Conference Announcement Poster addresses this question partially, unfortunately the link to the poster template (the first one, not the one in the answers) has become inactive. I would like the endproduct to be something along the lines of the posters created by the asker rather than the versions suggested by one of the repliers. Any suggestions as to the poster creation process itself are also welcomed! Thank you in advance!


title: KOMA-Script: "bad" italic in page header

text: Because of trouble with upright Greek characters, I decided to switch from latin modern to Bitstream Charter (even though I don't really like it). It seems that together with the `mathdesign` package, I'm getting the math features I need. What I'm observing after switching to Charter is that my page headings, using `scrbook`, will be typeset in a 'bad' italic font instead of the 'nice' italic font that is used in the document body. Please see the following example and have a look at the top of the second page compared to the italic text at the very end of the second page:               \documentclass{scrbook}          \usepackage{scrpage2}     \pagestyle{scrheadings}     \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage{lipsum}     \usepackage[ngerman]{babel}     \usepackage[charter]{mathdesign}          \begin{document}          \chapter{Heading}     \lipsum          For comparison:          \textit{1 Heading}          \end{document}      In the log, there are no messages about missing fonts. What did I do wrong?


title: Incorrect plot with pgfplots and LaTeX

text: > **Possible Duplicate:**   >  Incorrect plot using Pgfplots I'm trying to plot a function with pgfplots for LaTeX. Unfortunately, pgfplots plots the function incorrectly. Here is the LaTeX code I use:               \begin{figure}[H]     \centering     \begin{tikzpicture}         \begin{axis}[xlabel=Gameplays,ylabel=Rating]             \addplot+[gray,domain=1:30]             {0.5 + 0.5 * ((atan(x) * 2 / pi)^11.79)};         \end{axis}     \end{tikzpicture}     \caption{Omzetten van aantal gameplays tot impliciete rating}     \label{fig:omzetten_impliciete_ratings}     \end{figure}      Here is how the function should look like: http://i.stack.imgur.com/ilXR3.png This is how it is plotted: http://i.stack.imgur.com/9VQ5p.png Does anyone know what I do wrong?


title: keyvalue with kvoptions and switch structure

text: I am using kvoptions for a key-value syntax. However I need a switch syntax for the evaluation. Since boolexpr is problamatic (see here) I use now the other solution of this question. However the switch is not working as expected (always results in the same value). This is the code that I use:               \documentclass[]{scrbook}          \makeatletter     \RequirePackage{kvoptions-patch}     \RequirePackage{kvoptions}  % options     \RequirePackage{pdftexcmds} % string comparison          \SetupKeyvalOptions{family=demo,prefix=demo@}          % parallel, stacked     \DeclareStringOption[stacked]{style}          \ProcessKeyvalOptions{demo}          \newcommand{\PrintDemoUsingKeys}{%       \ifnum\pdf@strcmp{\demo@style}{parallel}=0%         parallel%       \else\ifnum\pdf@strcmp{\demo@style}{stacked}=0%         stacked%       \else%          \PackageError{templatedemo}{%            \MessageBreak%            value >\tplbugs@style< unkown \MessageBreak%          }{}%       \fi\fi%     }%          % Print code and result using the key-value syntax     \newcommand{\PrintDemo}[2][]{%     %  #1  is the optional keyval argument     %  #2  is a mandatory argument     \begingroup%     \setkeys{demo}{#1}%     %  Do  stuff  with  #2     \PrintDemoUsingKeys%     \endgroup%      }          \makeatother          \begin{document}     \PrintDemo{style=parallel}          \PrintDemo{style=stacked}     \end{document}


title: Table notes that are compatible with LaTeX2RTF

text: I want to create a simple table whit a few table footnotes as common in scientific journals. I've tried the package `tablefootnote` and the `threeparttable` but I can't convert them into a RTF document using LaTeX2RTF. What I want is something that looks like this table but I'm pretty certain that I have to be able to get it into Word or the journal wont accept it. The question: How do I get footnotes right under the table in a way that I can convert it into a Word-compatible format? ### UPDATE @Peter Gill's example produces this output in Word: ![The footnotes are at the bottom of the page](http://i.stack.imgur.com/Gd2z6.jpg) I use `R` for creating my tables. Most of the time I use the `Hmisc` latex() function that does a beautiful job but I've found that the ctable package and other vital packages aren't included in LaTeX2RTF and therefore I'm in trouble. I like LaTeX2RTF since it's very simple to work with but after some more websearching I found this post where the Sciweavers seems to have an implementation that handles footnotes slightly better although complex ctables seem to be an issue. I'll also try to give another try at `tex4ht` package to see if it will handle more complex solutions (how I wish that I could just send all my TeX files without any issues).


title: Cannot make latex multicolumn work

text: I am trying to make a matrix in LaTeX. Now I am trying to make a table with multicolumn like               a b c     d  у      So I coded               \usepackage{arydshln}     \usepackage{array}     \usepackage{amsmath}     \usepackage{multirow}     \begin{document}     \begin{align*}     & \hspace{0.3cm}\overbrace{\hphantom{\begin{array}{ccc}     a&b&c     \end{array}}}\\     &\left[     \begin{array}{ccc}     a&b&c\\     d&\multicolumn{2}{c}{$\phi$}\\     \end{array}     \right]     \end{align*}     \end{document}      But I cannot make the multicolumn work I've read several manuals like http://andrewjpage.com/index.php?/archives/43-Multirow-and-multicolumn- spanning-with-latex-tables.html http://cosy.comli.com/wordpress1/2009/04/08/advanced-matrix-partitioning- latex/ And some others, but it doesn't solve my problem. I am using texmaker and it error log gives some abstract errors like "`missing $ inserted`". Thank you.


title: Insert an image at the beginning of a chapter

text: I wish insert an image at the beginning of a chapter that, like in the figure attached, is seen in the white space at right of the title. Moreover, it must be different for every chapter of the book. I tried the following MWE:               \documentclass{book}     \usepackage{titlesec}     \titleformat{\chapter}[block]      {%\rule{1in}{1in}       \normalfont\huge\bfseries}       {\chaptertitlename\ \thechapter\\}       {0pt}       {\Huge}     \titlespacing*{\chapter}{0pt}{0pt}{40pt}          \begin{document}      \chapter{Example}     \end{document}      But it creates (or add) an image before the word "Chapter". ![Example](http://i.stack.imgur.com/A5z5w.jpg)


title: Numbering in SVJour document class

text: I am using the SVJour document class for a paper I am currently writing. The default numbering scheme is as follows:               Theorem 1     Corollary 1     Theorem 2     Proposition 1     Example 1     etc.      Which is completely independent of the chapter or section. I want to have:               Section 1     Proposition 1.1     Theorem 1.2     Proposition 1.3     etc.     Section 2     Proposition 2.1     Example 2.2      etc.      If I put               \newtheorem{thm}{Theorem}[section]     \newtheorem{cor}[thm]{Corollary}     \newtheorem{lem}[thm]{Lemma}     \newtheorem{prop}[thm]{Proposition}     \newtheorem{exm}[thm]{Example}     \newtheorem{deff}[thm]{Definition}      in the preamble then I almost get what I want but instead there is no dot, i.e.,               Section 1     Proposition 11     Theorem 12     Proposition 13     etc.     Section 2     Proposition 21     Example 22      etc.      Anyone know how to fix this? The SVJour user guide uses `\spnewtheorem` instead of `\newtheorem` (which I've never seen before) but it doesn't change anything.


title: tikz - command node - text

text: my MWE is:               \documentclass{book}     \usepackage{tikz}     \usetikzlibrary{intersections}     \usetikzlibrary{calc}          \begin{document}       \begin{tikzpicture}[domain=0:2*pi]          \draw[xstep=pi/4, ystep=0.5, dashed, color=gray] (-0.1,-1.6) grid (2*pi,1.6);          \draw[->] (-0.2,0) -- (7,0) node[right] {$t$};          \draw[->] (0,-2) -- (0,2) node[above] {$i(t)$};          \node[below left](0,0){$0$};         \draw[color=blue, smooth]   plot (\x,{sin(\x r)})    node[below right] {$i(t)$};          \node[below left] at (2,2) {$i(t) = I_0\sin\omega t$};       \end{tikzpicture}     \end{document}      In the last command I try to put the text `$i(t) = I_0\sin\omega t$` at coordinate (2,2), but the result does not match my expectations. Where is problem? How to insert text at a certain position without depending on previous commands? I got this image: ![enter image description here](http://i.stack.imgur.com/koAGm.png) I expected that the text `$i(t) = I_0\sin\omega t$` will be more right.


title: Typesetting limitations of LaTeX

text: What are the typesetting limitations of LaTeX? In other words what are the things that desktop publishing and word processing programs do better than LaTeX? I am not really interested in things that are better left to the editor (spell check, grammar check) or some post processing program (track changes, word count), but rather typesetting type issues. For example, LaTeX and I really struggle with suppressing page breaks and changing paragraph size. I think even MS Word can do these things better (although it is obviously much easier when you are ignoring the badness of the paragraph). Are there other things? Is there a list or a reference somewhere? **EDIT** In regards to the comment by alfC, in the bigger picture the question is what functionality is currently missing from LaTeX (and packages) that exists in other programs. Things like rivers are still difficult from a conceptual standpoint, while resizing a paragraph and preventing page breaks are easy to conceptualize (but difficult to solve).


title: Change the size of a symbol

text: I want to have the | the correct size for the situation and since I can't use \left and \right, I tried to use \large but it didn't change. Help?               \documentclass[a4paper,fleqn]{article}     \usepackage{eurosym,amsmath,amssymb,amsthm,tikz,fancyhdr,cancel,enumerate,array,booktabs,setspace,pgf,tikz,fancyhdr,graphicx,color}     \usepackage[T1]{fontenc}     \usepackage[latin1]{inputenc}     \begin{document}     \[ I(\theta)=-\E\left\lbrace\frac{d^2\ln{\left[f(X|\theta)\right]}}{d\theta^2}|\theta\right\rbrace\]     \end{document}


title: two-column lstlisting in landscape orientation

text: How can I divide my page in two to show my code with lstlisting? This is a large code and I want to set as 2 pages in one. Is an appendix of my project not all the document. **EDIT** thanks to Bordaigorl I set it to double column but when I add \landscape option this is my result: ![enter image description here](http://i.stack.imgur.com/fv1Lb.jpg)


title: Error using subequations

text: I am using `subequations`. There is no way to get a right output... I am using               \documentclass{book}     \usepackage{amsmath}     \usepackage{amssymb}     \usepackage{amsfonts}     \usepackage{amsthm}          \begin{document}          \begin{subequations}     \begin{equation}%<-----------------------<     h\nu'=\frac{h\nu}{1+\gamma(1-\cos\theta)}     \end{equation}     \begin{equation}     T=h\nu-h\nu'=h\nu \frac{\gamma(1-\cos\theta)}{1+\gamma(1-\cos\theta)}     \end{equation}     \begin{equation}     \cos\theta=1-\frac{2}{(1+\gamma)^2\tan^2\phi+1}     \end{equation}     \begin{equation}     \cot\phi=(1+\gamma)\tan\frac{\theta}{2}     \end{equation}     \end{subequations}          \end{document}      I also used `$some equations$` and `\\[some equations\\]` instead of `equation enviroment` but I can't get numbering... Any ideas? P.S.: The error occurs on line marked with arrow in aforementioned code which states: `extra \else` `Missing \endcsname inserted` `Incomplete \iffalse; all text wasignored after line67`. * * *               \documentclass[11pt,a4paper]{book}     \usepackage[english,greek]{babel}     \usepackage[iso-8859-7]{inputenc}     \usepackage{kerkis}     \usepackage{amsmath}     \usepackage{amssymb}     \usepackage{amsfonts}     \usepackage{amsthm}     \usepackage{units}     \usepackage{array}     \usepackage{framed} % ãéá ãêñé background ðßóù áðü êÜðïéá paragraphs     \usepackage{extarrows}     \usepackage{cancel}     \usepackage[pdftex]{graphicx}     %\usepackage[twoside,pdftex,total={16.4cm,24cm}, left=2.9cm, top=3.2cm, headsep=1.4cm]    {geometry}     %\usepackage[top=3.2cm, bottom=3.4cm, left=2.9cm, right=2.9cm,headsep=0.8cm]{geometry}     \usepackage[margin=2.8cm]{geometry}     %Options: Sonny, Lenny, Glenn, Conny, Rejne, Bjarne, Bjornstrup     \renewcommand\chaptername{ÊåöÜëáéï}     %\usepackage{babelbib}     %\selectbiblanguage{english}     \renewcommand\bibname{Âéâëéïãñáößá}     \usepackage[Glenn]{fncychap}     \usepackage{fancybox}     \usepackage{fancyhdr}     \usepackage{colortbl}     \usepackage{xcolor}     \usepackage{footmisc}     \usepackage{subfiles}     \usepackage{float}     \usepackage{slashbox}     \usepackage{float}     %\restylefloat{figure}     %_________________________________________________________________________________________          %\usepackage[nottoc,numbib]{tocbibind}     \usepackage{fancyhdr}          %!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!     \usepackage{tocloft}     \makeatletter     \newcommand*{\tocwithouttitle}{\@starttoc{toc}}     \makeatother     %--------------------------------------------------------------------------------     \makeatletter     \newcommand*{\lofwithouttitle}{\@starttoc{lof}}     \makeatother     %--------------------------------------------------------------------------------     \makeatletter     \newcommand*{\lotwithouttitle}{\@starttoc{lot}}     \makeatother     %--------------------------------------------------------------------------------     %!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!     \renewcommand{\cftsecleader}{\cftdotfill{\cftdotsep}}     \usepackage{hyperref}     \usepackage{subfigure}     \renewcommand{\labelitemi}{$\circ$}     \usepackage{wrapfig}     \usepackage{color}     %\usepackage[usenames,dvipsnames]{color}     \definecolor{Darkgreen}{rgb}{0,0.4,0}     \definecolor{Darkblue}{rgb}{0,0,0.4}     \newcommand{\HRule}{\rule{\linewidth}{0.8mm}}     \usepackage{rotating}     %\usepackage[landscape]{geometry}     \usepackage{lscape}     \usepackage{cancel}     \usepackage{fancyvrb}     %\usepackage{yannisgr}     \usepackage{listings}     %\lstset{ %     %language=matlab,                % choose the language of the code     %basicstyle=\footnotesize,       % the size of the fonts that are used for the code     %numbers=left,                   % where to put the line-numbers     %numberstyle=\footnotesize,      % the size of the fonts that are used for the line-    numbers     %stepnumber=1,                   % the step between two line-numbers. If it is 1 each     line will be numbered     %numbersep=5pt,                  % how far the line-numbers are from the code     %backgroundcolor=\color{white},  % choose the background color. You must add     \usepackage{color}     %showspaces=false,               % show spaces adding particular underscores     %showstringspaces=false,         % underline spaces within strings     %showtabs=false,                 % show tabs within strings adding particular     underscores     %frame=single,           % adds a frame around the code     %tabsize=2,          % sets default tabsize to 2 spaces     %captionpos=b,           % sets the caption-position to bottom     %breaklines=true,        % sets automatic line breaking     %breakatwhitespace=false,    % sets if automatic breaks should only happen at     whitespace     %escapeinside={\%*}{*)}          % if you want to add a comment within your code     %}     \usepackage{textcomp}     \definecolor{listinggray}{gray}{0.9}     \definecolor{lbcolor}{rgb}{0.9,0.9,0.9}     \lstset{         backgroundcolor=\color{lbcolor},         tabsize=4,     rulecolor=,     language=matlab,         basicstyle=\scriptsize,         upquote=true,         aboveskip={1.5\baselineskip},         columns=fixed,         showstringspaces=false,         extendedchars=true,         breaklines=true,         prebreak = \raisebox{0ex}[0ex][0ex]{\ensuremath{\hookleftarrow}},         frame=single,         showtabs=false,         showspaces=false,         showstringspaces=false,         identifierstyle=\ttfamily,         keywordstyle=\color[rgb]{0,0,1},         commentstyle=\color[rgb]{0.133,0.545,0.133},         stringstyle=\color[rgb]{0.627,0.126,0.941},     }     \usepackage{pifont}     \usepackage{subfiles}          %_________________________________________________________________________________________               \definecolor{mygray}{gray}{.75}%{.9, .9, .9}     \definecolor{lightgray}{gray}{.8}%{.9, .9, .9}     \definecolor{shadecolor}{gray}{.90} %gia framed package     %\definecolor{mygray}{rgb}{.9, .9, .9} %enallaktika !! anti gia panw     \newcommand*\mygraybox[1]{\colorbox{mygray}{\hspace{1em}#1\hspace{1em}}}          %\renewcommand{\topfraction}{0.85}%gia na min uparxoun 2 figures se mia selida kai     tipota allo     \renewcommand{\textfraction}{0.1}     \renewcommand{\floatpagefraction}{0.75}          \newcommand{\kai}{\quad \text{êáé} \quad}     \newcommand{\kkai}{\qquad \text{êáé} \qquad}          \linespread{1.1}     \newcommand{\sw}{\selectlanguage{english}}     \newcommand{\sq}{\selectlanguage{greek}}     \newcommand{\eng}[1]{\latintext#1\greektext}     \newcommand{\gre}[1]{\greektext\latintext#1}     \newcolumntype{C}[1]{>{\centering\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}          \begin{comment}   %ÁõôÜ ãéá âéâëßï     \let\origdoublepage\cleardoublepage  %áõôá åéíáé ãéá íá áöçíåé åíôåëùò êåíç óåëéäá     ìåôáîõ êåöáëáéùí     \newcommand{\clearemptydoublepage}{%       \clearpage       {\pagestyle{empty}\origdoublepage}%     }     \let\cleardoublepage\clearemptydoublepage               \pagestyle{fancy}     \fancyhead{}     \renewcommand{\chaptermark}[1]{\markboth{#1}{}}     \renewcommand{\sectionmark}[1]{\markright{\thesection\ #1}}     \fancyhf{} % delete current setting for header and footer     \fancyhead[LE,RO]{\bfseries\thepage}     \fancyhead[LO]{\rightmark}     \fancyhead[RE]{\leftmark}     \renewcommand{\headrulewidth}{0.5pt}     \renewcommand{\footrulewidth}{0pt}     \addtolength{\headheight}{0.5pt} % make space for the rule      %Ôï ÷ù ïñßóåé 0.8 áð ôï     package     \fancypagestyle{plain}%     \fancyhead{} % get rid of headers on plain pages     \renewcommand{\headrulewidth}{0pt} % and the line}          \newtheorem{thm}{Èåþñçìá}[chapter]     \newtheorem{cor}[thm]{Ðüñéóìá}     \newtheorem{lem}[thm]{ËÞììá}     \newtheorem{parad}{ÐáñÜäåéãìá}[chapter]     \newtheorem{defgr}{Ïñéóìüò}[chapter]     \end{comment}          \parskip 3mm     \footskip = 15mm     %``````````````````````````````````````````````````````````````````     %--\texorpdfstring{$\textswab{BoSonS}$}{Bosons}--     %``````````````````````````````````````````````````````````````````


title: Set arbitrary page numbers in pdf file

text: When I am using different `\pagenumbering`s in a document, the PDF viewer shows the right page numbers, that is pages i, ii, etc... for `\pagenumbering{roman}` and 1, 2, etc... for `\pagenumbering{arabic}` for instance. I wonder if it is possible to make the PDF viewer print anything as a page number. Since using LaTeX, the only possible options for page numbering are `arabic`, `roman`, `Roman`, `alpha` and `Alpha`, my goal is to make the PDF viewer print something else than what LaTeX would print by using the command `\thepage`. To be more specific, I'd like my title page to be "numbered" by the label "Title" in the PDF viewer for instance. Thanks in advance! P.S.: I am aware my question is not very well formulated but I have troubles to exactly explain what I wish, I still hope you'll understand!


title: Centering just one line in a multi-line caption

text: There are multiple questions already answered for centering an entire caption, but my problem is that I wish to just `\centerline` or `\begin{center} ... \end{center}` just one line in a multi-line caption. For example (I am using the `\ce` package for chemistry) if I were to write the following:               \caption{In the presence of A and B, C will be generated:          \centerline{ \ce{A + B -> C}.}          }      Will just error out on me.


title: Override the spacing on the right of an in-line equation when followed by a punctuation mark

text: I set `\mathsurround` to `2pt` in order to have a bit more horizontal spacing between text and in-line equations. Is there a way to set it to `0pt` on the right whenever the in-line equation is followed by a punctuation mark? For instance, the code               Let $x=0$ and $y=1$.      is typeset as in the first line below, while I would like it to be as in the second. ![Compiled code output](http://i.stack.imgur.com/P2AyU.png) Is there a way to achieve this without having to provide every time `\hspace{-2pt}`? ## Edit: I have already considered @barbarabeeton's advice, that is, to include the punctuation before the final `$`, but some marks are typeset differently in text mode and math mode. Probably _punctuation marks_ is a bit too restrictive, as I would like to include brackets () [] {} or even the apostrophe '. In addition I would like my code to be flexible, so whenever I decide to change something I don't have to edit the whole document.


title: How can I center Flashcards vertically, but not horizontally?

text: I'm currently experimenting with flashcards (the learning technique as well as the LaTeX document class) and `flashcards` seems to be pretty nice. But I could not find an option to center my flashcards vertically, but not horizontally: ![ugly horizontal centering](http://i.stack.imgur.com/fVg0Q.png) When I have the content of the flashcards within a `theorem` environment, the horizontal centering is not there (which is good), but as you can see in the flashcard at the upper right, I don't have much space. `theorem` wastes space by putting "definition" or something similar at the top and indenting the content. # Question How can I use the flashcards document class and center vertically, but not horizontally? # MWE The following code was used to create the image from above: ## mwe.tex               \documentclass[mycards,frame]{flashcards}     \usepackage{amsmath,amssymb}% math symbols / fonts     \usepackage[utf8]{inputenc} % this is needed for umlauts     \usepackage[ngerman]{babel} % this is needed for umlauts     \usepackage[T1]{fontenc}    % this is needed for correct output of umlauts in pdf     \usepackage{enumitem}          \def\mdr{\ensuremath{\mathbb{R}}}     \DeclareMathOperator{\Bild}{Bild}          \begin{document}     \begin{flashcard}{ Tangentialebene }     {         Sei $S \subseteq \mdr^3$ eine reguläre Fläche, $s \in S$,         $F: U \rightarrow V \cap S$ eine lokale Parametrisierung um $s$         (d.~h. $s \in V$)         \[(u,v) \mapsto (x(u,v), y(u,v), z(u,v))\]         Für $p=F^{-1}(s) \in U$ sei         \[        J_F(u,v) = \begin{pmatrix}                 \frac{\partial x}{\partial u} (p) & \frac{\partial x}{\partial v} (p)\\                 \frac{\partial y}{\partial u} (p) & \frac{\partial y}{\partial v} (p)\\                 \frac{\partial z}{\partial u} (p) & \frac{\partial z}{\partial v} (p)             \end{pmatrix}\]         und $D_P F: \mdr^2 \rightarrow \mdr^3$ die durch $J_F (p)$         definierte lineare Abbildung.              Dann heißt $T_s S := \Bild(D_p F)$ die \textbf{Tangentialebene}         an $s \in S$.      }     \end{flashcard}          \begin{flashcard}{ Normalenfeld\\Fläche, orientierbare }     {         \begin{enumerate}[label=\alph*)]             \item Ein \textbf{Normalenfeld} auf der                   Fläche $S$ ist eine Abbildung $n: S \rightarrow S^2 \subseteq \mdr^3$                   mit $n(s) \in T_s S^\perp$ für jedes $s \in S$.             \item $S$ heißt \textbf{orientierbar},                   wenn es ein stetiges Normalenfeld auf $S$ gibt.         \end{enumerate}      }     \end{flashcard}          \begin{flashcard}{ Normalenkrümmung }     {         In der Situation aus XY heißt die Krümmung $\kappa_\gamma(0)$         der Kurve $\gamma$ in der Ebene $(s+ E)$ im Punkt $s$ die         \textbf{Normalenkrümmung}\footnotemark von $S$ in $s$ in Richtung         $x = \gamma'(0)$.              Man scheibt: $\kappa_\gamma(0) := \kappa_{\text{Nor}}(s, x)$      }     \end{flashcard}     \end{document}      ## mycards.cfg               \NeedsTeXFormat{LaTeX2e}[1996/12/01]     \ProvidesFile{avery5388.cfg}     \newcommand{\cardpaper}{a4paper}     \newcommand{\cardpapermode}{portrait}     \newcommand{\cardrows}{4}     \newcommand{\cardcolumns}{2}     \setlength{\cardheight}{70mm}     \setlength{\cardwidth}{100mm}     \setlength{\topoffset}{2mm}     \setlength{\oddoffset}{5mm}     \setlength{\evenoffset}{5mm}     \endinput


title: LaTeX Tables: Cell value color based on its sign / conditional cell color

text: I've a long LaTeX document with many tables. Now I want to show negative values in cell in red color. I wonder how to do globally. My MWE is below:               \documentclass{article}          \begin{document}          \begin{tabular}{ l c r }       1 & 2 & 3 \\       -4 & 5 & 6 \\       7 & 8 & -9 \\     \end{tabular}          \end{document}      **Edited** Thanks all who provided answers. From provided answers it seems that I have to make edits in my all tables which have negative values and there is no automated solution. But still I will keep this question for better solution. One more clarification, I need negative values in red not their background. Thanks


title: How to combine Hobby paths with PGF Basic Layer commands?

text: I need to combine paths that are created via the hobby package with standard `pgf` path elements, like arcs. Within the Frontend Layer this is easily done, e.g.               \documentclass{standalone}     \usepackage{tikz}     \usetikzlibrary{hobby}     \begin{document}          \begin{tikzpicture}[use Hobby shortcut]     \draw (0,0) arc[start angle=180, end angle=90, x radius=1cm, y radius=1cm] .. (0.51, -0.5) .. (0, 0) -- cycle;     \end{tikzpicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/K6PtK.png) But I couldn't find a way to construct `hobby` paths within the `pgf` Basic Layer, i.e. for use with `\pgfusepath`, in the documentation of the `hobby` package. Since there are situations where I prefer path construction via Basic Layer commands I'd like to know: Is there some way of combining `hobby` paths with `pgf` Basic Layer paths into one connected (or closed) path? Does the `hobby` package maybe provide a Basic Layer interface that I haven't found?


title: Eliminate space at end of list in a table

text: I have a `tabular` environment, created with `array` loaded and using `m` columns, the cells of which mostly contain lists. In cells with a list, there is about 1em of dead space at the end of the list before the bottom of the cell (in the cell with the largest contents which sets the row size). I am trying to get rid of this space, to no avail. I am using a custom `itemize*` environment that sets `\topsep`, `\parskip`, and `\partopsep` all to 0pt at the beginning (immediately after `\begin{itemize}`). This eliminates internal spacing but not the end spacing. I also have it setting `\@noparlisttrue`, but to no avail. Here's my `itemize*` definition:               \newenvironment{itemize*}{\begin{itemize}%       \setlength\topsep{0pt}%       \setlength\itemsep{-2pt}%       \setlength\parskip{0pt}%       \setlength\partopsep{0pt}%       \@noparlisttrue}{\end{itemize}}      I've tried setting `\topsep`, `\parskip`, and `\partopsep` before the `\begin{itemize*}` in my table cell as well, but I _still_ have the blank space. Tracing and Phillipe's comment indicate that it is invoking `\par` at the end of the list and this is causing the whitespace. Including `\setlength\parskip{0pt}` or `\setlength\parskip{-\baselineskip}` before `\begin{itemize*}` or before `\end{itemize*}` do not eliminate the space. How can I get rid of it?


title: Trouble with multicol

text: I'm trying to use multicol to create a formula sheet with two columns. I have specified the use of such columns, and their position, but when I compile they come out one after the other rather than split vertically on each side of the page. It would be ideal to have two separate columns very close together to maximize space as this will be used during an examination. I have things like               \pagestyle{empty}     \setlength{\parindent}{0pt}     \setlength{\parskip}{0pt plus 0.5ex}      in my preamble to use as much of the page as possible, but every compilation yields the same output. I looked at a few posts with the lipsum environment but I'm not sure how that works with multicol. I realize this is a simple problem, and definitely has a simple answer, but I cannot achieve the desired output. It would also be excellent to have a framebox around each column, separated by \hspace or something of that nature. Thanks in advance **EDIT** :               \begin{multicols}{3}     2.1 a)       \begin{align*}     \ddot{x} &= \frac{1}{m}\left(F_0+ct\right)\\     \dot{x} &= \int_{0}^{t}\frac{1}{m}\left(F_0+ct\right)\,dt = \dfrac{F_0}{m}t+\dfrac{c}{2m}t^2\\     x &= \int_{0}^{t}\left(\dfrac{F_0}{m}t+\dfrac{c}{2m}t^2\right)\\     \end{align*}      \end{multicols}      Here is a sample, it's simply a strategy/reference to an assignment problem. I can post others as well as this is just a snippet, let me know. **EDIT 2**               \begin{multicols}{3}     {\bf Bullet shot up with quadratic drag}     \begin{align*}     F &=-c_2v^2-mg\\     mv\dfrac{dv}{dx} &= -c_2v^2-mg\\     \int\dfrac{mv}{c_2v^2+mg}\,dv &=\int -1\,dx\\     \dfrac{m}{2c_2}\int \ln(c_2v^2+mg) &= -x+\beta\\     \beta &= \dfrac{m}{c_2}\ln(c_2v_0^2+mg)\\     v(x) &= \left((v_0^2+\frac{mg}{c_2})\exp{\dfrac{-2c_2x}{m}}-\dfrac{mg}{c_2}\right)^{1/2}\\     \end{align*}          {\bf Useful Proof}     \begin{align*}     \dfrac{d}{dt}\left[\vec{r}\cdot(\vec{v}\times\vec{a})\right] &= \vec{r}\cdot(\vec{v}\times\vec{a})\\     &= \dot{\vec{r}}\cdot(\vec{v}\times\vec{a}) + \vec{r}\cdot\dfrac{d}{dt}(\vec{v}\times\vec{a})\\     &= \vec{v}\cdot(\vec{v}\times\vec{a})+\vec{r}\cdot\left[\dot{\vec{v}}\times\vec{a}+\vec{v}\times\dot{\vec{a}}\right]\\     &= \vec{r}\cdot(\vec{v}\times\dot{\vec{a}})\\     \end{align*}          {\bf Find $V(x)$ where $F(x)=-kx+\frac{kx^3}{A^2}$,$v(t=0) = A\sqrt{\frac{k}{2m}}$ and $x(t=0) = 0$ }     \begin{align*}     F&=-\dfrac{dV}{dx}\\     k\int x-\dfrac{x^3}{A^2}\,dx &= \int dV\\     \dfrac{kx^2}{2}-\dfrac{kx^4}{4A^2} &= V(x) + C\\     V(x) &= \dfrac{kx^2}{2} -\dfrac{kx^4}{4A^2}\\     \end{align*}     {\bf Proof of successive maxima}     \begin{align*}     x(t) &= \exp{-\gamma t}(A\cos(\omega_dt+\theta_0))\\     x'(t) &= -\gamma\exp{-\gamma t}(A\cos(\omega_dt+\theta_0))+\exp{-\gamma t}(-A\omega_d\sin(\omega_dt+\theta_0))\\     0 &=A(-\gamma\cos(\omega_dt+\theta_0)-\omega_d\sin(\omega_dt+\theta_0))\\     1&=\dfrac{-\omega_d}{\gamma}\tan(\omega_dt+\theta_0)\\     \dfrac{-\gamma}{\omega_d}&=\tan(\omega_dt+\theta_0)\\     (\omega_dt_{i+1}+\theta_0) - (\omega_dt_i+\theta_0) &= 2\pi\\     \omega_d(t_{i+1}-t_i) &= 2\pi\\     t_{i+1}-t_i &= \dfrac{2\pi}{\omega_d}\\     t_{i+1}-t_i &= \dfrac{2\pi}{(\omega_0^2-\gamma^2)^{1/2}}     \end{align*}


title: Hyperlink in \todo[inline]

text: Do anyone have an idea why I have this two errors when using a `\hyperlink{}{}` in `\todo[inline]` ?? > 1- Argument of \reserved@a has an extra }. > > 2- Paragraph ended befor \reserved@a was complete. Thank you.


title: Package pgf Warning

text: I'm working with MikTex2.9 and I couldn't get rid of this warning message: Package pgf Warning: Your graphic driver pgfsys-dvips.def does not support fadings. This warning is given only once on input line 31. By trying this example:               \documentclass{article}     \usepackage{tikz}     \usetikzlibrary{shadows}     \begin{document}     \tikzstyle{ball} = [circle,shading=ball, ball color=red!80!white,  drop shadow=black, minimum size=1cm]     \begin{tikzpicture}     \node [style=ball] {blah blah blah};     \end{tikzpicture}     \end{document}      I got a .pdf slightly different from the .dvi file (the shadow is a little lighter) and I was wondering if this problem could be linked with the warning or if it's only a problem of the reader (as reported in: Tikz: Strange color change. ). Thanks in advance for any suggestions.


title: Making Verbatim and Beamer play nice

text: I'm writing a beamer presentation on basic math type-setting in latex and I've been trying to use verbatim to display how math equations are typed. Using `fragile` this works, but I still get several annoying error messages every time I compile, so I'm never sure if I have an actual error or if beamer is just complaining about verbatim. The current offender would be:               \begin{verbatim}     \[       X := \bigcup_{n \in \Mb N}\coprod_{\lambda \in \Lambda}             (X_\lambda \cap Y_\lambda ) \vee \Mb S^{n}.     \]     \end{verbatim}      I get error messages along the lines of:               LaTeX Font Warning: Font shape `OT1/cmss/m/n' in size <4> not available     (Font)              size <5> substituted on input line 11.          [1{/home/schlatjj/.texmf-var/fonts/map/pdftex/updmap/pdftex.map}] (./Math.toc)     [2] (./Math.vrb          LaTeX Font Warning: Font shape `OMS/cmss/m/n' undefined     (Font)              using `OMS/cmsy/m/n' instead     (Font)              for symbol `textbraceleft' on input line 6.          ) [3] (./Math.vrb) [4] (./Math.vrb     ! Undefined control sequence.     \test@single@character ...ken ->\def \math@format                                                        ##1{\mydollar ##1\mydollar...     l.10   \end{verbatim}      Are there any workarounds for this, something I can change in the code to make these error messages go away?


title: Align Scaled Image With Text Centered in Columns

text: Say given a list of items:               Item 1:      Item 2:     Item 3:     Item 4:      I want this list to be split into two columns with images aligned on each side of them. Much like a centered bar-graph (If there's a way to do that with a package, that would work too).               Image   Item1 Item3   Image     Image   Item2 Item4   Image      How might I go about creating the two columns to align to the center of the column?


title: Plotting the solution of inequalities with WolframAlpha or Maple

text: I want to plot the solution of two inequalities and include them in a LaTeX paper. I really like they way this looks: Wolfram Alpha. Unfortunately, I have no idea how to export this into a LaTeX-suitable format and I don't have a version of Mathematica. I have tried it with the `implicitplot` command of Maple but it does not look good at all. It displays the solutions of each of the inequalities but not both. Any ideas?


title: Referencing theorems, lemmas, etc by name

text: > **Possible Duplicate:**   >  How to cross-reference theorems with "Theorem"? I have had this doubt for quite a long time but I am unable to work out a way. This problem concerns referring back to definitions, equations, theorems, lemmas in a mathematical write-up of any sort: Please consider the following code:                \documentclass{amsart}      \usepackage{amsthm}           \newtheorem{defn}{Definition}      \newtheorem{thm}{Theorem}      \begin{document}      This is an example.            \begin{defn} \label{ring}      A commutative ring $R$ with unity is an abelian group with a binary operation  $\cdot $     (frequently referred to as multiplication) which is associative, commutative and has an identity.       \end{defn}               \begin{thm} \label{0pro}     $0_R \cdot r = 0_R$ for all $r \in R$     \end{thm}          The proof of Theorem \ref{0pro} follows from definition \ref{ring}.            \end{document}      In referring back to a theorem, one has to say `Theorem \ref{0pro}`. My doubt is that it must be possible to automise this: as in every instance of a reference to a theorem must come automatically as `Theorem <blah>` instead of having to manually type this in. Example: `\ref{0pro}` must print `Theorem 1` and similar goes for others. Is there a hack or a work around?


title: Color text in LyX?

text: I'm trying to color specific text in LyX, wondering how to do that with the graphical user interface (shortcut or something of sorts).


title: combining paperTeX and newspaper with a5paper

text: If you mix paperTeX and newspaper with a5paper layout paperTeX scales bad and newspaper uses absolute cordinates so half of the paper is not shown. Is there a solution for this problem?


title: Word wrap in \text{} in math mode

text: I'm trying to type formula, which requires some textual comments. I perform this using \text{} command in math mode. However, word wrap doesn't work. What should I do? Code sample:               $P^1_{r,s}=\sum\limits_{i=r}^n{P(i\text{ applicant is selected and is the best})}=\sum\limits_{i=r}^n{P(i\text{ applicant is the best})*P(i\text{ is selected | is the best})}.$.       As you can see on the screenshot, no word wrap is used and the line is cut. Thanks in advance. ![enter image description here](http://i.stack.imgur.com/MK6FB.png)


title: Plots in TikZ don't work

text: I want to do some plots using TikZ, however the following code doesn't work:               \documentclass{minimal}     \usepackage{amsmath}          \usepackage{pgf,tikz}%     \begin{document}     \begin{tikzpicture}           \draw[->] (-3,0) -- (2.2,0) node[right] {$x$}; %           \draw[->] (0,-0.5) -- (0,3.2) node[above] {$y$};%           \draw plot (\x,{\x^2});%     \end{tikzpicture}     \end{document}      Any idea what's wrong? How to plot functions like `x \mapsto a^x (a > 0)`? Edit: Thanks for the patch, however ploting `2^x` doesn't work, I get the following picture using Jakes answer: ![enter image description here](http://i.stack.imgur.com/DredQ.jpg)


title: Bibtex Internals

text: I would like to make modifications to my bibtex title, and this can be done by modifying \bibname. But when it comes to reducing the amount of space between the title "Bibliography" and the entries below, I want to know how much space is put there in the first place. More generally, I am curious as to how the bibtex internals work. I can't seem to find any documentation on this. So my questions are:   1. Where I can find information on how bibtex formats the bibliography page(s)?   2. More specifically, what determines the amount of space between the title and the entries below?


title: How to place all proofs automatically in appendix?

text: Can I place all proofs to theorems in appendix automatically? Usually proofs are written in the LaTeX codes immediately after the theorems. Without physically moving proofs to appendix, how can I place them in appendix automatically? Is there a package?


title: How can I call TexLive in Ubuntu?

text: Following the instructions in this page https://help.ubuntu.com/community/LaTeX , I installed TexLive, which needs some 1GB of space (I installed the texlive-full package). Yet, after installation, I don't seem to find any command that seems to represent the TexLive!! Is it the normal tex, latex, pdflatex, etc.? Well, I already had those before installing TexLive? So where was the 1GB installed? What about the packages? Where were they installed?


title: Change the word "Chapter" to something else

text: I am using `fancyhdr`. With that, using the command               \renewcommand{\chaptername}{Lecture}      has no effect. How can I change the name "Chapter" into something else?


title: Backward compatibility for command names

text: I have made a class file. It defines commands for use in document files. I want to change some of the command names, but I also want old document files to work without changing them. Here's an example to illustrate:               \begin{filecontents}{a.cls}      \ProvidesClass{a}     \LoadClass{scrartcl}     \RequirePackage{scrpage2}     %     \def\commandnameA#1{\def\@commandnameA{#1}}     \commandnameA{}     %     \newpagestyle{a}{{}{}{A:\@commandnameA}}{{}{}{}}     \pagestyle{a}     \end{filecontents}     \documentclass{a}     \begin{document}     \commandnameA{test}     test     \end{document}      For this example I want to change "commandnameA" to "commandnameB" in the class file and have the document file work whether it contains `\commandnameA{test}` or `\commandnameB{test}`. Any help is appreciated.


title: Online references for creating advanced macros?

text: I am looking for online references for creating advanced macros for LaTeX.


title: Multicol layout for systems of (linear) equations

text: How can a similar arrangement be archived (with ams*, aligned, multicol, etc) 1.2.3 Solve the following system of equations:                 a)        x -  2y -  4z =   1   b)     -23x + 43y  = 22                3x -   y -   z =  -1             x -  5y  = -1                 x - 11y + 22z = 110             c)   x +   y - 4z -   u =  1    d) -23x + 43y   -t =    2          10x -   y - 5z +  6u = -1          x -  5y + 6t =  -10            x - 11y + 2z - 22u = 11         5x -  8y - 6t = -100            x - 18y + 8z +  2u = -6       with "full double", ie. vertical and horizontal alignment?


title: In what circumstances should one wrap numbers in dollars?

text: Here is an example to consider:               A $3.1415$ approximation for $\pi$ was known on 314 BC?      Or maybe               A 3.1415 approximation for $\pi$ was known on 314 BC?      And here is another:               We run 32 experiments, the average result was always 42\%      etc.


title: biblatex: Retrieve which references are NOT used

text: I think this is a gerenal issue: If you have a `.bib`-file with 200 entries and you use maybe about 170 of it, how can you retrieve the missing 30 keys? The background is: `\nocite{*}` will add all references, but that's not what I want. I want only the references which are really used. **But** : I also want to know what keys are not used, so I can scan through that list and check if important references are missing.


title: Find unused bibkeys using biblatex

text: I want to get a list of bib-keys from my `.bib` file which I don't actually use in my document. I have found "Unused bibliography entries - how to check which entries were not used?" but since I'm using biblatex I don't have the information in the `.aux` files, so I can't use checkcites. Is there a biblatex way to get such a list?


title: Cited and non-cited references

text: I'm writing a document which has both a "References" and a "Further Reading" section via BibTeX. I'd like to be able to put all cited references in the "references" section (using `\bibliography`, of course), and put the remainder of the references in my `.bib` (those which are never cited) in the "Further Reading" section. Is there a way to accomplish this?


title: Show uncited references using biblatex and refcheck

text: ### Does `refcheck` work with `biblatex`? If not: **how do I print all uncited references using`biblatex`**? * * * Using the MWE from here, I can display all the uncited references.   When I try to do the same using `biblatex`, `refcheck` doesn't appear to work. I don't see any error messages when I compile, though. This is my `.tex` file:               \documentclass{report}     \usepackage{biblatex}     \usepackage{refcheck}     \bibliography{refs}     \begin{document}          Hello world \cite{foo2012a}.     \nocite{*}     \printbibliography     \end{document}      Which is producing: ![No refcheck annotations](http://i.stack.imgur.com/Z41qy.png) I am (hopefully) expecting to see: ![what I want to see](http://i.stack.imgur.com/gzmwF.png) How can I make `refcheck` work with `biblatex` **or** how can I achieve the same thing in a different way (display all references that are not cited in my document)?


title: Reference list and Bibliography

text: I am currently writing a paper and need to include both   * a reference list {with items i have cited throughout my text}, and   * a bibliography {with items i made reference too whilst doing the thesis and are not cited in the text} I am using a bibtex file to keep all references in order. I have managed to get a reference list by making use of               \cite{Ccone}     \cite{3rings}     ...     \bibliographystyle{ieeetr}     \bibliography{ref1}      where ref1 is the .bib file containing all my references. I have tried the `\nocite{*}` command to include the bibliography. However, this overwrites the whole reference list and everything is included in the same list. This is the code I am currently using:               \documentclass[twoside]{article}     \usepackage[hmarginratio=1:1,top=32mm,columnsep=20pt]{geometry} % Document margins     \usepackage{multicol} % Used for the two-column layout of the document     \usepackage{bibunits}          \begin{document}     \begin{multicols}{2} % Two-column layout throughout the main article text     ...     \cite{Ccone}     \cite{3rings}     \nocite{*}     ...     %\section*{References}     \bibliographystyle{ieeetr}     \bibliography{ref1}     ...     %\section*{Bibliography}     \bibliography{ref1}     ...     \end{multicols}     \end{document}


title: Symbol for Gaussian distribution

text: What is the symbol for the normal density function in LaTeX?


title: Why does the following code run in an infinite loop?

text: \def\hcAuxText{}     \newread\hcInputStream     \immediate\openin\hcInputStream=myfile.tmp     \loop\unless\ifeof\hcInputStream         \read\hcInputStream to \hcAuxLine         \let\hcAuxAcumm\hcAuxText         \edef\hcAuxText{\hcAuxAcumm \hcAuxLine}     \repeat     \closein\hcInputStream      I am trying to read the contents of a file to a variable. I need the whole file to be read because the file will be later modified (like a table of contents). When the above code is run, I get the following message:               ! TeX capacity exceeded, sorry [input stack size=5000].     \@ifundefined #1->\expandafter \ifx \csname #1                                                   \endcsname \relax \expandafter..      I would like to know i) why that code overflows the stack, and ii) is there a better way to read a whole file to a variable? %%%%%%%%%% Edit %%%%%%%%%% The ulterior motives for this code are to load a file into a variable which can then be "pasted" whenever used. The file is read \AtBeginDocument but it is modified when the source is processed. So, I want to keep the "initial state" of the file in memory. That might help with my question (ii) above. As for part (i), I am baffled that the code above did not work. After all, I read a line storing it in \hcAuxLine, copy the previous state of \hcAuxAcumm to \hcAuxText, and finally concatenate {\hcAuxAcumm \hcAuxLine} to \hcAuxText.


title: Including 3D figures -- "click to activate"

text: When I use Asymptote to create 3D figures, they appear in the final PDF as static images. When the user hovers the mouse over them, the message "click to activate" is displayed and a mouse click transforms them into rotatable and zoomable interactive figures. I want to achieve the same thing with my U3D files which I include using `movie15`:               \includemovie[     poster,     text={\includegraphics[width=0.7\linewidth]{fig/mystaticversionof3dfile}},     toolbar,      label=my3dfile.u3d,     3Drender=SolidWireframe,     3Daac=30.000000,      3Droll=270.000000,      3Dc2c=86.22 -21.6 1.95,      3Droo=60.169449,      3Dcoo=-15.000000 3.500000 15.000000,     3Dlights=CAD,     ]{\linewidth}{0.5055\linewidth}{figures/my3dfile.u3d}      This figure automatically converts into an interactive figure if the viewer supports it. This is bad if the user opens the document to print it. What parameters do I need to change to introduce the "click to activate behaviour"?


title: Mathematical functions inside LaTeX tables

text: I have several tables where I have tables which may look like this:               -------------------------------------     | X | Y | X + Y | X - Y | (X + Y)/2 |     -------------------------------------     |   |   |       |       |           |     |   |   |       |       |           |     |   |   |       |       |           |     -------------------------------------      I mean X, Y are the data and columns 3, 4, 5 are derived from X and Y. Typing in contents of column 3, 4, 5 are subject to human error and mistakes (can be embarrassing). I was looking to get an idea as to how you solve this problem in LaTeX tables. Is there a package capable of doing this? When you copy-paste an Excel table, there is very little scope for such errors. Is something similar possible in LaTeX?


title: "pdf_open: Not a PDF 1.[1-5] file." when typesetting TeX file in TextMate

text: I have a TeX file, which is typeset by `XeLaTeX`. The file has `\includegraphics{coverimage.eps}` on the first page, and `coverimage.eps` is located in the same directory as the TeX file. OS: MacOS 10.6.5, TextMate 1.5.10, xelatex 3.1415926-2.2-0.9997.4 (TeX Live 2010) If I run `xelatex doc.tex` in console, file compiles without errors, and eps file is included. If I typeset it in TextMate (xelatex engine is selected in preferences), I get the following error:               ** WARNING ** pdf_open: Not a PDF 1.[1-5] file.     ** WARNING ** Failed to include image file "./coverimage.eps"     ** WARNING ** >> Please check if     ** WARNING ** >> rungs -q -dNOPAUSE -dBATCH -sPAPERSIZE=a0 -sDEVICE=pdfwrite -dCompatibilityLevel=%v -dAutoFilterGrayImages=false -dGrayImageFilter=/FlateEncode -dAutoFilterColorImages=false -dColorImageFilter=/FlateEncode -sOutputFile=%o %i -c quit     ** WARNING ** >> %o = output filename, %i = input filename, %b = input filename without suffix     ** WARNING ** >> can really convert "./coverimage.eps" to PDF format image.     ** WARNING ** pdf: image inclusion failed for "coverimage.eps".     ** WARNING ** Failed to read image file: coverimage.eps     ** WARNING ** Interpreting special command PSfile (ps:) failed.     ** WARNING ** >> at page="1" position="(107.149, 124.566)" (in PDF)     ** WARNING ** >> xxx "PSfile="coverimage.eps" llx=0 lly=0 urx=408 ury=526 rwi=3809       and there is no image included in the resulting file (but text looks ok). I am not sure whether it is the error of xelatex or TextMate LaTeX bundle. What I tried to do:   1. As I said, `xelatex doc.tex` from console works. The exact command line that TextMate uses is:              xelatex -interaction=nonstopmode -file-line-error-style -synctex=1      But it works from console too.   2. If I convert the image to pdf (and fix the .tex file accordingly), typesetting from TextMate works too.   3. I tried running `rungs` with parameters specified in the error message, and got valid .pdf file with image as a result.   4. I compared .log files from typesetting in TextMate and in console, they are absolutely identical except for this error message (in particular, version of `xelatex` is the same). Does anyone know what can cause this? Please tell me if you need any additional information. Thank you in advance.


title: Label steps of equations using \tikzmark

text: I was very happy with results obtained in this question: Combine two \tikzmark solutions. (Awaiting @PeterGrill to update his answer) The `\tikzmark` is a wonderful creation. What am stuck now is to create labels like the one shown in the diagram below: ![enter image description here](http://i.stack.imgur.com/3pOUE.png) I knwo that the commands `midway` and `below` for nodes can be applied but don't know why I can't get it. Can a simple command be created, say `\mylabel{node1}{node2}{text}` that does the desired result? This is my MWE:               \documentclass[11pt,a4paper]{article}     \usepackage{amsmath}     \usepackage{tikz}     \newcommand{\sn}[2]{\ensuremath{{#1}\times 10^{#2}}}     \newcommand{\mtikzmark}[1]{\tikz[overlay,remember picture] \node (#1) {};}     \tikzset{square arrow/.style={to path={-- ++(0,-.25) -| (\tikztotarget)}}}          \begin{document}         \begin{align*}         (\sn{3.14}{-\mtikzmark{a}2}) + (\sn{1.2}{-\mtikzmark{b}4}) &= (\sn{3.14}{-2}) + (\sn{0.012}{-2})\\                                          &= \sn{(3.14+0.012)}{-2}\\                                          &= \sn{3.152}{-2}           \tikz[overlay,remember picture] {\draw[<->,square arrow] (a.south) to (b.south);}         \end{align*}     \end{document}      Notice that am still not implementing the solution given in the quoted post as I believe this is a different question. Unfortunately, the `\tikzmark` definition above is fixed to below and not above of the equation. A customization of the such would be greatly appreciated.


title: Tikz / LaTeX Indian Calendar

text: There are many calendar templates out there but it did not give me good ideas on how to create the one for my requirement. Indian calendar has lot more information on days other than just the numbers. I would appreciate your ideas on how to proceed on this issue. I worked with tikz before but just enough to create a table etc. I don't know how to create a box for each day and also put some text into it. thanks for your help ![enter image description here](http://i.stack.imgur.com/ctuOW.jpg)


title: Chapters with long descriptive titles

text: I have document which require me that chapter headings consist of two parts: (1) Chapter number (Chapter 1, Chapter One etc.) or any other text with similar function and (2) descriptive title below number that can be long. I was able to push descriptive title below chapter number and style it according to my needs with following macro:               \documentclass[final]{book}     \usepackage{lipsum}          \def \mylongchapter#1#2{     \chapter*{\centering{\LARGE #1} \\* \textnormal{\Large #2}}     \addcontentsline{toc}{chapter}{#1: #2}     }          \begin{document}          \mylongchapter{Chapter 1}{This Chapter Have Very Interesting and Long Title Below Chapter Number}          \lipsum[11-30]          \end{document}       Which produces this: ![long chapter title](http://i.stack.imgur.com/h3Lil.png) **Questions:**   1. Is there any better way to typeset chapters with such descriptive title than what I did?   2. How to control (or remove) spacing/gap between two or more lines of descriptive title (see picture below)?   3. How to control spacing between _Chapter 1_ and descriptive title? ![gap between two lines of chapter title](http://i.stack.imgur.com/daXp7.png)


title: Difficult with fancyhdr and table of contents

text: Premise: I'm new with fancyhdr. I defined the following fancy style:               \lhead{}     \chead{\slshape\leftmark}     \rhead{}     \lfoot{}     \cfoot{\thepage}     \rfoot{}     \renewcommand{\headrulewidth}{0.4pt}     \renewcommand{\footrulewidth}{0.4pt}      which correctly draw the chapter number and name, top line, the bottom line, and the page number, in all the page except the first of each chapter. So, I redefined the plain style in the following way:               \fancypagestyle{plain}{     \lhead{}     \chead{}     \rhead{}     \lfoot{}     \cfoot{\thepage}     \rfoot{}     \renewcommand{\headrulewidth}{0pt}     \renewcommand{\footrulewidth}{0.4pt}}      which correctly draw the top line, the bottom line, and the page number in the first page of each chapter (note: the plain style miss the chapter number and name of the fancy style) Now, I have a problem with the table of contents. The first page of the toc has the plain style (without the chapter number and name), but the following pages have the fancy style (with chapter number and name). How can I apply the plain style to ALL the page of the toc?


title: Horizontal line under chapters in a multicolumn ToC

text: I have a document that contains a multicolumn ToC made with               \usepackage[toc]{multitoc}     \renewcommand*{\multicolumntoc}{3}      I use the following command to make chapters and add them to the ToC, as I do not want chapter numbers to show up anywhere:               \newcommand{\myChapter}[1]{       \chapter*{#1}       \addcontentsline{toc}{chapter}{#1}     }      I want to add a line under each chapter heading in this ToC, but I simply cannot figure out how to do it. It should end up looking like this:               Chapter 1               1.1.3 Subsection        2.1.1 Subsection     -----------------                               2.1.2 Subsection     1.1 Section             Chapter 2     1.1.1 Subsection        -----------------     1.1.2 Subsection        2.1 Section      I have looked at the tocloft package and it gives an example for parts:               \part{Part title}     \addtocontents{toc}{\protect\mbox{}\protect\hrulefill\par}      This works, but I am interested in doing it for chapters, not parts. I have looked at Overfull hbox (in the middle of page) in ToC with tocloft package and cftchapaftersnum and How to change the style of ToC and \chapter? and followed the answers, without success. The line simply does not show up. Can anyone tell me how I can make these lines?


title: Nested symbolic x coords in bar chart

text: any ideas on how to create something like this in latex? ![enter image description here](http://i.stack.imgur.com/JCWQo.png) the image is of a basic grouped plot (using pgfplots) but with a nested x axis group (the numbers in red) that I've added using an image editor. how could I go about adding multiple nested groups in latex? or if it's not possible, could I instead just manually add the second group as a label underneath the chart?


title: Lines in epsfig have corners

text: I have a problem with epsfig. I want to draw some graphs. I created the picture with xfig and got the following code:               \setlength{\unitlength}{4144sp}%     %     \begingroup\makeatletter\ifx\SetFigFont\undefined%     \gdef\SetFigFont#1#2#3#4#5{%       \reset@font\fontsize{#1}{#2pt}%       \fontfamily{#3}\fontseries{#4}\fontshape{#5}%       \selectfont}%     \fi\endgroup%     \begin{picture}(2280,2011)(1336,-1925)     \thinlines     {\color[rgb]{0,0,0}\put(1801,-61){\line( 1,-1){900}}     \put(2701,-961){\line(-1, 0){900}}     \end{picture}      I included it with the following code:               \begin{figure}[H]     \begin{minipage}{\linewidth}     \begin{center}     \input{*/File.tex}           \end{center}     \end{minipage}     \end{figure}      The problem is: The lines seem off, they are kind of irregular.


title: Undefined control sequence \SetKwProg

text: The minimal (not) working example is               \documentclass{article}     \usepackage[algo2e,ruled,vlined]{algorithm2e}     \begin{document}      \begin{algorithm2e}[h]       \SetKwProg{myproc}{Procedure}{}{}           \myproc{foo()}{        $\ldots$       }         \end{algorithm2e}      \end{document}      This example works on Windows with latest version of portable Miktex. However, it doesn't work on Linux (I try Ubuntu and Debian) with texlive installed. Both Linux system is updated. The error I got on Linux is               ! Undefined control sequence.     l.6   \SetKwProg                 {myproc}{Procedure}{}{}      Note, that with texlive I successfully Latex many algorithms, the only command which is not working is `\SetKwProg`. Any suggestion how to resolve this problem?


title: inlinelisting adds a space after keywords

text: I am having problem with `lstinline` macro. It keeps adding a space after the keyword "Module" - see MWE. How could I convince Latex not to do so? I already tried with including the "." inside the `\koda` argument, but then I get 2 spaces onward.               \documentclass{book}     \usepackage{listings}           \newcommand{\koda}[1]{%     \lstinline[language=[Visual]Basic,keywordstyle=\ttfamily\color{blue}, %     basicstyle=\rmfamily\normalsize, prebreak=, %     morekeywords={Or, Loop, Until, To, As, Single, Module, Double, ByVal}]     {#1}} %          \begin{document}     An example with \koda{Console, Sub et Module}. Continued text ...     \end{document}      Thanks in advance!


title: TikZ Scaling: Cannot scale a tikzpicture

text: Please take a look at the picture below. `scale` `pgfkey` works for the inner `tikzpicture` but not for the outer one. **MWE:**               \documentclass{standalone}     \usepackage{tikz}     \usetikzlibrary{positioning}     \begin{document}     \begin{tikzpicture}         \node[draw](node2){Node 2};          \node[below=of node2](tikzpic){%           \begin{tikzpicture}[scale=2]             \draw [step=0.25cm,lightgray,very thin] (0,0) grid (2.5,1.5);           \end{tikzpicture}         };           \draw[->,ultra thick] (node2) -- (tikzpic);       \end{tikzpicture}     %       \begin{tikzpicture}[scale=2]         \node[rectangle,draw](node2){Node 2};          \node[below=of node2](tikzpic){%           \begin{tikzpicture}             \draw [step=0.25cm,lightgray,very thin] (0,0) grid (2.5,1.5);           \end{tikzpicture}         };           \draw[->,ultra thick] (node2) -- (tikzpic);       \end{tikzpicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/qgU7D.png)


title: Paragraph indent after multicols environment

text: I'm using the `multicol` package and have found that the paragraph immediately following the `multicols` environment is indented. This happens even when there is no blank line between the end of the environment and the beginning of the next paragraph. Here is a MWE:               \documentclass{article}     \usepackage{multicol}     \usepackage{lipsum}          \begin{document}     \lipsum[1]     \begin{multicols}{3}         \lipsum[3-5]     \end{multicols}     \lipsum[2]     \end{document}      So how can I avoid the indent? Thanks! PS. How can I show the PDF of my MWE here?


title: How to change appendix IDs?

text: I'm writing a document in Russian and use the appendix package. Currently, it uses Latin letters A, B, C etc. to identify the individual appendices. I want to change these letters either to Russian ones (A, Б, В etc.) or to numbers. How can I do this? **Update 1:** Here is a MWE:               \documentclass[a5paper,pagesize,10pt,bibtotoc,pointlessnumbers,     normalheadings,DIV=9,twoside=false]{scrbook}          \usepackage[a5paper]{geometry}          \usepackage{cmap}     \usepackage[T1,T2A]{fontenc}     \usepackage[russian]{babel}          \usepackage{pdfpages}          \usepackage[utf8]{inputenc}          \linespread{1.05}           \usepackage{graphicx}          % \usepackage{hyperref}          \usepackage[toc,page]{appendix}          \newcommand{\q}[1]{>>\textit{#1}<<}          \title{A book title}     \author{My name}      \date{\today}                \renewcommand{\appendixtocname}{Приложения}     \renewcommand{\appendixpagename}{Приложения}          \begin{document}          \begin{appendices}          \chapter{...}     \section{...}     TBD     \section{...}     TBD     \section{...}     TBD     \section{...}     TBD          \chapter{...}     \section{...}     TBD     \section{...}     TBD     \section{...}     TBD     \section{...}     TBD          \chapter{...}     TBD          \chapter{...}     \begin{enumerate}         \item ...         \item ...         \item ...     \end{enumerate}          \end{appendices}                \end{document}


title: Footnotes and atbegshi header

text: I have done combination of eledpar and parcolumns packages 4 parallel texts on 2 pages. Using Atbegshi package adding page headers. Everything works fine, but when I add footnote page headers are lost. Here is a code.. If you comment footnotes everything works fine.                       \documentclass[10pt]{memoir}             \usepackage[utf8]{inputenc}             \usepackage{eledmac}             \usepackage{eledpar}              \usepackage{parcolumns}             \usepackage{xcolor}              \usepackage{atbegshi}              \usepackage{lipsum}             \foottwocolX{A}             \let\footnote\footnoteA             \parindent 0pt                   \newcommand{\pcheader}{\hspace*{0.2\textwidth}\textbf{A}{\hspace*{0.5\textwidth}\textbf{B}}\vspace*{1ex}\hrule}              \newcommand{\kpcheader}{\hspace*{0.2\textwidth}\textbf{C}{\hspace*{0.5\textwidth}\textbf{D}}\vspace*{1ex}\hrule}                   \AtBeginShipout{%             \checkoddpage             \ifoddpage              \pcheader             \else             \kpcheader             \fi             }%                       \begin{document}                        \sloppy             \begin{pages}                  \begin{Leftside}              \beginnumbering             \pstart             \begin{parcolumns}[nofirstindent,rulebetween=true]{2}   \colchunk[1]{                          \section*{LL1}\mbox{}                     {\color{red} testing color bug}                      \lipsum[3]                 test\footnote{footnote 1}                 \lipsum[3]                 }                 \colchunk[2]{                      \section*{LR1}\mbox{}                 \lipsum[3]                 test\footnote{footnote 2}                 \lipsum[3]                 }                 \colplacechunks             \end{parcolumns}             \begin{parcolumns}[nofirstindent,rulebetween=true]{2}   \colchunk[1]{                          \section*{LL2}\mbox{}                           }                 \colchunk[2]{                          \section*{LR2}\mbox{}                      }                 \colplacechunks             \end{parcolumns}                  \pend             \endnumbering% <             \end{Leftside}             \begin{Rightside}                  \beginnumbering             \pstart              \begin{parcolumns}[rulebetween=true]{2}                  \colchunk[1]{                  \section*{RL1}\mbox{}                 }                     \colchunk[2]{                          \section*{RR1}\mbox{}                          }                     \colplacechunks                         \colchunk[1]{                                 {\color{red} testing color bug}                         }                 \colchunk[2]{                 \mbox{}                 }                     \colplacechunks                          \colchunk[1]{                      \lipsum[1-2]                 test\footnote{footnote 3}                 \lipsum[1-2]                     }                     \colchunk[2]{                         \lipsum[3]                         test\footnote{footnote 4}                         \lipsum[3]                     }                 \colplacechunks                  \end{parcolumns}             \pend             \endnumbering% <--                  \end{Rightside}             \Pages             \end{pages}                  \AtBeginShipout\AtBeginShipoutDiscard             \end{document}


title: Profiles window too big in TeXnicCenter

text: I find the Build-->Define Output Profiles window to be too big, so I cannot click OK. Clicking "enter" does not work. How do I make it smaller?


title: How to use feynmf in LyX?

text: LyX documentation suggest to to use `feyn` package to draw Feynman Diagrams, It works fine, but unfortunately too restrictive and simple for my needs, I tried to use `feynmf` package instead, but it doesn't output anything, and I searched Internet for some possible examples/solution, but found none, are they compatible at first place? and if yes, can you please explain how to use it in LyX?


title: Performing basic arithmetic in custom commands

text: One thing annoying in `sparklines` is its verbosity and dependence on external arithmetics. For example, to depict a three bar graph of 16%, 53%, 31%, one has to write:               \begin{sparkline}{4}       \sparkspike .166 .302       \sparkspike .500 1       \sparkspike .834 .585      \end{sparkline}      I would prefer:               \threesparkline{0.16}{0.53}{0.31}      So my main question is _can I do basic arithmetic in LaTeX, like dividing and multiplying numbers, finding the max among three parameters, etc?_ Alternatively, _is there a better way of using sparklines that I've missed?_ **UPDATE:** After the sugestion of using the `calc` package, I'm stuck with the following attempt which yields an error in `\real` and `\ratio`:               \newcommand{\threespike}[3]{         \newcounter{max}\setcounter{max}{\maxof{\maxof{\real{#1}}{\real{#2}}}{\real{#3}}}         \newcounter{a}\setcounter{a}{\ratio{\real{#1}}{max}}         \newcounter{b}\setcounter{b}{\ratio{\real{#2}}{max}}         \newcounter{c}\setcounter{c}{\ratio{\real{#3}}{max}}             \begin{sparkline}{4}           \sparkspike .166 a           \sparkspike .500 b           \sparkspike .834 c          \end{sparkline}     }      **UPDATE2:** I eventually got to make `\ratio` work directly like this:               \newcommand{\ratiofivespark}[7]{         \begin{sparkline}{6}           \sparkspike .1 \ratio{#2}{#1}           \sparkspike .3 \ratio{#3}{#1}           \sparkspike .5 \ratio{#4}{#1}           \sparkspike .7 \ratio{#5}{#1}           \sparkspike .9 \ratio{#6}{#1}          \end{sparkline}     }      Where the first parameter passed establishes the full height of a bar. See the accepted answer for more powerful LaTeX-Fu!


title: Declaring variables and writing loops

text: My exam template includes a table listing the point values for each problem in the exam. Is there a way to declare the point values of each problem as variables within latex and write code to automatically generate this table?               \documentclass[letterpaper]{article}          \usepackage{amsthm}     \theoremstyle{definition}     \newtheorem{problem}{Problem}          \begin{document}          \begin{center}     \begin{tabular}{|c|c|c|}     \hline     Problem &   Points  &   Score   \\ \hline     1       &   12      &           \\ \hline     2       &   17      &           \\ \hline     Total   &   29      &           \\ \hline     \end{tabular}     \end{center}          \begin{problem}[12 Points]     Problem statement.     \end{problem}          \begin{problem}[17 Points]     Problem statement.     \end{problem}          \end{document}


title: Koma-script header/footer change with includepdf

text: I'm (still) moving from regular LaTeX classes (report, article) to Koma- Script. Lots of things are just okay, but not everything. My current problem lies with PDF inclusion **and** header/footer change for the included PDF pages. In a lot of documents, I have to include PDF docs here and there. To make reading easier, I want to modify the footer or headers to add some data about the included PDF doc. With `report` and `article` classes, `fancyheaders` and `pagecommand`, it is really easy :               \includepdf[addtotoc={1, section, 1, For the ToC, reference},     fitpaper=false,pages=-,frame,scale=0.7,     pagecommand={\thispagestyle{fancy}                  \fancyfoot[RE,LO]{\footnotesize\textbf{Some Footer}}}]{ThePDF}      No such luck when using `scrheadings`. I utterly fails to change the footer (or headers) for the included PDF pages. Here is a minimal (not) working example :               \documentclass[headheight=1.2cm,headsepline]{scrartcl}     \usepackage[bottom=2.8cm,footskip=18mm]{geometry}          \usepackage[headsepline]{scrpage2}     \usepackage{lipsum}     \usepackage{pdfpages}     \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage{lmodern}     \usepackage[frenchb]{babel}          \pagestyle{scrheadings}          \chead[]{Center header}     \ihead[]{Inside header}     \ohead[]{Outside header}          \cfoot[]{Center footer -- \thepage{} --}     \ifoot[]{Inside footer}     \ofoot[]{Outside footer}          \begin{document}          \title{That is some title}     \author{Author name}     \date{Someday}          \maketitle     \tableofcontents          \section{Blah}     \lipsum[3-5]          \includepdf[addtotoc={1, subsection, 1, Included PDF,tag},         turn=false,frame,scale=0.8,pages=1,         pagecommand={\thispagestyle{scrheadings}                      \ofoot{Another outside footer}                      \ifoot{Another inside footer}                      \chead{And a center header}}]{SomePDF}          \lipsum[3-5]     \end{document}      Any idea about what I'm doing wrong, or how to reach this goal ?


title: Deleting Footnotes Temporarily For Better Readability

text: In a document I use `\autocite` and `\footnote`(and biblatex what might not be an important information). I redefined `\footnote` (`\renewcommand{\footnote}[1]{}`) in order to produce a document with no personal remarks. Unfortunately, the `\autocite`command seems to be affected and no footnotes are shown at all. How to avoid this effect? Note: I am aware that I could switch to the inline mode.


title: Are there any typographical improvements planned for LaTeX3?

text: I have read a few posts about the changes to LaTeX in the upcoming "version", are there planned any changes to how LaTeX renders typography? Regarding kerning, spacing and all the "fancy" things `microtype` does today. I know that LaTeX has some problems with rivers and lakes today, and I do not know if those are possible to fix. But in that regard does LaTeX3 do anything different, for improved typography? This is not a critique, just a question from a curious user. If there are any improvements, a list and some examples would be much appreciated.


title: how to break in \only

text: Since the `allowframebreaks` in the beamer has some side effects as put by Gonzalo Medina, so in his answer to "Beamer, framebreaks with different subtitles", he recommend that `\only` should be a substitute. The following is the example he gives               \documentclass{beamer}     %---------------------------------------------------------------%     \usepackage{graphics,tikz}     %---------------------------------------------------------------%     \begin{document}     %---------------------------------------------------------------%     \begin{frame}     \frametitle{Common title, appearing on all slides in one frame}     %------------------------------------------------------------ 1     \only<1>{     \framesubtitle{The first frame subtitle}     \begin{itemize}     \item some text on slide 1     \item some text     \item some text     \item   \dots          \end{itemize}}     %------------------------------------------------------------ 2     \only<2>{     \framesubtitle{The second frame subtitle}     \begin{itemize}     \item some text on slide 2     \item some text     \item some text     \item   \dots      \end{itemize}}       %---------------------------------------------------------------%     \end{document}       My question is : if I have a little more things related to the title "The second frame subtitle" in the `\only<2>`, so that they cannot be put in one frame, then what I can do? Are there some similar command like `allowframebreaks` that can be used locally ?


title: Change the pagenumbering in a beamer presentation

text: In my beamer presentation I build a picture over some frames. But I want the pagenumber to stay while the picture is build up. Is there something similar to `\section*{Sectionname}`, or any other way to achieve this?


title: How to enable option 6 in "SKT" Package

text: Page 4 of the below link says that I have to enable "option 6" to use Sanskrit Transliteration of RgVeda.   * http://mirrors.ctan.org/language/sanskrit/sktdoc.ps Can anyone help me out in enabling the "option 6". I don't know how to enable it :(


title: How to set the number of the first citation?

text: I am using BibTeX and `natbib` for my citations. In the bibliography the first entry usually starts with [1]. Now I would like to shift all the numbers in the bibliography and text by a certain offset, e.g. 15, so that the first item is called 16 in this document.


title: How to I move the from (sender) address position to the left in a letter document class

text: This one deals more with vertical, not horizontal, space: Positioning the address in a Letter I know about the `scrlttr2` document class, but the `letter` class has much better default formatting (I only need to change ONE parameter), whereas the `scrlttr2` produces an aesthetically unpleasing document, which redundant output in the sender's info, and needs a lot of work to make it look like the `letter` class, which I find almost perfect: LaTeX letter with address field in the right place for a "C5 envelope with window" I would be willing to use the `scrlttr2` class, but I can't find a template for it that makes it look like the better looking `letter` class. Here is one: scrlttr2: Position of the recipient's address But I would rather just make this small fix to the `letter` class, if possible. Here is what I have so far for my .tex file:               \documentclass{letter}     \usepackage{hyperref}     \usepackage[english=nohyphenation]{hyphsubst}     \usepackage{tabularx}     \usepackage[left=2.0cm, right=3.0cm, top=3cm, bottom=2cm, bindingoffset=0cm, showframe=false]{geometry}     \renewcommand{\tabcolsep}{15cm}     \newcommand{\subject}[1]{% This macro will need one argument       {\begin{center} \bfseries \underline{#1} \end{center}}% Centred and bold text     }     \signature{Shafique Jamal}     \address{Shafique Jamal \\ 31 Streetname Drive \\ Town, Province \\ Canada ZIP POS}     \longindentation=0pt     \begin{document}     \begin{letter}{\TeX Stack Exchange Group \\ Office \\ 23 Streets Name \\ Town, Country POSTAL }     \opening{Dear Fellow Stack People:}     \subject{Subject: Subject goes here}          Can you help me move the sender's address to the left? It is too close to the right edge. I would like to make sure that it does not go more to the right than does the text in the body of the letter.          \closing{Sincerely,}     \end{letter}     \end{document}      And here is what this produces: ![Screenshot of LaTeX output](http://i.stack.imgur.com/Agcwt.png) The sender's address is too far to the right - I would like to bring it more to the left, so that the text of the sender's address goes no further to the right than does the text in the body of the letter. Any suggestions?


title: nested multicols with itemised list

text: Is there any way to reduce the column separation in `\begin{itemize}...\end{itemize}` in the following MWE to be the same as `\setlength{\columnsep}{1cm}`. Also how can I remove the column separation rule in the list?               \documentclass{article}          \usepackage{multicol}     \usepackage{lipsum}     \usepackage{enumitem}     \setlist{nolistsep}          \begin{document}          \setlength{\columnsep}{1cm}     \setlength{\columnseprule}{0.6pt}               \begin{multicols}{2}     \lipsum[1]          \begin{multicols}{2}     \begin{itemize}     \item  Item 1     \item  Item 2     \item  Item 3     \item  Item 4     \item  Item 5     \item  Item 6     \item  Item 7     \item  Item 8     \item  Item 9     \end{itemize}     \end{multicols}     \end{multicols}          \end{document}


title: A few words in a coloured/grey background box

text: How can I write a few words with a grey highlighting box in the background, as shown in the picture below ("TEXT 4")? ![](http://i.stack.imgur.com/9m8xw.png)


title: Creating Footer Read

text: I would like to create a footer in pdfLaTeX. The footnote should look like this: ![Footnote](http://i.stack.imgur.com/kb09G.png) On the left it should show the current page number, in the middle a description and on the right side an image. I tried till now the following:                   \usepackage{fancyhdr}         ...         \lfoot{\thepage}         \cfoot{some kind of description}         \rfoot{\includegraphics{pictures//image1}}      but i don't know how to get the background colored. Any suggestions?:)


title: How to prevent upper case in page header?

text: I just came across this small problem which I can't seem to fix. I have a section which looks like this:               \section{Properties of $C_q$}      The problem is that the header of the page uses upper case and so it displays this section title as if I had written               \section{Properties of $C_Q$}      How can I make sure the q is always lower case?


title: Should I make white spaces between the lines?

text: I don't know difference between two following codes:               \documentclass{article}     \begin{document}     The first line.          The second line.          The third line.     \end{document}      and               \documentclass{article}     \begin{document}     The first line.                    The second line.                    The third line.     \end{document}      The second code has many white spaces between the lines.


title: New paragraph without indent in KOMA Script

text: This might be the stupidest question ever asked on TeX.sx, but I recently changed my paragraphing style and now run into problems. Consider the following MWE:               \documentclass{scrartcl}          \begin{document}          This is a line. This is a line. This is a line. This is a line. This is a line.           Indented new paragraph. Indented new paragraph. Indented new paragraph. Indented new paragraph. Indented new paragraph.\\          New block again indented. Should not be indented.          \end{document}      It produces the following output: ![Indented new paragraph](http://i.stack.imgur.com/hE1Cv.png) In my opinion, there should not be an indented in the second paragraph. How do I avoid this?


title: Change order of initials/surname in klunamed citation style

text: I use Natbib's author-year (in LyX) with the klunamed.bst bibtex style. However, I would like to change the order of surname/initials in the compiled bibliography (see picture) so I get: `Surname1, A., Surname2, B., Surname3, C., ...` This is what I have (upper), and what I want. Is there a way to change klunamed.bst to obtain that? Link for klunamed.bst. _Edit_ My Preamble: `\usepackage[authoryear,round,colon]{natbib} \bibpunct[; ]{(}{)}{;}{a}{,}{;}` My Document settings: `Natbib style: Author-year`


title: How to use the parskip package? (space in between paragraphs)

text: Sorry, because I think it's a many times asked topic. But I don't find an example which help me to understand how to create a white space between paragraphs. I think `parskip` is the package I need to use but I don't know how to use it. I have this sample of LaTeX trying to understand how to use `parskip` package. What am I doing wrong?               \documentclass{report}          \usepackage{parskip}          \begin{document}     \setlength{\parskip}{0pt} % 1ex plus 0.5ex minus 0.2ex}     \setlength{\parindent}{0pt}          \section{Section Headings}          We explain in this section how to obtain headings     for the various sections and subsections of our     document.          \subsection{Headings in the `article' Document Style}          In the ``article'' style, the document may be divided up     into sections, subsections and subsubsections, and each     can be given a title, printed in a boldface font,     simply by issuing the appropriate command.     \parskip     Lorem ipsum `comillas simples' sit amet, consectetur adipiscing elit.     Fusce at augue nisi. Mauris vel metus velit. Nunc vitae augue justo, non euismod risus.     Nullam et bibendum nisl. Vestibulum nec leo lectus. Phasellus non dui et ipsum malesuada     venenatis vitae ut risus. Phasellus tincidunt erat sollicitudin leo auctor sed porta leo     commodo. Nullam et adipiscing libero. Ut et mi ac dui facilisis faucibus. Fusce eget magna     a quam volutpat accumsan. Duis dictum luctus ligula, at facilisis leo blandit sit amet.     Phasellus congue ornare lectus scelerisque malesuada. Praesent et cursus nulla. Quisque     aliquam felis ac nunc scelerisque a consectetur elit mattis.     \\          \end{document}      Will this spacing work in the entire document?


title: List with several types of items

text: How can one create a list with different types of items ? I am using the package `enumitem`, which is great for defining items and referring to them, but it seems to allow only one type of item. I have looked in the definition of `\item` in `latex.ltx`, but could not find any useful hint, and in `enumitem.sty` neither. More concretely I wish to have items like                  1 ...      → 2 ...      ✓ 3 ...      and type               \normalitem ...     \arrowitem ...     \checkeditem ...      Currently, I use `\item[\refstepcounter{xi}$\symbol$\arabic{thexi}]` Is there a better way to do it ?


title: Why should I update my tex installation?

text: Apart from not being able to get the latest package-updates, what are the benefits of the 2013 distribution over the one from 2012? Why should I update? I'm afraid updating will break something regarding my workflow with ST2 and synctex. I haven't found a specific changelog regarding the update. Please enlighten me.


title: Lifted or curved drop shadow

text: Does anyone know if it is possible to create a "lifted corner" or curved drop shadow effect for a text box? Something similar to this drop shadow effect


title: Legend for selected functions only

text: In my plot, there are 6-7 `\addplot[]` entries but I want legend for only one of those functions. How can I do that? I tried `\addlegendentry` after the function I wish to have a legend for but it creates a legend corresponding to the first one.


title: Making \footnote work in leftbar environment

text: Sorry, it's me again. Gonzalo has hinted me to the very nice leftbar environment in the framed package, which I now use for definitions, theorems and similar environment. Now I've got a new problem: Footnotes (\footnote) from inside the leftbar environment are not shown! The label is there, but there is no footnote with the corresponding number. According to this here and similar sources, this can be fixed by using \footnotemark and \footnotetext. The problem is: I'm using SWP and would like to have the \footnote command for footnotes. I thought of something like this:               \renewcommand{\footnote}[1]{\footnotemark \footnotetext{#1}}      But \footnotemark and \footnotetext need a label. So what I would like the most is someting like               \renewcommand{\footnote}[1]{\footnotemark[some arbitrary string "x" that cannot collide with an "x" from a different footnotemark] \footnotetext["x"]{#1}}      I've tried to use #1 itself as "x", but this spits out errors (not surprisingly, given that it is non-sanitized LaTeX). Is there a trick here, or is my syntax wrong? EDIT: My renewcommand is stupid anyway. The trick is to have the \footnotetext come _after the end_ of the leftbar environment. Is there a way to get this through renewcommand?


title: This particular use of xtabular makes latex hang indefinitely

text: Running latex or pdflatex on the following example causes a hang up, i.e. latex/pdflatex never ends:               \documentclass[twoside]{book}     \usepackage{calc}     \usepackage[table]{xcolor}     \usepackage{xtab}          \newcommand{\PBS}[1]{\let\temp=\\#1\let\\=\temp}%     \newlength{\tmplength}%     % table definition that divides available space in n equally spaced columns     \newenvironment{TabularC}[1]%     {%     \setlength{\tmplength}{\linewidth/(#1)-\tabcolsep*2-\arrayrulewidth*(#1+1)/(#1)}%     \par\begin{xtabular*}{\linewidth}{*{#1}{|>{\PBS\raggedright\hspace{0pt}}p{\the\tmplength}}|}%     }%     {\end{xtabular*}\par}%          \begin{document}     \begin{center}     \begin{TabularC}{1}      \hline      \begin{center}      \begin{TabularC}{1}       \hline       bla\\\cline{1-1}      \end{TabularC}      \end{center}\\\cline{1-1}     \end{TabularC}     \end{center}     \end{document}      If I replace xtabular by tabular or don't use a nested table in the document then all is fine. Does anyone know what causes this, or how to debug or workaround this? Note that above example is a minimized version of the output produced by doxygen, see the related bug report here: https://bugzilla.gnome.org/show_bug.cgi?id=732768.


title: How can the \textmu symbol be used in math mode and resize correctly?

text: I wish to use an upright mu character in various places in my document, and so I've put the following in my preamble:               % textcomp, for its upright mu     \usepackage{textcomp}     % some user macros     \newcommand{\murm}{\hbox{\textmu}}      This is fine in both text and math mode, except when I try to place the mu in sub/superscript positions, and its size remains unchanged. Is there any way to resize it to fit its environment within math mode?


title: How to make a right-facing fleur-de-lis list item bullet

text: Does anyone know how to make a right-facing, correctly-sized (12pt), nice- looking (crisp, maybe SVG or something), fleur-de-lis as a list item bullet? I found this, but it's not quite what I'm after because I'm having trouble finding a correctly-sized, right-facing fleur-de-lis image and I don't have the skills to draw one myself. When I try to scale one that I find using GIMP then it gets ugly very quickly. I found some fonts, but they all face up instead of to the right, and I'm not sure how I could use a system font as a list item even with XeLaTeX. There is a unicode fleur-de-lis, but my system (OS 10.6) doesn't seem to render it correctly (difficult to explain), and anyway, it faces up; not to the right. The fleur de lis below faces upward. I'd like it rotated 90 degrees clockwise so it looks a bit like an arrow facing right. ![Fleur de lis](http://i.stack.imgur.com/UvkyT.jpg)


title: Fit large table horizontally into a page

text: I have a table with 23 columns. How can I fit it to the page? Code:               \usepackage[verbose]{placeins}     \usepackage[ngerman]{babel}     \usepackage{blindtext}         \begin{table}[htbf]         \caption{Gross errors found using plausible value check}         \label{tab:gr}         \begin{center}             \begin{tabular*}{0.75\textwidth}{@{\extracolsep{\fill}}  l  c  c c c c c c c c c c c c c c c c c c c c c c  }                \toprule                  \textbf{Node Name} &\textbf{Node 2} &\textbf{Node 3} &\textbf{Node 4} &\textbf{Node 5} &\textbf{Node 6} &\textbf{Node 7} &\textbf{Node 8} &\textbf{Node 9} &\textbf{Node 10} &\textbf{Node 11} &\textbf{Node 12} &\textbf{Node 13} &\textbf{Node 14} &\textbf{Node 15} &\textbf{Node 17} &\textbf{Node 18} &\textbf{Node 19} &\textbf{Node 20} &\textbf{Node 25} &\textbf{Node 28} &\textbf{Node 29} &\textbf{Node 31} &\textbf{Node 32} \\                \midrule                  \textbf{Total Number Observations} 33 & 34 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33  \\                  \textbf{Number of Faults} & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33 & 33  \\                     \bottomrule             \end{tabular*}         \end{center}     \end{table}     \FloatBarrier     \blindtext      Result: ![Result of the code](http://i.stack.imgur.com/duLhs.png) Result of the code


title: Print page margins of a document

text: Sometimes when I'm reviewing my document and rearranging images and tables, It would be sometimes great to see the page margins. Is there any easy way to print the page margins when reviewing a document?


title: Arrows tangent and normal on a smooth cycle with TikZ

text: I would like to plot the normal and tangent lines on a smooth cycle. So far, I have this : ![enter image description here](http://i.stack.imgur.com/IviqL.png) As you can see, the normal well done, by the tangent isn't, what's the good setup for it ?               \documentclass[11pt]{standalone}        \usepackage{tikz}             \usetikzlibrary{arrows}           \begin{document}      \begin{tikzpicture} %[allow upside down]              \draw plot [smooth cycle, tension=0.8] coordinates {(2.5,0) (0,0) (0,2) (3,2)}           node[sloped,inner sep=0cm,below,pos=0,               anchor=south west,               minimum height=1cm,minimum width=1cm](N){};              \path[->] (N.south west) edge node[left] {$\vec{ n}$} (N.north east);         \path[->] (N.south west) edge node[left] {$\vec{ t}$} (N.south east);                \end{tikzpicture}     \end{document}


title: Automatically look up arXiv reference information

text: Does any editor or *TeX front-end provide the following feature? Given an arXiv preprint number, say `1234.5678`, automatically produce the relevant bibtex entry. This could be done for instance by looking up the webpage `http://arxiv.org/abs/1234.5678` whose source contains something like               <meta name="citation_title" content="Interesting facts about sequences of digits" />     <meta name="citation_author" content="A. Bethe" />     <meta name="citation_author" content="F. Gamov" />     <meta name="citation_date" content="2034/12/24" />     <meta name="citation_online_date" content="2034/12/25" />      I'm open to other bibliography tools than bibtex. And it does not need to be at the level of the editor. Of course, this could be done within the TeX run with shell escape, but letting TeX access the internet is a massive security risk `:)`.