title: How to set page counter in mdframed as footer?

text: I am using mdframed as footer and want page number as footer but in mdframed. If i use mdframed it overwrites on page number. How can i write page number in footer within mdframed? ![enter image description here](http://i.stack.imgur.com/laIlG.png) EDIT: Code of the comment               \pagestyle{fancy}      \fancyhf{} % sets both header and footer to nothing \renewcommand{\headrulewidth}{0pt}      \fancyfoot{}      \fancyfoot[C]{\begin{mdframed}[roundcorner=4pt,leftmargin=1, rightmargin=1, linecolor=blue,outerlinewidth=.5, innerleftmargin=5,innertopmargin=5,innerbottommargin=5,everyline = true, splittopskip=.6cm, splitbottomskip=.3cm]      \parbox[t]{0.333\textwidth}{\raggedright{ID} \parbox[t]{0.333\textwidth}{\centering{footertext} \parbox[t]{0.333\textwidth}{\raggedleft{Date} \end{mdframed}}       * * *               \documentclass{article}           \usepackage[framemethod=tikz]{mdframed}      \usepackage{fancyhdr} \usepackage{lipsum}      \pagestyle{fancy}      \fancyhead{}      \fancyfoot{}      \fancyfoot[C]{%      \begin{mdframed}[linecolor=blue!60,roundcorner=3pt]      \parbox[t]{0.333\textwidth}{\raggedright XXXXXXXX}%      \parbox[t]{0.333\textwidth}{\centering Page}%      \parbox[t]{0.333\textwidth}{\raggedleft 31 July 2012}      \end{mdframed}%      }      \begin{document}      \lipsum[1-2]      \end{document}


title: automatic conversion of xfig to tikz

text: I have a large collection (hundreds) of partially quite old xfig pictures. Though I really like the xfig program I would like to move to some more up-to- date picture format like TikZ. So I would like to ask if someone has a good idea for an automatic conversion tool. Ideally, some shell srcipt or so... Then problem (?) is that many of the xfig pictures have LaTeX overlays. EDIT: this might be too long for a comment on Mark's answer, so I post it here as an edit: Here is a sample of a xfig which simply produces an error # FIG 3.2 Produced by xfig version 3.2.5b               Landscape     Center     Metric     A4     52.00     Single     -2     1200 2     3 0 0 3 0 7 50 -1 -1 0.000 0 1 0 3     1 1 4.00 60.00 150.00     7650 3375 6975 4275 7650 5625     0.000 1.000 0.000      the script gives some tikz command requesting an error > Package pgf Error: Arrow end type ``triangle 45'' unknown. So, of course, I can edit now by hand several arrows and so, but I would like to have it more automatic... :(


title: How do I change the font size in LuaLaTeX?

text: \documentclass{minimal}          \usepackage[paperheight = 140mm,% comprimento                  paperwidth  = 200mm,% altura                 margin      = 10mm  % tamanho da margem                 ]{geometry}     \usepackage[T1]{fontenc}     \usepackage{fontspec}     \usepackage{xcolor}          \setmainfont[Color=brown]{Tangerine}          \begin{document}         Normal pleasure of your company is requested     \end{document}      I'm making a wedding invitation and I'm not sure how do it using LuaLaTeX. I want to set, in `\setmainfont`, the default color and size but I don't know how. I'm able to set the color, as in the example, but not the size at the same time. `\setmainfont[SizeFeatures={Size=30}]{Tangerine}` sets the size, but I don't know how put it together. Is it possible? Furthermore, how do I change the font size in the middle of the document? I tried `\Huge` but got an error.


title: Written response spaces for a workbook in ConTeXt

text: I am making a workbook in ConTeXt. Throughout the workbook, there will be many spaces for the owner to write in short answers of one or two paragraphs. This can be quite simple, perhaps just a question, followed by several thin, horizontal lines on which one can write. E.g.:               1. What was the most interesting part of the story?     __________________________________________________     __________________________________________________     __________________________________________________     __________________________________________________     __________________________________________________     __________________________________________________      Does TeX or ConTeXt have any standard method for providing such a space? Are there any algorithms in place within TeX or ConTeXt for specifying proper typographical placement of these elements and where breaks should appear? Here is an example of what I mean (although not necessarily ideal):   * No page break should be placed inside the writing area, unless the area before and after the break has at least 3 lines.   * No page break should be placed between the question and the writing area.   * Rather than specifying an exact number of lines, a range can be specified (e.g. 5 to 8 lines). E.g. If it prints 5 lines, but finds the rest of the page is empty, it can add up to 3 additional lines until the page is filled).


title: How to prevent `doc` from indexing foreign macros?

text: The `doc` package, used for documenting LaTeX packages, has the ability to produce an index of all macros used in the package. Index entries can of of three types: where the macro is _described_ , where it is _defined_ and where it is _used_. However, if `\DisableCrossrefs` has not been specified, `doc` will index _every_ macro in the code, including obviously useless entries like `\newcommand`, `\relax`, `\ifx` and so on. There is a command `\DoNotIndex`, which can be used to specify which macros should not be indexed. However, keeping the list intact is a tedious task that is prone to errors: each time you write a line of code, you need to think/check whether it introduces new unwanted index entries. One "solution" is to say `\DisableCrossrefs` and forget about code indexing. I would want something different, namely, have only macros defined by _my_ package listed in the index, which, IMO, makes more sense than blindly indexing everything but a set of explicit exceptions. More specifically, only names specified in the `macro` and `environment` environments should be tracked for where they are used, and other names should be omitted (for completeness, one can introduce a `\DoIndex` command, that is the opposite of `\DoNotIndex`, for exceptions that should be indexed anyway). In the following example code, the desired output is that `\newcommand` and `\GenericInfo` are not in the index, but, at the same time, `\mymacro` is still in the index and shows all three references: where it is described, defined and used:               % \iffalse     \documentclass{ltxdoc}     \EnableCrossrefs              \CodelineIndex     \begin{document}       \DocInput{test.dtx}     \end{document}     % \fi     %     % \DescribeMacro{\mymacro}     % Some meaningful description.     %      % \StopEventually{\PrintIndex}     %     % \begin{macro}{\mymacro}     % Here we define the macro.     %    \begin{macrocode}     \newcommand{\mymacro}{hello}     %    \end{macrocode}     % \end{macro}     %     % And here we use it.     %    \begin{macrocode}     \PackageInfo{test}{\mymacro}     %    \end{macrocode}     %      % \Finale      (Process it with two LaTeX runs with               makeindex -s gind.ist -o test.ind test.idx between them.) How can one achieve this result? Is there a package that already does this?


title: Changing of the numbering of parts in beamer

text: I want to change the part numbering in beamer. I tried the following:               \renewcommand*{\thepart}{\arabic{part}}     \renewcommand{\thepart}{\arabic{part}}      but without any success. The Roman numbering stays. What would be the best way to do it?


title: glossary does not appear

text: I've placed               \usepackage{glossaries}     \makeglossaries      just before               \begin{document}      as recommended in my preamble. After the main part of my paper I've placed               \newpage     \printglossaries     \newpage      before               \bibliographystyle{ecta}     \bibliography{references}     \end{document}      But the glossary won't appear. Here is what I do:   1. Run `LaTeX` to load my document   2. Run `BibTex` to load my bibliography   3. Run `LaTeX` to generate citations and references Before 3. I tried to run `MakeIndex` but then I got the following message:               Couldn't find input index file MainV2 nor MainV2.idx.     Usage: makeindex [-ilqrcgLT] [-s sty] [-o ind] [-t log] [-p num] [idx0 idx1 ...]      What do I do wrong? I use TeXShop Version 2.43 on Mac OS 10.7., if that matters.


title: Optional arguments in \def

text: I want to re-define the `\sqrt` command (as detailed in Nice-looking p-th roots), and so far I have the following:               \documentclass{article}          \usepackage{fouriernc} % use the New Century Schoolbook font     \usepackage{amsmath}          \let\oldsqrt\sqrt     \def\sqrt[#1]{\oldsqrt[\leftroot{-3}\uproot{3}#1]}          \begin{document}     This $\sqrt[p]{a}$ looks better than $\oldsqrt[p]{a}$,     since the $p$ does not intersect the root symbol.     \end{document}      However, when I try writing `\sqrt{a}`, I get an error. How can I make the `#1` argument optional, so that if it is not passed in, it leaves that area above the root symbol blank (as it would in the default `\sqrt` command)? (This is a follow-up to the comments on David's and Harish's answers to above- mentioned question.)


title: Two tables of content

text: See the min expl below. I would like to have two ToC: one giving only the rough structure of the document and a second one giving all the details down to subsubsections. The code pasted below should do just that but the second ToC is not displayed which I do not understand.               \documentclass{report}          \begin{document}          \setcounter{tocdepth}{1}               \setcounter{secnumdepth}{3}                 \tableofcontents          \renewcommand*\contentsname{Contents (detailed)}          \setcounter{tocdepth}{3}                    \tableofcontents          \chapter{XXX}     \section{YYY}     \subsection{WER}     \subsubsection{ABC}     \subsubsection{DEF}     \subsection{ZTR}     \subsubsection{OIU}     \subsubsection{OIZ}     \subsubsection{POI}     \section{YYY}     \subsection{WER}     \subsubsection{EDC}     \subsubsection{RFV}     \subsection{TGB}     \subsubsection{ZHN}     \subsubsection{OUH}     \subsubsection{WEK}     \chapter{ZZZ}     \chapter{AAA}          \end{document}       * * * Just noticed there is still a problem with hyperref:               \documentclass[10pt, a4paper]{report}     \usepackage{shorttoc}     \usepackage{hyperref}     \begin{document}          \setcounter{secnumdepth}{3}                \pdfbookmark[1]{Contents}{toc}         \shorttoc{Contents}{1}           \pdfbookmark[1]{Contents (detailed)}{toc}         \shorttoc{Contents (detailed)}{3}          \tableofcontents          \chapter{XXX}     \section{YYY}     \subsection{WER}     \subsubsection{ABC}     \subsubsection{DEF}     \subsection{ZTR}     \subsubsection{OIU}     \subsubsection{OIZ}     \subsubsection{POI}     \section{YYY}     \subsection{WER}     \subsubsection{EDC}     \subsubsection{RFV}     \subsection{TGB}     \subsubsection{ZHN}     \subsubsection{OUH}     \subsubsection{WEK}     \chapter{ZZZ}     \chapter{AAA}          \end{document}       By what does {toc} has to be replaced in the second \pdfbookmark? [Sorry, had problem with editing the above comment --> administrator please delete it!]


title: Trailing space to end \input| argument

text: Why do `\message{\input|"texlua ..."}` and `\message{\input|"texlua ..." }` give very different results? Notice the extra space before `}` in the second case. Minimal example to be compiled with `pdftex --shell-escape` below.               % Create an empty file \jobname.lua     %     \immediate\openout5\jobname.lua     \immediate\closeout5     %     % Only difference between \A and \B: a trailing space.     % Set \everyeof to allow \input within \edef.     %     \everyeof{\noexpand}     \edef\A{\input|"texlua \jobname.lua"}     \edef\B{\input|"texlua \jobname.lua" }     %     % Display the meanings in the terminal.     %     \newlinechar=10     \message       {%         ^^J^^J%         \meaning\A % => macro:->Script file <jobname>.lua         ^^J^^J%         \meaning\B % => macro:->\par         ^^J^^J%       }     \bye


title: Type Chinese in TeX compiled with LaTeX

text: I would like to type Chinese in TeX compiled with LaTeX. I have read the previous post. As I have to stick on `article` as `documentclass`, the following solution works for me so far:               % UTF-8 encoding     % bad-looking fonts (CJKfonts package)     % latex     \documentclass{article}     \usepackage{CJKutf8}     \begin{document}     \begin{CJK*}{UTF8}{gbsn}     文章内容。     \clearpage\end{CJK*}     \end{document}      It annoys me to have to enclose Chinese characters within an environment (`CJK*`). Isn't there a solution to type Chinese any time and any place we want, just as English characters? **Edit 1:** I tried the following code within `Emacs`, I use `C-c C-c` to launch `LaTeX` command within `Emacs`:               % Compile with xelatex     % UTF-8 encoding     \documentclass{article}     \usepackage{xeCJK}     \setCJKmainfont{SimSun}     \begin{document}     文章内容     \end{document}      It returns an error:               --- TeX said ---      ********************************************      * XeTeX is required to compile this document.      * Sorry!      ********************************************.     \RequireXeTeX ...********************************}                                                   \endgroup \fi      l.25 \RequireXeTeX      But I have already done `sudo apt-get install texlive-xetex`, I have also installed `texlive-full`.


title: Why do I have two different styles for my bar plots?

text: I have two bar plots—one uses error bars and draws its data from a `table`, the other does not. As far as I can tell, this is the only difference between the two. Why are they displayed in different styles? Why does the former stack its bars rather than setting them side-by-side? Code: (`pgfplotstat.sty` directly from Automatic calculation of error in pgfplots)               \documentclass[border=1cm]{standalone}     \usepackage{filecontents}          %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %%% BEGIN PACKAGE SETUP %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%              \begin{filecontents}{pgfplotstat.sty}         \newcommand{\calcrowmean}{             \def\rowmean{0}             \pgfmathparse{\pgfkeysvalueof{/pgfplots/table/summary statistics/end index}-\pgfkeysvalueof{/pgfplots/table/summary statistics/start index}+1}             \edef\numberofcols{\pgfmathresult}                     % ... loop over all columns, summing up the elements             \pgfplotsforeachungrouped \col in {\pgfkeysvalueof{/pgfplots/table/summary statistics/start index},...,\pgfkeysvalueof{/pgfplots/table/summary statistics/end index}}{                 \pgfmathparse{\rowmean+\thisrowno{\col}/\numberofcols}                 \edef\rowmean{\pgfmathresult}             }         }         \newcommand{\calcstddev}{             \def\rowstddev{0}             \calcrowmean             \pgfplotsforeachungrouped \col in {\pgfkeysvalueof{/pgfplots/table/summary statistics/start index},...,\pgfkeysvalueof{/pgfplots/table/summary statistics/end index}}{                 \pgfmathparse{\rowstddev+(\thisrowno{\col}-\rowmean)^2/(\numberofcols-1)}                 \edef\rowstddev{\pgfmathresult}             }             \pgfmathparse{sqrt(\rowstddev)}         }         \newcommand{\calcstderror}{             \calcrowmean             \calcstddev             \pgfmathparse{sqrt(\rowstddev)/sqrt(\numberofcols)}         }              \pgfplotstableset{             summary statistics/start index/.initial=1,             summary statistics/end index/.initial=4,             create col/mean/.style={                 /pgfplots/table/create col/assign/.code={% In each row ...                      \calcrowmean                     \pgfkeyslet{/pgfplots/table/create col/next content}\rowmean                 }             },             create col/standard deviation/.style={                 /pgfplots/table/create col/assign/.code={% In each row ...                      \calcstddev                     \pgfkeyslet{/pgfplots/table/create col/next content}\pgfmathresult                 }             },             create col/standard error/.style={                 create col/assign/.code={% In each row ...                      \calcstderror                     \pgfkeyslet{/pgfplots/table/create col/next content}\pgfmathresult                 }             }         }         \end{filecontents}                   \begin{filecontents}{setup.sty}         \usepackage{pgfplots,           pgfplotstable,           booktabs,           colortbl,           pgfplotstat,           amsmath}         \pgfplotsset{compat=1.7}              \pgfplotstableset{           summary statistics/start index/.initial=1,           summary statistics/end index/.initial=3,           create on use/mean/.style={create col/mean},           create on use/stddev/.style={create col/standard deviation},           create on use/stderror/.style={create col/standard error},           every head row/.style={             before row={\toprule},             after row={\midrule}},           every last row/.style={             after row={\bottomrule}},           every even row/.style={             before row={\rowcolor[gray]{0.9}}},           columns/.style={             dec sep align}}         \end{filecontents}          %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %%% END PACKAGE SETUP %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%          \usepackage{setup}          \begin{filecontents}{fish-8.9mgL.dat}     fishy measure1 measure2 measure3         1       92       98       90         2       66       86       80         3       78       90       86         4       96       80       84         5       82       78       86     \end{filecontents}     \begin{filecontents}{fish-3.9mgL.dat}     fishy measure1 measure2 measure3         1      148      138      148         2      120      136      138         3      124      144      150         4      132      144      130         5      124      112      138     \end{filecontents}          \begin{document}     \begin{tikzpicture}       \begin{axis}[         title={Comparison of Opercullum Openings           with Varying Oxygen Content},         xlabel=Fish,         ylabel=Opercullum openings per minute]              \addplot[ybar,                   error bars/y dir=both,                   error bars/y explicit]           table[x=fishy,                 y=mean,           y error=stderror]             {fish-8.9mgL.dat};              \addplot[ybar,                   error bars/y dir=both,                   error bars/y explicit]           table[x=fishy,                 y=mean,           y error=stderror]             {fish-3.9mgL.dat};      \end{axis}     \end{tikzpicture}          % Straight from `texdoc pgfplots` page 61 [2012-10-26]     \begin{tikzpicture}       \begin{axis}[         x tick label style={           /pgf/number format/1000 sep=},         ylabel=Population,         enlargelimits=0.15,         legend style={at={(0.5,-0.15)},           anchor=north,legend columns=-1},         ybar,         bar width=7pt,         ]         \addplot           coordinates {(1930,50e6) (1940,33e6)             (1950,40e6) (1960,50e6) (1970,70e6)};         \addplot           coordinates {(1930,38e6) (1940,42e6)             (1950,43e6) (1960,45e6) (1970,65e6)};         \addplot           coordinates {(1930,15e6) (1940,12e6)             (1950,13e6) (1960,25e6) (1970,35e6)};         \addplot[red,sharp plot,update limits=false]           coordinates {(1910,4.3e7) (1990,4.3e7)}           node[above] at (axis cs:1950,4.3e7) {Houses};         \legend{Far,Near,Here,Annot}       \end{axis}     \end{tikzpicture}          \end{document}


title: Bookmark using Part in article

text: Since I started using Part in my article, the bookmarks in my pdf have been screwed up. I now have the bibliography and the appendix as subsections of the final Part of my article. I want these sections to be outside of part, at the highest level within the bookmark-tree. = I also want to add a bookmark for the cover-page and the content-page at this same level, above the first Part in the tree.


title: Defining 3*(2^4) complex macro at once

text: An Automata can be   * 1- or 2- ways,   * With Several Heads or a Single head   * Deterministic or Non-deterministic   * With a stack or not That makes 2^4 = 16 possibilities. However, for each combination, I'd like to define several macros:   1. An abbreviation (e.g. 2MDFA+S for a "2-ways multi-head deterministic finite automata with stack")   2. An extended version (e.g. to fully write "2-ways multi-head deterministic finite automata with stack")   3. An abbreviation in a different font-face (e.g. **2MDFA+S** )   4. In the case of a multi-headed automata, the posibility to display the number of head in parenthesis (e.g 2MDFA+S(3) for a "2-ways 3-heads deterministic finite automata with stack") I would like not to write at each time what I want, but to massively use macro, to prevent typographic errors and misspellings. And, of course, to be able to change easily the displaying if I want to. * * * I know that I can define shorthands quickly, use `\csname...\endcsname` or define macros that define macro but that still leave me 16 combinations to define. I know that I can test for equality of a parameter thanks to the `xstring` package, but that force me to duplicate several `if` tests. That would (I guess) to have macros like \fa{1}{M}{D}{S}, but I don't mind. There is the additional difficulty that I cannot just "print the name of the macro", since I want "\O..." (for "one-way") to be printed with the number "1...". * * * Some kind of (lousy) attempt:               \documentclass{article}     \usepackage[utf8]{inputenc}     \usepackage{xparse}          % Underline for the example, but that could be a different font.     \newcommand{\bold}[1]{\underline{#1}}          % This part allows to have as an optional argument the number of heads.     % This is item 4 in the question.     \DeclareDocumentCommand{\abbrFA}{m g}{%         \text{#1}             \IfNoValueTF{#2}% then                         {}% else                         {(#2)}% fi     }          \DeclareDocumentCommand{\OMDFAS}{g}{%         \def\notation{$1$MDFA+S}                 \IfNoValueTF{#1}% then                     {\abbrFA{\notation}}% else                     {\abbrFA{\notation}{#1}}% fi     }          \newcommand{\longOMDFAS}{$1$-way Multi-Head Finite Automata with Stack}      % How to get this automatically for every combination?          \begin{document}     \(\OMDFAS\)          \(\OMDFAS{k}\)          \longOMDFAS          \(\bold{\OMDFAS}\)          \end{document}


title: Amsmath has problems with $e^{\sum{x}}$

text: Running the code:               \documentclass{article}     \usepackage{amsmath}     \begin{document} Test: $e^{\sum{x}}$ \end{document}      Dies, yet it runs just fine with the `\usepackage{amsmath}` commented out. The logs show:               !pdfTeX error: pdflatex (file fmex7.pfb): cannot open Type 1 font file for reading      Which seems to indicate a missing font. I've used amsmath quite a bit in the past and never come across the problem. A bit of googleing shows some other Debian users have had this problem but I'm not quite sure what to do here. I'm running Ubuntu 10.04 with most LaTeX packages installed.


title: Order of Figure in a Review Copy article

text: Order of figures (floats) is a common issue with LaTeX. I'm using a LaTeX template from a journal editor in my article I will submit for peer-review. I cannot thus use any of my own packages or anything else which is provided by the `cls` file. The journal editing policy ask author to put figures at the very end of the article. So I move my figure's environments at the end and use `\label` and `\ref` in order to call them. The thing is that my figure are not sorted in the `.tex` file as they are called. This means that for instance if fig2 is called in the text before fig1 the number of fig2 will be 2 and not 1 in the compiled version. This is really annoying, LaTeX should take into account the calling order and Not the order the `\begin{figure}` command in the `.tex`, because this does not make sense to me, what is the advantage in that case to use `\ref` and `\label`, I should hard code directly the number of each figure myself. So I'm sure I'm missing something. Any feedback would appreciated.


title: Indent Subsections (and their content) by one level

text: > **Possible Duplicate:**   >  How can I format sections/subsections/etc. like nested lists? I'm trying to get my subsections indented by one level (compared to the main sections). I know the best way to do this is probably to redefine the subsection and add an \hspace but I'm not quite sure how exactly.               \renewcommand{\subsection}{\hspace{2cm}{subsection}}      Or something similar? Thanks!


title: Changing LaTeX headers via a makefile

text: I recently created a makefile to use with my TeX documents and am quite happy with the discovery. When I create Beamer slides to use in class, I create both a set of slides and a handout to go along with them. I'd like to have a makefile that creates the slides, then changes one or two lines of the header of my TeX file (by uncommenting and commenting perhaps) to create a set of handouts (possibly by generating a new, intermediate TeX file). I'm guessing that a make file can't edit my TeX file, but that would be cool. Is it possible? Thanks!


title: What is bidirectional or multidirectional typesetting/editor?

text: I have been seen terms like **multidirectional typesetting** , **bidirectional typesetting/work** , **bidirectional editor** ... For example, in this brilliant answer to The differences between TeX engines, there is: > ... LuaTeX also incorporates some ideas from Omega and Aleph like > **multidirectional typesetting** ... > > ... XeTeX having been around longer and being probably the more widely-used > for **bidirectional work** at present ... Can someone help me to understand what these terms mean, and how they work? Thanks!


title: pgfplots bar chart: single symbolic x coord results in "! Package pgfplots Warning: Axis range for axis x is approximately empty; enlarging it"

text: How to avoid the error "! Package pgfplots Warning: Axis range for axis x is approximately empty; enlarging it" when there is only a single symbolic x coord in bar chart. Please see the following MWE:               \documentclass{article}     \usepackage{tikz}     \usepackage{pgfplots}          \begin{document}          \begin{tikzpicture}     \begin{axis}[symbolic x coords = {Q6},xtick = data,ybar,ymin = 0]          \addplot[mark=none,Red,fill=Red] coordinates {(Q6,3)};     \addplot[mark=none,Orange,fill=Orange] coordinates {(Q6,4)};     \addplot[mark=none,Green,fill=Green] coordinates {(Q6,3)};     \addplot[mark=none,Blue,fill=Blue] coordinates {(Q6,3)};     \end{axis}          \end{tikzpicture}          \end{document}      I would be really grateful for any suggestions here. Thank you.


title: Vertical aligment with tikzpicture

text: I have a problem with vertical alignment in a `tabular` environment with `tikzpicture`. My code so far is:               \documentclass[12pt,a4paper]{article}     \usepackage{tikz}     \begin{document}     \begin{tabular}{ccccc}     \begin{tikzpicture}       \draw[step=0.2cm,gray,very thin] (0,0) grid (0.2,1.6);     \end{tikzpicture}      & = &      \begin{tikzpicture}       \draw[step=0.2cm,gray,very thin] (0,0) grid (3,1.6);     \end{tikzpicture}     & * &      \begin{tikzpicture}       \draw[step=0.2cm,gray,very thin] (0,0) grid (0.2,3);     \end{tikzpicture}     \end{tabular}     \end{document}      which gives a result: ![enter image description here](http://i.stack.imgur.com/P2xHO.png) But what I want is more like this: ![enter image description here](http://i.stack.imgur.com/VbuJb.png) How can I do it?


title: siunitx with svg graphics

text: I am using pdfLaTeX (TeX Live 2011) to compile a document. Unfortunately it does not compile. Again, my example compiles flawlessly with TeX Live 2009. I include an SVG/PDF graphics following this guide. To do so I first create a drawing in an SVG file, then I export it to PDF and `pdf_tex` files. In the SVG file I added a line of text like this:               \SI{6}{\arcsecond}      The figure is included by:               \begin{figure}[htbp]     \centering     \def \svgwidth{\columnwidth}     \includesvg{path-to-figure}     \caption{\SI{6}{\metre}}     \label{fig:label-of-figure}     \end{figure}      The `\includesvg` command is defined as:               \newcommand{\executeiffilenewer}[3]{%        \ifnum\pdfstrcmp{\pdffilemoddate{#1}}%        {\pdffilemoddate{#2}}>0%          {\immediate\write18{#3}}\fi%     }      \newcommand{\includesvg}[1]{%     \executeiffilenewer{#1.svg}{#1.pdf}{%      inkscape -z -D --file=#1.svg %     --export-pdf=#1.pdf --export-latex}%     \input{#1.pdf_tex}%     }      Parts of the generated `pdf_tex` file.               \begin{picture}(1,0.44809873)%         \put(0,0){\includegraphics[width=\unitlength]{snifs_fov.pdf}}%         \put(0.47868192,0.06651686){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{c) foo + bar + baz }}}%         \put(0.47868192,0.17904892){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{b) bar + baz }}}%         \put(0.47868192,0.33397134){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{a) baz}}}%         \put(0.01018567,0.21107977){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{\SI{6}{\arcsecond}}}}%       \end{picture}%     \endgroup%      This is the resulting error.               (./figs/graphics/snifs_fov.pdf_tex     <./figs/graphics/snifs_fov.pdf, id=104, 376.15532pt x 168.55472pt>     <use ./figs/graphics/snifs_fov.pdf>)     ! Undefined control sequence.     \arcsecond ->\ERROR       **UPDATE:** I have mistakenly considered the SVG file to be the root of the error. In fact the same text, which is in the SVG file, follows in a paragraph after the figure. I debugged this by changing the text in the SVG file. The error message after compilation did not change. And also JosephWright's confirmation, that it is possible to compile the file in an MWE, helped me to find out.


title: Starting with LaTeX. Immidiately get an error

text: > **Possible Duplicate:**   >  the memory dump file could not be found Just trying to get started here with LaTeX, but I immediately get this strange error. I'm not much of a computer scientist to understand what I need to do next. Tried some Google searches but that was not of much help to me. Do you guys know what to do? The error:               This is pdfTeX, Version 3.1415926-2.3-1.40.12 (MiKTeX 2.9)     pdflatex.exe: The memory dump file could not be found.     pdflatex.exe: Data: pdflatex.fmt      I was typing some basic stuff, and then pressing the green 'play' button. It seems to me that he has trouble finding the `pdflatex.exe`? For extra information:               Using MiKTeX version 2.9 and TeXworks version 0.4.4.1003      ![problem](http://i45.tinypic.com/zso8lj.png)


title: insert Maple code in comment with mathmode create with tcolorbox package

text: see this code:               \documentclass[svgnames,12pt]{report}          \usepackage{amsmath,amsfonts,amssymb,amsthm}     \usepackage{tcolorbox}     \tcbuselibrary{listings,skins,theorems}          \lstdefinelanguage{Maple}%     {aboveskip={0pt},belowskip={0pt},basicstyle=\bfseries,     morekeywords={and,assuming,break,by,catch,description,do,done,%     elif,else,end,error,export,fi,finally,for,from,global,if,%     implies,in,intersect,local,minus,mod,module,next,not,od,%     option,options,or,proc,quit,read,return,save,stop,subset,then,%     to,try,union,use,uses,while,xor},%     sensitive=true,%     morecomment=[l]\#,%     morestring=[b]",%     morestring=[d]"%     }[keywords,comments,strings]%          \makeatletter     \tcbset{every listing line/.code={%       \def\lst@NewLine{%           \ifx\lst@OutputBox\@gobble\else               \par\noindent \hbox{}#1%           \fi           \global\advance\lst@newlines\m@ne           \lst@newlinetrue}}}     \makeatother          \newtcblisting{code}[1]{                colback=white,                skin=bicolor,                colbacklower=white,                colupper=red!40!black,                collower=blue,                frame style={draw=white,left color=white,right color=white},                fontupper=\bfseries,                fontlower=\bfseries,                width=\linewidth,                boxrule=0mm,                outer arc=1mm,arc=1mm,                leftupper=0cm,leftlower=0cm,rightupper=0cm,rightlower=0cm,                top=0mm,bottom=0mm,middle=0mm,                center lower,                nobeforeafter,                 listing and comment,                ams nodisplayskip lower,     %           comment={#1},                comment={\begin{align*}#1\end{align*}},                every listing line={\textcolor{red!40!black}{\ttfamily> }}                }          \begin{document}          \begin{code}{h := proc(t) t * (t-1) end proc}     h := proc(t) t*(t-1) end proc;     \end{code}          \end{document}      output is: ![enter image description here](http://i.stack.imgur.com/eQ29H.png) How do i change that until i have this output? ![enter image description here](http://i.stack.imgur.com/LZ1Pm.png) I mean in the main definition of **code** environment, not in the \begin{code}{} ... \end{code}. Thanks in advance.


title: Footnote on document author with footmisc

text: I'm using the following:               \documentclass[11pt]{article}     \usepackage[bottom,flushmargin,hang,multiple]{footmisc}     \title{Title}     \author{Joe Blow\footnote{Address}}     \begin{document}     \maketitle     Hello.\footnote{This is a footnote.}     \end{document}      Unfortunately the `flushmargin` option does not affect the footnote on the author. I would imagine there is a solution similar to the answer here, but I do not know the coding well enough to adapt it or come up with something else.


title: How can I 'compile' LaTeX snippets to (unicode) plain text?

text: I have a bunch of LaTeX snippets which I'd like to convert, as faithfully as possible, to Unicode strings. (In fact, these are title of papers from a bibliographic database, which I'd like to use as filenames.) > Can anyone suggest how to 'compile' a snippet of LaTeX into plain text? Here are some examples:               {\it {A}rithm\^etik\^e stoichei\^osis}꞉ on {D}iophantus and {H}ero of {A}lexandria     On a geometry of {I}vanov and {S}hpectorov for the {O}'{N}an sporadic simple group     On a theorem of {P}l\"unnecke concerning the sum of a basis and a set of positive density     On some series containing {$\psi(x)-\psi(y)$} and {$(\psi(x)-\psi(y))^2$} for certain values of {$x$} and {$y$}      My primary concerns are essentially just converting accented characters to unicode correctly and removing superfluous braces. I don't care about preserving formatting (e.g. `\it` above), and I'm happy leaving `$` delimited math as is. I'm interested in solutions that use TeX itself to do the conversion, as well as informed suggestions about doing the translation 'by hand' in some other language. Even removing braces, without destroying `$` delimited math, seems tricky.


title: How to include a custom text in page numbers?

text: I'd like to realise page numbers like "Type 1 Page 1" and "Type 1 Page 2" and so on in my document. How can I achieve this?


title: BibTeX using inconsistent name format in the case of two authors

text: I recently started using `biblatex` (my installation is TeX Live 2010). My preamble syntax is:               \usepackage[backend=bibtex,style=authoryear]{biblatex}      When I cite a source with two authors, the bibliography entry prints the author names using an inconsistent format. For instance, suppose my `.bib` file entry is:               @book{Abramowitz,     author = "Abramowitz, M. and Stegun, I.",     title  = "Handbook of Mathematical Functions",     publisher = {Dover Publications},     year = "1965" }      If I issue the command `\parencite{Abramowitz}` in my document, the bibliography entry prints as: > Abramowitz, M. and I. Stegun (1965). Handbook of Mathematical Functions. > Dover Publications. Notice that the name format used for the first author is inconsistent with that used for the second author. The first author is printed using Last Name First format, but the second author is printed using Last Name Last format. What I'd like is for the entry to print like this: > Abramowitz, M. and Stegun, I. (1965). Handbook of Mathematical Functions. > Dover Publications. How do I get `biblatex` to do what I want? Is this inconsistency a known `biblatex` bug?


title: Wrong abstract page number and spaces between LoF and LoT with \addcontentsline

text: How to correct two things in ToC:   * Page number of abstract - should be "vii"   * Spaces above LOF,LOT and Abstract are big. Not like above chapters ? Currently:               Contents          List of Figures       iii          List of Tables         v          Abstract               i     1 First                1     2 Second               2      Desired:               Contents          List of Figures       iii     List of Tables         v     Abstract              vii     1 First                1     2 Second               2      Code:               \documentclass[a4paper,12pt,twoside,openany]{report}     \usepackage[english]{babel}     \usepackage{makeidx}     \newcommand*{\term}{\textit}     \usepackage[colorlinks]{hyperref}     \usepackage[figure,table]{hypcap}     \hypersetup{         bookmarksnumbered,         pdfstartview={FitH},         citecolor={black},         linkcolor={black},         urlcolor={black},         pdfpagemode={UseOutlines}     }     \makeindex          \begin{document}     \title{Title Here}     \author{Author's Name}     \date{}          \pagenumbering{roman}     \tableofcontents          \cleardoublepage     \phantomsection     \addcontentsline{toc}{part}{List of Figures}     \listoffigures          \cleardoublepage     \phantomsection     \addcontentsline{toc}{part}{List of Tables}     \listoftables          \cleardoublepage     \phantomsection     \addcontentsline{toc}{part}{Abstract}     % \chapter*{Abstract} - When I use it I get chapter heading and abstract on another page     \begin{abstract}     Abstract     \end{abstract}          \pagenumbering{arabic}     \chapter{First}     \label{ch:first}     \chapter{Second}     \label{ch:Second}          \end{document}      I'd like to make it working with hyperref in pdf, that's why I left related code in example.


title: texlive does not find sty file

text: I am on Ubuntu 8.04 and just install TeX Live with :               sudo apt-get install texlive-full.      I tried to compile my `.tex` file with TexMaker. I get :   1. `xcolor.sty not found`   2. `titlesec.sty not found` How can I fix the problem ?


title: Conflict between color, graphicx and libertine

text: Compiling the following with pdflatex (TeXLive 2009/Debian on Ubuntu 10.04 "Lucid Lynx")               \documentclass{article}     \usepackage{ifpdf}     \ifpdf         \usepackage[T1]{fontenc}         \usepackage{libertine} % Linux Libertine. This gives an error         %\usepackage{lmodern} % this works fine         \usepackage[pdftex,usenames,dvipsnames]{color}         \usepackage[pdftex]{graphicx}     \else         \bye     \fi     \begin{document}     Hello, world!     \end{document}      I get this error:               ! LaTeX Error: Option clash for package color.          See the LaTeX manual or LaTeX Companion for explanation.     Type  H   for immediate help.      ...                                                        l.8     \usepackage                        [pdftex]{graphicx}      Can anyone explain this? I can't for the life of me understand why a font package would mess with color and graphicx.


title: Add a link to the TOC

text: I'd like to link the Table of Contents in the footer of each page. I can achieve this thanks to this hint like so:               # In the hyperref section of the document preamble     \cfoot{\hyperlink{page.1}{TOC}}      But if I change my document so that it has a title page, and the TOC moves to page two, I'll need to change this. Is there a better way to link to the TOC? Adding a `\label{}` and then using a `ref{}` does not seem to work.


title: Convert eps figure to grayscale without removing white space around the figure

text: I use eps2eps command followed by pscol command which convert color eps to grayscale. But this combination remove white space around the figure (which is probably done by eps2eps command). Directly applying pscol on my original figure without eps2eps before does not work. How to convert eps color figure into gray scale to have the same white space around?


title: How to wrap text around landscape page

text: I have from time to time a landscape page. I would like that text around it just normally flows. So something how figure environment works. So that it is not really important where you exactly define the figure, LaTeX moves it around so that text nicely flows. With landscape it does not do that.


title: TikZ arrowheads to match xy-pic?

text: I’d like to make arrow tips in TikZ that match with xy-pic’s standard arrowheads. The methods from this similar question look appropriate, but I thought I’d check first: has anyone else already created these? (The motivation is mainly that I’d like to have TikZ and xy-pic diagrams coexisting in the same document, since I often want the flexibility of TikZ, but I have co-authors who don’t know it and prefer to write in xy-pic.)


title: captionsetup redefines my margin captions nicely, but I want other captions to be default style

text: I'm writing a document with small and supporting figures placed in wide margins and larger figures in the text. I use the captions package and redefine the captions with               \captionsetup{     justification=raggedright     font=small}      and use this for my margin figure captions, which works fine. Since there are so few words on each line of the margin captions it looks ugly when Latex stretches the caption to cover the entire margin width, hence the raggedright. Now, the problem is that the \captionsetup also redefines my "normal" captions, so that they also become raggedright, which I don't want. So, the elements of my file are:               \usepackage{captions}          \addtolength{\evensidemargin}{1.5cm}      \addtolength{\textwidth}{-1.5cm}     \addtolength{\marginparwidth}{20pt}     \addtolength{\marginparsep}{10pt}          \captionsetup{     justification=raggedright     font=small}          \begin{document}          text text text ...          \begin{figure}     \begin{center}         \includegraphics{figure1}     \caption{figure 1 text, which I don't want to have a raggedright justification, since it looks quite good without it due to the many words that I can fit into one line in this type of caption.}         \end{center}     \end{figure}          some           more           text           about           something          \marginpar{\includegraphics[width=\marginparwidth]{figure2}     \captionof{figure}{Here for figure 2, the caption will look odd when few words are stretched across the marginparwidth}}          \end{document}      So, I want the \captionof to produce a different kind of caption than what caption does when used inside a figure environment. Thankful for any hints. I had a look at the tufte class but is seems to me that all captions have a raggedright justifcation in that class.


title: How to subtract two equations?

text: I am trying to subtract one equation from another but I can't get it to display the way that I want. This is what I have right now.               \begin{align*}     &y&=2x+5\\        -&&\\         &y&=3x+10\\\hline        &0&=-x-5         \end{align*}


title: How to automatically switch unit systems?

text: The question Why use a package to typeset units? made me think about something else: In non-scientific context one may have to provide data for persons using ... imperial units (shiver). But there may be two versions of a report, or the desire to put a secondary unit in parentheses following the primary unit value. Is there any package that treats this? So I'd write something like               $\SI{5}{\m/\s}$      And the output could be chosen to be any of e.g.               5 m/s     5 m/s (11.18 mph)     11.18 mph (18 km/h)      depending on a definition in the preamble?


title: Improve intercolumn spacing of this table

text: I'm trying to spruce up the appearance of this table:               \begin{tabular}{rr@{\hspace{2em}}rr@{\hspace{2em}}rr@{\hspace{2em}}rr}     \toprule     \multicolumn{2}{c@{\hspace{2em}}}{\textbf{Word C}}&     \multicolumn{2}{c@{\hspace{2em}}}{\textbf{Char C}}&     \multicolumn{2}{c@{\hspace{2em}}}{\textbf{Chess}}&     \multicolumn{2}{c}{\textbf{Matching}}\\     \multicolumn{2}{c@{\hspace{2em}}}{\textbf{9 trials}}&     \multicolumn{2}{c@{\hspace{2em}}}{\textbf{9 trials}}&     \multicolumn{2}{c@{\hspace{2em}}}{\textbf{12 trials}}&     \multicolumn{2}{c}{\textbf{12 trials}}\\     $N$&$V$&$N$&$V$&$N$&$V$&$N$&$V$\\     \midrule     10 &  1 & 12 &  3 & 16 &  3 & 4 & 0 \\     10 &  1 & 12 &  6 & 16 &  3 & 4 & 0 \\     10 &  1 & 12 &  9 & 16 &  5 & 4 & 1 \\     10 &  2 & 24 &  6 & 16 &  5 & 4 & 1 \\     % ... many more rows ...     \bottomrule     \end{tabular}      Here's what it currently looks like. The biggest problem is that there's too much horizontal space between each _N_ column and the corresponding _V_ column, and that space is of variable size among the four groups. ![screen shot of first four rows as rendered](http://i.stack.imgur.com/TDOSS.png) What I want is for there to be a fixed, small distance between each _N_ column and the corresponding _V_ column; a larger distance between the group headings; and the N/V column pairs to be centered under their heading. The numbers in each column should continue to be right-justified. How might I accomplish this? Note: all the elided rows contain numbers and only numbers, and there are no three-digit or larger numbers.


title: Change margins for all, but the first page

text: I've read Setting different margin sizes in different pages and Change \textwidth and \textheight in mid-document, but it doesn't work to well for my use case. I'm using the `geometry` and `fancyhdr` package. I did some 'hacking' to accomplish what I have right now, which pretty much is just that the first page has a big top-margin of 2.5in so that my `fancyhdr` fits in there nicely. I only want the header on the first page though, thus I set `thispagestyle{fancy}`. However, the margin still applies to the second page and I don't know how to change that. `newgeometry` wouldn't work, because I don't know where exactly the first page will end. Of course I could do some more hacking and just do trial&error, but I thought maybe there is some better way. In short: Is there a way to change the margin after the first page? Here is a MWE:               \documentclass[a4paper,10pt,oneside]{article}     \usepackage[english]{babel}     \usepackage[letterspace=150]{microtype}     \usepackage{fancyhdr}     \usepackage[top=2.5in,bottom=1.5in,right=1.5in,left=1.5in,headheight=95pt,headsep=2cm]{geometry}     \usepackage{lipsum}          \thispagestyle{fancy}     \pagestyle{empty}          \renewcommand{\headrulewidth}{0pt}          \fancyhead[C]{         \fontsize{22}{22}\scshape{I am\\ a\\ title}\\         \fontsize{12}{25}\scshape{Sub {\large\textperiodcentered} Title}     }          \begin{document}     \lipsum[1-2]     \lipsum[1-4]     \lipsum[1-2]     \end{document}


title: Using fancyhdr to handle headers of different sizes

text: I want to use `fancyhdr` in the `letter` document class to define a custom header for the first page only. I know that I can use `\fancypagestyle` to do this (as is discussed here), but the problem is that my first-page header contains several rows, and I don't want the following pages to contain white space at the top that results from the 'missing' header. Is there a fix for this?


title: enumitem conflicts with galician

text: The following code:               \documentclass{report}     \usepackage[T1]{fontenc}     \usepackage[latin1]{inputenc}     \usepackage[galician]{babel}     \usepackage[shortlabels]{enumitem}          \begin{document}     \chapter{Preguntas e respostas}     \begin{enumerate}     \item{}\textit{Non aparece a imaxe do fondo.}     Se construíches o KLettres.     \end{enumerate}     \end{document}      generates > Incomplete \iffalse; all text was ignored after line 11. The code works if I replace `enumitem` with `enumerate` or `galician` with `spanish`. But `enumitem` is needed to have unboxed style for descriptions. Is there any way to avoid this conflict?


title: How to wrap text in table with delimiter?

text: I have one long text in a column of table. I want to wrap this it into a cell by using delimiter "/". How can I do it in `longtable`?                        ABCDEFGHIJ/DATSET          Format:  ABCDEFGHIJ              DATSET


title: How can I use @author, @date, and @title after maketitle?

text: I want to include the values of author, date, and title in my use of fancyhdr in a document that uses `\maketitle`. Googling about, I saw that `@date`, etc. can access the date, etc., values set in the document preamble. It works fine, _provided_ `\maketitle` is not used. Here's a minimal working example:               \documentclass{article}          \title{Things about Stuff}     \author{Someone}     \date{Somewhen}          \begin{document}          %\maketitle  %Toggle comment and:          Now you see them, now you don't.          \makeatletter     \@date     \@author     \@title     \makeatother          \end{document}      So, 1) why does the use of `\maketitle` cause subsequent invocation of `@date`, etc. to yield nothing, and 2) how can I access the value of `\date`, etc after the use of `\maketitle`?


title: Year in bibliography with brackets

text: i want in my bibliography the year within brackets. How can I customize my style? I think I have to change the `FUNCTION {format.date}`, but how? regards               \documentclass[pdftex,a4paper,12pt,german]{book}     \usepackage[german,ngerman]{babel}      \usepackage[latin1]{inputenc}     \usepackage[T1]{fontenc}     \usepackage[authoryear]{natbib}     \begin{document}     \bibliographystyle{myplainnat}     \cite{Alonso.2004}     \bibliography{Literatur}     \end{document}                    @book{Alonso.2004,      author = {Alonso, Gustavo and Casati, Fabio and Kuno, Harumi and Machiraju, Vijay},      year = {2004},      title = {Web services: Concepts, architectures and applications},      url = {http://www.loc.gov/catdir/enhancements/fy0817/2004298168-d.html},      address = {Berlin},      publisher = {Springer},      isbn = {3540440089},      series = {Data-centric systems and applications}     }      Now my bibliography looks like this: > G. Alonso, F. Casati, H. Kuno, and V. Machiraju. 2004, Web services: > Concepts, architectures and applications. Data-centric systems and > applications. Springer, Berlin, 2004. But I want it looks like this: > G. Alonso, F. Casati, H. Kuno, and V. Machiraju. (2004), Web services: > Concepts, architectures and applications. Data-centric systems and > applications. Springer, Berlin, 2004. The First Year within brackets


title: How to reference an unnumbered section by writing a number?

text: I have an appendix with sections, e.g. `section*{Appendix 1: Measurment of X.Y.}`. I have set a label with `\label{appendix:1}`. Now if I reference that appendix via `\ref{appendix:1}` I get the number of the last numbered chapter before the appendix. This is because my appendix is also an unnumbered chapter. In my text I want the number of the appendix (each section* is a new appendix here) to be shown, like "in appendix 3 you can see...". How can I do that? EDIT: Here is a MWE:               \documentclass[         paper=a4,                        twoside=true,                    open=right,                      fontsize=12pt,                       parskip,                         headsepline,                     cleardoublepage=empty,           ]{scrbook}                        \usepackage{scrpage2}            \pagestyle{scrheadings}          \automark[section]{chapter}     \clearscrheadings                \ihead{}                         \chead{}                         \ohead{\headmark}                \ifoot{}                         \cfoot{}                         \clearscrplain      \ofoot[\pagemark]{\pagemark}     \setlength{\headheight}{1.1\baselineskip}          \usepackage[latin1]{inputenc}          \usepackage[         backend=bibtex,         ]{biblatex}          \usepackage[pdftex,                 colorlinks,                 linkcolor = black]{hyperref}          \usepackage[titletoc,title]{appendix}           \begin{document}          \tableofcontents              \chapter{Just a chapter}     Blabla     \chapter{Just another chapter}     Bla, bla, see appendix \ref{appendix:1}. Here should be a 1 for the first appendix and not the 2 for the last numbered chapter.               \chapter*{Appendix}          \begin{appendix}     \renewcommand{\thesection}{Anhang \arabic{section}:}     \addcontentsline{toc}{chapter}{Appendix}          \newpage     \section*{Appendix 1: Measurement X.Y.} \label{appendix:1}     \addcontentsline{toc}{section}{Appendix 1: Measurement X.Y.}     \chaptermark{Appendix}     \end{appendix}                    \end{document}


title: How do I get ConTeXt to produce pdf files in one directory, the aux files in a second, and take the .tex files from a third?

text: I want to be able to cleanly use my letterhead template with many different input files. I have created a shell scrip that invokes: `context --silent --purgeall --path=./img content/$1` But have found no arguments that could replace the less than optimal purgeall (as I don't actually want to purge them, I just don't want to see them). Are there any?


title: How to separate table content and table style

text: I want to know if there is a way to separate table / content for table style (think CSS). Like to have only data specification               \begin{tabular}     H1 & H2 & H3 & h4 \\     V1 & V2 & V3 & V4 \\     \end{tabular}      And then have the style somewhere to have the heading bold, the line filled, etc.


title: Styling  lots of tables

text: > **Possible Duplicate:**   >  How to separate table content and table style I am writing a document that include more than 50 tables. The tables can be divided into 5 groups with similar styles. How can I neatly, centrally and systematically style each group of tables? Is there any styling method similar to CSS?


title: Default Table Style

text: How can I create a default `table style`, which remains throughout the course of my document, lets say, for example, I want grid-lines and a gray shading behind the header-row, without having to explicitly format every table instance to this standard, is it possible to define these styling flavors in the preamble to affect all tables, in effect, on a global basis?


title: Can I have a path argument that contains spaces?

text: I'm trying to get biblatex to see where I have my .bib file located, but I have a space in the path to the file:               \addbibresource{~/Documents/My Project/TheBib.bib}      How do I specify a full path that includes a space? Is there a way to specify a relative path? * * * M(Not)WE, as requested:               \documentclass[nobib]{tufte-handout}          \usepackage{hyphenat}      \usepackage[backend=bibtex, natbib=true, citestyle=verbose]{biblatex}     \addbibresource{~/Documents/Projects/NoSpaces/Sources.bib} % Works     %\addbibresource{~/Documents/Projects/Some Spaces/Sources.bib} % Fails     %\addbibresource{"~/Documents/Projects/Some Spaces/Sources.bib"} % Fails          \begin{document}          Test.\cite{CiteKey}          \printbibliography           \end{document}


title: Multiple tikzpictures in a standalone document

text: I have a `standalone` document of the form:               \documentclass[tikz]{standalone}     %\documentclass{article}     %\usepackage{tikz}          \usetikzlibrary{positioning}          \newcommand{\tikzmark}[2]{\tikz[remember picture, baseline] \node[inner sep=0pt, outer sep=0pt, anchor=base] (#1) {#2};}          \begin{document}          \begin{tikzpicture}[remember picture]     \node (A) {     \begin{tabular}{ll}     1 & \tikzmark{two}{2} \\     3 & 4 \\     \end{tabular}};          \node[right=of A] (B) {     \begin{tabular}{ll}     5 & 6 \\     \tikzmark{seven}{7} & 8 \\     \end{tabular}};     \end{tikzpicture}     \begin{tikzpicture}[remember picture, overlay]     \draw[->] (two) -- (seven);     \end{tikzpicture}     \end{document}      The contents are displayed correctly when using the `article` `documentclass` instead of `standalone`. Can anyone suggest how to make it so that the contents of all `tikzpicture`s are displayed?


title: Ugly `\overline` raised to a power

text: I'm denoting the complement of the closure of the set `$A$` by `$\overline{A}^C$`. This looks ugly, though (the `C` is too high up and not far enough to the right)--might there be any quick fixes?


title: kpfonts, MnSymbol, eufrak and too many math alphabets

text: I'm having problems with `kpfonts`' `\mathfrak` and `MnSymbol`. This example produces the "too many math alphabets" error:               \documentclass{amsart}     \newcommand{\PrintMathFonts}{%       \typeout{*** Math fonts list ***}       \count255=0       \loop\ifnum\count255<16         \typeout{(\the\count255: \the\textfont\count255=\fontname\textfont\count255)}        \advance\count255 by 1       \repeat       \typeout{***}}     \usepackage{MnSymbol}     \usepackage[light,onlyrm,notext,noamsmath,notextcomp,sfmathbb,frenchstyle]{kpfonts}     \DeclareMathAlphabet\mathfrak{U}{euf}{m}{n}     \SetMathAlphabet\mathfrak{bold}{U}{euf}{b}{n}     \begin{document}       \PrintMathFonts       \begin{align*}         \mathfrak{Suca}\amalg A = x-2 \neq\mathcal{A}=\mathscr{F}=           \mathbb{R}=\mathsf{C} \rightarrow \rightrightarrows       \end{align*}     \end{document}      My goal is to disregard `kpfonts`' `\mathfrak` in favor of `eufrak`, but if I want to use `MnSymbol` as well then it doesn't work. I also tried the cmsy option of `MnSymbol`, and various `kpfonts` options but nada. p.s. the solution to this question kpfonts with eufrak doesn't seem to work and the solution provided by the other answer works, unless you load too many alphabets. p.p.s. I got the `\PrintMathFonts` trick from this answer Diagnosing the "too many math alphabets" error


title: How can I make an em-dash to allow for a linebreak on either side?

text: 1. How can I make an em-dash allow a linebreak on either side?   2. Optionally, how do I preserve the hyphenation points of the word on both sides? The following code allows for `refrigerator---refrigerator` to be line-broken only after the em-dash but nowhere else. (Regarding (2): The word "refrigerator" is hyphenated _re-frig-er-a-tor_ according to US hyphenation (see for example Merriam-Webster, which is also what LaTeX does.)               \documentclass{memoir}     \usepackage{lipsum}     \usepackage[pass,showframe]{geometry}          \begin{document}          \lipsum[1]          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \noindent qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqq refrigerator---refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator refrigerator          \end{document}      By the way, if someone knows of the most straightforward way to demonstrate such linebreaking behavior with code, please let me know (something with `\hspace*`? - I'm really looking for the best, shortest way to code such an example). You're welcome to edit my question to that effect.


title: Why does \noindent with CJK text prevent document from compiling?

text: I had a large linguistics example document with example text from many different languages, which stopped compiling when I transferred it to a new Mac (with all the same software and TeX distribution). The Chinese and Japanese sections were the culprits, yet Korean displayed fine (all using xeCJK). I finally tried removing \noindent (as well as the code indentation) from the beginning of the Chinese and Japanese sections and it suddenly worked fine. But why? MWE:               \documentclass[11pt]{article}          \usepackage{fontspec}          \usepackage[fallback]{xeCJK}          \setCJKmainfont{SimSun}          \setCJKfallbackfamilyfont{\CJKrmdefault}{AppleMyungjo}          \begin{document}          \section{Chinese (Traditional)}          構詞學          \section{Japanese}          語（ご）とは          \section{Korean}               \noindent 단어(單語)          \end{document}      This version works. With the \noindent before the Japanese and Chinese sections, it does not work.


title: Vertical bar strangely moving in a complex block matrix macro (XeTeX or pdfTeX)

text: The following code:               \documentclass[a4paper]{report}     \usepackage{amsmath,amsfonts,amssymb,multirow}     \usepackage{mathtools}     \newcommand{\sq}[1]{\left[#1\right]}     \DeclareSymbolFont{bbold}{U}{bbold}{m}{n}     \DeclareSymbolFontAlphabet{\mathbbold}{bbold}     \newcommand{\blocks}[9][-10]{\!\!\begin{array}{cccc}%         #2&#3\hspace{-0.2cm}&%         \multicolumn{2}{r}{\multirow{2}{*}{\raisebox{-14pt}{\scalebox{1}[1.3]{\Huge{$\vert$}}}%         \hspace{0.2cm}\raisebox{#1pt}{\Huge{$#6$}}}}\\%         #4&#5\hspace{-0.2cm}\\[0.2em]%         \hline\multicolumn{2}{r}{\multirow{2}{*}{\raisebox{#9pt}{\Huge{$#7$}\hspace{-0.2cm}}}}&%         \multicolumn{2}{r}{\multirow{2}{*}{\raisebox{-5pt}{\scalebox{1}[1]{\Huge{$\vert$}}}%         \hspace{0.2cm}\raisebox{#9pt}{\Huge{$#8$}}}}\\\\%         \end{array}\!\!}          \begin{document}     $$\sq{\blocks[-13]{\cosh\theta_v}{-\sinh\theta_v}{\sinh\theta_v}{\cosh\theta_v}         {\mathbbold{0}}{\mathbbold{0}\quad\,\,\,}{\mathbbold{1}}{-7}}.$$     $$\sq{\blocks[-13]{\cosh\theta_v}{-\sinh\theta_v}{\sinh\theta_v}{\cosh\theta_v}         {\mathbbold{0}}{\mathbbold{0}\quad\,\,\,}{\mathbbold{1}}{1}}.$$     \end{document}      typesets to: ![enter image description here](http://i.stack.imgur.com/8h7GX.png) Why does that vertical bar on the "second" row move down as the multicolumn- multirows of that row move up? And why does this macro, with `cc|cc` in the array definition, create a vertical line that stops at the `\hline` and doesn't go below it?


title: Hyphenate term with numbers and white space within acronyms

text: I want to use the command `\hyphanation` to force latex keeping terms in the same line   The terms are for example **IAS 39** and **IFRS 9**.   I use acornyms for IAS and IFRS and let a white space between the numbers. In code it looks like this:                 \acs{IAS} 39 and \acs{IFRS} 9      In the preamble I insert this code:               \hyphenation{     IFRS 9     IAS 39     IAS 01     IAS 02}      But when I compile my document I get the error message that it is not a letter.   If I remove the numbers it works fine.      Now the questions:     1. How can I use this command with the needed whitespaces?      2. Can this command handle acronyms?    I know that I can use the `\mbox{}`command, but these terms appear very often, so it would be a high invest.      Thanks for you help!!


title: Group bibliography by year and show header as cventry in moderncv

text: My idea is to get the same output as in this previous post but with a different approach as the previous has some limitations. So the goal is to have the first reference of each year in my bibliography showing the correspondent year on the left, as it was a normal `cventry`. ![enter image description here](http://i.stack.imgur.com/09dCn.png) The problem is I have multiple bibliographies and I use multibib with `\newcites` so I can have different headings in each one of them (ex, "oral presentations", "poster presentations", etc). But because the previous approach removes the `thebibliography` environment I loss the heading information as well. I know that I could just simply insert a new heading manually but I would prefer a different solution (more automatic lets say). The previous post (one of the answers) suggested this code _"If you want each year to appear only for the first paper of that year"_               STRINGS {oldyear}          FUNCTION {year.or.none}     { 's :=         oldyear empty$          { s 'oldyear := s }          { s oldyear =              { "" }              { s 'oldyear := s }            if$          }         if$     }      I was wondering if one could use the `year.or.none` function and `biblabel` together and display the year (or none) in the following code line: `\renewcommand\bibliographyitemlabel{\@biblabel{XXX}}` * * * EDITED I Here is a mock-up of what I want to achieve: ![enter image description here](http://i.stack.imgur.com/3TvXT.png) Please let me know if you need the code I am using. Note that the years shown were added manually on Photoshop. * * * EDITED II The `.bst` file I used can be found here. I have made some modifications to achieve the final style I wanted. Below is a link to the actual bibliography style in use (because there is a limitation to the number of characters that can be used in this post I could not paste it here). https://www.dropbox.com/s/evvx9dr7qhpbz2h/simon_bonner_cv.bst


title: What is the best way to use Latex for literary documents?

text: I was wondering, just out of curiosity: what would be the best way to produce literature-related documents in Latex? I have only ever written technical and scientific documents myself, so I really don't know if there are some famous packages that can help while writing literary documents. I only know about the Memoir class which can be useful to typeset books, but are there other suggested packages?


title: Placing two nodes by relative positioning in TikZ

text: I want to draw something like this: ![enter image description here](http://i.stack.imgur.com/TBzDA.jpg) So I did the following:               \begin{tikzpicture}     \node[draw] (node1) {Long long long box};     \node[draw, below left=of node1] {short} edge[->] (node1);     \node[draw, below right=of node1] {box} edge[->] (node1);     \end{tikzpicture}      Then the result is: ![enter image description here](http://i.stack.imgur.com/a2jjw.png) I want to move the two short boxes just under the long box and within the length of the long box. I also like the two arrows straight vertical. How can I do this? I want to use relative positioning.


title: LaTeX doesn't break lines with capitalized words to the end properly

text: I have a text like: > Lorem ipsum dolor sit amet, consetetur BRANDNAME sadipscing elitr, sed diam > nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed > diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. And LaTeX breaks the lines like               Lorem ipsum dolor sit amet, consetetur BRANDNAME       sadipscing elitr, sed diam nonumy eirmod tem-       por  invidunt ut  labore et dolore magna ali-       quyam erat, sed diam voluptua. At vero eos et       accusam et justo duo dolores et ea rebum.      Instead I would it expect to do something like:               Lorem   ipsum   dolor   sit   amet,  consetetur       BRANDNAME sadipscing elitr, sed diam nonumy ei-       rmod tempor  invidunt ut labore et dolore magna       aliquyam erat,  sed diam voluptua.  At vero eos       et accusam et justo duo dolores et ea rebum.      I have no idea how to break latin syllables, but I hope the problem got obvious. The name has to be completely capitalized and not wrapped, but the layout should also not be destroyed. I'm using PdfLaTeX as compiler and the Harvard style. This problem only affects completely capitaized words at the end of a line. I'm a bit surprised that I didn't find anyone else encountering the same problem earlier...


title: Source code description in LaTeX

text: I have a problem concerning the creation of the name below a "Source code" (Listing) in LaTeX. When I have a figure I use:                      \begin{figure}[t]            \centering            \includegraphics{Figures/drawing.pdf}            \caption{Spoken Dialogue System}                 \label{fig:SLDS2}            \end{figure}      I see               Figure 4.5.: Spoken Dialog System      on the screen. However, when I could not figure out how to print               Listing.4.5 Java Code      below this framed code on the screen. What should I add to this code? The source code is as shown in the following:                    \begin{framed}          \begin{lstlisting}[frame=single, backgroundcolor=\color{light-gray}, basicstyle=\footnotesize\ttfamily, language=Java, numbers=left, numberstyle=\tiny                       \color{black}]                    [HERE IS THE JAVA CODE]            \end{lstlisting}            \end{framed}      Thanks a lot in advance!


title: How to resolve conflicts in symbol packages?

text: I want to use symbols from `wasysym` and `marvosym` packages:               \usepackage{wasysym}     \usepackage{marvosym}      but it gives an errors as both packages have the command of `\CheckedBox`. I do not want to use this command, but since both packages have it, it makes confusion for latex. How can I ignore one command to have both packages?


title: Alternating offsets for logical pages within larger physical pages

text: I'm typesetting a book using dblatex/XeLaTeX that will be printed 2-Up on 8.5x11 paper (double sided), then cropped to a smaller size and bound. I have external tools to take a pile of 5.5x8.5 pages and splice them together in the right order. The goal is to minimize the number of stack cuts and to use the factory-cut edge for what ends up being the outside and top of the finished book, which means that the logical pages need to be flush left for left pages, and flush right for right pages. The only way I've been able to make this work roughly the way I want is to specify the physical paper size (5.5x8.5) as the paper size, then specify a very wide inner and bottom margin. The only problem with this is that I'd like to be able to insert crop marks, which requires setting the page size to the logical page size. When I do this, xelatex flushes both left and right pages to the left—that is to say, the area outside the logical page size always has a wide margin on the right side regardless of whether it is a front page or a back page. This means that if I actually printed the document two-sided and cut the pages, I'd get only about half of the flip side because the front and back would not line up correctly. I've also looked into a couple of packages that are supposed to make this easier, but thus far, they all seem to operate under the assumption that logical pages should be centered on the physical page. Although that makes for reasonable looking output for draft purposes, it's wholly wrong for actual printing because instead of having to cut only two sides, you now have to cut all four. And if your cuts aren't exactly perfect, four-cut production results in a fairly significant amount of non-squareness. The packages that allow you to offset the pages from the center, if the descriptions are to be believed, always do so in the same direction on all pages, which makes those similarly less than helpful; to do it right, I'd need to specify a positive offset for odd pages and a negative offset for even pages. Which brings me to my two questions:   1. Are there any packages that provide full control over how logical pages are oriented on a physical page (separately for left-facing and right-facing pages)?   2. Is there a good way to draw lines at a specific absolute position relative to the top left physical corner of the page, entirely outside the scope of the text/content flow, without regards to any margin settings, and with different content on left and right pages?


title: How to put the table of contents in Arial

text: I have install the package for a font similar to Arial               \usepackage{helvet}     \renewcommand{\familydefault}{\sfdefault}       However, in the table of contents the name of my sections don't show in this font but the normal latex font. I have put some subsections in my text, in one of the section, and the title of the subsections in the table of contents appear in the font similar to Arial.


title: How to stop mathmode straddling two lines (without overfull boxes)?

text: I do not like it when my maths spills over onto a second line. For example, what I am currently doing spits out stuff like,               ...just some talking then we have some maths Aut(G)     < H/K and lo! it has spilled onto another line...      However, I feel that the following is much neater,               ...just some talking then we have some maths     Aut(G) < H/K and lo! it has not spilled onto another     line...      Is there anyway of getting LaTeX to do this for me? I thought the command `\mbox` would work, or putting `\relpenalty=10000' and`\binoppenalty=10000' in the preamble, but these are `dumb' and do not think - they will spit out,               ...just some talking then we have some maths Aut(G) < H/K     and lo! it has spilled onto another line, and has     gone into the margin...      and we get the overspill into the margin. This is also true of the other fixes I have seen when I've been searching. I was wondering if there was some sort of `intelligent' thing, a package I could use or something I could put in the preamble, which makes math mode stick to the margins but keeps a block of maths on the same line. Thanks in advance! (There are two other `obvious' fixes:   1. I could use double dollar signs or square brackets to put my maths on a line of its own. However, I _do_ use this for longer strings of maths, but for short things like Aut(G) < H/K this is just overkill and is distracting when you are reading it.   2. I could go through my document and look at every instance of this problem and either add words or take away words earlier in the paragraph to make the maths sit on one line. However, I am trying to write something which will render nicely using different class files, and this fix is very much dependent on the class file I will be using ('cause of font sizes, etc.))


title: Prevent page break when text exists before title in twocolumn enviornment

text: I have an article using the two column enviornment but the title and abstract in a single column which works fine like this:               \documentclass[a4paper, 11pt, twocolumn]{article}          \begin{document}          \twocolumn[         \maketitle         \begin{onecolabstract}         Here is my abstract...     \end{onecolabstract}]          \end{document}      I now need to add information BEFORE the title but it always causes a page break. I have tried this solution and a couple more, but it didn't work. Unfortunately, I am quite new to TeX and couldn't find a solution that worked.


title: Korean characters in article title

text: I'm writing a paper in English and need to include a few characters in Korean in the body and title. I've read several other posts and managed to get the Hangul to show up inside the body, but I can't get them to show up inside the title. I am using pdflatex and have all of the necessary fonts installed. Here's the minimum working example that shows the characters appearing in the body but not in the title on my system:               \documentclass[11pt]{article}          \usepackage[utf8x]{inputenc}     \usepackage[thai,english]{babel}     \addto\extrasthaicjk{\fontencoding{C90}\selectfont}          \makeatletter     \@namedef{opt@inputenc.sty}{utf8}     \makeatother     \usepackage{CJKutf8}          \newenvironment{Korean}{%       \CJKfamily{mj}}{}          \title{       Character does not show up here:        \begin{CJK}{UTF8}{mj}\begin{Korean}시험\end{Korean}\end{CJK}     }          \begin{document}     \maketitle          It works here  \begin{CJK}{UTF8}{mj}\begin{Korean}시험\end{Korean}\end{CJK}              \end{document}      I don't see any errors about the title, so I'm stuck on what to do. This is my first time including foreign script characters in a LaTeX, so any help would be much appreciated. Thanks!


title: Korean Characters Not Working

text: I set up hlatex (the package for compiling in Korean) but when I build the file, I end up getting ?? instead of 안녕. How do you fix this? MWE:               \documentclass{article}     \usepackage{hangul}     \begin{document}     testing 안녕     \end{document}      No errors come up. The word "testing" comes up, but "안녕" does not.


title: Macro for formatting names (initials or full name)

text: I want to write full names of authors in the LaTeX source, but assign different roles to them, and then via macro decide whether to print the full first name or just initials:               In the work of \artist{Iannis Xenakis}, as analysed by \researcher{John Doe}.      I think in the end I want as output:               In the work of Iannis Xenakis, as analysed by J Doe.      But I might want `J. Doe` or `John Doe` or just `Doe` -- and I want to keep this decision open, therefore the macros... I am using `biblatex`, but I don't want to use `\citeauthor` because often the mentions are not directly related to a particular paper cited. Nevertheless, maybe I can reuse some macros that come with `biblatex`? * * * Here is my idea: I see that `\DeclareNameFormat` might provide a good way to define custom formats. But how would a macro using such a format to insert the name into the text look like? Might I use `\citename{⟨key⟩}[⟨format⟩]{⟨name list⟩}`? I understand that `name list` would be my source name as above, but what should I use as key?


title: A button that runs an external program from a Beamer PDF presentation

text: I want to add a "run demo" button to a Beamer presentation (PDF file) that will launch an external Java application. Can this be done somehow - Embed an "exec" command inside a PDF using LaTeX/Beamer?


title: Start an external program from Beamer' presentation using PREVIEW Mac

text: I would like to be able to START or RUN an external program from within the presentation by clicking a link, using PREVIEW. Is this possible using Beamer package ? I am using Mac OS X Snow Leopard with Preview. for example : a link to an image in my drive that allow me to start it in preview app ... I found it but only works from within TEXSHOP not PREVIEW, here is an example :               \href[]{file:///Users/Alji/seg.jpg}{run}


title: Embedding videos using media9

text: I'm really new to LaTeX and I'm not very good with computers. I'm trying to put videos into my PDF's. I'm using `media9` and I've got the following going so far.               \usepackage{media9}            \includemedia[         width=0.6\linewidth,         height=0.45\linewidth,         addresource=/Users/tristanjohnson/Library/texmf/tex/latex/misc/media9/Ruinn.MP4,         activate=onclick,         deactivate=onclick,       ]{Movie}{Ruinn.MP4}          \mediabutton[ mediacommand=some_dice:playPause, overface=\color{blue}{\fbox{\strut Play/Pause}}, downface=\color{red}{\fbox{\strut Play/Pause}}     ]{\fbox{\strut Play/Pause}} \mediabutton[     mediacommand=some_dice:setSource [(random.mp4)] ]{\fbox{\strut random.mp4}} \mediabutton[     mediacommand=some_dice:setSource [(cube.mp4)] ]{\fbox{\strut cube.mp4}}      I merely copied and pasted the `mediabutton` stuff. When I hit "Typeset" it runs without any errors. But when I click the play button nothing happens. I want the video embedded in the PDF so other people can see the video without having to have the file locally. Help?


title: Remove vertical line in tabular head

text: I want to go from this:   ![Image with line](http://i.stack.imgur.com/FWe5e.png)      To:   ![enter image description here](http://i.stack.imgur.com/DtcOC.png) I have the following LaTeX:               \begin{tabular}{p{8cm}|c|c|c|c|c}     \textbf{Functionality} &     \rot{Old ICCS engine} &     \rot{Current ICCS engine} &     \rot{Confious system} &     \rot{OpenConf} &     \rot{START} \\          \hline          Customizable conference settings & & & & & \\          \end{tabular}      What should I do?


title: Inkscape and Latex Line Spacing

text: I have exported a figure from inkscape to latex using the .pdf_text method. Everything is working fine but I would like to be able to change the line spacing of the text which was exported. Any ideas?


title: Note below figure as long as the figure - all centered but note left-aligned

text: I have a similar problem with my figure that is scaled, so the footnote/text underneath will be as long as the linewidth not as long as the figure. the figure is in the center and I want a caption above it to be in the center too. But the explanation should stand below the figure and be just as long as the figure (LEFT-aligned). Caption gives me the text above the figure and the text goes outside the figure, too. Here is what I got:               % I tried this:     % but the text starts outside the figure \\     \begin{figure}[hp]\caption[]{Balancing Diagnostics Kernel}     \footnotesize\centering     \includegraphics[width=0.7\textwidth]{Gaus.pdf}     \item\emph{Notes:} This figure provides a graphical illustration of the common trend assumption. And again this figure provides a graphical illustration of the perfect approach for estimating something.     \end{figure}      Any idea for figures that are not textwidth but 0.7\textwidth? How do I get an explanation of the figure underneath a scaled figure so that it will be as short as the figure? This is similar to this problem, but the solutions do not work for scaled figures as it seems. Note below figure


title: Accessing pointers in LuaTeX

text: This code writes the subtype of disc nodes to the log file.               \documentclass{minimal}     \usepackage{fontspec}     \directlua{     show_hyph = function(head)       while head do         if head.id == 0 or head.id == 1 then % hlist, vlist           show_hyph(head.head)         elseif head.id == 7 then             % disc           texio.write_nl("Subtype " .. head.subtype)         end       head = head.next       end       return true     end     luatexbase.add_to_callback("post_linebreak_filter",show_hyph,"show_hyph")          }          \begin{document}     \begin{minipage}{1pt}       discretionary     \end{minipage}     \end{document}      The LuaTeX reference manual says in section 8.1.2.7 “disc nodes” > `pre` `<node>` pointer to the pre-break text How do I access this?


title: Xelatex, verbatim and hyphenation

text: I have the following problem with XeLatex, Russian language, hyphenation and verbatim. Consider the following tex file (text below). It is compiled with XeLaTex, and before verbatim hyphenation is OK, but after verbatim environment hyphenation is broken. I have tested it with english --- it works well. I am on Mac Os X with MacTex.               \documentclass[12pt]{article}     \usepackage{fontspec}     \usepackage{xunicode}     \usepackage{polyglossia}     \usepackage{xltxtra}     \setdefaultlanguage{russian}     \newfontfamily\cyrillicfont{Cambria}     \newfontfamily\cyrillicfontsf{Calibri}     \newfontfamily\cyrillicfonttt{Cambria}     \defaultfontfeatures{Ligatures=TeX}     \setmainfont{Cambria}     \setsansfont[Scale=MatchLowercase,Mapping=tex-text]{Calibri}          \title{Test}     \date{\today}     \begin{document}          \maketitle     %Everything is fine here     Цель данного текста — дать читателю краткое представление о языке     Python и его применении в реальных научных вычислениях. Не предполагается      какого-то предварительного знакомства с синтаксисом языка. Текст пока      является наброском личного опыта автора (пока не очень большого),      однако будет пополняться.               \begin{verbatim}     Some stupid text     \end{verbatim}     %No hyphenation here!     Цель данного текста — дать читателю краткое представление о языке     Python и его применении в реальных научных вычислениях. Не предполагается      какого-то предварительного знакомства с синтаксисом языка. Текст пока      является наброском личного опыта автора (пока не очень большого),      однако будет пополняться.          \end{document}


title: Add Latex font for figure labels, legends and equation annotations with .png and .eps figures

text: For exporting `eps` figures from Matlab i use `matlabfrag` and `laprint` functions so that i split the `psfrag` commands (`.tex`) and figure(`.eps`) streams. During the compilation using `pstool` or `auto-pst-pdf` packages, figures with `latex` text font are automatically added. But my question is : How to add figure labels,legends for `.png` figures similar to `psfrag`? As the `.png` is from third-party software. Can i convert `.png` to tagged `.eps` and then add text using `psfrag` commands? I prefer to save figures in tagged `eps` (`.eps` and `.tex`) instead of `.pdf` so that i can add latex font based on the `beamer` or `article` class used. I don't like to freeze the font of text in figures by using `PDF`.


title: How to export svg to tikz

text: I was wondering if anyone had managed exporting .svg files to TikZ code. I do not mean include an .svg file into a latex document, but rather to obtain the code of an image so you can then edit it with TikZ. I know that this has been done here: http://www.texample.net/tikz/examples/india-map/ using inkscape and an svg converter here: http://code.google.com/p/inkscape2tikz/ but I cannot reproduce it after installing inkscape. When I run inkscape, I get the following message on the console (I run it from the console): > (inkscape:8700): Gtk-CRITICAL **: gtk_misc_set_alignment: assertion > `GTK_IS_MISC (misc)' failed I can still import an image and export to TikZ path but I get the following error message in a pop-up window: > Inkscape encountered an internal error and will close now. Automatic backups > of unsaved documents were done to the following locations: /home/squeeze/New > document 1.2012_06_19_18_10_24.0.svg and the exported .tex file shows the following code which does not reproduce the image and compiles to a blank page:               \documentclass{article}     \usepackage[utf8]{inputenc}     \usepackage{tikz}          \begin{document}          \begin{tikzpicture}[y=0.80pt,x=0.80pt,yscale=-1, inner sep=0pt, outer sep=0pt]       \begin{scope}[cm={{2.4087301,0.0,0.0,3.1036527,(-508.27381,-1163.9469)}}]         \begin{scope}[cm={{1.25,0.0,0.0,-1.25,(213.2835,636.20725)}}]           \begin{scope}[scale=0.100]             \begin{scope}[cm={{2304.0,0.0,0.0,1195.2,(141.732,141.732)}}]             \end{scope}           \end{scope}         \end{scope}       \end{scope}          \end{tikzpicture}     \end{document}      Has anyone done it? I run Debian Squeeze; Inkscape is 0.47 and the forum on the inkscape-svg converter is not really active so I thought someone may have done it here. I do not wish to specifically use .svg; I use GIMP usually, so if there is such a way to do it in GIMP, I am happy to do it (even better). Here is an example of an `.svg` image that fails the above procedure: ![enter image description here](http://i.stack.imgur.com/ZNUvL.png)


title: Transparent background spanning several tikzpictures

text: I am trying to display a "forbidden sign" in the background of two tikzpictures (much like some kind of watermark). However, in the following MWE the "forbidden sign" is cut-off at some seemingly arbitrary horizontal line.               \documentclass{scrartcl}          \usepackage{tikz}     \usetikzlibrary{backgrounds,shapes}          \begin{document}     \noindent       \begin{tikzpicture}         \draw[green] (0.0, -5.0) rectangle (10.0, 0.0);       \end{tikzpicture}\\       \begin{tikzpicture}         \draw[blue] (0.0, -5.0) rectangle (10.0, 0.0);         \begin{pgfonlayer}{background}           \begin{scope}[opacity=0.5,transparency group,overlay]             \draw node[forbidden sign,                        minimum size=5cm,                        line width=2ex,                        draw=red,                        fill=white] at (5.0,0.0) {Test};           \end{scope}         \end{pgfonlayer}       \end{tikzpicture}     \end{document}      Do you have any idea how I can fix this behaviour?


title: Force itemize inside description onto a new line

text: I have an itemize inside a description, like this:               \documentclass[]{article}     \usepackage[vmargin=1in,hmargin=1in]{geometry}     \usepackage{enumitem}     \setlist[description]{style=nextline}          \begin{document}          \begin{description}       \item[Definition 1]       \begin{itemize}         \item One         \item Two         \item Three       \end{itemize}       \item[Definition 2]       \begin{itemize}         \item Four         \item Five       \end{itemize}     \end{description}          \end{document}      However, despite the `style=newline` (which works for normal text in a description item), the first item of the itemize is on the same line as the definition: ![Example rendering](http://i.stack.imgur.com/EYi2F.png) How can I force the itemize to begin on a new line? Ideally, I am looking for a solution I can put in an `options.sty` rather than an in-line solution involving mboxes etc. (the actual latex causing me a problem is being generated from reStructuredText via pandoc, however the snippet above reproduces the problem).


title: Double wrapfigure on the same paragraph

text: I am trying to add two images, one on the left and one to the right, in a wrapfigure manner. I would like it to look like that ![enter image description here](http://i.stack.imgur.com/gHPmo.png) Although my code works for the sirst image, I don't know why it isn't working for the second one. My code is               \documentclass{article}          \usepackage[english,greek]{babel}     \usepackage[iso-8859-7]{inputenc}     \usepackage{kerkis}     \usepackage{wrapfig}          \newcommand{\eng}[1]{\latintext#1\greektext}          \begin{document}           \begin{wrapfigure}[12]{l}{0.32\textwidth}         \vspace{-0.6cm}       \begin{center}         \includegraphics[width=0.3\textwidth]{pixel}       \end{center}     \end{wrapfigure}     Αυτός ο ανιχνευτής τροχιών χρησιμοποιείται για να μετρήσει και να καταγράψει τις τροχιές των σωματιδίων της δέσμης με μεγάλη ακρίβεια. Είναι κατασκευασμένος από έξι επίπεδα από αισθητήρες πυριτίου, παρόμοιους με τις κάμερες που διαθέτουν τα κινητά μας τηλέφωνα. Κάθε αισθητήρας αποτελείται από μικρές ψηφίδες(\eng{pixels}) με μέγεθος περίπου μισής ανθρώπινης τρίχας, με τις οποίες προσδιορίζεται η θέση του εκάστοτε σωματιδίου. Όπως ακριβώς το φως δίνει ένα σήμα στην κάμερα του κινητού μας τηλεφώνου, έτσι και τα σωματίδια δίνουν ένα σήμα σε αυτούς τους αισθητήρες. Συνδυάζοντας τις συντεταγμένες της θέσης από την οποία προήλθε το κάθε σήμα για τους έξι ανιχνευτές, μπορούμε να υπολογίσουμε με ακρίβεια την τροχιά του σωματιδίου. Το τηλεσκόπιο μπορεί να χρησιμοποιηθεί είτε ως ένας ανιχνευτής τροχιών ή ως ένα εργαλείο με το οποίο θα δοκιμαστεί ένας άλλος ανιχνευτής τροχιών.      \begin{wrapfigure}{r}{0.32\textwidth}         %vspace{-0.6cm}       \begin{center}         \includegraphics[width=0.3\textwidth]{tracker}             \caption{(Πηγή:\eng{DESY})}             \label{fig:tracker}       \end{center}     \end{wrapfigure}     Στo σχ. \ref{fig:tracker} οι ανιχνευτές τροχιών απειονίζονται με μπλε χρώμα ενώ ο υπό δοκιμή ανιχνευτής με κόκκινο.Μετά τον υπολογισμό της διαδρομής των σωματιδίων στους έξι ανιχνευτές του τηλεσκοπίου, η σύγκριση με την μέτρηση του υπό δοκιμή ανιχνευτή θα δείξει με πόση ακρίβεια μπορεί να μετρήσει.          \end{document}      My output is ![enter image description here](http://i.stack.imgur.com/OUkVN.png) What is done wrong here? **EDIT** If I add some more code I get this terrible result               \documentclass{article}          \usepackage[english,greek]{babel}     \usepackage[iso-8859-7]{inputenc}     \usepackage{kerkis}     \usepackage{wrapfig}          \newcommand{\eng}[1]{\latintext#1\greektext}          \begin{document}          \subsubsection*{Τηλεσκόπιο ψηφίδας έξι επιπέδων}          \begin{wrapfigure}[12]{l}{0.32\textwidth}         \vspace{-0.6cm}       \begin{center}         \includegraphics[width=0.3\textwidth]{pixel}       \end{center}     \end{wrapfigure}     Αυτός ο ανιχνευτής τροχιών χρησιμοποιείται για να μετρήσει και να καταγράψει τις τροχιές των σωματιδίων της δέσμης με μεγάλη ακρίβεια. Είναι κατασκευασμένος από έξι επίπεδα από αισθητήρες πυριτίου, παρόμοιους με τις κάμερες που διαθέτουν τα κινητά μας τηλέφωνα. Κάθε αισθητήρας αποτελείται από μικρές ψηφίδες(\eng{pixels}) με μέγεθος περίπου μισής ανθρώπινης τρίχας, με τις οποίες προσδιορίζεται η θέση του εκάστοτε σωματιδίου. Όπως ακριβώς το φως δίνει ένα σήμα στην κάμερα του κινητού μας τηλεφώνου, έτσι και τα σωματίδια δίνουν ένα σήμα σε αυτούς τους αισθητήρες. Συνδυάζοντας τις συντεταγμένες της θέσης από την οποία προήλθε το κάθε σήμα για τους έξι ανιχνευτές, μπορούμε να υπολογίσουμε με ακρίβεια την τροχιά του σωματιδίου. Το τηλεσκόπιο μπορεί να χρησιμοποιηθεί είτε ως ένας ανιχνευτής τροχιών ή ως ένα εργαλείο με το οποίο θα δοκιμαστεί ένας άλλος ανιχνευτής τροχιών.      \begin{wrapfigure}{r}{0.32\textwidth}         %\vspace{-4cm}       \begin{center}         \includegraphics[width=0.3\textwidth]{tracker}             \caption{(Πηγή:\eng{DESY})}             \label{fig:tracker}       \end{center}     \end{wrapfigure}     Στo σχ. \ref{fig:tracker} οι ανιχνευτές τροχιών απειονίζονται με μπλε χρώμα ενώ ο υπό δοκιμή ανιχνευτής με κόκκινο.Μετά τον υπολογισμό της διαδρομής των σωματιδίων στους έξι ανιχνευτές του τηλεσκοπίου, η σύγκριση με την μέτρηση του υπό δοκιμή ανιχνευτή θα δείξει με πόση ακρίβεια μπορεί να μετρήσει.          \subsubsection*{Θερμιδόμετρο Κρυσταλλικού Μολύβδου}          {Καλορίμετρο είναι ένας ανιχνευτής ο οποίος μετρά τις ενέργειες και τις θέσεις των προσπίπτοντων σωματιδίων. Για παράδειγμα, ένα ηλεκτρόνιο θα δημιουργήσει έναν ηλεκτρομαγνητικό καταιγισμό, εναποθέτοντας όλη του την ενέργεια, επιτρέποντας με αυτόν τον τρόπο μια ακριβή μέτρησή της. Τα πιο βαριά σωματίδια θα δημιουργήσουν και αυτά σήμα αλλά η ενέργεια που εναποθέτουν είναι σημαντικά μικρότερη από αυτήν των ηλεκτρονίων. Μετρώντας αυτήν την ενέργεια, τα σήματα που έχουν προέλθει από ηλεκτρόνια μπορούν να διαχωριστούν από τα αντίστοιχα των μιονίων, καονίων, πιονίων ή πρωτονίων. Παρά το γεγονός ότι μπορούν να χρησιμοποιηθούν σαν ανιχνευτές θέσης, ο προσδιορισμός είναι λιγότερος ακριβής.}          \subsubsection*{Ανιχνευτής ((Καλαμάκι)) τεσσάρων επιπέδων}          Αυτός ο ανιχνευτής τροχιών αποτελείται από μεταλλικούς κυλίνδρους( ((καλαμάκια)) ) οι οποίοι είναι γειωμένοι ενώ ανάμεσά τους υπάρχει αέριο. Στο κέντρο του κάθε κυλίνδρου υπάρχει ένα λεπτό μεταλλικό σύρμα, το οποίο βρίσκεται σε υψηλό δυναμικό. Αν ένα φορτισμένο σωματίδιο διαπεράσει τον κύλινδρο, θα ιονίσει το αέριο και ηλεκτρόνια θα κινηθούν προς το θετικό δυναμικό όπου θα δημιουργήσουν ένα σήμα. Ο αριθμός των συρμάτων καθώς και ο χρόνος ολίσθησης από το πέρασμα του σωματιδίου μέχρι τον χρόνο άφιξης του σήματος, θα οδηγήσει σε μια ακριβή μέτρηση της θέσης. Τα τέσσερα επίπεδα επιτρέπουν  μια ακριβή μέτρηση της τροχιάς του σωματιδίου.          \end{document}      The result is ![enter image description here](http://i.stack.imgur.com/mnbAZ.png)