diff options
author | Norbert Preining <preining@logic.at> | 2021-04-05 01:43:33 +0000 |
---|---|---|
committer | Norbert Preining <preining@logic.at> | 2021-04-05 01:43:33 +0000 |
commit | a0c34b582e3f057d294123f01f48c36394602785 (patch) | |
tree | 8860ec4f46c34d0e188d0b02fa6d654a4d2c12a5 /Master/texmf-dist/bibtex | |
parent | 2e5fcbba355cdc61c85c2d0c67db185c51d462f0 (diff) |
thuthesis (5apr21)
git-svn-id: svn://tug.org/texlive/trunk@58750 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/bibtex')
3 files changed, 99 insertions, 138 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 22126985c57..d25269b8e34 100644 --- a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-author-year.bst +++ b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-author-year.bst @@ -8,7 +8,7 @@ %% ------------------------------------------------------------------- %% GB/T 7714—2015 BibTeX Style %% https://github.com/CTeX-org/gbt7714-bibtex-style -%% Version: 2020/12/17 v2.1 +%% Version: 2021/04/03 v2.1.1 %% ------------------------------------------------------------------- %% Copyright (C) 2016—2021 by Zeping Lee <zepinglee AT gmail.com> %% ------------------------------------------------------------------- @@ -65,7 +65,7 @@ FUNCTION {load.config} #0 'uppercase.name := #0 'terms.in.macro := #1 'year.after.author := - #1 'period.after.author := + #0 'period.after.author := #1 'sentence.case.title := #0 'link.title := #1 'title.in.journal := @@ -78,7 +78,7 @@ FUNCTION {load.config} #0 'italic.journal := #0 'bold.journal.volume := #0 'show.missing.address.publisher := - #0 'space.before.pages := + #1 'space.before.pages := #0 'only.start.page := #1 'show.urldate := #1 'show.url := @@ -250,6 +250,22 @@ FUNCTION {or} if$ } +STRINGS { x y } + +FUNCTION {contains} +{ 'y := + 'x := + y text.length$ 'len := + x text.length$ len - #1 + 'charptr := + { charptr #0 > + x charptr len substring$ y = not + and + } + { charptr #1 - 'charptr := } + while$ + charptr #0 > +} + STRINGS { s t } FUNCTION {output.nonnull} @@ -713,17 +729,13 @@ FUNCTION {output.bibitem} "\bibitem[" write$ label ")" * make.full.names duplicate$ short.list = - { pop$ } - { * } - if$ - 's := - s text.length$ 'charptr := - { charptr #0 > s charptr #1 substring$ "[" = not and } - { charptr #1 - 'charptr := } - while$ - charptr #0 > - { "{" s * "}" * } - { s } + { pop$ } + { duplicate$ "]" contains + { "{" swap$ * "}" * } + 'skip$ + if$ + * + } if$ "]{" * write$ cite$ write$ @@ -1186,21 +1198,6 @@ FUNCTION {extract.after.dash} if$ } -FUNCTION {contains.dash} -{ duplicate$ empty$ - { pop$ #0 } - { 's := - { s empty$ not - s #1 #1 substring$ "-" = not - and - } - { s #2 global.max$ substring$ 's := } - while$ - s empty$ not - } - if$ -} - FUNCTION {extract.before.slash} { duplicate$ empty$ { pop$ "" } @@ -1245,23 +1242,6 @@ FUNCTION {extract.after.slash} 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.slash extra.label * } @@ -2222,7 +2202,10 @@ FUNCTION {calc.short.authors} FUNCTION {calc.label} { calc.short.authors - short.list + short.list "]" contains + { "{" short.list * "}" * } + { short.list } + if$ "(" * format.year duplicate$ empty$ @@ -2230,6 +2213,10 @@ FUNCTION {calc.label} { pop$ "" } 'skip$ if$ + duplicate$ "]" contains + { "{" swap$ * "}" * } + 'skip$ + if$ * 'label := short.label diff --git a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-bachelor.bst b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-bachelor.bst index 1dd06bb8871..5c08210cb3f 100644 --- a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-bachelor.bst +++ b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-bachelor.bst @@ -8,7 +8,7 @@ %% ------------------------------------------------------------------- %% GB/T 7714—2015 BibTeX Style %% https://github.com/CTeX-org/gbt7714-bibtex-style -%% Version: 2020/12/17 v2.1 +%% Version: 2021/04/03 v2.1.1 %% ------------------------------------------------------------------- %% Copyright (C) 2016—2021 by Zeping Lee <zepinglee AT gmail.com> %% ------------------------------------------------------------------- @@ -240,6 +240,22 @@ FUNCTION {or} if$ } +STRINGS { x y } + +FUNCTION {contains} +{ 'y := + 'x := + y text.length$ 'len := + x text.length$ len - #1 + 'charptr := + { charptr #0 > + x charptr len substring$ y = not + and + } + { charptr #1 - 'charptr := } + while$ + charptr #0 > +} + STRINGS { s t } FUNCTION {output.nonnull} @@ -703,17 +719,13 @@ FUNCTION {output.bibitem} "\bibitem[" write$ label ")" * make.full.names duplicate$ short.list = - { pop$ } - { * } - if$ - 's := - s text.length$ 'charptr := - { charptr #0 > s charptr #1 substring$ "[" = not and } - { charptr #1 - 'charptr := } - while$ - charptr #0 > - { "{" s * "}" * } - { s } + { pop$ } + { duplicate$ "]" contains + { "{" swap$ * "}" * } + 'skip$ + if$ + * + } if$ "]{" * write$ cite$ write$ @@ -1176,21 +1188,6 @@ FUNCTION {extract.after.dash} if$ } -FUNCTION {contains.dash} -{ duplicate$ empty$ - { pop$ #0 } - { 's := - { s empty$ not - s #1 #1 substring$ "-" = not - and - } - { s #2 global.max$ substring$ 's := } - while$ - s empty$ not - } - if$ -} - FUNCTION {extract.before.slash} { duplicate$ empty$ { pop$ "" } @@ -1235,23 +1232,6 @@ FUNCTION {extract.after.slash} 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.slash extra.label * } @@ -2212,7 +2192,10 @@ FUNCTION {calc.short.authors} FUNCTION {calc.label} { calc.short.authors - short.list + short.list "]" contains + { "{" short.list * "}" * } + { short.list } + if$ "(" * format.year duplicate$ empty$ @@ -2220,6 +2203,10 @@ FUNCTION {calc.label} { pop$ "" } 'skip$ if$ + duplicate$ "]" contains + { "{" swap$ * "}" * } + 'skip$ + if$ * 'label := short.label diff --git a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-numeric.bst b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-numeric.bst index 6c1eaa63d78..9f57d5ed57d 100644 --- a/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-numeric.bst +++ b/Master/texmf-dist/bibtex/bst/thuthesis/thuthesis-numeric.bst @@ -8,7 +8,7 @@ %% ------------------------------------------------------------------- %% GB/T 7714—2015 BibTeX Style %% https://github.com/CTeX-org/gbt7714-bibtex-style -%% Version: 2020/12/17 v2.1 +%% Version: 2021/04/03 v2.1.1 %% ------------------------------------------------------------------- %% Copyright (C) 2016—2021 by Zeping Lee <zepinglee AT gmail.com> %% ------------------------------------------------------------------- @@ -73,7 +73,7 @@ FUNCTION {load.config} #0 'italic.journal := #0 'bold.journal.volume := #0 'show.missing.address.publisher := - #0 'space.before.pages := + #1 'space.before.pages := #0 'only.start.page := #1 'show.urldate := #1 'show.url := @@ -240,6 +240,22 @@ FUNCTION {or} if$ } +STRINGS { x y } + +FUNCTION {contains} +{ 'y := + 'x := + y text.length$ 'len := + x text.length$ len - #1 + 'charptr := + { charptr #0 > + x charptr len substring$ y = not + and + } + { charptr #1 - 'charptr := } + while$ + charptr #0 > +} + STRINGS { s t } FUNCTION {output.nonnull} @@ -703,17 +719,13 @@ FUNCTION {output.bibitem} "\bibitem[" write$ label ")" * make.full.names duplicate$ short.list = - { pop$ } - { * } - if$ - 's := - s text.length$ 'charptr := - { charptr #0 > s charptr #1 substring$ "[" = not and } - { charptr #1 - 'charptr := } - while$ - charptr #0 > - { "{" s * "}" * } - { s } + { pop$ } + { duplicate$ "]" contains + { "{" swap$ * "}" * } + 'skip$ + if$ + * + } if$ "]{" * write$ cite$ write$ @@ -1176,21 +1188,6 @@ FUNCTION {extract.after.dash} if$ } -FUNCTION {contains.dash} -{ duplicate$ empty$ - { pop$ #0 } - { 's := - { s empty$ not - s #1 #1 substring$ "-" = not - and - } - { s #2 global.max$ substring$ 's := } - while$ - s empty$ not - } - if$ -} - FUNCTION {extract.before.slash} { duplicate$ empty$ { pop$ "" } @@ -1235,23 +1232,6 @@ FUNCTION {extract.after.slash} 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.slash extra.label * } @@ -2212,7 +2192,10 @@ FUNCTION {calc.short.authors} FUNCTION {calc.label} { calc.short.authors - short.list + short.list "]" contains + { "{" short.list * "}" * } + { short.list } + if$ "(" * format.year duplicate$ empty$ @@ -2220,6 +2203,10 @@ FUNCTION {calc.label} { pop$ "" } 'skip$ if$ + duplicate$ "]" contains + { "{" swap$ * "}" * } + 'skip$ + if$ * 'label := short.label |