Ignore:
Timestamp:
02/07/16 23:21:55 (4 years ago)
Author:
Maciej Komosinski
Message:

GenMan? interface uses STL std::string instead of SString

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpp/frams/genetics/genman.cpp

    r391 r467  
    395395}
    396396
    397 SString GenMan::HTMLize(const char *g) { return HTMLize(g, false); }
    398 
    399 SString GenMan::HTMLizeShort(const char *g) { return HTMLize(g, true); }
    400 
    401 SString GenMan::HTMLize(const char *g, bool shorten)
     397string GenMan::HTMLize(const char *g) { return HTMLize(g, false); }
     398
     399string GenMan::HTMLizeShort(const char *g) { return HTMLize(g, true); }
     400
     401string GenMan::HTMLize(const char *g, bool shorten)
    402402{
    403403        char buf[50];
     
    407407        uint32_t *styletab = new uint32_t[len];
    408408        GetFullStyle(g, styletab);
    409         SString html = "\n<div style=\"background:white;padding:0.2em;font-family:arial,helvetica,sans-serif;font-size:90%\">";
     409        string html = "\n<div style=\"background:white;padding:0.2em;font-family:arial,helvetica,sans-serif;font-size:90%\">";
    410410        uint32_t prevstyle, prevcolor, style = 0, color = 0;
    411411        for (int i = 0; i<len; i++)
     
    448448void GenMan::p_htmlize(ExtValue *args, ExtValue *ret)
    449449{
    450         ret->setString(HTMLize(args->getString().c_str()));
     450        ret->setString(HTMLize(args->getString().c_str()).c_str());
    451451}
    452452
    453453void GenMan::p_htmlizeshort(ExtValue *args, ExtValue *ret)
    454454{
    455         ret->setString(HTMLizeShort(args->getString().c_str()));
     455        ret->setString(HTMLizeShort(args->getString().c_str()).c_str());
    456456}
    457457
Note: See TracChangeset for help on using the changeset viewer.