Guest User

mla-good.bst--by Reed CIS

a guest
Nov 30th, 2012
162
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Latex 31.84 KB | None | 0 0
  1. %%
  2. %% This is file `mla-new.bst',
  3. %% generated with the docstrip utility.
  4. %%
  5. %% The original source files were:
  6. %%
  7. %% merlin.mbs  (with options: `ay,nat,nm-revf,jnrlst,nmdash,nmd-3,keyxyr,tit-qq,bt-qq,atit-u,vnum-cm,volp-sp,jdt-vs,pp-last,num-xser,jnm-x,bkpg-x,add-pub,pub-date,pub-xpar,edby,edbyx,in-x,ppx,ed,abr,ednx,xedn,url,url-nl,nfss,')
  8. %% ----------------------------------------
  9. %% *** a new and more accurate mla style ***
  10. %%
  11. %% Copyright 1994-2004 Patrick W Daly
  12.  % ===============================================================
  13.  % IMPORTANT NOTICE:
  14.  % This bibliographic style (bst) file has been generated from one or
  15.  % more master bibliographic style (mbs) files, listed above.
  16.  %
  17.  % This generated file can be redistributed and/or modified under the terms
  18.  % of the LaTeX Project Public License Distributed from CTAN
  19.  % archives in directory macros/latex/base/lppl.txt; either
  20.  % version 1 of the License, or any later version.
  21.  % ===============================================================
  22.  % Name and version information of the main mbs file:
  23.  % \ProvidesFile{merlin.mbs}[2004/02/09 4.13 (PWD, AO, DPC)]
  24.  %   For use with BibTeX version 0.99a or later
  25.  %-------------------------------------------------------------------
  26.  % This bibliography style file is intended for texts in ENGLISH
  27.  % This is an author-year citation style bibliography. As such, it is
  28.  % non-standard LaTeX, and requires a special package file to function properly.
  29.  % Such a package is    natbib.sty   by Patrick W. Daly
  30.  % The form of the \bibitem entries is
  31.  %   \bibitem[Jones et al.(1990)]{key}...
  32.  %   \bibitem[Jones et al.(1990)Jones, Baker, and Smith]{key}...
  33.  % The essential feature is that the label (the part in brackets) consists
  34.  % of the author names, as they should appear in the citation, with the year
  35.  % in parentheses following. There must be no space before the opening
  36.  % parenthesis!
  37.  % With natbib v5.3, a full list of authors may also follow the year.
  38.  % In natbib.sty, it is possible to define the type of enclosures that is
  39.  % really wanted (brackets or parentheses), but in either case, there must
  40.  % be parentheses in the label.
  41.  % The \cite command functions as follows:
  42.  %   \citet{key} ==>>                Jones et al. (1990)
  43.  %   \citet*{key} ==>>               Jones, Baker, and Smith (1990)
  44.  %   \citep{key} ==>>                (Jones et al., 1990)
  45.  %   \citep*{key} ==>>               (Jones, Baker, and Smith, 1990)
  46.  %   \citep[chap. 2]{key} ==>>       (Jones et al., 1990, chap. 2)
  47.  %   \citep[e.g.][]{key} ==>>        (e.g. Jones et al., 1990)
  48.  %   \citep[e.g.][p. 32]{key} ==>>   (e.g. Jones et al., p. 32)
  49.  %   \citeauthor{key} ==>>           Jones et al.
  50.  %   \citeauthor*{key} ==>>          Jones, Baker, and Smith
  51.  %   \citeyear{key} ==>>             1990
  52.  %---------------------------------------------------------------------
  53.  
  54. ENTRY
  55.   { address
  56.    author
  57.    booktitle
  58.    chapter
  59.    edition
  60.    editor
  61.    eid
  62.    howpublished
  63.    institution
  64.    journal
  65.    key
  66.    month
  67.    note
  68.    number
  69.    organization
  70.    pages
  71.    publisher
  72.    school
  73.    series
  74.    title
  75.    type
  76.    url
  77.    volume
  78.    year
  79.  }
  80.  {}
  81.  { label extra.label sort.label short.list }
  82. INTEGERS { output.state before.all mid.sentence after.sentence after.block }
  83. FUNCTION {init.state.consts}
  84. { #0 'before.all :=
  85.  #1 'mid.sentence :=
  86.  #2 'after.sentence :=
  87.  #3 'after.block :=
  88. }
  89. STRINGS { s t}
  90. FUNCTION {output.nonnull}
  91. { 's :=
  92.  output.state mid.sentence =
  93.    { ", " * write$ }
  94.    { output.state after.block =
  95.        { add.period$ write$
  96.          newline$
  97.          "\newblock " write$
  98.        }
  99.        { output.state before.all =
  100.            'write$
  101.            { add.period$ " " * write$ }
  102.          if$
  103.        }
  104.      if$
  105.      mid.sentence 'output.state :=
  106.    }
  107.  if$
  108.  s
  109. }
  110. FUNCTION {output}
  111. { duplicate$ empty$
  112.    'pop$
  113.    'output.nonnull
  114.  if$
  115. }
  116. FUNCTION {output.check}
  117. { 't :=
  118.  duplicate$ empty$
  119.    { pop$ "empty " t * " in " * cite$ * warning$ }
  120.    'output.nonnull
  121.  if$
  122. }
  123. FUNCTION {fin.entry}
  124. { add.period$
  125.  write$
  126.  newline$
  127. }
  128.  
  129. FUNCTION {new.block}
  130. { output.state before.all =
  131.    'skip$
  132.    { after.block 'output.state := }
  133.  if$
  134. }
  135. FUNCTION {new.sentence}
  136. { output.state after.block =
  137.    'skip$
  138.    { output.state before.all =
  139.        'skip$
  140.        { after.sentence 'output.state := }
  141.      if$
  142.    }
  143.  if$
  144. }
  145. FUNCTION {add.blank}
  146. {  " " * before.all 'output.state :=
  147. }
  148.  
  149. FUNCTION {date.block}
  150. {
  151.  new.block
  152. }
  153.  
  154. FUNCTION {not}
  155. {   { #0 }
  156.    { #1 }
  157.  if$
  158. }
  159. FUNCTION {and}
  160. {   'skip$
  161.    { pop$ #0 }
  162.  if$
  163. }
  164. FUNCTION {or}
  165. {   { pop$ #1 }
  166.    'skip$
  167.  if$
  168. }
  169. FUNCTION {non.stop}
  170. { duplicate$
  171.   "}" * add.period$
  172.   #-1 #1 substring$ "." =
  173. }
  174.  
  175. FUNCTION {new.block.checkb}
  176. { empty$
  177.  swap$ empty$
  178.  and
  179.    'skip$
  180.    'new.block
  181.  if$
  182. }
  183. FUNCTION {field.or.null}
  184. { duplicate$ empty$
  185.    { pop$ "" }
  186.    'skip$
  187.  if$
  188. }
  189. FUNCTION {emphasize}
  190. { duplicate$ empty$
  191.    { pop$ "" }
  192.    { "\emph{" swap$ * "}" * }
  193.  if$
  194. }
  195. FUNCTION {tie.or.space.prefix}
  196. { duplicate$ text.length$ #3 <
  197.    { "~" }
  198.    { " " }
  199.  if$
  200.  swap$
  201. }
  202. FUNCTION {capitalize}
  203. { "u" change.case$ "t" change.case$ }
  204. FUNCTION {space.word}
  205. { " " swap$ * " " * }
  206.  % Here are the language-specific definitions for explicit words.
  207.  % Each function has a name bbl.xxx where xxx is the English word.
  208.  % The language selected here is ENGLISH
  209. FUNCTION {bbl.and}
  210. { "and"}
  211.  
  212. FUNCTION {bbl.etal}
  213. { "et~al." }
  214.  
  215. FUNCTION {bbl.editors}
  216. { "eds." }
  217.  
  218. FUNCTION {bbl.editor}
  219. { "ed." }
  220.  
  221. FUNCTION {bbl.edby}
  222. { "edited by" }
  223.  
  224. FUNCTION {bbl.edition}
  225. { "ed." }
  226.  
  227. FUNCTION {bbl.volume}
  228. { "vol." }
  229.  
  230. FUNCTION {bbl.of}
  231. { "of" }
  232.  
  233. FUNCTION {bbl.number}
  234. { "no." }
  235.  
  236. FUNCTION {bbl.nr}
  237. { "no." }
  238.  
  239. FUNCTION {bbl.in}
  240. { "in" }
  241.  
  242. FUNCTION {bbl.pages}
  243. { "" }
  244.  
  245. FUNCTION {bbl.page}
  246. { "" }
  247.  
  248. FUNCTION {bbl.chapter}
  249. { "chap." }
  250.  
  251. FUNCTION {bbl.techrep}
  252. { "Tech. Rep." }
  253.  
  254. FUNCTION {bbl.mthesis}
  255. { "Master's thesis" }
  256.  
  257. FUNCTION {bbl.phdthesis}
  258. { "Ph.D. thesis" }
  259.  
  260. MACRO {jan} {"Jan."}
  261.  
  262. MACRO {feb} {"Feb."}
  263.  
  264. MACRO {mar} {"Mar."}
  265.  
  266. MACRO {apr} {"Apr."}
  267.  
  268. MACRO {may} {"May"}
  269.  
  270. MACRO {jun} {"Jun."}
  271.  
  272. MACRO {jul} {"Jul."}
  273.  
  274. MACRO {aug} {"Aug."}
  275.  
  276. MACRO {sep} {"Sep."}
  277.  
  278. MACRO {oct} {"Oct."}
  279.  
  280. MACRO {nov} {"Nov."}
  281.  
  282. MACRO {dec} {"Dec."}
  283.  
  284. MACRO {acmcs} {"ACM Computing Surveys"}
  285.  
  286. MACRO {acta} {"Acta Informatica"}
  287.  
  288. MACRO {cacm} {"Communications of the ACM"}
  289.  
  290. MACRO {ibmjrd} {"IBM Journal of Research and Development"}
  291.  
  292. MACRO {ibmsj} {"IBM Systems Journal"}
  293.  
  294. MACRO {ieeese} {"IEEE Transactions on Software Engineering"}
  295.  
  296. MACRO {ieeetc} {"IEEE Transactions on Computers"}
  297.  
  298. MACRO {ieeetcad}
  299. {"IEEE Transactions on Computer-Aided Design of Integrated Circuits"}
  300.  
  301. MACRO {ipl} {"Information Processing Letters"}
  302.  
  303. MACRO {jacm} {"Journal of the ACM"}
  304.  
  305. MACRO {jcss} {"Journal of Computer and System Sciences"}
  306.  
  307. MACRO {scp} {"Science of Computer Programming"}
  308.  
  309. MACRO {sicomp} {"SIAM Journal on Computing"}
  310.  
  311. MACRO {tocs} {"ACM Transactions on Computer Systems"}
  312.  
  313. MACRO {tods} {"ACM Transactions on Database Systems"}
  314.  
  315. MACRO {tog} {"ACM Transactions on Graphics"}
  316.  
  317. MACRO {toms} {"ACM Transactions on Mathematical Software"}
  318.  
  319. MACRO {toois} {"ACM Transactions on Office Information Systems"}
  320.  
  321. MACRO {toplas} {"ACM Transactions on Programming Languages and Systems"}
  322.  
  323. MACRO {tcs} {"Theoretical Computer Science"}
  324. FUNCTION {bibinfo.check}
  325. { swap$
  326.  duplicate$ missing$
  327.    {
  328.      pop$ pop$
  329.      ""
  330.    }
  331.    { duplicate$ empty$
  332.        {
  333.          swap$ pop$
  334.        }
  335.        { swap$
  336.          pop$
  337.        }
  338.      if$
  339.    }
  340.  if$
  341. }
  342. FUNCTION {bibinfo.warn}
  343. { swap$
  344.  duplicate$ missing$
  345.    {
  346.      swap$ "missing " swap$ * " in " * cite$ * warning$ pop$
  347.      ""
  348.    }
  349.    { duplicate$ empty$
  350.        {
  351.          swap$ "empty " swap$ * " in " * cite$ * warning$
  352.        }
  353.        { swap$
  354.          pop$
  355.        }
  356.      if$
  357.    }
  358.  if$
  359. }
  360. FUNCTION {write.url}
  361. { url empty$
  362.    { "" }
  363.    { "" }
  364.  if$
  365. }
  366. %FUNCTION {write.url}
  367. %{ url empty$
  368. %    { skip$ }
  369. %    { "\newline\urlprefix\url{" url * "}" * write$ newline$ }
  370. %  if$
  371. %}
  372.  
  373.  
  374.  
  375. STRINGS  { bibinfo}
  376. INTEGERS { nameptr namesleft numnames }
  377.  
  378. FUNCTION {format.names}
  379. { 'bibinfo :=
  380.  duplicate$ empty$ 'skip$ {
  381.  's :=
  382.  "" 't :=
  383.  #1 'nameptr :=
  384.  s num.names$ 'numnames :=
  385.  numnames 'namesleft :=
  386.    { namesleft #0 > }
  387.    { s nameptr
  388.      "{vv~}{ll}{, ff}{, jj}"
  389.      format.name$
  390.      bibinfo bibinfo.check
  391.      't :=
  392.      nameptr #1 >
  393.        {
  394.          namesleft #1 >
  395.            { ", " * t * }
  396.            {
  397.              numnames #2 >
  398.                { "," * }
  399.                'skip$
  400.              if$
  401.              s nameptr "{ll}" format.name$ duplicate$ "others" =
  402.                { 't := }
  403.                { pop$ }
  404.              if$
  405.              t "others" =
  406.                {
  407.                  " " * bbl.etal *
  408.                }
  409.                {
  410.                  bbl.and
  411.                  space.word * t *
  412.                }
  413.              if$
  414.            }
  415.          if$
  416.        }
  417.        't
  418.      if$
  419.      nameptr #1 + 'nameptr :=
  420.      namesleft #1 - 'namesleft :=
  421.    }
  422.  while$
  423.  } if$
  424. }
  425. FUNCTION {format.names.ed}
  426. {
  427.  'bibinfo :=
  428.  duplicate$ empty$ 'skip$ {
  429.  's :=
  430.  "" 't :=
  431.  #1 'nameptr :=
  432.  s num.names$ 'numnames :=
  433.  numnames 'namesleft :=
  434.    { namesleft #0 > }
  435.    { s nameptr
  436.      "{ff~}{vv~}{ll}{, jj}"
  437.      format.name$
  438.      bibinfo bibinfo.check
  439.      't :=
  440.      nameptr #1 >
  441.        {
  442.          namesleft #1 >
  443.            { ", " * t * }
  444.            {
  445.              numnames #2 >
  446.                { "," * }
  447.                'skip$
  448.              if$
  449.              s nameptr "{ll}" format.name$ duplicate$ "others" =
  450.                { 't := }
  451.                { pop$ }
  452.              if$
  453.              t "others" =
  454.                {
  455.                  " " * bbl.etal *
  456.                }
  457.                {
  458.                  bbl.and
  459.                  space.word * t *
  460.                }
  461.              if$
  462.            }
  463.          if$
  464.        }
  465.        't
  466.      if$
  467.      nameptr #1 + 'nameptr :=
  468.      namesleft #1 - 'namesleft :=
  469.    }
  470.  while$
  471.  } if$
  472. }
  473. FUNCTION {format.key}
  474. { empty$
  475.    { key field.or.null }
  476.    { "" }
  477.  if$
  478. }
  479.  
  480. FUNCTION {format.authors}
  481. { author "author" format.names
  482. }
  483. FUNCTION {get.bbl.editor}
  484. { editor num.names$ #1 > 'bbl.editors 'bbl.editor if$ }
  485.  
  486. FUNCTION {format.editors}
  487. { editor "editor" format.names duplicate$ empty$ 'skip$
  488.    {
  489.      "," *
  490.      " " *
  491.      get.bbl.editor
  492.      *
  493.    }
  494.  if$
  495. }
  496. FUNCTION {format.note}
  497. {
  498. note empty$
  499.    { "" }
  500.    { note #1 #1 substring$
  501.      duplicate$ "{" =
  502.        'skip$
  503.        { output.state mid.sentence =
  504.          { "l" }
  505.          { "u" }
  506.        if$
  507.        change.case$
  508.        }
  509.      if$
  510.      note #2 global.max$ substring$ * "note" bibinfo.check
  511.    }
  512.  if$
  513. }
  514.  
  515. FUNCTION {format.title}
  516. { title
  517.  "title" bibinfo.check
  518.  duplicate$ empty$ 'skip$
  519.    {
  520.      "\enquote{" swap$ *
  521.      add.period$ "}" *
  522.    }
  523.  if$
  524. }
  525. FUNCTION {end.quote.btitle}
  526. { booktitle empty$
  527.    'skip$
  528.    { editor empty$
  529.        { before.all 'output.state := }
  530.        'skip$
  531.      if$
  532.    }
  533.  if$
  534. }
  535. FUNCTION {format.full.names}
  536. {'s :=
  537. "" 't :=
  538.  #1 'nameptr :=
  539.  s num.names$ 'numnames :=
  540.  numnames 'namesleft :=
  541.    { namesleft #0 > }
  542.    { s nameptr
  543.      "{vv~}{ll}" format.name$
  544.      't :=
  545.      nameptr #1 >
  546.        {
  547.          namesleft #1 >
  548.            { ", " * t * }
  549.            {
  550.              s nameptr "{ll}" format.name$ duplicate$ "others" =
  551.                { 't := }
  552.                { pop$ }
  553.              if$
  554.              t "others" =
  555.                {
  556.                  " " * bbl.etal *
  557.                }
  558.                {
  559.                  numnames #2 >
  560.                    { "," * }
  561.                    'skip$
  562.                  if$
  563.                  bbl.and
  564.                  space.word * t *
  565.                }
  566.              if$
  567.            }
  568.          if$
  569.        }
  570.        't
  571.      if$
  572.      nameptr #1 + 'nameptr :=
  573.      namesleft #1 - 'namesleft :=
  574.    }
  575.  while$
  576. }
  577.  
  578. FUNCTION {author.editor.key.full}
  579. { author empty$
  580.    { editor empty$
  581.        { key empty$
  582.            { cite$ #1 #3 substring$ }
  583.            'key
  584.          if$
  585.        }
  586.        { editor format.full.names }
  587.      if$
  588.    }
  589.    { author format.full.names }
  590.  if$
  591. }
  592.  
  593. FUNCTION {author.key.full}
  594. { author empty$
  595.    { key empty$
  596.         { cite$ #1 #3 substring$ }
  597.          'key
  598.      if$
  599.    }
  600.    { author format.full.names }
  601.  if$
  602. }
  603.  
  604. FUNCTION {editor.key.full}
  605. { editor empty$
  606.    { key empty$
  607.         { cite$ #1 #3 substring$ }
  608.          'key
  609.      if$
  610.    }
  611.    { editor format.full.names }
  612.  if$
  613. }
  614.  
  615. FUNCTION {make.full.names}
  616. { type$ "book" =
  617.  type$ "inbook" =
  618.  or
  619.    'author.editor.key.full
  620.    { type$ "proceedings" =
  621.        'editor.key.full
  622.        'author.key.full
  623.      if$
  624.    }
  625.  if$
  626. }
  627. FUNCTION {output.bibitem}
  628. { newline$
  629.  "\bibitem[{" write$
  630.  label write$
  631.  ")" make.full.names duplicate$ short.list =
  632.     { pop$ }
  633.     { * }
  634.   if$
  635.  "}]{" * write$
  636.  cite$ write$
  637.  "}" write$
  638.  newline$
  639.  ""
  640.  before.all 'output.state :=
  641. }
  642.  
  643. FUNCTION {n.dashify}
  644. {
  645.  't :=
  646.  ""
  647.    { t empty$ not }
  648.    { t #1 #1 substring$ "-" =
  649.        { t #1 #2 substring$ "--" = not
  650.            { "--" *
  651.              t #2 global.max$ substring$ 't :=
  652.            }
  653.            {   { t #1 #1 substring$ "-" = }
  654.                { "-" *
  655.                  t #2 global.max$ substring$ 't :=
  656.                }
  657.              while$
  658.            }
  659.          if$
  660.        }
  661.        { t #1 #1 substring$ *
  662.          t #2 global.max$ substring$ 't :=
  663.        }
  664.      if$
  665.    }
  666.  while$
  667. }
  668. FUNCTION {word.in}
  669. { "" }
  670. FUNCTION {format.date}
  671. { year "year" bibinfo.check duplicate$ empty$
  672.    {
  673.      "empty year in " cite$ * "; set to ????" * warning$
  674.       pop$ "????"
  675.    }
  676.    'skip$
  677.  if$
  678.  extra.label *
  679. }
  680. FUNCTION{format.year}
  681. { year "year" bibinfo.check duplicate$ empty$
  682.    {  "empty year in " cite$ *
  683.       "; set to ????" *
  684.       warning$
  685.       pop$ "????"
  686.    }
  687.    {
  688.    }
  689.  if$
  690.  extra.label *
  691.  " (" swap$ * ")" *
  692. }
  693. FUNCTION {format.btitle}
  694. { title "title" bibinfo.check
  695.  duplicate$ empty$ 'skip$
  696.    {
  697.      emphasize
  698.    }
  699.  if$
  700. }
  701. FUNCTION {either.or.check}
  702. { empty$
  703.    'pop$
  704.    { "can't use both " swap$ * " fields in " * cite$ * warning$ }
  705.  if$
  706. }
  707. FUNCTION {format.bvolume}
  708. { volume empty$
  709.    { "" }
  710.    { bbl.volume volume tie.or.space.prefix
  711.      "volume" bibinfo.check * *
  712.      series "series" bibinfo.check
  713.      duplicate$ empty$ 'pop$
  714.        { swap$ bbl.of space.word * swap$
  715.          emphasize * }
  716.      if$
  717.      "volume and number" number either.or.check
  718.    }
  719.  if$
  720. }
  721. FUNCTION {format.number.series}
  722. { volume empty$
  723.    { number empty$
  724.        { series field.or.null }
  725.        { series empty$
  726.            { number "number" bibinfo.check }
  727.            { output.state mid.sentence =
  728.                { bbl.number }
  729.                { bbl.number capitalize }
  730.              if$
  731.              number tie.or.space.prefix "number" bibinfo.check * *
  732.              bbl.in space.word *
  733.              series "series" bibinfo.check *
  734.            }
  735.          if$
  736.        }
  737.      if$
  738.    }
  739.    { "" }
  740.  if$
  741. }
  742.  
  743. FUNCTION {format.edition}
  744. { edition duplicate$ empty$ 'skip$
  745.    {
  746.      output.state mid.sentence =
  747.        { "l" }
  748.        { "t" }
  749.      if$ change.case$
  750.      "edition" bibinfo.check
  751.      " " * bbl.edition *
  752.    }
  753.  if$
  754. }
  755. INTEGERS { multiresult }
  756. FUNCTION {multi.page.check}
  757. { 't :=
  758.  #0 'multiresult :=
  759.    { multiresult not
  760.      t empty$ not
  761.      and
  762.    }
  763.    { t #1 #1 substring$
  764.      duplicate$ "-" =
  765.      swap$ duplicate$ "," =
  766.      swap$ "+" =
  767.      or or
  768.        { #1 'multiresult := }
  769.        { t #2 global.max$ substring$ 't := }
  770.      if$
  771.    }
  772.  while$
  773.  multiresult
  774. }
  775. FUNCTION {format.pages}
  776. { pages duplicate$ empty$ 'skip$
  777.    { duplicate$ multi.page.check
  778.        {
  779.          n.dashify
  780.        }
  781.        {
  782.        }
  783.      if$
  784.      "pages" bibinfo.check
  785.    }
  786.  if$
  787. }
  788. FUNCTION {format.journal.pages}
  789. { pages duplicate$ empty$ 'pop$
  790.    { swap$ duplicate$ empty$
  791.        { pop$ pop$ format.pages }
  792.        {
  793.          ": " *
  794.          swap$
  795.          n.dashify
  796.          "pages" bibinfo.check
  797.          *
  798.        }
  799.      if$
  800.    }
  801.  if$
  802. }
  803. FUNCTION {format.journal.eid}
  804. { eid "eid" bibinfo.check
  805.  duplicate$ empty$ 'pop$
  806.    { swap$ duplicate$ empty$ 'skip$
  807.      {
  808.          ": " *
  809.      }
  810.      if$
  811.      swap$ *
  812.    }
  813.  if$
  814. }
  815. FUNCTION {format.vol.num.pages}
  816. { volume field.or.null
  817.  duplicate$ empty$ 'skip$
  818.    {
  819.      "volume" bibinfo.check
  820.    }
  821.  if$
  822.  number "number" bibinfo.check duplicate$ empty$ 'skip$
  823.    {
  824.      swap$ duplicate$ empty$
  825.        { "there's a number but no volume in " cite$ * warning$ }
  826.        'skip$
  827.      if$
  828.      swap$
  829.      "." swap$ *
  830.  format.year *
  831.    }
  832.  if$ *
  833. }
  834.  
  835. FUNCTION {format.chapter.pages}
  836. { chapter empty$
  837.    { "" }
  838.    { type empty$
  839.        { bbl.chapter }
  840.        { type "l" change.case$
  841.          "type" bibinfo.check
  842.        }
  843.      if$
  844.      chapter tie.or.space.prefix
  845.      "chapter" bibinfo.check
  846.      * *
  847.    }
  848.  if$
  849. }
  850. FUNCTION {bt.enquote}
  851. { duplicate$ empty$ 'skip$
  852.  { "\enquote{" swap$ *
  853.    non.stop
  854.      { ",} " * }
  855.      { "}, " * }
  856.    if$
  857.  }
  858.  if$
  859. }
  860. FUNCTION {format.booktitle}
  861. {
  862.  booktitle "booktitle" bibinfo.check
  863.    duplicate$ empty$ 'skip$
  864.    {
  865.      emphasize
  866.      ". " *
  867.    }
  868.  if$
  869. }
  870. FUNCTION {format.in.ed.booktitle}
  871. { format.booktitle duplicate$ empty$ 'skip$
  872.    {
  873.      editor "editor" format.names.ed duplicate$ empty$ 'pop$
  874.        {
  875.          get.bbl.editor
  876.          " " * swap$ *
  877.          swap$
  878.          "" *
  879.          " " * swap$
  880.          * }
  881.      if$
  882.      word.in swap$ *
  883.    }
  884.  if$
  885. }
  886. FUNCTION {format.thesis.type}
  887. { type duplicate$ empty$
  888.    'pop$
  889.    { swap$ pop$
  890.      "t" change.case$ "type" bibinfo.check
  891.    }
  892.  if$
  893. }
  894. FUNCTION {format.tr.number}
  895. { number "number" bibinfo.check
  896.  type duplicate$ empty$
  897.    { pop$ bbl.techrep }
  898.    'skip$
  899.  if$
  900.  "type" bibinfo.check
  901.  swap$ duplicate$ empty$
  902.    { pop$ "t" change.case$ }
  903.    { tie.or.space.prefix * * }
  904.  if$
  905. }
  906. FUNCTION {format.article.crossref}
  907. {
  908.  word.in
  909.  " \cite{" * crossref * "}" *
  910. }
  911. FUNCTION {format.book.crossref}
  912. { volume duplicate$ empty$
  913.    { "empty volume in " cite$ * "'s crossref of " * crossref * warning$
  914.      pop$ word.in
  915.    }
  916.    { bbl.volume
  917.      capitalize
  918.      swap$ tie.or.space.prefix "volume" bibinfo.check * * bbl.of space.word *
  919.    }
  920.  if$
  921.  " \cite{" * crossref * "}" *
  922. }
  923. FUNCTION {format.incoll.inproc.crossref}
  924. {
  925.  word.in
  926.  " \cite{" * crossref * "}" *
  927. }
  928. FUNCTION {format.org.or.pub}
  929. { 't :=
  930.  ""
  931.      address "address" bibinfo.check *
  932.      t empty$
  933.        'skip$
  934.        { address empty$
  935.            'skip$
  936.            { ": " * }
  937.          if$
  938.          t *
  939.        }
  940.      if$
  941.      year duplicate$ empty$
  942.        { "empty year in " cite$ * "; set to ????" * warning$
  943.           pop$ "????" }
  944.        { "year" bibinfo.check extra.label * }
  945.      if$
  946.      t empty$ address empty$ and
  947.        { * }
  948.        { ", " swap$ * * }
  949.      if$
  950. }
  951. FUNCTION {format.publisher.address}
  952. { publisher "publisher" bibinfo.warn format.org.or.pub
  953. }
  954.  
  955. FUNCTION {format.organization.address}
  956. { organization "organization" bibinfo.check format.org.or.pub
  957. }
  958.  
  959. STRINGS {oldname}
  960.  
  961. FUNCTION {name.or.dash}
  962. { 's :=
  963.   oldname empty$
  964.     { s 'oldname := s }
  965.     { s oldname =
  966.         { "---{}---{}---" }
  967.         { s 'oldname := s }
  968.       if$
  969.     }
  970.   if$
  971. }
  972. FUNCTION {article}
  973. { output.bibitem
  974.  format.authors "author" output.check
  975.  author format.key output
  976.  name.or.dash
  977.  new.block
  978.  format.title "title" output.check
  979.  new.block
  980.  crossref missing$
  981.    {
  982.      journal
  983.      "journal" bibinfo.check
  984.      emphasize
  985.      "journal" output.check
  986.      add.blank
  987.      format.vol.num.pages output
  988.    }
  989.    { format.article.crossref output.nonnull
  990.    }
  991.  if$
  992.  eid empty$
  993.    { format.journal.pages }
  994.    { format.journal.eid }
  995.  if$
  996.  new.block
  997.  format.note output
  998.  fin.entry
  999.  write.url
  1000. }
  1001. FUNCTION {book}
  1002. { output.bibitem
  1003.  author empty$
  1004.    { format.editors "author and editor" output.check
  1005.      editor format.key output
  1006.      name.or.dash
  1007.    }
  1008.    { format.authors output.nonnull
  1009.      name.or.dash
  1010.      crossref missing$
  1011.        { "author and editor" editor either.or.check }
  1012.        'skip$
  1013.      if$
  1014.    }
  1015.  if$
  1016.  new.block
  1017.  format.btitle "title" output.check
  1018.  crossref missing$
  1019.    { format.bvolume output
  1020.      new.block
  1021.      format.number.series output
  1022.      new.sentence
  1023.      format.publisher.address output
  1024.    }
  1025.    {
  1026.      new.block
  1027.      format.book.crossref output.nonnull
  1028.      format.date "year" output.check
  1029.    }
  1030.  if$
  1031.  format.edition output
  1032.  new.block
  1033.  format.note output
  1034.  fin.entry
  1035.  write.url
  1036. }
  1037. FUNCTION {booklet}
  1038. { output.bibitem
  1039.  format.authors output
  1040.  author format.key output
  1041.  name.or.dash
  1042.  new.block
  1043.  format.title "title" output.check
  1044.  new.block
  1045.  howpublished "howpublished" bibinfo.check output
  1046.  address "address" bibinfo.check output
  1047.  format.date "year" output.check
  1048.  new.block
  1049.  format.note output
  1050.  fin.entry
  1051.  write.url
  1052. }
  1053.  
  1054. FUNCTION {inbook}
  1055. { output.bibitem
  1056.  author empty$
  1057.    { format.editors "author and editor" output.check
  1058.      editor format.key output
  1059.      name.or.dash
  1060.    }
  1061.    { format.authors output.nonnull
  1062.      name.or.dash
  1063.      crossref missing$
  1064.        { "author and editor" editor either.or.check }
  1065.        'skip$
  1066.      if$
  1067.    }
  1068.  if$
  1069.  new.block
  1070.  format.btitle "title" output.check
  1071.  crossref missing$
  1072.    {
  1073.      format.bvolume output
  1074.      format.chapter.pages "chapter and pages" output.check
  1075.      new.block
  1076.      format.number.series output
  1077.      new.sentence
  1078.      format.publisher.address output
  1079.    }
  1080.    {
  1081.      format.chapter.pages "chapter and pages" output.check
  1082.      new.block
  1083.      format.book.crossref output.nonnull
  1084.      format.date "year" output.check
  1085.    }
  1086.  if$
  1087.  format.edition output
  1088.  format.pages "pages" output.check
  1089.  new.block
  1090.  format.note output
  1091.  fin.entry
  1092.  write.url
  1093. }
  1094. FUNCTION {incollection}
  1095. { output.bibitem
  1096.  format.authors "author" output.check
  1097.  author format.key output
  1098.  name.or.dash
  1099.  new.block
  1100.  format.title "title" output.check
  1101.  new.block
  1102.  crossref missing$
  1103.    { format.in.ed.booktitle "booktitle" output.check
  1104.      end.quote.btitle
  1105.      format.bvolume output
  1106.      format.number.series output
  1107.      format.chapter.pages output
  1108.      new.sentence
  1109.      format.publisher.address output
  1110.      format.edition output
  1111.    }
  1112.    { format.incoll.inproc.crossref output.nonnull
  1113.      format.chapter.pages output
  1114.    }
  1115.  if$
  1116.  new.block
  1117.  format.pages "pages" output.check
  1118.  new.block
  1119.  format.note output
  1120.  fin.entry
  1121.  write.url
  1122. }
  1123. FUNCTION {inproceedings}
  1124. { output.bibitem
  1125.  format.authors "author" output.check
  1126.  author format.key output
  1127.  name.or.dash
  1128.  new.block
  1129.  format.title "title" output.check
  1130.  new.block
  1131.  crossref missing$
  1132.    { format.in.ed.booktitle "booktitle" output.check
  1133.      end.quote.btitle
  1134.      format.bvolume output
  1135.      format.number.series output
  1136.      new.sentence
  1137.      publisher empty$
  1138.        { format.organization.address output }
  1139.        { organization "organization" bibinfo.check output
  1140.          format.publisher.address output
  1141.        }
  1142.      if$
  1143.    }
  1144.    { format.incoll.inproc.crossref output.nonnull
  1145.    }
  1146.  if$
  1147.  format.pages "pages" output.check
  1148.  new.block
  1149.  format.note output
  1150.  fin.entry
  1151.  write.url
  1152. }
  1153. FUNCTION {conference} { inproceedings }
  1154. FUNCTION {manual}
  1155. { output.bibitem
  1156.  format.authors output
  1157.  author format.key output
  1158.  name.or.dash
  1159.  new.block
  1160.  format.btitle "title" output.check
  1161.  organization address new.block.checkb
  1162.  organization "organization" bibinfo.check output
  1163.  address "address" bibinfo.check output
  1164.  format.edition output
  1165.  format.date "year" output.check
  1166.  new.block
  1167.  format.note output
  1168.  fin.entry
  1169.  write.url
  1170. }
  1171. FUNCTION {mastersthesis}
  1172. { output.bibitem
  1173.  format.authors "author" output.check
  1174.  author format.key output
  1175.  name.or.dash
  1176.  new.block
  1177.  format.btitle
  1178.  "title" output.check
  1179.  new.block
  1180.  bbl.mthesis format.thesis.type output.nonnull
  1181.  school "school" bibinfo.warn output
  1182.  address "address" bibinfo.check output
  1183.  format.date "year" output.check
  1184.  new.block
  1185.  format.note output
  1186.  fin.entry
  1187.  write.url
  1188. }
  1189. FUNCTION {misc}
  1190. { output.bibitem
  1191.  format.authors output
  1192.  author format.key output
  1193.  name.or.dash
  1194.  new.block
  1195.  format.title output
  1196.  new.block
  1197.  howpublished "howpublished" bibinfo.check output
  1198.  format.date "year" output.check
  1199.  new.block
  1200.  format.note output
  1201.  fin.entry
  1202.  write.url
  1203. }
  1204. FUNCTION {phdthesis}
  1205. { output.bibitem
  1206.  format.authors "author" output.check
  1207.  author format.key output
  1208.  name.or.dash
  1209.  new.block
  1210.  format.btitle
  1211.  "title" output.check
  1212.  new.block
  1213.  bbl.phdthesis format.thesis.type output.nonnull
  1214.  school "school" bibinfo.warn output
  1215.  address "address" bibinfo.check output
  1216.  format.date "year" output.check
  1217.  new.block
  1218.  format.note output
  1219.  fin.entry
  1220.  write.url
  1221. }
  1222. FUNCTION {proceedings}
  1223. { output.bibitem
  1224.  format.editors output
  1225.  editor format.key output
  1226.  name.or.dash
  1227.  new.block
  1228.  format.btitle "title" output.check
  1229.  format.bvolume output
  1230.  format.number.series output
  1231.  new.sentence
  1232.  publisher empty$
  1233.    { format.organization.address output }
  1234.    { organization "organization" bibinfo.check output
  1235.      format.publisher.address output
  1236.    }
  1237.  if$
  1238.  new.block
  1239.  format.note output
  1240.  fin.entry
  1241.  write.url
  1242. }
  1243. FUNCTION {techreport}
  1244. { output.bibitem
  1245.  format.authors "author" output.check
  1246.  author format.key output
  1247.  name.or.dash
  1248.  new.block
  1249.  format.title
  1250.  "title" output.check
  1251.  new.block
  1252.  format.tr.number output.nonnull
  1253.  institution "institution" bibinfo.warn output
  1254.  address "address" bibinfo.check output
  1255.  format.date "year" output.check
  1256.  new.block
  1257.  format.note output
  1258.  fin.entry
  1259.  write.url
  1260. }
  1261. FUNCTION {unpublished}
  1262. { output.bibitem
  1263.  format.authors "author" output.check
  1264.  author format.key output
  1265.  name.or.dash
  1266.  new.block
  1267.  format.title "title" output.check
  1268.  format.date "year" output.check
  1269.  new.block
  1270.  format.note "note" output.check
  1271.  fin.entry
  1272.  write.url
  1273. }
  1274. FUNCTION {default.type} { misc }
  1275. READ
  1276. FUNCTION {sortify}
  1277. { purify$
  1278.  "l" change.case$
  1279. }
  1280. INTEGERS { len }
  1281. FUNCTION {chop.word}
  1282. { 's :=
  1283.  'len :=
  1284.  s #1 len substring$ =
  1285.    { s len #1 + global.max$ substring$ }
  1286.    's
  1287.  if$
  1288. }
  1289. FUNCTION {format.lab.names}
  1290. { 's :=
  1291.  "" 't :=
  1292.  s #1 "{vv~}{ll}" format.name$
  1293.  s num.names$ duplicate$
  1294.  #2 >
  1295.    { pop$
  1296.      " " * bbl.etal *
  1297.    }
  1298.    { #2 <
  1299.        'skip$
  1300.        { s #2 "{ff }{vv }{ll}{ jj}" format.name$ "others" =
  1301.            {
  1302.              " " * bbl.etal *
  1303.            }
  1304.            { bbl.and space.word * s #2 "{vv~}{ll}" format.name$
  1305.              * }
  1306.          if$
  1307.        }
  1308.      if$
  1309.    }
  1310.  if$
  1311. }
  1312. FUNCTION {author.key.label}
  1313. { author empty$
  1314.    { key empty$
  1315.        { cite$ #1 #3 substring$ }
  1316.        'key
  1317.      if$
  1318.    }
  1319.    { author format.lab.names }
  1320.  if$
  1321. }
  1322. FUNCTION {author.editor.key.label}
  1323. { author empty$
  1324.    { editor empty$
  1325.        { key empty$
  1326.            { cite$ #1 #3 substring$ }
  1327.            'key
  1328.          if$
  1329.        }
  1330.        { editor format.lab.names }
  1331.      if$
  1332.    }
  1333.    { author format.lab.names }
  1334.  if$
  1335. }
  1336. FUNCTION {editor.key.label}
  1337. { editor empty$
  1338.    { key empty$
  1339.        { cite$ #1 #3 substring$ }
  1340.        'key
  1341.      if$
  1342.    }
  1343.    { editor format.lab.names }
  1344.  if$
  1345. }
  1346. FUNCTION {calc.short.authors}
  1347. { type$ "book" =
  1348.  type$ "inbook" =
  1349.  or
  1350.    'author.editor.key.label
  1351.    { type$ "proceedings" =
  1352.        'editor.key.label
  1353.        'author.key.label
  1354.      if$
  1355.    }
  1356.  if$
  1357.  'short.list :=
  1358. }
  1359.  
  1360. FUNCTION {calc.label}
  1361. { calc.short.authors
  1362.  short.list
  1363.  "("
  1364.  *
  1365.  year duplicate$ empty$
  1366.  short.list key field.or.null = or
  1367.     { pop$ "" }
  1368.     { purify$ #-1 #4 substring$ }
  1369.  if$
  1370.  *
  1371.  'label :=
  1372. }
  1373.  
  1374. FUNCTION {sort.format.names}
  1375. { 's :=
  1376.  #1 'nameptr :=
  1377.  ""
  1378.  s num.names$ 'numnames :=
  1379.  numnames 'namesleft :=
  1380.    { namesleft #0 > }
  1381.    { s nameptr
  1382.      "{vv{ } }{ll{ }}{  ff{ }}{  jj{ }}"
  1383.      format.name$ 't :=
  1384.      nameptr #1 >
  1385.        {
  1386.          "   "  *
  1387.          namesleft #1 = t "others" = and
  1388.            { "zzzzz" * }
  1389.            { t sortify * }
  1390.          if$
  1391.        }
  1392.        { t sortify * }
  1393.      if$
  1394.      nameptr #1 + 'nameptr :=
  1395.      namesleft #1 - 'namesleft :=
  1396.    }
  1397.  while$
  1398. }
  1399. FUNCTION {sort.format.title}
  1400. { 't :=
  1401.  "A " #2
  1402.    "An " #3
  1403.      "The " #4 t chop.word
  1404.    chop.word
  1405.  chop.word
  1406.  sortify
  1407.  #1 global.max$ substring$
  1408. }
  1409. FUNCTION {author.sort}
  1410. { author empty$
  1411.    { key empty$
  1412.        { "to sort, need author or key in " cite$ * warning$
  1413.          ""
  1414.        }
  1415.        { key sortify }
  1416.      if$
  1417.    }
  1418.    { author sort.format.names }
  1419.  if$
  1420. }
  1421. FUNCTION {author.editor.sort}
  1422. { author empty$
  1423.    { editor empty$
  1424.        { key empty$
  1425.            { "to sort, need author, editor, or key in " cite$ * warning$
  1426.              ""
  1427.            }
  1428.            { key sortify }
  1429.          if$
  1430.        }
  1431.        { editor sort.format.names }
  1432.      if$
  1433.    }
  1434.    { author sort.format.names }
  1435.  if$
  1436. }
  1437. FUNCTION {editor.sort}
  1438. { editor empty$
  1439.    { key empty$
  1440.        { "to sort, need editor or key in " cite$ * warning$
  1441.          ""
  1442.        }
  1443.        { key sortify }
  1444.      if$
  1445.    }
  1446.    { editor sort.format.names }
  1447.  if$
  1448. }
  1449. FUNCTION {presort}
  1450. { calc.label
  1451.  label sortify
  1452.  "    "
  1453.  *
  1454.  type$ "book" =
  1455.  type$ "inbook" =
  1456.  or
  1457.    'author.editor.sort
  1458.    { type$ "proceedings" =
  1459.        'editor.sort
  1460.        'author.sort
  1461.      if$
  1462.    }
  1463.  if$
  1464.  #1 entry.max$ substring$
  1465.  'sort.label :=
  1466.  sort.label
  1467.  *
  1468.  "    "
  1469.  *
  1470.  title field.or.null
  1471.  sort.format.title
  1472.  *
  1473.  #1 entry.max$ substring$
  1474.  'sort.key$ :=
  1475. }
  1476. ITERATE {presort}
  1477. SORT
  1478. STRINGS { last.label next.extra }
  1479. INTEGERS { last.extra.num number.label }
  1480. FUNCTION {initialize.extra.label.stuff}
  1481. { #0 int.to.chr$ 'last.label :=
  1482.  "" 'next.extra :=
  1483.  #0 'last.extra.num :=
  1484.  #0 'number.label :=
  1485. }
  1486. FUNCTION {forward.pass}
  1487. { last.label label =
  1488.    { last.extra.num #1 + 'last.extra.num :=
  1489.      last.extra.num int.to.chr$ 'extra.label :=
  1490.    }
  1491.    { "a" chr.to.int$ 'last.extra.num :=
  1492.      "" 'extra.label :=
  1493.      label 'last.label :=
  1494.    }
  1495.  if$
  1496.  number.label #1 + 'number.label :=
  1497. }
  1498. FUNCTION {reverse.pass}
  1499. { next.extra "b" =
  1500.    { "a" 'extra.label := }
  1501.    'skip$
  1502.  if$
  1503.  extra.label 'next.extra :=
  1504.  extra.label
  1505.  duplicate$ empty$
  1506.    'skip$
  1507.    { "{\natexlab{" swap$ * "}}" * }
  1508.  if$
  1509.  'extra.label :=
  1510.  label extra.label * 'label :=
  1511. }
  1512. EXECUTE {initialize.extra.label.stuff}
  1513. ITERATE {forward.pass}
  1514. REVERSE {reverse.pass}
  1515. FUNCTION {bib.sort.order}
  1516. { sort.label
  1517.  "    "
  1518.  *
  1519.  year field.or.null sortify
  1520.  *
  1521.  "    "
  1522.  *
  1523.  title field.or.null
  1524.  sort.format.title
  1525.  *
  1526.  #1 entry.max$ substring$
  1527.  'sort.key$ :=
  1528. }
  1529. ITERATE {bib.sort.order}
  1530. SORT
  1531. FUNCTION {begin.bib}
  1532. { preamble$ empty$
  1533.    'skip$
  1534.    { preamble$ write$ newline$ }
  1535.  if$
  1536.  "\begin{thebibliography}{" number.label int.to.str$ * "}" *
  1537.  write$ newline$
  1538.  "\newcommand{\enquote}[1]{``#1''}"
  1539.  write$ newline$
  1540.  "\providecommand{\natexlab}[1]{#1}"
  1541.  write$ newline$
  1542.  "\providecommand{\url}[1]{\texttt{#1}}"
  1543.  write$ newline$
  1544.  "\providecommand{\urlprefix}{URL }"
  1545.  write$ newline$
  1546. }
  1547. EXECUTE {begin.bib}
  1548. EXECUTE {init.state.consts}
  1549. ITERATE {call.type$}
  1550. FUNCTION {end.bib}
  1551. { newline$
  1552.  "\end{thebibliography}" write$ newline$
  1553. }
  1554. EXECUTE {end.bib}
  1555. %% End of customized bst file
  1556. %%
  1557. %% End of file `mla-new.bst'.
Advertisement
Add Comment
Please, Sign In to add comment