title: TikZ circle size

text: Please which keys may I use to get the circles in the following two categories of the same size? `minimum size` and `inner sep` don't improve the output. Please, if needed, use any looping macro of your choice.               \begin{document}     \begin{tikzpicture}[scale=.8,auto=left,every node/.style={circle,thick}]     \foreach \x/\y in {a/{-1,-2},b/{1,-2},c/{2,-1},d/{2,1},e/{1,2},       f/{-1,2},g/{-2,1},h/{-2,-1}}{       \node (\x) at (\y) [fill=blue!20,draw=yellow] {\x};     }     \foreach \x/\y {a/b,b/c,c/d,d/e,e/f,f/g,g/h,h/a}{       \draw [->] (\x)--(\y) node [midway,fill=red!20,draw=blue,] {\x--\y};     }     \end{tikzpicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/ikIhq.png)


title: exsheets \vary with tikz \coordinate

text: I'm trying to use exsheet's `\vary` command in a `tikzpicture`:               \documentclass{article}     \usepackage{tikz}     \usepackage{exsheets}     \begin{document}     \begin{tikzpicture}     \coordinate (point) at (0, \vary{1}{-1});     \end{tikzpicture}     \end{document}      but I get an error:               ! Illegal unit of measure (pt inserted).     <to be read again>                         \tex_long:D      l.6 \coordinate (point) at (0, \vary{1}{-1})                                                 ;      I've tried several different versions of this, including:               \coordinate (point) at (\vary{0,1}{0,-1});     \coordinate (point) at \vary{(0,1)}{(0,-1)};     \node at (0, \vary{1}{-1}) {};     \node at (\vary{0,1}{0,-1}) {};      But they all give me errors of one form or another. How do I get the `\vary` command to work with TiKZ?


title: Easiest way to plot a function with PGF/TikZ

text: I am new to TikZ and/or PGF (whatever the difference is :/), as you can see. Anyway, I need to draw the graph of the equation `x^(2/3) + y^(2/3) = a^(2/3)`, where `a = 2`.   Any suggestions? Here is what I have so far.               \documentclass{article}     \usepackage{amsmath,amssymb,amsfonts}     \usepackage{tikz}     \usepackage{pgfplots}          \begin{document}     Some text goes here.     \begin{center}     \begin{tikzpicture}[>=latex']         % Draw x-axis         \draw[very thick,->] (-3,0) -- (3.5,0)                 node[right] {$x$};          % Draw y-axis         \draw[very thick, ->] (0,-3) -- (0,3.5)              node[above] {$y$};         % Draw graph of equation             \draw[smooth, color=blue, domain=-3:3, ultra thick, line cap=butt, samples=400]                 plot (\x,{ (2^{2/3} - (\x)^{2/3} )^{3/2} });     \end{tikzpicture}     \end{center}     \end{document}


title: Serious problem with \widebar

text: I met across a serious problem using the `widebar` math command defined by Hendrik Vogt as an answer to question 16337. It worked fine until I used `\(wide)hat` in its argument. Here is a M(non)WE:               \documentclass[12pt, a4paper]{article}     \usepackage{amsmath}%          \makeatletter     \newcommand*\if@single[3]{%       \setbox0\hbox{${\mathaccent"0362{#1}}^H$}%       \setbox2\hbox{${\mathaccent"0362{\kern0pt#1}}^H$}%       \ifdim\ht0=\ht2 #3\else #2\fi       }     %The bar will be moved to the right by a half of \macc@kerna, which is computed by amsmath:     \newcommand*\rel@kern[1]{\kern#1\dimexpr\macc@kerna}     %If there's a superscript following the bar, then no negative kern may follow the bar;     %an additional {} makes sure that the superscript is high enough in this case:     \newcommand*\widebar[1]{\@ifnextchar^{{\wide@bar{#1}{0}}}{\wide@bar{#1}{1}}}     %Use a separate algorithm for single symbols:     \newcommand*\wide@bar[2]{\if@single{#1}{\wide@bar@{#1}{#2}{1}}{\wide@bar@{#1}{#2}{2}}}     \newcommand*\wide@bar@[3]{%       \begingroup       \def\mathaccent##1##2{%     %If there's more than a single symbol, use the first character instead (see below):         \if#32 \let\macc@nucleus\first@char \fi     %Determine the italic correction:         \setbox\z@\hbox{$\macc@style{\macc@nucleus}_{}$}%         \setbox\tw@\hbox{$\macc@style{\macc@nucleus}{}_{}$}%         \dimen@\wd\tw@         \advance\dimen@-\wd\z@     %Now \dimen@ is the italic correction of the symbol.         \divide\dimen@ 3         \@tempdima\wd\tw@         \advance\@tempdima-\scriptspace     %Now \@tempdima is the width of the symbol.         \divide\@tempdima 10         \advance\dimen@-\@tempdima     %Now \dimen@ = (italic correction / 3) - (Breite / 10)         \ifdim\dimen@>\z@ \dimen@0pt\fi     %The bar will be shortened in the case \dimen@<0 !         \rel@kern{0.6}\kern-\dimen@         \if#31           \overline{\rel@kern{-0.6}\kern\dimen@\macc@nucleus\rel@kern{0.4}\kern\dimen@}%           \advance\dimen@0.4\dimexpr\macc@kerna     %Place the combined final kern (-\dimen@) if it is >0 or if a superscript follows:           \let\final@kern#2%           \ifdim\dimen@<\z@ \let\final@kern1\fi           \if\final@kern1 \kern-\dimen@\fi         \else           \overline{\rel@kern{-0.6}\kern\dimen@#1}%         \fi       }%       \macc@depth\@ne       \let\math@bgroup\@empty \let\math@egroup\macc@set@skewchar       \mathsurround\z@ \frozen@everymath{\mathgroup\macc@group\relax}%       \macc@set@skewchar\relax       \let\mathaccentV\macc@nested@a     %The following initialises \macc@kerna and calls \mathaccent:       \if#31         \macc@nested@a\relax111{#1}%       \else     %If the argument consists of more than one symbol, and if the first token is     %a letter, use that letter for the computations:         \def\gobble@till@marker##1\endmarker{}%         \futurelet\first@char\gobble@till@marker#1\endmarker         \ifcat\noexpand\first@char A\else           \def\first@char{}%         \fi         \macc@nested@a\relax111{\first@char}%       \fi       \endgroup     }     \makeatother          \begin{document}          $  \widebar{f \circ \widehat{x}}  $          \end{document}      The .log file delivers this:               ! TeX capacity exceeded, sorry [grouping levels=255].     <to be read again>                         \macc@style      l.195 ...i(f)^*} = \widebar{f \circ \widehat{x}} =                                                        \widebar f \circ \widehat...     If you really absolutely need more capacity, …      Without the `\widehat` command, it's perfect: ![enter image description here](http://i.stack.imgur.com/biF1q.png) Can anyone help?


title: How to create fancy table of equations (to be typeset before the equations are rendered in text)

text: Is there a way to create a command which adds to a table or otherwise typesets in a place specified by the user? Example of what I'm after               \documentclass{article}     \begin{document}     \tableofequations          \begin{equation}     e^{i\pi} = -1     \end{equation}\rememberequation{e^{i\pi}=-1}{Euler's Equation}          \end{document}      Where the `\tableofequations` command would render something like               %with \usepackage{array}     \begin{center}     \begin{tabular}{m{0.3\linewidth} m{0.3\linewidth} m{0.3\linewidth}}     Equation & Name & Page \\\hline     \[e^{i\pi} = -1\] & Euler's Equation & Page 1\\\hline     \end{tabular}     \end{center}      ![equation table](http://i.stack.imgur.com/HKzlY.png) The effect I'm after is _almost exactly_ recorded in this answer with the only difference being the facility to place the equation table before the equation is rendered (as a table of figures renders the captions before the figures are typeset). Possibly to be achevied through an auxilliary file, although I have almost no knowledge of how these work.


title: Customize Beamer navigational bar

text: The horizontal navigational bar of this beamer presentation               \documentclass[utf8,compress]{beamer}     \usetheme{Singapore}     \setbeamertemplate{mini frames}{}     \begin{document}           \section{1}     \subsection{a}     \frame{\frametitle{Beamer navigation}Frame text}      \subsection{b}     \frame{Frame text}      \subsection{c}     \frame{Frame text}      \section{2}     \frame{Frame text}     \section{3}     \frame{Frame text}          \end{document}      shows one entry for each section of the presentation (in this case 1,2 and 3). For my purposes -- rather than showing entries for each section -- I need to have entries for the subsections displayed, so that where it reads "1,2,3" now it will then read "a,b,c". I have been plowing through the Beamer manual, but without success. Suggestions anyone? Thanks. Harry


title: Automatically set the figure width depending on whether the layout is one or two column

text: I am wondering how do you usually deal with figure width when you are writing a paper. (use `\linewidth`, `\textwidth` ? others?) Maybe we can just define a "switch" and use it with `ifelse` package? (Assume that you are writing a `onecolumn` version, and you also want to know the `twocolumn` layout at the same time without adjusting the `\witdh` manually too often.) **EDIT**. LaTeX is quite "intelligent" to format the text content. Can we let it deal with figures the same way? That is, when we add a figure, we not only just set the `width=...`, but also add a tag for informing LaTeX that "I am setting this `width` according to `A4` paper `twocolumn`". Then when we change the layout to `onecolumn`, LaTeX knows how to handle (rescale). **EDIT**               \usepackage{ifthen}     \newboolean{figColumnTrueOneFalseTwo}     \setboolean{figColumnTrueOneFalseTwo}{false}     %\setboolean{figColumnTrueOneFalseTwo}{true}          % in main.tex     \ifthenelse {\boolean{figColumnTrueOneFalseTwo}}{     % for onecolumn here     }{     % for twocolumn here     }


title: How do I make the arrow -->-- using xymatrix?

text: I do not know any TikZ so I cannot use this post, which otherwise is precisely what I am looking for. So how do I make such a square? The best I could come up with was               \ar@{-}[r]^{\delta}|-{>}      but it doesn't look good and does not work on vertical lines/arrows. Now, having done this square my guess would be that the corners would be empty, that is, the edges would not meet each other. How do I fix that problem?


title: Different switch symbols in circuitikz?

text: I'm wondering if there are other commands associated with the switch symbol so that one doesn't have to specify if the switch is open or closed. I would like the switch symbol with two connectors and a line rather than the open switch (ospst) and closed switch (cspst). I've looked all over and can't seem to find any solution. Thanks


title: How to display numbers using comma as a thousands separator?

text: I want numbers like 5.5 million to be displayed using a comma as a thousands separator as "5,500,000". Is there a way to do this automatically, without having to manually put commas?


title: Dirtree pagebreak issue

text: I have a (rather long-ish) hierarchical structure, typeset with the `dirtree` package. However, I have some issues when breaking the tree over to a new page -- the line may protrude up to the very top of the sheet writeable area, extending into the headings area. Note that I used the headings here only to better illustrate the issue, they are not necessary to exemplify the problem. But I do have a similar page setup, and it looks particularly unpleasant with the horizontal rule being intersected by the tree lines. Here's an example:               \documentclass{article}     \usepackage{lipsum}     \usepackage{dirtree}     \usepackage{fancyhdr}          \fancyhf{}     \fancyhead[C]{\emph{\nouppercase{\rightmark}}}     \fancyfoot[C]{\thepage}     \renewcommand{\headrulewidth}{0.4pt}     \renewcommand{\footrulewidth}{0.4pt}     \pagestyle{fancy}     \renewcommand{\sectionmark}[1]{\markright{#1}}     \renewcommand{\subsectionmark}[1]{\markright{#1}}          \begin{document}     \lipsum[1-4]     \dirtree{%     .1 spam.     .2 eggs.     .2 ham.     .3 circus.     .3 parrot.     .4 knights.     .3 spamalot.     .4 ni.     .5 brian.     .5 vikings.     .2 meaning.     }     \end{document}      Now, the package documentation says that a command `\DTsplittree` is in the To-Do list, that will allow splitting the tree over several pages. Any ideas for a dirty hack or a workaround that I might be able to use in the meantime? I've used some other tricks from the book, like reducing the line spacing and playing with font size, and I guess I could split it in two a few smaller parts (which I will have to fit again between pages!) if I can't find another way of doing it. But I'm more interested in a TeXnical solution. **Update** Let's see if this will get answered if some 100 bonus rep is thrown at it.


title: What controls the encoding of the LaTeX log file – and how to change it?

text: I have a LaTeX document in UTF-8 encoding:               \documentclass{article}     \usepackage[utf8]{inputenc}              \usepackage[T1]{fontenc}                     \begin{document}       äääääääääääääääööööööööööööööööööööööüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüääääääääääääääääääääääääääääääääääüüüüüüüüüüüüüü     \end{document}      When compiling this with `pdflatex` on MacOS X in a terminal using an UTF-8 locale, the (expected) `overfull \hbox` warning comes out in Latin1 encoding – in the terminal as well as in the log file:               This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/MacPorts 2013_1) (format=pdflatex 2013.7.29)  2 SEP 2013 17:28     entering extended mode      restricted \write18 enabled.      %&-line parsing enabled.     **test          <SNIP>          Overfull \hbox (419.53918pt too wide) in paragraph at lines 7--8     []\T1/cmr/m/n/10 äääääääääääääääööööööööööööööööööööööüüüüüüüüüüüüüüüüüüüüüüüüü     üüüüüüüüüüüüüüüüüüüüüüüüüüüüüüüääääääääääääääääääääääääääääääääääüüüüüüüüüüüüüü           []          [1          {/opt/local/var/db/texmf/fonts/map/pdftex/updmap/pdftex.map}] (./test.aux) )      Here is how much of TeX's memory you used:      617 strings out of 494181      5593 string characters out of 6156676      52409 words of memory out of 5000000      3964 multiletter control sequences out of 15000+600000      4403 words of font info for 15 fonts, out of 8000000 for 9000      470 hyphenation exceptions out of 8191      23i,4n,17p,299b,113s stack positions out of 5000i,500n,10000p,200000b,80000s     {/o     pt/local/share/texmf-texlive/fonts/enc/dvips/cm-super/cm-super-t1.enc}</opt/loc     al/share/texmf-texlive/fonts/type1/public/cm-super/sfrm1000.pfb>     Output written on test.pdf (1 page, 12195 bytes).     PDF statistics:      13 PDF objects out of 1000 (max. 8388607)      8 compressed objects within 1 object stream      0 named destinations out of 1000 (max. 500000)      1 words of extra memory for PDF output out of 10000 (max. 10000000)      I am using a post-filter program for the log file (namely `pydflatex` by Olivier Verdier) that expects UTF-8 encoded input and, thus, breaks at this line. So what determines the encoding of the LaTeX log file – and how can I change it?


title: How to put two tables in a table* element so that the tables appear side by side in a two column layout scientific paper?

text: This is related to How to make a figure span on two columns in a scientific paper? In a table* element, I want to put two \tabular{} elements, and get them appear side by side. I will then need to caption them as (a) and (b) and create labels (for references in the text) and so forth. If I just use the table* element, the tables appear below each other and are centred across the two columns. EDIT: In response to TH: This is what I tried. Both tables still appear on the right column.               \begin{table*}     \subfloat[Before processing]{     \begin{tabular}{|c|c|c|c|c|}     \hline      Year & Month & Country & State & Impressions\tabularnewline     \hline     \hline      2007 & JAN & IN & TN & 3\tabularnewline     \hline      2007 & JAN & IN & TN & 1\tabularnewline     \hline      \end{tabular}     }          \begin{table}     \subfloat[After processing]{     \begin{tabular}{|c|c|c|c|c|}     \hline      Year & Month & Country & State & Impressions\tabularnewline     \hline     \hline      2007 & JAN & IN & TN & 7\tabularnewline     \hline      2007 & FEB & IN & KA & 13\tabularnewline     \hline      \end{tabular}     }     \caption{overall}     \end{table*}


title: Loss of figure subsection numbers when using mainmatter

text: I recently added `\frontmatter`, `\mainmatter`, etc. with the `\numberwithin` setting for my figures and tables into a document, but now my figures are no longer numbered by subsection on export. Inside LyX, they still show the correct numbering, but I lose the subsection number upon export. I am using the memoir package. Here is part of my preamble:               \setsecnumdepth{subsubsection}     \maxtocdepth{subsubsection}     \numberwithin{figure}{subsubsection}     \numberwithin{table}{subsubsection}      All numbering was working before inserting the `\...matter` statements.


title: how does \includegraphics from the graphicx get the size of a .jpg image

text: Is there someplace where I can read about how `\includegrapics` uses the metadata that is stored with a JPG image? I have carefully sized 80 images with Photoshop such that the Photoshop's ImageSize data shows the correct size in inches and a resolutions (300ppi) which calculates out to the same size in pixels. With `\includegraphics`, most of the images come out to be their specified size (in inches, and presumably in their underlying pixels) in the PDF file. However, about a dozen of the images which seem to be specified the same way in Photoshop output to the PDF much bigger than they should be. Is is possible that these non-working images were originally scanned at 600ppi (I've lost track of what happened during the scanning several years ago) rather than 300ppi and I resampled them with Photoshop to keep that same size in inches while reducing the resolution and thus the size in pixels? When I look at the metadata with another image processing program (FastStone Image Viewer) it looks correct. My goal is to avoid explicit specification of image width or whatever by sizing the images correctly so LaTeX output them correctly in their `\includegraphics` input mode. Thus, I am looking for what other bit of metadata `\incloudegraphics` may be finding that gets the wrong result for me. Thus my request for a pointer to how `\includegraphics` "does its thing." I have a two line program (between `\begin{document}` and `\end{document}`) and two image files (with seemly correct metadata) which demonstrate my problem (unless I am missing something).


title: Table without counting ampersands

text: I want a command like               \mytable{4}{ a & b & c & d & e & f}      would be the same as               \begin{tabular}{cccc}     a & b & c & d\\     e & f\\     \end{tabular}      and               \mytable{2}{ a & b & c & d & e & f}      would be the same as               \begin{tabular}{cc}     a & b\\     c & d\\     e & f\\     \end{tabular}


title: Windows LyX won't open a file created in Mac LyX

text: I created a lyX file yesterday on a Mac. It won't open in Lyx 2.0.7 on Windows. I get: Lyx_tempdir.HP7972/Buffer_convertLyXFormat.cr7972 is not a readable LyX document. I am pretty certain my file is not corrupted. I don't know the MAC version but it's up to date as I only installed it this week. My windows installation has Latex installed with Tex Live as i was advised that had better compatibility with Mac OS.


title: Biber error after MiKTeX update

text: After having updated Biber from 1.5 version to 1.8, while the build time, I'm getting errors on the `\begin{document}` of my latex code telling that `File ended while scanning use of \field.`. I've tried to compile the same full code on this site, and this have worked. Knowing that I'm on Windows 7 SP1 and using MiKTeX 2.9, how do I to fix this please? I've tried to use `Update (Admin)` of MiKTeX for updates, but, after doing this I still getting the same errors. # Full Log file. # Minimal Log file related to the below .tex code. .tex file               \documentclass[12pt,english,french]{report}     \usepackage[T1]{fontenc}     \usepackage[utf8]{inputenc}     \usepackage{babel} \usepackage{csquotes}% recommended in output (biblatex)      \usepackage[backend=biber, style=alphabetic]{biblatex}      \addbibresource{bibli.bib}      \usepackage{titletoc}          \begin{document}     \nocite{*}     \printbibliography     \addcontentsline{toc}{chapter}{Bibliographie}     \end{document}      small .bib file               @online{msdn2,         label    = {MSDN2},         title    = {Comparatif entre C\# et Visual Basic .NET},         author   = {Microsoft},         date     = {2014-01-01},         url      = {http://support.microsoft.com/kb/308470},         urldate  = {2014-04-12}     }


title: TikZ: Drawing a line from the origin to the edge of a circle

text: How can I draw a line from the origin to the edge of circle?               \documentclass{article}     \usepackage{tikz}     \usepackage{fp}     \usetikzlibrary{calc, arrows, fixedpointarithmetic}     \begin{document}     \begin{tikzpicture}[line cap = round, line join = round, >=triangle 45,     scale = 1.25, fixed point arithmetic]     \coordinate (O) at (0, 0);     \coordinate (P1) at ($(O) + (-30:1.5cm and .75cm)$);          \draw[-latex] (P1) arc (-30:310:1.5cm and .75cm) coordinate (P2);     \draw[-latex] (O) -- (0, 1.75) node[above, scale = .75] {\(\mathbf{h}\)};     \draw ($(P1)!.5!(P2)$) circle (.18cm) coordinate (P3);     %\draw[blue] (O) --  How to finish this?      \end{tikzpicture}     \end{document}      I don't know what the last coordinate should be to complete the line. I have tried:               ($(P3) + (-30:1.5cm and .75cm)$)      and something else but I can't quite remember what else it was. Any ways, it didn't work. After that, I want to draw a dashed line from the first edge of the circle to the other edge in line with the solid blue line.


title: Indenting and removing numbers of bibliography

text: I followed the instructions here on how to indent the second line of a bibliography, Indent second line of a bibliography but now I also want to remove the numbers as well. Can someone tell me how this is done?


title: Including a tikz figure with a reference to a table on file, problems with folder structure

text: I am trying to include a `tikz` figure in the chapter 6 of my thesis. I am using separate folders and .tex files for each chapter, as you may notice in the example. This means that in my main document I have the following code:               \input{H6}      Inside H6.tex, I have the following               \begin{figure}     \centering     \input{./H6Figs/Eyeartable.tikz}     \end{figure}      The folder structure in a nutshell:               Main folder:     main.tex     H6.tex       |        --H6 (folder)           Eyeartable.tikz           Eyear.dat      The file Eyeartable.tikz:               \begin{tikzpicture}          \begin{axis}[     ylabel={$Daily \; Energy \; [kWh]$},     xmin=-7, xmax=371,     ymin=-50, ymax=40,     axis on top,     width=\figurewidth,     height=\figureheight,     xtick={0,59,120,181,243,304},     xticklabels={Jan 1,Mar 1,May 1,Jul 1,Sep 1,Nov 1},     legend entries={Consumed,Generated,Exchanged},     xticklabel style={anchor=north east,rotate=45}     ]          \addplot[mark=none,color=blue] table[x index=0,y index=1,header=false] {"Eyear.dat"};      \addplot[mark=none,color=green!50.0!black] table[x index=0,y index=2,header=false] {"Eyear.dat"};      \addplot[mark=none,color=red] table[x index=0,y index=3,header=false] {"Eyear.dat"};                \end{axis}          \end{tikzpicture}      This figure shows perfectly in `qtikz`, but when trying to compile it in my document I get: > Package pgfplots Error: Could not read table file '"Eyear.dat" Any help would be greatly appreciated.


title: Palatino font size

text: I'm using Palatino for my dissertation, but 10pt is too small and 11pt is too large (looks childish). I would like to select something in between. Any suggestions on how to do this? Edit: following the other threads, there seem to be three answers:   1. (`pdflatex`, 11pt `memoir`, `fix-cm`, renew `\normalsize`): this only changes `\normalsize` (so not `\small`, `\huge`, etc.)              \documentclass[11pt,a4paper,twoside,openright]{memoir}     \renewcommand*{\rmdefault}{ppl}     \usepackage{fix-cm}     \renewcommand{\normalsize}{\fontsize{10.5pt}{12.5pt}\selectfont}     \begin{document}     {\tiny This is tiny}\\     {\scriptsize This is script size}\\     {\footnotesize This is footnote size}\\     {\small This is small}\\     {\normalsize This is normal size}\\     {\large This is large}\\     {\Large This is larger}\\     {\LARGE This is very large}\\     {\huge This is huge}\\     {\Huge This is very huge}     \end{document}        2. (`pdflatex`, 11pt `memoir`, `fix-cm`, `relscale`): this doesn't work at all (since you would need to use `\relscale{0.96}` whenever changing from `\normalsize` to `\small` or something)              \documentclass[11pt,a4paper,twoside,openright]{memoir}     \renewcommand*{\rmdefault}{ppl}     \usepackage{fix-cm,relsize}     \begin{document}     \relscale{0.96}     {\tiny This is tiny}\\     {\scriptsize This is script size}\\     {\footnotesize This is footnote size}\\     {\small This is small}\\     {\normalsize This is normal size}\\     {\large This is large}\\     {\Large This is larger}\\     {\LARGE This is very large}\\     {\huge This is huge}\\     {\Huge This is very huge}     \end{document}        3. (`lualatex`, 11pt `memoir`): this changes all type sizes (`\normalsize`, `\small`, `\huge`, etc.)              \documentclass[11pt,a4paper,twoside,openright]{memoir}     \usepackage{fontspec}     \setmainfont[Scale=0.96]{Palatino Linotype}     \begin{document}     {\tiny This is tiny}\\     {\scriptsize This is script size}\\     {\footnotesize This is footnote size}\\     {\small This is small}\\     {\normalsize This is normal size}\\     {\large This is large}\\     {\Large This is larger}\\     {\LARGE This is very large}\\     {\huge This is huge}\\     {\Huge This is very huge}     \end{document}      For example in my case, `\normalsize` was 10.91pt and afterwards 10.46pt. Perfect! Note also that in the third option, the system's Palatino font is used, while in the first two, URW Palladio is used. To conclude I would say that `lualatex` (or perhaps also `xelatex` etc.) is the way to go. The `\usepackage[scale=0.95]{tgpagella}` option mentioned in the comments also works, but this is specific to the font package. However, there is still an issue remaining: how to change the math type size? I'm using `\usepackage{lmodern}`.


title: Beamer: custom order of references

text: I usually include references in my beamer-presentation like this:               \begin{frame}         \frametitle<presentation>{References}             \bibliographystyle{acm}         \nocite{A}         \nocite{B}         \nocite{C}         \setbeamertemplate{bibliography item}[text]         \bibliography{../sources}     \end{frame}           However, for a talk I am going to give, I would prefer to have the two most important papers at the beginning (first references slide), followed by a second slide with the rest of the references. How can I achieve this WITHOUT writing everything myself using bibtex?


title: Is it possible to use tcolorbox in XeLaTeX?

text: This is a trivial color box, which provided by tcolorbox package:               \begin{tcolorbox}[colback=red!5!white,colframe=red!75!black,title=My nice heading]     This is another \textbf{tcolorbox}.     \tcblower     Here, you see the lower part of the box.     \end{tcolorbox}      In XeLaTeX, it works good in even pages, but cause overfull hbox in odd pages: ![Incorrect color box in XeLaTeX](http://i.stack.imgur.com/DMBEZ.jpg) The **twoside** class option has been activated and margin parameters are               \oddsidemargin=-10.4mm       \evensidemargin=-20.4mm      \topmargin=-35mm             \textwidth=190mm             \textheight=275mm       It appears OK in LaTeX. Is it possible to use correctly in XeLaTeX, too? Here is the minimal working example:               \documentclass[11pt,a4paper,twoside]{article}          \usepackage{xcolor}     \usepackage{tcolorbox}     \usepackage{bidi}              \oddsidemargin=-10.4mm       \evensidemargin=-20.4mm      \topmargin=-35mm             \textwidth=190mm             \textheight=275mm                 \begin{document}     Text test     \begin{tcolorbox}[colback=red!5!white,colframe=red!75!black,title=My nice heading]     This is another \textbf{tcolorbox}.     \tcblower     Here, you see the lower part of the box.     \end{tcolorbox}     \newpage     Text test     \begin{tcolorbox}[colback=red!5!white,colframe=red!75!black,title=My nice heading]     This is another \textbf{tcolorbox}.     \tcblower     Here, you see the lower part of the box.     \end{tcolorbox}     \end{document}


title: Empty body centered on the page and vertically splited

text: I want to have an empty page such that the body is centered. Next I want to have two `minipage`'s each half the width of the body and of its height, such that they will vertically split the body. Here is an illustration of what I want:               |-------------------|     | P                 |     | |---------------| |     | |  B1   | B2    | |     | |---------------| |     |                   |     |-------------------|      where `P` denotes the page and `B1` and `B2` are the two boxes whose union is exactly the body. Here is how far I got:               \documentclass{article}     \usepackage[%     showframe,paper=a4paper,noheadfoot,nomarginpar,vmargin=4cm,hmargin=2cm     ]%     {geometry}     \begin{document}     \pagestyle{empty}     \vbox{       \noindent       \fbox{         \begin{minipage}[c][\textheight][c]{0.5\textwidth}           Block 1         \end{minipage}       }       \fbox{         \begin{minipage}[c][\textheight][c]{0.5\textwidth}           Block 2         \end{minipage}       }     }     \end{document}      However, this is not perfect... It seems like `\textwidth` is too big, and therefore, the total width of the minipages is too big. Furthermore, the total height (`\textheight`) seems to be too big as well. How can I fix the code?


title: Use \textsc for \name and \section in moderncv

text: I am trying to use `\textsc` for name and section titles in moderncv template. However, the font seems weird. For example, looking at the following two examples, one for normal section title, one with `\textsc`:               \section{Education}     \section{\textsc{Education}}      Looks like `\textsc` also changes the default font. How can I maintain the default font at the same time have the ability to use `\textsc`? Similar problems happens in `\name` too. Any help is much appreciated. ![enter image description here](http://i.stack.imgur.com/x8J4x.png) **Updated:** A MWE can be seen as follows:               \documentclass[11pt,a4paper,sans]{moderncv}          \moderncvstyle{classic}     \moderncvcolor{blue}          \name{aaa}{bbb}          \begin{document}     \makecvtitle          \section{{Education}}     \section{\textsc{Education}}          \end{document}


title: Show three letters of authors' names in biblatex alphabetically

text: I would like to install the new version of the style but I cannot remember the hack I did in order to display more letters from the author's names. The hack was directly into the `.bst` or `.cst` files. In any case, my citations appear as, > MijKomSpi09b where there is three authors and for each one, I wish to display their first three letters. Beyond three authors, I just want the first three letters of the first authors (like `Mij+09`). Is it possible to do that directly in the `.tex` file? Currently my setting is                \usepackage[backend=biber, sorting=nyt, citestyle=ieee-alphabetic,                  bibstyle=ieee-alphabetic,  maxnames=3,minnames=1,maxbibnames=99]{biblatex}      and this displays the first three letters only when there is one authors. For multiple authors, it is of the form `AHW09b`.


title: TikZ error for externalized graphics but output is correct

text: This is not an MWE per se, but it is the code I boiled the problem down to. Note: it does not produce an error. The issue is that once I somehow managed to get an error for any TikZ or pgfplots graphic (due to any sort of mishap: missing bracket, semicolon or any other thing I suppose), the error message "`--shell-escape -halt- on-error -interaction=batchmode -jobname`" (and so forth...) comes up. Yet all graphics and edits to them get produced properly as far as I can tell. But the message won't go away. **I'm at a point where I'm totally clueless about it all. Is there a catch in connection to externalized TikZ/pgfplots-graphics?** Any help or hints would be greatly appreciated. :) ## Notes The error message only goes away if I remove/comment out   * the `footnotetext`\- and `\addtocounter`-commands after each `figure` with a `tikzpicture` in it or   * `\tikzexternalize` Does the editor (TeXstudio) make a difference?   * No, the problem appears in the same manner, whether I hit `F1` in TeXstudio or run pdflatex from the command line. ## Log for running pdflatex from Windows' cmd http://pastebin.com/vHqE5isd ## Log for running pdflatex --shell-escape from Windows' cmd http://pastebin.com/0JZCij4T ## MWE               \documentclass[     a4paper     ]{scrartcl}          \usepackage{         newtxtext,         amsmath,         subcaption,         biblatex     }     \usepackage[T1]{fontenc}     \usepackage[utf8]{inputenc}          \usepackage{tikz}     \usetikzlibrary{         external,     }     \tikzexternalize          \listfiles          \begin{document}     \begin{figure}[tp]         \begin{minipage}[b]{0.48\linewidth}             \centering             a\\             \begin{tikzpicture}             \draw (0,0) rectangle (1,1);             \end{tikzpicture}             \subcaption[Something short.]{Something longer. So there is some text.\footnotemark\footnotemark}         \end{minipage}         \hfill         \begin{minipage}[b]{0.48\linewidth}             \centering             b\\             \begin{tikzpicture}             \draw (0,0) rectangle (1,1);             \end{tikzpicture}             \subcaption[Text.]{Some longer text and a few words}         \end{minipage}     \end{figure}     \addtocounter{footnote}{-2}     \footnotetext{\cite[Cp.][12]{Smith}}     \addtocounter{footnote}{1}     \footnotetext{\cite[Cp.][23]{Jones}}                    \end{document}      ## Preamble relating to TikZ and pgfplots with style definitions               %% TikZ          \usetikzlibrary{         external,         plotmarks,         math,         calc,trees,shadows,positioning,arrows,chains,         decorations.pathreplacing,         decorations.pathmorphing,         decorations.shapes,         decorations.text,         shapes,         shapes.geometric,         shapes.symbols,         matrix,         patterns,         intersections,         fit     }     \tikzexternalize          \pgfdeclarelayer{background layer}     \pgfdeclarelayer{foreground layer}     \pgfsetlayers{background layer,main,foreground layer}          %% pgfplots          \usepgfplotslibrary{         groupplots,         external         }          \pgfplotsset{     every axis/.append style={     %%     %tick label style = {font=\sffamily\small\sansmath},     %every axis label = {font=\sffamily\small\sansmath},     %legend style = {font=\sffamily\small\sansmath},     %label style = {font=\sffamily\small\sansmath},     %     xmajorgrids={true},     ymajorgrids={true},     xminorgrids={true},     yminorgrids={true},     %     %line width=1pt,     %thick,     %     minor tick num=1,     %axis lines=middle,     %tick align=center,     compat=1.10,     },     every tick/.append style={     black,     thick     },     /pgf/number format/.cd,     use comma,     1000 sep={\,},     }          \tikzexternalize      ## File list               *File List*     scrartcl.cls    2013/12/19 v3.12 KOMA-Script document class (article)     scrkbase.sty    2013/12/19 v3.12 KOMA-Script package (KOMA-Script-dependent bas     ics and keyval usage)      scrbase.sty    2013/12/19 v3.12 KOMA-Script package (KOMA-Script-independent b     asics and keyval usage)       keyval.sty    1999/03/16 v1.13 key=value parser (DPC)     scrlfile.sty    2013/12/19 v3.12 KOMA-Script package (loading files)     tocbasic.sty    2013/12/19 v3.12 KOMA-Script package (handling toc-files)     scrsize11pt.clo    2013/12/19 v3.12 KOMA-Script font size class option (11pt)     typearea.sty    2013/12/19 v3.12 KOMA-Script package (type area)     newtxtext.sty    2014/04/07 v1.25     fontaxes.sty    2014/03/23 v1.0d Font selection axes      xkeyval.sty    2012/10/14 v2.6b package option processing (HA)      xkeyval.tex    2012/10/14 v2.6b key=value parser (HA)     etoolbox.sty    2011/01/03 v2.1 e-TeX tools for LaTeX         etex.sty    1998/03/26 v2.0 eTeX basic definition package (PEB)      fontenc.sty        t1enc.def    2005/09/27 v1.99g Standard LaTeX file     textcomp.sty    2005/09/27 v1.99g Standard LaTeX package       ts1enc.def    2001/06/05 v3.0e (jk/car/fm) Standard LaTeX file      amsmath.sty    2013/01/14 v2.14 AMS math features      amstext.sty    2000/06/29 v2.01       amsgen.sty    1999/11/30 v2.0       amsbsy.sty    1999/11/29 v1.2d       amsopn.sty    1999/12/14 v2.01 operator names     subcaption.sty    2013/02/03 v1.1-62 Sub-captions (AR)      caption.sty    2013/05/02 v3.3-89 Customizing captions (AR)     caption3.sty    2013/05/02 v1.6-88 caption3 kernel (AR)     biblatex.sty    2013/11/25 v2.8a programmable bibliographies (PK/JW/AB)     biblatex2.sty    2013/11/25 v2.8a programmable bibliographies (biber) (PK/JW/AB     )     kvoptions.sty    2011/06/30 v3.11 Key value format for package options (HO)      ltxcmds.sty    2011/11/09 v1.22 LaTeX kernel commands for general use (HO)     kvsetkeys.sty    2012/04/25 v1.16 Key value parser (HO)     infwarerr.sty    2010/04/08 v1.3 Providing info/warning/error messages (HO)     etexcmds.sty    2011/02/16 v1.5 Avoid name clashes with e-TeX commands (HO)     ifluatex.sty    2010/03/01 v1.3 Provides the ifluatex switch (HO)       logreq.sty    2010/08/04 v1.0 xml request logger       logreq.def    2010/08/04 v1.0 logreq spec v1.0       ifthen.sty    2001/05/26 v1.1c Standard LaTeX ifthen package (DPC)          url.sty    2013/09/16  ver 3.4  Verb mode for urls, etc.       blx-dm.def     biblatex-dm.cfg     blx-compat.def    2013/11/25 v2.8a biblatex compatibility (PK/JW/AB)     biblatex.def         standard.bbx    2013/11/25 v2.8a biblatex bibliography style (PK/JW/AB)      numeric.bbx    2013/11/25 v2.8a biblatex bibliography style (PK/JW/AB)      numeric.cbx    2013/11/25 v2.8a biblatex citation style (PK/JW/AB)     biblatex.cfg          fontenc.sty        t1enc.def    2005/09/27 v1.99g Standard LaTeX file     inputenc.sty    2008/03/30 v1.1d Input encoding file         utf8.def    2008/04/05 v1.1m UTF-8 support for inputenc        t1enc.dfu    2008/04/05 v1.1m UTF-8 support for inputenc       ot1enc.dfu    2008/04/05 v1.1m UTF-8 support for inputenc       omsenc.dfu    2008/04/05 v1.1m UTF-8 support for inputenc       ts1enc.dfu    2008/04/05 v1.1m UTF-8 support for inputenc         tikz.sty    2013/12/13 v3.0.0 (rcs-revision 1.142)          pgf.sty    2013/12/18 v3.0.0 (rcs-revision 1.14)       pgfrcs.sty    2013/12/20 v3.0.0 (rcs-revision 1.28)     everyshi.sty    2001/05/15 v3.00 EveryShipout Package (MS)       pgfrcs.code.tex      pgfcore.sty    2010/04/11 v3.0.0 (rcs-revision 1.7)     graphicx.sty    1999/02/16 v1.0f Enhanced LaTeX Graphics (DPC,SPQR)     graphics.sty    2009/02/05 v1.0o Standard LaTeX Graphics (DPC,SPQR)         trig.sty    1999/03/16 v1.09 sin cos tan (DPC)     graphics.cfg    2010/04/23 v1.9 graphics configuration of TeX Live       pdftex.def    2011/05/27 v0.06d Graphics/color for pdfTeX       pgfsys.sty    2013/11/30 v3.0.0 (rcs-revision 1.47)       pgfsys.code.tex     pgfsyssoftpath.code.tex    2013/09/09  (rcs-revision 1.9)     pgfsysprotocol.code.tex    2006/10/16  (rcs-revision 1.4)       xcolor.sty    2007/01/21 v2.11 LaTeX color extensions (UK)        color.cfg    2007/01/18 v1.5 color configuration of teTeX/TeXLive      pgfcore.code.tex     pgfcomp-version-0-65.sty    2007/07/03 v3.0.0 (rcs-revision 1.7)     pgfcomp-version-1-18.sty    2007/07/23 v3.0.0 (rcs-revision 1.1)       pgffor.sty    2013/12/13 v3.0.0 (rcs-revision 1.25)      pgfkeys.sty          pgfkeys.code.tex      pgfmath.sty          pgfmath.code.tex       pgffor.code.tex         tikz.code.tex     pdftexcmds.sty    2011/11/29 v0.20 Utility functions of pdfTeX for LuaTeX (HO)        ifpdf.sty    2011/01/30 v2.3 Provides the ifpdf switch (HO)      english.lbx    2013/11/25 v2.8a biblatex localization (PK/JW/AB)       ts1cmr.fd    1999/05/25 v2.5h Standard LaTeX font definitions      t1ntxrx.fd    2012/12/25 v1.0     supp-pdf.mkii     epstopdf-base.sty    2010/02/09 v2.5 Base part for package epstopdf       grfext.sty    2010/08/19 v1.1 Manage graphics extensions (HO)     kvdefinekeys.sty    2011/04/07 v1.3 Define keys (HO)     epstopdf-sys.cfg    2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live      ***********


title: Bullets disappear in nested lists when using \newenvironment

text: I am trying to typeset interviews using lists. I have created environments for questions and answers to style the `\item`s and their contained text. However, if I try to use these environments within a nested list (or a covington example), all the item labels but the first one suddenly disappear. The code:               \documentclass[12pt,notitlepage,a4paper]{article}          \newenvironment{question}{\item[Q:]}{}     \newenvironment{answer}{\item[A:]}{}          \begin{document}          \begin{itemize}     \item     \begin{itemize}     \begin{question} Text \end{question}     \begin{answer} Text \end{answer}     \end{itemize}     \end{itemize}          \end{document}      Should produce:               * Q: Text       A: Text      But `A:` is missing:               * Q: Text          Text      If use a plain `\item` instead of my `question` environment, all goes well. Does anyone know how to solve this problem?


title: Why is it not possible to embed \if construction in docstrip

text: I would like to create a DTX files which could be compiled in two different ways depending of a user's choice. One way to get only the user documentation, and another to get user documentation **and** code documentation. I do not want to use `\StopEventually` since in the second case I do not want to have theses documentations separated in two differents parts, but mixed all along the documentation. In order to that I setup a DTX template different and simpler than those generally used, _i.e._ the one from TeX Hacks or from Joseph Wright. Everything works fine in almost all cases but not in one case I isolated and reduced to this chunk of LaTeX code:               % \newif\ifcode     % \codefalse ^^A Change to \codetrue to include code documentation          % \iffalse     %<*documentation>     \documentclass{ltxdoc}     \begin{document}      \DocInput{\jobname.dtx}     \end{document}     %</documentation>     %<*latex>     % \fi          % some user command explanations     % \ifcode     % some code explanations     %    \begin{macrocode}     \newif\ifcadre     \cadretrue     \renewcommand{\maketitle}     {       \ifcadre         \framebox{title}       \else         {title}       \fi     }     %    \end{macrocode}     % \fi     % some other text     % \iffalse     %</latex>     % \fi     \endinput      When I try to compile that with `pdflatex` I get the following error               ! Too many }'s.     l.27 }          ?      When line 2 is changed from `\codefalse` to `\codetrue` everything works fine. When `\ifcadre`, `\else` and `\fi` lines are removed, everything works fine in both cases (with `\codetrue` or `\codefalse` in line 2). Did I miss something in docstrip documentation ?


title: tikz+matlab2tikz

text: I'm quite new at latex, but finding it awesome. Yet when it comes to figures things do get a bit tiresome. I'm currently linking a big amount of matlab plots with latex articles with `matlab2tikz`. After downsampling the figures quite a lot, it finally got correctly linked. But the thing is that now I need to control the display properties of the figures in the document WITHOUT changing stuff in the document of the picture itself. The way I include the plot in latex is:               \input{/path/fig.tex}     \FloatBarrier      But I can't control very well scale, centering and so on.. tried with construction like:               \begin{figure}[scale=0.5]     \center     \input{/path/fig.tex}     \end{figure}      or the same with a `{tikzpicture}`... Maybe setting this kind of parameters in the `matlab2tikz` command itself, in the Matlab script. Well, any help is appreciated..


title: Creating sections each with title pages in beamers slides

text: I'm writing up my dissertation defense slides. I would like to have a title page for each of three chapters. Specifically, I want to be able to replicate the box that the dissertation title is in for each of the chapters as I get to that section. Things I don't want: my name, university, and the date. So how do I get the title of each chapter in the same style box that the main title is in? Thanks in advance.               \title{This style box is what I want to replicate three other times in the slides.}     \author[Not needed]     \institute{I don't want this.}     \date{I don't want this either}


title: how to make TOC's 'List of Figure' link to title not the list itself

text: I made a table of content with clickable links. Links to chapters and sections work fine: when I click on them I see the chapter title and its content. On the other hand, when I click to the list of figures, tables and content itself, I get to the text of the list rather then see the whole page with the title "List of Figures". Can I get 'list of figure' behave in the same way of chapters? EDIT: it might be a problem on how I compile the code as other users with the same pdf viewer say it already works as I would like. Here's a code sample.               \documentclass{book}          \usepackage{color}     \usepackage{hyperref}     \hypersetup{         colorlinks=true,         citecolor=black,         filecolor=black,         linkcolor=blue,         urlcolor=black     }               \begin{document}          \tableofcontents     \addcontentsline{toc}{chapter}{Content}          \newpage ~          \listoffigures     \addcontentsline{toc}{chapter}{List of Figures}          \listoftables     \addcontentsline{toc}{chapter}{List of Tables}          \newpage ~     \chapter{Intro}          \begin{figure}     \caption{Bla Bla}     \label{fig:bla}     \end{figure}          \newpage ~     \chapter{Related}          \begin{table}[hb]     \caption{Boh}     \begin{tabular}{|l|l|r|}          \end{tabular}     \label{tab:boh}     \end{table}               \end{document}


title: How to draw a chessboard with numbers?

text: How to draw a chessboard filled with numbers, as the following figure? ![wanted](http://i.stack.imgur.com/XbZ1p.jpg) I've tried using the `chessboard` package but to no success.


title: Crossing paths in TikZ without intersection

text: Once again, I'm preparing a new logic puzzle; Resuko to be precise. ![enter image description here](http://i.stack.imgur.com/RPfjE.png) For the race track, I would like to have a symbolized bridge/underbridge `-|-`. I searched this site, but only found this question: Intersection of 2 lines not really connected in TikZ The answers there seem to indicate that there is no automatic solution for full paths. I'm quite sure, i have seen this, but maybe with PSTricks. Any ideas? **Edit:** Unfortunately, Frédéric's solution does not work after integration into `logicpuzzle.sty`. Some path construction must be supported, like `trackpath` in the following MWE:               \documentclass[border=5pt]{standalone}     \usepackage{tikz}     \usetikzlibrary{decorations.pathreplacing}       \makeatletter     \tikzstyle{bridge path}=[rounded corners=10pt,decorate,decoration={show path construction,     lineto code={         \draw [white,line width = 4pt,double=red,double distance=4pt]                 (\tikzinputsegmentfirst) -- (\tikzinputsegmentlast);},     curveto code={           \draw [red,line width = 4pt] (\tikzinputsegmentfirst) .. controls             (\tikzinputsegmentsupporta) and (\tikzinputsegmentsupportb)             ..(\tikzinputsegmentlast);                 }}]       \newcommand*\trackpath[3]%     {%       (#1.5,#2.5)%       \foreach \LP@direction in {#3}%       {%         \ifnum\LP@direction=1%         --++(-1,-1)%         \fi%         \ifnum\LP@direction=2%         --++(0,-1)%         \fi%         \ifnum\LP@direction=3%         --++(1,-1)%         \fi%         \ifnum\LP@direction=4%         --++(-1,0)%         \fi%         \ifnum\LP@direction=6%         --++(1,0)%         \fi%         \ifnum\LP@direction=7%         --++(-1,1)%         \fi%         \ifnum\LP@direction=8%         --++(0,1)%         \fi%         \ifnum\LP@direction=9%         --++(1,1)%         \fi%       };%     }%     %     \newcommand*\track[1]{       \draw[bridge path] #1;     }     \makeatother     \begin{document}     \begin{tikzpicture}      \track{\trackpath{0}{2}{6,2,2,4,8,6,6}}     \draw (0,0) grid[step=1] (3,3);     \end{tikzpicture}     \end{document}      ![MWE](http://i.stack.imgur.com/Kxawi.png) Then, the decoration doesn't work any longer. :-( It works with a `TikZ path`, `\trackpath` seems to trigger the problem. Any idea what's going wrong? **Edit2:** With Frédéric's idea to change the way how the path is constructed, we have a final solution:               \documentclass[border=5pt]{standalone}     \usepackage{tikz}     \usetikzlibrary{decorations.pathreplacing}       \makeatletter     \tikzstyle{bridge path}=[rounded corners=10pt,decorate,decoration={show path construction,     lineto code={         \draw [white,line width = 4pt,double=red,double distance=4pt]                 (\tikzinputsegmentfirst) -- (\tikzinputsegmentlast);},     curveto code={           \draw [red,line width = 4pt] (\tikzinputsegmentfirst) .. controls             (\tikzinputsegmentsupporta) and (\tikzinputsegmentsupportb)             ..(\tikzinputsegmentlast);                 }}]       \newcommand*\trackpath[3]%     {%       (#1.5,#2.5)%       \foreach \LP@dir/\LP@length in {#3}%       {%         \ifnum\LP@dir=2%         --++(0,-\LP@length)%         \fi%         \ifnum\LP@dir=4%         --++(-\LP@length,0)%         \fi%         \ifnum\LP@dir=6%         --++(\LP@length,0)%         \fi%         \ifnum\LP@dir=8%         --++(0,\LP@length)%         \fi%       };%     }%     %     \newcommand*\track[1]{       \draw[bridge path] #1;     }     \makeatother     \begin{document}     \begin{tikzpicture}      \track{\trackpath{0}{2}{6/1,2/2,4/1,8/1,6/2}}     \draw (0,0) grid[step=1] (3,3);     \end{tikzpicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/aSVI3.png)


title: Line with a \hbox is overflowing right margin, why?

text: Let's say I have a `hbox` inside a paragraph like this: `Do you like me? \hfill\hbox{\quad$\bigcirc$ Yes\quad$\bigcirc$ No}`. If the text of the question is longer than this "Do you like me?", the line just won't break. The `hbox` with answers will just owerflow the right margin. Why is that? Is that because I haven't adjusted the penalties? From what I read, for TeX `hbox` is something that cannot be broken into more lines. But why wouldn't it put a line break between the question and the answers?


title: TikZ Matrix - How can I align content horizontally which is spanning over multiple cells/rows?

text: I'd like to finetune the big rectangle in the last column and its content, i.e. that it's all aligned to the third column's center. It is currently too far on the right: ![enter image description here](http://i.stack.imgur.com/ZaZ2y.png) So far I have been unable to find the missing option. **MWE**               \documentclass[     11pt     ]{scrartcl}     \usepackage{     tikz,     relsize,     tgheros     }          \usetikzlibrary{         calc,trees,shadows,positioning,arrows,chains,shapes.geometric,         decorations.pathreplacing,decorations.pathmorphing,shapes,         matrix,shapes.symbols,patterns,intersections%,fit         }          \pgfdeclarelayer{background layer}     \pgfdeclarelayer{foreground layer}     \pgfsetlayers{background layer,main,foreground layer}          \tikzset{         rolle/.style=         {             rectangle,             drop shadow={opacity=0.5},             minimum width=4em,             minimum height=4em,             text width=4cm,             draw=black!80,             very thick,             fill=black!40,             font=\sffamily\bfseries,             align=center         },         einheit/.style=         {             rectangle,             rounded corners,              minimum height=2em,             minimum width=4em,         draw=black!80,             fill=black!20,         font=\sffamily         },     }          \begin{document}     \begin{center}     \begin{tikzpicture}[font=\sffamily\small,node distance=0.5cm]         \draw[thick] (-7.5,-4) rectangle (7.5,4);         \draw[thick,fill=black!20] (-7.5,4) rectangle (7.5,5) node[midway] {something};         \matrix (m) [matrix of nodes,nodes in empty cells,row sep=5mm,column sep=5mm] {         %         \node[rolle] {123}; & \node[rolle] {456}; & \node[rolle] {789}; \\         %         \node[einheit] {words}; & & \node[minimum width=5cm] (abc) {}; \\         %         & \node[einheit] {words}; & \\         %         & \node[einheit] {words}; & \\         %         & \node[einheit] {companies}; & \\         %         \node[einheit] {thing}; & & \\         };         \draw[einheit] (abc.north east) rectangle (m-6-3.south west) node[midway]{abc};     \end{tikzpicture}     \end{center}     \end{document}


title: automatic \allowbreak around mathbin and mathrel characters

text: I would like linebreaks to be permitted within math formulas on both sides of any characters of the `mathbin` and `mathrel` character classes. It seems like linebreaking is by default only permitted after these characters:               \documentclass{article}          \begin{document}          text text text text text text text text text text text text \(x + x + x + x + x + x + x + x + x\)          i text text text text text text text text text text text text \(x + x + x + x + x + x + x + x + x\)          text text text text text text text text text text text text \(x + x + x + x + x \allowbreak+ x + x + x + x\)          text text text text text text text text text text text text \(x = x = x = x = x = x = x = x = x\)          text text text text text text text text text text text text \(x = x = x = x = x \allowbreak= x = x = x = x\)          \end{document}      Oddly, I have also seen situations where an `\allowbreak` afterwards had an effect (that was after a `\cong` symbol), but I cannot reconstruct an example right now. **How can I automatically allow linebreaks around`mathbin` and `mathrel` symbols?** Of course I could always manually insert `\allowbreak` or include it in my own macros defining such operators as well as `\let`-redefine the existing such symbols occurring in my document, but that seems like the wrong approach. I know what I am doing stylistically; what I typeset is not ordinary math with run-of-the-mill equations, plus I really like having an indication of formula continuation at the _beginning_ of the next line. In any case, I think for example that in something like `a = b = c⋅d` a line break before the second equals sign looks perfectly fine. Basically, I would in some sense like to get rid of LaTeX's preference. I'm looking for a way to (1) give the left-hand side of such a symbol the same status as its right-hand side or (2) to basically insert automatic `\allowbreak`s around such symbols. (Note that these two options are not the same.) Note that this ideally shouldn't screw up more complex math symbols built with existing or self-defined `mathbin`/`mathrel` symbols.


title: Producing beamer handout in Scientific Workplace v 5.5

text: Does anyone know how to tell `beamer` to produce a handout from a `beamer` file, i.e., print one page for each full screen and not one page for each line that is added?


title: Last footnote of an Exam be "End of Exam"

text: I am using `exam` class. I am writing an exam, and I wanted the last footnote (the final, last one to appear) to be End of Exam. I have this:               \pagestyle{headandfoot}     \runningheadrule     \firstpageheader{AP Calculus Practice Exam A1}{ Mao Laoshi }{Senior 2}     \firstpageheadrule     \runningheader{AP Calculus Practice Exam A1}     { Page \thepage\ of \numpages}     {Senior 2 }          \footer{}     {\iflastpage{End of exam}{Please go on to the next page\ldots}}     {}


title: Is it possible to set a particular item of a LaTeX3 seq?

text: I want to use a `seq` as an array and then set a particular item of this array by its index. I know that I can access an item via `\seq_item:Nn` but didn’t find out if there's something like `\seq_set_item:Nnn`               \documentclass{article}          \usepackage{xparse}          \ExplSyntaxOn          \seq_new:N \my_seq          \seq_set_split:Nnn \my_seq {;} {a;;b;c;d}          % set item 5 to x     % \seq_set_item: Nnn \my_seq { 5 } { x }          \NewDocumentCommand {\printseq} {}      {       \seq_use:Nn \my_seq {,~}      }          \ExplSyntaxOff               \begin{document}     Sequence: \printseq     \end{document}      Is something like this possible, or are there other structures in LaTeX3 that I can use as indexed array? * * * ### some background information I want to use this in a new package, to apply a TikZ style/options to a particular element of a list by giving its number. For example               \mycmd[2=red]{a b c b}      should process the list `a b a c` as four TikZ `node`s (which works fine) and the second one (`b`) will become red since the applied option is `red`.


title: Is it possible to specify page numbers that are words, e.g. "Title"?

text: I suppose this might also go on SuperUser, but I'm only interested in it insofar as implementing it in LaTeX, so I'll ask here. I feel certain that I've seen PDF's where the actual PDF page number of (for example) the title page is not 1 or i, or any of the standard choices I know are possible in LaTeX, but rather the word "Title", like this: ![enter image description here](http://i.stack.imgur.com/UYEC6.png) (the numbering would then continue as usual, with the second page in the document being indicated as "1" in the white box, etc.) This is only a mock-up, because unfortunately I can't find any examples of PDFs that are like this (perhaps I've only imagined it?) but hopefully I have specified the idea well enough, and I'd like to know if it's possible to do in LaTeX.


title: Turn move number off in \variation

text: Can we customize `\variation` command to suppress display of move numbers ? `\variation{1. e4}` should display `e4` (without the move number). Can this be done ? I should have explained the problem more clearly. I'm talking about the `\variation` command which is part of `xskak` package, to display chess moves. I can customize the `\variation` command using `beforenumber`, `whiteopen`, `blackopen` etc. What ever I do, the final output displays the move number. Also, `\variation{e4}` is invalid as `\variation` command expects the move number. So, my question is, can we customize `\variation` command to not display the move number in the final output (along the lines of `beforenumber` etc). Here's an MWE               \documentclass{book}     \usepackage{xskak}          \begin{document}     \newchessgame\mainline{1. e4 e5} \variation{2. Nf3}     \end{document}      `\variation{Nf3}` is an invalid statement. But I do not want `2.` in the output.


title: empty space under the drawing

text: this is my tikz code:               \usepackage{tikz, tikz-3dplot}          \begin{figure}[ht!]             \centering             \tdplotsetmaincoords{45}{110}             \begin{tikzpicture}[scale=8, tdplot_main_coords]                 \tdplotsinandcos{\sintheta}{\costheta}{75}                 \tdplotdrawarc{(0,0,\sintheta)}{\costheta}{0}{360}{}{}                 \foreach \angle in {0,15,...,360} {                     \tdplotsetthetaplanecoords{\angle};                     \tdplotdrawarc[tdplot_rotated_coords]{(0,0,0)}{1}{0}{15}{}{}                 }             \end{tikzpicture}             \caption{Top row.}             \label{top_row}     \end{figure}      And this is the outcome. ![enter image description here](http://i.stack.imgur.com/DAQOs.png) May I kindly ask you to explain me where does that gap between drawing and caption comes from?


title: Tikz: intersection of line and plane

text: I am struggling with drawing a plane and a intersecting line. I would like to have the line `C,P',P` in the image, disappear if it is "behind" the plane and have it reappear if it is not behind the plane anymore. ![The result I would like to get](http://i.stack.imgur.com/bbvtf.png) Right now I solve this issue by plotting the line in two segments. Here is a MWE:               \documentclass{minimal}     \usepackage{tikz}     \begin{document}     \begin{tikzpicture}     \draw[->] (0,0) node[anchor=east]{C} -- (5,0)node[anchor=west] {Z};     \draw[->] (0,0) -- (0,3)node[anchor=south] {Y};     \draw[->] (-1.0,-1.0) -- (1.5,1.5)node[anchor=west] {X};     \draw (0,0) -- (3,1.2);     \filldraw[fill=lightgray] (2.5,-2.5) -- (2.5,1) --  (4,3) -- (4,-0.5) -- (2.5,-2.5);     \draw[->] (3.25,0) -- (3.25,0.75)node[anchor=south] {y};     \draw[->] (3.25,0) -- (3.5,0.5)node[anchor=west] {x};     \draw[->] (3.25,0) -- (5,0);     \draw (3,1.2) -- (5,2);     \fill (5,2) circle[radius=2pt] node[anchor=south] {P};     \fill (3,1.2) circle[radius=2pt] node[anchor=south] {P'};     \draw ((2.5,-2.5)node[anchor=west, font=\footnotesize] {image plane};     \end{tikzpicture}     \end{document}      However, I believe there must be an easier solution to this problem, as this now requires quite some annoying hand calculations. So my question is: **What is the easiest way to draw a line that is intersecting a plane?**


title: why \usepackage{tablefootnote} puts the footnote at random locations

text: I wanted to make a `footnote` in a table. So I used `tablefootnote` http://www.ctan.org/tex-archive/macros/latex/contrib/tablefootnote to do that as was suggested by google search since normal `\footnote` do not work inside tables. However, it seems the actual footnote sometimes shows up at the bottom of the previous page, and sometimes it shows up at the bottom of the next page. I'd like the footnote to show on the same page. ## Example 1, footnote shows up at bottom of previous page               \documentclass[12pt,notitlepage]{article}%     \usepackage{float}%     \usepackage{lipsum}     \usepackage{tablefootnote}          \begin{document}     \section{A}     \lipsum[4-10]     \section{B}     \begin{table}[htp]     \begin{center}     \begin{tabular}{|l|l|l|}\hline     $e$                      & 0.97774    & 0.9935      \\ \hline     semimajor axis $a$       & 300000     & 262413      \\ \hline     true anamoly $f$         & 163.76     & 176.08       \\\hline     semimajor axis $a$       & 300000     & 262413  \\ \hline     true anamoly $f$         & 163.76     & 176.08     \\\hline     $r_p$                    & 6678       & 1689       \tablefootnote{spacecraft will hit earth on way back since $r_p<r_{earth}$} \\\hline     \end{tabular}     \caption{Summary table for non-tangential per and post flyby the moon}     \label{tab:part_3_1_summary}     \end{center}     \end{table}     \end{document}      ![Mathematica graphics](http://i.stack.imgur.com/mmt8p.png) ## Example 2, footnote shows up on next page               \documentclass[12pt,notitlepage]{article}%     \usepackage{float}%     \usepackage{lipsum}     \usepackage{tablefootnote}          \begin{document}     \section{A}     \lipsum[4-6]     \section{B}     \begin{table}[htp]     \begin{center}     \begin{tabular}{|l|l|l|}\hline     semimajor axis $a$       & 300000  & 262413    \\ \hline     true anamoly $f$         & 163.76   & 176.08   \\\hline     $r_p$                    & 6678 & 1689      \tablefootnote{spacecraft will hit earth on way back since $r_p<r_{earth}$} \\\hline     \end{tabular}     \caption{Summary table for non-tangential per and post flyby the moon}     \label{tab:part_3_1_summary}     \end{center}     \end{table}     \section{C}     \lipsum[4-10]          \end{document}      ![Mathematica graphics](http://i.stack.imgur.com/YbPvP.png) Miktex 2.9, latest.


title: Changing numbers font features while changing shape

text: I am writing a document with the main font set up with old numbers, but I would like to have the "normal" style in the tables. This works but one particular table has some of the numbers in italic and somehow I cannot find a way of changing the font feature for these. It turns out that the table is irrelevant and using `\itshape` or `\em` or `\textit{}` in normal text give the same result:               \documentclass[preview,border=2px,12pt]{standalone}          \usepackage{fontspec}     \setmainfont [Numbers = {Proportional,OldStyle}]{Linux Libertine O}          \begin{document}          2189 89283 98239 8098 2983 098023 \textit{1392843902984u29830} {\itshape 1981987092183749280}          {     \addfontfeatures{Numbers={Lining,Monospaced}, ItalicFeatures={Numbers={Lining,Monospaced}}}     2189 89283 98239 8098 2983 098023 \textit{1392843902984u29830} \itshape 1981987092183749280     }          \end{document}      ![enter image description here](http://i.stack.imgur.com/aPsLY.png) Any idea what I am doing wrong? Or have I hit a bug?


title: Undefined control sequence \url error

text: I got this error while trying to run the `latex` command:               ! Undefined control sequence.     l.10 \newblock Available from: \url                                        {http://www.google.com}.     ?       Why is it an undefined control sequence?


title: column separation lines now showing up in table

text: I have the following code that produces the table that is shown. What I am trying to do is to get the fourth and fifth column titles vertically aligned at the top. Is this possible?               \documentclass{article}     \usepackage{multirow}     \usepackage{array}          \newcolumntype{x}[1]{%     >{\raggedright\hspace{0pt}}p{#1}}%          \begin{document}     \centering     \renewcommand{\arraystretch}{1.2}     \begin{tabular}{| m{2cm} | p{2cm} | p{2cm} | p{2cm} | p{2cm} | p{2cm} |} \hline         \multirow{3}{1.7cm}{Data Set} &%         \multicolumn{3}{c |}{Raw Data} &%         Offline Processing Time &         Index Size (KB)\\ \cline{2-4}     %         & %         RDF N3 File SizeKB (sec)    &%         Number of Triples &%         Number of Entities\\    \hline     \end{tabular}     \end{document}      ![enter image description here](http://i.stack.imgur.com/AqJNh.png)


title: Remove bibliography entry from ToC or change the way it is displayed

text: I'm using the `memoir` class and have my document structured by parts which means that the "Bibliography" entry in the Table of Contents are not showing correctly (I guess that it is shown as a chapter instead of as a part). I see two solutions:   1. Remove the entry from the ToC and add a custom entry like `\addcontentsline{toc}{part}{Bibliography}`   2. Change the way the entry is shown by default Does anyone know about a solution to this?


title: Adjust \lxvchars etc. for \documentclass point size

text: Follow-up to query re: adjusting textheight in memoir Apparently, memoir's `\setlxvchars[\normalfont]\setxlvchars[\normalfont]` commands standardize the result to 10pt, regardless of the point size specified in `\documentclass`. How can one adjust for this? Minimal example follows:               \documentclass[10pt]{memoir}          \usepackage{fontspec}     \setmainfont[Ligatures=TeX]{Linux Libertine}          \usepackage{calc}     \makeatletter     \newcommand{\psize}{\f@size}     \makeatother     \setlxvchars[\normalfont]     \setxlvchars[\normalfont]     \begin{document}     Point size = \psize\par     L45 = \the\xlvchars\par     L65 = \the\lxvchars     \end{document}      L45 and L65 only seem to change as the font is changed. I've tried unsuccessfully to adjust for the ratio `\psize` : 10. Shouldn't be that hard?


title: Depth-first traversal of a binary tree

text: How can I achieve the drawing of a depth-first traversal of a binary tree like in this picture ?


title: Importing in Mass from LaTeX to LyX

text: I have tons of tables stored in LaTeX format that I would like to import into LyX. Doing this manually (through file-->import-->latex(plain) ) will take forever and a day. Using tex2latex (text2lyx -f -d basic_R.tex) reports the following error:               " ...EL/Masters Tburg/Output/Bolivia/Regs/regs_                                                       trends_basic_R.tex     I've inserted a begin-math/end-math symbol since I think     you left one out. Proceed, with fingers crossed."      Despite the same file importing neatly using the file-->import option. Any ideas what's going wrong or an alternative way of importing LaTeX into LyX in mass?


title: How to change the endpoints of a picture in Latex but still keep the same length?

text: I am trying to make a table in LaTeX with 2 columns and 10 rows. Each row represents a different city and each column will represent a parameter. In each column I want to draw the mean and the quantiles of the parameter (of the MCMC draws). This code makes a boxplot               \usepackage{colortbl}          \newcommand{\boxplot}[5]{     \begin{picture}(100, 7)     \put(#1, 2){\line(0, 1){4}}     \put(#1, 4){\line(1, 0){#2}}     \put(#3, 4){\circle*{3}}     \put(#3, 4){\line(1, 0){#4}}     \put(#5, 2){\line(0, 1){4}}     \put(50, 3){\line(0, 1){4}}     \end{picture}     }      and this is an example for making the table.               \begin{figure}[!t]     \renewcommand{\baselinestretch}{0.5}     \noindent     {\scriptsize     \begin{tabular}{c r  @{} c }     \multicolumn{3}{c}{Flight} \\\hline          Rank & Change  & 50\% \\     \hline     1 & flight2reuse, & \boxplot{17.700000}{3.500000}{21.200000}{12.100000}{33.300000} \\     2 & improveteam, & \boxplot{20.800000}{4.500000}{25.300000}{9.100000}{34.400000} \\     2 & none, & \boxplot{20.100000}{6.200000}{26.300000}{11.800000}{38.100000} \\     3 & reducefunc, & \boxplot{18.700000}{8.500000}{27.200000}{11.000000}{38.200000} \\     3 & improveprecflex, & \boxplot{22.400000}{7.700000}{30.100000}{11.800000}{41.900000} \\     3 & flight4reuse, & \boxplot{23.000000}{7.200000}{30.200000}{12.400000}{42.600000} \\     4 & relaxschedule, & \boxplot{21.000000}{7.500000}{28.500000}{18.400000}{46.900000} \\     4 & archriskresl, & \boxplot{21.900000}{7.900000}{29.800000}{10.200000}{40.000000} \\     5 & improvepmat, & \boxplot{21.200000}{10.000000}{31.200000}{15.100000}{46.300000} \\     6 & flight3reuse, & \boxplot{23.800000}{10.600000}{34.400000}{10.400000}{44.800000} \\     7 & reducequality, & \boxplot{30.600000}{5.500000}{36.100000}{11.400000}{47.500000} \\     8 & improvepcap, & \boxplot{29.600000}{9.800000}{39.400000}{8.100000}{47.500000} \\     9 & improvetooltechplat, & \boxplot{40.800000}{13.000000}{53.800000}{18.400000}{72.200000} \\     10& flight1reuse, & \boxplot{31.400000}{35.500000}{66.900000}{14.700000}{81.600000} \\          \end{tabular}     \end{figure}      The problem is that the parameters I have to use are between -1 and 1 (not like in this example from 0 to 100) I have tried adding a second argument to `\begin{picture}`               \begin{picture}(100, 7)(-50,0)      this means that the start (at the lower left side) is at (-50,0) and the end is at (50,7) in the upper right corner. This unfortunately makes my parameters almost invisible. On the other hand if I change it to                \begin{picture}(2, 7)(-1,0)       I have the same problem. I want to somehow have a command like `\begin{picture}(100, 7)(-1,0)(1,7)` which would mean that the length is 100mm, it starts at (-1,0) and ends at (1,7).In that case my parameters would look normal. I have tried different ways but couldn't come up with an answer. Any help is much appreciated


title: How to use different font for full document in LaTeX

text: I am not able to find how to call different fonts family in latex. Could someone help me out or any link will be useful.               \documentclass[a4paper]{article}           \usepackage{amsmath,amssymb,amsfonts}     \usepackage{graphics}      \usepackage{color}                       \usepackage{hyperref}                   \usepackage{multirow}     \usepackage{longtable}     \usepackage{fullpage}     \usepackage[pdftex]{graphicx}     \usepackage{fancyhdr}               \pagestyle{fancy}     \renewcommand{\headrulewidth}{0.0pt}     \lfoot{%(full_name)s/%(emp_id)s/\thepage}     \cfoot{}     \topmargin -2.5cm     \parindent 0cm     \textheight 27.5cm     \parskip 3mm                         \begin{document}     \oddsidemargin -1cm     \evensidemargin 0cm               \fontencoding{\encodingdefault}          \renewcommand{\familydefault}{\sfdefault}          \fontshape{\shapedefault}      thanks


title: Disable or heavily penalise pagebreaking at a specified place

text: Is there a way in `LaTeX` to disable (or heavily penalise) pagebreaking at a specified place? Here's an example:               \documentclass[]{minimal}          \usepackage[a6paper]{geometry} % demonstration use only          \begin{document}          May break before this.     May break before this.     May break before this.     May break before this.     May break before this.     Don't break before this\\     or before this.          \end{document}


title: Printing Glossaries in amsart using TexStudio

text: I am trying to make a glossary in an amsart document using TeXstudio but the glossary will not print. I've downloaded xindy, arara, and perl and have tried to use all of them, but to no avail. Any thoughts? A Minimal example containing all of the relevant packages, etc.:               % arara: pdflatex     % arara: makeglossaries     % arara: pdflatex         % arara: pdflatex     \documentclass[9pt]{amsart}     \usepackage{amsmath, amssymb, amsthm}     \usepackage[toc,page]{appendix}     \usepackage{url}     \usepackage{hyperref}     \usepackage[xindy]{glossaries}     \makeglossaries          \newglossaryentry{def1}{name={first definition},description={description1}}     \newglossaryentry{def2}{name={second definition},description={description2}}          \begin{document}     \section{Preliminaries}          This is \gls{def1} and this is \gls{def2}.          \printglossaries      \end{document}


title: Long vertical bar on titlepage with rotated text

text: Is there a nice and easy way to include a vertical colored bar on the titlepage with some rotated text? I would like to have something similar to ERDC sample, but covering the left 5cm of the page without leaving any white space. I already checked the code of `erdc.cls` but found it to be beyond my knowledge.


title: French-style cover letter using 'moderncv' document class

text: I've got a quite similar problem as the one presented in this thread: Renew command \makelettertitle in moderncv, but the solution proposed does not completely answer my needs. As a reminder, the French way to type a letter header is traditionally to put the Sender's informations on the top left of the document, and the Recipient's informations below, but on the RIGHT side of the document. My problem is that I could not find a working way to flush to the right the textblock "Recipient address" by modifying the solution proposed in the link above. I would also like to justify the body of the letter, but my solution, as proposed in this thread Justify text in moderncv cover letter, interferes with the \makelettertittle command modification. Here comes a MWE to summarize everything: (please note that the signature is also flushed to the right)               \documentclass[11pt,a4paper,sans]{moderncv}     \moderncvstyle{classic}               \moderncvcolor{blue}                           \nopagenumbers{}     \usepackage{etoolbox}     \usepackage{lipsum}          %%%%%%%%%%%%% Beginning of \makelettertittle modification %%%%%%%%%%%%%%%%%%          \makeatletter     %-------------------------------------------------------------------------------     %                letter style definition     %-------------------------------------------------------------------------------     % commands     \renewcommand*{\recomputeletterlengths}{%     \recomputecvlengths%     \setlength{\parskip}{6\p@}}          \newcommand*{\subject}[1]{\def\@subject{#1}}                             \renewcommand*{\makelettertitle}{%     % recompute lengths (in case we are switching from letter to resume, or vice versa)     \recomputeletterlengths%     % sender contact info     %\hfill%                                           \begin{minipage}{.5\textwidth}%     \raggedright%                                                       \addressfont\textcolor{color2}{%                   {\bfseries\upshape\@firstname~\@familyname}\@firstdetailselementfalse%       \ifthenelse{\isundefined{\@addressstreet}}{}{\makenewline\addresssymbol\@addressstreet%         \ifthenelse{\equal{\@addresscity}{}}{}{\makenewline\@addresscity}}%       \ifthenelse{\isundefined{\@mobile}}{}{\makenewline\mobilesymbol\@mobile}%       \ifthenelse{\isundefined{\@phone}}{}{\makenewline\phonesymbol\@phone}%       \ifthenelse{\isundefined{\@email}}{}{\makenewline\emailsymbol\emaillink{\@email}}%       \ifthenelse{\isundefined{\@homepage}}{}{\makenewline\homepagesymbol\httplink{\@homepage}}%       \ifthenelse{\isundefined{\@extrainfo}}{}{\makenewline\@extrainfo}}%     \end{minipage}\\[2em]     % recipient block     \hspace{0.5\textwidth} \begin{minipage}[t]{.5\textwidth}            \raggedright%     \addressfont%     {\bfseries\upshape\@recipientname}\\%     \@recipientaddress\\[2em]%     \@date\\[1.5em]%                                                    \end{minipage}     % date     \hfill     \null\\[2em]%                                                   \raggedright%     \ifthenelse{\isundefined{\@subject}}{}{%                                  \begin{tabular}{ p{0.08\textwidth} p{0.92\textwidth} }     Objet: & \raggedright \@subject     \end{tabular}     \\[1.5em]}%     % opening     \raggedright%     \@opening\\[1.5em]%     \hspace{0pt}\par\vspace{-\baselineskip}\vspace{-\parskip}}          \renewcommand*{\makeletterclosing}{     \@closing\\[3em]%     {\bfseries \@firstname~\@familyname}%     \ifthenelse{\isundefined{\@enclosure}}{}{%     \\%     \vfill%     {\color{color2}\itshape\enclname: \@enclosure}}}     \makeatother%     %%%%%%%%%%%%%%%%% End of \makelettertittle modification%%%%%%%%%%%%%%%%%%%%%%%%%%%          \makeatletter     \patchcmd{\makelettertitle}               %%% Text body justifying attempt     {\raggedright \@opening}     {\@opening}     {}{}          \patchcmd{\makeletterclosing}             %%% Flushing right the signature     {\@closing}     {\flushright \@closing}     {}{}     \makeatother          % character encoding     \usepackage[ansinew]{inputenc}     \usepackage[francais]{babel}          % adjust the page margins     \usepackage[top=1.1cm, bottom=1.1cm, left=2cm, right=2cm]{geometry}     \setlength{\hintscolumnwidth}{3cm}          % personal data     \firstname{Mr Foo}     \familyname{Bar}     \title{Resume title}     \address{address}{city}{country}     \mobile{0987654321}                  \phone{0123456789}               \email{foo.bar@mail.lol}               \begin{document}          %%%%Recipient infos%%%%     \recipient{Recruitment Office}{Derp Corp.\\12 Some Way\\Foobar}     \date{\today}     \subject{Job application ref. 121212}     \opening{Dear Sir or Madam,}     \closing{Yours faithfully,}     \enclosure[Attached]{curriculum vit\ae{}}          \makelettertitle          \lipsum[1-3]          \makeletterclosing          \end{document}


title: How to have linked axes on plots?

text: I plot infrared spectra in many reports and I display the energy units in two ways, wavenumbers `$cm^{-1}$` on the bottom x-axis and wavelength (nm) on the upper x-axis. The relationship is `X(nm)=1e7/Y(cm^{-1})`. for example a spectra running from `4000$cm^{-1}$-400$cm^{-1}$` on the bottom x-axis (a linear scale) corresponds to a wavelength range of 2500nm - 25,000nm a non-linear scale. Is there a way to have this done in pgf, tikz etc? I use Origin to do this and then export as pdf and use `\includegraphics{linked- axis-plot.pdf}`


title: Biblatex --- how to add colon after volume?

text: How does one place a colon after the volume and before the page range for articles?               \documentclass{memoir}          \usepackage{biblatex}          \usepackage{filecontents}          \begin{filecontents}{\jobname.bib}     @Article{Reference:1994,       author =   {First I. Last, and Second Y. Author},       title =    {This is the article title},       journal =  {T Journal T},       journallongtitle =     {The Journal Title},       year =     1994,       volume =   50,       pages =    {30--40}     }     }     \end{filecontents}          \addbibresource{\jobname.bib}          \nocite{*}          \begin{document}          \printbibliography          \end{document}


title: Biblatex --- how to add comma before and between two names

text: I'm currently getting: > Surname, IN and Secondauthorsurname, FM. I need: > Surname, IN, and Secondauthorsurname, FM. Searching for "comma" in the documentation is impossible, since it also hits on "command"               \documentclass{memoir}          \usepackage[american]{babel}          \usepackage{biblatex}     \DeclareLanguageMapping{american}{american}          \usepackage{filecontents}          \begin{filecontents}{\jobname.bib}     @Article{Reference:1994,       author =   {First I. Last, and Second Y. Author},       title =    {This is the article title},       journal =  {T Journal T},       journallongtitle =     {The Journal Title},       year =     1994,       volume =   50,       pages =    {30--40}     }     }     \end{filecontents}          \addbibresource{\jobname.bib}          \nocite{*}          \begin{document}          \printbibliography          \end{document}


title: Typeset Theorems in Upright Fonts for Beamer

text: I want to typeset my theorems within my presentation in upright fonts. The only way I know is by doing this:               \begin{theorem}     \textup{Upright Theorem}     \end{theorem}      When I use `article` document class, I can use the theorem package and type `\theorembodyfont{\upshape}` within the preamble. However, such thing did not work for Beamer. I would like to do the similar thing when I use beamer (defined the upright-ness within the preamble). Is it possible?


title: Drawing a complete ER Diagram in Crow's foot style by TikZ

text: I need to draw a ER digram in Crow's foot style in LaTeX. After some search I found: Creating crow's foot style E-R diagrams, rather than Chen-style ones However, I found this style was not "complete" for me. I need to write down the "verb" between two tables and indicate both primary key (PK) and foreign key (FK) of the table. This red text on the uploaded image shown what I need. ![The wanted ERD](http://i.stack.imgur.com/SXRA0.png) After some coding I was only able to create some new relationship such as "1:zero,one, or many". But I was puzzled by inserting text as there are no any nodes. Appreciate for any help. Thanks you. The best attempt I have is:               \documentclass[12pt]{article}          \usepackage{tikz}     \usetikzlibrary{shapes.multipart}     \usetikzlibrary{matrix}     \usetikzlibrary{positioning}     \usetikzlibrary{shadows}     \usetikzlibrary{calc}          %\usepackage{pdflscape}          % Monspace Font Package     %\usepackage{courier}     \usepackage{lmodern}     %\renewcommand*\familydefault{\ttdefault} %% Only if the base font of the document is to be typewriter style          \makeatletter     \pgfarrowsdeclare{crow's foot}{crow's foot}     {       \pgfarrowsleftextend{+-.5\pgflinewidth}%       \pgfarrowsrightextend{+.5\pgflinewidth}%     }     {       \pgfutil@tempdima=0.6pt%       %\advance\pgfutil@tempdima by.25\pgflinewidth%       \pgfsetdash{}{+0pt}%       \pgfsetmiterjoin%       \pgfpathmoveto{\pgfqpoint{0pt}{-9\pgfutil@tempdima}}%       \pgfpathlineto{\pgfqpoint{-13\pgfutil@tempdima}{0pt}}%       \pgfpathlineto{\pgfqpoint{0pt}{9\pgfutil@tempdima}}%       \pgfpathmoveto{\pgfqpoint{0\pgfutil@tempdima}{0\pgfutil@tempdima}}%       \pgfpathmoveto{\pgfqpoint{-8pt}{-6pt}}%        \pgfpathlineto{\pgfqpoint{-8pt}{-6pt}}%         \pgfpathlineto{\pgfqpoint{-8pt}{6pt}}%        \pgfusepathqstroke%     }          \pgfarrowsdeclare{omany}{omany}     {       \pgfarrowsleftextend{+-.5\pgflinewidth}%       \pgfarrowsrightextend{+.5\pgflinewidth}%     }     {       \pgfutil@tempdima=0.6pt%       %\advance\pgfutil@tempdima by.25\pgflinewidth%       \pgfsetdash{}{+0pt}%       \pgfsetmiterjoin%       \pgfpathmoveto{\pgfqpoint{0pt}{-9\pgfutil@tempdima}}%       \pgfpathlineto{\pgfqpoint{-13\pgfutil@tempdima}{0pt}}%       \pgfpathlineto{\pgfqpoint{0pt}{9\pgfutil@tempdima}}%       \pgfpathmoveto{\pgfqpoint{0\pgfutil@tempdima}{0\pgfutil@tempdima}}%         \pgfpathmoveto{\pgfqpoint{0\pgfutil@tempdima}{0\pgfutil@tempdima}}%       \pgfpathmoveto{\pgfqpoint{-6pt}{-6pt}}%          \pgfpathcircle{\pgfpoint{-11.5pt}{0}} {3.5pt}       \pgfusepathqstroke%     }          \pgfarrowsdeclare{one}{one}     {       \pgfarrowsleftextend{+-.5\pgflinewidth}%       \pgfarrowsrightextend{+.5\pgflinewidth}%     }     {       \pgfutil@tempdima=0.6pt%       %\advance\pgfutil@tempdima by.25\pgflinewidth%       \pgfsetdash{}{+0pt}%       \pgfsetmiterjoin%       \pgfpathmoveto{\pgfqpoint{0\pgfutil@tempdima}{0\pgfutil@tempdima}}%       \pgfpathmoveto{\pgfqpoint{-6pt}{-6pt}}%        \pgfpathlineto{\pgfqpoint{-6pt}{-6pt}}%         \pgfpathlineto{\pgfqpoint{-6pt}{6pt}}%        \pgfpathmoveto{\pgfqpoint{0\pgfutil@tempdima}{0\pgfutil@tempdima}}%       \pgfpathmoveto{\pgfqpoint{-8pt}{-6pt}}%        \pgfpathlineto{\pgfqpoint{-8pt}{-6pt}}%         \pgfpathlineto{\pgfqpoint{-8pt}{6pt}}%           \pgfusepathqstroke%     }          \tikzset{         entity/.code={             \tikzset{                 label=above:#1,                 name=#1,                 inner sep=0pt,                 every entity/.try,                 fill=white               }%             \def\entityname{#1}%         },         entity anchor/.style={matrix anchor=#1.center},         every entity/.style={                 draw,         },         every property/.style={             inner xsep=0.25cm, inner ysep=0.15cm, anchor=west, text width=1in         },         zig zag to/.style={             to path={(\tikztostart) -| ($(\tikztostart)!#1!(\tikztotarget)$) |- (\tikztotarget)}         },         zig zag to/.default=0.5,         one to one/.style={             one-one, zig zag to         },             one to many/.style={             one-crow's foot, zig zag to,         },         one to omany/.style={             one-omany, zig zag to         },               many to one/.style={             crow's foot-one, zig zag to         },         many to many/.style={             crow's foot-crow's foot, zig zag to         }       }     \def\property#1{\node[name=\entityname-#1, every property/.try]{#1};}     \def\properties{\begingroup\catcode`\_=11\relax\processproperties}     \def\processproperties#1{\endgroup%         \def\propertycode{}%         \foreach \p in {#1}{%             \expandafter\expandafter\expandafter\gdef\expandafter\expandafter\expandafter\propertycode%                 \expandafter\expandafter\expandafter{\expandafter\propertycode\expandafter\property\expandafter{\p}\\}%         }%         \propertycode%     }          \begin{document}          %\begin{landscape}          \begin{tikzpicture}[every node/.style={font=\ttfamily}, node distance=5cm]     \matrix [entity=MEMBER] {         \properties{             MID,             MName         }     };          \matrix [entity=TABLE, right=of MEMBER-MID, entity anchor=TABLE-TID]  {         \properties{             TID,             MID,             CNAME,             CADDRESS         }     };          \draw [one to omany] (MEMBER-MID) to (TABLE-TID);          \end{tikzpicture}     %\end{landscape}          \end{document}


title: A plot using tikz is giving very odd results

text: I'm trying to include a plot of tan(x) in some student notes. Here is my input (using ConTeXt):               \usemodule[newmat,tikz,pgfmath]      \usetikzlibrary[arrows]          \starttext            \starttikzpicture[scale=0.65]         \draw[-angle 60] (-9,0) -- (14,0) node[right] {$x$};         \draw[-angle 60] (0,-6) -- (0,6) node[above] {$y$};         \foreach \r in                  {-6.28319,-3.14159,0.00000,3.14159,6.28319,9.42478,12.56637}                  \draw[domain=\r-1.4:\r+1.4,line width=2pt] plot[samples=100]                  (\x,{tan(\x r)});         \foreach \r in                   {-7.8540,-4.7124,-1.5708,1.5708,4.7124,7.8540,10.9956}                   \draw[dashed] (\r,-6) -- (\r,6);           \stoptikzpicture          \stoptext      And here is the output: ![enter image description here](http://i.stack.imgur.com/hLrmy.jpg) Can anybody shed some light on this strange output?


title: Spacing/stretching marginnote

text: I want to do something like this               \marginnote{     \hspace{\stretch{1}}     \framebox{text}     \hspace{\stretch{1}}     } ` i.e., center the marginnote. The problem seems to be that the width is defined to be that of `\textwidth`, so that the `\stretch` command assumes a margin width far larger than the actual 106pt. How can I redefine the width for `\stretch`?


title: Problem with gnuplot and lualatex

text: I have a pretty complicated graph to plot from coordinates.A friend from here adviced me to use gnuplot and also helped me with the code which is the following...               \documentclass[border= 5mm]{standalone}     \usepackage{pgfplots, filecontents}     \pgfplotsset{colormap={bluered}{rgb255(0cm)=(0,0,180); rgb255(1cm)=(0,255,255);rgb255(2cm)=(100,255,0);rgb255(3cm)=(255,255,0); rgb255(4cm)=(255,0,0); rgb255(5cm)=(128,0,0)}}      \begin{filecontents*}{data.txt}     1   1   70     2   1   48     3   1   41       4   1   70     5  1   68     6   1   82     7   1   38     8   1   47     9   1   35     10  1   66     11  1   53     12  1   78     1   2   91     2   2   43     3   2   68     4   2   90     5  2   66     6   2   55     7   2   66     8   2   46     9   2   25     10  2   38     11  2   50     12  2   58     1   3   60     2   3   68     3   3   39     4   3   65     5  3   59     6   3   69     7   3   72     8   3   62     9   3   94     10  3   36     11  3   33     12  3   39     1   4   48     2   4   80     3   4   68     4   4   66     5  4   59     6   4   63     7   4   93     8   4   63     9   4   30     10  4   52     11  4   60     12  4   14     1  5  74     2  5  84     3  5  86     4  5  39     5  5  76     6  5  51     7  5  43     8  5  55     9  5  37     10  5  60     11  5  49     12  5  42     1  6  74     2  6  51     3  6  62     4  6  45     5  6  69     6  6  58     7  6  73     8  6  50     9  6  58     10  6  50     11  6  64     12  6  42     1  7  60     2  7  57     3  7  80     4  7  59     5  7  48     6  7  60     7  7  69     8  7  56     9  7  67     10  7  51     11  7  32     12  7  57     1  8  43     2  8  88     3  8  64     4  8  62     5  8  56     6  8  65     7  8  34     8  8  44     9  8  80     10  8  52     11  8  66     12  8  42     1  9  86     2  9  61     3  9  68     4  9  71     5  9  61     6  9  51     7  9  62     8  9  52     9  9  49     10  9  62     11  9  46     12  9  27     \end{filecontents*}     \begin{document}     \begin{tikzpicture}     \begin{axis}[xtick={1,2,3,4,5,6,7,8,9,10,11,12},xticklabels={FRO,NOM,FER,EMM,COR,MOU,OZO,DRH,ELI,ANT,ARI,PAV},xmin=0,xmax=13,xlabel=Players,ylabel=Rounds,zlabel=Points Per Round,colormap/bluered,width=30cm,height=20cm,point meta min=30, point meta max=85]      \addplot3 [surf] gnuplot [raw gnuplot] {         set dgrid3d 52,52 spline;         splot 'data.txt';            };     \end{axis}     \end{tikzpicture}     \end{document}      This results to the following pic which is quite impressive BUT... ![enter image description here](http://i.stack.imgur.com/23qWZ.jpg) Ι wanted something more smooth...so I set dgrid3d 100,100 spline; This did not work because over 52 the tex capacity is exceeded... So by searching I found that lualatex does not have the same restrictions! So I tried the same code with lualatex... But I got the next message: ![enter image description here](http://i.stack.imgur.com/6IkQz.png) So if anyone can help me use gnuplot with lualatex I would be grateful! Thanks in advance! A


title: Generation of simple, CSS-less HTML with htlatex

text:
When `htlatex` converts a document, emphasis and bold-face are converted to spans of a certain style which is defined in the accompanying CSS file. Input:               \documentclass{scrartcl}          \begin{document}       Normal text            \em{Emphasized text}            \textbf{Bold-faced text}     \end{document}      Output (header and footer stripped):
Normal text
  Emphasized text
  Bold-faced text        Is it possible to generate "plain" HTML that does not use an external CSS file? Something along these lines:
Normal text
  Emphasized text
  Bold-faced text       This is for pasting references into another website that already has a CSS.


title: LaTeX Beamer: How to uncover formulas/text at a location of an "un'uncovered" formula/text

text: I have a beamer presentation in latex where I want a formula to change its coloring schema over a couple of steps (The idea is to mark the "active" part of the formula at the given moment). When I try to acomplish that like this,                   \begin{frame}{Title}              \uncover<1-1>{         \begin{align*}            e=mc^3         \end{align*}         }              \uncover<2-2>{         \begin{align*}            e=mc^{\color{red}3}         \end{align*}         }              \uncover<3-3>{         \begin{align*}            e=mc^{\color{green}2}         \end{align*}         }              \end{frame}      then, of course, the formula moves downward in the slide. Here is the question: how can I "update" a formula i.e. uncover a new version of the formula at exactly the location of its old version? It seems that the problem is that after slide m is reached, the formula encapsulated in \uncover<3-3>{...} is hidden but it is still there..(it still occupies space)


title: Undefined control sequence .<recently read> \aline( in a table)

text: Heelo, I am getting this error note but the document still compiles, however, the table of contents does not and I kind of need it. The part where the error lies is:               \subfloat[Subtable 3 list of tables text][Mayor proporción de bajos ingresos]{     \begin{tabular}{l|ccc}     & valor asignado\\     \aline     $c_1$ & 5.7143  \\     $c_2$ & 12.8571 \\     $q_1$& 1.2857\\     $q_2$& 2.5714\\     T& 4.2857 \\     U & 1.2478 \\     \end{tabular}}      In particular the last line. Any ideas?


title: Transfer big table from stata to Latex

text: I am a new user in this forum so forgive ex-ante my mistakes. The story is: I have create a big table in Stata (in LaTeX environment it is approximately 3 pages) and when I try to fit it in LaTeX, then I get only one page with as much information as it fits. I have tried to break the table into three parts but the results are not so good. Is there any command for my problem? Example:               \begin{table}[htbp]            \raggedleft     \splittablecaption*{Descriptive statistics by country} \label{tab:descriptive stat 1}          \begin{tiny}     \begin{tabular}{rcccccc}         \toprule         \textbf{Country} & \textbf{Expenses} & \textbf{Earning assets} & \textbf{Price of deposits} & \textbf{Price of labour} & \textbf{Price of physical capital} & \textbf{Bank profits} \\         \midrule          Afghanistan & 8.22  & 10.27 & 0.03  & 0.02  & 1.83  & 908.05 \\         Albania & 8.71  & 11.40 & 0.04  & 0.01  & 0.87  & 3723.46 \\     Algeria & 7.35  & 10.42 & 0.04  & 0.01  & 0.75  & 1184.20 \\     Andorra & 10.45 & 13.66 & 0.03  & 0.01  & 0.39  & 24572.85 \\          UNTIL          Zambia & 7.53  & 9.47  & 0.05  & 0.05  & 2.10  & 427.15 \\          Zimbabwe & 9.54  & 11.28 & 0.04  & 0.04  & 0.83  & 4862.60 \\      Thank you a priori.


title: adding space before each item in itemize

text: I would like to add some space before each `\item` in `begin{itemize}` When i try doing something like this               \begin{itemize}     \item \hspace {5cm} Sweden     \item \hspace {5cm} Germany     \end{itemize}      The output i get is something like this               •                Sweden     •                Germany      As it can be seen the space are added after the bullets. Any recommendation?? Help would be very much appreciated.


title: proper tool for charts in tex

text: I have scanned data graphics in a large ms written in `TeX` (of course). For copyright reasons I need to redraw these. My publisher may (sadly) decide not to use my source directly, so will need access to my drawings separate from my text. I can think of several possible workflows; I'm looking for recommendations.   * Use tikz, tikz-pgf, pgfplots. I'd have to learn these packages, but that in itself would be fun and useful. Can these generate good standalone images as well as ones included in my document?   * Use r, and export to pdf. I'd have to learn the r, but I have a really good consultant.   * Use inkscape (which I've begun learning).   * Use Excel, export to pdf. I am already doing this in some places where it's appropriate in context. I'd rather not have all the graphics look Excel-generated. Other suggestions welcome. If you're curious, the project is http://www.cs.umb.edu/~eb/qrbook/qrbook.pdf


title: Space after comma in units package

text: I have a problem with using the `units` package. In my thesis I used it sometimes in math environment, sometimes not. Now I realized that there is an addition space after the comma in math mode. I think this is a problem of European and American writing of decimal comma and decimal point. Can you tell me, how I can delete the space after the comma in the math environment? ![enter image description here](http://i.stack.imgur.com/SDPDs.png)               \documentclass[12pt,a4paper]{scrbook}          \usepackage{units}          \begin{document}          $V=\unit[0,5]{V}$     \unit[0,5]{V}          \end{document}