summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/bibtex/bst
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2023-12-18 20:54:49 +0000
committerKarl Berry <karl@freefriends.org>2023-12-18 20:54:49 +0000
commitcf68068a52192064a0f40b2658276b13eb478088 (patch)
treece54af94e21914a5f0b858138c82be0ab40af4f1 /Master/texmf-dist/bibtex/bst
parentefad7d8a2fa59fd55faeeb2b895f56295aa15a36 (diff)
iran-bibtex (18dec23)
git-svn-id: svn://tug.org/texlive/trunk@69158 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/bibtex/bst')
-rw-r--r--Master/texmf-dist/bibtex/bst/iran-bibtex/iran.bst473
1 files changed, 366 insertions, 107 deletions
diff --git a/Master/texmf-dist/bibtex/bst/iran-bibtex/iran.bst b/Master/texmf-dist/bibtex/bst/iran-bibtex/iran.bst
index f4534d5d621..5d8ee98fa4b 100644
--- a/Master/texmf-dist/bibtex/bst/iran-bibtex/iran.bst
+++ b/Master/texmf-dist/bibtex/bst/iran-bibtex/iran.bst
@@ -1,27 +1,28 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
-%% This file is “iran.bst”,
-%% generated with the DOCSTRIP utility and then modified to support
-%% bilingual (English/Latin, and Persian).
+%% This file is “iran.bst”, v0.3.0 (2023/12/18)
+%% generated with the DOCSTRIP utility, then modified to support
+%% bilingual (English/Latin, and Persian) and be compatible with the
+%% “Iran Manual of Style Citation Guide” (1st edn., 2016).
+%%
%%
-%% Bibliography style for BibTeX base on “Iran Manual of Style”.
%%
-%% Created, and maintained by
%% Copyright (c) 2023 Farshad Rasuli <farshad.rasuli@gmail.com>
%%
+%% This file can be redistributed and/or modified under the terms
+%% of the LaTeX Project Public License version 1.3c, or any later version.
+%% The latest version of the License is at: latex-project.org/lppl.txt
%%
-%% This bibliography style (bst) is part of the “iran-bibtex” package.
+%% This BibTeX bibliography style (bst) file is part of
+%% the “iran-bibtex” package.
%%
%% CTAN: https://ctan.org/pkg/iran-bibtex
-%% Homepage: https://github.com/farshadrasuli/iran-bibtex
+%% CTAN archive: https://ctan.org/tex-archive/biblio/bibtex/contrib/iran-bibtex
+%% Repository: https://github.com/farshadrasuli/iran-bibtex
%% Bug tracker: https://github.com/farshadrasuli/iran-bibtex/issues
%%
%%
%%
-%% This file can be redistributed and/or modified under the terms
-%% of the LaTeX Project Public License version 1.3c, or any later version.
-%% The latest version of the License is at: latex-project.org/lppl.txt
-%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -37,15 +38,14 @@
% in parentheses following. There must be no space before the opening
% parenthesis!
%
-% The \cite command functions as follows:
-% \cite{key} => (Jones et al. 1990)
-% \citet{key} => Jones et al. (1990)
-% \citet*{key} => Jones, Baker, and Smith (1990)
+% The \cite command functions as follows (\cite is equal to \citep command):
% \citep{key} => (Jones et al., 1990)
% \citep*{key} => (Jones, Baker, and Smith, 1990)
% \citep[chap. 2]{key} => (Jones et al., 1990, chap. 2)
% \citep[e.g.][]{key} => (e.g. Jones et al., 1990)
% \citep[e.g.][p. 32]{key} => (e.g. Jones et al., 1990, p. 32)
+% \citet{key} => Jones et al. (1990)
+% \citet*{key} => Jones, Baker, and Smith (1990)
% \citeauthor{key} => Jones et al.
% \citeauthor*{key} => Jones, Baker, and Smith
% \citeyear{key} => 1990
@@ -393,6 +393,14 @@ FUNCTION {bbl.issn}
if$
}
+FUNCTION {bbl.thesis}
+{
+ is.language.persian
+ {"پایان‌نامه"}
+ {"Thesis"}
+ if$
+}
+
FUNCTION {bbl.mthesis}
{
is.language.persian
@@ -1125,12 +1133,10 @@ FUNCTION {format.note}
FUNCTION {format.title}
{
- title "title" bibinfo.check
+ title
duplicate$ empty$
'skip$
- {
- bbl.dquote
- }
+ { bbl.dquote }
if$
}
@@ -1324,7 +1330,7 @@ FUNCTION {format.date}
-FUNCTION {format.article.comment}
+FUNCTION {format.comment}
{
comment
}
@@ -1353,7 +1359,7 @@ FUNCTION {format.article.jour.iss.vol.num.pp}
{
pages empty$ not
{
- " " * volume * " " *
+ " " * volume * "~" *
"(" * number * ")" * ": " *
pages *
}
@@ -1381,8 +1387,8 @@ FUNCTION {format.article.jour.iss.vol.num.pp}
{
pages empty$ not
{
- bbl.comma * " " * bbl.number * "~" * number *
- ": " * pages *
+ bbl.comma * " " * bbl.number * "~" * number * ": " *
+ pages *
}
{
bbl.comma * " " * bbl.number * "~" * number *
@@ -1409,6 +1415,76 @@ FUNCTION {format.article.jour.iss.vol.num.pp}
+FUNCTION {format.article.iss.vol.num.pp}
+{
+ journal empty$ not
+ {
+ issue empty$ not
+ { issue bbl.comma * " " *}
+ { "" }
+ if$
+ volume empty$ not
+ {
+ number empty$ not
+ {
+ pages empty$ not
+ {
+ bbl.comma * " " * bbl.volume * "~" * volume * "~" *
+ "(" * number * ")" * ": " *
+ pages *
+ }
+ {
+ bbl.comma * " " * bbl.volume * "~" * volume * bbl.comma *
+ " " * bbl.number * "~" * number *
+ }
+ if$
+ }
+ {
+ pages empty$ not
+ {
+ bbl.comma * " " * bbl.volume * "~" * volume * ":~" *
+ pages *
+ }
+ {
+ bbl.comma * " " * bbl.volume * "~" * volume *
+ }
+ if$
+ }
+ if$
+ }
+ {
+ number empty$ not
+ {
+ pages empty$ not
+ {
+ bbl.number * "~" * number * ": " *
+ pages *
+ }
+ {
+ bbl.number * "~" * number *
+ }
+ if$
+ }
+ {
+ pages empty$ not
+ {
+ pages *
+ }
+ 'skip$
+ if$
+ }
+ if$
+ }
+ if$
+ }
+ {
+ "journal" output.check
+ }
+ if$
+}
+
+
+
FUNCTION {format.btitle}
{
title "title" bibinfo.check
@@ -1422,7 +1498,7 @@ FUNCTION {format.btitle}
FUNCTION {format.title.in.books}
{
- title "title" bibinfo.check
+ title
duplicate$ empty$
'skip$
{ emphasize }
@@ -2050,6 +2126,76 @@ FUNCTION {format.proc.org.publisher.address} { format.conf.org.publisher.address
+FUNCTION {format.thesis.school.type.address}
+{
+ type empty$
+ {
+ type$ "mastersthesis" =
+ { bbl.mthesis "t" change.case$ }
+ {
+ type$ "phdthesis" =
+ { bbl.phdthesis "t" change.case$ }
+ { bbl.thesis "t" change.case$ }
+ if$
+ }
+ if$
+ school empty$ not
+ {
+ address empty$ not
+ { bbl.comma * " " * school * bbl.comma * " " * address * }
+ { bbl.comma * " " * school * }
+ if$
+ }
+ {
+ address empty$ not
+ { bbl.comma * address * }
+ { add.period$ }
+ if$
+ }
+ if$
+ }
+ {
+ type "~" =
+ {
+ school empty$ not
+ {
+ address empty$ not
+ { school bbl.comma * " " * address * }
+ { school }
+ if$
+ }
+ {
+ address empty$ not
+ { address }
+ { "" }
+ if$
+ }
+ if$
+ }
+ {
+ type
+ school empty$ not
+ {
+ address empty$ not
+ { bbl.comma * " " * school * bbl.comma * " " * address * }
+ { bbl.comma * " " * school * }
+ if$
+ }
+ {
+ address empty$ not
+ { bbl.comma * address * }
+ { add.period$ }
+ if$
+ }
+ if$
+ }
+ if$
+ }
+ if$
+}
+
+
+
FUNCTION {format.edition}
{
edition duplicate$ empty$
@@ -2599,8 +2745,8 @@ FUNCTION {article} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF STYLE
format.authors output.nonnull
name.or.dash
format.date "year" output.check
- new.block format.title "title" output.check
- new.sentence format.article.comment output
+ new.block format.title output
+ new.sentence format.comment output
new.sentence format.by output
crossref missing$
{
@@ -2626,8 +2772,8 @@ FUNCTION {article} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF STYLE
format.editors output.nonnull
name.or.dash
format.date "year" output.check
- new.block format.title "title" output.check
- new.sentence format.article.comment output
+ new.block format.title output
+ new.sentence format.comment output
new.sentence format.by output
crossref missing$
{
@@ -2652,8 +2798,8 @@ FUNCTION {article} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF STYLE
format.translators output.nonnull
name.or.dash
new.sentence format.translateyear output
- new.block format.title "title" output.check
- new.sentence format.article.comment output
+ new.block format.title output
+ new.sentence format.comment output
new.sentence format.by output
new.sentence format.date output
crossref missing$
@@ -2675,14 +2821,16 @@ FUNCTION {article} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF STYLE
{ %%% if author, editor, and translator are empty, proceeds with key
key empty$ not
{
- format.title "title" output.nonnull
+ format.article.journal output.nonnull
name.or.dash
format.date "year" output.check
+ new.block format.title output
+ new.sentence format.comment output
new.sentence format.by output
crossref missing$
{
new.sentence format.edby output
- new.sentence format.article.jour.iss.vol.num.pp output
+ new.sentence format.article.iss.vol.num.pp output
new.sentence format.note output
new.sentence format.issn output
new.sentence format.doi output
@@ -2723,6 +2871,7 @@ FUNCTION {book}
{
new.sentence format.edition output
new.sentence format.impression output
+ new.sentence format.comment output
new.sentence format.by output
new.sentence format.translatedby output
new.sentence format.translateyear output
@@ -2757,6 +2906,7 @@ FUNCTION {book}
{
new.sentence format.edition output
new.sentence format.impression output
+ new.sentence format.comment output
new.sentence format.by output
new.sentence format.translatedby output
new.sentence format.translateyear output
@@ -2790,6 +2940,7 @@ FUNCTION {book}
{
new.sentence format.edition output
new.sentence format.impression output
+ new.sentence format.comment output
new.sentence format.by output
new.sentence format.translatedby output
new.sentence format.translateyear output
@@ -2820,6 +2971,7 @@ FUNCTION {book}
new.block format.title.in.books "title" output.check
new.sentence format.edition output
new.sentence format.impression output
+ new.sentence format.comment output
new.sentence format.by output
new.sentence format.date output
new.sentence format.book.volume.series.number output
@@ -2845,6 +2997,7 @@ FUNCTION {book}
{
new.sentence format.edition output
new.sentence format.impression output
+ new.sentence format.comment output
new.sentence format.by output
new.sentence format.book.volume.series.number output
new.sentence format.incollaborationwith output
@@ -2962,6 +3115,7 @@ FUNCTION {incollection}
name.or.dash
format.date "year" output.check
new.block format.title "title" output.check
+ new.sentence format.comment output
crossref missing$
{
new.sentence format.by output
@@ -2992,6 +3146,7 @@ FUNCTION {incollection}
name.or.dash
format.date "year" output.check
new.block format.title "title" output.check
+ new.sentence format.comment output
crossref missing$
{
new.sentence format.by output
@@ -3021,6 +3176,7 @@ FUNCTION {incollection}
name.or.dash
format.date "year" output.check
new.block format.title "title" output.check
+ new.sentence format.comment output
crossref missing$
{
new.sentence format.by output
@@ -3049,6 +3205,7 @@ FUNCTION {incollection}
name.or.dash
new.sentence format.translateyear output
new.block format.title "title" output.check
+ new.sentence format.comment output
new.sentence format.by output
new.sentence format.date output
new.sentence format.incoll.chapter.booktitle.volume.pages output
@@ -3067,9 +3224,10 @@ FUNCTION {incollection}
{ %%% if author, compiler, editor, and translator fields are empty, proceeds with key
key empty$ not
{
- format.title "title" output.check
+ format.title.in.books output
name.or.dash
format.date "year" output.check
+ new.sentence format.comment output
new.sentence format.by output
crossref missing$
{
@@ -3176,7 +3334,7 @@ FUNCTION {inproceedings}
{ %%% if author, and translator fields are empty, proceeds with key
key empty$ not
{
- format.title "title" output.check
+ format.title.in.books output
name.or.dash
format.date "year" output.check
new.sentence format.by output
@@ -3273,7 +3431,7 @@ FUNCTION {conference}
{ %%% if author, and translator are empty, proceeds with key
key empty$ not
{
- format.title "title" output.check
+ format.title.in.books output
name.or.dash
format.date "year" output.check
new.sentence format.by output
@@ -3331,75 +3489,108 @@ FUNCTION {manual} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF STYLE
-FUNCTION {mastersthesis} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF STYLE
+FUNCTION {format.misc.title}
{
- begin.bibitem
- format.authors "author" output.check
- author format.key output
- name.or.dash
- format.date "year" output.check
- date.block
- format.title
- "title" output.check
- new.block
- bbl.mthesis format.thesis.type output.nonnull
- school "school" bibinfo.warn output
- address "address" bibinfo.check output
- format.doi output
- new.block
- format.note output
- format.eprint output
- format.url output
- end.bibitem
+ title empty$ not
+ { title }
+ 'skip$
+ if$
+}
+
+
+
+FUNCTION {format.howpublished}
+{
+ howpublished
}
-FUNCTION {misc} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF STYLE
+FUNCTION {misc}
{
begin.bibitem
- format.authors output
- author format.key output
- name.or.dash
- format.date "year" output.check
- date.block
- format.title output
- new.block
- howpublished "howpublished" bibinfo.check output
- format.doi output
- new.block
- format.note output
- format.eprint output
- format.url output
+ author empty$ not
+ {
+ format.authors output.nonnull
+ name.or.dash
+ format.date "year" output.check
+ new.block format.misc.title output
+ new.sentence format.by output
+ new.sentence format.howpublished output
+ new.sentence format.publisher.address output
+ new.sentence format.note output
+ new.sentence format.doi output
+ new.sentence format.urldate output
+ new.sentence format.url output
+ }
+ { %%% if author is empty, proceeds with key
+ key empty$ not
+ {
+ format.title.in.books output
+ name.or.dash
+ format.date "year" output.check
+ new.sentence format.by output
+ new.sentence format.howpublished output
+ new.sentence format.publisher.address output
+ new.sentence format.note output
+ new.sentence format.doi output
+ new.sentence format.urldate output
+ new.sentence format.url output
+ }
+ { "author, and key" output.check }
+ if$
+ }
+ if$
end.bibitem
}
-FUNCTION {phdthesis} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF STYLE
+FUNCTION {thesis}
{
begin.bibitem
- format.authors "author" output.check
- author format.key output
- name.or.dash
- format.date "year" output.check
- date.block
- format.title
- "title" output.check
- new.block
- bbl.phdthesis format.thesis.type output.nonnull
- school "school" bibinfo.warn output
- address "address" bibinfo.check output
- format.doi output
- new.block
- format.note output
- format.eprint output
- format.url output
+ author empty$ not
+ {
+ format.authors output.nonnull
+ name.or.dash
+ format.date "year" output.check
+ new.block format.title output
+ new.sentence format.comment output
+ new.sentence format.thesis.school.type.address output
+ new.sentence format.note output
+ new.sentence format.doi output
+ new.sentence format.urldate output
+ new.sentence format.url output
+ }
+ { %%% if author is empty, proceeds with key
+ key empty$ not
+ {
+ format.title.in.books output
+ name.or.dash
+ format.date "year" output.check
+ new.sentence format.comment output
+ new.sentence format.note output
+ new.sentence format.doi output
+ new.sentence format.urldate output
+ new.sentence format.url output
+ }
+ { "author, and key" output.check }
+ if$
+ }
+ if$
end.bibitem
}
+FUNCTION {mastersthesis} { thesis }
+
+
+
+FUNCTION {phdthesis} { thesis }
+
+
+
FUNCTION {proceedings}
{
begin.bibitem
@@ -3517,20 +3708,73 @@ FUNCTION {techreport} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF ST
-FUNCTION {unpublished} % THIS ENTRY TYPE IS NOT COMPATIBLE WITH IRAN MANUAL OF STYLE
+FUNCTION {format.unpub.title}
+{
+ title empty$ not
+ { title bbl.dquote }
+ 'skip$
+ if$
+}
+
+
+
+FUNCTION {unpublished}
{
begin.bibitem
- format.authors "author" output.check
- author format.key output
- name.or.dash
- format.date "year" output.check
- date.block
- format.title "title" output.check
- format.doi output
- new.block
- format.note "note" output.check
- format.eprint output
- format.url output
+ author empty$ not
+ {
+ format.authors output.nonnull
+ name.or.dash
+ format.date "year" output.check
+ new.block format.unpub.title output
+ new.sentence format.comment output
+ new.sentence format.by output
+ new.sentence format.translatedby output
+ new.sentence format.translateyear output
+ new.sentence format.howpublished output
+ new.sentence format.note output
+ new.sentence format.doi output
+ new.sentence format.urldate output
+ new.sentence format.url output
+ }
+ { %%% if author is empty, proceeds with translator
+ translator empty$ not
+ {
+ format.translators output.nonnull
+ name.or.dash
+ new.sentence format.translateyear output
+ new.block format.unpub.title output
+ new.sentence format.comment output
+ new.sentence format.by output
+ new.sentence format.date output
+ new.sentence format.translatedby output
+ new.sentence format.translateyear output
+ new.sentence format.howpublished output
+ new.sentence format.note output
+ new.sentence format.doi output
+ new.sentence format.urldate output
+ new.sentence format.url output
+ }
+ { %%% if author, and translator are empty, proceeds with key
+ key empty$ not
+ {
+ format.title.in.books output
+ name.or.dash
+ format.date "year" output.check
+ new.sentence format.comment output
+ new.sentence format.by output
+ new.sentence format.howpublished output
+ new.sentence format.note output
+ new.sentence format.doi output
+ new.sentence format.urldate output
+ new.sentence format.url output
+ }
+ { "author, translator, and key" output.check }
+ if$
+ }
+ if$
+ }
+ if$
end.bibitem
}
@@ -3542,6 +3786,21 @@ FUNCTION {default.type} { misc }
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
% Reading bibliography database (.bib) file
READ
@@ -3864,19 +4123,19 @@ FUNCTION {calc.short.authors}
type$ "book" =
'book.creator.label.order
{
- type "incollection" =
+ type$ "incollection" =
'incoll.creator.label.order
{
type$ "proceedings" =
'proc.creator.label.order
{
- type "conference" =
+ type$ "conference" =
'conf.creator.label.order
{
- type "inproceedings" =
+ type$ "inproceedings" =
'inproc.creator.label.order
{
- type "inbook" =
+ type$ "inbook" =
'author.editor.key.label
'author.key.label
if$
@@ -4271,19 +4530,19 @@ FUNCTION {presort}
type$ "book" =
'book.creator.sort.order
{
- type "incollection" =
+ type$ "incollection" =
'incoll.creator.sort.order
{
type$ "proceedings" =
'proc.creator.sort.order
{
- type "conference" =
+ type$ "conference" =
'conf.creator.sort.order
{
- type "inproceedings" =
+ type$ "inproceedings" =
'inproc.creator.sort.order
{
- type "inbook" =
+ type$ "inbook" =
'author.editor.sort
'author.sort
if$
@@ -4379,8 +4638,8 @@ FUNCTION {reverse.pass}
'skip$
{
is.language.persian
- { "{\natexlabfa{" swap$ * "}}" * }
- { "{\natexlaben{" swap$ * "}}" * }
+ { "{\extrayearlabelfa{" swap$ * "}}" * }
+ { "{\extrayearlabelen{" swap$ * "}}" * }
if$
}
if$