title: How to customize the bibliography?

text: I have the following minimal example which is texed with pdfLaTeX.               \documentclass{article}          \begin{document}          The reference is \cite{test1}.          \begin{thebibliography}{999}     \bibitem{test1} text1     \end{thebibliography}          \end{document}      Now I want to show "text1" instead of "1" in the pdf. How can I achieve this? Furthermore, I would like to have no numbering ("1,..") in the Bibliography chapter of the pdf. Are there any commands? ![enter image description here](http://i.stack.imgur.com/Jzpfn.png)


title: Dummy's solution for using of accent from one TTF glyph in another

text: I am making a document with the Josefin Sans font in LaTeX (using XeLaTeX). However, a pair of symbols I need (Žž) is missing there; I get just an empty space in PDF. I have no idea at all about fonts, but decided to try it anyway since I really need it. I took the Type light 3.2 font editor, found the missing glyphs (017D and 017E), copy-and-pasted there the corresponding Z and z glyphs, and added the vertically flipped circumflexes from other glyphs. In OpenOffice Writer, the trick works. (Character spacing is screwed up, but I can live with it: I need these symbols just a couple of times in my document, so I can manually shift them in TeX.) However in TeX the symbol is still not typeset---I receive empty space. I believe what I am doing is not the right way to go, but I really need it. Could anyone explain why XeLaTeX does not typeset the new symbol and if there is a better solution please? My tex-code:               \documentclass{article}     \usepackage{fontspec}     \setsansfont{Josefin Sans}     \begin{document}     Žž{\textsf{ZzŽžZz}     \end{document}      The font files are available here.


title: XeTeX crashing when including PDF files with \includegraphics

text: I've only used XeTeX a little so far for Greek text and it's the first time I am trying to include figures. `\includegraphics` works fine with `PNG` images but when I try `PDF` files, it just crashes. Here's a minimal sample:               \documentclass{article}     \usepackage{graphicx}          \begin{document}          Text.          \includegraphics[width=\textwidth]{fig.pdf}          \end{document}      The same sample works with `fig.png` instead of `fig.pdf`. It also works perfectly for both file types with PDFTeX. I am using the following XeTeX version:               This is XeTeX, Version 3.1415926-2.2-0.9995.2 (TeX Live 2009/Debian)      on Ubuntu 12.04 (with package `texlive-full` installed). Any idea what may be wrong?


title: How do I get both chapter names linked to the header, if I have two chapters on a single page?

text: I'd like to find out how I can have two chapters linked to my header. I'm using               \ihead{\headmark}      to get the names of the current chapter into the header. Document-class and loaded packages:               \documentclass [a4paper,11pt,oneside]{scrbook}      \usepackage[left=2.5cm,right=2.5cm,top=3.5cm,bottom=3.5cm]{geometry}     \usepackage[ngerman]{babel}     \usepackage[T1]{fontenc}     \usepackage[utf8]{inputenc}     \usepackage{float}     \restylefloat{figure}      \usepackage{graphicx}           \usepackage{hyperref}      \usepackage{scrpage2}      \usepackage{nameref}      \usepackage{gensymb}      \usepackage{amsmath}           \clearscrheadings     \clearscrplain     \clearscrheadfoot          \renewcommand{\chapterpagestyle}{scrheadings}          \ihead{\headmark}            \setheadsepline{0,4pt}      \setfootsepline{0,4pt}       \rofoot{Seite \thepage\ von 11}     \lofoot{Protokoll: ...,...}          \setheadwidth{text}     \setfootwidth{text}     \pagestyle{scrheadings}          \parindent 0pt      \parskip 0pt          \title{\textbf{Protokoll: Versuch 10/1 - Dünne Linsen}\vspace*{20mm}}     %     \author{\rmfamily von \textbf{...} und \textbf{...}\\     \\\textbf{\rmfamily Assistent:}\rmfamily\ ...}      %     %     \date{\textbf{\rmfamily Datum:}\rmfamily\ 26. Mai 2014 - 02. Juni 2014}                    \begin{document}      Also I used:               \listoffigures     \begingroup     \let\cleardoublepage\relax     \begin{thebibliography}{99}     \bibitem[foo] bar baz     \end{thebibliography}     \endgroup          \end{document}      to get the bibliography and the list of figures on the same page. But now I have the problem that on the page including the chapters "bibliography" and "list of figures" I get only the name of the "list of figures"-chapter in the header. I think this is caused by the fact, that normally there is only one chapter per page. ![Page with 2 chapters. But only the name of the "list of figures"\(Abbldungsverzeichnis\) chapter is in the header](http://i.stack.imgur.com/ZekCX.png) But because I have the two chapters "bibliography" and "list of figures" on a single page, I'd like to know how I can have both names of the chapters linked to the header. Is there a workaround for that?


title: Change US postal codes (CA) to AP stylebook abbreviations (Calif.) in bibliography (biblatex)

text: My `.bib` file is using US postal codes as abbreviations for US states (CA and MA for California and Massachusetts). For a paper I'm writing, these need to be changed to abbreviations such as `Calif.` and `Mass.` (cf. Wikipedia). I'd prefer not to change my `.bib` file, but instead include a command in my preamble that says "When the entry `LOCATION` in the `.bib` file has strings such as `, CA`, `, MA`, etc., then substitute these with `, Calif.`, `, Mass.`, etc.". (I've added a comma plus space before the strings to be absolutely certain that it doesn't catch any two-letter strings that aren't US states - not that I know right now what that would be, but just in case). MWE:               \documentclass{article}     \usepackage[style=authoryear]{biblatex}     \begin{filecontents}{\jobname.bib}     @BOOK{lehiste1970,         AUTHOR = "Ilse Lehiste",         TITLE = "Suprasegmentals",         YEAR = "1970",         LOCATION = "Cambridge, MA",         PUBLISHER = "The M.I.T. Press"}     \end{filecontents}     \addbibresource{\jobname.bib}     \begin{document}     \nocite{lehiste1970}     \printbibliography     \end{document}      ![enter image description here](http://i.stack.imgur.com/WOPt7.png) This should read > Lehiste, Ilse (1970). _Suprasegmentals_. Cambridge, Mass.: The M.I.T. Press.


title: Specific \epigraph style

text: I'm trying to create the `\epigraph` shown in the picture. I want to place it at the bottom right of an empty page with the style shown in the picture. I'm using the code. How can I modify it to get what I want? I don't want a line between the quote and the source ... basically the style shown below. ![enter image description here](http://i.stack.imgur.com/LLpWs.png)               \documentclass{book}     \usepackage{amsmath,amsfonts,mathabx}     \usepackage{epigraph}          \setlength\epigraphwidth{.8\textwidth}          \thispagestyle{empty}          \begin{document}          \vspace*{\fill}     \epigraph{Begin at the beginning, the King said gravely, ``and go on till you come to the end: then stop.''}{Lewis Carroll, \textit{Alice in Wonderland}}          \end{document}


title: What are the benefits of Sketch for PSTricks users?

text: When it comes to graphics and TeX I tent to be PostScript biased in part due to my age (TikZ didn't exist when I started learning TeX). Recently, I learned about Sketch. I was wondering what are the benefits of learning Sketch for the casual PSTricks user if any? Is there something which is trivial to do with Sketch but not so easy using PSTricks and its extensions?


title: Matplotlib and Python as the main TeX graphics engine

text: As many people here who do some scientific computing, I'm increasingly using Python as my main prototyping language in favor of MATLAB. A colleague of mine whose husband got me into Python approached me recently soliciting advice about graphics tools for TeX. Having in mind her background, I recommended Matplotlib in-spite of the fact that I have never used it before. Feeling guilty about my recommendation, I started experimenting with Matplotlib and I am really loving it. So far, as previously stated, my taste when it comes to graphics tools in TeX was PostScript biased, but apart from few hand hacks on PostScript files necessary to get output from old Eastern European printers I have never got to program regularly in pure PostScript. On the other hand Python is a different story, and I am trying to use it on the daily basis. Could anybody point me to an objective comparison of the graphical capabilities of Matplotlib and PostScript? I am particularly keen to see something of high quality like this post of Dr. Till Tantau, where in-spite of being TikZ main developer/inventor conceded that PostScript is still THE page description language to be reckon with.


title: Package pgf Error: No shape named X is known

text: I can't get this document to compile:               \documentclass{article}     \usepackage{tikz}     \usetikzlibrary{snakes,arrows,shapes}     \begin{document}     \begin{tikzpicture}[>=latex',line join=bevel,]            \definecolor{strokecol}{rgb}{0.0,0.0,0.0};       \pgfsetstrokecolor{strokecol}       \draw (140.1bp,19bp) node {310e} edge [loop below]  ();       \definecolor{strokecol}{rgb}{0.0,0.0,0.0};       \pgfsetstrokecolor{strokecol}       \draw (28bp,55.424bp) node {311r} edge [loop left]  ();          %          %%circles around nodes     %31-, 310e and 311r     %fail here     \draw (311r) -- (310e);     \end{tikzpicture}     \end{document}     %      It fails when I add that last draw command, saying `Package pgf Error: No shape named 311r is known.`, and another with "310e" instead of "311r". I just need to be able to draw lines with nodes as the anchors. Can anyone tell me what I am doing wrong?


title: How do I tell TikZ to compute the 'in' value again rather than use the previous one?

text: The first two lines do just what I want:               \node (F) at (1,1) {$F$};          \draw (0,2) to [out=-90] (F);      That is, it draws an edge downward from the point `(0,0)` and bends it to hit `(F)`, entering the node at roughly 135 degrees. I don't have to specify `in=135`. But the next line uses the same ~135 degree value for `in`, when I want it to have a value around 45 degrees _and not specify it_!               \draw (2,2) to [out=-90] (F);      How do I tell `tikz` to compute the `in` value again rather than use the previous one? Here's a minimum working example, modified now that it's clear I was a "victim of circuses": ![](http://i.imgur.com/1ImrZ.png)               \documentclass{article}     \usepackage{tikz}          \begin{document}       \begin{tikzpicture}         \node [circle, draw=black] (F) at (1,1) {$F$};         \draw (0,2) to [out=-90] (F);         \draw (0.7,2) to [out=-90, in=110] (F);         \draw (2,2) to [out=-90, in=45] (F);         \draw (F) to [out=-135, in=90] (0,0);         \draw (F) to [out=-45, in=90] (2,0);       \end{tikzpicture}     \end{document}


title: How to manually set a line number for end statement in algorithm2e?

text: I can manually set line numbers in an algorithm2e environment using the `\nlset` command (together with `\LinesNotNumbered`). However, I can't figure out how to make the same for lines with the `end` or `else` statements, as in the following picture: ![Example algorithm2e output](http://i.stack.imgur.com/VVFbX.png)


title: pslegend with dot instead of rule

text: I have the following MWE               \documentclass[pstricks,border=0pt]{standalone}     \usepackage{pst-node, pst-coil, pst-plot}               \begin{document}                    \begin{psgraph}[axesstyle=frame,Ox=0, Dx=0.1, Dy=0.1](0,0)(1.05,1.05){0.8\linewidth}{2.5in}%              \pslegend[rt]{         \red\rule[1ex]{2em}{1pt}  & Theoretical \\         \blue\rule[1ex]{2em}{1pt} & Numerical}     \end{psgraph}          \end{document}      I want the `\rule` next to "Numerical" to be a circle (dot) instead. I tried with `\dot`, but that gave me an error. Is there a way to do this?


title: Wrapping or adding line breaks in header cell of siunitx's S-type column

text: When using the `siunitx` package, is it possible to either "wrap" or insert line breaks in the header cell of an `S`-type column (see Section 4.6 of the documentation)? I have a relatively long table wherein I'd like to do this. Below, I show the general usage of the `S`-type column. Then, I (kind of) mimic what what to achieve using a `p`-type column, but it would be nice to be able to wrap the header while taking advantage of `siunitx`'s `S`-type column. MWE:               \documentclass[12pt]{article}     \usepackage{siunitx, booktabs}     \sisetup{per-mode=symbol}     \setlength\parindent{0em}     \begin{document}       \begin{tabular}{@{}cSSS@{}}         \toprule           &           {Reaction 1 (\si{\mmol\per\s})} &           {Reaction 2 (\si{\umol\per\minute})} &           {Reaction 3 (\si{\pmol\per\hour})} \\         \midrule           Item 1 & 10 & 12 & 15 \\           Item 2 & 20 & 22 & 25 \\           Item 3 & 30 & 32 & 35 \\         \bottomrule       \end{tabular}       \par\bigskip       \begin{tabular}{@{}cp{2cm}p{2cm}p{2cm}@{}}         \toprule           &           {Reaction 1 (\si{\mmol\per\s})} &           {Reaction 2 (\si{\umol\per\minute})} &           {Reaction 3 (\si{\pmol\per\hour})} \\         \midrule           Item 1 & 10 & 12 & 15 \\           Item 2 & 20 & 22 & 25 \\           Item 3 & 30 & 32 & 35 \\         \bottomrule       \end{tabular}     \end{document}      ![MWE output](http://i.stack.imgur.com/n4crP.png)


title: Using LaTeX to serve web requests in enterprise

text: I am looking for a solution to generate pdfs dynamically and serve the web requests. I have a couple of questions:   * Would it be a good solution to use LaTeX if I get input from web, fill LaTeX sources, generate pdf and return a link to the pdf? As far as the amount of such request may go up to 10K a day, I am worrying about load, concurrency, scaleability issues. So,   * Does anyone know the limits/boudaries for TeX compilers and pdf generators? Or suggest any to use in my case? **PS**. The reason why I chose LaTeX is that documents to be generated have lots of rules such as formating, section alignments, margins, floats, etc...


title: Generate System context diagram in TeX?

text: Good afternoon, Is there a way I can generate a system context diagram in LaTeX? - See below for example diagram: ![Example](http://i.stack.imgur.com/xsnlh.png)


title: How to use Inkscape's textext plugin

text: I am having trouble with the textext plugin in inkscape; even the simplest bit of code, such as               \documentclass[12pt]{article}      \begin{document}          test          \end{document}      gave an error as follows:               LaTeX Warning: Unused global option(s): [a0].     No file tmp.aux.     ! LaTeX Error: Can be used only in preamble.     See the LaTeX manual or LaTeX Companion for explanation.     Type  H <return>  for immediate help.      ...                                                   l.7         \documentclass                               [12pt]{article}     !  ==> Fatal error occurred, no output PDF file produced!     Transcript written on tmp.log.      What am I doing wrong?


title: Using exscale package

text: How to use `exscale` package for mathematical expressions to enlarge?               \documentclass[a4paper]{article}     \usepackage[utf8]{inputenc}     \usepackage{exscale}     \begin{document}     I need the big font          \[       \int_0^1 {\frac{\sqrt x}{2}dx}      \]          \end{document}


title: subimport issues: tikz/addplot

text: I am using subimport to include .tex chunks from different folders. Everything except my tikz figures seems to work fine. Here is a minimum working example: organization:               main.tex      > Folder1 > chapter1.tex               > data > turn_0.3.csv      my main.tex file:               \documentclass[conference]{IEEEtran}     \usepackage{pgfplots}     \usepackage{tikz}     \pgfplotsset{compat=newest}      \pgfplotsset{plot coordinates/math parser=false}     \newlength\figurewidth          \usepackage{import}     \begin{document}          \subimport{folder1/}{chapter1}          \end{document}      chapter1.tex:               \begin{figure}     \centering     \begin{tikzpicture}     \begin{axis}[         width=0.8\columnwidth,         height=0.5\columnwidth,         scale only axis,         xmin=0,         xmax=120,         grid=major,         inner axis line style={->},         xlabel={Time [s]},         ylabel={Badnwidth Usage [B/s]},         axis x line*=bottom,     axis y line*=left,         no markers,         smooth,     ]     \addplot[solid] table [x index = 0, y index =1, col sep=semicolon, green] {data/turn_0_3.csv};     \addlegendentry{0.3 rad/s}     \end{axis}     \end{tikzpicture}     \caption{Network usage in bytes per second for a single robot performing a 360  [$^\circ$] in-place rotation.}     \label{rot_bandwidth}     \end{figure}      the .csv is a 3 column seperated by ';'. I get the following error:                Package pgfplots Error: Could not read table file 'data/turn_0_3.csv'. In case you intended to provide inline data: maybe TeX screwed up your end-of-lines? Try `row sep=crcr' and terminate your lines with `\\' (refer to the pgfplotstable manual for details).      I can fix this be adding               \makeatletter        \def\relativepath{\import@path}     \makeatother      in the main.tex and appending \relativepath to the               \addplot[solid] table [x index = 0, y index =1, col sep=semicolon, green] {\relativepath data/turn_0_3.csv};      But I would like to have a solution that does not require modifying chapter1.tex file. Thank you for your time.


title: design a style using tikz package

text: How can I use latex tikz package to design the style that is seen in the picture?![enter image description here](http://i.stack.imgur.com/IAbl3.jpg)


title: Applying Matrix Operation Code

text: I'm (relatively) new to LaTeX, and I'm having a syntactic problem using the wonderful code here, which allows arbitrary matrix operations in LaTeX. I wrote a macro to generate certain matrices. E.g.:               \def\GetRotationMatrixZ#1{         cos(#1),-sin(#1),0,         sin(#1), cos(#1),0,               0,       0,1     }      Now I would like to use it with the linked code's \matnew, \matset commands. Everything obvious I tried, however, failed miserably. I tried many variations on the macro's syntax, but I'm stuck. EDIT: the main usage case would look something like:               \matnew \transformMatrixA     \matset \transformMatrixA {\GetRotationMatrixY\whatever}     % . . .     \matmul \transformMatrix \transformMatrixA \transformMatrixB      I've tried similar things; I don't remember exactly which. This particular example gives:               Unexpected comma: extra arguments ignored.


title: Why is the \endcsname not found in the following code

text: This is a precursor to my real question. But for whatever reason, when I tried reducing my code for something to post here, I got more errors. In particular, the following code gives me an error with the `\endcsname` in the `\foreach` loop. While the loop doesn't do anything like what I want it to, in my original code it actually compiled. Now in this snippet I get an error message about a missing `\endcsname`. Could someone please point out what I'm obviously overlooking?               \documentclass{article}          \usepackage{pgffor}     \usepackage{etoolbox}          \makeatletter          \def\ae@set@main#1:#2\@nil{%%       \expandafter\def\csname ae@slogan@#1/main\endcsname{#2}}     \def\slogan{\@ifstar{\set@slogan}{\get@slogan}}          \def\set@slogan#1#2{\ae@set@#1.0.0.0:#2\@nil}     \def\ae@set@#1.#2.#3.#4:#5\@nil{%%       \expandafter\def\csname ae@slogan@#1@max\endcsname{#2}%%'0       \expandafter\def\csname ae@slogan@#1.#2\endcsname{#5}}          \newif\if@iterate@through@subslogans     \def\get@slogan#1{%%       \@ae@sep#1.0.0\@nil       \ifnum\ae@second>0\relax         \expandafter\ae@get@\ae@first.0.0.0\@nil         :\hspace{0.5em}%%'       \else         \xdef\aemax{\csname ae@slogan@\ae@first @max\endcsname}%%         \typeout{====> MAX=\aemax}%%'         \ifnum\aemax>0\relax           \@iterate@through@subsloganstrue         \fi       \fi       \ae@get@#1.0.0.0\@nil       \if@iterate@through@subslogans         \expandafter\@iterate@subslogans       \fi       \@iterate@through@subslogansfalse     }     \def\ae@get@#1.#2.#3.#4\@nil{%%       \csname ae@slogan@#1.#2\endcsname}          \def\@iterate@subslogans{%%         \edef\ae@list{}           \foreach \myx in {1,2,...,\aemax}           {\typeout{==> (\myx|\ae@first) \csname ae@slogan@\ae@first.\myx \endcsname}%%' :\ae@list               }         \begin{enumerate}\item           \ae@list         \end{enumerate}     }          \def\aeitem{\item}     \def\@ae@sep#1.#2.#3\@nil{%%       \def\ae@first{#1}%%       \def\ae@second{#2}}          %% define slogans     \slogan*{1}{First of all train in the preliminaries}     \slogan*{1.1}{Arithmetic\rule{1em}{2pt}}     \slogan*{1.2}{Algebra}     \slogan*{1.3}{Geometry}          \makeatother     \pagestyle{empty}     \begin{document}            \slogan{1}            \slogan{1.2}          \end{document}      The error message               ====> MAX=3     ! Missing \endcsname inserted.     <to be read again>                         \def      l.65   \slogan{1}


title: clipbox with bidi

text: this is my code, compiled by xelatex:               \documentclass{book}     \usepackage{lipsum}     \usepackage{trimclip}     \usepackage{polyglossia}     \setdefaultlanguage{hebrew}     \setotherlanguage{english}     \newfontfamily\hebrewfont[Script=Hebrew]{Bitstream Vera Sans}          \begin{document}     hi     %\clipbox{0pt 0pt {0.6\width} 0pt}{hi}     hi          \begin{english}     \lipsum[1]     \end{english}     \end{document}      if the clipbox line stays commented-out, you get the expected results (hi hi and lipsum afterwards). but if you uncomment it, using clipbox in RTL context, the page gets mostly blank, and if the document is longer it gets crazy in other interesting ways. if I use it in LTR it's ok. I know. but my real work is in Hebrew, and I need this clipping for some nice feature I want to add there. i guess the trimclip package is not aware of bidi but it's deeply involved in text direction. so the weird RTL box confuses it. how can I solve this? or maybe use some other means for clipping a letter (means that work RTL too)? **EDIT** : OK. I've investigated it a little bit more. trimbox works just fine, so the problem is only with the clipping, which is carried out by a driver-specific command in the package files. the default uses xetex driver, which seems to have this bug. when loaded the package with [pgf] option, it gave the correct results. yet it requires me to load the graphicx package explicitly beforehand. yet, if anybody still wishes to correct the xetex driver, or at least point out the problem in it, be he blessed.


title: Remove content from field in biblatex

text: My `@thesis` entries in my `.bib` file have in the field `institution` information about both department and school. I'm creating a style sheet for a journal where only the name of the school (i.e. university, college, vel sim.) is needed. As a result, I'm looking for some code that will scan the field `institution` in the `@thesis` entries and delete text from the beginning until (and including) the final instance of `.` (period + space). If no such cases are found, as in `miller1923` below, it shouldn't do anything. If multiple cases are found, as in `anderson2008` below, it should delete all of them. In the end, only the names of the universities should remain.               \documentclass{article}     \usepackage[style = authoryear-comp]{biblatex}     \usepackage{filecontents}     \begin{filecontents}{\jobname.bib}     @thesis{miller1923,         AUTHOR = "Oscar Miller",         INSTITUTION = "Harvard University",         TITLE = "War -- what is it good for?",         TYPE = "Ph.D. dissertation",         YEAR = "1923"}     @thesis{smith2003,         AUTHOR = "Peter Smith",         INSTITUTION = "Department of Chemistry. Stanford University",         TITLE = "Oxygen and stuff",         TYPE = "Ph.D. dissertation",         YEAR = "2003"}     @thesis{anderson2008,         AUTHOR = "John Anderson",         INSTITUTION = "Department of Lang. \& Litt. Swarthmore College",         TITLE = "Shakespeare and the English he wrote",         TYPE = "MA thesis",         YEAR = "2008"}     \end{filecontents}     \addbibresource{\jobname.bib}     \begin{document}     \nocite{*}     \printbibliography     \end{document}      ![enter image description here](http://i.stack.imgur.com/Ybbl0.png)


title: Is it possible to know the actual length of a rubber length

text: The MWE is               A \hskip 0pt plus 2pt \foo B     \end      Then macro `\foo` will tell me the actual length of the previous `\hskip` in the log file. Is it possible to write such macro `\foo`? How?


title: Tables: vertical alignment of cell

text: I have a `tabu`-table and my default row-style is and **has to be`p`**. But I want the head-row ( _Column 1_ and _Column 2_ in the MWE) to be **vertically** centered. How can I achieve that? MWE:               \documentclass{article}     \usepackage{array}     \usepackage{tabu}     \usepackage{blindtext}     \usepackage{ragged2e}     \tabulinesep =0.5em     \newcommand*{\mytext}{\RaggedRight This is some blindtext with words and letters.}          \begin{document}     \begin{tabu} to\textwidth{|X[1,l,p]|X[1,l,p]|X[1,l,p]|}% m is not allowed!!!         \hline         Column 1 & Column 2 & Long Long very long caption, more than one line \\         \hline         \mytext & \mytext & \mytext \\         \mytext & \mytext & \mytext \\         \mytext & \mytext & \mytext \\         \hline     \end{tabu}     \end{document}      ![output](http://i.stack.imgur.com/p3myb.jpg)


title: Add an item in the table of contents

text: I am using tufte-book document class. I would like to add a part at the end of the document which is neither a chapter nor a section. How can I do for making this part visible in the tableofcontents?


title: pgfgantt create a blank page

text: I have this code that create a Gantt chart using `pgfgantt` package. I have two problems :   1. This code create two pages (the first is blank)   2. There's untranslated words (e.g. Today) Here's the code :               \documentclass{article}     %\usepackage[pdftex,active,tightpage]{preview}     %\setlength\PreviewBorder{2mm}     \usepackage[frenchb]{translator}     \usepackage[frenchb]{babel}     \usepackage{pgfgantt}     \usepackage{lscape}     \definecolor{barblue}{RGB}{153,204,254}     \definecolor{groupblue}{RGB}{51,102,254}     \definecolor{linkred}{RGB}{165,0,33}     \sffamily     \begin{document}     \begin{landscape}     \begin{tikzpicture} % optional        \begin{ganttchart}[x unit=2mm,                            y unit chart=1cm,                            time slot format=isodate,                            %compress calendar,                           vgrid=*{5}{dotted},                           today=2014-04-27,                           newline shortcut=true,                           title/.append style={fill=blue!20, drop shadow},                           title label font=\sffamily\bfseries\color{white},                           title label node/.append style={below=-1.6ex},                           title left shift=.05,                           title right shift=-.05,                           title height=1,                           bar/.append style={draw=none, fill=black!63},                           bar label node/.append style={align=center, font=\tiny},                           bar incomplete/.append style={fill=barblue},                           bar height=.4,                           bar label font=\normalsize\color{black!50},                           link/.style={-latex, draw=red, fill=red},                          ]                           {2014-04-14}{2014-07-11}        \gantttitlecalendar{month=name} \\               \ganttbar[progress=100]{Mise en place\ganttalignnewline de environnement\ganttalignnewline du travail}{2014-04-14}{2014-04-15} \\              \ganttbar[progress=100]{Spécifications}{2014-04-15}{2014-04-17} \\              \ganttbar[progress=70]{Comprendre et\ganttalignnewline analyser le\ganttalignnewline code existant}{2014-04-18}{2014-05-03} \\              \ganttbar[progress=60]{Analyse des \ganttalignnewline besoins de la\ganttalignnewline plate-forme MEANS}{2014-04-18}{2014-05-07} \\              \ganttbar[progress=30]{Conception des \ganttalignnewline services web}{2014-04-21}{2014-05-24} \\              \ganttbar[progress=80]{Conception de \ganttalignnewline l'API Java}{2014-04-25}{2014-05-07} \\              \ganttbar[progress=0]{Implémentation des\ganttalignnewline services web}{2014-05-26}{2014-06-15} \\              \ganttbar[progress=0]{Tests des\ganttalignnewline services web}{2014-05-26}{2014-06-17} \\              \ganttbar[progress=0]{Implémentation de\ganttalignnewline l'API Java}{2014-06-03}{2014-06-20}\\              \ganttbar[progress=0]{Tests de\ganttalignnewline l'API Java}{2014-06-03}{2014-06-21} \\              \ganttbar[progress=0]{Rédaction de\ganttalignnewline la documentation}{2014-06-22}{2014-06-25} \\              %\ganttbar[]{Maintenance}{2014-06-26}{2014-07-11}              \ganttlink[link type=f-s]{elem4}{elem6}         \ganttlink[link type=f-s]{elem1}{elem2}          \ganttlink[link type=s-s]{elem6}{elem7}           \ganttlink[link type=s-s]{elem8}{elem9}                  \end{ganttchart}     \end{tikzpicture}     \end{landscape}          \end{document}       I'm new in `pgfgantt`, I will appreciate any suggestion.


title: Invisible markers in PDFs using pdflatex

text: I'm using `latexdiff` to show changes that I make in a large text (200+ pages). Most of my changes affect only a few pages though, so I don't want my readers to sift through 200 pages looking for the rare pages where isolated typo corrections were made: only about 30pp out of the 200 will contain changes. I would like to:   1. Insert hidden PDF markers on pages where a changes occur   2. Compile with pdflatex   3. Run a script that filters out pages that don't contain the hidden PDF markers `book.tex -latexdiff-> book_diff.tex -pdftex-> 200pp.pdf -script-> 30pp.pdf` Could someone recommend:   * a tex package for inserting "markers" of some sort in a PDF file   * a python package for reading PDFs (and looking for said markers)


title: hyperref vs hyperxmp

text: What is the better package to use in embedding metadata, hyperref or hyperxmp? Which has a wider range or can be extended further? (Like: Does using xmp metadata more reliable than just embedding a simple metadata?)


title: \textbeta and \textmu defined in the beamer class

text: I really like using UTF-8 greek letters in my latex code source and I use utf8x to convert them into `\textalpha` commands and then I define the `\textalpha` commands in a separate file where I write this, for each greek letter:               \newcommand{\textalpha}{\ensuremath{\alpha}}      And can even afford the luxury to use `\varepsilon` and `\varphi`. This is actually the least intrusive and the most compatible way I found of doing this. (Well actually a little sed-parser was a lot more versatile and efficient because I knew what was going on but that's a very intrusive method) Sadly this ... does not work with beamer because it seems to already have defined `\textbeta` and `\textmu`. Yes, only them. I don't know why. Here is how to reproduce this. (This compiles. If you uncomment anything it won't compile)               \documentclass{beamer}     \usepackage[utf8x]{inputenc}     \newcommand{\textalpha}{\alpha}     %\newcommand{\textbeta}{\beta}     %\newcommand{\textmu}{\mu}     \begin{document}       $α$       % $β$       % $μ$     \end{document}      Does somebody know why? And also, how to overcome this? If I use `\renewcommand` it works in beamer files but it won't work in non-beamer files. Maybe there is a `\forcerenewcommand` that I don't know about?


title: Vertical Spacing After Paragraph Heading

text: **I can't manage to control vertical spacing after (and before) paragraph which I've customized.** \paragraph{Çatışma} Birden fazla düşman birimin karşılıklı yok etme .... And here is what i used to customize this:                   \documentclass[12pt,a4paper]{article}     \usepackage[utf8]{inputenc}     \usepackage[T1]{fontenc}     \usepackage[turkish]{babel}     \usepackage[left=3.50cm, right=2.50cm, top=3.00cm, bottom=3.00cm,nohead,nofoot]{geometry}      \usepackage[overload]{textcase}      \usepackage{graphicx}     \usepackage{amsmath}     \usepackage{amsfonts}     \usepackage{amssymb}     \usepackage{pslatex}     \usepackage[explicit]{titlesec}     \usepackage[font=small,format=plain,labelfont=bf,up,textfont=it,up]{caption}     \usepackage{graphicx,epstopdf}     \epstopdfsetup{update}     \DeclareGraphicsExtensions{.ps}     \epstopdfDeclareGraphicsRule{.ps}{pdf}{.pdf}{epstopdf er.ps --outfile \OutputFile}     \usepackage{setspace}     \setlength{\parindent}{0pt}     \renewcommand{\thefigure}{\arabic{section}.\arabic{figure}}     \setlength{\parskip}{\baselineskip}          \addto\extrasturkish{\uccode`i=\string"9D \lccode`I=\string"19 }     \addto\noextrasturkish{\uccode`i=`I \lccode`I=`i }          \titleformat{\section}       {\normalfont\normalsize\bfseries}{\thesection}{1em}{\MakeTextUppercase{#1}}     \titleformat{\subsection}       {\normalfont\normalsize\bfseries}{\thesubsection}{1em}{#1}     \titleformat{\subsubsection}       {\normalfont\normalsize\bfseries\itshape}{\thesubsubsection}{1em}{#1}          \raggedbottom     \usepackage{chngcntr}          \setcounter{secnumdepth}{6}     \renewcommand\theparagraph{\Alph{paragraph}}     \makeatletter     \renewcommand\paragraph{\@startsection  {paragraph}                                             {4}                                             {\z@}%                                             {0ex\@plus -0ex \@minus -.2ex}%                                             {0.0001pt \@plus .2ex}%                                             {\itshape\normalsize}}          \counterwithin{paragraph}{subsubsection}          \titlespacing\section{0pt}{-12pt plus 4pt minus 2pt}{-10pt plus 2pt minus 2pt}     \titlespacing\subsection{0pt}{-12pt plus 4pt minus 2pt}{-10pt plus 2pt minus 2pt}     \titlespacing\subsubsection{0pt}{-12pt plus 4pt minus 2pt}{-10 pt plus 2pt minus 2pt}     \titlespacing\paragraph{0pt}{-12pt plus 4pt minus 2pt}{-10 pt plus 2pt minus 2pt}               \usepackage{graphicx,epstopdf}     \epstopdfsetup{update}     \DeclareGraphicsExtensions{.ps}          \newcounter{subcount}                              \begin{document}      ![example](http://i.stack.imgur.com/tSEx0.png) I'm not even sure which packages effect each other and why... Any kind of help will be nice. Thanks in advance.


title: how to post TeX to Blackboard course?

text: Has anyone figured out how to post TeX code to blackboard? My browser can't run the Java applet (I am running IE7 under administrative lockdown), so I don't know of a way to get blackboard to recognize               $T(n) \le cn - b$      as TeX markup. Is there some other way to do this, like a shared link or copy-paste the image?


title: How can I draw a diamond with a cross in the center?

text: I wish to draw the cross diamond, however the line of the cross is inside the diamond, like described in the picture. ![enter image description here](http://i.stack.imgur.com/AXmwK.jpg) However, I tried the code below, the result is               \node[draw, diamond, below=of aux] (cross diamond) {};     \draw (cross diamond.north) -- (cross diamond.south)           (cross diamond.west) -- (cross diamond.east);      ![enter image description here](http://i.stack.imgur.com/xX57o.jpg)


title: how to truncate labelname using authoryear-style?

text: I've got a problem with my labelname in the bibliography. I adapted authoryear-style in order to display labelname and labelyear at the beginning of a reference. I want to display a maximum of two authornames (last names). If there are more than two authornames it should display the first authorname and add "et al.". Maybe it should be a counter like maxlabelnames=2... At the moment the labelname is truncated after only one authorname.               \documentclass{scrreprt}          \usepackage[ngerman]{babel}          \usepackage[babel, german=quotes]{csquotes}     \usepackage[style=authoryear, maxcitenames=2, firstinits=true, uniquename=init,  backend=biber]{biblatex}     \usepackage{filecontents}          \AtBeginBibliography{%     \renewcommand*{\multinamedelim}{\addsemicolon\space}     \renewcommand*{\finalnamedelim}{\addsemicolon\space}     \renewcommand{\labelnamepunct}{\addcolon\space}     \DeclareFieldFormat{title}{#1\isdot}     \DeclareNameFormat{sortname}{     \iffirstinits         {\usebibmacro{name:last-first}{#1}{#4}{#5}{#7}}         {\usebibmacro{name:last-first}{#1}{#3}{#5}{#7}}%         \usebibmacro{name:andothers}}     \renewbibmacro{begentry}{%     \textbf{\printnames[][-\value{liststop}]{labelname}~                 \printfield{labelyear}%                 \printfield{extrayear}}\\}     }          \DefineBibliographyStrings{ngerman}{andothers={et\ al\adddot}}     \DefineBibliographyStrings{ngerman}{and={\&}}          \begin{filecontents}{Label.bib}     @book{Bogelsack.1985,     author = {B{\"o}gelsack, G. and Kallenbach, Eberhard and Linnemann, Gerhard},     year = {1985},     title = {Roboter in der Ger{\"a}tetechnik},     address = {Heidelberg},     publisher = {A. H{\"u}thig},     isbn = {3778510428}     }               @book{Warnecke.1990,     author = {Warnecke, H.-J and Schraft, R. D.},     year = {1990},     title = {Industrieroboter: Handbuch f{\"u}r Industrie und Wissenschaft},     address = {Berlin [etc.]},     publisher = {Springer-Verlag},     isbn = {3540509348}     }     \end{filecontents}          \addbibresource{Label.bib}          \begin{document}          Test (\cite{Bogelsack.1985}).           Test 2 (\cite{Warnecke.1990}).          \printbibliography          \end{document}      The Bögelsack-item is okay, but the Warnecke-item is wrong. It should be: **Warnecke & Schraft 1990** Warnecke, H.-J.; Schraft, R. D. (1990): Industrieroboter: Handbuch für Industrie und Wissenschaft. Berlin [etc.]: Springer-Verlag. isbn: 3540509348. Does anybody have an idea?


title: Complex Page Layout in LaTeX

text: I'm a complete beginner at LaTeX, and I'm trying to typeset a complex layout. How should I go about building a page like the one shown below. ![example layout](http://i.stack.imgur.com/3kjeZ.png) **Edit** I was able to replicate the layout using `minipages` with the `multicols` package. The images were embedded using the `graphicx` package.


title: Indenting Text in Beamer

text: I am attempting to indent text, as below. ![enter image description here](http://i.stack.imgur.com/P56up.png) To get the alignment right (and it's far from perfect right now), I've been using trial and error with a linebreak `\\\` and `\hspace{3.1cm}`. Is there a legitimate way to get the results in the image above? As a minimum working example, I have                   \documentclass[12pt,mathserif]{beamer}          \usetheme{Berkeley}         \usecolortheme{dove}         \useinnertheme{default}         \setbeamertemplate{navigation symbols}{}          \setbeamertemplate{itemize items}[default]         \setbeamertemplate{enumerate items}[default]              \beamertemplatenavigationsymbolsempty         \setbeamerfont{footline}{size=\fontsize{9}{11}\selectfont}         \setbeamertemplate{footline}[page number]              \begin{document}         \frame{\frametitle{Detecting MWEs in Typed Text}         \begin{itemize}         \item $\mathbf{Assumption \;1}$: MWEs have unique prosodic\\             \hspace{3.1cm}characteristics         \item $\mathbf{Assumption \;2}$: KD is the reflection of prosody in\\             \hspace{3.1cm}typing         \item $\mathbf{Conclusion}$: \hspace{0.5cm}MWEs should be uniquely\\             \hspace{3.1cm}characterized in typing         \end{itemize}         }     \end{document}


title: tikz cannot parse radius in "radius=0.3" command

text: \documentclass[12pt]{article}          \usepackage{tikz}          \begin{document}          \begin{figure}     \centering     \begin{tikzpicture}[scale=1]       \draw (0,1.7) circle [radius=0.3] node {$T_1$};           \end{tikzpicture}     \end{figure}     \end{document}      I just wanted to specify the radius of the circle, but tikz gave the error > "! Package tikz Error: Cannot parse this radius." How can I fix this error?


title: Comparison of TeXworks editor with others with respect to spell checking

text: I use TeXworks editor on Windows where the default setting appears to be a) Errors are underlined in red (but TeX code is not recognized and so it is underlined too; and ``comments'' are in red too) this makes for an egg hunt to find the errors. b) You cannot permanently add a word to the dictionary Can the default be changed and how do other editors perform in this respect?


title: Using underline and strikethrough simultaneously in a table

text: I'm new to LaTeX and am currently using it to try and piece together a report on the orthography of the Armenian language. I'm trying to create a table where one column will display the printed letters and the other will display how they look in a "handwritten" font. In the second column, I'm interested in placing a baseline and a midline to show how the letters are to be written. The code I have looks something like this example (where I have replaced the actual fonts with Times New Roman):               \documentclass{article}          \usepackage{fontspec}     \setmainfont{Times New Roman}     \usepackage[normalem]{ulem}     \usepackage{color}          \newcommand\baseline{\bgroup\markoverwith{\textcolor{blue}{\rule[0ex]{2pt}{0.4pt}}}\ULon}     \newcommand\midline{\bgroup\markoverwith{\textcolor{red}{\rule[0.72ex]{2pt}{0.4pt}}}\ULon}     \newcommand\textline[1]{\huge{\baseline{\midline{\makebox[1cm][c]{#1}}}}}          \begin{document}     \begin{tabular}[c]{|c|c|c|c|}     \hline     A & \textline{A} & B & \textline{B}\\     \hline     C & \textline{C} & D & \textline{D}\\     \hline     \end{tabular}     \end{document}      I am using TeXstudio and XeLaTeX. The output seems fine, but what I'm wondering about is this error that keeps popping up, namely:               ! Dimension too large.     \UL@on ...UL@height \advance \UL@height -\ULdepth                                                    \setbox \UL@box \hbox {{#1...     l.15 A & \textline{A}                       & B & \textline{B}\\     I can't work with sizes bigger than about 19 feet.     Continue and I'll use the largest value I can.      As I said, it seems to compile correctly, but I'm wondering what the cause of this error is and if there is any possible remedy to the situation. Thanks a bunch!


title: EPS output from PSTricks

text: I am trying to produce an `EPS` file from a PSTricks code. I am reproducing here the sample working code that I already have here: PSTricks---plotstyle LSM (Least Square method) Here is the modified code with `\PStoEPS`               \documentclass[12pt]{article}     \usepackage{filecontents}     \begin{filecontents*}{data.dat}     0.0     0.0     144.321  0.84     159.407     0.8925          \end{filecontents*}          \usepackage{pst-plot,pstricks-add}     \usepackage{pst-eps}               \begin{document}     \readdata{\data}{data.dat}     \PSTtoEPS[bbllx=0,bblly=0,bburx=0,bbury=0]{test.eps}{%     \psset{xunit=0.6mm,yunit=30mm,xlabelFactor=$$,labelFontSize=\footnotesize,mathLabel=false}     \begin{pspicture}(0,0)(150,3)     \psaxes[axesstyle=frame,Dx=50,Dy=0.5, ticksize=0 4pt](150,3)     \listplot [xStart=0, xEnd=150,xunit=1,plotstyle=values,rot=90] {\data}     \listplot [xStart=0, xEnd=150,xunit=1,linewidth=1.5pt,linecolor=red,showpoints, dotstyle=square] {\data}     \end{pspicture}}          \end{document}      My understanding is that I need to enclose all PSTricks code in th last argument of `\PStoEPS`. On compilation, no DVI file is created and no other consequent output (eps) as well. I have three questions:   1. How to properly set the `\PStoEPS` options?    2. What compilation sequence is necessary to get the `EPS` output (LaTeX > DVI2ps?)   3. Are the bounding box coordinates necessary to be specified? Will `\PStoEPS` not produce an `EPS` with tight bounding box?  Thanks a lot... * * * Update: trying to use `pst2pdf`:               \documentclass[12pt]{article}     \usepackage{filecontents}     \begin{filecontents*}{data.dat}     0.0     0.0     144.321  0.84     159.407     0.8925          \end{filecontents*}          \usepackage{pst-plot,pstricks-add}     \usepackage{pst-eps}     %\usepackage{auto-pst-pdf}          \begin{document}     \pagestyle{empty}     \parindent=0pt     \readdata{\data}{data.dat}     \psset{xunit=0.6mm,yunit=30mm,xlabelFactor=$$,labelFontSize=\footnotesize,mathLabel=false}     \begin{pspicture}(0,0)(150,3)     \psaxes[axesstyle=frame,Dx=50,Dy=0.5, ticksize=0 4pt](150,3)     \listplot [xStart=0, xEnd=150,xunit=1,plotstyle=values,rot=90] {\data}     \listplot [xStart=0, xEnd=150,xunit=1,linewidth=1.5pt,linecolor=red,showpoints, dotstyle=square] {\data}     \end{pspicture}          \end{document}      On a DOS prompt running the `pst2pdf` command on the above `tex` file gives:               ! Undefined control sequence.     <argument> \data          l.23 ...0,xunit=1,plotstyle=values,rot=90] {\data}          ?      The `pst2pdf` has difficulty to understand the `\listplot` arguments. The goal in producing an `EPS` file is also to have one with a tight bounding box. But using the document class `standalone` seems to cut away the axes and no labels or tickmarks are shown.


title: Placing text and footnotes on separate pages

text: How can I place the main text of a document on only verso (left) pages and the footnotes on recto (right) pages (or vice versa)? Update: The expected appearance is not unlike moving the whole footnote area to the next page. A simple solution like this should work, but does not:               \renewcommand\footnoterule{\newpage}      Update: I have made some small progress on this on my own. The `footnote` package, as part of `mdwtools` has a command called `\savenotes`, `savenotes` environment, and `spewnotes` command.   * `savenotes` - This tells it to save notes.   * `savenotes` environment - Text places between here are saved.   * `spewnotes` - This tells it to print the notes. This code will display some text, but put the footnotes on the next page:               \documentclass{article}     \usepackage{footnote}     \begin{document}         \savenotes         This is some text.\footnote{This is a footnote.}         \newpage         \spewnotes     \end{document}      Unfortunately, this appears to be incompatible with `footmisc`. Update: I have discovered this page which explains how to put text on recto and figures on verso pages: Figures on left pages, text on right ones with class book, numbering only on right pages With some modification, footnotes can be placed on the left-hand pages:               \documentclass{book}     \usepackage{afterpage}     \usepackage{blindtext}     \makeatletter     \newcommand\@addfig{\relax}     \newcommand\addfig[1]{\global\long\def\@addfig{#1}}     \newcommand\@putfig{\@addfig\addfig{\relax}}     \newcommand\blankpage{%         \null         \@putfig%         \thispagestyle{empty}%         \addtocounter{page}{-1}%         \clearpage     \afterpage{\blankpage}}     \makeatother     \begin{document}         \afterpage{\footnote{This is in the right place.}\blankpage}         \blindtext         \Blindtext         \Blindtext         \Blindtext         \Blindtext         \Blindtext     \end{document}      The placement of everything seems fine, but the footnotes are not truly functioning as they should.


title: ConTeXt: Set mixedcolumns maximum height for vertical rule

text: # Background Looking to ensure that the height of a vertical rule for the first page of a section is the same as the subsequent sections. # Code Minimum working example to illustrate the issue:               \usemodule[ipsum]          \setuplayout[       topspace=\zeropoint,       height=fit,       width=fit, % Allow text to be flush with the bottom.       %footerdistance=2cm,     ]          \definemixedcolumns[StyleColumns][       frame=off,       separator=rule,       rulecolor=black,       alternative=global,       %maxheight=\textheight,     ]          % Set up two-column mode for the ingredients, instructions, etc.     \setuphead[section][       after={\startStyleColumns},       aftersection={\stopStyleColumns},     ]          \def\StylePageNumber#1{%       {\inframed[         frame=off,         background=color,         backgroundcolor=red,         width=2em,         height=2em,       ]{#1}}     }          \setuppagenumbering[location=inright,command=\StylePageNumber,]          \starttext     \startchapter[title=Chapter]       \startsection[title=Section]         \input knuth \input zapf \ipsum \input knuth \input knuth \input zapf       \stopsection     \stopchapter     \stoptext      # Problem The issue is that the vertical rule on the first page extends too far, shown below: ![Vertical Rule Extension](http://i.stack.imgur.com/7LGKV.png) The vertical rule on the first page should be the same height as the second page. I believe the vertical rule is reaching the bottom of the page due to the layout code:               \setuplayout[       topspace=\zeropoint,       height=fit, % Allow text to be flush with the bottom.       width=fit,     ]      Specifically:                 height=fit, % Allow text to be flush with the bottom.      Without adjusting the height to `fit`, the page number shifts up from being flush with the bottom of the page to being well above the page footer. The distance can be adjusted manually using:               footerdistance=2cm,      Yet that affects the subsequent pages, which were otherwise perfect. Due to the height being stretched to "fit", the following code does not work, either (I'm fairly certain `\textheight` has been recalculated to equal the page height):                maxheight=\textheight,      # Question How would you have a page number flush with the page bottom with a vertical rule that consistently matches the text height, without overlapping the chapter and section names? For example: ![Final Rule](http://i.stack.imgur.com/Gma4D.png)


title: Reducing the time it takes to write a document

text: ## Exemplar case I often have situations in which I must quickly write and print a report, within a short time. Some features of TeX allow me to work quickly. For example, with `BibTeX`, I can quickly add a source to an article. ## Issue However, some features of TeX seem to make the work inefficient. For e.g.: it can be difficult to make a `tabular` fit onto one page. Some problems are more serious, such as the syntax. One misplaced `&` or `}` and the whole document fails to compile.   * What packages, supporting software, or tricks have saved you time?   * What packages, settings, or work-flow process can help ensure that documents will always compile?


title: How to create a paragraph header centered and with '(a)' label

text: For my \documentclass[11pt, a4paper, oneside]{Thesis} in subsection 2.3.4 I created code for paragraphs:               \documentclass[11pt, a4paper, oneside]{Thesis}     \subsection{The reasons of wide values}     \setcounter{secnumdepth}{5}     \renewcommand\theparagraph{\alph{paragraph}}     \paragraph{State of the vegetation}     \paragraph{Climate}      \paragraph{Methods}     \setcounter{secnumdepth}{5}     \renewcommand\thesubparagraph{\arabic{subparagraph}}     \subparagraph{Lysimeters}     \subparagraph{Energy balance}     \subparagraph{Water balance}      But I want my paragraphs look like this:               2.3.4 The reasons of wide values          Some text                                     (a) State of vegetation     Some text                                     (b) Climate     Some text                                     (c) Methods     1.Lysimeters.-Some text          2.Energy balance.-Some text          3.Water balance.-Some text      What do I need to change in the code for the look I want? Please forgive me if I use wrongly LaTex terminology. I am new to the LaTex.


title: Make two figures aligned at top

text: I am inserting two graphs (of different size) in the following way:               \begin{figure}[H]     \begin{center}     \includegraphics[scale=0.5]{graph1.eps}     \includegraphics[scale=0.3]{graph2.eps}     \caption{\label{fig:scaled_diss}}     \end{center}     \end{figure}      which would be perfect if the graphs were of near-identical build, but it's currently resulting in the graph borders being mis-aligned, as in: ![enter image description here](http://i.stack.imgur.com/4xes0.png) So the right graph doesn't have tics on the x axis. How do I make it that the graphs are aligned at the top, then the scaling can be altered, to give something like this: ![enter image description here](http://i.stack.imgur.com/SiNaD.png)


title: Author not appearing

text: I've properly set the reference in the `.bib` file but still getting author problems:               Author undefined for the 'baeza1999modern' on page 1      In my `ref.bib`, I do have an entry:               @book{baeza1999modern,       title={Modern information retrieval},       author={Baeza-Yates, Ricardo and Ribeiro-Neto, Berthier and others},       volume={463},       year={1999},       publisher={ACM press New York.}     }      In LaTeX, the text is               As coupled by ~\citet{baeza1999modern},      I want to get something like `Baeza-Yates et al.`. However, it is appearing like ![enter image description here](http://i.stack.imgur.com/4eAJ0.png) The error I am getting is               Author undefined for citation`baeza1999modern' (natbib) on page 1      Any idea? * * * Ok, currently I have a solution which allow me at least to continue working, I added this in the preamble,               \usepackage[numbers, square]{natbib}      and this `\bibliographystyle{plainnat}`. So, currently the `et al` is being displayed properly, the citation is appearing like `[2,1]`. It would have been better if it was like `[Sin01,ADV10]`; any suggestion?


title: why my pic was changed by un-used tikzstyle

text: In a joint file, my picture was changed by some un-used global tikzstyle, which is added by other. Here is a minimal example. The output dots become bigger if I un-comment the commented line.               \documentclass{standalone}          \usepackage{tikz}     \usetikzlibrary{matrix,arrows,calc}     %\tikzset{cd/.style=matrix of math nodes,row sep=2em,column sep=2em, text height=1.5ex, text depth=0.5ex}          \begin{document}          \begin{tikzpicture}[mydot/.style={draw,circle,inner sep=1.5pt},every label/.style={scale=0.6},scale=0.75]            \node[mydot]      at (0,0)    (p1) {};       \node[mydot]      at (2,0)    (p2) {};          \end{tikzpicture}          \end{document}


title: Avoid eps to png conversion using mk4ht oolatex

text: I have a big set of `eps` images and I need to place them into an `OpenOffice` (`odt`) document. I wrote a simple script that creates a `tex` file containing these `eps` images and now I'm trying to convert it to `odt` format with:               mk4ht oolatex eps-images.tex      The problem is that all the images are converted to `png` format, thus becoming (ugly) bitmaps instead of (nice) vector images. Reading the manpage of `mk4ht`, I see that there is an option to skip image conversion:               -p     Do not convert pictures      but this option doesn't apply directly to `mk4ht` but has to be passed to one of its sub-scripts: `t4ht`. Looking at the conversion process with `ps afxu` (under Linux), the sequence of nested commands is:               \_ /usr/bin/perl /usr/bin/mk4ht oolatex eps-images.tex        \_ sh -c /usr/share/tex4ht/htlatex eps-images.tex "xhtml,ooffice" "ooffice/! -cmozhtf" "-cooxtpipes -coo"            \_ /bin/sh /usr/share/tex4ht/htlatex eps-images.tex xhtml,ooffice ooffice/! -cmozhtf -cooxtpipes -coo                \_ t4ht -f/eps-images.tex -cooxtpipes -coo                    \_ sh -c dvipng -T tight -x 1400 -D 72 -bg Transparent -pp 40:40 eps-images.idv -o eps-images19x.png                        \_ dvipng -T tight -x 1400 -D 72 -bg Transparent -pp 40:40 eps-images.idv -o eps-images19x.png      So the question is: how can I get a `-p` option down there to `t4ht`? **EDIT1: Thanks toCV Radhakrishnan for its answer! We're getting closer, but it still doesn't work.** If I run the command:               mk4ht oolatex eps-images ' '  ' '  ' -p'      starting from scratch, only with `tex` files in the main folder, the output of the last two scripts is:               ----------------------------     tex4ht.c (2009-01-31-07:33 kpathsea)     tex4ht -f/eps-images        -i/usr/share/texmf/tex4ht/ht-fonts/        ooffice/!        -cmozhtf      --- warning --- Can't find/open file `ooffice/!.dvi'     --- error --- Can't find/open file `ooffice/!.dvi'     ----------------------------     t4ht.c (2009-01-31-07:34 kpathsea)     t4ht -f/eps-images        -p        -cooxtpipes        -coo      (/usr/share/texmf/tex4ht/tex4ht.env)     --- warning --- Can't find/open file `eps-images.lg'      and no `odt` file is created. So the `-p` option actually reaches the `t4ht` command, but something in the middle is still missing and the script doesn't complete. Conversely, if I first run:               mk4ht oolatex eps-images      thus creating all the `png` images, and then run:               mk4ht oolatex eps-images ' '  ' '  ' -p'      all the `png` images are embedded into the final `odt` file (that is corrupt, however). So, it seems that someone in the middle still uses/needs the `png` images. **EDIT2: found another small hinthere.**               Conditional bitmap conversion for imported graphic files          Q. How to avoid the conversion of eps files to PNG’s, included through the \includegraphics{...} command’, each time the source file is run across tex4ht.          Compile your source with the command line ‘ htlatex filename "html,info" ’, and check the log file for the information provided there. In particular, the ‘\Configure{graphics*} {wmf} ...’ example may be adapted for dealing with eps files, where a conditional conversion is requested within the ‘\Needs{"..."}’ command (possibly indirectly through a call to a script for doing he job).      ## Can someone improve this solution?


title: Display math formula in the middle of a line

text: I am writing a report using some template with `amsmath`. The equations are displayed in a way that they are flushed to the left with certain space in front. Does anyone know how it happens? How can I change change something to make all math equations be displayed in the middle of a line?


title: How can I shift ymin to zero when values are near to zero?

text: How can I shift `ymin` to zero when values are near to zero? I also try `ymin=0` command but it does not work.               \begin{figure}[h]     \centering     \begin{tikzpicture}     \begin{axis}[     ybar, ymax=4,     enlargelimits=0.15,     legend style={at={(0.5,-0.20)},     anchor=north,legend columns=-1},     ylabel={Surface Roughness (nm)},     xlabel={Substrate},     symbolic x coords={Glass,Silicon,PEN},     xtick=data,     nodes near coords,     nodes near coords align={vertical},     ]     \addplot [fill= white] coordinates {(Glass,2.4) (Silicon,1.1) (PEN,1.8)};     \addplot [fill = black] coordinates  {(Glass,1.1) (Silicon,0.2) (PEN,1.0)};          \legend{Profilometer,AFM}     \end{axis}     \end{tikzpicture}      \caption{Substrate Vs IBD Surface Roughness(Avg)}     \label{Subvibd}     \end{figure}


title: How can I get just the table of contents to take the full page width?

text: I am using the template provided from http://hci.rwth- aachen.de/karrer_thesistemplate for my master thesis. The template is built so that there are margin notes at each page and is using the book class, so the text in any page is only taking around 60%. This is good for me but the problem is with the table of contents. Since there are no margin notes I would like to have the contents taking the whole width of the page. How do I do this for just the table of contents?


title: Why does pdflatex stall when called by NIS Users?

text: I ran into a very strange problem recently: I'm administrating Mandriva Linux in a networked setup where users authenticate via NIS. We noticed that pdflatex simply stalls with no error messages and output. All we get is the following:                   This is pdfTeX, Version 3.1415926-2.3-1.40.12 (TeX Live 2011/Mandriva)           restricted \write18 enabled.           **        It doesn't accept any commands or produce any output that we can see. We get the same behavior if we try running it on a file, as in `pdflatex <filename>`   Using a local user (as opposed to an NIS user) account, I was able to compile LaTeX files with no problem, so this seems related to NIS somehow. The weird thing is, we have one NIS user who doesn't face this problem and can compile LaTeX files normally.   Has anybody seen this before? Are there known solutions/workarounds? Is there a way for me to investigate further to help you answer this question?   Thanks EDIT: My answer below is based on Martin Schröder's suggestion.


title: Cannot manipulate nodes in tikz

text: I am using the following code               \documentclass[11pt,a4paper]{book}     \usepackage{tikz}     \usepackage[american voltages, american currents]{circuitikz}     \usetikzlibrary{%     calc,%     fadings,%     shadings%     }     \usetikzlibrary{arrows,snakes,shapes}     \begin{document}     \begin{figure}     \centering     \begin{circuitikz}%MM structure     %PCB     \draw[rounded corners, color=Darkgreen, fill=green, path fading=south] (0,0) rectangle     (11,0.6);     \draw node at (11.4,0.1) {\footnotesize \textcolor{Darkgreen}{\eng{PCB}}};%name it          %Read-Out Strips     \draw[color=orange, fill=orange] (1,0.6) rectangle (2,1);     \draw[color=orange, fill=orange] (3,0.6) rectangle (4,1);     \draw[color=orange, fill=orange] (5,0.6) rectangle (6,1);     \draw[color=orange, fill=orange] (7,0.6) rectangle (8,1);     \draw[color=orange, fill=orange] (9,0.6) rectangle (10,1);     \draw node at (11.4,0.8) {\footnotesize \textcolor{orange}{\eng{Strips}}};%name it          \draw node[ground] at (1.5,-1) {};     \draw node at (1.5,-1) {} to [R] (1.5,0);%<--------This is what I want to do     %\draw node[ground] to [R] (1.5,-1);     %\draw node[R] at (1.5,0) {};          %Micro-Mesh     \draw[very thick, color=gray, dashed] (0,3) -- (11,3);     \draw node at (11.4,3) {\footnotesize \textcolor{gray}{\eng{Mesh}}};%name it     \draw (0,3.5) -- (0,2.5) -- (-0.5,3) -- (0,3.5);     \draw node at (-1,3) {\footnotesize \eng{-HV}};%name it     \draw node at (-2,1.8) {\footnotesize \eng{Amplification}};     \draw node at (-2,1.4) {\footnotesize \eng{Gap}};          %Drift     \draw[very thick, color=gray] (0,6) -- (11,6);     \draw node at (11.4,6) {\footnotesize \textcolor{gray}{\eng{Drift}}};%name it     \draw (0,6.5) -- (0,5.5) -- (-0.5,6) -- (0,6.5);     \draw node at (-1,6) {\footnotesize \eng{-HV}};%name it     \draw node at (-2,4.8) {\footnotesize \eng{Drift}};     \draw node at (-2,4.4) {\footnotesize \eng{Region}};          %Particle's track     \draw[color=red,->] (0.2,7) -- (11.4,-1);     \draw node at (2.5,6.5) {\footnotesize \textcolor{red}{\eng{Particle's Track}}};%name     it          %electron     \draw (3,5) --(3.2,3);     \draw node at (1.5,4) {\eng{Primary's}};     \draw node at (1.6,3.6) {\eng{track}};          %avalanche     \draw[very thick, red, rotate=0, fill=red] (3.15,3) .. controls (2.15,0.4) and     (4.25,0.4) .. (3.25,3);     \draw[color=red] node at (1.8,1.5) {\eng{Avalanche}};          \end{circuitikz}     \caption{}%     \label{}%     \end{figure}     \end{document}      All I am trying to do is place a resistor and a gound below the first orange rectangle. While ground is placed as it should be, the resistor doesn't. I don;t know how to figure this out...Any suggestions will be welcomed!


title: Difference between - and -- in compiling options

text: In running MiKTeX   1. What is the difference between `-shell=escape` and `\--shell-escape`   2. What is the difference between `-synctex=1`, `\--synctex=1`, and `\--synctex=-1`


title: Wrong line spacing when changing the font size inside of a rectangle

text: i'm trying to change the font size inside of a rectangle and always the line space between the last and the second last line is getting wrong. How can that be fixed?               \documentclass[]{article}     \usepackage{tikz}     \usetikzlibrary{shapes}          \begin{document}     \begin{tikzpicture}         \tikzstyle{block} = [rectangle, draw, text centered, thick, node distance = 2cm, text width=1cm]            \node[block]                (init)  {1 \\  2 \\ 3  \\ 4};         \node[block,right of=init]  (second){\scriptsize 1 \\ 2 \\ 3  \\ 4};         \node[block,right of=second](third) {1 \\ \scriptsize 2 \\ 3  \\ 4};     \end{tikzpicture}     \end{document}      ![enter image description here](http://i.stack.imgur.com/nwOp7.png)


title: Is there any way to find what \settextfont[Scale=XXXXX] equivalent to font size?

text: I want to know how can I match `\settextfont[Scale=XXX}` with MS word font size? For example if I want to write essay in font of 14 in Ms word what should I set instead of XXX in `\settextfont[Scale=XXX}`? _EDIT Marco Daniel:_ The package `xepersian` provides the command `settextfont`


title: What is wrong with this macro-defining macro?

text: have this `\newsetter` macro that defines a "setter" macro (for lack of a better name) and a @-prefixed macro of the same name that holds the value. This is how is supposed to work:               \newsetter\macro          \macro{foo}     \@macro     % expands to foo          \macro{bar}     \@macro     % expands to bar      And this is the `\newsetter` code:               \newcommand\newsetter[1]{%       \@temptokena=\expandafter{\expandafter\@gobble\string #1}%        \expandafter\newcommand\csname @\the\@temptokena\endcsname{}%       \expandafter\newcommand\csname\the\@temptokena\endcsname[1]{%         \expandafter\renewcommand\csname @\the\@temptokena\endcsname{##1}}}%      The problem with this code is that it only works in a particular order:               \newsetter\firstword     \firstword{Hello}     \newsetter\secondword     \secondword{World}          \@firstword\ \@secondword         % expands to Hello World      Whereas the following fails:               \newsetter\firstword     \newsetter\secondword     \firstword{Hello}     \secondword{World}          \@firstword\ \@secondword         % expands to World, \@firstword is empty      What is wrong here?


title: Making boxed "problem" environment and a solution environment

text: I'm trying to make a template for my homework. I've been using a modification of the Harvey Mudd homework class, but there are some things I don't really like about it (functional and aesthetic). What I do want are the boxed problem environment and something like their solution environment (which is a lot like amsthm's proof environment). For the problem environment, I would like to call it, as in the HMC class, by typing               \begin{problem}[%problem number%]     %problem statement%     \end{problem}      I also wanted the frame to be "3-D," similar to `\shadowbox`, but I can't figure out how to get a more subtle effect. And is there a way that I can make a solution environment that is essentially identical to the asmthm proof environment? I want to redefine the qed symbol to be `\blacksquare` and be able to use `\qedhere`. I'm also trying to get spacing similar to that of amsthm's theorem and proof environments (that is, before and after the environments). If it matters, I am using AMS article. And here are some things I've referred to (and tried) in my attempts at this: Problem/solution environment Example/Solution Environment Box around minted environment http://www.slideshare.net/linjaaho/how-to-make-boxed-text-with-latex (On a similar note, how do you look at the "source" [I'm not sure this is the correct term] for a class? I would like to look at how stuff was defined/created in the HMC class, for instance.) Oh, and a link to the HMC class. Which has a pdf preview. EDIT: I think I figured out a solution environment:               \newenvironment{solution}{\begin{proof}[Solution]}{\end{proof}}


title: Converting PDF to EPS results in low resolution rasterization

text: I have a problem with image converting for scientific manuscript. I have been using `gnuplot` to make graphs, using TikZ terminal, and finally generating the figure as a PDF with LaTeX. It results in a nice vector graphic image, in PDF file format (PDFLaTeX). The problem is that publishers ask for images in EPS format. When I try to convert my PDF with `Imagemagick` or `pdf2ps`, I get a low resolution rasterized image. But as far as I know eps is also a vector graphic format. I tried to set the resolution for conversion, but I get the same low resolution image. Is there a way to convert my vector graphic PDF to vector graphic EPS? Or anyone knows a way to export in eps from `gnuplot` with LaTeX typesetting/fonts? Thanks,


title: Both centering and left alignment in same column in S colummn from siunitx

text: Here we go again with an `S` column problem:               \documentclass{article}          \usepackage[utf8]{inputenc}     \usepackage{booktabs}     \usepackage[locale=DE]{siunitx}          \DeclareSIUnit{\kroner}{kr.}          \begin{document}          \begin{table}      \centering      \caption{Priser på får og uldmængden, de giver.}      \label{tbl:1}       \begin{tabular}{         S[table-text-alignment=left]         S[table-format=4.0]         S[table-format=1.0]       }        \toprule         {Fårerace}     & {Vejledende pris per får} & {Uldmængde per får om året} \\         {---}          & {\si{\kroner}}            & {\si{\kg}}                  \\        \midrule         {Dorset}       & 1650                    & 4                         \\         {Gotland}      & 1595                    & 5                         \\         {Marsk}        & 1525                    & 7                         \\         {Rygja}        & 1800                    & 6                         \\         {Texel}        & 1725                    & 5                         \\        \bottomrule       \end{tabular}     \end{table}          \end{document}      ![output](http://i.stack.imgur.com/i2O6f.jpg) I would like `Fårerace` and `\---` to be centered in the first column instead of left-aligned as the rest of the entries. How do I get this?


title: Help with biblatex, no date

text: I have another problem with `biblatex` (I'm sorry but it's the first time that I use the `biblatex` package). In the .bib file I wrote               @article {amberg:artinian,      author = {Amberg, B.},          title = "Artinian and noetherian factorized groups",     journaltitle = {Rend. Sem. Mat. Univ. Padova},     date = {1976},        volume = {55},        pages = {105-122}        }      But in the pdf output I got this: `B. Amberg. Artinian and noetherian factorized groups. Rend. Sem. Mat. Univ. Padova 55 (), 105-122` As you can see, there is no date between brackets! Can you help me with that? This is the packages I used and the code I wrote to change the bibliography style:               \usepackage[autostyle,italian=guillemets]{csquotes}     \usepackage[backend=biber,style=numeric]{biblatex}     \addbibresource{biblio.bib}          \DeclareFieldFormat[article]{title}{#1}     \DeclareFieldFormat[article]{journaltitle}{\textit{#1}}     \DeclareFieldFormat[article,periodical]{volume}{\textbf{#1}}     \DeclareFieldFormat[article]{pages}{#1}          \renewbibmacro{in:}{%       \ifentrytype{article}{}{%       \printtext{\bibstring{in}\intitlepunct}}}      Thank you very much! This is a MWE:               \documentclass[a4paper]{report}     \usepackage[italian]{babel}     \usepackage[autostyle,italian=guillemets]{csquotes}     \usepackage[backend=biber,style=alphabetic]{biblatex}     \addbibresource{due.bib}          \begin{document}       Sia G \cite{amberg:artinian}       \cleardoublepage       \addcontentsline{toc}{chapter}{\bibname}       \printbibliography     \end{document}


title: Bibliography - issue - APA6

text: I am failing to understand following problem with my bibliography....citation in text works fine, citations in bibiography work fine too, except one problem: I want it like "Planen und Problemlösen: Überlegungen zur ...." but it results in "Planen und Problemlösen: überlegungen zur ....". I have no idea how to force LaTeX giving me a big Ü instead of a tiny ü. MWE:               \documentclass[12pt,ngerman]{article}     \usepackage[utf8]{inputenc}     \usepackage[ngerman]{babel}     \usepackage[backend=biber,style=apa]{biblatex}     \usepackage[german=quotes]{csquotes}%mod.     \usepackage[locale=US]{siunitx}     \DeclareLanguageMapping{ngerman}{ngerman-apa}     \addbibresource{Literatur.bib}          \begin{document}     Hello, this is my cite: \cite{Funke.1990}     \printbibliography     \end{document}      In my `Literatur.bib`:               @Article{Funke.1990,     Title  = {{P}lanen und {P}robleml{\"o}sen: {\"{U}}berlegungen zur      neuropsychologischen {D}iagnostik von {B}asiskompetenzen beim {P}lanen},     Author = {Funke, Joachim and Glodowski, Anne-Simone},     Journal= {Zeitschrift f{\"u}r Neuropsychologie},     Year  = {1990},     Pages = {139--148},     Volume = {2}     }


title: \rowcolor in \NewDocumentCommand

text: It seems to be impossible to wrap `\rowcolor` in a macro defined with `\NewDocumentCommand`, while everything is fine with `\newcommand`. Is ist possible to fixe this?               \documentclass{article}          \usepackage[table]{xcolor}     \usepackage{xparse}          \NewDocumentCommand{\rowI}{}{         \rowcolor{blue}     }     %\newcommand{\rowI}{     %   \rowcolor{green}     %}          \begin{document}     \begin{tabular}{lll}         \rowI 1 & 2 & 3 \\         1 & 2 & 3 \\     \end{tabular}     \end{document}      Since the error only appears with `\NewDocumentCommand` I guess `xparse` causes the problem and not `\rowcolor` itself …


title: Forcing smaller line spacing (risking that text overlaps) in XeTeX

text: I am writing some XeTeX code to display Chinese text with ruby (tone marks, translation or pronunciation) above and below the characters. If on any one line, I have ruby below, and then on the next line I have ruby above another character, the line spacing will automatically be stretched to about 2, even though I have specified 1.5 in the definitions. Is there any way to forcefully set the line spacing, taking the risk myself that some of the Ruby text might overlap?


title: Set fixed place for page numbers?

text: I really tried to reproduce this kind of error with a minimal working example, but whenever I strip it down the error disappears? My problem is, that the place of the page number is not fixed. In the first pages it is ok, e.g. like this: ![test1](http://i.stack.imgur.com/dUtDT.png) Suddenly in my document (no new paragraph change or something like this) it is more down below, so it changes? E.g. see this: ![test2](http://i.stack.imgur.com/aOQzT.png) There is no command or something like this, it just suddenly changes (after page 50) and then it stays there? So I wanted to ask, if there is a general command with which I can fix the place of the numbers? I tried to set it with `\setlength{\footskip}{5mm}` which moves the page numbers up, but the problem is, that it is still different, so suddenly it is more down (after page 50). EDIT: Here is the setting I use, I do not know which package causes the problem:               \documentclass[a4paper,              12pt,                                            bibliography=totoc,                  index=totoc,                 abstracton,                  headsepline,                      ]{scrreprt}                         \usepackage{latexsym}                  \usepackage[latin1]{inputenc}        \usepackage[ngerman,english]{babel}            \usepackage{amsmath}      \usepackage{subfig}          \usepackage{float}           \usepackage{graphicx}            \usepackage{rotating}       \usepackage{mathrsfs}     \usepackage{eurosym,bm,amsmath,amssymb,verbatim}     \usepackage{listings}     \usepackage[T1]{fontenc}     \usepackage{setspace}     \usepackage [round,authoryear] {natbib} Literaturstil     %\usepackage{natbib}     \usepackage{amsthm}     %\usepackage{placeins}     \usepackage{graphicx,eso-pic,lipsum}     %\usepackage[automark]{scrpage2}     \usepackage{url}     \usepackage{tikz}     \usepackage{tocstyle}     \usetocstyle{allwithdot}      \usepackage[bookmarksopen,hyperfootnotes=false,pdftitle=, pdfauthor=,pdfsubject=Master Thesis]{hyperref}     \usepackage{fancyhdr}     \usepackage{listings}      \lstset{        language=R,                   basicstyle=\scriptsize,       showstringspaces=false,       showspaces=false,       keywordstyle=\color{blue},                commentstyle=\color{green},              stringstyle=\color{black}     }     \usepackage{enumerate}     \usepackage{remreset}      \makeatletter     \@removefromreset{footnote}{chapter}     \makeatother     \usepackage{dblfnote} % multicolumn footnotes     \usepackage{booktabs} % for tables     \KOMAoption{footnotes}{multiple} % multiple footnotes     \usepackage[top=2cm,bottom=2cm]{geometry}      \usepackage{cleveref} % ref to multiple figures     \usepackage{multirow}  % for multirow     \usepackage{bookmark} % for bookmarks          \usepackage{lipsum}     \usepackage{tikz}     \usetikzlibrary{backgrounds} % for quotes               \usepackage{calligra} % for dedication          \usepackage{listings} % for ROutput      EDIT: Here is my log-file, I do not know so much about LaTex, so I still do not know what causes this problem? Link to my log file.


title: Creating a rhombus in LaTeX

text: I want to build an E/R diagram in LaTeX such that there should be rhombus for representing the relations and squares for representing the entity sets. I dont want to import graphics in LaTeX i.e. import the graphics after drawing it in some other image drawing software but want to do it in LaTeX itself.Could someone suggest me some good links to read from??


title: MinionPro is not displaying Cyrillic (and other) characters

text: I am following the directions in the `README` at the CTAN entry for `MinionPro`. I am using the Minion Pro fonts from the Adobe Font Folio 11. I'm running a fully-updated TeX Live 2011 distribution on OS X Lion 10.7.2. _Please note that I'm entirely aware this can be solved by using XeLaTeX (with`fontspec`), but I wish to use LaTeX in this case._ Running `otfinfo -v` on any one of the 64 Minion Pro fonts yields,               Version 2.030;PS 2.000;hotconv 1.0.51;makeotf.lib2.0.18671      so naturally I'm using the `enc-2.000.zip` encoding files. After unzipping `metrics-base.zip`, `metrics-full.zip`, `metrics- opticals.zip`, and `enc-2.000.zip` into my `/usr/local/texlive/texmf-local` directory, I ran `sudo mktexlsr`, then `sudo updmap-sys --enable Map=MinionPro.map`, then `sudo mktexlsr` again. I then typeset my test file, whose code and output is shown below.               \documentclass[10pt]{article}     \usepackage[T1,T2A]{fontenc}     \usepackage[openg]{MinionPro}     \usepackage[utf8]{inputenc}     \usepackage[english,russian]{babel}          \begin{document}     \section*{English}     Hello! How are you? This sentence has \textbf{bold}, \textit{italic}, and \textbf{\textit{bold italic}} characters. This sentence has \textsc{small caps}.          \section*{Russian}     Здравствуйте! Как у вас дела? Это предложение имеет \textbf{жирные}, \textit{курсивные}, и \textbf{\textit{жирные курсивные}} буквы. Это предложение имеет \textsc{капительные буквы}.          \section*{Equations}     \[       \psi_{nlm}(r,\theta,\rho) = \sqrt{\bigg(\frac{2}{na_0}\bigg)^3 \frac{(n - l - 1)!}{2n[(n + l)!]^3}} e^{-\rho / 2} \rho^{l} L_{n - l -1}^{2l + 1}(\rho) \cdot Y_{l}^{m}(\theta, \phi)     \]     \[       y = x\tan(\theta) - \frac{g\sec^2(\theta)}{2v_0^2}x^2     \]     \end{document}      ![image of test code output](http://i.stack.imgur.com/WKTSx.png) Note that the `openg` option also fails to display. This is strange to me, because it seems as if everything is working except for a few characters. Everything works great with XeLaTeX, but not when using the `MinionPro` package. Forgive me if I'm being naïve. Thanks.


title: Chapter headers with extending vertical rulers

text: I'm trying to reproduce the example below on the right margin, but have come into serious errors.               \documentclass[a4paper,DIV=classic]{scrbook}        \usepackage{scrpage2}        \usepackage{lipsum}        \usepackage{graphicx}          \titleformat{\chapter}[hang]     {\normalfont\Large\raggedright}     {%     \llap{ \resizebox{!}{1.2cm}{\thechapter} \smash{\rule{.4pt}{10cm}} } }     {10pt}{\Huge}          \begin{document}     \chapter{A Chapter}          \end{document}      I tried adapting the code below, which works fine:               \titleformat{\chapter}[display]      {\normalfont\Large\raggedleft}      {\MakeUppercase{\chaptertitlename}%      \rlap{ \resizebox{!}{1.2cm}{\thechapter} \smash{\rule{.4pt}{10cm}} } }      {10pt}{\Huge}      But then I cannot get rid of `\MakeUppercase{\chaptertitlename}` without messing things up. What am I doing wrong here? The result I expect is like: ![enter image description here](http://i.stack.imgur.com/10BWF.png)


title: Adding crop marks to a4 document to crop it to book without changing the layout?

text: I have a complete 150 pages LaTeX document that is in a4 format. I basically want to print it **exactly** as it is, except that I want to add crop part of the margins. I want to remove 10mm on the inner, 40mm on the outer, 40mm on the top and 30mm on the bootom edge. Basically what I want to do is just print the document on a4 paper in the original size, but afterwards cut it to its final size. For this I have to provide the print shop with either a version that has the final document size or a version in a4 that has crop marks. Unfortunately all my attempts to crop the page led to wrong results where parts of the document were cut off. I tried the crop package but that only seems to work if you want to add margins to the given document and not if you want to take them away. Also geometry did not help (maybe I am using it wrong). I can specify a paperheight and a voffset, but if I try to change the paperwidth it messes with the margins and i didn't find a way to just take from the paper 10mm on the inside and 40mm on the outside. What is the simplest solution to do what I want to do? EDIT: With Werner's reply I would consider this as a minimal example of what I am dealing with:               \documentclass[11pt,twoside,BCOR=10mm]{scrreprt}     \typearea[current]{calc}     \usepackage[T1]{fontenc}     \usepackage[utf8]{inputenc}     \usepackage[english]{babel}     \usepackage{setspace}     \usepackage{blindtext}     \usepackage[a4paper]{geometry}          \geometry{layoutheight=230mm,layoutwidth=160mm,layoutvoffset=30mm,layouthoffset=10mm,showcrop}          \typearea[current]{last}     \setlength{\textheight}{200mm}     \begin{document}\blindtext[8]\end{document}


title: Includegraphics: set image opacity

text: I'd like to insert a PDF, but make it "lighter" by setting the opacity to 10% ("background watermark"). How to do that? A solution that works with texlive 2011 would be great. I use pdflatex and includegraphics to insert the image.


title: Section Headings With Long Titles

text: I am trying to use latex to write my thesis, and I have modified a template to use, but am having trouble with some of my section headings. Specifically, with the weird spacing between words caused by the section heading being justified, rather than flush left. I am using the titlesec package and have tried:               \titleformat{\section}{\raggedright\large\sffamily\bf}{\thesection}{1em}{}      I also tried forcing titlesec to make everything raggedright by adding               \usepackage[raggedright]{titlesec}       to my preamble but neither seem to have any effect and the heading text is still strangely spaced. I think it is probably something else within my settings that is taking preference?               \documentclass[11 pt]{report}     %-----------------------------------------     %                  Packages     %-----------------------------------------          \usepackage{titlesec}     \usepackage[a4paper, scale=1.0, textwidth=145mm, textheight=237mm, layoutvoffset=0pt, layouthoffset=0pt, ignoremp, includehead, marginparsep=0pt, bottom=4cm, top=2cm, left=4cm, right=2.5cm, verbose=true, bindingoffset=0pt]{geometry}      \usepackage[utf8]{inputenc}      \usepackage[T1]{fontenc}      \usepackage[english]{babel}      \usepackage{setspace}      \usepackage[toc, page, header]{appendix}      \usepackage{fancyhdr}      \usepackage[plain]{fancyref}      \usepackage{textcomp}      \usepackage{sectsty}     \usepackage{balance}      \usepackage{lastpage}     \usepackage[format=plain,justification=centering,singlelinecheck=false,font=small,labelfont=bf,labelsep=space]{caption}           %-----------------------------------------------------------------------     %   MAIN PAGE SETUP     %-----------------------------------------------------------------------          \renewcommand{\rmdefault}{ptm} % sets roman font to Times ('ptm')     \renewcommand{\sfdefault}{phv} % sets serif font to Helvetica      \renewcommand{\ttdefault}{lmtt} % sets text type font to Latin Modern Typewriter ('ptm')     \widowpenalty=500      \clubpenalty=500      \pretolerance=10000      \tolerance=2000 %     \emergencystretch=10pt           \titleformat{\section}{\fillleft\large\sffamily\bf}{\thesection}{1em}{} %formats the section titles           \begin{document}          \onehalfspace     \chapter[Introduction]{Introduction}     \chaptermark{Introduction}     \label{ch:introduction} % label for referring to chapter in other parts of the thesis     \section[Importance]{Importance}\label{C1:Intro}      Filling in later                \section[Synthesis]{Synthesis of averylongcompoundnamethatis toobigtofitinthisbox}           blahblahblah          \end{document}      ![Longtitleimage](http://i.stack.imgur.com/fjwCH.jpg)


title: Page numbers and address formatting in letters in LaTeX

text: I've recently turned away from the `letter` document class for writing my covering letters as I'd like a little more creative freedom with the formatting, and as my own little exercise in formatting LaTeX. I'm almost done with my template, but I just have two teeny questions.   1. Is there a way to suppress page numbers for a single paged document, but allow them if my letter spills over to a second page (without compiling and checking manually)? And also,   2. Is there a way to align the rightmost point of the return address at the top with the rightmost part of the main body? I'd normally do it manually after compiling, but since I like to put the date in there, the length keeps changing. If that's a little vague, here's an MWE (using tabular, which is as close as I've gotten):              \documentclass{article}          \begin{document}     \begin{minipage}{\textwidth}     \hfill\begin{tabular}{l}     a) Return address\\     b) Here's a short line\\     c) Here's a slightly longer line     \end{tabular}\\     \end{minipage}\\          \noindent Here's a really long bit of text, to show where the line breaks are normally, and to show that at the moment, they don't line up. The end of the line labelled c) should align with the line breaks in this body of texts, and the start of line a) and b) should align with the start of line c).          \end{document}


title: Writing readable LaTeX

text: Lets say I have the following LaTeX code               \subsection{Convex sets}     A set \( \mathcal{S} \)     in \( \mathbb{R}^n \)     is said to be convex if      \[ \mathbf{x}_1, \mathbf{x}_2 \in \mathcal{S} \implies \lambda \mathbf{x}_1 +     (1-\lambda) \mathbf{x}_2 \in \mathcal{S} \text{~~~for all~~~} 0 < \lambda < 1 \]      I find that even after formatting it like this with a new line after each inline math environment it gets pretty unreadable after a while. I find that for texts that are full of math, in general, it is really hard to produce readable code. Is there some best practices how to write more readable math in LaTeX? I there something like LyX but with the possibility to write pure LaTeX and have commands being processed in the editor. Like if I write `\textbf{b}` then b would show as bold and the `\textbf{}` part would disappear. The when I hover with mouse over or place cursor behind b `\textbf{}` shows up again. Maybe this is possible with LyX?


title: Getting an error when trying to use 'xstring' commands in my macro

text: When I try to compile the minimal example below, I get an error:               ! Argument of \@xs@StrLeft has an extra }.     <inserted text>                      \par      l.33 \setInSCCF{abcdef}      If I switch the usage of `\setInSC` to `\textbf` in the `\setInSCCF` command, then it works. So there must be something related to the `\setInSC` command. However, `\setInSC` works fine when used on its own. I tried expanding the argument first but to no avail (don't know if I did it correctly, though).               \documentclass[a4paper, 11pt]{article}          \usepackage{textcase}     \usepackage{xstring}          \makeatletter     \DeclareRobustCommand{\setInSC}[1]{%       \ifx\f@shape\code@Roman         \expandafter\textsc{\MakeTextLowercase{#1}}%       \else         \ifdim\fontdimen\@ne\font>\z@           \begingroup           \check@mathfonts           \fontsize\sf@size\z@\selectfont           \let\MakeTextLowercase\@firstofone           \expandafter\MakeUppercase{#1}%           \endgroup         \else           \expandafter\MakeTextUppercase{#1}%         \fi       \fi     }     \newcommand*{\code@Roman}{n}     \newcommand*{\code@Italics}{it}     \makeatother          \DeclareRobustCommand{\setInSCCF}[1]{%       \StrLeft{#1}{1}\setInSC{\StrGobbleLeft{#1}{1}{}}%     }               \begin{document}     \setInSCCF{abcdef}     \end{document}


title: MuPDF errors in TeXmaker after viewing PDF

text: The compilation of the code is `exited normally`. After I view the PDF and close the PDF file and I see a huge set of errors in TeXMaker:               .\mupdf\source\fitz\stream-read.c:223: seek failed warning: ... repeated 85 times ... !     .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state -      .\mupdf\source\pdf\pdf-interpret.c:3044: Ignoring errors during rendering !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state -      .\mupdf\source\pdf\pdf-interpret.c:3044: Ignoring errors during rendering !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state -      .\mupdf\source\pdf\pdf-interpret.c:3044: Ignoring errors during rendering !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state -      .\mupdf\source\pdf\pdf-interpret.c:3044: Ignoring errors during rendering !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state -      .\mupdf\source\pdf\pdf-interpret.c:3044: Ignoring errors during rendering !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state -      .\mupdf\source\pdf\pdf-interpret.c:3044: Ignoring errors during rendering !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@ca1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !      .\mupdf\source\pdf\pdf-interpret.c:2542: cannot find extgstate resource 'pgf@CA1' !      .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state !     .\mupdf\source\pdf\pdf-interpre t.c:2542: cannot find extgstate resource 'pgf@ca1' !     .\mupdf\source\pdf\pdf-interpret.c:2825: cannot set graphics state          Process exited normally


title: Subfigure arrangment with no caption with IEEE format

text: I have a little problem. I am trying to arrange to subfigures side by side (i.e. a graph and its legend) using the IEEE article format and I cannot remove the subcaption. I was using package subfigure at first but I don't want to have the subcaption underneath the figures (i.e. (a), (b) ). By searching on the internet, I've found out that package _caption_ could do the job, but seems to have some compatibility issues with the IEEE class file. Therefore I had to create a table and put the figures in the table. However, now the legend is not centered. Here's the code:               \begin{figure}[!h]     \centering     \begin{tabular}{cc}      \includegraphics[scale=0.135]{fig_graph} &  \includegraphics[scale=0.115]{Legend} \\     \end{tabular}     \caption{Caption text.}     \label{fig_graph}     \end{figure}      **Question:** How is possible to put two figures side by side with no subcaption and without using the caption package (and no graphical editors if possible)? **Using _subcaption_** didn't helped. I forgot to mention that I am using _IEEEConf_ not IEEEtran. I modified the code as follows:               \begin{figure}[!h]     \centering     \begin{subfigure}     \includegraphics[scale=0.135]{fig_graph}     \phantomcaption{}     \end{subfigure}     \hfill          \begin{subfigure}     \includegraphics[scale=0.115]{Legend}     \phantomcaption{}     \end{subfigure}     \caption{Caption text.}     \label{fig_graph     \end{figure}      And now MikTex 2.9 complains that subcaption and subfigure cannot be used together. If I remove subfigure, the compiler gets VERY angry on another subfigure I have > Missing number, treated as zero.\letl.214 \label{fig_matrices}}). and a lot > more complaining about missing numbers and illegal units like pt (I guess > beacuse subfigure is needed) The packages I am importing are:               \documentclass[letterpaper, 10 pt, conference]{ieeeconf}     \IEEEoverridecommandlockouts     \overrideIEEEmargins          \usepackage{url}     %\usepackage[caption=false]{subfig}     \usepackage[pdftex]{graphicx}     \usepackage{subfigure}     \usepackage{booktabs}     \usepackage{multirow}     \usepackage{amsmath}     \usepackage{array}     %\usepackage{subcaption}      \usepackage{cite}      The error I get if I use caption is: > Command \c@subfigure already defined. If I use caption by giving:               \usepackage[caption=false]      I get many errors: > Argument of \@fileswith@pti@ns has an extra }. > > Paragraph ended before \@fileswith@pti@ns was complete. > > Paragraph ended before \reserved@b was complete. > > Undefined control sequence. \@fileswith@pti@ns ...served@b \reserved@a > ,\@nil,}\fi \reserved@al.37 \usepackage[pdftex]{graphicx} And a lot more most of them about not finding things or finding things and think that are undefined. I was kind of aware that people may get just a warning for caption, but what's wrong with this? Thank you all for your help!