summaryrefslogtreecommitdiffstats
path: root/klinkstatus/src/parser
diff options
context:
space:
mode:
Diffstat (limited to 'klinkstatus/src/parser')
-rw-r--r--klinkstatus/src/parser/htmlparser.cpp8
-rw-r--r--klinkstatus/src/parser/http.cpp8
-rw-r--r--klinkstatus/src/parser/mstring.cpp8
-rw-r--r--klinkstatus/src/parser/node.cpp16
-rw-r--r--klinkstatus/src/parser/node_impl.h4
-rw-r--r--klinkstatus/src/parser/url.cpp2
6 files changed, 23 insertions, 23 deletions
diff --git a/klinkstatus/src/parser/htmlparser.cpp b/klinkstatus/src/parser/htmlparser.cpp
index ebe8e362..759553e1 100644
--- a/klinkstatus/src/parser/htmlparser.cpp
+++ b/klinkstatus/src/parser/htmlparser.cpp
@@ -131,11 +131,11 @@ int HtmlParser::endOfTag(TQString const& s, int index, TQChar end_of_tag)
if( (uint)index >= s.length() )
return -1;
- int _end_of_tag = s.tqfind(end_of_tag, index);
+ int _end_of_tag = s.find(end_of_tag, index);
if(_end_of_tag == -1)
return _end_of_tag;
- int open_aspas = s.tqfind('"', index);
+ int open_aspas = s.find('"', index);
if(open_aspas == -1)
return _end_of_tag + 1;
@@ -147,7 +147,7 @@ int HtmlParser::endOfTag(TQString const& s, int index, TQChar end_of_tag)
else
{
- int close_aspas = s.tqfind('"', open_aspas + 1);
+ int close_aspas = s.find('"', open_aspas + 1);
if(close_aspas != -1)
return endOfTag(s, close_aspas + 1, end_of_tag);
else
@@ -259,7 +259,7 @@ void HtmlParser::parseNodesOfTypeBASE()
if(inicio == -1 || !doc[inicio].isSpace())
return;
- fim = doc.tqfind(">", inicio);
+ fim = doc.find(">", inicio);
if(fim == -1)
return;
diff --git a/klinkstatus/src/parser/http.cpp b/klinkstatus/src/parser/http.cpp
index 0a62a9a2..6e086739 100644
--- a/klinkstatus/src/parser/http.cpp
+++ b/klinkstatus/src/parser/http.cpp
@@ -34,8 +34,8 @@ void HttpResponseHeader::parseLocation()
int location = findWord(cabecalho, "Location: ");
Q_ASSERT(location != -1);
- int fim_de_linha_1 = cabecalho.tqfind('\n', location);
- int fim_de_linha_2 = cabecalho.tqfind('\r', location);
+ int fim_de_linha_1 = cabecalho.find('\n', location);
+ int fim_de_linha_2 = cabecalho.find('\r', location);
Q_ASSERT(fim_de_linha_1 != -1 || fim_de_linha_2 != -1);
@@ -67,11 +67,11 @@ TQString HttpResponseHeader::charset(TQString const& contentTypeHttpHeaderLine)
if(contentTypeHttpHeaderLine.isEmpty())
return _charset;
- int index = contentTypeHttpHeaderLine.tqfind("charset=");
+ int index = contentTypeHttpHeaderLine.find("charset=");
if(index != -1)
index += TQString("charset=").length();
else {
- index = contentTypeHttpHeaderLine.tqfind("charset:");
+ index = contentTypeHttpHeaderLine.find("charset:");
if(index != -1)
index += TQString("charset:").length();
}
diff --git a/klinkstatus/src/parser/mstring.cpp b/klinkstatus/src/parser/mstring.cpp
index f84c5809..aa2cdec7 100644
--- a/klinkstatus/src/parser/mstring.cpp
+++ b/klinkstatus/src/parser/mstring.cpp
@@ -28,7 +28,7 @@ using namespace std;
int findWord(TQString const& s, TQString const& palavra, uint a_partir_do_indice)
{
- int indice = s.tqfind(palavra, a_partir_do_indice, false);
+ int indice = s.find(palavra, a_partir_do_indice, false);
if(indice == -1)
return indice;
@@ -38,7 +38,7 @@ int findWord(TQString const& s, TQString const& palavra, uint a_partir_do_indice
int findChar(TQString const& s, TQChar letra, uint a_partir_do_indice)
{
- int index = s.tqfind(letra, a_partir_do_indice, false);
+ int index = s.find(letra, a_partir_do_indice, false);
if(index == -1)
return index;
else
@@ -173,7 +173,7 @@ vector<TQString> tokenizeWordsSeparatedByDots(TQString s)
if(inicio == -1)
return v;
- int fim = s.tqfind('.', inicio);
+ int fim = s.find('.', inicio);
if(fim == -1)
{
v.push_back(s.mid(inicio));
@@ -200,7 +200,7 @@ vector<TQString> tokenizeWordsSeparatedBy(TQString s, TQChar criteria)
if(inicio == -1)
return v;
- int fim = s.tqfind(criteria, inicio);
+ int fim = s.find(criteria, inicio);
if(fim == -1)
{
v.push_back(s.mid(inicio));
diff --git a/klinkstatus/src/parser/node.cpp b/klinkstatus/src/parser/node.cpp
index ad5ce064..f83031c8 100644
--- a/klinkstatus/src/parser/node.cpp
+++ b/klinkstatus/src/parser/node.cpp
@@ -39,19 +39,19 @@ TQString Node::getAttribute(TQString const& atributo)
{
if(content_[inicio] == '"')
{
- fim = content_.tqfind("\"", inicio + 1);
+ fim = content_.find("\"", inicio + 1);
tem_aspas_ou_plicas = true;
}
else if(content_[inicio] == '\'')
{
- fim = content_.tqfind("'", inicio + 1);
+ fim = content_.find("'", inicio + 1);
tem_aspas_ou_plicas = true;
}
else
{
int fim_bloco = nextSpaceChar(content_, inicio + 1);
- int fim_tag = content_.tqfind(">", inicio + 1);
- int fim_aspas = content_.tqfind("\"", inicio + 1);
+ int fim_tag = content_.find(">", inicio + 1);
+ int fim_aspas = content_.find("\"", inicio + 1);
if(fim_bloco == -1 && fim_tag == -1 && fim_aspas == -1)
{
@@ -137,7 +137,7 @@ void NodeLink::parseLinkLabel()
do
{
- fim_tag = content_.tqfind(">", fim_tag);
+ fim_tag = content_.find(">", fim_tag);
if(fim_tag != -1)
proximo_caractere = TQChar(content_[++fim_tag]);
@@ -147,7 +147,7 @@ void NodeLink::parseLinkLabel()
if(fim_tag != -1)
{
- int fim_label = content_.tqfind("<", fim_tag);
+ int fim_label = content_.find("<", fim_tag);
if(fim_label != -1)
{
@@ -183,7 +183,7 @@ void NodeMETA::parseAttributeURL()
int aspas = -1;
do
{
- aspas = attribute_url_.tqfind("\"");
+ aspas = attribute_url_.find("\"");
if(aspas != -1)
attribute_url_.remove(aspas, 1);
}
@@ -206,7 +206,7 @@ TQString NodeMETA::charset() const
if(content.isEmpty())
return charset;
- int index = content.tqfind("charset=");
+ int index = content.find("charset=");
if(index != -1)
{
index += TQString("charset=").length();
diff --git a/klinkstatus/src/parser/node_impl.h b/klinkstatus/src/parser/node_impl.h
index f1ebed13..bd62104b 100644
--- a/klinkstatus/src/parser/node_impl.h
+++ b/klinkstatus/src/parser/node_impl.h
@@ -404,8 +404,8 @@ inline TQString const& NodeTITLE::attributeTITLE() const
inline void NodeTITLE::parseAttributeTITLE()
{
attribute_title_ = content_;
- attribute_title_.tqreplace("<TITLE>", "", false);
- attribute_title_.tqreplace("</TITLE>", "", false);
+ attribute_title_.replace("<TITLE>", "", false);
+ attribute_title_.replace("</TITLE>", "", false);
attribute_title_.stripWhiteSpace();
//kdDebug(23100) << "TITLE: " << attribute_title_ << endl;
diff --git a/klinkstatus/src/parser/url.cpp b/klinkstatus/src/parser/url.cpp
index 173c734b..90a6e4e6 100644
--- a/klinkstatus/src/parser/url.cpp
+++ b/klinkstatus/src/parser/url.cpp
@@ -39,7 +39,7 @@ Node::LinkType Url::resolveLinkType(TQString const& url)
return Node::file_href;
else if(findWord(KCharsets::resolveEntities(url), "MAILTO:") != -1)
return Node::mailto;
- else if( (int)url.tqfind(":/") != -1)
+ else if( (int)url.find(":/") != -1)
return Node::href;
else
return Node::relative;