\textleftarrow 및 \textrightarrow를 줄이세요.

\textleftarrow 및 \textrightarrow를 줄이세요.

\textleftarrow나는 and 가 만든 화살표를 원합니다 .\textrightarrow에서 만든 화살표를 50%와 75%로 하고더 짧은, 화살촉의 크기는 그대로 유지합니다. 수학이 아닌 환경에서 사용하고 있습니다. 그냥 일반 텍스트.

다음 게시물은 모두 수학 기반인 것 같아서 아무 소용이 없었습니다.

답변1

trimclip이를 위해 패키지를 사용할 수 있습니다 .

여기에 이미지 설명을 입력하세요

clipbox*명령은 4개 좌표로 지정된 상자 외부의 텍스트 부분을 제거합니다.

\clipbox*{{.25\width} 0pt {\width} {\height}} \textrightarrow

화살표의 오른쪽 75%가 남습니다. 비슷하게,

\clipbox*{0pt 0pt {.75\width} {\height}} \textleftarrow

화살표의 왼쪽 75%가 남습니다. 원하는 대로 조정하세요.

코드는 다음과 같습니다.

%XeLaTeX
\documentclass[11pt]{book}
\usepackage{polyglossia}
\usepackage{trimclip}

\newcommand{\shorttextrightarrow}{\clipbox*{{.25\width} 0pt {\width} {\height}} \textrightarrow}
\newcommand{\shorttextleftarrow}{\clipbox*{0pt 0pt {.75\width} {\height}} \textleftarrow}

\begin{document}

Why \textrightarrow\ can't I figure this out \textleftarrow ?

Why \shorttextrightarrow\ can't I figure this out \shorttextleftarrow ?

\end{document}

관련 정보