Hot answers tagged

8

Well, it seems there is a bug (or is it a feature?) in your used class IEEEtran. Or it results in the using of package subfigure, which called package caption. And that package caption results in the following warning you should not oversee: Package caption Info: Unknown document class (or package), (caption) standard defaults will be used. ) ...


6

A stackengine approach, with scalerel for handling the change in math style size. REVISED ANSWER This can present nicely in all math styles and corrects the issue with my alternate solutions that the drop of a subscript is not uniform but depends on the letter height. For this application, that is not a helpful feature. \documentclass{article} ...


6

From the class documentation The LaTeX float placement commands [htbp] are intentionally disabled. Layout of figures and tables will be adjusted by the publisher during the production process, so authors should not concern themselves with placement to avoid disappointment and wasted effort. Ideally the optional argument would still be defined, ...


5

Here is a solution with wrapfigure. I replaced the items of a description environment (wrapfigure won't work) with a special formatting of \paragraph with the titlesec package, in order to mimick the layoout of a description environment: \documentclass[a4paper]{article} \usepackage[utf8]{inputenc} \usepackage{fourier, erewhon} ...


4

Here's a version that uses a few additional \raisebox and \scalebox instructions to place the letters "b" and "c". \documentclass{article} \usepackage{graphicx} \usepackage{amsmath} \newcommand{\ca}[1]{\operatornamewithlimits{\mathpalette\cb{#1}}} \newcommand{\cb}[2]{{% \vphantom{\triangle}% \ooalign{$#1\triangle$\cr\hidewidth\cc{$#1#2$}\hidewidth\cr ...


4

The solution in this case is easier than using absolute positioning on beamer. As both graphics are similar in size, except for the left label, you can include this long label in first graphic as a \phantom text. This way is not printed but the corresponding space is preserved, both graphics have same width and both will be centered on same slide position. ...


3

With a light (local) squeezing of the space between columns and some additional negative spacing where appropriate. I removed the wrong \quad spaces you are using. \documentclass[10pt,a4paper,titlepage]{book} \usepackage[paperwidth=165mm, paperheight=238mm, left=2.5cm,right=2cm,top=2cm,bottom=2cm]{geometry} \usepackage[graphicx]{realboxes} ...


3

First and most important: never use eqnarray for any reason whatsoever. Second: never leave a blank line before a display. Third: LaTeX doesn't force anybody to use \left and \right in front of each parenthesis or bracket; if your editor does it automatically, disable the feature. Fourth: from the chosen breaks, I guess you're writing in a two column ...


3

This is not a bug, in fact the behavior is (indirectly) documented in the manual: The between origins option can only be used for columns mentioned in the first row, that is, you cannot specify this option for columns introduced only in later rows. (Section 20.3.2 Setting and Adjusting Column and Row Spacing) In your matrix you only have one column ...


3

add \usepackage{flafter} which is part of the base latex distribution and changes the definition of t not to allow t on the page on which the figure appears in the source, so that floats never go backwards.


3

Package placins and \FloatBarrier might be of use here! \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{graphicx} \usepackage{listings} \usepackage{color} \usepackage{courier} \usepackage{placeins} \usepackage{longtable,geometry} \definecolor{Gray}{gray}{0.95} \setlength\parindent{0pt} % Uncomment to remove all indentation from paragraphs ...


2

You can use \clearpage before the listing to flush any floats.


2

No mdframed based solution, but using tcolorbox and an automatic \mbox{} and some vertical upshift. The \tcolorboxenvironment is basically the same what \surroundwithmdframed does. \documentclass[12pt]{article} %\usepackage{mdframed} %\usepackage{enumitem} \usepackage[most]{tcolorbox} \usepackage[T1]{fontenc} \usepackage{fouriernc} ...


2

This is a standard latex warning. You get it e.g. when you use \begin{figure}[] or \begin{table}[]: LaTeX Warning: No positions in optional float specifier. Default added (so using `tbp') on input line 9. And as latex adds a line number it should be easy to find.


2

Here's a way of making the \fakefigure macro suggested in the question work. Well, at least it survives minimal testing in combination with Werner's answer on absolute placement. The proposed redefinition of \caption won't work because capt-of defines \captionof in terms of \caption. However, it is possible to first save the definition of \caption and then ...


2

If I understand what you're looking for, you may want to pursue the following approach: Using the facilities of your text editor, globally replace all instances of \begin{figure} with \par\noindent\begin{minipage}{\textwidth}% globally replace all instances of \end{figure} with \end{minipage} and globally replace all instances of figure-related ...


2

You could try the following. Note that this relies on an experimental package and so cannot be guaranteed as future-proof. To avoid the experimental package, you could use the underlying stuff provided by the LaTeX 3 kernel development since the equivalent programming functions are not marked as experimental - only the user-level interface which I use here. ...


2

First of all: I kicked some (but not all) packages out that are not related to the problem. I could not reproduce the blank page issue The ToC title can be shifted upwards with \setlength{\cftbeforetoctitleskip}{0pt} for example (this requires tocloft package) The ToC title font size (and other features) can be set with ...


1

You can use just one tikzpicture, and move each part around with a scope environment and some shifts. \documentclass{standalone} \usepackage{tikz} \begin{document} \begin{tikzpicture}[scale=3,>=latex, font=\sffamily] \draw [->](0,0) -- (0,1) node[at end, above left, rotate=90] {engine output}; \draw [->](0,0) -- (1,0) node[at end, below left] ...


1

Page 10 of the manual, use the varwidth option. \documentclass[varwidth]{standalone} \usepackage{tikz} \begin{document} \begin{tikzpicture}[scale=3,>=latex, font=\sffamily] \draw [->](0,0) -- (0,1) node[at end, above left, rotate=90] {engine output}; \draw [->](0,0) -- (1,0) node[at end, below left] {pedal input}; \draw [-](0,0) -- (0.8,0.8); ...


1

I have rebuilt your code from scratch (but using your colors, font sizes, etc.) solely in Tikz. The code is shorter and easier to maintain in some cases. There are very minor differences in positions, but I tried to replicate your own as close as I could I have wrapped everything in a newcommand \mytitlepage with 5 arguments: \mytitlepage{ <title> }{ ...


1

use the optional argument float: \lstinputlisting[language=php,caption={PHP code snippet A}, float, label=listing:codeA.php]{./codeA.php}


1

I don't think the package provides for line breaks; you can add them as follows. \documentclass[draft,dutch]{article} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{babel} \usepackage{geometry} \geometry{tmargin=2.5cm,bmargin=2.5cm,lmargin=2.5cm,rmargin=2.5cm} \usepackage{backnaur} \newenvironment{bnfsplit}[1][0.7\textwidth] ...


1

This method works here since both graphs have the same right-side limit. Graphs with the same left-side limit could be dealt with by eliminating the \llap. However, this approach will not intrinsically work if one graph has extra stuff off to both the left and right. It works with the atbegshi package to overlay something over the graph at a specified ...


1

You are introducing some spurious white-space after the opening brace before including the image. It should be: % arara: pdflatex \documentclass{article} \usepackage[demo]{graphicx} \usepackage{subfig} \usepackage{blindtext} \begin{document} \begin{figure} \centering \includegraphics[width=\textwidth,height=0.1\textwidth]{dummy.pdf} ...



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