Обновление
This commit is contained in:
parent
ce1887a8df
commit
2c7dd2e3da
@ -10,6 +10,9 @@ $if(latex-dir-rtl)$
|
||||
\PassOptionsToPackage{RTLdocument}{bidi}
|
||||
$endif$
|
||||
$endif$
|
||||
$if(CJKmainfont)$
|
||||
\PassOptionsToPackage{space}{xeCJK}
|
||||
$endif$
|
||||
%
|
||||
\documentclass[
|
||||
$if(fontsize)$
|
||||
@ -57,7 +60,6 @@ $endfor$
|
||||
% Prevent slide breaks in the middle of a paragraph
|
||||
\widowpenalties 1 10000
|
||||
\raggedbottom
|
||||
\usepackage[defaultlines=3,all]{nowidow}
|
||||
$if(section-titles)$
|
||||
\setbeamertemplate{part page}{
|
||||
\centering
|
||||
@ -169,6 +171,12 @@ $if(CJKmainfont)$
|
||||
\fi
|
||||
$endif$
|
||||
\fi
|
||||
|
||||
\setlength{\parindent}{12.5mm}
|
||||
\usepackage[defaultlines=3,all]{nowidow}
|
||||
\usepackage[nobottomtitles]{titlesec}
|
||||
\renewcommand{\bottomtitlespace}{.15\textheight}
|
||||
|
||||
$if(beamer)$
|
||||
$if(theme)$
|
||||
\usetheme[$for(themeoptions)$$themeoptions$$sep$,$endfor$]{$theme$}
|
||||
@ -195,14 +203,15 @@ $endif$
|
||||
\usepackage[$for(microtypeoptions)$$microtypeoptions$$sep$,$endfor$]{microtype}
|
||||
\UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts
|
||||
}{}
|
||||
\usepackage{indentfirst}
|
||||
$if(indent)$
|
||||
$else$
|
||||
\makeatletter
|
||||
\@ifundefined{KOMAClassName}{% if non-KOMA class
|
||||
\IfFileExists{parskip.sty}{%
|
||||
\usepackage{parskip}
|
||||
}{% else
|
||||
\setlength{\parindent}{0pt}
|
||||
}{% else%
|
||||
\setlength{\parindent}{12.5mm}
|
||||
\setlength{\parskip}{6pt plus 2pt minus 1pt}}
|
||||
}{% if KOMA class
|
||||
\KOMAoptions{parskip=half}}
|
||||
@ -239,7 +248,7 @@ $endif$
|
||||
}
|
||||
\urlstyle{same} % disable monospaced font for URLs
|
||||
$if(verbatim-in-note)$
|
||||
\VerbatimFootnotes % allows verbatim text in footnotes
|
||||
\VerbatimFootnotes % allow verbatim text in footnotes
|
||||
$endif$
|
||||
$if(geometry)$
|
||||
\usepackage[$for(geometry)$$geometry$$sep$,$endfor$]{geometry}
|
||||
@ -262,7 +271,11 @@ $if(highlighting-macros)$
|
||||
$highlighting-macros$
|
||||
$endif$
|
||||
$if(tables)$
|
||||
\usepackage{longtable,booktabs}
|
||||
\usepackage{longtable,booktabs,array}
|
||||
$if(multirow)$
|
||||
\usepackage{multirow}
|
||||
$endif$
|
||||
\usepackage{calc} % for calculating minipage widths
|
||||
$if(beamer)$
|
||||
\usepackage{caption}
|
||||
% Make caption package work with longtable
|
||||
@ -270,6 +283,11 @@ $if(beamer)$
|
||||
\def\fnum@table{\tablename~\thetable}
|
||||
\makeatother
|
||||
$else$
|
||||
% Correct order of tables after \paragraph or \subparagraph
|
||||
\usepackage{etoolbox}
|
||||
\makeatletter
|
||||
\patchcmd\longtable{\par}{\if@noskipsec\mbox{}\fi\par}{}{}
|
||||
\makeatother
|
||||
% Allow footnotes in longtable head/foot
|
||||
\IfFileExists{footnotehyper.sty}{\usepackage{footnotehyper}}{\usepackage{footnote}}
|
||||
\makesavenoteenv{longtable}
|
||||
@ -357,6 +375,9 @@ $else$
|
||||
\usepackage[shorthands=off,russian]{babel}
|
||||
\fi
|
||||
$endif$
|
||||
\ifluatex
|
||||
\usepackage{selnolig} % disable illegal ligatures
|
||||
\fi
|
||||
$if(dir)$
|
||||
\ifxetex
|
||||
% Load bidi as late as possible as it modifies e.g. graphicx
|
||||
@ -380,6 +401,31 @@ $for(bibliography)$
|
||||
\addbibresource{$bibliography$}
|
||||
$endfor$
|
||||
$endif$
|
||||
$if(csl-refs)$
|
||||
\newlength{\cslhangindent}
|
||||
\setlength{\cslhangindent}{1.5em}
|
||||
\newlength{\csllabelwidth}
|
||||
\setlength{\csllabelwidth}{3em}
|
||||
\newenvironment{CSLReferences}[2] % #1 hanging-ident, #2 entry spacing
|
||||
{% don't indent paragraphs
|
||||
\setlength{\parindent}{0pt}
|
||||
% turn on hanging indent if param 1 is 1
|
||||
\ifodd #1 \everypar{\setlength{\hangindent}{\cslhangindent}}\ignorespaces\fi
|
||||
% set entry spacing
|
||||
\ifnum #2 > 0
|
||||
\setlength{\parskip}{#2\baselineskip}
|
||||
\fi
|
||||
}%
|
||||
{}
|
||||
\usepackage{calc}
|
||||
\newcommand{\CSLBlock}[1]{#1\hfill\break}
|
||||
\newcommand{\CSLLeftMargin}[1]{\parbox[t]{\csllabelwidth}{#1}}
|
||||
\newcommand{\CSLRightInline}[1]{\parbox[t]{\linewidth - \csllabelwidth}{#1}\break}
|
||||
\newcommand{\CSLIndent}[1]{\hspace{\cslhangindent}#1}
|
||||
$endif$
|
||||
$if(csquotes)$
|
||||
\usepackage{csquotes}
|
||||
$endif$
|
||||
|
||||
$if(title)$
|
||||
\title{$title$$if(thanks)$\thanks{$thanks$}$endif$}
|
||||
@ -412,6 +458,16 @@ $if(logo)$
|
||||
$endif$
|
||||
$endif$
|
||||
|
||||
\usepackage{float}
|
||||
\let\origfigure=\figure
|
||||
\let\endorigfigure=\endfigure
|
||||
\renewenvironment{figure}[1][]{%
|
||||
\origfigure[H]
|
||||
\centering
|
||||
}{%
|
||||
\endorigfigure
|
||||
}
|
||||
|
||||
\begin{document}
|
||||
$if(has-frontmatter)$
|
||||
\frontmatter
|
||||
@ -438,7 +494,7 @@ $if(toc-title)$
|
||||
\renewcommand*\contentsname{$toc-title$}
|
||||
$endif$
|
||||
$if(beamer)$
|
||||
\begin{frame}
|
||||
\begin{frame}[allowframebreaks]
|
||||
$if(toc-title)$
|
||||
\frametitle{$toc-title$}
|
||||
$endif$
|
||||
|
Loading…
Reference in New Issue
Block a user