title: Prematurely ended file

text: I'm trying to read a large file (about 1.5M) with information to be processed, but it always ends prematurely with either `\input` or a loop with `\read`. The file is correctly balanced (believe me) and by removing parts of it the file ends at different points, even in the middle of a macro name (with the corresponding error of undefined macro), which, of course, is complete in the source. So the problem is TeX itself (TeX Live 2010). I presume there should be a parameter setting a limit, but after reading the documentation I could find nothing. The program has nothing special except a lot of `\pdfsavepos`. Is there a parameter in TeX Live to change the file size limit or is there a known bug? **More on the error** The code is:               \begingroup     \makeatletter     \@tempswatrue     \loop     \ifeof\ulp@in\@tempswafalse\fi     \if@tempswa       \read\ulp@in to\@tempa       \@tempa     \repeat     \endgroup      When the following part is read:               \ulp@Ga{24}\@ne {%     \ulp@Pa{1}{13349836}{12624364}{0}%     \ulp@Pa{2}{14554971}{12624364}{1}%     \ulp@Pa{3}{14739040}{12624364}{1}%     \ulp@Pa{4}{16705126}{12624364}{1}%     \ulp@Pa{5}{16889195}{12624364}{1}%     \ulp@Pa{6}{18218124}{12624364}{1}%     \ulp@Pa{7}{7030046}{11837932}{1}%     \ulp@Pa{8}{8943337}{11837932}{0}%     }%      the file is prematurely ended, as shown in the log file:               \@tempa ->\ulp@Ga {24}\@ne {\ulp@Pa {1}{13349836}{12624364}{0}\ulp@Pa {2}{14554971}{12624364}{1}\ulp@Pa {3}{14739040}{12624364}{1}\ulp@Pa {4}{16705126}{12624364}{1}\ulp@Pa {5}{16889195}{64}{1}\ulp@Pa {5}{16889195}{      Note `\read` has not read correctly the file, and the last argument of `\ulp@Ga` is incomplete (the last thing is `{`). Before this point, all `\ulp@Ga`s are read correctly (some of them are even longer).


title: algpseudocode without visible EndIf

text: I have the following chunk of code               \begin{algorithmic}     \State $\mathit{FlatMask}(c)=0$     \If{$\mathit{Inc1}(c)>0$}         \State $\mathit{FlatMask}(c)\;+\!\!=2(\mathit{Inc1}(c)-1)$     \EndIf     \end{algorithmic}      It displays using the `algpseudocode` package, but I would like that the final printed **End If** not be displayed, just the indentation to be reset. Any thoughts?


title: Displaying the definition of a macro

text: I have always wondered how certain macros are made and I usually use the `\show` command to get a glimps of its definition. Is it possible to print the definition of a macro with a command, say `\printmacro{\quad}`, which will in turn create a `.pdf` (or `.txt`) file with the definition and the location (the file) in which it is defined? Update: The following features would be great:   1. Create the `\printmacro` command with the option `[printhere]`. That is, it will emulate the behaviour of `\meaning`.   2. Create the options `printtopdf` or `printtotxt` file.   3. Note that all of these options should automatically indicate which file contains the definition of the command. If the exact location of the file which contains the command definition can be extracted, that would be great.


title: Tabulary on a rotated page does not use correct \textwidth

text: I'm trying to have a tabulary-table on a landscape page in a portrait document. Because I want to have the table use the full width, I tried to set it width to `\textwidth`, but the width of the table is only as wide as the textwidth is on a portrait page. How can I make the table using the correct width? Since I am using XeLaTeX the MWE contains Unicode-Characters! MWE:               \documentclass[a4paper]{scrartcl}     \usepackage{tabulary}     \usepackage{lscape}     \title{MWE – tabulary rotate}     \subtitle{Textwidth is way to small}     \author{John Doe}     \begin{document}     \maketitle     \begin{landscape}     \begin{table}     \begin{tabulary}{\textwidth}{RJL}     \emph{Left} & \emph{Middle} & \emph{Right} \\     This is a text that shall be a litte bit longer, and longer!     & And even this text is meant to be not so short that it is just simple short…     & Also there is the last column, which shall not be just a handfull of letters     but an full sentence instead, that doesn't not even to make sense!     \end{tabulary}     \end{table}     \end{landscape}     \end{document}


title: Citation alias with multibib and natbib

text: I need a bibliography that presents citation as (Surname, year), for which I am using `natbib`, and that allows two different bibliographies at the end of the document, for which I am using `multibib`. Point is: I'd like to use the "alias" command of natbib for the secondary bibliography, but it doesn't work. MWE:               \documentclass[a4paper]{article}          \usepackage{natbib}     \usepackage{multibib}          \newcites{sec}{Other bibliographic references}     \defcitealias{intlog}{International journal of logistics, issue 91}          \begin{document}          Something something something and then \citetalias{intlog}.          \bibliographystyle{plainnat}     \bibliography{bibliography}     \bibliographystyle{plainnat}     \bibliography{bibliography}          \end{document}      with a proper entry in the file `bibliography.bib`. How to make the command `citetalias{intlog}` work in the secondary bibliography? What do I know:   * `\citetaliassec{intlog}` doesn't work   * `\defcitetaliassec{intlog}` doesn't work as well (ok, that was a long shot) that makes me think the alias system is not compatible with multibib... Of course whatever other solution different from the alias system is absolutely welcomed.


title: Publishing to Arxiv using Biblatex-Biber

text: As I have read, one should transition to Biblatex-Biber. Many sites indicating that Biber is far superior to \bibitem's in a latex file or Biblatex backend=BibTex. Thus, I have begun the transition of trying to create better, more efficient, clearer bibliographies. As with 99% of LaTeX users, I really don't understand any of the technical details, I am simply a grateful user of LaTeX. Since making the transition to Biber, I have come across several problems. The most important of which is that I can't upload my document to the ArXiv.org, however the file compiles perfectly fine on my system. My endless hours of reading seems to indicate that ArXiv doesn't like to use my .bib file (it doesn't compile with biber, I think). So, instead I upload the .bbl file, however, the ArXiv doesn't know what to do with that either and produces:               Package biblatex Warning: File 'test.bbl' created by     wrong version.          (./test.bbl     ! Undefined control sequence.     l.21 \sortlist     {entry}{nty}     ?      ! Emergency stop.     l.21 \sortlist     {entry}{nty}     ! ==> Fatal error occurred, no output PDF file produced!      I have Biber 1.8. What Biber should I be using. ArXiv is using Live Tex 2011 I think. Many places online seem to indicate that I should go back to using \bibitem's or something similar to that. In general I am trying (the best that I can) to not change or edit my bibliography entries, but instead I want to learn how to properly use LaTeX to handle things instead of performing endless manual edits. My second issue is how to control the bibliography output. After reading for some time I wrote this for my bibliography code:               \usepackage[english]{babel}     \usepackage{csquotes}     \usepackage[style=numeric-comp,firstinits=true,backend=biber,%backref=true     ,]{biblatex}     \bibliography{test.bib}     \DeclareFieldFormat[article,book,incollection,phdthesis,misc]{volume}{\mkbibbold{#1}}     \DeclareFieldFormat[article]{publisher}{\textnormal{#1}}     \DeclareFieldFormat[article,book]{title}{\mkbibemph{#1}}      However, in a confusing fashion, if I use,               \DeclareFieldFormat[phdthesis]{title}{\mkbibemph{#1}}      nothing happens. Biber still defaults to ``quotes'' around my titles and doesn't italics them. An explanation of why this is happening would be nice.


title: How do I change the indentation of wrapped lines in enumeration items?

text: When I use the following document (which uses `\documentclass{article}`):               \documentclass{article}     \title{Sample Document}     \author{John Smith}     \begin{document}     \begin{enumerate}     \item This is a short line     \item This is a short line     \item This is a really really really really long line that wraps around the page and as you can see it goes to the left of the item number.     \item This is a short line     \item This is a short line     \end{enumerate}     \end{document}      I get the following: ![the result of an enumeration using the article document class; text is all left-aligned along the same vertical line](http://i.stack.imgur.com/ojKzQ.png) But when I create a similar document using this apa6 class:               \documentclass{apa6}     \title{Sample Document}     \author{John Smith}     \begin{document}     \begin{enumerate}     \item This is a short line     \item This is a short line     \item This is a really really really really long line that wraps around the page and as you can see it goes to the left of the item number.     \item This is a short line     \item This is a short line     \end{enumerate}     \end{document}      I get the following result: ![the result of an enumeration using the apa6 document class; wrapped text in an enumeration item is shifted to the left with respect to the first line](http://i.stack.imgur.com/M65ct.png) How can I use `\documentclass{apa6}`, and line up wrapped lines in enumerations similar to `\documentclass{article}`? And what code in `apa6` causes this to happen?


title: autocomplete in TeXnicCenter does not work when biblatex is used

text: I'm working with TeXnicCenter and I set a up a project file and created my output pdf file and bibliography using biblatex. Everything works well, the document looks the way it should...and now comes the but: I can't get the autocomplete for the \cite{} (any citation command actually) working. I don't even see the references in the reference tab (stable version TeXnicCenter) or in the Literature window (Alpha version). This is a bit annoying, since I have a huge list of references in my .bib file. Does anyone know, how to fix that? Maybe a note, I have just recently switched to biblatex and before I started using it, I could see the references and the autocomplete function was working. Here is a minimal example of my code:               \documentclass[12pt,a4paper,twoside]{report}       \usepackage{geometry}       \usepackage[latin1]{inputenc}         \usepackage[american]{babel}       \usepackage{filecontents}         \usepackage{csquotes}                  \usepackage[style=authoryear-comp,%       natbib=true,      % enable natbib macros       bibencoding=ascii,        url=false,       sorting=nyt,       uniquename=false,       firstinits=true, % use initials as first names       uniquelist=false,        dashed=false,     % do not use a dash instead of author name in case of several publications       maxnames=99,     % in the bibliography show all names        maxcitenames=2,   % in the text use et al. for more than 2        backref=true,     % have backrefs in the bibliography        backend=bibtex8,        refsegment=section]{biblatex}             \addbibresource{PhDall.bib}             \usepackage[T1]{fontenc}        \usepackage{fancyhdr}        \usepackage{setspace}        \usepackage[intoc]{nomencl}       \usepackage[colorlinks]{hyperref}       \usepackage[figure,table]{hypcap}            %-------Main-Document-Body---------            \begin{document}            \chapter{test}\label{testchapter}            lets see if this works: \parencite{albergel_evaluation_2012} and \parencite{maltese_event_2010}            \printbibliography            \end{document}         And the bibliography -which I get from zotero (coding Western - ISO8859-1) -looks like that:               @inproceedings{maltese_event_2010,           title = {Event detection of hydrological processes with passive L-band data from {SMOS}},           volume = {7824},            shorttitle = {Event detection of hydrological processes with passive L-band data from {SMOS}},           url = {http://dx.doi.org/10.1117/12.865074},           doi = {10.1117/12.865074},           booktitle = {{SPIE}},           publisher = {{SPIE}},           author = {Maltese, Antonio and Al Bitar, Ahmad and Jacquette, Elsa and Kerr, Yann and Mialon, Arnaud and Cabot, Francoise and Quesney, Arnaud and Merlin, Olivier and Richaume, Phillipe},           year = {2010},           pages = {78240J}       },          @article{albergel_evaluation_2012,       title = {Evaluation of remotely sensed and modelled soil moisture products using global ground-based in situ observations},           volume = {118},           shorttitle = {Evaluation of remotely sensed and modelled soil moisture products using global ground-based in situ observations},           url = {http://www.sciencedirect.com/science/article/pii/S0034425711004147},       doi = {10.1016/j.rse.2011.11.017},       journal = {Remote Sensing of Environment},       author = {Albergel, Clement and de Rosnay, Patricia and Gruhier, Claire and {Mu\~{n}oz-Sabater}, Joaquin and Hasenauer, Stefan and Isaksen, Lars and Kerr, Yann and Wagner, Wolfgang},       year = {2012},       pages = {215--226}       }      Any suggestions where I interfer with the autocomplete option?? Thanks


title: formatting section numbers with \hangsection in Memoir

text: I'd previously been renewing my section command in Memoir in order to style the section numbers by prefacing them with a symbol (§) and following them with a period:               \renewcommand{\thesection}{§ \arabic{section}.}      Werner has helpfully indicated in another post a way of putting the section numbers in the margin, getting rid of headings, and having the text body begin from the section numbers without any skip:               \hangsecnum     \counterwithout{section}{chapter}     \makeatletter     \newcommand{\hangsection}{%       \savebox{\@tempboxa}{\normalfont\ }%       \section{}\hspace*{-\wd\@tempboxa}%     }     \makeatother     \setaftersecskip{0pt}%      Could anyone indicate how to format the section numbers (e.g., with a symbol and a period) with such a new command? Many thanks.


title: \Needspace inside \multline

text: How to make `\Needspace` work inside `\multline`? `\displaybreak` would be ok, but it doesn't support arbitrary lengths. For example:               \documentclass{article}     \usepackage{amsmath}     \usepackage{needspace}          \begin{document}     \begin{multline}     a\\     b\\     c\\     d\\     %e\Needspace{10cm}\\   % this doesn't work     f\\     g\\     h\\     i     \end{multline}     \end{document}


title: Conflict between packages auto-pst-pdf and minted?

text: I have tried to create a document using the pdfLaTeX engine which includes graphics generated by PSTricks and resorts to the package `auto-pst-pdf`. Everything went right until I used the package minted; as soon as this was included, `auto-pst-pdf` could not create the `-autopp.dvi` file and the ensuing `-pics.pdf` file. Everything about the package `minted` seems to go right either with or without including `auto-pst-pdf`, so it seems to me that the latter has some conflict with the former. Anyone knows what is going on here? Thanks so much for your attention and assistance. I am appending an MWE right below as suggested by texlearner:               \documentclass[12pt]{memoir}          \usepackage{pstricks}     \usepackage{auto-pst-pdf}     %\usepackage{minted}          \pagestyle{empty}          \begin{document}          \begin{postscript}     \psset{fillstyle=solid}     \psscalebox{0.75}{%     \begin{pspicture}(-5.25,-5.25)(5.25,5.25)%       \pscircle*[linecolor=cyan]{5}       \psgrid[subgriddiv=0,gridcolor=lightgray,gridlabels=0pt]       \Huge\sffamily\bfseries       \rput(-4.5,4.5){A} \rput(4.5,4.5){B}       \rput(-4.5,-4.5){C}\rput(4.5,-4.5){D}       \rput(0,0){auto-pst-pdf}       \rmfamily       \rput(0,-3.8){PSTricks}       \rput(0,3.8){\LaTeX}     \end{pspicture}}     \end{postscript}          \end{document}      With WinEdt 6.0 and on MikTeX 2.9, as long as the inclusion of `minted` is commented, `pdflatex` with `-shell-escape` generates the corresponding one- page long PDF. As soon as `minted` is effectively included, no PDF is created. Herbert has provided an answer (to be found below) which solves the problem in what `minted` is concerned. Nonetheless, I have found a strange behavior when some PSTricks-based packages are included jointly with the base package `pstricks`. As an MWE let me suggest the following code:                   \documentclass[12pt]{memoir}              \usepackage{ifpdf}         \ifpdf            \usepackage{minted}            \usemintedstyle{friendly}            \newminted{latex}{linenos=true,mathescape}        \else            \usepackage{pstricks,pst-blur,pst-circ,pst-grad,pst-node,                         pst-gantt,pst-eucl,pst-3d,pst-solides3d,pst-lens,                         pst-coxeterp,pst-coxcoor,pst-rubans,pst-eps,                         pst-dbicons,pst-light3d,pst-tree,pst-sigsys,                         pst-text,pst-slpe}            \usepackage{pstricks-add,pst-optexp,pst-optic,pst-plot,pst-3dplot}        \fi              \usepackage{auto-pst-pdf}              \newcommand{\pstricksplot}{%                  \begin{postscript}                  \psset{fillstyle=solid}                  \psscalebox{0.75}{%                  \begin{pspicture}(-5.25,-5.25)(5.25,5.25)%                  \pscircle*[linecolor=cyan]{5}                  \psgrid[subgriddiv=0,gridcolor=lightgray,gridlabels=0pt]                  \Huge\sffamily\bfseries                  \rput(-4.5,4.5){A} \rput(4.5,4.5){B}                  \rput(-4.5,-4.5){C}\rput(4.5,-4.5){D}                  \rput(0,0){auto-pst-pdf}                  \rmfamily                  \rput(0,-3.8){PSTricks}                  \rput(0,3.8){\LaTeX}                  \end{pspicture}}                  \end{postscript}                  }             \pagestyle{empty}             \begin{document}             \pstricksplot             A few lines with minted:             \begin{latexcode}           \psplot[linecolor=#1,plotstyle=curve,                   linewidth=1.25\pslinewidth,linestyle=#2,                   plotpoints=10000]{#3}{#4}{1 div x #5\space mul #6\space add}           % Parameter 5 is the resonance frequency  $\omega_0=\frac{1}{\sqrt{LC}}\,\cdot$           % Parameter 6 is the time constant $\tau=RC\,.$        \end{latexcode}            The same PSTricks code as above the ``minted'' lines.            \pstricksplot            \end{document}         Now, the strange behavior is related to the inclusion of any of the packages `pstricks-add`, `pst-optexp`, `pst-optic`, `pst-plot`, `pst-3dplot`. I have included the PSTricks-based packages in two different bunches in order to emphasize this point: if I comment the corresponding line, everything goes fine; but if they are effectively included, the command `\pstricksplot` right above the end of the document does not lead to a graphic in the PDF. I use graphics intensively and PSTricks has proved most convenient for my needs, hence my including all those pst- packages. Thanks so much for your assistance and attention.


title: Expanding expl3 counter test at the right moment

text: I'm trying to get a counter to work, called `\l__ioiooiioio_args_second_int` in the example below, and I've declared to increment at each loop through `\int_incr:N \l__ioiooiioio_step_int`, but apparently the counter stays put at zero (can be seen by controlling `\int_compare:nT{\l__ioiooiioio_step_int = 0}{\hyperlink{doc.rc.#1}{$\rightarrow$}`, which apparently is only true for `\l__ioiooiioio_step_int=0`. Apparently this is _always_ the case. Why isn't the value of the counter increasing?               \documentclass{article}          \usepackage{xparse} \usepackage{longtable} \usepackage{multirow} \usepackage{hyperref}          \ExplSyntaxOn          \NewDocumentCommand{\mymacro}{ m m }        {          \ioiooiioio_setargs:nn { #1 } { #2 }          \ioiooiioio_print:n         }          \seq_new:N \l__ioiooiioio_first_col_seq      \seq_new:N \l__ioiooiioio_second_col_seq      \tl_new:N \l__ioiooiioio_table_body_tl      \int_new:N \l__ioiooiioio_step_int      \int_new:N \l__ioiooiioio_args_int          \cs_new_protected:Npn \ioiooiioio_setargs:nn #1 #2        {          \seq_set_split:Nnn \l__ioiooiioio_first_col_seq { , } { #1 }          \seq_set_split:Nnn \l__ioiooiioio_second_col_seq { , } { #2 }          \tl_clear:N \l__ioiooiioio_table_body_tl          \int_zero:N \l__ioiooiioio_step_int          \int_set:Nn \l__ioiooiioio_args_int { \seq_count:N \l__ioiooiioio_first_col_seq }       \seq_mapthread_function:NNN            \l__ioiooiioio_first_col_seq            \l__ioiooiioio_second_col_seq            \__ioiooiioio_fill_body:nn        }          \cs_new_protected:Npn \__ioiooiioio_fill_body:nn #1 #2        {       \int_incr:N \l__ioiooiioio_step_int          \tl_put_right:Nn \l__ioiooiioio_table_body_tl {  & #1 & #2 &        \int_compare:nT{\l__ioiooiioio_step_int = 0}{\hyperlink{doc.rc.#1}{$\rightarrow$}}       \\}        }          \cs_new_protected:Npn \ioiooiioio_print:n         {         \multirow{ \l__ioiooiioio_args_int}{*}{\seq_item:Nn \l__ioiooiioio_first_col_seq { 1 }}        \l__ioiooiioio_table_body_tl          }      \ExplSyntaxOff          \begin{document}          \begin{longtable}{cccc}      \mymacro{this is a test,this,is a,test}{now its,not a,test,anymore}      \end{longtable}          \end{document}


title: Wrong place for hyperref link in scaled tikz picture

text: I have a TikZ picture with a node containing a minipage with an itemize environment; each item is a hyperref to other sections of the document. When scaling the image (for example with `\begin{tikzpicture}[scale=.7, transform shape]` I've a strange behavior: links in itemize are not in the right place: they present a somewhat vertical offset, as if they don't scale as the rest of image. Here the MWE:               \documentclass[a4paper]{article}     \usepackage{tikz}     \usepackage[pdftex]{hyperref}     \begin{document}          Here something interesting\label{text:interesting-one}     \newpage          Here something interesting, too\label{text:interesting-two}     \newpage          and here there are very very interesting stuff\label{text:interesting-three}     \newpage          \newpage     Now the problem: links rectangles have some offset, making links unusable in case of long itemize          \begin{figure}[htb]     \begin{tikzpicture}[scale=.7, transform shape]     \node at (0,0) (mynode) {     \begin{minipage}{4cm}     \begin{itemize}     \item \hyperref[text:interesting-one]{First link}     \item \hyperref[text:interesting-two]{Second link}     \item \hyperref[text:interesting-three]{Third link}     \item \hyperref[text:interesting-one]{First link again}     \item \hyperref[text:interesting-two]{Second link again}     \item \hyperref[text:interesting-three]{Third link again}     \end{itemize}     \end{minipage}     };     \end{tikzpicture}     \end{figure}     \end{document}      And here a snapshot of the problem ![hyperref offset in scaled TikZ picture](http://i.stack.imgur.com/GhQKi.png) Note: This is evident using the default settings of `hyperref` package, which draws the red rectangle around links, but it took me some time to found it when only the text is coloured, i.e. when using `\usepackage[linkcolor=blue,colorlinks=true]{hyperref}`


title: How to wrap text in a table when there are no spaces at which to break the line?

text: I have a lot of text in table. I want to wrap it with in 2cm. In the last column, I have [1][2][3].....[89][100] but the column width is only 2 cm. It is supposed be wrapped by itself. ![enter image description here](http://i.stack.imgur.com/Amwxy.png) How can I implement that?


title: Same Header on different slides with beamer and longtable

text: When using the Longtable package in a LaTeX Beamerdocument, how can I create a table header shown on every slide containing table contents? The following approach seems not to work:               \begin{frame}[allowframebreaks]{title}     \begin{longtable}{cc}     a & b \\ \endfirsthead     c & d \\ \endhead     fooooooooooo & Bar\\      fooooooooooo & Bar\\      ...     \end{longtable}     \end{frame}      The headerline with "c d" is never shown. This behaviour doesn't seem right.


title: How to use autoplay (within animate package) together with a pause at the end of every playing?

text: I am trying to include the following animated gif: ![enter image description here](http://i.stack.imgur.com/7hiw5.gif) into beamer document and I am using `animate` package. When I follow this instructions: http://www.geogebratube.org/forum/viewtopic.php?f=20&t=25986 the resulting picture differs from the original in that way, that there is no stagnation in the movement at the end of one loop. The required stagnation is probably made by repeating one frame within some period. However when one decomposes the original gif according the instructions into frames, then there is no repeated frame (which causes the unwanted smooth motion in the end). What I am looking for is some way how to adjust autoplaying that will go from the first frame 0 to the last (let's say 22nd) and then, before it skips to the beginning again, it will repeat the last (the 22nd) frame for some while. Thank you for you advice.


title: How to align bottom edges of mdframes with bottom of text area

text: I've got a problem with the alignment of the bottom edges of "mdframes". These aren't aligned with the bottom of the text area, as in the following example:               \documentclass{scrartcl}          \usepackage{lipsum}     \usepackage{mdframed}          \definecolor{lightgray}{gray}{0.92}          \newmdenv[%       backgroundcolor=lightgray,       skipabove=\medskipamount,       skipbelow=\medskipamount,       splittopskip=\topskip,       splitbottomskip=6pt,       linewidth=1pt]%       {grayBox}          \begin{document}          \begin{grayBox}     \lipsum[1-6]     \begin{itemize}       \item a       \item b     \end{itemize}     \lipsum[1-6]     \end{grayBox}          \lipsum[1-2]          \begin{grayBox}     \lipsum[6]     \end{grayBox}          \lipsum[1-6]               \end{document}      The bottom edges on pages 1 and 2 are not aligned: ![bottom edges on pages 1 and 2](http://i.stack.imgur.com/53EoP.png) Moreover, the bottom edge of the last box on page 3 is not aligned with the bottom of the text area on page 4: ![bottom edges on pages 3 and 4](http://i.stack.imgur.com/Et1Vq.png) How can I achieve that in both cases the bottom edges of the "mdframes" are aligned with the bottom edge of the text area?


title: Numbering theorem-like environments

text: I would like all my theorem-like environments (theorem, example, etc.) to be numbered but such that the number appears _before_ the environment's name, more or less like this: **1. Theorem** **2. Example** How can I do this?


title: Change from "Theorem 10.1" to "10.1 Theorem"

text: > **Possible Duplicate:**   >  Numbering theorem-like environments">Numbering theorem-like environments How can I change the order in which theorems are displayed? I want 10.1 Theorem and not Theorem 10.1 Thanks.


title: Acronym hyperlink without special color

text: I use the `acronym` package for managing acronyms. I would like to show the acronym hyperlink without special colors or borders, just as plain text. Is there a way to do this?


title: Change from italics to normal text

text: In a new section instead of normal text i have italics, how to change it to normal text? I know that `\normaltext` works, but i want to change in the whole article.               \documentclass[12pt,a4paper]{article}      \usepackage{polski}      \usepackage[cp1250]{inputenc}      \usepackage[T1]{fontenc}      \usepackage[polish]{babel}      \usepackage{amsmath}      \usepackage{amsthm}      \usepackage{amsfonts}      \usepackage{bbm}      \begin{document}      \newtheorem{tw}{Twierdzenie}[section]      \newtheorem{df}{Definicja}[section]      \newtheorem{lm}{Lemat}[section]      \section{Wstęp}      \tw{Jakies twierdzenie}      bala      \section{Inna}      Balala      \end{document}


title: Varying style for chapter-references

text: I would like to refer to a chapter (roman numbering) partly with arabic numerals (e.g. as part of equation numbers) and partly with roman numerals (e.g. when refering directly to the chapter) ... I've tried sth like:               \newcommand{\chapref}[1]{\def\thechapter{\roman{chapter}}\ref{#1}}      (this changed the counter format globally) or               \newcommand{\chapref}[1]{\uppercase\expandafter{\romannumeral \ref{#1}}}      (in may case: compiled without warning but no effect..) but this didn't work out ... any ideas?


title: Use TikZ "circle connection bar" with non circular shapes

text: Is there any way to use the `circle connection bar` feature from the `mindmap` Tikz library with non circular node shapes? Here a non working Example: ![enter image description here](http://i.stack.imgur.com/sKhgq.png)               \documentclass[]{article}          \usepackage{tikz}     \usetikzlibrary{mindmap}     \usetikzlibrary{positioning}               \begin{document}              \begin{tikzpicture}             \node[circle, draw] (a) {a};             \node[rectangle, rounded corners, draw, above right=of a] (b) {b};                  \path (a) to[circle connection bar] (b);         \end{tikzpicture}          \end{document}


title: minionpro: v and \nu in math mode

text: I have noticed that with _Minion Pro_ font `v` and `\nu` are indistinguishable. Does anyone know a decent workaround to this? Somewhere in the web it was suggested to use `\upsilon` as a substitute for `v`. It's a bit irritating, however: You lose `\upsilon` and `w` and `v` will look too different.


title: makebst 'initial error'

text: I'm trying to make a customized bibliography style, and I have downloaded `makebst`. I open the `makebst.tex` file in my TeXMaker-editor, and press LaTeX (`F2`) to compile. But then I get this error:               ! Emergency stop.     <read 1>     l.214 Do you want a description of the usage? {NO}     ** *(cannot \read from terminal in nonstop modes)      And for you to know: 214 says:               \ask{\yn}{Do you want a description of the usage? (NO)}      I'm not sure what I am supposed to do?? Can anyone help me? As I read it, some kind of dialog box should appear?


title: Fixing Quotation Marks in Large Blocks of Text

text: I am writing a casebook with a law professor using TexShop, and a large portion of project are legal cases, all of which have "quotes" and not ``quotes'' I know the programming difficulties of auto-replacement, but anything is better than doing this manually for four hundred pages of material. I am not looking for a magic button, but what would be great is a workflow for converting quote marks before putting the cases into the latex document. I know this is an old problem, and I know a perfect solution is not feasible, but something quick and dirty that works with copy and pasting large blocks of text would make me a very happy person.


title: Configuring Memoir page and font size for the Kindle3

text: I'm trying to output a document sides for the Kindle3 and have a preamble that looks like so:               \documentclass[oneside,6pt,final]{memoir}                                           \usepackage{amssymb,amsmath}                                                             \pagestyle{empty}                                                                        \setstocksize{122mm}{91mm}                                                          \settrimmedsize{\stockheight}{\stockwidth}{*}                                       \settrims{0pt}{0pt}                                                                 \setlrmarginsandblock{0.5cm}{0.5cm}{*}                                              \setulmarginsandblock{0.5cm}{0.5cm}{*}                                              \checkandfixthelayout[fixed]       I have two problems. The first:               ! Class memoir Error: \headheight (12.0pt) and/or \headsep (18.06749pt) are  too large for \uppermargin (14.22636pt) by 15.84113pt.      Secondly, my font size directive is ignored: the default 10pt size is output. I do not rightly understand the first error and am rather surprised at the second. Would someone be so kind as to explain my mistakes?


title: hyperref causes a gap between the figure and subcaption with memoir

text: I'm experiencing a strange problem with `memoir` subfigure captions together with `hyperref`. Below is a working example:               \documentclass{memoir}          \usepackage{hyperref}     \newsubfloat{figure}          \begin{document}     \begin{figure}[tb]       \rule{\textwidth}{4ex}       \subcaption{}     \end{figure}     \end{document}      This produces the following result: ![enter image description here](http://i.stack.imgur.com/hGh7I.png) If I remove the `hyperref` package and recompile, the gap disappears: ![enter image description here](http://i.stack.imgur.com/BnlCl.png) Anyone have any idea why this is happening, and how to solve it?


title: LaTeX + Sketch: Workflow—Can It Be Simpler?

text: I am brand-new to LaTeX, Sketch, and even using the command line. My purpose is to write assignments as high-quality documents next semester for Physics, Math, Chemistry, and Engineering undergraduate-level courses. I am on break, so I figure it is a good time to learn. I recently downloaded Sketch to use with LaTex. You will find a simplified piece of working code at the bottom. By the way, I use Windows 8. * * * I am trying to create a document which includes code produced by Sketch. Below I will detail my workflow. **My question is: Is there a simpler way to do this???** From what I've seen, Sketch is very powerful, and 3D images are easier to write than when using PSTricks alone. I am willing to learn Sketch. However, if there is another software or package that is just as powerful as Sketch, but much simpler to use, that would be great. **(Would Inkscape be a good alternative?)** * * * My project file hierarchy is shown below. I making use of the `\input{...}` command to do this. Pay special attention to the image1 folder.   * project      * project.tex     * content        * chapter1.tex (I want to include the image here.)     * formatting        * packages.tex, etc.     * images        * image1          * sketch.exe         * Command Prompt (Set to open in this directory.)         * image1.sk         * image1_standalone.tex (Contains code for the image such that it can be compiled as a standalone PDF.)         * image1.tex (Contains the code for the image such that it can be included in the final document via `\input{}`.) AFAIK, every image folder, according to my current workflow, needs all these files. * * * Currently, my workflow goes like this:   1. Write Sketch code for my image in image1.sk and put `global {language tikz}` at the end.      * (AFAIK, not mentioned in the documentation in any clear place. Found the tip here. Without this command, the image was not compiling at all. This might be because without this command, Sketch produces PostScript code?     * Tangential rant: Documentation expects user knows what the Command Prompt is, how to use it, how to change directories, that the Sketch.exe needs (AFAIK) to be in the directory you are working in, etc. My computer knowledge is basic, and I wish the documentation gave this kind of information. It would have saved me a lot of time.   2. Open the Command Prompt and type:              Sketch -T image1.sk -o image1_standalone.tex     pdflatex image1_standalone.tex        3. Open the newly created image1_standalone.pdf file, and check whether I like how the image was produced.      * If I don't like the image, repeat above steps.   4. From image1_standalone.tex, copy the \usepackage{} and \usetikzlibrary{} commands into my packages.tex file.   5. Create image1.tex and paste the code `\begin{tikzpicture} ... \end{tikzpicture}`...possible surrounded by `\begin{center} ... \end{center}`.   6. Write `\include{./images/image1/image1.tex}` into the chapter1.tex file.   7. Compile final document. * * * Simple example code:                   \documentclass[pdftex,12pt,letterpaper]{report}              \usepackage[x11names,rgb]{xcolor}         \usepackage{tikz}         \usetikzlibrary{snakes}         \usetikzlibrary{arrows}         \usetikzlibrary{shapes}         \usetikzlibrary{backgrounds}         \usepackage{amsmath}              \usetikzlibrary{snakes}         \usetikzlibrary{arrows}         \usetikzlibrary{shapes}         \usetikzlibrary{backgrounds}                   \begin{document}         \begin{center}         \begin{tikzpicture}[line join=round]         \draw(-1,-1)--(.333,.333);         \filldraw[fill=white](0,0)--(1,0)--(0,1)--cycle;         \draw(.333,.333)--(2,2);         \end{tikzpicture}         \end{center}         \end{document}


title: detect previous character state

text: I am using the following tex-file:               \documentclass{book}          \begin{document}     foo\footnote{test.}\footnote{test2}     \end{document}      And the result is two adjacent superscript numbers: ![enter image description here](http://i.stack.imgur.com/NFWPC.png) I want to add a comma between the two numbers. Something in the line of               if (supercript number as the last char) print ,      Is there a general way to achieve that, not limited to the footnote example?


title: Line breaking words with apostrophe gets overflows

text: I'm using this Latex document class (that's the class used for the CHI/TEI conferences) and I'm facing a strange problem with automatic newlines with words having apostrophes: in Italian we are used to have words like _l'albero_ or _l'informazione_. Unfortunately, it looks like whenever Latex (pdflatex, most recent texlive) encounter one of those words, it's not able to line break within that word which then overflows the column space. ![enter image description here](http://i.stack.imgur.com/CIt3r.jpg) Example document showing such problem here. Any kind of help appreciated.


title: Using two different wallpapers in the same document

text: I have a 2-page document (letter) where I want to have a background image on both pages, but not the same image on both. It seems as though the wallpaper package can only work with one image. Is there a way to use two different images?


title: How to highlight math environments with colored background?

text: How to highlight maths environments (in-line mode excluded) with a coloured rectangular background e.g. grey? A `\textwidth` rectangular **behind** the `{equation}` environment.


title: Using the fancyhdr package, how do I have a footer but no header on the first page only

text: I would like to have a header and a footer throughout the document, however on the first page I would like no header with the footer remaining as it is throughout the document. So far all I can do is change the the first page style to plain, however this only gives the footer to be a page number, not the information I want. I believe I have included a minimum working example below, however it's most likely i've done something wrong as i'm quite new to this all. I'm also aware this may be marked as a duplicate question however my search has provided me no results with this issue specifically.               \usepackage{fancyhdr}     \begin{document}          \pagestyle{fancy}     \fancyhf{}     \renewcommand{\footrulewidth}{0.1mm}     \fancyfoot[R]{Assignment No.}     \fancyfoot[C]{\thepage}     \fancyfoot[L]{\today}     \fancyhead[L]{\leftmark}     \fancyhead[R]{Name:First Last}


title: How can I access the currently specified date in \rfoot?

text: I'm using `\date` to specify my document's date for `\maketitle`. I would like to use the same date in my footer. Currently I have to enter the date twice: once in `\date` and once in `\rfoot`. Is there a way I can enter the date a single time and have `\maketitle` and `\rfoot` both use the same date? Here's an excerpt from my original document:               \date{December 12, 2012}          \rfoot{December 12, 2012}          \begin{document}          \maketitle      I found a related question: How can I use @author, @date, and @title after maketitle? so I tried this:               \date{December 12, 2012} \let\Date\@date          \rfoot{\Date}          \begin{document}          \maketitle        But that gives me an error:               ./MyDoc.tex:45: LaTeX Error: Missing \begin{document}     .          See the LaTeX manual or LaTeX Companion for explanation.     Type  H <return>  for immediate help.      ...                                                        l.45 \date{December 12, 2012} \let\Date\@d                                               ate


title: Paragraph indent, both \indent and \par, not working

text: Preamble. I use Win 8 Pro x64, MiKTeX 2.9, TeXnicCenter latest version.               \documentclass[12pt,a4paper]{article}     \usepackage{graphicx}     \usepackage{polyglossia}     \usepackage{xltxtra}     \usepackage{xunicode}     \usepackage{units}     \usepackage{amsmath}     \usepackage{pstricks}     \usepackage{float}     \usepackage{wrapfig}     \usepackage[top=2.5cm, left=3cm, bottom=2.5cm, right=2.5cm]{geometry}     \usepackage{setspace}     \usepackage{pgfplots}     \usepackage[document]{ragged2e}     \usepackage[nottoc]{tocbibind}     \usepackage{titlesec}     \usepackage{indentfirst}     \setlength\parindent{24pt}     \titleformat{\section}[block]{\color{black}\Large\bfseries\filcenter}{}{1em}{}     \pgfplotsset{compat=1.8}     \usepgfplotslibrary{polar}     \usepgflibrary{shapes.geometric}     \usetikzlibrary{calc}     \onehalfspacing     \setmainfont{Times New Roman}     \setdefaultlanguage{latvian}     \setotherlanguages{english, russian}     \numberwithin{equation}{subsection}     \numberwithin{figure}{subsection}     \numberwithin{table}{subsection}     \pgfplotsset{pa/.append style={axis x line=bottom, axis y line=left, xlabel={$r; \cdot 10^7 m$}, ylabel={$F_{pa}; \cdot 10^8 N$}}}     \makeatletter     \renewcommand\@biblabel[1]{#1.}     \makeatother     \begin{document}      Piece working as needed:               \begin{center}     \noindent \large{\textsc{University \    Department\    Faculty}}          \topskip0pt     \vspace*{\fill}     \noindent \Large{name \    \textbf{Topic} \    Study}     \vspace*{\fill}     \end{center}     \begin{FlushRight}     \noindent \large{Work advisor: \    Professor } \end{FlushRight} \bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip\bigskip     \begin{center}     \noindent \large{\textsc{City, Year}}     \end{center}     \newpage     \tableofcontents     \newpage      Here I make `titlepage` according to the asked style. Then I go for my abstract. And there are no paragraph indents, but I need one at the first line (after `section`, and I tried to use both `\par` and `\indent` for two different paragraphs in that piece of text. Also, not a single intent working in anywhere further in document.               \section*{Abstract}     Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. \par     Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum     \\ \indent Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.     \newpage      It should have three indents, but has none. Looking through existing similar questions didn't bring me any sort of solution either. Also, I've put my build log on pastebin - http://pastebin.com/0EiP5BKw


title: setspace and quoting environment result in superfluous empty line

text: I was trying to set up the `quoting` environment by the package of the same name, which included single line spacing for block quotes as opposed to one and a half line spacing for normal text. The spacing seemed weird to me, so I boiled it down to the following MWE, which clearly shows off the extra line when applying `singlespacing` to `quoting`, even though nothing ought to happen because single line spacing is the standard.               \documentclass[12pt,twocolumn]{article}     \usepackage[a4paper,landscape]{geometry}     \usepackage{setspace}     \usepackage{quoting}     \usepackage{lipsum}     \begin{document}     \lipsum*[66]          \begin{quoting}     \lipsum*[66]     \end{quoting}          \lipsum*[66]          \newpage          \quotingsetup{font=singlespacing}          \lipsum*[66]          \begin{quoting}     \lipsum*[66]     \end{quoting}          \lipsum*[66]     \end{document}      Notes: The order in which `setspace` and `quoting` are loaded does not seem to matter. I also made sure `lipsum`'s paragraph breaks don't disturb us by using `\lipsum*`, which doesn't insert `\par`s. ![output](http://i.stack.imgur.com/A78v3.png) Is this expected behavior, can I patch it, is it a bug?


title: Can I make the index link to the correct part of the page?

text: I have managed to create an index where the page number links to the correct page. But I would like it to link to the correct part of the page, not to the top of the page. Is this possible? Here is the code I have so far (on GitHub with Makefile) and explicitly:               \documentclass[a5paper]{book}     \usepackage{makeidx}  % for automatically generation of an index     \usepackage{hyperref} % has to be after makeidx     \usepackage[margin=2.5cm]{geometry} % layout          \makeindex          \begin{document}     Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam      nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam      erat,      sed diam voluptua. At vero eos et accusam et justo duo dolores et ea      rebum. Stet \index{clita} clita kasd gubergren, no sea takimata sanctus      est Lorem      ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur      sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore      et dolore magna aliquyam erat, sed diam voluptua. At vero eos et      accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren,      no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum      dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod      tempor invidunt ut labore et dolore magna aliquyam erat, sed diam      voluptua. At vero eos et accusam et justo duo dolores et ea rebum.      Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum      dolor sit amet.             Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse      molestie consequat, vel illum dolore eu feugiat nulla facilisis at      vero eros et accumsan et iusto odio dignissim qui blandit praesent      luptatum zzril delenit augue duis dolore te feugait nulla facilisi.      Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam      nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat      volutpat.             Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam      nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam      erat,      sed diam voluptua. At vero eos et accusam et justo duo dolores et ea      rebum. Stet clita kasd gubergren, no sea takimata sanctus      est Lorem      ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur      sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore      et dolore magna aliquyam erat, sed diam voluptua. At vero eos et      accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren,      no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum      dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod      tempor invidunt ut labore et dolore magna aliquyam erat, sed diam      voluptua. At vero eos et accusam et justo duo dolores et ea rebum.      Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum      dolor sit amet.             Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse      molestie consequat, vel illum \index{dolore} dolore eu feugiat nulla facilisis at      vero eros et accumsan et iusto odio dignissim qui blandit praesent      luptatum zzril delenit augue duis dolore te feugait nulla facilisi.      Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam      nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat      volutpat.             Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam      nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam      erat,      sed diam voluptua. At vero eos et accusam et justo duo dolores et ea      rebum. Stet \index{clita} clita kasd gubergren, no sea takimata sanctus      est Lorem      ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur      sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore      et dolore magna aliquyam erat, sed diam voluptua. At vero eos et      accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren,      no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum      dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod      tempor invidunt ut labore et dolore magna aliquyam erat, sed diam      voluptua. At vero eos et accusam et justo duo dolores et ea rebum.      Stet clita \index{kasd} kasd gubergren, no sea takimata sanctus est Lorem ipsum      dolor sit amet.             Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse      molestie consequat, vel illum dolore eu feugiat nulla facilisis at      vero eros et accumsan et iusto odio dignissim qui blandit praesent      luptatum zzril delenit augue duis dolore te feugait nulla facilisi.      Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam      nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat      volutpat.             \printindex % print the automatically created index          \end{document}


title: How to make \animategraphics happy with a file name with spaces?

text: % this filename is main.tex     % compile it with "pdflatex -shell-escape main" (without the quotes)          \documentclass{article}          \usepackage{filecontents}          % Create a PDF file that consist of some pages     \begin{filecontents*}{"heart animation.tex"}     \documentclass[border=12pt,pstricks]{standalone}     \usepackage{pst-plot}     \usepackage[nomessages]{fp}     \FPeval\Delta{round(2*pi/30:2)}          \def\x(#1){sin(#1)^3}     \def\y(#1){(13*cos(t)-5*cos(2*t)-2*cos(3*t)-cos(4*t))/16}          \psset{algebraic,plotpoints=300}          \begin{document}     \multido{\n=0.00+\Delta}{31}{%     \begin{pspicture}[showgrid=false](-2,-2)(2,2)         \psparametricplot[origin={0,0.15},linecolor=red]{0}{\n}{\x(t)|\y(t)}     \end{pspicture}}          \end{document}     \end{filecontents*}          \immediate\write18{latex "heart animation.tex"}     \immediate\write18{dvips "heart animation.dvi"}     \immediate\write18{ps2pdf "heart animation.ps"}     % sometimes you need to disable auto rotate in ps2pdf. Please follow up if you really need it!     % delete auxiliary files generated by the 3 commands above.     \makeatletter     \@for\x:={tex,dvi,ps,log,aux,out,toc,nav,snm}\do{\immediate\write18{cmd /c if exist "heart animation.\x" del "heart animation.\x"}}     \makeatother          \usepackage{animate}     \begin{document}     %\animategraphics[controls,autoplay,loop,scale=<integer>]{<frame rate>}{<PDF filename without extension>}{<left blank>}{<left blank>}     \animategraphics[controls,autoplay,loop,scale=1]{10}{"heart animation"}{}{}     \end{document}      How to make `\animategraphics` happy with a file name with spaces?


title: How to use Times Roman (Nimbus Roman) with fontspec under Linux and LuaLaTeX

text: Times Roman under Linux is usually Nimbus Roman. If I use the `times` package, Nimbus Roman will be embedded successfully, as a Type 1 font. Now I want to use the `fontspec` package to load it. This a minimal example.               \documentclass{article}     \usepackage{fontspec}     \setmainfont{Times Roman}          \begin{document}     test     \end{document}      `fontspec` says it cannot find the font TimesRoman. I have also tried               \setmainfont{Nimbus Roman}     \setmainfont{Nimbus Roman No 9 L}     \setmainfont{NimbusRomNo9L}     \setmainfont{NimbusRomNo9L-Regu}      but none of them can load it successfully. Any hint will be greatly appreciated.


title: How to find out which glyphs are different in an OpenType style set?

text: With `fontspec`, and XeTeX or LuaTeX it's possible to access a font's OpenType features, including the Style Sets, e.g. like this:               \addfontfeatures{RawFeature=+ss01;+ss18}      TeX.sx has already taught me how to find out which features are available. Assuming I don't have proper documentation of my font at hand, is there **a way to find out which glyphs** (in which contexts) **will actually come out differently** when I use a certain style set (or another OpenType feature)? It also seems to depend on the script and font family (e.g. small caps). I feel like LuaTeX would be able to do this. A nice font with lots of features to test this is Junicode. For this specific case, however, all the features are neatly described in _Specimens and User's Guide_.


title: Displaying three graphics on one line

text: I am trying to display 3 graphics on one line (3 cycle graphs each with a caption underneath). How can I do this? Currently I have:               \begin{figure}[h]     \includegraphics[width =3cm]{c3.jpg}     \caption{$C_3$}     \end{figure}          \begin{figure}[h]     \includegraphics[width=3cm]{c4.jpg}     \caption{$C_4$}     \end{figure}          \begin{figure}[h]     \includegraphics[width=3cm]{c5.jpg}     \caption{$C_5$}     \end{figure}      The above displays my three graphs going down vertically on the side of the page with the captions centered (definitely not what I am trying to do). How can I get these three graphs on one line with their respective caption underneath them?


title: Space between footnote index and text

text: I think there is not enough space in a footnote between the index (the superscript 1, 2, etc.) and the text (inside `\footnote{...}`). How can I increase the space between the index and the text?


title: Widehat with right arrow

text: I am searching for a wide hat with a right arrow. So far I've found only the regular wide hat (`\widehat`, shown at the left of the image), or a curved right arrow (`\curvearrowright`). ![Wide had and wide hat with arrow](http://i.stack.imgur.com/e9svY.png) Is there a way to get something like what I have badly drawn at the right of the image?


title: How to bring beauty to this pgfplot?

text: We are making a plot as follows:               \documentclass{standalone}          \usepackage{pgfplots}     \usetikzlibrary{calc,shadings}     \usepackage{pgfplots}          \begin{document}         \begin{tikzpicture}             \def\xmin{0}             \def\xmax{10}             \def\ymin{0}             \def\ymax{7}             \draw[style=help lines, ystep=1, xstep=1] ;                  \draw (-.25,-.25) node[auto] {0};             \draw[->] (\xmin,\ymin) -- (\xmax,\ymin) node[right] {$x$};             \draw[->] (\xmin,\ymin) -- (\xmin,\ymax) node[above] {$f(x)$};                  \def\intersectX1{2}             \def\intersectY1{4/5+3}             \def\intersectX2{7}             \def\intersectY1{9/5+3}             \def\intersectX{4.76}             \def\intersectY{4.26}             \def\QPX{4}             \def\QPY{5}             \draw[color=red,smooth] plot [domain=0:8] (\x,{((\x-4)^2)/5+3)});                  \draw[dashed]  (2,0) node[below] {$x_1$} -- (2,3.8) node[up,left] {$f(x_1)$};             \draw[dashed]  (7,0) node[below] {$x_1$} -- (7,4.8) node[up,right] {$f(x_2)$};                  \draw[dashed,orange]  (4,0) node[below] {$\alpha\,x_1+(1-\alpha)x_2$} -- (4,3) node[below] {$f(\alpha\,x_1+(1-\alpha)x_2)$};             \draw[color=black,dashedd] (4,3) -- (4,4.2) node[up] {$\alpha f(x_1) + (1-\alpha)f(x_2)$};             \draw[color=blue] (2,3.8) -- (7,4.8);         \end{tikzpicture}     \end{document}      We want to achieve:   1. The labels `$f(x_1)$`, ... needs to be smaller but more clear -- by bringing more color in them.   2. Display that : `$\alpha f(x_1) + (1-\alpha)f(x_2) \ge f (\alpha x_1 + (1-\alpha) x_2)$`. Just the picture need to tell the story.   3. Any idea to beautify this plot is very welcome. ![Example](http://i.stack.imgur.com/GFunN.png)


title: Nice-looking tables with thick rules

text: I want to make a table with rules that are thicker than the default. It's pretty straightforward to do, however the result looks bad: the lines have gaps in them (see image below). There must be a way to make this look better.               \documentclass{article}     \setlength{\arrayrulewidth}{2pt}     \begin{document}       \begin{tabular}{|c|c|}         \hline         hello & world \cr         \hline         hello & world \cr         \hline       \end{tabular}     \end{document}      ![enter image description here](http://i.stack.imgur.com/A34E2.png)


title: xeCJK and paragraph indentation

text: I am using xelatex and want to use the xeCJK package, but without indenting the first paragraph of a section. I tried the setup directive below, which should do the trick. But it does not. The manual is in Chinese ...               \documentclass{article}               \usepackage{xeCJK}     \setCJKmainfont{SimSun}     \xeCJKsetup{indentfirst=false}               \begin{document}          \section{Section 1}          I want to have a paragrpah without indentation.          This one should be indented.          \subsection{Section 2}          Same here.          This one should be indented.               \end{document}


title: Why do I have so much free space on the left-hand side of my tikz diagram?

text: Inspired by http://tex.stackexchange.com/questions/3892/ I created my own snake like diagram (see below). The entries are rather large and the figure thus too wide. My question is: Why does the figure start only almost in the middle of the page and not on the left-hand side? _Why is there so much free space on the left?_               \documentclass{article}     \usepackage{graphicx}     \usepackage{tikz}     \usetikzlibrary{matrix,arrows}          \begin{document}     \begin{tikzpicture}[descr/.style={fill=white,inner sep=1.5pt}]             \matrix (m) [                 matrix of math nodes,                  row sep=1em,                  column sep=2em,             ]             { Q_{5}\oplus\bigoplus_{i\in\{1,2,3,4\}} Q_{12345\setminus i}[1] &             \bigoplus_{l\in\{1,2,3,4\}} Q_{l5}\oplus Q_{12345}[1] &             \bigoplus_{j\neq k\in\{1,2,3,4\}} Q_{jk5} \\               \ bigoplus_{i\in\{1,2,3,4\}} Q_{12345\setminus i} &             Q_{12345} &             S_{12345} \\             };             \path[->, font=\scriptsize,>=latex]             (m-1-1) edge (m-1-2)             (m-1-2) edge (m-1-3)             (m-1-3) edge[out=355,in=175] (m-2-1)         (m-2-1) edge (m-2-2)             (m-2-2) edge (m-2-3);     \end{tikzpicture}     \end{document}


title: Can I set Vim w/ vim-latexsuite to clean up aux files after compile?

text: I can't find the appropriate setting in gVim. Is there a way to manually edit my setting file to clean aux files after compile? Thanks!


title: Getting a random sublist from a given list

text: The `etoolbox` package provides macros to handle list, which can be useful to package/class writers, however it miss macros to get random sublists. So I want to define the following macros:               \getrandomsublist{<to store list macro>}{<sublist length>}{<list macro>}     \getrandomsublistcs{<to store list macro>}{<sublist length>}{<list name>}     \getcsrandomsublist{<to store list name>}{<sublist length>}{<list macro>}     \getcsrandomsublistcs{<to store list name>}{<sublist length>}{<list name>}      To start with, I have attempted the following:               \documentclass{article}          \usepackage{etoolbox}     \usepackage{pgfcore}     \usepackage{ifthen}     \usepackage{forloop}          %% this stores the length of a given list in the a counter, for later use     \newcounter{thelistlength}     \newcommand{\listlength}[1]{%         \setcounter{thelistlength}{0}%         \renewcommand{\do}{%             \stepcounter{thelistlength}%         }%         \dolistcsloop{#1}%     }          %% for test it with csv lists     \newcommand{\myinternallist}{}     \newcommand{\tomyinternallist}[1]{%         \forcsvlist{\listadd\myinternallist}{#1}%     }          %% \getrandomsublist{<sublist length>}{<list name>}     %% store the resulting sublist in a `\outputlist`     \newcommand{\outputlist}{}%     \newcommand{\getrandomsublist}[2]{%         \listlength{#2}%                              % calculate the length of the list          \newcommand{\randomindex}%                             \newcounter{innerct}%         \setcounter{innerct}{0}%         \renewcommand{\do}[1]{%             \stepcounter{innerct}%             \ifnum \randomindex=\value{innerct}%                 \listgadd{\outputlist}{##1}%             \fi%         }         \newcounter{ct}\forloop{ct}{0}{\value{ct}<#1}{%             \pgfmathrandominteger{\randomindex}{\value{thelistlength}}{1}%             \docslistloop{#2}%         }%         \outputlist     }          \begin{document}     \tomyinternallist{really,random,list,of,items}     \listlength{myinternallist}     \thethelistlength     \getrandomsublist{2}{myinternallist}     \renewcommand{\do}[1]{#1\qquad}     \dolistloop{\outputlist}     \end{document}      without success. How can we effectively define these macros?


title: Word count excluding certain environments

text: I would like a way to get a word count while ignoring certain environments. The reason for this is that I have quite a bit of pseudocode enclosed within multiple verbatim blocks. Ideally, a solution would be like this, but with the ability to select which environments to not select. edit: I am using TexStudio


title: biblatex-apa and hyperref: right parenthesis not part of link for \textcite

text: I use biblatex-apa citation style. I also use hyperref with colour links, rather than ugly coloured boxes. When I use `\textcite` the author name and year are both part of the link, but the right parenthesis is not. Like this: Jones (2000). Is there a way to fix this? I want either both or neither parenthesis linked... One way round this is to use `citestyle=authoryear` as an option. This means that only the year is linked, so it's not a perfect solution. Is there a better way to solve this problem?


title: Figures misplaced in recent version of MiKTeX

text: After a MiKTeX update, eps graphs were misplaced and appeared overlap with captions and text in pdf files. They worked perfect in earlier MiKTeX 2.9. Figures in dvi files worked fine as desired. System is Windows 7, tex files are edited and processed in Texmaker. Exactly the same question was posted earlier by someone else, but somehow removed without being answered. In an active post Why do eps images overlap the captions in subfigures? this problem was addressed in the answer of Heiko Oberdiek. My question: Is there solutions other than what is described below? If the following is the only or good solution, could anyone tell me what other files to modify so that they are consistent with the change in `dvipdfmx.cfg`? For example, what are "the conversion of PostScript files, e.g. (TeX Live)" and where are they located?


title: Test whether passed parameter is a number (possibly floating point) or dimension

text: With `TikZ` using the `calc` library you can write things along the lines of               \node (A) at ($(0,0)!0.75!(1,1)$) {};      or you can write something (rather different)               \node (B) at ($(0,0)!2in!(1,1)$) {};      What I would like to do is create a command that takes an argument which is either a scalar or a dimension. Naively I would like to do something like               \def\test#1{\ifdim#1\relax ... \else ... \fi}      Of course, that is completely wrong since `\ifdim` compares the values of two dimensions. So what I really would like is something more like               \def\test#1{\ifIsDimension#1\relax ... \else ... \fi}      Any suggestions how I go about this?


title: Having table on the same page as the heading?

text: I want to have a table under a subsection, but the place I write the table and its specifications in the source file seem not to matter. Can someone explain how to have a table at a desired position together with its vertical and horizontal position? Thanks Edit: The part of the code I mention is as follows:               \documentclass[12pt]{article}     \usepackage{a4, color}     \usepackage{amsmath, amsfonts, amssymb}     \usepackage{siunitx}     \begin{document}      \title{Understanding Semiconductor Lasers}     \author{Ongun Ar\i sev}     \date{Report: 15.10.2013\\ Experiment: 8.10.2013}     \maketitle     \subsection{Output characteristic of semiconductor laser diode}          \begin{table}[htbp]     \centering     \begin{minipage}[t]{.4\textwidth}     \begin{tabular}[t]{|c|c|}     \hline     I\,(\si{\milli\ampere})&P\,(\si{\micro\watt})\\     \hline     2.5&0.53\\     2.6&0.56\\          \hline     \end{tabular}     \end{minipage}     \begin{minipage}[t]{.4\textwidth}     \begin{tabular}[t]{|c|c|}     \hline     I\,(\si{\milli\ampere})&P\,(\si{\milli\watt})\\     \hline     11.0&12.63\\          \hline     \end{tabular}     \end{minipage}     \end{table}     \newpage     \subsection{Divergence angle of the beam measurement}     \begin{table}     \centering     \begin{minipage}[t]{.4\textwidth}     \begin{tabular}[t]{|c|c|}     \hline     I\,(\si{\milli\ampere})&P\,(\si{\micro\watt})\\     \hline          \hline     \end{tabular}     \end{minipage}     \end{document}


title: How to define vertical spacing around subcaptions

text: I want to increase the spacing between my (sub)figures and their respective captions. Unfortunately, all things tried (skip or margin options in e.g. \captionsetup, vspaces) didn't have any effect. What is the correct way to do so?               \documentclass{article}     \usepackage{subcaption}     \usepackage{floatrow}     %\floatsetup{      %  heightadjust=noobject,     %  valign=b     %}     \captionsetup{skip=-50pt}          \begin{document}          \begin{figure}[h!]     \ffigbox[\textwidth]{     \begin{subfloatrow}       \ffigbox[\FBwidth][\FBheight]         {\caption{a}}         {\rule{14cm}{7cm}}     \end{subfloatrow}     \begin{subfloatrow}       \ffigbox[\FBwidth][\FBheight]         {\caption{b}}         {\fbox{\rule{7cm}{4cm}\vspace{20pt}}}       \ffigbox[\FBwidth][\FBheight]         {\caption{c}}         {\rule{7cm}{4cm}}     \end{subfloatrow}     }{\caption{cap}}     \end{figure}          \end{document}


title: Latex Math Symbol

text: Could anyone tell me what is the command for this math symbol in LaTeX Math mode? ![Symbol](http://i.stack.imgur.com/rn5yg.jpg)


title: tabularx within the enumerate environment

text: does someone know how to set the width of the tabularx table to the width of the text inside `\item` in the enumerate environment? `\textwidth` doesn't account for the environment


title: Box with adaptive length

text: When I want to put formulas into boxes, I like the box to adapt to the length of my formula. For example, I don't want to put `$1+1=2$` in a very large box. To address this, I use the command `\encadrer` (it requires the `calc` package and the `ifthen` package) which is included in the preamble of the following minimal example :               \documentclass[10pt,a4paper]{article}     \usepackage{ifthen}     \usepackage{calc}          %\encadrer:     \newlength\lenbox     \newcommand{\encadrer}[1]{          \linethickness{2pt}     \setlength\lenbox{\widthof{#1}}     \begin{center}     \fbox{     \begin{minipage}{\lenbox}     #1     \end{minipage}     }     \end{center}      }               \begin{document}          \encadrer{$1+1+1=3$}          \end{document}      But this command doesn't work for multiple lines. For example, if I put               \encadrer{$1+1+1=3$ \\ and \\ $1+1=2$}      in the previous example, the box becomes larger. In this example, I would like the length of the box to be max(`\widthof{$1+1+1=3$}`, `\widthof{$1+1=2$}`). I thought of something : If the argument of `\encadrer` is of the form : `string1 \\\ string2 \\\ ... \\\ stringN`, I can use the `xstring` package to extract all the strings between `\\\` and use a loop to define something like that : (in pseudocode)               set lenbox to 0     for i from 1 to N       set lenbox to max(lenbox,\widthof{stringi})     end for      But it feels complicated and I wonder if there is another solution. If I on the right track, can someone help me convert this pseudocode to LaTeX code ? Thank you for your help !


title: Characters missing when embedding PDF with pdftex

text: I have the feeling this must have been asked before, but I couldn't find it with search... When I run the following test file               \documentclass{article}          \usepackage[T1]{fontenc}          % \pdfmapfile{+rotis.map}          % \renewcommand\rmdefault{rotissemisans}     % \renewcommand\seriesdefault{l}          \usepackage{graphicx}          \begin{document}          MF          foo bar          \bigskip          \noindent\fbox{\includegraphics{12462}}          \end{document}      through pdflatex with this PDF file http://www.quinscape.de/download/examples/12462.pdf then I receive the following, expected result: ![correct result](http://i.stack.imgur.com/dUUHC.png) But when I uncomment the three lines configuring Rotis Semi Sans Light as the document font, I unexpectedly get: ![enter image description here](http://i.stack.imgur.com/0qF9M.png) That is, a lot of characters are missing from the embedded PDF file. I can deduce this has something to do with the fact that the font embedded in the embedded PDF is the same as the document font, combined with font subsetting, but what exactly has gone wrong, and what are my options? Please excuse that I can't upload the complete font setup. The generated PDF is here: http://www.quinscape.de/download/examples/test.pdf (more precisely, an older version without the nice frame, but with the same error). Here's the relevant line from the map file:               pr3l8r  RotisSemiSans-Light " TeXBase1Encoding ReEncodeFont " <8r.enc <pr3l8a.pfb      Maybe some expert can analyse something or has seen this before? **Update** : When I add the line               \pdfinclusioncopyfonts 1      to the preamble, then I get ![enter image description here](http://i.stack.imgur.com/OoxAy.png) which looks Ok, though it does not really relate to what the documentation says this switch does :-) Here's the relevant part from the pdftex manual, but I can't comprehend the connection to the case at hand: > `\pdfinclusioncopyfonts` _(integer)_ > > If positive, this parameter forces pdfTeX to include fonts from a pdf file > loaded with `\pdfximage`, even if those fonts are available on disk. Bigger > files might be created, but included pdf files are sure to be embedded with > the adequate fonts; indeed, the fonts on disk might be different from the > embedded ones, and glyphs might be missing. My remaining problem now is that I am generating documents which can contain literally thousands of these embedded diagrams, and I fear that if all the embedded fonts are copied to the document PDF, it might get huge or otherwise too unwieldy for prepress tools...


title: How to add more columns to one row relative to other rows in a table?

text: I just simply add a row with more columns compared to other rows. I learned that there is `\multicolumn` command to span the columns but in my case if I use this command I need to repeat it so much time for the other rows. Is there any short cut for this. Another question, to take all this burden, do you know any table editor that works visually and end up a latex code?


title: Blank page changes headings and footers

text: I am trying to insert a blank page in a article class document, and I want it to have the same headers and footers as the rest of the document (which I have already set up using `fancyhdr`). However, when I insert the blank page, both its header and its footer change to what I assume is the default for this type of document (page number on the top left, section name on the top right, and nothing on the bottom), whereas the rest of the document has my customized headings (constant text on the top left and right and page number at the bottom). I have this code on the preamble:               \usepackage{fancyhdr}     \pagestyle{fancy}     \lhead{this is left}     \rhead{this is right}      And I am inserting the blank page using `\newpage`, as follows:               \newpage\null\thispagestyle{myheadings}\newpage      Thanks!!


title: Printing just the first 20 characters of a text, adding \ldots

text: Is it possible to truncate the name of a chapter to - let's say - 20 characters and adding `\ldots` to it? So that it fits into the space of the tabs shown here?


title: defernumbers causes wrong indentation

text: # Addendum 2: This has been fixed in the latest 3.0 dev version. Thank you, PLK! # Addendum: This question will probably be closed because it is to do with a development version of `biblatex` 3.0. For those interested, the issue can be found on the `biblatex` bug tracker here. * * * `biblatex`'s `defernumbers=true` causes the bibliography to be typeset with wrong indentation. # `defernumbers=false` ![defernumbers=false output](http://i.stack.imgur.com/3wB8F.png) # `defernumbers=true` ![defernumbers=true output](http://i.stack.imgur.com/9WiIl.png) Have a look at citation 1. It seems to that the spacing that should be reserved for the label is not passed on when `defernumbers` is enabled. # MWE:               \documentclass{article}          \usepackage{filecontents}     \begin{filecontents}{bibliography.bib}     @Article{gob,       title           = {I've Made a Huge Mistake},       author          = {Bluth, Gob},       journal         = {Journal of Magicians},       year            = {2003},       volume          = {1},       number          = {1},       pages           = {1--10},     }          @Article{michael,       title           = {Her?},       author          = {Bluth, Michael},       journal         = {Sudden Valley},       year            = {2003},       volume          = {1},       number          = {1},       pages           = {1--10},     }          @Article{tobias,       title           = {Never-nudism},       author          = {F{\"u}nke, Tobias},       journal         = {Blue Man Group},       year            = {2003},       volume          = {1},       number          = {1},       pages           = {1--10},     }     \end{filecontents}          \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage[british]{babel}     \usepackage{csquotes}     \usepackage[%       backend=biber,       defernumbers=true, % Should be enabled when using refsegments.       refsegment=section,       style=numeric,     ] {biblatex}     \addbibresource{bibliography.bib}          \begin{document}     \section{First section}     Check this out~\cite{gob}.     \printbibliography[heading=subbibliography,segment=1,]          \section{Second section}     Check this out~\cite{michael}.     \printbibliography[heading=subbibliography,segment=2,]          \nocite{tobias}     \printbibliography     \end{document}


title: How to set a background color of figure environment?

text: Currently I've this situation:               \newenvironment{inline}[2]{       \begin{figure}[h!]         \caption{#1}\label{#2}         \vspace{10pt}%     }{       \end{figure}     }      How can I set a background color to whole content, which is in the figure?


title: Should using spaces in math mode be a common thing?

text: Since I'm a beginner I want your opinion on a couple of things.               $$ A_4 = \left\{ f | f(x) > g(x) , x \in [0;1] \right\} $$      This is not a particularly interesting example, but would you use it? I guess it's alright, but doesn't `|` symbol look somewhat jammed to you?               $$ \forall f \in A_4 \exists r > 0 : B(f,r) \subset A_4 $$      Now here `\exists` symbol definitely looks jammed to me since there is pretty much no space between those two "sentences". Or it it normal in international papers? I know I can start using `\,` , `\:` , `\;` and similar stuff but this would make it much harder to stay perfectly consistent which is pretty much a point of using LaTeX for me.


title: Horizontal equivalent to \raisebox?

text: Is there a horizontal equivalent to `\raisebox`? I'd like to shift some content horizontally without altering the layout of surrounding content. **Edit:** I feel bad because my question wasn't precise enough. David Carlisle's answer is the best if you're looking for the true horizontal analogue to `\raisebox` (moves content horizontally instead of vertically, operates in vertical mode instead of LR mode). However, what I really want is something that works in LR mode.


title: big square parentheses with subscript

text: what I want to do is: ![enter image description here](http://i.stack.imgur.com/eGJ6Y.png) what I have done is:               \begin{align}     \tag*{(1)}  &  v_t(\mathrm{\textbf{K}})= \mathbb{E}\left[_{0\leq x_j\leq D_{jt},j     \in J} \max_{\mathbf x \in \mathcal J(\mathbf K)}\right]     \end{align}      **Output** ![enter image description here](http://i.stack.imgur.com/QZdMY.png) Anyone has any idea about how to code the first part, I guess I have troubles with the subscript of the square parenthesis, I will really appreciate any help. Thanks a lot


title: Top-aligned table cells with different font sizes and controlled spacing

text: I am trying to achieve a table where a few things have to work simultaneously. Several of these things have been discussed before, but I have been unable to make everything work at once (and some things at all). I want to be able to use different font sizes in cells on the same row, and have them _precisely_ aligned at the top. That has almost been achieved in the MWE below, but the letters of the smaller font are slightly below the letters of the larger font. (Previous discussion: Make different font sizes in a table align at top, not bottom, but the alignment is only close, not perfect.) **Edit** : The top alignment should be for the maximum height of the font used, so that an 'a' ends up at the same height whether it is written by itself or followed by a tall letter, such as an 'l' (or, if the small 'b' next to the big 'B' in the example below is changed for a small 'a', the 'a' should not jump up to the ceiling. I also want to be able to insert several rows of text with forced line breaks within a cell of the table, and those rows need to have the same spacing between them as normal text has. That has been achieved by nesting another table in a cell in the MWE below. In addition, I want to be able to use \hfill to put something out in the right margin from within the nested table, which works in the MWE. Further, the margins on the top, bottom and sides of the table should be zero, so that only the page margins determine the amount of white space around the table (as it is now, there is even a difference between the right and left margins -- although the margins were for some reason adjusted when I uploaded the pdf below, it is visible if you compile the code and look at the pdf directly). Lastly, I would like to get rid of all automatic spacing between cells, and then define my own spacing. Preferably, I would like to be able to define the vertical spacing between cells in terms of line heights (for lines of the size that I specify for normal text, so 11pt in the example below), while the units of horizontal spacing would preferably be defined in terms of "the width of an 'm'", or something like that.               \documentclass[paper=a4,fontsize=11pt]{scrartcl} % KOMA-article class     \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage[english]{babel} % English language/hyphenation     \usepackage{geometry}     \usepackage{tabu}     \usepackage{lipsum}          \pagestyle{empty} % No pagenumbers/headers/footers          \newcolumntype{V}{>{\vspace{0pt}}p}          \begin{document}     \begin{tabular} [t]{@{}V{0.2\columnwidth}V{0.8\columnwidth}} % @{} is used to remove the margins from cells     \Huge\textbf A & \begin{tabular}[t]{@{}p{0.8\columnwidth}}     Lorem ipsum \hfill right-aligned\\     sem.\\     Lorem\\     ipsum     \end{tabular} \\      \Huge\textbf B & b \\      \Huge\textbf C & \lipsum*[1] \\      \end{tabular}     \end{document}      ![enter image description here](http://i.stack.imgur.com/ff1PN.png) **Edit** 2013-03-25: I tried a different approach (with minipages) and asked a question: Make a list with uniform spacing regardless of the characters and number of text lines, possibly with minipages or a table. As of writing this, I have one answer that is similar to the accepted answer below. It achieves correct spacing, but is limited to different sizes in the left column (if one wants to use `\hfill` in the right column), and the top alignment for the `\Huge` text is not perfect. **Edit** 2013-03-25: I got an answer in the thread Make a list with uniform spacing regardless of the characters and number of text lines, possibly with minipages or a table where `\strut` was used to add space, and `\vphantom{Qp}` (adds the vertical space of what is written in the braces(Qp in this example)). That could most likely be used here to, to get the correct spacing between cells even if only short letters or letters that do not protrude downwards are used.


title: How can I use LaTex to mark my delta y and my delta x?

text: I know it is possible to use curly brackets (braces) in both vertical and horizontal orientation in Latex. Can I somehow use this to mark my change in y and my change in x on a Coordinate plane? Here's an image of what I am trying to accomplish. ![change in y over change in x](http://i.stack.imgur.com/rkQHg.png) This graphic is produced in Geogebra 4.2 and as you can see it's a very simple idea. But I had to use the pen tool to draw the curly bracket and I used Latex to typeset the delta y and delta x. Why not use Latex for both of these? Here's another image where I actually used Latex commands `\rbrace` and `\underbrace` to produce the brackets. ![second image](http://i.stack.imgur.com/Jtgdu.png) It worked out pretty good in this case. But had the slope of this line been bigger and I wanted to mark a larger distance the bracket would not be long (or high) enough. What I have done with these two is I have increased it's "size" to make it bigger. But this results in a much thicker lines. Can I control the width and length of the bracket by some argument? What is the syntax and what are the possible arguments for the `\underbrace` command? Is there any official resource page where I can look this up? Like a command catalog?


title: box instead of picture in sharelatex

text: \section{Software Architecture}     Hello     \begin{figure}[h]     \includegraphics{SystemOverview.pdf}     \end{figure}     Hallo      results in: ![enter image description here](http://i.stack.imgur.com/awQGW.png) I'm using packages               \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage[english]{babel}     \usepackage{amsmath}     \usepackage{ae}     \usepackage{icomma}     \usepackage{units}     \usepackage{color}     \usepackage{graphicx}     \usepackage{epstopdf}     \usepackage{subfigure}     \usepackage{bbm}     \usepackage{caption}     \usepackage[square, numbers, sort]{natbib}     \usepackage{multirow}     \usepackage{array}     \usepackage{geometry}     \usepackage{fancyhdr}     \usepackage{fncychap}     \usepackage[hyphens]{url}     \usepackage[breaklinks,pdfpagelabels=false]{hyperref}     \usepackage{lettrine}     \usepackage{eso-pic}      and document class               \documentclass[11pt,a4paper]{report}      How can i fix it?


title: renewcommand chapter

text: Just a short question: I want to renew the chapter command, so that I can manipulate the distance between the chapter number and the chapter title in my header, currently I have defined my header as:               \renewcommand{\chaptername}{}     \fancyhead[L]{\hspace{4mm}\textcolor{headercolor}{\leftmark}\\ \text{ }\textcolor{headercolor}{\hspace{0.4cm}\rightmark}\hfill\textcolor{headercolor}{}\hspace{2mm}}     \renewcommand{\headrule}{\vspace{-\headheight}\textcolor{headercolor}{\vrule height \headheight width 2pt\relax\rule{\textwidth}{2pt}\vrule height \headheight width 2pt\relax}}      now I want to change the chaptermark/chaptername, so that I can manipulate the distance between the number and the title. E.g. currently it says 1. INTRODUCTION but I want the space between 1. and INTRODUCTION to increase? I know this is not a working example, but I hope you get it fast what I mean.


title: How to get abstracts of referenced works as mouseover texts in the generated pdf?

text: For a BibTeX entry, there is a field called `abstract` into which the abstract of a work can be entered. Including the abstract as plain text in the compiled document for every reference in the BibTeX file that has an abstract will take up a lot of extra space in the final report, which can often be quite unpractical. Another way (which would not occupy any space in the report) would be to include each abstract as a mouseover text in the generated pdf (if compiled to a pdf, of course), to be displayed when for example the reader hoovered the mouse over the title of the reference that had that abstract. Is it possible to achieve this?


title: Remove left and right indentation of abstract

text: Trying to remove the indentation which is appearing around my abstract for some unknown reason. A MWE is below:               \documentclass[a4paper,oneside,10pt]{article}     \usepackage[english]{babel} % formatting rules for the English language     \usepackage[T1]{fontenc} % proper formatting for accented characters and non-standard characters such as pipelines     \usepackage{mathptmx}% fot a font which looks like Times New Roman (serif/roman)     %\usepackage{tgtermes}% an altternative     \usepackage[scaled=.90]{helvet}% for a font which looks like Helvetica, scaled to match TNR (sans)     %\usepackage{tgheros}% an altternative     \usepackage{courier}% for a font which looks like Courier (typewriter/monospaced)     %\usepackage{tgcursor}% an altternative     \usepackage[top=15mm, bottom=15mm, left=30mm, right=30mm]{geometry} % page layout     \setlength{\parindent}{0mm} % Do not indent the 1st line of a paragraph.     \setlength{\parskip}{3mm}   % Add space between paragraphs.               %% redefine \footnoterule for using the whole text width     \renewcommand\footnoterule{%       \kern-3\p@\hrule\@width\columnwidth\kern 2.6\p@     }          \begin{document}          \renewcommand*\abstractname{\flushleft\textbf{ABSTRACT}\hfill}     \begin{abstract}     \noindent This is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstractThis is my abstract     \end{abstract}          Some other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuffSome other stuff     \end{document}


title: Compile warning regarding fonts

text: A MWE of my code is this:               \documentclass[12pt]{article}     \usepackage[top=0.7in, bottom=1.2in, left=0.8in, right=0.8in]{geometry}          \setlength{\parindent}{0cm}          \usepackage{xltxtra}     \usepackage{xgreek}     \setmainfont[Mapping=tex-text]{GFSArtemisia.otf}     \setsansfont[Mapping=tex-text]{GFSArtemisia.otf}          \usepackage[fleqn]{amsmath}     \usepackage{unicode-math}          \begin{document}          Text goes here!          \end{document}      When I compile it I get the following warnings: Font shape `EU1/GFSArtemisia.otf(0)/bx/n' undefined(Font) using`EU1/GFSArtemisia.otf(0)/m/n' instead Some font shapes were not available, defaults substituted. What is the problem and how can I fix it?


title: Curved cylinders in Tikz

text: I would like to draw this figure here using tikz. However I do not know how to draw curved cylinders in Tikz. ![enter image description here](http://i.stack.imgur.com/KfJZa.png) Can someone give a hint with it? Thanks


title: How to use `ybar interval` without skipping the last value

text: I have the following code               \documentclass[tikz]{standalone}     \usepackage{pgfplots}     \usepackage{pgfplotstable}     \usepackage{filecontents}          \begin{filecontents}{testdata.dat}       -3.316988309367815e-07 0.07000000000000001       -1.948815911147526e-08 0.13       7.15864175355987e-08 0       1.799432483450127e-07 0       0.0002850606647384129 0       0.0009429559686380238 0.08999999999999997       0.00157188462064142 0       0.005259918700865051 0       0.01739392641273605 0.18       0.06208364670743995 0.55       68.69485148165926 6.970000000000001       31.217611224923 79.12       0 12.89     \end{filecontents}          \pgfplotsset{compat=newest}     \pgfplotstableread{testdata.dat}\datatable          \begin{document}     \begin{tikzpicture}     \begin{axis}[       ybar interval,       width=10cm,       height=5cm,       enlargelimits=false,        xtick=data,       ymin=0, ymax=100,       xticklabels={0 -- 0.063,0.063 -- 0.125,0.125 -- 0.25,0.25 -- 0.5,0.5 -- 1,                    1 -- 2,2 -- 4,4 -- 5.6,5.6 -- 8,                    8 -- 11.2,11.2 -- 16,16 -- 22.4,22.4 -- 31.5},       x tick label style={rotate=60,anchor=east}       ]       \addplot table[x expr=\coordindex,y=0]{\datatable};       \addplot table[x expr=\coordindex,y=1]{\datatable};      \end{axis}     \end{tikzpicture}     \end{document}      and the output looks like this: ![enter image description here](http://i.stack.imgur.com/VuUqs.png) But the command `ybar interval` does skip the last value. It should look like: ![enter image description here](http://i.stack.imgur.com/Ij6D8.png) I prefer to have the last value to show up in the interval `22.4 -- 31.5`. How do I achieve this without inserting a row of zeros to my table?


title: Too much transparancy in pgfplots

text: I try to embed pngs including transparancy into pgfplots. The problem is, that the transparancy is only around the main object of the png. However, as demonstrated by the MWE, it seems also to affect the entire PNG. How can I have the red dot in the attached image cover the dots behind it?               \documentclass[tikz]{standalone}     \usepackage{pgfplots}     \pgfplotsset{compat=newest}     \usepackage{amsmath}     \begin{document}     \begin{tikzpicture}          \begin{axis}[%     width=6cm,     axis equal image,     scale only axis,     xmin=0.5,xmax=100.5,%     ymin=0.5,     ymax=100.5     ]          \addplot[color=blue,     only marks,     mark size=0.4pt,     mark=*,     mark options={solid}]     table[row sep=crcr] {     10 10\\     50 50\\     };               \addplot[] graphics[xmin=0.5,xmax=100.5,%     ymin=0.5,     ymax=100.5     ]{transparancyinpgfplots.png};          \end{axis}     \end{tikzpicture}%     \end{document}      ![Including Image](http://i.stack.imgur.com/1fLpF.png)


title: How can we swap columns in two-column regime preserving hyperlinks?

text: > Please save your time and energy on this question, some solutions exist. I have been helping with Arabic-English (right-to-left typesetting) and English-Arabic (left-to-right typesetting) indices typesetted in one document, see more in Switch twocolumn between right-to-left and left-to-right with the package multiind in polyglossia. How to rearrange columns to have the first column on right side and the second column on left side in two-column regime preserving clickable cross-references and index page numbers? I enclose a basic scheme, it runs on all major `latex` engines.               % run: *latex mal-cols.tex     \documentclass[a4paper]{article}     \parindent=0pt     \newcount\maltemp     \usepackage{multicol}     \usepackage{kantlipsum}     \def\textbonus{{\normalsize\kant[1-5]}}     \begin{document}     \columnseprule=3pt     \Huge\bfseries% For better reading...     Regular page in one-column regime...     \newpage     \begin{multicols}{2}     \textbonus     \loop     \advance\maltemp by 1     \the\maltemp\par     \ifnum\maltemp<130\repeat     \end{multicols}     \end{document}      ![mwe](http://i.stack.imgur.com/AgU5p.png)


title: How to create luatex.fmt

text: I wanted to try the latest version of LuaTeX, so I downloaded the official precompiled binaries. But these raw binaries are useless without a luatex.fmt. How can this file be created?


title: csquotes: Using Auto Quotes to Create Block Quotes if Required

text: One of the great features of `csquotes` is that, using `\MakeAutoQuote`, we can simply type proper hard-coded quotation marks and have `csquotes` do the rest, i.e. turn them into the correct format (as defined by language, typography etc.), plus take care of nesting:               \documentclass{article}     \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage{lmodern}     \usepackage[english]{babel}     \usepackage[babel]{csquotes}     \usepackage{lipsum}          \MakeAutoQuote{»}{«}     \MakeAutoQuote*{›}{‹}          \begin{document}     \lipsum*[1]     »\lipsum*[2] »[...]««     \lipsum*[3]     \blockquote{\lipsum*[2] »[...]«}     \end{document}      In my documents, I use `»` + `«` and `›` + `‹` exclusively (placed on an easy- to-reach position on my keyboard), no matter what language I'm writing in, no matter what the quotation marks are required to look like in print. `Csquotes` will treat them as `\enquote`s. That's perfect ...unless we're talking about a longer quote which we'd like to automatically be turned into block format. What I'd like to have is an even smarter autoquote that behaves like `\blockquote` rather than `\enquote`, i.e. that will switch to block format if the anticipated length hits a certain threshold. That way, I could uniformly use `»` and `«` throughout my document without having to manually consider the quote's length. Unfortunately, `\MakeAutoQuote` seems to be linked to `\enquote` rather tightly (§4.1 of csquotes doc). What would be a way of changing that, and are there any pitfalls that I'm not aware of at the moment? ## FOLLOW-UP prompted by @cfr's and Ulrike's replies, I came up with (the idea of) what some might consider a somewhat dirty workaround. If we can use `\mkblockquote` to define the block quotes' precise format, why not change the function of our active blockquoting chars (e.g. `»` and `«`) _after the beginning_ of each instance of a block quote -- to become active textquoting chars inside the block quote? And give them back their block quote function at the very end?               \documentclass{article}     \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage{lmodern}     \usepackage[english]{babel}     \usepackage[babel]{csquotes}     \usepackage{lipsum}          % define » and « to trigger a block quote     \MakeBlockQuote{»}{|}{«}          \renewcommand{\mkblockquote}[4]{%     % inside a block quote, make them trigger a text quote     \MakeAutoQuote{»}{«}%     #1#2#3#4%     % now they resume functioning as block quote triggers again     \MakeBlockQuote{»}{|}{«}     }%          \begin{document}     \lipsum*[1]     »\lipsum*[2]«     »\lipsum*[2] »[...]««     \lipsum*[3]          \end{document}      Apparently, this is not how it works. I had hoped `\MakeBlockQuote` would work like, say, `\renewcommand`, but `csquotes` doesn't seem to accept a re- definition of the active blockquote chars. Even this construction causes an »invalid argument error«:               \MakeBlockQuote{»}{|}{«}     \MakeBlockQuote{>}{|}{<}      It's as if, once defined, the block quotes are inseperably tied to those chars. Or is there a way we can make this work somehow?


title: pgfplotstable: Two columns into one with numeric data, but can't round

text: **Question:** Relates to the question posed here. I have made one column from two, but I would like to round the numbers off from a precision of 4 to 2. How do I do that? Here is the MWE:               \documentclass{standalone}     \usepackage{pgfplotstable}     \begin{document}     \pgfplotstableread[row sep=\\,col sep=&,header=true]{     var & mean & sd \\     x & 95.265 & 11.4801 \\     y & 85.7 & 18.95 \\     z & 15 & 5.01 \\     }\means          \pgfplotstabletypeset[       columns/var/.style={string type},       columns/mean/.style={fixed zerofill,precision=2},       columns/sd/.style={fixed zerofill,precision=2},       columns/mixed/.style={string type,column type=l,column name={Mean (SD)}},       columns={var, mixed},       create on use/mixed/.style={         create col/assign/.code={%           \edef\entry{\thisrow{mean} (\thisrow{sd})}%           \pgfkeyslet{/pgfplots/table/create col/next content}\entry         }       }     ]\means\     \end{document}      The column "Mean (SD)" in the output is in the raw data format, even though I had specified the precision in the columns of "mean" and "sd". How do I get it to round off appropriately with zerofill?