# Tag Info

0

The package option margins is causing the problem as the track changes are written as margin notes. This is not possible for floats. Hence, if you remove the option margin the first problem will be fixed. The third figures is also causing the problem. I have now removed third figure and changed package option to inline get your MWE generate the PDF. \...

0

I encountered the same problem – in my case \clearpage \thispagestyle{empty} did the trick.

2

uncomment your \makebox %\makebox[\figurewidth][c]{ but change the specified width to 0pt instead of \figurewidth

0

since your figure is wider than the text width, you want to make it look to latex like it is narrower. here's one possibility (just the group with the figure): \noindent\hss \begingroup \fontsize{8}{\baselinestretch}\selectfont \input{VoltFRFFreq.tikz} \endgroup \hss\par

0

You can use afterpage to perform some magic between page shipouts: \documentclass{article} \usepackage{graphicx,float} \usepackage{afterpage} \usepackage{showframe,lipsum}% Just for this example \begin{document} \section{First section}\lipsum[1-3] \afterpage{ \begin{figure}[H] \centering \includegraphics[width=.8\textwidth,height=.8\...

6

The caption2 package offers \captionlabelfalse for this purpose: \documentclass{article} \usepackage{caption2} \begin{document} \begin{figure} \centering \Large A \captionlabelfalse % don't show the caption label \caption{A figure} \addtocounter{figure}{-1} % correct figure counter \end{figure} \begin{figure} \centering \Large B \caption{...

4

This is more of an answer to a comment, but it was too long to write there. It is based on the code in jon's answer. It creates a new counter. I am sure this can be done in one of the existing packages, but this works without any. A new environment is created (figCaption), mostly not to keep writing the same thing for every figure. Within it, it just ...

2

Heed the warning of caption2: Package: caption2 2015/09/15 v2.2-100 Customising captions (AR) Package caption2 Warning: **************************************************** (caption2) THIS PACKAGE IS OBSOLETE: (caption2) This package attempts to provide an caption2' (caption2) package v2.0/2.1 author ...

5


2

Use \floatsetup{captionskip=…}: \documentclass{book} \usepackage{graphicx} \usepackage{floatrow} \usepackage{caption} \captionsetup{ slc=false, } \begin{document} \begin{figure} \floatsetup{captionskip=2cm} \ffigbox[\FBwidth] {\caption{Caption goes here.}} {\includegraphics{example-image-a}} \end{figure} \end{document}...

1

The relevant LaTeX parameters are: \intextsep: the space between text and floats in the running text \textfloatsep: the space between a float at the top of the page and the text, also the space below text and a float at the bottom of the page \floatsep: the space between to consecutive floats Thus you should be adjusting the first two of these parameters....

2

I recommend the following \begin{figure}[h] \centering \includegraphics[width=0.495\textwidth]{figure1} \includegraphics[width=0.495\textwidth]{figure2} \caption{Side by side figures.} \label{fig:sidebyside} \end{figure} This creates two side by side figures. Note that the width has to be set to a values slightly less that width=0.5\...

2

An alternative approach using tabularand \captionof from thecaption-package. I do not really like using tabulars for this, but it works. You can then align the images and caption individually. Output Code \documentclass{article} \usepackage{graphicx} \usepackage{array} \usepackage{caption} \begin{document} \begin{tabular}{m{4cm}m{6cm}} \...

3

You may wish to move the content into place for the smaller image. To do so, place the larger image inside a box - \imagebox - so you can measure its height: \documentclass{article} \usepackage{graphicx} \newsavebox{\imagebox} \begin{document} \begin{figure} \savebox{\imagebox}{\includegraphics[width=.45\linewidth]{example-image-9x16}}% \begin{...

3

Add [b] to minipages, it will vertically align them to the bottom. \begin{minipage}[b]{.45\linewidth} As pointed out by Mico, there is no use for \centering here. Output Code \documentclass{article} \usepackage{graphicx} \begin{document} \begin{figure}[h] \begin{minipage}[b]{.45\linewidth} \includegraphics[width=.5\...

1

In your example code you have \newsubfloat{figure} behind \usepackage{hyperref}. This is correct and compile without warnings. But in your screenshot you have \newsubfloat{figure} before \usepackage{hyperref}, and this leads to the warning as now hyperref can't patch the subfloat.

1

Apart from the usefulness of minipage here, there are two errors: \begin{minipage}{10cm} (or any other width), but the width was missing here (in both minipage usages) -- this will to a syntactical error. The \label must be placed within the minipage, not outside -- this is because \label reuses the \@currentlabel macro which is a \protected@edefined macro ...

3

The log file contains a warning: Class scrreprt Warning: \float@listhead detected! (scrreprt) Implementation of \float@listhead became (scrreprt) deprecated in KOMA-Script v3.01 2008/11/14 and (scrreprt) has been replaced by several more flexible (scrreprt) features of package tocbasic. (scrreprt) ...

1

The standard behavior of \paragraph is to print the heading in-line. If you want a line break after the heading, type \paragraph{Fremdschlüssel}\mbox{}\\* \includegraphics[width=0.4\textwidth]{Resources/Included Graphics/foreign_keys_example.png}

1

I would say you are looking for the package overpic, but as there are already many examples of this package in TeX.SX, just a different poor's man solution: overlap two minipages. \documentclass{article} \usepackage{graphicx,capt-of,lipsum,xcolor} \parskip1em\fboxsep1em \begin{document} \lipsum[2] \hfil\fbox{ \rlap{\begin{minipage}[c][5cm][c]{5cm} ...

3

It depends on how you want the references to be printed. If you want that the reference to figure or table 7–1 is printed as “7.1”, here's a possibility: \documentclass{book} \usepackage{graphicx} \usepackage{caption} \makeatletter \DeclareCaptionLabelFormat{pcdn}{% Prefix Chapter Dash Number \MakeUppercase{#1} P\arabic{chapter}--\arabic{\@captype}% } \...

3

Here is an example with a very simple tcolorbox setup: In principle, the tcolorbox can 'conquer' the figure environment and blend into, this would mean, that the caption is at the top and displayed as the the title of the box. \documentclass{article} \usepackage{graphicx} \usepackage{caption} \usepackage[most]{tcolorbox} \newtcolorbox{annotatedbox}[1][...

1

That's because tikzfigure doesn't use \caption. \renewenvironment{tikzfigure}[1][]{ \def \rememberparameter{#1} \vspace{10pt} \refstepcounter{figurecounter} \begin{center} }{ \ifx\rememberparameter\@empty \else %nothing \\[10pt] %{\small Fig.~\thefigurecounter: \rememberparameter} {\small \rememberparameter} \fi \end{...

1

First, as a man who has been typesetting French documents in France, I strongly recommend using direct Unicode input of your accented chars. Instead of \c ca br\^ ule, write ça brûle as usually; you have \usepackage[utf8]{inputenc} on your side! Second, for an MWE, get rid of all those extra packages. See if any of them is causing trouble. For example, ...

0

Try placing \label inside the caption: \begin{table} \caption{\label{t:1} Tabe caption.} \begin{tabular}{c c} a & b\ \ c& d\ \ \end{tabular} \end{table} Worked for me for statsoc document class.

6

EDIT -- After posting the code below, I worked on it some more and got rid of some of the ugliness. Rather than continuing to update this answer, I made a project on github: https://github.com/bcrowell/timetravel Below is the code for a proof-of-concept implementation of this idea. The good news: It accomplishes what I wanted to do for this application. ...

1

Thanks to Axel Sommerfeldt's solution to a similar issue described in Compatibility issue with \renewenvironment{figure} and [H] placement I was able to solve the problem by patching \float@endH from the float package as well. \documentclass[]{article} \usepackage{mwe} \usepackage{changepage} \usepackage{float} \makeatletter \newenvironment{shiftedfloat}[...

0


2

Almost the same as Zarko's solution. I slightly enlarged the left-hand minipage, and suppressed both {} on both sides of the tables, but used a cropped \cmidrule instead of \midrule. Also, palatino is obsolete, as it modifies only the text font, andd cmmaths are still used, which is ugly with palatino text. So I replaced it with mathpazo(cf. the l2tabu ...

3

Like this: For above picture you need enlarge width of the first \minipage that the caption can be placed in one line only ... In complete code below I made some small changes in comparison to your MWE. For the first table is used tabularx. With it I got better looks of tables and respective captions. \documentclass[12pt,a4paper]{report} \usepackage[...

3

Last but not least a solution which tries to patch the endfloat package as less as possible: \documentclass{article} \usepackage{graphicx} \usepackage{mwe} \newcommand{\addfig}[1]{% \begin{figure}[htbp] % when float environment is included here \centering \includegraphics[width=\textwidth]{#1} \end{figure} } \usepackage{endfloat}[2011/12/25] % we ...

4

The problem lives in the code of the float package: If the placement [H] is used, \endfigure will be redefined locally with no respect on the original definition of \endfigure: \def\@float@HH#1[H]{% % Locally redefine the end of the environment. \expandafter\let\csname end#1\endcsname\float@endH ... As consequence the following code compiles fine, ...

1

I discovered that using a minipage appears to work a few hours after posting. \newenvironment{smallbox}[1][p]{% \begin{boxe}[#1] \begin{minipage}[c][\textheight]{\linewidth} }{\end{minipage}\end{boxe}}

1

Here's a solution based on Werner's answer but which does away with the use of endfloat altogether. Once we are writing the figures to an external file anyhow, there doesn't seem much need for endfloat as we can just read the figures in from the file at the end of the document. It happens to use the expl3 syntax, but that is really by-the-by. expl3 doesn't ...

3

Here's one approach that writes each figure used in the command form \addfig[<opts>]{<image>} to a file tmpfig.tex and then immediately reads in that file: \documentclass{article} \usepackage{graphicx,newfile,endfloat} \newoutputstream{tmpimg} \newcommand{\addfig}[2][width=\textwidth]{% \openoutputfile{tmpfig.tex}{tmpimg}% Open tmpfig.tex ...

5

Load the lastpage package and then redefine the footer or \@totpages to use \pageref{LastPage}. The lastpage package tries very hard to get the correct last page number even if there are pending floats and so is much more reliable than most manual solutions.

3

Well, your question is not clear because you say need not to be bold Anyways, I am answering both. If you want to have bold label then simply use \usepackage[labelfont=bf]{caption} However if you want to have label and cation both bold, use \usepackage[textfont=bf, labelfont =bf]{caption} The above set up will make changes to both figure ...

3

Almost right:-) But figure* always comes the page after it appears in the source so you can't do this on the first page (if you need that you need to do something a bit trickier) and you need \noindent to avoid a paragraph indentation making your full width tables not fit on a line. \documentclass[twocolumn]{article} \usepackage{tabularx} \usepackage{...

3

Normally the end of line after \end{figure} doesn't produce a visible space. Actually, the code will carry on a possible white space coming from before the environment, adding a normal space if figure starts in paragraph mode and there was no space before \begin{figure}. So Before\begin{figure} <code> \end{figure} Test will produce a regular ...

0

Well, if I understand you right, you have to change your \begin{minipage}{.5\textwidth} to \begin{minipage}{.5\textheight}, because you used environment landscape. This means that now the given textheight of your document becomes the width of the new typing area ... I show it to you in the following mwe (please see I added an command \fbox in your subfile ...

1

Counters only accept integers values, so try this: \setcounter{chapter}{2} \setcounter{section}{3} \section{Your Headline} % This is section 2.4 Or \setcounter{chapter}{2} \setcounter{section}{2} \section{Your Headline} % This is section 2.3

1

This is not really an actual solution but more of a workaround. Instead of copying the image into its Float Figure container, I use the Insert graphics tab beneath the menu bar. A more definite solution was to reinstall lyx (make sure you save the files you've been working on before; do not leave anything in the default working directories).

1

\scriptsize may work for you: it is between \tiny and \footnotesize (from https://www.sharelatex.com/learn/Font_sizes,_families,_and_styles) Hope this helps :)

0

I see now. It is the subcaption that increases the counter every time, thanks for pointing that out, Christian. Embedding the \subcaption command in a group or minipage or changing it as Werner suggested did resolve the warning for "subcaption our of box", however the numbering issue remained. The solution for me was to not use the \subcaption command at ...

3

As Christian already mentioned, \subcaption has to be placed inside a group (or a box) since it's very much \caption and therefore interferes with the specific caption type counter. To see how this is a problem, use \subcaption before \caption inside one of your figures. Depending on the spread of your current non-grouped used of \subcaption, one can fix ...

5

The error is the usage of \subcaption* outside its own box or environment. The subcaption manual explicitly states that \subcaption needs a box or an environment, i.e. \begin{table} \begin{minipage}{0.4\textwidth} % some content \subcaption{Foo} \end{minipage} \end{table} In principle, it's better to use the subfigure and subtable environments ...

1

You can use a key-value system, for instance expl3. \documentclass{article} \usepackage{xparse} \ExplSyntaxOn \NewDocumentCommand{\archietable}{m} { \begin{table}[htp] \centering \keys_set:nn { archie/table } { #1 } \begin{tabular}{|l|l|l|} \hline STATIC & STATIC & STATIC \\ \hline STATIC & \l_archie_table_XA_tl & \...

3

Here I do it with left-aligned \Longunderstacks. \documentclass{article} \usepackage{graphicx,stackengine} \setstackEOL{/} \setstackgap{L}{\normalbaselineskip} \strutlongstacks{T} \begin{document} \begin{table} \renewcommand{\arraystretch}{1.2} \centering \setlength\tabcolsep{0.5em} \scalebox{0.84} { \begin{tabular}{|l|l|l|} \hline Items & Type & ...

4

I have here added a solution without multirow, and edited the code with some more common practices in LaTeX, generally acknowledged as a more professional look, and easier to read. This solution uses booktabs, and the advice contained in that documentation to never use vertical lines, and also some horizontal lines with different widths. The scaleboxshould ...

0

In your code, once you've entered a minipage, the widths become \linewidth, not 0.48\linewidth: \documentclass[]{article} \usepackage[showframe]{geometry} \usepackage{graphicx} % Grafikpaket (ermöglicht unter anderem das Einbinden von .jpg-Bildern) \usepackage{subcaption} \usepackage{psfrag} \usepackage{lscape} \usepackage{color} % Color Paket wird ...

Top 50 recent answers are included