diff options
author | Karl Berry <karl@freefriends.org> | 2009-11-27 01:30:49 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2009-11-27 01:30:49 +0000 |
commit | fc5af52f05a1b38ceecdf30ba7a5cb0cd5b9dfb5 (patch) | |
tree | 31f59ecea61711810e8f1dbf717e146cc43a242c /Master/texmf-dist/bibtex | |
parent | 45a77effd223883b558d54a8a7cbd6a87aa01e16 (diff) |
disser update (26nov09)
git-svn-id: svn://tug.org/texlive/trunk@16188 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/bibtex')
-rw-r--r-- | Master/texmf-dist/bibtex/bst/disser/gost705.bst | 299 | ||||
-rw-r--r-- | Master/texmf-dist/bibtex/bst/disser/gost705s.bst | 319 |
2 files changed, 379 insertions, 239 deletions
diff --git a/Master/texmf-dist/bibtex/bst/disser/gost705.bst b/Master/texmf-dist/bibtex/bst/disser/gost705.bst index 2ef3d68c643..5f732e239fb 100644 --- a/Master/texmf-dist/bibtex/bst/disser/gost705.bst +++ b/Master/texmf-dist/bibtex/bst/disser/gost705.bst @@ -74,7 +74,8 @@ INTEGERS { output.state before.all mid.sentence after.sentence after.block after.dblslash after.slash after.column after.semicolumn } FUNCTION {init.state.consts} -{ #0 'before.all := +{ + #0 'before.all := #1 'mid.sentence := #2 'after.sentence := #3 'after.block := @@ -89,18 +90,20 @@ STRINGS { s t } STRINGS { curlanguage } FUNCTION {change.language} -{ booklanguage empty$ - { "" } - { booklanguage 'curlanguage := - "\selectlanguageifdefined{" - curlanguage * - "}" * - } +{ + booklanguage empty$ + { "" } + { booklanguage 'curlanguage := + "\selectlanguageifdefined{" + curlanguage * + "}" * + } if$ } FUNCTION {output.nonnull} -{ swap$ +{ + swap$ output.state mid.sentence = { ", " * write$ } { output.state after.block = @@ -136,14 +139,16 @@ FUNCTION {output.nonnull} } FUNCTION {output} -{ duplicate$ empty$ +{ + duplicate$ empty$ 'pop$ 'output.nonnull if$ } FUNCTION {output.check} -{ 't := +{ + 't := duplicate$ empty$ { pop$ "empty " t * " in " * cite$ * warning$ } 'output.nonnull @@ -151,48 +156,55 @@ FUNCTION {output.check} } FUNCTION {fin.entry} -{ add.period$ +{ + add.period$ write$ newline$ } FUNCTION {new.block} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.block 'output.state := } if$ } FUNCTION {new.dblslash} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.dblslash 'output.state := } if$ } FUNCTION {new.slash} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.slash 'output.state := } if$ } FUNCTION {new.column} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.column 'output.state := } if$ } FUNCTION {new.semicolumn} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.semicolumn 'output.state := } if$ } FUNCTION {new.sentence} -{ output.state after.block = +{ + output.state after.block = 'skip$ { output.state before.all = 'skip$ @@ -202,42 +214,47 @@ FUNCTION {new.sentence} if$ } -FUNCTION {add.blank} -{ " " * before.all 'output.state := } +FUNCTION {add.blank} { " " * before.all 'output.state := } FUNCTION {not} -{ { #0 } +{ + { #0 } { #1 } if$ } FUNCTION {and} -{ 'skip$ +{ + 'skip$ { pop$ #0 } if$ } FUNCTION {or} -{ { pop$ #1 } +{ + { pop$ #1 } 'skip$ if$ } FUNCTION {non.stop} -{ duplicate$ +{ + duplicate$ "}" * add.period$ #-1 #1 substring$ "." = } FUNCTION {new.block.checka} -{ empty$ +{ + empty$ 'skip$ 'new.block if$ } FUNCTION {new.block.checkb} -{ empty$ +{ + empty$ swap$ empty$ and 'skip$ @@ -246,14 +263,16 @@ FUNCTION {new.block.checkb} } FUNCTION {new.sentence.checka} -{ empty$ +{ + empty$ 'skip$ 'new.sentence if$ } FUNCTION {new.sentence.checkb} -{ empty$ +{ + empty$ swap$ empty$ and 'skip$ @@ -262,21 +281,22 @@ FUNCTION {new.sentence.checkb} } FUNCTION {field.or.null} -{ duplicate$ empty$ +{ + duplicate$ empty$ { pop$ "" } 'skip$ if$ } FUNCTION {emphasize} -{ duplicate$ empty$ +{ + duplicate$ empty$ { pop$ "" } { "\BibEmph{" swap$ * "}" * } if$ } -FUNCTION {space.word} -{ " " swap$ * " " * } +FUNCTION {space.word} { " " swap$ * " " * } FUNCTION {bbl.edby} % { "\bbledby{}" } { @@ -307,8 +327,8 @@ FUNCTION {bbl.edition} % { "\bbledition{}" } curlanguage "english" = { "edition" } { curlanguage "russian" = - {"{\cyr\cyri\cyrz\cyrd.}"} - {"language is not defined: " language "edition" * * warning$ "edition"} + { "{\cyr\cyri\cyrz\cyrd.}" } + { "language is not defined: " language "edition" * * warning$ "edition" } if$ } if$ @@ -319,8 +339,8 @@ FUNCTION {bbl.vvolume} % { "\bblVolume{}" } curlanguage "english" = { "Volume" } { curlanguage "russian" = - {"\CYRT\cyro\cyrm"} - {"language is not defined: " language "Volume" * * warning$ "Volume"} + { "{\cyr\CYRT\cyro\cyrm}" } + { "language is not defined: " language "Volume" * * warning$ "Volume" } if$ } if$ @@ -331,7 +351,7 @@ FUNCTION {bbl.vvol} % { "\bblVol{}" } curlanguage "english" = { "Vol." } { curlanguage "russian" = - { "\CYRT." } + { "{\cyr\CYRT.}" } { "language is not defined: " language "Vol." * * warning$ "Vol." } if$ } @@ -343,8 +363,8 @@ FUNCTION {bbl.iissue} % { "\bblIssue{}" } curlanguage "english" = { "Issue" } { curlanguage "russian" = - {"\CYRV\cyrery\cyrp\cyru\cyrs\cyrk"} - {"language is not defined: " language * warning$ "Issue"} + { "{\cyr\CYRV\cyrery\cyrp\cyru\cyrs\cyrk}" } + { "language is not defined: " language * warning$ "Issue" } if$ } if$ @@ -355,8 +375,8 @@ FUNCTION {bbl.iiss} % { "\bblIss{}" } curlanguage "english" = {"Iss."} { curlanguage "russian" = - {"\CYRV\cyrery\cyrp."} - {"language is not defined: " language * warning$ "Issue"} + { "{\cyr\CYRV\cyrery\cyrp.}" } + { "language is not defined: " language * warning$ "Issue" } if$ } if$ @@ -367,8 +387,8 @@ FUNCTION {bbl.of} % { "\bblof{}" } curlanguage "english" = {"of"} { curlanguage "russian" = - {"{\cyr\cyri\cyrz}"} - {"language is not defined: " language "of" * * warning$ "of"} + { "{\cyr\cyri\cyrz}" } + { "language is not defined: " language "of" * * warning$ "of" } if$ } if$ @@ -391,7 +411,7 @@ FUNCTION {bbl.nnumber} % { "\bblNumber{}" } curlanguage "english" = { "Number" } { curlanguage "russian" = - { "\CYRN\cyro\cyrm\cyre\cyrr"} + { "{\cyr\CYRN\cyro\cyrm\cyre\cyrr}" } { "language is not defined: " language "Number" * * warning$ "Number" } if$ } @@ -403,7 +423,7 @@ FUNCTION {bbl.number} % { "\bblnumber{}" } curlanguage "english" = { "number" } { curlanguage "russian" = - { "{\cyr\cyrn\cyro\cyrm\cyre\cyrr}"} + { "{\cyr\cyrn\cyro\cyrm\cyre\cyrr}" } { "language is not defined: " language "number" * * warning$ "number" } if$ } @@ -451,7 +471,7 @@ FUNCTION {bbl.iin} % { "\bblIn{}" } curlanguage "english" = { "In" } { curlanguage "russian" = - { "\CYRV" } + { "{\cyr\CYRV}" } { "language is not defined: " language "In" * * warning$ "In" } if$ } @@ -545,7 +565,8 @@ FUNCTION {bbl.phdthesis} INTEGERS { nameptr namesleft numnames } FUNCTION {format.names} -{ 's := +{ + 's := #1 'nameptr := s num.names$ 'numnames := numnames 'namesleft := @@ -564,8 +585,8 @@ FUNCTION {format.names} { ", " * t * } { t "others" = - t "~others" = - or + t "~others" = + or { " " * bbl.etal * } { ", " * t * } if$ @@ -581,7 +602,8 @@ FUNCTION {format.names} } FUNCTION {format.names.rev} -{ 's := +{ + 's := #1 'nameptr := s num.names$ 'numnames := numnames 'namesleft := @@ -617,56 +639,64 @@ FUNCTION {format.names.rev} } FUNCTION {format.authors} -{ author empty$ +{ + author empty$ { "" } { author format.names emphasize } if$ } FUNCTION {format.bookauthors} -{ bookauthor empty$ +{ + bookauthor empty$ { "" } { bookauthor format.names } if$ } FUNCTION {format.authors.after} -{ author empty$ +{ + author empty$ { "" } { author format.names.rev } if$ } FUNCTION {format.bookauthors.after} -{ bookauthor empty$ +{ + bookauthor empty$ { "" } { bookauthor format.names.rev } if$ } FUNCTION {format.editors.after} -{ editor empty$ +{ + editor empty$ { "" } { bbl.edby editor format.names.rev * } if$ } -FUNCTION { format.compiler.after } -{ compiler empty$ +FUNCTION {format.compiler.after} +{ + compiler empty$ { "" } { bbl.cmplr compiler format.names.rev * } if$ } FUNCTION {format.title} -{ title empty$ +{ + title empty$ { "" } { title } if$ } FUNCTION {format.date} -{ year empty$ +{ + year empty$ { month empty$ { "" } { "there's a month but no year in " cite$ * warning$ @@ -683,7 +713,8 @@ FUNCTION {format.date} } FUNCTION {output.address.publisher.date} -{ address empty$ +{ + address empty$ 'skip$ { address output publisher empty$ @@ -697,7 +728,8 @@ FUNCTION {output.address.publisher.date} } FUNCTION {output.bibitem} -{ newline$ +{ + newline$ "\bibitem[" write$ "\BibPrefix" write$ label write$ @@ -718,7 +750,8 @@ FUNCTION {output.bibitem} } FUNCTION {n.dashify} -{ 't := +{ + 't := "" { t empty$ not } { t #1 #1 substring$ "-" = @@ -742,35 +775,32 @@ FUNCTION {n.dashify} while$ } -FUNCTION {word.in} -{ bbl.iin - " " * } +FUNCTION {word.in} { bbl.iin " " * } -FUNCTION {format.btitle} -{ title } +FUNCTION {format.btitle} { title } FUNCTION {tie.or.space.connect} -{ duplicate$ text.length$ #3 < +{ + duplicate$ text.length$ #3 < { "~" } { " " } if$ swap$ * * } -FUNCTION {tie.connect} -{"~" -swap$ * * -} +FUNCTION {tie.connect} { "~" swap$ * * } FUNCTION {either.or.check} -{ empty$ +{ + empty$ 'pop$ { "can't use both " swap$ * " fields in " * cite$ * warning$ } if$ } FUNCTION {format.bvolume} -{ volume empty$ +{ + volume empty$ { "" } { bbl.vvol volume tie.connect series empty$ @@ -783,7 +813,8 @@ FUNCTION {format.bvolume} } FUNCTION {format.number.series} -{ volume empty$ +{ + volume empty$ { number empty$ { series field.or.null } { series empty$ @@ -805,13 +836,15 @@ FUNCTION {format.number.series} } FUNCTION {is.num} -{ chr.to.int$ +{ + chr.to.int$ duplicate$ "0" chr.to.int$ < not swap$ "9" chr.to.int$ > not and } FUNCTION {extract.num} -{ duplicate$ 't := +{ + duplicate$ 't := "" 's := { t empty$ not } { t #1 #1 substring$ @@ -828,11 +861,11 @@ FUNCTION {extract.num} if$ } -FUNCTION {convert.edition} -{ edition } +FUNCTION {convert.edition} { edition } FUNCTION {format.edition} -{ edition empty$ +{ + edition empty$ { "" } { output.state mid.sentence = { convert.edition "l" change.case$ " " * bbl.edition * } @@ -845,7 +878,8 @@ FUNCTION {format.edition} INTEGERS { multiresult } FUNCTION {multi.page.check} -{ 't := +{ + 't := #0 'multiresult := { multiresult not t empty$ not @@ -865,7 +899,8 @@ FUNCTION {multi.page.check} } FUNCTION {format.pages} -{ pages empty$ +{ + pages empty$ { "" } { pages multi.page.check { bbl.ppages pages n.dashify tie.connect } @@ -876,7 +911,8 @@ FUNCTION {format.pages} } FUNCTION {format.pages.page} -{ pages empty$ +{ + pages empty$ { numpages empty$ { "" } { numpages bbl.pages tie.connect } @@ -887,7 +923,8 @@ FUNCTION {format.pages.page} } FUNCTION {format.vol.num.pages} -{ volume field.or.null +{ + volume field.or.null number empty$ 'skip$ { @@ -909,21 +946,24 @@ FUNCTION {format.vol.num.pages} } FUNCTION {format.volume} -{ volume empty$ +{ + volume empty$ { "" } { bbl.vvol volume tie.or.space.connect } if$ } FUNCTION {format.number} -{ number empty$ +{ + number empty$ { "" } { bbl.nr number tie.or.space.connect } if$ } FUNCTION {empty.misc.check} -{ author empty$ title empty$ howpublished empty$ +{ + author empty$ title empty$ howpublished empty$ month empty$ year empty$ note empty$ and and and and and key empty$ not and @@ -933,7 +973,8 @@ FUNCTION {empty.misc.check} } FUNCTION {format.thesis.type} -{ type empty$ +{ + type empty$ 'skip$ { pop$ type "t" change.case$ @@ -942,7 +983,8 @@ FUNCTION {format.thesis.type} } FUNCTION {format.tr.number} -{ type empty$ +{ + type empty$ { bbl.techrep } 'type if$ @@ -953,7 +995,8 @@ FUNCTION {format.tr.number} } FUNCTION {author.before} -{ author empty$ +{ + author empty$ 'skip$ { format.authors output @@ -963,7 +1006,8 @@ FUNCTION {author.before} } FUNCTION {bookauthor.before} -{ bookauthor empty$ +{ + bookauthor empty$ 'skip$ { format.bookauthors output @@ -973,7 +1017,8 @@ FUNCTION {bookauthor.before} } FUNCTION {author.after} -{ author empty$ +{ + author empty$ 'skip$ { author num.names$ #3 > { format.authors.after output @@ -986,7 +1031,8 @@ FUNCTION {author.after} } FUNCTION {bookauthor.after} -{ bookauthor empty$ +{ + bookauthor empty$ 'skip$ { bookauthor num.names$ #3 > { format.bookauthors.after output @@ -999,7 +1045,8 @@ FUNCTION {bookauthor.after} } FUNCTION {editor.organization.after} -{ compiler empty$ +{ + compiler empty$ 'skip$ { format.compiler.after output new.semicolumn @@ -1020,14 +1067,16 @@ FUNCTION {editor.organization.after} } FUNCTION {format.url} -{ url empty$ +{ + url empty$ { "" } { "\BibUrl{" url * "}" * } if$ } FUNCTION {format.urldate} -{ urldate empty$ +{ + urldate empty$ { "" } { add.blank "\BibUrlDate{" urldate * "}" * @@ -1036,7 +1085,8 @@ FUNCTION {format.urldate} } FUNCTION {output.url} -{ url empty$ +{ + url empty$ 'skip$ { format.url output format.urldate output @@ -1045,7 +1095,8 @@ FUNCTION {output.url} } FUNCTION {format.annote} -{ annote empty$ +{ + annote empty$ { "" } { after.sentence 'output.state := "\BibAnnote{" annote add.period$ * "}" * @@ -1054,7 +1105,8 @@ FUNCTION {format.annote} } FUNCTION {article} -{ output.bibitem +{ + output.bibitem author.before format.title "title" output.check new.dblslash @@ -1075,7 +1127,8 @@ FUNCTION {article} } FUNCTION {book} -{ output.bibitem +{ + output.bibitem author.before format.btitle "title" output.check editor.organization.after @@ -1098,7 +1151,8 @@ FUNCTION {book} } FUNCTION {booklet} -{ output.bibitem +{ + output.bibitem author.before format.title "title" output.check editor.organization.after @@ -1115,7 +1169,8 @@ FUNCTION {booklet} } FUNCTION {inbook} -{ output.bibitem +{ + output.bibitem author.before format.btitle "title" output.check new.dblslash @@ -1141,7 +1196,8 @@ FUNCTION {inbook} } FUNCTION {incollection} -{ output.bibitem +{ + output.bibitem author.before new.sentence format.title "title" output.check @@ -1160,13 +1216,13 @@ FUNCTION {incollection} note output new.block output.url - new.block format.annote output fin.entry } FUNCTION {inproceedings} -{ output.bibitem +{ + output.bibitem author.before new.sentence format.title "title" output.check @@ -1201,7 +1257,8 @@ FUNCTION {inproceedings} FUNCTION {conference} { inproceedings } FUNCTION {manual} -{ output.bibitem +{ + output.bibitem author empty$ { organization empty$ 'skip$ @@ -1239,7 +1296,8 @@ FUNCTION {manual} } FUNCTION {mastersthesis} -{ output.bibitem +{ + output.bibitem format.authors "author" output.check new.block format.btitle "title" output.check @@ -1257,7 +1315,8 @@ FUNCTION {mastersthesis} } FUNCTION {misc} -{ output.bibitem +{ + output.bibitem format.authors "author" output.check new.block format.title "title" output.check @@ -1274,7 +1333,8 @@ FUNCTION {misc} } FUNCTION {phdthesis} -{ output.bibitem +{ + output.bibitem format.authors "author" output.check new.sentence format.btitle "title" output.check @@ -1294,7 +1354,8 @@ FUNCTION {phdthesis} } FUNCTION {proceedings} -{ output.bibitem +{ + output.bibitem format.btitle "title" output.check new.slash editor.organization.after @@ -1320,7 +1381,8 @@ FUNCTION {proceedings} } FUNCTION {techreport} -{ output.bibitem +{ + output.bibitem author.before new.sentence format.title "title" output.check @@ -1341,7 +1403,8 @@ FUNCTION {techreport} } FUNCTION {unpublished} -{ output.bibitem +{ + output.bibitem author.before format.btitle "title" output.check editor.organization.after @@ -1428,13 +1491,15 @@ STRINGS { longest.label } INTEGERS { number.label longest.label.width } FUNCTION {initialize.longest.label} -{ "" 'longest.label := +{ + "" 'longest.label := #1 'number.label := #0 'longest.label.width := } FUNCTION {longest.label.pass} -{ number.label int.to.str$ 'label := +{ + number.label int.to.str$ 'label := number.label #1 + 'number.label := label width$ longest.label.width > { label 'longest.label := @@ -1449,7 +1514,8 @@ EXECUTE {initialize.longest.label} ITERATE {longest.label.pass} FUNCTION {begin.bib} -{ preamble$ empty$ +{ + preamble$ empty$ 'skip$ { preamble$ write$ newline$ } if$ @@ -1492,7 +1558,8 @@ EXECUTE {init.state.consts} ITERATE {call.type$} FUNCTION {end.bib} -{ newline$ +{ + newline$ "\end{thebibliography}" write$ newline$ } diff --git a/Master/texmf-dist/bibtex/bst/disser/gost705s.bst b/Master/texmf-dist/bibtex/bst/disser/gost705s.bst index 513077582d1..335783ba0a4 100644 --- a/Master/texmf-dist/bibtex/bst/disser/gost705s.bst +++ b/Master/texmf-dist/bibtex/bst/disser/gost705s.bst @@ -74,7 +74,8 @@ INTEGERS { output.state before.all mid.sentence after.sentence after.block after.dblslash after.slash after.column after.semicolumn } FUNCTION {init.state.consts} -{ #0 'before.all := +{ + #0 'before.all := #1 'mid.sentence := #2 'after.sentence := #3 'after.block := @@ -89,18 +90,20 @@ STRINGS { s t } STRINGS { curlanguage } FUNCTION {change.language} -{ booklanguage empty$ - { "" } - { booklanguage 'curlanguage := - "\selectlanguageifdefined{" - curlanguage * - "}" * - } +{ + booklanguage empty$ + { "" } + { booklanguage 'curlanguage := + "\selectlanguageifdefined{" + curlanguage * + "}" * + } if$ } FUNCTION {output.nonnull} -{ swap$ +{ + swap$ output.state mid.sentence = { ", " * write$ } { output.state after.block = @@ -136,14 +139,16 @@ FUNCTION {output.nonnull} } FUNCTION {output} -{ duplicate$ empty$ +{ + duplicate$ empty$ 'pop$ 'output.nonnull if$ } FUNCTION {output.check} -{ 't := +{ + 't := duplicate$ empty$ { pop$ "empty " t * " in " * cite$ * warning$ } 'output.nonnull @@ -151,48 +156,55 @@ FUNCTION {output.check} } FUNCTION {fin.entry} -{ add.period$ +{ + add.period$ write$ newline$ } FUNCTION {new.block} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.block 'output.state := } if$ } FUNCTION {new.dblslash} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.dblslash 'output.state := } if$ } FUNCTION {new.slash} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.slash 'output.state := } if$ } FUNCTION {new.column} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.column 'output.state := } if$ } FUNCTION {new.semicolumn} -{ output.state before.all = +{ + output.state before.all = 'skip$ { after.semicolumn 'output.state := } if$ } FUNCTION {new.sentence} -{ output.state after.block = +{ + output.state after.block = 'skip$ { output.state before.all = 'skip$ @@ -202,42 +214,47 @@ FUNCTION {new.sentence} if$ } -FUNCTION {add.blank} -{ " " * before.all 'output.state := } +FUNCTION {add.blank} { " " * before.all 'output.state := } FUNCTION {not} -{ { #0 } +{ + { #0 } { #1 } if$ } FUNCTION {and} -{ 'skip$ +{ + 'skip$ { pop$ #0 } if$ } FUNCTION {or} -{ { pop$ #1 } +{ + { pop$ #1 } 'skip$ if$ } FUNCTION {non.stop} -{ duplicate$ +{ + duplicate$ "}" * add.period$ #-1 #1 substring$ "." = } FUNCTION {new.block.checka} -{ empty$ +{ + empty$ 'skip$ 'new.block if$ } FUNCTION {new.block.checkb} -{ empty$ +{ + empty$ swap$ empty$ and 'skip$ @@ -246,14 +263,16 @@ FUNCTION {new.block.checkb} } FUNCTION {new.sentence.checka} -{ empty$ +{ + empty$ 'skip$ 'new.sentence if$ } FUNCTION {new.sentence.checkb} -{ empty$ +{ + empty$ swap$ empty$ and 'skip$ @@ -262,21 +281,22 @@ FUNCTION {new.sentence.checkb} } FUNCTION {field.or.null} -{ duplicate$ empty$ +{ + duplicate$ empty$ { pop$ "" } 'skip$ if$ } FUNCTION {emphasize} -{ duplicate$ empty$ +{ + duplicate$ empty$ { pop$ "" } { "\BibEmph{" swap$ * "}" * } if$ } -FUNCTION {space.word} -{ " " swap$ * " " * } +FUNCTION {space.word} { " " swap$ * " " * } FUNCTION {bbl.edby} % { "\bbledby{}" } { @@ -307,8 +327,8 @@ FUNCTION {bbl.edition} % { "\bbledition{}" } curlanguage "english" = { "edition" } { curlanguage "russian" = - {"{\cyr\cyri\cyrz\cyrd.}"} - {"language is not defined: " language "edition" * * warning$ "edition"} + { "{\cyr\cyri\cyrz\cyrd.}" } + { "language is not defined: " language "edition" * * warning$ "edition" } if$ } if$ @@ -319,8 +339,8 @@ FUNCTION {bbl.vvolume} % { "\bblVolume{}" } curlanguage "english" = { "Volume" } { curlanguage "russian" = - {"\CYRT\cyro\cyrm"} - {"language is not defined: " language "Volume" * * warning$ "Volume"} + { "{\cyr\CYRT\cyro\cyrm}" } + { "language is not defined: " language "Volume" * * warning$ "Volume" } if$ } if$ @@ -331,7 +351,7 @@ FUNCTION {bbl.vvol} % { "\bblVol{}" } curlanguage "english" = { "Vol." } { curlanguage "russian" = - { "\CYRT." } + { "{\cyr\CYRT.}" } { "language is not defined: " language "Vol." * * warning$ "Vol." } if$ } @@ -343,8 +363,8 @@ FUNCTION {bbl.iissue} % { "\bblIssue{}" } curlanguage "english" = { "Issue" } { curlanguage "russian" = - {"\CYRV\cyrery\cyrp\cyru\cyrs\cyrk"} - {"language is not defined: " language * warning$ "Issue"} + { "{\cyr\CYRV\cyrery\cyrp\cyru\cyrs\cyrk}" } + { "language is not defined: " language * warning$ "Issue" } if$ } if$ @@ -355,8 +375,8 @@ FUNCTION {bbl.iiss} % { "\bblIss{}" } curlanguage "english" = {"Iss."} { curlanguage "russian" = - {"\CYRV\cyrery\cyrp."} - {"language is not defined: " language * warning$ "Issue"} + { "{\cyr\CYRV\cyrery\cyrp.}" } + { "language is not defined: " language * warning$ "Issue" } if$ } if$ @@ -367,8 +387,8 @@ FUNCTION {bbl.of} % { "\bblof{}" } curlanguage "english" = {"of"} { curlanguage "russian" = - {"{\cyr\cyri\cyrz}"} - {"language is not defined: " language "of" * * warning$ "of"} + { "{\cyr\cyri\cyrz}" } + { "language is not defined: " language "of" * * warning$ "of" } if$ } if$ @@ -391,7 +411,7 @@ FUNCTION {bbl.nnumber} % { "\bblNumber{}" } curlanguage "english" = { "Number" } { curlanguage "russian" = - { "\CYRN\cyro\cyrm\cyre\cyrr"} + { "{\cyr\CYRN\cyro\cyrm\cyre\cyrr}" } { "language is not defined: " language "Number" * * warning$ "Number" } if$ } @@ -403,7 +423,7 @@ FUNCTION {bbl.number} % { "\bblnumber{}" } curlanguage "english" = { "number" } { curlanguage "russian" = - { "{\cyr\cyrn\cyro\cyrm\cyre\cyrr}"} + { "{\cyr\cyrn\cyro\cyrm\cyre\cyrr}" } { "language is not defined: " language "number" * * warning$ "number" } if$ } @@ -451,7 +471,7 @@ FUNCTION {bbl.iin} % { "\bblIn{}" } curlanguage "english" = { "In" } { curlanguage "russian" = - { "\CYRV" } + { "{\cyr\CYRV}" } { "language is not defined: " language "In" * * warning$ "In" } if$ } @@ -545,7 +565,8 @@ FUNCTION {bbl.phdthesis} INTEGERS { nameptr namesleft numnames } FUNCTION {format.names} -{ 's := +{ + 's := #1 'nameptr := s num.names$ 'numnames := numnames 'namesleft := @@ -564,8 +585,8 @@ FUNCTION {format.names} { ", " * t * } { t "others" = - t "~others" = - or + t "~others" = + or { " " * bbl.etal * } { ", " * t * } if$ @@ -581,7 +602,8 @@ FUNCTION {format.names} } FUNCTION {format.names.rev} -{ 's := +{ + 's := #1 'nameptr := s num.names$ 'numnames := numnames 'namesleft := @@ -617,56 +639,64 @@ FUNCTION {format.names.rev} } FUNCTION {format.authors} -{ author empty$ +{ + author empty$ { "" } { author format.names emphasize } if$ } FUNCTION {format.bookauthors} -{ bookauthor empty$ +{ + bookauthor empty$ { "" } { bookauthor format.names } if$ } FUNCTION {format.authors.after} -{ author empty$ +{ + author empty$ { "" } { author format.names.rev } if$ } FUNCTION {format.bookauthors.after} -{ bookauthor empty$ +{ + bookauthor empty$ { "" } { bookauthor format.names.rev } if$ } FUNCTION {format.editors.after} -{ editor empty$ +{ + editor empty$ { "" } { bbl.edby editor format.names.rev * } if$ } -FUNCTION { format.compiler.after } -{ compiler empty$ +FUNCTION {format.compiler.after} +{ + compiler empty$ { "" } { bbl.cmplr compiler format.names.rev * } if$ } FUNCTION {format.title} -{ title empty$ +{ + title empty$ { "" } { title } if$ } FUNCTION {format.date} -{ year empty$ +{ + year empty$ { month empty$ { "" } { "there's a month but no year in " cite$ * warning$ @@ -683,7 +713,8 @@ FUNCTION {format.date} } FUNCTION {output.address.publisher.date} -{ address empty$ +{ + address empty$ 'skip$ { address output publisher empty$ @@ -697,7 +728,8 @@ FUNCTION {output.address.publisher.date} } FUNCTION {output.bibitem} -{ newline$ +{ + newline$ "\bibitem[" write$ "\BibPrefix" write$ label write$ @@ -718,7 +750,8 @@ FUNCTION {output.bibitem} } FUNCTION {n.dashify} -{ 't := +{ + 't := "" { t empty$ not } { t #1 #1 substring$ "-" = @@ -742,35 +775,32 @@ FUNCTION {n.dashify} while$ } -FUNCTION {word.in} -{ bbl.iin - " " * } +FUNCTION {word.in} { bbl.iin " " * } -FUNCTION {format.btitle} -{ title } +FUNCTION {format.btitle} { title } FUNCTION {tie.or.space.connect} -{ duplicate$ text.length$ #3 < +{ + duplicate$ text.length$ #3 < { "~" } { " " } if$ swap$ * * } -FUNCTION {tie.connect} -{"~" -swap$ * * -} +FUNCTION {tie.connect} { "~" swap$ * * } FUNCTION {either.or.check} -{ empty$ +{ + empty$ 'pop$ { "can't use both " swap$ * " fields in " * cite$ * warning$ } if$ } FUNCTION {format.bvolume} -{ volume empty$ +{ + volume empty$ { "" } { bbl.vvol volume tie.connect series empty$ @@ -783,7 +813,8 @@ FUNCTION {format.bvolume} } FUNCTION {format.number.series} -{ volume empty$ +{ + volume empty$ { number empty$ { series field.or.null } { series empty$ @@ -805,13 +836,15 @@ FUNCTION {format.number.series} } FUNCTION {is.num} -{ chr.to.int$ +{ + chr.to.int$ duplicate$ "0" chr.to.int$ < not swap$ "9" chr.to.int$ > not and } FUNCTION {extract.num} -{ duplicate$ 't := +{ + duplicate$ 't := "" 's := { t empty$ not } { t #1 #1 substring$ @@ -828,11 +861,11 @@ FUNCTION {extract.num} if$ } -FUNCTION {convert.edition} -{ edition } +FUNCTION {convert.edition} { edition } FUNCTION {format.edition} -{ edition empty$ +{ + edition empty$ { "" } { output.state mid.sentence = { convert.edition "l" change.case$ " " * bbl.edition * } @@ -845,7 +878,8 @@ FUNCTION {format.edition} INTEGERS { multiresult } FUNCTION {multi.page.check} -{ 't := +{ + 't := #0 'multiresult := { multiresult not t empty$ not @@ -865,7 +899,8 @@ FUNCTION {multi.page.check} } FUNCTION {format.pages} -{ pages empty$ +{ + pages empty$ { "" } { pages multi.page.check { bbl.ppages pages n.dashify tie.connect } @@ -876,7 +911,8 @@ FUNCTION {format.pages} } FUNCTION {format.pages.page} -{ pages empty$ +{ + pages empty$ { numpages empty$ { "" } { numpages bbl.pages tie.connect } @@ -887,7 +923,8 @@ FUNCTION {format.pages.page} } FUNCTION {format.vol.num.pages} -{ volume field.or.null +{ + volume field.or.null number empty$ 'skip$ { @@ -909,21 +946,24 @@ FUNCTION {format.vol.num.pages} } FUNCTION {format.volume} -{ volume empty$ +{ + volume empty$ { "" } { bbl.vvol volume tie.or.space.connect } if$ } FUNCTION {format.number} -{ number empty$ +{ + number empty$ { "" } { bbl.nr number tie.or.space.connect } if$ } FUNCTION {empty.misc.check} -{ author empty$ title empty$ howpublished empty$ +{ + author empty$ title empty$ howpublished empty$ month empty$ year empty$ note empty$ and and and and and key empty$ not and @@ -933,7 +973,8 @@ FUNCTION {empty.misc.check} } FUNCTION {format.thesis.type} -{ type empty$ +{ + type empty$ 'skip$ { pop$ type "t" change.case$ @@ -942,7 +983,8 @@ FUNCTION {format.thesis.type} } FUNCTION {format.tr.number} -{ type empty$ +{ + type empty$ { bbl.techrep } 'type if$ @@ -953,7 +995,8 @@ FUNCTION {format.tr.number} } FUNCTION {author.before} -{ author empty$ +{ + author empty$ 'skip$ { format.authors output @@ -963,7 +1006,8 @@ FUNCTION {author.before} } FUNCTION {bookauthor.before} -{ bookauthor empty$ +{ + bookauthor empty$ 'skip$ { format.bookauthors output @@ -973,7 +1017,8 @@ FUNCTION {bookauthor.before} } FUNCTION {author.after} -{ author empty$ +{ + author empty$ 'skip$ { author num.names$ #3 > { format.authors.after output @@ -986,7 +1031,8 @@ FUNCTION {author.after} } FUNCTION {bookauthor.after} -{ bookauthor empty$ +{ + bookauthor empty$ 'skip$ { bookauthor num.names$ #3 > { format.bookauthors.after output @@ -999,7 +1045,8 @@ FUNCTION {bookauthor.after} } FUNCTION {editor.organization.after} -{ compiler empty$ +{ + compiler empty$ 'skip$ { format.compiler.after output new.semicolumn @@ -1020,14 +1067,16 @@ FUNCTION {editor.organization.after} } FUNCTION {format.url} -{ url empty$ +{ + url empty$ { "" } { "\BibUrl{" url * "}" * } if$ } FUNCTION {format.urldate} -{ urldate empty$ +{ + urldate empty$ { "" } { add.blank "\BibUrlDate{" urldate * "}" * @@ -1036,7 +1085,8 @@ FUNCTION {format.urldate} } FUNCTION {output.url} -{ url empty$ +{ + url empty$ 'skip$ { format.url output format.urldate output @@ -1045,7 +1095,8 @@ FUNCTION {output.url} } FUNCTION {format.annote} -{ annote empty$ +{ + annote empty$ { "" } { after.sentence 'output.state := "\BibAnnote{" annote add.period$ * "}" * @@ -1054,7 +1105,8 @@ FUNCTION {format.annote} } FUNCTION {article} -{ output.bibitem +{ + output.bibitem author.before format.title "title" output.check new.dblslash @@ -1075,7 +1127,8 @@ FUNCTION {article} } FUNCTION {book} -{ output.bibitem +{ + output.bibitem author.before format.btitle "title" output.check editor.organization.after @@ -1098,7 +1151,8 @@ FUNCTION {book} } FUNCTION {booklet} -{ output.bibitem +{ + output.bibitem author.before format.title "title" output.check editor.organization.after @@ -1115,7 +1169,8 @@ FUNCTION {booklet} } FUNCTION {inbook} -{ output.bibitem +{ + output.bibitem author.before format.btitle "title" output.check new.dblslash @@ -1141,7 +1196,8 @@ FUNCTION {inbook} } FUNCTION {incollection} -{ output.bibitem +{ + output.bibitem author.before new.sentence format.title "title" output.check @@ -1160,13 +1216,13 @@ FUNCTION {incollection} note output new.block output.url - new.block format.annote output fin.entry } FUNCTION {inproceedings} -{ output.bibitem +{ + output.bibitem author.before new.sentence format.title "title" output.check @@ -1201,7 +1257,8 @@ FUNCTION {inproceedings} FUNCTION {conference} { inproceedings } FUNCTION {manual} -{ output.bibitem +{ + output.bibitem author empty$ { organization empty$ 'skip$ @@ -1239,7 +1296,8 @@ FUNCTION {manual} } FUNCTION {mastersthesis} -{ output.bibitem +{ + output.bibitem format.authors "author" output.check new.block format.btitle "title" output.check @@ -1257,7 +1315,8 @@ FUNCTION {mastersthesis} } FUNCTION {misc} -{ output.bibitem +{ + output.bibitem format.authors "author" output.check new.block format.title "title" output.check @@ -1274,7 +1333,8 @@ FUNCTION {misc} } FUNCTION {phdthesis} -{ output.bibitem +{ + output.bibitem format.authors "author" output.check new.sentence format.btitle "title" output.check @@ -1294,7 +1354,8 @@ FUNCTION {phdthesis} } FUNCTION {proceedings} -{ output.bibitem +{ + output.bibitem format.btitle "title" output.check new.slash editor.organization.after @@ -1320,7 +1381,8 @@ FUNCTION {proceedings} } FUNCTION {techreport} -{ output.bibitem +{ + output.bibitem author.before new.sentence format.title "title" output.check @@ -1341,7 +1403,8 @@ FUNCTION {techreport} } FUNCTION {unpublished} -{ output.bibitem +{ + output.bibitem author.before format.btitle "title" output.check editor.organization.after @@ -1423,14 +1486,16 @@ MACRO {tcs} {"Theoretical Computer Science"} READ FUNCTION {sortify} -{ purify$ +{ + purify$ "l" change.case$ } INTEGERS { len } FUNCTION {chop.word} -{ 's := +{ + 's := 'len := s #1 len substring$ = { s len #1 + global.max$ substring$ } @@ -1439,7 +1504,8 @@ FUNCTION {chop.word} } FUNCTION {sort.format.names} -{ 's := +{ + 's := #1 'nameptr := "" s num.names$ 'numnames := @@ -1463,7 +1529,8 @@ FUNCTION {sort.format.names} } FUNCTION {sort.format.title} -{ 't := +{ + 't := "A " #2 "An " #3 "The " #4 t chop.word @@ -1474,7 +1541,8 @@ FUNCTION {sort.format.title} } FUNCTION {author.sort} -{ author empty$ +{ + author empty$ { key empty$ { "to sort, need author or key in " cite$ * warning$ "" @@ -1483,13 +1551,14 @@ FUNCTION {author.sort} if$ } { - author sort.format.names} + author sort.format.names } if$ } FUNCTION {author.title.sort} -{ author empty$ +{ + author empty$ { title empty$ { key empty$ { "to sort, need author, title, or key in " cite$ * warning$ @@ -1533,13 +1602,15 @@ STRINGS { longest.label } INTEGERS { number.label longest.label.width } FUNCTION {initialize.longest.label} -{ "" 'longest.label := +{ + "" 'longest.label := #1 'number.label := #0 'longest.label.width := } FUNCTION {longest.label.pass} -{ number.label int.to.str$ 'label := +{ + number.label int.to.str$ 'label := number.label #1 + 'number.label := label width$ longest.label.width > { label 'longest.label := @@ -1554,7 +1625,8 @@ EXECUTE {initialize.longest.label} ITERATE {longest.label.pass} FUNCTION {begin.bib} -{ preamble$ empty$ +{ + preamble$ empty$ 'skip$ { preamble$ write$ newline$ } if$ @@ -1597,7 +1669,8 @@ EXECUTE {init.state.consts} ITERATE {call.type$} FUNCTION {end.bib} -{ newline$ +{ + newline$ "\end{thebibliography}" write$ newline$ } |