如何使用 gb4e 不間斷地放置兩個範例?

如何使用 gb4e 不間斷地放置兩個範例?

我想問一下語言學中的編號範例。我使用 gb4e 作為編號範例,使用森林作為語法樹。我的問題是如何將兩個語法樹排成一行。我想得到以下結果。

理想的結果

然而,為了接收這個結構,我並沒有使用gb4e。這意味著a.和b。圖中是直接用腳本寫的。

以下是該腳本的腳本。

\begin{exe}
\ex syntactic tree \\
        a. \begin{forest} 
[VP
    [DP]
    [V’
        [V]
        [DP]
    ]
]
    \end{forest} \hspace{4ex}
    b. \begin{forest} 
[VP
    [DP]
    [V’
        [V]
        [DP]
    ]
]
    \end{forest} \\
    c. \begin{forest} 
[VP
    [DP]
    [V’
        [V]
        [DP]
    ]
]
    \end{forest}

\end{exe}

當我在這個結構中引入編號代碼時,我無法得到上圖。我想做的是將兩個語法樹如圖所示不間斷地放置。以下是我從程式碼中得到的程式碼和結果。

不良例子

   \begin{exe}
    \ex derivation of tree
        \begin{xlist}
        \ex \begin{forest}
    [VP
        [DP]
        [V’
            [V]
            [DP]
        ]
    ]    
        \end{forest}
        \quad
        \ex \begin{forest}
    [VP
        [DP]
        [V’
            [V]
            [DP]
        ]
    ]    
        \end{forest}


        \end{xlist}
    \end{exe}

如果您對如何實現理想的想法有想法,您能告訴我這個想法嗎?

謝謝。

答案1

您可以使用該multicol套件將(小)樹和範例並排放置。

另一種解決方案請參閱:

\usepackage{gb4e}
\begin{document}
\begin{exe}
\ex syntactic tree
\begin{xlist}
\begin{multicols}{2}
\ex\begin{forest} 
[VP
    [DP]
    [V’
        [V]
        [DP]
    ]
]
\end{forest}
\ex
\begin{forest} 
[VP
    [DP]
    [V’
        [V]
        [DP]
    ]
]
\end{forest}
\end{multicols}
\ex\begin{forest} 
[VP
    [DP]
    [V’
        [V]
        [DP]
    ]
]
\end{forest}
\end{xlist}
\end{exe}
\end{document}

程式碼的輸出

相關內容