1

I have more sequences of the image with the text between there, from this post I resolve the problem of the withe space but now I have too a little space from the image.

I want to add the space upper and down Image, is it possible?

this is the problem

enter image description here

This is my example

\documentclass[11pt]{toptesi}


\usepackage[utf8]{inputenc}
\usepackage[italian]{babel}
\usepackage{lipsum,caption,graphicx}


\begin{document}

L’operatore OP\_2 verifica che nello stack ci siano 2 elementi, successivamente vengono inserite le tre chiavi pubbliche, ottenendo così uno stato come in Figura \ref{fig:stackmultsing02}.

{\centering
\includegraphics[scale=0.35]{images/script/multisig/2.png}
\captionof{figure}{Stato dello stack dopo la verifica con OP\_2 e l’inserimento nello stack delle chiavi pubbliche.\label{fig:stackmultsing02}}
\par}

Infine le firme vengono verificate con le chiavi pubbliche mediante l’operatore OP\_CHECKMULTISIG in maniera iterativa, cioè la prima firma viene confrontata con tutte le chiavi pubbliche e l’azione si ripete per tutte le firme inserite, come in Figura \ref{fig:stackmultsing03}.

{\centering
\includegraphics[scale=0.35]{images/script/multisig/3.png}
\captionof{figure}{Esecuzione dell’operatore OP\_CHECKMULTISIG per la verifica delle chiavi \cite{learnmeabitcoin:p2ms}.\label{fig:stackmultsing03}}
\par}

\subsection{P2SH}
Lo script {\it pay-to-script-hash \/} venne introdotto nel 2012, per semplificare l’uso degli script in transazioni complesse: infatti molto spesso accade di avere script molto grandi, come uno script P2MS 14:15 che comporta un aumento della complessità dello script di sblocco; la motivazione dell’introduzione dello script P2SH è stata la semplificazione di quest’ultimo, come se fosse un normale pagamento ad un indirizzo Bitcoin.
Questa nuova tipologia semplifica notevolmente lo script di blocco, perché sarà popolato solo dal suo hash, a discapito però dell’aggiunta di una copia dello script di blocco all’interno dello script di sblocco. Si considere, ad esempio il seguente script P2SH:
 \end{document}

1 Answers1

2

The OP, on another thread, invited me to comment/answer.

Normally, one can use the center environment. However, the OP seemed, for reasons that are not wholly clear, to prefer the \centering approach with a specified space manually added.

Thanks to Zarko for pointing to another thread for other (likely prefereable) ways to deal with this issue, How to change the spacing between figures/tables and text?

Here, I just create a macro \mygap which can be judiciously added after \centering and/or before the closing \par for additional vertical space.

\documentclass[11pt]{toptesi}


\usepackage[utf8]{inputenc}
\usepackage[italian]{babel}
\usepackage{lipsum,caption,graphicx}
\newcommand\mygap{\vspace{10pt}}

\begin{document}

L’operatore OP\_2 verifica che nello stack ci siano 2 elementi, successivamente vengono inserite le tre chiavi pubbliche, ottenendo così uno stato come in Figura \ref{fig:stackmultsing02}.

{\centering\mygap
\includegraphics[scale=0.35]{example-image}
\captionof{figure}{Stato dello stack dopo la verifica con OP\_2 e l’inserimento nello stack delle chiavi pubbliche.\label{fig:stackmultsing02}}
\mygap\par}

Infine le firme vengono verificate con le chiavi pubbliche mediante l’operatore OP\_CHECKMULTISIG in maniera iterativa, cioè la prima firma viene confrontata con tutte le chiavi pubbliche e l’azione si ripete per tutte le firme inserite, come in Figura \ref{fig:stackmultsing03}.

{\centering\mygap
\includegraphics[scale=0.35]{example-image-a}
\captionof{figure}{Esecuzione dell’operatore OP\_CHECKMULTISIG per la verifica delle chiavi \cite{learnmeabitcoin:p2ms}.\label{fig:stackmultsing03}}
\mygap\par}

\subsection{P2SH}
Lo script {\it pay-to-script-hash \/} venne introdotto nel 2012, per semplificare l’uso degli script in transazioni complesse: infatti molto spesso accade di avere script molto grandi, come uno script P2MS 14:15 che comporta un aumento della complessità dello script di sblocco; la motivazione dell’introduzione dello script P2SH è stata la semplificazione di quest’ultimo, come se fosse un normale pagamento ad un indirizzo Bitcoin.
Questa nuova tipologia semplifica notevolmente lo script di blocco, perché sarà popolato solo dal suo hash, a discapito però dell’aggiunta di una copia dello script di blocco all’interno dello script di sblocco. Si considere, ad esempio il seguente script P2SH:
 \end{document}

enter image description here

  • Why not simply use \begin{center} \includegraphics[scale=0.35]{example-image-a}\captionof{figure}{Esecuzione dell’operatore OP\_CHECKMULTISIG per la verifica delle chiavi \cite{learnmeabitcoin:p2ms}.\label{fig:stackmultsing03}}\end{center}? – Zarko Oct 09 '19 at 17:55
  • Thanks fot this – vincenzopalazzo Oct 09 '19 at 17:55
  • @Zarko The thread where I was contacted was specifically about eliminating vertical space and thus to not use the center environment. Why the OP prefers this approach, I am not sure, but it may be related to how much vertical space he desires. Not sure. – Steven B. Segletes Oct 09 '19 at 17:57
  • @Zarko I have edited to discuss the issue a little. – Steven B. Segletes Oct 09 '19 at 17:59
  • @StevenB.Segletes, I must confess that I do not understood OP question. To me it is unclear. It seems to me that (s)he want to invent a wheel again. I would rather stick with figure float and than consider https://tex.stackexchange.com/questions/26521/how-to-change-the-spacing-between-figures-tables-and-text . – Zarko Oct 09 '19 at 18:07
  • @Zarko I think I can interpret why the OP rejects the figure approach. Based on his words, "I have them with space dead in all my files" I take that to mean that the figure environment introduces an unacceptable amount of vertical "dead space" into the document. – Steven B. Segletes Oct 09 '19 at 18:09
  • @StevenB.Segletes, well, this can be handled as explained in given link in my previous comment. However, OP accept your answer :-), so all my comments are now irrelevant :-( – Zarko Oct 09 '19 at 18:12