1. % \iffalse meta-comment -*- tab-width: 2; fill-column: 76; -*-
  2. % !TEX program = pdflatex
  3. % !Mode:: "DTX:UNIX:UTF-8"
  4. %
  5. % This is the source file for the DSTU bundle used with BibTeX,
  6. % heavily based on the GOST bundle.
  7. %
  8. % Current version is 1.4, 2025-02-24.
  9. %
  10. % It contains set of bibliographic styles that
  11. % attempt to format the bibliography according to
  12. % DSTU 8302:2015 with some conventional modifications.
  13. %
  14. % For a bibliographic entry in Ukrainian or Russian you need
  15. % to add the field
  16. % language = {ukrainian}
  17. % or
  18. % language = {russian}
  19. % correspondingly.
  20. %
  21. % German, French, Italian languages are
  22. % also partially supported. Default language is English.
  23. %
  24. % Advices and bug reports about what in particular is not currently
  25. % implemented (but should be) for Ukrainian language are welcome.
  26. %
  27. % Book entry should have the pagetotal field
  28. % showing total number of pages. Optional field
  29. % url will format URL (using hyperref, if loaded).
  30. %
  31. % See examples in dstu2015*.pdf.
  32. %
  33. % Requires 8-bit bibtex with switch -B and csf file supporting cyrillic.
  34. % bibtex8 -B -c <encoding>.csf <your_document>
  35. %
  36. % Alternatively, you can use Unicode version of bibtex.
  37. % bibtexu -B -l ukr -o ukr <your_document>
  38. %
  39. %
  40. % To unpack run
  41. % pdflatex dstu.dtx
  42. % To produce the documentation run
  43. % pdflatex dstu.dtx \
  44. % makeindex -r -s gind.ist dstu
  45. % makeindex -r -s gglo.ist -o dstu.gls dstu.glo
  46. % pdflatex dstu.dtx
  47. % pdflatex dstu.dtx
  48. % To succeed you must have Cyrillic fonts (LH of cm-super) installed.
  49. %
  50. %<*internal>
  51. \iffalse
  52. %</internal>
  53. %<*internal>
  54. \fi
  55. \def\nameofplainTeX{plain}
  56. \ifx\fmtname\nameofplainTeX\else
  57. \expandafter\begingroup
  58. \fi
  59. \input docstrip.tex
  60. \keepsilent
  61. \askforoverwritefalse
  62. \preamble
  63. -------------------------------------------------------------------
  64. This file is a part of DSTU package, which is a bundle of BibTEX
  65. styles to format bibliographic references according to
  66. DSTU 8302:2015.
  67.  
  68. Current version is 1.4, 2025/02/24.
  69.  
  70. Released under the LaTeX Project Public License v1.3c or later
  71. -------------------------------------------------------------------
  72. Copyright 2022-2025 Mykhailo Mishchenko
  73. Version 1.4
  74.  
  75. Copyright 2012-2020 Igor A. Kotelnikov.
  76. Copyright 2017 Leonid Sinev.
  77. Version 1.2k* of the original GOST bundle
  78.  
  79. Copyright 1996-2005 Maksym Polyakov.
  80. Version 2005.08.12 of the original GOST bundle
  81.  
  82. Released under the LaTeX Project Public License v1.3c or later
  83.  
  84. Current version is 1.4, 2025/02/25.
  85.  
  86. This work is derived from the GOST bundle. The only way this work is
  87. related to the authors of the GOST package is that it is based on their
  88. code. In particular, this means that all requests for support, including
  89. (but not limited to) the reporting and handling of errors in the DSTU
  90. package should be directed to its current maintainer and not to the authors
  91. of the GOST package.
  92.  
  93. This work has the LPPL maintenance status `maintained'.
  94.  
  95. The Current Maintainer of this work is Mykhailo Mishchenko.
  96.  
  97. Please, send bug report via e-mail:
  98. [email protected] <Mykhailo Mishchenko>
  99. or via an issue tracker at https://codeberg.org/mdmisch/dstu/issues .
  100.  
  101. Please, don't write me to the @firemail.cc address from Gmail, because Google
  102. will silently drop my reply. It will not even appear in Spam folder.
  103. If you really need to use your Gmail email, you can use an alternative email
  104. address:
  105. [email protected] <Mykhailo Mishchenko>
  106. -------------------------------------------------------------------
  107. This work consists of the file dstu.dtx
  108. and the derived files dstu.pdf,
  109. dstu*.bst,
  110. udstu*.bst,
  111. uudstu*.bst.
  112. It also contains some examples (*.tex, *.pdf files).
  113. -------------------------------------------------------------------
  114. \endpreamble
  115. %</internal>
  116. %<*install>
  117. \input docstrip
  118. \usedir{source/bibtex/dstu}
  119. \askonceonly
  120. \nopostamble
  121. %%\ProvidesFile{dstu.ins}[2024/02/10 1.3]
  122. \generate{%
  123. %% BST styles that mimics DSTU 8302:2015 for bibliographic *references*
  124. \file{dstu2015.bst} {\from{dstu.dtx} {bst,eprint,dstu2015}}
  125. \file{dstu2015l.bst} {\from{dstu.dtx} {bst,eprint,long,dstu2015}}
  126. %%
  127. %% Same styles with sorting
  128. \file{dstu2015s.bst} {\from{dstu.dtx} {bst,eprint,sort,dstu2015}}
  129. \file{dstu2015ls.bst} {\from{dstu.dtx} {bst,eprint,long,sort,dstu2015}}
  130. %% `
  131. %% --------------------------------------------------------------------------
  132. %% Unicode BST styles that mimics DSTU 8302:2015 for bibliographic *references*
  133. %% (for BibTeX implementations other than bibtexu)
  134. \file{udstu2015.bst} {\from{dstu.dtx} {bst,utf8,eprint,dstu2015}}
  135. \file{udstu2015l.bst} {\from{dstu.dtx} {bst,utf8,eprint,long,dstu2015}}
  136. %%
  137. %% Same styles with sorting
  138. \file{udstu2015s.bst} {\from{dstu.dtx} {bst,utf8,eprint,sort,dstu2015}}
  139. \file{udstu2015ls.bst} {\from{dstu.dtx} {bst,utf8,eprint,long,sort,dstu2015}}
  140. %%
  141. %% --------------------------------------------------------------------------
  142. %% Unicode BST styles that mimics DSTU 8302:2015 for bibliographic *references*
  143. %% (for BibTeX implementation bibtexu)
  144. \file{uudstu2015.bst} {\from{dstu.dtx} {bst,utf8,eprint,dstu2015,bibtexu}}
  145. \file{uudstu2015l.bst} {\from{dstu.dtx} {bst,utf8,eprint,long,dstu2015,bibtexu}}
  146. %%
  147. %% Same styles with sorting
  148. \file{uudstu2015s.bst} {\from{dstu.dtx} {bst,utf8,eprint,sort,dstu2015,bibtexu}}
  149. \file{uudstu2015ls.bst} {\from{dstu.dtx} {bst,utf8,eprint,long,sort,dstu2015,bibtexu}}
  150. %%
  151. %% --------------------------------------------------------------------------
  152. %% Experimental styles compatible with natbib package.
  153. \file{dstu2015n.bst} {\from{dstu.dtx} {bst,natbib,eprint,dstu2015}}
  154. \file{dstu2015ns.bst} {\from{dstu.dtx} {bst,natbib,eprint,sort,dstu2015}}
  155. %%
  156. \file{udstu2015n.bst} {\from{dstu.dtx} {bst,utf8,natbib,eprint,dstu2015}}
  157. \file{udstu2015ns.bst} {\from{dstu.dtx} {bst,utf8,natbib,eprint,sort,dstu2015}}
  158. %%
  159. \file{uudstu2015n.bst} {\from{dstu.dtx} {bst,utf8,natbib,eprint,dstu2015,bibtexu}}
  160. \file{uudstu2015ns.bst} {\from{dstu.dtx} {bst,utf8,natbib,eprint,sort,dstu2015,bibtexu}}
  161. %%
  162. %% --------------------------------------------------------------------------
  163. %% DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) refactored styles
  164. \file{dstu2006.bst} {\from{dstu.dtx} {bst,strict,eprint}}
  165. \file{dstu2006s.bst} {\from{dstu.dtx} {bst,strict,eprint,sort}}
  166. \file{udstu2006.bst} {\from{dstu.dtx} {bst,utf8,strict,eprint}}
  167. \file{udstu2006s.bst} {\from{dstu.dtx} {bst,utf8,strict,eprint,sort}}
  168. \file{uudstu2006.bst} {\from{dstu.dtx} {bst,utf8,strict,eprint,bibtexu}}
  169. \file{uudstu2006s.bst} {\from{dstu.dtx} {bst,utf8,strict,eprint,sort,bibtexu}}
  170. }
  171. %</install>
  172. %<install>\endbatchfile
  173. %<*internal>
  174. \ifx\fmtname\nameofplainTeX
  175. \expandafter\endbatchfile
  176. \else
  177. \expandafter\endgroup
  178. \fi
  179. %</internal>
  180. %<*driver>
  181. \ProvidesFile{dstu.dtx}[2025/02/24 v.1.4 BibTEX support for DSTU 8302:2015 bibliographies]
  182. \NeedsTeXFormat{LaTeX2e}
  183. \documentclass{ltxdoc}
  184. \usepackage{geometry}
  185. \usepackage{ifluatex,ifxetex}
  186. \ifnum 0\ifxetex 1\fi\ifluatex 1\fi>0
  187. \usepackage{fontspec}
  188. \defaultfontfeatures{Ligatures={TeX},Renderer=Basic}
  189. \setmainfont{CMU Serif}
  190. \setsansfont{CMU Sans Serif}
  191. \setmonofont{CMU Typewriter Text}
  192. \else
  193. \usepackage[utf8]{inputenc} % UTF-8: PDFLaTeX
  194. \usepackage[T2A]{fontenc}
  195. \usepackage{cmap}
  196. \fi
  197. \usepackage[russian,english]{babel}
  198. \usepackage{makeidx}\makeindex
  199. %\usepackage{xcolor}
  200. %\definecolor{darkblue}{rgb}{0,0,.6}
  201. \usepackage[
  202. unicode
  203. ,pdfusetitle
  204. ,colorlinks = true
  205. %,linkcolor = darkblue
  206. %,citecolor = darkblue, filecolor = darkblue
  207. %,menucolor = darkblue, urlcolor = darkblue
  208. ,bookmarksnumbered = true,
  209. ,pdfdisplaydoctitle = true% display document title instead of file
  210. ,pdfpagemode = UseOutlines% (show bookmarks)
  211. ]{hyperref}
  212. \usepackage{ulem}
  213. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  214. %
  215. \def\file#1{\texttt{#1}}
  216. \def\pkg#1{\textsf{#1}}
  217. \def\cmd#1{\texttt{#1}}
  218. \newcommand{\note}[2][N$\!\!$B: ]{\textcolor{red}{\ensuremath{\langle}#1#2\ensuremath{\rangle}}}
  219.  
  220. %
  221. \newcommand\DescribeEntry[1]{%
  222. \DescribeMacro{#1}\index{Entry!\texttt{#1}}%
  223. }
  224. \newcommand\DescribeFunction[1]{%
  225. \DescribeMacro{#1}\index{\texttt{#1}}%
  226. }
  227. \newcommand\DescribeField[1]{%
  228. \DescribeMacro{#1}\index{Field!\texttt{#1}}%
  229. }
  230. \newcommand{\BibTeXu}{{{\BibTeX}\kern-.175em\rmfamily\textsc{u}}}
  231. %
  232. %\OnlyDescription % uncomment to hide the Implementation section
  233. \EnableCrossrefs
  234. \CodelineIndex
  235. \RecordChanges
  236. \begin{document}
  237. \DocInput{\jobname.dtx}
  238. \end{document}
  239. %</driver>
  240. % \fi
  241. %
  242. % \CheckSum{0}
  243. %
  244. % \DoNotIndex{\cyra,\cyrb,\cyrv,\cyrg,\cyrd,\cyre}
  245. % \DoNotIndex{\CYRP,\cyrii,\cyrr,\cyre,\cyro,\CYRU,\cyrk,\cyrl,\CYRS,\cyrs}
  246. % \DoNotIndex{\cyrt,\cyri,\cyrz,\CYRT,\cyrm}
  247. % \DoNotIndex{\cyr,\cyrc,\CYRD,\cyrery,\cyrh,\CYRK,\CYRM,\CYRN,\cyrn}
  248. % \DoNotIndex{\cyrp,\cyrs,\cyrshch,\cyru,\CYRV,\cyrya}
  249. % \DoNotIndex{\CYRA,\CYRB,\cyrch,\CYRE,\CYREREV,\CYRF,\cyrf,\CYRI,\cyrishrt}
  250. % \DoNotIndex{\CYRO,\CYRR,\cyrsftsn,\CYRYA,\cyryu,\cyrzh}
  251. % \DoNotIndex{\CYRCH, \CYRG, \CYRL, \CYRZH}
  252. % \DoNotIndex{\z@skip,\z@}
  253. % \DoNotIndex{\|,\~,\ ,\,}
  254. %
  255. % \begingroup
  256. % \makeatletter
  257. % \lccode`9=32\relax
  258. % \lowercase{%^^A
  259. % \edef\x{\noexpand\DoNotIndex{\@backslashchar9}}%^^A
  260. % }%^^A
  261. % \expandafter\endgroup\x
  262. % \expandafter\DoNotIndex\expandafter{\string\&}
  263. %
  264. % \DoNotIndex{\',\(,\),\`,\\,\/,\.,\ }
  265. % \DoNotIndex{\begin,\DeclareUTFcharacter}
  266. % \DoNotIndex{\csname,\def}
  267. % \DoNotIndex{\else,\endcsname,\end}
  268. % \DoNotIndex{\expandafter,\fi}
  269. % \DoNotIndex{\hbox,\hss}
  270. % \DoNotIndex{\iffalse,\ifx,\ignorespaces,\iflanguage}
  271. % \DoNotIndex{\language,\lastskip,\ldots,\let,\natexlab,\newblock,\nobreak}
  272. % \DoNotIndex{\providecommand,\ProvideTextCommandDefault,\relax,\renewcommand}
  273. % \DoNotIndex{\selectlanguage,\selectlanguageifdefined,\small,\textemdash}
  274. % \DoNotIndex{\textnumero,\unskip,\url,\UTFencname}
  275. % \DoNotIndex{\catcode,\cite,\citeauthor,\citet,\citeyear,\href,\hskip,\ifdim}
  276. %
  277. %\GetFileInfo{\jobname.ins}
  278. %
  279. %\title{The DSTU package}
  280. %\author{
  281. % Mykhailo Mishchenko\thanks{E-mail: [email protected]}\hspace{0.25em}; \\ \\
  282. % heavily based on the GOST package by \\
  283. % Igor Kotelnikov\thanks{E-mail: [email protected]},
  284. % Leonid Sinev
  285. %}
  286. %\date{Version 1.4 released 2025.02.24}
  287. %\maketitle
  288. %
  289. % \begin{abstract}
  290. %
  291. % DSTU is a bundle of BibTeX styles designed to meet the DSTU 8302:2015
  292. % standard
  293. % on bibliographic references issued by the ДП «УкрНДНЦ»
  294. % and Державна наукова установа «Книжкова палата України імені Івана Федорова»,
  295. % and the DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) standard on biblographic
  296. % recording and bibliographic description.
  297. %
  298. % It comprises 18 BibTeX styles to format bibliography according to DSTU
  299. % 8302:2015 and 6 styles according to DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT).
  300. % Bibliographic records in English, Russian and Ukrainian are supported.
  301. % Both 8-bit and Unicode (UTF-8) versions of each BibTeX style, in each case
  302. % offering a choice of sorted and unsorted.
  303. %
  304. % \end{abstract}
  305. %
  306. % \section{Introduction}\label{s1}
  307. %
  308. % DSTU package is a modification of the GOST package which implements changes
  309. % required to comply with the current Ukrainian standard on bibliography
  310. % DSTU 8302:2015, which relaxes many archaic requirements of
  311. % DSTU GOST 7.1:2006 (i.\,e.\ GOST 7.1-2003, IDT).
  312. % While bibliography prepared according to GOST 7.1-2003 is still considered
  313. % valid under DSTU 8302:2015, following recommendations of DSTU 8302:2015 is
  314. % preferential. In some cases it is also explicitly required to prepare
  315. % bibliography specifically according to advices from DSTU 8302:2015.
  316. % For example, to follow typesetting style of a journal you are publishing
  317. % in.
  318. %
  319. % Although DSTU 8302:2015 can be used almost in every situation where
  320. % Ukrainian bibliographic standards are honored, there is a rumor that there
  321. % are some obscure cases when DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) must be
  322. % used and usage of DSTU 8302:2015 is prohibited. Thus, |*dstu2006*|
  323. % bibliographic styles
  324. % implementing DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) are also provided. It
  325. % seems like the DSTU GOST 7.1:2006 is actually a copy-paste of the Russian
  326. % GOST 7.1-2003. Thus, they are based on the |gost2003*| styles from the GOST
  327. % package. Nevertheless it appeared that the implementation of this
  328. % particular standard there was partial. |*dstu2006*| styles contain some
  329. % improvements made to better meet the DSTU GOST 7.1:2006 standard's
  330. % requirements, but there may be some yet unknown cases when it fails to meet
  331. % the standard. In addition, Ukrainian localization for was added where it
  332. % was missing.
  333. %
  334. % The GOST package was initially developed by Maksym Polyakov. It was later
  335. % updated by Igor Kotelnikov to the present status and some code was borrowed
  336. % from \pkg{disser} package developed by Stanislav Kruchinin and unpublished
  337. % work by Artem Petrenkov.
  338. %
  339. % Currently, DSTU contains 24 \BibTeX{} styles to format bibliography in
  340. % English, Ukrainian and
  341. % Russian according to DSTU 8302:2015 or DSTU GOST 7.1:2006
  342. % (GOST 7.1-2003, IDT). Both 8-bit and Unicode (UTF-8) versions of each
  343. % \BibTeX{} style, in each case offering a choice of sorted and unsorted.
  344. %
  345. % All styles in the DSTU bundle are derived from single master file
  346. % \file{dstu.dtx} by applying different set of options as shown in the table
  347. % below.
  348. %
  349. % \noindent
  350. % \begin{minipage}{\linewidth}
  351. % \begin{verbatim}
  352. %------------------------------------------------------------------------------------
  353. % Style | utf8 | bibtexu | strict | eprint | long | sort | natbib | dstu2015
  354. %------------------------------------------------------------------------------------
  355. % dstu2015 | | | | + | | | | +
  356. % dstu2015l | | | | + | + | | | +
  357. % dstu2015s | | | | + | | + | | +
  358. % dstu2015ls | | | | + | + | + | | +
  359. % dstu2015n | | | | + | | | + | +
  360. % dstu2015ns | | | | + | | + | + | +
  361. %------------------------------------------------------------------------------------
  362. % udstu2015 | + | | | + | | | | +
  363. % udstu2015l | + | | | + | + | | | +
  364. % udstu2015s | + | | | + | | + | | +
  365. % udstu2015ls | + | | | + | + | + | | +
  366. % udstu2015n | + | | | + | | | + | +
  367. % udstu2015ns | + | | | + | | + | + | +
  368. %------------------------------------------------------------------------------------
  369. % uudstu2015 | + | + | | + | | | | +
  370. % uudstu2015l | + | + | | + | + | | | +
  371. % uudstu2015s | + | + | | + | | + | | +
  372. % uudstu2015ls | + | + | | + | + | + | | +
  373. % uudstu2015n | + | + | | + | | | + | +
  374. % uudstu2015ns | + | + | | + | | + | + | +
  375. %------------------------------------------------------------------------------------
  376. % dstu2006 | | | + | + | | | |
  377. % dstu2006s | | | + | + | | + | |
  378. % udstu2006 | + | | + | + | | | |
  379. % udstu2006s | + | | + | + | | + | |
  380. % uudstu2006 | + | + | + | + | | | |
  381. % uudstu2006s | + | + | + | + | | + | |
  382. %------------------------------------------------------------------------------------
  383. % Style | utf8 | bibtexu | strict | eprint | long | sort | natbib | dstu2015
  384. %------------------------------------------------------------------------------------
  385. % \end{verbatim}
  386. % \end{minipage}
  387. %
  388. % |uudstu2015| style is recommended for most applications. It corresponds to the
  389. % currently effective DSTU 8302:2015 and intended to be used with UTF-8 encoded
  390. % documents and bibliography databases. Usage of other styles is best explained
  391. % through the meaning of options used to compile those styles from the master
  392. % source.
  393. %
  394. % All styles with |dstu2015| option and without |strict| option (|*dstu2015*|
  395. % styles) make best effort to implement DSTU 8302:2015. All styles without
  396. % |dstu2015| option and with |strict| option (|*dstu2006*| styles) make best
  397. % effort to implement DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT).
  398. %
  399. % If the number of authors exceeds 4, modern styles cut the list of authors
  400. % to at most 4 persons as prescibed by the Standards. Option
  401. % |long| overrides this rule to provide backward compatibility with the
  402. % package \pkg{disser} by Stanislav Kruchinin.
  403. %
  404. % Major effect of the |long| option is that the list of authors always
  405. % precedes book or article title no matter how long is it.
  406. % Modern styles compiled without |long| place long list of authors behind
  407. % the title. The names of styles compiled with the option |long| has the
  408. % suffix |l|. Recall that those styles do not conform effective Standards and
  409. % their use is discouraged.
  410. %
  411. % The |eprint| option enables formatting electronic publications. In particular,
  412. % it enables |eprint|, |eprinttype|, |eprintclass|, and |doi| fields for a
  413. % bibliographic entry. The styles generated without the |eprint| option,
  414. % ignore the these fields.
  415. %
  416. % The |natbib| option provides compatibility with the |natbib| package. The names
  417. % of styles compiled with the option |natbib| bear the suffix |n|. Currently
  418. % 4 styles with that option are available for beta testing.
  419. %
  420. % The |sort| option enables sorting bibliographic references by author names
  421. % and references titles. The names of styles compiled with the option |sort|
  422. % bear the suffix |s|.
  423. %
  424. % Finally, the |utf8| option produces bibliographic styles in Unicode rather
  425. % that in 8-bit encoding. The |utf8| without |bibtexu| option are intended
  426. % to be used with \BibTeX8 and have some functionality (involving typesetting
  427. % initials and letter case changing) disabled to prevent glitches appearing when
  428. % using \BibTeX8 with UTF-8 encoded bibliography. Names of those styles bear
  429. % the prefix |u|.
  430. %
  431. % The |utf8| styles with |bibtexu| option are fully functional styles in
  432. % Unicode intended to be used with \BibTeXu. As of 2022
  433. % \BibTeXu{} works pretty decently, but beware that its older
  434. % versions often crash with "Segmentation fault" and thus are unusable.
  435. %
  436. % Styles without |utf8| option are intended for documents in one-byte 8-bit
  437. % encodings (e.\,g.\ cp1251) and not for Unicode.
  438. %
  439. % The original GOST bundle contains CS files (codepage and
  440. % sorting order) which are recommended to be used with the DSTU bundle.
  441. %
  442. % \noindent
  443. % \begin{minipage}{\linewidth}
  444. % \begin{verbatim}
  445. % ----------------------------------------------------------------
  446. % Encoding | CSF | Sorting order
  447. % ----------------------------------------------------------------
  448. % cp866 | ruscii.csf | Cyrillic first, Latin
  449. % cp1251 | cp1251.csf | Cyrillic first, Latin
  450. % koi8-u | koi8u.csf | Cyrillic first, Latin
  451. % utf8 | utf8cyrillic.csf | Cyrillic first, Latin
  452. % ----------------------------------------------------------------
  453. % \end{verbatim}
  454. % \end{minipage}
  455. %
  456. % In addition, \BibTeX8 distribution comes with few more CSFs.
  457. %
  458. % \noindent
  459. % \begin{minipage}{\linewidth}
  460. % \begin{verbatim}
  461. % ---------------------------------------------------------------
  462. % Encoding | CSF | Sorting order
  463. % ---------------------------------------------------------------
  464. % cp866 | cp866rus.csf | Latin first, Cyrillic
  465. % ---------------------------------------------------------------
  466. % \end{verbatim}
  467. % \end{minipage}
  468. %
  469. % \section{How to use}\label{s2}
  470. %
  471. % \begin{enumerate}
  472. % \item
  473. % Select bibliography style by adding appropriate |\bibliographystyle|
  474. % declaration to your source file \file{<filename>.tex}, e.g.
  475. % \begin{verbatim}
  476. % \bibliographystyle{dstu2015}
  477. % \bibliography{database}
  478. % \end{verbatim}
  479. %
  480. % \item
  481. % Add the field |langid="ukrainian"| or |langid="russian"| to the
  482. % bibliographic entries in Ukrainian or Russian languages in your
  483. % database; English is the default language. German, Italian and
  484. % French are partially supported. |language| field with the same
  485. % meaning is available, but deprecated.
  486. %
  487. % \item
  488. % To compile list of references from your database use \file{bibtex8}
  489. % program rather than \file{bibtex}. Depending on the codepage of your
  490. % bibliographic database, indicate one of the CS files
  491. % listed above as option to \file{bibtex8}. Run LaTeX, then run
  492. % \file{bibTeX8} and LaTeX again:
  493. % \begin{verbatim}
  494. % latex <filename>.tex
  495. % bibtex8 -B -c <csf_file>.csf <filename>.aux
  496. % latex <filename>.tex
  497. % \end{verbatim}
  498. %
  499. % Alternatively, you can use \file{bibtexu} instead of \file{bibtex8} as
  500. % following:
  501. % \begin{verbatim}
  502. % latex <filename>.tex
  503. % bibtexu -B -l ukr -o ukr <filename>.aux
  504. % latex <filename>.tex
  505. % \end{verbatim}
  506. %
  507. % \item
  508. % \begin{sloppypar}
  509. % For details on preparing bibliographic database see examples in
  510. % \file{dstu2015*.pdf}, \file{udstu2015*.pdf} and \file{uudstu2015*.pdf}.
  511. % \end{sloppypar}
  512. %
  513. % \item
  514. % \file{udstu2015*} and \file{uudstu2015*} styles are primarily intended for
  515. % use with unicode compilers (\file{xelatex} and \file{lualatex}). They
  516. % should be preferred as well when using 8bit compilers
  517. % (\file{latex} and \file{pdflatex}) if source file is in utf8 encoding
  518. % \textit{and} you are using \file{bibtex} or \file{bibtex8}.
  519. %
  520. % You can also use \file{dstu2015*} styles if you use the
  521. % \file{bibtexu} program to build your bibliography instead of
  522. % \file{bibtex} or \file{bibtex8}.
  523. %
  524. % \item
  525. % Neither \file{bibtex} nor \file{bibtex8} provides
  526. % correct sorting order of unicode text. It means that using
  527. % \file{udstu2015s} or \file{udstu2015ns} may produce unexpected result
  528. % for documents in \texttt{utf8} encoding.
  529. % Consider using \file{bibtexu} if you need correct sorting in this case.
  530. %
  531. % \item
  532. % \file{bibtex8} fails to change case of a string if it contains Cyrillic
  533. % letter in unicode. Therefore \file{ugost2008*} styles do not change case of
  534. % titles and other parts of bibliographic record while 8-bit styles
  535. % do the case change where appropriate.
  536. %
  537. % \item
  538. % Either \file{bibtex} or \file{bibtex8} fail to cut Cyrillic names to
  539. % initials. Therefore \file{udstu2015*} styles do not modify name of
  540. % authors.
  541. %
  542. % \item
  543. % Package |natbib| is required when choosing styles with
  544. % suffix |n| in their names.
  545. %
  546. % \end{enumerate}
  547. %
  548. %
  549. % \section{Customization}\label{s3}
  550. %
  551. % Every DSTU style defines few commands to format some parts of a
  552. % reference. You can redefine these commands prior to
  553. % the |\bibliography{<bibtex_style>}| command. Initial
  554. % definitions are listed below.
  555. % \begin{verbatim}
  556. % \providecommand*{\url}[1]{{\small #1}}
  557. % \providecommand*{\BibUrl}[1]{\url{#1}}
  558. % \providecommand{\BibAnnote}[1]{}
  559. % \providecommand*{\BibEmph}[1]{#1}
  560. % \providecommand*{\BibEnNo}{no.}
  561. % \providecommand*{\BibFirstNameSpace}{\,}
  562. % \providecommand*{\BibSemicolonSpace}{~}
  563. % \end{verbatim}
  564. %
  565. % \DescribeMacro{\DSTUAllowBibDash}
  566. % By default, dstu styles separate logical parts of a bibliography
  567. % record by a period. It is still legitimate to separate them by a period and
  568. % cyrdash (|. "---|) instead, like required by DSTU GOST 7.1:2006, but it is
  569. % strongly discouraged (while allowed) in DSTU 8302:2015. You can enable the
  570. % dash separator in |dstu2015*| and |udstu2015*| styles by overriding the
  571. % command |\DSTUAllowBibDash| as follows:
  572. %
  573. % \begin{verbatim}
  574. % \newcommand*{\DSTUAllowBibDash}{1}
  575. % \end{verbatim}
  576. %
  577. % \DescribeMacro{\DSTUResponsibilityName}
  578. % By default, names are formatted in a way so that initials appear
  579. % \textit{after} last name. But it seems like the exact order is not
  580. % defined by the standards. Some journals (e.\,g.\ Problems of Control and
  581. % Informatics) require to have this order in names before the title and
  582. % reverse order in names after the title (i.\,e. in the "responsibility"
  583. % section of bibliographic reference).
  584. %
  585. % To address this all names after the title are formatted twice for both
  586. % variants of formatting. Each two variants of formatting of the same name
  587. % are used as two arguments of |\DSTUResponsibilityName| custom \LaTeX{}
  588. % macro. This commant by default uses the first its argument (with
  589. % normal order) and ignores its second argument (with reverse order). You
  590. % can make styles use the reverse order in the "responsibility" section by
  591. % overriding it as follows:
  592. %
  593. % \begin{verbatim}
  594. % \newcommand*{\DSTUResponsibilityName}[2]{#2}
  595. % \end{verbatim}
  596. %
  597. % \DescribeMacro{\DSTUAllowNamesAnd}
  598. % By default, lists of names containing more than 4 names will have "and",
  599. % "и", or "і" (depending on language) before the last name in such list.
  600. % Some journals (e.\,g.\ Problems of Control and Informatics) prohibit it.
  601. % |\DSTUAllowNamesAnd| allows to disable adding "and", "и", or "і" with
  602. % following command:
  603. %
  604. % \begin{verbatim}
  605. % \newcommand*{\DSTUAllowNamesAnd}{0}
  606. % \end{verbatim}
  607. %
  608. % \DescribeMacro{\BibDOIFullURL}
  609. % By default, the DOI identifier is printed as is, and is not formatted as
  610. % an URL to the \url{https://doi.org/}. Placing full URL instead of a DOI
  611. % identifier is explicitly discouraged (but still allowed) by
  612. % DSTU~8302:2015. Nevertheless, some journals (e.\,g.\ Problems of Control
  613. % and Informatics) require to place full DOI URLs into bibliographic
  614. % references.
  615. %
  616. % You can make this style print full DOI URLs by placing the following
  617. % definition somewhere before bibliography in your document.
  618. % \begin{verbatim}
  619. % \newcommand*{\BibDOIFullURL}{1}
  620. % \end{verbatim}
  621. %
  622. % \textbf{TODO:} Test |\DSTUAllowBibDash| in
  623. % |dstu2015*| and |udstu2015*|.
  624. %
  625. % By default, |\BibDash| is equivalent to the shorthand |"---|
  626. % defined by the babel package with the option |russian|.
  627. % It prints a so called Cyrillic dash (|\cyrdash|),
  628. % which is 20\% shorter then ordinary LaTeX dash (|---|), and puts
  629. % unbreakable space before |\cyrdash| so that dash never appears
  630. % in the beginning of a line.
  631. %
  632. % \DescribeMacro{\BibEnNo}
  633. % |\BibEnNo|, obviously, defines every occurance of prefix of a number in
  634. % bibliography. In some cases, you may wish to replace it with something like
  635. % |N.| or |№|.
  636. %
  637. %
  638. % \DescribeMacro{\BibFirstNameSpace}
  639. % |\BibFirstNameSpace| represents space between initials, for example,
  640. % between initials for first name and patronymic. It seems like everyone has
  641. % their own opinion on what it should be: nonbreakng whitespace |~|, short
  642. % unstretchable space |\,|, no space at all or something else. See
  643. % \href
  644. % for discussion on this topic regaring Ukrainian language.
  645. %
  646. % \DescribeMacro{\BibSemicolonSpace}
  647. % |\BibSemicolonSpace| defines space before semicolon dividing bibliographic
  648. % record's sections. Normally it is nonbreaking space |~|. Redefining it
  649. % would violate standards. Nevertheess, some journals may require, for
  650. % example, not to have space before semicolons.
  651. %
  652. % \DescribeMacro{\BibDiscouragedbreakSpace}
  653. % \phantomsection\label{macro:BibDiscouragedbreakSpace}
  654. % Line breaks between "Vol." (or its translations) and corresponding
  655. % volume numbers do not look good in general. This bibliographic style
  656. % inserts nonbreaking space (|~|) if the volume number is shorter than 3
  657. % characters. Otherwise it inserts |\BibDiscouragedbreakSpace| which by
  658. % default discourages line break at this point, but do not prohibit it
  659. % completely. Thus, \TeX{} can still decide to make a line break at this
  660. % point if otherwise too wide whitespaces emerge.
  661. %
  662. % Its default definition is equivalent to the following:
  663. % \begin{verbatim}
  664. % \newcommand*{\BibDiscouragedbreakSpace}{ \nolinebreak[3] }
  665. % \end{verbatim}
  666. % You can redefine it in your document to something else if required. For
  667. % example, you can change weight argument of |\nolinebreak| to something
  668. % else, or you can explicitly prohibit breaking a line at this place by
  669. % changing its definition to |~|.
  670. %
  671. % \DescribeMacro{\BibISBNandISSNcolon}
  672. % \DescribeMacro{\BibISBNcolon}
  673. % \DescribeMacro{\BibISSNcolon}
  674. % Starting from v1.4 colons \texttt{:} are not prnted after \texttt{ISBN}
  675. % and \texttt{ISSN} in accordance to DSTU~GOST~7.1-2006. If for some
  676. % reason you need to place colons there, like it is done after
  677. % \texttt{URL} and \texttt{DOI}, you can define one of these macro
  678. % according to what you need:
  679. % \begin{verbatim}
  680. % \newcommand*{\BibISBNcolon}{:}
  681. % \newcommand*{\BibISSNcolon}{:}
  682. % \newcommand*{\BibISBNandISSNcolon}{:}
  683. % \end{verbatim}
  684. %
  685. % \DescribeMacro{\DSTUAllowSeriesParentheses}
  686. % \phantomsection\label{macro:DSTUAllowSeriesParentheses}
  687. % Starting from v1.4 the information related to series is properly
  688. % represented as the "series" section in accordance to DSTU~GOST~7.1-2006.
  689. %
  690. % The "series" section, according to DSTU~GOST~7.1-2006, must be put in
  691. % braces. In DSTU~8303:2015 nothing is said about these braces, which
  692. % implicitly means that they must be inherited from DSTU~GOST~7.1-2006.
  693. %
  694. % Nevertheles, these braces are rarely seen in examples of bibliographic
  695. % references formatted according to DSTU~8303:2015 because this standard
  696. % \textit{allows} to skip the series section completely. Thus, editors
  697. % \sout{may be freaked by} may not be familiar with these braces and thus
  698. % may insist on removing them. Set \cs{DSTUAllowSeriesParentheses} as
  699. % following if you need to remove these braces:
  700. % \begin{verbatim}
  701. % \newcommand*{\DSTUAllowSeriesParentheses}{0}
  702. % \end{verbatim}
  703. %
  704. % \section{Where to get}\label{s4}
  705. %
  706. % Latest versions are published at
  707. %
  708. % \section{Version history}\label{s5}
  709. %
  710. % \subsection{Version 1.4 (2025.02.24)}
  711. %
  712. % \begin{enumerate}
  713. % \item Include the series bibliographic record's section in a proper
  714. % position (instead of just mentioning corresponding information
  715. % somewhere) in accordance to the DSTU~GOST~7.1-2006.
  716. % \item Changed how and where the \texttt{volume} field is printed. From
  717. % now on \texttt{volume} is printed as a book volume only if there is no
  718. % \texttt{series} section in bibliographic record. Otherwise it is
  719. % treated as a volume within series.
  720. % \end{enumerate}
  721. %
  722. % \subsection{Version 1.3 (2025.02.10)}
  723. % \begin{enumerate}
  724. % \item Name formatting rewritten. This fixes bug with disappearing second
  725. % part in hyphenated double first names and ansures no linebreak after
  726. % hyphens in this position (if the |\nobreakdash| from \texttt{amsmath}
  727. % is available).
  728. % \end{enumerate}
  729. %
  730. % \subsection*{Version 1.2 (2025.02.04)}
  731. %
  732. % \begin{enumerate}
  733. % \item Renamed |uudstu2015sc.bst|, |uudstu2015lsc.bst| to
  734. % |uudstu2015s.bst|, |uudstu2015ls.bst| (correspondingly) for naming
  735. % consistency.
  736. % \item Added generation of bibliography example consistent with
  737. % requirements of the Problems of Control and Informatics journal:
  738. % |uudstu2015-pcijournal.{tex,pdf}|.
  739. % \item Added a bibliography example |ex78.bib| with four and more authors
  740. % in English.
  741. % \item Added a macro \cs{DSTUResponsibilityName} which can be redefined
  742. % by user to change order of corresponding initials and surnames
  743. % appearing after title.
  744. % \item Added macro \cs{DSTUAllowNamesAnd} which determines whether to use
  745. % "and", "і" or "и" in name lists.
  746. % \item User can now change the kind of whitespace inserted between "Vol."
  747. % (or its translations) and corresponding volume numbers longer than 2
  748. % characters. Previously it was a normal whitespace (which allows line
  749. % break). Now it is | \nolinebreak[3] | by default and can be changed by
  750. % user. See the description of
  751. % \hyperref[macro:BibDiscouragedbreakSpace]{\textbackslash BibDiscouragedbreakSpace}.
  752. % \end{enumerate}
  753. %
  754. % \subsection*{Version 1.1 (2023.09.12)}
  755. %
  756. % \begin{enumerate}
  757. % \item
  758. % Added ISSN to articles.
  759. % \end{enumerate}
  760. %
  761. % \subsection*{Version 1.0 (2023.08.04)}
  762. %
  763. % \begin{enumerate}
  764. % \item
  765. % Codebase inherited from the GOST bundle 1.2k (2020.12.29).
  766. %
  767. % \item
  768. % Added some tweaks to comply with the DSTU 8302:2015.
  769. %
  770. % \item
  771. % Building of original styles from the GOST bundle removed to avoid
  772. % filename clashes.
  773. %
  774. % \item
  775. % Added `polyglossia` support for language changing in bibliography entries.
  776. % \end{enumerate}
  777. %
  778. % \StopEventually{
  779. % \IndexPrologue{\section{Index}
  780. % Numbers written in dark blue refer to the page where the corresponding
  781. % entry is described; numbers in black roman refer to the code lines where
  782. % the entry is used.
  783. % }
  784. % \GlossaryPrologue{\newpage\section{Change History}}
  785. % \PrintChanges
  786. % \PrintIndex
  787. % }
  788. %
  789. % \section{Implementation}\label{s6}
  790. %
  791. % We need Russian fonts to produce documentation of the code below.
  792. % Therefore we switch current language to Russian by issuing the command
  793. % |\selectlanguage{russian}|.
  794. %
  795. % \selectlanguage{russian}
  796. %
  797. % \begin{macrocode}
  798. %<*bst>
  799. % \end{macrocode}
  800. %
  801. % \begin{macrocode}
  802. %% This bibstyle attempts to format bibliography according to
  803. %<strict&dstu2015>%% strange mix of DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) and DSTU 8302:2015. Do not use it!
  804. %<strict&!dstu2015>%% DSTU GOST 7.1:2006 (GOST 7.1-2003, IDT) for bibliographic records.
  805. %<!strict&!dstu2015>%% (probaly) GOST 7.0.5-2008 for bibliographic reference.
  806. %<!strict&dstu2015>%% DSTU 8302:2015 for bibliographic reference.
  807. %<*natbib>%%
  808. %%-------------------------------------------------------------------
  809. %% This is an author-year citation style bibliography.
  810. %% It requires a special package file to function properly
  811. %% such as natbib.sty by Patrick W. Daly.
  812. %% The form of the \bibitem entries is
  813. %% \bibitem[Jones et al.(1990)]{key}...
  814. %% \bibitem[Jones et al.(1990)Jones, Baker, and Smith]{key}...
  815. %% where the label part [in brackets] consists of the author names,
  816. %% as they should appear in the citation, with the year in parentheses following.
  817. %% There must be no space before the opening parenthesis!
  818. %% A full list of authors may also follow the year.
  819. %% In natbib.sty, it is possible to define the type of enclosures that is
  820. %% really wanted (brackets or parentheses), but in either case, there must
  821. %% be parentheses in the label.
  822. %% The \cite command functions as follows:
  823. %% \citet{key} => Jones et al. (1990)
  824. %% \citet*{key} => Jones, Baker, and Smith (1990)
  825. %% \cite{key} => (Jones et al., 1990)
  826. %% \cite*{key} => (Jones, Baker, and Smith, 1990)
  827. %% \cite[chap. 2]{key} => (Jones et al., 1990, chap. 2)
  828. %% \cite[e.g.][]{key} => (e.g. Jones et al., 1990)
  829. %% \cite[e.g.][p. 32]{key} => (e.g. Jones et al., p. 32)
  830. %% \citeauthor{key} => Jones et al.
  831. %% \citeauthor*{key} => Jones, Baker, and Smith
  832. %% \citeyear{key} => 1990
  833. %%---------------------------------------------------------------------
  834. %</natbib>
  835.  
  836. % \end{macrocode}
  837. % \subsection{Fields}\label{s6.1}
  838. %
  839. % Enlist all entry fields allowed in a bibliographic database.
  840. % Most fields are common for many standard |bst| styles. Nonlisted fields
  841. % are just ignored by \BibTeX.
  842. % \changes{GOST v1.2i}{12 Jan 2017}{field \texttt{date} added}
  843. % \changes{GOST v1.2i}{12 Jan 2017}{field \texttt{specialitycode} added}
  844. % \changes{GOST v1.2f}{12 Jul 2016}{entry \texttt{patent} added}
  845. % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{langid} added}
  846. % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{eid} added}
  847. % \changes{GOST v1.2}{01 Feb 2012}{entry field \texttt{medium} added}
  848. % \changes{GOST v0.8}{06 Jun 2003}{entry field \texttt{annote} added}
  849. % \begin{macrocode}
  850. ENTRY
  851. { address
  852. annote
  853. author
  854. booktitle
  855. bookauthor
  856. chapter
  857. edition
  858. editor
  859. compiler
  860. howpublished
  861. institution
  862. journal
  863. key
  864. %major % new in v.1.2i, alias for speciality, not implemented
  865. majorcode % new in v.1.2i, alias for specialitycode
  866. month
  867. note
  868. number
  869. organization
  870. pages
  871. eid % new in v1.2c
  872. publisher
  873. school % alias for institution
  874. series
  875. %speciality % new in v.1.2i, eqv. to major in biblatex-gost, not implemented yet...
  876. specialitycode % new in v.1.2i, alias of number, eqv. to majorcode in biblatex-gost
  877. title
  878. %medium % new in v1.2; renamed to media.
  879. media % new in v1.2f
  880. type
  881. volume
  882. year
  883. language
  884. langid % new in v1.2c
  885. booklanguage
  886. % \end{macrocode}
  887. % Entries borrowed from biblatex.
  888. % \changes{GOST v1.2b}{19 Jan 2014}{entry field \texttt{numpages} renamed to
  889. % \texttt{pagetotal}}
  890. % \changes{GOST v1.2}{26 Jan 2012}{entry fields \texttt{eprint}, \texttt{eprintclass},
  891. % \texttt{eprinttype} added}
  892. % \changes{v1.1}{12 Sep 2023}{entry field \texttt{issn} added}
  893. % \begin{macrocode}
  894. date % new in v1.2i
  895. pagetotal
  896. url
  897. urldate
  898. isbn
  899. issn
  900. doi
  901. eprint
  902. eprinttype % = archivePrefix
  903. eprintclass % = primaryClass
  904. % new in v1.2f:
  905. % appear in biblatex:
  906. %addendum % not implemented yet...
  907. holder % see patent
  908. location % new in v.1.2i, alias of address
  909. %subtitle % not implemented yet...
  910. titleaddon % new in v.1.2i, see @thesis
  911. %version % not implemented yet...
  912. % Appear in biblatex-gost for @patent entry:
  913. authorcountry % country of the patent authors
  914. credits % statement of responsibility, other than provided in Biblatex
  915. ipc % Code of the International Patent Classification
  916. %media % General material designation NOTE: medium in the above
  917. requestnumber % Registration number of the application to the patent document
  918. publicationdate % Date of publication
  919. publication % and information on the official gazette, which published patent
  920. prioritydate % Information about the convention priority: the date of filing of the application,
  921. prioritynumber % number and
  922. prioritycountry % country name of convention priority.
  923. requestdate % ??
  924. }
  925. {}
  926. %<!natbib> { label }
  927. %<natbib> { label extra.label sort.label short.list }
  928.  
  929. % \end{macrocode}
  930. %
  931. % \subsection{Output functions}\label{s6.2}
  932. %
  933. % Declare internal variables and constants used for formatting bibliographic
  934. % records. Other variables are defined below when needed.
  935. % \begin{macrocode}
  936. INTEGERS {
  937. output.state
  938. before.all
  939. mid.sentence
  940. after.sentence
  941. after.block
  942. after.dblslash
  943. after.slash
  944. after.colon
  945. after.semicolon
  946. output.needitalic
  947. fmt.responsibility.name
  948. }
  949.  
  950. STRINGS { curlanguage }
  951.  
  952. STRINGS { s t }
  953.  
  954. STRINGS { y m d } % new in v.1.2j
  955.  
  956. % \end{macrocode}
  957. %
  958. % \DescribeFunction{init.state.consts}%
  959. % Set constants that designate various output states which are kept by
  960. % `output.state` integer. The latter is checked and updated by a set of functions
  961. % such as `output` to be defined below.
  962. % \begin{macrocode}
  963. FUNCTION {init.state.consts}
  964. { #0 'before.all :=
  965. #1 'mid.sentence :=
  966. #2 'after.sentence :=
  967. #3 'after.block :=
  968. #4 'after.dblslash :=
  969. #5 'after.slash :=
  970. #6 'after.colon :=
  971. #7 'after.semicolon :=
  972. }
  973.  
  974. % \end{macrocode}
  975. %
  976. % \DescribeFunction{set.language}
  977. % Sets current language |curlanguage|.
  978. % Called by |bibitem.output| before any other function.
  979. % \begin{macrocode}
  980. FUNCTION {set.language}
  981. { langid empty$
  982. { language empty$
  983. { "english" 'curlanguage := }
  984. { language 'curlanguage := }
  985. if$
  986. }
  987. { langid 'curlanguage := }
  988. if$
  989. }
  990.  
  991. % \end{macrocode}
  992. %
  993. % \DescribeFunction{reset.language}
  994. % Reset current language to |booklanguage| if provided. Called by
  995. % |output.nonnull| after double slash so that the rest of the record is formatted
  996. % with |booklanguage|.
  997. % \begin{macrocode}
  998. FUNCTION {reset.language}
  999. { booklanguage empty$
  1000. { "" }
  1001. { booklanguage 'curlanguage :=
  1002. "\selectlanguageifdefined{"
  1003. curlanguage *
  1004. "}" *
  1005. }
  1006. if$
  1007. }
  1008.  
  1009. % \end{macrocode}
  1010. %
  1011. % Declare various functions to output various parts of a bibliographic record.
  1012. %
  1013. % \DescribeFunction{format.italicize}
  1014. % This function is supposed to be used in \texttt{output.nonnull}. It wraps
  1015. % last string on stack in \sc{textit} if \texttt{output.needitalic} is set and
  1016. % resets this variable it to zero.
  1017. %
  1018. % This hack is needed to italicize entries together with punctuation appended
  1019. % to it in some other place.
  1020. %
  1021. % \changes{v1.0}{11 Sep 2022}{Added \texttt{output.needitalic} for delayed
  1022. % italicising of entries.}
  1023. %
  1024. % \begin{macrocode}
  1025. FUNCTION {format.italicize}
  1026. {
  1027. output.needitalic
  1028. { "\textit{" swap$ * "}" *
  1029. #0 'output.needitalic :=
  1030. }
  1031. 'skip$
  1032. if$
  1033. }
  1034. % \end{macrocode}
  1035. %
  1036. % \DescribeFunction{output.nonnull}
  1037. % Writes the last literal in the stack to output buffer
  1038. % assuming that it is not empty and adds an appropriate punctuation symbol.
  1039. % \changes{GOST v1.2c}{17 Jan 2015}{fix Gost2003: \texttt{"}\texttt{-}\texttt{-}\texttt{-} replaced by macro \cs{BibDash}}
  1040. % \changes{v1.0}{11 Sep 2022}{Replace double dash with dot for \texttt{dstu2015} and mark anything after supposed double dash as italicized.}
  1041. % \changes{v1.0}{20 Mar 2023}{Removed \cs{BibDash} by default (can be enabled back by user).}
  1042. % \changes{v1.0}{19 Jun 2023}{Added \cs{BibSemicolonSpace}.}
  1043. % \begin{macrocode}
  1044. FUNCTION {output.nonnull}
  1045. {
  1046. swap$
  1047. output.state mid.sentence =
  1048. { format.italicize ", " * write$ }
  1049. { output.state after.block =
  1050. { add.period$ format.italicize write$
  1051. %<!dstu2015> " \BibDash " write$
  1052. %<dstu2015> " \DSTUBibDash " write$
  1053. newline$
  1054. "\newblock " write$
  1055. }
  1056. { output.state before.all =
  1057. { format.italicize write$ }
  1058. { output.state after.dblslash =
  1059. %<!dstu2015> { format.italicize "~//" * reset.language * " " * write$ }
  1060. %<*dstu2015>
  1061. { add.period$ format.italicize reset.language * " " * write$
  1062. #1 'output.needitalic :=
  1063. }
  1064. %</dstu2015>
  1065. { output.state after.slash =
  1066. { format.italicize "~/ " * write$ }
  1067. { output.state after.colon =
  1068. { format.italicize "~: " * write$ }
  1069. { output.state after.semicolon =
  1070. { format.italicize "\BibSemicolonSpace ; " * write$ }
  1071. { add.period$ format.italicize " " * write$ }
  1072. if$
  1073. }
  1074. if$
  1075. }
  1076. if$
  1077. }
  1078. if$
  1079. }
  1080. if$
  1081. }
  1082. if$
  1083. mid.sentence 'output.state :=
  1084. }
  1085. if$
  1086. }
  1087.  
  1088. % \end{macrocode}
  1089. %
  1090. % \DescribeFunction{output}
  1091. % Calls |output.nonnull| if the last literal string in the stack
  1092. % is not empty; otherwise it discards the literal.
  1093. % \begin{macrocode}
  1094. FUNCTION {output}
  1095. { duplicate$ empty$
  1096. 'pop$
  1097. 'output.nonnull
  1098. if$
  1099. }
  1100.  
  1101. % \end{macrocode}
  1102. %
  1103. % \DescribeFunction{output.check}
  1104. % Does the same but also warns if the indicated field is empty. Needs two
  1105. % literals in the stack: the field and the name of the field, e.g.,
  1106. % |author "author" output.check|.
  1107. % \begin{macrocode}
  1108. FUNCTION {output.check}
  1109. { 't :=
  1110. duplicate$ empty$
  1111. { pop$
  1112. "empty " t * " in " * cite$ * warning$
  1113. }
  1114. 'output.nonnull
  1115. if$
  1116. }
  1117.  
  1118. % \end{macrocode}
  1119. %
  1120. % \DescribeFunction{fin.entry}
  1121. % |fin.entry| finalizes current entry. It writes dot, if no dot is found in
  1122. % stack, and starts new line.
  1123. % \begin{macrocode}
  1124. FUNCTION {fin.entry}
  1125. { add.period$
  1126. write$
  1127. newline$
  1128. }
  1129.  
  1130. % \end{macrocode}
  1131. %
  1132. % Declare a family of functions to put punctuation marks depending on the current
  1133. % status of the output stack.
  1134. %
  1135. % \DescribeFunction{new.block}%
  1136. % This just checks output state and revert it to another state if required.
  1137. % Checking output state prevents occasional doubling of punctuation marks.
  1138. % \begin{macrocode}
  1139. FUNCTION {new.block}
  1140. { output.state before.all =
  1141. 'skip$
  1142. { after.block 'output.state := }
  1143. if$
  1144. }
  1145.  
  1146. % \end{macrocode}
  1147. % \DescribeFunction{new.dblslash}%
  1148. % \begin{macrocode}
  1149. FUNCTION {new.dblslash}
  1150. { output.state before.all =
  1151. 'skip$
  1152. { after.dblslash 'output.state := }
  1153. if$
  1154. }
  1155.  
  1156. % \end{macrocode}
  1157. % \changes{v1.2}{09 Jan 2025}{Add automatic switch to the
  1158. % responsibility-section mode of name formatting
  1159. % after slash.}
  1160. % \DescribeFunction{new.slash}%
  1161. % \begin{macrocode}
  1162. FUNCTION {new.slash}
  1163. { output.state before.all =
  1164. 'skip$
  1165. { after.slash 'output.state := }
  1166. if$
  1167. #1 'fmt.responsibility.name :=
  1168. }
  1169.  
  1170. % \end{macrocode}
  1171. % \DescribeFunction{new.colon}%
  1172. % \begin{macrocode}
  1173. FUNCTION {new.colon}
  1174. { output.state before.all =
  1175. 'skip$
  1176. { after.colon 'output.state := }
  1177. if$
  1178. }
  1179.  
  1180. % \end{macrocode}
  1181. % \DescribeFunction{new.semicolon}%
  1182. % \begin{macrocode}
  1183. FUNCTION {new.semicolon}
  1184. { output.state before.all =
  1185. 'skip$
  1186. { after.semicolon 'output.state := }
  1187. if$
  1188. }
  1189.  
  1190. % \end{macrocode}
  1191. % \DescribeFunction{new.sentence}%
  1192. % \begin{macrocode}
  1193. FUNCTION {new.sentence}
  1194. { output.state after.block =
  1195. 'skip$
  1196. { output.state before.all =
  1197. 'skip$
  1198. { after.sentence 'output.state := }
  1199. if$
  1200. }
  1201. if$
  1202. }
  1203.  
  1204. % \end{macrocode}
  1205. %
  1206. % \DescribeFunction{add.blank}%
  1207. % \begin{macrocode}
  1208. FUNCTION {add.blank}
  1209. { " " * before.all 'output.state :=
  1210. }
  1211.  
  1212. % \end{macrocode}
  1213. %
  1214. % \subsection{Logical functions and various checks}\label{s6.3}
  1215. %
  1216. % Declare few logical functions.
  1217. %
  1218. % \DescribeFunction{not}
  1219. % \begin{macrocode}
  1220. FUNCTION {not}
  1221. { { #0 }
  1222. { #1 }
  1223. if$
  1224. }
  1225.  
  1226. % \end{macrocode}
  1227. % \DescribeFunction{and}
  1228. % \begin{macrocode}
  1229. FUNCTION {and}
  1230. { 'skip$
  1231. { pop$ #0 }
  1232. if$
  1233. }
  1234.  
  1235. % \end{macrocode}
  1236. % \DescribeFunction{or}
  1237. % \begin{macrocode}
  1238. FUNCTION {or}
  1239. { { pop$ #1 }
  1240. 'skip$
  1241. if$
  1242. }
  1243.  
  1244. % \end{macrocode}
  1245. %
  1246. % \DescribeFunction{non.stop}
  1247. % \note{What's the hell? Never used.}
  1248. % \begin{macrocode}
  1249. %FUNCTION {non.stop}
  1250. %{ duplicate$
  1251. % "}" * add.period$
  1252. % #-1 #1 substring$ "." =
  1253. %}
  1254. %
  1255. % \end{macrocode}
  1256. % \DescribeFunction{new.block.checka}
  1257. % Adds |new.block| if the last literal in stack is not empty.
  1258. % \begin{macrocode}
  1259. FUNCTION {new.block.checka}
  1260. { empty$
  1261. 'skip$
  1262. 'new.block
  1263. if$
  1264. }
  1265.  
  1266. % \end{macrocode}
  1267. % \DescribeFunction{new.block.checkb}
  1268. % Adds |new.block| if either of the two last literals in the stack is not empty.
  1269. % \begin{macrocode}
  1270. FUNCTION {new.block.checkb}
  1271. { empty$
  1272. swap$ empty$
  1273. and
  1274. 'skip$
  1275. 'new.block
  1276. if$
  1277. }
  1278.  
  1279. % \end{macrocode}
  1280. % \DescribeFunction{new.sentence.checka}
  1281. % Adds |new.sentence| if the last literal in stack is not empty.
  1282. % \begin{macrocode}
  1283. FUNCTION {new.sentence.checka}
  1284. { empty$
  1285. 'skip$
  1286. 'new.sentence
  1287. if$
  1288. }
  1289.  
  1290. % \end{macrocode}
  1291. % \DescribeFunction{new.sentence.checkb}
  1292. % Adds |new.sentence| if either of the two last literals in the stack is not empty.
  1293. % \begin{macrocode}
  1294. FUNCTION {new.sentence.checkb}
  1295. { empty$
  1296. swap$ empty$
  1297. and
  1298. 'skip$
  1299. 'new.sentence
  1300. if$
  1301. }
  1302.  
  1303. % \end{macrocode}
  1304. % \DescribeFunction{new.dblslash.checka}
  1305. % For |online| entry.
  1306. % \changes{GOST v1.1}{15 Jan 2012}{entry type \texttt{@online} added}
  1307. % \begin{macrocode}
  1308. FUNCTION {new.dblslash.checka}
  1309. { empty$
  1310. 'skip$
  1311. 'new.dblslash
  1312. if$
  1313. }
  1314.  
  1315. % \end{macrocode}
  1316. % \DescribeFunction{field.or.null}
  1317. % Replaces an empty field with null string |""|.
  1318. % \begin{macrocode}
  1319. FUNCTION {field.or.null}
  1320. { duplicate$ empty$
  1321. { pop$ "" }
  1322. 'skip$
  1323. if$
  1324. }
  1325.  
  1326. % \end{macrocode}
  1327. %%
  1328. % \DescribeFunction{either.or.check}
  1329. % \note{Move upwards}
  1330. % \begin{macrocode}
  1331. FUNCTION {either.or.check}
  1332. { empty$
  1333. 'pop$
  1334. { "can't use both " swap$ * " fields in " * cite$ * warning$ }
  1335. if$
  1336. }
  1337.  
  1338. % \end{macrocode}
  1339. %
  1340. % \subsection{String Functions}\label{s6.4}
  1341. %
  1342. % \DescribeFunction{spaces.around}
  1343. % Inserts a space before and after last literal in the stack.
  1344. % \begin{macrocode}
  1345. FUNCTION {spaces.around}
  1346. { " " swap$ * " " * }
  1347.  
  1348. % \end{macrocode}
  1349. %
  1350. % \DescribeFunction{emphasize}
  1351. % Emphasizes the last literal in the stack if it is not empty.
  1352. % v1.2k: |emphasize| now returns empty field if last literal in the stack
  1353. % was empty.
  1354. % \changes{GOST v1.2k}{25 Dec 2020}{function emphasize modified}
  1355. % \changes{GOST v0.8}{10 Aug 2003}{macro \cs{BibEmph} added}
  1356. % \begin{macrocode}
  1357. FUNCTION {emphasize}
  1358. { duplicate$ empty$
  1359. %{ pop$ "" }
  1360. 'skip$ % v.1.2k
  1361. { "\BibEmph{" swap$ * "}" * }
  1362. if$
  1363. }
  1364.  
  1365. % \end{macrocode}
  1366. %
  1367. % \DescribeFunction{bracify}
  1368. % New in v.1.2. An idea borrowed from apsrev4-1.bst.
  1369. % Encloses last literal in the stack by braces even if it is empty. Note that
  1370. % braces are normally not printed by \LaTeX.
  1371. % \begin{macrocode}
  1372. FUNCTION {bracify}
  1373. { duplicate$ empty$
  1374. { pop$ "{}" }
  1375. { "{" swap$ * "}" * }
  1376. if$
  1377. }
  1378.  
  1379. % \end{macrocode}
  1380. % \DescribeFunction{bracketise}
  1381. % This and the next functions are used to enclose last word by square and round
  1382. % brackets. In contrast to |bracify| function they push null string if the
  1383. % last literal is empty.
  1384. % \begin{macrocode}
  1385. FUNCTION {bracketise}
  1386. {
  1387. duplicate$ empty$
  1388. { pop$ "" }
  1389. { "[" swap$ * "]" * }
  1390. if$
  1391. }
  1392.  
  1393. % \end{macrocode}
  1394. % \DescribeFunction{paranthesify}
  1395. % \begin{macrocode}
  1396. FUNCTION {paranthesify}
  1397. {
  1398. duplicate$ empty$
  1399. { pop$ "" }
  1400. { "(" swap$ * ")" * }
  1401. if$
  1402. }
  1403.  
  1404. % \end{macrocode}
  1405. % \DescribeFunction{paranthesify.seies}
  1406. % Enclose series reference section in braces, while allowing to
  1407. % conditionally skip these braces. See
  1408. % \hyperref[macro:DSTUAllowSeriesParentheses]{the description of
  1409. % \cs{DSTUAllowSeriesParentheses}} for details.
  1410. % \begin{macrocode}
  1411. FUNCTION {paranthesify.series}
  1412. {
  1413. duplicate$ empty$
  1414. { pop$ "" }
  1415. { "\ifnum \DSTUAllowSeriesParentheses>0(\fi " swap$ * "\ifnum \DSTUAllowSeriesParentheses>0)\fi{}" * }
  1416. if$
  1417. }
  1418.  
  1419. % \end{macrocode}
  1420. %
  1421. % \DescribeFunction{chop.word}
  1422. %
  1423. % The function |chop.word| in the context `\emph{sstr} \emph{len} \emph{str}
  1424. % |chop.word|' tries to remove given substring \emph{sstr} of the length \emph{len}
  1425. % from the beginning of the string \emph{str}. It trims \emph{str} only if first
  1426. % \emph{len} symbols in \emph{str} coinsides with \emph{sstr}.
  1427. % See examples in Section~\ref{s6.6}.
  1428. % \begin{macrocode}
  1429. %<*sort|natbib>
  1430. INTEGERS { len }
  1431.  
  1432. FUNCTION {chop.word}
  1433. { 's :=
  1434. 'len :=
  1435. s #1 len substring$ =
  1436. { s len #1 + global.max$ substring$ }
  1437. 's
  1438. if$
  1439. }
  1440. %</sort|natbib>
  1441.  
  1442. % \end{macrocode}
  1443. %
  1444. % \DescribeFunction{is.num}
  1445. % Currently not used.
  1446. %
  1447. % \note{Можно использовать для проверки года, извлечённого из |date|.}
  1448. % \begin{macrocode}
  1449. %<*debug>
  1450. FUNCTION {is.num}
  1451. { chr.to.int$
  1452. duplicate$ "0" chr.to.int$ < not
  1453. swap$ "9" chr.to.int$ > not and
  1454. }
  1455.  
  1456. %</debug>
  1457. % \end{macrocode}
  1458. %
  1459. % \DescribeFunction{extract.num}
  1460. % Currently not used.
  1461. % \begin{macrocode}
  1462. %<*debug>
  1463. FUNCTION {extract.num}
  1464. { duplicate$ 't :=
  1465. "" 's :=
  1466. { t empty$ not }
  1467. { t #1 #1 substring$
  1468. t #2 global.max$ substring$ 't :=
  1469. duplicate$ is.num
  1470. { s swap$ * 's := }
  1471. { pop$ "" 't := }
  1472. if$
  1473. }
  1474. while$
  1475. s empty$
  1476. 'skip$
  1477. { pop$ s }
  1478. if$
  1479. }
  1480.  
  1481. %</debug>
  1482. % \end{macrocode}
  1483. %
  1484. % \DescribeFunction{tie.connect}
  1485. % Inserts unbreakable space between last two literals in the stack.
  1486. % \begin{macrocode}
  1487. FUNCTION {tie.connect}
  1488. {"~" swap$ * *
  1489. }
  1490.  
  1491. % \end{macrocode}
  1492. %
  1493. % \DescribeFunction{tie.or.space.connect}
  1494. % Inserts space or unbreakable space between last two literals in the stack
  1495. % depending on the length of last literal.
  1496. % \begin{macrocode}
  1497. FUNCTION {tie.or.space.connect}
  1498. { duplicate$ text.length$ #3 <
  1499. { "~" }
  1500. { " " }
  1501. if$
  1502. swap$ * *
  1503. }
  1504.  
  1505. % \end{macrocode}
  1506. %
  1507. % \DescribeFunction{tie.or.discouragedbreak.connect}
  1508. % Inserts space with discouraged line break or unbreakable space between
  1509. % last two literals in the stack depending on the length of last literal.
  1510. % \changes{1.2}{2025/02/04}{\texttt{tie.or.discouragedbreak.connect} added
  1511. % to add normal spaces with discouraged line break
  1512. % between two strings if second string is too
  1513. % long.}
  1514. % \begin{macrocode}
  1515. FUNCTION {tie.or.discouragedbreak.connect}
  1516. { duplicate$ text.length$ #3 <
  1517. { "~" }
  1518. { "\BibDiscouragedbreakSpace " }
  1519. if$
  1520. swap$ * *
  1521. }
  1522.  
  1523. % \end{macrocode}
  1524. %
  1525. % \DescribeFunction{n.dashify}
  1526. % \begin{macrocode}
  1527. FUNCTION {n.dashify}
  1528. { 't :=
  1529. ""
  1530. { t empty$ not }
  1531. { t #1 #1 substring$ "-" =
  1532. { t #1 #2 substring$ "--" = not
  1533. { "--" *
  1534. t #2 global.max$ substring$ 't :=
  1535. }
  1536. { { t #1 #1 substring$ "-" = }
  1537. { "-" *
  1538. t #2 global.max$ substring$ 't :=
  1539. }
  1540. while$
  1541. }
  1542. if$
  1543. }
  1544. { t #1 #1 substring$ *
  1545. t #2 global.max$ substring$ 't :=
  1546. }
  1547. if$
  1548. }
  1549. while$
  1550. }
  1551.  
  1552. % \end{macrocode}
  1553. %
  1554. % \DescribeFunction{multi.page.check}
  1555. % Returns 1 if the last literal (usually |page|) contains either `|-|', `|,|'
  1556. % or `|+|'; otherwise returns 0.
  1557. % Used in connection with |n.dashify|.
  1558. %
  1559. % \note{Заметим несогласованность функций |multi.page.check| и
  1560. % |n.dashify|. Последняя функция проверяет дефис, а первая ещё и минус и
  1561. % запятую.}
  1562. %
  1563. % \begin{macrocode}
  1564. INTEGERS { multiresult }
  1565.  
  1566. FUNCTION {multi.page.check}
  1567. { 't :=
  1568. #0 'multiresult :=
  1569. { multiresult not
  1570. t empty$ not
  1571. and
  1572. }
  1573. { t #1 #1 substring$
  1574. duplicate$ "-" =
  1575. swap$ duplicate$ "," =
  1576. swap$ "+" =
  1577. or or
  1578. { #1 'multiresult := }
  1579. { t #2 global.max$ substring$ 't := }
  1580. if$
  1581. }
  1582. while$
  1583. multiresult
  1584. }
  1585.  
  1586. % \end{macrocode}
  1587. %
  1588. %
  1589. % \subsection{Language-sensitive abbreviations}\label{s6.5}
  1590. %
  1591. % Declare language-sensitive abbreviations.
  1592. % We provide two versions of any abbreviation for unicode and non-Unicode styles.
  1593. % The language-sensitive functions push to the stack a string that depends of the
  1594. % the current value of the string |curlanguage|. It is set for every entry by
  1595. % |output.bibitem| function. Abbreviations for |russian|, |ukrainian| and |english|
  1596. % values of the string |curlanguage| are always provided, and sometimes for
  1597. % |french| and |german|.
  1598. %
  1599. % \changes{v1.0}{13 Apr. 2023}{Changed \texttt{"під ред."} to more correct
  1600. % \texttt{"за ред."} in Ukrainian.}
  1601. % \DescribeFunction{bbl.edby}
  1602. % \begin{macrocode}
  1603. FUNCTION {bbl.edby}
  1604. { curlanguage "english" =
  1605. {"ed.\ by"}
  1606. { curlanguage "ukrainian" =
  1607. %<!utf8> {"{\cyr\cyrz\cyra\ \cyrr\cyre\cyrd.}"}
  1608. %<utf8> {"за ред."}
  1609. { curlanguage "russian" =
  1610. %<!utf8> {"{\cyr\cyrp\cyro\cyrd\ \cyrr\cyre\cyrd.}"}
  1611. %<utf8> {"под ред."}
  1612. { curlanguage "german" =
  1613. { "ed." }
  1614. {"language is not defined: " curlanguage " in bbl.edby" * * warning$ "Ed.\ by"}
  1615. if$}
  1616. if$}
  1617. if$}
  1618. if$}
  1619.  
  1620. % \end{macrocode}
  1621. % \DescribeFunction{bbl.compiler}
  1622. % \begin{macrocode}
  1623. FUNCTION {bbl.compiler}
  1624. { curlanguage "english" =
  1625. { "Compiler"}
  1626. { curlanguage "german" =
  1627. { "Hrsg." }
  1628. { curlanguage "ukrainian" =
  1629. %<!utf8> {"{\cyr\CYRU\cyrk\cyrl.}"}
  1630. %<utf8> {"{Укл.}"}
  1631. { curlanguage "russian" =
  1632. %<!utf8> {"{\cyr\CYRS\cyro\cyrs\cyrt.}"}
  1633. %<utf8> {"{Сост.}"}
  1634. {"language is not defined: " curlanguage " in bbl.compiler" * * warning$ "Compiler"}
  1635. if$}
  1636. if$}
  1637. if$}
  1638. if$}
  1639.  
  1640. % \end{macrocode}
  1641. % \DescribeFunction{bbl.edition}
  1642. % \begin{macrocode}
  1643. FUNCTION {bbl.edition}
  1644. { curlanguage "english" =
  1645. {"ed."}
  1646. { curlanguage "ukrainian" =
  1647. %<!utf8> {"{\cyr\cyrv\cyri\cyrd.}"}
  1648. %<utf8> {"{вид.}"}
  1649. { curlanguage "russian" =
  1650. %<!utf8> {"{\cyr\cyri\cyrz\cyrd.}"}
  1651. %<utf8> {"{изд.}"}
  1652. { curlanguage "german" =
  1653. {" {aus.}" } %%%% { "Aufl." } ??
  1654. { curlanguage "italian" =
  1655. {"edizione"}
  1656. { curlanguage "french" =
  1657. {"\'{e}dition"}
  1658. {"language is not defined: " curlanguage " in bbl.edition" * * warning$ "ed."}
  1659. if$}
  1660. if$}
  1661. if$}
  1662. if$}
  1663. if$}
  1664. if$}
  1665.  
  1666. % \end{macrocode}
  1667. % \DescribeFunction{bbl.vvolume}
  1668. % \begin{macrocode}
  1669. FUNCTION {bbl.vvolume}
  1670. { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or
  1671. {"Volume"}
  1672. { curlanguage "ukrainian" = curlanguage "russian" = or
  1673. %<!utf8> { "\CYRT\cyro\cyrm" }
  1674. %<utf8> { "Том" }
  1675. { curlanguage "german" =
  1676. {"{Band}"} %%%% { "Volumen" }
  1677. {"language is not defined: " curlanguage " in bbl.vvolume" * * warning$ "Volume"}
  1678. if$}
  1679. if$}
  1680. if$}
  1681.  
  1682. % \end{macrocode}
  1683. % \DescribeFunction{bbl.vvol}
  1684. % \begin{macrocode}
  1685. FUNCTION {bbl.vvol}
  1686. { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or
  1687. {"Vol."}
  1688. { curlanguage "ukrainian" = curlanguage "russian" = or
  1689. %<!utf8> {"\CYRT."}
  1690. %<utf8> {"Т."}
  1691. { curlanguage "german" =
  1692. {"{Bd.}"} %%%% { "Vol." }
  1693. {"language is not defined: " curlanguage " in bbl.vvol" * * warning$ "Vol."}
  1694. if$}
  1695. if$}
  1696. if$}
  1697.  
  1698. % \end{macrocode}
  1699. % \DescribeFunction{bbl.iissue}
  1700. % \begin{macrocode}
  1701. FUNCTION {bbl.iissue}
  1702. { curlanguage "english" =
  1703. {"Issue"}
  1704. { curlanguage "ukrainian" =
  1705. %<!utf8> {"\CYRV\cyri\cyrp\cyru\cyrs\cyrk"}
  1706. %<utf8> {"Випуск"}
  1707. { curlanguage "russian" =
  1708. %<!utf8> {"\CYRV\cyrery\cyrp\cyru\cyrs\cyrk"}
  1709. %<utf8> {"Выпуск"}
  1710. { curlanguage "german" =
  1711. {"{Heft}"} %%%% { "Ausgabe" }
  1712. {"language is not defined: " curlanguage " in bbl.iissue" * * warning$ "Issue"}
  1713. if$}
  1714. if$}
  1715. if$}
  1716. if$}
  1717.  
  1718. % \end{macrocode}
  1719. % \DescribeFunction{bbl.iiss}
  1720. % \begin{macrocode}
  1721. FUNCTION {bbl.iiss}
  1722. { curlanguage "english" =
  1723. {"Iss."}
  1724. { curlanguage "ukrainian" =
  1725. %<!utf8> {"\CYRV\cyri\cyrp."}
  1726. %<utf8> {"Вип."}
  1727. { curlanguage "russian" =
  1728. %<!utf8> {"\CYRV\cyrery\cyrp."}
  1729. %<utf8> {"Вып."}
  1730. { curlanguage "german" =
  1731. {"{H.}"}
  1732. {"language is not defined: " curlanguage " in bbl.iiss" * * warning$ "Iss."}
  1733. if$}
  1734. if$}
  1735. if$}
  1736. if$}
  1737.  
  1738. % \end{macrocode}
  1739. % \DescribeFunction{bbl.of}
  1740. % \begin{macrocode}
  1741. FUNCTION {bbl.of}
  1742. { curlanguage "english" =
  1743. {"of"}
  1744. { curlanguage "german" =
  1745. { "von" }
  1746. { curlanguage "ukrainian" =
  1747. %<!utf8> { "{\cyr\cyrii\cyrz}" }
  1748. %<utf8> { "{із}" }
  1749. { curlanguage "russian" =
  1750. %<!utf8> { "{\cyr\cyri\cyrz}" }
  1751. %<utf8> { "{из}" }
  1752. {"language is not defined: " curlanguage " in bbl.of" * * warning$ "of"}
  1753. if$}
  1754. if$}
  1755. if$}
  1756. if$}
  1757.  
  1758. % \end{macrocode}
  1759. % \DescribeFunction{bbl.etal}
  1760. % \begin{macrocode}
  1761. FUNCTION {bbl.etal}
  1762. { curlanguage "english" =
  1763. {"et~al."}
  1764. { curlanguage "german" =
  1765. { "u.~a." }
  1766. { curlanguage "ukrainian" =
  1767. %<!utf8> {"{\cyr\cyrt\cyra~\cyrii\cyrn.}"}
  1768. %<utf8> {"{та~ін.}"}
  1769. { curlanguage "russian" =
  1770. %<!utf8> {"{\cyr\cyri~\cyrd\cyrr.}"}
  1771. %<utf8> {"и~др."}
  1772. {"language is not defined: " curlanguage " in bbl.etal" * * warning$ "et~al."}
  1773. if$}
  1774. if$}
  1775. if$}
  1776. if$}
  1777.  
  1778. % \end{macrocode}
  1779. % \DescribeFunction{bbl.and}
  1780. % \begin{macrocode}
  1781. FUNCTION {bbl.and}
  1782. { curlanguage "english" =
  1783. {"and"}
  1784. { curlanguage "german" =
  1785. { "und" }
  1786. { curlanguage "ukrainian" =
  1787. %<!utf8> {"{\cyrii}"}
  1788. %<utf8> {"і"}
  1789. { curlanguage "russian" =
  1790. %<!utf8> {"{\cyri}"}
  1791. %<utf8> {"и"}
  1792. { curlanguage "french" =
  1793. {"et"}
  1794. {"language is not defined: " curlanguage " in bbl.and" * * warning$ "and"}
  1795. if$}
  1796. if$}
  1797. if$}
  1798. if$}
  1799. if$}
  1800.  
  1801. % \end{macrocode}
  1802. % \DescribeFunction{bbl.nnumber}
  1803. % \begin{macrocode}
  1804. FUNCTION {bbl.nnumber}
  1805. { curlanguage "english" =
  1806. {"Number"}
  1807. { curlanguage "ukrainian" = curlanguage "russian" = or
  1808. %<!utf8> { "\CYRN\cyro\cyrm\cyre\cyrr" }
  1809. %<utf8> { "{Номер}" }
  1810. { curlanguage "german" =
  1811. {"{Heft}"} %%% { "Anzahl" }
  1812. {"language is not defined: " curlanguage " in bbl.nnumber" * * warning$ "Number"}
  1813. if$}
  1814. if$}
  1815. if$}
  1816.  
  1817. % \end{macrocode}
  1818. % \DescribeFunction{bbl.number}
  1819. % \begin{macrocode}
  1820. FUNCTION {bbl.number}
  1821. { curlanguage "english" =
  1822. {"number"}
  1823. { curlanguage "ukrainian" = curlanguage "russian" = or
  1824. %<!utf8> {"{\cyr\cyrn\cyro\cyrm\cyre\cyrr}"}
  1825. %<utf8> {"{номер}"}
  1826. { curlanguage "german" =
  1827. {"{Heft}"} %%% { "anzahl" }???
  1828. {"language is not defined: " curlanguage " in bbl.number" * * warning$ "number"}
  1829. if$}
  1830. if$}
  1831. if$}
  1832.  
  1833. % \end{macrocode}
  1834. % \DescribeFunction{bbl.nr}
  1835. % Put a "number" specifier corresponding to current language on stack.
  1836. %
  1837. % \changes{v1.0}{29 Sep 2022}{Make "no." number specifier replaceable through \cs{BibEnNo} macro.}
  1838. % \begin{macrocode}
  1839. FUNCTION {bbl.nr}
  1840. { curlanguage "english" =
  1841. {"{\BibEnNo}"}
  1842. { curlanguage "italian" =
  1843. { "no." }
  1844. { curlanguage "ukrainian" = curlanguage "russian" = or
  1845. %<!utf8> { "{\cyr\textnumero}" }
  1846. %<utf8> { "{№}" }
  1847. { curlanguage "german" =
  1848. {"{nu.}"} %%% { "an." }
  1849. { curlanguage "french" =
  1850. { "no." }
  1851. {"language is not defined: " curlanguage " in bbl.nr" * * warning$ "\BibEnNo{}"}
  1852. if$}
  1853. if$}
  1854. if$}
  1855. if$}
  1856. if$}
  1857.  
  1858. % \end{macrocode}
  1859. % \DescribeFunction{bbl.nnr}
  1860. % A capital letter version of number sign.
  1861. % \begin{macrocode}
  1862. FUNCTION {bbl.nnr}
  1863. { curlanguage "english" =
  1864. {"No."}
  1865. { curlanguage "ukrainian" = curlanguage "russian" = or
  1866. %<!utf8> { "{\cyr\textnumero}" }
  1867. %<utf8> { "{№}" }
  1868. { curlanguage "german" =
  1869. {"{H.}"} %%% { "an." }
  1870. {"language is not defined: " curlanguage " in bbl.nnr" * * warning$ "No."}
  1871. if$}
  1872. if$}
  1873. if$}
  1874.  
  1875. % \end{macrocode}
  1876. % \DescribeFunction{bbl.in}
  1877. % \begin{macrocode}
  1878. FUNCTION {bbl.in}
  1879. { curlanguage "english" = curlanguage "german" = or
  1880. {"in"}
  1881. { curlanguage "ukrainian" = curlanguage "russian" = or
  1882. %<!utf8> { "{\cyr\cyrv}" }
  1883. %<utf8> { "{в}" }
  1884. {"language is not defined: " curlanguage " in bbl.in" * * warning$ "in"}
  1885. if$}
  1886. if$}
  1887.  
  1888. % \end{macrocode}
  1889. % \DescribeFunction{bbl.iin}
  1890. % Currently not used.
  1891. % \begin{macrocode}
  1892. FUNCTION {bbl.iin}
  1893. { curlanguage "english" = curlanguage "german" = or
  1894. {"In"}
  1895. { curlanguage "ukrainian" = curlanguage "russian" = or
  1896. %<!utf8> { "\CYRV" }
  1897. %<utf8> { "{В}" }
  1898. {"language is not defined: " curlanguage " in bbl.iin" * * warning$ "In"}
  1899. if$}
  1900. if$}
  1901.  
  1902. % \end{macrocode}
  1903. % \DescribeFunction{bbl.pages}
  1904. % \begin{macrocode}
  1905. FUNCTION {bbl.pages}
  1906. { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or
  1907. {"p."} %%% {"pp."}
  1908. { curlanguage "ukrainian" = curlanguage "russian" = or
  1909. %<!utf8> {"{\cyr\cyrs.}"}
  1910. %<utf8> {"{с.}"}
  1911. { curlanguage "german" =
  1912. {"S."} %%%% { "s." }
  1913. {"language is not defined: " curlanguage " in bbl.pages" * * warning$ "p."}
  1914. if$}
  1915. if$}
  1916. if$}
  1917.  
  1918. % \end{macrocode}
  1919. % \DescribeFunction{bbl.page}
  1920. % \begin{macrocode}
  1921. FUNCTION {bbl.page}
  1922. { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or
  1923. {"p."}
  1924. { curlanguage "ukrainian" = curlanguage "russian" = or
  1925. %<!utf8> {"{\cyr\cyrs.}"}
  1926. %<utf8> {"{с.}"}
  1927. { curlanguage "german" =
  1928. {"S."} %%%% { "s." }
  1929. {"language is not defined: " curlanguage " in bbl.page" * * warning$ "p."}
  1930. if$}
  1931. if$}
  1932. if$}
  1933.  
  1934. % \end{macrocode}
  1935. % \DescribeFunction{bbl.ppages}
  1936. % \begin{macrocode}
  1937. FUNCTION {bbl.ppages}
  1938. { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or
  1939. {"P."} %%%% { "Pp." }
  1940. { curlanguage "ukrainian" = curlanguage "russian" = or
  1941. %<!utf8> {"{\cyr\CYRS.}"}
  1942. %<utf8> {"{С.}"}
  1943. { curlanguage "german" =
  1944. {"S."}
  1945. {"language is not defined: " curlanguage " in bbl.ppages" * * warning$ "P."}
  1946. if$}
  1947. if$}
  1948. if$}
  1949.  
  1950. % \end{macrocode}
  1951. % \DescribeFunction{bbl.ppage}
  1952. % \begin{macrocode}
  1953. FUNCTION {bbl.ppage}
  1954. { curlanguage "english" = curlanguage "french" = or curlanguage "italian" = or
  1955. {"P."}
  1956. { curlanguage "ukrainian" = curlanguage "russian" = or
  1957. %<!utf8> {"{\cyr\CYRS.}"}
  1958. %<utf8> {"{С.}"}
  1959. { curlanguage "german" =
  1960. {"S."}
  1961. {"language is not defined: " curlanguage " in bbl.ppage" * * warning$ "P."}
  1962. if$}
  1963. if$}
  1964. if$}
  1965.  
  1966. % \end{macrocode}
  1967. % \DescribeFunction{bbl.url}
  1968. % Added in version 2016.07.07.
  1969. % \changes{GOST v1.2e}{07 Jul 2016}{\texttt{bbl.url} added to replace URL string}
  1970. % \changes{v1.0}{10 Sep 2022}{Remove legacy "Access mode" notice before URLs
  1971. % for \texttt{dstu2015}.}
  1972. % \begin{macrocode}
  1973. FUNCTION {bbl.url}
  1974. %<*!dstu2015>
  1975. { curlanguage "english" =
  1976. {"Access mode"}
  1977. { curlanguage "ukrainian" =
  1978. %<!utf8> { "{\CYRR\cyre\cyrzh\cyri\cyrm\ \cyrd\cyro\cyrs\cyrt\cyru\cyrp\cyru}" }
  1979. %<utf8> { "{Режим доступу}" }
  1980. { curlanguage "russian" =
  1981. %<!utf8> { "{\CYRR\cyre\cyrzh\cyri\cyrm\ \cyrd\cyro\cyrs\cyrt\cyru\cyrp\cyra}" }
  1982. %<utf8> { "{Режим доступа}" }
  1983. { curlanguage "german" =
  1984. { "{online; abgerufen}" }
  1985. { curlanguage "french" =
  1986. { "Mode d'acc\`{e}s" }
  1987. { "language is not defined: " curlanguage " in bbl.url" * * warning$ "online; accessed" }
  1988. if$}
  1989. if$}
  1990. if$}
  1991. if$}
  1992. if$}
  1993. %</!dstu2015>
  1994. %<*dstu2015>
  1995. { "URL" }
  1996. %</dstu2015>
  1997. % \end{macrocode}
  1998. % \DescribeFunction{bbl.urldate}
  1999. % Added in version 2012.01.15.
  2000. % \changes{GOST v1.2}{13 Feb 2012}{fix \texttt{bbl.urldate} for ukrainian (Andrey Shvajkoy)}
  2001. % \changes{v1.0}{23 Apr 2023}{\texttt{bbl.urldate}: Make first letter capital
  2002. % for \texttt{strict} styles.}
  2003. % \begin{macrocode}
  2004. FUNCTION {bbl.urldate}
  2005. { curlanguage "english" =
  2006. {"online; accessed"}
  2007. { curlanguage "ukrainian" =
  2008. %<!utf8&!strict> { "{\cyrd\cyra\cyrt\cyra\ \cyrz\cyrv\cyre\cyrr\cyrn\cyre\cyrn\cyrn\cyrya}" }
  2009. %<utf8&!strict> { "{дата звернення}" }
  2010. %<!utf8&strict> { "{\CYRD\cyrz\cyrv\cyre\cyrr\cyrn\cyre\cyrn\cyrn\cyrya}" }
  2011. %<utf8&strict> { "{Дата звернення}" }
  2012. { curlanguage "russian" =
  2013. %<!utf8&!strict> { "{\cyrd\cyra\cyrt\cyra\ \cyro\cyrb\cyrr\cyra\cyrshch\cyre\cyrn\cyri\cyrya}" }
  2014. %<utf8&!strict> { "{дата обращения}" }
  2015. %<!utf8&strict> { "{\CYRD\cyra\cyrt\cyra\ \cyro\cyrb\cyrr\cyra\cyrshch\cyre\cyrn\cyri\cyrya}" }
  2016. %<utf8&!strict> { "{Дата обращения}" }
  2017.  
  2018. { curlanguage "german" =
  2019. %<!strict> { "{online; abgerufen}" }
  2020. %<strict> { "{Online; abgerufen}" }
  2021. { curlanguage "french" =
  2022. %<!strict> { "{en ligne; acc\'{e}d\'{e}}" }
  2023. %<strict> { "{En ligne; acc\'{e}d\'{e}}" }
  2024. { "language is not defined: " curlanguage " in bbl.urldate" * * warning$ "online; accessed" }
  2025. if$}
  2026. if$}
  2027. if$}
  2028. if$}
  2029. if$}
  2030.  
  2031. % \end{macrocode}
  2032. % \DescribeFunction{bbl.techreport}
  2033. % \begin{macrocode}
  2034. FUNCTION {bbl.techreport}
  2035. { curlanguage "english" =
  2036. { "Rep." }
  2037. { curlanguage "german" =
  2038. { "Bericht" }
  2039. { curlanguage "russian" =
  2040. %<!utf8> { "{\cyr\CYRO\cyrt\cyrch\cyre\cyrt}" }
  2041. %<utf8> { "{Отчет}" }
  2042. { "language is not defined: " curlanguage " in bbl.techrep" * * warning$ "Rep." }
  2043. if$}
  2044. if$}
  2045. if$}
  2046.  
  2047. % \end{macrocode}
  2048. % \DescribeFunction{bbl.mathesis}
  2049. % \begin{macrocode}
  2050. FUNCTION {bbl.mathesis}
  2051. { curlanguage "english" =
  2052. { "Master's thesis" }
  2053. { curlanguage "german" =
  2054. { "diss.~mag." }
  2055. { curlanguage "russian" =
  2056. %<!utf8> { "{\cyr\cyrk\cyrv\cyra\cyrl\cyri\cyrf\cyri\cyrk\cyra\cyrc\cyri"
  2057. %<!utf8> "\cyro\cyrn\cyrn\cyra\cyrya\ \cyrr\cyra\cyrb\cyro\cyrt\cyra\ " *
  2058. %<!utf8> "\cyrm\cyra\cyrg\cyri\cyrs\cyrt\cyrr\cyra}" * }
  2059. %<utf8> { "{квалификационная работа магистра}" }
  2060. { "language is not defined: " curlanguage " in bbl.mthesis" * * warning$ "Master's thesis" }
  2061. if$}
  2062. if$}
  2063. if$}
  2064.  
  2065. % \end{macrocode}
  2066. % \DescribeFunction{bbl.phdthesis}
  2067. % \changes{GOST v1.2i}{04 Jan 2017}{corrected bbl.phdthesis and bbl.docthesis to comply GOST}
  2068. % \changes{v1.0}{05 Apr 2023}{Ukrainian translation for Ph.\,D..}
  2069. % \begin{macrocode}
  2070. FUNCTION {bbl.phdthesis}
  2071. { curlanguage "english" =
  2072. { "Ph.\,D. thesis" }
  2073. { curlanguage "german" =
  2074. { "diss.~Ph.\,D." }
  2075. { curlanguage "russian" =
  2076. %<!utf8> { "{\cyr\cyrd\cyri\cyrs.\ \ldots\ \cyrk\cyra\cyrn\cyrd. "
  2077. %<!utf8> "\cyrn\cyra\cyru\cyrk}" * }
  2078. %<utf8> { "{дис.\ \ldots\ канд.\ наук}" }
  2079. { curlanguage "french" =
  2080. { "th\`{e}se de doctorat" }
  2081. { curlanguage "ukrainian" =
  2082. %<!utf8> {"\cyr\cyrd\cyri\cyrs.~Ph.\,D."}
  2083. %<utf8> {"дис.~Ph.\,D."}
  2084. { "language is not defined: " curlanguage " in bbl.phdthesis" * * warning$ "Ph.\,D. thesis" }
  2085. if$}
  2086. if$}
  2087. if$}
  2088. if$}
  2089. if$}
  2090.  
  2091. % \end{macrocode}
  2092. % \DescribeFunction{bbl.docthesis}
  2093. % \begin{macrocode}
  2094. FUNCTION {bbl.docthesis}
  2095. { curlanguage "english" =
  2096. { "dr.\,sci. dissertation" }
  2097. { curlanguage "german" =
  2098. { "diss.~dr." }
  2099. { curlanguage "russian" =
  2100. %<!utf8> { "{\cyr\cyrd\cyri\cyrs.\ \ldots\ \cyrd-\cyrr\cyra\ "
  2101. %<!utf8> "\cyrn\cyra\cyru\cyrk}" * }
  2102. %<utf8> { "{дис.\ \ldots\ д-ра наук}" }
  2103. { "language is not defined: " curlanguage " in bbl.docthesis" * * warning$ "Dr.\,Sci. dissertation" }
  2104. if$}
  2105. if$}
  2106. if$}
  2107.  
  2108. % \end{macrocode}
  2109. %
  2110. % \DescribeFunction{bbl.nnoaddress}
  2111. % \changes{v1.0}{23 Apr 2023}{|bbl.nnoaddress| - add "ukrainian".}
  2112. % \begin{macrocode}
  2113. FUNCTION {bbl.nnoaddress}
  2114. { curlanguage "english" =
  2115. { "S.\ l." }
  2116. { curlanguage "russian" = curlanguage "ukrainian" = +
  2117. %<!utf8> { "{\cyr\CYRB.\ \cyrm.}" }
  2118. %<utf8> { "{Б.\ м.}" }
  2119. { "language is not defined: " curlanguage " in bbl.nnoaddress" * * warning$ "S.\ l." }
  2120. if$}
  2121. if$}
  2122.  
  2123. % \end{macrocode}
  2124. % \DescribeFunction{bbl.nopublisher}
  2125. % \changes{v1.0}{23 Apr 2023}{|bbl.nopublisher| - add "ukrainian".}
  2126. % \begin{macrocode}
  2127. FUNCTION {bbl.nopublisher}
  2128. { curlanguage "english" =
  2129. { "s.\ n." }
  2130. { curlanguage "russian" =
  2131. %<!utf8> { "{\cyr\cyrb.\ \cyri.}" }
  2132. %<utf8> { "{б.\ и.}" }
  2133. { curlanguage "ukrainian" =
  2134. %<!utf8> "{\cyr\cyrb.\ \cyrv.}"
  2135. %<utf8> { "б.\ в."}
  2136. { "language is not defined: " curlanguage " in bbl.nopublisher" * * warning$ "s.\ n." }
  2137. if$}
  2138. if$}
  2139. if$}
  2140.  
  2141. % \end{macrocode}
  2142. % \DescribeFunction{bbl.nnopublisher}
  2143. % \changes{v1.0}{23 Apr 2023}{|bbl.nnopublisher| - add "ukrainian".}
  2144. % \begin{macrocode}
  2145. FUNCTION {bbl.nnopublisher}
  2146. { curlanguage "english" =
  2147. { "S.\ n." }
  2148. { curlanguage "russian" =
  2149. %<!utf8> { "{\cyr\CYRB.\ \cyri.}" }
  2150. %<utf8> { "{Б.\ и.}" }
  2151. { curlanguage "ukrainian" =
  2152. %<!utf8> "{\cyr\CYRB.\ \cyrv.}"
  2153. %<utf8> { "Б.\ в."}
  2154. { "language is not defined: " curlanguage " in bbl.nnopublisher" * * warning$ "s.\ n." }
  2155. if$}
  2156. if$}
  2157. if$}
  2158.  
  2159. % \end{macrocode}
  2160. % \DescribeFunction{bbl.media.text}
  2161. % \begin{macrocode}
  2162. FUNCTION {bbl.media.text}
  2163. { curlanguage "english" =
  2164. { "Text" }
  2165. { curlanguage "russian" = curlanguage "ukrainian" = or
  2166. %<!utf8> { "{\cyr\CYRT\cyre\cyrk\cyrs\cyrt}" }
  2167. %<utf8> { "{Текст}" }
  2168. { "language is not defined: " curlanguage " in bbl.media" * * warning$ "Text" }
  2169. if$}
  2170. if$}
  2171.  
  2172. % \end{macrocode}
  2173. % \DescribeFunction{bbl.media.eresource}
  2174. % \begin{macrocode}
  2175. FUNCTION {bbl.media.eresource}
  2176. { curlanguage "english" =
  2177. { "Electronic resource" }
  2178. { curlanguage "russian" =
  2179. %<!utf8> { "{\cyr\CYREREV\cyrl\cyre\cyrk\cyrt\cyrr\cyro\cyrn\cyrn\cyrery\cyrishrt\ "
  2180. %<!utf8> "\cyrr\cyre\cyrs\cyru\cyrr\cyrs}" * }
  2181. %<utf8> { "{Электронный ресурс}" }
  2182. { curlanguage "ukrainian" =
  2183. %<!utf8> { "{\cyr\CYRE\cyrl\cyre\cyrk\cyrt\cyrr\cyro\cyrn\cyrn\cyri\cyrishrt\ "
  2184. %<!utf8> "\cyrr\cyre\cyrs\cyru\cyrr\cyrs}" * }
  2185. %<utf8> { "{Електронний ресурс}" }
  2186. { "language is not defined: " curlanguage " in bbl.media" * * warning$ "Electronic resource" }
  2187. if$}
  2188. if$}
  2189. if$}
  2190.  
  2191. % \end{macrocode}
  2192. % \DescribeFunction{bbl.media.online}
  2193. % \changes{GOST v1.2i}{02 Jan 2017}{\texttt{media} field normalised}
  2194. % \begin{macrocode}
  2195. FUNCTION {bbl.media.online}
  2196. { curlanguage "english" =
  2197. { "Electronic resource online" }
  2198. { curlanguage "russian" =
  2199. %<!utf8> { "{\cyr\CYREREV\cyrl\cyre\cyrk\cyrt\cyrr\cyro\cyrn\cyrn\cyrery\cyrishrt\ "
  2200. %<!utf8> "\cyrr\cyre\cyrs\cyru\cyrr\cyrs\ \cyro\cyrn\cyrl\cyra\cyrishrt\cyrn}" * }
  2201. %<utf8> { "{Электронный ресурс онлайн}" }
  2202. { curlanguage "ukrainian" =
  2203. %<!utf8> { "{\cyr\CYRE\cyrl\cyre\cyrk\cyrt\cyrr\cyro\cyrn\cyrn\cyri\cyrishrt\ "
  2204. %<!utf8> "\cyrr\cyre\cyrs\cyru\cyrr\cyrs\ \cyro\cyrn\cyrl\cyra\cyrishrt\cyr}" * }
  2205. %<utf8> { "{Електронний ресурс онлайн}" }
  2206. { "language is not defined: " curlanguage " in bbl.media" * * warning$ "Electronic resource" }
  2207. if$}
  2208. if$}
  2209. if$}
  2210.  
  2211. % \end{macrocode}
  2212. % \DescribeFunction{bbl.chief}
  2213. % \begin{macrocode}
  2214. FUNCTION {bbl.chief}
  2215. { curlanguage "english" =
  2216. { "chief" }
  2217. { curlanguage "russian" =
  2218. %<!utf8> { "\cyrr\cyru\cyrk." }
  2219. %<utf8> { "{рук.}" }
  2220. { curlanguage "ukrainian" =
  2221. %<!utf8> { "\cyrr\cyru\cyrk." }
  2222. %<utf8> { "{рук.}" }
  2223. { "language is not defined: " curlanguage " in bbl.chief" * * warning$ "chief" }
  2224. if$}
  2225. if$}
  2226. if$}
  2227.  
  2228. % \end{macrocode}
  2229. % \DescribeFunction{bbl.executor}
  2230. % \begin{macrocode}
  2231. FUNCTION {bbl.executor}
  2232. { curlanguage "english" =
  2233. { "executor" }
  2234. { curlanguage "russian" =
  2235. %<!utf8> { "{\cyr\cyri\cyrs\cyrp\cyro\cyrl\cyrn.}" }
  2236. %<utf8> { "{исполн.}" }
  2237. { curlanguage "ukrainian" =
  2238. %<!utf8> { "{\cyr\cyrv\cyri\cyrk\cyro\cyrn\cyra\cyrv\cyre\cyrc\cyrsftsn}" }
  2239. %<utf8> { "{виконавець}" }
  2240. { "language is not defined: " curlanguage " in bbl.executor" * * warning$ "executor" }
  2241. if$}
  2242. if$}
  2243. if$}
  2244.  
  2245. % \end{macrocode}
  2246. % \DescribeFunction{bbl.media}
  2247. % \begin{macrocode}
  2248. FUNCTION {bbl.media}
  2249. { media "online" =
  2250. { bbl.media.online }
  2251. { media "eresource" =
  2252. { bbl.media.eresource }
  2253. { bbl.media.text }
  2254. if$}
  2255. if$}
  2256.  
  2257. % \end{macrocode}
  2258. % \DescribeFunction{bbl.req}
  2259. % \begin{macrocode}
  2260. FUNCTION {bbl.req}
  2261. {
  2262. curlanguage "english" =
  2263. { "req." }
  2264. { curlanguage "german" =
  2265. { "ang." }
  2266. { curlanguage "russian" =
  2267. %<!utf8> { "{\cyr\cyrz\cyra\cyrya\cyrv\cyrl.}" }
  2268. %<utf8> { "{заявл.}" }
  2269. { "language is not defined: " curlanguage " in bbl.req" * * warning$ "req" }
  2270. if$
  2271. }
  2272. if$
  2273. }
  2274. if$
  2275. }
  2276.  
  2277. % \end{macrocode}
  2278. % \DescribeFunction{bbl.publ}
  2279. % \begin{macrocode}
  2280. FUNCTION {bbl.publ}
  2281. {
  2282. curlanguage "english" =
  2283. { "publ." }
  2284. { curlanguage "german" =
  2285. { "ausg." }
  2286. { curlanguage "russian" =
  2287. %<!utf8> { "{\cyr\cyro\cyrp\cyru\cyrb\cyrl.}" }
  2288. %<utf8> { "{опубл.}" }
  2289. { "language is not defined: " curlanguage " in bbl.publication" * * warning$ "publication" }
  2290. if$
  2291. }
  2292. if$
  2293. }
  2294. if$
  2295. }
  2296.  
  2297. % \end{macrocode}
  2298. % \DescribeFunction{bbl.priority}
  2299. % \begin{macrocode}
  2300. FUNCTION {bbl.priority}
  2301. {
  2302. curlanguage "english" =
  2303. { "priority" }
  2304. { curlanguage "german" =
  2305. { "Prioritat" }
  2306. { curlanguage "russian" =
  2307. %<!utf8> { "{\cyr\cyrp\cyrr\cyri\cyro\cyrr\cyri\cyrt\cyre\cyrt}" }
  2308. %<utf8> { "{приоритет}" }
  2309. { "language is not defined: " curlanguage " in bbl.priority" * * warning$ "priority" }
  2310. if$
  2311. }
  2312. if$
  2313. }
  2314. if$
  2315. }
  2316.  
  2317. % \end{macrocode}
  2318. %
  2319. %
  2320. % \DescribeFunction{bbl.jan}
  2321. % \DescribeFunction{bbl.feb}
  2322. % \DescribeFunction{bbl.mar}
  2323. % \DescribeFunction{bbl.apr}
  2324. % \DescribeFunction{bbl.may}
  2325. % \DescribeFunction{bbl.jun}
  2326. % \DescribeFunction{bbl.jul}
  2327. % \DescribeFunction{bbl.aug}
  2328. % \DescribeFunction{bbl.sep}
  2329. % \DescribeFunction{bbl.oct}
  2330. % \DescribeFunction{bbl.nov}
  2331. % \DescribeFunction{bbl.dec}
  2332. % New in version 1.2k.
  2333. % \changes{GOST v1.2k}{22 Jan 2017}{added \texttt{bbl.jan}, \texttt{bbl.feb}, etc.}
  2334. % \begin{macrocode}
  2335. FUNCTION {bbl.jan}
  2336. { curlanguage "english" =
  2337. {"Jan."}
  2338. { curlanguage "ukrainian" =
  2339. %<!utf8> {"\CYRS\cyrii\cyrch."}
  2340. %<utf8> {"Січ."} % Січень
  2341. { curlanguage "russian" =
  2342. %<!utf8> { "\CYRYA\cyrn\cyrv." }
  2343. %<utf8> { "Янв." }
  2344. { curlanguage "german" =
  2345. { "Jan." } % Januar
  2346. { "language is not defined: bbl.jan for " curlanguage * warning$ "Jan." }
  2347. if$}
  2348. if$}
  2349. if$}
  2350. if$}
  2351.  
  2352. FUNCTION {bbl.feb}
  2353. { curlanguage "english" =
  2354. {"Feb."}
  2355. { curlanguage "ukrainian" =
  2356. %<!utf8> {"\CYRL\cyryu\cyrt."}
  2357. %<utf8> {"Лют."} % Лютий
  2358. { curlanguage "russian" =
  2359. %<!utf8> { "\CYRF\cyre\cyrv\cyrr." }
  2360. %<utf8> { "Фев." }
  2361. { curlanguage "german" =
  2362. {"Feb."} % Februar
  2363. {"language is not defined: bbl.feb for " curlanguage * warning$ "Feb."}
  2364. if$}
  2365. if$}
  2366. if$}
  2367. if$}
  2368.  
  2369. FUNCTION {bbl.mar}
  2370. { curlanguage "english" =
  2371. {"Mar."}
  2372. { curlanguage "ukrainian" =
  2373. %<!utf8> {"\CYRB\cyre\cyrr."}
  2374. %<utf8> {"Бер."} % Березень
  2375. { curlanguage "russian" =
  2376. %<!utf8> { "\CYRM\cyra\cyrr\cyrt" }
  2377. %<utf8> { "Март" }
  2378. { curlanguage "german" =
  2379. {"März"} % März
  2380. {"language is not defined: bbl.mar for " curlanguage * warning$ "Mar."}
  2381. if$}
  2382. if$}
  2383. if$}
  2384. if$}
  2385.  
  2386. FUNCTION {bbl.apr}
  2387. { curlanguage "english" =
  2388. {"Apr."}
  2389. { curlanguage "ukrainian" =
  2390. %<!utf8> {"\CYRK\cyrv\cyrii\cyrt."}
  2391. %<utf8> {"Квіт."} % квітень
  2392. { curlanguage "russian" =
  2393. %<!utf8> { "\CYRA\cyrp\cyrr." }
  2394. %<utf8> { "Апр." }
  2395. { curlanguage "german" =
  2396. {"Apr."} % April
  2397. { "language is not defined: bbl.apr for " curlanguage * warning$ "Apr." }
  2398. if$}
  2399. if$}
  2400. if$}
  2401. if$}
  2402.  
  2403. FUNCTION {bbl.may}
  2404. { curlanguage "english" =
  2405. {"May"}
  2406. { curlanguage "ukrainian" =
  2407. %<!utf8> {"\CYRT\cyrr\cyra\cyrv."}
  2408. %<utf8> {"Трав."} % травень
  2409. { curlanguage "russian" =
  2410. %<!utf8> { "\CYRM\cyra\cyrishrt" }
  2411. %<utf8> { "Май" }
  2412. { curlanguage "german" =
  2413. {"Mai"}
  2414. { "language is not defined: bbl.may for " curlanguage * warning$ "May" }
  2415. if$}
  2416. if$}
  2417. if$}
  2418. if$}
  2419.  
  2420. FUNCTION {bbl.jun}
  2421. { curlanguage "english" =
  2422. {"June"}
  2423. { curlanguage "ukrainian" =
  2424. %<!utf8> {"\CYRCH\cyre\cyrr."}
  2425. %<utf8> {"Чер."} % червень
  2426. { curlanguage "russian" =
  2427. %<!utf8> { "\CYRI\cyryu\cyrn\cyrsftsn" }
  2428. %<utf8> { "Июнь" }
  2429. { curlanguage "german" =
  2430. {"Juni"}
  2431. { "language is not defined: bbl.jun for " curlanguage * warning$ "June" }
  2432. if$}
  2433. if$}
  2434. if$}
  2435. if$}
  2436.  
  2437. FUNCTION {bbl.jul}
  2438. { curlanguage "english" =
  2439. {"July"}
  2440. { curlanguage "ukrainian" =
  2441. %<!utf8> {"\CYRL\cyri\cyrp."}
  2442. %<utf8> {"Липень"} %Липень
  2443. { curlanguage "russian" =
  2444. %<!utf8> { "\CYRI\cyryu\cyrl\cyrsftsn" }
  2445. %<utf8> { "Июль" }
  2446. { curlanguage "german" =
  2447. {"Juli"}
  2448. { "language is not defined: bbl.jul for " curlanguage * warning$ "July" }
  2449. if$}
  2450. if$}
  2451. if$}
  2452. if$}
  2453.  
  2454. FUNCTION {bbl.aug}
  2455. { curlanguage "english" =
  2456. {"Aug."}
  2457. { curlanguage "ukrainian" =
  2458. %<!utf8> {"\CYRS\cyre\cyrr."}
  2459. %<utf8> {"Серпень"} % Серпень
  2460. { curlanguage "russian" =
  2461. %<!utf8> { "\CYRA\cyrv\cyrg\." }
  2462. %<utf8> { "Авг." }
  2463. { curlanguage "german" =
  2464. {"Aug."} % August
  2465. { "language is not defined: bbl.aug for " curlanguage * warning$ "Aug." }
  2466. if$}
  2467. if$}
  2468. if$}
  2469. if$}
  2470.  
  2471. FUNCTION {bbl.sep}
  2472. { curlanguage "english" =
  2473. {"Sep."}
  2474. { curlanguage "ukrainian" =
  2475. %<!utf8> {"\CYRV\cyre\cyrr."}
  2476. %<utf8> {"Вер."} % вересень
  2477. { curlanguage "russian" =
  2478. %<!utf8> { "\CYRS\cyre\cyrn\cyrt." }
  2479. %<utf8> { "Сент." }
  2480. { curlanguage "german" =
  2481. {"Sep."} % September
  2482. { "language is not defined: bbl.sep for " curlanguage * warning$ "Sep." }
  2483. if$}
  2484. if$}
  2485. if$}
  2486. if$}
  2487.  
  2488. FUNCTION {bbl.oct}
  2489. { curlanguage "english" =
  2490. {"Oct."}
  2491. { curlanguage "ukrainian" =
  2492. %<!utf8> {"\CYRZH\cyro\cyrn."}
  2493. %<utf8> {"Жов."} % жовтень
  2494. { curlanguage "russian" =
  2495. %<!utf8> { "\CYRO\cyrk\cyrt." }
  2496. %<utf8> { "Окт." }
  2497. { curlanguage "german" =
  2498. {"Okt."} % Oktober
  2499. { "language is not defined: bbl.oct for " curlanguage * warning$ "Oct." }
  2500. if$}
  2501. if$}
  2502. if$}
  2503. if$}
  2504.  
  2505. FUNCTION {bbl.nov}
  2506. { curlanguage "english" =
  2507. {"Nov."}
  2508. { curlanguage "ukrainian" =
  2509. %<!utf8> {"\CYRL\cyri\cyrs."}
  2510. %<utf8> {"Лис."} % листопад
  2511. { curlanguage "russian" =
  2512. %<!utf8> { "\CYRN\cyro\cyrya\cyrb." }
  2513. %<utf8> { "Нояб." }
  2514. { curlanguage "german" =
  2515. {"Nov."} % November
  2516. { "language is not defined: bbl.nov for " curlanguage * warning$ "Nov." }
  2517. if$}
  2518. if$}
  2519. if$}
  2520. if$}
  2521.  
  2522. FUNCTION {bbl.dec}
  2523. { curlanguage "english" =
  2524. {"Dec."}
  2525. { curlanguage "ukrainian" =
  2526. %<!utf8> {"\CYRG\cyrr\cyru\cyrd."}
  2527. %<utf8> {"Груд."} % грудень
  2528. { curlanguage "russian" =
  2529. %<!utf8> { "\CYRD\cyre\cyrk." }
  2530. %<utf8> { "Дек." }
  2531. { curlanguage "german" =
  2532. {"Dez."} % Dezember
  2533. { "language is not defined: bbl.dec for " curlanguage * warning$ "Dec." }
  2534. if$}
  2535. if$}
  2536. if$}
  2537. if$}
  2538. % \end{macrocode}
  2539. %
  2540. % \DescribeFunction{bbl.arxiv}
  2541. % \DescribeFunction{bbl.jstor}
  2542. % \DescribeFunction{bbl.pubmed}
  2543. % \DescribeFunction{bbl.googlebooks}
  2544. % \DescribeFunction{bbl.hdl}
  2545. % New in version 1.2k.
  2546. % \changes{GOST v1.2k}{25 Dec 2020}{added \texttt{bbl.arxiv}, \texttt{bbl.jstor}, etc.}
  2547. % \begin{macrocode}
  2548. FUNCTION {bbl.arxiv}
  2549. { curlanguage "english" =
  2550. { "ArXiv" }
  2551. { curlanguage "ukrainian" =
  2552. %<!utf8> {"ArXiv"}
  2553. %<utf8> {"ArXiv"}
  2554. { curlanguage "russian" =
  2555. %<!utf8> { "ArXiv" }
  2556. %<utf8> { "ArXiv" }
  2557. { curlanguage "german" =
  2558. { "ArXiv" }
  2559. { "language is not defined: bbl.arxiv for " curlanguage * warning$ "ArXiv" }
  2560. if$}
  2561. if$}
  2562. if$}
  2563. if$}
  2564.  
  2565. FUNCTION {bbl.jstor}
  2566. { curlanguage "english" =
  2567. { "JSTOR" }
  2568. { curlanguage "ukrainian" =
  2569. %<!utf8> {"JSTOR"}
  2570. %<utf8> {"JSTOR"}
  2571. { curlanguage "russian" =
  2572. %<!utf8> { "JSTOR" }
  2573. %<utf8> { "JSTOR" }
  2574. { curlanguage "german" =
  2575. { "JSTOR" }
  2576. { "language is not defined: bbl.jstor for " curlanguage * warning$ "JSTOR" }
  2577. if$}
  2578. if$}
  2579. if$}
  2580. if$}
  2581.  
  2582. FUNCTION {bbl.pubmed}
  2583. { curlanguage "english" =
  2584. { "PubMed" }
  2585. { curlanguage "ukrainian" =
  2586. %<!utf8> {"PubMed"}
  2587. %<utf8> {"PubMed"}
  2588. { curlanguage "russian" =
  2589. %<!utf8> { "PubMed" }
  2590. %<utf8> { "PubMed" }
  2591. { curlanguage "german" =
  2592. { "PubMed" }
  2593. { "language is not defined: bbl.pubmed for " curlanguage * warning$ "PubMed" }
  2594. if$}
  2595. if$}
  2596. if$}
  2597. if$}
  2598.  
  2599. FUNCTION {bbl.googlebooks}
  2600. { curlanguage "english" =
  2601. { "Google Books" }
  2602. { curlanguage "ukrainian" =
  2603. %<!utf8> {"Google \CYRK\cyrn\cyri\cyrg\cyri"}
  2604. %<utf8> {"Google Книги"}
  2605. { curlanguage "russian" =
  2606. %<!utf8> { "Google \CYRK\cyrn\cyri\cyrg\cyri" }
  2607. %<utf8> { "Google Книги" }
  2608. { curlanguage "german" =
  2609. { "Google Books" }
  2610. { "language is not defined: bbl.googlebooks for " curlanguage * warning$ "Google Books" }
  2611. if$}
  2612. if$}
  2613. if$}
  2614. if$}
  2615.  
  2616. FUNCTION {bbl.hdl}
  2617. { curlanguage "english" =
  2618. { "Handle.Net" }
  2619. { curlanguage "ukrainian" =
  2620. %<!utf8> {"Handle.Net"}
  2621. %<utf8> {"Handle.Net"}
  2622. { curlanguage "russian" =
  2623. %<!utf8> { "Handle.Net" }
  2624. %<utf8> { "Handle.Net" }
  2625. { curlanguage "german" =
  2626. { "Handle.Net" }
  2627. { "language is not defined: bbl.hdl for " curlanguage * warning$ "Handle.Net" }
  2628. if$}
  2629. if$}
  2630. if$}
  2631. if$}
  2632. % \end{macrocode}
  2633. %
  2634. %
  2635. % \subsection{Aliases}\label{s6.10}
  2636. %
  2637. % Aliases to some fields are introduced with the help of
  2638. % \emph{field1}|.or.|\emph{field2} functions.
  2639. %
  2640. % \DescribeFunction{address.or.location}
  2641. % Pushes |address| field if not empty; otherwise pushes |location| value even
  2642. % if it is empty.
  2643. % \changes{GOST v1.2i}{02 Jan 2017}{\texttt{location} field added as alias to \texttt{address} field}
  2644. % \begin{macrocode}
  2645. %FUNCTION {address.or.location}
  2646. %{
  2647. % address empty$
  2648. % { location empty$
  2649. % 'skip$
  2650. % { location }
  2651. % if$ }
  2652. % { address }
  2653. % if$
  2654. %}
  2655. FUNCTION {address.or.location}
  2656. {
  2657. address empty$
  2658. { location }
  2659. { address }
  2660. if$
  2661. }
  2662.  
  2663. % \end{macrocode}
  2664. %
  2665. % \DescribeFunction{specialitycode.or.number}
  2666. % Pushed |specialitycode| value if not empty; otherwise
  2667. % returns |number| value even if the latter is empty.
  2668. % \changes{GOST v1.2i}{13 Jan 2017}{\texttt{number} field is now alias to \texttt{specialitycode}}
  2669. % \begin{macrocode}
  2670. FUNCTION {specialitycode.or.number}
  2671. {
  2672. specialitycode empty$
  2673. { number }
  2674. { specialitycode }
  2675. if$
  2676. }
  2677.  
  2678. % \end{macrocode}
  2679. %
  2680. % \DescribeFunction{institution.or.school}
  2681. % Pushes |institution| value if not empty; otherwise
  2682. % returns |school| value even if the latter is empty.
  2683. % \changes{GOST v1.2i}{13 Jan 2017}{\texttt{school} field is now alias to \texttt{instituttion}}
  2684. % \begin{macrocode}
  2685. FUNCTION {institution.or.school}
  2686. {
  2687. institution empty$
  2688. { school}
  2689. { institution }
  2690. if$
  2691. }
  2692. % \end{macrocode}
  2693. %
  2694. %
  2695. % \subsection{Formatting dates}\label{s6.7}
  2696. %
  2697. % \note{NEEDS to be located before natbib labels. This is experimental section.
  2698. % Needs to be upgraded.}
  2699. %
  2700. % \DescribeFunction{date.to.year}
  2701. % New in version 1.2k. Extracts year from date. Currently, only the date
  2702. % of the form either |YYYY-MM-DD|, or |YYYY-MM|, or |YYYY| can be processed as
  2703. % expected. Returns |date| if it is empty or has wrong format.
  2704. % \changes{GOST v1.2j}{15 Jan 2017}{new function \texttt{date.to.year}}
  2705. % \begin{macrocode}
  2706. FUNCTION {date.to.year}
  2707. {
  2708. date empty$
  2709. { date }
  2710. {
  2711. %<*debug>
  2712. "date.to.year::: date in " cite$ * " =" * date * warning$
  2713. "date.to.year::: length of date is " date text.length$ int.to.str$ * warning$
  2714. %</debug>
  2715. date text.length$ #3 >
  2716. {
  2717. date #1 #4 substring$ 'y :=
  2718. %<*debug>
  2719. ":::::: y=" y * warning$
  2720. %</debug>
  2721. y
  2722. }
  2723. {
  2724. "wrong format of date in " cite$ * ": date=" * date * warning$
  2725. date
  2726. }
  2727. if$
  2728. }
  2729. if$
  2730. }
  2731.  
  2732. % \end{macrocode}
  2733. %
  2734. % \DescribeFunction{date.to.month}
  2735. % New in version 1.2k. Extracts month from date.
  2736. % Returns |date| if it is empty or has wrong format.
  2737. % \changes{GOST v1.2j}{15 Jan 2017}{new function \texttt{date.to.month}}
  2738. % \begin{macrocode}
  2739. FUNCTION {date.to.month}
  2740. {
  2741. date empty$
  2742. { date }
  2743. {
  2744. %<*debug>
  2745. "date.to.month::: date in " cite$ * " =" * date * warning$
  2746. "date.to.month::: length of date is " date text.length$ int.to.str$ * warning$
  2747. %</debug>
  2748. date text.length$ #6 >
  2749. {
  2750. date #6 #2 substring$ 'm :=
  2751. %<*debug>
  2752. ":::::: m=" m * warning$
  2753. %</debug>
  2754. m
  2755. }
  2756. {
  2757. "wrong format of date in " cite$ * ": date=" * date * warning$
  2758. date
  2759. }
  2760. if$
  2761. }
  2762. if$
  2763. }
  2764.  
  2765. % \end{macrocode}
  2766. %
  2767. % \DescribeFunction{date.to.day}
  2768. % New in version 1.2k. Extracts year from date.
  2769. % Returns |date| if it is empty or has wrong format.
  2770. % \changes{GOST v1.2j}{15 Jan 2017}{new function \texttt{date.to.day}}
  2771. % \begin{macrocode}
  2772. FUNCTION {date.to.day}
  2773. {
  2774. date empty$
  2775. { date }
  2776. {
  2777. %<*debug>
  2778. "date.to.day::: date in " cite$ * " =" * date * warning$
  2779. "date.to.day::: length of date is " date text.length$ int.to.str$ * warning$
  2780. %</debug>
  2781. date text.length$ #10 =
  2782. {
  2783. date #9 #2 substring$ 'd :=
  2784. %<*debug>
  2785. ":::::: d=" d * warning$
  2786. %</debug>
  2787. d
  2788. }
  2789. {
  2790. "wrong format of date in " cite$ * ": date=" * date * warning$
  2791. date
  2792. }
  2793. if$
  2794. }
  2795. if$
  2796. }
  2797.  
  2798. % \end{macrocode}
  2799. %
  2800. % \DescribeFunction{year.or.date.to.year}
  2801. % New in version 1.2k. Returns |year| if not empty; otherwise call |date.to.year|.
  2802. %
  2803. % \note{ВОЗМОЖНО, ПОДОБНЫЕ ФУНКЦИИ ЛУЧШЕ назвать \texttt{this.year}.}
  2804. % \changes{GOST v1.2j}{15 Jan 2017}{new function \texttt{year.or.date.to.year}}
  2805. % \begin{macrocode}
  2806. FUNCTION {year.or.date.to.year}
  2807. {
  2808. year empty$
  2809. {
  2810. %<*debug>
  2811. "year.or.date.to.year::: empty year in " cite$ * warning$
  2812. %</debug>
  2813. date.to.year
  2814. }
  2815. { year }
  2816. if$
  2817. }
  2818.  
  2819. % \end{macrocode}
  2820. %
  2821. % \DescribeFunction{format.month}
  2822. % Reads |month| field and translate standard
  2823. % English abbreviation of months (as defined by |jan|, |feb|, etc. macros below)
  2824. % to current language.
  2825. % \note{НАДО ИЗОБРЕСТИ ЧТО-ТО ВРОДЕ |month.or.date.to.month|
  2826. % (|this.month|).}
  2827. % \changes{GOST v1.2i}{29 Dec 2016}{typo fix in \texttt{format.month}}
  2828. % \begin{macrocode}
  2829. FUNCTION {format.month}
  2830. { month empty$
  2831. { "" }
  2832. { month "Jan." =
  2833. { bbl.jan }
  2834. { month "Feb." =
  2835. { bbl.feb }
  2836. { month "Mar." =
  2837. { bbl.mar }
  2838. { month "Apr." =
  2839. { bbl.apr }
  2840. { month "May" =
  2841. { bbl.may }
  2842. { month "Jun." =
  2843. { bbl.jun }
  2844. { month "Jul." =
  2845. { bbl.jul }
  2846. { month "Aug." =
  2847. { bbl.aug }
  2848. { month "Sep." =
  2849. { bbl.sep }
  2850. { month "Oct." =
  2851. { "Окт." }
  2852. { month "Nov." =
  2853. { bbl.nov }
  2854. { month "Dec." =
  2855. { bbl.dec }
  2856. {
  2857. "unknown month in " cite$ * warning$
  2858. month
  2859. }
  2860. if$}if$}if$}if$}if$}if$}if$}if$}if$}if$}if$}if$}
  2861. if$
  2862. }
  2863. % \end{macrocode}
  2864. %
  2865. % \DescribeFunction{format.date}
  2866. % \changes{GOST v1.2c}{17 Jan 2015}{fix Gost2003: \texttt{"}\texttt{-}\texttt{-}\texttt{-} replaced by macro \cs{BibDash}}
  2867. % \changes{GOST v1.2j}{15 Jan 2017}{extraction of year from date added}
  2868. % \changes{v1.0}{12 Mar 2023}{Remove \cs{BibDash} by default after year in dates for \texttt{dstu2015}.}
  2869. % \begin{macrocode}
  2870. FUNCTION {format.date}
  2871. %{ year empty$
  2872. { year.or.date.to.year empty$
  2873. { month empty$
  2874. { "" }
  2875. { "there's a month but no year in " cite$ * warning$
  2876. format.month
  2877. }
  2878. if$
  2879. }
  2880. { month empty$
  2881. % 'year
  2882. % { year ". \BibDash " format.month * * }
  2883. 'year.or.date.to.year
  2884. %<!dstu2015> { year.or.date.to.year ". \BibDash " format.month * * }
  2885. %<dstu2015> { year.or.date.to.year ". \DSTUBibDash " format.month * * }
  2886. if$
  2887. }
  2888. if$
  2889. }
  2890.  
  2891. % \end{macrocode}
  2892. %
  2893. %
  2894. % \subsection{Formatting names}\label{s6.6}
  2895. %
  2896. % Declare functions to format separate elements of a bibliographic reference.
  2897. %
  2898. % \textbf{Important note}
  2899. %
  2900. % Neither \file{bibtex} nor \file{bibtex8} can handle unicoded text without
  2901. % troubles. In particular, they fail to reduce a Cyrillic name to initials.
  2902. % Therefore we avoid using |f.| primitive (which trims first name to first letter)
  2903. % when option |utf8| is in effect; in the latter caase |ff| primitive is called
  2904. % instead.
  2905. %
  2906. % \begin{macrocode}
  2907. INTEGERS { nameptr namesleft numnames }
  2908.  
  2909. % \end{macrocode}
  2910. %
  2911. % \DescribeFunction{fmt.names.spec}
  2912. % \DescribeFunction{fmt.names.reversespec}
  2913. % Specifications for name formatting with |format.name$|: one for normal
  2914. % order of initials and last name and one for reverse order.
  2915. % \begin{macrocode}
  2916. FUNCTION {fmt.names.spec}
  2917. {
  2918. "{vv~}{ll}{~jj}"
  2919. %<strict> "{,"
  2920. %<!strict> "{"
  2921. %<!(utf8&!bibtexu)> "~f{.\BibFirstNameSpace{}}{.}}"
  2922. %<utf8&!bibtexu> "~ff}"
  2923. * *
  2924. }
  2925.  
  2926. FUNCTION {fmt.names.reversespec}
  2927. {
  2928. %<!(utf8&!bibtexu)> "{f{.\BibFirstNameSpace{}}{.~}}"
  2929. %<utf8&!bibtexu> "{ff}"
  2930. "{vv~}{ll}{~jj}"
  2931. *
  2932. }
  2933.  
  2934. FUNCTION {fmt.names.firstnamespec}
  2935. {
  2936. %<!(utf8&!bibtexu)> "{f.}"
  2937. %<utf8&!bibtexu> "{ff}"
  2938. }
  2939.  
  2940. FUNCTION {fmt.names.lastnamespec}
  2941. {
  2942. "{vv~}{ll}{~jj}"
  2943. }
  2944.  
  2945. % \end{macrocode}
  2946. % \DescribeFunction{fmt.names.single}
  2947. % Format single name from \BibTeX "name list" in variable |s| with
  2948. % position in variable |nameptr|.
  2949. % Takes into acount whether the name is in "responsibility" section of
  2950. % the bibliographic reference and whether it is a special name |"others"|
  2951. % or |"~others"|.
  2952. % \begin{macrocode}
  2953. FUNCTION {fmt.names.single}
  2954. {
  2955. s nameptr fmt.names.lastnamespec format.name$ duplicate$
  2956. duplicate$ "others" = swap$ "~others" = or not
  2957. {
  2958. s nameptr fmt.names.firstnamespec format.name$
  2959. duplicate$ "" =
  2960. 'skip$
  2961. {
  2962. "\BibReplaceFirstNameChars{" swap$ "}" * *
  2963. %<strict> ",~"
  2964. %<!strict> "~"
  2965. swap$ *
  2966. }
  2967. if$ *
  2968. fmt.responsibility.name
  2969. {
  2970. "\DSTUResponsibilityName{" swap$
  2971. "}{"
  2972. s nameptr fmt.names.firstnamespec format.name$
  2973. duplicate$ "" =
  2974. 'skip$
  2975. {
  2976. "\BibReplaceFirstNameChars{" swap$ "}~" * *
  2977. }
  2978. if$
  2979. s nameptr fmt.names.lastnamespec format.name$ *
  2980. "}" * * * *
  2981. }
  2982. 'skip$
  2983. if$
  2984. }
  2985. 'skip$
  2986. if$
  2987. }
  2988.  
  2989. % \end{macrocode}
  2990. %
  2991. % \DescribeFunction{fmt.names.first}
  2992. % \DescribeFunction{fmt.names.three}
  2993. % \DescribeFunction{fmt.names.all}
  2994. % New version of functions formating names. Function name indicates number
  2995. % of persons printed. These functions look for last literal in the stack
  2996. % which should not be empty; hence, they should be called by other functions
  2997. % that checks if the last literal is empty.
  2998. %
  2999. % \changes{v1.2}{09 Jan 2025}{Add automatic usage of
  3000. % \cs{DSTUResponsibilityName} in the
  3001. % responsibility section of bibliographic record.
  3002. % Remove \cs{BibDash} by default after year in
  3003. % dates for \texttt{dstu2015}. Add
  3004. % \cs{DSTUAllowNamesAnd}.}
  3005. % \begin{macrocode}
  3006. FUNCTION {fmt.names.first}
  3007. { 's :=
  3008. #1 'nameptr :=
  3009. fmt.names.single
  3010. }
  3011.  
  3012. FUNCTION {fmt.names.three}
  3013. {
  3014. 's :=
  3015. #1 'nameptr :=
  3016. s num.names$ 'numnames :=
  3017. numnames 'namesleft :=
  3018. { namesleft #0 > }
  3019. { fmt.names.single 't :=
  3020. nameptr #1 >
  3021. { nameptr #4 = numnames #4 > and
  3022. { "others" 't :=
  3023. #1 'namesleft :=
  3024. }
  3025. 'skip$
  3026. if$
  3027. namesleft #1 >
  3028. { ", " * t * }
  3029. { t "others" = t "~others" = or
  3030. %<!strict> { " " * bbl.etal * }
  3031. %<strict> { " " * bbl.etal bracketise *}
  3032. { ", " * t * }
  3033. if$
  3034. }
  3035. if$
  3036. }
  3037. 't
  3038. if$
  3039. nameptr #1 + 'nameptr :=
  3040. namesleft #1 - 'namesleft :=
  3041. }
  3042. while$
  3043. }
  3044.  
  3045. FUNCTION {fmt.names.all}
  3046. { 's :=
  3047. #1 'nameptr :=
  3048. s num.names$ 'numnames :=
  3049. numnames 'namesleft :=
  3050. { namesleft #0 > }
  3051. { fmt.names.single 't :=
  3052. nameptr #1 >
  3053. { namesleft #1 >
  3054. { ", " * t * }
  3055. { numnames #2 > curlanguage "english" = and
  3056. { "\ifnum \DSTUAllowNamesAnd>0, \fi{}" *
  3057. t "others" = t "~others" = or
  3058. %<!strict> { " " * bbl.etal * }
  3059. %<strict> { " " * bbl.etal bracketise * }
  3060. { "\ifnum \DSTUAllowNamesAnd>0 " bbl.and " \else, \fi " * * * t * }
  3061. if$
  3062. }
  3063. {
  3064. t "others" = t "~others" = or
  3065. %<!strict> { " " * bbl.etal * }
  3066. %<strict> { " " * bbl.etal bracketise * }
  3067. { "\ifnum \DSTUAllowNamesAnd>0{} " bbl.and " \else, \fi " * * * t * }
  3068. if$
  3069. }
  3070. if$
  3071. }
  3072. if$
  3073. }
  3074. 't
  3075. if$
  3076. nameptr #1 + 'nameptr :=
  3077. namesleft #1 - 'namesleft :=
  3078. }
  3079. while$
  3080. }
  3081.  
  3082. % \end{macrocode}
  3083. %
  3084. %
  3085. % \subsection{Formatting names (cont.)}\label{s6.9}
  3086. %
  3087. % \DescribeFunction{format.author}
  3088. % Formats a list of authors for the heading part of a bibliographic record
  3089. % by appying either |fmt.names.first|, |fmt.names.three| or |fmt.names.all| to
  3090. % the field |author|, if it is not empty; % otherwise it pushes empty |author|.
  3091. % This allows making a check as in the case of
  3092. % |format.author "author" output.check|.
  3093. %
  3094. % \note{Однако заметим, что все другие
  3095. % функции |format....| пустое поле замещают пустой строкой.}
  3096. % \begin{macrocode}
  3097. %FUNCTION {format.author}
  3098. %{ author empty$
  3099. % %%%{ "" } % < v.1.2k
  3100. % { author } % v.1.2k
  3101. % %{ author format.names emphasize} % 1st if strict, <=3 otherwise
  3102. %%<long> { author fmt.names.all emphasize}
  3103. %%<!long&strict> { author fmt.names.first emphasize}
  3104. %%<!long&!strict> { author fmt.names.three emphasize}
  3105. % if$
  3106. %}
  3107. FUNCTION {format.author}
  3108. {
  3109. author empty$
  3110. { author } %%%'skip$
  3111. %<*long>
  3112. { author fmt.names.all }
  3113. %</long>
  3114. %<*!long>
  3115. {author num.names$ #4 <
  3116. {
  3117. %<strict> author fmt.names.first
  3118. %<!strict> author fmt.names.three
  3119. }
  3120. { "" } %%%'skip$
  3121. if$}
  3122. %</!long>
  3123. if$
  3124. }
  3125.  
  3126. % \end{macrocode}
  3127. %
  3128. % \DescribeFunction{format.bookauthors}
  3129. % Is used only once by |bookauthor.head| called in |inbook| entry.
  3130. % \note{Not used anymore!}
  3131. % \begin{macrocode}
  3132. %<*debug>
  3133. %FUNCTION {format.bookauthors}
  3134. %{ bookauthor empty$
  3135. % { "" }
  3136. % { bookauthor format.names}% cuts to 4 persons if |!strict| option
  3137. % if$
  3138. %}
  3139. %
  3140. %</debug>
  3141. % \end{macrocode}
  3142. %
  3143. % \DescribeFunction{format.author.rest}
  3144. % Formats |author| to be placed after a slash in the zone of responsibiloty of
  3145. % a bibliographic record. In contrast to |output.author.rest| does not check
  3146. % number of items in the |author| field; it is recommended to use
  3147. % |output.author.rest| instead whenever possible.
  3148. % \note{Not used any more.}
  3149. % \begin{macrocode}
  3150. %<*debug>
  3151. FUNCTION {format.author.rest}
  3152. {
  3153. %<*long>
  3154. %%% Does this work?
  3155. %%%skip$ % this seemed to work
  3156. %%% "" % this seemed to work
  3157. %</long>
  3158. %<*!long>
  3159. author empty$
  3160. %%%{ "" } % < v.1.2k
  3161. { author } % v.1.2k
  3162. { author fmt.names.three }
  3163. if$
  3164. %</!long>
  3165. }
  3166.  
  3167. %</debug>
  3168. % \end{macrocode}
  3169. % \DescribeFunction{format.bookauthors.rest}
  3170. % \begin{macrocode}
  3171. FUNCTION {format.bookauthors.rest}
  3172. { bookauthor empty$
  3173. { "" }
  3174. %<long> { bookauthor fmt.names.all emphasize }
  3175. %<!long> { bookauthor fmt.names.three emphasize }
  3176. if$
  3177. }
  3178.  
  3179. % \end{macrocode}
  3180. % \DescribeFunction{format.editors.rest}
  3181. % \begin{macrocode}
  3182. FUNCTION {format.editors.rest}
  3183. { editor empty$
  3184. { "" }
  3185. %<long> { bbl.edby "\ " * editor fmt.names.all * }
  3186. %<!long> { bbl.edby "\ " * editor fmt.names.three * }
  3187. if$
  3188. }
  3189.  
  3190. % \end{macrocode}
  3191. % \DescribeFunction{format.chief.rest}
  3192. % Formats |editor| field for |report| and |techreport| entries.
  3193. % \begin{macrocode}
  3194. FUNCTION {format.chief.rest}
  3195. { editor empty$
  3196. { "" }
  3197. %<long> { bbl.chief "\ " * editor fmt.names.all * }
  3198. %<!long> { bbl.chief "\ " * editor fmt.names.three * }
  3199. if$
  3200. }
  3201.  
  3202. % \end{macrocode}
  3203. % \DescribeFunction{format.executor.rest}
  3204. % \begin{macrocode}
  3205. FUNCTION {format.executor.rest}
  3206. { author empty$
  3207. { "" }
  3208. %<long> { bbl.executor ": " * author fmt.names.all * }
  3209. %<!long> { bbl.executor ": " * author fmt.names.three * }
  3210. if$
  3211. }
  3212.  
  3213. % \end{macrocode}
  3214. % \DescribeFunction{format.compiler.rest}
  3215. % \begin{macrocode}
  3216. FUNCTION {format.compiler.rest}
  3217. { compiler empty$
  3218. { "" }
  3219. %<long> { bbl.compiler "\ " * compiler fmt.names.all * }
  3220. %<!long> { bbl.compiler "\ " * compiler fmt.names.three * }
  3221. if$
  3222. }
  3223.  
  3224. % \end{macrocode}
  3225. %
  3226. %
  3227. % \subsection{Formatting natbib keys}\label{s6.8}
  3228. %
  3229. % \begin{macrocode}
  3230. %<*natbib>
  3231. % \end{macrocode}
  3232. %
  3233. % \DescribeFunction{fmt.names.brief}
  3234. % Formats all names like |fmt.names.all| except that first name of every person is dropped
  3235. % (dropped |ff| and |f.| modifiers).
  3236. %
  3237. % \note{Вероятно, нужно сократить число персон до 3х максимум. Что говорит ГОСТ?
  3238. % Где используется это? В метке ссылки это расгиренный список авторов после
  3239. % краткого списка и года в необязательном аргументе \cs{bibitem}.}
  3240. % \begin{macrocode}
  3241. FUNCTION {fmt.names.brief}
  3242. { 's :=
  3243. #1 'nameptr :=
  3244. s num.names$ 'numnames :=
  3245. numnames 'namesleft :=
  3246. { namesleft #0 > }
  3247. { s nameptr "{vv~}{ll}" format.name$ 't :=
  3248. nameptr #1 >
  3249. {
  3250. namesleft #1 >
  3251. { ", " * t * }
  3252. {
  3253. numnames #2 > curlanguage "english" = and
  3254. { "," * }
  3255. 'skip$
  3256. if$
  3257. t "others" = t "~others" = or
  3258. { " " bbl.etal * * }
  3259. { " " bbl.and " " * * * t * }
  3260. if$
  3261. }
  3262. if$
  3263. }
  3264. 't
  3265. if$
  3266. nameptr #1 + 'nameptr :=
  3267. namesleft #1 - 'namesleft :=
  3268. }
  3269. while$
  3270. }
  3271.  
  3272. % \end{macrocode}
  3273. %
  3274. % \DescribeFunction{format.names.key}
  3275. % Declares function to go to left part of optional argument of |\bibitem| in
  3276. % the bibstyles generated with the option |natbib|. It cuts the list of person
  3277. % to 2 at most and drops first name of every person.
  3278. % \begin{macrocode}
  3279. FUNCTION {format.names.key}
  3280. { 's :=
  3281. set.language %%% уже вызвана в output.bibitem, но вроде бы нужна и здесь
  3282. s #1 "{vv~}{ll}" format.name$
  3283. s num.names$ duplicate$
  3284. #2 >
  3285. { pop$ " " bbl.etal * * }
  3286. { #2 <
  3287. 'skip$
  3288. { s #2 "{ff }{vv }{ll}{ jj}" format.name$ "others" =
  3289. { " " bbl.etal * * }
  3290. { " " bbl.and " " * * * s #2 "{vv~}{ll}" format.name$ * }
  3291. if$
  3292. }
  3293. if$
  3294. }
  3295. if$
  3296. }
  3297.  
  3298. % \end{macrocode}
  3299. %
  3300. % \DescribeFunction{format.key}
  3301. % Substitute an empty last literal in the stack (usually, |author|) with the |key| field
  3302. % if provided. Used as a heading of bibliographic record of |author| is empty.
  3303. % \begin{macrocode}
  3304. FUNCTION {format.key}
  3305. { empty$
  3306. { key field.or.null }
  3307. { "" }
  3308. if$
  3309. }
  3310.  
  3311. % \end{macrocode}
  3312. %
  3313. % \DescribeFunction{author.key.label}
  3314. % Composes a key to be used as a reference label with natbib
  3315. % styles. If |author| field is empty an attempt is made to retrieve |key| field.
  3316. % If it is also empty 3 first letters are retreived from the citation key |cite$|.
  3317. % If |author| field is not empty |format.names.key| defined above is called.
  3318. % \begin{macrocode}
  3319. FUNCTION {author.key.label}
  3320. { author empty$
  3321. { key empty$
  3322. { cite$ #1 #3 substring$ }
  3323. 'key
  3324. if$
  3325. }
  3326. { author format.names.key }
  3327. if$
  3328. }
  3329. % \end{macrocode}
  3330. %
  3331. % \DescribeFunction{author.editor.key.label}
  3332. % \DescribeFunction{author.key.organization.label}
  3333. % \DescribeFunction{editor.key.organization.label}
  3334. % These functions operate similarly but engage a different set of fields. They
  3335. % are called below by |calc.short.list|.
  3336. % \begin{macrocode}
  3337. FUNCTION {author.editor.key.label}
  3338. { author empty$
  3339. { editor empty$
  3340. { key empty$
  3341. { cite$ #1 #3 substring$ }
  3342. %'key %% causes lost of year
  3343. { "{}" key * } %% Bug in bibtex8 ??
  3344. if$
  3345. }
  3346. { editor format.names.key }
  3347. if$
  3348. }
  3349. { author format.names.key }
  3350. if$
  3351. }
  3352.  
  3353. FUNCTION {author.key.organization.label}
  3354. { author empty$
  3355. { key empty$
  3356. { organization empty$
  3357. { cite$ #1 #3 substring$ }
  3358. { "The " #4 organization chop.word #3 text.prefix$ }
  3359. if$
  3360. }
  3361. 'key
  3362. if$
  3363. }
  3364. { author format.names.key }
  3365. if$
  3366. }
  3367.  
  3368. FUNCTION {editor.key.organization.label}
  3369. { editor empty$
  3370. { key empty$
  3371. { organization empty$
  3372. { cite$ #1 #3 substring$ }
  3373. { "The " #4 organization chop.word #3 text.prefix$ }
  3374. if$
  3375. }
  3376. 'key
  3377. if$
  3378. }
  3379. { editor format.names.key }
  3380. if$
  3381. }
  3382.  
  3383. % \end{macrocode}
  3384. %
  3385. % \DescribeFunction{calc.short.list}
  3386. % Calculates |short.list| for |\bibitem| label in natbib styles depending on the type of entry.
  3387. %
  3388. % \note{Нужна внимательная ревизия логики вычислений. В общем-то, она имеет значения в особом
  3389. % случае, когда поле |author| пустое. }
  3390. % \begin{macrocode}
  3391. FUNCTION {calc.short.list}
  3392. { type$ "book" = type$ "inbook" = or
  3393. 'author.editor.key.label
  3394. { type$ "proceedings" =
  3395. 'editor.key.organization.label
  3396. { type$ "manual" =
  3397. 'author.key.organization.label
  3398. 'author.key.label
  3399. if$
  3400. }
  3401. if$
  3402. }
  3403. if$
  3404. 'short.list :=
  3405. }
  3406.  
  3407. % \end{macrocode}
  3408. %
  3409. % \DescribeFunction{calc.label}
  3410. %
  3411. % \note{Вопреки названию, вычисляет только часть метки в [] для
  3412. % \cs{bibitem}. Скобка после года не закрыта, так как еще может
  3413. % быть добавлено a, b, \dots. Лучше перенести весь код |output.bibitem|. }
  3414. % \begin{macrocode}
  3415. FUNCTION {calc.label}
  3416. { calc.short.list
  3417. short.list
  3418. "("
  3419. *
  3420. % year duplicate$ empty$
  3421. year.or.date.to.year duplicate$ empty$
  3422. short.list key field.or.null = or
  3423. { pop$ "" }
  3424. 'skip$
  3425. if$
  3426. *
  3427. 'label :=
  3428. }
  3429.  
  3430. % \end{macrocode}
  3431. %
  3432. % \DescribeFunction{calc.long.list}
  3433. % In case of |natbib| option, we need |calc.long.list| to compose
  3434. % |output.bibitem|, and the latter, in its turn, requires some more functions.
  3435. % \begin{macrocode}
  3436. FUNCTION {calc.long.list} %% called 1 time only
  3437. { type$ "book" = type$ "inbook" = or
  3438. %'format.author.editor.brief
  3439. { author empty$
  3440. { editor empty$
  3441. { "" }
  3442. { editor fmt.names.brief }
  3443. if$
  3444. }
  3445. { author fmt.names.brief }
  3446. if$
  3447. }
  3448. { type$ "proceedings" =
  3449. %'format.editor.brief
  3450. { editor empty$
  3451. { "" }
  3452. { editor fmt.names.brief }
  3453. if$
  3454. }
  3455. %'format.author.brief
  3456. { author empty$
  3457. { "" }
  3458. { author fmt.names.brief }
  3459. if$
  3460. }
  3461. if$
  3462. }
  3463. if$
  3464. }
  3465.  
  3466. % \end{macrocode}
  3467. %
  3468. % \begin{macrocode}
  3469. %</natbib>
  3470. % \end{macrocode}
  3471. %
  3472. %
  3473. % \subsection{Output functions (continued)}\label{s6.11}
  3474. %
  3475. % \DescribeFunction{output.address.publisher}
  3476. % Outputs |address| (or |location|) and |publisher| fields separated by colon
  3477. % if both fields are available; otherwise outputs that field which is not
  3478. % empty.
  3479. % \begin{macrocode}
  3480. %<*!strict>
  3481. FUNCTION {output.address.publisher}
  3482. {
  3483. address empty$ location empty$ and
  3484. 'skip$
  3485. { address.or.location output
  3486. publisher empty$
  3487. 'skip$
  3488. { new.colon }
  3489. if$
  3490. }
  3491. if$
  3492. publisher output
  3493. }
  3494. %</!strict>
  3495. %<*strict>
  3496. FUNCTION {output.address.publisher}
  3497. {
  3498. address empty$
  3499. {
  3500. bbl.nnoaddress
  3501. publisher empty$
  3502. { "~: " * bbl.nopublisher * bracketise }
  3503. { bracketise "~: " * publisher * }
  3504. if$
  3505. }
  3506. {
  3507. address output
  3508. new.colon
  3509. publisher empty$
  3510. { bbl.nopublisher bracketise }
  3511. { publisher }
  3512. if$
  3513. }
  3514. if$
  3515. output
  3516. }
  3517.  
  3518. %</strict>
  3519. % \end{macrocode}
  3520. %
  3521. % \DescribeFunction{output.bibitem}
  3522. % Is called at the beginning of any entry. It sets |curlanguage|
  3523. % string variable based on |langid| or |language| field.
  3524. % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{langid} added}
  3525. % \changes{v1.0}{11 Sep 2022}{Added cleanup of new \texttt{output.needitalic}
  3526. % state variable into \texttt{output.bibitem}.}
  3527. % \changes{v1.2}{08 Jan 2025}{Added cleanup of new \texttt{output.needitalic}
  3528. % state variable into \texttt{output.bibitem}.}
  3529. % \changes{v1.2}{09 Jan 2025}{Added cleanup of new \texttt{fmt.responsibility.name}
  3530. % state variable into \texttt{output.bibitem}.}
  3531. % \begin{macrocode}
  3532. FUNCTION {output.bibitem}
  3533. {
  3534. set.language
  3535. newline$
  3536. "\bibitem" write$
  3537. %<*natbib>
  3538. label extra.label * ")" *
  3539. calc.long.list *
  3540. bracketise write$
  3541. %</natbib>
  3542. cite$ bracify write$
  3543. newline$
  3544. "\selectlanguageifdefined" curlanguage bracify * write$
  3545. newline$
  3546. ""
  3547. before.all 'output.state :=
  3548. #0 'output.needitalic :=
  3549. #0 'fmt.responsibility.name :=
  3550. }
  3551.  
  3552. % \end{macrocode}
  3553. %
  3554. % \begin{macrocode}
  3555. %<*natbib>
  3556. %FUNCTION {output.bibitem}
  3557. %{ newline$
  3558. % "\bibitem" write$
  3559. %% author.key.label
  3560. %% year parenthesify *
  3561. %% "; lbl:" label * *
  3562. %% "; mfn:" calc.long.list * *
  3563. % label
  3564. % calc.long.list *
  3565. % bracketise write$
  3566. % cite$ bracify write$
  3567. % newline$
  3568. % language empty$
  3569. % { "english" 'curlanguage := }
  3570. % {language 'curlanguage := }
  3571. % if$
  3572. % "\selectlanguageifdefined" curlanguage bracify * write$
  3573. % newline$
  3574. % ""
  3575. % before.all 'output.state :=
  3576. %}
  3577.  
  3578. %</natbib>
  3579. % \end{macrocode}
  3580. %
  3581. %
  3582. % \subsection{Formatting title, booktitle, etc.}\label{s6.13}
  3583. %
  3584. % \textbf{Important note}
  3585. %
  3586. % Neither \file{bibtex.exe} nor \file{bibtex8.exe} can handle unicoded text without
  3587. % troubles. In particular, \file{bibtex8} fails to change case of a string if it
  3588. % contains Cyrillic letter. Therefore we avoid using |change.case$| when
  3589. % option |utf8| is applied.
  3590. %
  3591. % \changes{v1.4}{15 Feb 2025}{Book volume is printed only if there is no
  3592. % "series" and/or "issn". Otherwise it is a volume of series. I hope it is
  3593. % always the case.}
  3594. %
  3595. % \DescribeFunction{format.bvolume}
  3596. % \begin{macrocode}
  3597. FUNCTION {format.bvolume}
  3598. { series empty$ issn empty$ and
  3599. { volume empty$
  3600. { "" }
  3601. { bbl.vvol volume tie.connect
  3602. "volume and number if they are not related to series"
  3603. number either.or.check
  3604. }
  3605. if$
  3606. }
  3607. { "" }
  3608. if$
  3609. }
  3610.  
  3611. % \end{macrocode}
  3612. % \DescribeFunction{format.issn}
  3613. % \changes{v1.1}{12 Sep 2023}{Added |format.issn|.}
  3614. % \changes{v1.4}{24 Feb 2025}{Do not print colon symbol (\texttt{:}) by
  3615. % default after ISSN in accordance to
  3616. % DSTU~GOST~7.1-2006.}
  3617. % \begin{macrocode}
  3618. FUNCTION {format.issn}
  3619. {
  3620. issn empty$
  3621. { "" }
  3622. { "ISSN\BibISSNcolon~\href{https://portal.issn.org/resource/ISSN/"; issn *
  3623. "}{" * issn * "}" *
  3624. }
  3625. if$
  3626. }
  3627.  
  3628. % \end{macrocode}
  3629. % \DescribeFunction{format.series.and.issn}
  3630. % \changes{v1.4}{24 Feb 2025}{Do not print colon symbol (\texttt{:}) by
  3631. % default after ISSN in accordance to
  3632. % DSTU~GOST~7.1-2006.}
  3633. % \begin{macrocode}
  3634. FUNCTION {format.series.and.issn}
  3635. {
  3636. format.issn duplicate$ empty$
  3637. { pop$ series field.or.null }
  3638. { series empty$
  3639. { "there's an issn, but no series in " cite$ * warning$ }
  3640. { series swap$ ", " swap$ * * }
  3641. if$
  3642. }
  3643. if$
  3644. }
  3645. % \end{macrocode}
  3646. %
  3647. % \DescribeFunction{format.number.series}
  3648. % Represents the "series section" of bibliographic reference.
  3649. %
  3650. % \changes{v1.0}{29 Sep 2022}
  3651. % {Force nonbreakable space ("tie") between "number sign" and number in
  3652. % series number in \texttt{dstu2015}.}
  3653. % \changes{v1.4}{15 Feb 2025}
  3654. % {Replace nonbreakable space ("tie") between "number sign" and
  3655. % number in series number with
  3656. % \texttt{tie.or.discouragedbreak.connect}.}
  3657. % \changes{v1.4}{24 Feb 2025}{\texttt{format.number.series} from now on
  3658. % prints complete series section in accordance
  3659. % to DSTU~GOST~7.1-2006.}
  3660. % \begin{macrocode}
  3661. FUNCTION {format.number.series}
  3662. {
  3663. number empty$
  3664. { format.series.and.issn
  3665. duplicate$ empty$ volume empty$ or
  3666. 'skip$
  3667. { "~; " *
  3668. bbl.vvol volume tie.connect *
  3669. }
  3670. if$
  3671. }
  3672. { series empty$ issn empty$ and
  3673. { "there's a number but no series or issn in " cite$ * warning$
  3674. bbl.nnr number tie.or.discouragedbreak.connect
  3675. }
  3676. {
  3677. %new.dblslash
  3678. new.sentence
  3679. format.series.and.issn
  3680. volume empty$
  3681. 'skip$
  3682. { "~; "
  3683. bbl.vvol volume tie.connect
  3684. * *
  3685. }
  3686. if$
  3687. "~; "
  3688. bbl.nr number tie.or.discouragedbreak.connect
  3689. * *
  3690. }
  3691. if$
  3692. }
  3693. if$
  3694. paranthesify.series
  3695. }
  3696.  
  3697. % \end{macrocode}
  3698. %
  3699. % \DescribeFunction{eng.ord}
  3700. % Is not currently used.
  3701. % \note{Note that |bbl.st|, |bbl.nd|, |bbl.rd|, |bbl.th|
  3702. % are not defined.}
  3703. % \begin{macrocode}
  3704. %<*debug>
  3705. FUNCTION {eng.ord}
  3706. { duplicate$ "1" swap$ *
  3707. #-2 #1 substring$ "1" =
  3708. { bbl.th * }
  3709. { duplicate$ #-1 #1 substring$
  3710. duplicate$ "1" =
  3711. { pop$ bbl.st * }
  3712. { duplicate$ "2" =
  3713. { pop$ bbl.nd * }
  3714. { "3" =
  3715. { bbl.rd * }
  3716. { bbl.th * }
  3717. if$
  3718. }
  3719. if$
  3720. }
  3721. if$
  3722. }
  3723. if$
  3724. }
  3725. %</debug>
  3726.  
  3727. % \end{macrocode}
  3728. %
  3729. % \DescribeFunction{convert.edition}
  3730. % \begin{macrocode}
  3731. FUNCTION {convert.edition}
  3732. { edition
  3733. % edition extract.num "l" change.case$ 's :=
  3734. % s "first" = s "1" = or
  3735. % { bbl.first 't := }
  3736. % { s "second" = s "2" = or
  3737. % { bbl.second 't := }
  3738. % { s "third" = s "3" = or
  3739. % { bbl.third 't := }
  3740. % { s "fourth" = s "4" = or
  3741. % { bbl.fourth 't := }
  3742. % { s "fifth" = s "5" = or
  3743. % { bbl.fifth 't := }
  3744. % { s #1 #1 substring$ is.num
  3745. % { s eng.ord 't := }
  3746. % { edition 't := }
  3747. % if$
  3748. % }
  3749. % if$
  3750. % }
  3751. % if$
  3752. % }
  3753. % if$
  3754. % }
  3755. % if$
  3756. % }
  3757. % if$
  3758. % t
  3759. }
  3760.  
  3761. % \end{macrocode}
  3762. %
  3763. % \DescribeFunction{format.edition}
  3764. % \begin{macrocode}
  3765. FUNCTION {format.edition}
  3766. { edition empty$
  3767. { "" }
  3768. { output.state mid.sentence =
  3769. %<!(utf8&!bibtexu)> { convert.edition "l" change.case$ " " * bbl.edition * }
  3770. %<!(utf8&!bibtexu)> { convert.edition "t" change.case$ " " * bbl.edition * }
  3771. %<utf8&!bibtexu> { convert.edition " " * bbl.edition * }
  3772. %<utf8&!bibtexu> { convert.edition " " * bbl.edition * }
  3773. if$
  3774. }
  3775. if$
  3776. }
  3777.  
  3778. % \end{macrocode}
  3779. %
  3780. % \DescribeFunction{format.pages}
  3781. % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{eid} added}
  3782. % \begin{macrocode}
  3783. FUNCTION {format.pages}
  3784. { eid empty$
  3785. {
  3786. pages empty$
  3787. { "" }
  3788. { pages multi.page.check
  3789. { bbl.ppages pages n.dashify tie.connect }
  3790. { bbl.ppage pages tie.connect }
  3791. if$
  3792. }
  3793. if$
  3794. }
  3795. { eid multi.page.check
  3796. { bbl.ppages eid n.dashify tie.connect }
  3797. { bbl.ppage eid tie.connect }
  3798. if$
  3799. }
  3800. if$
  3801. }
  3802.  
  3803. % \end{macrocode}
  3804. %
  3805. % \DescribeFunction{format.pages.page}
  3806. % \changes{GOST v1.2c}{18 Jan 2015}{entry field \texttt{eid} added}
  3807. % \changes{GOST v1.2b}{19 Jan 2014}{entry field \texttt{numpages} renamed to \texttt{pagetotal}}
  3808. % \begin{macrocode}
  3809. FUNCTION {format.pages.page}
  3810. { eid empty$
  3811. { pages empty$
  3812. { pagetotal empty$
  3813. { "" }
  3814. { pagetotal bbl.pages tie.connect }
  3815. if$
  3816. }
  3817. { format.pages}
  3818. if$
  3819. }
  3820. { format.pages }
  3821. if$
  3822. }
  3823.  
  3824. % \end{macrocode}
  3825. %
  3826. % \DescribeFunction{format.vol.num.pages}
  3827. % \changes{v1.0}{29 Sep 2022}{Force nonbreakable space ("tie") between
  3828. % "number sign" and number in volume's number of pages.}
  3829. % \begin{macrocode}
  3830. FUNCTION {format.vol.num.pages}
  3831. { volume field.or.null
  3832. number empty$
  3833. 'skip$
  3834. {
  3835. %<!dstu2015> ", {\BibEnNo}" number tie.or.space.connect *
  3836. %<dstu2015> ", {\BibEnNo}~" number *
  3837. volume empty$
  3838. { "there's a number but no volume in " cite$ * warning$ }
  3839. 'skip$
  3840. if$
  3841. }
  3842. if$
  3843. pages empty$
  3844. 'skip$
  3845. { duplicate$ empty$
  3846. { pop$ format.pages }
  3847. { ": " * pages n.dashify * }
  3848. if$
  3849. }
  3850. if$
  3851. }
  3852.  
  3853. % \end{macrocode}
  3854. %
  3855. % \DescribeFunction{format.volume}
  3856. % \changes{v1.2}{2025/02/03}{From now on after "Vol." (or its translation)
  3857. % nonbreaking space is always inserted.}
  3858. % \begin{macrocode}
  3859. FUNCTION {format.volume}
  3860. { volume empty$
  3861. { "" }
  3862. { bbl.vvol volume tie.or.discouragedbreak.connect }
  3863. if$
  3864. }
  3865.  
  3866. % \end{macrocode}
  3867. % \DescribeFunction{format.number}
  3868. % \changes{v1.0}{29 Sep 2022}
  3869. % {Force nonbreakable space ("tie") between "number sign" and number in
  3870. % arbitrary formatted "numbers" in \texttt{dstu2015}.}
  3871. % \begin{macrocode}
  3872. FUNCTION {format.number}
  3873. { number empty$
  3874. { "" }
  3875. %<!dstu2015> { bbl.nr number tie.or.space.connect }
  3876. %<dstu2015> { bbl.nr "~" number * * }
  3877. if$
  3878. }
  3879.  
  3880. % \end{macrocode}
  3881. %
  3882. % \DescribeFunction{format.chapter.pages}
  3883. % \begin{macrocode}
  3884. %<*debug>
  3885. FUNCTION {format.chapter.pages}
  3886. { chapter empty$
  3887. 'format.pages
  3888. { type empty$
  3889. { bbl.chapter }
  3890. { type "l" change.case$ }
  3891. if$
  3892. chapter tie.or.space.connect
  3893. pages empty$
  3894. 'skip$
  3895. { ", " * format.pages * }
  3896. if$
  3897. }
  3898. if$
  3899. }
  3900. %</debug>
  3901.  
  3902. % \end{macrocode}
  3903. %
  3904. % \DescribeFunction{empty.misc.check}
  3905. % \begin{macrocode}
  3906. FUNCTION {empty.misc.check}
  3907. { author empty$ title empty$ howpublished empty$
  3908. month empty$ year empty$ note empty$
  3909. and and and and and
  3910. key empty$ not and
  3911. { "all relevant fields are empty in " cite$ * warning$ }
  3912. 'skip$
  3913. if$
  3914. }
  3915.  
  3916. % \end{macrocode}
  3917. %
  3918. % \DescribeFunction{bbl.thesis.type}
  3919. %
  3920. % \note{ЭТУ ФУНКЦИЮ ПЕРЕНЕСТИ КУДА-ТО ВНИЗ ближе к |format.thesis.type|
  3921. % И объединить с ней (?)}
  3922. % \begin{macrocode}
  3923. FUNCTION {bbl.thesis.type}
  3924. { type "mathesis" =
  3925. { bbl.mathesis }
  3926. { type "phdthesis" =
  3927. { bbl.phdthesis }
  3928. { type "docthesis" =
  3929. { bbl.docthesis }
  3930. %%{ "!!!" type * "t" change.case$ }
  3931. %<!(utf8&!bibtexu)> { type "t" change.case$ }
  3932. %<utf8&!bibtexu> { type }
  3933. if$}
  3934. if$}
  3935. if$}
  3936.  
  3937. % \end{macrocode}
  3938. %
  3939. % \DescribeFunction{format.thesis.type}
  3940. % \begin{macrocode}
  3941. %FUNCTION {format.thesis.type}
  3942. %{ type empty$
  3943. % 'skip$
  3944. % { pop$
  3945. %%<!(utf8&compat)> bbl.thesis.type "t" change.case$
  3946. %%<utf8&compat> bbl.thesis.type
  3947. % }
  3948. % if$
  3949. %}
  3950. FUNCTION {format.thesis.type}
  3951. { type empty$
  3952. 'skip$
  3953. { pop$
  3954. bbl.thesis.type
  3955. }
  3956. if$
  3957. }
  3958. % \end{macrocode}
  3959. %
  3960. % \DescribeFunction{format.techrep.type.number}
  3961. % Function to format report type and number.
  3962. % \begin{macrocode}
  3963. %FUNCTION {format.techrep.type.number}
  3964. %{ type empty$
  3965. % { bbl.techreport }
  3966. % 'type
  3967. % if$
  3968. % number empty$
  3969. %%<!(utf8&compat)> { "t" change.case$ }
  3970. %%<utf8&compat> { "" }
  3971. % { number tie.or.space.connect }
  3972. % if$
  3973. %}
  3974.  
  3975. FUNCTION {format.techreport.type}
  3976. { type empty$
  3977. { bbl.techreport }
  3978. 'type
  3979. if$
  3980. }
  3981.  
  3982. % \end{macrocode}
  3983. %
  3984. % \DescribeFunction{output.author.head}
  3985. % Formats and writes list of authors in the heading of a bibliographic record.
  3986. % The GOST bibstyles skip the list of authors in the beginning of the
  3987. % bibliographic record if the number of authors is 4 or larger except for the
  3988. % styles with suffix |l| which prints all authors in the
  3989. % heading. The bibstyles compiled with the option |struct| print at most 1 person
  3990. % name in the heading.
  3991. % \begin{macrocode}
  3992. FUNCTION {output.author.head}
  3993. {
  3994. author empty$
  3995. 'skip$
  3996. %<*long>
  3997. { author fmt.names.all output.nonnull
  3998. %new.sentence
  3999. }
  4000. %</long>
  4001. %<*!long>
  4002. {author num.names$ #4 <
  4003. {
  4004. %<strict> author fmt.names.first output
  4005. %<!strict> author fmt.names.three output
  4006. new.sentence
  4007. }
  4008. 'skip$
  4009. if$}
  4010. %</!long>
  4011. if$
  4012. }
  4013.  
  4014. % \end{macrocode}
  4015. %
  4016. % \DescribeFunction{bookauthor.head}
  4017. % There are also 2 version of the function |bookauthor.head|.
  4018. % Not used anymore!
  4019. % \begin{macrocode}
  4020. % \end{macrocode}
  4021. %
  4022. % \DescribeFunction{output.author.rest}
  4023. % Writes the rest of authors list after the entry title followed by a slash.
  4024. % In modern bibstyles, the list of authors in the heading part of a bibliographic
  4025. % record is cut to either 3 persons (if no |!strict| option is applied) or 1
  4026. % person (if |strict| option). By idea, |output.author.rest| should print the rest
  4027. % of the authors in the |author| field but currently it also repeats the persons
  4028. % printed in the heading part. |output.author.rest| returns a null string (|""|)
  4029. % if all persons are printed in the heading part of the record. Note that all
  4030. % persons are alwats printed in the heading part if |long| option is applied.
  4031. % \begin{macrocode}
  4032. FUNCTION {output.author.rest}
  4033. {
  4034. %<*!long>
  4035. author empty$
  4036. 'skip$
  4037. %<strict> {author num.names$ #1 >
  4038. %<!strict> {author num.names$ #3 >
  4039. { author fmt.names.all output
  4040. new.semicolon
  4041. }
  4042. 'skip$
  4043. if$}
  4044. if$
  4045. %</!long>
  4046. }
  4047.  
  4048. % \end{macrocode}
  4049. %
  4050. % \DescribeFunction{bookauthor.rest}
  4051. % This function is used only in |inbook| entry. It always cuts list to 4 persons
  4052. % since |format.bookauthors.rest| does that.
  4053. % \begin{macrocode}
  4054. FUNCTION {bookauthor.rest}
  4055. {
  4056. bookauthor empty$
  4057. 'skip$
  4058. {
  4059. %<strict> bookauthor fmt.names.all output
  4060. %<!strict> bookauthor fmt.names.three output
  4061. new.semicolon
  4062. }
  4063. if$
  4064. }
  4065.  
  4066. % \end{macrocode}
  4067. % \DescribeFunction{editor.organization.rest}
  4068. % \begin{macrocode}
  4069. FUNCTION {editor.organization.rest}
  4070. {
  4071. compiler empty$
  4072. {}
  4073. { format.compiler.rest output
  4074. new.semicolon
  4075. }
  4076. if$
  4077. editor empty$
  4078. {}
  4079. { format.editors.rest output.nonnull
  4080. new.semicolon
  4081. }
  4082. if$
  4083. organization empty$
  4084. {}
  4085. {organization output.nonnull
  4086. new.semicolon
  4087. }
  4088. if$
  4089. }
  4090.  
  4091. % \end{macrocode}
  4092. % \DescribeFunction{format.doi}
  4093. % DOI entry formatting function.
  4094. % \changes{v1.0}{11 Sep 2022}{Added DOI entry formatting function
  4095. % \texttt{format.doi}.}
  4096. % \changes{v1.2}{04 Feb 2025}{Added \cs{BibDOIFullURL} switch which makes
  4097. % This style print URLs to |doi.org| instead of
  4098. % just short identifiers.}
  4099. % \begin{macrocode}
  4100. FUNCTION {format.doi}
  4101. { doi empty$
  4102. { "" }
  4103. {
  4104. "DOI: \ifnum \BibDOIFullURL>0\BibUrl{https://doi.org/"; doi *
  4105. "}\else\href{https://doi.org/"; * doi *
  4106. "}{{\urlstyle{same}\nolinkurl{" * doi * "}}}\fi" *
  4107. }
  4108. if$
  4109. }
  4110.  
  4111. % \end{macrocode}
  4112. % \DescribeFunction{format.url}
  4113. % \changes{GOST v0.8}{06 Jun 2003}{macro \cs{BibUrl} added}
  4114. % \changes{v1.0}{23 Apr 2023}{|format.url| - remove braced |urldate| for
  4115. % |strict| styles.}
  4116. % \begin{macrocode}
  4117. FUNCTION {format.url}
  4118. { url empty$
  4119. { "" }
  4120. {
  4121. bbl.url ": \BibUrl{" * url * "}" *
  4122. %<*!strict>
  4123. urldate empty$
  4124. { "" }
  4125. { " (" bbl.urldate * ": " * urldate * ")" * }
  4126. if$ *
  4127. %</!strict>
  4128. }
  4129. if$
  4130. }
  4131.  
  4132. % \end{macrocode}
  4133. % \DescribeFunction{output.url}
  4134. % \changes{v1.0}{23 Apr 2023}{|output.url| - output |urldate| as separate block
  4135. % for |strict| styles.}
  4136. % \begin{macrocode}
  4137. FUNCTION {output.url}
  4138. {
  4139. url empty$
  4140. 'skip$
  4141. { format.url output }
  4142. if$
  4143. %<*strict>
  4144. urldate empty$
  4145. 'skip$
  4146. { new.block bbl.urldate ": " * urldate * output }
  4147. if$
  4148. %</strict>
  4149. }
  4150.  
  4151. % \end{macrocode}
  4152. % \DescribeFunction{format.annote}
  4153. % \changes{GOST v0.8}{06 Jun 2003}{macro \cs{BibAnnote} added}
  4154. % \changes{v1.0}{23 Apr 2023}{|annote| prints as separate block for |strict|
  4155. % styles.}
  4156. % \begin{macrocode}
  4157. FUNCTION {format.annote}
  4158. { annote empty$
  4159. { "" }
  4160. {
  4161. %<!strict> after.sentence 'output.state :=
  4162. %<strict> new.block
  4163. "\BibAnnote{" annote add.period$ * "}" *
  4164. }
  4165. if$
  4166. }
  4167.  
  4168. % \end{macrocode}
  4169. %
  4170. % \DescribeFunction{format.isbn}
  4171. % \note{Do we really need to provide electronic search for ISBN?}
  4172. % \changes{v1.0}{11 Sep 2022}{Fix broken ISBN URL.}
  4173. % \changes{v1.4}{24 Feb 2025}{Do not print colon symbol (\texttt{:}) by
  4174. % default after ISBN in accordance to
  4175. % DSTU~GOST~7.1-2006.}
  4176. % \begin{macrocode}
  4177. FUNCTION {format.isbn}
  4178. {
  4179. isbn empty$
  4180. { "" }
  4181. { "ISBN\BibISBNcolon~\href{https://isbndb.com/book/"; isbn *
  4182. "}{" * isbn * "}" *
  4183. }
  4184. if$
  4185. }
  4186.  
  4187. % \end{macrocode}
  4188. %
  4189. % \DescribeFunction{add.doi}
  4190. % The Digital Object Identifier (DOI) System is for identifying content
  4191. % objects in the digital environment. DOI names are assigned to any entity
  4192. % for use on digital networks. They are used to provide current information,
  4193. % including where they (or information about them) can be found on the
  4194. % Internet. Information about a digital object may change over time,
  4195. % including where to find it, but its DOI name will not change.
  4196. %
  4197. % Function |add.doi| embraces last string in stack into hyperlink
  4198. % that links it to specified |doi| identificator at https://doi.org/ web-site.
  4199. % \changes{GOST v1.2k}{25 Dec 2020}{formatting of \texttt{doi} field updated}
  4200. % \changes{v1.0}{10 Sep 2022}{\texttt{dstu2015} adds separate DOI entry, so
  4201. % suppressing adding clickable DOI URL anywhere
  4202. % else.}
  4203. % \begin{macrocode}
  4204. %<*eprint&!dstu2015>
  4205. FUNCTION {add.doi}
  4206. { duplicate$ empty$
  4207. 'skip$
  4208. { doi empty$
  4209. 'skip$
  4210. { "\href{https://doi.org/"; doi * "}{" * swap$ * "}" * }
  4211. if$
  4212. }
  4213. if$
  4214. }
  4215. %</eprint&!dstu2015>
  4216. % \end{macrocode}
  4217. %
  4218. % If \file{.bst} style is compiled without |eprint| option, we just ignore
  4219. % |doi| field.
  4220. % \begin{macrocode}
  4221. %<*!eprint|dstu2015>
  4222. FUNCTION {add.doi} { }
  4223. %</!eprint|dstu2015>
  4224.  
  4225. % \end{macrocode}
  4226. %
  4227. % \DescribeFunction{add.media}
  4228. % New in version 1.2. Adds |media| field if |strict| options is in effect.
  4229. % If the |media| field is empty |add.media| prints a value based on the |type|
  4230. % field. If the |type| is also empty |add.media| prints equivalent of the
  4231. % word |text| in current language.
  4232. % \begin{macrocode}
  4233. %<*!strict>
  4234. FUNCTION {add.media}
  4235. { duplicate$ empty$
  4236. 'skip$
  4237. { media empty$
  4238. 'skip$
  4239. { " " * bbl.media bracketise * }
  4240. if$
  4241. }
  4242. if$
  4243. }
  4244. %</!strict>
  4245. %<*strict>
  4246. FUNCTION {add.media}
  4247. { duplicate$ empty$
  4248. 'skip$
  4249. { media empty$
  4250. { type$ "online" =
  4251. { " " * bbl.media.online bracketise * }
  4252. { " " * bbl.media.text bracketise * }
  4253. if$
  4254. }
  4255. { " " * bbl.media bracketise * }
  4256. if$
  4257. }
  4258. if$
  4259. }
  4260. %</strict>
  4261.  
  4262. % \end{macrocode}
  4263. %
  4264. % \subsection{Electronic Publishing Information}\label{s6.14}
  4265. %
  4266. % The biblatex package provides three fields for electronic publishing
  4267. % information: |eprint|, |eprinttype|, and |eprintclass|. The |eprint| field
  4268. % is a verbatim field similar to |doi| which holds the identifier of the item.
  4269. % The |eprinttype| field holds the resource name, i. e., the name of the
  4270. % site or electronic archive. Optional |eprintclass| field is intended
  4271. % for additional information specific to the resource indicated by the
  4272. % |eprinttype| field. This could be a section, a path, classification
  4273. % information, etc. If the |eprinttype| field is available, the standard styles
  4274. % will use it as a literal label. In the following example, they would print
  4275. % ``Resource: identifier'' rather than the generic ``eprint: identifier'':
  4276. % \begin{verbatim}
  4277. % eprint = {identifier},
  4278. % eprinttype = {Resource},
  4279. % \end{verbatim}
  4280. %
  4281. % \DescribeFunction{format.eprint}
  4282. % The electronic identifier of an online publication.
  4283. % This is roughly comparable to a |doi| but specific to a certain archive,
  4284. % repository, service, or system.
  4285. % Also see eprinttype and eprintclass.
  4286. %
  4287. % \note{This function should use url. TO BE DONE YET.}
  4288. % \changes{GOST v1.2}{26 Jan 2012}{entry fields \texttt{eprint}, \texttt{eprintclass}, \texttt{eprinttype}}
  4289. % \begin{macrocode}
  4290. %<*eprint>
  4291. %FUNCTION {format.eprint}
  4292. %{ eprint empty$
  4293. % { "" }
  4294. % { eprintclass empty$
  4295. % { " \href{http://arxiv.org/abs/"; eprint * "}" * "{" * eprint * "}" * }
  4296. % { eprinttype empty$
  4297. % { " \href{http://arxiv.org/abs/"; eprint * "}" *
  4298. % "{" * eprintclass * "/" * eprint * "}" *
  4299. % }
  4300. % { " \href{http://arxiv.org/abs/"; eprint * "}" *
  4301. % "{" * eprinttype * ":" * eprintclass * "/" * eprint * "}" *
  4302. % }
  4303. % if$}
  4304. % if$}
  4305. %if$}
  4306.  
  4307. %FUNCTION {format.eprint}
  4308. %{ eprint empty$
  4309. % { "" }
  4310. % { eprinttype empty$
  4311. % { "" }
  4312. % { eprinttype "~: " *}
  4313. % if$
  4314. % eprintclass empty$
  4315. % { }
  4316. % { eprintclass * "/" *}
  4317. % if$
  4318. % eprint *
  4319. % }
  4320. % if$
  4321. % url empty$
  4322. % { }
  4323. % { "\href{" url * "}{" * swap$ * "}" *}
  4324. % if$
  4325. %}
  4326.  
  4327. FUNCTION {format.eprint}
  4328. { eprint empty$
  4329. { "" }
  4330. { eprinttype empty$
  4331. { "" }
  4332. { eprinttype "~: " *}
  4333. if$
  4334. eprintclass empty$
  4335. { }
  4336. { eprintclass * "/" *}
  4337. if$
  4338. url empty$
  4339. { eprint * }
  4340. { "\href{" * url * "}{" * eprint * "}" *}
  4341. if$
  4342. }
  4343. if$
  4344. }
  4345.  
  4346. FUNCTION {output.eprint.url}
  4347. {
  4348. eprint empty$
  4349. { output.url }
  4350. { format.eprint output }
  4351. if$
  4352. }
  4353.  
  4354. %</eprint>
  4355.  
  4356. %<*!eprint>
  4357. FUNCTION {output.eprint.url}
  4358. {
  4359. output.url
  4360. }
  4361. %</!eprint>
  4362.  
  4363. % \end{macrocode}
  4364. %
  4365. % Functions added in v1.2f to format patent entry (thanks to Stanislav Kruchinin).
  4366. %
  4367. % \changes{GOST v1.2f}{12 Jul 2016}{entry field \texttt{patent} added}
  4368. % \changes{v1.0}{29 Sep 2022}
  4369. % {Force nonbreakable space ("tie") between "number sign" and
  4370. % number in arbitrary "added" "numbers" in \texttt{dstu2015}.}
  4371. % \DescribeFunction{add.number}
  4372. % \begin{macrocode}
  4373. FUNCTION {add.number}
  4374. { duplicate$ empty$
  4375. { "" }
  4376. %<!dstu2015> { bbl.nr swap$ tie.or.space.connect }
  4377. %<dstu2015> { bbl.nr swap$ "~" swap$ * * }
  4378. if$
  4379. }
  4380.  
  4381. % \end{macrocode}
  4382. % \DescribeFunction{format.type.number}
  4383. % \begin{macrocode}
  4384. FUNCTION {format.type.number}
  4385. {
  4386. type empty$
  4387. { "" }
  4388. {
  4389. number empty$
  4390. { "" }
  4391. { type number tie.or.space.connect }
  4392. if$
  4393. }
  4394. if$
  4395. }
  4396.  
  4397. % \end{macrocode}
  4398. % \DescribeFunction{format.requestdate}
  4399. % \begin{macrocode}
  4400. FUNCTION {format.requestdate}
  4401. { requestdate empty$
  4402. { "" }
  4403. { bbl.req requestdate tie.or.space.connect }
  4404. if$
  4405. }
  4406.  
  4407. % \end{macrocode}
  4408. % \DescribeFunction{format.publicationdate}
  4409. % \begin{macrocode}
  4410. FUNCTION {format.publicationdate}
  4411. { publicationdate empty$
  4412. { "" }
  4413. { bbl.publ publicationdate tie.or.space.connect }
  4414. if$
  4415. }
  4416.  
  4417. % \end{macrocode}
  4418. %
  4419. % \DescribeFunction{format.prioritydate}
  4420. % \begin{macrocode}
  4421. FUNCTION {format.prioritydate}
  4422. { prioritydate empty$
  4423. { "" }
  4424. { bbl.priority prioritydate tie.or.space.connect }
  4425. if$
  4426. }
  4427.  
  4428. % \end{macrocode}
  4429. % \DescribeFunction{format.journal.series}
  4430. % \changes{v1.0}{05 Apr 2023}
  4431. % {Added combining of \texttt{journal} and \texttt{series} for articles.}
  4432. % \begin{macrocode}
  4433. FUNCTION {format.journal.series}
  4434. { journal
  4435. series empty$
  4436. { skip$ }
  4437. { add.period$ series tie.or.space.connect }
  4438. if$
  4439. }
  4440.  
  4441. % \end{macrocode}
  4442. %
  4443. % \subsection{Entry types}
  4444. %
  4445. % Text below in this section is borrowed from biblatex manual. Not every
  4446. % field listed below is actually supported by GOST styles. So description
  4447. % below should be considered as a goal or a feature request.
  4448. %
  4449. % The lists below indicate the fields supported by each entry type.
  4450. % Note that the mapping of fields to an entry type is ultimately at the
  4451. % discretion of the bibliography style. The lists below therefore serve
  4452. % two purposes. They indicate the fields supported by the standard styles
  4453. % which ship with this package and they also serve as a model for custom
  4454. % styles. Note that the required fields are not strictly required
  4455. % in all cases. The fields marked as optional
  4456. % are optional in a technical sense. Bibliographical formatting rules
  4457. % usually require more than just the required fields. The standard
  4458. % styles will generally not perform any formal validity checks, but
  4459. % custom styles may do so. Generic fields like abstract and annotation
  4460. % or label and shorthand are not included in the lists below because they
  4461. % are independent of the entry type.
  4462. %
  4463. % \subsubsection{Regular Types}
  4464. %
  4465. % \DescribeFunction{article}
  4466. % An article in a journal, magazine, newspaper, or other periodical which forms a
  4467. % self-contained unit with its own title. The title of the periodical is given in the
  4468. % journaltitle field. If the issue has its own title in addition to the main title of
  4469. % the periodical, it goes in the issuetitle field. Note that editor and related fields
  4470. % refer to the journal while translator and related fields refer to the article.
  4471. %
  4472. % Required fields: author, title, journaltitle, year/date.
  4473. %
  4474. % Optional fields: translator, annotator, commentator, subtitle, titleaddon,
  4475. % editor, editora, editorb, editorc, journalsubtitle, issuetitle,
  4476. % issuesubtitle, language, origlanguage, series, volume, number, eid, issue,
  4477. % month, pages, version, note, issn, addendum, pubstate, doi, eprint,
  4478. % eprintclass, eprinttype, url, urldate.
  4479. %
  4480. % \changes{v1.1}{23 Sep 2023}{Added ISSN to articles.}
  4481. % \changes{v1.2}{08 Jan 2025}{Fixed unexpected comma after authors of
  4482. % articles in bibliographic records formatted
  4483. % with "l" styles.
  4484. % }
  4485. % \begin{macrocode}
  4486. FUNCTION {article}
  4487. {
  4488. output.bibitem
  4489. output.author.head
  4490. new.sentence
  4491. %<natbib> author format.key output
  4492. title add.media "title" output.check
  4493. new.slash
  4494. output.author.rest
  4495. new.dblslash
  4496. format.journal.series emphasize add.doi "journal" output.check % new in v1.2
  4497. new.block
  4498. format.date "year/date" output.check
  4499. new.block
  4500. format.volume output
  4501. format.number output
  4502. new.block
  4503. format.pages.page output
  4504. new.block
  4505. format.issn output
  4506. new.block
  4507. note output
  4508. new.sentence
  4509. %<dstu2015> format.doi output
  4510. %<dstu2015> new.block
  4511. % output.url
  4512. output.eprint.url
  4513. format.annote output
  4514. fin.entry
  4515. }
  4516.  
  4517. % \end{macrocode}
  4518. %
  4519. % \DescribeFunction{book}
  4520. % A \sout{single-volume} book with one or more authors where the authors
  4521. % share credit for the work as a whole. In biblatex, this entry type also
  4522. % covers the function of the |@inbook| type of traditional BibTeX.
  4523. %
  4524. % Required fields: author, title, year/date.
  4525. %
  4526. % Optional fields: editor, editora, editorb, editorc, translator, annotator,
  4527. % commentator, introduction, foreword, afterword, subtitle, titleaddon,
  4528. % maintitle, mainsubtitle, maintitleaddon, language, origlanguage, volume,
  4529. % part, edition, volumes, series, number, note, publisher, location, isbn,
  4530. % chapter, pages, pagetotal, addendum, pubstate, doi, eprint, eprintclass,
  4531. % eprinttype, url, urldate.
  4532. % \begin{macrocode}
  4533. FUNCTION {book}
  4534. {
  4535. output.bibitem
  4536. output.author.head
  4537. new.sentence
  4538. %<natbib> author format.key output
  4539. title add.doi add.media "title" output.check
  4540. new.colon % added in v.1.2k
  4541. titleaddon output % added in v.1.2k
  4542. new.slash
  4543. output.author.rest
  4544. editor.organization.rest
  4545. new.sentence
  4546. format.edition output
  4547. new.block
  4548. output.address.publisher
  4549. format.date "year/date" output.check
  4550. new.block
  4551. format.bvolume output
  4552. new.block
  4553. format.pages.page output
  4554. new.block
  4555. format.number.series output
  4556. new.block
  4557. %<eprint> format.isbn output
  4558. %<eprint> new.block
  4559. note output
  4560. new.sentence
  4561. %<dstu2015> format.doi output
  4562. %<dstu2015> new.block
  4563. % output.url
  4564. output.eprint.url
  4565. format.annote output
  4566. fin.entry
  4567. }
  4568.  
  4569. % \end{macrocode}
  4570. %
  4571. % \DescribeFunction{booklet}
  4572. % A book-like work without a formal publisher or sponsoring institution. Use the
  4573. % field howpublished to supply publishing information in free format, if applicable.
  4574. % The field type may be useful as well.
  4575. %
  4576. % Required fields: author/editor, title, year/date.
  4577. %
  4578. % Optional fields: subtitle, titleaddon, language, howpublished, type, note,
  4579. % location, chapter, pages, pagetotal, addendum, pubstate, doi, eprint,
  4580. % eprintclass, eprinttype, url, urldate.
  4581. %
  4582. % \begin{macrocode}
  4583. FUNCTION {booklet}
  4584. {
  4585. output.bibitem
  4586. output.author.head
  4587. new.sentence
  4588. %<natbib> author format.key output
  4589. title add.doi add.media "title" output.check
  4590. new.colon % added in v.1.2k
  4591. titleaddon output % added in v.1.2k
  4592. new.slash
  4593. output.author.rest
  4594. editor.organization.rest
  4595. new.block
  4596. howpublished output
  4597. address.or.location output
  4598. format.date "year/date" output.check
  4599. new.block
  4600. note output
  4601. new.sentence
  4602. %<dstu2015> format.doi output
  4603. %<dstu2015> new.block
  4604. % output.url
  4605. output.eprint.url
  4606. format.annote output
  4607. fin.entry
  4608. }
  4609.  
  4610. % \end{macrocode}
  4611. %
  4612. % \DescribeFunction{inbook}
  4613. % A part of a book which forms a self-contained unit with its own title.
  4614. % Note that the profile of this entry type is different from standard BibTeX.
  4615. %
  4616. % Required fields: author, title, booktitle, year/date.
  4617. %
  4618. % Optional fields: bookauthor, editor, editora, editorb, editorc, translator,
  4619. % annotator, commentator, introduction, foreword, afterword, subtitle,
  4620. % titleaddon, maintitle, mainsubtitle, maintitleaddon, booksubtitle,
  4621. % booktitleaddon, language, origlanguage, volume, part, edition, volumes,
  4622. % series, number, note, publisher, location, isbn, chapter, pages, addendum,
  4623. % pubstate, doi, eprint, eprintclass, eprinttype, url, urldate.
  4624. % \begin{macrocode}
  4625. FUNCTION {inbook}
  4626. {
  4627. output.bibitem
  4628. output.author.head
  4629. new.sentence
  4630. %<natbib> author format.key output
  4631. title add.doi add.media "title" output.check
  4632. new.colon % added in v.1.2k
  4633. titleaddon output % added in v.1.2k
  4634. new.slash
  4635. output.author.rest
  4636. new.dblslash
  4637. % bookauthor.head
  4638. booktitle "booktitle" output.check
  4639. new.slash
  4640. bookauthor.rest
  4641. editor.organization.rest
  4642. new.block
  4643. format.edition output
  4644. new.sentence
  4645. output.address.publisher
  4646. format.date "year/date" output.check
  4647. new.block
  4648. format.bvolume output
  4649. new.block
  4650. format.pages.page output
  4651. new.block
  4652. format.number.series output
  4653. new.block
  4654. %<eprint> format.isbn output
  4655. %<eprint> new.block
  4656. note output
  4657. new.sentence
  4658. %<dstu2015> format.doi output
  4659. %<dstu2015> new.block
  4660. % output.url
  4661. output.eprint.url
  4662. format.annote output
  4663. fin.entry
  4664. }
  4665.  
  4666. % \end{macrocode}
  4667. %
  4668. % \DescribeFunction{incollection}
  4669. % A contribution to a collection which forms a self-contained unit with a distinct
  4670. % author and title. The author refers to the title, the editor to the booktitle,
  4671. % i. e., the title of the collection.
  4672. %
  4673. % Required fields: author, editor, title, booktitle, year/date.
  4674. %
  4675. % Optional fields: editora, editorb, editorc, translator, annotator,
  4676. % commentator, introduction, foreword, afterword, subtitle, titleaddon,
  4677. % maintitle, mainsubtitle, maintitleaddon, booksubtitle, booktitleaddon,
  4678. % language, origlanguage, volume, part, edition, volumes, series, number,
  4679. % note, publisher, location, isbn, chapter, pages, addendum, pubstate, doi,
  4680. % eprint, eprintclass, eprinttype, url, urldate.
  4681. % \begin{macrocode}
  4682. FUNCTION {incollection}
  4683. {
  4684. output.bibitem
  4685. output.author.head
  4686. new.sentence
  4687. %<natbib> author format.key output
  4688. new.sentence
  4689. title add.doi add.media "title" output.check
  4690. new.colon % added in v.1.2k
  4691. titleaddon output % added in v.1.2k
  4692. new.slash
  4693. output.author.rest
  4694. new.dblslash
  4695. booktitle "booktitle" output.check
  4696. new.slash
  4697. editor.organization.rest
  4698. new.block
  4699. output.address.publisher
  4700. format.date "year/date" output.check
  4701. new.block
  4702. format.bvolume output
  4703. new.block
  4704. format.number.series output
  4705. new.block
  4706. format.pages.page output
  4707. new.block
  4708. note output
  4709. new.sentence
  4710. %<dstu2015> format.doi output
  4711. %<dstu2015> new.block
  4712. % output.url
  4713. output.eprint.url
  4714. format.annote output
  4715. fin.entry
  4716. }
  4717.  
  4718. % \end{macrocode}
  4719. %
  4720. % \DescribeFunction{proceedings}
  4721. % A single-volume conference proceedings. This type is very similar to @collection.
  4722. % It supports an optional organization field which holds the sponsoring institution.
  4723. % The editor is omissible.
  4724. %
  4725. % Required fields: editor, title, year/date.
  4726. %
  4727. % Optional fields: subtitle, titleaddon, maintitle, mainsubtitle,
  4728. % maintitleaddon, eventtitle, eventdate, venue, language, volume, part,
  4729. % volumes, series, number, note, organization, publisher, location, month,
  4730. % isbn, chapter, pages, pagetotal, addendum, pubstate, doi, eprint,
  4731. % eprintclass, eprinttype, url, urldate.
  4732. % \begin{macrocode}
  4733. FUNCTION {proceedings}
  4734. {
  4735. output.bibitem
  4736. %<natbib> editor format.key output
  4737. title add.doi add.media "title" output.check
  4738. new.colon % added in v.1.2k
  4739. titleaddon output % added in v.1.2k
  4740. new.slash
  4741. editor.organization.rest
  4742. new.block
  4743. output.address.publisher % 1.2k moved from below
  4744. new.block % added in v.1.2k
  4745. format.date "year/date" output.check
  4746. new.block
  4747. format.bvolume output
  4748. new.block
  4749. format.pages.page output
  4750. %%%output.address.publisher % 1.2k moved upper
  4751. new.block
  4752. format.number.series output
  4753. new.block
  4754. note output
  4755. new.sentence
  4756. %<dstu2015> format.doi output
  4757. %<dstu2015> new.block
  4758. % output.url
  4759. output.eprint.url
  4760. format.annote output
  4761. fin.entry
  4762. }
  4763.  
  4764. % \end{macrocode}
  4765. %
  4766. % \DescribeFunction{inproceedings}
  4767. % An article in a conference proceedings. This type is similar to @incollection. It
  4768. % supports an optional organization field.
  4769. %
  4770. % Required fields: author, editor, title, booktitle, year/date.
  4771. %
  4772. % Optional fields: subtitle, titleaddon, maintitle, mainsubtitle,
  4773. % maintitleaddon, booksubtitle, booktitleaddon, eventtitle, eventdate,
  4774. % venue, language, volume, part, volumes, series, number, note, organization,
  4775. % publisher, location, month, isbn, chapter, pages, addendum, pubstate, doi,
  4776. % eprint, eprintclass, eprinttype, url, urldate.
  4777. % \changes{GOST v0.9}{07 Oct 2003}{bug fix in \texttt{@inproceedings} entry type}
  4778. % \begin{macrocode}
  4779. FUNCTION {inproceedings}
  4780. { output.bibitem
  4781. output.author.head
  4782. new.sentence
  4783. %<natbib> author format.key output
  4784. new.sentence
  4785. title add.doi add.media "title" output.check
  4786. new.colon % added in v.1.2k
  4787. titleaddon output % added in v.1.2k
  4788. new.slash
  4789. output.author.rest
  4790. new.dblslash
  4791. booktitle "booktitle" output.check
  4792. new.slash
  4793. editor.organization.rest
  4794. new.block
  4795. output.address.publisher % 1.2k moved from below
  4796. new.block % added in v.1.2k
  4797. % address empty$
  4798. % { publisher output
  4799. % format.date "year/date" output.check
  4800. % }
  4801. % { address output.nonnull
  4802. % new.colon
  4803. % publisher output
  4804. % format.date "year/date" output.check
  4805. % }
  4806. % if$
  4807. % output.address.publisher % moved upper in v.1.2k
  4808. format.date "year/date" output.check
  4809. new.block
  4810. format.bvolume output
  4811. new.block
  4812. format.pages.page output
  4813. new.block
  4814. format.number.series output
  4815. new.block
  4816. note output
  4817. new.sentence
  4818. %<dstu2015> format.doi output
  4819. %<dstu2015> new.block
  4820. % output.url
  4821. output.eprint.url
  4822. format.annote output
  4823. fin.entry
  4824. }
  4825.  
  4826. % \end{macrocode}
  4827. % \DescribeFunction{manual}
  4828. % Technical or other documentation, not necessarily in printed form. The author or
  4829. % editor is omissible.
  4830. %
  4831. % Required fields: author/editor, title, year/date.
  4832. %
  4833. % Optional fields: subtitle, titleaddon, language, edition, type, series,
  4834. % number, version, note, organization, publisher, location, isbn, chapter,
  4835. % pages, pagetotal, addendum, pubstate, doi, eprint, eprintclass,
  4836. % eprinttype, url, urldate.
  4837. % \changes{v1.1}{11 Oct 2023}{Added \texttt{new.sentence} after
  4838. % \texttt{titleaddon}, because after it a next section of this bibliographic
  4839. % entry starts.}
  4840. % \begin{macrocode}
  4841. FUNCTION {manual}
  4842. { output.bibitem
  4843. author empty$
  4844. { organization empty$
  4845. 'skip$
  4846. { organization output.nonnull
  4847. address output
  4848. }
  4849. if$
  4850. }
  4851. { format.author output.nonnull }
  4852. if$
  4853. %<natbib> author format.key output
  4854. new.block
  4855. title add.doi add.media "title" output.check
  4856. new.colon % added in v.1.2k
  4857. titleaddon output % added in v.1.2k
  4858. new.sentence
  4859. author empty$
  4860. { organization empty$
  4861. {
  4862. address new.block.checka
  4863. address output
  4864. }
  4865. 'skip$
  4866. if$
  4867. }
  4868. {
  4869. organization address new.block.checkb
  4870. organization output
  4871. address output
  4872. }
  4873. if$
  4874. format.edition output
  4875. format.date "year/date" output.check
  4876. new.block
  4877. note output
  4878. new.sentence
  4879. %<dstu2015> format.doi output
  4880. %<dstu2015> new.block
  4881. % output.url
  4882. output.eprint.url
  4883. format.annote output
  4884. fin.entry
  4885. }
  4886.  
  4887. % \end{macrocode}
  4888. % \DescribeFunction{patent}
  4889. % A patent or patent request. The number or record token is given in the number
  4890. % field. Use the |type| field to specify the type and the |location| field to
  4891. % indicate the scope of the patent, if different from the scope implied by the
  4892. % type. Note that the location field is treated as a key list with this entry
  4893. % type.
  4894. %
  4895. % Required fields: author, title, number, year/date.
  4896. %
  4897. % Optional fields: holder, subtitle, titleaddon, type, version, location, note,
  4898. % date, month, year, addendum, pubstate, doi, eprint, eprint class, eprint type,
  4899. % url, urldate.
  4900. % \begin{macrocode}
  4901. FUNCTION {patent}
  4902. {
  4903. output.bibitem
  4904. title add.media output.nonnull
  4905. new.colon % added in v.1.2k
  4906. titleaddon output % added in v.1.2k
  4907. new.colon
  4908. format.type.number output
  4909. add.blank
  4910. address.or.location output
  4911. new.colon
  4912. ipc output
  4913. new.slash
  4914. format.author "author" output.check
  4915. add.blank
  4916. authorcountry paranthesify output.nonnull
  4917. %<natbib> author format.key output
  4918. new.semicolon
  4919. holder output.nonnull
  4920. new.semicolon
  4921. credits output.nonnull
  4922. new.block
  4923. requestnumber add.number output
  4924. new.semicolon
  4925. format.requestdate output
  4926. new.semicolon
  4927. format.publicationdate output
  4928. publication output
  4929. new.semicolon
  4930. format.prioritydate output
  4931. prioritynumber output
  4932. prioritycountry paranthesify output
  4933. new.block
  4934. note output
  4935. new.sentence
  4936. %<dstu2015> format.doi output
  4937. %<dstu2015> new.block
  4938. output.url
  4939. format.annote output
  4940. new.block
  4941. pagetotal output
  4942. fin.entry
  4943. }
  4944.  
  4945. % \end{macrocode}
  4946. % \DescribeFunction{misc}
  4947. % A fallback type for entries which do not fit into any other category.
  4948. % Use the field howpublished to supply publishing information in free format,
  4949. % if applicable. The field type may be useful as well. |author|, |editor|, and
  4950. % |year| are omissible.
  4951. %
  4952. % Required fields: author/editor, title, year/date.
  4953. % \begin{macrocode}
  4954. FUNCTION {misc}
  4955. { output.bibitem
  4956. %format.author output % < v.1.2k
  4957. output.author.head % v.1.2k
  4958. %new.sentence % v.1.2k
  4959. %<natbib> author format.key output
  4960. title howpublished new.sentence.checkb
  4961. title add.media output
  4962. howpublished new.block.checka
  4963. howpublished output
  4964. new.block
  4965. format.date "year/date" output.check
  4966. new.block
  4967. note output
  4968. new.sentence
  4969. %<dstu2015> format.doi output
  4970. %<dstu2015> new.block
  4971. % output.url
  4972. output.eprint.url
  4973. format.annote output
  4974. fin.entry
  4975. }
  4976.  
  4977. % \end{macrocode}
  4978. %
  4979. % \DescribeFunction{unpublished}
  4980. % A work with an author and a title which has not been formally published, such
  4981. % as a manuscript or the script of a talk. Use the fields howpublished and note to
  4982. % supply additional information in free format, if applicable.
  4983. %
  4984. % Required fields: author, title, year/date.
  4985. %
  4986. % Optional fields: subtitle, titleaddon, language, howpublished, note,
  4987. % location, isbn, date, month, year, addendum, pubstate, url, urldate
  4988. % \begin{macrocode}
  4989. FUNCTION {unpublished}
  4990. { output.bibitem
  4991. output.author.head
  4992. new.sentence
  4993. %<natbib> author format.key output
  4994. title "title" output.check
  4995. new.colon % added in v.1.2k
  4996. titleaddon output % added in v.1.2k
  4997. new.slash
  4998. output.author.rest
  4999. editor.organization.rest
  5000. new.block
  5001. format.date "year/date" output.check
  5002. new.block
  5003. note "note" output.check
  5004. new.sentence
  5005. % output.url
  5006. output.eprint.url
  5007. format.annote output
  5008. fin.entry
  5009. }
  5010.  
  5011. % \end{macrocode}
  5012. %
  5013. % \DescribeFunction{online}
  5014. % An online resource. Author, editor, and year are omissible.
  5015. % This entry type is intended for sources such as web sites which are intrinsically
  5016. % online resources. Note that all entry types support the url field. For example,
  5017. % when adding an article from an online journal, it may be preferable to use the
  5018. % |@article| type and its url field.
  5019. %
  5020. % Required fields: author/editor, title, year/date, url.
  5021. %
  5022. % Optional fields: subtitle, titleaddon, language, version, note,
  5023. % organization, date, month, year, addendum, pubstate, urldate.
  5024. % \changes{GOST v1.1}{15 Jan 2012}{Entry type \texttt{@online} added}
  5025. % \begin{macrocode}
  5026. FUNCTION {online}
  5027. { output.bibitem
  5028. format.author output
  5029. %<natbib> author format.key output
  5030. title howpublished new.sentence.checkb
  5031. title add.doi add.media "title" output.check
  5032. new.colon % added in v.1.2k
  5033. titleaddon output % added in v.1.2k
  5034. % howpublished new.block.checka
  5035. howpublished new.dblslash.checka
  5036. %<!strict> howpublished output
  5037. %<strict> howpublished bracketise output
  5038. editor.organization.rest
  5039. new.sentence
  5040. new.block
  5041. output.address.publisher
  5042. format.date output
  5043. new.block
  5044. %<dstu2015> format.doi output
  5045. %<dstu2015> new.block
  5046. % output.url
  5047. output.eprint.url
  5048. new.sentence
  5049. note output
  5050. format.annote output
  5051. fin.entry
  5052. }
  5053.  
  5054. % \end{macrocode}
  5055. %
  5056. % \DescribeFunction{internet}
  5057. % \DescribeFunction{www}
  5058. % \DescribeFunction{webpage}
  5059. % \DescribeFunction{ielectronic}
  5060. % New in version 2012.02.15.
  5061. % \begin{macrocode}
  5062. FUNCTION {internet} {online}
  5063. FUNCTION {www} {online}
  5064. FUNCTION {webpage} {online}
  5065. FUNCTION {electronic} {online}
  5066. % \end{macrocode}
  5067. %
  5068. % \DescribeFunction{thesis}
  5069. % New in version 2012.02.02.
  5070. %
  5071. % A thesis written for an educational institution to satisfy the requirements for a
  5072. % degree. Use the type field to specify the type of thesis.
  5073. %
  5074. % Required fields: author, title, type, institution, year/date.
  5075. %
  5076. % Optional fields: subtitle, titleaddon, language, note, location, month, isbn,
  5077. % chapter, pages, pagetotal, addendum, pubstate, doi, eprint, eprintclass,
  5078. % eprinttype, url, urldate
  5079. %
  5080. % \changes{GOST v1.2}{02 Feb 2012}{\texttt{@thesis} entry}
  5081. % \begin{macrocode}
  5082. FUNCTION {thesis}
  5083. { output.bibitem
  5084. format.author "author" output.check
  5085. %<natbib> author format.key output
  5086. new.sentence
  5087. title add.doi add.media "title" output.check
  5088. new.colon
  5089. bbl.phdthesis format.thesis.type output.nonnull
  5090. new.colon
  5091. specialitycode.or.number output % code of the speciality, new in v.1.2i
  5092. new.colon
  5093. titleaddon output % date of defence and approvement; new in v.1.2i
  5094. new.slash
  5095. %%%format.author.rest output %% dupplicates athours from the head zone
  5096. output.author.rest %% prints if num.names$ > 3 or > 1
  5097. new.semicolon
  5098. %institution "institution" output.check
  5099. institution.or.school "institution/school" output.check
  5100. new.block
  5101. output.address.publisher
  5102. format.date "year/date" output.check
  5103. new.block
  5104. format.pages.page output
  5105. new.block
  5106. note output
  5107. new.sentence
  5108. %<dstu2015> format.doi output
  5109. %<dstu2015> new.block
  5110. % output.url
  5111. output.eprint.url
  5112. format.annote output
  5113. fin.entry
  5114. }
  5115. % \end{macrocode}
  5116. %
  5117. % \DescribeFunction{report}
  5118. % New in version 2012.02.02.
  5119. %
  5120. % A technical report, research report, or white paper published by a university or
  5121. % some other institution. Use the type field to specify the type of report. The sponsoring
  5122. % institution goes in the institution field.
  5123. %
  5124. % Required fields: author, title, type, institution, year/date.
  5125. %
  5126. % Optional fields: subtitle, titleaddon, language, number, version, note,
  5127. % location, month, isrn, chapter, pages, pagetotal, addendum, pubstate, doi,
  5128. % eprint, eprintclass, eprinttype, url, urldate.
  5129. % \changes{GOST v1.2}{02 Feb 2012}{\texttt{@report} entry}
  5130. % \begin{macrocode}
  5131. %FUNCTION {report}
  5132. %{
  5133. % output.bibitem
  5134. % output.author.head
  5135. % new.sentence
  5136. % title add.doi add.media "title" output.check
  5137. % new.colon
  5138. %% format.techrep.type.number output.nonnull
  5139. % type "type" output.check
  5140. % new.slash
  5141. % output.author.rest
  5142. % editor.organization.rest
  5143. % new.block
  5144. % address output
  5145. % new.colon
  5146. % institution "institution" output.check
  5147. % format.date "year/date" output.check
  5148. % new.block
  5149. % note output
  5150. % new.block % v.2
  5151. % format.pages.page output % v.2
  5152. % new.sentence
  5153. %% output.url
  5154. % output.eprint.url
  5155. % format.annote output
  5156. % fin.entry
  5157. %}
  5158. FUNCTION {report}
  5159. {
  5160. output.bibitem
  5161. % output.author.head
  5162. % new.sentence
  5163. title add.doi add.media "title" output.check
  5164. %<natbib> title format.key output
  5165. new.colon % added in v.1.2k
  5166. titleaddon output % added in v.1.2k
  5167. new.colon
  5168. % format.techrep.type.number output.nonnull
  5169. % type "type" output.check
  5170. % format.report.type.number "type" output.check
  5171. type "type" output.check
  5172. new.colon
  5173. number output
  5174. new.slash
  5175. %institution "institution" output.check
  5176. institution.or.school "institution/school" output.check
  5177. new.semicolon
  5178. format.chief.rest output % from editor field
  5179. new.semicolon
  5180. format.executor.rest output % from author field
  5181. new.block
  5182. address.or.location output
  5183. new.colon
  5184. organization output
  5185. format.date "year/date" output.check
  5186. new.block % v.2
  5187. format.pages.page output % v.2
  5188. new.sentence % или new.block ?
  5189. %<dstu2015> format.doi output
  5190. %<dstu2015> new.block
  5191. output.eprint.url
  5192. new.block
  5193. note output
  5194. format.annote output
  5195. fin.entry
  5196. }
  5197.  
  5198. % \end{macrocode}
  5199. %
  5200. % \subsubsection{Type Aliases}
  5201. %
  5202. % The entry types listed in this section are provided for backwards compatibility
  5203. % with traditional BibTeX styles. These aliases are resolved by BibTeX as the data is
  5204. % exported. Bibliography styles will see the entry type the alias points to, not the
  5205. % alias name. All unknown entry types are generally exported as @misc.
  5206. %
  5207. % \DescribeFunction{phdthesis}
  5208. % Similar to @thesis except that the type field is optional and defaults to the localized
  5209. % term `PhD thesis'. You may still use the type field to override that.
  5210. % \begin{macrocode}
  5211. FUNCTION {phdthesis}
  5212. { output.bibitem
  5213. format.author "author" output.check
  5214. %<natbib> author format.key output
  5215. new.sentence
  5216. title add.doi add.media "title" output.check
  5217. new.colon
  5218. bbl.phdthesis format.thesis.type output.nonnull
  5219. new.colon
  5220. %%number output % code of the speciality
  5221. specialitycode.or.number output % code of the speciality, new in v.1.2i
  5222. new.colon
  5223. titleaddon output % date of defence and approvement; new in v.1.2i
  5224. new.slash
  5225. %%%format.author.rest output %% dupplicates athours
  5226. output.author.rest %% prints if num.names$ > 3 or > 1
  5227. new.semicolon
  5228. %institution "institution" output.check
  5229. institution.or.school "institution/school" output.check
  5230. new.block
  5231. output.address.publisher
  5232. format.date "year/date" output.check
  5233. new.block
  5234. format.pages.page output
  5235. new.block
  5236. note output
  5237. new.sentence
  5238. %<dstu2015> format.doi output
  5239. %<dstu2015> new.block
  5240. % output.url
  5241. output.eprint.url
  5242. format.annote output
  5243. fin.entry
  5244. }
  5245. % \end{macrocode}
  5246. % \DescribeFunction{mastersthesis}
  5247. % Similar to |@thesis| except that the type field is optional and defaults to the localized
  5248. % term `Master's thesis'. You may still use the type field to override that.
  5249. % \changes{GOST v1.2i}{29 Dec 2016}{entry \texttt{@MastersThesis} added again (see v1.1)}
  5250. % \begin{macrocode}
  5251. FUNCTION {mastersthesis}
  5252. { output.bibitem
  5253. format.author "author" output.check
  5254. %<natbib> author format.key output
  5255. new.sentence
  5256. title add.doi add.media "title" output.check
  5257. new.colon
  5258. bbl.mathesis format.thesis.type output.nonnull
  5259. new.colon
  5260. %%number output % code of the speciality
  5261. specialitycode.or.number output % code of the speciality, new in v.1.2i
  5262. new.colon
  5263. titleaddon output % date of defence and approvement; new in v.1.2i
  5264. new.slash
  5265. %%%format.author.rest output %% dupplicates athours
  5266. output.author.rest %% prints if num.names$ > 3 or > 1
  5267. new.semicolon
  5268. %institution "institution" output.check
  5269. institution.or.school "institution/school" output.check
  5270. new.block
  5271. output.address.publisher
  5272. format.date "year/date" output.check
  5273. new.block
  5274. format.pages.page output
  5275. new.block
  5276. note output
  5277. new.sentence
  5278. %<dstu2015> format.doi output
  5279. %<dstu2015> new.block
  5280. % output.url
  5281. output.eprint.url
  5282. format.annote output
  5283. fin.entry
  5284. }
  5285. % \end{macrocode}
  5286. % \DescribeFunction{docthesis}
  5287. % Similar to |@thesis| except that the type field is optional and defaults to the localized
  5288. % term `Doctor's of sciences thesis'. You may still use the type field to override that.
  5289. % \changes{GOST v1.2i}{02 Jan 2017}{\texttt{@dscithesis} entry renamed to \texttt{@docthesis}}
  5290. % \begin{macrocode}
  5291. FUNCTION {docthesis}
  5292. { output.bibitem
  5293. format.author "author" output.check
  5294. %<natbib> author format.key output
  5295. new.sentence
  5296. title add.doi add.media "title" output.check
  5297. new.colon
  5298. bbl.docthesis format.thesis.type output.nonnull
  5299. new.colon
  5300. %%number output % code of the speciality
  5301. specialitycode.or.number output % code of the speciality, new in v.1.2i
  5302. new.colon
  5303. titleaddon output % date of defence and approvement; new in v.1.2i
  5304. new.slash
  5305. %%%format.author.rest output %% dupplicate athours
  5306. output.author.rest %% prints if num.names$ > 3 or > 1
  5307. new.semicolon
  5308. %institution "institution" output.check
  5309. institution.or.school "institution/school" output.check
  5310. new.block
  5311. output.address.publisher
  5312. format.date "year/date" output.check
  5313. new.block
  5314. format.pages.page output
  5315. new.block
  5316. note output
  5317. new.sentence
  5318. %<dstu2015> format.doi output
  5319. %<dstu2015> new.block
  5320. % output.url
  5321. output.eprint.url
  5322. format.annote output
  5323. fin.entry
  5324. }
  5325. % \end{macrocode}
  5326. % \DescribeFunction{conference}
  5327. % \begin{macrocode}
  5328. FUNCTION {conference} { inproceedings }
  5329.  
  5330. % \end{macrocode}
  5331. %
  5332. % \DescribeFunction{techreport}
  5333. % TechReport is similar to |@report| except that the |type| field is optional
  5334. % and defaults to the localized term `technical report'.
  5335. % You may still use the type field to override that.
  5336. % \begin{macrocode}
  5337. %FUNCTION {techreport}
  5338. %{
  5339. % output.bibitem
  5340. % output.author.head
  5341. % new.sentence
  5342. % title add.doi add.media "title" output.check
  5343. % new.colon
  5344. % format.techrep.type.number output.nonnull
  5345. % new.slash
  5346. % output.author.rest
  5347. % editor.organization.rest
  5348. % new.block
  5349. % address output
  5350. % new.colon
  5351. % institution "institution" output.check
  5352. % format.date "year/date" output.check
  5353. % new.block
  5354. % note output
  5355. % new.block % v.2
  5356. % format.pages.page output % v.2
  5357. % new.sentence
  5358. %% output.url
  5359. % output.eprint.url
  5360. % format.annote output
  5361. % fin.entry
  5362. %}
  5363.  
  5364. FUNCTION {techreport}
  5365. {
  5366. output.bibitem
  5367. % output.author.head
  5368. % new.sentence
  5369. title add.doi add.media "title" output.check
  5370. %<natbib> title format.key output
  5371. new.colon
  5372. % format.techrep.type.number output.nonnull
  5373. % type "type" output.check
  5374. % format.report.type.number "type" output.check
  5375. % type output
  5376. format.techreport.type output
  5377. new.colon
  5378. number output
  5379. new.slash
  5380. %institution "institution" output.check
  5381. institution.or.school "institution/school" output.check
  5382. new.semicolon
  5383. format.chief.rest output % from editor field
  5384. new.semicolon
  5385. format.executor.rest output % from author field
  5386. new.block
  5387. address.or.location output
  5388. new.colon
  5389. organization output
  5390. format.date "year/date" output.check
  5391. new.block % v.2
  5392. format.pages.page output % v.2
  5393. new.sentence % или new.block ?
  5394. %<dstu2015> format.doi output
  5395. %<dstu2015> new.block
  5396. output.eprint.url
  5397. new.block
  5398. note output
  5399. format.annote output
  5400. fin.entry
  5401. }
  5402.  
  5403. % \end{macrocode}
  5404. % \DescribeFunction{default.type}
  5405. % \begin{macrocode}
  5406. FUNCTION {default.type} { misc }
  5407.  
  5408. % \end{macrocode}
  5409. %
  5410. % \subsection{Month Abbreviations}
  5411. % Borrowed from \file{merlin.mbs} of package \pkg{custom-bib}. This is done for
  5412. % backward compatibility with standard .bst styles which are designed for English.
  5413. % The string in the definition of any month macro must coincide with that used in
  5414. % |format.month| function in the above.
  5415. % \changes{GOST v1.2d}{18 Feb 2016}{\cs{bbljan} etc. macros removed}
  5416. % \begin{macrocode}
  5417. MACRO {jan} {"Jan."}
  5418. MACRO {feb} {"Feb."}
  5419. MACRO {mar} {"Mar."}
  5420. MACRO {apr} {"Apr."}
  5421. MACRO {may} {"May"}
  5422. MACRO {jun} {"Jun."}
  5423. MACRO {jul} {"Jul."}
  5424. MACRO {aug} {"Aug."}
  5425. MACRO {sep} {"Sep."}
  5426. MACRO {oct} {"Oct."}
  5427. MACRO {nov} {"Nov."}
  5428. MACRO {dec} {"Dec."}
  5429. % \end{macrocode}
  5430. %
  5431. % \subsection{Journal Abbreviations}
  5432. %
  5433. % \subsubsection{Physics and astronomy}
  5434. %
  5435. % Borrowed from \file{physjour.mbs} of package \pkg{custom-bib}.
  5436. % \begin{macrocode}
  5437. MACRO {aa}{"Astron.\ \& Astrophys."}
  5438. MACRO {aasup}{"Astron.\ \& Astrophys.\ Suppl.\ Ser."}
  5439. MACRO {aj} {"Astron.\ J."}
  5440. MACRO {aph} {"Acta Phys."}
  5441. MACRO {advp} {"Adv.\ Phys."}
  5442. MACRO {ajp} {"Amer.\ J.\ Phys."}
  5443. MACRO {ajm} {"Amer.\ J.\ Math."}
  5444. MACRO {amsci} {"Amer.\ Sci."}
  5445. MACRO {anofd} {"Ann.\ Fluid Dyn."}
  5446. MACRO {am} {"Ann.\ Math."}
  5447. MACRO {ap} {"Ann.\ Phys.\ (NY)"}
  5448. MACRO {adp} {"Ann.\ Phys.\ (Leipzig)"}
  5449. MACRO {ao} {"Appl.\ Opt."}
  5450. MACRO {apl} {"Appl.\ Phys.\ Lett."}
  5451. MACRO {app} {"Astroparticle Phys."}
  5452. MACRO {apj} {"Astrophys.\ J."}
  5453. MACRO {apjsup} {"Astrophys.\ J.\ Suppl."}
  5454. MACRO {apss} {"Astrophys.\ Space Sci."}
  5455. MACRO {araa} {"Ann.\ Rev.\ Astron.\ Astrophys."}
  5456. MACRO {baas} {"Bull.\ Amer.\ Astron.\ Soc."}
  5457. MACRO {baps} {"Bull.\ Amer.\ Phys.\ Soc."}
  5458. MACRO {cmp} {"Comm.\ Math.\ Phys."}
  5459. MACRO {cpam} {"Commun.\ Pure Appl.\ Math."}
  5460. MACRO {cppcf} {"Comm.\ Plasma Phys.\ \& Controlled Fusion"}
  5461. MACRO {cpc} {"Comp.\ Phys.\ Comm."}
  5462. MACRO {cqg} {"Class.\ Quant.\ Grav."}
  5463. MACRO {cra} {"C.\ R.\ Acad.\ Sci.\ A"}
  5464. MACRO {fed} {"Fusion Eng.\ \& Design"}
  5465. MACRO {ft} {"Fusion Tech."}
  5466. MACRO {grg} {"Gen.\ Relativ.\ Gravit."}
  5467. MACRO {ieeens} {"IEEE Trans.\ Nucl.\ Sci."}
  5468. MACRO {ieeeps} {"IEEE Trans.\ Plasma Sci."}
  5469. MACRO {ijimw} {"Interntl.\ J.\ Infrared \& Millimeter Waves"}
  5470. MACRO {ip} {"Infrared Phys."}
  5471. MACRO {irp} {"Infrared Phys."}
  5472. MACRO {jap} {"J.\ Appl.\ Phys."}
  5473. MACRO {jasa} {"J.\ Acoust.\ Soc.\ America"}
  5474. MACRO {jcp} {"J.\ Comp.\ Phys."}
  5475. MACRO {jchp} {"J.\ Chem.\ Phys."}
  5476. MACRO {jetp} {"Sov.\ Phys.--JETP"}
  5477. MACRO {jfe} {"J.\ Fusion Energy"}
  5478. MACRO {jfm} {"J.\ Fluid Mech."}
  5479. MACRO {jmp} {"J.\ Math.\ Phys."}
  5480. MACRO {jne} {"J.\ Nucl.\ Energy"}
  5481. MACRO {jnec} {"J.\ Nucl.\ Energy, C: Plasma Phys., Accelerators, Thermonucl.\ Res."}
  5482. MACRO {jnm} {"J.\ Nucl.\ Mat."}
  5483. MACRO {jpc} {"J.\ Phys.\ Chem."}
  5484. MACRO {jpp} {"J.\ Plasma Phys."}
  5485. MACRO {jpsj} {"J.\ Phys.\ Soc.\ Japan"}
  5486. MACRO {jsi} {"J.\ Sci.\ Instrum."}
  5487. MACRO {jvst} {"J.\ Vac.\ Sci.\ \& Tech."}
  5488. MACRO {nat} {"Nature"}
  5489. MACRO {nature} {"Nature"}
  5490. MACRO {nedf} {"Nucl.\ Eng.\ \& Design/Fusion"}
  5491. MACRO {nf} {"Nucl.\ Fusion"}
  5492. MACRO {nim} {"Nucl.\ Inst.\ \& Meth."}
  5493. MACRO {nimpr} {"Nucl.\ Inst.\ \& Meth.\ in Phys.\ Res."}
  5494. MACRO {np} {"Nucl.\ Phys."}
  5495. MACRO {npb} {"Nucl.\ Phys.\ B"}
  5496. MACRO {nt/f} {"Nucl.\ Tech./Fusion"}
  5497. MACRO {npbpc} {"Nucl.\ Phys.\ B (Proc.\ Suppl.)"}
  5498. MACRO {inc} {"Nuovo Cimento"}
  5499. MACRO {nc} {"Nuovo Cimento"}
  5500. MACRO {pf} {"Phys.\ Fluids"}
  5501. MACRO {pfa} {"Phys.\ Fluids A: Fluid Dyn."}
  5502. MACRO {pfb} {"Phys.\ Fluids B: Plasma Phys."}
  5503. MACRO {pl} {"Phys.\ Lett."}
  5504. MACRO {pla} {"Phys.\ Lett.\ A"}
  5505. MACRO {plb} {"Phys.\ Lett.\ B"}
  5506. MACRO {prep} {"Phys.\ Rep."}
  5507. MACRO {pnas} {"Proc.\ Nat.\ Acad.\ Sci.\ USA"}
  5508. MACRO {pp} {"Phys.\ Plasmas"}
  5509. MACRO {pop} {"Phys.\ Plasmas"}
  5510. MACRO {ppcf} {"Plasma Phys.\ \& Controlled Fusion"}
  5511. MACRO {phitrsl} {"Philos.\ Trans.\ Roy.\ Soc.\ London"}
  5512. MACRO {prl} {"Phys.\ Rev.\ Lett."}
  5513. MACRO {pr} {"Phys.\ Rev."}
  5514. MACRO {physrev} {"Phys.\ Rev."}
  5515. MACRO {pra} {"Phys.\ Rev.\ A"}
  5516. MACRO {prb} {"Phys.\ Rev.\ B"}
  5517. MACRO {prc} {"Phys.\ Rev.\ C"}
  5518. MACRO {prd} {"Phys.\ Rev.\ D"}
  5519. MACRO {pre} {"Phys.\ Rev.\ E"}
  5520. MACRO {ps} {"Phys.\ Scripta"}
  5521. MACRO {procrsl} {"Proc.\ Roy.\ Soc.\ London"}
  5522. MACRO {rmp} {"Rev.\ Mod.\ Phys."}
  5523. MACRO {rsi} {"Rev.\ Sci.\ Inst."}
  5524. MACRO {science} {"Science"}
  5525. MACRO {sciam} {"Sci.\ Am."}
  5526. MACRO {sam} {"Stud.\ Appl.\ Math."}
  5527. MACRO {st} {"Sky and Telesc."}
  5528. % \end{macrocode}
  5529. %
  5530. % \subsubsection{Supplementary Journal Names}
  5531. %
  5532. % Borrowed from \file{suppjour.mbs} of package \pkg{custom-bib}.
  5533. % \begin{macrocode}
  5534. MACRO {cjp} {"Czech. J. Phys."}
  5535. MACRO {el} {"Europhys. Lett."}
  5536. MACRO {en} {"Europhys. News"}
  5537. MACRO {fujitsustj} {"FUJITSU Sci. Tech. J."}
  5538. MACRO {ieeeed} {"IEEE Trans. Electron Devices"}
  5539. MACRO {ieeeim} {"IEEE Trans. Instrum. Meas."}
  5540. MACRO {ieeejqe} {"IEEE J. Quantum Electron."}
  5541. MACRO {ieeem} {"IEEE Trans. Magn."}
  5542. MACRO {ieeeptl} {"IEEE Photonic Technol. Lett."}
  5543. MACRO {ieeeuffc} {"IEEE Trans. Ultrason., Ferroelect., Freq. Cont."}
  5544. MACRO {jem} {"J. Electron. Mater."}
  5545. MACRO {jes} {"J. Electrochem. Soc."}
  5546. MACRO {jetplett} {"JETP Lett."}
  5547. MACRO {jjap} {"Japan. J. Appl. Phys."}
  5548. MACRO {jpha} {"J. Phys. A: Math. Gen."}
  5549. MACRO {jphb} {"J. Phys. B: At. Mol. Opt. Phys."}
  5550. MACRO {jphbold} {"J. Phys. B: At. Mol. Phys."}
  5551. MACRO {jphc} {"J. Phys.: Condens. Matter"}
  5552. MACRO {jphcold} {"J. Phys. C: Solid State Phys."}
  5553. MACRO {jphd} {"J. Phys. D: Appl. Phys."}
  5554. MACRO {jvsta} {"J. Vac. Sci. Technol. A"}
  5555. MACRO {jvstb} {"J. Vac. Sci. Technol. B"}
  5556. MACRO {me} {"Microelectron. Eng."}
  5557. MACRO {necrd} {"NEC Res.{\&} Develop."}
  5558. MACRO {pa} {"Physica A"}
  5559. MACRO {pb} {"Physica B"}
  5560. MACRO {pc} {"Physica C"}
  5561. MACRO {pd} {"Physica D"}
  5562. MACRO {procieee} {"Proc. IEEE"}
  5563. MACRO {procspie} {"Proc. SPIE"}
  5564. MACRO {pssa} {"Phys. Stat. Sol. A"}
  5565. MACRO {pssb} {"Phys. Stat. Sol. B"}
  5566. MACRO {rpp} {"Rep. Progr. Phys."}
  5567. MACRO {sm} {"Synthet. Metal"}
  5568. MACRO {sost} {"Solid State Technol."}
  5569. MACRO {ss} {"Surf. Sci."}
  5570. MACRO {ssc} {"Solid State Commun."}
  5571. MACRO {sst} {"Semicond. Sci. Technol."}
  5572. MACRO {suplatt} {"Superlatt. Microstr."}
  5573. MACRO {sust} {"Supercond. Sci. Technol."}
  5574. MACRO {znat} {"Z. Naturforsch."}
  5575. % \end{macrocode}
  5576. %
  5577. % \subsubsection{Optics}
  5578. %
  5579. % Borrowed from \file{photjour.mbs}.
  5580. % \begin{macrocode}
  5581. MACRO {appopt} {"Appl.\ Opt."}
  5582. MACRO {bell} {"Bell Syst.\ Tech.\ J."}
  5583. MACRO {ell} {"Electron.\ Lett."}
  5584. MACRO {jasp} {"J.\ Appl.\ Spectr."}
  5585. MACRO {jqe} {"IEEE J.\ Quantum Electron."}
  5586. MACRO {jlwt} {"J.\ Lightwave Technol."}
  5587. MACRO {jmo} {"J.\ Mod.\ Opt."}
  5588. MACRO {josa} {"J.\ Opt.\ Soc.\ America"}
  5589. MACRO {josaa} {"J.\ Opt.\ Soc.\ Amer.~A"}
  5590. MACRO {josab} {"J.\ Opt.\ Soc.\ Amer.~B"}
  5591. MACRO {jdp} {"J.\ Phys.\ (Paris)"}
  5592. MACRO {oc} {"Opt.\ Commun."}
  5593. MACRO {ol} {"Opt.\ Lett."}
  5594. MACRO {os} {"Opt.\ Spectrosc."}
  5595. MACRO {phtl} {"IEEE Photon. Technol. Lett."}
  5596. MACRO {pspie} {"Proc.\ Soc.\ Photo-Opt.\ Instrum. Eng."}
  5597. MACRO {vr} {"Vision Res."}
  5598. MACRO {zph} {"Z.\ f.\ Physik"}
  5599. MACRO {zphb} {"Z.\ f.\ Physik~B"}
  5600. MACRO {zphd} {"Z.\ f.\ Physik~D"}
  5601. % \end{macrocode}
  5602. %
  5603. % \subsubsection{Physics of condensed Matter}
  5604. %
  5605. % \begin{macrocode}
  5606. MACRO {sse} {"Solid-State Electron."}
  5607. MACRO {pss} {"Phys. Sol. State"}
  5608. MACRO {nl} {"Nano Lett."}
  5609. % \end{macrocode}
  5610. %
  5611. % \subsubsection{Soviet and Russian journals}
  5612. % \note{To be extended.}
  5613. % \begin{macrocode}
  5614. MACRO {sjpp} {"Sov.\ J.\ Plasma Phys."}
  5615. MACRO {spd} {"Sov.\ Phys.--Doklady"}
  5616. MACRO {sptp} {"Sov.\ Phys.--Tech. Phys."}
  5617. MACRO {spu} {"Sov.\ Phys.--Uspekhi"}
  5618. %<!utf8>MACRO {ufn} {"\CYRU\CYRF\CYRN"}
  5619. %<utf8>MACRO {ufn} {"УФН"}
  5620. MACRO {pu} {"Phys.--Uspekhi"}
  5621. MACRO {sjot} {"Sov.\ J.\ Opt.\ Technol."}
  5622. MACRO {sjqe} {"Sov.\ J.\ Quantum Electron."}
  5623. MACRO {sleb} {"Sov.\ Phys.--Leb.\ Inst.\ Rep."}
  5624. MACRO {stph} {"Sov.\ Phys.--Techn.\ Phys."}
  5625. MACRO {stphl}{"Sov.\ Techn.\ Phys.\ Lett."}
  5626. % \end{macrocode}
  5627. %
  5628. % \subsection{Main cycle}
  5629. %
  5630. % \begin{macrocode}
  5631.  
  5632. READ
  5633.  
  5634. % \end{macrocode}
  5635. %
  5636. % \subsection{Sorting}
  5637. %
  5638. % Next chunk of code governs sorting reference list by authors' names and
  5639. % titles.
  5640. % \begin{macrocode}
  5641. %<*sort|natbib>
  5642. % \end{macrocode}
  5643. % \DescribeFunction{sortify}
  5644. % \begin{macrocode}
  5645. FUNCTION {sortify}
  5646. { purify$
  5647. %<!(utf8&!bibtexu)> "l" change.case$
  5648. }
  5649. %</sort|natbib>
  5650. % \end{macrocode}
  5651. % \DescribeFunction{sort.format.names}
  5652. % \begin{macrocode}
  5653. %<*sort>
  5654. %% =====================================
  5655. %% This version from old Gost package
  5656. %%<*!natbib>
  5657. FUNCTION {sort.format.names}
  5658. { 's :=
  5659. #1 'nameptr :=
  5660. ""
  5661. s num.names$ 'numnames :=
  5662. numnames 'namesleft :=
  5663. { namesleft #0 > }
  5664. { nameptr #1 >
  5665. { " " * }
  5666. 'skip$
  5667. if$
  5668. s nameptr
  5669. "{vv{ } }{ll{ }}{ f{ }}{ jj{ }}"
  5670. format.name$ 't :=
  5671. nameptr numnames = t "others" = and
  5672. { "et al" * }
  5673. %{ bbl.etal * }
  5674. { t sortify * }
  5675. if$
  5676. nameptr #1 + 'nameptr :=
  5677. namesleft #1 - 'namesleft :=
  5678. }
  5679. while$
  5680. }
  5681. %%</!natbib>
  5682. %% This version from plainnat.bst
  5683. %% It ignores second and subsequent authors but include year.
  5684. %%<*natbib>
  5685. %FUNCTION {sort.format.names}
  5686. %{ 's :=
  5687. % #1 'nameptr :=
  5688. % ""
  5689. % s num.names$ 'numnames :=
  5690. % numnames 'namesleft :=
  5691. % { namesleft #0 > }
  5692. % {
  5693. % s nameptr "{vv{ } }{ll{ }}{ ff{ }}{ jj{ }}" format.name$ 't :=
  5694. % nameptr #1 >
  5695. % {
  5696. % " " *
  5697. % namesleft #1 = t "others" = and
  5698. % { "zzzzz" * }
  5699. % { numnames #2 > nameptr #2 = and
  5700. % { "zz" * year field.or.null * " " * }
  5701. % 'skip$
  5702. % if$
  5703. % t sortify *
  5704. % }
  5705. % if$
  5706. % }
  5707. % { t sortify * }
  5708. % if$
  5709. % nameptr #1 + 'nameptr :=
  5710. % namesleft #1 - 'namesleft :=
  5711. % }
  5712. % while$
  5713. %}
  5714. %%</natbib>
  5715. %% =====================================
  5716.  
  5717. % \end{macrocode}
  5718. % \DescribeFunction{sort.format.title}
  5719. % \begin{macrocode}
  5720. FUNCTION {sort.format.title}
  5721. { 't :=
  5722. "A " #2
  5723. "An " #3
  5724. "The " #4 t chop.word % Removes "The " if any
  5725. chop.word % Removes "An " if any
  5726. chop.word % Removes "A " if any
  5727. sortify
  5728. #1 global.max$ substring$
  5729. }
  5730.  
  5731. % \end{macrocode}
  5732. % \DescribeFunction{author.sort}
  5733. % \begin{macrocode}
  5734. %% =====================================
  5735. %% This version from old gost package.
  5736. %%
  5737. %<*!natbib>
  5738. FUNCTION {author.sort}
  5739. { author empty$
  5740. { key empty$
  5741. { "to sort, need author or key in " cite$ * warning$
  5742. ""
  5743. }
  5744. { key sortify }
  5745. if$
  5746. }
  5747. {
  5748. author num.names$ #4 <
  5749. {author sort.format.names }
  5750. {title sort.format.title}
  5751. if$
  5752. }
  5753. if$
  5754. }
  5755. %</!natbib>
  5756. %% This version from plainnat.bst
  5757. %<*natbib>
  5758. FUNCTION {author.sort}
  5759. { author empty$
  5760. { key empty$
  5761. { "to sort, need author or key in " cite$ * warning$
  5762. ""
  5763. }
  5764. { key sortify }
  5765. if$
  5766. }
  5767. { author sort.format.names }
  5768. if$
  5769. }
  5770. %</natbib>
  5771. %% =====================================
  5772.  
  5773. % \end{macrocode}
  5774. % \DescribeFunction{author.title.sort}
  5775. % The function |author.title.sort| is used in the |presort| function only.
  5776. % \begin{macrocode}
  5777. FUNCTION {author.title.sort}
  5778. { author empty$
  5779. { title empty$
  5780. { key empty$
  5781. { "to sort, need author, title, or key in " cite$ * warning$
  5782. ""
  5783. }
  5784. { key sortify }
  5785. if$
  5786. }
  5787. { title sort.format.title }
  5788. if$
  5789. }
  5790. {
  5791. author num.names$ #4 <
  5792. {author sort.format.names }
  5793. {title sort.format.title}
  5794. if$
  5795. }
  5796. if$
  5797. }
  5798. % \end{macrocode}
  5799. %
  5800. % \DescribeFunction{author.editor.sort}
  5801. % \DescribeFunction{author.organization.sort}
  5802. % \DescribeFunction{editor.organization.sort}
  5803. % The function |author.editor.sort|, |author.organization.sort|,
  5804. % |editor.organization.sort| are not currently used. See commented
  5805. % text in function |presort|\#2. \note{WE NEED TO CORRECT THAT!}
  5806. % \begin{macrocode}
  5807. %<*natbib>
  5808. %FUNCTION {author.editor.sort}
  5809. %{ author empty$
  5810. % { editor empty$
  5811. % { key empty$
  5812. % { "to sort, need author, editor, or key in " cite$ * warning$
  5813. % ""
  5814. % }
  5815. % { key sortify }
  5816. % if$
  5817. % }
  5818. % { editor sort.format.names }
  5819. % if$
  5820. % }
  5821. % { author sort.format.names }
  5822. % if$
  5823. %}
  5824. %
  5825. %FUNCTION {author.organization.sort}
  5826. %{ author empty$
  5827. % { organization empty$
  5828. % { key empty$
  5829. % { "to sort, need author, organization, or key in " cite$ * warning$
  5830. % ""
  5831. % }
  5832. % { key sortify }
  5833. % if$
  5834. % }
  5835. % { "The " #4 organization chop.word sortify }
  5836. % if$
  5837. % }
  5838. % { author sort.format.names }
  5839. % if$
  5840. %}
  5841.  
  5842. FUNCTION {editor.organization.sort}
  5843. { editor empty$
  5844. { organization empty$
  5845. { key empty$
  5846. { "to sort, need editor, organization, or key in " cite$ * warning$
  5847. ""
  5848. }
  5849. { key sortify }
  5850. if$
  5851. }
  5852. { "The " #4 organization chop.word sortify }
  5853. if$
  5854. }
  5855. { editor sort.format.names }
  5856. if$
  5857. }
  5858. %</natbib>
  5859. % \end{macrocode}
  5860. %
  5861. % \DescribeFunction{presort}
  5862. % Function to compute |sort.key$|.
  5863. % What is the space string \verb*|" "| for?
  5864. % Version \#1 is for `sort` and `!natbib` options.
  5865. % Version \#2 is for `sort` and `natbib` options.
  5866. % Version \#3 is for `!sort` and `natbib` options.
  5867. % \begin{macrocode}
  5868. %<*!natbib>
  5869. FUNCTION {presort}%#1
  5870. {
  5871. author.title.sort
  5872. " "
  5873. *
  5874. year field.or.null sortify
  5875. *
  5876. " "
  5877. *
  5878. title field.or.null
  5879. sort.format.title
  5880. *
  5881. #1 entry.max$ substring$
  5882. 'sort.key$ :=
  5883. }
  5884. %</!natbib>
  5885. %<*natbib>
  5886. FUNCTION {presort}%#2
  5887. { calc.label
  5888. label sortify
  5889. %author.title.sort
  5890. " "
  5891. *
  5892. % ========= plainnat.bst =========
  5893. % type$ "book" =
  5894. % type$ "inbook" =
  5895. % or
  5896. % 'author.editor.sort
  5897. % { type$ "proceedings" =
  5898. % 'editor.organization.sort
  5899. % { type$ "manual" =
  5900. % 'author.organization.sort
  5901. % 'author.sort
  5902. % if$
  5903. % }
  5904. % if$
  5905. % }
  5906. % if$
  5907. author.title.sort
  5908. " "
  5909. *
  5910. year field.or.null sortify
  5911. *
  5912. " "
  5913. *
  5914. %cite$
  5915. title field.or.null sort.format.title
  5916. *
  5917. #1 entry.max$ substring$
  5918. 'sort.label :=
  5919. sort.label *
  5920. % ================================
  5921. #1 entry.max$ substring$
  5922. 'sort.key$ :=
  5923. }
  5924. %</natbib>
  5925. %</sort>
  5926.  
  5927. %<*!sort>
  5928. %<*natbib>
  5929. INTEGERS { seq.num }
  5930.  
  5931. FUNCTION {init.seq}
  5932. { #0 'seq.num :=}
  5933.  
  5934. EXECUTE {init.seq}
  5935.  
  5936. FUNCTION {int.to.fix}
  5937. { "000000000" swap$ int.to.str$ *
  5938. #-1 #10 substring$
  5939. }
  5940.  
  5941. FUNCTION {presort}%#3
  5942. {
  5943. calc.label % computes label
  5944. label sortify % initiates sort.label
  5945. " "
  5946. *
  5947. seq.num #1 + 'seq.num := % advance seq.num
  5948. seq.num int.to.fix % prepend seq.num with 0s
  5949. 'sort.label := % set sort.label to seq.num
  5950. sort.label * % append seq.num to label
  5951. #1 entry.max$ substring$ % cut if too long
  5952. 'sort.key$ := % set sort.key$
  5953. }
  5954. %</natbib>
  5955. %</!sort>
  5956.  
  5957. %<*sort|natbib>
  5958. ITERATE {presort}
  5959.  
  5960. SORT
  5961.  
  5962. %</sort|natbib>
  5963.  
  5964. % \end{macrocode}
  5965. %
  5966. % \subsection{Bibliography list}
  5967. %
  5968. % We need to find longest label to put in into the argument of
  5969. % the |thebibliography| environment. In case of |natbib| options
  5970. % we also need to compute extra suffix for the |year| field if there two or
  5971. % more entries for given label (=author/editor/organization) in that year.
  5972. %
  5973. % Declare global (external) strings used in calculation of the longest label.
  5974. % \begin{macrocode}
  5975. %<!natbib>STRINGS { longest.label }
  5976. %<natbib>STRINGS { longest.label last.label next.extra }
  5977.  
  5978. %<!natbib>INTEGERS { number.label longest.label.width }
  5979. %<natbib>INTEGERS { number.label longest.label.width last.extra.num }
  5980.  
  5981. % \end{macrocode}
  5982. %
  5983. % \DescribeFunction{initialize.longest.label}
  5984. % Initialize those string.
  5985. % \begin{macrocode}
  5986. %<*!natbib>
  5987. FUNCTION {initialize.longest.label}
  5988. { "" 'longest.label :=
  5989. #1 'number.label :=
  5990. #0 'longest.label.width :=
  5991. }
  5992. %</!natbib>
  5993. %<*natbib>
  5994. FUNCTION {initialize.longest.label}
  5995. { "" 'longest.label :=
  5996. #0 int.to.chr$ 'last.label :=
  5997. "" 'next.extra :=
  5998. #0 'longest.label.width :=
  5999. #0 'last.extra.num :=
  6000. #0 'number.label :=
  6001. }
  6002. %</natbib>
  6003.  
  6004. EXECUTE {initialize.longest.label}
  6005.  
  6006. % \end{macrocode}
  6007. %
  6008. % \DescribeFunction{initialize.longest.label}
  6009. % Iterate though the list of entries to compute |label|.
  6010. % \begin{macrocode}
  6011. %<*!natbib>
  6012. FUNCTION {forward.pass}
  6013. { number.label int.to.str$ 'label :=
  6014. number.label #1 + 'number.label :=
  6015. label width$ longest.label.width >
  6016. { label 'longest.label :=
  6017. label width$ 'longest.label.width :=
  6018. }
  6019. 'skip$
  6020. if$
  6021. }
  6022. %</!natbib>
  6023. %<*natbib>
  6024. FUNCTION {forward.pass}
  6025. { last.label label =
  6026. { last.extra.num #1 + 'last.extra.num :=
  6027. last.extra.num int.to.chr$ 'extra.label :=
  6028. }
  6029. { "a" chr.to.int$ 'last.extra.num :=
  6030. "" 'extra.label :=
  6031. label 'last.label :=
  6032. }
  6033. if$
  6034. number.label #1 + 'number.label :=
  6035. }
  6036. %</natbib>
  6037.  
  6038. ITERATE {forward.pass}
  6039.  
  6040. % \end{macrocode}
  6041. %
  6042. % \DescribeFunction{reverse.pass}
  6043. % |Natbib| styles require reverse iteration over all entries.
  6044. % \begin{macrocode}
  6045. %<*natbib>
  6046. FUNCTION {reverse.pass}
  6047. { next.extra "b" =
  6048. { "a" 'extra.label := }
  6049. 'skip$
  6050. if$
  6051. extra.label 'next.extra :=
  6052. extra.label
  6053. duplicate$ empty$
  6054. 'skip$
  6055. { "{\natexlab{" swap$ * "}}" * }
  6056. if$
  6057. 'extra.label :=
  6058. %%%label extra.label * 'label :=
  6059. }
  6060.  
  6061. REVERSE {reverse.pass}
  6062.  
  6063. FUNCTION {bib.sort.order}
  6064. { sort.label 'sort.key$ :=
  6065. }
  6066.  
  6067. ITERATE {bib.sort.order}
  6068.  
  6069. SORT
  6070. %</natbib>
  6071.  
  6072. % \end{macrocode}
  6073. % \DescribeFunction{begin.bib}
  6074. % Within |thebibliography| environment we define few formatting macros
  6075. % for user to customize how the reference list is formatted.
  6076. %
  6077. % Code for |\BibReplaceFirstNameChars| is inspired by
  6078. % \url{https://tex.stackexchange.com/a/693376}. I can not just redefine dush
  6079. % locally, as I have done with |~|, because |-| is not of "active" character
  6080. % class (and character class is fixed when character is being readed and
  6081. % thus its character class can not be redefined by a macro nested inside
  6082. % another macro).
  6083. %
  6084. % \changes{GOST v1.2a}{31 Aug 2012}{default for \cs{cyrdash} added}
  6085. % \changes{GOST v0.8}{06 Jun 2003}{macro \cs{BibAnnote} added}
  6086. % \changes{GOST v0.8}{06 Jun 2003}{macro \cs{BibUrl} added}
  6087. % \changes{GOST v0.8}{10 Aug 2003}{macro \cs{BibEmph} added}
  6088. % \changes{v1.0}{29 Sep 2022}{macro \cs{BibEnNo} added}
  6089. % \changes{v1.0}{14 Apr 2023}{\cs{selectlanguageifdefined} now supports
  6090. % \pkg{polyglossia} and enables TeX ligatures if it
  6091. % is loaded (e.g. em and en dash shorthands).}
  6092. % \changes{v1.0}{22 Apr 2023}{\cs{BibAnnote} is now is an identity macro,
  6093. % because annotation (\texttt{annote} field) is
  6094. % sometimes mandatory according to standards.}
  6095. % \changes{v1.0}{03 Jun 2023}{macro \cs{BibFirstNameSpace} added}
  6096. % \changes{v1.2}{09 Jan 2025}{macro \cs{DSTUResponsibilityName} added}
  6097. % \changes{v1.2}{09 Jan 2025}{macro \cs{DSTUAllowNamesAnd} added}
  6098. % \changes{v1.4}{24 Feb 2025}{macro \cs{BibISBNandISSNcolon},
  6099. % \cs{BibISBNcolon}, \cs{BibISSNcolon},
  6100. % \cs{DSTUAllowSeriesParentheses} added}
  6101. % \begin{macrocode}
  6102. FUNCTION {begin.bib}
  6103. { "\begin{thebibliography}{" longest.label * "}" * write$ newline$
  6104. "\def\selectlanguageifdefined#1{" write$ newline$
  6105. "\ifdefined\ifbabellanguageloaded" write$ newline$
  6106. "\ifbabellanguageloaded{#1}{\selectlanguage{#1}}{}" write$ newline$
  6107. "\else\expandafter\ifx\csname date#1\endcsname\relax" write$ newline$
  6108. % "\else\language\csname l@#1\endcsname\fi\fi}" write$ newline$
  6109. "\else\selectlanguage{#1}\fi\fi" write$ newline$
  6110. "\ifdefined\addfontfeature\addfontfeature{Ligatures=TeX}\fi}" write$ newline$
  6111. "\providecommand*{\href}[2]{{\small #2}}" write$ newline$
  6112. "\providecommand*{\url}[1]{{\small #1}}" write$ newline$
  6113. "\providecommand*{\nobreakdash}{\relax}" write$ newline$
  6114. "\providecommand*{\BibUrl}[1]{\url{#1}}" write$ newline$
  6115. "\providecommand*{\BibDOIFullURL}{0}" write$ newline$
  6116. "\providecommand{\BibAnnote}[1]{#1}" write$ newline$
  6117. "\providecommand*{\BibEmph}[1]{#1}" write$ newline$
  6118. "\providecommand*{\BibEnNo}{no.}" write$ newline$
  6119. "\providecommand*{\BibFirstNameSpace}{\,}" write$ newline$
  6120. "\providecommand*{\BibSemicolonSpace}{~}" write$ newline$
  6121. "\providecommand*{\BibDiscouragedbreakSpace}{ \nolinebreak[3] }" write$ newline$
  6122. "\ProvideTextCommandDefault{\cyrdash}{\iflanguage{russian}{\hbox to.8em{--\hss--}}{\textemdash}}" write$ newline$
  6123. "\providecommand*{\BibDash}{\ifdim\lastskip>0pt\unskip\nobreak\hskip.2em plus 0.1em\fi" write$ newline$
  6124. "\cyrdash\hskip.2em plus 0.1em\ignorespaces}" write$ newline$
  6125. "\providecommand*{\DSTUAllowBibDash}{0}" write$ newline$
  6126. "\providecommand*{\DSTUBibDash}{\ifnum \DSTUAllowBibDash>0 \BibDash \fi}" write$ newline$
  6127. "\providecommand*{\DSTUResponsibilityName}[2]{#1}" write$ newline$
  6128. "\providecommand*{\DSTUAllowNamesAnd}{1}" write$ newline$
  6129. "\providecommand*\DSTUBibFirstNameDash{\ifdefined\nobreakdash\nobreakdash -\else -\fi}" write$ newline$
  6130. "\providecommand*{\DSTUreplaceminus}[1]{\DSTUdoreplaceminus #1-\relax}" write$ newline$
  6131. "\def\DSTUdoreplaceminus#1-#2\relax{" write$
  6132. "\ifx\relax#2\relax #1" write$
  6133. "\else #1\nobreakdash" write$ newline$
  6134. " -\DSTUdoreplaceminus#2\relax" write$ newline$
  6135. "\fi}" write$ newline$
  6136. "\providecommand*{\BibReplaceFirstNameChars}[1]{{\def~{\BibFirstNameSpace}\DSTUreplaceminus{#1}}}" write$ newline$
  6137. "\providecommand*{\BibISBNandISSNcolon}{}" write$ newline$
  6138. "\providecommand*{\BibISBNcolon}{\BibISBNandISSNcolon}" write$ newline$
  6139. "\providecommand*{\BibISSNcolon}{\BibISBNandISSNcolon}" write$ newline$
  6140. "\providecommand*{\DSTUAllowSeriesParentheses}{1}" write$ newline$
  6141. %<natbib> "\providecommand{\natexlab}[1]{#1}" write$ newline$
  6142. preamble$ empty$
  6143. 'skip$
  6144. { preamble$ write$ newline$ }
  6145. if$
  6146. }
  6147.  
  6148.  
  6149. EXECUTE {begin.bib}
  6150.  
  6151. EXECUTE {init.state.consts}
  6152.  
  6153. ITERATE {call.type$}
  6154.  
  6155. % \end{macrocode}
  6156. % \DescribeFunction{end.bib}
  6157. % \begin{macrocode}
  6158. FUNCTION {end.bib}
  6159. { newline$
  6160. % "\catcode`\/=11" write$ newline$
  6161. "\end{thebibliography}" write$ newline$
  6162. }
  6163.  
  6164. EXECUTE {end.bib}
  6165.  
  6166. % \end{macrocode}
  6167. %
  6168. % \begin{macrocode}
  6169. %</bst>
  6170. % \end{macrocode}
  6171. %
  6172. %\CheckSum{957}
  6173. %
  6174. %\Finale