Tag Info

10

This is a bug in multicol similar to the one recently found about marginpars. At the end of a page LaTeX's normal output routine resets the variables \@mparbottom and \@textfloatsminheight. The multicol package neglected to do so, thus \@textfloatsminheight still contained the height from the here float from the first page --- as a result the available ...

6

Like this? \documentclass{article} \usepackage{graphicx,calc} \newlength\myheight \newlength\mydepth \settototalheight\myheight{Xygp} \settodepth\mydepth{Xygp} \setlength\fboxsep{0pt} \begin{document} This is some arbitrary \raisebox{-\mydepth}{\fbox{\includegraphics[height=\myheight]{tiger}}} line of uninteresting text. \end{document} As written, ...

5

I would do it like this: % arara: pdflatex \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{caption,booktabs} \usepackage[flushleft]{threeparttable} \usepackage{siunitx} \begin{document} \begin{table} \centering \begin{threeparttable} \caption[Primary Energy Consumption]{Primary Energy Consumption ...

5

David Carlisle suggests tabular, which is good. But there is also the tabbing environment. In the first line of tabbing you set one or more alignment points with \=; in subsequent lines you align with \>: \documentclass{article} \begin{document} \begin{tabbing} Here is some text. \=Alignment point set.\\ \>Under alignment point.\\ ...

5

At this point it's hard to know whether pure TikZ or pgfplots is the best tool, since both packages allow to easily draw the diagram in the question. Below I show both possibilities. If you need to plot some functions, then pgfplots would be my suggestion; if not, then pure TikZ can do the job. In both cases, you can use the appropriate options to scale ...

4

This has been fixed in version 1.1.1 of this package. Please note that there is a new syntax since 1.1 which looks like: #1 (optional) = stepsize, #2 = yearstart, #3 = yearstop, #4 = postscaledtimelinewidth, #5 (optional) = prescaledtimelinewidth The code for your and JLDiaz' example looks like the following: % arara: pdflatex ...

4

Here I do some stacking. I had to introduce \xlu to achieve underlining on tabbed fields. EDIT: I create \twobrak[text] as a stackable 2-row bracket element, that can be incorporated into the tabular stack. \documentclass{article} \usepackage{tabstackengine} \def\xlu#1{\setbox0=\hbox{$#1{}$}% ...

4

Here is a solution based on the blkarray package: \documentclass{book} \usepackage{amsmath} \usepackage{blkarray, bigstrut, booktabs} \usepackage[x11names]{xcolor} \begin{document} \begin{blockarray}{r@{}r@{{}={}}l@{\qquad}l} \begin{block}{\Left{\scriptsize\fcolorbox{IndianRed3}{white}{\parbox{1.6cm}{\raggedright Here, we can add ...

3

You can use TikZ and put your images inside \nodes placed at the current page.center special anchor (\node is overlay aware). Compile the code twice so the images reach their final positions: \documentclass[12pt,utf8]{beamer} \usepackage{tikz} \begin{document} \begin{frame} \begin{itemize} \item<1,3,6-> item \item<3,6-> item \item<6-> ...

3

Just place the \caption above the \includegraphics: \documentclass{article} \usepackage{graphicx,subcaption} \begin{document} \begin{figure}[h!] \begin{subfigure}[b]{.329\textwidth} \caption{} \includegraphics[width=\textwidth]{example-image-a} \end{subfigure} \begin{subfigure}[b]{.329\textwidth} \caption{} ...

3

Here's one option using the \sidesubfloat command from the floatrow package; using subcapbesideposition (possible values= top, bottom, center) you can control the vertical position of the labels for the subfloats: The code: \documentclass[a4paper,10pt]{article} \usepackage{graphicx} \usepackage{floatrow} \usepackage{subfig} \begin{document} As we can ...

2

Explanation \indent basically switches to horizontal mode and inserts a box of width \parindent; since inside a list (such as enumerate) \parindent is 0pt, using \indent inside a list won't produce any indentation. Recommendation You can define a command to give you the desired indentation: \documentclass{article} ...

2

algorithm uses the float package which defines a H float specifier. Without loading algorithm, your \begin{table}[H] ... \end{table} actually produces an error stating "Unknown float option H". LaTeX does recover from this error though and then defaults to something different, which changes the display to a page-of-floats-like layout (which has the ...

2

This will turn off top floats for the duration. The default for article class is 2, but amsclass uses 4. Use \makeatletter\the\c@topnumber\par\makeatother to find out. \documentclass{article} \usepackage{mwe} \begin{document} \lipsum[1-3]% at least 0.7 of first page \begin{figure}[t]\includegraphics{example-image-a}\end{figure} ...

2


2

The following uses a default array construction to lay out the elements you require: \documentclass{article} \begin{document} \[ \renewcommand{\arraystretch}{1.2} \begin{array}{r@{}r@{}l@{}l} \raisebox{-.5\dimexpr\arraystretch\normalbaselineskip}[0pt][0pt]{$\left\{\begin{array}{@{}c@{}} \mathstrut \\ \mathstrut \end{array}\right.$} ...

2

\wd, \ht and \dp (not \tp) are TeX primitives for getting the width, height and depth of a box (respectively). So, for example, \newbox\mybox \setbox\mybox=\hbox{\vrule width10pt height20pt depth 30pt} \typeout{width=\the\wd\mybox, height=\the\ht\mybox, depth=\the\dp\mybox} will produce width=10.0pt, height=20.0pt, depth=30.0pt Somewhere in the ...

2

I figured I might as well just use pdfcrop to same sized margins and using a bash script to apply it to all of my pdfs for file in $DIRECTORY/*.pdf; do # Process$file echo $file # Find bounding boxes pdfcrop --verbose$file tmp.pdf | grep "%%HiResBoundingBox:" > bbox; # First page has the largest bounding box largest=`echo \$(head -n 1 ...

1

Simply lower from 0.3\baselineskip: \documentclass{article}%[preprint2]{aastex} \usepackage{graphicx} \newcommand*{\img}[1]{% \raisebox{-.3\baselineskip}{% \includegraphics[ height=\baselineskip, width=\baselineskip, keepaspectratio, ]{#1}% }% } \begin{document} \begin{enumerate} \item When ready, click ...

1

Here's one option using the eso-pic package; using the conditional on the page value you can easily select which image to place on the designated pages: \documentclass{book} \usepackage[a6paper]{geometry}% just for the example \usepackage{tikz} \usepackage{eso-pic} \usepackage{lipsum} \AddToShipoutPictureBG{% \def\Image{}% \ifnum\value{page}=3\relax ...

1

You could say something like \documentclass{book} \usepackage{lipsum} \title{a title} \begin{document} \maketitle %maybe more stuff \cleardoublepage\thispagestyle{empty} %clears head and foot \vspace*{5cm} %adjust spacing as you like \begin{center} % i think this should be centered To my father \end{center} \vfill %some content.. here fake ...

1

There are two issues, it would appear from the OP's comments: 1) insetting an image, and 2) eliminating/masking the transparancy of the inset. I will address the issues in turn: IMAGE INSET Here I give two examples using \stackinset. The first flush to the bottom right corner, and the second with some border. I use \includegraphics for the images, but ...

1

pdfTeX in PDF mode provide \pdfsavepos, which stores the current position that can be written to the .aux file and used the next TeX run. Also XeTeX and LuaTeX provide this features. There are some limitations: XeTeX's right to left mode is somewhat broken. Graphics state changes, that do not use the pdfTeX interfaces (\pdfsetmatrix, \pdfsave, \pdfrestore) ...

1

These solutions are too complicated IMHO, you don't need to install any new packages. \begin{figure}[h] \begin{tabular}{ll} \includegraphics[scale=1]{Figures/Race.png} & \includegraphics[scale=0.4]{Figures/Bearing.png} \end{tabular} \caption{Left: Diagram of angular contact bearing \cite{NBCBearing}. Right: Disassembled bearing} \label{Fig:Race} ...

Only top voted, non community-wiki answers of a minimum length are eligible