Do rename qt=>tqt on source files, directories and libraries.

Rename pyuic=>pytquic, pylupdate=>pytqlupdate.
Do rename qt=>tqt on constants and variables.
Do rename QT=>TQT on constants.

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
pull/13/head
Slávek Banko 1 year ago
parent 1c362264d3
commit 16434e5519
No known key found for this signature in database
GPG Key ID: 608F5293A04BE668

@ -19,7 +19,7 @@
#
# This is the build script for PyTQt. It should be run in the top level
# directory of the source distribution and by the Python interpreter for which
# it is being built. It uses either qmake or tmake to do the hard work of
# it is being built. It uses either tqmake or tmake to do the hard work of
# generating the platform specific Makefiles.
@ -46,14 +46,14 @@ config = sip_tqt_config.SIPConfig("PyTQt 3.18.1")
# Initialise the globals.
sipMajorVersion = config.sip_version >> 16
sciIncDir = config.qt_inc_dir
sciLibDir = config.qt_lib_dir
sciIncDir = config.tqt_inc_dir
sciLibDir = config.tqt_lib_dir
sciLib = None
sciVersion = None
binDir = config.default_bin_dir
modDir = config.default_mod_dir
sipDir = config.default_sip_dir
buildModules = ["qt"]
buildModules = ["tqt"]
tempBuildDir = None
catCppFiles = 0
catSplit = 1
@ -71,14 +71,14 @@ def usage(rcode = 2):
print(" %s [-h] [-a version] [-b dir] [-c] [-d dir] [-g] [-j #] [-n dir] [-o dir] [-r] [-v dir]" % sip_tqt_config.script())
print("where:")
print(" -h display this help message")
print(" -a tag explicitly enable the qtpe module")
print(" -a tag explicitly enable the tqtpe module")
print(" -b dir where pyuic and pylupdate will be installed [default %s]" % config.default_bin_dir)
print(" -c concatenate each module's C++ source files")
print(" -d dir where the PyTQt modules will be installed [default %s]" % config.default_mod_dir)
print(" -g always release the GIL (SIP-TQt v3.x behaviour)")
print(" -j # split the concatenated C++ source files into # pieces [default 1]")
print(" -n dir the directory containing the TQScintilla header files [default %s]" % config.qt_inc_dir)
print(" -o dir the directory containing the TQScintilla library [default %s]" % config.qt_lib_dir)
print(" -n dir the directory containing the TQScintilla header files [default %s]" % config.tqt_inc_dir)
print(" -o dir the directory containing the TQScintilla library [default %s]" % config.tqt_lib_dir)
print(" -r generate code with tracing enabled [default disabled]")
print(" -v dir where the PyTQt .sip files will be installed [default %s]" % config.default_sip_dir)
@ -87,7 +87,7 @@ def usage(rcode = 2):
def mkTempBuildDir(olddir=None):
"""Create a temporary build directory for a console application called
qttest, complete with patched Makefile. The global tempBuildDir is set to
tqttest, complete with patched Makefile. The global tempBuildDir is set to
the name of the directory. The temporary directory becomes the current
directory.
@ -107,26 +107,26 @@ def mkTempBuildDir(olddir=None):
prevdir = sip_tqt_config.push_dir(tempBuildDir)
sip_tqt_config.copy_to_file("qttest.pro.in",
sip_tqt_config.copy_to_file("tqttest.pro.in",
"""TEMPLATE = app
TARGET = qttest
TARGET = tqttest
CONFIG += console warn_off @TEST_OPENGL@ @BLX_CONFIG_APP@
INCLUDEPATH = @BLX_INCLUDEPATH@ @TEST_QSCINTILLA_INC@
INCLUDEPATH = @BLX_INCLUDEPATH@ @TEST_TQSCINTILLA_INC@
DEFINES = @BLX_DEFINES@
SOURCES = qttest.cpp
LIBS += @TEST_QUI_LIB@ @TEST_QSCINTILLA_LIB@
SOURCES = tqttest.cpp
LIBS += @TEST_TQUI_LIB@ @TEST_TQSCINTILLA_LIB@
""")
# Disable OpenGL, tqui and TQScintilla support by default.
config.patches["@TEST_OPENGL@"] = ""
config.patches["@TEST_QUI_LIB@"] = ""
config.patches["@TEST_QSCINTILLA_INC@"] = ""
config.patches["@TEST_QSCINTILLA_LIB@"] = ""
config.patches["@TEST_TQUI_LIB@"] = ""
config.patches["@TEST_TQSCINTILLA_INC@"] = ""
config.patches["@TEST_TQSCINTILLA_LIB@"] = ""
# Create a dummy source file to suppress a qmake warning.
sip_tqt_config.copy_to_file("qttest.cpp", "")
sip_tqt_config.copy_to_file("tqttest.cpp", "")
config.create_makefile("qttest.pro")
config.create_makefile("tqttest.pro")
else:
sip_tqt_config.pop_dir(olddir)
prevdir = None
@ -152,7 +152,7 @@ def tryModule(maindir, mname, incfile, ctor):
if not os.access(msip, os.F_OK):
return
sip_tqt_config.copy_to_file("qttest.cpp",
sip_tqt_config.copy_to_file("tqttest.cpp",
"""#include <%s>
int main(int argc,char **argv)
@ -177,7 +177,7 @@ def checkTQScintilla():
sciglobal = os.path.join(sciIncDir, "tqextscintillaglobal.h")
if os.access(sciglobal,os.F_OK):
config.patches["@PYQT_QSCINTILLA_INC@"] = sciIncDir
config.patches["@PYTQT_TQSCINTILLA_INC@"] = sciIncDir
sip_tqt_config.inform("%s contains tqextscintillaglobal.h." % (sciIncDir))
@ -209,13 +209,13 @@ def checkTQScintilla():
else:
sciLib = sip_tqt_config.escape("-L" + sciLibDir) + " -ltqscintilla"
config.patches["@PYQT_QSCINTILLA_LIB@"] = sciLib
config.patches["@PYTQT_TQSCINTILLA_LIB@"] = sciLib
else:
sip_tqt_config.inform("The TQScintilla library could not be found in %s and so the qtext module will not be built. If TQScintilla is installed then use the -o argument to explicitly specify the correct directory." % (sciLibDir))
sip_tqt_config.inform("The TQScintilla library could not be found in %s and so the tqtext module will not be built. If TQScintilla is installed then use the -o argument to explicitly specify the correct directory." % (sciLibDir))
sciVersion = -1
else:
sip_tqt_config.inform("tqextscintillaglobal.h could not be found in %s and so the qtext module will not be built. If TQScintilla is installed then use the -n argument to explicitly specify the correct directory." % sciIncDir)
sip_tqt_config.inform("tqextscintillaglobal.h could not be found in %s and so the tqtext module will not be built. If TQScintilla is installed then use the -n argument to explicitly specify the correct directory." % sciIncDir)
sciVersion = -1
@ -225,54 +225,54 @@ def moduleChecks(maindir):
"""
sip_tqt_config.inform("Checking which additional PyTQt modules to build.");
tryModule(maindir,"qtcanvas", "qcanvas.h", "TQCanvas()")
tryModule(maindir,"qtnetwork", "qsocket.h", "TQSocket()")
tryModule(maindir,"qttable", "qtable.h", "TQTable()")
tryModule(maindir,"qtxml", "qdom.h", "TQDomImplementation()")
tryModule(maindir,"tqtcanvas", "tqcanvas.h", "TQCanvas()")
tryModule(maindir,"tqtnetwork", "tqsocket.h", "TQSocket()")
tryModule(maindir,"tqttable", "tqtable.h", "TQTable()")
tryModule(maindir,"tqtxml", "tqdom.h", "TQDomImplementation()")
if config.qt_version >= 0x030000:
tryModule(maindir,"qtsql", "qsql.h", "TQSql()")
if config.tqt_version >= 0x030000:
tryModule(maindir,"tqtsql", "tqsql.h", "TQSql()")
# We need a different Makefile for the qtgl module.
# We need a different Makefile for the tqtgl module.
config.patches["@TEST_OPENGL@"] = "opengl"
config.create_makefile("qttest.pro")
config.create_makefile("tqttest.pro")
tryModule(maindir,"qtgl", "qgl.h", "TQGLWidget()")
tryModule(maindir,"tqtgl", "tqgl.h", "TQGLWidget()")
# Put things back.
config.patches["@TEST_OPENGL@"] = ""
config.create_makefile("qttest.pro")
config.create_makefile("tqttest.pro")
# Check for the tqui library.
if config.qt_version >= 0x030000:
if config.tqt_version >= 0x030000:
if sys.platform == "win32":
tquilib = r"$(TQTDIR)\lib\tqui.lib"
else:
tquilib = "-ltqui"
config.patches["@PYQT_QUI_LIB@"] = tquilib
config.patches["@PYTQT_TQUI_LIB@"] = tquilib
config.patches["@TEST_QUI_LIB@"] = tquilib
config.create_makefile("qttest.pro")
config.patches["@TEST_TQUI_LIB@"] = tquilib
config.create_makefile("tqttest.pro")
tryModule(maindir,"qtui", "qwidgetfactory.h", "TQWidgetFactory()")
tryModule(maindir,"tqtui", "tqwidgetfactory.h", "TQWidgetFactory()")
# Put things back.
config.patches["@TEST_QUI_LIB@"] = ""
config.create_makefile("qttest.pro")
config.patches["@TEST_TQUI_LIB@"] = ""
config.create_makefile("tqttest.pro")
# Check for the TQScintilla library.
if sciVersion >= 0:
config.patches["@TEST_QSCINTILLA_INC@"] = sciIncDir
config.patches["@TEST_QSCINTILLA_LIB@"] = sciLib
config.create_makefile("qttest.pro")
config.patches["@TEST_TQSCINTILLA_INC@"] = sciIncDir
config.patches["@TEST_TQSCINTILLA_LIB@"] = sciLib
config.create_makefile("tqttest.pro")
tryModule(maindir,"qtext", "tqextscintillabase.h", "TQextScintillaBase()")
tryModule(maindir,"tqtext", "tqextscintillabase.h", "TQextScintillaBase()")
# Put things back.
config.patches["@TEST_QSCINTILLA_INC@"] = ""
config.patches["@TEST_QSCINTILLA_LIB@"] = ""
config.create_makefile("qttest.pro")
config.patches["@TEST_TQSCINTILLA_INC@"] = ""
config.patches["@TEST_TQSCINTILLA_LIB@"] = ""
config.create_makefile("tqttest.pro")
def generateFeatures(featfile):
@ -302,7 +302,7 @@ def generateFeatures(featfile):
"WORKSPACE"]
# Generate the program which will generate the features file.
f = open("qttest.cpp","w")
f = open("tqttest.cpp","w")
# Escape the backslashes so that the name can be embedded in a C++ string.
ffstr = string.replace(featfile, "\\", "\\\\")
@ -328,7 +328,7 @@ int main(int argc,char **argv)
#endif
#if (defined(Q_OS_WIN32) || defined(Q_OS_WIN64)) && TQT_VERSION >= 0x030000
if (qWinVersion() != TQt::WV_XP)
if (tqWinVersion() != TQt::WV_XP)
fprintf(fp,"-x TQt_STYLE_WINDOWSXP\\n");
#endif
""" % (ffstr, ffstr))
@ -352,18 +352,18 @@ int main(int argc,char **argv)
f.close()
sip_tqt_config.run_make()
sip_tqt_config.run_program(os.path.join(os.getcwd(), "qttest"))
sip_tqt_config.run_program(os.path.join(os.getcwd(), "tqttest"))
sip_tqt_config.run_make("clean")
sip_tqt_config.inform("Generated the features file.")
def generateSource(mname, plattag, qttag, xtrtag):
def generateSource(mname, plattag, tqttag, xtrtag):
"""Generate the C++ source code for a particular PyTQt module.
mname is the name of the module.
plattag is the SIP-TQt tag for the platform.
qttag is the SIP-TQt tag for the TQt version.
tqttag is the SIP-TQt tag for the TQt version.
xtrtag is an optional extra SIP-TQt tag.
"""
sip_tqt_config.inform("Generating the C++ source for the %s module." % mname)
@ -381,7 +381,7 @@ def generateSource(mname, plattag, qttag, xtrtag):
pro = mname + ".pro"
argv = ["-t", plattag,
"-t", qttag,
"-t", tqttag,
"-z", "features",
"-I", "sip",
"-m", mname + "/" + pro + ".in",
@ -474,8 +474,8 @@ def main(argv):
if opt == "-h":
usage(0)
elif opt == "-a":
global qpeTag
qpeTag = arg
global tqpeTag
tqpeTag = arg
elif opt == "-b":
global binDir
binDir = arg
@ -522,19 +522,19 @@ def main(argv):
sip_tqt_config.error("Please copy the license file %s to the sip directory.\n" % config.license_file)
# Check the TQt version.
if config.qt_version == 0:
if config.tqt_version == 0:
sip_tqt_config.error("SIP-TQt has been built with TQt support disabled.\n")
# Early versions of TQt for the Mac didn't include everything. Rather than
# maintain these in the future we just mandate a later version.
if sys.platform == "darwin" and config.qt_version < 0x030100:
if sys.platform == "darwin" and config.tqt_version < 0x030100:
sip_tqt_config.error("PyTQt for MacOS/X requires TQt v3.1.0 or later.\n")
# Check the installation directory is valid and add it as a patch.
if not os.access(modDir,os.F_OK):
sip_tqt_config.error("The %s PyTQt destination directory does not seem to exist. Use the -d argument to set the correct directory." % (modDir))
config.patches["@PYQT_MODDIR@"] = sip_tqt_config.escape(modDir)
config.patches["@PYTQT_MODDIR@"] = sip_tqt_config.escape(modDir)
sip_tqt_config.inform("%s is the PyTQt installation directory." % (modDir))
@ -544,7 +544,7 @@ def main(argv):
else:
warn = "warn_off"
config.patches["@PYQT_WARN@"] = warn
config.patches["@PYTQT_WARN@"] = warn
# Create patches to allow some modules to link against others.
if sipMajorVersion >= 4:
@ -552,52 +552,52 @@ def main(argv):
elif sys.platform == "win32":
modlink = sip_tqt_config.escape(os.path.join(modDir, "libtqtc.lib"))
else:
modlink = sip_tqt_config.escape("-L" + modDir) + " -lqtcmodule"
modlink = sip_tqt_config.escape("-L" + modDir) + " -ltqtcmodule"
config.patches["@PYQT_QT_MODULE@"] = modlink
config.patches["@PYTQT_TQT_MODULE@"] = modlink
if sipMajorVersion >= 4:
modlink = ""
elif sys.platform == "win32":
modlink = sip_tqt_config.escape(os.path.join(modDir, "libtqttablec.lib")) + " " + sip_tqt_config.escape(os.path.join(modDir, "libtqtc.lib"))
else:
modlink = sip_tqt_config.escape("-L" + modDir) + " -lqttablecmodule -lqtcmodule"
modlink = sip_tqt_config.escape("-L" + modDir) + " -ltqttablecmodule -ltqtcmodule"
config.patches["@PYQT_QTTABLE_MODULE@"] = modlink
config.patches["@PYTQT_TQTTABLE_MODULE@"] = modlink
# The professional edition needs special handling if XML support is needed.
if config.qt_edition == "professional":
if config.tqt_edition == "professional":
rbprof = "rbprof"
else:
rbprof = ""
config.patches["@PYQT_RBPROF@"] = rbprof
config.patches["@PYTQT_RBPROF@"] = rbprof
# Link in the qassistantclient library for TQt v3.1+.
qaclib = ""
tqaclib = ""
if config.qt_version >= 0x030100:
if config.tqt_version >= 0x030100:
if sys.platform == "win32":
qaclib = r"$(TQTDIR)\lib\qassistantclient.lib"
tqaclib = r"$(TQTDIR)\lib\tqassistantclient.lib"
else:
qaclib = "-lqassistantclient"
tqaclib = "-ltqassistantclient"
config.patches["@PYQT_QASSISTANTCLIENT_LIB@"] = qaclib
config.patches["@PYTQT_QASSISTANTCLIENT_LIB@"] = tqaclib
# Check for TQScintilla.
if config.qt_version >= 0x030000:
if config.tqt_version >= 0x030000:
checkTQScintilla()
# Create a build directory that we can compile test programs.
maindir = mkTempBuildDir()
# Check what additional modules to build.
if config.qt_version >= 0x020000:
if config.tqt_version >= 0x020000:
moduleChecks(maindir)
# Work out the platform and TQt version tags to pass to SIP-TQt to generate the
# code we need.
if config.qt_lib == "qte":
if config.tqt_lib == "tqte":
plattag = "WS_QWS"
elif sys.platform == "win32":
plattag = "WS_WIN"
@ -606,7 +606,7 @@ def main(argv):
else:
plattag = "WS_X11"
qttags = {
tqttags = {
0x020000: "TQt_1_43",
0x020100: "TQt_2_00",
0x020200: "TQt_2_1_0",
@ -626,7 +626,7 @@ def main(argv):
0x040000: "TQt_3_3_0"
}
qttag = versionToTag(config.qt_version, qttags, "TQt")
tqttag = versionToTag(config.tqt_version, tqttags, "TQt")
# Work out the TQScintilla tag.
if sciVersion >= 0:
@ -648,20 +648,20 @@ def main(argv):
subdirs = []
for mname in buildModules:
if mname == "qtext":
if mname == "tqtext":
xtratag = scitag
else:
xtratag = None
generateSource(mname, plattag, qttag, xtratag)
generateSource(mname, plattag, tqttag, xtratag)
subdirs.append(mname)
# We handle the qtpe module explicitly rather than auto-detect. This is
# We handle the tqtpe module explicitly rather than auto-detect. This is
# because it does things a bit differently and I'm too lazy to deal with it
# properly at the moment.
if qpeTag:
generateSource("qtpe", plattag, qttag, qpeTag)
subdirs.append("qtpe")
if tqpeTag:
generateSource("tqtpe", plattag, tqttag, tqpeTag)
subdirs.append("tqtpe")
# Install the .sip files.
sip_tqt_config.inform("Creating Makefile for .sip files.")
@ -683,23 +683,23 @@ def main(argv):
subdirs.append("sip")
# See which version of pyuic to build.
config.patches["@PYQT_BINDIR@"] = sip_tqt_config.escape(binDir)
config.patches["@PYTQT_BINDIR@"] = sip_tqt_config.escape(binDir)
if config.qt_version >= 0x030000:
sip_tqt_config.inform("Creating Makefile for pyuic3.")
subdirs.append("pyuic3")
olddir = sip_tqt_config.push_dir("pyuic3")
if config.tqt_version >= 0x030000:
sip_tqt_config.inform("Creating Makefile for pytquic3.")
subdirs.append("pytquic3")
olddir = sip_tqt_config.push_dir("pytquic3")
config.create_makefile("pyuic.pro", [])
config.create_makefile("pytquic.pro", [])
sip_tqt_config.pop_dir(olddir)
# Build pylupdate if TQt v3.0 or later.
if config.qt_version >= 0x030000:
sip_tqt_config.inform("Creating Makefile for pylupdate3.")
subdirs.append("pylupdate3")
olddir = sip_tqt_config.push_dir("pylupdate3")
if config.tqt_version >= 0x030000:
sip_tqt_config.inform("Creating Makefile for pytqlupdate3.")
subdirs.append("pytqlupdate3")
olddir = sip_tqt_config.push_dir("pytqlupdate3")
config.create_makefile("pylupdate.pro", [])
config.create_makefile("pytqlupdate.pro", [])
sip_tqt_config.pop_dir(olddir)
# Generate the top-level Makefile.

File diff suppressed because it is too large Load Diff

@ -82,7 +82,7 @@ and run this version of PyTQt.</P
><P
><TT
CLASS="LITERAL"
>qt</TT
>tqt</TT
> is the main module and contains the core classes and most
user interface widgets.</P
></LI
@ -90,7 +90,7 @@ user interface widgets.</P
><P
><TT
CLASS="LITERAL"
>qtaxcontainer</TT
>tqtaxcontainer</TT
> contains a sub-set of the classes implemented
in TQt's TQAxContainer module, part of TQt's ActiveTQt framework.</P
></LI
@ -98,7 +98,7 @@ in TQt's TQAxContainer module, part of TQt's ActiveTQt framework.</P
><P
><TT
CLASS="LITERAL"
>qtcanvas</TT
>tqtcanvas</TT
> contains the classes implemented in TQt's Canvas
module.</P
></LI
@ -106,14 +106,14 @@ module.</P
><P
><TT
CLASS="LITERAL"
>qtgl</TT
>tqtgl</TT
> contains the classes implemented in TQt's OpenGL module.</P
></LI
><LI
><P
><TT
CLASS="LITERAL"
>qtnetwork</TT
>tqtnetwork</TT
> contains the classes implemented in TQt's Network
module.</P
></LI
@ -121,7 +121,7 @@ module.</P
><P
><TT
CLASS="LITERAL"
>qtpe</TT
>tqtpe</TT
> contains the classes implemented in TQtopia (originally
called the TQt Palmtop Environment). It is only supported with TQt/Embedded.</P
></LI
@ -129,14 +129,14 @@ called the TQt Palmtop Environment). It is only supported with TQt/Embedded.</P
><P
><TT
CLASS="LITERAL"
>qtsql</TT
>tqtsql</TT
> contains the classes implemented in TQt's SQL module.</P
></LI
><LI
><P
><TT
CLASS="LITERAL"
>qttable</TT
>tqttable</TT
> contains the classes implemented in TQt's Table
module.</P
></LI
@ -144,7 +144,7 @@ module.</P
><P
><TT
CLASS="LITERAL"
>qtui</TT
>tqtui</TT
> contains the classes implemented in TQt's tqui library.
These allow GUIs to be created directly from TQt Designer's
<TT
@ -156,14 +156,14 @@ CLASS="LITERAL"
><P
><TT
CLASS="LITERAL"
>qtxml</TT
>tqtxml</TT
> contains the classes implemented in TQt's XML module.</P
></LI
><LI
><P
><TT
CLASS="LITERAL"
>qtext</TT
>tqtext</TT
> contains useful third-party classes that are not part
of TQt. At the moment it contains bindings for TQScintilla, the port to TQt of
the Scintilla programmer's editor class.</P
@ -172,11 +172,11 @@ the Scintilla programmer's editor class.</P
><P
>PyTQt also includes the <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
> and
<TT
CLASS="LITERAL"
>pylupdate</TT
>pytqlupdate</TT
> utilities which correspond to the TQt
<TT
CLASS="LITERAL"
@ -187,11 +187,11 @@ CLASS="LITERAL"
> utilities.
<TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
> converts the GUI designs created with TQt Designer to
executable Python code. <TT
CLASS="LITERAL"
>pylupdate</TT
>pytqlupdate</TT
> scans Python code,
extracts all strings that are candidates for internationalisation, and creates
an XML file for use by TQt Linguist.</P
@ -223,18 +223,18 @@ CLASS="LITERAL"
><P
>PyTQt includes <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
> which generates Python code from the
same XML. The Python code is self contained and can be executed immediately.</P
><P
>It is sometimes useful to be able to include some specific Python code in the
output generated by <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
>. For example, if you are using
custom widgets, <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
> has no way of knowing the name of the
Python module containing the widget and so cannot generate the required
<TT
@ -243,7 +243,7 @@ CLASS="LITERAL"
> statement. To help get around this,
<TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
> will extract any lines entered in the
<TT
CLASS="LITERAL"
@ -271,7 +271,7 @@ WIDTH="100%"
><TD
><PRE
CLASS="PROGRAMLISTING"
>This comment will be ignored by pyuic.
>This comment will be ignored by pytquic.
Python:
Python:# Import our custom widget.
Python:from foo import bar</PRE
@ -281,7 +281,7 @@ Python:from foo import bar</PRE
><P
>Here's the corresponding output from <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
>.</P
><TABLE
BORDER="0"
@ -291,7 +291,7 @@ WIDTH="100%"
><TD
><PRE
CLASS="PROGRAMLISTING"
>from PyTQt.qt import *
>from PyTQt.tqt import *
# Import our custom widget.
from foo import bar</PRE
@ -301,7 +301,7 @@ from foo import bar</PRE
><P
>Thanks to Christian Bird, <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
> will extract Python code
entered using TQt Designer to implement slots. In TQt Designer, when you need to
edit a slot and the source editor appears, enter Python code between the curly
@ -317,7 +317,7 @@ CLASS="LITERAL"
>.ui</TT
> file when using <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
>. The
<TT
CLASS="LITERAL"
@ -348,7 +348,7 @@ if self.debugging:
><P
>Here is the resulting code when <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
> is run.</P
><TABLE
BORDER="0"
@ -413,7 +413,7 @@ your application.</P
><P
>Thanks to Detlev Offenbach, PyTQt includes the <TT
CLASS="LITERAL"
>pylupdate</TT
>pytqlupdate</TT
>
program. This generates the same <TT
CLASS="LITERAL"
@ -467,7 +467,7 @@ CLASS="SECT1"
NAME="AEN153"
><TT
CLASS="LITERAL"
>pyqtconfig</TT
>pytqtconfig</TT
> and Build System Support</A
></H2
><P
@ -477,14 +477,14 @@ CLASS="LITERAL"
> module) is described
in the SIP documentation. PyTQt includes the <TT
CLASS="LITERAL"
>pyqtconfig</TT
>pytqtconfig</TT
>
module that can be used by configuration scripts of other bindings that are
built on top of PyTQt.</P
><P
>The <TT
CLASS="LITERAL"
>pyqtconfig</TT
>pytqtconfig</TT
> module contains the following classes:</P
><P
></P
@ -514,17 +514,17 @@ CLASS="VARIABLELIST"
><DT
><TT
CLASS="LITERAL"
>pyqt_bin_dir</TT
>pytqt_bin_dir</TT
></DT
><DD
><P
>The name of the directory containing the <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
> and
<TT
CLASS="LITERAL"
>pylupdate</TT
>pytqlupdate</TT
> executables.</P
><P
></P
@ -534,7 +534,7 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_mod_dir</TT
>pytqt_mod_dir</TT
></DT
><DD
><P
@ -547,7 +547,7 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_modules</TT
>pytqt_modules</TT
></DT
><DD
><P
@ -560,18 +560,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qt_sip_flags</TT
>pytqt_tqt_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qt</TT
>tqt</TT
> module and which should be added to those needed by any
module that imports the <TT
CLASS="LITERAL"
>qt</TT
>tqt</TT
> module.</P
><P
></P
@ -581,18 +581,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qtaxcontainer_sip_flags</TT
>pytqt_tqtaxcontainer_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qtaxcontainer</TT
>tqtaxcontainer</TT
> module and which should be added to those
needed by any module that imports the <TT
CLASS="LITERAL"
>qtaxcontainer</TT
>tqtaxcontainer</TT
> module.</P
><P
></P
@ -602,18 +602,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qtcanvas_sip_flags</TT
>pytqt_tqtcanvas_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qtcanvas</TT
>tqtcanvas</TT
> module and which should be added to those needed by
any module that imports the <TT
CLASS="LITERAL"
>qtcanvas</TT
>tqtcanvas</TT
> module.</P
><P
></P
@ -623,18 +623,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qtext_sip_flags</TT
>pytqt_tqtext_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qtext</TT
>tqtext</TT
> module and which should be added to those needed by
any module that imports the <TT
CLASS="LITERAL"
>qtext</TT
>tqtext</TT
> module.</P
><P
></P
@ -644,18 +644,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qtgl_sip_flags</TT
>pytqt_tqtgl_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qtgl</TT
>tqtgl</TT
> module and which should be added to those needed by any
module that imports the <TT
CLASS="LITERAL"
>qtgl</TT
>tqtgl</TT
> module.</P
><P
></P
@ -665,18 +665,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qtnetwork_sip_flags</TT
>pytqt_tqtnetwork_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qtnetwork</TT
>tqtnetwork</TT
> module and which should be added to those needed
by any module that imports the <TT
CLASS="LITERAL"
>qtnetwork</TT
>tqtnetwork</TT
> module.</P
><P
></P
@ -686,18 +686,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qtsql_sip_flags</TT
>pytqt_tqtsql_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qtsql</TT
>tqtsql</TT
> module and which should be added to those needed by
any module that imports the <TT
CLASS="LITERAL"
>qtsql</TT
>tqtsql</TT
> module.</P
><P
></P
@ -707,18 +707,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qttable_sip_flags</TT
>pytqt_tqttable_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qttable</TT
>tqttable</TT
> module and which should be added to those needed by
any module that imports the <TT
CLASS="LITERAL"
>qttable</TT
>tqttable</TT
> module.</P
><P
></P
@ -728,18 +728,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qtui_sip_flags</TT
>pytqt_tqtui_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qtui</TT
>tqtui</TT
> module and which should be added to those needed by any
module that imports the <TT
CLASS="LITERAL"
>qtui</TT
>tqtui</TT
> module.</P
><P
></P
@ -749,18 +749,18 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_qtxml_sip_flags</TT
>pytqt_tqtxml_sip_flags</TT
></DT
><DD
><P
>A string of the SIP flags used to generate the code for the
<TT
CLASS="LITERAL"
>qtxml</TT
>tqtxml</TT
> module and which should be added to those needed by
any module that imports the <TT
CLASS="LITERAL"
>qtxml</TT
>tqtxml</TT
> module.</P
><P
></P
@ -770,7 +770,7 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_sip_dir</TT
>pytqt_sip_dir</TT
></DT
><DD
><P
@ -788,7 +788,7 @@ the module.</P
><DT
><TT
CLASS="LITERAL"
>pyqt_version</TT
>pytqt_version</TT
></DT
><DD
><P
@ -805,7 +805,7 @@ CLASS="LITERAL"
><DT
><TT
CLASS="LITERAL"
>pyqt_version_str</TT
>pytqt_version_str</TT
></DT
><DD
><P
@ -831,7 +831,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qt</TT
>tqt</TT
> module.</P
><P
></P
@ -866,7 +866,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qtaxcontainer</TT
>tqtaxcontainer</TT
>
module.</P
><P
@ -902,7 +902,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qtcanvas</TT
>tqtcanvas</TT
>
module.</P
><P
@ -938,7 +938,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qtext</TT
>tqtext</TT
> module.</P
><P
></P
@ -973,7 +973,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qtgl</TT
>tqtgl</TT
> module.</P
><P
></P
@ -1008,7 +1008,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qtnetwork</TT
>tqtnetwork</TT
>
module.</P
><P
@ -1044,7 +1044,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qttable</TT
>tqttable</TT
>
module.</P
><P
@ -1080,7 +1080,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qtsql</TT
>tqtsql</TT
> module.</P
><P
></P
@ -1115,7 +1115,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qtui</TT
>tqtui</TT
> module.</P
><P
></P
@ -1150,7 +1150,7 @@ CLASS="LITERAL"
><P
>The Makefile class for modules that import the <TT
CLASS="LITERAL"
>qtxml</TT
>tqtxml</TT
> module.</P
><P
></P
@ -1751,7 +1751,7 @@ CLASS="PROGRAMLISTING"
><P
>Note that the code generated by <TT
CLASS="LITERAL"
>pyuic</TT
>pytquic</TT
> uses
<TT
CLASS="LITERAL"
@ -1982,7 +1982,7 @@ CLASS="SECT1"
NAME="AEN632"
><TT
CLASS="LITERAL"
>qt</TT
>tqt</TT
> Module Reference</A
></H2
><DIV
@ -10048,7 +10048,7 @@ CLASS="SECT1"
NAME="AEN3784"
><TT
CLASS="LITERAL"
>qtaxcontainer</TT
>tqtaxcontainer</TT
> Module Reference</A
></H2
><DIV
@ -10140,7 +10140,7 @@ CLASS="LITERAL"
> module to manipulate objects
created by the <TT
CLASS="LITERAL"
>qtaxcontainer</TT
>tqtaxcontainer</TT
> module.</P
><P
>The <TT
@ -10243,7 +10243,7 @@ CLASS="SECT1"
NAME="AEN3860"
><TT
CLASS="LITERAL"
>qtcanvas</TT
>tqtcanvas</TT
> Module Reference</A
></H2
><DIV
@ -10493,7 +10493,7 @@ CLASS="SECT1"
NAME="AEN3937"
><TT
CLASS="LITERAL"
>qtext</TT
>tqtext</TT
> Module Reference</A
></H2
><DIV
@ -10943,7 +10943,7 @@ CLASS="SECT1"
NAME="AEN4076"
><TT
CLASS="LITERAL"
>qtgl</TT
>tqtgl</TT
> Module Reference</A
></H2
><DIV
@ -11035,7 +11035,7 @@ CLASS="SECT1"
NAME="AEN4107"
><TT
CLASS="LITERAL"
>qtnetwork</TT
>tqtnetwork</TT
> Module Reference</A
></H2
><DIV
@ -11410,7 +11410,7 @@ CLASS="SECT1"
NAME="AEN4243"
><TT
CLASS="LITERAL"
>qtpe</TT
>tqtpe</TT
> Module Reference</A
></H2
><DIV
@ -11739,7 +11739,7 @@ CLASS="SECT1"
NAME="AEN4343"
><TT
CLASS="LITERAL"
>qtsql</TT
>tqtsql</TT
> Module Reference</A
></H2
><DIV
@ -12192,7 +12192,7 @@ CLASS="SECT1"
NAME="AEN4486"
><TT
CLASS="LITERAL"
>qttable</TT
>tqttable</TT
> Module Reference</A
></H2
><DIV
@ -12274,7 +12274,7 @@ CLASS="SECT1"
NAME="AEN4509"
><TT
CLASS="LITERAL"
>qtui</TT
>tqtui</TT
> Module Reference</A
></H2
><DIV
@ -12300,7 +12300,7 @@ CLASS="SECT1"
NAME="AEN4516"
><TT
CLASS="LITERAL"
>qtxml</TT
>tqtxml</TT
> Module Reference</A
></H2
><DIV

@ -54,61 +54,61 @@ The bindings are implemented as a number of Python modules
<ItemizedList>
<ListItem>
<Para>
<Literal>qt</Literal> is the main module and contains the core classes and most
<Literal>tqt</Literal> is the main module and contains the core classes and most
user interface widgets.
</Para>
</ListItem>
<ListItem>
<Para>
<Literal>qtaxcontainer</Literal> contains a sub-set of the classes implemented
<Literal>tqtaxcontainer</Literal> contains a sub-set of the classes implemented
in TQt's TQAxContainer module, part of TQt's ActiveTQt framework.
</Para>
</ListItem>
<ListItem>
<Para>
<Literal>qtcanvas</Literal> contains the classes implemented in TQt's Canvas
<Literal>tqtcanvas</Literal> contains the classes implemented in TQt's Canvas
module.
</Para>
</ListItem>
<ListItem>
<Para>
<Literal>qtgl</Literal> contains the classes implemented in TQt's OpenGL module.
<Literal>tqtgl</Literal> contains the classes implemented in TQt's OpenGL module.
</Para>
</ListItem>
<ListItem>
<Para>
<Literal>qtnetwork</Literal> contains the classes implemented in TQt's Network
<Literal>tqtnetwork</Literal> contains the classes implemented in TQt's Network
module.
</Para>
</ListItem>
<ListItem>
<Para>
<Literal>qtpe</Literal> contains the classes implemented in TQtopia (originally
<Literal>tqtpe</Literal> contains the classes implemented in TQtopia (originally
called the TQt Palmtop Environment). It is only supported with TQt/Embedded.
</Para>
</ListItem>
<ListItem>
<Para>
<Literal>qtsql</Literal> contains the classes implemented in TQt's SQL module.
<Literal>tqtsql</Literal> contains the classes implemented in TQt's SQL module.
</Para>
</ListItem>
<ListItem>
<Para>
<Literal>qttable</Literal> contains the classes implemented in TQt's Table
<Literal>tqttable</Literal> contains the classes implemented in TQt's Table
module.
</Para>
</ListItem>
<ListItem>
<Para>
<Literal>qtui</Literal> contains the classes implemented in TQt's tqui library.
<Literal>tqtui</Literal> contains the classes implemented in TQt's tqui library.
These allow GUIs to be created directly from TQt Designer's
<Literal>.ui</Literal> files.
</Para>
@ -116,13 +116,13 @@ These allow GUIs to be created directly from TQt Designer's
<ListItem>
<Para>
<Literal>qtxml</Literal> contains the classes implemented in TQt's XML module.
<Literal>tqtxml</Literal> contains the classes implemented in TQt's XML module.
</Para>
</ListItem>
<ListItem>
<Para>
<Literal>qtext</Literal> contains useful third-party classes that are not part
<Literal>tqtext</Literal> contains useful third-party classes that are not part
of TQt. At the moment it contains bindings for TQScintilla, the port to TQt of
the Scintilla programmer's editor class.
</Para>
@ -130,11 +130,11 @@ the Scintilla programmer's editor class.
</ItemizedList>
<Para>
PyTQt also includes the <Literal>pyuic</Literal> and
<Literal>pylupdate</Literal> utilities which correspond to the TQt
PyTQt also includes the <Literal>pytquic</Literal> and
<Literal>pytqlupdate</Literal> utilities which correspond to the TQt
<Literal>uic</Literal> and <Literal>lupdate</Literal> utilities.
<Literal>pyuic</Literal> converts the GUI designs created with TQt Designer to
executable Python code. <Literal>pylupdate</Literal> scans Python code,
<Literal>pytquic</Literal> converts the GUI designs created with TQt Designer to
executable Python code. <Literal>pytqlupdate</Literal> scans Python code,
extracts all strings that are candidates for internationalisation, and creates
an XML file for use by TQt Linguist.
</Para>
@ -196,7 +196,7 @@ The missing <Literal>MacintoshVersion</Literal> enum has been added.
<ListItem>
<Para>
<Literal>PYQT_BUILD</Literal> has been removed.
<Literal>PYTQT_BUILD</Literal> has been removed.
</Para>
</ListItem>
@ -223,17 +223,17 @@ It generates an XML description of a GUI design. TQt includes
</Para>
<Para>
PyTQt includes <Literal>pyuic</Literal> which generates Python code from the
PyTQt includes <Literal>pytquic</Literal> which generates Python code from the
same XML. The Python code is self contained and can be executed immediately.
</Para>
<Para>
It is sometimes useful to be able to include some specific Python code in the
output generated by <Literal>pyuic</Literal>. For example, if you are using
custom widgets, <Literal>pyuic</Literal> has no way of knowing the name of the
output generated by <Literal>pytquic</Literal>. For example, if you are using
custom widgets, <Literal>pytquic</Literal> has no way of knowing the name of the
Python module containing the widget and so cannot generate the required
<Literal>import</Literal> statement. To help get around this,
<Literal>pyuic</Literal> will extract any lines entered in the
<Literal>pytquic</Literal> will extract any lines entered in the
<Literal>Comment</Literal> field of TQt Designer's
<Literal>Form Settings</Literal> dialog that begin with
<Literal>Python:</Literal> and copies them to the generated output.
@ -245,25 +245,25 @@ field.
</Para>
<ProgramListing>
This comment will be ignored by pyuic.
This comment will be ignored by pytquic.
Python:
Python:# Import our custom widget.
Python:from foo import bar
</ProgramListing>
<Para>
Here's the corresponding output from <Literal>pyuic</Literal>.
Here's the corresponding output from <Literal>pytquic</Literal>.
</Para>
<ProgramListing>
from PyTQt.qt import *
from PyTQt.tqt import *
# Import our custom widget.
from foo import bar
</ProgramListing>
<Para>
Thanks to Christian Bird, <Literal>pyuic</Literal> will extract Python code
Thanks to Christian Bird, <Literal>pytquic</Literal> will extract Python code
entered using TQt Designer to implement slots. In TQt Designer, when you need to
edit a slot and the source editor appears, enter Python code between the curly
braces. Don't worry about the correct starting indent level, each line is
@ -272,7 +272,7 @@ prepended with a correct indentation.
<Para>
Make sure that the <Literal>ui.h</Literal> file is in the same directory as the
<Literal>.ui</Literal> file when using <Literal>pyuic</Literal>. The
<Literal>.ui</Literal> file when using <Literal>pytquic</Literal>. The
<Literal>.ui</Literal> file implies the name of the <Literal>.ui.h</Literal>
file so there is no need to specify it on the command line.
</Para>
@ -290,7 +290,7 @@ if self.debugging:
</ProgramListing>
<Para>
Here is the resulting code when <Literal>pyuic</Literal> is run.
Here is the resulting code when <Literal>pytquic</Literal> is run.
</Para>
<ProgramListing>
@ -324,7 +324,7 @@ your application.
</Para>
<Para>
Thanks to Detlev Offenbach, PyTQt includes the <Literal>pylupdate</Literal>
Thanks to Detlev Offenbach, PyTQt includes the <Literal>pytqlupdate</Literal>
program. This generates the same <Literal>.ts</Literal> language source files
from your PyTQt source files.
</Para>
@ -358,16 +358,16 @@ In order to build PyTQt with support for the VendorID package, pass the
</Para>
</Sect1>
<Sect1><Title><Literal>pyqtconfig</Literal> and Build System Support</Title>
<Sect1><Title><Literal>pytqtconfig</Literal> and Build System Support</Title>
<Para>
The SIP build system (ie. the <Literal>sipconfig</Literal> module) is described
in the SIP documentation. PyTQt includes the <Literal>pyqtconfig</Literal>
in the SIP documentation. PyTQt includes the <Literal>pytqtconfig</Literal>
module that can be used by configuration scripts of other bindings that are
built on top of PyTQt.
</Para>
<Para>
The <Literal>pyqtconfig</Literal> module contains the following classes:
The <Literal>pytqtconfig</Literal> module contains the following classes:
</Para>
<VariableList>
@ -386,18 +386,18 @@ by the <Literal>sipconfig.Configuration</Literal> class):
<VariableList>
<VarListEntry>
<Term><Literal>pyqt_bin_dir</Literal></Term>
<Term><Literal>pytqt_bin_dir</Literal></Term>
<ListItem>
<Para>
The name of the directory containing the <Literal>pyuic</Literal> and
<Literal>pylupdate</Literal> executables.
The name of the directory containing the <Literal>pytquic</Literal> and
<Literal>pytqlupdate</Literal> executables.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_config_args</Literal></Term>
<Term><Literal>pytqt_config_args</Literal></Term>
<ListItem>
<Para>
The command line passed to <Literal>configure.py</Literal> when PyTQt was
@ -408,7 +408,7 @@ configured.
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_mod_dir</Literal></Term>
<Term><Literal>pytqt_mod_dir</Literal></Term>
<ListItem>
<Para>
The name of the directory containing the PyTQt modules.
@ -418,7 +418,7 @@ The name of the directory containing the PyTQt modules.
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_modules</Literal></Term>
<Term><Literal>pytqt_modules</Literal></Term>
<ListItem>
<Para>
A string containing the names of the PyTQt modules that were installed.
@ -428,127 +428,127 @@ A string containing the names of the PyTQt modules that were installed.
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qt_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqt_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qt</Literal> module and which should be added to those needed by any
module that imports the <Literal>qt</Literal> module.
<Literal>tqt</Literal> module and which should be added to those needed by any
module that imports the <Literal>tqt</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qtaxcontainer_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqtaxcontainer_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qtaxcontainer</Literal> module and which should be added to those
needed by any module that imports the <Literal>qtaxcontainer</Literal> module.
<Literal>tqtaxcontainer</Literal> module and which should be added to those
needed by any module that imports the <Literal>tqtaxcontainer</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qtcanvas_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqtcanvas_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qtcanvas</Literal> module and which should be added to those needed by
any module that imports the <Literal>qtcanvas</Literal> module.
<Literal>tqtcanvas</Literal> module and which should be added to those needed by
any module that imports the <Literal>tqtcanvas</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qtext_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqtext_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qtext</Literal> module and which should be added to those needed by
any module that imports the <Literal>qtext</Literal> module.
<Literal>tqtext</Literal> module and which should be added to those needed by
any module that imports the <Literal>tqtext</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qtgl_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqtgl_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qtgl</Literal> module and which should be added to those needed by any
module that imports the <Literal>qtgl</Literal> module.
<Literal>tqtgl</Literal> module and which should be added to those needed by any
module that imports the <Literal>tqtgl</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qtnetwork_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqtnetwork_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qtnetwork</Literal> module and which should be added to those needed
by any module that imports the <Literal>qtnetwork</Literal> module.
<Literal>tqtnetwork</Literal> module and which should be added to those needed
by any module that imports the <Literal>tqtnetwork</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qtsql_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqtsql_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qtsql</Literal> module and which should be added to those needed by
any module that imports the <Literal>qtsql</Literal> module.
<Literal>tqtsql</Literal> module and which should be added to those needed by
any module that imports the <Literal>tqtsql</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qttable_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqttable_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qttable</Literal> module and which should be added to those needed by
any module that imports the <Literal>qttable</Literal> module.
<Literal>tqttable</Literal> module and which should be added to those needed by
any module that imports the <Literal>tqttable</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qtui_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqtui_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qtui</Literal> module and which should be added to those needed by any
module that imports the <Literal>qtui</Literal> module.
<Literal>tqtui</Literal> module and which should be added to those needed by any
module that imports the <Literal>tqtui</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_qtxml_sip_flags</Literal></Term>
<Term><Literal>pytqt_tqtxml_sip_flags</Literal></Term>
<ListItem>
<Para>
A string of the SIP flags used to generate the code for the
<Literal>qtxml</Literal> module and which should be added to those needed by
any module that imports the <Literal>qtxml</Literal> module.
<Literal>tqtxml</Literal> module and which should be added to those needed by
any module that imports the <Literal>tqtxml</Literal> module.
</Para>
<Para></Para><Para></Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_sip_dir</Literal></Term>
<Term><Literal>pytqt_sip_dir</Literal></Term>
<ListItem>
<Para>
The name of the base directory where the <Literal>.sip</Literal> files for each
@ -560,7 +560,7 @@ the module.
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_version</Literal></Term>
<Term><Literal>pytqt_version</Literal></Term>
<ListItem>
<Para>
The PyTQt version as a 3 part hexadecimal number (eg. v3.10 is represented as
@ -571,7 +571,7 @@ The PyTQt version as a 3 part hexadecimal number (eg. v3.10 is represented as
</VarListEntry>
<VarListEntry>
<Term><Literal>pyqt_version_str</Literal></Term>
<Term><Literal>pytqt_version_str</Literal></Term>
<ListItem>
<Para>
The PyTQt version as a string. For development snapshots it will start with
@ -589,7 +589,7 @@ The PyTQt version as a string. For development snapshots it will start with
<Term><Literal>TQtModuleMakefile(sipconfig.SIPModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qt</Literal> module.
The Makefile class for modules that import the <Literal>tqt</Literal> module.
</Para>
<VariableList>
<VarListEntry>
@ -609,7 +609,7 @@ This is a reimplementation of <Literal>sipconfig.Makefile.finalise()</Literal>.
<Term><Literal>TQtAxContainerModuleMakefile(TQtModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qtaxcontainer</Literal>
The Makefile class for modules that import the <Literal>tqtaxcontainer</Literal>
module.
</Para>
<VariableList>
@ -630,7 +630,7 @@ This is a reimplementation of <Literal>sipconfig.Makefile.finalise()</Literal>.
<Term><Literal>TQtCanvasModuleMakefile(TQtModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qtcanvas</Literal>
The Makefile class for modules that import the <Literal>tqtcanvas</Literal>
module.
</Para>
<VariableList>
@ -651,7 +651,7 @@ This is a reimplementation of <Literal>sipconfig.Makefile.finalise()</Literal>.
<Term><Literal>TQtExtModuleMakefile(TQtModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qtext</Literal> module.
The Makefile class for modules that import the <Literal>tqtext</Literal> module.
</Para>
<VariableList>
<VarListEntry>
@ -671,7 +671,7 @@ This is a reimplementation of <Literal>sipconfig.Makefile.finalise()</Literal>.
<Term><Literal>TQtGLModuleMakefile(TQtModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qtgl</Literal> module.
The Makefile class for modules that import the <Literal>tqtgl</Literal> module.
</Para>
<VariableList>
<VarListEntry>
@ -691,7 +691,7 @@ This is a reimplementation of <Literal>sipconfig.Makefile.finalise()</Literal>.
<Term><Literal>TQtNetworkModuleMakefile(TQtModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qtnetwork</Literal>
The Makefile class for modules that import the <Literal>tqtnetwork</Literal>
module.
</Para>
<VariableList>
@ -712,7 +712,7 @@ This is a reimplementation of <Literal>sipconfig.Makefile.finalise()</Literal>.
<Term><Literal>TQtTableModuleMakefile(TQtModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qttable</Literal>
The Makefile class for modules that import the <Literal>tqttable</Literal>
module.
</Para>
<VariableList>
@ -733,7 +733,7 @@ This is a reimplementation of <Literal>sipconfig.Makefile.finalise()</Literal>.
<Term><Literal>TQtSQLModuleMakefile(TQtTableModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qtsql</Literal> module.
The Makefile class for modules that import the <Literal>tqtsql</Literal> module.
</Para>
<VariableList>
<VarListEntry>
@ -753,7 +753,7 @@ This is a reimplementation of <Literal>sipconfig.Makefile.finalise()</Literal>.
<Term><Literal>TQtUIModuleMakefile(TQtModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qtui</Literal> module.
The Makefile class for modules that import the <Literal>tqtui</Literal> module.
</Para>
<VariableList>
<VarListEntry>
@ -773,7 +773,7 @@ This is a reimplementation of <Literal>sipconfig.Makefile.finalise()</Literal>.
<Term><Literal>TQtXMLModuleMakefile(TQtModuleMakefile)</Literal></Term>
<ListItem>
<Para>
The Makefile class for modules that import the <Literal>qtxml</Literal> module.
The Makefile class for modules that import the <Literal>tqtxml</Literal> module.
</Para>
<VariableList>
<VarListEntry>
@ -1094,7 +1094,7 @@ class A(TQObject):
</ProgramListing>
<Para>
Note that the code generated by <Literal>pyuic</Literal> uses
Note that the code generated by <Literal>pytquic</Literal> uses
<Literal>TQApplication.translate()</Literal>.
</Para>
</Sect2>
@ -1243,7 +1243,7 @@ Classes that are not mentioned have not yet been implemented.
</Sect1>
<Sect1><Title><Literal>qt</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqt</Literal> Module Reference</Title>
<Sect2><Title>TQt Constants</Title>
<Para>
All constant values defined by TQt have equivalent constants defined to Python.
@ -4663,7 +4663,7 @@ values. (TQt v2+)
</Para>
</Sect2>
</Sect1>
<Sect1><Title><Literal>qtaxcontainer</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqtaxcontainer</Literal> Module Reference</Title>
<Sect2><Title>TQAxBase (Windows, TQt v3+)</Title>
<FuncSynopsis>
<FuncDef><Function>TQAxObject</Function></FuncDef>
@ -4705,7 +4705,7 @@ Not implemented.
<Para>
This is a utility method provided by PyTQt to make it easier to use
Mark Hammond's <Literal>win32com</Literal> module to manipulate objects
created by the <Literal>qtaxcontainer</Literal> module.
created by the <Literal>tqtaxcontainer</Literal> module.
</Para>
<Para>
The <Literal>RegisterActiveObject()</Literal> COM function is called to
@ -4747,7 +4747,7 @@ Not implemented.
</Para>
</Sect2>
</Sect1>
<Sect1><Title><Literal>qtcanvas</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqtcanvas</Literal> Module Reference</Title>
<Sect2><Title>TQCanvas (TQt v2.2+)</Title>
<Para>
<Literal>TQCanvas</Literal> is fully implemented.
@ -4851,7 +4851,7 @@ The <Literal>pixmaps</Literal> argument is a Python list of TQPixmap instances.
</Para>
</Sect2>
</Sect1>
<Sect1><Title><Literal>qtext</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqtext</Literal> Module Reference</Title>
<Sect2><Title>TQextScintilla</Title>
<FuncSynopsis>
@ -5040,7 +5040,7 @@ This takes no parameters and returns a tuple of the values returned by the
</Para>
</Sect2>
</Sect1>
<Sect1><Title><Literal>qtgl</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqtgl</Literal> Module Reference</Title>
<Sect2><Title>TQGL</Title>
<Para>
<Literal>TQGL</Literal> is fully implemented.
@ -5076,7 +5076,7 @@ Not yet implemented.
</Para>
</Sect2>
</Sect1>
<Sect1><Title><Literal>qtnetwork</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqtnetwork</Literal> Module Reference</Title>
<Sect2><Title>TQDns (TQt v2.2+)</Title>
<Para>
<Literal>TQDns</Literal> is fully implemented.
@ -5223,7 +5223,7 @@ as a parameter.
</Para>
</Sect2>
</Sect1>
<Sect1><Title><Literal>qtpe</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqtpe</Literal> Module Reference</Title>
<Sect2><Title>TQPEApplication</Title>
<FuncSynopsis>
@ -5361,7 +5361,7 @@ Not implemented.
</Sect2>
</Sect1>
<Sect1><Title><Literal>qtsql</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqtsql</Literal> Module Reference</Title>
<Sect2><Title>TQDataBrowser (TQt v3+)</Title>
<FuncSynopsis>
<FuncDef>virtual void <Function>del</Function></FuncDef>
@ -5534,7 +5534,7 @@ This has been renamed <Literal>execQuery</Literal> in Python.
</Para>
</Sect2>
</Sect1>
<Sect1><Title><Literal>qttable</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqttable</Literal> Module Reference</Title>
<Sect2><Title>TQTable (TQt v2.2+)</Title>
<Para>
<Literal>TQTable</Literal> is fully implemented.
@ -5565,14 +5565,14 @@ This has been renamed <Literal>execQuery</Literal> in Python.
</Para>
</Sect2>
</Sect1>
<Sect1><Title><Literal>qtui</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqtui</Literal> Module Reference</Title>
<Sect2><Title>TQWidgetFactory (TQt v3+)</Title>
<Para>
<Literal>TQWidgetFactory</Literal> is fully implemented.
</Para>
</Sect2>
</Sect1>
<Sect1><Title><Literal>qtxml</Literal> Module Reference</Title>
<Sect1><Title><Literal>tqtxml</Literal> Module Reference</Title>
<Sect2><Title>TQDomImplementation (TQt v2.2+)</Title>
<Para>
<Literal>TQDomImplementation</Literal> is fully implemented.

File diff suppressed because it is too large Load Diff

@ -2,11 +2,11 @@ This directory contains some translated sql examples from TQt 3.x.
runform1.py, form1.ui:
A simple designer generated TQDataTable. Run "pyuic form1.ui -o form1.py".
A simple designer generated TQDataTable. Run "pytquic form1.ui -o form1.py".
runform2.py, form2.ui:
A simple designer generated TQDataBrowser. Run "pyuic form2.ui -o form2.py".
A simple designer generated TQDataBrowser. Run "pytquic form2.ui -o form2.py".
sqlcustom1.py:

@ -9,7 +9,7 @@
void ConnectDialog::init()
{
from PyTQt.qtsql import TQSqlDatabase
from PyTQt.tqtsql import TQSqlDatabase
#qDebug("ConnectDialog init")
self.comboDriver.clear()
self.comboDriver.insertStringList(TQSqlDatabase.drivers())

@ -1,8 +1,8 @@
#!/usr/bin/env python
import sys
from PyTQt.qt import *
from PyTQt.qtsql import *
from PyTQt.tqt import *
from PyTQt.tqtsql import *
from frmconnect import frmConnect
from dbpar import *
@ -12,7 +12,7 @@ FALSE = 0
def createConnection():
driver = DB_DRIVER
# all qt examples use TQSqlDatabase::addDatabase, but
# all tqt examples use TQSqlDatabase::addDatabase, but
# this never returns NULL in my experience
drivers = list(map(str, TQSqlDatabase.drivers()))
if driver in drivers:

@ -1,12 +1,12 @@
# Form implementation generated from reading ui file 'frmconnect.ui'
#
# Created: Sam Jul 6 12:47:10 2002
# by: The PyTQt User Interface Compiler (pyuic)
# by: The PyTQt User Interface Compiler (pytquic)
#
# WARNING! All changes made in this file will be lost!
from PyTQt.qt import *
from PyTQt.tqt import *
class frmConnect(TQDialog):

@ -1,7 +1,7 @@
#!/usr/bin/env python
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
from form1 import Form1
from dbconnect import createConnection

@ -1,7 +1,7 @@
#!/usr/bin/env python
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
from form2 import Form2
from dbconnect import createConnection

@ -1,8 +1,8 @@
#!/usr/bin/env python
import sys
from PyTQt.qt import *
from PyTQt.qtsql import *
from PyTQt.tqt import *
from PyTQt.tqtsql import *
from sqlex import SqlEx
from connect import ConnectDialog

@ -11,8 +11,8 @@
#*****************************************************************************/
import sys
from PyTQt.qt import *
from PyTQt.qtsql import *
from PyTQt.tqt import *
from PyTQt.tqtsql import *
from dbconnect import createConnection

@ -11,8 +11,8 @@
#*****************************************************************************/
import sys
from PyTQt.qt import *
from PyTQt.qtsql import *
from PyTQt.tqt import *
from PyTQt.tqtsql import *
from dbconnect import createConnection

@ -11,8 +11,8 @@
#*****************************************************************************/
import sys
from PyTQt.qt import *
from PyTQt.qtsql import *
from PyTQt.tqt import *
from PyTQt.tqtsql import *
from dbconnect import createConnection

@ -1,7 +1,7 @@
#!/usr/bin/env python
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
def TQMIN(x, y):
if y > x: return y
@ -19,7 +19,7 @@ class AnalogClock(TQWidget):
if new_time.minute() != self.time.minute():
self.update()
def paintEvent(self, qe):
def paintEvent(self, tqe):
if not self.isVisible():
return
self.time = TQTime.currentTime()

@ -4,7 +4,7 @@
import sys, string
from PyTQt.qt import *
from PyTQt.tqt import *
TRUE = 1
FALSE = 0

@ -4,7 +4,7 @@
import sys, string
from PyTQt.qt import *
from PyTQt.tqt import *
fileopen = [

@ -1,7 +1,7 @@
#!/usr/bin/env python
import os, sys, string
from PyTQt.qt import *
from PyTQt.tqt import *
if TQT_VERSION < 0x030100:

@ -12,8 +12,8 @@
import sys
import os
from PyTQt.qt import *
from PyTQt.qttable import *
from PyTQt.tqt import *
from PyTQt.tqttable import *
TRUE = 1
FALSE = 0

@ -10,7 +10,7 @@
#*****************************************************************************/
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
TRUE = 1
FALSE = 0
@ -118,7 +118,7 @@ a = TQApplication( sys.argv )
buttonsgroups = ButtonsGroups()
buttonsgroups.resize( 500, 250 )
buttonsgroups.setCaption( "PyQT Example - Buttons and Groups" )
buttonsgroups.setCaption( "PyTQt Example - Buttons and Groups" )
a.setMainWidget( buttonsgroups )
buttonsgroups.show()

@ -1,8 +1,8 @@
#!/usr/bin/env python
import sys
from PyTQt.qt import *
from PyTQt.qtcanvas import *
from PyTQt.tqt import *
from PyTQt.tqtcanvas import *
import random
@ -124,7 +124,7 @@ class BouncyLogo(TQCanvasSprite):
# Make sure the logo exists.
global bouncy_logo
if bouncy_logo is None:
bouncy_logo=TQCanvasPixmapArray("qt-trans.xpm")
bouncy_logo=TQCanvasPixmapArray("tqt-trans.xpm")
TQCanvasSprite.__init__(self,None,canvas)
self.setSequence(bouncy_logo)
@ -587,11 +587,11 @@ if __name__=='__main__':
if len(sys.argv) > 2:
logo_fn = TQString(sys.argv[2])
else:
logo_fn=TQString("qtlogo.png")
logo_fn=TQString("tqtlogo.png")
canvas=TQCanvas(800,600)
canvas.setAdvancePeriod(30)
m=Main(canvas,None,"pyqt canvas example")
m=Main(canvas,None,"pytqt canvas example")
m.resize(m.sizeHint())
tqApp.setMainWidget(m)

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 22 KiB

@ -3,7 +3,7 @@
# Copyright (C) 2002 Oleksandr Yakovlyev (yshurik) <yshurik@thekompany.com>
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
TRUE = 1
FALSE = 0

@ -10,7 +10,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
# cb_bits and cm_bits were generated by X bitmap program.

@ -4,7 +4,7 @@
import sys, string
from PyTQt.qt import *
from PyTQt.tqt import *
class DigitalClock(TQLCDNumber):

@ -1,7 +1,7 @@
#!/usr/bin/env python
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
seed = 0.353535353535
KINDA_RAND_MAX = 32767

@ -12,7 +12,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
folder_closed_xpm = [
"16 16 9 1",

@ -3,7 +3,7 @@
# Ported to PyTQt by Issac Trotts on Jan 1, 2002
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
import dropsite, secret

@ -1,7 +1,7 @@
#!/usr/bin/env python
import sys, random
from PyTQt.qt import *
from PyTQt.tqt import *
TRUE = 1
FALSE = 0

@ -1,7 +1,7 @@
# This is part of the dragdrop example.
from PyTQt.qt import *
from PyTQt.tqt import *
import secret
@ -23,7 +23,7 @@ class DropSite(TQLabel):
drobj = TQTextDrag( self.text(), self )
drobj.dragCopy()
def backgroundColorChange( self, qcolor ):
def backgroundColorChange( self, tqcolor ):
# Reduce flicker by using repaint() rather than update()
self.repaint()

@ -11,7 +11,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
class FontRowTable( TQFrame ):
def __init__( self, parent=None, name=None ):

@ -11,7 +11,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
class Viewer( TQWidget ):
def __init__( self ):

@ -3,8 +3,8 @@
import sys
import math
from PyTQt.qt import *
from PyTQt.qtgl import *
from PyTQt.tqt import *
from PyTQt.tqtgl import *
from OpenGL.GL import *
def gear(inner_radius,outer_radius,width,teeth,tooth_depth):

@ -5,7 +5,7 @@
from whrandom import randint
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
from mywidget import MyWidget

@ -1,6 +1,6 @@
# Copyright (c) 2002 Detlev Offenbach <detlev@die-offenbachs.de>
from PyTQt.qt import *
from PyTQt.tqt import *
class MyWidget(TQMainWindow):

@ -11,7 +11,7 @@
#*****************************************************************************/
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
TRUE = 1
FALSE = 0

@ -11,7 +11,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
FALSE = 0
TRUE = 1

@ -11,7 +11,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
FALSE = 0
TRUE = 1
@ -34,7 +34,7 @@ class ListBoxCombo( TQVBox ):
self.lb1.setSelectionMode( TQListBox.Multi )
# ...insert a pixmap item...
xpm = TQPixmap( "qtlogo.png" )
xpm = TQPixmap( "tqtlogo.png" )
txt = TQString()
TQListBoxPixmap( self.lb1, xpm, txt )

@ -4,7 +4,7 @@
import sys, string
from PyTQt.qt import *
from PyTQt.tqt import *
fileopen = [

@ -11,7 +11,7 @@
#*****************************************************************************/
import sys, string
from PyTQt.qt import *
from PyTQt.tqt import *
TRUE = 1
FALSE = 0

@ -13,7 +13,7 @@
#*****************************************************************************/
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
from random import randint
class AnimatedThingy(TQLabel):

@ -12,7 +12,7 @@
#import pdb
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
FALSE = 0
TRUE = 1

@ -11,7 +11,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
INT_MAX = sys.maxsize

@ -11,7 +11,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
sayings = [
"<b>Saying 1:</b><br>"

@ -1,7 +1,7 @@
# This is part of the dragdrop example.
from PyTQt.qt import *
from PyTQt.tqt import *
def canDecode(e):

@ -7,12 +7,12 @@ import sys
# Check if thread support was enabled.
try:
from PyTQt.qt import TQThread
from PyTQt.tqt import TQThread
except:
print("Thread support not enabled")
sys.exit(1)
from PyTQt.qt import *
from PyTQt.tqt import *
# The semaphore instances.

@ -12,8 +12,8 @@
import sys
import os
from PyTQt.qt import *
from PyTQt.qttable import *
from PyTQt.tqt import *
from PyTQt.tqttable import *
TRUE = 1
FALSE = 0

@ -1,7 +1,7 @@
#!/usr/bin/env python
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
class Test(TQWidget):
def __init__(self, parent=None, name='Test', f=0):

@ -11,7 +11,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
class TabDialog( TQTabDialog ):
def __init__( self, parent=None, name=None, filename=None ):

@ -12,8 +12,8 @@
import sys
import os
from PyTQt.qt import *
from PyTQt.qttable import *
from PyTQt.tqt import *
from PyTQt.tqttable import *
TRUE = 1
FALSE = 0
@ -52,11 +52,11 @@ class Table(TQTable):
def initTable(self):
# read all the TQt source and header files into a list
all = []
qtdir = os.getenv("TQTDIR")
if qtdir is None:
tqtdir = os.getenv("TQTDIR")
if tqtdir is None:
raise Exception("The TQTDIR environment variable has not been set.")
for i in dirs:
dir = TQDir(os.path.join(qtdir, "src", i))
dir = TQDir(os.path.join(tqtdir, "src", i))
lst = TQStringList(dir.entryList("*.cpp; *.h"))
for f in lst:
if f.contains("moc"):
@ -71,7 +71,7 @@ class Table(TQTable):
# insert the data into the table
for it in all:
self.setText(i, TB_FILE, it)
f = TQFile(os.path.join(qtdir, "src", str(it)))
f = TQFile(os.path.join(tqtdir, "src", str(it)))
self.setText(i, TB_SIZE, str(f.size()))
ci = ComboItem(self, TQTableItem.WhenCurrent)
self.setItem(i, TB_FLAG, ci)

@ -11,7 +11,7 @@
***************************************************************************"""
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
from random import random
class DynamicTip( TQToolTip ):

@ -5,7 +5,7 @@
from __future__ import print_function
import os
import pickle
from PyTQt.qt import *
from PyTQt.tqt import *
from dirview import Directory, DirectoryView
bookmarks = [

@ -11,7 +11,7 @@
#*****************************************************************************/
import sys
from PyTQt.qt import *
from PyTQt.tqt import *
TRUE = 1
FALSE = 0

Before

Width:  |  Height:  |  Size: 355 B

After

Width:  |  Height:  |  Size: 355 B

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

@ -3,12 +3,12 @@
# TQt tutorial 1.
import sys
from PyTQt import qt
from PyTQt import tqt
a = qt.TQApplication(sys.argv)
a = tqt.TQApplication(sys.argv)
hello = qt.TQPushButton("Hello world!", None)
hello = tqt.TQPushButton("Hello world!", None)
hello.resize(100, 30)
a.setMainWidget(hello)

@ -3,19 +3,19 @@
# TQt tutorial 10.
import sys
from PyTQt import qt
from PyTQt import tqt
class LCDRange(qt.TQVBox):
class LCDRange(tqt.TQVBox):
def __init__(self, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
lcd = qt.TQLCDNumber(2, self, "lcd")
self.slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
lcd = tqt.TQLCDNumber(2, self, "lcd")
self.slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
self.slider.setRange(0, 99)
self.slider.setValue(0)
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), self, qt.PYSIGNAL("valueChanged(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), self, tqt.PYSIGNAL("valueChanged(int)"))
self.setFocusProxy(self.slider)
@ -31,13 +31,13 @@ class LCDRange(qt.TQVBox):
self.slider.setRange(minVal, maxVal)
class CannonField(qt.TQWidget):
class CannonField(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
self.ang = 45
self.f = 0
self.setPalette(qt.TQPalette(qt.TQColor(250, 250, 200)))
self.setPalette(tqt.TQPalette(tqt.TQColor(250, 250, 200)))
def angle(self):
return self.ang
@ -51,7 +51,7 @@ class CannonField(qt.TQWidget):
return
self.ang = degrees
self.repaint(self.cannonRect(), 0)
self.emit(qt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
self.emit(tqt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
def force(self):
return self.f
@ -62,46 +62,46 @@ class CannonField(qt.TQWidget):
if self.f == newton:
return
self.f = newton
self.emit(qt.PYSIGNAL("forceChanged(int)"), (self.f, ))
self.emit(tqt.PYSIGNAL("forceChanged(int)"), (self.f, ))
def paintEvent(self, ev):
if not ev.rect().intersects(self.cannonRect()):
return
cr = self.cannonRect()
pix = qt.TQPixmap(cr.size())
pix = tqt.TQPixmap(cr.size())
pix.fill(self, cr.topLeft())
p = qt.TQPainter(pix)
p = tqt.TQPainter(pix)
p.setBrush(qt.TQt.blue)
p.setPen(qt.TQt.NoPen)
p.setBrush(tqt.TQt.blue)
p.setPen(tqt.TQt.NoPen)
p.translate(0, pix.height() - 1)
p.drawPie(qt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
p.drawPie(tqt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
p.rotate(-self.ang)
p.drawRect(qt.TQRect(33, -4, 15, 8))
p.drawRect(tqt.TQRect(33, -4, 15, 8))
p.end()
p.begin(self)
p.drawPixmap(cr.topLeft(), pix)
def cannonRect(self):
r = qt.TQRect(0, 0, 50, 50)
r = tqt.TQRect(0, 0, 50, 50)
r.moveBottomLeft(self.rect().bottomLeft())
return r
def sizePolicy(self):
return qt.TQSizePolicy(qt.TQSizePolicy.Expanding, qt.TQSizePolicy.Expanding)
return tqt.TQSizePolicy(tqt.TQSizePolicy.Expanding, tqt.TQSizePolicy.Expanding)
class MyWidget(qt.TQWidget):
class MyWidget(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
quit = qt.TQPushButton("&Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
quit = tqt.TQPushButton("&Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
self.angle = LCDRange(self, "angle")
self.angle.setRange(5, 70)
@ -111,19 +111,19 @@ class MyWidget(qt.TQWidget):
self.cannonField = CannonField(self, "cannonField")
self.connect(self.angle, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, qt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.angle, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, tqt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.force, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, qt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
self.connect(self.force, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, tqt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
grid = qt.TQGridLayout(self, 2, 2, 10)
grid = tqt.TQGridLayout(self, 2, 2, 10)
grid.addWidget(quit, 0, 0)
grid.addWidget(self.cannonField, 1, 1)
grid.setColStretch(1, 10)
leftBox = qt.TQVBoxLayout()
leftBox = tqt.TQVBoxLayout()
grid.addLayout(leftBox, 1, 0)
@ -135,8 +135,8 @@ class MyWidget(qt.TQWidget):
self.angle.setFocus()
qt.TQApplication.setColorSpec(qt.TQApplication.CustomColor)
a = qt.TQApplication(sys.argv)
qt.TQApplication.setColorSpec(tqt.TQApplication.CustomColor)
a = tqt.TQApplication(sys.argv)
w = MyWidget()
w.setGeometry(100, 100, 500, 355)

@ -4,19 +4,19 @@
import sys
import math
from PyTQt import qt
from PyTQt import tqt
class LCDRange(qt.TQVBox):
class LCDRange(tqt.TQVBox):
def __init__(self, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
lcd = qt.TQLCDNumber(2, self, "lcd")
self.slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
lcd = tqt.TQLCDNumber(2, self, "lcd")
self.slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
self.slider.setRange(0, 99)
self.slider.setValue(0)
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), self, qt.PYSIGNAL("valueChanged(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), self, tqt.PYSIGNAL("valueChanged(int)"))
self.setFocusProxy(self.slider)
@ -32,23 +32,23 @@ class LCDRange(qt.TQVBox):
self.slider.setRange(minVal, maxVal)
class CannonField(qt.TQWidget):
class CannonField(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
self.ang = 45
self.f = 0
self.timerCount = 0
self.autoShootTimer = qt.TQTimer(self, "movement handler")
self.connect(self.autoShootTimer, qt.SIGNAL("timeout()"), self.moveShot)
self.autoShootTimer = tqt.TQTimer(self, "movement handler")
self.connect(self.autoShootTimer, tqt.SIGNAL("timeout()"), self.moveShot)
self.shoot_ang = 0
self.shoot_f = 0
self.setPalette(qt.TQPalette(qt.TQColor(250, 250, 200)))
self.setPalette(tqt.TQPalette(tqt.TQColor(250, 250, 200)))
self.barrelRect = qt.TQRect(33, -4, 15, 8)
self.barrelRect = tqt.TQRect(33, -4, 15, 8)
def angle(self):
return self.ang
@ -62,7 +62,7 @@ class CannonField(qt.TQWidget):
return
self.ang = degrees
self.repaint(self.cannonRect(), 0)
self.emit(qt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
self.emit(tqt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
def force(self):
return self.f
@ -73,7 +73,7 @@ class CannonField(qt.TQWidget):
if self.f == newton:
return
self.f = newton
self.emit(qt.PYSIGNAL("forceChanged(int)"), (self.f, ))
self.emit(tqt.PYSIGNAL("forceChanged(int)"), (self.f, ))
def shoot(self):
if self.autoShootTimer.isActive():
@ -85,7 +85,7 @@ class CannonField(qt.TQWidget):
self.autoShootTimer.start(50)
def moveShot(self):
r = qt.TQRegion(self.shotRect())
r = tqt.TQRegion(self.shotRect())
self.timerCount = self.timerCount + 1
shotR = self.shotRect()
@ -93,13 +93,13 @@ class CannonField(qt.TQWidget):
if shotR.x() > self.width() or shotR.y() > self.height():
self.autoShootTimer.stop()
else:
r = r.unite(qt.TQRegion(shotR))
r = r.unite(tqt.TQRegion(shotR))
self.repaint(r)
def paintEvent(self, ev):
updateR = ev.rect()
p = qt.TQPainter(self)
p = tqt.TQPainter(self)
if updateR.intersects(self.cannonRect()):
self.paintCannon(p)
@ -108,21 +108,21 @@ class CannonField(qt.TQWidget):
self.paintShot(p)
def paintShot(self, p):
p.setBrush(qt.TQt.black)
p.setPen(qt.TQt.NoPen)
p.setBrush(tqt.TQt.black)
p.setPen(tqt.TQt.NoPen)
p.drawRect(self.shotRect())
def paintCannon(self, p):
cr = self.cannonRect()
pix = qt.TQPixmap(cr.size())
pix = tqt.TQPixmap(cr.size())
pix.fill(self, cr.topLeft())
tmp = qt.TQPainter(pix)
tmp.setBrush(qt.TQt.blue)
tmp.setPen(qt.TQt.NoPen)
tmp = tqt.TQPainter(pix)
tmp.setBrush(tqt.TQt.blue)
tmp.setPen(tqt.TQt.NoPen)
tmp.translate(0, pix.height() - 1)
tmp.drawPie(qt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
tmp.drawPie(tqt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
tmp.rotate(-self.ang)
tmp.drawRect(self.barrelRect)
tmp.end()
@ -130,7 +130,7 @@ class CannonField(qt.TQWidget):
p.drawPixmap(cr.topLeft(), pix)
def cannonRect(self):
r = qt.TQRect(0, 0, 50, 50)
r = tqt.TQRect(0, 0, 50, 50)
r.moveBottomLeft(self.rect().bottomLeft())
return r
@ -148,21 +148,21 @@ class CannonField(qt.TQWidget):
x = x0 + velx * time
y = y0 + vely * time - 0.5 * gravity * time * time
r = qt.TQRect(0, 0, 6, 6)
r.moveCenter(qt.TQPoint(int(x), int(self.height() - 1 - y)))
r = tqt.TQRect(0, 0, 6, 6)
r.moveCenter(tqt.TQPoint(int(x), int(self.height() - 1 - y)))
return r
def sizePolicy(self):
return qt.TQSizePolicy(qt.TQSizePolicy.Expanding, qt.TQSizePolicy.Expanding)
return tqt.TQSizePolicy(tqt.TQSizePolicy.Expanding, tqt.TQSizePolicy.Expanding)
class MyWidget(qt.TQWidget):
class MyWidget(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
quit = qt.TQPushButton("&Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
quit = tqt.TQPushButton("&Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
self.angle = LCDRange(self, "angle")
self.angle.setRange(5, 70)
@ -172,28 +172,28 @@ class MyWidget(qt.TQWidget):
self.cannonField = CannonField(self, "cannonField")
self.connect(self.angle, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, qt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.angle, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, tqt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.force, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, qt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
self.connect(self.force, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, tqt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
shoot = qt.TQPushButton("&Shoot", self, "shoot")
shoot.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(shoot, qt.SIGNAL("clicked()"), self.cannonField.shoot)
shoot = tqt.TQPushButton("&Shoot", self, "shoot")
shoot.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(shoot, tqt.SIGNAL("clicked()"), self.cannonField.shoot)
grid = qt.TQGridLayout(self, 2, 2, 10)
grid = tqt.TQGridLayout(self, 2, 2, 10)
grid.addWidget(quit, 0, 0)
grid.addWidget(self.cannonField, 1, 1)
grid.setColStretch(1, 10)
leftBox = qt.TQVBoxLayout()
leftBox = tqt.TQVBoxLayout()
grid.addLayout(leftBox, 1, 0)
leftBox.addWidget(self.angle)
leftBox.addWidget(self.force)
topBox = qt.TQHBoxLayout()
topBox = tqt.TQHBoxLayout()
grid.addLayout(topBox, 0, 1)
topBox.addWidget(shoot)
topBox.addStretch(1)
@ -203,8 +203,8 @@ class MyWidget(qt.TQWidget):
self.angle.setFocus()
qt.TQApplication.setColorSpec(qt.TQApplication.CustomColor)
a = qt.TQApplication(sys.argv)
qt.TQApplication.setColorSpec(tqt.TQApplication.CustomColor)
a = tqt.TQApplication(sys.argv)
w = MyWidget()
w.setGeometry(100, 100, 500, 355)

@ -5,23 +5,23 @@
import sys
import math
import random
from PyTQt import qt
from PyTQt import tqt
class LCDRange(qt.TQVBox):
class LCDRange(tqt.TQVBox):
def __init__(self, s=None, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
lcd = qt.TQLCDNumber(2, self, "lcd")
self.slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
lcd = tqt.TQLCDNumber(2, self, "lcd")
self.slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
self.slider.setRange(0, 99)
self.slider.setValue(0)
self.label = qt.TQLabel(" ", self, "label")
self.label.setAlignment(qt.TQt.AlignCenter)
self.label = tqt.TQLabel(" ", self, "label")
self.label.setAlignment(tqt.TQt.AlignCenter)
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), self, qt.PYSIGNAL("valueChanged(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), self, tqt.PYSIGNAL("valueChanged(int)"))
self.setFocusProxy(self.slider)
@ -47,24 +47,24 @@ class LCDRange(qt.TQVBox):
self.label.setText(s)
class CannonField(qt.TQWidget):
class CannonField(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
self.ang = 45
self.f = 0
self.timerCount = 0
self.autoShootTimer = qt.TQTimer(self, "movement handler")
self.connect(self.autoShootTimer, qt.SIGNAL("timeout()"), self.moveShot)
self.autoShootTimer = tqt.TQTimer(self, "movement handler")
self.connect(self.autoShootTimer, tqt.SIGNAL("timeout()"), self.moveShot)
self.shoot_ang = 0
self.shoot_f = 0
self.target = qt.TQPoint(0, 0)
self.target = tqt.TQPoint(0, 0)
self.setPalette(qt.TQPalette(qt.TQColor(250, 250, 200)))
self.setPalette(tqt.TQPalette(tqt.TQColor(250, 250, 200)))
self.barrelRect = qt.TQRect(33, -4, 15, 8)
self.barrelRect = tqt.TQRect(33, -4, 15, 8)
self.newTarget()
@ -80,7 +80,7 @@ class CannonField(qt.TQWidget):
return
self.ang = degrees
self.repaint(self.cannonRect(), 0)
self.emit(qt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
self.emit(tqt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
def force(self):
return self.f
@ -91,7 +91,7 @@ class CannonField(qt.TQWidget):
if self.f == newton:
return
self.f = newton
self.emit(qt.PYSIGNAL("forceChanged(int)"), (self.f, ))
self.emit(tqt.PYSIGNAL("forceChanged(int)"), (self.f, ))
def shoot(self):
if self.autoShootTimer.isActive():
@ -103,30 +103,30 @@ class CannonField(qt.TQWidget):
self.autoShootTimer.start(50)
def newTarget(self):
r = qt.TQRegion(self.targetRect())
self.target = qt.TQPoint(random.randint(200, 390), random.randint(10, 265))
self.repaint(r.unite(qt.TQRegion(self.targetRect())))
r = tqt.TQRegion(self.targetRect())
self.target = tqt.TQPoint(random.randint(200, 390), random.randint(10, 265))
self.repaint(r.unite(tqt.TQRegion(self.targetRect())))
def moveShot(self):
r = qt.TQRegion(self.shotRect())
r = tqt.TQRegion(self.shotRect())
self.timerCount = self.timerCount + 1
shotR = self.shotRect()
if shotR.intersects(self.targetRect()):
self.autoShootTimer.stop()
self.emit(qt.PYSIGNAL("hit()"), ())
self.emit(tqt.PYSIGNAL("hit()"), ())
elif shotR.x() > self.width() or shotR.y() > self.height():
self.autoShootTimer.stop()
self.emit(qt.PYSIGNAL("missed()"), ())
self.emit(tqt.PYSIGNAL("missed()"), ())
else:
r = r.unite(qt.TQRegion(shotR))
r = r.unite(tqt.TQRegion(shotR))
self.repaint(r)
def paintEvent(self, ev):
updateR = ev.rect()
p = qt.TQPainter(self)
p = tqt.TQPainter(self)
if updateR.intersects(self.cannonRect()):
self.paintCannon(p)
@ -138,26 +138,26 @@ class CannonField(qt.TQWidget):
self.paintTarget(p)
def paintShot(self, p):
p.setBrush(qt.TQt.black)
p.setPen(qt.TQt.NoPen)
p.setBrush(tqt.TQt.black)
p.setPen(tqt.TQt.NoPen)
p.drawRect(self.shotRect())
def paintTarget(self, p):
p.setBrush(qt.TQt.red)
p.setPen(qt.TQt.black)
p.setBrush(tqt.TQt.red)
p.setPen(tqt.TQt.black)
p.drawRect(self.targetRect())
def paintCannon(self, p):
cr = self.cannonRect()
pix = qt.TQPixmap(cr.size())
pix = tqt.TQPixmap(cr.size())
pix.fill(self, cr.topLeft())
tmp = qt.TQPainter(pix)
tmp.setBrush(qt.TQt.blue)
tmp.setPen(qt.TQt.NoPen)
tmp = tqt.TQPainter(pix)
tmp.setBrush(tqt.TQt.blue)
tmp.setPen(tqt.TQt.NoPen)
tmp.translate(0, pix.height() - 1)
tmp.drawPie(qt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
tmp.drawPie(tqt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
tmp.rotate(-self.ang)
tmp.drawRect(self.barrelRect)
tmp.end()
@ -165,7 +165,7 @@ class CannonField(qt.TQWidget):
p.drawPixmap(cr.topLeft(), pix)
def cannonRect(self):
r = qt.TQRect(0, 0, 50, 50)
r = tqt.TQRect(0, 0, 50, 50)
r.moveBottomLeft(self.rect().bottomLeft())
return r
@ -183,26 +183,26 @@ class CannonField(qt.TQWidget):
x = x0 + velx * time
y = y0 + vely * time - 0.5 * gravity * time * time
r = qt.TQRect(0, 0, 6, 6)
r.moveCenter(qt.TQPoint(int(x), int(self.height() - 1 - y)))
r = tqt.TQRect(0, 0, 6, 6)
r.moveCenter(tqt.TQPoint(int(x), int(self.height() - 1 - y)))
return r
def targetRect(self):
r = qt.TQRect(0, 0, 20, 10)
r.moveCenter(qt.TQPoint(self.target.x(), self.height() - 1 - self.target.y()))
r = tqt.TQRect(0, 0, 20, 10)
r.moveCenter(tqt.TQPoint(self.target.x(), self.height() - 1 - self.target.y()))
return r
def sizePolicy(self):
return qt.TQSizePolicy(qt.TQSizePolicy.Expanding, qt.TQSizePolicy.Expanding)
return tqt.TQSizePolicy(tqt.TQSizePolicy.Expanding, tqt.TQSizePolicy.Expanding)
class MyWidget(qt.TQWidget):
class MyWidget(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
quit = qt.TQPushButton("&Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
quit = tqt.TQPushButton("&Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
self.angle = LCDRange("ANGLE", self, "angle")
self.angle.setRange(5, 70)
@ -212,28 +212,28 @@ class MyWidget(qt.TQWidget):
self.cannonField = CannonField(self, "cannonField")
self.connect(self.angle, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, qt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.angle, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, tqt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.force, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, qt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
self.connect(self.force, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, tqt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
shoot = qt.TQPushButton("&Shoot", self, "shoot")
shoot.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(shoot, qt.SIGNAL("clicked()"), self.cannonField.shoot)
shoot = tqt.TQPushButton("&Shoot", self, "shoot")
shoot.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(shoot, tqt.SIGNAL("clicked()"), self.cannonField.shoot)
grid = qt.TQGridLayout(self, 2, 2, 10)
grid = tqt.TQGridLayout(self, 2, 2, 10)
grid.addWidget(quit, 0, 0)
grid.addWidget(self.cannonField, 1, 1)
grid.setColStretch(1, 10)
leftBox = qt.TQVBoxLayout()
leftBox = tqt.TQVBoxLayout()
grid.addLayout(leftBox, 1, 0)
leftBox.addWidget(self.angle)
leftBox.addWidget(self.force)
topBox = qt.TQHBoxLayout()
topBox = tqt.TQHBoxLayout()
grid.addLayout(topBox, 0, 1)
topBox.addWidget(shoot)
topBox.addStretch(1)
@ -243,8 +243,8 @@ class MyWidget(qt.TQWidget):
self.angle.setFocus()
qt.TQApplication.setColorSpec(qt.TQApplication.CustomColor)
a = qt.TQApplication(sys.argv)
qt.TQApplication.setColorSpec(tqt.TQApplication.CustomColor)
a = tqt.TQApplication(sys.argv)
w = MyWidget()
w.setGeometry(100, 100, 500, 355)

@ -5,27 +5,27 @@
import sys
import math
import random
from PyTQt import qt
from PyTQt import tqt
class LCDRange(qt.TQWidget):
class LCDRange(tqt.TQWidget):
def __init__(self, s=None, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
lcd = qt.TQLCDNumber(2, self, "lcd")
self.slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
lcd = tqt.TQLCDNumber(2, self, "lcd")
self.slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
self.slider.setRange(0, 99)
self.slider.setValue(0)
self.label = qt.TQLabel(" ", self, "label")
self.label.setAlignment(qt.TQt.AlignCenter)
self.label = tqt.TQLabel(" ", self, "label")
self.label.setAlignment(tqt.TQt.AlignCenter)
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), self, qt.PYSIGNAL("valueChanged(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), self, tqt.PYSIGNAL("valueChanged(int)"))
self.setFocusProxy(self.slider)
l = qt.TQVBoxLayout(self)
l = tqt.TQVBoxLayout(self)
l.addWidget(lcd, 1)
l.addWidget(self.slider)
l.addWidget(self.label)
@ -52,25 +52,25 @@ class LCDRange(qt.TQWidget):
self.label.setText(s)
class CannonField(qt.TQWidget):
class CannonField(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
self.ang = 45
self.f = 0
self.timerCount = 0
self.autoShootTimer = qt.TQTimer(self, "movement handler")
self.connect(self.autoShootTimer, qt.SIGNAL("timeout()"), self.moveShot)
self.autoShootTimer = tqt.TQTimer(self, "movement handler")
self.connect(self.autoShootTimer, tqt.SIGNAL("timeout()"), self.moveShot)
self.shoot_ang = 0
self.shoot_f = 0
self.target = qt.TQPoint(0, 0)
self.target = tqt.TQPoint(0, 0)
self.gameEnded = 0
self.setPalette(qt.TQPalette(qt.TQColor(250, 250, 200)))
self.setPalette(tqt.TQPalette(tqt.TQColor(250, 250, 200)))
self.barrelRect = qt.TQRect(33, -4, 15, 8)
self.barrelRect = tqt.TQRect(33, -4, 15, 8)
self.newTarget()
@ -86,7 +86,7 @@ class CannonField(qt.TQWidget):
return
self.ang = degrees
self.repaint(self.cannonRect(), 0)
self.emit(qt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
self.emit(tqt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
def force(self):
return self.f
@ -97,7 +97,7 @@ class CannonField(qt.TQWidget):
if self.f == newton:
return
self.f = newton
self.emit(qt.PYSIGNAL("forceChanged(int)"), (self.f, ))
self.emit(tqt.PYSIGNAL("forceChanged(int)"), (self.f, ))
def shoot(self):
if self.isShooting():
@ -107,12 +107,12 @@ class CannonField(qt.TQWidget):
self.shoot_ang = self.ang
self.shoot_f = self.f
self.autoShootTimer.start(50)
self.emit(qt.PYSIGNAL("canShoot(bool)"), (0, ))
self.emit(tqt.PYSIGNAL("canShoot(bool)"), (0, ))
def newTarget(self):
r = qt.TQRegion(self.targetRect())
self.target = qt.TQPoint(random.randint(200, 390), random.randint(10, 265))
self.repaint(r.unite(qt.TQRegion(self.targetRect())))
r = tqt.TQRegion(self.targetRect())
self.target = tqt.TQPoint(random.randint(200, 390), random.randint(10, 265))
self.repaint(r.unite(tqt.TQRegion(self.targetRect())))
def gameOver(self):
return self.gameEnded
@ -130,35 +130,35 @@ class CannonField(qt.TQWidget):
self.autoShootTime.stop()
self.gameEnded = 0
self.repaint()
self.emit(qt.PYSIGNAL("canShoot(bool)"), (1, ))
self.emit(tqt.PYSIGNAL("canShoot(bool)"), (1, ))
def moveShot(self):
r = qt.TQRegion(self.shotRect())
r = tqt.TQRegion(self.shotRect())
self.timerCount = self.timerCount + 1
shotR = self.shotRect()
if shotR.intersects(self.targetRect()):
self.autoShootTimer.stop()
self.emit(qt.PYSIGNAL("hit()"), ())
self.emit(qt.PYSIGNAL("canShoot(bool)"), (1, ))
self.emit(tqt.PYSIGNAL("hit()"), ())
self.emit(tqt.PYSIGNAL("canShoot(bool)"), (1, ))
elif shotR.x() > self.width() or shotR.y() > self.height():
self.autoShootTimer.stop()
self.emit(qt.PYSIGNAL("missed()"), ())
self.emit(qt.PYSIGNAL("canShoot(bool)"), (1, ))
self.emit(tqt.PYSIGNAL("missed()"), ())
self.emit(tqt.PYSIGNAL("canShoot(bool)"), (1, ))
else:
r = r.unite(qt.TQRegion(shotR))
r = r.unite(tqt.TQRegion(shotR))
self.repaint(r)
def paintEvent(self, ev):
updateR = ev.rect()
p = qt.TQPainter(self)
p = tqt.TQPainter(self)
if self.gameEnded:
p.setPen(qt.TQt.black)
p.setFont(qt.TQFont("Courier", 48, qt.TQFont.Bold))
p.drawText(self.rect(), qt.TQt.AlignCenter, "Game Over")
p.setPen(tqt.TQt.black)
p.setFont(tqt.TQFont("Courier", 48, tqt.TQFont.Bold))
p.drawText(self.rect(), tqt.TQt.AlignCenter, "Game Over")
if updateR.intersects(self.cannonRect()):
self.paintCannon(p)
@ -170,26 +170,26 @@ class CannonField(qt.TQWidget):
self.paintTarget(p)
def paintShot(self, p):
p.setBrush(qt.TQt.black)
p.setPen(qt.TQt.NoPen)
p.setBrush(tqt.TQt.black)
p.setPen(tqt.TQt.NoPen)
p.drawRect(self.shotRect())
def paintTarget(self, p):
p.setBrush(qt.TQt.red)
p.setPen(qt.TQt.black)
p.setBrush(tqt.TQt.red)
p.setPen(tqt.TQt.black)
p.drawRect(self.targetRect())
def paintCannon(self, p):
cr = self.cannonRect()
pix = qt.TQPixmap(cr.size())
pix = tqt.TQPixmap(cr.size())
pix.fill(self, cr.topLeft())
tmp = qt.TQPainter(pix)
tmp.setBrush(qt.TQt.blue)
tmp.setPen(qt.TQt.NoPen)
tmp = tqt.TQPainter(pix)
tmp.setBrush(tqt.TQt.blue)
tmp.setPen(tqt.TQt.NoPen)
tmp.translate(0, pix.height() - 1)
tmp.drawPie(qt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
tmp.drawPie(tqt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
tmp.rotate(-self.ang)
tmp.drawRect(self.barrelRect)
tmp.end()
@ -197,7 +197,7 @@ class CannonField(qt.TQWidget):
p.drawPixmap(cr.topLeft(), pix)
def cannonRect(self):
r = qt.TQRect(0, 0, 50, 50)
r = tqt.TQRect(0, 0, 50, 50)
r.moveBottomLeft(self.rect().bottomLeft())
return r
@ -215,29 +215,29 @@ class CannonField(qt.TQWidget):
x = x0 + velx * time
y = y0 + vely * time - 0.5 * gravity * time * time
r = qt.TQRect(0, 0, 6, 6)
r.moveCenter(qt.TQPoint(int(x), int(self.height() - 1 - y)))
r = tqt.TQRect(0, 0, 6, 6)
r.moveCenter(tqt.TQPoint(int(x), int(self.height() - 1 - y)))
return r
def targetRect(self):
r = qt.TQRect(0, 0, 20, 10)
r.moveCenter(qt.TQPoint(self.target.x(), self.height() - 1 - self.target.y()))
r = tqt.TQRect(0, 0, 20, 10)
r.moveCenter(tqt.TQPoint(self.target.x(), self.height() - 1 - self.target.y()))
return r
def isShooting(self):
return self.autoShootTimer.isActive()
def sizePolicy(self):
return qt.TQSizePolicy(qt.TQSizePolicy.Expanding, qt.TQSizePolicy.Expanding)
return tqt.TQSizePolicy(tqt.TQSizePolicy.Expanding, tqt.TQSizePolicy.Expanding)
class GameBoard(qt.TQWidget):
class GameBoard(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
quit = qt.TQPushButton("&Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
quit = tqt.TQPushButton("&Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
self.angle = LCDRange("ANGLE", self, "angle")
self.angle.setRange(5, 70)
@ -247,40 +247,40 @@ class GameBoard(qt.TQWidget):
self.cannonField = CannonField(self, "cannonField")
self.connect(self.angle, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, qt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.angle, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, tqt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.force, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, qt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
self.connect(self.force, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, tqt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
self.connect(self.cannonField, qt.PYSIGNAL("hit()"), self.hit)
self.connect(self.cannonField, qt.PYSIGNAL("missed()"), self.missed)
self.connect(self.cannonField, tqt.PYSIGNAL("hit()"), self.hit)
self.connect(self.cannonField, tqt.PYSIGNAL("missed()"), self.missed)
self.shoot = qt.TQPushButton("&Shoot", self, "shoot")
self.shoot.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(self.shoot, qt.SIGNAL("clicked()"), self.fire)
self.connect(self.cannonField, qt.PYSIGNAL("canShoot(bool)"), self.shoot, qt.SLOT("setEnabled(bool)"))
self.shoot = tqt.TQPushButton("&Shoot", self, "shoot")
self.shoot.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(self.shoot, tqt.SIGNAL("clicked()"), self.fire)
self.connect(self.cannonField, tqt.PYSIGNAL("canShoot(bool)"), self.shoot, tqt.SLOT("setEnabled(bool)"))
restart = qt.TQPushButton("&New Game", self, "newgame")
restart.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(restart, qt.SIGNAL("clicked()"), self.newGame)
restart = tqt.TQPushButton("&New Game", self, "newgame")
restart.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(restart, tqt.SIGNAL("clicked()"), self.newGame)
self.hits = qt.TQLCDNumber(2, self, "hits")
self.shotsLeft = qt.TQLCDNumber(2, self, "shotsleft")
hitsL = qt.TQLabel("HITS", self, "hitsLabel")
shotsLeftL = qt.TQLabel("SHOTS LEFT", self, "shotsleftLabel")
self.hits = tqt.TQLCDNumber(2, self, "hits")
self.shotsLeft = tqt.TQLCDNumber(2, self, "shotsleft")
hitsL = tqt.TQLabel("HITS", self, "hitsLabel")
shotsLeftL = tqt.TQLabel("SHOTS LEFT", self, "shotsleftLabel")
grid = qt.TQGridLayout(self, 2, 2, 10)
grid = tqt.TQGridLayout(self, 2, 2, 10)
grid.addWidget(quit, 0, 0)
grid.addWidget(self.cannonField, 1, 1)
grid.setColStretch(1, 10)
leftBox = qt.TQVBoxLayout()
leftBox tqt.TQVBoxLayout()
grid.addLayout(leftBox, 1, 0)
leftBox.addWidget(self.angle)
leftBox.addWidget(self.force)
topBox = qt.TQHBoxLayout()
topBox = tqt.TQHBoxLayout()
grid.addLayout(topBox, 0, 1)
topBox.addWidget(self.shoot)
topBox.addWidget(self.hits)
@ -320,8 +320,8 @@ class GameBoard(qt.TQWidget):
self.cannonField.newTarget()
qt.TQApplication.setColorSpec(qt.TQApplication.CustomColor)
a = qt.TQApplication(sys.argv)
qt.TQApplication.setColorSpec(tqt.TQApplication.CustomColor)
a = tqt.TQApplication(sys.argv)
gb = GameBoard()
gb.setGeometry(100, 100, 500, 355)

@ -5,27 +5,27 @@
import sys
import math
import random
from PyTQt import qt
from PyTQt import tqt
class LCDRange(qt.TQWidget):
class LCDRange(tqt.TQWidget):
def __init__(self, s=None, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
lcd = qt.TQLCDNumber(2, self, "lcd")
self.slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
lcd = tqt.TQLCDNumber(2, self, "lcd")
self.slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
self.slider.setRange(0, 99)
self.slider.setValue(0)
self.label = qt.TQLabel(" ", self, "label")
self.label.setAlignment(qt.TQt.AlignCenter)
self.label = tqt.TQLabel(" ", self, "label")
self.label.setAlignment(tqt.TQt.AlignCenter)
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), self, qt.PYSIGNAL("valueChanged(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), self, tqt.PYSIGNAL("valueChanged(int)"))
self.setFocusProxy(self.slider)
l = qt.TQVBoxLayout(self)
l = tqt.TQVBoxLayout(self)
l.addWidget(lcd, 1)
l.addWidget(self.slider)
l.addWidget(self.label)
@ -52,26 +52,26 @@ class LCDRange(qt.TQWidget):
self.label.setText(s)
class CannonField(qt.TQWidget):
class CannonField(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
self.ang = 45
self.f = 0
self.timerCount = 0
self.autoShootTimer = qt.TQTimer(self, "movement handler")
self.connect(self.autoShootTimer, qt.SIGNAL("timeout()"), self.moveShot)
self.autoShootTimer = tqt.TQTimer(self, "movement handler")
self.connect(self.autoShootTimer, tqt.SIGNAL("timeout()"), self.moveShot)
self.shoot_ang = 0
self.shoot_f = 0
self.target = qt.TQPoint(0, 0)
self.target = tqt.TQPoint(0, 0)
self.gameEnded = 0
self.barrelPressed = 0
self.setPalette(qt.TQPalette(qt.TQColor(250, 250, 200)))
self.setPalette(tqt.TQPalette(tqt.TQColor(250, 250, 200)))
self.barrelRect = qt.TQRect(33, -4, 15, 8)
self.barrelRect = tqt.TQRect(33, -4, 15, 8)
self.newTarget()
@ -87,7 +87,7 @@ class CannonField(qt.TQWidget):
return
self.ang = degrees
self.repaint(self.cannonRect(), 0)
self.emit(qt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
self.emit(tqt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
def force(self):
return self.f
@ -98,7 +98,7 @@ class CannonField(qt.TQWidget):
if self.f == newton:
return
self.f = newton
self.emit(qt.PYSIGNAL("forceChanged(int)"), (self.f, ))
self.emit(tqt.PYSIGNAL("forceChanged(int)"), (self.f, ))
def shoot(self):
if self.isShooting():
@ -108,12 +108,12 @@ class CannonField(qt.TQWidget):
self.shoot_ang = self.ang
self.shoot_f = self.f
self.autoShootTimer.start(50)
self.emit(qt.PYSIGNAL("canShoot(bool)"), (0, ))
self.emit(tqt.PYSIGNAL("canShoot(bool)"), (0, ))
def newTarget(self):
r = qt.TQRegion(self.targetRect())
self.target = qt.TQPoint(random.randint(200, 390), random.randint(10, 265))
self.repaint(r.unite(qt.TQRegion(self.targetRect())))
r = tqt.TQRegion(self.targetRect())
self.target = tqt.TQPoint(random.randint(200, 390), random.randint(10, 265))
self.repaint(r.unite(tqt.TQRegion(self.targetRect())))
def gameOver(self):
return self.gameEnded
@ -131,29 +131,29 @@ class CannonField(qt.TQWidget):
self.autoShootTime.stop()
self.gameEnded = 0
self.repaint()
self.emit(qt.PYSIGNAL("canShoot(bool)"), (1, ))
self.emit(tqt.PYSIGNAL("canShoot(bool)"), (1, ))
def moveShot(self):
r = qt.TQRegion(self.shotRect())
r = tqt.TQRegion(self.shotRect())
self.timerCount = self.timerCount + 1
shotR = self.shotRect()
if shotR.intersects(self.targetRect()):
self.autoShootTimer.stop()
self.emit(qt.PYSIGNAL("hit()"), ())
self.emit(qt.PYSIGNAL("canShoot(bool)"), (1, ))
self.emit(tqt.PYSIGNAL("hit()"), ())
self.emit(tqt.PYSIGNAL("canShoot(bool)"), (1, ))
elif shotR.x() > self.width() or shotR.y() > self.height() or shotR.intersects(self.barrierRect()):
self.autoShootTimer.stop()
self.emit(qt.PYSIGNAL("missed()"), ())
self.emit(qt.PYSIGNAL("canShoot(bool)"), (1, ))
self.emit(tqt.PYSIGNAL("missed()"), ())
self.emit(tqt.PYSIGNAL("canShoot(bool)"), (1, ))
else:
r = r.unite(qt.TQRegion(shotR))
r = r.unite(tqt.TQRegion(shotR))
self.repaint(r)
def mousePressEvent(self, ev):
if ev.button() != qt.TQt.LeftButton:
if ev.button() != tqt.TQt.LeftButton:
return
if self.barrelHit(ev.pos()):
self.barrelPressed = 1
@ -170,17 +170,17 @@ class CannonField(qt.TQWidget):
self.setAngle(int(round(rad * 180 / math.pi)))
def mouseReleaseEvent(self, ev):
if ev.button() == qt.TQt.LeftButton:
if ev.button() == tqt.TQt.LeftButton:
self.barrelPressed = 0
def paintEvent(self, ev):
updateR = ev.rect()
p = qt.TQPainter(self)
p = tqt.TQPainter(self)
if self.gameEnded:
p.setPen(qt.TQt.black)
p.setFont(qt.TQFont("Courier", 48, qt.TQFont.Bold))
p.drawText(self.rect(), qt.TQt.AlignCenter, "Game Over")
p.setPen(tqt.TQt.black)
p.setFont(tqt.TQFont("Courier", 48, tqt.TQFont.Bold))
p.drawText(self.rect(), tqt.TQt.AlignCenter, "Game Over")
if updateR.intersects(self.cannonRect()):
self.paintCannon(p)
@ -195,31 +195,31 @@ class CannonField(qt.TQWidget):
self.paintTarget(p)
def paintShot(self, p):
p.setBrush(qt.TQt.black)
p.setPen(qt.TQt.NoPen)
p.setBrush(tqt.TQt.black)
p.setPen(tqt.TQt.NoPen)
p.drawRect(self.shotRect())
def paintTarget(self, p):
p.setBrush(qt.TQt.red)
p.setPen(qt.TQt.black)
p.setBrush(tqt.TQt.red)
p.setPen(tqt.TQt.black)
p.drawRect(self.targetRect())
def paintBarrier(self, p):
p.setBrush(qt.TQt.yellow)
p.setPen(qt.TQt.black)
p.setBrush(tqt.TQt.yellow)
p.setPen(tqt.TQt.black)
p.drawRect(self.barrierRect())
def paintCannon(self, p):
cr = self.cannonRect()
pix = qt.TQPixmap(cr.size())
pix = tqt.TQPixmap(cr.size())
pix.fill(self, cr.topLeft())
tmp = qt.TQPainter(pix)
tmp.setBrush(qt.TQt.blue)
tmp.setPen(qt.TQt.NoPen)
tmp = tqt.TQPainter(pix)
tmp.setBrush(tqt.TQt.blue)
tmp.setPen(tqt.TQt.NoPen)
tmp.translate(0, pix.height() - 1)
tmp.drawPie(qt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
tmp.drawPie(tqt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
tmp.rotate(-self.ang)
tmp.drawRect(self.barrelRect)
tmp.end()
@ -227,7 +227,7 @@ class CannonField(qt.TQWidget):
p.drawPixmap(cr.topLeft(), pix)
def cannonRect(self):
r = qt.TQRect(0, 0, 50, 50)
r = tqt.TQRect(0, 0, 50, 50)
r.moveBottomLeft(self.rect().bottomLeft())
return r
@ -245,20 +245,20 @@ class CannonField(qt.TQWidget):
x = x0 + velx * time
y = y0 + vely * time - 0.5 * gravity * time * time
r = qt.TQRect(0, 0, 6, 6)
r.moveCenter(qt.TQPoint(int(x), int(self.height() - 1 - y)))
r = tqt.TQRect(0, 0, 6, 6)
r.moveCenter(tqt.TQPoint(int(x), int(self.height() - 1 - y)))
return r
def targetRect(self):
r = qt.TQRect(0, 0, 20, 10)
r.moveCenter(qt.TQPoint(self.target.x(), self.height() - 1 - self.target.y()))
r = tqt.TQRect(0, 0, 20, 10)
r.moveCenter(tqt.TQPoint(self.target.x(), self.height() - 1 - self.target.y()))
return r
def barrierRect(self):
return qt.TQRect(145, self.height() - 100, 15, 100)
return tqt.TQRect(145, self.height() - 100, 15, 100)
def barrelHit(self, p):
mtx = qt.TQWMatrix()
mtx = tqt.TQWMatrix()
mtx.translate(0, self.height() - 1)
mtx.rotate(-self.ang)
(mtx, invertable) = mtx.invert()
@ -268,16 +268,16 @@ class CannonField(qt.TQWidget):
return self.autoShootTimer.isActive()
def sizePolicy(self):
return qt.TQSizePolicy(qt.TQSizePolicy.Expanding, qt.TQSizePolicy.Expanding)
return tqt.TQSizePolicy(tqt.TQSizePolicy.Expanding, tqt.TQSizePolicy.Expanding)
class GameBoard(qt.TQWidget):
class GameBoard(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
quit = qt.TQPushButton("&Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
quit = tqt.TQPushButton("&Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
self.angle = LCDRange("ANGLE", self, "angle")
self.angle.setRange(5, 70)
@ -285,50 +285,50 @@ class GameBoard(qt.TQWidget):
self.force = LCDRange("FORCE", self, "force")
self.force.setRange(10, 50)
box = qt.TQVBox(self, "cannonFrame")
box.setFrameStyle(qt.TQFrame.WinPanel | qt.TQFrame.Sunken)
box = tqt.TQVBox(self, "cannonFrame")
box.setFrameStyle(tqt.TQFrame.WinPanel | tqt.TQFrame.Sunken)
self.cannonField = CannonField(box, "cannonField")
self.connect(self.angle, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, qt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.angle, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, tqt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.force, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, qt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
self.connect(self.force, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setForce)
self.connect(self.cannonField, tqt.PYSIGNAL("forceChanged(int)"), self.force.setValue)
self.connect(self.cannonField, qt.PYSIGNAL("hit()"), self.hit)
self.connect(self.cannonField, qt.PYSIGNAL("missed()"), self.missed)
self.connect(self.cannonField, tqt.PYSIGNAL("hit()"), self.hit)
self.connect(self.cannonField, tqt.PYSIGNAL("missed()"), self.missed)
self.shoot = qt.TQPushButton("&Shoot", self, "shoot")
self.shoot.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(self.shoot, qt.SIGNAL("clicked()"), self.fire)
self.connect(self.cannonField, qt.PYSIGNAL("canShoot(bool)"), self.shoot, qt.SLOT("setEnabled(bool)"))
self.shoot = tqt.TQPushButton("&Shoot", self, "shoot")
self.shoot.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(self.shoot, tqt.SIGNAL("clicked()"), self.fire)
self.connect(self.cannonField, tqt.PYSIGNAL("canShoot(bool)"), self.shoot, tqt.SLOT("setEnabled(bool)"))
restart = qt.TQPushButton("&New Game", self, "newgame")
restart.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(restart, qt.SIGNAL("clicked()"), self.newGame)
restart = tqt.TQPushButton("&New Game", self, "newgame")
restart.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(restart, tqt.SIGNAL("clicked()"), self.newGame)
self.hits = qt.TQLCDNumber(2, self, "hits")
self.shotsLeft = qt.TQLCDNumber(2, self, "shotsleft")
hitsL = qt.TQLabel("HITS", self, "hitsLabel")
shotsLeftL = qt.TQLabel("SHOTS LEFT", self, "shotsleftLabel")
self.hits = tqt.TQLCDNumber(2, self, "hits")
self.shotsLeft = tqt.TQLCDNumber(2, self, "shotsleft")
hitsL = tqt.TQLabel("HITS", self, "hitsLabel")
shotsLeftL = tqt.TQLabel("SHOTS LEFT", self, "shotsleftLabel")
accel = qt.TQAccel(self)
accel.connectItem(accel.insertItem(qt.TQt.Key_Enter), self.fire)
accel.connectItem(accel.insertItem(qt.TQt.Key_Return), self.fire)
accel.connectItem(accel.insertItem(qt.TQt.CTRL + qt.TQt.Key_Q), qt.tqApp, qt.SLOT("quit()"))
accel = tqt.TQAccel(self)
accel.connectItem(accel.insertItem(tqt.TQt.Key_Enter), self.fire)
accel.connectItem(accel.insertItem(tqt.TQt.Key_Return), self.fire)
accel.connectItem(accel.insertItem(tqt.TQt.CTRL + tqt.TQt.Key_Q), tqt.tqApp, tqt.SLOT("quit()"))
grid = qt.TQGridLayout(self, 2, 2, 10)
grid = tqt.TQGridLayout(self, 2, 2, 10)
grid.addWidget(quit, 0, 0)
grid.addWidget(box, 1, 1)
grid.setColStretch(1, 10)
leftBox = qt.TQVBoxLayout()
leftBox = tqt.TQVBoxLayout()
grid.addLayout(leftBox, 1, 0)
leftBox.addWidget(self.angle)
leftBox.addWidget(self.force)
topBox = qt.TQHBoxLayout()
topBox = tqt.TQHBoxLayout()
grid.addLayout(topBox, 0, 1)
topBox.addWidget(self.shoot)
topBox.addWidget(self.hits)
@ -368,8 +368,8 @@ class GameBoard(qt.TQWidget):
self.cannonField.newTarget()
qt.TQApplication.setColorSpec(qt.TQApplication.CustomColor)
a = qt.TQApplication(sys.argv)
qt.TQApplication.setColorSpec(tqt.TQApplication.CustomColor)
a = tqt.TQApplication(sys.argv)
gb = GameBoard()
gb.setGeometry(100, 100, 500, 355)

@ -3,16 +3,16 @@
# TQt tutorial 2.
import sys
from PyTQt import qt
from PyTQt import tqt
a = qt.TQApplication(sys.argv)
a = tqt.TQApplication(sys.argv)
quit = qt.TQPushButton("Quit", None)
quit = tqt.TQPushButton("Quit", None)
quit.resize(75, 30)
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
qt.TQObject.connect(quit, qt.SIGNAL("clicked()"), a, qt.SLOT("quit()"))
qt.TQObject.connect(quit, tqt.SIGNAL("clicked()"), a, tqt.SLOT("quit()"))
a.setMainWidget(quit)
quit.show()

@ -3,18 +3,18 @@
# TQt tutorial 3.
import sys
from PyTQt import qt
from PyTQt import tqt
a = qt.TQApplication(sys.argv)
a = tqt.TQApplication(sys.argv)
box = qt.TQVBox()
box = tqt.TQVBox()
box.resize(200, 120)
quit = qt.TQPushButton("Quit", box)
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
quit = tqt.TQPushButton("Quit", box)
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
qt.TQObject.connect(quit, qt.SIGNAL("clicked()"), a, qt.SLOT("quit()"))
qt.TQObject.connect(quit, tqt.SIGNAL("clicked()"), a, tqt.SLOT("quit()"))
a.setMainWidget(box)
box.show()

@ -3,24 +3,24 @@
# TQt tutorial 4.
import sys
from PyTQt import qt
from PyTQt import tqt
class MyWidget(qt.TQWidget):
class MyWidget(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
self.setMinimumSize(200, 120)
self.setMaximumSize(200, 120)
quit = qt.TQPushButton("Quit", self, "quit")
quit = tqt.TQPushButton("Quit", self, "quit")
quit.setGeometry(62, 40, 75, 30)
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
a = qt.TQApplication(sys.argv)
a = tqt.TQApplication(sys.argv)
w = MyWidget()
w.setGeometry(100, 100, 200, 120)

@ -3,28 +3,28 @@
# TQt tutorial 5.
import sys
from PyTQt import qt
from PyTQt import tqt
class MyWidget(qt.TQVBox):
class MyWidget(tqt.TQVBox):
def __init__(self, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
quit = qt.TQPushButton("Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
quit = tqt.TQPushButton("Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
lcd = qt.TQLCDNumber(2, self, "lcd")
lcd = tqt.TQLCDNumber(2, self, "lcd")
slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
slider.setRange(0, 99)
slider.setValue(0)
self.connect(slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
a = qt.TQApplication(sys.argv)
a = tqt.TQApplication(sys.argv)
w = MyWidget()
a.setMainWidget(w)

@ -3,37 +3,37 @@
# TQt tutorial 6.
import sys
from PyTQt import qt
from PyTQt import tqt
class LCDRange(qt.TQVBox):
class LCDRange(tqt.TQVBox):
def __init__(self, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
lcd = qt.TQLCDNumber(2, self, "lcd")
slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
lcd = tqt.TQLCDNumber(2, self, "lcd")
slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
slider.setRange(0, 99)
slider.setValue(0)
self.connect(slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
class MyWidget(qt.TQVBox):
class MyWidget(tqt.TQVBox):
def __init__(self, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
quit = qt.TQPushButton("Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
quit = tqt.TQPushButton("Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
grid = qt.TQGrid(4, self)
grid = tqt.TQGrid(4, self)
for c in range(4):
for r in range(4):
LCDRange(grid)
a = qt.TQApplication(sys.argv)
a = tqt.TQApplication(sys.argv)
w = MyWidget()
a.setMainWidget(w)

@ -3,19 +3,19 @@
# TQt tutorial 7.
import sys
from PyTQt import qt
from PyTQt import tqt
class LCDRange(qt.TQVBox):
class LCDRange(tqt.TQVBox):
def __init__(self, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
lcd = qt.TQLCDNumber(2, self, "lcd")
self.slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
lcd = tqt.TQLCDNumber(2, self, "lcd")
self.slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
self.slider.setRange(0, 99)
self.slider.setValue(0)
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), self, qt.PYSIGNAL("valueChanged(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), self, tqt.PYSIGNAL("valueChanged(int)"))
def value(self):
return self.slider.value()
@ -24,16 +24,16 @@ class LCDRange(qt.TQVBox):
self.slider.setValue(value)
class MyWidget(qt.TQVBox):
class MyWidget(tqt.TQVBox):
def __init__(self, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
quit = qt.TQPushButton("Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
quit = tqt.TQPushButton("Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
grid = qt.TQGrid(4, self)
grid = tqt.TQGrid(4, self)
self.lcdlist = []
previous = None
@ -43,13 +43,13 @@ class MyWidget(qt.TQVBox):
lr = LCDRange(grid)
if previous:
self.connect(lr, qt.PYSIGNAL("valueChanged(int)"), previous.setValue)
self.connect(lr, tqt.PYSIGNAL("valueChanged(int)"), previous.setValue)
previous = lr
self.lcdlist.append(lr)
a = qt.TQApplication(sys.argv)
a = tqt.TQApplication(sys.argv)
w = MyWidget()
a.setMainWidget(w)

@ -3,19 +3,19 @@
# TQt tutorial 8.
import sys
from PyTQt import qt
from PyTQt import tqt
class LCDRange(qt.TQVBox):
class LCDRange(tqt.TQVBox):
def __init__(self, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
lcd = qt.TQLCDNumber(2, self, "lcd")
self.slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
lcd = tqt.TQLCDNumber(2, self, "lcd")
self.slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
self.slider.setRange(0, 99)
self.slider.setValue(0)
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), self, qt.PYSIGNAL("valueChanged(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), self, tqt.PYSIGNAL("valueChanged(int)"))
self.setFocusProxy(self.slider)
@ -32,12 +32,12 @@ class LCDRange(qt.TQVBox):
self.slider.setRange(minVal, maxVal)
class CannonField(qt.TQWidget):
class CannonField(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
self.ang = 45
self.setPalette(qt.TQPalette(qt.TQColor(250, 250, 200)))
self.setPalette(tqt.TQPalette(tqt.TQColor(250, 250, 200)))
def angle(self):
return self.ang
@ -51,36 +51,36 @@ class CannonField(qt.TQWidget):
return
self.ang = degrees
self.repaint()
self.emit(qt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
self.emit(tqt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
def paintEvent(self, ev):
p = qt.TQPainter(self)
p = tqt.TQPainter(self)
p.drawText(200, 200, "Angle = %d" % (self.ang))
def sizePolicy(self):
return qt.TQSizePolicy(qt.TQSizePolicy.Expanding, qt.TQSizePolicy.Expanding)
return tqt.TQSizePolicy(tqt.TQSizePolicy.Expanding, tqt.TQSizePolicy.Expanding)
class MyWidget(qt.TQWidget):
class MyWidget(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
quit = qt.TQPushButton("Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
quit = tqt.TQPushButton("Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
self.angle = LCDRange(self, "angle")
self.angle.setRange(5, 70)
self.cannonField = CannonField(self, "cannonField")
self.connect(self.angle, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, qt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.angle, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, tqt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
grid = qt.TQGridLayout(self, 2, 2, 10)
grid = tqt.TQGridLayout(self, 2, 2, 10)
grid.addWidget(quit, 0, 0)
grid.addWidget(self.angle, 1, 0, qt.TQt.AlignTop)
grid.addWidget(self.angle, 1, 0, tqt.TQt.AlignTop)
grid.addWidget(self.cannonField, 1, 1)
grid.setColStretch(1, 10)
@ -88,7 +88,7 @@ class MyWidget(qt.TQWidget):
self.angle.setFocus()
a = qt.TQApplication(sys.argv)
a = tqt.TQApplication(sys.argv)
w = MyWidget()
w.setGeometry(100, 100, 500, 355)

@ -3,19 +3,19 @@
# TQt tutorial 9.
import sys
from PyTQt import qt
from PyTQt import tqt
class LCDRange(qt.TQVBox):
class LCDRange(tqt.TQVBox):
def __init__(self, parent=None, name=None):
qt.TQVBox.__init__(self, parent, name)
tqt.TQVBox.__init__(self, parent, name)
lcd = qt.TQLCDNumber(2, self, "lcd")
self.slider = qt.TQSlider(qt.TQt.Horizontal, self, "slider")
lcd = tqt.TQLCDNumber(2, self, "lcd")
self.slider = tqt.TQSlider(tqt.TQt.Horizontal, self, "slider")
self.slider.setRange(0, 99)
self.slider.setValue(0)
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), lcd, qt.SLOT("display(int)"))
self.connect(self.slider, qt.SIGNAL("valueChanged(int)"), self, qt.PYSIGNAL("valueChanged(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), lcd, tqt.SLOT("display(int)"))
self.connect(self.slider, tqt.SIGNAL("valueChanged(int)"), self, tqt.PYSIGNAL("valueChanged(int)"))
self.setFocusProxy(self.slider)
@ -31,12 +31,12 @@ class LCDRange(qt.TQVBox):
self.slider.setRange(minVal, maxVal)
class CannonField(qt.TQWidget):
class CannonField(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
self.ang = 45
self.setPalette(qt.TQPalette(qt.TQColor(250, 250, 200)))
self.setPalette(tqt.TQPalette(tqt.TQColor(250, 250, 200)))
def angle(self):
return self.ang
@ -50,43 +50,43 @@ class CannonField(qt.TQWidget):
return
self.ang = degrees
self.repaint()
self.emit(qt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
self.emit(tqt.PYSIGNAL("angleChanged(int)"), (self.ang, ))
def paintEvent(self, ev):
p = qt.TQPainter(self)
p = tqt.TQPainter(self)
p.setBrush(qt.TQt.blue)
p.setPen(qt.TQt.NoPen)
p.setBrush(tqt.TQt.blue)
p.setPen(tqt.TQt.NoPen)
p.translate(0, self.rect().bottom())
p.drawPie(qt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
p.drawPie(tqt.TQRect(-35, -35, 70, 70), 0, 90 * 16)
p.rotate(-self.ang)
p.drawRect(qt.TQRect(33, -4, 15, 8))
p.drawRect(tqt.TQRect(33, -4, 15, 8))
def sizePolicy(self):
return qt.TQSizePolicy(qt.TQSizePolicy.Expanding, qt.TQSizePolicy.Expanding)
return tqt.TQSizePolicy(tqt.TQSizePolicy.Expanding, tqt.TQSizePolicy.Expanding)
class MyWidget(qt.TQWidget):
class MyWidget(tqt.TQWidget):
def __init__(self, parent=None, name=None):
qt.TQWidget.__init__(self, parent, name)
tqt.TQWidget.__init__(self, parent, name)
quit = qt.TQPushButton("&Quit", self, "quit")
quit.setFont(qt.TQFont("Times", 18, qt.TQFont.Bold))
self.connect(quit, qt.SIGNAL("clicked()"), qt.tqApp, qt.SLOT("quit()"))
quit = tqt.TQPushButton("&Quit", self, "quit")
quit.setFont(tqt.TQFont("Times", 18, tqt.TQFont.Bold))
self.connect(quit, tqt.SIGNAL("clicked()"), tqt.tqApp, tqt.SLOT("quit()"))
self.angle = LCDRange(self, "angle")
self.angle.setRange(5, 70)
self.cannonField = CannonField(self, "cannonField")
self.connect(self.angle, qt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, qt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
self.connect(self.angle, tqt.PYSIGNAL("valueChanged(int)"), self.cannonField.setAngle)
self.connect(self.cannonField, tqt.PYSIGNAL("angleChanged(int)"), self.angle.setValue)
grid = qt.TQGridLayout(self, 2, 2, 10)
grid = tqt.TQGridLayout(self, 2, 2, 10)
grid.addWidget(quit, 0, 0)
grid.addWidget(self.angle, 1, 0, qt.TQt.AlignTop)
grid.addWidget(self.angle, 1, 0, tqt.TQt.AlignTop)
grid.addWidget(self.cannonField, 1, 1)
grid.setColStretch(1, 10)
@ -94,8 +94,8 @@ class MyWidget(qt.TQWidget):
self.angle.setFocus()
qt.TQApplication.setColorSpec(qt.TQApplication.CustomColor)
a = qt.TQApplication(sys.argv)
qt.TQApplication.setColorSpec(tqt.TQApplication.CustomColor)
a = tqt.TQApplication(sys.argv)
w = MyWidget()
w.setGeometry(100, 100, 500, 355)

@ -3,13 +3,13 @@
# Form implementation generated from reading ui file 'mainwindow.ui'
#
# Created: Sun Dec 5 14:50:47 2004
# by: The PyTQt User Interface Compiler (pyuic) snapshot-20041203
# by: The PyTQt User Interface Compiler (pytquic) snapshot-20041203
#
# WARNING! All changes made in this file will be lost!
from PyTQt.qt import *
from PyTQt.qtaxcontainer import TQAxWidget
from PyTQt.tqt import *
from PyTQt.tqtaxcontainer import TQAxWidget
image0_data = [
"32 32 3 1",
@ -925,7 +925,7 @@ class MainWindow(TQMainWindow):
self.setName("MainWindow")
self.setCentralWidget(TQWidget(self,"qt_central_widget"))
self.setCentralWidget(TQWidget(self,"tqt_central_widget"))
MainWindowLayout = TQHBoxLayout(self.centralWidget(),0,6,"MainWindowLayout")
self.Frame3 = TQFrame(self.centralWidget(),"Frame3")

@ -7,21 +7,21 @@
import sys
from PyTQt import qt
from PyTQt import qtaxcontainer
from PyTQt import tqt
from PyTQt import tqtaxcontainer
import mainwindow
class MainWindowImpl(mainwindow.MainWindow):
def init(self):
self.pb = qt.TQProgressBar(self.statusBar())
self.pb = tqt.TQProgressBar(self.statusBar())
self.pb.setPercentageVisible(False)
self.pb.hide()
self.statusBar().addWidget(self.pb, 0, True)
self.connect(self.WebBrowser, qt.SIGNAL("ProgressChange(int,int)"), self.setProgress)
self.connect(self.WebBrowser, qt.SIGNAL("StatusTextChange(const TQString&)"), self.statusBar(), qt.SLOT("message(const TQString&)"))
self.connect(self.WebBrowser, tqt.SIGNAL("ProgressChange(int,int)"), self.setProgress)
self.connect(self.WebBrowser, tqt.SIGNAL("StatusTextChange(const TQString&)"), self.statusBar(), tqt.SLOT("message(const TQString&)"))
self.WebBrowser.dynamicCall("GoHome()");
@ -29,7 +29,7 @@ class MainWindowImpl(mainwindow.MainWindow):
def go(self):
self.actionStop.setEnabled(True)
self.WebBrowser.dynamicCall("Navigate(const TQString&)", qt.TQVariant(self.addressEdit.text()))
self.WebBrowser.dynamicCall("Navigate(const TQString&)", tqt.TQVariant(self.addressEdit.text()))
def setTitle(self, title):
self.setCaption("TQt WebBrowser - " + title.latin1())
@ -69,17 +69,17 @@ class MainWindowImpl(mainwindow.MainWindow):
self.subwindows += window
def aboutSlot(self):
qt.TQMessageBox.about(self, self.tr("About WebBrowser"), self.tr(
tqt.TQMessageBox.about(self, self.tr("About WebBrowser"), self.tr(
"""This Example has been created using the ActiveTQt integration into TQt Designer.
It demonstrates the use of TQAxWidget to embed the Internet Explorer ActiveX
control into a TQt application."""))
def aboutTQtSlot(self):
qt.TQMessageBox.aboutTQt(self, self.tr("About TQt"))
tqt.TQMessageBox.aboutTQt(self, self.tr("About TQt"))
def main(args):
a = qt.TQApplication(args)
a = tqt.TQApplication(args)
w = MainWindowImpl()
a.setMainWidget(w)
w.show()

@ -2,7 +2,7 @@
import sys, string
from PyTQt.qt import *
from PyTQt.tqt import *
#
## Constructs an analog clock widget that uses an internal TQTimer.
@ -36,7 +36,7 @@ class AnalogClock( TQWidget ):
#
## The clock is painted using a 1000x1000 square coordinate system.
#
def paintEvent( self, qe ): # paint clock
def paintEvent( self, tqe ): # paint clock
if not self.isVisible(): # is is invisible
return
self.time = TQTime.currentTime() # save current time
@ -192,10 +192,10 @@ class WidgetView ( TQWidget ):
self.connect( self.pb, SIGNAL("clicked()"), self.button1Clicked )
TQToolTip.add( self.pb, "push button 1" )
self.pm = TQPixmap()
self.pix = self.pm.load( "qt.png" ) # load pixmap for button 2
self.pix = self.pm.load( "tqt.png" ) # load pixmap for button 2
if not self.pix:
TQMessageBox.information( None, "TQt Widgets Example",
"Could not load the file \"qt.png\", which\n"
"Could not load the file \"tqt.png\", which\n"
"contains an icon used...\n\n"
"The text \"line 42\" will be substituted.",
TQMessageBox.Ok + TQMessageBox.Default )

@ -7,8 +7,8 @@ for m_path in sys.path:
m_sip_dir = os.path.join(m_path, 'sip4_tqt')
tqt_modules.insert(0, m_sip_dir)
if os.path.exists(os.path.join(m_path, 'PyTQt')):
m_pyqt_dir = os.path.join(m_path, 'PyTQt')
tqt_modules.insert(0, m_pyqt_dir)
m_pytqt_dir = os.path.join(m_path, 'PyTQt')
tqt_modules.insert(0, m_pytqt_dir)
for m_path in tqt_modules:
sys.path.insert(0, m_path)
@ -31,22 +31,22 @@ def is_module_available(module_name):
# Base modules
__all__ = [
'qt',
'qtcanvas',
'qtnetwork',
'qttable',
'qtsql',
'qtui',
'qtxml',
'tqt',
'tqtcanvas',
'tqtnetwork',
'tqttable',
'tqtsql',
'tqtui',
'tqtxml',
]
# Optional modules
if is_module_available('qtaxcontainer'):
__all__.append('qtaxcontainer')
if is_module_available('qtext'):
__all__.append('qtext')
if is_module_available('qtgl'):
__all__.append('qtgl')
if is_module_available('tqtaxcontainer'):
__all__.append('tqtaxcontainer')
if is_module_available('tqtext'):
__all__.append('tqtext')
if is_module_available('tqtgl'):
__all__.append('tqtgl')
# Import namespaces
from PyTQt import *

@ -444,7 +444,7 @@ void fetchtr_py( const char *fileName, MetaTranslator *tor,
yyInFile = fopen( fileName, "r" );
if ( yyInFile == 0 ) {
if ( mustExist )
tqWarning( "pylupdate error: cannot open Python source file '%s': %s",
tqWarning( "pytqlupdate error: cannot open Python source file '%s': %s",
fileName, strerror(errno) );
return;
}

@ -51,7 +51,7 @@ typedef TQValueList<MetaTranslatorMessage> TML;
static void printUsage()
{
tqWarning( "Usage: pylupdate [options] file.pro...\n"
tqWarning( "Usage: pytqlupdate [options] file.pro...\n"
"Options:\n"
" -help Display this information and exits\n"
" -noobsolete\n"
@ -59,7 +59,7 @@ static void printUsage()
" -verbose\n"
" Explain what is being done\n"
" -version\n"
" Display the version of pylupdate and exits" );
" Display the version of pytqlupdate and exits" );
}
int main( int argc, char **argv )
@ -80,14 +80,14 @@ int main( int argc, char **argv )
verbose = TRUE;
continue;
} else if ( qstrcmp(argv[i], "-version") == 0 ) {
tqWarning( "pylupdate version %s", TQT_VERSION_STR );
tqWarning( "pytqlupdate version %s", TQT_VERSION_STR );
return 0;
}
numProFiles++;
TQFile f( argv[i] );
if ( !f.open(IO_ReadOnly) ) {
tqWarning( "pylupdate error: Cannot open project file '%s': %s",
tqWarning( "pytqlupdate error: Cannot open project file '%s': %s",
argv[i], strerror(errno) );
return 1;
}
@ -135,14 +135,14 @@ int main( int argc, char **argv )
tor.stripObsoleteMessages();
tor.stripEmptyContexts();
if ( !tor.save(*tf) )
tqWarning( "pylupdate error: Cannot save '%s': %s", (*tf).utf8(),
tqWarning( "pytqlupdate error: Cannot save '%s': %s", (*tf).utf8(),
strerror(errno) );
}
if ( !metSomething ) {
tqWarning( "pylupdate warning: File '%s' does not look like a project"
tqWarning( "pytqlupdate warning: File '%s' does not look like a project"
" file", argv[i] );
} else if ( translatorFiles.isEmpty() ) {
tqWarning( "pylupdate warning: Met no 'TRANSLATIONS' entry in project"
tqWarning( "pytqlupdate warning: Met no 'TRANSLATIONS' entry in project"
" file '%s'", argv[i] );
}
}

@ -1,4 +1,4 @@
# This is the build file for pylupdate for TQt v3 Professional Edition.
# This is the build file for pytqlupdate for TQt v3 Professional Edition.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -19,6 +19,6 @@
# PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
target = pylupdate
target = pytqlupdate
sources = fetchtr.cpp main.cpp merge.cpp numberh.cpp sametexth.cpp metatranslator.cpp proparser.cpp qxml.cpp
headers = metatranslator.h proparser.h

@ -1,16 +1,16 @@
# Copyright (c) 2002
# Detlev Offenbach <detlev@die-offenbachs.de>
#
# The project file pylupdate for TQt v3.
# The project file pytqlupdate for TQt v3.
TEMPLATE = app
CONFIG += qt warn_on console release @PYQT_RBPROF@
CONFIG += tqt warn_on console release @PYTQT_RBPROF@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = QT_INTERNAL_XML @BLX_DEFINES@
DEFINES = TQT_INTERNAL_XML @BLX_DEFINES@
DESTDIR = @PYQT_BINDIR@
TARGET = pylupdate
DESTDIR = @PYTQT_BINDIR@
TARGET = pytqlupdate
HEADERS = metatranslator.h \
proparser.h
@ -24,6 +24,6 @@ SOURCES = fetchtr.cpp \
proparser.cpp
rbprof:exists($(TQTDIR)/src/qt_professional.pri) {
QT_SOURCE_TREE = $(TQTDIR)
TQT_SOURCE_TREE = $(TQTDIR)
include($(TQTDIR)/src/qt_professional.pri)
}

@ -1,4 +1,4 @@
# This is the build file for pylupdate for TQt v3 Professional Edition.
# This is the build file for pytqlupdate for TQt v3 Professional Edition.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -19,6 +19,6 @@
# PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
target = pylupdate
target = pytqlupdate
sources = fetchtr.cpp main.cpp merge.cpp numberh.cpp sametexth.cpp metatranslator.cpp proparser.cpp
headers = metatranslator.h proparser.h

@ -48,12 +48,12 @@ class Configuration(sip_tqt_config.Configuration):
class TQtModuleMakefile(sip_tqt_config.SIPModuleMakefile):
"""The Makefile class for modules that %Import qt.
"""The Makefile class for modules that %Import tqt.
"""
def __init__(self, *args, **kw):
"""Initialise an instance of a module Makefile.
"""
kw["qt"] = 1
kw["tqt"] = 1
apply(sip_tqt_config.SIPModuleMakefile.__init__, (self, ) + args, kw)
def finalise(self):
@ -62,55 +62,55 @@ class TQtModuleMakefile(sip_tqt_config.SIPModuleMakefile):
if self.config.sip_version < 0x040000:
# Note that we don't use self.extra_lib_dirs because we don't want
# it to be added to the rpath.
self.LIBDIR.append(self.config.pyqt_mod_dir)
self.extra_libs.append(self.module_as_lib("qt"))
self.LIBDIR.append(self.config.pytqt_mod_dir)
self.extra_libs.append(self.module_as_lib("tqt"))
sip_tqt_config.SIPModuleMakefile.finalise(self)
class TQtAxContainerModuleMakefile(TQtModuleMakefile):
"""The Makefile class for modules that %Import qtaxcontainer.
"""The Makefile class for modules that %Import tqtaxcontainer.
"""
def finalise(self):
"""Finalise the macros.
"""
if self.config.sip_version < 0x040000:
self.extra_libs.append(self.module_as_lib("qtaxcontainer"))
self.extra_libs.append(self.module_as_lib("tqtaxcontainer"))
TQtModuleMakefile.finalise(self)
class TQtCanvasModuleMakefile(TQtModuleMakefile):
"""The Makefile class for modules that %Import qtcanvas.
"""The Makefile class for modules that %Import tqtcanvas.
"""
def finalise(self):
"""Finalise the macros.
"""
if self.config.sip_version < 0x040000:
self.extra_libs.append(self.module_as_lib("qtcanvas"))
self.extra_libs.append(self.module_as_lib("tqtcanvas"))
TQtModuleMakefile.finalise(self)
class TQtExtModuleMakefile(TQtModuleMakefile):
"""The Makefile class for modules that %Import qtext.
"""The Makefile class for modules that %Import tqtext.
"""
def finalise(self):
"""Finalise the macros.
"""
if self.config.sip_version < 0x040000:
self.extra_libs.append(self.module_as_lib("qtext"))
self.extra_libs.append(self.module_as_lib("tqtext"))
self.extra_defines.extend(self.config._pyqt_qscintilla_defines)
self.extra_include_dirs.append(self.config._pyqt_qscintilla_inc_dir)
self.extra_lib_dirs.append(self.config._pyqt_qscintilla_lib_dir)
self.extra_defines.extend(self.config._pytqt_tqscintilla_defines)
self.extra_include_dirs.append(self.config._pytqt_tqscintilla_inc_dir)
self.extra_lib_dirs.append(self.config._pytqt_tqscintilla_lib_dir)
self.extra_libs.append("tqscintilla")
TQtModuleMakefile.finalise(self)
class TQtGLModuleMakefile(TQtModuleMakefile):
"""The Makefile class for modules that %Import qtgl.
"""The Makefile class for modules that %Import tqtgl.
"""
def __init__(self, *args, **kw):
"""Initialise an instance of a module Makefile.
@ -122,66 +122,66 @@ class TQtGLModuleMakefile(TQtModuleMakefile):
"""Finalise the macros.
"""
if self.config.sip_version < 0x040000:
self.extra_libs.append(self.module_as_lib("qtgl"))
self.extra_libs.append(self.module_as_lib("tqtgl"))
TQtModuleMakefile.finalise(self)
class TQtNetworkModuleMakefile(TQtModuleMakefile):
"""The Makefile class for modules that %Import qtnetwork.
"""The Makefile class for modules that %Import tqtnetwork.
"""
def finalise(self):
"""Finalise the macros.
"""
if self.config.sip_version < 0x040000:
self.extra_libs.append(self.module_as_lib("qtnetwork"))
self.extra_libs.append(self.module_as_lib("tqtnetwork"))
TQtModuleMakefile.finalise(self)
class TQtTableModuleMakefile(TQtModuleMakefile):
"""The Makefile class for modules that %Import qttable.
"""The Makefile class for modules that %Import tqttable.
"""
def finalise(self):
"""Finalise the macros.
"""
if self.config.sip_version < 0x040000:
self.extra_libs.append(self.module_as_lib("qttable"))
self.extra_libs.append(self.module_as_lib("tqttable"))
TQtModuleMakefile.finalise(self)
class TQtSQLModuleMakefile(TQtTableModuleMakefile):
"""The Makefile class for modules that %Import qtsql.
"""The Makefile class for modules that %Import tqtsql.
"""
def finalise(self):
"""Finalise the macros.
"""
if self.config.sip_version < 0x040000:
self.extra_libs.append(self.module_as_lib("qtsql"))
self.extra_libs.append(self.module_as_lib("tqtsql"))
TQtTableModuleMakefile.finalise(self)
class TQtUIModuleMakefile(TQtModuleMakefile):
"""The Makefile class for modules that %Import qtui.
"""The Makefile class for modules that %Import tqtui.
"""
def finalise(self):
"""Finalise the macros.
"""
if self.config.sip_version < 0x040000:
self.extra_libs.append(self.module_as_lib("qtui"))
self.extra_libs.append(self.module_as_lib("tqtui"))
TQtModuleMakefile.finalise(self)
class TQtXMLModuleMakefile(TQtModuleMakefile):
"""The Makefile class for modules that %Import qtxml.
"""The Makefile class for modules that %Import tqtxml.
"""
def finalise(self):
"""Finalise the macros.
"""
if self.config.sip_version < 0x040000:
self.extra_libs.append(self.module_as_lib("qtxml"))
self.extra_libs.append(self.module_as_lib("tqtxml"))
TQtModuleMakefile.finalise(self)

@ -128,13 +128,13 @@ void Uic::embed( TQTextStream& out, const char* project, const TQStringList& ima
for ( it = images.begin(); it != images.end(); ++it )
out << "# " << *it << "\n";
out << "#\n";
out << "# Created by: The PyTQt User Interface Compiler (pyuic) " << PYTQT_VERSION << "\n";
out << "# Created by: The PyTQt User Interface Compiler (pytquic) " << PYTQT_VERSION << "\n";
out << "#\n";
out << "# WARNING! All changes made in this file will be lost!\n";
out << "\n";
out << "\n";
out << "from PyTQt.qt import TQImage, TQMimeSourceFactory";
out << "from PyTQt.tqt import TQImage, TQMimeSourceFactory";
#ifndef TQT_NO_IMAGE_COLLECTION_COMPRESSION
out << ", tqUncompress";
#endif
@ -149,7 +149,7 @@ void Uic::embed( TQTextStream& out, const char* project, const TQStringList& ima
for ( it = images.begin(); it != images.end(); ++it ) {
TQImage img;
if ( !img.load( *it ) ) {
fprintf( stderr, "pyuic: cannot load image file %s\n", (*it).utf8() );
fprintf( stderr, "pytquic: cannot load image file %s\n", (*it).utf8() );
continue;
}
EmbedImage *e = new EmbedImage;
@ -275,7 +275,7 @@ void Uic::embed( TQTextStream& out, const char* project, const TQStringList& ima
out << indent << "factory = None\n";
out << "\n";
out << indent << "def qInitImages_" << cProject << "():\n";
out << indent << "def tqInitImages_" << cProject << "():\n";
++indent;
out << indent << "global factory\n";
out << "\n";
@ -288,7 +288,7 @@ void Uic::embed( TQTextStream& out, const char* project, const TQStringList& ima
out << "\n";
out << "\n";
out << indent << "def qCleanupImages_" << cProject << "():\n";
out << indent << "def tqCleanupImages_" << cProject << "():\n";
++indent;
out << indent << "global factory\n";
out << "\n";
@ -305,8 +305,8 @@ void Uic::embed( TQTextStream& out, const char* project, const TQStringList& ima
++indent;
out << indent << "def __init__(self):\n";
++indent;
out << indent << "self.cleanup = qCleanupImages_" << cProject << "\n";
out << indent << "qInitImages_" << cProject << "()\n";
out << indent << "self.cleanup = tqCleanupImages_" << cProject << "\n";
out << indent << "tqInitImages_" << cProject << "()\n";
--indent;
out << "\n";
out << indent << "def __del__(self):\n";

@ -238,12 +238,12 @@ void Uic::createFormImpl( const TQDomElement &e )
for ( i = 1; i < (int) nl.length(); i++ ) { // start at 1, 0 is the toplevel widget
TQString name = getClassName( nl.item(i).toElement() );
if ( name == "Spacer" ) {
globalIncludes += "qlayout.h";
globalIncludes += "qapplication.h";
globalIncludes += "tqlayout.h";
globalIncludes += "tqapplication.h";
continue;
}
if ( name.mid( 1 ) == "ListView" )
globalIncludes += "qheader.h";
globalIncludes += "tqheader.h";
else if ( name == "TQAxWidget" )
axwidgets += getObjectName(nl.item(i).toElement());
else if ( name == "TQDataBrowser" )
@ -257,14 +257,14 @@ void Uic::createFormImpl( const TQDomElement &e )
}
}
if (globalIncludes.findIndex("qtable.h") >= 0)
out << indent << "from PyTQt.qttable import TQTable" << endl;
if (globalIncludes.findIndex("tqtable.h") >= 0)
out << indent << "from PyTQt.tqttable import TQTable" << endl;
if (!axwidgets.empty())
out << indent << "from PyTQt.qtaxcontainer import TQAxWidget" << endl;
out << indent << "from PyTQt.tqtaxcontainer import TQAxWidget" << endl;
if (globalIncludes.findIndex("tqextscintilla.h") >= 0)
out << indent << "from PyTQt.qtext import TQextScintilla" << endl;
out << indent << "from PyTQt.tqtext import TQextScintilla" << endl;
registerDatabases( e );
dbConnections = unique( dbConnections );
@ -289,20 +289,20 @@ void Uic::createFormImpl( const TQDomElement &e )
sqlClasses += "TQSqlRecord";
}
if (globalIncludes.findIndex("qdatatable.h") >= 0)
if (globalIncludes.findIndex("tqdatatable.h") >= 0)
sqlClasses += "TQDataTable";
if (globalIncludes.findIndex("qtableview.h") >= 0)
if (globalIncludes.findIndex("tqtableview.h") >= 0)
sqlClasses += "TQTableView";
if (globalIncludes.findIndex("qdatabrowser.h") >= 0)
if (globalIncludes.findIndex("tqdatabrowser.h") >= 0)
sqlClasses += "TQDataBrowser";
if (globalIncludes.findIndex("qdataview.h") >= 0)
if (globalIncludes.findIndex("tqdataview.h") >= 0)
sqlClasses += "TQDataView";
if ( !sqlClasses.empty() ) {
out << indent << "from PyTQt.qtsql import";
out << indent << "from PyTQt.tqtsql import";
const char *sep = " ";
for ( it = sqlClasses.begin(); it != sqlClasses.end(); ++it ) {

@ -135,7 +135,7 @@ int main( int argc, char * argv[] )
if ( argc < 2 || error || (!fileName && !imagecollection ) ) {
fprintf( stderr, "PyTQt user interface compiler.\n" );
if ( error )
fprintf( stderr, "pyuic: %s\n", error );
fprintf( stderr, "pytquic: %s\n", error );
fprintf( stderr, "Usage: %s [options] [mode] <uifile>\n"
"\nGenerate implementation:\n"
@ -153,7 +153,7 @@ int main( int argc, char * argv[] )
"\t-tr func\tUse func() rather than TQApplication.translate() for i18n\n"
"\t-x\t\tGenerate extra code to test and display the class\n"
"\t-test\t\tGenerate extra code to test but not display the class\n"
"\t-version\tDisplay version of pyuic\n"
"\t-version\tDisplay version of pytquic\n"
"\t-help\t\tDisplay this information\n"
, argv[0], argv[0], argv[0], argv[0]);
return 1;
@ -165,7 +165,7 @@ int main( int argc, char * argv[] )
if ( !outputFile.isEmpty() ) {
fileOut.setName( outputFile );
if (!fileOut.open( IO_WriteOnly ) )
tqFatal( "pyuic: Could not open output file '%s'", outputFile.data() );
tqFatal( "pytquic: Could not open output file '%s'", outputFile.data() );
} else {
fileOut.open( IO_WriteOnly, stdout );
}
@ -182,17 +182,17 @@ int main( int argc, char * argv[] )
out.setEncoding( TQTextStream::UnicodeUTF8 );
TQFile file( fileName );
if ( !file.open( IO_ReadOnly ) )
tqFatal( "pyuic: Could not open file '%s' ", fileName );
tqFatal( "pytquic: Could not open file '%s' ", fileName );
TQDomDocument doc;
TQString errMsg;
int errLine;
if ( !doc.setContent( &file, &errMsg, &errLine ) )
tqFatal( TQString("pyuic: Failed to parse %s: ") + errMsg + TQString (" in line %d\n"), fileName, errLine );
tqFatal( TQString("pytquic: Failed to parse %s: ") + errMsg + TQString (" in line %d\n"), fileName, errLine );
TQDomElement e = doc.firstChild().toElement();
if ( e.hasAttribute("version") && e.attribute("version").toDouble() > 3.3 ) {
tqWarning( TQString("pyuic: File generated with too recent version of TQt Designer (%s vs. %s)"),
tqWarning( TQString("pytquic: File generated with too recent version of TQt Designer (%s vs. %s)"),
e.attribute("version").utf8(), TQT_VERSION_STR );
return 1;
}
@ -209,7 +209,7 @@ int main( int argc, char * argv[] )
if ( !subcl ) {
out << "# Form implementation generated from reading ui file '" << fileName << "'" << endl;
out << "#" << endl;
out << "# Created by: The PyTQt User Interface Compiler (pyuic) " << PYTQT_VERSION << endl;
out << "# Created by: The PyTQt User Interface Compiler (pytquic) " << PYTQT_VERSION << endl;
out << "#" << endl;
out << "# WARNING! All changes made in this file will be lost!" << endl;
out << endl;
@ -219,7 +219,7 @@ int main( int argc, char * argv[] )
if (testCode || execCode)
out << "import sys" << endl;
out << "from PyTQt.qt import *" << endl;
out << "from PyTQt.tqt import *" << endl;
Uic( fileName, outputFile, out, doc, subcl, trmacro, className, uicClass );

@ -43,7 +43,7 @@ TQString Uic::createObjectImpl( const TQDomElement &e, const TQString& parentCla
TQString parent( par );
if ( parent == "self" && isMainWindow ) {
if ( !createdCentralWidget )
out << indent << "self.setCentralWidget(TQWidget(self,\"qt_central_widget\"))" << endl;
out << indent << "self.setCentralWidget(TQWidget(self,\"tqt_central_widget\"))" << endl;
createdCentralWidget = TRUE;
parent = "self.centralWidget()";
}

@ -1,4 +1,4 @@
# This is the build file for pyuic for TQt v3 Professional Edition.
# This is the build file for pytquic for TQt v3 Professional Edition.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -19,6 +19,6 @@
# PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
target = pyuic
sources = main.cpp uic.cpp form.cpp object.cpp subclassing.cpp embed.cpp widgetdatabase.cpp domtool.cpp parser.cpp qdom.cpp qxml.cpp
target = pytquic
sources = main.cpp uic.cpp form.cpp object.cpp subclassing.cpp embed.cpp widgetdatabase.cpp domtool.cpp parser.cpp tqdom.cpp tqxml.cpp
headers = domtool.h globaldefs.h parser.h uic.h widgetdatabase.h widgetinterface.h

@ -3,16 +3,16 @@
# Copyright (c) 2002, 2003
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
#
# The project file for pyuic for TQt v3.
# The project file for pytquic for TQt v3.
TEMPLATE = app
CONFIG += qt console warn_on release @PYQT_RBPROF@
CONFIG += tqt console warn_on release @PYTQT_RBPROF@
INCLUDEPATH += @BLX_INCLUDEPATH@ $(TQTDIR)/src/3rdparty/zlib
DEFINES += UIC QT_INTERNAL_XML @BLX_DEFINES@
DEFINES += UIC TQT_INTERNAL_XML @BLX_DEFINES@
DESTDIR = @PYQT_BINDIR@
TARGET = pyuic
DESTDIR = @PYTQT_BINDIR@
TARGET = pytquic
HEADERS = uic.h \
widgetdatabase.h \
@ -30,7 +30,7 @@ SOURCES = main.cpp \
domtool.cpp \
parser.cpp
rbprof:exists($(TQTDIR)/src/qt_professional.pri) {
QT_SOURCE_TREE = $(TQTDIR)
include($(TQTDIR)/src/qt_professional.pri)
rbprof:exists($(TQTDIR)/src/tqt_professional.pri) {
TQT_SOURCE_TREE = $(TQTDIR)
include($(TQTDIR)/src/tqt_professional.pri)
}

@ -1,4 +1,4 @@
# This is the build file for pyuic for TQt v3.
# This is the build file for pytquic for TQt v3.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -19,6 +19,6 @@
# PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
target = pyuic
target = pytquic
sources = main.cpp uic.cpp form.cpp object.cpp subclassing.cpp embed.cpp widgetdatabase.cpp domtool.cpp parser.cpp
headers = domtool.h globaldefs.h parser.h uic.h widgetdatabase.h widgetinterface.h

@ -256,7 +256,7 @@ void WidgetDatabase::setupDataBase( int id )
#if !defined(TQT_NO_SQL)
r = new WidgetDatabaseRecord;
r->iconSet = "designer_datatable.png";
r->includeFile = "qdatatable.h";
r->includeFile = "tqdatatable.h";
r->name = "TQDataTable";
r->group = widgetGroup( "Database" );
r->toolTip = "Data Table";
@ -287,7 +287,7 @@ void WidgetDatabase::setupDataBase( int id )
r->name = "TQDateEdit";
r->group = widgetGroup( "Input" );
r->toolTip = "Date Edit";
r->includeFile = "qdatetimeedit.h";
r->includeFile = "tqdatetimeedit.h";
append( r );
@ -296,7 +296,7 @@ void WidgetDatabase::setupDataBase( int id )
r->name = "TQTimeEdit";
r->group = widgetGroup( "Input" );
r->toolTip = "Time Edit";
r->includeFile = "qdatetimeedit.h";
r->includeFile = "tqdatetimeedit.h";
append( r );
@ -305,7 +305,7 @@ void WidgetDatabase::setupDataBase( int id )
r->name = "TQDateTimeEdit";
r->group = widgetGroup( "Input" );
r->toolTip = "Date-Time Edit";
r->includeFile = "qdatetimeedit.h";
r->includeFile = "tqdatetimeedit.h";
append( r );
@ -399,7 +399,7 @@ void WidgetDatabase::setupDataBase( int id )
r->name = "Line";
r->group = widgetGroup( "Display" );
r->toolTip = "Line";
r->includeFile = "qframe.h";
r->includeFile = "tqframe.h";
r->whatsThis = "The Line widget provides horizontal and vertical lines.";
append( r );
@ -476,7 +476,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->name = "TQSplitter";
r->group = widgetGroup( "Temp" );
r->includeFile = "qsplitter.h";
r->includeFile = "tqsplitter.h";
r->isContainer = TRUE;
append( r );
@ -508,7 +508,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "";
r->name = "TQMainWindow";
r->includeFile = "qmainwindow.h";
r->includeFile = "tqmainwindow.h";
r->group = widgetGroup( "Temp" );
r->isContainer = TRUE;
@ -517,7 +517,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "";
r->name = "TQDesignerAction";
r->includeFile = "qaction.h";
r->includeFile = "tqaction.h";
r->group = widgetGroup( "Temp" );
r->isContainer = FALSE;
@ -526,7 +526,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "";
r->name = "TQDesignerActionGroup";
r->includeFile = "qaction.h";
r->includeFile = "tqaction.h";
r->group = widgetGroup( "Temp" );
r->isContainer = FALSE;
@ -535,7 +535,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "";
r->name = "TQScrollView";
r->includeFile = "qscrollview.h";
r->includeFile = "tqscrollview.h";
r->group = widgetGroup( "Temp" );
r->isContainer = TRUE;
@ -545,7 +545,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "";
r->name = "TQDataBrowser";
r->includeFile = "qdatabrowser.h";
r->includeFile = "tqdatabrowser.h";
r->group = widgetGroup( "Database" );
r->toolTip = "Data Browser";
r->iconSet = "designer_databrowser.png";
@ -556,7 +556,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "";
r->name = "TQDataView";
r->includeFile = "qdataview.h";
r->includeFile = "tqdataview.h";
r->group = widgetGroup( "Database" );
r->toolTip = "Data View";
r->iconSet = "designer_dataview.png";

@ -1,279 +0,0 @@
// This is the SIP interface definition for the qt module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qt 2
%Plugin PyTQt3
%Include versions.sip
%Include copying.sip
unsigned PYTQT_VERSION;
const char *PYTQT_VERSION_STR;
%ModuleCode
static unsigned PYTQT_VERSION = 0x031201;
static const char *PYTQT_VERSION_STR = "3.18.1";
%End
// Hook into the VendorID package if it is enabled.
%Feature VendorID
%If (VendorID)
%ModuleCode
#include <vendorid.h>
%End
%PreInitialisationCode
if (!vendorid_check())
{
PyErr_SetString(PyExc_RuntimeError, "PyTQt cannot be used with this Python interpreter");
return;
}
%End
%End
%DefaultMetatype qt.pyqtWrapperType
%DefaultSupertype qt.pyqtWrapper
// Include the interface definitions for each class.
// These contain enum and type definitions that need to be defined before they
// are used so they do not seem to be classes.
%Include qglobal.sip
%Include qnamespace.sip
%Include qwindowdefs.sip
%Include qpen.sip
%Include qpaintdevice.sip
%Include qpixmap.sip
%Include qbitmap.sip
%Include qsize.sip
%Include qsizepolicy.sip
%Include qaccel.sip
%Include qaction.sip
%Include qapplication.sip
%Include qassistantclient.sip
%Include qbrush.sip
%Include qbutton.sip
%Include qbuttongroup.sip
%Include qbytearray.sip
%Include qcdestyle.sip
%Include qcheckbox.sip
%Include qclipboard.sip
%Include qcolor.sip
%Include qcolordialog.sip
%Include qcolorgroup.sip
%Include qcombobox.sip
%Include qcommonstyle.sip
%Include qcstring.sip
%Include qcursor.sip
%Include qdatastream.sip
%Include qdatetime.sip
%Include qdatetimeedit.sip
%Include qdesktopwidget.sip
%Include qdial.sip
%Include qdialog.sip
%Include qdir.sip
%Include qdockarea.sip
%Include qdockwindow.sip
%Include qdragobject.sip
%Include qdrawutil.sip
%Include qdropsite.sip
%Include qerrormessage.sip
%Include qevent.sip
%Include qeventloop.sip
%Include qfile.sip
%Include qfiledialog.sip
%Include qfileinfo.sip
%Include qfont.sip
%Include qfontdatabase.sip
%Include qfontdialog.sip
%Include qfontinfo.sip
%Include qfontmetrics.sip
%Include qframe.sip
%Include qgrid.sip
%Include qgridview.sip
%Include qgroupbox.sip
%Include qhbox.sip
%Include qhbuttongroup.sip
%Include qheader.sip
%Include qhgroupbox.sip
%Include qiconset.sip
%Include qiconview.sip
%Include qimage.sip
%Include qinputdialog.sip
%Include qinterlacestyle.sip
%Include qiodevice.sip
%Include qkeysequence.sip
%Include qlabel.sip
%Include qlayout.sip
%Include qlcdnumber.sip
%Include qlibrary.sip
%Include qlineedit.sip
%Include qlistbox.sip
%Include qlistview.sip
%Include qlocale.sip
%Include qmainwindow.sip
%Include qmemarray.sip
%Include qmenubar.sip
%Include qmenudata.sip
%Include qmessagebox.sip
%Include qmetaobject.sip
%Include qmime.sip
%Include qmotifplusstyle.sip
%Include qmotifstyle.sip
%Include qmovie.sip
%Include qmutex.sip
%Include qmultilinedit.sip
%Include qnetworkprotocol.sip
%Include qobject.sip
%Include qobjectcleanuphandler.sip
%Include qobjectlist.sip
%Include qpaintdevicemetrics.sip
%Include qpainter.sip
%Include qpair.sip
%Include qpalette.sip
%Include qpicture.sip
%Include qpixmapcache.sip
%Include qplatinumstyle.sip
%Include qpoint.sip
%Include qpointarray.sip
%Include qpopupmenu.sip
%Include qprintdialog.sip
%Include qprinter.sip
%Include qprocess.sip
%Include qprogressbar.sip
%Include qprogressdialog.sip
%Include qptrlist.sip
%Include qpushbutton.sip
%Include qradiobutton.sip
%Include qrangecontrol.sip
%Include qrect.sip
%Include qregexp.sip
%Include qregion.sip
%Include qscrollbar.sip
%Include qscrollview.sip
%Include qsemaphore.sip
%Include qsessionmanager.sip
%Include qsettings.sip
%Include qsgistyle.sip
%Include qsignalmapper.sip
%Include qsimplerichtext.sip
%Include qsizegrip.sip
%Include qslider.sip
%Include qsocketnotifier.sip
%Include qsound.sip
%Include qspinbox.sip
%Include qsplashscreen.sip
%Include qsplitter.sip
%Include qstatusbar.sip
%Include qstring.sip
%Include qstringlist.sip
%Include qstrlist.sip
%Include qstyle.sip
%Include qstylefactory.sip
%Include qstylesheet.sip
%Include qsyntaxhighlighter.sip
%Include qtabbar.sip
%Include qtabdialog.sip
%Include qtabwidget.sip
%Include qtextbrowser.sip
%Include qtextcodec.sip
%Include qtextedit.sip
%Include qtextstream.sip
%Include qtextview.sip
%Include qthread.sip
%Include qtimer.sip
%Include qtoolbar.sip
%Include qtoolbox.sip
%Include qtoolbutton.sip
%Include qtooltip.sip
%Include qtranslator.sip
%Include qurl.sip
%Include qurlinfo.sip
%Include qurloperator.sip
%Include quuid.sip
%Include qvalidator.sip
%Include qvaluelist.sip
%Include qvariant.sip
%Include qvbox.sip
%Include qvbuttongroup.sip
%Include qvgroupbox.sip
%Include qwaitcondition.sip
%Include qwhatsthis.sip
%Include qwidget.sip
%Include qwidgetlist.sip
%Include qwidgetstack.sip
%Include qwindowsstyle.sip
%Include qwindowsxpstyle.sip
%Include qwizard.sip
%Include qwmatrix.sip
%Include qworkspace.sip
// The build file templates.
%Makefile qt.pro.in
# The project file for the qt module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
#
# This file is part of PyTQt.
#
# This copy of PyTQt is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the Free
# Software Foundation; either version 2, or (at your option) any later
# version.
#
# PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
# details.
#
# You should have received a copy of the GNU General Public License along with
# PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYQT_QASSISTANTCLIENT_LIB@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B
HEADERS = $H
%End

@ -1,51 +0,0 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip

@ -1,51 +0,0 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip

@ -1,51 +0,0 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip

@ -1,51 +0,0 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip

@ -1,51 +0,0 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip

@ -1,51 +0,0 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip

@ -1,51 +0,0 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip

@ -42,10 +42,10 @@ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -419,37 +419,37 @@ enum TQtMsgType {
};
SIP_PYCALLABLE qInstallMsgHandler(SIP_PYCALLABLE /AllowNone/);
SIP_PYCALLABLE tqInstallMsgHandler(SIP_PYCALLABLE /AllowNone/);
%MethodCode
void (*old)(TQtMsgType, const char *);
// Treat None as the default handler.
old = qInstallMsgHandler((a0 != Py_None) ? pyqtMsgHandler : 0);
old = tqInstallMsgHandler((a0 != Py_None) ? pytqtMsgHandler : 0);
// If we recognise the old handler, then return it. Otherwise return
// the default handler. This doesn't exactly mimic the TQt behaviour
// but it is probably close enough for the way it will be used.
sipRes = (old == pyqtMsgHandler) ? pyqtPyMsgHandler : Py_None;
sipRes = (old == pytqtMsgHandler) ? pytqtPyMsgHandler : Py_None;
Py_INCREF(sipRes);
// Save the new Python handler.
Py_XDECREF(pyqtPyMsgHandler);
pyqtPyMsgHandler = a0;
Py_INCREF(pyqtPyMsgHandler);
Py_XDECREF(pytqtPyMsgHandler);
pytqtPyMsgHandler = a0;
Py_INCREF(pytqtPyMsgHandler);
%End
%ModuleCode
// The user supplied Python handler.
static PyObject *pyqtPyMsgHandler = 0;
static PyObject *pytqtPyMsgHandler = 0;
// The C++ wrapper around the Python handler.
static void pyqtMsgHandler(TQtMsgType type, const char *msg)
static void pytqtMsgHandler(TQtMsgType type, const char *msg)
{
PyObject *res;
SIP_BLOCK_THREADS
res = sipCallMethod(0, pyqtPyMsgHandler, "Es", type, sipEnum_TQtMsgType, msg);
res = sipCallMethod(0, pytqtPyMsgHandler, "Es", type, sipEnum_TQtMsgType, msg);
Py_XDECREF(res);

@ -158,7 +158,7 @@ public:
const char **str;
if ((str = PyTQt_qt_ListToArray(a0)) == NULL)
if ((str = PyTQt_tqt_ListToArray(a0)) == NULL)
sipIsErr = 1;
else
{
@ -409,14 +409,14 @@ public:
%ModuleHeaderCode
const char **PyTQt_qt_ListToArray(PyObject *lst);
const char **PyTQt_tqt_ListToArray(PyObject *lst);
%End
%ModuleCode
// Convert a list of strings to an array of strings on the heap. Also used by
// TQPixmap.
const char **PyTQt_qt_ListToArray(PyObject *lst)
const char **PyTQt_tqt_ListToArray(PyObject *lst)
{
SIP_SSIZE_T nstr;
const char **str, **sp;

@ -108,7 +108,7 @@ public:
typedef uint WState;
// WidgetState isn't part of the public API but is used in code
// generated by uic/pyuic, so we implement the minimum required.
// generated by uic/pytquic, so we implement the minimum required.
enum WidgetState {
WState_Polished
};

@ -304,7 +304,7 @@ public:
#else
{NULL, NULL, -1, -1},
#endif
#if defined(PYQT_STYLE_WINDOWSXP)
#if defined(PYTQT_STYLE_WINDOWSXP)
{sipName_TQWindowsXPStyle, &sipClass_TQWindowsXPStyle, -1, -1},
#else
{NULL, NULL, -1, -1},
@ -350,7 +350,7 @@ public:
%MethodCode
if (tqApp)
{
const char *source = PyTQt_qt_encode(&a0, TQApplication::DefaultCodec);
const char *source = PyTQt_tqt_encode(&a0, TQApplication::DefaultCodec);
if (source)
{
@ -369,7 +369,7 @@ public:
if (source)
{
sipRes = new TQString(QString::fromUtf8(source));
sipRes = new TQString(TQString::fromUtf8(source));
Py_DECREF(a0);
}
else
@ -383,7 +383,7 @@ public:
%MethodCode
if (tqApp)
{
const char *source = PyTQt_qt_encode(&a0, TQApplication::DefaultCodec);
const char *source = PyTQt_tqt_encode(&a0, TQApplication::DefaultCodec);
if (source)
{
@ -525,27 +525,27 @@ public:
void installEventFilter(const TQObject *);
void removeEventFilter(const TQObject *);
static SIP_PYOBJECT connect(SIP_QOBJECT,SIP_SIGNAL,SIP_QOBJECT,SIP_SLOT);
static SIP_PYOBJECT connect(SIP_TQOBJECT,SIP_SIGNAL,SIP_TQOBJECT,SIP_SLOT);
%MethodCode
sipRes = sipConnectRx(a0,a1,a2,a3,0);
%End
static SIP_PYOBJECT connect(SIP_QOBJECT,SIP_SIGNAL,SIP_PYCALLABLE);
static SIP_PYOBJECT connect(SIP_TQOBJECT,SIP_SIGNAL,SIP_PYCALLABLE);
%MethodCode
sipRes = sipConnectRx(a0,a1,a2,0,0);
%End
SIP_PYOBJECT connect(SIP_QOBJECT,SIP_SIGNAL,SIP_SLOT) const;
SIP_PYOBJECT connect(SIP_TQOBJECT,SIP_SIGNAL,SIP_SLOT) const;
%MethodCode
sipRes = sipConnectRx(a0,a1,sipSelf,a2,0);
%End
static SIP_PYOBJECT disconnect(SIP_QOBJECT,SIP_SIGNAL,SIP_QOBJECT,SIP_SLOT);
static SIP_PYOBJECT disconnect(SIP_TQOBJECT,SIP_SIGNAL,SIP_TQOBJECT,SIP_SLOT);
%MethodCode
sipRes = sipDisconnectRx(a0,a1,a2,a3);
%End
static SIP_PYOBJECT disconnect(SIP_QOBJECT,SIP_SIGNAL,SIP_PYCALLABLE);
static SIP_PYOBJECT disconnect(SIP_TQOBJECT,SIP_SIGNAL,SIP_PYCALLABLE);
%MethodCode
sipRes = sipDisconnectRx(a0,a1,a2,0);
%End
@ -558,7 +558,7 @@ public:
void emit(SIP_SIGNAL,SIP_PYTUPLE);
%MethodCode
if (pyqt3EmitSignal(sipSelf, a0, a1) < 0)
if (pytqtEmitSignal(sipSelf, a0, a1) < 0)
sipIsErr = 1;
%End
@ -579,7 +579,7 @@ public:
// method.
SIP_PYOBJECT sender();
%MethodCode
sipRes = pyqt3GetSender();
sipRes = pytqt3GetSender();
%End
protected:
@ -606,11 +606,11 @@ SIP_PYOBJECT QT_TRANSLATE_NOOP(SIP_PYOBJECT,SIP_PYOBJECT);
%End
SIP_PYOBJECT SLOT(const char * /Encoding="ASCII"/) /TypeHint="QT_SLOT"/;
SIP_PYOBJECT SLOT(const char * /Encoding="ASCII"/) /TypeHint="TQT_SLOT"/;
%MethodCode
if (!a0)
{
PyErr_Format(PyExc_TypeError,"qt.SLOT() slot name cannot be None");
PyErr_Format(PyExc_TypeError,"tqt.SLOT() slot name cannot be None");
sipIsErr = 1;
}
else
@ -631,11 +631,11 @@ SIP_PYOBJECT SLOT(const char * /Encoding="ASCII"/) /TypeHint="QT_SLOT"/;
%End
SIP_PYOBJECT SIGNAL(const char * /Encoding="ASCII"/) /TypeHint="QT_SIGNAL"/;
SIP_PYOBJECT SIGNAL(const char * /Encoding="ASCII"/) /TypeHint="TQT_SIGNAL"/;
%MethodCode
if (!a0)
{
PyErr_Format(PyExc_TypeError,"qt.SIGNAL() signal cannot be None");
PyErr_Format(PyExc_TypeError,"tqt.SIGNAL() signal cannot be None");
sipIsErr = 1;
}
else
@ -660,7 +660,7 @@ SIP_PYOBJECT PYSIGNAL(const char * /Encoding="ASCII"/);
%MethodCode
if (!a0)
{
PyErr_Format(PyExc_TypeError,"qt.PYSIGNAL() signal cannot be None");
PyErr_Format(PyExc_TypeError,"tqt.PYSIGNAL() signal cannot be None");
sipIsErr = 1;
}
else
@ -683,8 +683,8 @@ SIP_PYOBJECT PYSIGNAL(const char * /Encoding="ASCII"/);
%ModuleHeaderCode
int pyqt3EmitSignal(PyObject *self, const char *sig, PyObject *sigargs);
PyObject *pyqt3GetSender();
int pytqtEmitSignal(PyObject *self, const char *sig, PyObject *sigargs);
PyObject *pytqt3GetSender();
%End
@ -731,9 +731,9 @@ extern "C" {
// The meta-type for PyTQt classes. It is just a marker type so that we can
// safely cast to get access to PyTQt3-specific data structures.
PyTypeObject pyqtWrapperType_Type = {
PyTypeObject pytqtWrapperType_Type = {
PyVarObject_HEAD_INIT(NULL, 0)
"qt.pyqtWrapperType", /* tp_name */
"tqt.pytqtWrapperType", /* tp_name */
sizeof (sipWrapperType), /* tp_basicsize */
0, /* tp_itemsize */
0, /* tp_dealloc */
@ -802,52 +802,52 @@ PyTypeObject pyqtWrapperType_Type = {
/*
* An entry in a linked list of slots.
*/
typedef struct _pyqt3SlotList {
typedef struct _pytqt3SlotList {
/* The receiver. */
sipSlot rx;
/* Next in the list. */
struct _pyqt3SlotList *next;
} pyqt3SlotList;
struct _pytqt3SlotList *next;
} pytqt3SlotList;
/*
* A Python signal.
*/
typedef struct _pyqt3PySig {
typedef struct _pytqt3PySig {
/* The name of the signal. */
char *name;
/* The list of receivers. */
pyqt3SlotList *rxlist;
pytqt3SlotList *rxlist;
/* Next in the list. */
struct _pyqt3PySig *next;
} pyqt3PySig;
struct _pytqt3PySig *next;
} pytqt3PySig;
/*
* The C++ wrapper object used by PyTQt3.
*/
typedef struct _pyqtWrapper {
typedef struct _pytqtWrapper {
/* The super-type. */
sipWrapper super;
/* The list of Python signals. */
pyqt3PySig *pySigList;
} pyqtWrapper;
pytqt3PySig *pySigList;
} pytqtWrapper;
/*
* Clear any slots connected to any Python signals.
*/
static void clear_py_signals_slots(pyqtWrapper *pw)
static void clear_py_signals_slots(pytqtWrapper *pw)
{
pyqt3PySig *ps;
pytqt3PySig *ps;
for (ps = pw->pySigList; ps != NULL; ps = ps->next)
{
pyqt3SlotList *psrx;
pytqt3SlotList *psrx;
for (psrx = ps->rxlist; psrx != NULL; psrx = psrx->next)
sipClearAnySlotReference(&psrx->rx);
@ -858,9 +858,9 @@ static void clear_py_signals_slots(pyqtWrapper *pw)
/*
* Find the given Python signal.
*/
static pyqt3PySig *find_py_signal(pyqtWrapper *pw, const char *sig)
static pytqt3PySig *find_py_signal(pytqtWrapper *pw, const char *sig)
{
pyqt3PySig *ps;
pytqt3PySig *ps;
for (ps = pw->pySigList; ps != NULL; ps = ps->next)
if (sipTQtSameSignalSlotName(ps->name, sig))
@ -873,7 +873,7 @@ static pyqt3PySig *find_py_signal(pyqtWrapper *pw, const char *sig)
/*
* Free an slot list entry.
*/
static void free_slot_list(pyqt3SlotList *sl)
static void free_slot_list(pytqt3SlotList *sl)
{
sipFreeSipslot(&sl->rx);
sipFree(sl);
@ -883,7 +883,7 @@ static void free_slot_list(pyqt3SlotList *sl)
/*
* The instance clear slot.
*/
static int pyqtWrapper_clear(pyqtWrapper *self)
static int pytqtWrapper_clear(pytqtWrapper *self)
{
clear_py_signals_slots(self);
@ -894,14 +894,14 @@ static int pyqtWrapper_clear(pyqtWrapper *self)
/*
* The instance dealloc slot.
*/
static void pyqtWrapper_dealloc(pyqtWrapper *self)
static void pytqtWrapper_dealloc(pytqtWrapper *self)
{
clear_py_signals_slots(self);
while (self->pySigList != NULL)
{
pyqt3PySig *ps;
pyqt3SlotList *psrx;
pytqt3PySig *ps;
pytqt3SlotList *psrx;
/* Take this one out of the list. */
ps = self->pySigList;
@ -924,17 +924,17 @@ static void pyqtWrapper_dealloc(pyqtWrapper *self)
/*
* The instance traverse slot.
*/
static int pyqtWrapper_traverse(pyqtWrapper *self, visitproc visit, void *arg)
static int pytqtWrapper_traverse(pytqtWrapper *self, visitproc visit, void *arg)
{
int vret;
pyqt3PySig *ps;
pytqt3PySig *ps;
if ((vret = sipWrapper_Type->tp_traverse((PyObject *)self, visit, arg)) != 0)
return vret;
for (ps = self->pySigList; ps != NULL; ps = ps->next)
{
pyqt3SlotList *psrx;
pytqt3SlotList *psrx;
for (psrx = ps->rxlist; psrx != NULL; psrx = psrx->next)
if ((vret = sipVisitSlot(&psrx->rx, visit, arg)) != 0)
@ -945,16 +945,16 @@ static int pyqtWrapper_traverse(pyqtWrapper *self, visitproc visit, void *arg)
}
static sipWrapperType pyqtWrapper_Type = {
static sipWrapperType pytqtWrapper_Type = {
#if !defined(STACKLESS)
{
#endif
{
PyVarObject_HEAD_INIT(&pyqtWrapperType_Type, 0)
"qt.pyqtWrapper", /* tp_name */
sizeof (pyqtWrapper), /* tp_basicsize */
PyVarObject_HEAD_INIT(&pytqtWrapperType_Type, 0)
"tqt.pytqtWrapper", /* tp_name */
sizeof (pytqtWrapper), /* tp_basicsize */
0, /* tp_itemsize */
(destructor)pyqtWrapper_dealloc, /* tp_dealloc */
(destructor)pytqtWrapper_dealloc, /* tp_dealloc */
#if PY_VERSION_HEX >= 0x03080000
0, /* tp_vectorcall_offset */
#else
@ -979,8 +979,8 @@ static sipWrapperType pyqtWrapper_Type = {
0, /* tp_as_buffer */
Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE | Py_TPFLAGS_HAVE_GC, /* tp_flags */
0, /* tp_doc */
(traverseproc)pyqtWrapper_traverse, /* tp_traverse */
(inquiry)pyqtWrapper_clear, /* tp_clear */
(traverseproc)pytqtWrapper_traverse, /* tp_traverse */
(inquiry)pytqtWrapper_clear, /* tp_clear */
0, /* tp_richcompare */
0, /* tp_weaklistoffset */
0, /* tp_iter */
@ -1027,7 +1027,7 @@ static sipWrapperType pyqtWrapper_Type = {
// This enumerates the different dynamic signal argument types.
enum pyqt3SigArgType {
enum pytqt3SigArgType {
unknown_sat,
char_sat,
uchar_sat,
@ -1061,10 +1061,10 @@ enum pyqt3SigArgType {
// This defines a single dynamic signal argument type.
struct pyqt3SigArg
struct pytqt3SigArg
{
// The type.
pyqt3SigArgType atype;
pytqt3SigArgType atype;
union {
// The Python type for classes.
@ -1080,29 +1080,29 @@ struct pyqt3SigArg
// A parsed signal signature.
struct pyqt3Signature {
struct pytqt3Signature {
// The number of arguments.
int sg_nrargs;
// The parsed arguments (heap).
pyqt3SigArg *sg_args;
pytqt3SigArg *sg_args;
// The unparsed signature (heap).
char *sg_signature;
// The next in the list.
pyqt3Signature *sg_next;
pytqt3Signature *sg_next;
};
// A connection to a universal slot.
struct pyqt3SlotConnection
struct pytqt3SlotConnection
{
// The transmitter TQObject.
void *sc_transmitter;
// The parsed signature.
const pyqt3Signature *sc_signature;
const pytqt3Signature *sc_signature;
// The slot.
sipSlot sc_slot;
@ -1118,7 +1118,7 @@ struct pyqt3SlotConnection
class UniversalSlot : public TQObject
{
public:
UniversalSlot(TQObject *qtx, pyqt3SlotConnection *conn, const char **member);
UniversalSlot(TQObject *tqtx, pytqt3SlotConnection *conn, const char **member);
~UniversalSlot();
virtual TQMetaObject *metaObject() const
@ -1133,7 +1133,7 @@ public:
static UniversalSlot *unislots;
UniversalSlot *nextus, *prevus;
pyqt3SlotConnection conn;
pytqt3SlotConnection conn;
private:
static TQMetaObject *metaObj;
@ -1142,14 +1142,14 @@ private:
// Create a universal slot. Note that this will leak if there is no signal
// transmitter (ie. no parent) - TQTimer.singleShot() for example.
UniversalSlot::UniversalSlot(TQObject *qtx, pyqt3SlotConnection *connection, const char **member) : TQObject()
UniversalSlot::UniversalSlot(TQObject *tqtx, pytqt3SlotConnection *connection, const char **member) : TQObject()
{
// Save the connection.
conn = *connection;
// Detect when the transmitter is destroyed.
if (qtx)
connect(qtx, SIGNAL(destroyed(TQObject *)), SLOT(deleteLater()));
if (tqtx)
connect(tqtx, SIGNAL(destroyed(TQObject *)), SLOT(deleteLater()));
// Return the slot to connect to.
*member = SLOT(unislot());
@ -1229,7 +1229,7 @@ bool UniversalSlot::tqt_invoke(int id, TQUObject *qargs)
return TQObject::tqt_invoke(id, qargs);
bool ok = TRUE;
const pyqt3Signature *psig = conn.sc_signature;
const pytqt3Signature *psig = conn.sc_signature;
TQVariant *qv;
// Save in case it is asked for later.
@ -1380,8 +1380,8 @@ bool UniversalSlot::tqt_invoke(int id, TQUObject *qargs)
}
static pyqt3Signature *parseSignature(const char *sig);
static void parseType(const char *type, pyqt3SigArg *arg);
static pytqt3Signature *parseSignature(const char *sig);
static void parseType(const char *type, pytqt3SigArg *arg);
// Factory function to create a universal slot instance. Returns a pointer to
@ -1389,7 +1389,7 @@ static void parseType(const char *type, pyqt3SigArg *arg);
static void *sipTQtCreateUniversalSlot(sipWrapper *tx, const char *sig,
PyObject *rxObj, const char *slot, const char **member, int)
{
pyqt3SlotConnection conn;
pytqt3SlotConnection conn;
/* Initialise the connection. */
if (tx && sipGetAddress(&tx->super) == NULL)
@ -1412,7 +1412,7 @@ static void *sipTQtCreateUniversalSlot(sipWrapper *tx, const char *sig,
return 0;
}
TQObject *qtx = 0;
TQObject *tqtx = 0;
// See if the transmitter is a TQObject in which case we will connect
// to it's destroyed signal so that the universal slot can be destroyed
@ -1421,17 +1421,17 @@ static void *sipTQtCreateUniversalSlot(sipWrapper *tx, const char *sig,
// expected because TQWidget destroys its children before emitting the
// destroyed signal.)
if (tx && PyObject_TypeCheck((PyObject *)tx, (PyTypeObject *)sipClass_TQObject))
qtx = reinterpret_cast<TQObject *>(conn.sc_transmitter);
tqtx = reinterpret_cast<TQObject *>(conn.sc_transmitter);
return new UniversalSlot(qtx, &conn, member);
return new UniversalSlot(tqtx, &conn, member);
}
// Parse the signal arguments for a connection.
static pyqt3Signature *parseSignature(const char *sig)
static pytqt3Signature *parseSignature(const char *sig)
{
static pyqt3Signature *psig_list = NULL;
pyqt3Signature *psig;
static pytqt3Signature *psig_list = NULL;
pytqt3Signature *psig;
const char *sp, *ep;
// First see if it has already been parsed. Note that both sides of a
@ -1444,7 +1444,7 @@ static pyqt3Signature *parseSignature(const char *sig)
return psig;
// Create a new one including space for the copy of the signature.
if ((psig = (pyqt3Signature *)sipMalloc(sizeof (pyqt3Signature) + strlen(sig) + 1)) == NULL)
if ((psig = (pytqt3Signature *)sipMalloc(sizeof (pytqt3Signature) + strlen(sig) + 1)) == NULL)
return NULL;
psig->sg_signature = (char *)&psig[1];
@ -1519,7 +1519,7 @@ static pyqt3Signature *parseSignature(const char *sig)
// Allocate the space.
psig->sg_nrargs = nrcommas + 1;
if ((psig->sg_args = (pyqt3SigArg *)sipMalloc(sizeof (pyqt3SigArg) * psig->sg_nrargs)) == NULL)
if ((psig->sg_args = (pytqt3SigArg *)sipMalloc(sizeof (pytqt3SigArg) * psig->sg_nrargs)) == NULL)
{
sipFree(psig);
return NULL;
@ -1547,12 +1547,12 @@ static pyqt3Signature *parseSignature(const char *sig)
// Parse a single type.
static void parseType(const char *type, pyqt3SigArg *arg)
static void parseType(const char *type, pytqt3SigArg *arg)
{
size_t btlen = 0;
int unsup, isref = FALSE, indir = 0;
const char *ep;
pyqt3SigArgType sat = unknown_sat;
pytqt3SigArgType sat = unknown_sat;
// Find the start of the significant part of the type.
if (strncmp(type, "const ", 6) == 0)
@ -1783,7 +1783,7 @@ static void *sipTQtFindSlot(void *tx, const char *sig, PyObject *rxObj,
{
for (UniversalSlot *us = UniversalSlot::unislots; us; us = us->nextus)
{
pyqt3SlotConnection *conn = &us->conn;
pytqt3SlotConnection *conn = &us->conn;
if (conn->sc_transmitter != tx)
continue;
@ -1857,7 +1857,7 @@ static sipSlot *sipTQtFindSipslot(void *tx, void **context)
while (us)
{
pyqt3SlotConnection *this_conn = &us->conn;
pytqt3SlotConnection *this_conn = &us->conn;
us = us->nextus;
@ -1878,14 +1878,14 @@ static sipSlot *sipTQtFindSipslot(void *tx, void **context)
static int sipTQtConnectPySignal(PyObject *txObj, const char *sig,
PyObject *rxObj, const char *slot)
{
pyqt3PySig *ps;
pyqt3SlotList *psrx;
pyqtWrapper *pw = (pyqtWrapper *)txObj;
pytqt3PySig *ps;
pytqt3SlotList *psrx;
pytqtWrapper *pw = (pytqtWrapper *)txObj;
/* Create a new one if necessary. */
if ((ps = find_py_signal(pw, sig)) == NULL)
{
if ((ps = (pyqt3PySig *)sipMalloc(sizeof (pyqt3PySig))) == NULL)
if ((ps = (pytqt3PySig *)sipMalloc(sizeof (pytqt3PySig))) == NULL)
return -1;
if ((ps->name = (char *)sipMalloc(strlen(sig) + 1)) == NULL)
@ -1903,7 +1903,7 @@ static int sipTQtConnectPySignal(PyObject *txObj, const char *sig,
}
/* Create the new receiver. */
if ((psrx = (pyqt3SlotList *)sipMalloc(sizeof (pyqt3SlotList))) == NULL)
if ((psrx = (pytqt3SlotList *)sipMalloc(sizeof (pytqt3SlotList))) == NULL)
return -1;
if (sipSaveSlot(&psrx->rx, rxObj, slot) < 0)
@ -1923,15 +1923,15 @@ static int sipTQtConnectPySignal(PyObject *txObj, const char *sig,
static void sipTQtDisconnectPySignal(PyObject *txObj, const char *sig,
PyObject *rxObj, const char *slot)
{
pyqt3PySig *ps;
pytqt3PySig *ps;
if ((ps = find_py_signal((pyqtWrapper *)txObj, sig)) != NULL)
if ((ps = find_py_signal((pytqtWrapper *)txObj, sig)) != NULL)
{
pyqt3SlotList **psrxp;
pytqt3SlotList **psrxp;
for (psrxp = &ps->rxlist; *psrxp != NULL; psrxp = &(*psrxp)->next)
{
pyqt3SlotList *psrx = *psrxp;
pytqt3SlotList *psrx = *psrxp;
if (sipSameSlot(&psrx->rx, rxObj, slot))
{
@ -1947,12 +1947,12 @@ static void sipTQtDisconnectPySignal(PyObject *txObj, const char *sig,
// Emit a signal for the sip module.
static int sipTQtEmitSignal(PyObject *self, const char *sig, PyObject *sigargs)
{
return pyqt3EmitSignal(self, sig, sigargs);
return pytqtEmitSignal(self, sig, sigargs);
}
// Emit a Python or TQt signal.
int pyqt3EmitSignal(PyObject *self, const char *sig, PyObject *sigargs)
int pytqtEmitSignal(PyObject *self, const char *sig, PyObject *sigargs)
{
// Don't do anything if signals are blocked. TQt signals would be blocked
// anyway, but this blocks Python signals as well.
@ -1967,10 +1967,10 @@ int pyqt3EmitSignal(PyObject *self, const char *sig, PyObject *sigargs)
// See if it is a TQt signal.
if (*sig == '2')
{
pyqt3QtSignal *tab;
pytqtTQtSignal *tab;
// Search the table.
for (tab = ((pyqt3ClassTypeDef *)((sipWrapperType *)(self->ob_type))->type)->qt3_emit; tab->st_name != NULL; ++tab)
for (tab = ((pytqtClassTypeDef *)((sipWrapperType *)(self->ob_type))->type)->tqt_emit; tab->st_name != NULL; ++tab)
{
const char *sp, *tp;
bool found;
@ -1998,12 +1998,12 @@ int pyqt3EmitSignal(PyObject *self, const char *sig, PyObject *sigargs)
return -1;
}
pyqt3PySig *ps = find_py_signal((pyqtWrapper *)self, sig);
pytqt3PySig *ps = find_py_signal((pytqtWrapper *)self, sig);
if (ps)
{
int rc = 0;
pyqt3SlotList *rxlist = ps->rxlist;
pytqt3SlotList *rxlist = ps->rxlist;
// Forget the last TQt sender and remember this one.
UniversalSlot::lastSender = 0;
@ -2012,7 +2012,7 @@ int pyqt3EmitSignal(PyObject *self, const char *sig, PyObject *sigargs)
// Apply the arguments to each slot method.
while (rxlist && rc >= 0)
{
pyqt3SlotList *next;
pytqt3SlotList *next;
PyObject *res;
// We get the next in the list before calling the slot in case the
@ -2041,7 +2041,7 @@ int pyqt3EmitSignal(PyObject *self, const char *sig, PyObject *sigargs)
// Return the most recent signal sender.
PyObject *pyqt3GetSender()
PyObject *pytqt3GetSender()
{
PyObject *sender;
@ -2065,22 +2065,22 @@ PyObject *pyqt3GetSender()
%InitialisationCode
// Initialise the meta-type.
pyqtWrapperType_Type.tp_base = sipWrapperType_Type;
pytqtWrapperType_Type.tp_base = sipWrapperType_Type;
if (PyType_Ready(&pyqtWrapperType_Type) < 0)
Py_FatalError("qt: Failed to initialise pyqtWrapperType type");
if (PyType_Ready(&pytqtWrapperType_Type) < 0)
Py_FatalError("tqt: Failed to initialise pytqtWrapperType type");
// Register the meta-type.
if (sipRegisterPyType((PyTypeObject *)&pyqtWrapperType_Type) < 0)
Py_FatalError("qt: Failed to register pyqtWrapperType type");
if (sipRegisterPyType((PyTypeObject *)&pytqtWrapperType_Type) < 0)
Py_FatalError("tqt: Failed to register pytqtWrapperType type");
// Initialise the super-type.
pyqtWrapper_Type.super.ht_type.tp_base = sipWrapper_Type;
pytqtWrapper_Type.super.ht_type.tp_base = sipWrapper_Type;
if (PyType_Ready((PyTypeObject *)&pyqtWrapper_Type) < 0)
Py_FatalError("qt: Failed to initialise pyqtWrapper type");
if (PyType_Ready((PyTypeObject *)&pytqtWrapper_Type) < 0)
Py_FatalError("tqt: Failed to initialise pytqtWrapper type");
// Register the super-type.
if (sipRegisterPyType((PyTypeObject *)&pyqtWrapper_Type) < 0)
Py_FatalError("qt: Failed to register pyqtWrapper type");
if (sipRegisterPyType((PyTypeObject *)&pytqtWrapper_Type) < 0)
Py_FatalError("tqt: Failed to register pytqtWrapper type");
%End

@ -80,27 +80,27 @@ return type of a function or the type of an argument, a Python list of
return 1;
}
TQObjectList *qol = new TQObjectList;
TQObjectList *tqol = new TQObjectList;
for (int i = 0; i < PyList_GET_SIZE(sipPy); ++i)
{
TQObject *qobj;
TQObject *tqobj;
// We apply the transfer to the list itself, not the elements.
// Note that any temporary element will never be destroyed.
// There is nothing that can be done about this.
qobj = reinterpret_cast<TQObject *>(sipConvertToInstance(PyList_GET_ITEM(sipPy,i),sipClass_TQObject,0,0,0,sipIsErr));
tqobj = reinterpret_cast<TQObject *>(sipConvertToInstance(PyList_GET_ITEM(sipPy,i),sipClass_TQObject,0,0,0,sipIsErr));
if (*sipIsErr)
{
delete qol;
delete tqol;
return 0;
}
qol -> append(qobj);
tqol -> append(tqobj);
}
*sipCppPtr = qol;
*sipCppPtr = tqol;
return sipGetState(sipTransferObj);
%End

@ -93,7 +93,7 @@ public:
const char **str;
if ((str = PyTQt_qt_ListToArray(a0)) == NULL)
if ((str = PyTQt_tqt_ListToArray(a0)) == NULL)
sipIsErr = 1;
else
{

@ -634,12 +634,12 @@ public:
SIP_PYOBJECT __unicode__();
%MethodCode
sipRes = PyTQt_qt_PyObject_FromTQString(sipCpp);
sipRes = PyTQt_tqt_PyObject_FromTQString(sipCpp);
%End
SIP_PYOBJECT __str__();
%MethodCode
sipRes = PyTQt_qt_PyObject_FromTQString(sipCpp);
sipRes = PyTQt_tqt_PyObject_FromTQString(sipCpp);
%End
%ConvertToTypeCode
@ -651,7 +651,7 @@ public:
PyUnicode_Check(sipPy) ||
sipCanConvertToInstance(sipPy,sipClass_TQString,SIP_NO_CONVERTORS));
*sipCppPtr = PyTQt_qt_PyObject_AsTQString(sipPy);
*sipCppPtr = PyTQt_tqt_PyObject_AsTQString(sipPy);
if (*sipCppPtr)
return sipGetState(sipTransferObj);
@ -743,12 +743,12 @@ bool operator>=(const TQString &,const TQString &);
%ModuleHeaderCode
extern PyObject *PyTQt_qt_PyObject_FromTQString(const TQString *qstr);
extern PyObject *PyTQt_tqt_PyObject_FromTQString(const TQString *tqstr);
%End
%ModuleCode
// Convert a QString to a Python Unicode object.
PyObject *PyTQt_qt_PyObject_FromTQString(const TQString *qstr)
// Convert a TQString to a Python Unicode object.
PyObject *PyTQt_tqt_PyObject_FromTQString(const TQString *tqstr)
{
PyObject *obj;
@ -758,12 +758,12 @@ PyObject *PyTQt_qt_PyObject_FromTQString(const TQString *qstr)
// common case. Note that we can't use PyUnicode_FromKindAndData() because
// it doesn't handle surrogates in UCS2 strings.
int qt_len = qstr->length();
int tqt_len = tqstr->length();
Py_UCS4 maxchar = 0x007f;
for (int qt_i = 0; qt_i < qt_len && maxchar < 0xffff; ++qt_i)
for (int tqt_i = 0; tqt_i < tqt_len && maxchar < 0xffff; ++tqt_i)
{
Py_UCS4 uch = qstr->at(qt_i).unicode();
Py_UCS4 uch = tqstr->at(tqt_i).unicode();
if (uch > 0x00ff)
{
@ -776,34 +776,34 @@ PyObject *PyTQt_qt_PyObject_FromTQString(const TQString *qstr)
}
// Create the correctly sized object.
if ((obj = PyUnicode_New(qt_len, maxchar)) == NULL)
if ((obj = PyUnicode_New(tqt_len, maxchar)) == NULL)
return NULL;
int kind = PyUnicode_KIND(obj);
void *data = PyUnicode_DATA(obj);
for (int qt_i = 0; qt_i < qt_len; ++qt_i)
for (int tqt_i = 0; tqt_i < tqt_len; ++tqt_i)
{
Py_UCS4 uch = qstr->at(qt_i).unicode();
PyUnicode_WRITE(kind, data, qt_i, uch);
Py_UCS4 uch = tqstr->at(tqt_i).unicode();
PyUnicode_WRITE(kind, data, tqt_i, uch);
}
#elif defined(Py_UNICODE_WIDE)
// Note that this doesn't handle code points greater than 0xffff. It could
// but it's only an issue for old versions of Qt.
// but it's only an issue for old versions of TQt.
if ((obj = PyUnicode_FromUnicode(NULL, qstr->length())) == NULL)
if ((obj = PyUnicode_FromUnicode(NULL, tqstr->length())) == NULL)
return NULL;
Py_UNICODE *pyu = PyUnicode_AS_UNICODE(obj);
for (unsigned int i = 0; i < qstr->length(); ++i)
*pyu++ = (qstr->at(i)).unicode();
for (unsigned int i = 0; i < tqstr->length(); ++i)
*pyu++ = (tqstr->at(i)).unicode();
#else
if ((obj = PyUnicode_FromUnicode(NULL, qstr->length())) == NULL)
if ((obj = PyUnicode_FromUnicode(NULL, tqstr->length())) == NULL)
return NULL;
memcpy(PyUnicode_AS_UNICODE(obj), qstr->ucs2(),
qstr->length() * sizeof (Py_UNICODE));
memcpy(PyUnicode_AS_UNICODE(obj), tqstr->ucs2(),
tqstr->length() * sizeof (Py_UNICODE));
#endif
return obj;
@ -812,12 +812,12 @@ PyObject *PyTQt_qt_PyObject_FromTQString(const TQString *qstr)
%ModuleHeaderCode
extern TQString *PyTQt_qt_PyObject_AsTQString(PyObject *obj);
extern TQString *PyTQt_tqt_PyObject_AsTQString(PyObject *obj);
%End
%ModuleCode
// Convert a Python Unicode object to a QString.
TQString *PyTQt_qt_PyObject_AsTQString(PyObject *obj)
// Convert a Python Unicode object to a TQString.
TQString *PyTQt_tqt_PyObject_AsTQString(PyObject *obj)
{
if (PyUnicode_Check(obj))
{
@ -835,33 +835,33 @@ TQString *PyTQt_qt_PyObject_AsTQString(PyObject *obj)
case PyUnicode_4BYTE_KIND:
// Note that this doesn't handle code points greater than 0xffff. It
// could but it's only an issue for old versions of Qt.
// could but it's only an issue for old versions of TQt.
TQString *qstr = new TQString;
TQString *tqstr = new TQString;
Py_UCS4 *ucode = PyUnicode_4BYTE_DATA(obj);
for (SIP_SSIZE_T i = 0; i < len; ++i)
qstr->append(TQChar((uint)ucode[i]));
tqstr->append(TQChar((uint)ucode[i]));
return qstr;
return tqstr;
}
return NULL;
#else
TQString *qstr = new TQString;
TQString *tqstr = new TQString;
# ifdef Py_UNICODE_WIDE
Py_UNICODE *ucode = PyUnicode_AS_UNICODE(obj);
SIP_SSIZE_T len = PyUnicode_GET_SIZE(obj);
for (SIP_SSIZE_T i = 0; i < len; ++i)
qstr->append(TQChar((uint)ucode[i]));
tqstr->append(TQChar((uint)ucode[i]));
# else
qstr->setUnicodeCodes((ushort *)PyUnicode_AS_UNICODE(obj),PyUnicode_GET_SIZE(obj));
tqstr->setUnicodeCodes((ushort *)PyUnicode_AS_UNICODE(obj),PyUnicode_GET_SIZE(obj));
# endif
return qstr;
return tqstr;
#endif
}
else if (PyBytes_Check(obj))
@ -875,14 +875,14 @@ TQString *PyTQt_qt_PyObject_AsTQString(PyObject *obj)
%ModuleHeaderCode
extern const char *PyTQt_qt_encode(PyObject **s, TQApplication::Encoding encoding);
extern const char *PyTQt_tqt_encode(PyObject **s, TQApplication::Encoding encoding);
%End
%ModuleCode
// Convert a Python unicode/string/bytes object to a character string encoded
// according to the given encoding. Update the object with a new reference to
// the object that owns the data.
const char *PyTQt_qt_encode(PyObject **s, TQApplication::Encoding encoding)
const char *PyTQt_tqt_encode(PyObject **s, TQApplication::Encoding encoding)
{
PyObject *obj = *s;
const char *es = 0;
@ -900,12 +900,12 @@ const char *PyTQt_qt_encode(PyObject **s, TQApplication::Encoding encoding)
if (codec)
{
// Use the Qt codec to get to a byte string, and then to a
// Use the TQt codec to get to a byte string, and then to a
// Python object.
TQString *qstr = PyTQt_qt_PyObject_AsTQString(obj);
TQString qs = *qstr;
TQByteArray ba = codec->fromUnicode(qs);
delete qstr;
TQString *tqstr = PyTQt_tqt_PyObject_AsTQString(obj);
TQString tqs = *tqstr;
TQByteArray ba = codec->fromUnicode(tqs);
delete tqstr;
obj = PyBytes_FromStringAndSize(ba.data(), ba.size());
}

@ -76,7 +76,7 @@ is used instead.
if (sipIsErr == NULL)
return PyList_Check(sipPy);
TQStrList *qsl = new TQStrList;
TQStrList *tqsl = new TQStrList;
for (int i = 0; i < PyList_GET_SIZE(sipPy); ++i)
{
@ -90,14 +90,14 @@ is used instead.
else if ((s = (char *)sipBytes_AsString(object)) == NULL)
{
*sipIsErr = 1;
delete qsl;
delete tqsl;
return 0;
}
qsl -> append(s);
tqsl -> append(s);
}
*sipCppPtr = qsl;
*sipCppPtr = tqsl;
return sipGetState(sipTransferObj);
%End

@ -0,0 +1,279 @@
// This is the SIP interface definition for the tqt module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.tqt 2
%Plugin PyTQt3
%Include versions.sip
%Include copying.sip
unsigned PYTQT_VERSION;
const char *PYTQT_VERSION_STR;
%ModuleCode
static unsigned PYTQT_VERSION = 0x031201;
static const char *PYTQT_VERSION_STR = "3.18.1";
%End
// Hook into the VendorID package if it is enabled.
%Feature VendorID
%If (VendorID)
%ModuleCode
#include <vendorid.h>
%End
%PreInitialisationCode
if (!vendorid_check())
{
PyErr_SetString(PyExc_RuntimeError, "PyTQt cannot be used with this Python interpreter");
return;
}
%End
%End
%DefaultMetatype tqt.pytqtWrapperType
%DefaultSupertype tqt.pytqtWrapper
// Include the interface definitions for each class.
// These contain enum and type definitions that need to be defined before they
// are used so they do not seem to be classes.
%Include tqglobal.sip
%Include tqnamespace.sip
%Include tqwindowdefs.sip
%Include tqpen.sip
%Include tqpaintdevice.sip
%Include tqpixmap.sip
%Include tqbitmap.sip
%Include tqsize.sip
%Include tqsizepolicy.sip
%Include tqaccel.sip
%Include tqaction.sip
%Include tqapplication.sip
%Include tqassistantclient.sip
%Include tqbrush.sip
%Include tqbutton.sip
%Include tqbuttongroup.sip
%Include tqbytearray.sip
%Include tqcdestyle.sip
%Include tqcheckbox.sip
%Include tqclipboard.sip
%Include tqcolor.sip
%Include tqcolordialog.sip
%Include tqcolorgroup.sip
%Include tqcombobox.sip
%Include tqcommonstyle.sip
%Include tqcstring.sip
%Include tqcursor.sip
%Include tqdatastream.sip
%Include tqdatetime.sip
%Include tqdatetimeedit.sip
%Include tqdesktopwidget.sip
%Include tqdial.sip
%Include tqdialog.sip
%Include tqdir.sip
%Include tqdockarea.sip
%Include tqdockwindow.sip
%Include tqdragobject.sip
%Include tqdrawutil.sip
%Include tqdropsite.sip
%Include tqerrormessage.sip
%Include tqevent.sip
%Include tqeventloop.sip
%Include tqfile.sip
%Include tqfiledialog.sip
%Include tqfileinfo.sip
%Include tqfont.sip
%Include tqfontdatabase.sip
%Include tqfontdialog.sip
%Include tqfontinfo.sip
%Include tqfontmetrics.sip
%Include tqframe.sip
%Include tqgrid.sip
%Include tqgridview.sip
%Include tqgroupbox.sip
%Include tqhbox.sip
%Include tqhbuttongroup.sip
%Include tqheader.sip
%Include tqhgroupbox.sip
%Include tqiconset.sip
%Include tqiconview.sip
%Include tqimage.sip
%Include tqinputdialog.sip
%Include tqinterlacestyle.sip
%Include tqiodevice.sip
%Include tqkeysequence.sip
%Include tqlabel.sip
%Include tqlayout.sip
%Include tqlcdnumber.sip
%Include tqlibrary.sip
%Include tqlineedit.sip
%Include tqlistbox.sip
%Include tqlistview.sip
%Include tqlocale.sip
%Include tqmainwindow.sip
%Include tqmemarray.sip
%Include tqmenubar.sip
%Include tqmenudata.sip
%Include tqmessagebox.sip
%Include tqmetaobject.sip
%Include tqmime.sip
%Include tqmotifplusstyle.sip
%Include tqmotifstyle.sip
%Include tqmovie.sip
%Include tqmutex.sip
%Include tqmultilinedit.sip
%Include tqnetworkprotocol.sip
%Include tqobject.sip
%Include tqobjectcleanuphandler.sip
%Include tqobjectlist.sip
%Include tqpaintdevicemetrics.sip
%Include tqpainter.sip
%Include tqpair.sip
%Include tqpalette.sip
%Include tqpicture.sip
%Include tqpixmapcache.sip
%Include tqplatinumstyle.sip
%Include tqpoint.sip
%Include tqpointarray.sip
%Include tqpopupmenu.sip
%Include tqprintdialog.sip
%Include tqprinter.sip
%Include tqprocess.sip
%Include tqprogressbar.sip
%Include tqprogressdialog.sip
%Include tqptrlist.sip
%Include tqpushbutton.sip
%Include tqradiobutton.sip
%Include tqrangecontrol.sip
%Include tqrect.sip
%Include tqregexp.sip
%Include tqregion.sip
%Include tqscrollbar.sip
%Include tqscrollview.sip
%Include tqsemaphore.sip
%Include tqsessionmanager.sip
%Include tqsettings.sip
%Include tqsgistyle.sip
%Include tqsignalmapper.sip
%Include tqsimplerichtext.sip
%Include tqsizegrip.sip
%Include tqslider.sip
%Include tqsocketnotifier.sip
%Include tqsound.sip
%Include tqspinbox.sip
%Include tqsplashscreen.sip
%Include tqsplitter.sip
%Include tqstatusbar.sip
%Include tqstring.sip
%Include tqstringlist.sip
%Include tqstrlist.sip
%Include tqstyle.sip
%Include tqstylefactory.sip
%Include tqstylesheet.sip
%Include tqsyntaxhighlighter.sip
%Include tqtabbar.sip
%Include tqtabdialog.sip
%Include tqtabwidget.sip
%Include tqtextbrowser.sip
%Include tqtextcodec.sip
%Include tqtextedit.sip
%Include tqtextstream.sip
%Include tqtextview.sip
%Include tqthread.sip
%Include tqtimer.sip
%Include tqtoolbar.sip
%Include tqtoolbox.sip
%Include tqtoolbutton.sip
%Include tqtooltip.sip
%Include tqtranslator.sip
%Include tqurl.sip
%Include tqurlinfo.sip
%Include tqurloperator.sip
%Include tquuid.sip
%Include tqvalidator.sip
%Include tqvaluelist.sip
%Include tqvariant.sip
%Include tqvbox.sip
%Include tqvbuttongroup.sip
%Include tqvgroupbox.sip
%Include tqwaitcondition.sip
%Include tqwhatsthis.sip
%Include tqwidget.sip
%Include tqwidgetlist.sip
%Include tqwidgetstack.sip
%Include tqwindowsstyle.sip
%Include tqwindowsxpstyle.sip
%Include tqwizard.sip
%Include tqwmatrix.sip
%Include tqworkspace.sip
// The build file templates.
%Makefile tqt.pro.in
# The project file for the tqt module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
#
# This file is part of PyTQt.
#
# This copy of PyTQt is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the Free
# Software Foundation; either version 2, or (at your option) any later
# version.
#
# PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
# details.
#
# You should have received a copy of the GNU General Public License along with
# PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYTQT_QASSISTANTCLIENT_LIB@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B
HEADERS = $H
%End

@ -34,10 +34,10 @@ All constant values defined by TQt have equivalent constants defined to Python.
%End
%OptionalInclude qwindowdefs_mac.sip
%OptionalInclude qwindowdefs_qws.sip
%OptionalInclude qwindowdefs_win.sip
%OptionalInclude qwindowdefs_x11.sip
%OptionalInclude tqwindowdefs_mac.sip
%OptionalInclude tqwindowdefs_qws.sip
%OptionalInclude tqwindowdefs_win.sip
%OptionalInclude tqwindowdefs_x11.sip
typedef TQ_INT32 TQCOORD;

@ -42,10 +42,10 @@ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -62,7 +62,7 @@ Not implemented.
<Para>
This is a utility method provided by PyTQt to make it easier to use
Mark Hammond's <Literal>win32com</Literal> module to manipulate objects
created by the <Literal>qtaxcontainer</Literal> module.
created by the <Literal>tqtaxcontainer</Literal> module.
</Para>
<Para>
The <Literal>RegisterActiveObject()</Literal> COM function is called to

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qtaxcontainer module of PyTQt.
// This is the SIP interface definition for the tqtaxcontainer module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -20,13 +20,13 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qtaxcontainer 1
%Module PyTQt.tqtaxcontainer 1
%Import qt/qtmod.sip
%Import tqt/tqtmod.sip
%Include copying.sip
%Include qaxbase.sip
%Include qaxobject.sip
%Include qaxwidget.sip
%Include tqaxbase.sip
%Include tqaxobject.sip
%Include tqaxwidget.sip

@ -42,10 +42,10 @@ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qttable module of PyTQt.
// This is the SIP interface definition for the tqtcanvas module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -20,20 +20,20 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qttable 1
%Module PyTQt.tqtcanvas 1
%Import qt/qtmod.sip
%Import tqt/tqtmod.sip
%Include copying.sip
%Include qtable.sip
%Include tqcanvas.sip
// The build file template.
%Makefile qttable.pro.in
# The project file for the qttable module.
%Makefile tqtcanvas.pro.in
# The project file for the tqtcanvas module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -57,11 +57,11 @@
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYQT_WARN@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYQT_QT_MODULE@ @BLX_LIBS@
LIBS += @PYTQT_TQT_MODULE@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B

@ -42,10 +42,10 @@ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pyqt-internal.sip
%OptionalInclude pyqt-gpl.sip
%OptionalInclude pyqt-commercial.sip
%OptionalInclude pyqt-edu.sip
%OptionalInclude pyqt-eval.sip
%OptionalInclude pyqt-nc.sip
%OptionalInclude pyqt-tkc.sip
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qtext module of PyTQt.
// This is the SIP interface definition for the tqtext module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -20,9 +20,9 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qtext 4
%Module PyTQt.tqtext 4
%Import qt/qtmod.sip
%Import tqt/tqtmod.sip
%Include copying.sip
@ -37,40 +37,40 @@ const char *TQSCINTILLA_VERSION_STR;
const char *TQSCINTILLA_BUILD;
%Include qextscintillaapis.sip
%Include qextscintillabase.sip
%Include qextscintilla.sip
%Include qextscintillacommand.sip
%Include qextscintillacommandset.sip
%Include qextscintilladocument.sip
%Include qextscintillalexer.sip
%Include qextscintillalexerbash.sip
%Include qextscintillalexerbatch.sip
%Include qextscintillalexercpp.sip
%Include qextscintillalexercsharp.sip
%Include qextscintillalexercss.sip
%Include qextscintillalexerdiff.sip
%Include qextscintillalexerhtml.sip
%Include qextscintillalexeridl.sip
%Include qextscintillalexerjava.sip
%Include qextscintillalexerjavascript.sip
%Include qextscintillalexerlua.sip
%Include qextscintillalexermakefile.sip
%Include qextscintillalexerperl.sip
%Include qextscintillalexerpov.sip
%Include qextscintillalexerproperties.sip
%Include qextscintillalexerpython.sip
%Include qextscintillalexerruby.sip
%Include qextscintillalexersql.sip
%Include qextscintillalexertex.sip
%Include qextscintillamacro.sip
%Include qextscintillaprinter.sip
%Include tqextscintillaapis.sip
%Include tqextscintillabase.sip
%Include tqextscintilla.sip
%Include tqextscintillacommand.sip
%Include tqextscintillacommandset.sip
%Include tqextscintilladocument.sip
%Include tqextscintillalexer.sip
%Include tqextscintillalexerbash.sip
%Include tqextscintillalexerbatch.sip
%Include tqextscintillalexercpp.sip
%Include tqextscintillalexercsharp.sip
%Include tqextscintillalexercss.sip
%Include tqextscintillalexerdiff.sip
%Include tqextscintillalexerhtml.sip
%Include tqextscintillalexeridl.sip
%Include tqextscintillalexerjava.sip
%Include tqextscintillalexerjavascript.sip
%Include tqextscintillalexerlua.sip
%Include tqextscintillalexermakefile.sip
%Include tqextscintillalexerperl.sip
%Include tqextscintillalexerpov.sip
%Include tqextscintillalexerproperties.sip
%Include tqextscintillalexerpython.sip
%Include tqextscintillalexerruby.sip
%Include tqextscintillalexersql.sip
%Include tqextscintillalexertex.sip
%Include tqextscintillamacro.sip
%Include tqextscintillaprinter.sip
// The build file template.
%Makefile qtext.pro.in
# The project file for the qtext module.
%Makefile tqtext.pro.in
# The project file for the tqtext module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -94,11 +94,11 @@ const char *TQSCINTILLA_BUILD;
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@ @PYQT_QSCINTILLA_INC@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@ @PYTQT_TQSCINTILLA_INC@
DEFINES = @BLX_DEFINES@ TQEXTSCINTILLA_DLL
LIBS += @PYQT_QT_MODULE@ @PYQT_QSCINTILLA_LIB@ @BLX_LIBS@
LIBS += @PYTQT_TQT_MODULE@ @PYTQT_TQSCINTILLA_LIB@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B

@ -0,0 +1,51 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qtgl module of PyTQt.
// This is the SIP interface definition for the tqtgl module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -20,21 +20,21 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qtgl 1
%Module PyTQt.tqtgl 1
%Import qt/qtmod.sip
%Import tqt/tqtmod.sip
%Include copying.sip
%Include qgl.sip
%Include qglcolormap.sip
%Include tqgl.sip
%Include tqglcolormap.sip
// The build file template.
%Makefile qtgl.pro.in
# The project file for the qtgl module.
%Makefile tqtgl.pro.in
# The project file for the tqtgl module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -58,11 +58,11 @@
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ opengl @PYQT_WARN@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ opengl @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYQT_QT_MODULE@ @BLX_LIBS@
LIBS += @PYTQT_TQT_MODULE@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B

@ -0,0 +1,51 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qtnetwork module of PyTQt.
// This is the SIP interface definition for the tqtnetwork module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -20,28 +20,28 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qtnetwork 1
%Module PyTQt.tqtnetwork 1
%Import qt/qtmod.sip
%Import tqt/tqtmod.sip
%Include copying.sip
%Include qdns.sip
%Include qhostaddress.sip
%Include qftp.sip
%Include qhttp.sip
%Include qlocalfs.sip
%Include qnetwork.sip
%Include qserversocket.sip
%Include qsocket.sip
%Include qsocketdevice.sip
%Include tqdns.sip
%Include tqhostaddress.sip
%Include tqftp.sip
%Include tqhttp.sip
%Include tqlocalfs.sip
%Include tqnetwork.sip
%Include tqserversocket.sip
%Include tqsocket.sip
%Include tqsocketdevice.sip
// The build file template.
%Makefile qtnetwork.pro.in
# The project file for the qtnetwork module.
%Makefile tqtnetwork.pro.in
# The project file for the tqtnetwork module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -65,11 +65,11 @@
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYQT_WARN@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYQT_QT_MODULE@ @BLX_LIBS@
LIBS += @PYTQT_TQT_MODULE@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B

@ -0,0 +1,51 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -29,7 +29,7 @@
class TQCopEnvelope : TQDataStream
{
%TypeHeaderCode
#include <tqpe/qcopenvelope_qws.h>
#include <tqpe/tqcopenvelope_qws.h>
%End
public:

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qtpe module of PyTQt.
// This is the SIP interface definition for the tqtpe module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -20,9 +20,9 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qtpe 1
%Module PyTQt.tqtpe 1
%Import qt/qtmod.sip
%Import tqt/tqtmod.sip
%Include copying.sip
@ -38,26 +38,26 @@
const char *TQPE_VERSION;
%Include qpeapplication.sip
%Include qpeapplnk.sip
%Include qpeconfig.sip
%Include qpefilemanager.sip
%Include qpefileselector.sip
%Include qpefontdatabase.sip
%Include qpeglobal.sip
%Include qpemenubar.sip
%Include qpemenubutton.sip
%Include qpeqcopenvelope.sip
%Include qpeqdawg.sip
%Include qperesource.sip
%Include qpetimestring.sip
%Include qpetoolbar.sip
%Include tqpeapplication.sip
%Include tqpeapplnk.sip
%Include tqpeconfig.sip
%Include tqpefilemanager.sip
%Include tqpefileselector.sip
%Include tqpefontdatabase.sip
%Include tqpeglobal.sip
%Include tqpemenubar.sip
%Include tqpemenubutton.sip
%Include tqpeqcopenvelope.sip
%Include tqpeqdawg.sip
%Include tqperesource.sip
%Include tqpetimestring.sip
%Include tqpetoolbar.sip
// The build file template.
%Makefile qtpe.pro.in
# The project file for the qtpe module.
%Makefile tqtpe.pro.in
# The project file for the tqtpe module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -81,11 +81,11 @@ const char *TQPE_VERSION;
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYQT_WARN@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYQT_QT_MODULE@ @BLX_LIBS@ -lqpe
LIBS += @PYTQT_TQT_MODULE@ @BLX_LIBS@ -lqpe
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B

@ -0,0 +1,51 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qtsql module of PyTQt.
// This is the SIP interface definition for the tqtsql module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -20,38 +20,38 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qtsql 1
%Module PyTQt.tqtsql 1
%Import qt/qtmod.sip
%Import qttable/qttablemod.sip
%Import tqt/tqtmod.sip
%Import tqttable/tqttablemod.sip
%Include copying.sip
%Include qdatabrowser.sip
%Include qdatatable.sip
%Include qdataview.sip
%Include qeditorfactory.sip
%Include qsql.sip
%Include qsqlcursor.sip
%Include qsqldatabase.sip
%Include qsqldriver.sip
%Include qsqleditorfactory.sip
%Include qsqlerror.sip
%Include qsqlfield.sip
%Include qsqlform.sip
%Include qsqlindex.sip
%Include qsqlpropertymap.sip
%Include qsqlquery.sip
%Include qsqlrecord.sip
%Include qsqlresult.sip
%Include qsqlselectcursor.sip
%Include tqdatabrowser.sip
%Include tqdatatable.sip
%Include tqdataview.sip
%Include tqeditorfactory.sip
%Include tqsql.sip
%Include tqsqlcursor.sip
%Include tqsqldatabase.sip
%Include tqsqldriver.sip
%Include tqsqleditorfactory.sip
%Include tqsqlerror.sip
%Include tqsqlfield.sip
%Include tqsqlform.sip
%Include tqsqlindex.sip
%Include tqsqlpropertymap.sip
%Include tqsqlquery.sip
%Include tqsqlrecord.sip
%Include tqsqlresult.sip
%Include tqsqlselectcursor.sip
// The build file template.
%Makefile qtsql.pro.in
# The project file for the qtsql module.
%Makefile tqtsql.pro.in
# The project file for the tqtsql module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -75,11 +75,11 @@
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYQT_WARN@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYQT_QTTABLE_MODULE@ @BLX_LIBS@
LIBS += @PYTQT_TQTTABLE_MODULE@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B

@ -0,0 +1,51 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qtcanvas module of PyTQt.
// This is the SIP interface definition for the tqttable module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -20,20 +20,20 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qtcanvas 1
%Module PyTQt.tqttable 1
%Import qt/qtmod.sip
%Import tqt/tqtmod.sip
%Include copying.sip
%Include qcanvas.sip
%Include tqtable.sip
// The build file template.
%Makefile qtcanvas.pro.in
# The project file for the qtcanvas module.
%Makefile tqttable.pro.in
# The project file for the tqttable module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -57,11 +57,11 @@
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYQT_WARN@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYQT_QT_MODULE@ @BLX_LIBS@
LIBS += @PYTQT_TQT_MODULE@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B

@ -0,0 +1,51 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qtui module of PyTQt. Thanks to
// This is the SIP interface definition for the tqtui module of PyTQt. Thanks to
// Hans-Peter Jansen for the original work.
//
// Copyright (c) 2007
@ -21,20 +21,20 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qtui 1
%Module PyTQt.tqtui 1
%Import qt/qtmod.sip
%Import tqt/tqtmod.sip
%Include copying.sip
%Include qwidgetfactory.sip
%Include tqwidgetfactory.sip
// The build file template.
%Makefile qtui.pro.in
# The project file for the qtui module.
%Makefile tqtui.pro.in
# The project file for the tqtui module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -58,11 +58,11 @@
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYQT_WARN@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYQT_QT_MODULE@ @PYQT_QUI_LIB@ @BLX_LIBS@
LIBS += @PYTQT_TQT_MODULE@ @PYTQT_TQUI_LIB@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B

@ -0,0 +1,51 @@
// This is the SIP file defining the PyTQt license.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
//
// This file is part of PyTQt.
//
// This copy of PyTQt is free software; you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2, or (at your option) any later
// version.
//
// PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
// FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
// details.
//
// You should have received a copy of the GNU General Public License along with
// PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Copying
Copyright (c) 2007
Riverbank Computing Limited <info@riverbankcomputing.co.uk>
This file is part of PyTQt.
This copy of PyTQt is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2, or (at your option) any later
version.
PyTQt is supplied in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
You should have received a copy of the GNU General Public License along with
PyTQt; see the file LICENSE. If not, write to the Free Software Foundation,
Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%End
%OptionalInclude pytqt-internal.sip
%OptionalInclude pytqt-gpl.sip
%OptionalInclude pytqt-commercial.sip
%OptionalInclude pytqt-edu.sip
%OptionalInclude pytqt-eval.sip
%OptionalInclude pytqt-nc.sip
%OptionalInclude pytqt-tkc.sip

@ -1,4 +1,4 @@
// This is the SIP interface definition for the qtxml module of PyTQt.
// This is the SIP interface definition for the tqtxml module of PyTQt.
//
// Copyright (c) 2007
// Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -20,30 +20,30 @@
// Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
%Module PyTQt.qtxml 0
%Module PyTQt.tqtxml 0
%Import qt/qtmod.sip
%Import tqt/tqtmod.sip
%Include copying.sip
%Include qdom.sip
%Include tqdom.sip
// This is only needed on Windows to make sure that the DLL containing the C++
// code of the main qt module is loaded before we import our own C++ code which
// code of the main tqt module is loaded before we import our own C++ code which
// has been linked against it. All other modules inherit from a class in the
// qt module which sorts it out, but this module doesn't so we add a dummy. It
// tqt module which sorts it out, but this module doesn't so we add a dummy. It
// is ignored by SIP v4.x and later.
%PrePythonCode
from PyTQt.qt import TQObject
from PyTQt.tqt import TQObject
%End
// The build file template.
%Makefile qtxml.pro.in
# The project file for the qtxml module.
%Makefile tqtxml.pro.in
# The project file for the tqtxml module.
#
# Copyright (c) 2007
# Riverbank Computing Limited <info@riverbankcomputing.co.uk>
@ -67,11 +67,11 @@ from PyTQt.qt import TQObject
TEMPLATE = lib
TARGET = @BLX_TARGET_LIB@
DESTDIR = @PYQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYQT_WARN@
DESTDIR = @PYTQT_MODDIR@
CONFIG += @BLX_CONFIG_LIB@ @PYTQT_WARN@
INCLUDEPATH = @BLX_INCLUDEPATH@
DEFINES = @BLX_DEFINES@
LIBS += @PYQT_QT_MODULE@ @BLX_LIBS@
LIBS += @PYTQT_TQT_MODULE@ @BLX_LIBS@
macx:QMAKE_LFLAGS += -framework Python
SOURCES = $B
Loading…
Cancel
Save