断行后\hfill好像被吃掉了

2019-11-10 15:40发布

```tex \documentclass{book} \newcommand{\xz}{\hfill\mbox{\upshape(~~~~)}\\} \begin{document} \begin{...

```tex \documentclass{book} \newcommand{\xz}{\hfill\mbox{\upshape(~~~~)}\\} \begin{document} \begin{enumerate} \item[1.] sldfjaskdfklasjdflaksfdjlaksdfjklasjfdklsajfsaldfjasfdasdafsdfadfdsfaasfasdffsd\xz \item[2.] sldfjaskdfklasjdflaksfdjlaksdfjklasjfdklsajfsaldfjasfdasdafs dfadfdsfaas fasdffsddsfa\xz \end{enumerate} \end{document} ``` 我希望\xz 的括号能够自动在换行后的最右侧,像2.中的那样 ![](https://pics.latexstudio.net/data/images/201911/eaff99d316630cb.png)
1条回答
简单一点可以这样写,但是最好还是重新设计一下这个结构。 ```tex \documentclass{book} \newcommand{\xz}{\hfill\mbox{}\hfill\mbox{\upshape(\hspace{2em})}\\} \begin{document} \begin{enumerate} \item[1.] sldfjaskdfklasjdflaksfdjlaksdfjklasjfdklsajfsaldfjasfdasdafsdfadfdsfaasfasdffsd\xz \item[1.] sldfjaskdfklasjdflaksfdjlaksdfjklasjfdklsdsfaasfasdffsd\xz \item[2.] sldfjaskdfklasjdflaksfdjlaksdfjklasjfdklsajfsaldfjasfdasdafs dfadfdsfaas fasdffsddsfa\xz \end{enumerate} \end{document} ```

一周热门 更多>