Ejemplo n.º 1
0
def _xml_get_authors_string(authors):
    "Convert author tuple to author string"
    authors = [
        _xml_mark_author(author,
                         short_author(author).strip()) for author in authors
    ]
    return '\n'.join(authors)
Ejemplo n.º 2
0
def _latex_get_authors_string(authors):
    "Convert author tuple to author string"
    authors = [_latex_mark_author(author, short_author(author).strip()) for author in authors]
    if len(authors) == 1:
        return authors[0]
    if authors[-1] == "others":
        return ", ".join(authors[:-1]) + " et al."
    else:
        return ", ".join(authors[:-1]) + " and " + authors[-1]
Ejemplo n.º 3
0
def _html_get_authors_string(authors):
    "Convert author tuple to author string"
    authors = [_html_mark_author(author, short_author(author).strip()) for author in authors]
    if len(authors) == 1:
        str = authors[0]
    else :
        if authors[-1] == "others":
            str =  ", ".join(authors[:-1]) + " et al."
        else:
            str = ", ".join(authors[:-1]) + " and " + authors[-1]

    return '<span class="%s_item_authors">%s</span>' % (config.get("html_class_prefix"), str)
Ejemplo n.º 4
0
def _rst_get_authors_string(authors):
    "Convert author tuple to author string"
    authors = [_rst_mark_author(author, short_author(author).strip()) \
                   for author in authors]
    if len(authors) == 1:
        str = authors[0]
    else :
        if authors[-1] == "others":
            str =  ", ".join(authors[:-1]) + " et al."
        else:
            str = ", ".join(authors[:-1]) + " and " + authors[-1]
    #str = "_%s (%s)_" % (str, paper["year"])
    str = "_%s_" % (str)
    return str
Ejemplo n.º 5
0
def _rst_get_authors_string(authors):
    "Convert author tuple to author string"
    authors = [_rst_mark_author(author, short_author(author).strip()) \
                   for author in authors]
    if len(authors) == 1:
        str = authors[0]
    else:
        if authors[-1] == "others":
            str = ", ".join(authors[:-1]) + " et al."
        else:
            str = ", ".join(authors[:-1]) + " and " + authors[-1]
    #str = "_%s (%s)_" % (str, paper["year"])
    str = "_%s_" % (str)
    return str
Ejemplo n.º 6
0
def _xml_get_authors_string(authors):
    "Convert author tuple to author string"
    authors = [_xml_mark_author(author, short_author(author).strip())
               for author in authors]
    return '\n'.join(authors)