Tag Info

Hot answers tagged

7

That looks like a potential bug, but as a workaround you can force the page break where the page break finally happened, before the section, then the float placement gets in sync: \documentclass{article} \usepackage{mwe} \usepackage{flafter} \begin{document} \blindtext[4] paragraph1 %paragraph2 \clearpage \section{My section} \begin{figure}[hbpt] ...


5

No need to guess values: set the (a) box with reference point at the bottom, the (b) box without depth and the (c) box with reference point at the top (just for symmetry). \documentclass{book} \usepackage{graphicx,adjustbox} \usepackage[hypcap=true]{subcaption} \begin{document} \begin{figure}[tbp] \raggedright \begin{subfigure}[b]{0.24\linewidth}% ...


5

I used my method here What are the ways to position things absolutely on the page? for placing the image on the page. I used Bruno's answer at Can \includegraphics be used to change an image color? to employ the decodearray option of \includegraphics to change the image color of the background. Other than that, I just employed a clipbox of the magnified ...


5

As Mico says in his comment p{3.5cm} is not enough in the \multicolumn, change it to p{4.5cm}. Then adjust the optional argument of \multirow (I've changed it from 4 to 8). MWE \documentclass[12pt]{report} \usepackage{multirow,caption} \usepackage{bigstrut} \makeatletter \def\hlinewd#1{% \noalign{\ifnum0=`}\fi\hrule \@height #1 \futurelet ...


4

The problem is actually independent of flafter, it happens even if you comment out the package altogether: as the section appears on page 2 why is the "h" float not after the section but on top of it? The reason for this behavior is that a \section command attempts to keep the material following it on the same page. Therefore while LaTeX is still processing ...


4

The package stfloats allows to have bottom two column floats: \documentclass[twocolumn]{article} \usepackage{graphicx} \usepackage{stfloats} \usepackage{kantlipsum} \begin{document} \kant[1-3] \begin{figure*}[b] \centering \includegraphics[width=.8\textwidth,height=4cm]{example-image} \caption{A caption to this wonderful picture} \end{figure*} ...


4

You're forgetting the indentation at the start of a paragraph. For TeX, a picture environment is just like a single (big) letter. I changed the unit length to 1cm in order to fit the picture in the page. The showframe package shows the boundaries of the text block. \documentclass[letterpaper,10pt]{article} \usepackage{showframe} \usepackage[calc]{picture} ...


4

You want the page break to happen after the \vfill otherwise it will happen before the \vfill on the first column (and so be discarded) but still be there on the last: so use \vspace* \documentclass[twocolumn]{article} \newcommand\myskip{} % vertical spacing between mybox environments \newenvironment{mybox}{\par\noindent% ...


3

You have to use figure* here. Also reduce the width of minipages to \begin{minipage}{.0.48\textwidth}. And in \includegraphics the width can be \linewidth. Further, you may need the [t] alignment specifier for minipages and a \hfill in between the minipages. There is no need of using \captionof, use \caption straight away.. ...


3

Rather than changing the styling of the chapter title itself, I would keep the page style the same --- it seems odd to me to switch the chapter style. Instead, I would either have the diagram float to another page or simply rotate the diagram on the title page, without rotating the page itself. For example, allowing the diagram to float to the next page: ...


3

I don't use fancy, but rather a home-brewed concoction. I EDITED to excise the unneeded fancy and tikz calls. Also, I did not employ your colors, but used an algorithm for varying the colors. Finally, this only works for ascii \lettergroups at present, so no umlauted e's will get a tab. I use everypage as the vehicle, employing logic similar to my answer ...


3

To place a node x distance to the right of node a, use: right=x of a x might, for example, be 0pt or 5mm or whatever. To place the inner line of the ellipse, it is easiest to draw the outer line first and then place the inner line using inout.center to centre the ellipse. This seems simpler, to me, than figuring out the appropriate amount to move to the ...


2

How about simply adding a \vspace*{-20pt} to you progress bar? \addtobeamertemplate{frametitle}{} {% \vspace*{-20pt} \begin{beamercolorbox}[wd=\paperwidth,ht=1pt,dp=1pt]{}% \progressbar@progressbar% \end{beamercolorbox}% }%


2

You can add blank line if no subtitle is provided. \documentclass[14pt]{beamer} \usetheme{Singapore} \makeatletter \setbeamertemplate{frametitle}% { \ifbeamercolorempty[bg]{frametitle}{}{\nointerlineskip}% \@tempdima=\textwidth% \advance\@tempdima by\beamer@leftmargin% \advance\@tempdima by\beamer@rightmargin% ...


2

Here it is Code: \documentclass[11pt,a4paper,sans]{moderncv} \moderncvstyle{classic} % CV theme - options include: 'casual' (default), 'classic', 'oldstyle' and 'banking' \moderncvcolor{red} % CV color - options include: 'blue' (default), 'orange', 'green', 'red', 'purple', 'grey' and 'black' \usepackage{ leftidx} \definecolor{orange}{RGB}{255,127,0} ...


2

You may measure the left image and then build a minipage with the same height containing the other two images (as subfigure environments). \documentclass{article} \usepackage{graphicx} \usepackage{subcaption} \newsavebox{\bigimage} \begin{document} \begin{figure} \centering \sbox{\bigimage}{% \begin{subfigure}[b]{.38\textwidth} \centering ...


2

You fixed-width p-column is too narrow. You can calculate the actual width to have a more precise measurement if needed, or specify something close to it (the actual width, under \scriptsize is around 133pt): \documentclass[12pt]{report} \usepackage{bigstrut,booktabs,siunitx} \makeatletter \def\hlinewd#1{% \noalign{\ifnum0=`}\fi\hrule \@height #1 ...


2

From the comments, with additional information added: TikZ/pgf define several special nodes in every path/picture. These are detailed in Section 102.4 of the manual. The one we're interested in here is current bounding box. The details from the manual: Predefined node current bounding box This node is of shape rectangle. Unlike normal nodes, its ...


2

One option would be to use auxiliary coordinates defined from the (t) coordinate (the lower end of the left line with the spring) \coordinate (upperright) at ( $ (t)+(0.5,0) $ ); \coordinate (lowerleft) at ( $ (t)+(-0.5,-2) $ ); and then use those coordinates to draw the "rectangular" component \draw (lowerleft) -- (lowerleft-|upperright); \draw ...


2

Here's one option: The code: \documentclass{article} \usepackage{listings} \usepackage{tikz} \usetikzlibrary{tikzmark} \lstset{ basicstyle=\small\ttfamily, escapeinside=@@, columns=fullflexible } \begin{document} Some regular text before \vspace{1.8cm} \begin{lstlisting} @\tikzmark{a}@this.@\tikzmark{b}@Something = new AnotherThing(anArgument); ...


2

Hopefully I understood what you want... \documentclass{article} \usepackage{graphicx} % to add figure environment that comes with caption \usepackage{caption} %if you don't want to float your figure for using \captionof \usepackage{tikz} \usetikzlibrary{calc,patterns,decorations.pathmorphing,decorations.markings,circuits} \tikzset{ ...


2

article class has \setcounter{totalnumber}{3} so only allows three floats per text page by default, but you can reset that, however more easily you could use [!htbp] where the ! signifies that the numeric constraints are to be ignored.


1

I don't know if this fix is universal, but it works for a number of different box sizes (\mysize). I apply an optional argument to your \mybox environment. If the optional 1-letter argument is F or is omitted, it applies a closing \vfill to the environment. For any other letter, it applies a \vspace{-.5\baselineskip} (and I am not sure why this works). ...


1

I'd make a 'special' pedersen style and just use that. \documentclass[12pt,a4paper,oneside]{memoir} \usepackage[left=3.00cm, right=3.00cm, top=3.00cm, bottom=3.00cm, a4paper]{geometry} \usepackage{pdflscape,blindtext,graphicx,xcolor} %Defining a colour % \definecolor{ared}{HTML}{BF0000} \renewcommand\colorchapnum{\color{ared}} ...


1

Here's the fix using your existing fancy interface, rather than the home-brew concoction of my other answer. Let me show the changes: Initializations: \def\thumbnew{} \def\thumbold{} If there are no new thumbs on a page, use the last of the old thumbs \usepackage{everypage} \AddEverypageHook{\if\relax\thumbnew\relax\xdef\thumbnew{\thumbold}\fi} Here ...



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