summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/bibtex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2020-09-09 20:57:31 +0000
committerKarl Berry <karl@freefriends.org>2020-09-09 20:57:31 +0000
commit4a264bf091040319f9bc0a0564729de3a3bfdb11 (patch)
tree02bc05d3a123693f37f4ae758d7c16aa330edeef /Master/texmf-dist/bibtex
parent736754172b88861049bf28a4e4b381af4f42a4af (diff)
thuthesis (9sep20)
git-svn-id: svn://tug.org/texlive/trunk@56305 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/bibtex')
-rw-r--r--Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-author-year.bst530
-rw-r--r--Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-bachelor.bst488
-rw-r--r--Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-numeric.bst516
3 files changed, 1200 insertions, 334 deletions
diff --git a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-author-year.bst b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-author-year.bst
index 071d19764fd..2a361a97c26 100644
--- a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-author-year.bst
+++ b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-author-year.bst
@@ -4,7 +4,7 @@
%%
%% The original source files were:
%%
-%% gbt7714.dtx (with options: `thu,2005,authoryear')
+%% gbt7714.dtx (with options: `thu,2015,authoryear')
%% -------------------------------------------------------------------
%% GB/T 7714-2015 BibTeX Style
%% https://github.com/CTeX-org/gbt7714-bibtex-style
@@ -21,9 +21,14 @@
%% version 2005/12/01 or later.
%% -------------------------------------------------------------------
INTEGERS {
+ citation.et.al.min
+ citation.et.al.use.first
+ bibliography.et.al.min
+ bibliography.et.al.use.first
uppercase.name
- max.num.authors
- period.between.author.year
+ terms.in.macro
+ year.after.author
+ period.after.author
sentence.case.title
link.title
title.in.journal
@@ -32,7 +37,7 @@ INTEGERS {
show.medium.type
slash.for.extraction
in.booktitle
- abbreviate.journal
+ short.journal
italic.journal
bold.journal.volume
show.missing.address.publisher
@@ -52,25 +57,30 @@ INTEGERS {
FUNCTION {load.config}
{
+ #2 'citation.et.al.min :=
+ #1 'citation.et.al.use.first :=
+ #4 'bibliography.et.al.min :=
+ #3 'bibliography.et.al.use.first :=
#0 'uppercase.name :=
- #3 'max.num.authors :=
- #1 'period.between.author.year :=
+ #0 'terms.in.macro :=
+ #1 'year.after.author :=
+ #1 'period.after.author :=
#1 'sentence.case.title :=
#0 'link.title :=
#1 'title.in.journal :=
#1 'show.mark :=
- #1 'space.before.mark :=
+ #0 'space.before.mark :=
#1 'show.medium.type :=
#1 'slash.for.extraction :=
#0 'in.booktitle :=
- #0 'abbreviate.journal :=
+ #0 'short.journal :=
#0 'italic.journal :=
#0 'bold.journal.volume :=
#0 'show.missing.address.publisher :=
#0 'only.start.page :=
#1 'show.urldate :=
#1 'show.url :=
- #0 'show.doi :=
+ #1 'show.doi :=
#0 'show.preprint :=
#0 'show.note :=
#0 'show.english.translation :=
@@ -91,11 +101,15 @@ ENTRY
edition
editor
eprint
+ eprinttype
howpublished
institution
journal
+ journaltitle
key
+ langid
language
+ location
mark
medium
note
@@ -105,6 +119,7 @@ ENTRY
publisher
school
series
+ shortjournal
title
translation
translator
@@ -114,7 +129,7 @@ ENTRY
year
}
{ entry.lang entry.is.electronic is.pure.electronic entry.numbered }
- { label extra.label sort.label short.list entry.mark entry.url }
+ { label extra.label sort.label short.label short.list entry.mark entry.url }
INTEGERS { output.state before.all mid.sentence after.sentence after.block after.slash }
@@ -149,6 +164,9 @@ FUNCTION {bbl.space}
if$
}
+FUNCTION {bbl.and}
+{ "" }
+
FUNCTION {bbl.et.al}
{ entry.lang lang.zh =
{ "等" }
@@ -164,14 +182,25 @@ FUNCTION {bbl.et.al}
if$
}
+FUNCTION {citation.and}
+{ terms.in.macro
+ { "{\biband}" }
+ 'bbl.and
+ if$
+}
+
FUNCTION {citation.et.al}
-{ bbl.et.al }
+{ terms.in.macro
+ { "{\bibetal}" }
+ 'bbl.et.al
+ if$
+}
FUNCTION {bbl.colon} { ": " }
-FUNCTION {bbl.wide.space} { "\ " }
+FUNCTION {bbl.wide.space} { "\quad " }
-FUNCTION {bbl.slash} { " // " }
+FUNCTION {bbl.slash} { "// " }
FUNCTION {bbl.sine.loco}
{ entry.lang lang.zh =
@@ -460,16 +489,27 @@ FUNCTION {check.entry.lang}
get.str.lang
}
+STRINGS { entry.langid }
+
FUNCTION {set.entry.lang}
-{ language empty$
+{ "" 'entry.langid :=
+ language empty$ not
+ { language 'entry.langid := }
+ 'skip$
+ if$
+ langid empty$ not
+ { langid 'entry.langid := }
+ 'skip$
+ if$
+ entry.langid empty$
{ check.entry.lang }
- { language "english" = language "american" = or language "british" = or
+ { entry.langid "english" = entry.langid "american" = or entry.langid "british" = or
{ lang.en }
- { language "chinese" =
+ { entry.langid "chinese" =
{ lang.zh }
- { language "japanese" =
+ { entry.langid "japanese" =
{ lang.ja }
- { language "russian" =
+ { entry.langid "russian" =
{ lang.ru }
{ check.entry.lang }
if$
@@ -495,6 +535,25 @@ FUNCTION {set.entry.numbered}
INTEGERS { nameptr namesleft numnames name.lang }
+FUNCTION {format.name}
+{ "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
+ t "others" =
+ { bbl.et.al }
+ { t get.str.lang 'name.lang :=
+ name.lang lang.en =
+ { t #1 "{vv~}{ll}{~f{~}}" format.name$
+ uppercase.name
+ { "u" change.case$ }
+ 'skip$
+ if$
+ t #1 "{, jj}" format.name$ *
+ }
+ { t #1 "{ll}{ff}" format.name$ }
+ if$
+ }
+ if$
+}
+
FUNCTION {format.names}
{ 's :=
#1 'nameptr :=
@@ -502,31 +561,21 @@ FUNCTION {format.names}
""
numnames 'namesleft :=
{ namesleft #0 > }
- { s nameptr "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
- nameptr #1 >
- { ", " * }
- 'skip$
- if$
- nameptr max.num.authors >
- { bbl.et.al *
+ { s nameptr format.name bbl.et.al =
+ numnames bibliography.et.al.min #1 - > nameptr bibliography.et.al.use.first > and or
+ { ", " *
+ bbl.et.al *
#1 'namesleft :=
}
- { t "others" =
- { bbl.et.al * }
- { t get.str.lang 'name.lang :=
- name.lang lang.en =
- { t #1 "{vv~}{ll}{~f{~}}" format.name$
- uppercase.name
- { "u" change.case$ }
- 'skip$
- if$
- t #1 "{, jj}" format.name$ *
- }
- { t #1 "{ll}{ff}" format.name$ }
+ { nameptr #1 >
+ { namesleft #1 = bbl.and "" = not and
+ { bbl.and * }
+ { ", " * }
if$
- *
}
+ 'skip$
if$
+ s nameptr format.name *
}
if$
nameptr #1 + 'nameptr :=
@@ -920,18 +969,38 @@ FUNCTION {abbreviate}
}
FUNCTION {format.journal}
-{ journal empty$ not
- { journal
- abbreviate.journal
- 'abbreviate
- 'skip$
+{ ""
+ short.journal
+ { shortjournal empty$ not
+ { shortjournal * }
+ { journal empty$ not
+ { journal * abbreviate }
+ { journaltitle empty$ not
+ { journaltitle * abbreviate }
+ 'skip$
+ if$
+ }
+ if$
+ }
if$
- italic.journal entry.lang lang.en = and
+ }
+ { journal empty$ not
+ { journal * }
+ { journaltitle empty$ not
+ { journaltitle * }
+ 'skip$
+ if$
+ }
+ if$
+ }
+ if$
+ duplicate$ empty$ not
+ { italic.journal entry.lang lang.en = and
'italicize
'skip$
if$
}
- { "" }
+ 'skip$
if$
}
@@ -948,9 +1017,6 @@ FUNCTION {set.entry.mark}
FUNCTION {format.mark}
{ show.mark
- type$ "phdthesis" = type$ "mastersthesis" = or type$ "patent" = or
- medium empty$ not or entry.is.electronic or
- and
{ entry.mark
show.medium.type
{ medium empty$ not
@@ -967,7 +1033,7 @@ FUNCTION {format.mark}
'entry.mark :=
space.before.mark
{ " [" entry.mark * "]" * }
- { "\allowbreak[" entry.mark * "]" * }
+ { "[" entry.mark * "]" * }
if$
}
{ "" }
@@ -1036,8 +1102,15 @@ FUNCTION {format.publisher}
FUNCTION {format.address.publisher}
{ address empty$ not
- { address
- format.publisher empty$ not
+ { address }
+ { location empty$ not
+ { location }
+ { "" }
+ if$
+ }
+ if$
+ duplicate$ empty$ not
+ { format.publisher empty$ not
{ bbl.colon * format.publisher * }
{ entry.is.electronic not show.missing.address.publisher and
{ bbl.colon * bbl.sine.nomine * }
@@ -1046,7 +1119,8 @@ FUNCTION {format.address.publisher}
}
if$
}
- { entry.is.electronic not show.missing.address.publisher and
+ { pop$
+ entry.is.electronic not show.missing.address.publisher and
{ format.publisher empty$ not
{ bbl.sine.loco bbl.colon * format.publisher * }
{ bbl.sine.loco.sine.nomine }
@@ -1117,9 +1191,93 @@ FUNCTION {contains.dash}
if$
}
+FUNCTION {extract.before.slash}
+{ duplicate$ empty$
+ { pop$ "" }
+ { 's :=
+ #1 'charptr :=
+ s text.length$ #1 + 'len :=
+ { charptr len <
+ s charptr #1 substring$ "/" = not
+ and
+ }
+ { charptr #1 + 'charptr := }
+ while$
+ s #1 charptr #1 - substring$
+ }
+ if$
+}
+
+FUNCTION {extract.after.slash}
+{ duplicate$ empty$
+ { pop$ "" }
+ { 's :=
+ #1 'charptr :=
+ s text.length$ #1 + 'len :=
+ { charptr len <
+ s charptr #1 substring$ "-" = not
+ and
+ s charptr #1 substring$ "/" = not
+ and
+ }
+ { charptr #1 + 'charptr := }
+ while$
+ { charptr len <
+ s charptr #1 substring$ "-" =
+ s charptr #1 substring$ "/" =
+ or
+ and
+ }
+ { charptr #1 + 'charptr := }
+ while$
+ s charptr global.max$ substring$
+ }
+ if$
+}
+
+FUNCTION {contains.slash}
+{ duplicate$ empty$
+ { pop$ #0 }
+ { 's :=
+ { s empty$ not
+ s #1 #1 substring$ "-" = not
+ and
+ s #1 #1 substring$ "/" = not
+ and
+ }
+ { s #2 global.max$ substring$ 's := }
+ while$
+ s empty$ not
+ }
+ if$
+}
+
FUNCTION {format.year}
{ year empty$ not
- { year extract.before.dash }
+ { year extract.before.slash extra.label * }
+ { date empty$ not
+ { date extract.before.dash extra.label * }
+ { "empty year in " cite$ * warning$
+ urldate empty$ not
+ { "[" urldate extract.before.dash * extra.label * "]" * }
+ { "" }
+ if$
+ }
+ if$
+ }
+ if$
+}
+
+FUNCTION {format.periodical.year}
+{ year empty$ not
+ { year extract.before.slash
+ "--" *
+ year extract.after.slash
+ duplicate$ empty$
+ 'pop$
+ { * }
+ if$
+ }
{ date empty$ not
{ date extract.before.dash }
{ "empty year in " cite$ * warning$
@@ -1131,14 +1289,15 @@ FUNCTION {format.year}
if$
}
if$
- extra.label *
}
FUNCTION {format.date}
{ type$ "patent" = type$ "newspaper" = or
date empty$ not and
{ date }
- { year }
+ { year field.or.null
+ extra.label *
+ }
if$
}
@@ -1224,7 +1383,7 @@ FUNCTION {format.journal.pages}
FUNCTION {format.periodical.year.volume.number}
{ year empty$ not
- { year extract.before.dash }
+ { year extract.before.slash }
{ "empty year in periodical " cite$ * warning$ }
if$
volume empty$ not
@@ -1235,24 +1394,20 @@ FUNCTION {format.periodical.year.volume.number}
{ "\penalty0 (" * number extract.before.dash * ")" * }
'skip$
if$
- year contains.dash
- { "--" *
- year extract.after.dash empty$
- volume extract.after.dash empty$ and
- number extract.after.dash empty$ and not
- { year extract.after.dash empty$ not
- { year extract.after.dash * }
- { year extract.before.dash * }
- if$
- volume empty$ not
- { ", " * volume extract.after.dash * }
- 'skip$
- if$
- number empty$ not
- { "\penalty0 (" * number extract.after.dash * ")" * }
- 'skip$
- if$
- }
+ "--" *
+ year extract.after.slash empty$
+ volume extract.after.dash empty$ and
+ number extract.after.dash empty$ and not
+ { year extract.after.slash empty$ not
+ { year extract.after.slash * }
+ { year extract.before.slash * }
+ if$
+ volume empty$ not
+ { ", " * volume extract.after.dash * }
+ 'skip$
+ if$
+ number empty$ not
+ { "\penalty0 (" * number extract.after.dash * ")" * }
'skip$
if$
}
@@ -1395,11 +1550,22 @@ FUNCTION {check.electronic}
}
FUNCTION {format.eprint}
-{ ""
- archivePrefix empty$ not
- { archivePrefix * ": " *
- "\eprint{https://" *
- archivePrefix "l" change.case$ * ".org/abs/" * eprint * "}{" *
+{ eprinttype empty$ not
+ { eprinttype }
+ { archivePrefix empty$ not
+ { archivePrefix }
+ { "" }
+ if$
+ }
+ if$
+ 's :=
+ s empty$ not
+ { s ": \eprint{" *
+ url empty$ not
+ { url }
+ { "https://" s "l" change.case$ * ".org/abs/" * eprint * }
+ if$
+ * "}{" *
eprint * "}" *
}
{ eprint }
@@ -1470,11 +1636,15 @@ FUNCTION {monograph}
}
if$
output
- period.between.author.year
- 'new.sentence
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
'skip$
if$
- format.year "year" output.check
new.block
format.series.vol.num.title "title" output.check
"M" set.entry.mark
@@ -1485,6 +1655,10 @@ FUNCTION {monograph}
format.edition output
new.block
format.address.publisher output
+ year.after.author not
+ { format.year "year" output.check }
+ 'skip$
+ if$
format.pages bbl.colon output.after
format.urldate "" output.after
output.url
@@ -1499,11 +1673,15 @@ FUNCTION {incollection}
output.translation
format.authors output
author format.key output
- period.between.author.year
- 'new.sentence
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
'skip$
if$
- format.year "year" output.check
new.block
format.title "title" output.check
"M" set.entry.mark
@@ -1518,6 +1696,10 @@ FUNCTION {incollection}
format.edition output
new.block
format.address.publisher output
+ year.after.author not
+ { format.year "year" output.check }
+ 'skip$
+ if$
format.extracted.pages bbl.colon output.after
format.urldate "" output.after
output.url
@@ -1532,11 +1714,15 @@ FUNCTION {periodical}
output.translation
format.authors output
author format.key output
- period.between.author.year
- 'new.sentence
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
'skip$
if$
- format.year "year" output.check
new.block
format.title "title" output.check
"J" set.entry.mark
@@ -1545,6 +1731,10 @@ FUNCTION {periodical}
format.periodical.year.volume.number output
new.block
format.address.publisher output
+ year.after.author not
+ { format.periodical.year "year" output.check }
+ 'skip$
+ if$
format.urldate "" output.after
output.url
output.doi
@@ -1558,11 +1748,15 @@ FUNCTION {article}
output.translation
format.authors output
author format.key output
- period.between.author.year
- 'new.sentence
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
'skip$
if$
- format.year "year" output.check
new.block
title.in.journal
{ format.title "title" output.check
@@ -1573,6 +1767,10 @@ FUNCTION {article}
'skip$
if$
format.journal "journal" output.check
+ year.after.author not
+ { format.date "year" output.check }
+ 'skip$
+ if$
format.journal.volume output
format.journal.number "" output.after
format.journal.pages "" output.after
@@ -1589,11 +1787,15 @@ FUNCTION {patent}
output.translation
format.authors output
author format.key output
- period.between.author.year
- 'new.sentence
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
'skip$
if$
- format.year "year" output.check
new.block
format.title "title" output.check
"P" set.entry.mark
@@ -1616,17 +1818,29 @@ FUNCTION {electronic}
output.translation
format.authors output
author format.key output
- period.between.author.year
- 'new.sentence
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
'skip$
if$
- format.year "year" output.check
new.block
format.series.vol.num.title "title" output.check
"EB" set.entry.mark
format.mark "" output.after
new.block
format.address.publisher output
+ year.after.author not
+ { date empty$
+ { format.date output }
+ 'skip$
+ if$
+ }
+ 'skip$
+ if$
format.pages bbl.colon output.after
format.editdate "" output.after
format.urldate "" output.after
@@ -1651,11 +1865,15 @@ FUNCTION {preprint}
}
if$
output
- period.between.author.year
- 'new.sentence
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
'skip$
if$
- format.year "year" output.check
new.block
title.in.journal
{ format.series.vol.num.title "title" output.check
@@ -1670,6 +1888,10 @@ FUNCTION {preprint}
format.edition output
new.block
output.eprint
+ year.after.author not
+ { format.year "year" output.check }
+ 'skip$
+ if$
format.pages bbl.colon output.after
format.urldate "" output.after
output.url
@@ -1689,7 +1911,8 @@ FUNCTION {misc}
'preprint
{ entry.is.electronic
'electronic
- { "Z" set.entry.mark
+ {
+ "Z" set.entry.mark
monograph
}
if$
@@ -1745,11 +1968,7 @@ FUNCTION {map}
FUNCTION {manual} { monograph }
FUNCTION {mastersthesis}
-{ lang.zh entry.lang =
- { "硕士学位论文" }
- { "D" }
- if$
- set.entry.mark
+{ "D" set.entry.mark
monograph
}
@@ -1763,14 +1982,7 @@ FUNCTION {online}
electronic
}
-FUNCTION {phdthesis}
-{ lang.zh entry.lang =
- { "博士学位论文" }
- { "D" }
- if$
- set.entry.mark
- monograph
-}
+FUNCTION {phdthesis} { mastersthesis }
FUNCTION {proceedings}
{ "C" set.entry.mark
@@ -1875,18 +2087,48 @@ FUNCTION {chop.word}
if$
}
+FUNCTION {format.lab.name}
+{ "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
+ t "others" =
+ { citation.et.al }
+ { t get.str.lang 'name.lang :=
+ name.lang lang.zh = name.lang lang.ja = or
+ { t #1 "{ll}{ff}" format.name$ }
+ { t #1 "{vv~}{ll}" format.name$ }
+ if$
+ }
+ if$
+}
+
FUNCTION {format.lab.names}
{ 's :=
- s #1 "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
- t get.str.lang 'name.lang :=
- name.lang lang.en =
- { t #1 "{vv~}{ll}" format.name$}
- { t #1 "{ll}{ff}" format.name$}
- if$
- s num.names$ #1 >
- { bbl.space * citation.et.al * }
- 'skip$
- if$
+ s #1 format.lab.name 'short.label :=
+ #1 'nameptr :=
+ s num.names$ 'numnames :=
+ ""
+ numnames 'namesleft :=
+ { namesleft #0 > }
+ { s nameptr format.lab.name citation.et.al =
+ numnames citation.et.al.min #1 - > nameptr citation.et.al.use.first > and or
+ { bbl.space *
+ citation.et.al *
+ #1 'namesleft :=
+ }
+ { nameptr #1 >
+ { namesleft #1 = citation.and "" = not and
+ { citation.and * }
+ { ", " * }
+ if$
+ }
+ 'skip$
+ if$
+ s nameptr format.lab.name *
+ }
+ if$
+ nameptr #1 + 'nameptr :=
+ namesleft #1 - 'namesleft :=
+ }
+ while$
}
FUNCTION {author.key.label}
@@ -1946,7 +2188,8 @@ FUNCTION {editor.key.organization.label}
}
FUNCTION {calc.short.authors}
-{ type$ "book" =
+{ "" 'short.label :=
+ type$ "book" =
type$ "inbook" =
or
'author.editor.key.label
@@ -1963,6 +2206,10 @@ FUNCTION {calc.short.authors}
}
if$
'short.list :=
+ short.label empty$
+ { short.list 'short.label := }
+ 'skip$
+ if$
}
FUNCTION {calc.label}
@@ -1977,6 +2224,16 @@ FUNCTION {calc.label}
if$
*
'label :=
+ short.label
+ "("
+ *
+ format.year duplicate$ empty$
+ short.list key field.or.null = or
+ { pop$ "" }
+ 'skip$
+ if$
+ *
+ 'short.label :=
}
FUNCTION {sort.language.label}
@@ -1996,6 +2253,7 @@ FUNCTION {sort.language.label}
if$
}
if$
+ #64 +
int.to.chr$
}
@@ -2062,7 +2320,7 @@ FUNCTION {author.sort}
{ author sort.format.names }
if$
}
- { key sortify }
+ { key }
if$
}
@@ -2078,7 +2336,7 @@ FUNCTION {author.editor.sort}
{ author sort.format.names }
if$
}
- { key sortify }
+ { key }
if$
}
@@ -2094,7 +2352,7 @@ FUNCTION {author.organization.sort}
{ author sort.format.names }
if$
}
- { key sortify }
+ { key }
if$
}
@@ -2110,7 +2368,7 @@ FUNCTION {editor.organization.sort}
{ editor sort.format.names }
if$
}
- { key sortify }
+ { key }
if$
}
@@ -2124,6 +2382,8 @@ FUNCTION {presort}
" "
*
sort.language.label
+ " "
+ *
type$ "book" =
type$ "inbook" =
or
@@ -2166,13 +2426,13 @@ FUNCTION {initialize.longest.label}
}
FUNCTION {forward.pass}
-{ last.label label =
+{ last.label short.label =
{ last.extra.num #1 + 'last.extra.num :=
last.extra.num int.to.chr$ 'extra.label :=
}
{ "a" chr.to.int$ 'last.extra.num :=
"" 'extra.label :=
- label 'last.label :=
+ short.label 'last.label :=
}
if$
number.label #1 + 'number.label :=
@@ -2204,6 +2464,14 @@ FUNCTION {begin.bib}
if$
"\begin{thebibliography}{" number.label int.to.str$ * "}" *
write$ newline$
+ terms.in.macro
+ { "\providecommand{\biband}{和}"
+ write$ newline$
+ "\providecommand{\bibetal}{等}"
+ write$ newline$
+ }
+ 'skip$
+ if$
"\providecommand{\natexlab}[1]{#1}"
write$ newline$
"\providecommand{\url}[1]{#1}"
diff --git a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-bachelor.bst b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-bachelor.bst
index bb91ba5c09b..9094bc339bb 100644
--- a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-bachelor.bst
+++ b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-bachelor.bst
@@ -21,9 +21,14 @@
%% version 2005/12/01 or later.
%% -------------------------------------------------------------------
INTEGERS {
+ citation.et.al.min
+ citation.et.al.use.first
+ bibliography.et.al.min
+ bibliography.et.al.use.first
uppercase.name
- max.num.authors
- period.between.author.year
+ terms.in.macro
+ year.after.author
+ period.after.author
sentence.case.title
link.title
title.in.journal
@@ -32,7 +37,7 @@ INTEGERS {
show.medium.type
slash.for.extraction
in.booktitle
- abbreviate.journal
+ short.journal
italic.journal
bold.journal.volume
show.missing.address.publisher
@@ -47,8 +52,14 @@ INTEGERS {
FUNCTION {load.config}
{
+ #2 'citation.et.al.min :=
+ #1 'citation.et.al.use.first :=
+ #4 'bibliography.et.al.min :=
+ #3 'bibliography.et.al.use.first :=
#1 'uppercase.name :=
- #3 'max.num.authors :=
+ #0 'terms.in.macro :=
+ #0 'year.after.author :=
+ #1 'period.after.author :=
#1 'sentence.case.title :=
#0 'link.title :=
#1 'title.in.journal :=
@@ -57,7 +68,7 @@ FUNCTION {load.config}
#1 'show.medium.type :=
#1 'slash.for.extraction :=
#0 'in.booktitle :=
- #0 'abbreviate.journal :=
+ #0 'short.journal :=
#0 'italic.journal :=
#0 'bold.journal.volume :=
#0 'show.missing.address.publisher :=
@@ -80,11 +91,15 @@ ENTRY
edition
editor
eprint
+ eprinttype
howpublished
institution
journal
+ journaltitle
key
+ langid
language
+ location
mark
medium
note
@@ -94,6 +109,7 @@ ENTRY
publisher
school
series
+ shortjournal
title
translation
translator
@@ -103,7 +119,7 @@ ENTRY
year
}
{ entry.lang entry.is.electronic is.pure.electronic entry.numbered }
- { label extra.label sort.label short.list entry.mark entry.url }
+ { label extra.label sort.label short.label short.list entry.mark entry.url }
INTEGERS { output.state before.all mid.sentence after.sentence after.block after.slash }
@@ -138,6 +154,9 @@ FUNCTION {bbl.space}
if$
}
+FUNCTION {bbl.and}
+{ "" }
+
FUNCTION {bbl.et.al}
{ entry.lang lang.zh =
{ "等" }
@@ -153,8 +172,19 @@ FUNCTION {bbl.et.al}
if$
}
+FUNCTION {citation.and}
+{ terms.in.macro
+ { "{\biband}" }
+ 'bbl.and
+ if$
+}
+
FUNCTION {citation.et.al}
-{ bbl.et.al }
+{ terms.in.macro
+ { "{\bibetal}" }
+ 'bbl.et.al
+ if$
+}
FUNCTION {bbl.colon} { ": " }
@@ -449,16 +479,27 @@ FUNCTION {check.entry.lang}
get.str.lang
}
+STRINGS { entry.langid }
+
FUNCTION {set.entry.lang}
-{ language empty$
+{ "" 'entry.langid :=
+ language empty$ not
+ { language 'entry.langid := }
+ 'skip$
+ if$
+ langid empty$ not
+ { langid 'entry.langid := }
+ 'skip$
+ if$
+ entry.langid empty$
{ check.entry.lang }
- { language "english" = language "american" = or language "british" = or
+ { entry.langid "english" = entry.langid "american" = or entry.langid "british" = or
{ lang.en }
- { language "chinese" =
+ { entry.langid "chinese" =
{ lang.zh }
- { language "japanese" =
+ { entry.langid "japanese" =
{ lang.ja }
- { language "russian" =
+ { entry.langid "russian" =
{ lang.ru }
{ check.entry.lang }
if$
@@ -484,6 +525,25 @@ FUNCTION {set.entry.numbered}
INTEGERS { nameptr namesleft numnames name.lang }
+FUNCTION {format.name}
+{ "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
+ t "others" =
+ { bbl.et.al }
+ { t get.str.lang 'name.lang :=
+ name.lang lang.en =
+ { t #1 "{vv~}{ll}{~f{~}}" format.name$
+ uppercase.name
+ { "u" change.case$ }
+ 'skip$
+ if$
+ t #1 "{, jj}" format.name$ *
+ }
+ { t #1 "{ll}{ff}" format.name$ }
+ if$
+ }
+ if$
+}
+
FUNCTION {format.names}
{ 's :=
#1 'nameptr :=
@@ -491,31 +551,21 @@ FUNCTION {format.names}
""
numnames 'namesleft :=
{ namesleft #0 > }
- { s nameptr "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
- nameptr #1 >
- { ", " * }
- 'skip$
- if$
- nameptr max.num.authors >
- { bbl.et.al *
+ { s nameptr format.name bbl.et.al =
+ numnames bibliography.et.al.min #1 - > nameptr bibliography.et.al.use.first > and or
+ { ", " *
+ bbl.et.al *
#1 'namesleft :=
}
- { t "others" =
- { bbl.et.al * }
- { t get.str.lang 'name.lang :=
- name.lang lang.en =
- { t #1 "{vv~}{ll}{~f{~}}" format.name$
- uppercase.name
- { "u" change.case$ }
- 'skip$
- if$
- t #1 "{, jj}" format.name$ *
- }
- { t #1 "{ll}{ff}" format.name$ }
+ { nameptr #1 >
+ { namesleft #1 = bbl.and "" = not and
+ { bbl.and * }
+ { ", " * }
if$
- *
}
+ 'skip$
if$
+ s nameptr format.name *
}
if$
nameptr #1 + 'nameptr :=
@@ -909,18 +959,38 @@ FUNCTION {abbreviate}
}
FUNCTION {format.journal}
-{ journal empty$ not
- { journal
- abbreviate.journal
- 'abbreviate
- 'skip$
+{ ""
+ short.journal
+ { shortjournal empty$ not
+ { shortjournal * }
+ { journal empty$ not
+ { journal * abbreviate }
+ { journaltitle empty$ not
+ { journaltitle * abbreviate }
+ 'skip$
+ if$
+ }
+ if$
+ }
if$
- italic.journal entry.lang lang.en = and
+ }
+ { journal empty$ not
+ { journal * }
+ { journaltitle empty$ not
+ { journaltitle * }
+ 'skip$
+ if$
+ }
+ if$
+ }
+ if$
+ duplicate$ empty$ not
+ { italic.journal entry.lang lang.en = and
'italicize
'skip$
if$
}
- { "" }
+ 'skip$
if$
}
@@ -953,7 +1023,7 @@ FUNCTION {format.mark}
'entry.mark :=
space.before.mark
{ " [" entry.mark * "]" * }
- { "\allowbreak[" entry.mark * "]" * }
+ { "[" entry.mark * "]" * }
if$
}
{ "" }
@@ -1022,8 +1092,15 @@ FUNCTION {format.publisher}
FUNCTION {format.address.publisher}
{ address empty$ not
- { address
- format.publisher empty$ not
+ { address }
+ { location empty$ not
+ { location }
+ { "" }
+ if$
+ }
+ if$
+ duplicate$ empty$ not
+ { format.publisher empty$ not
{ bbl.colon * format.publisher * }
{ entry.is.electronic not show.missing.address.publisher and
{ bbl.colon * bbl.sine.nomine * }
@@ -1032,7 +1109,8 @@ FUNCTION {format.address.publisher}
}
if$
}
- { entry.is.electronic not show.missing.address.publisher and
+ { pop$
+ entry.is.electronic not show.missing.address.publisher and
{ format.publisher empty$ not
{ bbl.sine.loco bbl.colon * format.publisher * }
{ bbl.sine.loco.sine.nomine }
@@ -1103,9 +1181,93 @@ FUNCTION {contains.dash}
if$
}
+FUNCTION {extract.before.slash}
+{ duplicate$ empty$
+ { pop$ "" }
+ { 's :=
+ #1 'charptr :=
+ s text.length$ #1 + 'len :=
+ { charptr len <
+ s charptr #1 substring$ "/" = not
+ and
+ }
+ { charptr #1 + 'charptr := }
+ while$
+ s #1 charptr #1 - substring$
+ }
+ if$
+}
+
+FUNCTION {extract.after.slash}
+{ duplicate$ empty$
+ { pop$ "" }
+ { 's :=
+ #1 'charptr :=
+ s text.length$ #1 + 'len :=
+ { charptr len <
+ s charptr #1 substring$ "-" = not
+ and
+ s charptr #1 substring$ "/" = not
+ and
+ }
+ { charptr #1 + 'charptr := }
+ while$
+ { charptr len <
+ s charptr #1 substring$ "-" =
+ s charptr #1 substring$ "/" =
+ or
+ and
+ }
+ { charptr #1 + 'charptr := }
+ while$
+ s charptr global.max$ substring$
+ }
+ if$
+}
+
+FUNCTION {contains.slash}
+{ duplicate$ empty$
+ { pop$ #0 }
+ { 's :=
+ { s empty$ not
+ s #1 #1 substring$ "-" = not
+ and
+ s #1 #1 substring$ "/" = not
+ and
+ }
+ { s #2 global.max$ substring$ 's := }
+ while$
+ s empty$ not
+ }
+ if$
+}
+
FUNCTION {format.year}
{ year empty$ not
- { year extract.before.dash }
+ { year extract.before.slash extra.label * }
+ { date empty$ not
+ { date extract.before.dash extra.label * }
+ { "empty year in " cite$ * warning$
+ urldate empty$ not
+ { "[" urldate extract.before.dash * extra.label * "]" * }
+ { "" }
+ if$
+ }
+ if$
+ }
+ if$
+}
+
+FUNCTION {format.periodical.year}
+{ year empty$ not
+ { year extract.before.slash
+ "--" *
+ year extract.after.slash
+ duplicate$ empty$
+ 'pop$
+ { * }
+ if$
+ }
{ date empty$ not
{ date extract.before.dash }
{ "empty year in " cite$ * warning$
@@ -1117,14 +1279,15 @@ FUNCTION {format.year}
if$
}
if$
- extra.label *
}
FUNCTION {format.date}
{ type$ "patent" = type$ "newspaper" = or
date empty$ not and
{ date }
- { year }
+ { year field.or.null
+ extra.label *
+ }
if$
}
@@ -1210,7 +1373,7 @@ FUNCTION {format.journal.pages}
FUNCTION {format.periodical.year.volume.number}
{ year empty$ not
- { year extract.before.dash }
+ { year extract.before.slash }
{ "empty year in periodical " cite$ * warning$ }
if$
volume empty$ not
@@ -1221,24 +1384,20 @@ FUNCTION {format.periodical.year.volume.number}
{ "\penalty0 (" * number extract.before.dash * ")" * }
'skip$
if$
- year contains.dash
- { "--" *
- year extract.after.dash empty$
- volume extract.after.dash empty$ and
- number extract.after.dash empty$ and not
- { year extract.after.dash empty$ not
- { year extract.after.dash * }
- { year extract.before.dash * }
- if$
- volume empty$ not
- { ", " * volume extract.after.dash * }
- 'skip$
- if$
- number empty$ not
- { "\penalty0 (" * number extract.after.dash * ")" * }
- 'skip$
- if$
- }
+ "--" *
+ year extract.after.slash empty$
+ volume extract.after.dash empty$ and
+ number extract.after.dash empty$ and not
+ { year extract.after.slash empty$ not
+ { year extract.after.slash * }
+ { year extract.before.slash * }
+ if$
+ volume empty$ not
+ { ", " * volume extract.after.dash * }
+ 'skip$
+ if$
+ number empty$ not
+ { "\penalty0 (" * number extract.after.dash * ")" * }
'skip$
if$
}
@@ -1381,11 +1540,22 @@ FUNCTION {check.electronic}
}
FUNCTION {format.eprint}
-{ ""
- archivePrefix empty$ not
- { archivePrefix * ": " *
- "\eprint{https://" *
- archivePrefix "l" change.case$ * ".org/abs/" * eprint * "}{" *
+{ eprinttype empty$ not
+ { eprinttype }
+ { archivePrefix empty$ not
+ { archivePrefix }
+ { "" }
+ if$
+ }
+ if$
+ 's :=
+ s empty$ not
+ { s ": \eprint{" *
+ url empty$ not
+ { url }
+ { "https://" s "l" change.case$ * ".org/abs/" * eprint * }
+ if$
+ * "}{" *
eprint * "}" *
}
{ eprint }
@@ -1456,6 +1626,15 @@ FUNCTION {monograph}
}
if$
output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.series.vol.num.title "title" output.check
"M" set.entry.mark
@@ -1466,7 +1645,10 @@ FUNCTION {monograph}
format.edition output
new.block
format.address.publisher output
- format.year "year" output.check
+ year.after.author not
+ { format.year "year" output.check }
+ 'skip$
+ if$
format.pages bbl.colon output.after
format.urldate "" output.after
output.url
@@ -1481,6 +1663,15 @@ FUNCTION {incollection}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.title "title" output.check
"M" set.entry.mark
@@ -1495,7 +1686,10 @@ FUNCTION {incollection}
format.edition output
new.block
format.address.publisher output
- format.year "year" output.check
+ year.after.author not
+ { format.year "year" output.check }
+ 'skip$
+ if$
format.extracted.pages bbl.colon output.after
format.urldate "" output.after
output.url
@@ -1510,6 +1704,15 @@ FUNCTION {periodical}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.title "title" output.check
"J" set.entry.mark
@@ -1518,7 +1721,10 @@ FUNCTION {periodical}
format.periodical.year.volume.number output
new.block
format.address.publisher output
- format.date "year" output.check
+ year.after.author not
+ { format.periodical.year "year" output.check }
+ 'skip$
+ if$
format.urldate "" output.after
output.url
output.doi
@@ -1532,6 +1738,15 @@ FUNCTION {article}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
title.in.journal
{ format.title "title" output.check
@@ -1542,7 +1757,10 @@ FUNCTION {article}
'skip$
if$
format.journal "journal" output.check
- format.date "year" output.check
+ year.after.author not
+ { format.date "year" output.check }
+ 'skip$
+ if$
format.journal.volume output
format.journal.number "" output.after
format.journal.pages "" output.after
@@ -1559,6 +1777,15 @@ FUNCTION {patent}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.title "title" output.check
"P" set.entry.mark
@@ -1581,14 +1808,27 @@ FUNCTION {electronic}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.series.vol.num.title "title" output.check
"EB" set.entry.mark
format.mark "" output.after
new.block
format.address.publisher output
- date empty$
- { format.date output }
+ year.after.author not
+ { date empty$
+ { format.date output }
+ 'skip$
+ if$
+ }
'skip$
if$
format.pages bbl.colon output.after
@@ -1615,6 +1855,15 @@ FUNCTION {preprint}
}
if$
output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
title.in.journal
{ format.series.vol.num.title "title" output.check
@@ -1629,7 +1878,10 @@ FUNCTION {preprint}
format.edition output
new.block
output.eprint
- format.year "year" output.check
+ year.after.author not
+ { format.year "year" output.check }
+ 'skip$
+ if$
format.pages bbl.colon output.after
format.urldate "" output.after
output.url
@@ -1649,7 +1901,8 @@ FUNCTION {misc}
'preprint
{ entry.is.electronic
'electronic
- { "Z" set.entry.mark
+ {
+ "Z" set.entry.mark
monograph
}
if$
@@ -1824,18 +2077,48 @@ FUNCTION {chop.word}
if$
}
+FUNCTION {format.lab.name}
+{ "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
+ t "others" =
+ { citation.et.al }
+ { t get.str.lang 'name.lang :=
+ name.lang lang.zh = name.lang lang.ja = or
+ { t #1 "{ll}{ff}" format.name$ }
+ { t #1 "{vv~}{ll}" format.name$ }
+ if$
+ }
+ if$
+}
+
FUNCTION {format.lab.names}
{ 's :=
- s #1 "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
- t get.str.lang 'name.lang :=
- name.lang lang.en =
- { t #1 "{vv~}{ll}" format.name$}
- { t #1 "{ll}{ff}" format.name$}
- if$
- s num.names$ #1 >
- { bbl.space * citation.et.al * }
- 'skip$
- if$
+ s #1 format.lab.name 'short.label :=
+ #1 'nameptr :=
+ s num.names$ 'numnames :=
+ ""
+ numnames 'namesleft :=
+ { namesleft #0 > }
+ { s nameptr format.lab.name citation.et.al =
+ numnames citation.et.al.min #1 - > nameptr citation.et.al.use.first > and or
+ { bbl.space *
+ citation.et.al *
+ #1 'namesleft :=
+ }
+ { nameptr #1 >
+ { namesleft #1 = citation.and "" = not and
+ { citation.and * }
+ { ", " * }
+ if$
+ }
+ 'skip$
+ if$
+ s nameptr format.lab.name *
+ }
+ if$
+ nameptr #1 + 'nameptr :=
+ namesleft #1 - 'namesleft :=
+ }
+ while$
}
FUNCTION {author.key.label}
@@ -1895,7 +2178,8 @@ FUNCTION {editor.key.organization.label}
}
FUNCTION {calc.short.authors}
-{ type$ "book" =
+{ "" 'short.label :=
+ type$ "book" =
type$ "inbook" =
or
'author.editor.key.label
@@ -1912,6 +2196,10 @@ FUNCTION {calc.short.authors}
}
if$
'short.list :=
+ short.label empty$
+ { short.list 'short.label := }
+ 'skip$
+ if$
}
FUNCTION {calc.label}
@@ -1926,6 +2214,16 @@ FUNCTION {calc.label}
if$
*
'label :=
+ short.label
+ "("
+ *
+ format.year duplicate$ empty$
+ short.list key field.or.null = or
+ { pop$ "" }
+ 'skip$
+ if$
+ *
+ 'short.label :=
}
INTEGERS { seq.num }
@@ -1969,13 +2267,13 @@ FUNCTION {initialize.longest.label}
}
FUNCTION {forward.pass}
-{ last.label label =
+{ last.label short.label =
{ last.extra.num #1 + 'last.extra.num :=
last.extra.num int.to.chr$ 'extra.label :=
}
{ "a" chr.to.int$ 'last.extra.num :=
"" 'extra.label :=
- label 'last.label :=
+ short.label 'last.label :=
}
if$
number.label #1 + 'number.label :=
@@ -2007,6 +2305,14 @@ FUNCTION {begin.bib}
if$
"\begin{thebibliography}{" number.label int.to.str$ * "}" *
write$ newline$
+ terms.in.macro
+ { "\providecommand{\biband}{和}"
+ write$ newline$
+ "\providecommand{\bibetal}{等}"
+ write$ newline$
+ }
+ 'skip$
+ if$
"\providecommand{\natexlab}[1]{#1}"
write$ newline$
"\providecommand{\url}[1]{#1}"
diff --git a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-numeric.bst b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-numeric.bst
index 234b065a7d5..9bb0702e39e 100644
--- a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-numeric.bst
+++ b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-numeric.bst
@@ -4,7 +4,7 @@
%%
%% The original source files were:
%%
-%% gbt7714.dtx (with options: `thu,2005,numerical')
+%% gbt7714.dtx (with options: `thu,2015,numerical')
%% -------------------------------------------------------------------
%% GB/T 7714-2015 BibTeX Style
%% https://github.com/CTeX-org/gbt7714-bibtex-style
@@ -21,9 +21,14 @@
%% version 2005/12/01 or later.
%% -------------------------------------------------------------------
INTEGERS {
+ citation.et.al.min
+ citation.et.al.use.first
+ bibliography.et.al.min
+ bibliography.et.al.use.first
uppercase.name
- max.num.authors
- period.between.author.year
+ terms.in.macro
+ year.after.author
+ period.after.author
sentence.case.title
link.title
title.in.journal
@@ -32,7 +37,7 @@ INTEGERS {
show.medium.type
slash.for.extraction
in.booktitle
- abbreviate.journal
+ short.journal
italic.journal
bold.journal.volume
show.missing.address.publisher
@@ -47,24 +52,30 @@ INTEGERS {
FUNCTION {load.config}
{
+ #2 'citation.et.al.min :=
+ #1 'citation.et.al.use.first :=
+ #4 'bibliography.et.al.min :=
+ #3 'bibliography.et.al.use.first :=
#0 'uppercase.name :=
- #3 'max.num.authors :=
+ #0 'terms.in.macro :=
+ #0 'year.after.author :=
+ #1 'period.after.author :=
#1 'sentence.case.title :=
#0 'link.title :=
#1 'title.in.journal :=
#1 'show.mark :=
- #1 'space.before.mark :=
+ #0 'space.before.mark :=
#1 'show.medium.type :=
#1 'slash.for.extraction :=
#0 'in.booktitle :=
- #0 'abbreviate.journal :=
+ #0 'short.journal :=
#0 'italic.journal :=
#0 'bold.journal.volume :=
#0 'show.missing.address.publisher :=
#0 'only.start.page :=
#1 'show.urldate :=
#1 'show.url :=
- #0 'show.doi :=
+ #1 'show.doi :=
#0 'show.preprint :=
#0 'show.note :=
#0 'show.english.translation :=
@@ -80,11 +91,15 @@ ENTRY
edition
editor
eprint
+ eprinttype
howpublished
institution
journal
+ journaltitle
key
+ langid
language
+ location
mark
medium
note
@@ -94,6 +109,7 @@ ENTRY
publisher
school
series
+ shortjournal
title
translation
translator
@@ -103,7 +119,7 @@ ENTRY
year
}
{ entry.lang entry.is.electronic is.pure.electronic entry.numbered }
- { label extra.label sort.label short.list entry.mark entry.url }
+ { label extra.label sort.label short.label short.list entry.mark entry.url }
INTEGERS { output.state before.all mid.sentence after.sentence after.block after.slash }
@@ -138,6 +154,9 @@ FUNCTION {bbl.space}
if$
}
+FUNCTION {bbl.and}
+{ "" }
+
FUNCTION {bbl.et.al}
{ entry.lang lang.zh =
{ "等" }
@@ -153,14 +172,25 @@ FUNCTION {bbl.et.al}
if$
}
+FUNCTION {citation.and}
+{ terms.in.macro
+ { "{\biband}" }
+ 'bbl.and
+ if$
+}
+
FUNCTION {citation.et.al}
-{ bbl.et.al }
+{ terms.in.macro
+ { "{\bibetal}" }
+ 'bbl.et.al
+ if$
+}
FUNCTION {bbl.colon} { ": " }
-FUNCTION {bbl.wide.space} { "\ " }
+FUNCTION {bbl.wide.space} { "\quad " }
-FUNCTION {bbl.slash} { " // " }
+FUNCTION {bbl.slash} { "// " }
FUNCTION {bbl.sine.loco}
{ entry.lang lang.zh =
@@ -449,16 +479,27 @@ FUNCTION {check.entry.lang}
get.str.lang
}
+STRINGS { entry.langid }
+
FUNCTION {set.entry.lang}
-{ language empty$
+{ "" 'entry.langid :=
+ language empty$ not
+ { language 'entry.langid := }
+ 'skip$
+ if$
+ langid empty$ not
+ { langid 'entry.langid := }
+ 'skip$
+ if$
+ entry.langid empty$
{ check.entry.lang }
- { language "english" = language "american" = or language "british" = or
+ { entry.langid "english" = entry.langid "american" = or entry.langid "british" = or
{ lang.en }
- { language "chinese" =
+ { entry.langid "chinese" =
{ lang.zh }
- { language "japanese" =
+ { entry.langid "japanese" =
{ lang.ja }
- { language "russian" =
+ { entry.langid "russian" =
{ lang.ru }
{ check.entry.lang }
if$
@@ -484,6 +525,25 @@ FUNCTION {set.entry.numbered}
INTEGERS { nameptr namesleft numnames name.lang }
+FUNCTION {format.name}
+{ "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
+ t "others" =
+ { bbl.et.al }
+ { t get.str.lang 'name.lang :=
+ name.lang lang.en =
+ { t #1 "{vv~}{ll}{~f{~}}" format.name$
+ uppercase.name
+ { "u" change.case$ }
+ 'skip$
+ if$
+ t #1 "{, jj}" format.name$ *
+ }
+ { t #1 "{ll}{ff}" format.name$ }
+ if$
+ }
+ if$
+}
+
FUNCTION {format.names}
{ 's :=
#1 'nameptr :=
@@ -491,31 +551,21 @@ FUNCTION {format.names}
""
numnames 'namesleft :=
{ namesleft #0 > }
- { s nameptr "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
- nameptr #1 >
- { ", " * }
- 'skip$
- if$
- nameptr max.num.authors >
- { bbl.et.al *
+ { s nameptr format.name bbl.et.al =
+ numnames bibliography.et.al.min #1 - > nameptr bibliography.et.al.use.first > and or
+ { ", " *
+ bbl.et.al *
#1 'namesleft :=
}
- { t "others" =
- { bbl.et.al * }
- { t get.str.lang 'name.lang :=
- name.lang lang.en =
- { t #1 "{vv~}{ll}{~f{~}}" format.name$
- uppercase.name
- { "u" change.case$ }
- 'skip$
- if$
- t #1 "{, jj}" format.name$ *
- }
- { t #1 "{ll}{ff}" format.name$ }
+ { nameptr #1 >
+ { namesleft #1 = bbl.and "" = not and
+ { bbl.and * }
+ { ", " * }
if$
- *
}
+ 'skip$
if$
+ s nameptr format.name *
}
if$
nameptr #1 + 'nameptr :=
@@ -909,18 +959,38 @@ FUNCTION {abbreviate}
}
FUNCTION {format.journal}
-{ journal empty$ not
- { journal
- abbreviate.journal
- 'abbreviate
- 'skip$
+{ ""
+ short.journal
+ { shortjournal empty$ not
+ { shortjournal * }
+ { journal empty$ not
+ { journal * abbreviate }
+ { journaltitle empty$ not
+ { journaltitle * abbreviate }
+ 'skip$
+ if$
+ }
+ if$
+ }
+ if$
+ }
+ { journal empty$ not
+ { journal * }
+ { journaltitle empty$ not
+ { journaltitle * }
+ 'skip$
+ if$
+ }
if$
- italic.journal entry.lang lang.en = and
+ }
+ if$
+ duplicate$ empty$ not
+ { italic.journal entry.lang lang.en = and
'italicize
'skip$
if$
}
- { "" }
+ 'skip$
if$
}
@@ -937,9 +1007,6 @@ FUNCTION {set.entry.mark}
FUNCTION {format.mark}
{ show.mark
- type$ "phdthesis" = type$ "mastersthesis" = or type$ "patent" = or
- medium empty$ not or entry.is.electronic or
- and
{ entry.mark
show.medium.type
{ medium empty$ not
@@ -956,7 +1023,7 @@ FUNCTION {format.mark}
'entry.mark :=
space.before.mark
{ " [" entry.mark * "]" * }
- { "\allowbreak[" entry.mark * "]" * }
+ { "[" entry.mark * "]" * }
if$
}
{ "" }
@@ -1025,8 +1092,15 @@ FUNCTION {format.publisher}
FUNCTION {format.address.publisher}
{ address empty$ not
- { address
- format.publisher empty$ not
+ { address }
+ { location empty$ not
+ { location }
+ { "" }
+ if$
+ }
+ if$
+ duplicate$ empty$ not
+ { format.publisher empty$ not
{ bbl.colon * format.publisher * }
{ entry.is.electronic not show.missing.address.publisher and
{ bbl.colon * bbl.sine.nomine * }
@@ -1035,7 +1109,8 @@ FUNCTION {format.address.publisher}
}
if$
}
- { entry.is.electronic not show.missing.address.publisher and
+ { pop$
+ entry.is.electronic not show.missing.address.publisher and
{ format.publisher empty$ not
{ bbl.sine.loco bbl.colon * format.publisher * }
{ bbl.sine.loco.sine.nomine }
@@ -1106,9 +1181,93 @@ FUNCTION {contains.dash}
if$
}
+FUNCTION {extract.before.slash}
+{ duplicate$ empty$
+ { pop$ "" }
+ { 's :=
+ #1 'charptr :=
+ s text.length$ #1 + 'len :=
+ { charptr len <
+ s charptr #1 substring$ "/" = not
+ and
+ }
+ { charptr #1 + 'charptr := }
+ while$
+ s #1 charptr #1 - substring$
+ }
+ if$
+}
+
+FUNCTION {extract.after.slash}
+{ duplicate$ empty$
+ { pop$ "" }
+ { 's :=
+ #1 'charptr :=
+ s text.length$ #1 + 'len :=
+ { charptr len <
+ s charptr #1 substring$ "-" = not
+ and
+ s charptr #1 substring$ "/" = not
+ and
+ }
+ { charptr #1 + 'charptr := }
+ while$
+ { charptr len <
+ s charptr #1 substring$ "-" =
+ s charptr #1 substring$ "/" =
+ or
+ and
+ }
+ { charptr #1 + 'charptr := }
+ while$
+ s charptr global.max$ substring$
+ }
+ if$
+}
+
+FUNCTION {contains.slash}
+{ duplicate$ empty$
+ { pop$ #0 }
+ { 's :=
+ { s empty$ not
+ s #1 #1 substring$ "-" = not
+ and
+ s #1 #1 substring$ "/" = not
+ and
+ }
+ { s #2 global.max$ substring$ 's := }
+ while$
+ s empty$ not
+ }
+ if$
+}
+
FUNCTION {format.year}
{ year empty$ not
- { year extract.before.dash }
+ { year extract.before.slash extra.label * }
+ { date empty$ not
+ { date extract.before.dash extra.label * }
+ { "empty year in " cite$ * warning$
+ urldate empty$ not
+ { "[" urldate extract.before.dash * extra.label * "]" * }
+ { "" }
+ if$
+ }
+ if$
+ }
+ if$
+}
+
+FUNCTION {format.periodical.year}
+{ year empty$ not
+ { year extract.before.slash
+ "--" *
+ year extract.after.slash
+ duplicate$ empty$
+ 'pop$
+ { * }
+ if$
+ }
{ date empty$ not
{ date extract.before.dash }
{ "empty year in " cite$ * warning$
@@ -1120,14 +1279,15 @@ FUNCTION {format.year}
if$
}
if$
- extra.label *
}
FUNCTION {format.date}
{ type$ "patent" = type$ "newspaper" = or
date empty$ not and
{ date }
- { year }
+ { year field.or.null
+ extra.label *
+ }
if$
}
@@ -1213,7 +1373,7 @@ FUNCTION {format.journal.pages}
FUNCTION {format.periodical.year.volume.number}
{ year empty$ not
- { year extract.before.dash }
+ { year extract.before.slash }
{ "empty year in periodical " cite$ * warning$ }
if$
volume empty$ not
@@ -1224,24 +1384,20 @@ FUNCTION {format.periodical.year.volume.number}
{ "\penalty0 (" * number extract.before.dash * ")" * }
'skip$
if$
- year contains.dash
- { "--" *
- year extract.after.dash empty$
- volume extract.after.dash empty$ and
- number extract.after.dash empty$ and not
- { year extract.after.dash empty$ not
- { year extract.after.dash * }
- { year extract.before.dash * }
- if$
- volume empty$ not
- { ", " * volume extract.after.dash * }
- 'skip$
- if$
- number empty$ not
- { "\penalty0 (" * number extract.after.dash * ")" * }
- 'skip$
- if$
- }
+ "--" *
+ year extract.after.slash empty$
+ volume extract.after.dash empty$ and
+ number extract.after.dash empty$ and not
+ { year extract.after.slash empty$ not
+ { year extract.after.slash * }
+ { year extract.before.slash * }
+ if$
+ volume empty$ not
+ { ", " * volume extract.after.dash * }
+ 'skip$
+ if$
+ number empty$ not
+ { "\penalty0 (" * number extract.after.dash * ")" * }
'skip$
if$
}
@@ -1384,11 +1540,22 @@ FUNCTION {check.electronic}
}
FUNCTION {format.eprint}
-{ ""
- archivePrefix empty$ not
- { archivePrefix * ": " *
- "\eprint{https://" *
- archivePrefix "l" change.case$ * ".org/abs/" * eprint * "}{" *
+{ eprinttype empty$ not
+ { eprinttype }
+ { archivePrefix empty$ not
+ { archivePrefix }
+ { "" }
+ if$
+ }
+ if$
+ 's :=
+ s empty$ not
+ { s ": \eprint{" *
+ url empty$ not
+ { url }
+ { "https://" s "l" change.case$ * ".org/abs/" * eprint * }
+ if$
+ * "}{" *
eprint * "}" *
}
{ eprint }
@@ -1459,6 +1626,15 @@ FUNCTION {monograph}
}
if$
output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.series.vol.num.title "title" output.check
"M" set.entry.mark
@@ -1469,7 +1645,10 @@ FUNCTION {monograph}
format.edition output
new.block
format.address.publisher output
- format.year "year" output.check
+ year.after.author not
+ { format.year "year" output.check }
+ 'skip$
+ if$
format.pages bbl.colon output.after
format.urldate "" output.after
output.url
@@ -1484,6 +1663,15 @@ FUNCTION {incollection}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.title "title" output.check
"M" set.entry.mark
@@ -1498,7 +1686,10 @@ FUNCTION {incollection}
format.edition output
new.block
format.address.publisher output
- format.year "year" output.check
+ year.after.author not
+ { format.year "year" output.check }
+ 'skip$
+ if$
format.extracted.pages bbl.colon output.after
format.urldate "" output.after
output.url
@@ -1513,6 +1704,15 @@ FUNCTION {periodical}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.title "title" output.check
"J" set.entry.mark
@@ -1521,7 +1721,10 @@ FUNCTION {periodical}
format.periodical.year.volume.number output
new.block
format.address.publisher output
- format.date "year" output.check
+ year.after.author not
+ { format.periodical.year "year" output.check }
+ 'skip$
+ if$
format.urldate "" output.after
output.url
output.doi
@@ -1535,6 +1738,15 @@ FUNCTION {article}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
title.in.journal
{ format.title "title" output.check
@@ -1545,7 +1757,10 @@ FUNCTION {article}
'skip$
if$
format.journal "journal" output.check
- format.date "year" output.check
+ year.after.author not
+ { format.date "year" output.check }
+ 'skip$
+ if$
format.journal.volume output
format.journal.number "" output.after
format.journal.pages "" output.after
@@ -1562,6 +1777,15 @@ FUNCTION {patent}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.title "title" output.check
"P" set.entry.mark
@@ -1584,14 +1808,27 @@ FUNCTION {electronic}
output.translation
format.authors output
author format.key output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
format.series.vol.num.title "title" output.check
"EB" set.entry.mark
format.mark "" output.after
new.block
format.address.publisher output
- date empty$
- { format.date output }
+ year.after.author not
+ { date empty$
+ { format.date output }
+ 'skip$
+ if$
+ }
'skip$
if$
format.pages bbl.colon output.after
@@ -1618,6 +1855,15 @@ FUNCTION {preprint}
}
if$
output
+ year.after.author
+ { period.after.author
+ 'new.sentence
+ 'skip$
+ if$
+ format.year "year" output.check
+ }
+ 'skip$
+ if$
new.block
title.in.journal
{ format.series.vol.num.title "title" output.check
@@ -1632,7 +1878,10 @@ FUNCTION {preprint}
format.edition output
new.block
output.eprint
- format.year "year" output.check
+ year.after.author not
+ { format.year "year" output.check }
+ 'skip$
+ if$
format.pages bbl.colon output.after
format.urldate "" output.after
output.url
@@ -1652,7 +1901,8 @@ FUNCTION {misc}
'preprint
{ entry.is.electronic
'electronic
- { "Z" set.entry.mark
+ {
+ "Z" set.entry.mark
monograph
}
if$
@@ -1708,11 +1958,7 @@ FUNCTION {map}
FUNCTION {manual} { monograph }
FUNCTION {mastersthesis}
-{ lang.zh entry.lang =
- { "硕士学位论文" }
- { "D" }
- if$
- set.entry.mark
+{ "D" set.entry.mark
monograph
}
@@ -1726,14 +1972,7 @@ FUNCTION {online}
electronic
}
-FUNCTION {phdthesis}
-{ lang.zh entry.lang =
- { "博士学位论文" }
- { "D" }
- if$
- set.entry.mark
- monograph
-}
+FUNCTION {phdthesis} { mastersthesis }
FUNCTION {proceedings}
{ "C" set.entry.mark
@@ -1838,18 +2077,48 @@ FUNCTION {chop.word}
if$
}
+FUNCTION {format.lab.name}
+{ "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
+ t "others" =
+ { citation.et.al }
+ { t get.str.lang 'name.lang :=
+ name.lang lang.zh = name.lang lang.ja = or
+ { t #1 "{ll}{ff}" format.name$ }
+ { t #1 "{vv~}{ll}" format.name$ }
+ if$
+ }
+ if$
+}
+
FUNCTION {format.lab.names}
{ 's :=
- s #1 "{vv~}{ll}{, jj}{, ff}" format.name$ 't :=
- t get.str.lang 'name.lang :=
- name.lang lang.en =
- { t #1 "{vv~}{ll}" format.name$}
- { t #1 "{ll}{ff}" format.name$}
- if$
- s num.names$ #1 >
- { bbl.space * citation.et.al * }
- 'skip$
- if$
+ s #1 format.lab.name 'short.label :=
+ #1 'nameptr :=
+ s num.names$ 'numnames :=
+ ""
+ numnames 'namesleft :=
+ { namesleft #0 > }
+ { s nameptr format.lab.name citation.et.al =
+ numnames citation.et.al.min #1 - > nameptr citation.et.al.use.first > and or
+ { bbl.space *
+ citation.et.al *
+ #1 'namesleft :=
+ }
+ { nameptr #1 >
+ { namesleft #1 = citation.and "" = not and
+ { citation.and * }
+ { ", " * }
+ if$
+ }
+ 'skip$
+ if$
+ s nameptr format.lab.name *
+ }
+ if$
+ nameptr #1 + 'nameptr :=
+ namesleft #1 - 'namesleft :=
+ }
+ while$
}
FUNCTION {author.key.label}
@@ -1909,7 +2178,8 @@ FUNCTION {editor.key.organization.label}
}
FUNCTION {calc.short.authors}
-{ type$ "book" =
+{ "" 'short.label :=
+ type$ "book" =
type$ "inbook" =
or
'author.editor.key.label
@@ -1926,6 +2196,10 @@ FUNCTION {calc.short.authors}
}
if$
'short.list :=
+ short.label empty$
+ { short.list 'short.label := }
+ 'skip$
+ if$
}
FUNCTION {calc.label}
@@ -1940,6 +2214,16 @@ FUNCTION {calc.label}
if$
*
'label :=
+ short.label
+ "("
+ *
+ format.year duplicate$ empty$
+ short.list key field.or.null = or
+ { pop$ "" }
+ 'skip$
+ if$
+ *
+ 'short.label :=
}
INTEGERS { seq.num }
@@ -1983,13 +2267,13 @@ FUNCTION {initialize.longest.label}
}
FUNCTION {forward.pass}
-{ last.label label =
+{ last.label short.label =
{ last.extra.num #1 + 'last.extra.num :=
last.extra.num int.to.chr$ 'extra.label :=
}
{ "a" chr.to.int$ 'last.extra.num :=
"" 'extra.label :=
- label 'last.label :=
+ short.label 'last.label :=
}
if$
number.label #1 + 'number.label :=
@@ -2021,6 +2305,14 @@ FUNCTION {begin.bib}
if$
"\begin{thebibliography}{" number.label int.to.str$ * "}" *
write$ newline$
+ terms.in.macro
+ { "\providecommand{\biband}{和}"
+ write$ newline$
+ "\providecommand{\bibetal}{等}"
+ write$ newline$
+ }
+ 'skip$
+ if$
"\providecommand{\natexlab}[1]{#1}"
write$ newline$
"\providecommand{\url}[1]{#1}"