aboutsummaryrefslogtreecommitdiff
path: root/doc/gost/gost-7-32-bibliography.sty
blob: dca60fa8f72b432c2397de5439d49f9a0f4f1857 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
\ProvidesPackage{gost-7-32-bibliography}[2022/01/28 GOST 7.32-2017]

\def\UrlBreaks{\do\/\do-}
\RequirePackage{url}

\newdimen\bibindent
\renewenvironment{thebibliography}[1]{
 \chapter*{\bibname}\addcontentsline{toc}{chapter}{\bibname}%
 \list{\@biblabel{\@arabic\c@enumiv}}%
      {\settowidth\labelwidth{\@biblabel{#1}}%
       \leftmargin\labelwidth
       \advance\leftmargin\labelsep
       \@openbib@code
       \usecounter{enumiv}%
       \let\p@enumiv\@empty
       \renewcommand\theenumiv{\@arabic\c@enumiv}}%
 \sloppy\clubpenalty4000\widowpenalty4000%
 \sfcode`\.\@m
}{
 \setcounter{totalbib}{\c@enumiv}%
 \def\@noitemerr
 {\@latex@warning{Empty `thebibliography' environment}}%
 \endlist
}
\renewcommand\@biblabel{}%
\setlength\bibindent{1.5em}

% Точки после номеров в библиографии. Несовместимо с natbib! -- Коротков И.
%\makeatletter
\renewcommand*{\@biblabel}[1]{\hfill#1.}


%
% Remove References header completely
% Stolen from original article.cls
%
\makeatletter
\renewenvironment{thebibliography}[1]{%
%     \usection{\refname}%
%      \@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}%
      \list{\@biblabel{\@arabic\c@enumiv}}%
          {\settowidth\labelwidth{\@biblabel{#1}}%
            \leftmargin\labelwidth
            \advance\leftmargin\labelsep
            \@openbib@code
            \usecounter{enumiv}%
            \let\p@enumiv\@empty
            \renewcommand\theenumiv{\@arabic\c@enumiv}}%
      \sloppy
      \clubpenalty4000
      \@clubpenalty \clubpenalty
      \widowpenalty4000%
      \sfcode`\.\@m}
     {\def\@noitemerr
      {\@latex@warning{Empty `thebibliography' environment}}%
      \endlist}
\makeatother