Tengo la siguiente estructura de directorios:
main.tex
chapter/
chapter1.tex
img/
image.svg
Este es el contenido de main.tex
:
\documentclass{report}
\usepackage{svg}
\begin{document}
\import{chapter/}{chapter1}
\end{document}
Esto es chapter/chapter1.tex
:
\begin{figure}
\centering
\includesvg[width=0.7\textwidth, svgpath = img/]{image}
\caption{Caption}
\end{figure}
¿Cómo utilizar el paquete de importación para mantener referencias de rutas relativas en subarchivos y al mismo tiempo utilizar archivos svg?
Si uso svg en un archivo principal y no en un subarchivo, se genera correctamente.
Respuesta1
Añadiendo
\makeatletter
\svgpath{{\input@path/img/}}
\makeatother
al inicio de chapter1.tex
las obras.