
Eu uso meus carros alegóricos com [h]
. Quando eu uso este comando:
\setlength{\intextsep}{0pt plus 0pt minus 0pt}
ele define a separação entre o texto acima e a figura como 0, mas não entre a figura e o parágrafo posterior. Tentei também não mudar nada e carregar o parskip
pacote. Não funcionou. Já vi muitas perguntas sobre esse assunto, mas nenhuma resposta real... Minhas figuras não estão bem centralizadas entre o texto...
\documentclass[11pt,a4paper,addpoints]{exam}
\unframedsolutions
%\printanswers
\usepackage{tikz}
\usepackage{graphicx}
\usepackage{geometry}
\usepackage{calc}
\usepackage{blindtext}
\newgeometry{left=2cm,top=2cm,right=2cm,bottom=2cm}
\begin{document}
\begin{questions}
This is the upper paragraph which has less space between this text and lower figure.
\begin{figure*}[h]
\begin{tikzpicture}[rounded corners=5mm]
\path node[rectangle,draw=green,fill=green!8,inner sep=.70cm] {\parbox{\textwidth-1.4cm-\fboxrule}{
\question[2] What is the first question?
\begin{solutionorlines}[4cm]
This box is smaller than when the solutions are not printed. How do I make this the same dimension as when answers are not printed?
\end{solutionorlines}
}};
\end{tikzpicture}
\end{figure*}
This is the lower paragraph which has more space between this text and above figure.
\end{questions}
\end{document}
Responder1
Especulando sem MWE, mas vamos lá...
Se você definir \intextsep
como zero, ainda terá um espaço entre linhas após sua figura. Você pode suprimir isso configurando \prevdepth
para -1000pt
(veja o capítulo 15 doTeX por tópico).
\documentclass{article}
\usepackage{lipsum}
\setlength\intextsep{0pt plus 0pt minus 0pt}
\begin{document}
\lipsum[1]
\begin{figure}[h]
\rule{4cm}{4cm}
\end{figure}
\prevdepth=-1000pt
\lipsum[2]
\end{document}
É difícil pensar em uma boa razão para fazer isso.