%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% BibLIPN %% %% basé sur %% %% BibLSV %% %% Nicolas Markey %% %% %% %% Version 2.42 (12-02-2001) %% %% (première version : 14-10-2000) %% %% %% %% basé sur DMIstable, de R. Di Cosmo. %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% %% %% Toute modification est strictement autorisée à %% %% condition d'être annoncée et documentée à la fin %% %% de ce fichier. %% %% %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ENTRY { address %%\ author %%| booktitle %%| chapter %%| Ces champs sont les champs classiques edition %%| Le style LIPNstable est ainsi 100% editor %%| compatible avec d'autres styles. howpublished %%| institution %%| L'utilisation de fichiers BIB lipn journal %%| avec un autre style marchera sans key %%| probleme, les champs lipn-* seront month %% > ignores. note %%| L'utilisation de fichiers BIB number %%| "classiques" avec lipnstable.bst organization %%| produira des warnings, des labels pages %%| foireux, mais marchera... publisher %%| En definissant lipn-categ-order="", school %%| on peut supprimer le tri par catégorie series %%| et obtenir des "labels" classiques, title %%| ie avec initiales des noms et les deux type %%| derniers chiffres de l'annee. volume %%| isbn %%| year %%/ lipn-time %%> "ant" = anterieur a l'arrivee au labo lipn-status %%> "apar" = a paraitre lipn-category %%> categorie parmi la liste plus bas lipn-category-order %%\ lipn-misc %%| lipn-category-keyprefs %%| Pour l'entree (theoriqt unique) lipn-chronology-order %% > @Config, pour passer des options lipn-year-first %%| a BibTeX. lipn-ant %%| lipn-apar %%| lipn-separator %%| lipn-fake-prefix %%| lipn-categ-label %%| lipn-sort %%| lipn-abbr } %%/ { lipn.item.order } %%> une variable entiere pour chaque entree { label %%\ deux variables de type "chaine", dont lipn.entry.category.prefix }%%/ une classique, celle qui contiendra le label. STRINGS { lipn.categ.order lipn.categ.keyprefs category.prefix.separator lipn.time.order lipn.year.first lipn.apar lipn.ant lipn.misc lipn.fake.prefix lipn.categ.label lipn.sort lipn.abbr %% add CF tmpyear %% fin add CF } FUNCTION { init.default.config } { "livr chap edit jour autj invi auti tuto intc autc thes cour rapl cont real soum misc" 'lipn.categ.order := "{LI} {Ch} {Ed} {RI} {RE} {IN} {In} {TU} {CI} {CO} {TH} {Nc} {Ra} {Rc} {Lo} {So} {Mi}" 'lipn.categ.keyprefs := "-" 'category.prefix.separator := "asc" 'lipn.time.order := "true" 'lipn.year.first := "true" 'lipn.apar := "false" 'lipn.ant := "Miscellanea" 'lipn.misc := "XX" 'lipn.fake.prefix := "true" 'lipn.categ.label := "true" 'lipn.sort := "false" 'lipn.abbr := "" 'tmpyear := } FUNCTION {field.or.null} { duplicate$ empty$ { pop$ "" } 'skip$ if$ } FUNCTION {not} { { #0 } { #1 } if$ } FUNCTION {and} { 'skip$ { pop$ #0 } if$ } FUNCTION {or} { { pop$ #1 } 'skip$ if$ } INTEGERS {set.lipn.misc set.lipn.sep set.lipn.fp} FUNCTION{lipn.style.config} { type$ "config" = { %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % Check for custom category order %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% lipn-category-order missing$ {} {lipn-category-order empty$ {"" 'lipn.categ.order :=} {lipn-category-order " " * lipn.categ.order * 'lipn.categ.order :=} if$} if$ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % Check for custom category key prefixes %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% lipn-category-keyprefs empty$ {lipn-category-keyprefs missing$ {} {"" 'lipn.categ.keyprefs :=} if$} {lipn-category-keyprefs " " * lipn.categ.keyprefs * 'lipn.categ.keyprefs :=} if$ %%%%%%%%%%%%%%%%%%%%%%%%%%%%% % Now check for chronology %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%% lipn-chronology-order field.or.null "l" change.case$ "desc" = lipn-chronology-order field.or.null "-1" = + {"desc" 'lipn.time.order :=} {} if$ %%%%%%%%%%%%%%%%%%%%%%%%%%% % And now for year-first %% %%%%%%%%%%%%%%%%%%%%%%%%%%% lipn-year-first missing$ {} {lipn-year-first field.or.null "l" change.case$ "true" = {} {"" 'lipn.year.first :=} if$} if$ %%%%%%%%%%%%%%%%%% % Check lipn-ant %% %%%%%%%%%%%%%%%%%% lipn-ant missing$ {} {lipn-ant field.or.null "l" change.case$ 'lipn.ant :=} if$ %%%%%%%%%%%%%%%%%%%%%%%%%%%% % Configure lipn-separator %% %%%%%%%%%%%%%%%%%%%%%%%%%%%% lipn-separator missing$ {} {lipn-separator 'category.prefix.separator := #1 'set.lipn.sep :=} if$ %%%%%%%%%%%%%%%%%%%%%% % And lipn-misc, too %% %%%%%%%%%%%%%%%%%%%%%% lipn-misc missing$ {} {lipn-misc 'lipn.misc := #1 'set.lipn.misc :=} if$ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % Don't forget lipn-fake-prefix %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% lipn-fake-prefix missing$ {} {lipn-fake-prefix 'lipn.fake.prefix := #1 'set.lipn.fp :=} if$ %%%%%%%%%%%%%%%%%%%%%%%% % lipn-apar, of course %% %%%%%%%%%%%%%%%%%%%%%%%% lipn-apar missing$ {} {lipn-apar "l" change.case$ 'lipn.apar :=} if$ %%%%%%%%%%%%%%%%%%%%%%%%%% % Check lipn-categ-label %% %%%%%%%%%%%%%%%%%%%%%%%%%% lipn-categ-label missing$ {} {lipn-categ-label "l" change.case$ 'lipn.categ.label :=} if$ %%%%%%%%%%%%%%%%%%%%%%%% %% Shall I lipn-sort ? %% %%%%%%%%%%%%%%%%%%%%%%%% lipn-sort missing$ {} {lipn-sort "l" change.case$ 'lipn.sort :=} if$ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Shall I abbreviate first names ? %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% lipn-abbr missing$ {} {lipn-abbr "l" change.case$ 'lipn.abbr :=} if$ } {} if$ } FUNCTION {lipn.style.summary} { "" top$ "Summary of the configuration : " top$ "livr chap edit jour autj invi auti tuto intc autc thes cour rapl cont real soum" lipn.categ.order = {" - Using classical category-order "} {" - Using your own category-order " "" lipn.categ.order = {"(in fact, no categories)" *} {} if$ } if$ top$ "" lipn.categ.order = {} {"{LI} {Ch} {Ed} {RI} {RE} {IN} {CT} {CI} {CO} {TH} {Nc} {Ra} {Rc} {Lo} {So}" lipn.categ.keyprefs = {" - Using classical category-prefix "} {" - Using your customized category-prefix "} if$ top$} if$ lipn.abbr "true" = {" - First names will be abbreviated" top$} {} if$ lipn.sort "true" = {" - I will sort entries " "year" lipn.year.first = "true" lipn.year.first = or {"w.r.t. year first, " ", then to author(s)" #1} {"w.r.t. author(s) first, then to year " #0} if$ "desc" lipn.time.order = {"in reverse order"} {"in ascending order"} if$ swap$ {swap$ * *} {*} if$ * top$ "" lipn.categ.order = {} {" (inside each category)" top$} if$} {"" lipn.categ.order = {" - I don't sort entries. They will appear in the order you \cite them." top$} {" - Entries are sorted into categories, but not sorted inside each category." top$} if$} if$ "false" lipn.ant = {" - Entries marked « ant » won't appear in the list." #0} {" - « ant »-entries will be listed." #1} if$ swap$ top$ "true" lipn.apar = { {" - Ditto for « apar »-entries"} {" - But « apar »-entries will"} if$} {"end" lipn.apar = { {" - « apar »-entries too, but at the end of each category."} {" - « apar »-entries will, but at the end of each category."} if$} { {" - But « apar »-entries won't."} {" - Ditto for « apar »-entries"} if$} if$ } if$ top$ set.lipn.sep {category.prefix.separator empty$ {" - I'll use no separator in labels." top$} {" - I'll use " category.prefix.separator * " as separator in labels" * top$} if$} {} if$ set.lipn.misc {" - " lipn.misc * " is the name of the MISC category." * top$} {} if$ set.lipn.fp {" - " lipn.fake.prefix * " is the prefix when I don't know which one to use." top$} {} if$ "" top$ } MACRO {jan} {"\janname\ "} MACRO {feb} {"\febname\ "} MACRO {mar} {"\marname\ "} MACRO {apr} {"\aprname\ "} MACRO {may} {"\mayname\ "} MACRO {jun} {"\junname\ "} MACRO {jul} {"\julname\ "} MACRO {aug} {"\augname\ "} MACRO {sep} {"\sepname\ "} MACRO {oct} {"\octname\ "} MACRO {nov} {"\novname\ "} MACRO {dec} {"\decname\ "} MACRO {spring} {"\springname\ "} MACRO {summer} {"\summername\ "} MACRO {fall} {"\fallname\ "} MACRO {winter} {"\wintername\ "} INTEGERS { lipn.ordinal lipn.max.category.length } FUNCTION { lipn.category.index } { lipn.categ.order text.length$ 'lipn.max.category.length := #1 'lipn.ordinal := {lipn.ordinal lipn.max.category.length > {#0} {#1} if$} {duplicate$ lipn.categ.order lipn.ordinal #4 substring$ = {lipn.ordinal #1 - 'lipn.max.category.length :=} {lipn.ordinal #5 + 'lipn.ordinal := } if$} while$ lipn.ordinal swap$ pop$ } FUNCTION { lipn.category.ordinal } { duplicate$ lipn.category.index #1000 + int.to.str$ swap$ * } FUNCTION {category.code} { lipn-category field.or.null #4 text.prefix$ duplicate$ text.length$ #0 > { lipn.category.ordinal } {type$ "config" = {} {"Missing mandatory value for field lipn-CATEGORY " "(I'll treat it as MISC) in entry " * cite$ * warning$ pop$ "misc" lipn.category.ordinal } if$} if$ } FUNCTION {category.prefix} { lipn-category field.or.null #4 text.prefix$ duplicate$ text.length$ #0 > {lipn.category.index lipn.categ.keyprefs swap$ #4 substring$ } {type$ "config" = {} {% missing Category: use a fake prefix lipn.fake.prefix "Missing mandatory value for field lipn-CATEGORY" "(I'll treat it as MISC) in entry " * cite$ * warning$ pop$ lipn.fake.prefix } if$} if$ }FUNCTION {sortify} { purify$ "l" change.case$ } STRINGS{ s } INTEGERS { len } FUNCTION {chop.word} { 's := 'len := s #1 len substring$ = { s len #1 + global.max$ substring$ } 's if$ } INTEGERS { nameptr namesleft numnames } STRINGS{ t } FUNCTION {sort.format.names} { 's := #1 'nameptr := "" s num.names$ 'numnames := numnames 'namesleft := { namesleft #0 > } {nameptr #1 > {" " * } 'skip$ if$ s nameptr "{vv{ } }{ll{ }}{ ff{ }}{ jj{ }}" format.name$ 't := nameptr numnames = t "others" = and {"et al" * } {t sortify * } if$ nameptr #1 + 'nameptr := namesleft #1 - 'namesleft :=} while$ } FUNCTION {sort.format.title} { 't := "A " #2 "An " #3 "The " #4 t chop.word chop.word chop.word sortify } FUNCTION {author.sort} { author empty$ {key empty$ { "to sort, need author or key in " cite$ * warning$ ""} { key sortify } if$} {author sort.format.names } if$ } FUNCTION {author.editor.sort} { author empty$ {editor empty$ {key empty$ {"to sort, need author, editor, or key in " cite$ * warning$ ""} {key sortify } if$} {editor sort.format.names } if$} {author sort.format.names } if$ } FUNCTION {author.organization.sort} { author empty$ {organization empty$ {key empty$ {"to sort, need author, organization, or key in " cite$ * warning$ ""} {key sortify } if$} {"The " #4 organization chop.word sortify } if$} {author sort.format.names } if$ } FUNCTION {editor.organization.sort} { editor empty$ {organization empty$ {key empty$ { "to sort, need editor, organization, or key in " cite$ * warning$ ""} {key sortify } if$} {"The " #4 organization chop.word sortify } if$} {editor sort.format.names } if$ } INTEGERS { stlgt count } FUNCTION {presort} { lipn.categ.order "" = not {category.code} {""} if$ lipn.sort "true" = {type$ "book" = type$ "inbook" = or 'author.editor.sort {type$ "proceedings" = 'editor.organization.sort {type$ "manual" = 'author.organization.sort {type$ "config" = {""} 'author.sort if$} if$} if$} if$ year field.or.null purify$ #-1 #4 substring$ lipn.time.order #4 text.prefix$ "desc" = {duplicate$ text.length$ 'stlgt := stlgt #1 + 'count := {count #1 - 'count := count} {duplicate$ stlgt #1 + count - #1 substring$ swap$ } while$ pop$ "" stlgt #1 + 'count := {count #1 - 'count := count} {swap$ chr.to.int$ "9" chr.to.int$ swap$ - "0" chr.to.int$ + int.to.chr$ swap$ * } while$} {} if$ lipn.year.first "true" = {swap$} {} if$ * lipn.apar "end" = {lipn-status field.or.null sortify " " * swap$} {""} if$ * * " " * title field.or.null sort.format.title *} {} if$ 'sort.key$ := } STRINGS { longest.label } INTEGERS { number.label longest.label.width } FUNCTION {initialize.longest.label} { "" 'longest.label := #1 'number.label := #0 'longest.label.width := } FUNCTION {format.lab.names} { 's := s num.names$ 'numnames := numnames #1 > {numnames #3 > {#2 'namesleft := } {numnames 'namesleft := } if$ #1 'nameptr := "" {namesleft #0 > } {nameptr numnames = {s nameptr "{ff }{vv }{ll}{ jj}" format.name$ "others" = {"{\etalchar{+}}" * } { s nameptr "{v{}}{l{}}" format.name$ * } if$} {s nameptr "{v{}}{l{}}" format.name$ * } if$ nameptr #1 + 'nameptr := namesleft #1 - 'namesleft :=} while$ numnames #3 > {"{\etalchar{+}}" * } 'skip$ if$} {s #1 "{v{}}{l{}}" format.name$ duplicate$ text.length$ #2 < {pop$ s #1 "{ll}" format.name$ #3 text.prefix$ } 'skip$ if$} if$ } FUNCTION {author.key.label} { author empty$ {key empty$ {cite$ #3 text.prefix$ } {key #3 text.prefix$ } if$} {author format.lab.names } if$ } FUNCTION {author.editor.key.label} { author empty$ {editor empty$ {key empty$ {cite$ #3 text.prefix$ } {key #3 text.prefix$ } if$} {editor format.lab.names } if$} {author format.lab.names } if$ } FUNCTION {author.key.organization.label} { author empty$ {key empty$ {organization empty$ {cite$ #3 text.prefix$ } {"The " #4 organization chop.word #3 text.prefix$ } if$} {key #3 text.prefix$ } if$} {author format.lab.names } if$ } FUNCTION {editor.key.organization.label} { editor empty$ {key empty$ {organization empty$ {cite$ #3 text.prefix$ } {"The " #4 organization chop.word #3 text.prefix$ } if$} {key #3 text.prefix$ } if$} {editor format.lab.names } if$ } FUNCTION {calc.label} { type$ "book" = type$ "inbook" = or 'author.editor.key.label {type$ "proceedings" = 'editor.key.organization.label {type$ "manual" = 'author.key.organization.label 'author.key.label if$} if$} if$ category.prefix.separator * year field.or.null purify$ #-1 #2 substring$ * 'label := } STRINGS { last.category.value } FUNCTION {longest.label.pass} { "" lipn.categ.order = not "true" lipn.categ.label = and {category.prefix 'lipn.entry.category.prefix := last.category.value lipn-category field.or.null #4 text.prefix$ = {lipn.entry.category.prefix category.prefix.separator * number.label int.to.str$ * 'label := } {lipn.entry.category.prefix category.prefix.separator * "1" * 'label := lipn-category field.or.null #4 text.prefix$ 'last.category.value := #1 'number.label :=} if$} {calc.label} if$ number.label #1 + 'number.label := label width$ longest.label.width > {label 'longest.label := label width$ 'longest.label.width :=} 'skip$ if$ } FUNCTION {longest.label.pass.if.needed} { lipn.ant "true" = {lipn.apar "true" = lipn.apar "end" = or {longest.label.pass} {lipn-status field.or.null #4 text.prefix$ #-1 #3 substring$ "par" = 'skip$ {longest.label.pass} if$} if$} {lipn-time field.or.null #3 text.prefix$ "ant" = 'skip$ {lipn.apar "true" = lipn.apar "end" = or {longest.label.pass} {lipn-status field.or.null #4 text.prefix$ #-1 #3 substring$ "par" = 'skip$ {longest.label.pass} if$} if$} if$} if$ } FUNCTION { init.reverse.pass } { "" 'last.category.value := #1 'number.label := } FUNCTION { reverse.pass } { lipn.time.order #4 text.prefix$ "desc" = "" lipn.categ.order = not "true" lipn.categ.label = and and {last.category.value lipn-category field.or.null #4 text.prefix$ = {#1 number.label + 'number.label := lipn.entry.category.prefix category.prefix.separator * number.label int.to.str$ * 'label := } {lipn-category field.or.null #4 text.prefix$ 'last.category.value := #1 'number.label := lipn.entry.category.prefix category.prefix.separator * number.label int.to.str$ * 'label := } if$} {} if$ } FUNCTION{ reverse.pass.if.needed } { lipn.ant "true" = {lipn.apar "true" = lipn.apar "end" = or {reverse.pass} {lipn-status field.or.null #4 text.prefix$ #-1 #3 substring$ "par" = 'skip$ {reverse.pass} if$} if$} {lipn-time field.or.null #3 text.prefix$ "ant" = 'skip$ {lipn.apar "true" = lipn.apar "end" = or {reverse.pass} {lipn-status field.or.null #4 text.prefix$ #-1 #3 substring$ "par" = 'skip$ {reverse.pass} if$} if$} if$} if$ } INTEGERS { output.state before.all mid.sentence after.sentence after.block } FUNCTION {init.state.consts} { #0 'before.all := #1 'mid.sentence := #2 'after.sentence := #3 'after.block := "-1" 'last.category.value := } FUNCTION {format.names} { 's := #1 'nameptr := s num.names$ 'numnames := numnames 'namesleft := {namesleft #0 > } {s nameptr lipn.abbr "true" = {"{f.~}{vv~}{ll}{, jj}"} {"{ff~}{vv~}{ll}{, jj}"} if$ format.name$ 't := nameptr #1 > {namesleft #1 > {", " * t * } {%numnames #2 > %{"," * } %'skip$ %if$ t "others" = {" et~al." * } {" \andname\ " * t * } if$} if$} 't if$ nameptr #1 + 'nameptr := namesleft #1 - 'namesleft :=} while$ } FUNCTION {format.authors} { author empty$ {"" } {author format.names } if$ } FUNCTION {format.editors} { editor empty$ {"" } {editor format.names editor num.names$ #1 > {", \editornames" * } {", \editorname" * } if$} if$ } FUNCTION {emphasize} { duplicate$ empty$ {pop$ "" } {"{\emph{" swap$ * "}}" * } if$ } FUNCTION {format.title} { title empty$ {"" } {title "t" change.case$ } if$ } FUNCTION {format.btitle} { title emphasize } FUNCTION {format.date} { year empty$ {month empty$ {"" } {"there's a month but no year in " cite$ * warning$ month} if$} {month empty$ 'year {month " " * year * } if$} if$ } FUNCTION {tie.or.space.connect} { duplicate$ text.length$ #3 < {"~" } {"\ " } if$ swap$ * * } FUNCTION {either.or.check} { empty$ 'pop$ {"can't use both " swap$ * " fields in " * cite$ * warning$ } if$ } FUNCTION {format.bvolume} { volume empty$ {"" } {"volume" volume tie.or.space.connect series empty$ 'skip$ {" \ofname\ " * series emphasize * } if$ "volume and number" number either.or.check} if$ } FUNCTION {format.number.series} { volume empty$ {number empty$ {series field.or.null } {output.state mid.sentence = {"\numbername\ " } {"\Numbername\ " } if$ number tie.or.space.connect series empty$ {"there's a number but no series in " cite$ * warning$ } {" \inname\ " * series * } if$} if$} {"" } if$ } FUNCTION {format.edition} { edition empty$ {"" } {output.state mid.sentence = {edition "l" change.case$ " \editionname" * } {edition "t" change.case$ " \editionname" * } if$} if$ } FUNCTION {format.tr.number} { type empty$ {"\technicalreportname" } 'type if$ number empty$ {"t" change.case$ } {number tie.or.space.connect } if$ } FUNCTION {n.dashify} { 't := "" {t empty$ not } {t #1 #1 substring$ "-" = {t #1 #2 substring$ "--" = not {"--" * t #2 global.max$ substring$ 't :=} {{t #1 #1 substring$ "-" = } { "-" * t #2 global.max$ substring$ 't := } while$} if$} {t #1 #1 substring$ * t #2 global.max$ substring$ 't :=} if$} while$ } INTEGERS { multiresult } FUNCTION {multi.page.check} { 't := #0 'multiresult := {multiresult not t empty$ not and} {t #1 #1 substring$ duplicate$ "-" = swap$ duplicate$ "," = swap$ "+" = or or { #1 'multiresult := } { t #2 global.max$ substring$ 't := } if$} while$ multiresult } FUNCTION {format.isbn} { isbn empty$ {"" } {"ISBN " isbn *} if$ } FUNCTION {format.pages} { pages empty$ {"" } {pages multi.page.check {"\pagesname\ " pages n.dashify tie.or.space.connect } {"\pagename\ " pages tie.or.space.connect } if$} if$ } FUNCTION {format.vol.num.pages} { volume field.or.null number empty$ 'skip$ {"(" number * ")" * * volume empty$ {"there's a number but no volume in " cite$ * warning$ } 'skip$ if$} if$ pages empty$ 'skip$ {duplicate$ empty$ {pop$ format.pages } {":" * pages n.dashify * } if$} if$ } FUNCTION {format.chapter.pages} { chapter empty$ 'format.pages {type empty$ {"\chaptername\ " } {type "l" change.case$ } if$ chapter tie.or.space.connect pages empty$ 'skip$ {", " * format.pages * } if$} if$ } FUNCTION {format.thesis.type} { type empty$ 'skip$ {pop$ type "t" change.case$} if$ } FUNCTION {empty.misc.check} { author empty$ title empty$ howpublished empty$ month empty$ year empty$ note empty$ and and and and and key empty$ not and {"all relevant fields are empty in " cite$ * warning$ } 'skip$ if$ } FUNCTION {format.in.ed.booktitle} { booktitle empty$ {"" } {editor empty$ {"\inname\ " booktitle emphasize * } {"\inname\ " format.editors * ", " * booktitle emphasize * } if$} if$ } FUNCTION {format.crossref.editor} { editor #1 "{vv~}{ll}" format.name$ editor num.names$ duplicate$ #2 > {pop$ " et~al." * } {#2 < 'skip$ {editor #2 "{ff }{vv }{ll}{ jj}" format.name$ "others" = {" et~al." * } {" \andname\ " * editor #2 "{vv~}{ll}" format.name$ * } if$} if$} if$ } FUNCTION {format.article.crossref} { key empty$ {journal empty$ {"need key or journal for " cite$ * " to crossref " * crossref * warning$ ""} {"\Inname\ {\emph{" journal * "}}" * } if$} {"\Inname\ " key * } if$ " \cite{" * crossref * "}" * } FUNCTION {format.book.crossref} { volume empty$ {"empty volume in " cite$ * "'s crossref of " * crossref * warning$ "\Inname\ "} {"Volume" volume tie.or.space.connect " \ofname\ " * } if$ editor empty$ editor field.or.null author field.or.null = or {key empty$ {series empty$ {"need editor, key, or series for " cite$ * " to crossref " * crossref * warning$ "" *} {"{\em " * series * "\/}" * } if$} { key * } if$} { format.crossref.editor * } if$ " \cite{" * crossref * "}" * } FUNCTION {format.incoll.inproc.crossref} { editor empty$ editor field.or.null author field.or.null = or {key empty$ {booktitle empty$ {"need editor, key, or booktitle for " cite$ * " to crossref " * crossref * warning$ ""} {"\Inname\ {\em " booktitle * "\/}" * } if$} {"\Inname\ " key * } if$} {"\Inname\ " format.crossref.editor * } if$ " \cite{" * crossref * "}" * } FUNCTION {status.code} { lipn-status field.or.null #4 text.prefix$ #-1 #3 substring$ duplicate$ text.length$ #0 > {duplicate$ "par" = {} {pop$ "" "Unknown value (" lipn-status * ") for field lipn-STATUS in entry " * cite$ * warning$} if$} {pop$ ""} if$ lipn-time field.or.null #3 text.prefix$ duplicate$ text.length$ #0 > {duplicate$ "ant" = {*} {pop$ "Unknown value (" lipn-time * ") for field lipn-TIME in entry" * cite$ * warning$} if$} {pop$} if$ } FUNCTION {output.nonnull} { 's := output.state mid.sentence = {", " * write$ } {output.state after.block = {add.period$ write$ newline$ "\newblock " write$} {output.state before.all = 'write$ {add.period$ " " * write$ } if$} if$ mid.sentence 'output.state :=} if$ s } FUNCTION {output} { duplicate$ empty$ 'pop$ 'output.nonnull if$ } FUNCTION {output.check} { 't := duplicate$ empty$ {pop$ "empty " t * " \inname\ " * cite$ * warning$ } 'output.nonnull if$ } FUNCTION {output.bibitem} { newline$ last.category.value lipn-category field.or.null #4 text.prefix$ = {} {lipn-category field.or.null #4 text.prefix$ duplicate$ "" = {pop$ "misc"} {} if$ lipn.categ.order "" = {pop$} {"\BibHeadline" swap$ * write$ newline$} if$} if$ lipn-category field.or.null #4 text.prefix$ 'last.category.value := status.code "\" swap$ * write$ "lipnbibitem{" write$ label write$ "}{" write$ cite$ write$ "}{" write$ newline$ "" %% Ajout LP date en début de ligne 01/10/2007 year empty$ {} { year tmpyear = {} {year 'tmpyear := "\bibyear{" write$ year write$ "}" write$} if$ } if$ %% Fin Ajout LP date en début de ligne 01/10/2007 before.all 'output.state := } FUNCTION {fin.entry} { add.period$ write$ "{\lipnref{[" cite$ "]}}}" * * write$ newline$ } FUNCTION {new.block} { output.state before.all = 'skip$ {after.block 'output.state := } if$ } FUNCTION {new.sentence} { output.state after.block = 'skip$ {output.state before.all = 'skip$ {after.sentence 'output.state := } if$} if$ } FUNCTION {new.block.checka} { empty$ 'skip$ 'new.block if$ } FUNCTION {new.block.checkb} { empty$ swap$ empty$ and 'skip$ 'new.block if$ } FUNCTION {new.sentence.checka} { empty$ 'skip$ 'new.sentence if$ } FUNCTION {new.sentence.checkb} { empty$ swap$ empty$ and 'skip$ 'new.sentence if$ } FUNCTION {article} { output.bibitem format.authors "author" output.check new.block format.title "title" output.check new.block crossref missing$ {journal emphasize "journal" output.check format.vol.num.pages output format.date "year" output.check} {format.article.crossref output.nonnull format.pages output} if$ new.block note output fin.entry } FUNCTION {book} { output.bibitem author empty$ {format.editors "author and editor" output.check } {format.authors output.nonnull crossref missing$ {"author and editor" editor either.or.check } 'skip$ if$} if$ new.block format.btitle "title" output.check crossref missing$ {format.bvolume output new.block format.number.series output new.sentence publisher "publisher" output.check address output} {new.block format.book.crossref output.nonnull} if$ format.edition output format.date "year" output.check format.isbn output new.block note output fin.entry } FUNCTION {booklet} { output.bibitem format.authors output new.block format.title "title" output.check howpublished address new.block.checkb howpublished output address output format.date output new.block note output fin.entry } FUNCTION {inbook} { output.bibitem author empty$ {format.editors "author and editor" output.check } {format.authors output.nonnull crossref missing$ {"author and editor" editor either.or.check } 'skip$ if$} if$ new.block format.btitle "title" output.check crossref missing$ {format.in.ed.booktitle "booktitle" output.check format.bvolume output format.chapter.pages "chapter and pages" output.check new.block format.number.series output new.sentence publisher "publisher" output.check address output} {format.chapter.pages "chapter and pages" output.check new.block format.book.crossref output.nonnull} if$ format.edition output format.date "year" output.check format.isbn output new.block note output fin.entry } FUNCTION {incollection} { output.bibitem format.authors "author" output.check new.block format.title "title" output.check new.block crossref missing$ {format.in.ed.booktitle "booktitle" output.check format.bvolume output format.number.series output format.chapter.pages output new.sentence publisher "publisher" output.check address output format.edition output format.date "year" output.check} {format.incoll.inproc.crossref output.nonnull format.chapter.pages output} if$ new.block note output fin.entry } FUNCTION {inproceedings} { output.bibitem format.authors "author" output.check new.block format.title "title" output.check new.block crossref missing$ {format.in.ed.booktitle "booktitle" output.check format.bvolume output format.number.series output format.pages output address empty$ {organization publisher new.sentence.checkb organization output publisher output format.date "year" output.check} {address output.nonnull format.date "year" output.check new.sentence organization output publisher output} if$} {format.incoll.inproc.crossref output.nonnull format.pages output} if$ new.block note output fin.entry } FUNCTION {conference} { inproceedings } FUNCTION {manual} { output.bibitem author empty$ {organization empty$ 'skip$ {organization output.nonnull address output} if$} {format.authors output.nonnull } if$ new.block format.btitle "title" output.check author empty$ {organization empty$ {address new.block.checka address output} 'skip$ if$} {organization address new.block.checkb organization output address output} if$ format.edition output format.date output new.block note output fin.entry } FUNCTION {mastersthesis} { output.bibitem format.authors "author" output.check new.block format.btitle "title" output.check new.block "Master's thesis" format.thesis.type output.nonnull school "school" output.check address output format.date "year" output.check new.block note output fin.entry } FUNCTION {misc} { output.bibitem format.authors output title howpublished new.block.checkb format.title output howpublished new.block.checka howpublished output format.date output new.block note output fin.entry empty.misc.check } FUNCTION {phdthesis} { output.bibitem format.authors "author" output.check new.block format.title "title" output.check new.block "PhD thesis" format.thesis.type output.nonnull school "school" output.check address output format.date "year" output.check new.block note output fin.entry } FUNCTION {proceedings} { output.bibitem editor empty$ {organization output } {format.editors output.nonnull } if$ new.block format.btitle "title" output.check format.bvolume output format.number.series output address empty$ {editor empty$ {publisher new.sentence.checka } {organization publisher new.sentence.checkb organization output} if$ publisher output format.date "year" output.check} {address output.nonnull format.date "year" output.check new.sentence editor empty$ 'skip$ {organization output } if$ publisher output} if$ format.isbn output new.block note output fin.entry } FUNCTION {techreport} { output.bibitem format.authors "author" output.check new.block format.title "title" output.check new.block format.tr.number output.nonnull institution "institution" output.check address output format.date "year" output.check new.block note output fin.entry } FUNCTION {unpublished} { output.bibitem format.authors "author" output.check new.block format.title "title" output.check new.block note "note" output.check format.date output fin.entry } FUNCTION {default.type} { misc } FUNCTION {config} { lipn.style.summary } FUNCTION {begin.bib} { "\providecommand{\BibHeadlinemisc}{\pagebreak[2]\begin{center}" "{\bf " * lipn.misc * "}" * "\end{center}\nopagebreak[4]}" * write$ newline$ "\input{biblio/lipn.alpha.default}" write$ newline$ "\input{biblio/lipn.default.headlines}" write$ newline$ "\newcommand{\bibyear}[1]" write$ newline$ "{\hspace{-4cm}{\parbox[t]{2cm}{\bf\raggedleft #1}\hspace{2cm}}}" write$ newline$ preamble$ empty$ 'skip$ {preamble$ write$ newline$ } if$ "\begin{lipnbibliography}[" longest.label * "*]{\bibname}{\thelipnlevel}" * write$ newline$ %%"\begin{thebibliography}{" longest.label * "\lipnaparsymb}" * write$ newline$ "\item[]" write$ newline$ } FUNCTION {call.type.if.needed} { lipn.ant "true" = {lipn.apar "true" = lipn.apar "end" = or {call.type$} {lipn-status field.or.null #4 text.prefix$ #-1 #3 substring$ "par" = {skip$} {call.type$} if$} if$} {lipn-time field.or.null #3 text.prefix$ "ant" = 'skip$ {lipn.apar "true" = lipn.apar "end" = or {call.type$} {lipn-status field.or.null #4 text.prefix$ #-1 #3 substring$ "par" = {skip$} {call.type$} if$} if$} if$} if$ } FUNCTION {end.bib} { newline$ "\end{lipnbibliography}" write$ newline$ } %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%% La procedure principale %%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% READ EXECUTE { init.default.config } ITERATE { lipn.style.config } ITERATE { presort } SORT EXECUTE { initialize.longest.label } ITERATE { longest.label.pass.if.needed } EXECUTE { init.reverse.pass } REVERSE { reverse.pass.if.needed } EXECUTE { begin.bib } EXECUTE { init.state.consts } ITERATE { call.type.if.needed } EXECUTE { end.bib } %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% %% Modifications : %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% %% Version 1.00 : o passage de DMIstable a LSVstable. %% (N. Markey) o ajout fonction dmi.to.lsv %% o ajout categorie auti %% o inclusion de PATCH.bib %% %% Version 1.01 : o les publis "apar" sont a la fin de %% (N. Markey) leur categorie. %% %% Version 1.02 : o ajout des variables *ant, *apar et %% (N. Markey) *aparant, pour que le nom de la categ. %% ne soit pas ecrit si la categorie est %% vide (si on ne met pas les publis a %% paraitre/anterieures a l'arrivee au LSV) %% %% Version 1.02a : o version a : on garde toutes les entrees, %% (N. Markey) meme si lsv-time = "ant". %% %% Version 1.03a : o correction bug categ.keyprefs %% (N. Markey) %% %% Version 1.04a : o correction ordre : year-author par %% (N. Markey) defaut. %% %% Version 2.00 : o gestion des "ant" et "apar" par un %% (N. Markey) fichier config.bib %% o nettoyage complet %% %% Version 2.10 : o nouvelles options (categ-label, sort) %% (N. Markey) o bug dans le tri "descendant" %% %% Version 2.20 : o label "inverses" dans le cas d'un tri %% (N. Markey) descendant (reverse.pass) %% %% Version 2.30 : o option lsv-abbr pour abreger les prenoms. %% (N. Markey) %% %% Version 2.40 : o lsvstable fait aussi le boulot de %% (N. Markey) lsvstablelist grace a la commande %% \lsvref (qui ne fait rien par defaut, %% mais qui peut recopier son argument.) %% %% Version 2.41 : o ajout de la categorie "soum" pour les %% (N. Markey) travaux en cours de soumission. %% %% Version 2.42 : o bugfix de la modif precedente. %% (N. Markey) %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% %% Version 3.00 : o adaptation au LIPN %% (L. Petrucci) o ajout du champ isbn %% %% Version 3.10 : o utilisation du package frbib.sty permettant %% (L. Petrucci) d'avoir une biblio correcte en français %% o suppression de la virgule avant le et dans %% une liste %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%