adsabs / export_service

Export service to output ADS records with various formats including BibTex, AASTex, and multiple tagged and xml options
MIT License
3 stars 5 forks source link

Adjust all tex-based output for superscripts/subscripts #34

Closed aaccomazzi closed 6 years ago

aaccomazzi commented 6 years ago

We need to translate <SUP>foo</SUP> and <SUB>bar</SUB> sequences into the proper latex equivalent of $^{foo}$ and $_{bar}$ Example:

@INPROCEEDINGS{1989BAAS...21..780H,
       author = {{Hanisch}, R.~J. and {Biemesderfer}, C.~D.},
        title = "{T<SUB>E</SUB>X and LAT<SUB>E</SUB>X Macro Definition Files for
        Astronomical Publications}",
    booktitle = {Bulletin of the American Astronomical Society, 21, 780},
         year = 1989,
       volume = {21},
        month = Mar,
        pages = {780},
       adsurl = {https://ui.adsabs.harvard.edu/#abs/1989BAAS...21..780H},
      adsnote = {Provided by the SAO/NASA Astrophysics Data System}
}

vs. the classic output:

@INPROCEEDINGS{1989BAAS...21..780H,
   author = {{Hanisch}, R.~J. and {Biemesderfer}, C.~D.},
    title = "{T$_{E}$X and LAT$_{E}$X Macro Definition Files for Astronomical Publications}",
booktitle = {Bulletin of the American Astronomical Society},
     year = 1989,
   series = {\baas},
   volume = 21,
    month = mar,
   adsurl = {http://adsabs.harvard.edu/abs/1989BAAS...21..780H},
  adsnote = {Provided by the SAO/NASA Astrophysics Data System}
}
golnazads commented 6 years ago

Fixed in release v2.0.19

@INPROCEEDINGS{1989BAAS...21..780H, author = {{Hanisch}, R.~J. and {Biemesderfer}, C.~D.}, title = "{T${E}$X and LAT${E}$X Macro Definition Files for Astronomical Publications}", booktitle = {Bulletin of the American Astronomical Society}, year = 1989, volume = {21}, month = Mar, pages = {780}, adsurl = {https://ui.adsabs.harvard.edu/#abs/1989BAAS...21..780H}, adsnote = {Provided by the SAO/NASA Astrophysics Data System} }