Portál AbcLinuxu, 10. května 2025 17:14

Dotaz: \cline v prostredi 'frame' (beamer)

2.9.2012 15:05 Jenda
\cline v prostredi 'frame' (beamer)
Přečteno: 1170×
Odpovědět | Admin
Potrebuju udelat tabulku v beameru s castecnou horizontalni linkou, tedy pouzit prikaz \cline. Na preklad cestiny pouzivam babel (mozny kamen urazu). Se \cline jsem mel v prostredi \table problemy, ktere jsem resil s \catcode`\-=12. V prostredi \frame mi to catcode ale neresi a hazi chybu "Paragraph Ended before \@cline was complete \end{frame}. Nevite co s tim? Chci prelozit tento kod s odkomentovanym \begin{frame}, \end{frame}: (takto zakomentovany mi funguje)

\documentclass{beamer}

\usepackage[utf8x]{inputenc} \usepackage{default} \usepackage[czech]{babel} \begin{document}

%\begin{frame} \begin{table}[!h] \centering \catcode`\-=12 \begin{tabular}{r c|c|c|c|c|c c r c|c|c|c|c|} \multicolumn{1}{c}{} & \multicolumn{1}{c}{} & \multicolumn{1}{c}{$c_{0}$} & \multicolumn{1}{c}{$c_{1}$} & \multicolumn{1}{c}{$c_{2}$} & \multicolumn{1}{c}{$c_{3}$} & \multicolumn{1}{c}{} & \multicolumn{1}{c}{} & \multicolumn{1}{c}{} & \multicolumn{1}{c}{} & \multicolumn{1}{c}{$c_{0}$} & \multicolumn{1}{c}{$c_{1}$} & \multicolumn{1}{c}{$c_{2}$} & \multicolumn{1}{c}{$c_{3}$}\\ \cline{3-6} \cline{11-14} & $r_{0}$ & $s_{0}$ & $s_{1}$ & & & & & & $r_{0}$ & $s_{1}$ & $s_{0}$ & & \\ \cline{3-6} \cline{11-14} $T_1=$ & $r_{1}$ & $s_{1}$ & $s_{0}$ &$s_{3}$ & $s_{2}$ & & & $T_2=$ & $r_{1}$ & $s_{0}$ & $s_{1}$ & $s_{2}$ & $s_{3}$ \\ \cline{3-6} \cline{11-14} & $r_{2}$ & & & $s_{2}$ & $s_{3}$ & & & & $r_{2}$ & & & $s_{3}$ & $s_{2}$ \\ \cline{3-6} \cline{11-14} \end{tabular} \caption{Příklad latinské záměny $(T_1,T_2)$} \label{bitrade} \end{table} %\end{frame}

\end{document}
Nástroje: Začni sledovat (0) ?Zašle upozornění na váš email při vložení nového komentáře.

Odpovědi

2.9.2012 15:16 Jenda
Rozbalit Rozbalit vše Re: \cline v prostredi 'frame' (beamer)
Odpovědět | | Sbalit | Link | Blokovat | Admin
Omlouvam se za spatne zobrazeny kod, takze vkladam jeste jednou:
\documentclass{beamer}

\usepackage[utf8x]{inputenc}
\usepackage{default}
\usepackage[czech]{babel}
\begin{document}

\vspace{10cm}
%\begin{frame}
\begin{table}[!h]
\centering
\catcode`\-=12
\begin{tabular}{r c|c|c|c|c|c c r c|c|c|c|c|}
\multicolumn{1}{c}{}
& \multicolumn{1}{c}{} & \multicolumn{1}{c}{$c_{0}$} & \multicolumn{1}{c}{$c_{1}$} & \multicolumn{1}{c}{$c_{2}$} & \multicolumn{1}{c}{$c_{3}$}
& \multicolumn{1}{c}{} & \multicolumn{1}{c}{} & \multicolumn{1}{c}{} & \multicolumn{1}{c}{} & \multicolumn{1}{c}{$c_{0}$} 
& \multicolumn{1}{c}{$c_{1}$} & \multicolumn{1}{c}{$c_{2}$} & \multicolumn{1}{c}{$c_{3}$}\\
\cline{3-6}
\cline{11-14}
& $r_{0}$ & $s_{0}$ & $s_{1}$ & & & & & & $r_{0}$ & $s_{1}$ & $s_{0}$ & & \\
\cline{3-6}
\cline{11-14}
$T_1=$ & $r_{1}$ & $s_{1}$ & $s_{0}$ &$s_{3}$ & $s_{2}$ & & & $T_2=$ & $r_{1}$ & $s_{0}$ & $s_{1}$ & $s_{2}$ & $s_{3}$ \\
\cline{3-6}
\cline{11-14}
& $r_{2}$ & & & $s_{2}$ & $s_{3}$ & & & & $r_{2}$ & & & $s_{3}$ & $s_{2}$ \\
\cline{3-6}
\cline{11-14}
\end{tabular}
\caption{Příklad latinské záměny $(T_1,T_2)$}
\label{bitrade}
\end{table}
%\end{frame}
\begin{frame}
 ghjdj
\end{frame}

\end{document}
4.9.2012 18:19 Ramwi | skóre: 2
Rozbalit Rozbalit vše Re: \cline v prostredi 'frame' (beamer)
Odpovědět | | Sbalit | Link | Blokovat | Admin
Příloha:
Ahoj, konflikt je skutečně v [czech] v babel (tedy alespoň pokavad sahá moje znalost). Zkus zaměnit \catcode... za \shorthandoff{-}, já s tímto ten dokument zkompiloval. V příloze posílám, co mi z toho vylezlo.
Jsem BFU a nestydím se za to.

Založit nové vláknoNahoru

Tiskni Sdílej: Linkuj Jaggni to Vybrali.sme.sk Google Del.icio.us Facebook

ISSN 1214-1267, (c) 1999-2007 Stickfish s.r.o.