\foreignlanguage 在第一个测试表中工作。 但是 \foreignlanguage 在第二个表格中不起作用。如何在表格中切换语言?
\documentclass[a4paper,14pt]{extarticle}
\usepackage[T1,T2A]{fontenc}
\usepackage[english,russian]{babel}
\usepackage{supertabular}
\usepackage{multirow}
\usepackage{makecell}
\usepackage{listings}
\input{glyphtounicode}
\pdfgentounicode=1
\usepackage{pdflscape}
\usepackage{longtable}
\usepackage{array}
\begin{document}
\begin{otherlanguage*}{english}
Work:``We will implement prudent and responsible macroeconomic policies to ensure mutually reinforcing effect of growth and to maintain economic and financial stability in the region, and prevent negative spillover effect.''
\end{otherlanguage*}
\begin{longtable}{|p{0.1\textwidth} | p{0.1\textwidth}|}
{\foreignlanguage{english}{Work: some words in english.}}& А здесь русское длинное слово. \\
5 & 6 \\
\end{longtable}
\renewcommand\theadfont{\normalsize\scshape}
\begin{landscape}
\begin{longtable}[c]{|p{0.081818\linewidth}|p{0.081818\linewidth}|p{0.081818\linewidth}|p{0.081818\linewidth}|p{0.081818\linewidth}|p{0.081818\linewidth}|p{0.081818\linewidth}|p{0.081818\linewidth}|p{0.081818\linewidth}|p{0.081818\linewidth}|}
\hline
\thead[c]{\parbox{0.081818\textwidth}{\textbf{ITF.LEV}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{\foreignlanguage{english}{TRTUTBL, c}}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{{\begin{otherlanguage}{english}TRTUTBL, c\end{otherlanguage}}}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{{\selectlanguage{english}TVTETBL, c\selectlanguage{russian}}}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{TVTUTBL, с}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{TVPCTBL, c}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{H1TBL}\textbf{, }\textbf{мор. миля}\textbf{2}\textbf{/c}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{DMODTBL, мор. миля}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{TVPETBL, с}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{TVVTT\_TBL, с}
}}\\ \hline
\endfirsthead
\hline
\thead[c]{\parbox{0.081818\textwidth}{\textbf{ITF.LEV}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{\foreignlanguage{english}{TRTUTBL, c}}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{{\begin{otherlanguage}{english}TRTUTBL, c\end{otherlanguage}}}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{{\selectlanguage{english}TVTETBL, c\selectlanguage{russian}}}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{TVTUTBL, с}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{TVPCTBL, с}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{H1TBL}\textbf{, }\textbf{мор. миля}\textbf{2}\textbf{/c}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{DMODTBL, мор. миля}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{TVPETBL, с}
}} & \thead[c]{\parbox{0.081818\textwidth}{\textbf{TVVTT\_TBL, с}
}}\\ \hline
\endhead
7
& 35
& 35
& 35
& 35
& 48
& .004
& 1.10
& 40
& 25
\\ \hline
\end{longtable}
\end{landscape}
\end{document}
答案1
您可能对以下某种布局感到满意:
\documentclass[a4paper,14pt]{extarticle}
\usepackage[T1,T2A]{fontenc}
\usepackage[english,russian]{babel}
\usepackage{makecell,rotating}
\usepackage{xltabular}
\renewcommand\theadfont{\normalsize\scshape\bfseries}
\begin{document}
\settowidth{\rotheadsize}{\bfseries DMODTBL, мор. миля\quad}
\begin{longtable}{|*{10}{c|}}
\hline
\rothead{ITF.LEV}
& \rothead{\foreignlanguage{english}{TRTUTBL, c}}
& \rothead{\begin{otherlanguage}{english}TRTUTBL, c\end{otherlanguage}}
& \rothead{\selectlanguage{english}TVTETBL, c\selectlanguage{russian}}
& \rothead{TVTUTBL, с}
& \rothead{TVPCTBL, c}
& \rothead{H1TBL, мор. миля2c}
& \rothead{DMODTBL, мор. миля}
& \rothead{TVPETBL, с}
& \rothead{TVVTT\_TBL, с}\\ \hline
\endhead
7
& 35
& 35
& 35
& 35
& 48
& .004
& 1.10
& 40
& 25
\\ \hline
\end{longtable}
\settowidth{\rotheadsize}{\bfseries TVPETBL, с\quad}
\begin{longtable}{|*{10}{c|}}
\hline
\rothead{ITF.LEV}
& \rothead{\foreignlanguage{english}{TRTUTBL, c}}
& \rothead{\begin{otherlanguage}{english}TRTUTBL, c\end{otherlanguage}}
& \rothead{\selectlanguage{english}TVTETBL, c\selectlanguage{russian}}
& \rothead{TVTUTBL, с}
& \rothead{TVPCTBL, c}
& \rothead{H1TBL, мор. миля2c}
& \rothead{DMODTBL, мор. миля}
& \rothead{TVPETBL, с}
& \rothead{TVVTT\_ TBL, с}\\ \hline
\endhead
7
& 35
& 35
& 35
& 35
& 48
& .004
& 1.10
& 40
& 25
\\ \hline
\end{longtable}
\end{document}