使用 wrapfig 环境放置图形时出现的问题

使用 wrapfig 环境放置图形时出现的问题

如图所示,我使用了 wrapfig 包。但是,我可以看到第五个点(在附图中)仅覆盖了页面宽度的一半。但不应该发生这种情况,它应该覆盖整行。我不知道我做错了什么。有什么提示吗?而且位置看起来也很糟糕,图的顶部和底部有很多空间。我还可以减少文本和图形之间的间隙吗?

\usepackage{graphicx}
\usepackage{listings}
\usepackage{wrapfig}

\begin{document}

\par The TCP/IP based communication between the client and the server is through sockets. A browser enabled with WebGL is used for the rendering process at the client side. The volume rendered is displayed on the canvas. The interaction is done on the canvas and volume is rendered and updated back to the canvas.

\begin{wrapfigure}[10]{R}{0.5\textwidth}
% \vspace{-5pt}
 \centering
  \includegraphics[width=7cm, height=8cm]{arch1sysflow.png}
 \vspace{-10pt} 
\caption{Pictorial representation of system interactions for Architecture-I}
%\vspace{-10pt}
\label{flow1}
\end{wrapfigure}

\par The system interactions flow of architecture-I is shown in Figure.~\ref{flow1}. The step by step interaction flow are given below:
\begin{enumerate}
\item The server is always listening on sockets for any client connections.
\item Downloading the volumetric dataset
\begin{enumerate}
\item User clicks the link {\lq}Downlaod Volumetric Dataset\rq.
\item The client connects to the server and requests for the dataset.
\item The server receives the request and sends the requested dataset.
\end{enumerate}
\item User loads the downloaded volumetric dataset and client renders the     volume based on initial settings.
\item Continuous canvas interaction
\begin{enumerate}
\item User interacts with the canvas continuously.
\item The client renders the volume and keeps updating the canvas with the   rendered image until the interaction stops.
\end{enumerate}
\item When user interaction stops, the client also stops rendering.
\end{enumerate}

\end{document}

在此处输入图片描述

答案1

这是一个解决方法:我使用resume*来自的键将枚举环境一分为二enumitem。我还稍微改进了嵌套枚举环境的布局:

    \documentclass{article}
    \usepackage{amsmath}
\usepackage{enumitem} \usepackage[demo]{graphicx}
\usepackage{wrapfig}


\begin{document}

\par The TCP/IP based communication between the client and the server is through sockets. A browser enabled with WebGL is used for the rendering process at the client side. The volume rendered is displayed on the canvas. The interaction is done on the canvas and volume is rendered and updated back to the canvas.

\begin{wrapfigure}[10]{R}{0.5\textwidth}
  % \vspace{-5pt}
  \centering
  \includegraphics[width=7cm, height=8cm]{arch1sysflow.png}
  \vspace{-10pt}
  \caption{Pictorial representation of system interactions for Architecture-I}
  %\vspace{-10pt}
  \label{flow1}
\end{wrapfigure}

The system interactions flow of architecture-I is shown in Figure.~\ref{flow1}. The step by step interaction flow are given below:
\begin{enumerate}
  \item The server is always listening on sockets for any client connections.
  \item Downloading the volumetric dataset
        \begin{enumerate}[wide=0pt, leftmargin=*]
          \item User clicks the link {\lq}Downlaod Volumetric Dataset\rq.
          \item The client connects to the server and requests for the dataset.
          \item The server receives the request and sends the reques\-ted dataset.
        \end{enumerate}
  \item User loads the downloaded volumetric dataset and client renders the volume based on initial settings.
\end{enumerate}

\begin{enumerate}[resume*, topsep = \itemsep]
  \item Continuous canvas interaction
        \begin{enumerate}[wide=0pt, leftmargin=*]
          \item User interacts with the canvas continuously.
          \item The client renders the volume and keeps updating the canvas with the rendered image until the interaction stops.
        \end{enumerate}
  \item When user interaction stops, the client also stops rendering.
\end{enumerate}

\end{document}

在此处输入图片描述

相关内容