Skip to content

Commit

Permalink
fixed language detection for lacalizables
Browse files Browse the repository at this point in the history
  • Loading branch information
jemmybutton committed May 31, 2024
1 parent 60231fd commit 42f3d71
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 36 deletions.
2 changes: 1 addition & 1 deletion byrne-ru-latex.tex
Original file line number Diff line number Diff line change
Expand Up @@ -1403,7 +1403,7 @@ \chapter*{Предложения}
stopTempAngleScale;
stopAutoLabeling;
}\\
получим $\drawUnitLine{AB,BD} = \drawUnitLine{AC,CE}$ (конст.),\\
получим $\drawUnitLine{AB,BD} = \drawUnitLine{AC,CE}$ \byref{\constref},\\
\drawAngle{BAC} общий обоим,\\
и $\drawUnitLine{AB} = \drawUnitLine{AC}$ \byref{\hypref}.

Expand Down
65 changes: 30 additions & 35 deletions byrnebook.cls
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,6 @@
%\advance \oddpict by \textwidth
%\advance \oddpict by -\pictureIndent


\newwrite \lettrineslist
\openout \lettrineslist = lettrines/lettrineslist.txt\relax

Expand Down Expand Up @@ -311,16 +310,11 @@
\fi%
}




\def\qedNB{\hfill\qedstr\vskip 10pt}
\def\qed{\qedNB\vfill\pagebreak}
\def\qefNB{\hfill\qefstr\vskip 10pt}
\def\qef{\qefNB\vfill\pagebreak}



\def\symb#1{\noindent{#1}\quad}

% tabular horizontal spacing
Expand Down Expand Up @@ -581,32 +575,9 @@
\newcommand*\l@propositionAZ{\@dottedtocline{1}{1.5em}{2.3em}}

%
% Other
%

\newcommand\byref[1]{(\zcref{#1})}
\newcommand\charspacing[2]{\addfontfeature{LetterSpace=#1} #2 \addfontfeature{LetterSpace=0}}

\emergencystretch 3em

\newcommand\margincomment[1]{\marginnote{\footnotesize #1}}

%
% Localizables
% zref-clever definitions
%

\def\qedstr{Q. E. D.}
\def\qefstr{Q. E. F.}
\def\hypstr{hyp.}
\def\conststr{const.}

\def\inpropstr{pr.}
\def\inpoststr{post.}
\def\indefstr{def.}
\def\inaxstr{ax.}

\def\bookString{Book}

\zcLanguageSetup{english}{
type = axiom ,
Name-sg = Axiom ,
Expand Down Expand Up @@ -873,7 +844,6 @@
name-pl-ab = пр. ,
}


\zcRefTypeSetup{hypothesis}{
Name-sg = ,
name-sg = ,
Expand All @@ -888,8 +858,34 @@
name-pl = ,
}

\AtBeginDocument{
\@ifpackagewith{babel}{russian}{%
%
% Other
%

\newcommand\byref[1]{(\zcref{#1})}
\newcommand\charspacing[2]{\addfontfeature{LetterSpace=#1} #2 \addfontfeature{LetterSpace=0}}

\emergencystretch 3em

\newcommand\margincomment[1]{\marginnote{\footnotesize #1}}

%
% Localizables
%

\def\qedstr{Q. E. D.}
\def\qefstr{Q. E. F.}
\def\hypstr{hyp.}
\def\conststr{const.}

\def\inpropstr{pr.}
\def\inpoststr{post.}
\def\indefstr{def.}
\def\inaxstr{ax.}

\def\bookString{Book}

\iflanguage{russian}{
\def\qedstr{Ч. Т. Д.}%
\def\qefstr{Ч. Т. Д.}%
\def\hypstr{гип.}%
Expand All @@ -899,7 +895,6 @@
\def\indefstr{опр.}%
\def\inaxstr{акс.}%
\def\bookString{Книга}%
}{}
}
}

\makeatother

0 comments on commit 42f3d71

Please sign in to comment.