summaryrefslogtreecommitdiffstats
path: root/buildtools/lib/parsers
diff options
context:
space:
mode:
Diffstat (limited to 'buildtools/lib/parsers')
-rw-r--r--buildtools/lib/parsers/autotools/autotools.ll2
-rw-r--r--buildtools/lib/parsers/autotools/autotools.yy2
-rw-r--r--buildtools/lib/parsers/autotools/autotools_lex.cpp6
-rw-r--r--buildtools/lib/parsers/autotools/autotools_yacc.cpp2
-rw-r--r--buildtools/lib/parsers/autotools/autotoolsast.cpp14
-rw-r--r--buildtools/lib/parsers/autotools/autotoolsast.h10
-rw-r--r--buildtools/lib/parsers/autotools/autotoolsdriver.h8
-rw-r--r--buildtools/lib/parsers/autotools/tests/viewer.cpp18
-rw-r--r--buildtools/lib/parsers/autotools/tests/viewer.h5
-rw-r--r--buildtools/lib/parsers/autotools/tests/viewer_main.cpp2
-rw-r--r--buildtools/lib/parsers/autotools/tests/viewerbase.ui40
-rw-r--r--buildtools/lib/parsers/qmake/location.hh6
-rw-r--r--buildtools/lib/parsers/qmake/position.hh6
-rw-r--r--buildtools/lib/parsers/qmake/qmake.yy4
-rw-r--r--buildtools/lib/parsers/qmake/qmake_lex.cpp16
-rw-r--r--buildtools/lib/parsers/qmake/qmake_lex.h14
-rw-r--r--buildtools/lib/parsers/qmake/qmake_yacc.cpp20
-rw-r--r--buildtools/lib/parsers/qmake/qmake_yacc.hpp22
-rw-r--r--buildtools/lib/parsers/qmake/qmakeast.cpp28
-rw-r--r--buildtools/lib/parsers/qmake/qmakeast.h10
-rw-r--r--buildtools/lib/parsers/qmake/qmakeastvisitor.cpp16
-rw-r--r--buildtools/lib/parsers/qmake/qmakeastvisitor.h6
-rw-r--r--buildtools/lib/parsers/qmake/qmakedriver.cpp26
-rw-r--r--buildtools/lib/parsers/qmake/qmakedriver.h6
-rw-r--r--buildtools/lib/parsers/qmake/stack.hh4
-rw-r--r--buildtools/lib/parsers/qmake/tests/runner.cpp64
-rw-r--r--buildtools/lib/parsers/qmake/tests/viewer.cpp48
-rw-r--r--buildtools/lib/parsers/qmake/tests/viewer.h9
-rw-r--r--buildtools/lib/parsers/qmake/tests/viewer_main.cpp2
-rw-r--r--buildtools/lib/parsers/qmake/tests/viewerbase.ui44
30 files changed, 231 insertions, 229 deletions
diff --git a/buildtools/lib/parsers/autotools/autotools.ll b/buildtools/lib/parsers/autotools/autotools.ll
index f05f8ff6..d6f2a9bb 100644
--- a/buildtools/lib/parsers/autotools/autotools.ll
+++ b/buildtools/lib/parsers/autotools/autotools.ll
@@ -98,7 +98,7 @@ rule [\t]+[^\n]*
<list>{id_list} {
yylval.value = yytext;
- yylval.value = yylval.value.mid(0, yylval.value.findRev("\\"));
+ yylval.value = yylval.value.mid(0, yylval.value.tqfindRev("\\"));
unput('\\');
BEGIN(INITIAL);
return (ID_LIST);
diff --git a/buildtools/lib/parsers/autotools/autotools.yy b/buildtools/lib/parsers/autotools/autotools.yy
index d76cc5fe..350fbd77 100644
--- a/buildtools/lib/parsers/autotools/autotools.yy
+++ b/buildtools/lib/parsers/autotools/autotools.yy
@@ -89,7 +89,7 @@ currently on the top in the stack.
When a scope or function scope statement is parsed, the child ProjectAST is created
and pushed onto the stack. Therefore all statements which belong to the scope
-or function scope are added as childs to their direct parent (scope or function scope).
+or function scope are added as childs to their direct tqparent (scope or function scope).
*/
QValueStack<ProjectAST*> projects;
diff --git a/buildtools/lib/parsers/autotools/autotools_lex.cpp b/buildtools/lib/parsers/autotools/autotools_lex.cpp
index d5f690b5..e534d74f 100644
--- a/buildtools/lib/parsers/autotools/autotools_lex.cpp
+++ b/buildtools/lib/parsers/autotools/autotools_lex.cpp
@@ -539,8 +539,8 @@ at the left of the operator in assignments (like "SOURCES" in "SOURCES+=foo.cpp
-id_list: those are "value list identifiers" at the right side in assignments
(like "foo.cpp goo.cpp" in "SOURCES+=foo.cpp goo.cpp");
-id_args: function arguments recognized as one identifier
-(example: ""${QMAKE_FILE} is intended only for Windows!""
-in "!win32-*:!wince-*:error("${QMAKE_FILE} is intended only for Windows!")" statements).
+(example: ""${TQMAKE_FILE} is intended only for Windows!""
+in "!win32-*:!wince-*:error("${TQMAKE_FILE} is intended only for Windows!")" statements).
.
To recognize those identifiers two additional start conditions are used: list and funcargs.
@@ -841,7 +841,7 @@ YY_RULE_SETUP
#line 99 "autotools.ll"
{
yylval.value = yytext;
- yylval.value = yylval.value.mid(0, yylval.value.findRev("\\"));
+ yylval.value = yylval.value.mid(0, yylval.value.tqfindRev("\\"));
unput('\\');
BEGIN(INITIAL);
return (ID_LIST);
diff --git a/buildtools/lib/parsers/autotools/autotools_yacc.cpp b/buildtools/lib/parsers/autotools/autotools_yacc.cpp
index 93cdb733..e0b92999 100644
--- a/buildtools/lib/parsers/autotools/autotools_yacc.cpp
+++ b/buildtools/lib/parsers/autotools/autotools_yacc.cpp
@@ -204,7 +204,7 @@ currently on the top in the stack.
When a scope or function scope statement is parsed, the child ProjectAST is created
and pushed onto the stack. Therefore all statements which belong to the scope
-or function scope are added as childs to their direct parent (scope or function scope).
+or function scope are added as childs to their direct tqparent (scope or function scope).
*/
TQValueStack<ProjectAST*> projects;
diff --git a/buildtools/lib/parsers/autotools/autotoolsast.cpp b/buildtools/lib/parsers/autotools/autotoolsast.cpp
index ddcbddc3..f6ac032f 100644
--- a/buildtools/lib/parsers/autotools/autotoolsast.cpp
+++ b/buildtools/lib/parsers/autotools/autotoolsast.cpp
@@ -28,7 +28,7 @@ namespace AutoTools {
AST::~AST()
{
- for (TQValueList<AST*>::iterator it = m_children.begin(); it != m_children.end(); ++it)
+ for (TQValueList<AST*>::iterator it = m_tqchildren.begin(); it != m_tqchildren.end(); ++it)
{
AST *node = *it;
delete node;
@@ -37,13 +37,13 @@ AST::~AST()
void AST::addChildAST(AST *node)
{
- m_children.append(node);
+ m_tqchildren.append(node);
}
void AST::writeBack(TQString &buffer)
{
- for (TQValueList<AST*>::const_iterator it = m_children.constBegin();
- it != m_children.constEnd(); ++it)
+ for (TQValueList<AST*>::const_iterator it = m_tqchildren.constBegin();
+ it != m_tqchildren.constEnd(); ++it)
{
if (*it)
(*it)->writeBack(buffer);
@@ -60,12 +60,12 @@ TQString AST::indentation()
bool AST::hasChildren() const
{
- return !m_children.isEmpty();
+ return !m_tqchildren.isEmpty();
}
-TQValueList<AST*> AST::children() const
+TQValueList<AST*> AST::tqchildren() const
{
- return m_children;
+ return m_tqchildren;
}
//ProjectAST
diff --git a/buildtools/lib/parsers/autotools/autotoolsast.h b/buildtools/lib/parsers/autotools/autotoolsast.h
index 768e3e07..e690baa4 100644
--- a/buildtools/lib/parsers/autotools/autotoolsast.h
+++ b/buildtools/lib/parsers/autotools/autotoolsast.h
@@ -37,7 +37,7 @@ namespace AutoTools
* AST node.
* This is the base class. Objects of this type are not created by the parser.
*
- * Each AST node holds the list of its children which are always deleted in the
+ * Each AST node holds the list of its tqchildren which are always deleted in the
* destructor. This way, it's possible call delete for only root AST node and
* others will be deleted automatically.
*
@@ -85,20 +85,20 @@ public:
/** @return The indentation string based on node depth.*/
virtual TQString indentation();
- //! \return true if this AST has children
+ //! \return true if this AST has tqchildren
bool hasChildren() const;
/**
- * Get the children of this ast
+ * Get the tqchildren of this ast
* \return the list of this ast's childre
*/
- TQValueList<AST*> children() const;
+ TQValueList<AST*> tqchildren() const;
protected:
NodeType m_nodeType;
- TQValueList<AST*> m_children;
+ TQValueList<AST*> m_tqchildren;
private:
int m_depth;
diff --git a/buildtools/lib/parsers/autotools/autotoolsdriver.h b/buildtools/lib/parsers/autotools/autotoolsdriver.h
index 5f6ac7e7..8e29bec6 100644
--- a/buildtools/lib/parsers/autotools/autotoolsdriver.h
+++ b/buildtools/lib/parsers/autotools/autotoolsdriver.h
@@ -20,8 +20,8 @@
* Free Software Foundation, Inc., *
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
***************************************************************************/
-#ifndef QMAKEQMAKEDRIVER_H
-#define QMAKEQMAKEDRIVER_H
+#ifndef TQMAKETQMAKEDRIVER_H
+#define TQMAKETQMAKEDRIVER_H
#include <tqvaluelist.h>
#include <kurl.h>
@@ -56,12 +56,12 @@ public:
static void walkAST(Op &op, const ProjectAST *ast)
{
// op(ast);
- for (TQValueList<QMake::AST*>::const_iterator it = ast->statements.constBegin();
+ for (TQValueList<TQMake::AST*>::const_iterator it = ast->statements.constBegin();
it != ast->statements.constEnd(); ++it)
{
const AST *child = *it;
if (child->nodeType() == AST::ProjectAST)
- walkAST<Op>(op, static_cast<const QMake::ProjectAST*>(child));
+ walkAST<Op>(op, static_cast<const TQMake::ProjectAST*>(child));
else
op(child);
}
diff --git a/buildtools/lib/parsers/autotools/tests/viewer.cpp b/buildtools/lib/parsers/autotools/tests/viewer.cpp
index 0dc8e733..66401c2c 100644
--- a/buildtools/lib/parsers/autotools/tests/viewer.cpp
+++ b/buildtools/lib/parsers/autotools/tests/viewer.cpp
@@ -34,8 +34,8 @@
using namespace AutoTools;
-Viewer::Viewer(TQWidget *parent, const char *name)
- :ViewerBase(parent, name)
+Viewer::Viewer(TQWidget *tqparent, const char *name)
+ :ViewerBase(tqparent, name)
{
if (TQFile::exists(TQDir::currentDirPath() + "/" + "qtlist"))
{
@@ -46,7 +46,7 @@ Viewer::Viewer(TQWidget *parent, const char *name)
files->insertItem(str.readLine());
}
ast->setSorting(-1);
- parentProject.push((TQListViewItem*)0);
+ tqparentProject.push((TQListViewItem*)0);
}
void Viewer::addAll_clicked()
@@ -99,12 +99,12 @@ void Viewer::tabWidget2_selected(const TQString& text)
void Viewer::processAST(ProjectAST *projectAST, TQListViewItem *globAfter)
{
TQListViewItem *projectIt;
- if (!parentProject.top())
+ if (!tqparentProject.top())
projectIt = new TQListViewItem(ast, "Project");
else
{
if ( projectAST->isConditionalScope() || projectAST->isRule() )
- projectIt = new TQListViewItem(parentProject.top(), globAfter, projectAST->scopedID);
+ projectIt = new TQListViewItem(tqparentProject.top(), globAfter, projectAST->scopedID);
}
projectIt->setOpen(true);
@@ -128,7 +128,7 @@ void Viewer::processAST(ProjectAST *projectAST, TQListViewItem *globAfter)
{
AutomakeTargetAST* ata = static_cast<AutomakeTargetAST*>(ast);
TQListViewItem* item = new TQListViewItem(projectIt, after,
- ata->target, TQString::null, ata->deps.join(""));
+ ata->target, TQString(), ata->deps.join(""));
after = item;
}
break;
@@ -145,14 +145,14 @@ void Viewer::processAST(ProjectAST *projectAST, TQListViewItem *globAfter)
{
ConditionAST* ata = static_cast<ConditionAST*>(ast);
TQListViewItem* item = new TQListViewItem(projectIt, after,
- ata->type, ata->conditionName, TQString::null );
+ ata->type, ata->conditionName, TQString() );
after = item;
}
case AST::ProjectAST: {
ProjectAST *projectAST = static_cast<ProjectAST*>(ast);
- parentProject.push(projectIt);
+ tqparentProject.push(projectIt);
processAST(projectAST, after);
- parentProject.pop(); }
+ tqparentProject.pop(); }
break;
}
}
diff --git a/buildtools/lib/parsers/autotools/tests/viewer.h b/buildtools/lib/parsers/autotools/tests/viewer.h
index 5ee63c54..c0653020 100644
--- a/buildtools/lib/parsers/autotools/tests/viewer.h
+++ b/buildtools/lib/parsers/autotools/tests/viewer.h
@@ -30,8 +30,9 @@ class TQListViewItem;
class Viewer: public ViewerBase {
Q_OBJECT
+ TQ_OBJECT
public:
- Viewer(TQWidget *parent = 0, const char *name = 0);
+ Viewer(TQWidget *tqparent = 0, const char *name = 0);
void processAST(AutoTools::ProjectAST *projectAST, TQListViewItem *globAfter = 0);
public slots:
virtual void tabWidget2_selected(const TQString&);
@@ -40,7 +41,7 @@ public slots:
virtual void addAll_clicked();
private:
AutoTools::ProjectAST *projectAST;
- TQValueStack<TQListViewItem *> parentProject;
+ TQValueStack<TQListViewItem *> tqparentProject;
};
#endif
diff --git a/buildtools/lib/parsers/autotools/tests/viewer_main.cpp b/buildtools/lib/parsers/autotools/tests/viewer_main.cpp
index 380767a9..0fc5157b 100644
--- a/buildtools/lib/parsers/autotools/tests/viewer_main.cpp
+++ b/buildtools/lib/parsers/autotools/tests/viewer_main.cpp
@@ -28,7 +28,7 @@ int main(int argc, char **argv)
app.setMainWidget(&viewer);
viewer.show();
viewer.resize(800, 600);
- //viewer.setWindowState(viewer.windowState() | Qt::WindowMaximized);
+ //viewer.setWindowState(viewer.windowState() | TQt::WindowMaximized);
return app.exec();
}
diff --git a/buildtools/lib/parsers/autotools/tests/viewerbase.ui b/buildtools/lib/parsers/autotools/tests/viewerbase.ui
index 7c228299..75ed7559 100644
--- a/buildtools/lib/parsers/autotools/tests/viewerbase.ui
+++ b/buildtools/lib/parsers/autotools/tests/viewerbase.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>ViewerBase</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>ViewerBase</cstring>
</property>
@@ -19,15 +19,15 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget" row="0" column="1" rowspan="4" colspan="1">
+ <widget class="TQLayoutWidget" row="0" column="1" rowspan="4" colspan="1">
<property name="name">
- <cstring>layout2</cstring>
+ <cstring>tqlayout2</cstring>
</property>
<vbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QTextEdit">
+ <widget class="TQTextEdit">
<property name="name">
<cstring>source</cstring>
</property>
@@ -40,7 +40,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QTabWidget">
+ <widget class="TQTabWidget">
<property name="name">
<cstring>tabWidget2</cstring>
</property>
@@ -52,7 +52,7 @@
<verstretch>2</verstretch>
</sizepolicy>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>tab</cstring>
</property>
@@ -63,7 +63,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QListView" row="0" column="0">
+ <widget class="TQListView" row="0" column="0">
<column>
<property name="text">
<string>Name</string>
@@ -103,7 +103,7 @@
</widget>
</grid>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>tab</cstring>
</property>
@@ -114,7 +114,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QTextEdit" row="0" column="0">
+ <widget class="TQTextEdit" row="0" column="0">
<property name="name">
<cstring>writeBack</cstring>
</property>
@@ -124,22 +124,22 @@
</widget>
</vbox>
</widget>
- <widget class="QLineEdit" row="0" column="0">
+ <widget class="TQLineEdit" row="0" column="0">
<property name="name">
<cstring>allLocation</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>150</width>
<height>32767</height>
</size>
</property>
</widget>
- <widget class="QPushButton" row="1" column="0">
+ <widget class="TQPushButton" row="1" column="0">
<property name="name">
<cstring>addAll</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>150</width>
<height>32767</height>
@@ -149,11 +149,11 @@
<string>Add All From Directory</string>
</property>
</widget>
- <widget class="QPushButton" row="2" column="0">
+ <widget class="TQPushButton" row="2" column="0">
<property name="name">
<cstring>choose</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>150</width>
<height>32767</height>
@@ -163,7 +163,7 @@
<string>Choose File to Add...</string>
</property>
</widget>
- <widget class="QListBox" row="3" column="0">
+ <widget class="TQListBox" row="3" column="0">
<property name="name">
<cstring>files</cstring>
</property>
@@ -175,7 +175,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>150</width>
<height>32767</height>
@@ -210,11 +210,11 @@
<slot>tabWidget2_selected(const QString&amp;)</slot>
</connection>
</connections>
-<slots>
+<Q_SLOTS>
<slot>addAll_clicked()</slot>
<slot>choose_clicked()</slot>
<slot>files_currentChanged(QListBoxItem*)</slot>
<slot>tabWidget2_selected(const QString&amp;)</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/buildtools/lib/parsers/qmake/location.hh b/buildtools/lib/parsers/qmake/location.hh
index 4da36b8a..41ec2015 100644
--- a/buildtools/lib/parsers/qmake/location.hh
+++ b/buildtools/lib/parsers/qmake/location.hh
@@ -19,7 +19,7 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA. */
-/* As a special exception, you may create a larger work that contains
+/* As a special exception, you may create a larger work that tqcontains
part or all of the Bison parser skeleton and distribute that work
under terms of your choice, so long as that work isn't itself a
parser generator using the skeleton or a modified version thereof
@@ -34,7 +34,7 @@
/**
** \file location.hh
- ** Define the QMake::location class.
+ ** Define the TQMake::location class.
*/
#ifndef BISON_LOCATION_HH
@@ -44,7 +44,7 @@
# include <string>
# include "position.hh"
-namespace QMake
+namespace TQMake
{
/// Abstract a location.
diff --git a/buildtools/lib/parsers/qmake/position.hh b/buildtools/lib/parsers/qmake/position.hh
index 704f0df4..63fe2d81 100644
--- a/buildtools/lib/parsers/qmake/position.hh
+++ b/buildtools/lib/parsers/qmake/position.hh
@@ -19,7 +19,7 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA. */
-/* As a special exception, you may create a larger work that contains
+/* As a special exception, you may create a larger work that tqcontains
part or all of the Bison parser skeleton and distribute that work
under terms of your choice, so long as that work isn't itself a
parser generator using the skeleton or a modified version thereof
@@ -34,7 +34,7 @@
/**
** \file position.hh
- ** Define the QMake::position class.
+ ** Define the TQMake::position class.
*/
#ifndef BISON_POSITION_HH
@@ -43,7 +43,7 @@
# include <iostream>
# include <string>
-namespace QMake
+namespace TQMake
{
/// Abstract a position.
class position
diff --git a/buildtools/lib/parsers/qmake/qmake.yy b/buildtools/lib/parsers/qmake/qmake.yy
index e11c086d..75d306d0 100644
--- a/buildtools/lib/parsers/qmake/qmake.yy
+++ b/buildtools/lib/parsers/qmake/qmake.yy
@@ -90,7 +90,7 @@ currently on the top in the stack.
When a scope or function scope statement is parsed, the child ProjectAST is created
and pushed onto the stack. Therefore all statements which belong to the scope
-or function scope are added as childs to their direct parent (scope or function scope).
+or function scope are added as childs to their direct tqparent (scope or function scope).
*/
//QValueStack<ProjectAST*> projects;
@@ -359,7 +359,7 @@ function_call : ID_SIMPLE LBRACE function_args RBRACE
depth++;
//qWarning("%s", $<value>1.ascii());
- if ($<value>1.contains("include"))
+ if ($<value>1.tqcontains("include"))
{
IncludeAST *includeAST = new IncludeAST();
includeAST->projectName = $<value>3;
diff --git a/buildtools/lib/parsers/qmake/qmake_lex.cpp b/buildtools/lib/parsers/qmake/qmake_lex.cpp
index 9fe37664..4d74571c 100644
--- a/buildtools/lib/parsers/qmake/qmake_lex.cpp
+++ b/buildtools/lib/parsers/qmake/qmake_lex.cpp
@@ -398,7 +398,7 @@ int yyFlexLexer::yylex()
return 0;
}
-#define YY_DECL int QMake::Lexer::yylex()
+#define YY_DECL int TQMake::Lexer::yylex()
/* %if-c-only Standard (non-C++) definition */
/* %endif */
@@ -630,7 +630,7 @@ static yyconst flex_int16_t yy_rule_linenum[23] =
/**
@file qmake.ll
-QMake Lexer
+TQMake Lexer
There are 3 types of identifiers recognized by this lexer:
-id_simple: examples of such identifiers are qmake variables and scoped variables
@@ -638,8 +638,8 @@ at the left of the operator in assignments (like "SOURCES" in "SOURCES+=foo.cpp
-id_list: those are "value list identifiers" at the right side in assignments
(like "foo.cpp goo.cpp" in "SOURCES+=foo.cpp goo.cpp");
-id_args: function arguments recognized as one identifier
-(example: ""${QMAKE_FILE} is intended only for Windows!""
-in "!win32-*:!wince-*:error("${QMAKE_FILE} is intended only for Windows!")" statements).
+(example: ""${TQMAKE_FILE} is intended only for Windows!""
+in "!win32-*:!wince-*:error("${TQMAKE_FILE} is intended only for Windows!")" statements).
.
To recognize those identifiers two additional start conditions are used: list and funcargs.
@@ -1011,7 +1011,7 @@ YY_RULE_SETUP
{
BEGIN(vallist);
mylval->value = TQString::fromLocal8Bit( YYText(), YYLeng() );
- return Parser::token::token::QUOTED_VARIABLE_VALUE;
+ return Parser::token::token::TQUOTED_VARIABLE_VALUE;
}
YY_BREAK
case 9:
@@ -2202,14 +2202,14 @@ void yyfree (void * ptr )
#line 203 "qmake.ll"
-namespace QMake
+namespace TQMake
{
Lexer::Lexer( std::istream* argin, std::ostream* argout )
: yyFlexLexer(argin, argout), mylval(0), m_lineEnding(None)
{
}
- int Lexer::yylex( QMake::Parser::semantic_type* yylval )
+ int Lexer::yylex( TQMake::Parser::semantic_type* yylval )
{
mylval = yylval;
return yylex();
@@ -2231,7 +2231,7 @@ namespace QMake
}
}
-int QMakelex( QMake::Parser::semantic_type* yylval, QMake::Lexer* lexer)
+int TQMakelex( TQMake::Parser::semantic_type* yylval, TQMake::Lexer* lexer)
{
return lexer->yylex( yylval );
}
diff --git a/buildtools/lib/parsers/qmake/qmake_lex.h b/buildtools/lib/parsers/qmake/qmake_lex.h
index 242cec2a..514631bf 100644
--- a/buildtools/lib/parsers/qmake/qmake_lex.h
+++ b/buildtools/lib/parsers/qmake/qmake_lex.h
@@ -1,4 +1,4 @@
-/* KDevelop QMake Support
+/* KDevelop TQMake Support
*
* Copyright 2007 Andreas Pakulat <apaku@gmx.de>
*
@@ -17,8 +17,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
* 02110-1301, USA.
*/
-#ifndef QMAKE_LEX_H
-#define QMAKE_LEX_H
+#ifndef TQMAKE_LEX_H
+#define TQMAKE_LEX_H
#include "qmake_yacc.hpp"
#include <iostream>
@@ -27,23 +27,23 @@
#include "FlexLexer.h"
#endif
-namespace QMake
+namespace TQMake
{
class Lexer : public yyFlexLexer
{
public:
enum LineEnding{ None, Unix, MacOS, Windows };
Lexer( std::istream* argin = 0, std::ostream* argout = 0 );
- int yylex( QMake::Parser::semantic_type* yylval );
+ int yylex( TQMake::Parser::semantic_type* yylval );
int yylex();
void setLineEndingFromString( const TQString& );
LineEnding lineending();
private:
- QMake::Parser::semantic_type* mylval;
+ TQMake::Parser::semantic_type* mylval;
LineEnding m_lineEnding;
};
}
#endif
-// kate: space-indent on; indent-width 4; tab-width: 4; replace-tabs on; auto-insert-doxygen on
+// kate: space-indent on; indent-width 4; tab-width: 4; tqreplace-tabs on; auto-insert-doxygen on
diff --git a/buildtools/lib/parsers/qmake/qmake_yacc.cpp b/buildtools/lib/parsers/qmake/qmake_yacc.cpp
index 32722979..718cb4f5 100644
--- a/buildtools/lib/parsers/qmake/qmake_yacc.cpp
+++ b/buildtools/lib/parsers/qmake/qmake_yacc.cpp
@@ -19,7 +19,7 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA. */
-/* As a special exception, you may create a larger work that contains
+/* As a special exception, you may create a larger work that tqcontains
part or all of the Bison parser skeleton and distribute that work
under terms of your choice, so long as that work isn't itself a
parser generator using the skeleton or a modified version thereof
@@ -33,7 +33,7 @@
version 2.2 of Bison. */
// Take the name prefix into account.
-#define yylex QMakelex
+#define yylex TQMakelex
#include "qmake_yacc.hpp"
@@ -41,7 +41,7 @@
/* Line 317 of lalr1.cc. */
-#line 45 "qmake_yacc.cpp"
+#line 45 "tqmake_yacc.cpp"
#ifndef YY_
# if YYENABLE_NLS
@@ -100,7 +100,7 @@ do { \
#define YYABORT goto yyabortlab
#define YYERROR goto yyerrorlab
-namespace QMake
+namespace TQMake
{
#if YYERROR_VERBOSE
@@ -144,7 +144,7 @@ namespace QMake
#endif
/// Build a parser object.
- Parser::Parser (QMake::Lexer* lexer_yyarg, TQValueStack<ProjectAST*>& projects_yyarg, int depth_yyarg)
+ Parser::Parser (TQMake::Lexer* lexer_yyarg, TQValueStack<ProjectAST*>& projects_yyarg, int depth_yyarg)
: yydebug_ (false),
yycdebug_ (&std::cerr),
lexer (lexer_yyarg),
@@ -679,7 +679,7 @@ namespace QMake
depth++;
//qWarning("%s", $<value>1.ascii());
- if ((yysemantic_stack_[(4) - (1)].value).contains("include"))
+ if ((yysemantic_stack_[(4) - (1)].value).tqcontains("include"))
{
IncludeAST *includeAST = new IncludeAST();
includeAST->projectName = (yysemantic_stack_[(4) - (3)].value);
@@ -752,7 +752,7 @@ namespace QMake
/* Line 675 of lalr1.cc. */
-#line 756 "qmake_yacc.cpp"
+#line 756 "tqmake_yacc.cpp"
default: break;
}
YY_SYMBOL_PRINT ("-> $$ =", yyr1_[yyn], &yyval, &yyloc);
@@ -1089,7 +1089,7 @@ namespace QMake
"$end", "error", "$undefined", "ID_SIMPLE", "EQ", "PLUSEQ", "MINUSEQ",
"STAREQ", "TILDEEQ", "LBRACE", "RBRACE", "COLON", "NEWLINE", "COMMENT",
"CONT", "COMMENT_CONT", "RCURLY", "LCURLY", "ID_ARGS",
- "QUOTED_VARIABLE_VALUE", "VARIABLE_VALUE", "LIST_WS", "ENDOFFILE",
+ "TQUOTED_VARIABLE_VALUE", "VARIABLE_VALUE", "LIST_WS", "ENDOFFILE",
"\"else\"", "$accept", "project", "@1", "statements", "statement",
"variable_assignment", "possible_value", "multiline_values",
"variable_value", "listws", "operator", "scope", "@2", "function_call",
@@ -1227,13 +1227,13 @@ namespace QMake
const unsigned int Parser::yyuser_token_number_max_ = 278;
const Parser::token_number_type Parser::yyundef_token_ = 2;
-} // namespace QMake
+} // namespace TQMake
#line 421 "qmake.yy"
-namespace QMake
+namespace TQMake
{
void Parser::error(const location_type& /*l*/, const std::string& m)
{
diff --git a/buildtools/lib/parsers/qmake/qmake_yacc.hpp b/buildtools/lib/parsers/qmake/qmake_yacc.hpp
index 91583cd3..0b67bb14 100644
--- a/buildtools/lib/parsers/qmake/qmake_yacc.hpp
+++ b/buildtools/lib/parsers/qmake/qmake_yacc.hpp
@@ -19,7 +19,7 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA. */
-/* As a special exception, you may create a larger work that contains
+/* As a special exception, you may create a larger work that tqcontains
part or all of the Bison parser skeleton and distribute that work
under terms of your choice, so long as that work isn't itself a
parser generator using the skeleton or a modified version thereof
@@ -41,7 +41,7 @@
#include <iostream>
#include "stack.hh"
-namespace QMake
+namespace TQMake
{
class position;
class location;
@@ -74,9 +74,9 @@ namespace QMake
/**
@file qmake.yy
-QMake Parser
+TQMake Parser
-Simple LALR parser which builds the syntax tree (see @ref QMake::AST).
+Simple LALR parser which builds the syntax tree (see @ref TQMake::AST).
@todo Recognize comments after statements like:
SOURCES = foo #regognize me
@@ -91,7 +91,7 @@ SOURCES = foo #regognize me
#define YYSTYPE_IS_DECLARED
-namespace QMake
+namespace TQMake
{
class Lexer;
@@ -129,7 +129,7 @@ struct Result {
typedef Result YYSTYPE;
}
-extern int QMakelex( QMake::Result* yylval, QMake::Lexer* lexer );
+extern int TQMakelex( TQMake::Result* yylval, TQMake::Lexer* lexer );
/**
The stack to store ProjectAST pointers when a new child
@@ -141,7 +141,7 @@ currently on the top in the stack.
When a scope or function scope statement is parsed, the child ProjectAST is created
and pushed onto the stack. Therefore all statements which belong to the scope
-or function scope are added as childs to their direct parent (scope or function scope).
+or function scope are added as childs to their direct tqparent (scope or function scope).
*/
//TQValueStack<ProjectAST*> projects;
@@ -202,7 +202,7 @@ do { \
} while (false)
#endif
-namespace QMake
+namespace TQMake
{
/// A Bison parser.
@@ -238,7 +238,7 @@ namespace QMake
RCURLY = 271,
LCURLY = 272,
ID_ARGS = 273,
- QUOTED_VARIABLE_VALUE = 274,
+ TQUOTED_VARIABLE_VALUE = 274,
VARIABLE_VALUE = 275,
LIST_WS = 276,
ENDOFFILE = 277
@@ -249,7 +249,7 @@ namespace QMake
typedef token::yytokentype token_type;
/// Build a parser object.
- Parser (QMake::Lexer* lexer_yyarg, TQValueStack<ProjectAST*>& projects_yyarg, int depth_yyarg);
+ Parser (TQMake::Lexer* lexer_yyarg, TQValueStack<ProjectAST*>& projects_yyarg, int depth_yyarg);
virtual ~Parser ();
/// Parse.
@@ -408,7 +408,7 @@ namespace QMake
/* User arguments. */
- QMake::Lexer* lexer;
+ TQMake::Lexer* lexer;
TQValueStack<ProjectAST*>& projects;
int depth;
};
diff --git a/buildtools/lib/parsers/qmake/qmakeast.cpp b/buildtools/lib/parsers/qmake/qmakeast.cpp
index 91e48d2d..c551abef 100644
--- a/buildtools/lib/parsers/qmake/qmakeast.cpp
+++ b/buildtools/lib/parsers/qmake/qmakeast.cpp
@@ -21,34 +21,34 @@
#include <kdebug.h>
-namespace QMake {
+namespace TQMake {
//AST
AST::~AST()
{
- for (TQValueList<AST*>::iterator it = m_children.begin(); it != m_children.end(); ++it)
+ for (TQValueList<AST*>::iterator it = m_tqchildren.begin(); it != m_tqchildren.end(); ++it)
{
AST *node = *it;
delete node;
}
- m_children.clear();
+ m_tqchildren.clear();
}
void AST::addChildAST(AST *node)
{
- m_children.append(node);
+ m_tqchildren.append(node);
}
void AST::removeChildAST(AST *node)
{
- m_children.remove(node);
+ m_tqchildren.remove(node);
}
void AST::writeBack(TQString &buffer)
{
- for (TQValueList<AST*>::const_iterator it = m_children.constBegin();
- it != m_children.constEnd(); ++it)
+ for (TQValueList<AST*>::const_iterator it = m_tqchildren.constBegin();
+ it != m_tqchildren.constEnd(); ++it)
{
if (*it)
{
@@ -70,7 +70,7 @@ TQString AST::indentation()
void ProjectAST::writeBack(TQString &buffer)
{
bool hasActualStatements = false;
- for (TQValueList<QMake::AST*>::const_iterator it = m_children.begin(); it != m_children.end(); ++it)
+ for (TQValueList<TQMake::AST*>::const_iterator it = m_tqchildren.begin(); it != m_tqchildren.end(); ++it)
{
if ((*it)->nodeType() != AST::IncludeAST)
{
@@ -84,7 +84,7 @@ void ProjectAST::writeBack(TQString &buffer)
if( !buffer.endsWith(": ") )
buffer += indentation();
buffer += scopedID;
- if( m_children.count() == 1 )
+ if( m_tqchildren.count() == 1 )
buffer += " : ";
else
buffer += " {";
@@ -94,9 +94,9 @@ void ProjectAST::writeBack(TQString &buffer)
if( !buffer.endsWith(": ") )
buffer += indentation();
buffer += scopedID + "(" + args + ")";
- if( m_children.count() == 1 && hasActualStatements )
+ if( m_tqchildren.count() == 1 && hasActualStatements )
buffer += ": ";
- else if( (m_children.count() > 0 && hasActualStatements) )
+ else if( (m_tqchildren.count() > 0 && hasActualStatements) )
buffer += "{";
else
buffer += "";
@@ -104,10 +104,10 @@ void ProjectAST::writeBack(TQString &buffer)
else if( !buffer.endsWith(": ") )
buffer += indentation();
AST::writeBack(buffer);
- if (isScope() && m_children.count() > 1 )
+ if (isScope() && m_tqchildren.count() > 1 )
buffer += indentation() + "}";
- if (isFunctionScope() && (hasActualStatements) && m_children.count() > 1)
+ if (isFunctionScope() && (hasActualStatements) && m_tqchildren.count() > 1)
buffer += indentation() + "}";
}
@@ -165,6 +165,6 @@ void IncludeAST::writeBack(TQString &/*buffer*/)
}
-// kate: space-indent on; indent-width 4; tab-width 4; replace-tabs on
+// kate: space-indent on; indent-width 4; tab-width 4; tqreplace-tabs on
diff --git a/buildtools/lib/parsers/qmake/qmakeast.h b/buildtools/lib/parsers/qmake/qmakeast.h
index 45aedb2e..e2abba70 100644
--- a/buildtools/lib/parsers/qmake/qmakeast.h
+++ b/buildtools/lib/parsers/qmake/qmakeast.h
@@ -17,8 +17,8 @@
* Free Software Foundation, Inc., *
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
***************************************************************************/
-#ifndef QMAKEQMAKEAST_H
-#define QMAKEQMAKEAST_H
+#ifndef TQMAKETQMAKEAST_H
+#define TQMAKETQMAKEAST_H
#include <tqstringlist.h>
@@ -27,13 +27,13 @@
Abstract Syntax Tree (AST) class declarations.
*/
-namespace QMake {
+namespace TQMake {
/**
AST node.
This is the base class. Objects of this type are not created by the parser.
-Each AST node holds the list of its children which are always deleted in the
+Each AST node holds the list of its tqchildren which are always deleted in the
destructor. This way, it's possible call delete for only root AST node and
others will be deleted automatically.
@@ -79,7 +79,7 @@ public:
virtual TQString indentation();
/**The list of child AST nodes.*/
- TQValueList<AST*> m_children;
+ TQValueList<AST*> m_tqchildren;
protected:
NodeType m_nodeType;
diff --git a/buildtools/lib/parsers/qmake/qmakeastvisitor.cpp b/buildtools/lib/parsers/qmake/qmakeastvisitor.cpp
index 1f7e6cb6..b9470bd9 100644
--- a/buildtools/lib/parsers/qmake/qmakeastvisitor.cpp
+++ b/buildtools/lib/parsers/qmake/qmakeastvisitor.cpp
@@ -19,7 +19,7 @@
***************************************************************************/
#include "qmakeastvisitor.h"
-namespace QMake {
+namespace TQMake {
void ASTVisitor::processProject(ProjectAST *project)
{
@@ -29,31 +29,31 @@ void ASTVisitor::processProject(ProjectAST *project)
enterScope(project);
else if (project->isFunctionScope())
enterFunctionScope(project);
- for (TQValueList<QMake::AST*>::const_iterator it = project->m_children.constBegin();
- it != project->m_children.constEnd(); ++it)
+ for (TQValueList<TQMake::AST*>::const_iterator it = project->m_tqchildren.constBegin();
+ it != project->m_tqchildren.constEnd(); ++it)
{
AST *ast = *it;
if (ast == 0)
continue;
switch (ast->nodeType()) {
case AST::AssignmentAST:
- processAssignment(static_cast<QMake::AssignmentAST*>(ast));
+ processAssignment(static_cast<TQMake::AssignmentAST*>(ast));
break;
case AST::NewLineAST:
- processNewLine(static_cast<QMake::NewLineAST*>(ast));
+ processNewLine(static_cast<TQMake::NewLineAST*>(ast));
break;
case AST::CommentAST:
- processComment(static_cast<QMake::CommentAST*>(ast));
+ processComment(static_cast<TQMake::CommentAST*>(ast));
break;
case AST::ProjectAST:
- processProject(static_cast<QMake::ProjectAST*>(ast));
+ processProject(static_cast<TQMake::ProjectAST*>(ast));
break;
case AST::IncludeAST:
- processInclude(static_cast<QMake::IncludeAST*>(ast));
+ processInclude(static_cast<TQMake::IncludeAST*>(ast));
break;
}
}
diff --git a/buildtools/lib/parsers/qmake/qmakeastvisitor.h b/buildtools/lib/parsers/qmake/qmakeastvisitor.h
index 3db9d14d..6978074c 100644
--- a/buildtools/lib/parsers/qmake/qmakeastvisitor.h
+++ b/buildtools/lib/parsers/qmake/qmakeastvisitor.h
@@ -17,12 +17,12 @@
* Free Software Foundation, Inc., *
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
***************************************************************************/
-#ifndef QMAKEQMAKEASTVISITOR_H
-#define QMAKEQMAKEASTVISITOR_H
+#ifndef TQMAKETQMAKEASTVISITOR_H
+#define TQMAKETQMAKEASTVISITOR_H
#include "qmakeast.h"
-namespace QMake {
+namespace TQMake {
class ASTVisitor{
public:
diff --git a/buildtools/lib/parsers/qmake/qmakedriver.cpp b/buildtools/lib/parsers/qmake/qmakedriver.cpp
index e2d93ef8..09256178 100644
--- a/buildtools/lib/parsers/qmake/qmakedriver.cpp
+++ b/buildtools/lib/parsers/qmake/qmakedriver.cpp
@@ -30,7 +30,7 @@
#include "qmake_lex.h"
#include "qmake_yacc.hpp"
-namespace QMake {
+namespace TQMake {
int Driver::parseFile(const char *fileName, ProjectAST **ast, int debug)
{
@@ -52,15 +52,15 @@ int Driver::parseFile(const char *fileName, ProjectAST **ast, int debug)
(*ast)->setFileName(fileName);
switch( l.lineending() )
{
- case QMake::Lexer::Windows:
- (*ast)->setLineEnding(QMake::ProjectAST::Windows);
+ case TQMake::Lexer::Windows:
+ (*ast)->setLineEnding(TQMake::ProjectAST::Windows);
break;
- case QMake::Lexer::MacOS:
- (*ast)->setLineEnding(QMake::ProjectAST::MacOS);
+ case TQMake::Lexer::MacOS:
+ (*ast)->setLineEnding(TQMake::ProjectAST::MacOS);
break;
- case QMake::Lexer::Unix:
+ case TQMake::Lexer::Unix:
default:
- (*ast)->setLineEnding(QMake::ProjectAST::Unix);
+ (*ast)->setLineEnding(TQMake::ProjectAST::Unix);
break;
}
return ret;
@@ -96,15 +96,15 @@ int Driver::parseString( const char* string, ProjectAST **ast, int debug )
(*ast)->setFileName("");
switch( l.lineending() )
{
- case QMake::Lexer::Windows:
- (*ast)->setLineEnding(QMake::ProjectAST::Windows);
+ case TQMake::Lexer::Windows:
+ (*ast)->setLineEnding(TQMake::ProjectAST::Windows);
break;
- case QMake::Lexer::MacOS:
- (*ast)->setLineEnding(QMake::ProjectAST::MacOS);
+ case TQMake::Lexer::MacOS:
+ (*ast)->setLineEnding(TQMake::ProjectAST::MacOS);
break;
- case QMake::Lexer::Unix:
+ case TQMake::Lexer::Unix:
default:
- (*ast)->setLineEnding(QMake::ProjectAST::Unix);
+ (*ast)->setLineEnding(TQMake::ProjectAST::Unix);
break;
}
return ret;
diff --git a/buildtools/lib/parsers/qmake/qmakedriver.h b/buildtools/lib/parsers/qmake/qmakedriver.h
index 918054fa..ee56f388 100644
--- a/buildtools/lib/parsers/qmake/qmakedriver.h
+++ b/buildtools/lib/parsers/qmake/qmakedriver.h
@@ -17,13 +17,13 @@
* Free Software Foundation, Inc., *
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
***************************************************************************/
-#ifndef QMAKEQMAKEDRIVER_H
-#define QMAKEQMAKEDRIVER_H
+#ifndef TQMAKETQMAKEDRIVER_H
+#define TQMAKETQMAKEDRIVER_H
class TQString;
class KURL;
-namespace QMake {
+namespace TQMake {
/**
@file qmakedriver.h
diff --git a/buildtools/lib/parsers/qmake/stack.hh b/buildtools/lib/parsers/qmake/stack.hh
index b81e4a28..07f71922 100644
--- a/buildtools/lib/parsers/qmake/stack.hh
+++ b/buildtools/lib/parsers/qmake/stack.hh
@@ -19,7 +19,7 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor,
Boston, MA 02110-1301, USA. */
-/* As a special exception, you may create a larger work that contains
+/* As a special exception, you may create a larger work that tqcontains
part or all of the Bison parser skeleton and distribute that work
under terms of your choice, so long as that work isn't itself a
parser generator using the skeleton or a modified version thereof
@@ -37,7 +37,7 @@
#include <deque>
-namespace QMake
+namespace TQMake
{
template <class T, class S = std::deque<T> >
class stack
diff --git a/buildtools/lib/parsers/qmake/tests/runner.cpp b/buildtools/lib/parsers/qmake/tests/runner.cpp
index 6f1d5956..5dd417db 100644
--- a/buildtools/lib/parsers/qmake/tests/runner.cpp
+++ b/buildtools/lib/parsers/qmake/tests/runner.cpp
@@ -21,8 +21,8 @@
#include <cstdlib>
#include <iostream>
#include <stdio.h>
-#include "qmakedriver.h"
-#include "qmakeastvisitor.h"
+#include "tqmakedriver.h"
+#include "tqmakeastvisitor.h"
#include <tqstring.h>
@@ -34,92 +34,92 @@ static const KCmdLineOptions options[] =
{
{"silent", "Enable Parser debug output", 0},
{"!debug", "Disable output of the generated AST", 0},
- {"!+files", "QMake project files", 0}
+ {"!+files", "TQMake project files", 0}
};
-class PrintAST : QMake::ASTVisitor
+class PrintAST : TQMake::ASTVisitor
{
public:
- PrintAST() : QMake::ASTVisitor()
+ PrintAST() : TQMake::ASTVisitor()
{
indent = 0;
}
- virtual void processProject( QMake::ProjectAST* p )
+ virtual void processProject( TQMake::ProjectAST* p )
{
- QMake::ASTVisitor::processProject(p);
+ TQMake::ASTVisitor::processProject(p);
}
private:
- virtual void enterRealProject( QMake::ProjectAST* p )
+ virtual void enterRealProject( TQMake::ProjectAST* p )
{
kdDebug(9024) << getIndent() << "--------- Entering Project: " << replaceWs(p->fileName()) << "| LineEnding:" << p->lineEnding() << " --------------" << endl;
indent += 4;
- QMake::ASTVisitor::enterRealProject(p);
+ TQMake::ASTVisitor::enterRealProject(p);
}
- virtual void leaveRealProject( QMake::ProjectAST* p )
+ virtual void leaveRealProject( TQMake::ProjectAST* p )
{
indent -= 4;
kdDebug(9024) << getIndent() << "--------- Leaving Project: " << replaceWs(p->fileName()) << " --------------" << endl;
- QMake::ASTVisitor::leaveRealProject(p);
+ TQMake::ASTVisitor::leaveRealProject(p);
}
- virtual void enterScope( QMake::ProjectAST* p )
+ virtual void enterScope( TQMake::ProjectAST* p )
{
kdDebug(9024) << getIndent() << "--------- Entering Scope: " << replaceWs(p->scopedID) << " --------------" << endl;
indent += 4;
- QMake::ASTVisitor::enterScope(p);
+ TQMake::ASTVisitor::enterScope(p);
}
- virtual void leaveScope( QMake::ProjectAST* p )
+ virtual void leaveScope( TQMake::ProjectAST* p )
{
indent -= 4;
kdDebug(9024) << getIndent() << "--------- Leaving Scope: " << replaceWs(p->scopedID) << " --------------" << endl;
- QMake::ASTVisitor::leaveScope(p);
+ TQMake::ASTVisitor::leaveScope(p);
}
- virtual void enterFunctionScope( QMake::ProjectAST* p )
+ virtual void enterFunctionScope( TQMake::ProjectAST* p )
{
kdDebug(9024) << getIndent() << "--------- Entering FunctionScope: " << replaceWs(p->scopedID) << "(" << replaceWs(p->args) << ")"<< " --------------" << endl;
indent += 4;
- QMake::ASTVisitor::enterFunctionScope(p);
+ TQMake::ASTVisitor::enterFunctionScope(p);
}
- virtual void leaveFunctionScope( QMake::ProjectAST* p )
+ virtual void leaveFunctionScope( TQMake::ProjectAST* p )
{
indent -= 4;
kdDebug(9024) << getIndent() << "--------- Leaving FunctionScope: " << replaceWs(p->scopedID) << "(" << replaceWs(p->args) << ")"<< " --------------" << endl;
- QMake::ASTVisitor::leaveFunctionScope(p);
+ TQMake::ASTVisitor::leaveFunctionScope(p);
}
TQString replaceWs(TQString s)
{
- return s.replace("\n", "%nl").replace("\t", "%tab").replace(" ", "%spc");
+ return s.tqreplace("\n", "%nl").tqreplace("\t", "%tab").tqreplace(" ", "%spc");
}
- virtual void processAssignment( QMake::AssignmentAST* a)
+ virtual void processAssignment( TQMake::AssignmentAST* a)
{
kdDebug(9024) << getIndent() << "Assignment(" << replaceWs(a->indent) << "):" << replaceWs(a->scopedID) << " " << replaceWs(a->op) << " " << replaceWs(a->values.join("|")) << endl;
- QMake::ASTVisitor::processAssignment(a);
+ TQMake::ASTVisitor::processAssignment(a);
}
- virtual void processNewLine( QMake::NewLineAST* n)
+ virtual void processNewLine( TQMake::NewLineAST* n)
{
kdDebug(9024) << getIndent() << "Newline " << endl;
- QMake::ASTVisitor::processNewLine(n);
+ TQMake::ASTVisitor::processNewLine(n);
}
- virtual void processComment( QMake::CommentAST* a)
+ virtual void processComment( TQMake::CommentAST* a)
{
kdDebug(9024) << getIndent() << "Comment: " << replaceWs(a->comment) << endl;
- QMake::ASTVisitor::processComment(a);
+ TQMake::ASTVisitor::processComment(a);
}
- virtual void processInclude( QMake::IncludeAST* a)
+ virtual void processInclude( TQMake::IncludeAST* a)
{
kdDebug(9024) << getIndent() << "Include: " << replaceWs(a->projectName) << endl;
- QMake::ASTVisitor::processInclude(a);
+ TQMake::ASTVisitor::processInclude(a);
}
TQString getIndent()
@@ -133,7 +133,7 @@ private:
};
int main(int argc, char *argv[])
{
- KCmdLineArgs::init( argc, argv, "QMake Parser", "qmake-parser", "Parse QMake project files", "1.0.0");
+ KCmdLineArgs::init( argc, argv, "TQMake Parser", "qmake-parser", "Parse TQMake project files", "1.0.0");
KCmdLineArgs::addCmdLineOptions(options);
KCmdLineArgs *args = KCmdLineArgs::parsedArgs();
@@ -152,8 +152,8 @@ int main(int argc, char *argv[])
debug = 1;
for( int i = 0 ; i < args->count() ; i++ )
{
- QMake::ProjectAST *projectAST;
- int ret = QMake::Driver::parseFile(args->url(i).path(), &projectAST, debug);
+ TQMake::ProjectAST *projectAST;
+ int ret = TQMake::Driver::parseFile(args->url(i).path(), &projectAST, debug);
PrintAST pa;
if ( ret == 0 )
if ( !silent )
@@ -161,7 +161,7 @@ int main(int argc, char *argv[])
pa.processProject(projectAST);
TQString profile;
projectAST->writeBack(profile);
- kdDebug(9024) << "QMake file written back:\n" << profile << endl;
+ kdDebug(9024) << "TQMake file written back:\n" << profile << endl;
}
return ret;
}
diff --git a/buildtools/lib/parsers/qmake/tests/viewer.cpp b/buildtools/lib/parsers/qmake/tests/viewer.cpp
index 4583ab11..6f1e5f25 100644
--- a/buildtools/lib/parsers/qmake/tests/viewer.cpp
+++ b/buildtools/lib/parsers/qmake/tests/viewer.cpp
@@ -29,14 +29,14 @@
#include <tqlistview.h>
#include <tqtabwidget.h>
-#include <qmakeast.h>
-#include <qmakedriver.h>
-#include <qmakeastvisitor.h>
+#include <tqmakeast.h>
+#include <tqmakedriver.h>
+#include <tqmakeastvisitor.h>
-using namespace QMake;
+using namespace TQMake;
-Viewer::Viewer(TQWidget *parent, const char *name)
- :ViewerBase(parent, name), projectAST(0)
+Viewer::Viewer(TQWidget *tqparent, const char *name)
+ :ViewerBase(tqparent, name), projectAST(0)
{
if (TQFile::exists(TQDir::currentDirPath() + "/" + "qtlist"))
{
@@ -47,7 +47,7 @@ Viewer::Viewer(TQWidget *parent, const char *name)
files->insertItem(str.readLine());
}
ast->setSorting(-1);
-// parentProject.push((TQListViewItem*)0);
+// tqparentProject.push((TQListViewItem*)0);
}
void Viewer::addAll_clicked()
@@ -78,7 +78,7 @@ void Viewer::files_currentChanged(TQListBoxItem* item)
source->setText(str.read());
f.close();
- int result = QMake::Driver::parseFile(item->text().ascii(), &projectAST, 0);
+ int result = TQMake::Driver::parseFile(item->text().ascii(), &projectAST, 0);
if (projectAST && (result == 0))
{
processAST(projectAST);
@@ -102,7 +102,7 @@ public:
ViewerVisitor(Viewer *v): ASTVisitor()
{
this->v = v;
- parentProject.push((TQListViewItem*)0);
+ tqparentProject.push((TQListViewItem*)0);
}
virtual void processProject(ProjectAST *project)
@@ -113,39 +113,39 @@ public:
virtual void enterRealProject(ProjectAST *project)
{
TQListViewItem *projectIt;
- if (!parentProject.top())
+ if (!tqparentProject.top())
{
projectIt = new TQListViewItem(v->ast, "Project");
projectIt->setOpen(true);
- parentProject.push(projectIt);
+ tqparentProject.push(projectIt);
}
ASTVisitor::enterRealProject(project);
}
virtual void enterScope(ProjectAST *scope)
{
- TQListViewItem *projectIt = new TQListViewItem(parentProject.top(), scope->scopedID, "scope");
- parentProject.push(projectIt);
+ TQListViewItem *projectIt = new TQListViewItem(tqparentProject.top(), scope->scopedID, "scope");
+ tqparentProject.push(projectIt);
ASTVisitor::enterScope(scope);
}
virtual void leaveScope(ProjectAST *scope)
{
- parentProject.pop();
+ tqparentProject.pop();
}
virtual void enterFunctionScope(ProjectAST *fscope)
{
- TQListViewItem *projectIt = new TQListViewItem(parentProject.top(),
+ TQListViewItem *projectIt = new TQListViewItem(tqparentProject.top(),
fscope->scopedID + "(" + fscope->args + ")", "function scope");
- parentProject.push(projectIt);
+ tqparentProject.push(projectIt);
ASTVisitor::enterFunctionScope(fscope);
}
virtual void leaveFunctionScope(ProjectAST *fscope)
{
- parentProject.pop();
+ tqparentProject.pop();
}
virtual void processAssignment(AssignmentAST *assignment)
{
- TQListViewItem *item = new TQListViewItem(parentProject.top(),
+ TQListViewItem *item = new TQListViewItem(tqparentProject.top(),
assignment->scopedID, assignment->op, assignment->values.join("|"),
"assignment");
item->setMultiLinesEnabled(true);
@@ -154,26 +154,26 @@ public:
}
virtual void processNewLine(NewLineAST *newline)
{
- new TQListViewItem(parentProject.top(), "<newline>");
+ new TQListViewItem(tqparentProject.top(), "<newline>");
ASTVisitor::processNewLine(newline);
}
virtual void processComment(CommentAST *comment)
{
- new TQListViewItem(parentProject.top(), "<comment>");
+ new TQListViewItem(tqparentProject.top(), "<comment>");
ASTVisitor::processComment(comment);
}
virtual void processInclude(IncludeAST *include)
{
- new TQListViewItem(parentProject.top(), "<include>", include->projectName);
- QMake::ASTVisitor::processInclude(include);
+ new TQListViewItem(tqparentProject.top(), "<include>", include->projectName);
+ TQMake::ASTVisitor::processInclude(include);
}
Viewer *v;
- TQValueStack<TQListViewItem *> parentProject;
+ TQValueStack<TQListViewItem *> tqparentProject;
};
-void Viewer::processAST(QMake::ProjectAST *projectAST, TQListViewItem *globAfter)
+void Viewer::processAST(TQMake::ProjectAST *projectAST, TQListViewItem *globAfter)
{
ViewerVisitor visitor(this);
visitor.processProject(projectAST);
diff --git a/buildtools/lib/parsers/qmake/tests/viewer.h b/buildtools/lib/parsers/qmake/tests/viewer.h
index bba85b1f..28a7613c 100644
--- a/buildtools/lib/parsers/qmake/tests/viewer.h
+++ b/buildtools/lib/parsers/qmake/tests/viewer.h
@@ -24,7 +24,7 @@
#include "viewerbase.h"
-namespace QMake {
+namespace TQMake {
class ProjectAST;
}
@@ -32,16 +32,17 @@ class TQListViewItem;
class Viewer: public ViewerBase {
Q_OBJECT
+ TQ_OBJECT
public:
- Viewer(TQWidget *parent = 0, const char *name = 0);
- void processAST(QMake::ProjectAST *projectAST, TQListViewItem *globAfter = 0);
+ Viewer(TQWidget *tqparent = 0, const char *name = 0);
+ void processAST(TQMake::ProjectAST *projectAST, TQListViewItem *globAfter = 0);
public slots:
virtual void tabWidget2_selected(const TQString&);
virtual void files_currentChanged(TQListBoxItem*);
virtual void choose_clicked();
virtual void addAll_clicked();
private:
- QMake::ProjectAST *projectAST;
+ TQMake::ProjectAST *projectAST;
friend class ViewerVisitor;
};
diff --git a/buildtools/lib/parsers/qmake/tests/viewer_main.cpp b/buildtools/lib/parsers/qmake/tests/viewer_main.cpp
index c31ea02c..199b106d 100644
--- a/buildtools/lib/parsers/qmake/tests/viewer_main.cpp
+++ b/buildtools/lib/parsers/qmake/tests/viewer_main.cpp
@@ -27,7 +27,7 @@ int main(int argc, char **argv)
Viewer viewer;
app.setMainWidget(&viewer);
viewer.show();
- viewer.setWindowState(viewer.windowState() | Qt::WindowMaximized);
+ viewer.setWindowState(viewer.windowState() | TQt::WindowMaximized);
return app.exec();
}
diff --git a/buildtools/lib/parsers/qmake/tests/viewerbase.ui b/buildtools/lib/parsers/qmake/tests/viewerbase.ui
index 976d4d0f..c37f41bf 100644
--- a/buildtools/lib/parsers/qmake/tests/viewerbase.ui
+++ b/buildtools/lib/parsers/qmake/tests/viewerbase.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>ViewerBase</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>ViewerBase</cstring>
</property>
@@ -19,37 +19,37 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QSplitter" row="0" column="0">
+ <widget class="TQSplitter" row="0" column="0">
<property name="name">
<cstring>splitter5</cstring>
</property>
<property name="orientation">
<enum>Horizontal</enum>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout4</cstring>
+ <cstring>tqlayout4</cstring>
</property>
<vbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLineEdit">
+ <widget class="TQLineEdit">
<property name="name">
<cstring>allLocation</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>32767</height>
</size>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>addAll</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>32767</height>
@@ -59,11 +59,11 @@
<string>Add All From Directory</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>choose</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>32767</height>
@@ -73,7 +73,7 @@
<string>Choose File to Add...</string>
</property>
</widget>
- <widget class="QListBox">
+ <widget class="TQListBox">
<property name="name">
<cstring>files</cstring>
</property>
@@ -85,7 +85,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>32767</height>
@@ -97,14 +97,14 @@
</widget>
</vbox>
</widget>
- <widget class="QSplitter">
+ <widget class="TQSplitter">
<property name="name">
<cstring>splitter2</cstring>
</property>
<property name="orientation">
<enum>Vertical</enum>
</property>
- <widget class="QTextEdit">
+ <widget class="TQTextEdit">
<property name="name">
<cstring>source</cstring>
</property>
@@ -117,7 +117,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QTabWidget">
+ <widget class="TQTabWidget">
<property name="name">
<cstring>tabWidget2</cstring>
</property>
@@ -129,7 +129,7 @@
<verstretch>2</verstretch>
</sizepolicy>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>tab</cstring>
</property>
@@ -140,7 +140,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QListView" row="0" column="0">
+ <widget class="TQListView" row="0" column="0">
<column>
<property name="text">
<string>Name</string>
@@ -191,7 +191,7 @@
</widget>
</grid>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>tab</cstring>
</property>
@@ -202,7 +202,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QTextEdit" row="0" column="0">
+ <widget class="TQTextEdit" row="0" column="0">
<property name="name">
<cstring>writeBack</cstring>
</property>
@@ -240,11 +240,11 @@
<slot>tabWidget2_selected(const QString&amp;)</slot>
</connection>
</connections>
-<slots>
+<Q_SLOTS>
<slot>addAll_clicked()</slot>
<slot>choose_clicked()</slot>
<slot>files_currentChanged( QListBoxItem * )</slot>
<slot>tabWidget2_selected( const QString &amp; )</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>