Ignore:
Timestamp:
Sep 23, 2012, 6:09:08 AM (9 years ago)
Author:
Peter Johansson
Message:

remove trailing whitespace

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/first_page.cc

    r1290 r1513  
    5454
    5555  void print_main_page(const std::string& dir, const SVNlog& log,
    56                        const StatsCollection& stats, std::string url, 
     56                       const StatsCollection& stats, std::string url,
    5757                       const NodeCounter& node_counter)
    5858  {
     
    6464    set<string> authors;
    6565    std::transform(log.commits().begin(), log.commits().end(),
    66                    std::inserter(authors, authors.begin()), 
     66                   std::inserter(authors, authors.begin()),
    6767                   std::mem_fun_ref(&Commitment::author));
    6868    // erase invalid authors
     
    8585  }
    8686
    87   void print_general_information(std::ostream& os, const SVNlog& log, 
     87  void print_general_information(std::ostream& os, const SVNlog& log,
    8888                                 size_t nof_authors, std::string url,
    8989                                 const NodeCounter& node_counter)
    90   { 
     90  {
    9191    assert(log.commits().size());
    92     Date begin(log.commits().begin()->date());   
     92    Date begin(log.commits().begin()->date());
    9393    Date end(log.latest_commit().date());
    9494    std::string timefmt("%a %b %e %H:%M:%S %Y");
    9595
    96     os << "<div class=\"main\">" 
    97        << "<table class=\"main\"><thead><tr><th colspan=\"2\">" 
     96    os << "<div class=\"main\">"
     97       << "<table class=\"main\"><thead><tr><th colspan=\"2\">"
    9898       << "General Information"
    9999       << "</th></tr></thead>\n"
    100100       << "<tbody>\n"
    101        << "<tr><td>URL:</td><td>"; 
     101       << "<tr><td>URL:</td><td>";
    102102    if (url.size()>=4 && url.substr(0,4)=="http")
    103103      os << anchor(url, url);
     
    105105      os << url;
    106106    os << "</td></tr>\n"
    107        << "<tr><td>First Revision Date:</td><td>" 
     107       << "<tr><td>First Revision Date:</td><td>"
    108108       << begin(timefmt) << "</td></tr>\n"
    109        << "<tr><td>Latest Revision Date:</td><td>" 
     109       << "<tr><td>Latest Revision Date:</td><td>"
    110110       << end(timefmt) << "</td></tr>\n"
    111        << "<tr><td>Age:</td><td>"; 
     111       << "<tr><td>Age:</td><td>";
    112112    os << end.difftime(begin);
    113113    os << "</td></tr>\n"
    114        << "<tr><td>Smallest Revision:</td><td>" 
    115        << log.commits().begin()->revision() 
    116        << "</td></tr>\n"
    117        << "<tr><td>Largest Revision:</td><td>" << log.latest_commit().revision() 
    118        << "</td></tr>\n"
    119        << "<tr><td>Revision Count:</td><td>" << log.commits().size() 
     114       << "<tr><td>Smallest Revision:</td><td>"
     115       << log.commits().begin()->revision()
     116       << "</td></tr>\n"
     117       << "<tr><td>Largest Revision:</td><td>" << log.latest_commit().revision()
     118       << "</td></tr>\n"
     119       << "<tr><td>Revision Count:</td><td>" << log.commits().size()
    120120       << "</td></tr>\n"
    121121       << "<tr><td>Number of Authors:</td><td>" << nof_authors
    122122       << "</td></tr>\n"
    123        << "<tr><td>Number of Directories:</td><td>" 
     123       << "<tr><td>Number of Directories:</td><td>"
    124124       << node_counter.directories()
    125125       << "</td></tr>\n"
    126        << "<tr><td>Number of Files:</td><td>" 
     126       << "<tr><td>Number of Files:</td><td>"
    127127       << node_counter.files()
    128128       << "</td></tr>\n"
     
    132132
    133133
    134   void print_authors(std::ostream& os, 
     134  void print_authors(std::ostream& os,
    135135                     const std::vector<Commitment>& lc,
    136136                     const Stats& stats)
     
    138138    HtmlStream hs(os);
    139139    os << "<div class=\"main\">"
    140        << "<table class=\"main\"><thead><tr><th colspan=\"2\">" 
     140       << "<table class=\"main\"><thead><tr><th colspan=\"2\">"
    141141       << "Authors"
    142142       << "</th></tr></thead>\n";
    143143
    144     os << "<tr><td>Author</td>" 
     144    os << "<tr><td>Author</td>"
    145145       << "<td>Number of Lines</td>"
    146146       << "<td>Code Lines</td>"
     
    152152    using namespace std;
    153153    for (vector<Commitment>::const_iterator i=lc.begin(); i!=lc.end(); ++i) {
    154       os << "<tr><td>"; 
     154      os << "<tr><td>";
    155155      if (!stats.lines(i->author()))
    156156        os << i->author();
     
    158158        os << anchor(std::string("classic/"+i->author()+"/total/index.html"),
    159159                     i->author());
    160       os << "</td><td>" << stats.lines(i->author()) << " (" 
     160      os << "</td><td>" << stats.lines(i->author()) << " ("
    161161         << 100*stats.lines(i->author())/(stats.lines()?stats.lines():1)
    162          << "%)</td><td>" << stats.code(i->author()) << " (" 
     162         << "%)</td><td>" << stats.code(i->author()) << " ("
    163163         << 100*stats.code(i->author())/(stats.code()?stats.code():1)
    164          << "%)</td><td>" << stats.comments(i->author()) << " (" 
     164         << "%)</td><td>" << stats.comments(i->author()) << " ("
    165165         << 100*stats.comments(i->author())/(stats.comments()?stats.comments():1)
    166166         << "%)</td><td>";
     
    190190  {
    191191    os << "<div class=\"main\">\n"
    192        << "<table class=\"main\"><thead><tr><th colspan=\"2\">" 
     192       << "<table class=\"main\"><thead><tr><th colspan=\"2\">"
    193193       << "Recent Log"
    194194       << "</th></tr></thead>\n";
     
    202202    typedef SVNlog::container::const_reverse_iterator iter;
    203203    size_t count = 0;
    204     for (iter i=log.commits().rbegin(); 
     204    for (iter i=log.commits().rbegin();
    205205         i != log.commits().rend() && count<10; ++i) {
    206       os << "<tr><td>" 
     206      os << "<tr><td>"
    207207         << anchor(std::string("classic/")+i->author()+"/total/index.html",
    208                    i->author()) 
     208                   i->author())
    209209         << "</td>";
    210210      Date date(i->date());
    211211      os << "<td>";
    212       hs << date(timefmt); 
    213       os << "</td>";
    214       os << "<td>"; 
     212      hs << date(timefmt);
     213      os << "</td>";
     214      os << "<td>";
    215215      os << trac_revision(i->revision());
    216216      os << "</td>";
    217217      os << "<td>";
    218218      int added = stats["add"](LineTypeParser::total, "all", i->revision()) -
    219         stats["add"](LineTypeParser::total, "all", i->revision() - 1); 
     219        stats["add"](LineTypeParser::total, "all", i->revision() - 1);
    220220      os << added;
    221221      os << "</td>";
    222222      os << "<td>";
    223223      os << added-(stats["blame"](LineTypeParser::total, "all", i->revision()) -
    224                    stats["blame"](LineTypeParser::total,"all",i->revision()-1)); 
     224                   stats["blame"](LineTypeParser::total,"all",i->revision()-1));
    225225      os << "</td>";
    226226      os << "<td>";
Note: See TracChangeset for help on using the changeset viewer.