summaryrefslogtreecommitdiffstats
path: root/quanta/parsers/parser.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-09 02:23:29 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-09 02:23:29 +0000
commit929d7ae4f69d62b8f1f6d3506adf75f017753935 (patch)
tree21652db5723e70ded94f724015e77d96e42c83b9 /quanta/parsers/parser.cpp
parenta40b0e89b6b20ba9039d3f79e73afbeac6954ccb (diff)
downloadtdewebdev-929d7ae4f69d62b8f1f6d3506adf75f017753935.tar.gz
tdewebdev-929d7ae4f69d62b8f1f6d3506adf75f017753935.zip
Remove the tq in front of these incorrectly TQt4-converted methods/data members:
tqrepaint[...] tqinvalidate[...] tqparent[...] tqmask[...] tqlayout[...] tqalignment[...] git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdewebdev@1240522 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'quanta/parsers/parser.cpp')
-rw-r--r--quanta/parsers/parser.cpp92
1 files changed, 46 insertions, 46 deletions
diff --git a/quanta/parsers/parser.cpp b/quanta/parsers/parser.cpp
index 0a9441db..c795f11e 100644
--- a/quanta/parsers/parser.cpp
+++ b/quanta/parsers/parser.cpp
@@ -115,11 +115,11 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
bool nodeFound = false;
bool goUp;
Node *rootNode = 0L;
- Node *tqparentNode = a_node;
+ Node *parentNode = a_node;
Node *currentNode = a_node;
if (currentNode && (currentNode->tag->type != Tag::XmlTag ||
currentNode->tag->single))
- tqparentNode = currentNode->tqparent;
+ parentNode = currentNode->tqparent;
Tag *tag = 0L;
TQTag *qTag = 0L;
textLine.append(write->text(startLine, startCol, startLine, write->editIf->lineLength(startLine)));
@@ -144,13 +144,13 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
if ( specialStartPos != -1 &&
(specialStartPos <= tagStartPos || tagStartPos == -1) )
{
- currentNode = ParserCommon::createTextNode(write, currentNode, line, specialStartPos, tqparentNode);
+ currentNode = ParserCommon::createTextNode(write, currentNode, line, specialStartPos, parentNode);
if (!rootNode)
rootNode = currentNode;
TQString foundText = m_dtd->specialAreaStartRx.cap();
//create a toplevel node for the special area
AreaStruct area(line, specialStartPos, line, specialStartPos + foundText.length() - 1);
- Node *node = ParserCommon::createScriptTagNode(write, area, foundText, m_dtd, tqparentNode, currentNode);
+ Node *node = ParserCommon::createScriptTagNode(write, area, foundText, m_dtd, parentNode, currentNode);
if (node->tqparent && node->prev == node->tqparent) //some strange cases, but it's possible, eg.: <a href="<? foo ?>""></a><input size="<? foo ?>" >
{
node->prev->next = 0L;
@@ -266,18 +266,18 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
if (m_dtd->specialTags.tqcontains(tag->name.lower()) && !tag->single)
{
//TODO: handle goUp here
- Node *node = new Node(tqparentNode);
+ Node *node = new Node(parentNode);
nodeNum++;
node->tag = tag;
node->insideSpecial = true;
- if (currentNode && currentNode != tqparentNode)
+ if (currentNode && currentNode != parentNode)
{
currentNode->next = node;
node->prev = currentNode;
} else
{
- if (tqparentNode)
- tqparentNode->child = node;
+ if (parentNode)
+ parentNode->child = node;
}
if (!rootNode)
rootNode = node;
@@ -315,21 +315,21 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
}
qTag = 0L;
- goUp = ( tqparentNode &&
- ( (tag->type == Tag::XmlTagEnd && QuantaCommon::closesTag(tqparentNode->tag, tag)
+ goUp = ( parentNode &&
+ ( (tag->type == Tag::XmlTagEnd && QuantaCommon::closesTag(parentNode->tag, tag)
) ||
- tqparentNode->tag->single )
+ parentNode->tag->single )
);
- if (tqparentNode && !goUp)
+ if (parentNode && !goUp)
{
- qTag = QuantaCommon::tagFromDTD(m_dtd, tqparentNode->tag->name);
+ qTag = QuantaCommon::tagFromDTD(m_dtd, parentNode->tag->name);
if ( qTag )
{
TQString searchFor = (m_dtd->caseSensitive)?tag->name:tag->name.upper();
searchFor.remove('/');
if ( qTag->stoppingTags.tqcontains(searchFor))
{
- tqparentNode->tag->closingMissing = true; //tqparent is single...
+ parentNode->tag->closingMissing = true; //tqparent is single...
goUp = true;
}
}
@@ -340,9 +340,9 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
if (nodeFound)
{
//first create a text/empty node between the current position and the last node
- Node *savedParentNode = tqparentNode;
- currentNode = ParserCommon::createTextNode(write, currentNode, tagStartLine, tagStartPos, tqparentNode);
- if (savedParentNode != tqparentNode)
+ Node *savedParentNode = parentNode;
+ currentNode = ParserCommon::createTextNode(write, currentNode, tagStartLine, tagStartPos, parentNode);
+ if (savedParentNode != parentNode)
goUp = false;
if (!rootNode)
rootNode = currentNode;
@@ -351,19 +351,19 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
if (goUp)
{
//handle cases like <ul><li></ul>
- if (tag->type == Tag::XmlTagEnd && !QuantaCommon::closesTag(tqparentNode->tag, tag))
+ if (tag->type == Tag::XmlTagEnd && !QuantaCommon::closesTag(parentNode->tag, tag))
{
- while ( tqparentNode->tqparent &&
- QuantaCommon::closesTag(tqparentNode->tqparent->tag, tag)
+ while ( parentNode->tqparent &&
+ QuantaCommon::closesTag(parentNode->tqparent->tag, tag)
)
{
- tqparentNode = tqparentNode->tqparent;
+ parentNode = parentNode->tqparent;
}
} else
if (qTag && tag->type != Tag::XmlTagEnd)
{
//handle the case when a tag is a stopping tag for tqparent, and grandtqparent and so on.
- Node *n = tqparentNode;
+ Node *n = parentNode;
TQString searchFor = (m_dtd->caseSensitive)?tag->name:tag->name.upper();
while (qTag && n)
{
@@ -374,7 +374,7 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
{
n->tag->closingMissing = true; //tqparent is single...
if (n->tqparent)
- tqparentNode = n;
+ parentNode = n;
n = n->tqparent;
} else
{
@@ -384,29 +384,29 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
}
}
- node = new Node(tqparentNode->tqparent);
+ node = new Node(parentNode->tqparent);
nodeNum++;
- node->prev = tqparentNode;
- tqparentNode->next = node;
- tqparentNode = tqparentNode->tqparent;
+ node->prev = parentNode;
+ parentNode->next = node;
+ parentNode = parentNode->tqparent;
node->closesPrevious = true;
} else
{
- node = new Node(tqparentNode);
+ node = new Node(parentNode);
nodeNum++;
- if (currentNode && currentNode != tqparentNode)
+ if (currentNode && currentNode != parentNode)
{
currentNode->next = node;
node->prev = currentNode;
} else
{
- if (tqparentNode)
+ if (parentNode)
{
- if (!tqparentNode->child)
- tqparentNode->child = node;
+ if (!parentNode->child)
+ parentNode->child = node;
else
{
- Node *n = tqparentNode->child;
+ Node *n = parentNode->child;
while (n->next)
n = n->next;
n->next = node;
@@ -416,7 +416,7 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
}
}
if (!tag->single)
- tqparentNode = node;
+ parentNode = node;
node->tag = tag;
if (tag->type == Tag::NeedsParsing)
@@ -467,7 +467,7 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
#endif
cleanGroups();
m_saParser->setParsingEnabled(true);
- currentNode = m_saParser->parseArea(area, "", "", tqparentNode, true, true); //TODO: don't parse in detail here
+ currentNode = m_saParser->parseArea(area, "", "", parentNode, true, true); //TODO: don't parse in detail here
m_saParser->setParsingEnabled(false);
el = m_saParser->lastParsedLine();
ec = m_saParser->lastParsedColumn();
@@ -484,16 +484,16 @@ Node *Parser::parseArea(int startLine, int startCol, int endLine, int endCol, No
el = endLine;
ec = endCol + 1;
}
- currentNode = ParserCommon::createTextNode(write, currentNode, el, ec, tqparentNode);
+ currentNode = ParserCommon::createTextNode(write, currentNode, el, ec, parentNode);
} else
if (el != endLine || ec != endCol)
{
if (currentNode && currentNode->tag->type == Tag::ScriptTag)
{
- tqparentNode = currentNode;
+ parentNode = currentNode;
currentNode = 0L;
}
- currentNode = ParserCommon::createTextNode(write, currentNode, endLine, endCol, tqparentNode);
+ currentNode = ParserCommon::createTextNode(write, currentNode, endLine, endCol, parentNode);
}
if (!rootNode)
rootNode = currentNode;
@@ -623,9 +623,9 @@ Node *Parser::nodeAt(int line, int col, bool findDeepest, bool exact)
{
if (node->tqparent)
{
- int tqparentEl, tqparentEc;
- node->tqparent->tag->endPos(tqparentEl, tqparentEc);
- if (!exact && QuantaCommon::isBetween(line, col, bl, bc, tqparentEl, tqparentEc) == 0)
+ int parentEl, parentEc;
+ node->tqparent->tag->endPos(parentEl, parentEc);
+ if (!exact && QuantaCommon::isBetween(line, col, bl, bc, parentEl, parentEc) == 0)
{
node = node->tqparent;
}
@@ -1563,14 +1563,14 @@ void Parser::parseIncludedFile(const TQString& fileName, const DTDStruct *dtd)
node->fileName = fileName;
GroupElement *groupElement = new GroupElement;
groupElement->node = node;
- groupElement->tqparentNode = 0L;
+ groupElement->parentNode = 0L;
int minPos = areaPos + pos + 1;
for (TQValueList<GroupElementPosition>::Iterator gPosIt = gPositions.begin(); gPosIt != gPositions.end(); ++gPosIt)
{
GroupElementPosition gPos = (*gPosIt);
if ( (areaPos + pos > gPos.startPos) && (areaPos + pos < gPos.endPos) && (gPos.startPos < minPos))
{
- groupElement->tqparentNode = gPos.element->node;
+ groupElement->parentNode = gPos.element->node;
minPos = gPos.startPos;
}
}
@@ -1588,8 +1588,8 @@ void Parser::parseIncludedFile(const TQString& fileName, const DTDStruct *dtd)
TQTag *qTag = new TQTag();
qTag->setName(s.left(s.tqfind('(')));
qTag->className = "";
- if (groupElement->tqparentNode)
- qTag->className = groupElement->tqparentNode->tag->name;
+ if (groupElement->parentNode)
+ qTag->className = groupElement->parentNode->tag->name;
write->userTagList.tqreplace(s.lower(), qTag);
}
}
@@ -1658,7 +1658,7 @@ void Parser::parseForXMLGroup(Node *node)
groupElement->deleted = false;
groupElement->tag = newTag;
groupElement->node = node;
- groupElement->tqparentNode = 0L;
+ groupElement->parentNode = 0L;
groupElement->global = true;
groupElement->group = const_cast<XMLStructGroup*>(&(xmlGroupIt.data()));
node->m_groupElements.append(groupElement);