Changeset 10496 for trunk/FACT++/src


Ignore:
Timestamp:
04/29/11 13:06:49 (14 years ago)
Author:
tbretz
Message:
Removed usage of Tools::Form.
Location:
trunk/FACT++/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/Console.cc

    r10429 r10496  
    133133{
    134134    const string siz = fLogO.GetSizeStr();
    135     return fContinous ?
    136         Tools::Form("[%d]",    GetLine()) :
    137         Tools::Form("[%d:%s]", GetLine(), siz.c_str());
     135
     136    string rc = "[";
     137    rc += GetLine();
     138    return fContinous ? rc+']' : rc+':'+siz+']';
    138139}
    139140
  • trunk/FACT++/src/Readline.cc

    r10485 r10496  
    536536string Readline::GetLinePrompt() const
    537537{
    538     return Tools::Form("[%d]", fLine);
     538    string rc = "[";
     539    rc += fLine;
     540    return rc+"]";
    539541}
    540542
  • trunk/FACT++/src/ReadlineWindow.cc

    r10429 r10496  
    290290
    291291    // Compile a proper format string
    292     const string fmt = Tools::Form("%%-%ds", max);
     292    string fmt = "%-";
     293    fmt += max;
     294    fmt + 's';
    293295
    294296    // loop over all entries and display them
  • trunk/FACT++/src/StateMachineImp.cc

    r10490 r10496  
    712712{
    713713    const StateNames::const_iterator i = fStateNames.find(state);
    714     return i==fStateNames.end() || i->second.first.empty() ? Tools::Form("%d", state) : i->second.first;
     714
     715    string rc;
     716    rc += state;
     717    return i==fStateNames.end() || i->second.first.empty() ? rc : i->second.first;
    715718}
    716719
     
    748751{
    749752    const string &str = GetStateName(state);
    750     if (str==Tools::Form("%d", state))
     753
     754    string s;
     755    s += state;
     756    if (str==s)
    751757        return str;
    752     return str.empty() ? Tools::Form("%d", state) : (str+Tools::Form("[%d]", state));
     758
     759    return str.empty() ? s : (str+'['+s+']');
    753760}
    754761
  • trunk/FACT++/src/WindowLog.cc

    r10429 r10496  
    273273        u = 'M';
    274274    }
    275     return Tools::Form("%d%c", s, u);
     275
     276    string rc;
     277    rc += s;
     278    return rc + u;
    276279}
    277280
Note: See TracChangeset for help on using the changeset viewer.