summaryrefslogtreecommitdiffstats
path: root/quanta/parsers
diff options
context:
space:
mode:
Diffstat (limited to 'quanta/parsers')
-rw-r--r--quanta/parsers/dtd/dtepcreationdlg.ui2
-rw-r--r--quanta/parsers/node.h4
-rw-r--r--quanta/parsers/parser.cpp92
-rw-r--r--quanta/parsers/parsercommon.cpp42
-rw-r--r--quanta/parsers/parsercommon.h6
-rw-r--r--quanta/parsers/qtag.cpp16
-rw-r--r--quanta/parsers/qtag.h6
-rw-r--r--quanta/parsers/sagroupparser.cpp14
-rw-r--r--quanta/parsers/saparser.cpp50
-rw-r--r--quanta/parsers/saparser.h6
-rw-r--r--quanta/parsers/tag.cpp6
11 files changed, 122 insertions, 122 deletions
diff --git a/quanta/parsers/dtd/dtepcreationdlg.ui b/quanta/parsers/dtd/dtepcreationdlg.ui
index adaeabc4..db29d504 100644
--- a/quanta/parsers/dtd/dtepcreationdlg.ui
+++ b/quanta/parsers/dtd/dtepcreationdlg.ui
@@ -148,5 +148,5 @@
<tabstop>defaultExtension</tabstop>
<tabstop>caseSensitive</tabstop>
</tabstops>
-<tqlayoutdefaults spacing="6" margin="11"/>
+<layoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/quanta/parsers/node.h b/quanta/parsers/node.h
index ab8e6267..d2007482 100644
--- a/quanta/parsers/node.h
+++ b/quanta/parsers/node.h
@@ -37,7 +37,7 @@ struct GroupElement{
/* The tag which point to the actual place in the node */
Tag *tag;
/*The tqparent node indicating the beginning of a structure */
- Node *tqparentNode;
+ Node *parentNode;
bool global;
bool deleted;
TQString type;
@@ -99,7 +99,7 @@ public:
TQString nodeName();
TQString nodeValue();
void setNodeValue(const TQString &value);
- Node* tqparentNode() {return tqparent;}
+ Node* parentNode() {return tqparent;}
Node* firstChild() {return child;}
Node* lastChild();
Node* DOMpreviousSibling() {return prev;}
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);
diff --git a/quanta/parsers/parsercommon.cpp b/quanta/parsers/parsercommon.cpp
index 8a9a4be5..469bedd6 100644
--- a/quanta/parsers/parsercommon.cpp
+++ b/quanta/parsers/parsercommon.cpp
@@ -78,7 +78,7 @@ void appendAreaToTextNode(Document *write, const AreaStruct &area, Node *node)
node->tag->setTagPosition(bLine, bCol, area.eLine, area.eCol);
}
-Node* createTextNode(Document *write, Node *node, int eLine, int eCol, Node *tqparentNode)
+Node* createTextNode(Document *write, Node *node, int eLine, int eCol, Node *parentNode)
{
Tag *textTag = 0L;
Node *textNode = 0L;
@@ -89,10 +89,10 @@ Node* createTextNode(Document *write, Node *node, int eLine, int eCol, Node *tqp
{
node->tag->endPos(bLine, bCol);
} else
- if (tqparentNode)
- tqparentNode->tag->endPos(bLine, bCol);
- if (tqparentNode)
- dtd = tqparentNode->tag->dtd();
+ if (parentNode)
+ parentNode->tag->endPos(bLine, bCol);
+ if (parentNode)
+ dtd = parentNode->tag->dtd();
eCol--;
if (bLine == 0 && bCol == 0)
bCol = -1;
@@ -110,13 +110,13 @@ Node* createTextNode(Document *write, Node *node, int eLine, int eCol, Node *tqp
textTag->type = Tag::Text;
}
- if (tqparentNode && tqparentNode->tag->single)
+ if (parentNode && parentNode->tag->single)
{
- textNode = new Node(tqparentNode->tqparent);
+ textNode = new Node(parentNode->tqparent);
nodeNum++;
- textNode->prev = tqparentNode;
- tqparentNode->next = textNode;
- tqparentNode = tqparentNode->tqparent;
+ textNode->prev = parentNode;
+ parentNode->next = textNode;
+ parentNode = parentNode->tqparent;
} else
{
if ( node &&
@@ -129,21 +129,21 @@ Node* createTextNode(Document *write, Node *node, int eLine, int eCol, Node *tqp
textTag = 0L;
} else
{
- textNode = new Node(tqparentNode);
+ textNode = new Node(parentNode);
nodeNum++;
- if (node && node != tqparentNode)
+ if (node && node != parentNode)
{
node->next = textNode;
textNode->prev = node;
} else
{
- if (tqparentNode)
+ if (parentNode)
{
- Node *n = tqparentNode->child;
+ Node *n = parentNode->child;
while (n && n->next)
n = n->next;
if (!n)
- tqparentNode->child = textNode;
+ parentNode->child = textNode;
else
{
n->next = textNode;
@@ -163,7 +163,7 @@ Node* createTextNode(Document *write, Node *node, int eLine, int eCol, Node *tqp
}
Node* createScriptTagNode(Document *write, const AreaStruct &area, const TQString &areaName,
- const DTDStruct *dtd, Node *tqparentNode, Node *currentNode)
+ const DTDStruct *dtd, Node *parentNode, Node *currentNode)
{
Tag *tag = new Tag();
tag->setTagPosition(area);
@@ -178,17 +178,17 @@ Node* createScriptTagNode(Document *write, const AreaStruct &area, const TQStrin
tag->type = Tag::ScriptTag;
tag->validXMLTag = false;
- Node *node = new Node(tqparentNode);
+ Node *node = new Node(parentNode);
nodeNum++;
node->tag = tag;
node->insideSpecial = true;
- 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;
diff --git a/quanta/parsers/parsercommon.h b/quanta/parsers/parsercommon.h
index 021541b0..d1c76092 100644
--- a/quanta/parsers/parsercommon.h
+++ b/quanta/parsers/parsercommon.h
@@ -39,16 +39,16 @@ namespace ParserCommon{
/** Appends a text area to a text node. */
void appendAreaToTextNode(Document *write, const AreaStruct &area, Node *node);
/** Creates a text/empty node between node and the provided position */
- Node* createTextNode(Document *write, Node *node, int eLine, int eCol, Node *tqparentNode);
+ Node* createTextNode(Document *write, Node *node, int eLine, int eCol, Node *parentNode);
/** Creates a head node for special areas.
area: the area belonging to this node
areaName: the special area name (type)
dtd: the tqparent DTD
- tqparentNode: the tqparent of the node
+ parentNode: the tqparent of the node
currentNode: the last child of the tqparent, if it exists
*/
Node* createScriptTagNode(Document *write, const AreaStruct &area, const TQString &areaName,
- const DTDStruct *dtd, Node *tqparentNode, Node *currentNode);
+ const DTDStruct *dtd, Node *parentNode, Node *currentNode);
/** Print the doc structure tree to the standard output.
Only for debugging purposes. */
diff --git a/quanta/parsers/qtag.cpp b/quanta/parsers/qtag.cpp
index d31f91b8..6a98c3b1 100644
--- a/quanta/parsers/qtag.cpp
+++ b/quanta/parsers/qtag.cpp
@@ -24,7 +24,7 @@ TQTag::TQTag()
single = false;
optional = false;
type = "xmltag";
- tqparentDTD = 0L;
+ parentDTD = 0L;
}
TQTag::TQTag( TQTag &t)
@@ -33,7 +33,7 @@ TQTag::TQTag( TQTag &t)
single = t.single;
optional = t.optional;
m_fileName = t.m_fileName;
- tqparentDTD = t.tqparentDTD;
+ parentDTD = t.parentDTD;
type = t.type;
returnType = t.returnType;
comment = t.comment;
@@ -105,7 +105,7 @@ bool TQTag::isAttribute(const TQString &attrName)
//Check in the common attributes
for(i = 0; i < (signed)commonGroups.count(); i++)
{
- groupAttrs = tqparentDTD->commonAttrs->tqfind(commonGroups[i]);
+ groupAttrs = parentDTD->commonAttrs->tqfind(commonGroups[i]);
if(groupAttrs)
{
for(a = groupAttrs->first(); a; a = groupAttrs->next())
@@ -136,7 +136,7 @@ void TQTag::setName(const TQString& theName)
/** No descriptions */
TQString TQTag::name(bool doNotConvert)
{
- if (doNotConvert || !tqparentDTD || tqparentDTD->caseSensitive)
+ if (doNotConvert || !parentDTD || parentDTD->caseSensitive)
return tagName;
else
return tagName.upper();
@@ -169,7 +169,7 @@ TQTag TQTag::operator = (TQTag &t)
single = t.single;
optional = t.optional;
m_fileName = t.m_fileName;
- tqparentDTD = t.tqparentDTD;
+ parentDTD = t.parentDTD;
type = t.type;
returnType = t.returnType;
comment = t.comment;
@@ -204,7 +204,7 @@ Attribute* TQTag::attribute(const TQString& name)
bool TQTag::isChild(const TQString& tag, bool trueIfNoChildsDefined)
{
TQString tagName = tag;
- tagName = tqparentDTD->caseSensitive ? tagName : tagName.upper();
+ tagName = parentDTD->caseSensitive ? tagName : tagName.upper();
if(trueIfNoChildsDefined)
return (childTags.isEmpty() || childTags.tqcontains(tagName));
else
@@ -247,10 +247,10 @@ bool TQTag::isChild(Node *node, bool trueIfNoChildsDefined, bool treatEmptyNodes
return isChild(node->tag->name, trueIfNoChildsDefined);
}
-TQPtrList<TQTag> TQTag::tqparents()
+TQPtrList<TQTag> TQTag::parents()
{
TQPtrList<TQTag> qTagList;
- TQDictIterator<TQTag> it((*tqparentDTD->tagsList));
+ TQDictIterator<TQTag> it((*parentDTD->tagsList));
for(; it.current(); ++it)
{
if(it.current()->isChild(name()))
diff --git a/quanta/parsers/qtag.h b/quanta/parsers/qtag.h
index 679fbc55..ed4b594a 100644
--- a/quanta/parsers/qtag.h
+++ b/quanta/parsers/qtag.h
@@ -58,7 +58,7 @@ class XMLStructGroup {
bool hasFileName; ///<the group contains filename(s)
TQRegExp fileNameRx; ///<delete the matches of this regexp to obtain a filename (eg. linked, included file name)
bool appendToTags; ///<true if the group elements must be used as normal tags in autocompletion
- TQString tqparentGroup; ///<if the group element can be a child of another group (eg. member function of a class), holds the tqparent name. Makes sense only if appentToTags is true
+ TQString parentGroup; ///<if the group element can be a child of another group (eg. member function of a class), holds the tqparent name. Makes sense only if appentToTags is true
};
@@ -248,7 +248,7 @@ public:
//prefer using this variant, it handle Text, Empty, XmlTagEnd nodes!
bool isChild(Node *node, bool trueIfNoChildsDefined = true, bool treatEmptyNodesAsText = false);
/*** Returns the list of tqparent of this tag. */
- TQPtrList<TQTag> tqparents();
+ TQPtrList<TQTag> parents();
/** No descriptions */
TQString fileName();
@@ -258,7 +258,7 @@ public:
Attribute* attribute(const TQString& name);
/** The tag belongs to this DTD */
- const DTDStruct *tqparentDTD;
+ const DTDStruct *parentDTD;
/** The tag has the attributes of the above common groups */
TQStringList commonGroups;
TQStringList stoppingTags;
diff --git a/quanta/parsers/sagroupparser.cpp b/quanta/parsers/sagroupparser.cpp
index 5f45a73a..49973c70 100644
--- a/quanta/parsers/sagroupparser.cpp
+++ b/quanta/parsers/sagroupparser.cpp
@@ -182,10 +182,10 @@ void SAGroupParser::parseForScriptGroup(Node *node)
}
if (tmpNode && tmpNode->tag->type == Tag::ScriptStructureBegin)
{
- groupElement->tqparentNode = tmpNode;
+ groupElement->parentNode = tmpNode;
} else
{
- groupElement->tqparentNode = 0L;
+ groupElement->parentNode = 0L;
}
groupElement->global = true;
tmpNode = node->tqparent;
@@ -194,7 +194,7 @@ void SAGroupParser::parseForScriptGroup(Node *node)
if ( tmpNode->tag->type == Tag::ScriptStructureBegin && tmpNode->tag->dtd()->localScopeKeywordsRx.search(tmpNode->tag->cleanStr) != -1)
{
groupElement->global = false;
- groupElement->tqparentNode = tmpNode;
+ groupElement->parentNode = tmpNode;
break;
}
tmpNode = tmpNode->tqparent;
@@ -207,11 +207,11 @@ void SAGroupParser::parseForScriptGroup(Node *node)
int nameEnd = s.tqfind('(');
qTag->setName(s.left(nameEnd));
qTag->className = "";
- if (groupElement->tqparentNode)
+ if (groupElement->parentNode)
{
- for (GroupElementList::ConstIterator it2 = groupElement->tqparentNode->m_groupElements.constBegin(); it2 != groupElement->tqparentNode->m_groupElements.constEnd(); ++it2)
+ for (GroupElementList::ConstIterator it2 = groupElement->parentNode->m_groupElements.constBegin(); it2 != groupElement->parentNode->m_groupElements.constEnd(); ++it2)
{
- if ((*it2)->group->name == group.tqparentGroup)
+ if ((*it2)->group->name == group.parentGroup)
{
qTag->className = (*it2)->tag->name;
break;
@@ -253,7 +253,7 @@ void SAGroupParser::parseForScriptGroup(Node *node)
else
break;
}
- // Now we are left with the current line, lets check if the variable is inside tqparentheses
+ // Now we are left with the current line, lets check if the variable is inside parentheses
int lineOpenParenth=tagWholeLineStr.tqfind('(');
if(lineOpenParenth != -1)
{
diff --git a/quanta/parsers/saparser.cpp b/quanta/parsers/saparser.cpp
index e562d47b..9a30273c 100644
--- a/quanta/parsers/saparser.cpp
+++ b/quanta/parsers/saparser.cpp
@@ -157,7 +157,7 @@ bool SAParser::slotParseOneLine()
s_currentNode->tag->type == Tag::Empty) )
ParserCommon::appendAreaToTextNode(m_write, s_currentContext.area, s_currentNode);
else
- s_currentNode = ParserCommon::createTextNode(m_write, s_currentNode, s_line, s_currentContext.area.eCol + 1, s_currentContext.tqparentNode);
+ s_currentNode = ParserCommon::createTextNode(m_write, s_currentNode, s_line, s_currentContext.area.eCol + 1, s_currentContext.parentNode);
s_currentNode->tag->type = Tag::ScriptStructureBegin;
s_currentNode->tag->single = false;
@@ -166,7 +166,7 @@ bool SAParser::slotParseOneLine()
s_currentContext.lastNode = s_currentNode;
s_contextStack.push(s_currentContext);
- s_currentContext.tqparentNode = s_currentNode;
+ s_currentContext.parentNode = s_currentNode;
s_col = s_context.area.bCol + s_context.startString.length();
s_currentContext.area.bLine = s_line;
s_currentContext.area.bCol = s_col;
@@ -208,14 +208,14 @@ bool SAParser::slotParseOneLine()
s_currentNode->tag->type == Tag::Empty) )
ParserCommon::appendAreaToTextNode(m_write, s_currentContext.area, s_currentNode);
else
- s_currentNode = ParserCommon::createTextNode(m_write, s_currentNode, s_line, groupKeywordPos, s_currentContext.tqparentNode);
+ s_currentNode = ParserCommon::createTextNode(m_write, s_currentNode, s_line, groupKeywordPos, s_currentContext.parentNode);
if (s_currentNode)
{
s_currentNode->insideSpecial = true;
s_currentNode->specialInsideXml = m_specialInsideXml;
}
s_previousContext = s_contextStack.pop();
- s_currentContext.tqparentNode = s_previousContext.tqparentNode;
+ s_currentContext.parentNode = s_previousContext.parentNode;
s_currentContext.lastNode = s_previousContext.lastNode;
s_currentContext.type = s_previousContext.type;
s_currentContext.area.bLine = s_line;
@@ -232,14 +232,14 @@ bool SAParser::slotParseOneLine()
tag->setDtd(s_dtd);
tag->type = Tag::ScriptStructureEnd;
tag->single = true;
- Node *node = new Node(s_currentContext.tqparentNode);
+ Node *node = new Node(s_currentContext.parentNode);
nodeNum++;
node->tag = tag;
node->insideSpecial = true;
node->specialInsideXml = m_specialInsideXml;
- if (s_currentContext.tqparentNode && !s_currentContext.tqparentNode->child)
+ if (s_currentContext.parentNode && !s_currentContext.parentNode->child)
{
- s_currentContext.tqparentNode->child = node;
+ s_currentContext.parentNode->child = node;
}
else if (s_currentContext.lastNode)
{
@@ -275,7 +275,7 @@ bool SAParser::slotParseOneLine()
s_currentNode->tag->type == Tag::Empty) )
ParserCommon::appendAreaToTextNode(m_write, s_currentContext.area, s_currentNode);
else
- s_currentNode = ParserCommon::createTextNode(m_write, s_currentNode, s_line, specialAreaPos, s_currentContext.tqparentNode);
+ s_currentNode = ParserCommon::createTextNode(m_write, s_currentNode, s_line, specialAreaPos, s_currentContext.parentNode);
if (s_currentNode)
{
s_currentNode->insideSpecial = true;
@@ -284,7 +284,7 @@ bool SAParser::slotParseOneLine()
}
//create a toplevel node for the included special area
AreaStruct area(s_line, specialAreaPos, s_line, specialAreaPos + foundText.length() - 1);
- Node *node = ParserCommon::createScriptTagNode(m_write, area, foundText, s_dtd, s_currentContext.tqparentNode, s_currentNode);
+ Node *node = ParserCommon::createScriptTagNode(m_write, area, foundText, s_dtd, s_currentContext.parentNode, s_currentNode);
#ifdef DEBUG_PARSER
kdDebug(24001) << "Parsing a nested area." << endl;
#endif
@@ -419,10 +419,10 @@ bool SAParser::slotParseOneLine()
{
s_context.area.bLine = s_line;
s_context.area.eLine = s_context.area.eCol = -1;
- s_context.tqparentNode = s_currentContext.tqparentNode;
+ s_context.parentNode = s_currentContext.parentNode;
s_currentContext.area.eLine = s_context.area.bLine;
s_currentContext.area.eCol = s_context.area.bCol - 1;
- // s_currentContext.tqparentNode = s_parentNode;
+ // s_currentContext.parentNode = s_parentNode;
s_contextStack.push(s_currentContext);
if (s_fullParse)
{
@@ -451,14 +451,14 @@ bool SAParser::slotParseOneLine()
}
tag->single = true;
//create a node with the above tag
- Node *node = new Node(s_currentContext.tqparentNode);
+ Node *node = new Node(s_currentContext.parentNode);
nodeNum++;
node->tag = tag;
node->insideSpecial = true;
node->specialInsideXml = m_specialInsideXml;
- if (s_currentContext.tqparentNode && !s_currentContext.tqparentNode->child)
+ if (s_currentContext.parentNode && !s_currentContext.parentNode->child)
{
- s_currentContext.tqparentNode->child = node;
+ s_currentContext.parentNode->child = node;
}
else if (s_currentNode)
{
@@ -522,12 +522,12 @@ bool SAParser::slotParseOneLine()
s_currentNode->tag->type == Tag::Empty) )
ParserCommon::appendAreaToTextNode(m_write, s_currentContext.area, s_currentNode);
else
- s_currentNode = ParserCommon::createTextNode(m_write, 0L, s_line, pos, s_currentContext.tqparentNode);
+ s_currentNode = ParserCommon::createTextNode(m_write, 0L, s_line, pos, s_currentContext.parentNode);
s_currentNode->insideSpecial = true;
s_currentNode->specialInsideXml = m_specialInsideXml;
}
s_previousContext = s_contextStack.pop();
- s_currentContext.tqparentNode = s_previousContext.tqparentNode;
+ s_currentContext.parentNode = s_previousContext.parentNode;
s_currentContext.type = s_previousContext.type;
s_currentContext.area.bLine = s_line;
s_currentContext.area.bCol = pos + 1;
@@ -570,7 +570,7 @@ bool SAParser::slotParseOneLine()
tag->type = Tag::Comment;
tag->single = true;
//create a node with the above tag
- Node *node = new Node(s_currentContext.tqparentNode);
+ Node *node = new Node(s_currentContext.parentNode);
nodeNum++;
node->tag = tag;
node->insideSpecial = true;
@@ -585,7 +585,7 @@ bool SAParser::slotParseOneLine()
s_currentNode = node;
}
s_previousContext = s_contextStack.pop();
- s_currentContext.tqparentNode = s_previousContext.tqparentNode;
+ s_currentContext.parentNode = s_previousContext.parentNode;
s_currentContext.type = s_previousContext.type;
s_currentContext.area.bLine = s_line;
s_currentContext.area.bCol = s_currentContext.area.eCol + 1;
@@ -635,11 +635,11 @@ bool SAParser::slotParseOneLine()
Node* SAParser::parseArea(const AreaStruct &specialArea,
const TQString &areaStartString,
const TQString &forcedAreaEndString,
- Node *tqparentNode,
+ Node *parentNode,
bool fullParse, bool synchronous)
{
m_synchronous = synchronous;
- s_parentNode = tqparentNode;
+ s_parentNode = parentNode;
s_fullParse = fullParse;
#ifdef DEBUG_PARSER
kdDebug(24001) << "parseArea full: " << s_fullParse << " synch: " << m_synchronous <<endl;
@@ -656,11 +656,11 @@ Node* SAParser::parseArea(const AreaStruct &specialArea,
s_dtd = 0L;
if (s_parentNode && !areaStartString.isEmpty())
{
- const DTDStruct *tqparentDTD = m_dtd;
+ const DTDStruct *parentDTD = m_dtd;
if (s_parentNode->tqparent)
- tqparentDTD = s_parentNode->tqparent->tag->dtd();
- s_dtd = DTDs::ref()->tqfind(tqparentDTD->specialAreaNames[areaStartString]);
- s_areaEndString = tqparentDTD->specialAreas[areaStartString];
+ parentDTD = s_parentNode->tqparent->tag->dtd();
+ s_dtd = DTDs::ref()->tqfind(parentDTD->specialAreaNames[areaStartString]);
+ s_areaEndString = parentDTD->specialAreas[areaStartString];
s_searchForAreaEnd = true;
}
if (!forcedAreaEndString.isEmpty())
@@ -702,7 +702,7 @@ Node* SAParser::parseArea(const AreaStruct &specialArea,
s_currentContext.area.bLine = s_line;
s_currentContext.area.bCol = s_col;
s_currentContext.area.eLine = s_currentContext.area.eCol = -1;
- s_currentContext.tqparentNode = s_parentNode;
+ s_currentContext.parentNode = s_parentNode;
s_currentNode = s_parentNode;
m_lastParsedNode = 0L;
s_useReturnVars = false;
diff --git a/quanta/parsers/saparser.h b/quanta/parsers/saparser.h
index d344fb55..01ea34e0 100644
--- a/quanta/parsers/saparser.h
+++ b/quanta/parsers/saparser.h
@@ -57,7 +57,7 @@ public:
area. It may end before the end position.
areaStartString: the special area starting string
forcedAreaEndString: force this as the special area ending string.
- tqparentNode: the Node under where the special area goes
+ parentNode: the Node under where the special area goes
fullParse: the script node will be fully parsed for groups, structures or so. If false, only the script beginning and end will be determined.
synchronous: if true, the function does not return until the parsing is finished, otherwise
return immediately.
@@ -66,7 +66,7 @@ public:
Node* parseArea(const AreaStruct &specialArea,
const TQString &areaStartString,
const TQString &forcedAreaEndString,
- Node *tqparentNode,
+ Node *parentNode,
bool fullParse, bool synchronous);
/** Returns the line where the last parsing run ended. */
int lastParsedLine() {return m_lastParsedLine;}
@@ -97,7 +97,7 @@ private:
int type;
AreaStruct area;
TQString startString;
- Node *tqparentNode;
+ Node *parentNode;
Node *lastNode;
};
enum ContextType {
diff --git a/quanta/parsers/tag.cpp b/quanta/parsers/tag.cpp
index f6460fce..a2dbcf71 100644
--- a/quanta/parsers/tag.cpp
+++ b/quanta/parsers/tag.cpp
@@ -328,7 +328,7 @@ void Tag::parse(const TQString &p_tagStr, Document *p_write)
{
newTag = new TQTag();
newTag->setName(name);
- newTag->tqparentDTD = m_dtd;
+ newTag->parentDTD = m_dtd;
}
for (int i = 0; i >attrCount(); i++)
{
@@ -574,7 +574,7 @@ void Tag::modifyAttributes(TQDict<TQString> *attrDict)
{
attribute = it.currentKey();
value = *(it.current());
- if (qTag && qTag->tqparentDTD->singleTagStyle == "xml" && attribute=="/")
+ if (qTag && qTag->parentDTD->singleTagStyle == "xml" && attribute=="/")
{
++it;
continue;
@@ -622,7 +622,7 @@ TQString Tag::toString()
attrString.append(QuantaCommon::tagCase(name));
tagString.prepend(attrString);
- if (attrs.isEmpty() && qTag && qTag->tqparentDTD->singleTagStyle == "xml" &&
+ if (attrs.isEmpty() && qTag && qTag->parentDTD->singleTagStyle == "xml" &&
(qTag->isSingle() ||
(!qConfig.closeOptionalTags && qTag->isOptional()) || single)
)