title: place several figure into one -tikz

text: I draw several trees and now I want to place them in a figure ( side by side or one below the other )                \documentclass{report}           \usepackage{tikz}      \usetikzlibrary{fit,shapes}           \begin{document}      %First picture      \begin{tikzpicture}[every fit/.style={ellipse,draw,red,inner sep=-2pt},]       \tikzstyle{level 1}=[sibling distance=40mm]       \tikzstyle{level 2}=[sibling distance=20mm]       \tikzstyle{level 3}=[sibling distance=10mm]       \node (S) {S}        child{node (n) {N} child{node (mary) {mary}} }       child{node (VP) {VP}                  child{node{V} child{node(des){brought }}}             child{node (np) {NP}   child{node{D} child{node (a) {a}}} child{node{N} child{node (cat) {cat}}}  }             child{node{PP}  child{node{IN} child{node{to}}}     child{node{N}  child{node{school}}} } }        ;                  \end{tikzpicture}        %Second picture       \begin{tikzpicture}[every fit/.style={ellipse,draw,red,inner sep=-2pt},]        \tikzstyle{level 1}=[sibling distance=40mm]        \tikzstyle{level 2}=[sibling distance=20mm]        \tikzstyle{level 3}=[sibling distance=10mm]        \node (VP) {VP}                  child{node{V} child{node(des){brought }}}             child{node (np) {NP}   child{node{D} child{node (a) {a}}} child{node{N} child{node (cat) {cat}}}  }             child{node{PP}  child{node{IN} child{node{to}}}     child{node{N}  child{node{school}}} } ;                 \end{tikzpicture}       %Third picture      \begin{tikzpicture}[every fit/.style={ellipse,draw,red,inner sep=-2pt},]            \node(V){V}          child{node(des){brought }};          \end{tikzpicture}                 %fourth picture      \begin{tikzpicture}[every fit/.style={ellipse,draw,red,inner sep=-2pt},]             \node (np){NP}              child{node{D} child{node{a}} }             child{node{N} child{node{a}} };                \end{tikzpicture}           % ..... the other picture      \end{document}      So i want to make something like this : ![enter image description here](http://i.stack.imgur.com/tdF9e.png)


title: Highlighting words in forms if they are too long

text: I am using the following code to have LaTeX fill paper forms for bank payments. The single cells in the form have a maximum width so my question is the following: Can I make LaTeX highlight those text sequences that exceed a predefined width e.g. in red? If for example the "Account holder" text get too long I'd like to have it appear in red font color in the PDF.               \documentclass[12pt]{scrartcl}     \usepackage[a6paper,landscape,left=0cm,top=0cm,right=0cm,bottom=0cm]{geometry}          \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage{ocr}     \usepackage[absolute]{textpos}     \setlength{\TPHorizModule}{1cm}     \setlength{\TPVertModule}{1cm}     \setlength{\parindent}{0cm}     \setlength{\parskip}{0cm}          \begin{document}\ocrfamily           \begin{textblock}{3.5}[0,0](0.8,3.5)1234567890\end{textblock}          \begin{textblock}{6}[0,0](4.8,3.4)Account holder\end{textblock}          \begin{textblock}{2.5}[0,0](11.75,3.5)40,00\end{textblock}          \begin{textblock}{12}[0,0](0.75,5)Some Description\end{textblock}          \end{document}      ![bargeld](http://i.stack.imgur.com/5RBzb.png)


title: How to set one move on one line in e.g. texmate?

text: A document set by using `texmate` (package) looks good but quite dense. I would like to have only one move on one line, as you get in the older chess package by e.g.:               \move e2e4 e7e5       \move g1f3 b8c6      Is there a possibility to get a similar appearance in `texmate`? Compare this example using texmate to a similar using package chess. texmateexample.tex:               %     % Based on the package documentation:     % http://mirrors.ctan.org/macros/latex/contrib/texmate/texmate2manual.pdf     %     \documentclass[a4paper]{article}          \usepackage[english]{babel}     \usepackage[utf8x]{inputenc}     \usepackage{texmate}          \title{Example: Chess with TeXmate}     \date{}          \begin{document}     \maketitle          \section{Game with Diagram of Final Board State}          \whitename{Dubois}     \blackname{Steinitz}     \chessevent{London 1862}     \ECO{C50}     \chessopening{Giucco Pianissimo}          \makegametitle     |1 e4 e5 Nf3 Nc6 Bc4 Bc5 0-0 d6 d3 Nf6 Bg5 h6 Bh4 g5 Bg3 h5 Nxg5 h4 Nxf7 hxg3 Nxd8 Bg4 Qe1 Nd4 Nc3 Nf3+ gxf3 Bxf3 \resigns|     \begin{figure}[h]     \centering     \showboard     \end{figure}          \end{document}      chessexample.tex:               \documentclass[a4paper]{article}     \usepackage{chess}          \begin{document}          \section*{Game with Diagram of Final Board State}     \subsection*{Dubois -- Steinitz, London 1862}     {\sc Giucco Pianissimo}\medskip          \newgame     \move e2e4 e7e5     \move g1f3 b8c6     \move f1c4 f8c5     \move e1g1 d7d6     \move d2d3 g8f6     \move c1g5 h7h6     \move g5h4 g7g5     \move h4g3 h6h5     \move f3g5 h5h4     \move g5f7 h4g3     \move f7d8 c8g4     \move d1e1 c6d4     \move b1c3 d4f3     \move g2f3 g4f3          $$\showboard$$          \end{document}


title: Aren't the sectioning commands supposed to work inside longtable?

text: Using sectioning commands such as **section** , **subsection** inside a **longtable** produce the following error:               ! LaTeX Error: Something's wrong--perhaps a missing \item.      Is this normal? Here is the code (created with LyX):               % Preview source code          %% LyX 1.6.7 created this file.  For more info, see http://www.lyx.org/.     %% Do not edit unless you really know what you are doing.     \documentclass[english]{article}     \usepackage[T1]{fontenc}     \usepackage[latin9]{inputenc}     \usepackage{array}     \usepackage{longtable}          \makeatletter          %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands.     %% Because html converters don't know tabularnewline     \providecommand{\tabularnewline}{\\}          \makeatother          \usepackage{babel}          \begin{document}     \begin{longtable}{|>{\centering}p{0.3\textwidth}|>{\raggedright}p{0.4\textwidth}|}     \hline      \section*{Name} & \section*{Description}\tabularnewline     \hline     \hline           a & b     \tabularnewline     \hline      a & b          \tabularnewline     \hline      a & b          \tabularnewline     \hline     \end{longtable}     \end{document}


title: Error: PDF file not found

text: ![enter image description here](http://i.stack.imgur.com/1h5BK.png) After compiling the LaTeX rightly, I try to view the `.pdf` file. But it said that `.pdf file not found`. I think maybe I need to correct some settings? I am a beginner Thank you very much! * * *               \documentclass{article}     \begin{document}     Hello, world!     \end{document}


title: Hyperref - borders arounds (name)ref and no borders around cites and ToC entries

text: Both cites and references should be clickable. I want to have visible borders around the links (refs and namerefs) and no borders around citations (cites). Yet, there shouldn't be any borders in ToC.               \documentclass[a4paper]{book}     \usepackage[hyperfootnotes=false]{hyperref}     \hypersetup{colorlinks=false, linkbordercolor={1 0 1}, citebordercolor={1 1 0}}                                                     %101 = pink,         110=yellow          \begin{document}     \chapter{Abc}     \cite{abc} a.k.a. \nameref{yoyo}          \tableofcontents          \begin{thebibliography}{99}     \bibitem{abc}     ABC.     \end{thebibliography}          \appendix     \chapter{yoyo}     \label{yoyo}          \end{document}      In the example above, there shouldn't be any border around cite #1 and in ToC.


title: feynmf with pdflatex

text: > **Possible Duplicate:**   >  How to use kile with feynmf or feynmp? I would like to use `feynmf`, or better `feynmp`, with `pdflatex`. My first idea was to replace all the files `file.[0-9]*` which are produced after running `mpost` on `file.mp` corresponding to a `\fmffile{file}` environment by their PDF version obtained with `epstopdf`. But unfortunately `pdflatex` complains               ! LaTeX Error: Unknown graphics extension: .1.      Obviously it does not know the filetype from this extension. How can I tell LaTeX that these are PDF files? The names of the files do of course not appear explicitly in my LaTeX source. Note that I looked at How to use kile with feynmf or feynmp? which does not seem to work for me. Also I would prefer a solution which allows me to be able to compile with both `latex` and `pdflatex` (of course after generating the corresponding `feynmf` graph files). I do not mind running `feynmf` and `mpost` by hand.


title: Tex4ht on document: error "\leftmargin doesn't match its definition" when  \small is used in acronym name

text: Is it possible to change the settings of dvi compilation in tex4ht? I ask, because I get a strange errors, when trying to generate html for my latex file:               ! Use of \leftmargin doesn't match its definition.          [exec] \@listi ...argin \leftmargini \parsep 4\p@ \@plus           [exec]                                                   2\p@ \@minus \p@ \topsep 8...          [exec] l.18 \begin{itemize}          [exec]                               [exec] ?           [exec] ! Emergency stop.          [exec] \@listi ...argin \leftmargini \parsep 4\p@ \@plus           [exec]                                                   2\p@ \@minus \p@ \topsep 8...          [exec] l.18 \begin{itemize}      I do not have any errors like that, when generating pdf or dvi (using texify.exe) UPDATE. I have created a sample tex that produces the error:               \documentclass[10pt]{book}     \usepackage{float}     \usepackage{hyperref}     \usepackage{tabularx}         \usepackage[style=altlist,          %Verwendung eines Glossars                             nonumberlist,                             numberedsection,                             acronym,                             toc]{glossaries}         \newacronym{ie}{{\small IE}}{}     \newacronym{ml}{{\small ML}}{}         \makeglossaries          \begin{document}         \chapter{Example}     \glsresetall     \subsection{Fundamentals}      \gls{ie}               \begin{table}[tpb]         \begin{center}             \begin{tabularx}{\columnwidth}{|l|X|}                 \hline                 \textbf{Doc No} & \textbf{Text} \\ \hline                              5641 &   Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium    \\ \hline                  9382 &   Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium  \\ \hline              \end{tabularx}         \end{center}         \caption{AAA \label{tbl:unstr_example}}     \end{table}                \gls{ie}          \appendix               \printglossary[toctitle=Acronyms,type=\acronymtype]     \printglossary[toctitle=Glossary, type=main]          \bibliographystyle{apalike}          \bibliography{}     \clearpage     \pagestyle{empty}         \end{document}      The error message for the sample doc is (run: htlatex test_doc.tex):               ! Use of \leftmargin doesn't match its definition.     \@listi ...argin \leftmargini \parsep 4\p@ \@plus                                                         2\p@ \@minus \p@ \topsep 8...     l.2 \begin{theglossary}                            \glossaryheader      ?      ! Emergency stop.     \@listi ...argin \leftmargini \parsep 4\p@ \@plus                                                         2\p@ \@minus \p@ \topsep 8...      l.2 \begin{theglossary}                              \glossaryheader      The error does not appear if I remove `\small` from acronym definition: `\newacronym{ie}{{\small IE}}{information extraction}`


title: How to control the alignment of the brace in a dcases environment

text: The following code               \begin{equation}         \begin{dcases}             u = \frac{\sqrt{2}}{2}(i+j)\\             v = k         \end{dcases}     \end{equation}        results in the following display   ![Go home, equation, you're ugly.](http://i.stack.imgur.com/7ms1i.png)   that I find particularly disgraceful. Is there a way to lower the brace to make it look more like this   ![Much better-looking equation](http://i.stack.imgur.com/a60la.png)   ?


title: How to place a list of attachments at the same hight as the closing?

text: I am writing a letter using KOMA-scripts `scrlttr2`-class. I would like to add a list of attachments at the end, and I would like that list to be at the same height as the closing, but on the right side of the document. Something like this:               Kind regards,                                                 Attachments:                                                                     * Attachment one                                                                     * Attachment two     My Name      It does not seem to be possible to put the `\closing` into a tabular. Is there any way to achieve this?


title: hvFloat: caption above and note below the object.

text: Using:               \hvFloat[%     floatPos=p,%     capWidth=1.3,%     capPos=b,%     rotAngle=90,%     objectPos=l]     {figure}{\includegraphics[width=\textheight, height=0.75\textwidth]{./Figur/resqrbd}}[Table caption]{Figure caption}{fig:resqrbd}      Any way I can add a note/description (like tnote in ctable) under the figure and have the caption on top (capPos = t)?


title: Sectioning bibliography by type of refered item

text: My promoteur has a very unusual requirement: the bibliography needs to be sorted first by specific type of refered item, next by author and by year of publication. I managed to get this custom sorting done by using makebst and manually editing bst, but now there is even greater problem for me: the bibliography itselft must be sectioned, so it shoud look something like this: * * * ## Sources Aahn, A. 2008, whatever dude Aahn, A. 2009, whatever dude, really ## Dictionaries Encyclopeadia of everythinga, 1999 Wikipaedia, 2000-today ## Articles Aahn, B. and Boss, C., 1889 This issue is not to our concern, good man ## Other Materia Bactera, E.C., 1987, How we totally not-wiped the whole earth. * * * Can this be done automagicly with bibtex? Or do I have to edit the generated file manually?


title: Tikz and alignment with two nodes on the same line

text: Another minimal example:               \documentclass{article}     \usepackage{tikz}     \begin{document}     \begin{tikzpicture}          \node[draw=black,%     rounded corners=2pt,%     rectangle,%     bottom color=black!80!white] (A) {node aligned on left margin};           \node[draw=black,%     rounded corners=2pt,%      rectangle,%      bottom color=black!80!white] {node aligned on the right margin};               \end{tikzpicture}     \end{document}      in this case I'd like to have the first node aligned on the left margin of the paper and the second one on the right.


title: Sublime Text 2: Resources for Configuration and Tutorials

text: Can anyone recomend me a good **website/s** that (i) goes through the configuration of LaTeX on Sublime Text 2 and (ii) give some introductory tips via tutorials? (Sorry for the generality of the question but I need some easy general stuff to get started)


title: Text that doesn't affect the placement of other text

text: I would like to be able to put blocks of text in a document that don't affect the layout of the main part of it. (Specifically, I'm writing the solutions to a previously written exam; I'd like to be able to add the solutions in without causing the text from the original exam to move around.) For what it's worth, the original spacing was largely handled via "\vfill", and I'd like those to still take up the same amount of space. (In principle, this means that if a solution were too long, it would run over and end up on top of the next problem, and I expected to have to manually check that this doesn't happen.) Update: Here's an example, except that it isn't doing the spacing quite right. (The stuff in typewriter font is the solutions.) The point is that I want to leave the spacing of the original exam content alone, while inserting the solutions---complete with formatting---in the gaps left behind. In the unlikely event that there isn't enough space, I expect that any solution might cause crazy things to happen, but I'd like the typical case, that my solution fits in the space allotted, to be relatively seamless.


title: Align footnote mark with text margin

text: I have to clone a document, and the footnote mark shouldn't be indented, but aligned to the text body. I couldn't find an answer elsewhere. Any ideas? I'm using XeLaTeX. The result should look like this: > textbody-textbody-textbody-textbody-textbody² textbody-textbody-textbody- > textbody-textbody- textbody-textbody-textbody-textbody-textbody- > > 2 Footnote-Footnote-Footnote-Footnote-Footnote- Footnote-Footnote-Footnote- > Footnote-Footnote- Footnote-Footnote-Footnote-Footnote-Footnote-   1. The number of the footnote should have the same size as the footnote. This can be achieved with:              \usepackage{scrextend}     \deffootnote{1,2em}{1.6em}{\thefootnotemark.\enskip}        (from http://tex.stackexchange.com/a/19845/)   2. The footnote text should be aligned with the text body.


title: LuaLaTeX:PGFplots can't read data passed by Lua

text: I wanted to give a LuaLaTeX answer to this question Here it is the listing I wrote:               % !TEX encoding   = UTF-8     % !TEX program    = LuaLaTeX     % !TEX spellcheck = en_GB     \documentclass{standalone}          \usepackage{pgfplots}          \usepackage{luacode}          \begin{luacode*}     -- Code taken by     -- http://rosettacode.org/wiki/Gamma_function#Lua     function recigamma(z)         local gamma =  0.577215664901         local coeff = -0.65587807152056         local quad  = -0.042002635033944         local qui   =  0.16653861138228         local set   = -0.042197734555571         return z+gamma*z^2+coeff*z^3+quad*z^4+qui*z^5+set*z^6     end          function gamma(z)         if z == 1 then             return 1         elseif math.abs(z) <= 0.5 then             return 1/recigamma(z)         else             return (z-1)*gamma(z-1)         end     end          -- From Wikipedia     -- http://en.wikipedia.org/wiki/Chi-squared_distribution     function chi_PF(x,k)         if x<0 then             return 0         else             return (1/(2^(k/2)*gamma(k/2)))*x^(k/2-1)*math.exp(-x/2)         end     end          -- Code to write PGFplots data as coordinates     function printData(xMin,xMax,n,k)         local delta = (xMax-xMin)/(n-1)         local     x = xMin         --tex.sprint("{")         for i=1,n do             y = chi_PF(x,k)             tex.print("("..x..","..y..")\n")             x = x+delta         end         --tex.sprint("}")          end     \end{luacode*}          \def\printData#1#2#3#4{\directlua{printData(#1,#2,#3,#4)}}          \begin{document}     \begin{tikzpicture}     \begin{axis}               \addplot coordinates{\printData{0}{10}{10}{3}};          \end{axis}     \end{tikzpicture}     \end{document}      But the error encountered is:               ! Package pgfplots Error: Sorry, I could not read the plot coordinates near '(0,0)      (1.1111111111111,0.2412971123005)      (2.2222222222222,0.19579085829747)      (3.3333333333333,0.13758254145982)      (4.4444444444444,0.091150275097439)      (5.5555555555556,0.058470697966872)      (6.6666666666667,0.036749733066543)      (7.7777777777778,0.022774710835611)      (8.8888888888889,0.013969283552714)      (10,0.0085011109038277)     '. Please check for format mistakes..      Why? How can I avoid it?


title: How can I use the Optima font delivered with my Mac in LuaLaTeX?

text: I am trying the following on my Mac:               \documentclass{minimal}          \usepackage{fontspec}          \begin{document}          \setsansfont{Optima}          \textsf{Test}     \end{document}      But I get the following:               !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!     !     ! fontspec error: "font-not-found"     !      ! The font "Optima" cannot be found.     !      ! See the fontspec documentation for further information.     !      ! For immediate help type H <return>.     !...............................................      I was under the impression this would work. What have I missed?


title: Typeset index upright automatically

text: As discussed for example here: Should subscripts in math mode be upright? subscripts should usually be typeset upright. Is there a possibility to this automatically e.g. inserting something to the document-header? Or, if not possible in LaTeX, is there an option in LyX? Until now I do it like this: `Q _ Alt Z R test` which is quite slow.


title: Tabular p-column and environment gives strange output

text: The code below does produce a clearly too high column. The same effect can also be seen with other environments (center, ...). ![first column to high](http://i.stack.imgur.com/JpnEt.png) **How can I use the p-column and have the correct height at the same time?** Code:               \documentclass{scrreprt}     \usepackage{listings}          \begin{document}          \begin{tabular}{|p{1cm}|p{8cm}|}         \hline         A &%         \begin{lstlisting}     [1.67007,1.99831e-06,0.000413824]         \end{lstlisting} \\         \hline     \end{tabular}          \begin{tabular}{|p{1cm}|l|}         \hline         A &%         \begin{lstlisting}     [1.67007,1.99831e-06,0.000413824]         \end{lstlisting} \\         \hline     \end{tabular}          \end{document}


title: Install OpenType fonts in Texlive

text: Maybe this topic has already been discussed, but I haven't found anything clear about it! I bought Garamond Opentype fonts by Adobe, so I have *.otf font files. I'd like to use it in my thesis, but i can't install it in TexLive 2011! I've downloaded pad.zip file from http://www.ctan.org/tex- archive/fonts/psfonts/w-a-schmidt, and after long hours I sucessfully converted .otf to .pfb. Then I used Crossfont to obtain the .afm file... and now? Do I need any other file? I read that using autoinst may help, but how? Please, help!


title: How to jump to the first slide of the previous frame when pressing page up in presentation?

text: I have a beamer presentation with frames A, B, and C. Frame B has several slies (made with overlays) that are shown in a timed sequence finishing at at frame C. Then, at frame C, I'd like to press the page up key to go back to the beginning of frame B instead of going back to the last slide of frame B, which is putting me back into frame C. How can I do this?


title: Very wide columns with dcolumn package

text: I want the the following table to be perfectly centered within the margin, with an approximately even spacing between each column.                \documentclass[a4paper,11pt]{article}       \usepackage{color,amsmath,amsfonts,amssymb}          \usepackage[english]{babel}       \usepackage{colortbl}       \usepackage{booktabs,dcolumn,caption}       \usepackage{expdlist}  %expanded list environment       \usepackage{longtable} %multipage table       \usepackage{setspace} %for \singlespacing       \usepackage{adjustbox} %center tables       \usepackage{icomma}            \usepackage[margin=1in]{geometry}       \usepackage{setspace}       \setstretch{1}                \captionsetup{labelsep=newline,singlelinecheck=false} % optional      \newcolumntype{d}[1]{D{.}{.}{#1}} % "decimal" column type                \setlength{\LTleft}{0pt}      \setlength{\LTright}{0pt} %full margins           \oddsidemargin 0.5cm %      \evensidemargin 0.5cm %      \textwidth 15cm %      \topmargin  -0.2in  %      \textheight 23.5cm %      \headheight 15pt %                \doublerulesep2pt           \begin{document}                \footnotesize           \begin{longtable}{@{} l @{\extracolsep{\fill}} *{2}{d{5}} @{}}      \caption{Pearson correlations} \\      \toprule      & \multicolumn{1}{l}{$(del1,del2)$}      & \multicolumn{1}{l}{$(del1,del3)$} \\      \midrule      \endfirsthead      \multicolumn{2}{@{}l}{\emph{(continued)}} \\      \toprule      & \multicolumn{1}{l}{$(del1,del2)$}      & \multicolumn{1}{l}{$(del1,del3)$} \\      \midrule      \endhead      \midrule[\heavyrulewidth]      \multicolumn{3}{r@{}}{\emph{(continued)}}      \endfoot      \bottomrule      \endlastfoot      Hello                & -0.032(Q>0.671) & 0.036(Q>0.620) \\      Hello                & -0.032(Q>0.671) & 0.036(Q>0.620) \\      Hello                & -0.032(Q>0.671) & 0.036(Q>0.620) \\      Hello                & -0.032(Q>0.671) & 0.036(Q>0.620) \\      Hello                & -0.032(Q>0.671) & 0.036(Q>0.620) \\      Hello                & -0.032(Q>0.671) & 0.036(Q>0.620) \\      Hello                & -0.032(Q>0.671) & 0.036(Q>0.620) \\      Hello                & -0.032(Q>0.671) & 0.036(Q>0.620) \\      Hello                & -0.032(Q>0.671) & 0.036(Q>0.620) \\      \end{longtable}      %\vspace{-0.8cm}           {\noindent ....}      \clearpage                     \end{document}


title: How to force equation to be closer to the sum operator?

text: I would like to know if it is possible to force the equation to be closer to the operation sum? When there are a lot of subscript under the sum operator, it tends to pouch the equation to the right, and this is not very aesthetic.               \sum_{n\in N_{-i}}\sum_{\substack{j \in N_{-i} \\ j \neq n}}v_j


title: Changing the way authors' names are displayed in a citation?

text: For example, currently if I do a `\cite{name}` I get this: (AUTHOR1, 2000)   (AUTHOR1; AUTHOR2, 2000)   (AUTHOR1; AUTHOR2; AUTHOR3, 2000) What I'd like is to have et al. beyond 2 authors and have "and" when there are just 2. So: (AUTHOR1, 2000)   (AUTHOR1 and AUTHOR2, 2000)   (AUTHOR1 et al., 2000) Is it possible to get that? I've found these packages being imported by the model:               \usepackage[bibjustif,abnt-etal-cite=3,abnt-full-initials=yes]{abntcite}     \usepackage[toc,page]{modelo/tex/appendix}     \usepackage[portuguese,brazilian,portuges]{babel}     \usepackage[utf8]{inputenc}     \usepackage{abnt-alf}     \usepackage{graphicx}     \usepackage{multicol}     \usepackage{listings}     \usepackage{booktabs}     \usepackage{amsmath}     \usepackage{amsthm}     \usepackage{eucal}     \usepackage{amssymb}     \usepackage{mathrsfs}      If I edit the `abnt-etal-cite=2` I can get the et al. as I need, but what about the separator between 2 authors names?


title: Text not visible if positioned over included colored pdf?

text: I'm having a strange issue with LaTeX: My document uses a PDF background that is included with `\includepdf{pdf/title}`. This PDF consist of some logos and a solid red colored stripe across the page. I need to show some text above this colored area. The problem is, that as soon the text is over this area it becomes invisible on the rendered PDF. I can select it with the cursor though. If I'm moving the text out of the colored area (but its still over the background PDF) the text becomes visible again.               \newcommand{\createCover}[3]     {              \thispagestyle{empty}         \begin{titlepage}         \setlength{\TPHorizModule}{1mm}         \setlength{\TPVertModule}{1mm}         \textblockorigin{0mm}{0mm}          \begin{textblock}{111}(83,115)             \begin{minipage}[c][1,78cm][c]{11,09cm}                  \fontsize{22pt}{20pt}             \selectfont             \begin{center}             #1             \end{center}             \end{minipage}         \end{textblock}         \begin{textblock}{111}(83,131)             \begin{minipage}[c][4,81cm][t]{11,09cm}              \linespread{1.2}             \fontsize{16pt}{14pt}             \selectfont         \begin{center}         #2 \\ \medskip         #3         \end{center}         \end{minipage}         \end{textblock}         \begin{textblock}{186}(22,264)         \begin{minipage}[t][5,72cm][l]{17,57cm}             \fontsize{12pt}{12pt}             \selectfont                 {\em Subtext \hfill Subtext 2}\\                 {\em Subtext 3 \hfill Subtext 4}         \end{minipage}         \end{textblock}         \newpage         \end{titlepage}         \includepdf{pdf/title}     }      I would be very thankful for any help. **UPDATE:** Since I'm not allowed to answer my own question for 8 hours, I'm updating my question with the solution that worked for me: Thanks to Martin, I have found the solution. He was completely right: The PDF doc was in the foreground, so the underlining text was not visible. The solution is to add the **overlay** parameter to the **textpos** package.               \usepackage[absolute,overlay]{textpos}      Now the text is in the foreground. Thanks again.


title: LaTeX commands for centering the equations without numbering them

text: What LaTeX commands should I use to center the equations on the page, but without numbering them?


title: Tabular+dcolumn+mathspec — columns overlapping

text: I would like to typeset a table using the `D` column type as described in the `dcolumn` package. When I combine this with `\setmathfont(Digits){Gotham Narrow Light}` I get overlapping columns:               \documentclass{article}     \pagestyle{empty}     \usepackage{lipsum}     \usepackage{dcolumn}     \newcolumntype{d}[1]{D{.}{.}{#1}}     \usepackage{mathspec}     \setmainfont[BoldFont=Gotham Narrow Medium]{Gotham Narrow Book}     \setmathrm{Gotham Narrow Book}     \setmathfont(Latin){Gotham Narrow Book}     % works fine     %\setmathfont(Digits){Monaco}     \setmathfont(Digits){Arial}     % causes column overlapping     \setmathfont(Digits){Gotham Narrow Light}          \begin{document}     \lipsum[1]     \[     \begin{array}{d{1.3}|d{1.5}|d{1.4}|d{1.4}|d{1.4}}     1.500 & 2.75000 & 0.5000 & 0.2500 & 1.2500 \\     1.750 & 2.93750 & 0.2500 & 0.0625 & 1.0625 \\     1.900 & 2.99000 & 0.1000 & 0.0100 & 1.0100 \\     1.990 & 2.99990 & 0.0100 & 0.0001 & 1.0001 \\     1.999 & 3.00000 & 0.0010 & 0.0000 & 1.0000 \\     2.000 & 1.00000 & 0.0000 & 2.0000 & 3.0000 \\     2.001 & 3.00000 & 0.0010 & 0.0000 & 1.0000 \\     2.010 & 2.99990 & 0.0100 & 0.0001 & 1.0001 \\     2.100 & 2.99000 & 0.1000 & 0.0100 & 1.0100 \\     2.250 & 2.93750 & 0.2500 & 0.0625 & 1.0625 \\     2.500 & 2.75000 & 0.5000 & 0.2500 & 1.2500 \\     \end{array}     \]     \lipsum[2]     \end{document}      ![sample output](http://i.stack.imgur.com/RDXyt.png) I've tried with other monospace and proportional fonts and they seem to work fine. Is something wrong with Gotham?


title: How can you position a node relatively to another in TikZ

text: I would like to place a node 'B' 60 degrees of an arbitrary node 'A' between which there is a distance of 2cm. I can do this if node 'A' is at (0, 0), so 'B' would just be (60 : 2) from 'A', but what happens when 'A' is not at (0, 0)?


title: How to avoid bad quality image

text: > **Possible Duplicate:**   >  Included PNG appears blurry in PDF I have a PNG image with a pretty good quality, but when I import this in `beamer` it has lost its quality, even if I maintain the 1.0 as scale factor. How can I avoid it? Is vectorial image the one solution? I grab this image from a website. I use this code to import image:               \begin{figure}[here]     \begin{center}     \includegraphics[scale=1.0]{img/dp2}     \end{center}     \end{figure}      I'm using `pdflatex`. PS: I have no type of knowledge about graphic and photoediting. ![Original image, on the left looks bigger when imported ad 1 as scale factor](http://i.stack.imgur.com/9OfzC.png)


title: How to correctly include pixel graphics with pdflatex with consistent scaling across PDF viewers?

text: > **Possible Duplicates:**   >  Included PNG appears blurry in PDF   >  My pixel perfect picture gets blurry when compiled in LaTex I often need to use pixel graphics in LaTeX files (mostly screenshots), but I don’t really know what’s the best way to do it. Let me illustrate the problem I am having with the following minimum working example:               \documentclass{scrartcl}     \usepackage{graphicx}     \begin{document}     \includegraphics{scrot.png}     \end{document}      You can get scrot.png from http://t.zekjur.net/tex/scrot.png (it’s just a screenshot I made with the tool `scrot`. Any pixel graphic will do). After using `pdflatex mwe.tex` I get `mwe.pdf`. The picture in it looks good (sharp, not scaled but at its native size) in Xpdf when I chose 100% zoom level. **However** , when I open the same file with evince instead of Xpdf, I cannot get the picture to look good -- no matter which zoom level I choose. This is what it looks like in Xpdf: ![](http://i.stack.imgur.com/XjXNI.png) and this is what it looks like in evince: ![](http://i.stack.imgur.com/Cst83.png) What is the reason for this problem and what is a better way (aside from using vector graphics, obviously)?


title: Prevent LaTex from word wrapping subsequent lines

text: I am writing (partially) in german. German words tend to be quite long and my page is rather slim (I'm using the classicthesis template). So words get wrapped quite often which results in a lot of subsequent lines ending with dashes. Typographically, this is not very nice: ![Furious Line breaking](http://i.stack.imgur.com/fGvqi.png) Is there a way to prevent that? I know that programs, such as Indesign have such a feature. Is there something similar for LaTeX?!


title: tikzpicture draw inside node/frame

text: I'm trying to reproduce a picture and I'm having a problem (since this is my very first experience with tikzpictures). The picture is the following: ![image to be reproduced](http://i.stack.imgur.com/P2jZ1.png) My problem is of how to create the part that is inside the frame in the middle and more precisely how am I supposed to "frame" it like that (with the underlying part - description) and connect it later with the other nodes I have. Sorry if the question is very naive. Thanks in advance for any help.


title: Are there umlaut variants for non-blackletter fonts?

text: In the `yfonts` package for blackletter fonts, there is an option `varumlaut` that puts a tiny "e" instead of the two dots on your umlaut ä, ö, ü. Is there any other font that has these kind of glyphs? (In particular, I am searching for a Garalde typeface).


title: Adding a .sty file to the appropriate directory?

text: I am using emacs on Ubuntu 10.10. I was trying to add `doublespace.sty` to my packages. To figure out what directory to put the doublespace.sty in I did a search on my computer for `amsmath.sty`, since I know that package works, and found the directory it was in, which was a subdirectory of `/usr/share/texmf-texlive`. Since there are a bunch of `.sty` files in that directory, I decided to put `doublespace.sty` in `/usr/share/texmf-texlive/latex/base` . Then I ran `texhash` on that directory. But for some reason it is telling me it can't find `doublespace.sty` when I do `/usepackage{doublespace}`. Any idea what might be going on?


title: beamer footnote not showing

text: I was wondering what's the appropriate way to add a footnote to a LaTeX `beamer` presentation, because I am trying `\footnote` and it's not showing the footnote. It shows the number but no footnote.


title: Using urw-garamond fonts in plain TeX

text: I am struggling with a font problem that I can't solve by myself. I almost always write my files with pdfLaTeX and the `urw-garamond` fonts from `mathdesign`. However I would like to produce the same output with plain TeX or plain XeTeX, but with no success. I tried to read the `mathdesign.sty` file, and yet I can't really understand what is going on. The point of my question is about mathematical formulae, since I think I could use Garamond with XeTeX with little effort. Can you give me some hints?


title: How to reduce space between items in enumerate?

text: My question refers to previous question already asked on forum. No spacing between enumerated items with \usepackage{enumerate} I need reduce space between enumerated items. How can i do it?                 \begin{enumerate}[-]          \item ABC          \item DEF          \item XYZ       \end{enumerate}      Regards


title: Looking for a better code for my \newcommand

text: While preparing my lecture notes, I decide to create a command, possibly a new environment, that highlights when I am presenting a worked example. I came up with the following code. The code does kinda satisfy my general use and its purpose but I am looking for a possible better code that includes the following:   1. The environment should use the entire textwidth and expand vertically as text is added. The table kinda does that feature for it expands vertically as you add text. If you notice in my code I forced the textwidth of the table so that it more or else seems to fit the page. I am still working on that.   2. That the environment possibly expands to a next page by saying where "Example 1" is "Contd. Example 1." I hope this not too hard to figure out.  I forced tikzpicture to be aligned with the table border but I know this is not the best way. Any assistance into the matter will be highly appreciated.                   \documentclass[letterpaper]{article}         \usepackage{fullpage,color}         \usepackage{array,tikz}         \parindent0pt         \definecolor{mblue}{rgb}{0,0.6,0.8}         \newcounter{mEgnum}         \newcommand{\eg}[1]{%         \par\vspace*{0.5cm}\stepcounter{mEgnum}         \begin{tabular}{p{15cm}l|}         \hline\setlength\parindent{-2.17mm}         \begin{tikzpicture}         \draw [color=mblue,fill=mblue](0,0) rectangle (0.25,0.75);         \draw [color=mblue!20,fill=mblue!20](0.25,0) rectangle (3.5,0.75);         \draw (0.5,0.375) node [right] {\large\textbf{ Example \arabic{mEgnum}}};         \end{tikzpicture}         & \tabularnewline         #1         &\tabularnewline\cline{2-2}         \end{tabular}\par\vspace{0.5cm}\noindent%         }              \begin{document}         \eg{Solve the following inequalities and represent the solution set in Set-Builder, Interval Notations and on the Number Line.&\tabularnewline}         \end{document}       ![Sample](http://i.stack.imgur.com/3UQQH.png)


title: Switching between environments

text: I teach at the university and I write exams in Tex. I'd like to write an exam with a number of questions, where for each question I include either empty lines and empty figures with axes (for the actual exam - students to fill) OR the solution, including complete figures. For example:               Q. Illustrate what happens to the demand of housing when interest rates go down.          \begin{nosolution}     A FEW HORIZONTAL LINES     \begin{figure}     \includegraphics[scale=1]{EmptyGraph_withAxes}     \end{figure}     \end{nosolution}          \begin{solution}     It will increase....      \begin{figure}     \includegraphics[scale=1]{HousingDemand}     \end{figure}     \end{solution}      Then set a paramater at the beginning of the exam such as \printsolution, which says to print what is within the \begin{solution}...\end{solution}, and otherwise print what is within the \begin{nosolution} ... \end{nosolution}. I defined a solution and nosolution environment:               \newenvironment{solution}     {     \vspace{0.5cm}     \textbf{Solution.} \quad \itshape     }{}          \newenvironment{nosolution}     {     \hrulefill     \hrulefill     \hrulefill     }{}      Is there a way to switch between one and the other depending on an initial parameter like \printsolution? I have been trying the exam class (exam.cls) but it is not perfect for what I need to do because it cannot take floats in the solutions: I get a lost float message. I also checked the documentation which confirmed that floats are not supported because it uses frames. thanks, Mario


title: How to mix lhs2TeX code and spec lines in a single block?

text: Suppose I have an incomplete code block like:               \documentclass{article}     %include polycode.fmt     \begin{document}     \begin{code}     somefunction :: a -> a     \end{code}     \begin{spec}     somefunction x = undefined     \end{spec}     \end{document}      It is supposed to express a work in-progress, because `somefunction` is only defined at a later point, so I want to hide this incomplete definition from ghc, but I want to reuse the type signature. Unfortunately in this setup there is a vertical space between the two lines. A workaround is to rewrite the document body as follows:               \begin{spec}     somefunction :: a -> a     somefunction x = undefined     \end{spec}     %if False     \begin{code}     somefunction :: a -> a     \end{code}     %endif      This has the downside of being repetitive and thereby likely to introduce mistakes. The space inserted appears to be about `\belowdisplayskip` + `\baselineskip` + `\abovedisplayskip`, so one could add negative `\vspace` in the former definition. Is space really the sum of the above? What solution is recommended for gluing `code` and `spec` environments?


title: How to make a line break in a TikZ matrix cell?

text: Can I use TikZ's own tools to make a line break in the matrix cells or do I have to use a `tabular`-environment or a `\parbox`? ## MWE (doesn't work, I included the faulty code)               \documentclass[     11pt     ]{scrartcl}     \usepackage{     tikz,     relsize,     tgheros     }          \usetikzlibrary{         calc,trees,shadows,positioning,arrows,chains,         decorations.pathreplacing,         decorations.pathmorphing,         decorations.shapes,         decorations.text,         shapes,         shapes.geometric,         shapes.symbols,         matrix,         patterns,         intersections,         fit     }          \pgfdeclarelayer{background layer}     \pgfdeclarelayer{foreground layer}     \pgfsetlayers{background layer,main,foreground layer}          \tikzset{         >=latex,         line/.style={draw, thick, ->},         phase/.style={             text height=1.5ex,             text depth=0ex,             align=left,             anchor=center,             %   text width=6cm,             font=\sffamily\bfseries\small,             rectangle,             minimum height=1.0cm,             draw=black,             very thick,             fill=black!40         }     }          \begin{document}     \begin{center}     \begin{tikzpicture}[font=\sffamily\small,node distance=0.5cm]     \matrix (m) [     matrix of nodes,     nodes in empty cells,     row sep=6mm,     column sep=3mm,     inner sep=7pt     ] {         %         |[phase]| This should include\\a line break\\         |[phase], align=center| Here should be a line\\break as well.     };     \end{tikzpicture}     \end{center}     \end{document}


title: Multiple bibliography and MLA style

text: I have to write my BA Thesis in the MLA Style and I tried different stuff such as   Biblatex and mla-paper making weird headings this. The problem is I need to use two bibliographies, two .bib files. One for primary and the other one for secondary sources. How do I do that? It also gives me the word "Print" at the end of a reference. I want to get rid of it. Right now I'm this far (it has only one bibliography so far):               \documentclass[12pt]{scrartcl}     \usepackage{geometry}                     \geometry{a4paper, top=25mm, left=35mm, right=35mm, bottom=25mm}                      \usepackage{graphicx}     \usepackage{amssymb}     \usepackage{epstopdf}     \usepackage[latin1]{inputenc}     \usepackage[american]{babel}     \usepackage[T1]{fontenc}     \usepackage{enumitem}     \usepackage{stmaryrd}     \usepackage{makeidx}     \makeindex     \usepackage{amsmath}     \numberwithin{equation}{section}     \usepackage{hyperref}     \usepackage{underlin}     \usepackage{qtree}     \usepackage{tipa}     \usepackage{natbib}     \usepackage{subfigure}     \usepackage{ifthen}     \setcitestyle{notesep={  }}     \usepackage{csquotes}     \usepackage[style=mla]{biblatex}          \usepackage{ifpdf}     \usepackage{mla}     \bibliography{prim}          \makeatletter     \renewcommand\@cite[2]{     ({ #1\ifthenelse{\boolean{@tempswa}}{ \nolinebreak[3] #2}{}})     }     \makeatother     \usepackage{cite}     \pagestyle{headings}          \DeclareGraphicsRule{.tif}{png}{.png}{`convert #1 `dirname #1`/`basename #1 .tif`.png}          \tableofcontents     \newpage                                                 \begin{document}     \newcommand{\attrib}[1]{\nopagebreak{\raggedleft\footnotesize #1\par}}          \begin{mla}{kim}{foo}{bar}{ha}{\today}{week}     \setcounter{page}{1}     \renewcommand{\baselinestretch}{1.50}\normalsize          \cite[23]{maggie}     \end{mla}          \printbibliography          \end{document}


title: Spacing before and after section titles

text: I know this subject has been mentioned before, but I'm still having a problem in creating a space under a section title. I used the `titlesec` package and then tried using the command `\titlespacing{\section}`... This is my code. Can anybody help?               \documentclass[10pt]{book}     \usepackage[utf8]{inputenc}     \usepackage{fullpage}     \usepackage[compact]{titlesec}     \usepackage{setspace}     \usepackage{sectsty}     \chapterfont{\huge}     \sectionfont{\Huge}     \begin{document}     \chapter*{Kapitel 1}     \section*{Einleitung}     \begin{large}     \subsection*{1.1 Motivation}


title: Using a theorem-based environment inside a list

text: When I include a theorem-based environment right after the start of a list item, a linebreak is inserted that looks a little funny.               \documentclass{article}     \usepackage{amsthm}     \newtheorem{claim}{Claim}     \begin{document}     Problem:     \begin{enumerate}         \item First part of problem         \item Second part of problem     \end{enumerate}          Solution:     \begin{enumerate}         \item First part of solution         \item         \begin{claim}             Result X holds         \end{claim}         By Result X, the second part follows.     \end{enumerate}     \end{document}      The linebreak occurs after Item 2 of the solution, since theorem environments always start with a linebreak. Is there an alternative to a theorem environment that I should be using? I am looking for a solution that is as canonical as possible, and doesn't require tweaking lots of settings manually. **EDIT:** While updating my code snippet to make it a MWE, I realized that omitting the `\usepackage{amsthm}` fixes the problem. However, in my actual LaTeX document I would prefer to keep using amsthm.


title: How to make Times-Roman appear instead of NimbusRomNo9L-Regu in the PDF document properties in LaTeX?

text: When we generate a simple document in LaTeX using the times package (\usepakage{times} @ 9pt), the resultant PDF will contain NimbusRomNo9L-Regu instead of Times-Roman. (I know, this is because, LaTeX is renaming Times to Nimbus for embedding the font in PDF. Correct me if I am wrong.) We can make Times-Roman to appear in the PDF (instead of NimbusRomNo9L-Regu) by adding some mapping in dvips configuration file (config.ps or config.pdf). How do we do this. Thus generated PS file when distilled using Adobe Distiller will show Times-Roman instead of NimbusRomNo9L-Regu. I am searching the internet resources for a couple of days to find a suitable explanation for this. But I did not get a suitable answer. I hope somebody in this list can help me in fixing the problem.


title: How to indent the equation number a bit to the left?

text: How can I add space after the equation numbering? MWE:               \documentclass{book}     \usepackage{amsmath}      \begin{document}       \begin{align}         a = b + c       \end{align}      \end{document}      So I want to move the equation number a little bit more to the left:               a = b + c                                                     (1)   <--   (1)      EDIT/SOLUTION: I could adjust my code thanks to barbara beeton:               \makeatletter     \def\tagform@#1{\maketag@@@{(#1)\unskip\@@italiccorr}\hspace{2em}}     \makeatother


title: Title above left line

text: I'm trying to create a `mdframed` environment where   1. The title is repeated on every page (works fine with `repeatframetitle`)   2. the title is left aligned relative to the normal text and this implies that the left line should start below the title.  Can someone help me with 2? How do I remove the line? And how to get rid of the ugly `10.4pt`?               \documentclass[parskip=half-]{scrartcl}     \usepackage{lipsum}     \usepackage[framemethod=tikz]{mdframed}               \newmdenv       [leftmargin=0pt,       topline=false,rightline=false,       frametitle={\hspace{-10.4pt}I want the title here and no line beside it},       repeatframetitle=true,       everyline=true       ]{test}               \begin{document}          \lipsum[1]               \begin{test}     \lipsum\lipsum     \end{test}          \end{document}


title: Saving in macros plus \scantokens as an alternative to external files

text: I am generating a lot of TeX code automatically using Python scripts. I've been saving the TeX code to file, and then bringing those files into my documents at the appropriate places via `\input`. That works, but sometimes it results in a lot of external files, many of which are only a few lines long. I'm thinking about saving the generated TeX code in macros. I could just bring in a big file of macro definitions in my preamble rather than many small files at various points in the document. The problem with this approach is that the TeX code can contain verbatim and similar content. I've developed an approach for saving such content in a macro and then retrieving it using `\scantokens` (minimal example below). Does this approach have any disadvantages compared to leaving the TeX code in individual external files? Are there cases where `\scantokens` will fail to replicate exactly what I would get from `\input` with an external file? In terms of application, this is primarily related to my `pythontex` package. The package allows you to include Python code in a LaTeX document, execute it, and bring in its output. The Python code is saved to an external file during compilation. A script then executes each block of code, and saves each block's output in its own file. These files are automatically brought back into the LaTeX document at the appropriate place via `\input`. This allows the output of, say, a `print()` function in the Python code to be replaced by its output. Usually, printed content (the external files) would only be a couple to a few dozen lines, but they could be as large as the user wants.               \documentclass{article}          \makeatletter     \long\def\catcher#1{%         \def\name{#1}%         \begingroup         \endlinechar`\^^J         \let\do\@makeother\dospecials         \catcher@i}          \begingroup     \catcode`!=0     !catcode`!\=12     !long!gdef!catcher@i#1\endcatcher^^J{%         !endgroup!expandafter!gdef!name{#1}}%     !endgroup          \def\getter#1{\expandafter\scantokens\expandafter{#1\empty}}     \makeatother          \catcher\myfile     Text, with verb \verb!#$^_!     \begin{verbatim}     Verbatim     environment     \end{verbatim}     More text     \endcatcher          \begin{document}          \getter\myfile           \end{document}


title: No support for Asymptote in AUCTeX

text: I got a problem with my Emacs/AUCTeX setup. I'm using a lot of Asymptote graphics in my TeX documents, but there is a big problem to compile such documents inside of Emacs with AUCTeX. However I can compile those document from within Kile. For Emacs/AUCTeX this workaround works:   1. call from Emacs pdflatex(compile latex)   2. manually from the shell: `asy filename-1.asy`   3. call from Emacs pdflatex(compile latex) How can I tell AUCTeX to call the `asy` compiler automatically if needed?


title: Dependency graphs in ConTeXt

text: Have anyone tried using `tikz-dependency` with ConTeXt? http://danielepighin.net/cms/software/tikz-dependency Can anyone recommend other ways to create dependency graphs in ConTeXt?


title: LaTeX errors in Formatting

text: I want to print this text :   make -j 5 KDEB_PKGVERSION=1.yourcustomname deb-pkg But I feel because of the underscore , LaTeX generates an error **missing $ inserted** and it doesn't print it as well. Secondly, In the \fbox{} , I wanted to print the two texts on the next line(i.e) one text per line , so I used \ and even \par but it doesn't seem to work and I would like to align the (or) as well.                \fbox{\texttt{uname -a}\\(or) \texttt{cat /proc/version}}      Here is my full source code:               \documentclass[12pt]{article}     \author{Subham Soni S.}     \date{\today}     \title{Compiling and Installing a Kernel 3.13.3 On Ubuntu, Debian and its Derivatives}     \begin{document}     \maketitle     To replace the existing \textsl{kernel} with a new one, do the following:     \begin{enumerate}     \item Create a folder named \emph{kernel} in the home directory.     \item Download the latest kernel to the folder from  \texttt{www.kernel.org}.     \item Extract the file.     \item In the terminal, type the following command to \textbf{install the neccesary tools to compile the kernel}:       \begin{center}         \fbox{\texttt{sudo apt-get install gcc libncurses5-dev dpkg-dev}}       \end{center}     \item Enter the directory of the extracted kernel source       \begin{center}         \fbox{\texttt{cd kernel} \par \texttt{cd linux-3.13.3}}       \end{center}     \item Configure the kernel       \begin{center}         \fbox{\texttt{make menuconfig}}       \end{center}       In this menu you can customize your kernel     \item Save and exit     \item Compile the kernel       \begin{center}         \fbox{\texttt{make -j 5 KDEB_PKGVERSION=1.yourcustomname deb-pkg}}       \end{center}       \emph{This process might take a while...}     \item Install the kernel       \begin{center}         \fbox{\texttt{sudo dpkg -i ../linux*.deb}}       \end{center}     \item Reboot       \begin{center}         \fbox{\texttt{sudo reboot}}       \end{center}     \item Run the following commands to check the kernel version       \begin{center}         \fbox{\texttt{uname -a}\\(or) \texttt{cat /proc/version}}       \end{center}     \item You can easily uninstall the kernel with the command:       \begin{center}         \fbox{\texttt{sudo apt-get purge linux-image-3.13.3 linux-image-3.13.3-dbg}}       \end{center}     \end{enumerate}     \end{document}


title: #ifdef analog for LaTeX

text: For example there is a simple tex-file with following text:               \documentclass[tikz]{standalone}     \begin{document}     \begin{tikzpicture}     \draw (0,0) circle (0.4cm);     \end{tikzpicture}     \end{document}      Is it possible to modifiy it so: if I `\include` it another TeX file it is compiled as a picture in a document, while if it is compiled alone (say:`pdflatex myfile.tex`) it results in a standalone pdf file as the unmodified file?


title: \textleftarrow and mathpazo

text: I would like to use Palatino for running text and some matching fonts for math, so I use the package `mathpazo`. Is there a way to get the `\textleftarrow`?               \documentclass{article}     \usepackage[T1]{fontenc}     \usepackage{textcomp}     \usepackage{mathpazo}          \begin{document}     abc\textleftarrow     \end{document}


title: Align tikzpicture to body text with node as reference

text: In a example like the one below I would like to adjust the figure horizontally so that the grid aligns with the surrounding text and the y-axis and the label protrudes into the margin. Note that the width of the x-axis is exactly `\textwidth` so it should fit comfortably. I could do this manually with a negative `\hspace`, but this is not very exact and also un-TeXy. Ideally what I would like to do is to define a point within the `tikzpicture` environment to serve as reference point for external alignment. Thin I could experiment with aligning the y-axis with the text and whatnot. I did not find a way to this in the Tikz manual.               \documentclass[a4paper,onesided]{article}     \usepackage{tikz}     \usepackage{blindtext}          \begin{document}     \blindtext          \begin{figure}[h!]     \begin{tikzpicture}[y=0.5mm, x=0.333\textwidth]          \def\axissep{5mm}     \def\tickl{2mm}     \def\xlabsep{3mm}          % y-axis     \draw (-\axissep,0) -- (-\axissep,100);     % y-ticks     \foreach \x in {10,20,30,40,60,70,80,90} % avoids double inking on 0, 50 and 100 that becomes thicker         \draw (-\axissep,\x) -- ++ (-\tickl,0);     % y-tickslabels     \foreach \x in {0,50,100}         \draw (-\axissep,\x) -- ++ (-\tickl*2,0);     \foreach \x in {0,50,100}         \node[anchor=east] at (-\axissep-\tickl*2,\x) {\x};          % x-axis     \draw (0,-\axissep) -- ++ (3,0);     \foreach \x in {0,1,...,3}         \draw (\x,-\axissep) -- ++ (0,-\tickl);          % x-labels     \node[below] at (0,-\axissep-\tickl){1};     \node[below] at (1,-\axissep-\tickl){2};     \node[below] at (2,-\axissep-\tickl){3};     \node[below,align=center] at (3,-\axissep-\tickl){4};          % grid     \foreach \x in {0,10,...,100}         \draw[very thin, color=gray] (0,\x) -- (3,\x);          \draw (0,10) -- (1,14) --(2,45) -- (3,23) ++ (1mm,0) node[anchor=west] {\tiny Some label};          \end{tikzpicture}     \end{figure}          \blindtext          \end{document}      ![enter image description here](http://i.stack.imgur.com/F4fKo.gif)


title: Confused visibility of PDF layers when restoring from fullscreen mode

text: one of may colleagues observed that the visibility of some PDF layers may (unreasonably) change when the document restores from Fullscreen mode. Steps to reproduce:   1. Open the file ocg-p_example_4.pdf from ocg-p bundle at http://www.ctan.org/pkg/ocg-p . The direct link is http://mirror.ibcp.fr/pub/CTAN/macros/latex/contrib/ocg-p/examples/ocg-p_example_4.pdf .   2. Press ctrl+L for fullscreen.   3. Click the header "Grade" in the second table (ocgtabular). The table becomes sorted with respect to grade.   4. Press Esc to return to the window mode. The table is **not** sorted now. Few more tests give suspicion that some of the changes of visibility of PDF layers which have been made in Fullscreen mode and with help of javascripts do not persist after leaving fullscreen. Do you have any idea how to change this behavior? Many thanks. EDIT: The question is related to Adobe Reader browser (because of ocg layers and javascripts).


title: Ukrainian language support in ConTeXt

text: Are there any possibilities to write Ukrainian texts in the ConTeXt system? What do I need to do this?


title: Perform simple calculations on user-defined variables

text: In my document, I have a user-defined variable like:                \newcommand{\MyNumber}{30}      Suppose, if I want to use a derivative of \MyNumber, it could be \MyNumber+10, 100-\MyNumber, 5*\MyNumber of \MyNumber/5, can that be done? One step forward, if I have:               \newcommand{\MyNumberA}{30}          \newcommand{\MyNumberB}{60}      Can I use, \MyNumberA+\MyNumberB?


title: How to properly format a proof/explanation with multiple points of alignment?

text: This answered question addresses how to properly align/format a proof, allowing one to add text commentary alongside equations without ruining the alignment of the equations; however, it only seems to allow for one point of alignment in the equation and one point of alignment in the text, how can we get a similar result with multiple points of alignment? eg. points of alignment for equations are indicated by an asterisk (*)                 *aaaaaaaaa *= bbbbbbbb     = *ccccccccc *= bbbbbbbb      comment or explanatory remark.     = *ddddddddd *= bbbbbbbb      second comment or explanatory remark.      Here is a hacked approximation of what I was trying to describe: ![Sample rendering approximating desired format](http://i.stack.imgur.com/V5yGi.png) Here:   * the column of `\Rightarrow` and `=` are right-aligned;   * the LHS of the equations are right-aligned;   * the column of `=` are left-aligned;   * the RHS of the equations are left-aligned;   * the text is also left-aligned.  **Issues that I could not resolve even in this hacked example:**   1. Ideally the the text would be pushed as far to the right as possible and have minimal effect on the horizontal centering of the equations (i.e. w.r.t. the page). It would be especially nice if it were possible to specify the width of the text column in such a way that text exceeding that width would automatically format justified and multi-lined, vertically centered about the corresponding line of math, but I imagine that's a bit of a pipe dream …    2. The final boxed form would be properly centered w.r.t. to the math above it. I realize it may not be possible to do this easily and so am open to any other means of clearly distinguishing the final form.


title: technical drawing with automatic re-shaping from list

text: I would like to know which program will suit my needs. I want to do technical drawings for direct use in (wood) workshop, specifically organ-building.   1. We prefer 1:1-scaled drawings, exactly printed, that we pin on a board. The workers reports mainly the dimensions rulerless, using compasses or this kind of tools. They then verify the dimensions piece by piece on the drawing.   2. The views are standard: top, side and front.   3. We use mainly simple geometrical figures, rectangles (Hexahedrons), circles (cylinders) and triangles (cones), in different colors for readability. And of course lines (axis).   4. Many, and thats my main preoccupation with it, many (at least hundreds up to thousands) pieces should be defined automatically in their dimension, since they are standardized in their construction but adapted in size to the customer's project and to the function inside the project. They are indeed all different in sizes within a project (in the case of the pipes). Using graphical CAD-programs mean much work to adapt to each project, while TeX does much automatically. So I mean in my idea, and ods (or any list/table) contains the sizes needed for the project, and the drawing program says declarations like               \include{thisCustomersProject.ods}      \def \woodenpipe{... a set of hexaedrons...}      \def \rank {... a set of \woodenpipe according to a list in thisCustomersProject ...}      \place \rank {... first left bootom point ...}      I found sketch, PSTricks and TikZ, but reading the doc didnt helps me that far, since without knowing deeply each program is not helped. Does somebody can help with a recommandation? (even a graphical program with automatical re- shaping from an external table would do the trick). Thanks in advance!


title: Accessing sub/keys with l3keys

text: I'm not sure if I'm taking it too far, but I think I've seen something like this around. This gives an error:               \documentclass{scrartcl}     \usepackage{xparse}     \ExplSyntaxOn     \NewDocumentCommand \RULE {}       {         \rule{\l_tmpa_dim}{\l_tmpb_dim}       }     \keys_define:nn { foo / bar }       {         tmpa .dim_set:N = \l_tmpa_dim,         tmpb .dim_set:N = \l_tmpb_dim,         tmpa .initial:n = 1em,         tmpb .initial:n = 4em,       }     \NewDocumentCommand \dimsetup { m } { \keys_set:nn { foo } { #1 } }     \ExplSyntaxOff     \dimsetup{bar={tmpa=3em,tmpb=1em}}     \begin{document}       \RULE     \end{document}      leads to > >     !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! >     ! >     ! LaTeX error: "kernel/key-unknown" >     ! >     ! The key 'foo/bar' is unknown and is being ignored. >     ! >     ! See the LaTeX3 documentation for further information. >     ! >     ! For immediate help type H <return>. >     !............................................... >   Is that how it's expected to be? How can I easily use this key-value inside a key (do I need to define `bar` so it passes the options?). I think I've seen this around, and I thought that this worked. This is the “manual” workaround of what I want to achieve:               \dimsetup{bar/tmpa=3em,bar/tmpb=1em}


title: Split LaTeX footnotes into two columns

text: I have a number of short footnotes that form a column and make my paper look pretty crappy, and so I'd like to have LaTeX put multiple footnotes on one horizontal line. I've tried using the `[para]{footmisc}` package, but that bunches them all up on one line with no space between them and makes it unreadable. Really, I just want a maximum of three footnotes on a line, depending on their length (I have a mix of very short footnotes ("DM 13") and long, self-indulgent ones). Also, footmisc's para gets rid of my favourite options from `footmisc` like `hang`, `flushmargin` and my `\skip\footins`. I'm sure the `manyfoot` package can do this, but I don't really have time to read through and understand the documentation at present. I'm very new to LaTeX (please go easy on me!). Does anyone have any ideas?


title: For 2 references the full author list is displayed, for all other references, only the name of the first author and et al. is displayed

text: In the main text, I would like to cite my references as 'First Author et al.' For most references, this works just fine. However, for 2 of my references the entire author list is begin displayed in the main text. As far as I can tell, the author list is formatted identical to those references that work. Does anyone know what might be causing the full author list being displayed for just 2 of my references? In the examples below, the first examples (Mordant et al.) is one of the references that isn't working. The second example (Muramatsu et al.) is an example of a reference that is working just fine. I am using the `agsm` bibliography style and I'm using JabRef as my reference manager. _edit_               @ARTICLE{Mordant2011a,         author = {Mordant, David J. and Al-Abboud, Ied and Muyo, Gonzalo and Gorman, Alistair and Sallam, Ahmed and Rodmell, Paul and Crowe, John and Morgan, Steve and Ritchie, Peter and Harvey, Andrew R. and McNaught, Andrew I.},         title = {Validation of human whole blood oximetry, using a hyperspectral fundus camera with a model eye},         journal = {Invest Ophthalmol Vis Sci},          year = {2011},         volume = {52},          pages = {2851-2859},         type = {Journal Article}     }          @ARTICLE{Muramatsu2011,         author = {Muramatsu, Chisako and Hatanaka, Yuji and Iwase, Tatsuhiko and Hara, Takeshi and Fujita, Hiroshi},         title = {Automated selection of major arteries and veins for measurement of arteriolar-to-venular diameter ratio on retinal fundus images},         journal = {Comput Med Imaging Graph},         year = {2011},         volume = {35},         pages = {472-480},         number = {6},         type = {Journal Article}     }      Here is a MWE that reproduces the issue:               \documentclass[12pt]{article}     \usepackage{natbib}     \AtBeginDocument{\renewcommand{\harvardand}{and}}     \renewcommand*{\refname}{}     \usepackage{chapterbib}     \begin{document}          \bibliographystyle{agsm}               \section{Introduction}          Image registration algorithms were necessary to correct for any eye movements that occurred between the individual images \citep{Kim2011, Mordant2011, Mordant2011a, Narasimha-Iyer2005}.     \subsection{References}          \bibliography{thesis}          \end{document}      The bibtexkey for both Mordant references are _Mordant2011_ and _Mordant2011a_.


title: set character/symbol from a particular font instead of bullet in beamer

text: I am using fontspec and beamer and would like to change the bullet symbol of "itemize" to a given character. I have tried               \setbeamertemplate{itemize item}[]      Before and after `\begin{document}`, but it did not work. So far, the only thing that works is `\item[☙]`, but it's too cumbersome to use every time I want an item. A MWE looks like this:               \documentclass[xcolor=dvipsnames]{beamer}      \setbeamertemplate{itemize item}[☙]     \usepackage{fontspec}     \setmainfont{EB Garamond}     \usefonttheme{serif}          \begin{document}          \begin{frame}     \begin{itemize}     \item \item \item     \end{itemize}     \end{frame}          \end{document}


title: pdfLaTeX+MakeIndex+BibTex does not run in Dropbox

text: When on Windows 7 I run pdfLaTeX+MakeIndex+BibTex in Dropbox, it does not produce a bbl file. If I then separately run Bibtex, it works fine. Also, if I compile the same file on C-drive, everything works fine in one step.


title: How to prevent Table of Contents from being added to the bookmarks of a pdf file

text: I have a set of pdf files (without the latex source) which I merged into a larger pdf file. Each individual pdf file is an article with sections. I created a set of bookmarks for the larger pdf which point to each of the sections in each of the constituent smaller pdf files using the bookmarks package.               \bookmark[level=2,page=6,view={FitH 842}]{<Section>}     \bookmark[level=3,page=6,view={FitH \calc{\paperheight-\topmargin-8in} null}]{<Subsection1>}     \bookmark[level=3,page=8,view={FitH \calc{\paperheight-\topmargin-7in} null}]{<Subsection2>}     \bookmark[level=3,page=11,view={FitH \calc{\paperheight-\topmargin-2in} null}]{<Subsection3>}     \bookmark[level=3,page=13,view={FitH \calc{\paperheight-\topmargin-7in} null}]{<Subsection4>}      Unfortunately I could not use these bookmarks to create the ToC. To create the ToC I did the following               \tableofcontents     \clearpage\phantomsection     \addcontentsline{toc}{chapter}{<Chaptername N>}     \includepdf[pages=-,linktodoc=false]{<file N>.pdf}     \clearpage\phantomsection     \addcontentsline{toc}{chapter}{<Chaptername N+1>}     \includepdf[pages=-,linktodoc=false]{<file N+1>.pdf}      The issue I am facing now is that the contents of the ToC are being added (prepended) to the bookmarks data containing the the bookmarks I had manually added. **My question is: How can I keep the ToC contents from being added to the bookmarks?** More info: The ToC data comes before the bookmarks data (the bookmark commands refer to page numbers of the fully merged pdf file). The file structure is as follows:               <ToC data>     \bookmarksetup{startatroot}     \bookmarks ...        * I need to add the bookmarks because I cannot add the sections of each individual pdf file to the ToC (since I do not have the LaTeX sources)   * The reason I want a separate contents page at the very beginning is because some lightweight pdf readers (such as the google chrome's native pdf reader) do not utilize bookmarks) This is a continuation of the question I had previously asked at How do I use LaTeX to create table of contents (chapter headings, subsections etc) for a set of pdf files which I am merging into a single large pdf?


title: conflict between mathabx and other packages

text: I need to write the symbol of the earth, which is found in the package mathabx. When I compile my script I get the following error:               ! LaTeX Error: Command \iint already defined.                    Or name \end... illegal, see p.192 of the manual.          See the LaTeX manual or LaTeX Companion for explanation.     Type  H <return>  for immediate help.      ...                                                        l.505 ...d{\iint}{\DOTSI\protect\MultiIntegral{2}}.      It looks like a conflict between different packages. Here is a sample of my latex script, with the packages I am using:               \documentclass[11pt,a4paper]{article}          \usepackage[pdfencoding=auto,psdextra]{hyperref}          \usepackage{mathabx}          \usepackage{amsmath}               \begin{document}       \begin{equation}         U_{\Earth}       \end{equation}     \end{document}      I cannot understand what is wrong.


title: Option breaklinks doesn't actually break links pandoc

text: \usepackage[       breaklinks=true,       unicode=true,       urlcolor = blue,       colorlinks = true,       citecolor = blue,       linkcolor = blue]{hyperref}      From what I've read, that should work. The other options _do_ work. Nonetheless, the links do not break. Some of them walk clear off the page. I'm using pandoc to generate the PDFs/LaTeX. Is there anything obvious that I'm doing wrong?


title: How to correct excessive lines at the corner and bad line spaces in `polynom.sty`?

text: # Excessive lines at the corner ![alt text](http://i.stack.imgur.com/R7EUw.png) * * * # Bad line spacing ![alt text](http://i.stack.imgur.com/BZzwg.png) * * * # Minimal Code **History:** This code is done by @localghost at LaTeX community site. He made a modification from `)` to `|`.               \documentclass{article}     \usepackage{polynom}          \makeatletter     \def\pld@ArrangeResult#1{%         \ifx\pld@remainder\@empty             \@tempcnta\pld@maxcol\relax             \pld@InsertItems@do\pld@lastline                 {\pld@firsttrue\pld@PLD{\pld@R{0}{1}}}%         \fi         \ifnum\pld@currstage>\z@             \pld@Extend\pld@allines{\pld@lastline\cr}%         \else             \pld@InsertFake\pld@lastline         \fi         \pld@iftopresult             \def\pld@lastline{\pld@PrintPoly\pld@divisor\,\smash{\Big|}\kern-2pt&}%         \else             \let\pld@lastline\@empty             \ifx B\pld@style\else                 \def\pld@lastline{\pld@leftdelim\strut\pld@rightxdelim&}%             \fi         \fi         \expandafter\pld@AR@col\expandafter\pld@PLD                                \expandafter\pld@lastline#1+\relax+%         \pld@SplitQuotient         \pld@iftopresult             \let\pld@currentline\@empty             \expandafter\pld@AR@col\expandafter\pld@PLD                                    \expandafter\pld@currentline                                                \pld@quotient+\relax+%             \expandafter\pld@AR@col\expandafter\pld@XPLD                                    \expandafter\pld@currentline                                                \pld@shadow+\relax+%             \edef\pld@subline{%                 \noexpand\cline{\tw@-\pld@maxcol}%                 \noalign{\vskip\jot}}%             \pld@Extend\pld@currentline{\expandafter\cr\pld@subline}%         \else             \@tempcnta-\@tempcnta             \advance\@tempcnta\pld@maxcol\relax \advance\@tempcnta\@ne             \edef\pld@span{\the\@tempcnta}%             \ifx B\pld@style               \pld@AddTo\pld@lastline{%                 &\multispan\pld@span${}=%                 \pld@PrintPolyWithDelims\pld@divisor                 \expandafter\pld@IfSum\expandafter{\pld@divisor}{}{\cdot}%                 \expandafter\pld@IfSum\expandafter{\pld@quotient}\pld@true                                                                  \pld@false                 \pld@if \pld@leftdelim                         \pld@PrintPolyShadow                         \pld@rightdelim                   \else \pld@PrintPolyShadow \fi                 \pld@firstfalse                 \expandafter\pld@PrintRemain\expandafter{\pld@remainder}$}%             \else               \pld@AddTo\pld@lastline{%                 &\multispan\pld@span$\pld@leftxdelim\strut\pld@rightdelim                 \pld@div                 \pld@PrintPolyWithDelims\pld@divisor=                 \pld@PrintPolyShadow                 \ifx\pld@remainder\@empty\else                     +{}%                     \setbox\z@=\hbox{$\displaystyle                       \frac{\let\strut\@empty\pld@firsttrue \expandafter                             \pld@PrintRemain\expandafter{\pld@remainder}}%                            {\let\strut\@empty\pld@PrintPoly\pld@divisor}$}%                     \dp\z@=\z@\box\z@                 \fi                 $}%             \fi         \fi     \expandafter\pld@AR@\pld@allines\relax}     \makeatother     \begin{document}     \polylongdiv[style=A]{3x^9+x^2-1}{\frac{2}{5}x^4-1}     \end{document}      * * * # EDIT See my answer (based on @Herbert's info).


title: Can you put git revision information in a multifile document?

text: I have my PhD thesis under revision control (git), with a master file `(~/Thesis/thesis.tex)` using the `\include` command to include the chapters (`~/Thesis/tex/chapter1.tex`, etc). Is there a way to include the revision information of each separate chapter in the header of each page for each respective chapter? I thought I was getting somewhere with a combination of the `gitinfo` and `fancyhdr` packages, but I'm not sure if you can have different revision headers under gitinfo.


title: How to deal with conditions with many nested \and and \or?

text: This simple example will fail because of the priority rules are not taken into account :               \documentclass{article}     \usepackage{ifthen}          \begin{document}     \newcommand{\bibi}2     \newcommand{\toto}3     \ifthenelse{ {\toto=3\and\bibi=2} \or {\bibi=5\and\toto=1} }{Yes}{No}     \end{document}      It should produce "Yes" but it produces "No" because the last "\and" test is not met. So what is the best way to deal with this kind of tests, and the more complicated one witch causes me trouble, that is :               [(a and b) or (c and d)] and (e or f)      where a,...,f are booleans ?


title: Lettrine, accentuated characters and htlatex

text: I use accentuated letters with the `lettrine` package like:               \lettrine{É}{lisée} avait vu le pouvoir de Dieu sur la vie d'Élie.      With `luatex` (which is my normal rendering engine), it works fine. However, when I try to use TeX4HT to build HTML from it, I get:               ! Missing \endcsname inserted.     <to be read again>                         \protect      l.805 \lettrine{É}{lisée}                                 avait vu le pouvoir de Dieu sur la vie d'Élie.      I have already added these two lines when building with `htlatex`:               \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}      and I call `htlatex` with:               htlatex sagesse_lulu.tex 'xhtml,charset=utf-8' ' -cunihtf -utf8 -cvalidate'


title: How to avoid hyphenating a word on page break

text: > **Possible Duplicate:**   >  Suppressing hyphenation across pages I'm writing a paper and it is bad style to hyphenate over page break. Is there a way to tell LaTeX not to hyphenate if it is the last word on a page?


title: How to prevent page breaks inside words?

text: > **Possible Duplicate:**   >  Suppressing hyphenation across pages I would like to prevent page breaking from happening inside a word. In other words, hyphenation should not take place between pages. (This is what my publisher demands.) Is there a way to achieve this globally by setting some kind of penalties, or do I have to go through every page and remove the hyphens manually?


title: pgfplots: stacked plots using absolute values instead of relative

text: I would like to use absolute coordinates instead of relative values when using a ybar stacked plot. Is this possible? I know I can just reformat my data to be relative, but it sounds like pgfplots could do that job too. I assume my real problem is that what I seek is not 'stacked', but just 'overlay'. Does that exist? Here is an example from converting an area plot that uses absolute coordinates to a ybar stacked plot to show what I mean. ![area plot](http://i.stack.imgur.com/Br2o7.png)               \begin{figure}[h]\centering     \begin{tikzpicture}\begin{axis}[area style,xtick=data]     \addplot[red,fill=red] coordinates { (1,8) (2,8) (3,9) (4,10) } \closedcycle;     \addplot[green,fill=green] coordinates { (1,5) (2,7) (3,8) (4,9)  } \closedcycle;     \addplot[blue,fill=blue] coordinates { (1,3) (2,5) (3,7) (4,8)  } \closedcycle;     \end{axis}\end{tikzpicture}     \caption{Original area plot ordered back to front using absolute values that I want to convert to a stacked bar plot instead.}     \end{figure}      ![stacked relative](http://i.stack.imgur.com/Yp7Ij.png)               \begin{figure}[h]\centering     \begin{tikzpicture}\begin{axis}[ybar stacked,xtick=data]     \addplot[blue,fill=blue] coordinates { (1,3) (2,5) (3,7) (4,8) };     \addplot[green,fill=green] coordinates { (1,2) (2,2) (3,1) (4,1) };     \addplot[red,fill=red] coordinates { (1,3) (2,1) (3,1) (4,1) };     \end{axis}\end{tikzpicture}     \caption{Stacked using base values and relative values, ordered bottom to top. This is the output I desire, but I had to modify the data to be relative.}     \end{figure}      ![stacked_absolute](http://i.stack.imgur.com/f95Cw.png)               \begin{figure}[h]\centering     \begin{tikzpicture}\begin{axis}[ybar stacked,xtick=data]     \addplot[red,fill=red] coordinates { (1,8) (2,8) (3,9) (4,10) };     \addplot[green,fill=green] coordinates { (1,5) (2,7) (3,8) (4,9)  };     \addplot[blue,fill=blue] coordinates { (1,3) (2,5) (3,7) (4,8)  };     \end{axis}\end{tikzpicture}     \caption{Stacked using original absolute data, ordered back to front.}     \end{figure}      As a new user I can't make new keywords, but I wish they were: pgfplots, stacked, ybar, absolute, relative.


title: Controlling fontspec to use certain font features for different fonts in one document

text: I'm using the font _Fontin_ to prepare a document and have come across a problem when using the discretionary ligatures. The regular font supports the discretionary ligatures, but the bold and italic variants do not. When I turn the feature on, there will be blank spaces where a bold or italic discretionary ligature should be. How can I achieve that when using the regular font, discretionary ligatures are used, and when using one of the fonts that do not support them, they aren't used? I used the following command to turn on the features.               \fontspec[RawFeature={+liga, +dlig, +frac}]{Fontin}


title: endnotes with hyperref (resetting the counter) problem

text: Following with the discussion in Making endnotes clickable links with hyperref, I've the following issue. If I try to use this method to enable hyperlinks with endnote, everything works fine. But, if in my document I reset the endnote counter to zero at some point(s) (as I'd do if I had several chapters, for instance), when clicking the endnotes inserted after resetting the counter, they get referenced to the endnote list corresponding to the first bunch of endnotes. A MWE would be:               \documentclass[pdftex]{article}     \usepackage{endnotes}     \usepackage{hyperref}     \usepackage{hyperendnote}     \begin{document}     \noindent          FIRST ENDNOTE\endnote{blabla one}          \newpage A page between two notes. \newpage          \addtoendnotes{\newpage}% so both notes will be on separate pages for testing          \theendnotes          \setcounter{endnote}{0}          Another page with another endnote\endnote{blabla two}          \newpage blabla \newpage          \theendnotes          \end{document}      A related discussion can be found on comp.text.tex, but it seems that it was resolved for the `memoir` class, and using `pagenotes` (as supplied by the `memoir` class), not `endnotes`.


title: converting threeparttable tabular to threeparttablex and longtable

text: I am trying to convert an existing `threeparttable` to a `threeparttablex` table with `longtable` so I can break the table over multiple pages, but I'm having some trouble. Specifically, I'm getting an error about a misplaced \noalign related to `\toprule`. Any ideas where I am going wrong? Original:               \documentclass{article}          \usepackage{threeparttable}     \usepackage{booktabs}     \usepackage{dcolumn}     \usepackage{longtable}     \usepackage{threeparttablex}          \begin{document}          \begin{table}[H]     \centerline{\begin{threeparttable}       \caption{My caption}       \label{mytbl}       \centering       \begin{tabular}{lrrrrr}       \toprule           & \multicolumn{2}{c}{Grp 1} & \multicolumn{2}{c}{Grp 2} &  \\           & \multicolumn{2}{c}{(\textit{n}=500)} & \multicolumn{2}{c}{(\textit{n}=500)} &  \\           \cmidrule(lr){2-3} \cmidrule(lr){4-5}            Variable & \multicolumn{1}{r}{Mean} & \multicolumn{1}{r}{SD} & \multicolumn{1}{r}{Mean} & \multicolumn{1}{r}{SD} & p-value \\           \midrule       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       \bottomrule       \end{tabular}       \begin{tablenotes}       \small       \item My notes       \end{tablenotes}       \end{threeparttable}}     \end{table}          \end{document}      New:               \documentclass{article}          \usepackage{threeparttable}     \usepackage{booktabs}     \usepackage{dcolumn}     \usepackage{longtable}     \usepackage{threeparttablex}          \begin{document}          \begin{ThreePartTable}     \begin{longtable}{lrrrrr}       \caption{My caption}\\       \label{mytbl}       \toprule       & \multicolumn{2}{c}{Grp 1} & \multicolumn{2}{c}{Grp 2} &  \\       & \multicolumn{2}{c}{(\textit{n}=500)} & \multicolumn{2}{c}{(\textit{n}=500)} &  \\       \cmidrule(lr){2-3} \cmidrule(lr){4-5}        Variable & \multicolumn{1}{r}{Mean} & \multicolumn{1}{r}{SD} & \multicolumn{1}{r}{Mean} & \multicolumn{1}{r}{SD} & p-value \\       \midrule       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       Variable & 11.11 & 1.11 & 11.11 & 1.11 & 0.111 \\       \bottomrule       \end{longtable}       \begin{tablenotes}       \small       \item Note. My table notes here       \end{tablenotes}       \end{ThreePartTable}            \end{document}      Bonus: I'd like to add a `Continued on next page` message at the bottom of every page except the last, and a `Table X Continued` message on every page but the first.


title: how to set font feature file for a specific font file and not the whole font shape

text: I'm looking for having my document set with specific ligatures, such as 's' replaced by 'longs', 's t' by 'longs_t' etc. and using the Linux Libertine G font. To do this, I'm writing my text normally with 's' and I'm using a font feature file together with the fontspec package and compiling with Lualatex. This works properly. Here if the font feature file:               #font.fea     languagesystem DFLT dflt ;     languagesystem latn dflt ;          feature oplt {         @notf = [a b c d e g j k m n o p q r u v w x y z];         sub s' @notf by longs;         sub longs longs' by s; # words don't end with longs         sub f longs' by s;     # end with fs, not f_longs     } oplt;          feature oooo {         sub s s by longs_s;         sub s s by germandbls.alt;         sub s t by longs_t;         sub s h by longs_h;         sub s i by longs_i;         sub s l by longs_l;         sub s s i by longs_longs_i;     } oooo;      here is a piece of code compiled with Lualatex:               \documentclass{article}     \usepackage{fontspec}     \setmainfont[FeatureFile=font.fea, RawFeature=+oplt,RawFeature=+oooo]{Linux Libertine G Regular}     \begin{document}       ssi       \textit{ssi}     \end{document}      The issue I have is, this will fail. Lualatex ends with                !LuaTeX error (file C:/Windows/Fonts/linlibertineg_it.ttf): Invalid glyph index       (gid 2335)      My understanding is that the font feature file is applied to the whole font shapes (italic, bold, etc.), but the thing is some of the glyphs I put in the feature file are present in the regular file and not in the italic/bold shapes. That is the case for the longs_longs_i ligature, which is defined in the regular shape of Linux Libertine Graphite and not in the Italic shape. I didn't clearly find the way to use fontspec to set-up my feature file only for the regular shape and not for the other shapes. Is there any workaround, apart from embedding the features in the font file ?


title: Positioning of the chapter number in the margin note space

text: How can I fix the position of my chapter number? I would like to put it right in the middle of the space for the notes, and aligned with the first line of text of the chapter. I am undecided for the case where the chapter start with a section if align the chapter number with the title of the section or, again, with first line of the text. I would be sure that there are not modifications at the original positioning of the chapter title and of course of the vertical spacing of it, provided by tufte class. **My code below modify that position.** **Goals**   1. I would like to center the chapter number right in the middle of the space for the notes.   2. I would like to align the chapter number with the first line of text of the chapter.   3. I would be sure that there are not modifications at the original positioning of the chapter title and of course of the vertical spacing of it. You can see from the picture that my numbers are not aligned with the first line of text and also that they are not centered in the space for the notes. If you have some advices to find a better positioning of the chapter number, please, feel free to give me your tips. In fact my positioning is not based on calculations, but only on some visual approximations... I have also seen, that with the variation of the chapter number, the vertical space of the page change, I think that this happen because the different numbers have different measures. **Ideally, I would to put the chapter number as a margin note fixed at the first line of text.** ![enter image description here](http://i.stack.imgur.com/qIFtE.jpg)               \documentclass[a4paper,twoside,nofonts]{tufte-book}          \RequirePackage[%                    nomath,%                    nott,%     %              nosf,%                    noamsmath,%                    notextcomp,%                    oldstylenums%                    ]{kpfonts}               \usepackage{lipsum}          \usepackage[pdftex]{graphicx}          \setcounter{secnumdepth}{0}          \titleformat{\chapter}%       [display]% shape       {\relax\ifthenelse{\NOT\boolean{@tufte@symmetric}}{\begin{fullwidth}}{}}% format applied to label+text       {\itshape\vspace*{30pt}\color{black!10}\hfill\rlap{\resizebox{!}{5cm}{\thechapter}}\hspace*{150pt}}% label       {-200pt}% horizontal separation between label and title body       {\huge\rmfamily\itshape}% before the title body       [\ifthenelse{\NOT\boolean{@tufte@symmetric}}{\end{fullwidth}}{}]% after the title body               \geometry{showframe}          \begin{document}          \chapter{Implementation}          \lipsum          \chapter{Implementation}          \section{Valence Shell Electron Pair Repulsion theory}          \lipsum          \end{document}      ![enter image description here](http://i.stack.imgur.com/udHph.jpg)


title: how could we create this tree diagram?

text: How could we create the following tree diagram in a seperate page which has horizontal landscape? ![this](http://i.stack.imgur.com/nmP9J.png)


title: Undefined control sequence for equation

text: I am running into the error message `!Undefined control sequence` with the below explanation and can't figure out what I'm doing wrong. I am using Mactex and Texmaker. I am new to LaTeX and would really appreciate your help!               ! Undefined control sequence.     \beamer@doifinframe ...\par \begin {equation*} \x     (k) = \left ( \begin {arra...     l.123 \end{frame}     %     The control sequence at the end of the top line     of your error message was never \def'ed. If you have     misspelled it (e.g., `\hobx'), type `I' and the correct     spelling (e.g., `I\hbox'). Otherwise just continue,     and I'll forget about whatever was undefined.     ! Missing $ inserted.     <inserted text>     $     l.123 \end{frame}     %     I've inserted a begin-math/end-math symbol since I think     you left one out. Proceed, with fingers crossed.     ! Missing } inserted          -------      The code:                  \documentclass[notes=show,beamer,t,notheorems]{beamer}              \usepackage{amsfonts}         \usepackage{amsmath}         \usepackage{amssymb}         \usepackage{mathpazo}         \usepackage{hyperref}         \usepackage{subfigure}         \usepackage{tikz}              \setcounter{MaxMatrixCols}{10}              \newenvironment{stepenumerate}{\begin{enumerate}[<+->]}{\end{enumerate}}         \newenvironment{stepitemize}{\begin{itemize}[<+->]}{\end{itemize} }         \newenvironment{stepenumeratewithalert}{\begin{enumerate}[<+-| alert@+>]}{\end{enumerate}}         \newenvironment{stepitemizewithalert}{\begin{itemize}[<+-| alert@+>]}{\end{itemize} }         \newtheorem{assumption}{Assumption}         \newtheorem{proposition}{Proposition}         \usetheme{CambridgeUS}         \setbeamertemplate{navigation symbols}{}         \numberwithin{figure}{section}         \setbeamertemplate{navigation symbols}{}         \useoutertheme{umbcfootline}         \setfootline{ \hfill \insertframenumber}         \numberwithin{figure}{section}         \input{tcilatex}         \renewcommand{\QTR}[2]{\frametitle{#2}}              \begin{document}              \begin{equation*}         \x(k) = \left(             \begin{array}{c}                 x_1(k)\\                 x_2(k)\\                 \vdots\\             \end{array} \right)              \end{equation*}


title: Getting subcaptions into the list of figures without having a real subfigure

text: I gave searching my best shot, but no luck. Here's my problem: I use `\phantomsubcaption` from the `subcaption` package to do referencing, but I also want some sort of marker in the List of Figures with a short description of each panel. I've tried other command combinations from the `subcaption` package, but no luck so far. Does memoir have something built in to help me, or should I just give up? Here's the MWE               \documentclass{memoir}          \usepackage{float}     \usepackage[list=true]{subcaption}             \renewcommand\thesubfigure{\Alph{subfigure}} %just for aesthetics             \newcommand{\callsubfig}[1]{\textbf{(#1)}} % how I reference subfigs in my captions     \usepackage[style=base,labelfont=bf]{caption} % I bold my caption titles.               \begin{document}     \newdimen\LoFindent     \LoFindent = \parindent          \frontmatter          \tableofcontents*     \newpage     \listoffigures          \mainmatter     \chapter{Intro}     Intro to my topic. Here's a figure to clarify. (\fref{fig:introFig})          \begin{figure}[!b]     \centering         {\fbox{Figure graphics that have 2 panels in one PDF file.}         \phantomsubcaption\label{subfig:introFigA}         \phantomsubcaption\label{subfig:introFigB}}         \caption[Full Caption Title for ToC]{Caption title appears in text and is much longer than what appears in the LoF, which is good because this is long.             \callsubfig{\subref{subfig:introFigA}} Explaining the first part, then\ldots             \callsubfig{\subref{subfig:introFigB}} Explaining the second. But how do I get subcaption titles into the LoF?             }\label{fig:introFig}     \end{figure}          for an idea of what I want my LoF to look like, see \fref{fig:example}.               \begin{figure}[!b]     ToC Title for Fig 1.1 \dotfill \pageref{fig:introFig}          \hspace{\LoFindent} subtitle for subfig A          \hspace{\LoFindent} subtitle for subfig B               ToC Title for Fig 1.2 \dotfill \pageref{fig:example}          \caption{What I want my LoF to look like (content-wise, of course)}\label{fig:example}     \end{figure}          \end{document}