summaryrefslogtreecommitdiffstats
path: root/kommander/plugin
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
commit36c36b53a129509d56fdaa0a7c9fcbcacd0c5826 (patch)
tree629d3942958745660e36c30b0d6139af9459c0f8 /kommander/plugin
parent929d7ae4f69d62b8f1f6d3506adf75f017753935 (diff)
downloadtdewebdev-36c36b53a129509d56fdaa0a7c9fcbcacd0c5826.tar.gz
tdewebdev-36c36b53a129509d56fdaa0a7c9fcbcacd0c5826.zip
rename the following methods:
tqfind find tqreplace replace tqcontains contains git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdewebdev@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kommander/plugin')
-rw-r--r--kommander/plugin/specialinformation.cpp36
-rw-r--r--kommander/plugin/specials.h2
2 files changed, 19 insertions, 19 deletions
diff --git a/kommander/plugin/specialinformation.cpp b/kommander/plugin/specialinformation.cpp
index 75faf9e0..a653dfd6 100644
--- a/kommander/plugin/specialinformation.cpp
+++ b/kommander/plugin/specialinformation.cpp
@@ -22,8 +22,8 @@ SpecialFunction::SpecialFunction(const TQString& name, const TQString& descripti
int minArgs, int maxArgs)
{
m_parserTypes = AllParsers;
- int lbracket = name.tqfind('(');
- int rbracket = name.tqfind(')');
+ int lbracket = name.find('(');
+ int rbracket = name.find(')');
m_function = (lbracket != -1) ? name.left(lbracket) : name;
m_description = description;
if (lbracket != -1 && rbracket != -1)
@@ -44,8 +44,8 @@ SpecialFunction::SpecialFunction(ParserType p, const TQString& name, const TQStr
int minArgs, int maxArgs)
{
m_parserTypes = p;
- int lbracket = name.tqfind('(');
- int rbracket = name.tqfind(')');
+ int lbracket = name.find('(');
+ int rbracket = name.find(')');
m_function = (lbracket != -1) ? name.left(lbracket) : name;
m_description = description;
if (lbracket != -1 && rbracket != -1)
@@ -107,9 +107,9 @@ int SpecialFunction::argumentCount() const
int SpecialInformation::function(int group, const TQString& fname)
{
TQString f = fname.lower();
- if (m_functions.tqcontains(group) && m_functions[group].tqcontains(f))
+ if (m_functions.contains(group) && m_functions[group].contains(f))
return m_functions[group][f];
- else if (m_aliases.tqcontains(group) && m_aliases[group].tqcontains(f))
+ else if (m_aliases.contains(group) && m_aliases[group].contains(f))
return m_aliases[group][f];
return -1;
}
@@ -122,14 +122,14 @@ SpecialFunction SpecialInformation::functionObject(const TQString& gname, const
int SpecialInformation::group(const TQString& gname)
{
- if (m_groups.tqcontains(gname))
+ if (m_groups.contains(gname))
return m_groups[gname];
return -1;
}
bool SpecialInformation::isValid(int gname, int fname)
{
- return m_specials.tqcontains(gname) && m_specials[gname].tqcontains(fname);
+ return m_specials.contains(gname) && m_specials[gname].contains(fname);
}
bool SpecialInformation::isValid(const TQString& gname, const TQString& fname)
@@ -139,7 +139,7 @@ bool SpecialInformation::isValid(const TQString& gname, const TQString& fname)
bool SpecialInformation::isValid(int gname, int fname, SpecialFunction::ParserType p)
{
- return m_specials.tqcontains(gname) && m_specials[gname].tqcontains(fname)
+ return m_specials.contains(gname) && m_specials[gname].contains(fname)
&& m_specials[gname][fname].isSupported(p);
}
@@ -198,9 +198,9 @@ bool SpecialInformation::insert(int id, const TQString& function, const TQString
{
if (isValid(m_defaultGroup, id)) /* function already defined */
return false;
- if (m_functions[m_defaultGroup].tqcontains(function.lower()))
+ if (m_functions[m_defaultGroup].contains(function.lower()))
return false; /* function name already in use */
- if (m_aliases[m_defaultGroup].tqcontains(function.lower()))
+ if (m_aliases[m_defaultGroup].contains(function.lower()))
return false; /* function name already in use */
SpecialFunction sf(pType, function, description, minArgs, maxArgs);
m_specials[m_defaultGroup][id] = sf;
@@ -224,9 +224,9 @@ bool SpecialInformation::insertAlias(int id, const TQString& alias)
{
if (!isValid(m_defaultGroup, id)) /* function doesn't exists */
return false;
- if (m_functions[m_defaultGroup].tqcontains(alias.lower()))
+ if (m_functions[m_defaultGroup].contains(alias.lower()))
return false;
- if (m_aliases[m_defaultGroup].tqcontains(alias.lower()))
+ if (m_aliases[m_defaultGroup].contains(alias.lower()))
return false;
m_aliases[m_defaultGroup][alias] = id;
return true;
@@ -248,7 +248,7 @@ void SpecialInformation::insertGroup(int id, const TQString& name, const TQStrin
TQString SpecialInformation::parserGroupName(const TQString& name)
{
- if (m_parserGroups.tqcontains(name))
+ if (m_parserGroups.contains(name))
return m_parserGroups[name];
else
return name;
@@ -524,11 +524,11 @@ void SpecialInformation::registerSpecials()
insertGroup(Group::String, "String", "str");
insert(String::length, "length(TQString string)",
i18n("Returns number of chars in the string."), 1);
- insert(String::tqcontains, "tqcontains(TQString string, TQString substring)",
+ insert(String::contains, "contains(TQString string, TQString substring)",
i18n("Checks if the the string contains the given substring."), 2);
- insert(String::tqfind, "tqfind(TQString string, TQString sought, int index)",
+ insert(String::find, "find(TQString string, TQString sought, int index)",
i18n("Returns the position of a substring in the string, or -1 if it is not found."), 2);
- insert(String::tqfindRev, "tqfindRev(TQString string, TQString sought, int index)",
+ insert(String::findRev, "findRev(TQString string, TQString sought, int index)",
i18n("Returns the position of a substring in the string, or -1 if it is not found. String is searched backwards"), 2);
insertInternal(String::count, "count(TQString String, TQString substring)",
i18n("Returns the count of a given substring in the given string."), 2);
@@ -540,7 +540,7 @@ void SpecialInformation::registerSpecials()
i18n("Returns <i>n</i> chars of the string, starting from <i>start</i>."), 3);
insert(String::remove, "remove(TQString string, TQString substring)",
i18n("Removes all occurrences of given substring."), 2);
- insert(String::tqreplace, "tqreplace(TQString string, TQString substring, TQString replacement)",
+ insert(String::replace, "replace(TQString string, TQString substring, TQString replacement)",
i18n("Replaces all occurrences of the given substring with the given replacement."), 3);
insert(String::upper, "upper(TQString string)",
i18n("Converts the string to uppercase."), 1);
diff --git a/kommander/plugin/specials.h b/kommander/plugin/specials.h
index e6e9cf94..793f44dc 100644
--- a/kommander/plugin/specials.h
+++ b/kommander/plugin/specials.h
@@ -55,7 +55,7 @@ namespace Matrix
namespace String
{
- enum {length, tqcontains, tqfind, tqfindRev, left, right, mid, remove, tqreplace, upper, lower,
+ enum {length, contains, find, findRev, left, right, mid, remove, replace, upper, lower,
compare, isEmpty, isNumber, section, args, toInt, toDouble, round, sort, trim, padLeft, padRight, count};
}