2

I'm using the standalone package so that I can write parts of my paper separately. My appendices is structured into sections. When I compile appendices.tex it shows up as expected i.e. 1. [title] followed by the figure.
Appendices.tex compiled

But when I import it to main.tex the sections are now separated from the photos. I can't figure out how to fix it.
Main.tex compiled.

Here are my codes:

Main.tex

\documentclass{article}
\usepackage[utf8]{inputenc}

\usepackage{standalone}
\usepackage{import}
\usepackage{graphicx}
%\usepackage{appendix}

% paragraph formatting for better readability
\setlength{\parindent}{4em} % indent length starting 2nd paragraph onwards
\setlength{\parskip}{1em}  % number of lines to skip between paragraphs
\renewcommand{\baselinestretch}{1.0} % thickness of the line separating paragraphs

\title{Research Report}
\author{name}
\date{March 2021}

\begin{document}

\maketitle

\import{Sections/}{Introduction}
\import{Sections/}{Methodology}

\newpage
\appendix
\import{Sections/}{Appendices}

\end{document}

Appendices.tex

\documentclass[class=article, crop=false]{standalone}
\usepackage{import}
\usepackage{graphicx}
\graphicspath{{\subfix{Figures/Appendices}}}


% paragraph formatting for better readability
\setlength{\parindent}{4em} % indent length starting 2nd paragraph onwards
\setlength{\parskip}{1em}  % number of lines to skip between paragraphs
\renewcommand{\baselinestretch}{1.0} % thickness of the line separating paragraphs

\begin{document}


\counterwithin{figure}{section}
    \section{ Calibrate the setup}
        \begin{figure}[htbp]
            \centering
            \includegraphics[scale=0.42,keepaspectratio]{Figures/Appendices/02 Calibrate the setup.png}
            \caption{Test}
            \label{Appendix: sfdds}
        \end{figure}
        
    \section{Start the Laser}
        \begin{figure}[htbp]
            \centering
            \includegraphics[scale=0.29,keepaspectratio]{Figures/Appendices/03 Start the laser.png}
            \caption{Test}
        \end{figure}
    
    \section{Turn-off the laser}
        \begin{figure}[htbp]
            \centering
            \includegraphics[scale=0.73,keepaspectratio]{Figures/Appendices/04 Shut down the laser.png}
            \caption{Test}
        \end{figure}


\end{document}



Thanks in advance!

0

You must log in to answer this question.

Browse other questions tagged .