LaTeXML icon indicating copy to clipboard operation
LaTeXML copied to clipboard

support sort option for natbib.sty

Open BalajiCM24 opened this issue 1 year ago • 2 comments

When converting from LaTeX to HTML, my input is: Citations: \citep{sigurd_word_2004,bybee_frequency_2007,ernestus_introduction_2011}.

Converted output: (Sigurd et al., 2004; Bybee, 2007; Ernestus & Warner, 2011)

PDF output: (Bybee, 2007; Ernestus & Warner, 2011; Sigurd et al., 2004)

How shall I sort the reference citation in alphabetical order?

BalajiCM24 avatar Jul 30 '24 07:07 BalajiCM24

Are you using the sort option of the natbib package? On a quick check, latexml doesn't support that yet, will mark the issue as a package enhancement.

Existing code is at: https://github.com/brucemiller/LaTeXML/blob/40e9fa89efbf4006ddf06ecb57da4588aa661b4e/lib/LaTeXML/Package/natbib.sty.ltxml#L68-L69

dginev avatar Jul 30 '24 17:07 dginev

Thanks for your response. Yes, I tried, it sorts only by year in chronological order, not alphabetically.

BalajiCM24 avatar Jul 31 '24 04:07 BalajiCM24