1.1 --- a/api.cpp Tue Oct 24 15:36:38 2006 +0000
1.2 +++ b/api.cpp Thu Nov 16 10:07:11 2006 +0000
1.3 @@ -197,19 +197,19 @@
1.4 // a variable later
1.5 QString r;
1.6 ok=true;
1.7 - /*
1.8 - QRegExp re("\"(.*)\"");
1.9 - int pos=re.search (paramList[index]);
1.10 - if (pos>=0)
1.11 - r=re.cap (1);
1.12 - else
1.13 - r="";
1.14 - */
1.15 - if (paramList[index]=="true")
1.16 + QString p=paramList[index];
1.17 + if (p=="true" || p=="1")
1.18 return true;
1.19 - else if (paramList[index]=="false")
1.20 + else if (p=="false" || p=="0")
1.21 return false;
1.22 ok=false;
1.23 return ok;
1.24 }
1.25
1.26 +QColor API::parColor(bool &ok,const int &index)
1.27 +{
1.28 + // return the QColor at index
1.29 + ok=true;
1.30 + return QColor (paramList[index]);
1.31 +}
1.32 +