summaryrefslogtreecommitdiffstats
path: root/kig
diff options
context:
space:
mode:
Diffstat (limited to 'kig')
-rw-r--r--kig/CMakeLists.txt9
-rw-r--r--kig/DESIGN2
-rw-r--r--kig/Makefile.am2
-rw-r--r--kig/filters/cabri-filter.cpp6
-rw-r--r--kig/filters/drgeo-filter-chooser.cpp6
-rw-r--r--kig/filters/drgeo-filter-chooser.h2
-rw-r--r--kig/filters/drgeo-filter.cpp4
-rw-r--r--kig/filters/exporter.cpp2
-rw-r--r--kig/filters/imageexporteroptions.cpp4
-rw-r--r--kig/filters/imageexporteroptions.h2
-rw-r--r--kig/filters/kgeo-filter.cpp10
-rw-r--r--kig/filters/kgeo-filter.h6
-rw-r--r--kig/filters/latexexporter.cpp8
-rw-r--r--kig/filters/native-filter.cpp4
-rw-r--r--kig/filters/svgexporter.cpp2
-rw-r--r--kig/kig/Makefile.am2
-rw-r--r--kig/kig/kig.cpp28
-rw-r--r--kig/kig/kig.h2
-rw-r--r--kig/kig/kig_commands.h2
-rw-r--r--kig/kig/kig_part.cpp60
-rw-r--r--kig/kig/kig_part.h2
-rw-r--r--kig/kig/kig_view.cpp48
-rw-r--r--kig/kig/kig_view.h4
-rw-r--r--kig/kig/main.cpp6
-rw-r--r--kig/misc/boost_intrusive_pointer.h1
-rw-r--r--kig/misc/guiaction.h2
-rw-r--r--kig/misc/kigfiledialog.h2
-rw-r--r--kig/misc/kiginputdialog.cpp18
-rw-r--r--kig/misc/kiginputdialog.h2
-rw-r--r--kig/misc/kigpainter.cpp20
-rw-r--r--kig/misc/kigpainter.h8
-rw-r--r--kig/misc/object_constructor.cpp16
-rw-r--r--kig/misc/special_constructors.cpp14
-rw-r--r--kig/modes/construct_mode.cpp10
-rw-r--r--kig/modes/dragrectmode.cpp2
-rw-r--r--kig/modes/edittype.cpp2
-rw-r--r--kig/modes/edittype.h2
-rw-r--r--kig/modes/edittypebase.ui4
-rw-r--r--kig/modes/label.cpp2
-rw-r--r--kig/modes/linkslabel.cpp10
-rw-r--r--kig/modes/linkslabel.h2
-rw-r--r--kig/modes/macro.cpp14
-rw-r--r--kig/modes/macrowizard.cpp10
-rw-r--r--kig/modes/macrowizard.h2
-rw-r--r--kig/modes/moving.cpp6
-rw-r--r--kig/modes/normal.cpp10
-rw-r--r--kig/modes/popup.cpp58
-rw-r--r--kig/modes/popup.h4
-rw-r--r--kig/modes/textlabelwizard.cpp14
-rw-r--r--kig/modes/textlabelwizard.h2
-rw-r--r--kig/modes/typesdialog.cpp8
-rw-r--r--kig/modes/typesdialog.h2
-rw-r--r--kig/modes/typesdialogbase.ui4
-rw-r--r--kig/objects/object_calcer.cpp14
-rw-r--r--kig/objects/object_drawer.cpp24
-rw-r--r--kig/objects/object_drawer.h10
-rw-r--r--kig/objects/object_factory.cpp2
-rw-r--r--kig/objects/text_type.cpp2
-rwxr-xr-xkig/pykig/pykig.py120
-rw-r--r--kig/scripting/newscriptwizard.cpp14
-rw-r--r--kig/scripting/newscriptwizard.h2
-rw-r--r--kig/scripting/python_scripter.cpp4
-rw-r--r--kig/scripting/script_mode.cpp8
-rw-r--r--kig/tdefile/Makefile.am4
-rw-r--r--kig/tdefile/tdefile_drgeo.h2
-rw-r--r--kig/tdefile/tdefile_kig.cpp2
-rw-r--r--kig/tdefile/tdefile_kig.h2
67 files changed, 342 insertions, 342 deletions
diff --git a/kig/CMakeLists.txt b/kig/CMakeLists.txt
index 40d738a2..23a5511d 100644
--- a/kig/CMakeLists.txt
+++ b/kig/CMakeLists.txt
@@ -9,9 +9,13 @@ add_subdirectory( tdefile )
add_subdirectory( data )
add_subdirectory( icons )
add_subdirectory( pykig )
-add_subdirectory( scripting )
add_subdirectory( examples )
+if( WITH_KIG_PYTHON_SCRIPTING )
+ add_subdirectory( scripting )
+ set( KIGSCRIPTING_LIBRARIES kigscripting-static )
+endif( )
+
include_directories(
${CMAKE_BINARY_DIR}
${CMAKE_CURRENT_BINARY_DIR}
@@ -25,7 +29,6 @@ link_directories(
${TDE_LIB_DIR}
)
-
##### libkigpart (kpart)
configure_file( ${TDE_CMAKE_TEMPLATES}/tde_dummy_cpp.cmake dummy.cpp COPYONLY )
@@ -43,7 +46,7 @@ tde_add_kpart( libkigpart AUTOMOC
kigobjects-static
kigfilters-static
kigmodes-static
- kigscripting-static
+ ${KIGSCRIPTING_LIBRARIES}
EMBED
kigpart-static
diff --git a/kig/DESIGN b/kig/DESIGN
index 0de0c986..69837b23 100644
--- a/kig/DESIGN
+++ b/kig/DESIGN
@@ -150,7 +150,7 @@ way. I will explain all the classes involved.
First of all, there is the TextImp class. It is an ObjectImp (
cf. supra ), and thus represents a piece of text that can be drawn on
-the document. It contains a QString ( the text to be shown ), a
+the document. It contains a TQString ( the text to be shown ), a
coordinate ( the location to draw it ), and a boolean saying whether a
frame should be drawn around it. As with all ObjectImp's, it does not
contain any code for calculating it, or how it behaves on user input.
diff --git a/kig/Makefile.am b/kig/Makefile.am
index eea9593b..3f6bebd1 100644
--- a/kig/Makefile.am
+++ b/kig/Makefile.am
@@ -25,7 +25,7 @@ SUBDIRS = \
kde_module_LTLIBRARIES = libkigpart.la
libkigpart_la_SOURCES = dummy.cpp
-libkigpart_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries) $(LIB_QT) $(LIB_TDECORE) $(LIB_TDEUI) $(LIB_TDEIO) -ltdetexteditor
+libkigpart_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries) $(LIB_TQT) $(LIB_TDECORE) $(LIB_TDEUI) $(LIB_TDEIO) -ltdetexteditor
libkigpart_la_LIBADD = $(LIB_TDEPARTS) \
misc/libmisc.la objects/libobjects.la filters/libfilters.la \
modes/libmodes.la kig/libkigparttemp.la $(scriptinglib)
diff --git a/kig/filters/cabri-filter.cpp b/kig/filters/cabri-filter.cpp
index 0a94f140..f65a0138 100644
--- a/kig/filters/cabri-filter.cpp
+++ b/kig/filters/cabri-filter.cpp
@@ -343,12 +343,12 @@ KigDocument* KigFilterCabri::load( const TQString& file )
return 0;
// reading linestyle
- Qt::PenStyle ls = Qt::SolidLine;
+ TQt::PenStyle ls = TQt::SolidLine;
if ( ( obj.lineSegLength > 1 ) && ( obj.lineSegLength < 6 ) &&
( obj.lineSegSplit > 1 ) && ( obj.lineSegSplit <= 10 ) )
- ls = Qt::DotLine;
+ ls = TQt::DotLine;
else if ( ( obj.lineSegLength >= 6 ) && ( obj.lineSegSplit > 10 ) )
- ls = Qt::DashLine;
+ ls = TQt::DashLine;
int ps = 0;
args.clear();
diff --git a/kig/filters/drgeo-filter-chooser.cpp b/kig/filters/drgeo-filter-chooser.cpp
index 89250235..4ec6db88 100644
--- a/kig/filters/drgeo-filter-chooser.cpp
+++ b/kig/filters/drgeo-filter-chooser.cpp
@@ -33,9 +33,9 @@ KigFilterDrgeoChooser::KigFilterDrgeoChooser( const TQStringList& l )
FigureListBox->insertStringList( l );
- connect( OKButton, TQT_SIGNAL( clicked() ), TQT_SLOT( slotOKPressed() ) );
- connect( CancelButton, TQT_SIGNAL( clicked() ), TQT_SLOT( slotCancelPressed() ) );
- connect( FigureListBox, TQT_SIGNAL( executed( TQListBoxItem* ) ), TQT_SLOT( slotExecuted( TQListBoxItem* ) ) );
+ connect( OKButton, TQ_SIGNAL( clicked() ), TQ_SLOT( slotOKPressed() ) );
+ connect( CancelButton, TQ_SIGNAL( clicked() ), TQ_SLOT( slotCancelPressed() ) );
+ connect( FigureListBox, TQ_SIGNAL( executed( TQListBoxItem* ) ), TQ_SLOT( slotExecuted( TQListBoxItem* ) ) );
}
void KigFilterDrgeoChooser::slotOKPressed()
diff --git a/kig/filters/drgeo-filter-chooser.h b/kig/filters/drgeo-filter-chooser.h
index 78e3b4c0..9b227bca 100644
--- a/kig/filters/drgeo-filter-chooser.h
+++ b/kig/filters/drgeo-filter-chooser.h
@@ -27,7 +27,7 @@ class TQStringList;
class KigFilterDrgeoChooser
: public KigFilterDrgeoChooserBase
{
- Q_OBJECT
+ TQ_OBJECT
public:
diff --git a/kig/filters/drgeo-filter.cpp b/kig/filters/drgeo-filter.cpp
index 9742fcf5..1c904c3e 100644
--- a/kig/filters/drgeo-filter.cpp
+++ b/kig/filters/drgeo-filter.cpp
@@ -729,7 +729,7 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
// Normal -> the medium
// Thick -> the biggest one
int w = -1;
- Qt::PenStyle s = Qt::SolidLine;
+ TQt::PenStyle s = TQt::SolidLine;
if ( domelem.tagName() == "point" )
{
if ( domelem.attribute( "thickness" ) == "Normal" )
@@ -740,7 +740,7 @@ KigDocument* KigFilterDrgeo::importFigure( TQDomNode f, const TQString& file, co
else
{
if ( domelem.attribute( "thickness" ) == "Dashed" )
- s = Qt::DotLine;
+ s = TQt::DotLine;
if ( domelem.attribute( "thickness" ) == "Thick" )
w = 2;
}
diff --git a/kig/filters/exporter.cpp b/kig/filters/exporter.cpp
index 32b25f01..a64bab01 100644
--- a/kig/filters/exporter.cpp
+++ b/kig/filters/exporter.cpp
@@ -162,7 +162,7 @@ void ImageExporter::run( const KigPart& doc, KigWidget& w )
TQPixmap img( TQSize( width, height ) );
img.fill( TQt::white );
- KigPainter p( ScreenInfo( w.screenInfo().shownRect(), img.rect() ), TQT_TQPAINTDEVICE(&img), doc.document() );
+ KigPainter p( ScreenInfo( w.screenInfo().shownRect(), img.rect() ), &img, doc.document() );
p.setWholeWinOverlay();
p.drawGrid( doc.document().coordinateSystem(), showgrid, showaxes );
// FIXME: show the selections ?
diff --git a/kig/filters/imageexporteroptions.cpp b/kig/filters/imageexporteroptions.cpp
index cd68a0af..a72b0ae7 100644
--- a/kig/filters/imageexporteroptions.cpp
+++ b/kig/filters/imageexporteroptions.cpp
@@ -28,8 +28,8 @@ ImageExporterOptions::ImageExporterOptions( TQWidget* parent, const TQSize& s )
minternallysettingstuff( false )
{
keepAspectRatio->setChecked( true );
- connect( WidthInput, TQT_SIGNAL( valueChanged( int ) ), this, TQT_SLOT( slotWidthChanged( int ) ) );
- connect( HeightInput, TQT_SIGNAL( valueChanged( int ) ), this, TQT_SLOT( slotHeightChanged( int ) ) );
+ connect( WidthInput, TQ_SIGNAL( valueChanged( int ) ), this, TQ_SLOT( slotWidthChanged( int ) ) );
+ connect( HeightInput, TQ_SIGNAL( valueChanged( int ) ), this, TQ_SLOT( slotHeightChanged( int ) ) );
}
ImageExporterOptions::~ImageExporterOptions()
diff --git a/kig/filters/imageexporteroptions.h b/kig/filters/imageexporteroptions.h
index ba5e645b..21b67c3e 100644
--- a/kig/filters/imageexporteroptions.h
+++ b/kig/filters/imageexporteroptions.h
@@ -25,7 +25,7 @@ class TQSize;
class ImageExporterOptions
: public ImageExporterOptionsBase
{
- Q_OBJECT
+ TQ_OBJECT
TQSize msize;
diff --git a/kig/filters/kgeo-filter.cpp b/kig/filters/kgeo-filter.cpp
index 8849256b..1b0900cf 100644
--- a/kig/filters/kgeo-filter.cpp
+++ b/kig/filters/kgeo-filter.cpp
@@ -42,7 +42,7 @@
#include "../objects/transform_types.h"
#include "../objects/vector_type.h"
-#include <ksimpleconfig.h>
+#include <tdesimpleconfig.h>
#include <algorithm>
#include <functional>
@@ -54,14 +54,14 @@ bool KigFilterKGeo::supportMime( const TQString& mime )
KigDocument* KigFilterKGeo::load( const TQString& sFrom )
{
- // kgeo uses a KSimpleConfig to save its contents...
- KSimpleConfig config ( sFrom );
+ // kgeo uses a TDESimpleConfig to save its contents...
+ TDESimpleConfig config ( sFrom );
loadMetrics ( &config );
return loadObjects ( sFrom, &config );
}
-void KigFilterKGeo::loadMetrics(KSimpleConfig* c )
+void KigFilterKGeo::loadMetrics(TDESimpleConfig* c )
{
c->setGroup("Main");
xMax = c->readNumEntry("XMax", 16);
@@ -100,7 +100,7 @@ static std::vector<KGeoHierarchyElement> sortElems( const std::vector<KGeoHierar
return ret;
}
-KigDocument* KigFilterKGeo::loadObjects( const TQString& file, KSimpleConfig* c )
+KigDocument* KigFilterKGeo::loadObjects( const TQString& file, TDESimpleConfig* c )
{
KigDocument* ret = new KigDocument();
diff --git a/kig/filters/kgeo-filter.h b/kig/filters/kgeo-filter.h
index 9bac9085..62fae04c 100644
--- a/kig/filters/kgeo-filter.h
+++ b/kig/filters/kgeo-filter.h
@@ -21,7 +21,7 @@
#include "filter.h"
-class KSimpleConfig;
+class TDESimpleConfig;
/**
* This is an import filter for files generated by the program KGeo,
@@ -43,8 +43,8 @@ protected:
KigFilterKGeo();
~KigFilterKGeo();
- void loadMetrics ( KSimpleConfig* );
- KigDocument* loadObjects ( const TQString& file, KSimpleConfig* );
+ void loadMetrics ( TDESimpleConfig* );
+ KigDocument* loadObjects ( const TQString& file, TDESimpleConfig* );
int xMax;
int yMax;
diff --git a/kig/filters/latexexporter.cpp b/kig/filters/latexexporter.cpp
index 622a1a49..bbf6144a 100644
--- a/kig/filters/latexexporter.cpp
+++ b/kig/filters/latexexporter.cpp
@@ -126,7 +126,7 @@ private:
* Draws a line (segment) or a vector if vector is true.
*/
void emitLine( const Coordinate& a, const Coordinate& b, const int width,
- const Qt::PenStyle s, bool vector = false );
+ const TQt::PenStyle s, bool vector = false );
/**
* Sends a new line character ( \n ) to stream.
*/
@@ -144,7 +144,7 @@ private:
/**
* Converts a pen style into latex style string.
*/
- TQString writeStyle( Qt::PenStyle style );
+ TQString writeStyle( TQt::PenStyle style );
/**
* Plots a generic curve though its points calc'ed with getPoint.
*/
@@ -157,7 +157,7 @@ void LatexExportImpVisitor::emitCoord( const Coordinate& c )
}
void LatexExportImpVisitor::emitLine( const Coordinate& a, const Coordinate& b,
- const int width, const Qt::PenStyle s,
+ const int width, const TQt::PenStyle s,
bool vector )
{
mstream << "\\psline[linecolor=" << mcurcolorid << ",linewidth=" << width / 100.0
@@ -210,7 +210,7 @@ double LatexExportImpVisitor::dimRealToCoord( int dim )
return fabs( r.width() );
}
-TQString LatexExportImpVisitor::writeStyle( Qt::PenStyle style )
+TQString LatexExportImpVisitor::writeStyle( TQt::PenStyle style )
{
TQString ret( "linestyle=" );
if ( style == TQt::DashLine )
diff --git a/kig/filters/native-filter.cpp b/kig/filters/native-filter.cpp
index cf6521b2..72c464a8 100644
--- a/kig/filters/native-filter.cpp
+++ b/kig/filters/native-filter.cpp
@@ -39,7 +39,7 @@
#include <karchive.h>
#include <kdebug.h>
#include <tdeglobal.h>
-#include <kstandarddirs.h>
+#include <tdestandarddirs.h>
#include <ktar.h>
#include <stdio.h>
@@ -536,7 +536,7 @@ KigDocument* KigFilterNative::load07( const TQString& file, const TQDomElement&
if ( ! ok ) width = -1;
tmp = e.attribute( "style" );
- Qt::PenStyle style = ObjectDrawer::styleFromString( tmp );
+ TQt::PenStyle style = ObjectDrawer::styleFromString( tmp );
tmp = e.attribute( "point-style" );
int pointstyle = ObjectDrawer::pointStyleFromString( tmp );
diff --git a/kig/filters/svgexporter.cpp b/kig/filters/svgexporter.cpp
index 2fd53756..54e9c5f1 100644
--- a/kig/filters/svgexporter.cpp
+++ b/kig/filters/svgexporter.cpp
@@ -91,7 +91,7 @@ void SVGExporter::run( const KigPart& part, KigWidget& w )
TQPicture pic;
pic.setBoundingRect( r );
KigPainter* p = new KigPainter( ScreenInfo( w.screenInfo().shownRect(), viewrect ),
- TQT_TQPAINTDEVICE(&pic), part.document() );
+ &pic, part.document() );
// p->setWholeWinOverlay();
// p->setBrushColor( TQt::white );
// p->setBrushStyle( TQt::SolidPattern );
diff --git a/kig/kig/Makefile.am b/kig/kig/Makefile.am
index 063b1e2e..67747bff 100644
--- a/kig/kig/Makefile.am
+++ b/kig/kig/Makefile.am
@@ -23,7 +23,7 @@ bin_PROGRAMS = kig
# the application source, library search path, and link libraries
kig_SOURCES = main.cpp kig.cpp
-kig_LDFLAGS = $(all_libraries) $(KDE_RPATH) $(LIB_QT) -lDCOP $(LIB_TDECORE) $(LIB_TDEUI) -ltdefx $(LIB_TDEIO) -ltdetexteditor
+kig_LDFLAGS = $(all_libraries) $(KDE_RPATH) $(LIB_TQT) -lDCOP $(LIB_TDECORE) $(LIB_TDEUI) -ltdefx $(LIB_TDEIO) -ltdetexteditor
kig_LDADD = $(LIB_TDEPARTS)
# this is where the desktop file will go
diff --git a/kig/kig/kig.cpp b/kig/kig/kig.cpp
index d6af88b2..4dd41cc3 100644
--- a/kig/kig/kig.cpp
+++ b/kig/kig/kig.cpp
@@ -69,7 +69,7 @@ Kig::Kig()
// now that the Part is loaded, we cast it to a Part to get
// our hands on it
m_part = static_cast<KParts::ReadWritePart*>
- (factory->create(TQT_TQOBJECT(this), "kig_part", "KParts::ReadWritePart" ));
+ (factory->create(this, "kig_part", "KParts::ReadWritePart" ));
if (m_part)
{
// tell the KParts::MainWindow that this is indeed the main widget
@@ -78,7 +78,7 @@ Kig::Kig()
// and integrate the part's GUI with the shell's
createGUI(m_part);
// finally show tip-of-day ( if the user wants it :) )
- TQTimer::singleShot( 0, this, TQT_SLOT( startupTipOfDay() ) );
+ TQTimer::singleShot( 0, this, TQ_SLOT( startupTipOfDay() ) );
}
}
else
@@ -105,30 +105,30 @@ Kig::~Kig()
void Kig::setupActions()
{
- KStdAction::openNew(TQT_TQOBJECT(this), TQT_SLOT(fileNew()), actionCollection());
- KStdAction::open(TQT_TQOBJECT(this), TQT_SLOT(fileOpen()), actionCollection());
- KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection());
+ KStdAction::openNew(this, TQ_SLOT(fileNew()), actionCollection());
+ KStdAction::open(this, TQ_SLOT(fileOpen()), actionCollection());
+ KStdAction::quit(this, TQ_SLOT(close()), actionCollection());
#ifdef KIG_DONT_USE_NEW_KMAINWINDOW_FEATURES
- m_toolbarAction = KStdAction::showToolbar(TQT_TQOBJECT(this), TQT_SLOT(optionsShowToolbar()), actionCollection());
- m_statusbarAction = KStdAction::showStatusbar(TQT_TQOBJECT(this), TQT_SLOT(optionsShowStatusbar()), actionCollection());
+ m_toolbarAction = KStdAction::showToolbar(this, TQ_SLOT(optionsShowToolbar()), actionCollection());
+ m_statusbarAction = KStdAction::showStatusbar(this, TQ_SLOT(optionsShowStatusbar()), actionCollection());
#else
createStandardStatusBarAction();
setStandardToolBarMenuEnabled(true);
#endif
// FIXME: this (recent files) should be app-wide, not specific to each window...
- m_recentFilesAction = KStdAction::openRecent(TQT_TQOBJECT(this), TQT_SLOT(openURL(const KURL&)), actionCollection());
+ m_recentFilesAction = KStdAction::openRecent(this, TQ_SLOT(openURL(const KURL&)), actionCollection());
m_recentFilesAction->loadEntries(config);
#if KDE_IS_VERSION( 3, 2, 90 )
- KStdAction::keyBindings( guiFactory(), TQT_SLOT( configureShortcuts() ), actionCollection() );
+ KStdAction::keyBindings( guiFactory(), TQ_SLOT( configureShortcuts() ), actionCollection() );
#else
- KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureKeys()), actionCollection());
+ KStdAction::keyBindings(this, TQ_SLOT(optionsConfigureKeys()), actionCollection());
#endif
- KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureToolbars()), actionCollection());
+ KStdAction::configureToolbars(this, TQ_SLOT(optionsConfigureToolbars()), actionCollection());
- KStdAction::tipOfDay( TQT_TQOBJECT(this), TQT_SLOT( tipOfDay() ), actionCollection(), "help_tipofday" );
+ KStdAction::tipOfDay( this, TQ_SLOT( tipOfDay() ), actionCollection(), "help_tipofday" );
}
void Kig::saveProperties(TDEConfig* config)
@@ -203,8 +203,8 @@ void Kig::optionsConfigureToolbars()
// use the standard toolbar editor
KEditToolbar dlg(factory());
- connect(&dlg, TQT_SIGNAL(newToolbarConfig()),
- this, TQT_SLOT(applyNewToolbarConfig()));
+ connect(&dlg, TQ_SIGNAL(newToolbarConfig()),
+ this, TQ_SLOT(applyNewToolbarConfig()));
dlg.exec();
}
diff --git a/kig/kig/kig.h b/kig/kig/kig.h
index db2a3c33..d6681570 100644
--- a/kig/kig/kig.h
+++ b/kig/kig/kig.h
@@ -48,7 +48,7 @@ class TDERecentFilesAction;
*/
class Kig : public KParts::MainWindow
{
- Q_OBJECT
+ TQ_OBJECT
public:
/**
diff --git a/kig/kig/kig_commands.h b/kig/kig/kig_commands.h
index b7e4ac12..16ab40b2 100644
--- a/kig/kig/kig_commands.h
+++ b/kig/kig/kig_commands.h
@@ -43,7 +43,7 @@ class Rect;
class KigCommand
: public TQObject, public KNamedCommand
{
- Q_OBJECT
+ TQ_OBJECT
class Private;
Private* d;
diff --git a/kig/kig/kig_part.cpp b/kig/kig/kig_part.cpp
index ef4de909..be58e391 100644
--- a/kig/kig/kig_part.cpp
+++ b/kig/kig/kig_part.cpp
@@ -49,13 +49,13 @@
#include <tdefiledialog.h>
#include <tdeglobal.h>
#include <kiconloader.h>
-#include <kinstance.h>
+#include <tdeinstance.h>
#include <tdelocale.h>
#include <tdemainwindow.h>
#include <tdemessagebox.h>
#include <kmimetype.h>
#include <kprinter.h>
-#include <kstandarddirs.h>
+#include <tdestandarddirs.h>
#include <kstdaction.h>
#include <tdetoolbar.h>
#include <tdeparts/genericfactory.h>
@@ -193,7 +193,7 @@ KigPart::KigPart( TQWidget *parentWidget, const char *,
// construct our command history
mhistory = new KCommandHistory(actionCollection());
mhistory->documentSaved();
- connect( mhistory, TQT_SIGNAL( documentRestored() ), this, TQT_SLOT( setUnmodified() ) );
+ connect( mhistory, TQ_SIGNAL( documentRestored() ), this, TQ_SLOT( setUnmodified() ) );
// we are read-write by default
setReadWrite(true);
@@ -206,21 +206,21 @@ KigPart::KigPart( TQWidget *parentWidget, const char *,
void KigPart::setupActions()
{
// save actions..
- (void) KStdAction::saveAs(this, TQT_SLOT(fileSaveAs()), actionCollection());
- (void) KStdAction::save(this, TQT_SLOT(fileSave()), actionCollection());
+ (void) KStdAction::saveAs(this, TQ_SLOT(fileSaveAs()), actionCollection());
+ (void) KStdAction::save(this, TQ_SLOT(fileSave()), actionCollection());
// print actions
- (void) KStdAction::print( this, TQT_SLOT( filePrint() ), actionCollection() );
- (void) KStdAction::printPreview( this, TQT_SLOT( filePrintPreview() ), actionCollection() );
+ (void) KStdAction::print( this, TQ_SLOT( filePrint() ), actionCollection() );
+ (void) KStdAction::printPreview( this, TQ_SLOT( filePrintPreview() ), actionCollection() );
// selection actions
aSelectAll = KStdAction::selectAll(
- this, TQT_SLOT( slotSelectAll() ), actionCollection() );
+ this, TQ_SLOT( slotSelectAll() ), actionCollection() );
aDeselectAll = KStdAction::deselect(
- this, TQT_SLOT( slotDeselectAll() ), actionCollection() );
+ this, TQ_SLOT( slotDeselectAll() ), actionCollection() );
aInvertSelection = new TDEAction(
i18n( "Invert Selection" ), "", 0, this,
- TQT_SLOT( slotInvertSelection() ), actionCollection(),
+ TQ_SLOT( slotInvertSelection() ), actionCollection(),
"edit_invert_selection" );
// we need icons...
@@ -229,46 +229,46 @@ void KigPart::setupActions()
aDeleteObjects = new TDEAction(
i18n("&Delete Objects"), "edit-delete", Key_Delete, this,
- TQT_SLOT(deleteObjects()), actionCollection(), "delete_objects");
+ TQ_SLOT(deleteObjects()), actionCollection(), "delete_objects");
aDeleteObjects->setToolTip(i18n("Delete the selected objects"));
aCancelConstruction = new TDEAction(
i18n("Cancel Construction"), "process-stop", Key_Escape, this,
- TQT_SLOT(cancelConstruction()), actionCollection(), "cancel_construction");
+ TQ_SLOT(cancelConstruction()), actionCollection(), "cancel_construction");
aCancelConstruction->setToolTip(
i18n("Cancel the construction of the object being constructed"));
aCancelConstruction->setEnabled(false);
aShowHidden = new TDEAction(
- i18n("U&nhide All"), 0, this, TQT_SLOT( showHidden() ),
+ i18n("U&nhide All"), 0, this, TQ_SLOT( showHidden() ),
actionCollection(), "edit_unhide_all");
aShowHidden->setToolTip(i18n("Show all hidden objects"));
aShowHidden->setEnabled( true );
aNewMacro = new TDEAction(
- i18n("&New Macro..."), "gear", 0, this, TQT_SLOT(newMacro()),
+ i18n("&New Macro..."), "gear", 0, this, TQ_SLOT(newMacro()),
actionCollection(), "macro_action");
aNewMacro->setToolTip(i18n("Define a new macro"));
aConfigureTypes = new TDEAction(
- i18n("Manage &Types..."), 0, this, TQT_SLOT(editTypes()),
+ i18n("Manage &Types..."), 0, this, TQ_SLOT(editTypes()),
actionCollection(), "types_edit");
aConfigureTypes->setToolTip(i18n("Manage macro types."));
KigExportManager::instance()->addMenuAction( this, m_widget->realWidget(),
actionCollection() );
- TDEAction* a = KStdAction::zoomIn( TQT_TQOBJECT(m_widget), TQT_SLOT( slotZoomIn() ),
+ TDEAction* a = KStdAction::zoomIn( m_widget, TQ_SLOT( slotZoomIn() ),
actionCollection() );
a->setToolTip( i18n( "Zoom in on the document" ) );
a->setWhatsThis( i18n( "Zoom in on the document" ) );
- a = KStdAction::zoomOut( TQT_TQOBJECT(m_widget), TQT_SLOT( slotZoomOut() ),
+ a = KStdAction::zoomOut( m_widget, TQ_SLOT( slotZoomOut() ),
actionCollection() );
a->setToolTip( i18n( "Zoom out of the document" ) );
a->setWhatsThis( i18n( "Zoom out of the document" ) );
- a = KStdAction::fitToPage( TQT_TQOBJECT(m_widget), TQT_SLOT( slotRecenterScreen() ),
+ a = KStdAction::fitToPage( m_widget, TQ_SLOT( slotRecenterScreen() ),
actionCollection() );
// grr.. why isn't there an icon for this..
a->setIconSet( TQIconSet( l->loadIcon( "view_fit_to_page", TDEIcon::Toolbar ) ) );
@@ -281,12 +281,12 @@ void KigPart::setupActions()
#endif
#endif
#ifdef KIG_PART_CPP_STD_FULLSCREEN_ACTION
- a = KStdAction::fullScreen( TQT_TQOBJECT(m_widget), TQT_SLOT( toggleFullScreen() ), actionCollection(), (TQWidget*)(widget()->parent()),"fullscreen" );
+ a = KStdAction::fullScreen( m_widget, TQ_SLOT( toggleFullScreen() ), actionCollection(), (TQWidget*)(widget()->parent()),"fullscreen" );
#else
tmp = l->loadIcon( "view-fullscreen", TDEIcon::Toolbar );
a = new TDEAction(
i18n( "Full Screen" ), tmp, CTRL+SHIFT+Key_F,
- m_widget, TQT_SLOT( toggleFullScreen() ),
+ m_widget, TQ_SLOT( toggleFullScreen() ),
actionCollection(), "fullscreen" );
#endif
a->setToolTip( i18n( "View this document full-screen." ) );
@@ -294,31 +294,31 @@ void KigPart::setupActions()
// TODO: an icon for this..
a = new TDEAction(
- i18n( "&Select Shown Area" ), "zoom-fit-best", 0, TQT_TQOBJECT(m_widget), TQT_SLOT( zoomRect() ),
+ i18n( "&Select Shown Area" ), "zoom-fit-best", 0, m_widget, TQ_SLOT( zoomRect() ),
actionCollection(), "view_select_shown_rect" );
a->setToolTip( i18n( "Select the area that you want to be shown in the window." ) );
a->setWhatsThis( i18n( "Select the area that you want to be shown in the window." ) );
a = new TDEAction(
- i18n( "S&elect Zoom Area" ), "viewmag", 0, TQT_TQOBJECT(m_widget), TQT_SLOT( zoomArea() ),
+ i18n( "S&elect Zoom Area" ), "viewmag", 0, m_widget, TQ_SLOT( zoomArea() ),
actionCollection(), "view_zoom_area" );
// a->setToolTip( i18n( "Select the area that you want to be shown in the window." ) );
// a->setWhatsThis( i18n( "Select the area that you want to be shown in the window." ) );
aToggleGrid = new TDEToggleAction(
- i18n( "Show &Grid" ), 0, this, TQT_SLOT( toggleGrid() ),
+ i18n( "Show &Grid" ), 0, this, TQ_SLOT( toggleGrid() ),
actionCollection(), "settings_show_grid" );
aToggleGrid->setToolTip( i18n( "Show or hide the grid." ) );
aToggleGrid->setChecked( true );
aToggleAxes = new TDEToggleAction(
- i18n( "Show &Axes" ), 0, this, TQT_SLOT( toggleAxes() ),
+ i18n( "Show &Axes" ), 0, this, TQ_SLOT( toggleAxes() ),
actionCollection(), "settings_show_axes" );
aToggleAxes->setToolTip( i18n( "Show or hide the axes." ) );
aToggleAxes->setChecked( true );
aToggleNightVision = new TDEToggleAction(
- i18n( "Wear Infrared Glasses" ), 0, this, TQT_SLOT( toggleNightVision() ),
+ i18n( "Wear Infrared Glasses" ), 0, this, TQ_SLOT( toggleNightVision() ),
actionCollection(), "settings_toggle_nightvision" );
aToggleNightVision->setToolTip( i18n( "Enable/Disable hidden objects visibility." ) );
aToggleNightVision->setChecked( false );
@@ -563,8 +563,8 @@ void KigPart::delObjects( const std::vector<ObjectHolder*>& os )
void KigPart::enableConstructActions( bool enabled )
{
for_each( aActions.begin(), aActions.end(),
- bind2nd( mem_fun( &TDEAction::setEnabled ),
- enabled ) );
+ std::bind( mem_fn( &TDEAction::setEnabled ),
+ std::placeholders::_1, enabled ) );
}
void KigPart::unplugActionLists()
@@ -635,7 +635,7 @@ void KigPart::runMode( KigMode* m )
setMode( m );
- (void) kapp->eventLoop()->enterLoop();
+ (void) tdeApp->eventLoop()->enterLoop();
setMode( prev );
redrawScreen();
@@ -646,7 +646,7 @@ void KigPart::doneMode( KigMode* d )
assert( d == mMode );
// pretend to use this var..
(void)d;
- kapp->eventLoop()->exitLoop();
+ tdeApp->eventLoop()->exitLoop();
}
void KigPart::actionRemoved( GUIAction* a, GUIUpdateToken& t )
@@ -716,7 +716,7 @@ void KigPart::setupMacroTypes()
};
// hack: we need to plug the action lists _after_ the gui is
// built.. i can't find a better solution than this...
- TQTimer::singleShot( 0, this, TQT_SLOT( plugActionLists() ) );
+ TQTimer::singleShot( 0, this, TQ_SLOT( plugActionLists() ) );
}
void KigPart::setupBuiltinMacros()
diff --git a/kig/kig/kig_part.h b/kig/kig/kig_part.h
index 140c56f6..8865b856 100644
--- a/kig/kig/kig_part.h
+++ b/kig/kig/kig_part.h
@@ -60,7 +60,7 @@ class ScreenInfo;
*/
class KigPart : public KParts::ReadWritePart
{
- Q_OBJECT
+ TQ_OBJECT
public:
/**
diff --git a/kig/kig/kig_view.cpp b/kig/kig/kig_view.cpp
index 7d988df4..b9f64590 100644
--- a/kig/kig/kig_view.cpp
+++ b/kig/kig/kig_view.cpp
@@ -69,7 +69,7 @@ KigWidget::KigWidget( KigPart* part,
{
part->addWidget(this);
- setFocusPolicy(TQ_ClickFocus);
+ setFocusPolicy(TQWidget::ClickFocus);
setBackgroundMode( TQt::NoBackground );
setMouseTracking(true);
@@ -89,32 +89,32 @@ void KigWidget::paintEvent(TQPaintEvent*)
void KigWidget::mousePressEvent (TQMouseEvent* e)
{
- if( e->button() & Qt::LeftButton )
+ if( e->button() & TQt::LeftButton )
return mpart->mode()->leftClicked( e, this );
- if ( e->button() & Qt::MidButton )
+ if ( e->button() & TQt::MidButton )
return mpart->mode()->midClicked( e, this );
- if ( e->button() & Qt::RightButton )
+ if ( e->button() & TQt::RightButton )
return mpart->mode()->rightClicked( e, this );
}
void KigWidget::mouseMoveEvent (TQMouseEvent* e)
{
- if( e->state() & Qt::LeftButton )
+ if( e->state() & TQt::LeftButton )
return mpart->mode()->leftMouseMoved( e, this );
- if ( e->state() & Qt::MidButton )
+ if ( e->state() & TQt::MidButton )
return mpart->mode()->midMouseMoved( e, this );
- if ( e->state() & Qt::RightButton )
+ if ( e->state() & TQt::RightButton )
return mpart->mode()->rightMouseMoved( e, this );
return mpart->mode()->mouseMoved( e, this );
}
void KigWidget::mouseReleaseEvent (TQMouseEvent* e)
{
- if( e->state() & Qt::LeftButton )
+ if( e->state() & TQt::LeftButton )
return mpart->mode()->leftReleased( e, this );
- if ( e->state() & Qt::MidButton )
+ if ( e->state() & TQt::MidButton )
return mpart->mode()->midReleased( e, this );
- if ( e->state() & Qt::RightButton )
+ if ( e->state() & TQt::RightButton )
return mpart->mode()->rightReleased( e, this );
}
@@ -245,7 +245,7 @@ void KigWidget::redrawScreen( const std::vector<ObjectHolder*>& selection, bool
// update the screen...
clearStillPix();
- KigPainter p( msi, TQT_TQPAINTDEVICE(&stillPix), mpart->document() );
+ KigPainter p( msi, &stillPix, mpart->document() );
p.drawGrid( mpart->document().coordinateSystem(), mpart->document().grid(),
mpart->document().axes() );
p.drawObjects( selection, true );
@@ -294,21 +294,21 @@ KigView::KigView( KigPart* part,
mupdatingscrollbars( false ),
mrealwidget( 0 ), mpart( part )
{
- connect( part, TQT_SIGNAL( recenterScreen() ), this, TQT_SLOT( slotInternalRecenterScreen() ) );
+ connect( part, TQ_SIGNAL( recenterScreen() ), this, TQ_SLOT( slotInternalRecenterScreen() ) );
mlayout = new TQGridLayout( this, 2, 2 );
- mrightscroll = new TQScrollBar(Qt::Vertical, this, "Right Scrollbar" );
+ mrightscroll = new TQScrollBar(TQt::Vertical, this, "Right Scrollbar" );
// TODO: make this configurable...
mrightscroll->setTracking( true );
- connect( mrightscroll, TQT_SIGNAL( valueChanged( int ) ),
- this, TQT_SLOT( slotRightScrollValueChanged( int ) ) );
- connect( mrightscroll, TQT_SIGNAL( sliderReleased() ),
- this, TQT_SLOT( updateScrollBars() ) );
- mbottomscroll = new TQScrollBar(Qt::Horizontal, this, "Bottom Scrollbar" );
- connect( mbottomscroll, TQT_SIGNAL( valueChanged( int ) ),
- this, TQT_SLOT( slotBottomScrollValueChanged( int ) ) );
- connect( mbottomscroll, TQT_SIGNAL( sliderReleased() ),
- this, TQT_SLOT( updateScrollBars() ) );
+ connect( mrightscroll, TQ_SIGNAL( valueChanged( int ) ),
+ this, TQ_SLOT( slotRightScrollValueChanged( int ) ) );
+ connect( mrightscroll, TQ_SIGNAL( sliderReleased() ),
+ this, TQ_SLOT( updateScrollBars() ) );
+ mbottomscroll = new TQScrollBar(TQt::Horizontal, this, "Bottom Scrollbar" );
+ connect( mbottomscroll, TQ_SIGNAL( valueChanged( int ) ),
+ this, TQ_SLOT( slotBottomScrollValueChanged( int ) ) );
+ connect( mbottomscroll, TQ_SIGNAL( sliderReleased() ),
+ this, TQ_SLOT( updateScrollBars() ) );
mrealwidget = new KigWidget( part, this, this, "Kig Widget", fullscreen );
mlayout->addWidget( mbottomscroll, 1, 0 );
mlayout->addWidget( mrealwidget, 0, 0 );
@@ -451,8 +451,8 @@ TQSize KigWidget::sizeHint() const
void KigWidget::wheelEvent( TQWheelEvent* e )
{
int delta = e->delta();
- Qt::Orientation orient = e->orientation();
- if ( orient == Qt::Vertical )
+ TQt::Orientation orient = e->orientation();
+ if ( orient == TQt::Vertical )
mview->scrollVertical( delta );
else
mview->scrollHorizontal( delta );
diff --git a/kig/kig/kig_view.h b/kig/kig/kig_view.h
index 2e09014a..99535218 100644
--- a/kig/kig/kig_view.h
+++ b/kig/kig/kig_view.h
@@ -49,7 +49,7 @@ class KigView;
*/
class KigWidget : public TQWidget
{
- Q_OBJECT
+ TQ_OBJECT
KigPart* mpart;
@@ -227,7 +227,7 @@ public:
class KigView
: public TQWidget
{
- Q_OBJECT
+ TQ_OBJECT
TQGridLayout* mlayout;
diff --git a/kig/kig/main.cpp b/kig/kig/main.cpp
index 9923f9bf..b0c2d963 100644
--- a/kig/kig/main.cpp
+++ b/kig/kig/main.cpp
@@ -20,7 +20,7 @@
#include "kig.h"
-#include <kuniqueapplication.h>
+#include <tdeuniqueapplication.h>
#include <tdeaboutdata.h>
#include <tdecmdlineargs.h>
#include <tdelocale.h>
@@ -40,7 +40,7 @@ static TDECmdLineOptions options[] =
};
class KigApplication
- : public KUniqueApplication
+ : public TDEUniqueApplication
{
public:
KigApplication( bool gui = true );
@@ -49,7 +49,7 @@ public:
};
KigApplication::KigApplication( bool gui )
- : KUniqueApplication( gui, gui )
+ : TDEUniqueApplication( gui, gui )
{
}
diff --git a/kig/misc/boost_intrusive_pointer.h b/kig/misc/boost_intrusive_pointer.h
index 1dd2dd81..292a73c9 100644
--- a/kig/misc/boost_intrusive_pointer.h
+++ b/kig/misc/boost_intrusive_pointer.h
@@ -141,7 +141,6 @@ public:
return p_ == 0? 0: &intrusive_ptr::get;
}
- // operator! is a Borland-specific workaround
bool operator! () const
{
return p_ == 0;
diff --git a/kig/misc/guiaction.h b/kig/misc/guiaction.h
index 56ab6f73..7837f6a6 100644
--- a/kig/misc/guiaction.h
+++ b/kig/misc/guiaction.h
@@ -34,7 +34,7 @@ class KigPart;
class KigGUIAction
: public TDEAction
{
- Q_OBJECT
+ TQ_OBJECT
GUIAction* mact;
KigPart& mdoc;
diff --git a/kig/misc/kigfiledialog.h b/kig/misc/kigfiledialog.h
index 14c53a2d..a96b8c81 100644
--- a/kig/misc/kigfiledialog.h
+++ b/kig/misc/kigfiledialog.h
@@ -27,7 +27,7 @@
class KigFileDialog
: public KFileDialog
{
- Q_OBJECT
+ TQ_OBJECT
private:
diff --git a/kig/misc/kiginputdialog.cpp b/kig/misc/kiginputdialog.cpp
index a596c87c..24c659cf 100644
--- a/kig/misc/kiginputdialog.cpp
+++ b/kig/misc/kiginputdialog.cpp
@@ -84,7 +84,7 @@ KigInputDialog::KigInputDialog( const TQString& caption, const TQString& label,
d->m_textEdit = new KTextEdit( frame );
d->m_textEdit->setText( label );
d->m_textEdit->setReadOnly( true );
- d->m_textEdit->setFocusPolicy( TQ_NoFocus );
+ d->m_textEdit->setFocusPolicy( TQWidget::NoFocus );
// d->m_textEdit->setAlignment( d->m_textEdit->alignment() | TQt::WordBreak );
d->m_textEdit->setFrameStyle( TQFrame::NoFrame );
mainlay->addWidget( d->m_textEdit );
@@ -98,8 +98,8 @@ KigInputDialog::KigInputDialog( const TQString& caption, const TQString& label,
}
mainlay->addWidget( d->m_lineEditFirst );
- connect( d->m_lineEditFirst, TQT_SIGNAL(textChanged(const TQString&)),
- this, TQT_SLOT(slotCoordsChanged(const TQString&)) );
+ connect( d->m_lineEditFirst, TQ_SIGNAL(textChanged(const TQString&)),
+ this, TQ_SLOT(slotCoordsChanged(const TQString&)) );
if ( d->m_coord2.valid() )
{
@@ -108,8 +108,8 @@ KigInputDialog::KigInputDialog( const TQString& caption, const TQString& label,
d->m_lineEditSecond->setText( d->m_doc.coordinateSystem().fromScreen( d->m_coord2, d->m_doc ) );
mainlay->addWidget( d->m_lineEditSecond );
- connect( d->m_lineEditSecond, TQT_SIGNAL(textChanged(const TQString&)),
- this, TQT_SLOT(slotCoordsChanged(const TQString&)) );
+ connect( d->m_lineEditSecond, TQ_SIGNAL(textChanged(const TQString&)),
+ this, TQ_SLOT(slotCoordsChanged(const TQString&)) );
deltay += d->m_lineEditSecond->height() + spacingHint();
}
@@ -159,10 +159,10 @@ KigInputDialog::KigInputDialog( TQWidget* parent, const Goniometry& g )
mainlay->addLayout( horlay );
- connect( d->m_lineEditFirst, TQT_SIGNAL(textChanged(const TQString&)),
- this, TQT_SLOT(slotGonioTextChanged(const TQString&)) );
- connect( d->m_comboBox, TQT_SIGNAL(activated(int)),
- this, TQT_SLOT(slotGonioSystemChanged(int)) );
+ connect( d->m_lineEditFirst, TQ_SIGNAL(textChanged(const TQString&)),
+ this, TQ_SLOT(slotGonioTextChanged(const TQString&)) );
+ connect( d->m_comboBox, TQ_SIGNAL(activated(int)),
+ this, TQ_SLOT(slotGonioSystemChanged(int)) );
resize( 350, 100 );
diff --git a/kig/misc/kiginputdialog.h b/kig/misc/kiginputdialog.h
index c9f4be7d..ecde4cbd 100644
--- a/kig/misc/kiginputdialog.h
+++ b/kig/misc/kiginputdialog.h
@@ -40,7 +40,7 @@ class KigInputDialogPrivate;
class KigInputDialog
: KDialogBase
{
-Q_OBJECT
+TQ_OBJECT
public:
diff --git a/kig/misc/kigpainter.cpp b/kig/misc/kigpainter.cpp
index 4b3ede2e..cbaf57be 100644
--- a/kig/misc/kigpainter.cpp
+++ b/kig/misc/kigpainter.cpp
@@ -43,10 +43,10 @@ KigPainter::KigPainter( const ScreenInfo& si, TQPaintDevice* device,
const KigDocument& doc, bool no )
: mP ( device ),
color( TQt::blue ),
- style( Qt::SolidLine ),
+ style( TQt::SolidLine ),
pointstyle( 0 ),
width( -1 ),
- brushStyle( Qt::NoBrush ),
+ brushStyle( TQt::NoBrush ),
brushColor( TQt::blue ),
mdoc( doc ),
msi( si ),
@@ -101,7 +101,7 @@ void KigPainter::drawFatPoint( const Coordinate& p )
case 0:
{
double radius = twidth * pixelWidth();
- setBrushStyle( Qt::SolidPattern );
+ setBrushStyle( TQt::SolidPattern );
Coordinate rad( radius, radius );
rad /= 2;
Coordinate tl = p - rad;
@@ -115,7 +115,7 @@ void KigPainter::drawFatPoint( const Coordinate& p )
case 1:
{
double radius = twidth * pixelWidth();
- setBrushStyle( Qt::NoBrush );
+ setBrushStyle( TQt::NoBrush );
Coordinate rad( radius, radius );
rad /= 2;
Coordinate tl = p - rad;
@@ -218,7 +218,7 @@ void KigPainter::setColor( const TQColor& c )
mP.setPen( TQPen( color, width == -1 ? 1 : width, style ) );
}
-void KigPainter::setStyle( const Qt::PenStyle c )
+void KigPainter::setStyle( const TQt::PenStyle c )
{
style = c;
mP.setPen( TQPen( color, width == -1 ? 1 : width, style ) );
@@ -251,7 +251,7 @@ void KigPainter::setBrush( const TQBrush& b )
mP.setBrush( b );
}
-void KigPainter::setBrushStyle( const Qt::BrushStyle c )
+void KigPainter::setBrushStyle( const TQt::BrushStyle c )
{
brushStyle = c;
mP.setBrush( TQBrush( brushColor, brushStyle ) );
@@ -291,7 +291,7 @@ void KigPainter::drawPolygon( const std::vector<TQPoint>& pts,
TQPen oldpen = mP.pen();
TQBrush oldbrush = mP.brush();
setBrush( TQBrush( color, Dense4Pattern ) );
- setPen( Qt::NoPen );
+ setPen( TQt::NoPen );
// i know this isn't really fast, but i blame it all on TQt with its
// stupid container classes... what's wrong with the STL ?
TQPointArray t( pts.size() );
@@ -314,7 +314,7 @@ void KigPainter::drawArea( const std::vector<Coordinate>& pts, bool border )
if ( border )
setPen( TQPen( color, width == -1 ? 1 : width ) );
else
- setPen( Qt::NoPen );
+ setPen( TQt::NoPen );
TQPointArray t( pts.size() );
int c = 0;
for( std::vector<Coordinate>::const_iterator i = pts.begin(); i != pts.end(); ++i )
@@ -512,7 +512,7 @@ void KigPainter::drawTextStd( const TQPoint& p, const TQString& s )
int tf = AlignLeft | AlignTop | DontClip | WordBreak;
// we need the rect where we're going to paint text
setPen(TQPen(TQt::blue, 1, SolidLine));
- setBrush(Qt::NoBrush);
+ setBrush(TQt::NoBrush);
drawText( Rect(
msi.fromScreen(p), window().bottomRight()
).normalized(), s, tf );
@@ -643,7 +643,7 @@ void KigPainter::drawAngle( const Coordinate& cpoint, const double dstartangle,
// arrow.push_back( end + orthvect + vect );
// arrow.push_back( end + orthvect - vect );
- setBrushStyle( Qt::SolidPattern );
+ setBrushStyle( TQt::SolidPattern );
// drawPolygon( arrow );
mP.drawPolygon( arrow, false, 0, -1 );
diff --git a/kig/misc/kigpainter.h b/kig/misc/kigpainter.h
index ee3b14c1..60ce119f 100644
--- a/kig/misc/kigpainter.h
+++ b/kig/misc/kigpainter.h
@@ -59,10 +59,10 @@ protected:
mutable TQPainter mP;
TQColor color;
- Qt::PenStyle style;
+ TQt::PenStyle style;
int pointstyle;
int width;
- Qt::BrushStyle brushStyle;
+ TQt::BrushStyle brushStyle;
TQColor brushColor;
const KigDocument& mdoc;
@@ -94,7 +94,7 @@ public:
Rect fromScreen( const TQRect& r ) const;
// colors and stuff...
- void setStyle( const Qt::PenStyle c );
+ void setStyle( const TQt::PenStyle c );
void setColor( const TQColor& c );
/**
* setting this to -1 means to use the default width for the object
@@ -103,7 +103,7 @@ public:
void setWidth( const int c );
void setPointStyle( const int p );
void setPen( const TQPen& p );
- void setBrushStyle( const Qt::BrushStyle c );
+ void setBrushStyle( const TQt::BrushStyle c );
void setBrush( const TQBrush& b );
void setBrushColor( const TQColor& c );
diff --git a/kig/misc/object_constructor.cpp b/kig/misc/object_constructor.cpp
index ae2a37d0..6db3d802 100644
--- a/kig/misc/object_constructor.cpp
+++ b/kig/misc/object_constructor.cpp
@@ -101,7 +101,7 @@ void StandardConstructorBase::handlePrelim(
{
assert ( margsparser.check( os ) != ArgsParser::Invalid );
std::vector<ObjectCalcer*> args = margsparser.parse( os );
- p.setBrushStyle( Qt::NoBrush );
+ p.setBrushStyle( TQt::NoBrush );
p.setBrushColor( TQt::red );
p.setPen( TQPen ( TQt::red, 1) );
p.setWidth( -1 ); // -1 means the default width for the object being
@@ -130,7 +130,7 @@ void SimpleObjectTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPai
Args args;
using namespace std;
transform( parents.begin(), parents.end(),
- back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
+ back_inserter( args ), mem_fn( &ObjectCalcer::imp ) );
ObjectImp* data = mtype->calc( args, doc );
drawer.draw( *data, p, true );
delete data;
@@ -184,7 +184,7 @@ void MultiObjectTypeConstructor::drawprelim( const ObjectDrawer& drawer, KigPain
Args args;
using namespace std;
transform( parents.begin(), parents.end(),
- back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
+ back_inserter( args ), mem_fn( &ObjectCalcer::imp ) );
for ( vector<int>::const_iterator i = mparams.begin(); i != mparams.end(); ++i )
{
@@ -302,7 +302,7 @@ TQString StandardConstructorBase::useText( const ObjectCalcer& o, const std::vec
{
using namespace std;
Args args;
- transform( sel.begin(), sel.end(), back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
+ transform( sel.begin(), sel.end(), back_inserter( args ), mem_fn( &ObjectCalcer::imp ) );
std::string ret = margsparser.usetext( o.imp(), args );
if ( ret.empty() ) return TQString();
@@ -315,7 +315,7 @@ TQString StandardConstructorBase::selectStatement(
{
using namespace std;
Args args;
- transform( sel.begin(), sel.end(), back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
+ transform( sel.begin(), sel.end(), back_inserter( args ), mem_fn( &ObjectCalcer::imp ) );
std::string ret = margsparser.selectStatement( args );
if ( ret.empty() ) return TQString();
@@ -419,7 +419,7 @@ TQString MacroConstructor::selectStatement(
using namespace std;
Args args;
transform( sel.begin(), sel.end(), back_inserter( args ),
- mem_fun( &ObjectCalcer::imp ) );
+ mem_fn( &ObjectCalcer::imp ) );
std::string ret = mparser.selectStatement( args );
if ( ret.empty() ) return TQString();
else return i18n( ret.c_str() );
@@ -432,7 +432,7 @@ TQString MacroConstructor::useText( const ObjectCalcer& o, const std::vector<Obj
using namespace std;
Args args;
transform( sel.begin(), sel.end(), back_inserter( args ),
- mem_fun( &ObjectCalcer::imp ) );
+ mem_fn( &ObjectCalcer::imp ) );
std::string ret = mparser.usetext( o.imp(), args );
if ( ret.empty() ) return TQString();
else return i18n( ret.c_str() );
@@ -447,7 +447,7 @@ void MacroConstructor::handlePrelim( KigPainter& p, const std::vector<ObjectCalc
using namespace std;
Args args;
transform( sel.begin(), sel.end(), back_inserter( args ),
- mem_fun( &ObjectCalcer::imp ) );
+ mem_fn( &ObjectCalcer::imp ) );
args = mparser.parse( args );
std::vector<ObjectImp*> ret = mhier.calc( args, doc );
for ( uint i = 0; i < ret.size(); ++i )
diff --git a/kig/misc/special_constructors.cpp b/kig/misc/special_constructors.cpp
index 9618bc90..c8137966 100644
--- a/kig/misc/special_constructors.cpp
+++ b/kig/misc/special_constructors.cpp
@@ -116,7 +116,7 @@ void ConicRadicalConstructor::drawprelim(
{
Args args;
std::transform( parents.begin(), parents.end(),
- std::back_inserter( args ), std::mem_fun( &ObjectCalcer::imp ) );
+ std::back_inserter( args ), std::mem_fn( &ObjectCalcer::imp ) );
for ( int i = -1; i < 2; i += 2 )
{
IntImp root( i );
@@ -349,7 +349,7 @@ void PolygonBNPTypeConstructor::handlePrelim(
}
std::vector<ObjectCalcer*> args = os;
- p.setBrushStyle( Qt::NoBrush );
+ p.setBrushStyle( TQt::NoBrush );
p.setBrushColor( TQt::red );
p.setPen( TQPen ( TQt::red, 1) );
p.setWidth( -1 ); // -1 means the default width for the object being
@@ -658,7 +658,7 @@ void PolygonBCVConstructor::handlePrelim(
args.push_back( ns );
}
- p.setBrushStyle( Qt::NoBrush );
+ p.setBrushStyle( TQt::NoBrush );
p.setBrushColor( TQt::red );
p.setPen( TQPen ( TQt::red, 1) );
p.setWidth( -1 ); // -1 means the default width for the object being
@@ -685,7 +685,7 @@ void PolygonBCVConstructor::handlePrelim(
text = TextImp( TQString( "(%1)" ).arg(i), where, false );
text.draw( p );
}
- p.setStyle( Qt::DotLine );
+ p.setStyle( TQt::DotLine );
p.setWidth( 1 );
double radius = ( v - c ).length();
CircleImp circle = CircleImp( c, radius );
@@ -803,7 +803,7 @@ void PolygonBCVConstructor::drawprelim( const ObjectDrawer& drawer, KigPainter&
Args args;
std::transform( parents.begin(), parents.end(),
- std::back_inserter( args ), std::mem_fun( &ObjectCalcer::imp ) );
+ std::back_inserter( args ), std::mem_fn( &ObjectCalcer::imp ) );
ObjectImp* data = mtype->calc( args, doc );
drawer.draw( *data, p, true );
@@ -1178,7 +1178,7 @@ void MeasureTransportConstructor::handlePrelim(
const KigDocument& d, const KigWidget&
) const
{
- p.setBrushStyle( Qt::NoBrush );
+ p.setBrushStyle( TQt::NoBrush );
p.setBrushColor( TQt::red );
p.setPen( TQPen ( TQt::red, 1) );
p.setWidth( -1 ); // -1 means the default width for the object being
@@ -1196,7 +1196,7 @@ void MeasureTransportConstructor::drawprelim( const ObjectDrawer& drawer,
Args args;
using namespace std;
transform( parents.begin(), parents.end(),
- back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
+ back_inserter( args ), mem_fn( &ObjectCalcer::imp ) );
ObjectImp* data = mtype->calc( args, doc );
drawer.draw( *data, p, true );
delete data;
diff --git a/kig/modes/construct_mode.cpp b/kig/modes/construct_mode.cpp
index 02bb98fc..378fc999 100644
--- a/kig/modes/construct_mode.cpp
+++ b/kig/modes/construct_mode.cpp
@@ -182,7 +182,7 @@ void BaseConstructMode::mouseMoved( const std::vector<ObjectHolder*>& os, const
mdoc.emitStatusBarText( selectStatement( getCalcers( mparents ), w ) );
w.updateCurPix();
- KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
+ KigPainter pter( w.screenInfo(), &w.curPix, mdoc.document() );
Coordinate ncoord = w.fromScreen( p );
if ( shiftpressed )
@@ -330,7 +330,7 @@ void PointConstructMode::mouseMoved(
bool shiftpressed )
{
w.updateCurPix();
- KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
+ KigPainter pter( w.screenInfo(), &w.curPix, mdoc.document() );
Coordinate ncoord = w.fromScreen( p );
if ( shiftpressed )
@@ -423,7 +423,7 @@ void TestConstructMode::handlePrelim( const std::vector<ObjectCalcer*>& os, cons
{
Args args;
std::transform( os.begin(), os.end(), std::back_inserter( args ),
- std::mem_fun( &ObjectCalcer::imp ) );
+ std::mem_fn( &ObjectCalcer::imp ) );
// usetext
TQString usetext = i18n( mtype->argsParser().usetext( args.back(), args ).c_str() );
@@ -529,7 +529,7 @@ void TestConstructMode::mouseMoved( const std::vector<ObjectHolder*>& os, const
w.setCursor( KCursor::blankCursor() );
w.updateCurPix();
- KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
+ KigPainter pter( w.screenInfo(), &w.curPix, mdoc.document() );
TQPoint qloc = p + TQPoint( -40, 0 );
Coordinate loc = w.fromScreen( qloc );
@@ -554,7 +554,7 @@ TQString TestConstructMode::selectStatement( const std::vector<ObjectCalcer*>& s
{
using namespace std;
Args args;
- transform( sel.begin(), sel.end(), back_inserter( args ), mem_fun( &ObjectCalcer::imp ) );
+ transform( sel.begin(), sel.end(), back_inserter( args ), mem_fn( &ObjectCalcer::imp ) );
std::string ret = mtype->argsParser().selectStatement( args );
if ( ret.empty() ) return TQString();
diff --git a/kig/modes/dragrectmode.cpp b/kig/modes/dragrectmode.cpp
index 29b00886..1bb39cae 100644
--- a/kig/modes/dragrectmode.cpp
+++ b/kig/modes/dragrectmode.cpp
@@ -48,7 +48,7 @@ void DragRectMode::moved( const TQPoint& p, KigWidget& w )
std::vector<TQRect> overlay;
if ( mstartselected )
{
- KigPainter pt( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
+ KigPainter pt( w.screenInfo(), &w.curPix, mdoc.document() );
pt.drawFilledRect( TQRect( p, mstart ) );
overlay = pt.overlay();
};
diff --git a/kig/modes/edittype.cpp b/kig/modes/edittype.cpp
index 00686392..75ba9ca3 100644
--- a/kig/modes/edittype.cpp
+++ b/kig/modes/edittype.cpp
@@ -50,7 +50,7 @@ EditType::~EditType()
void EditType::helpSlot()
{
- kapp->invokeHelp( TQString::fromLatin1( "working-with-types" ),
+ tdeApp->invokeHelp( TQString::fromLatin1( "working-with-types" ),
TQString::fromLatin1( "kig" ) );
}
diff --git a/kig/modes/edittype.h b/kig/modes/edittype.h
index 28e2353d..41c19f88 100644
--- a/kig/modes/edittype.h
+++ b/kig/modes/edittype.h
@@ -27,7 +27,7 @@
*/
class EditType : public EditTypeBase
{
- Q_OBJECT
+ TQ_OBJECT
TQString mname;
diff --git a/kig/modes/edittypebase.ui b/kig/modes/edittypebase.ui
index c0ed56cf..f8078404 100644
--- a/kig/modes/edittypebase.ui
+++ b/kig/modes/edittypebase.ui
@@ -270,11 +270,11 @@
<slot>cancelSlot()</slot>
</connection>
</connections>
-<Q_SLOTS>
+<slots>
<slot>helpSlot()</slot>
<slot>okSlot()</slot>
<slot>cancelSlot()</slot>
-</Q_SLOTS>
+</slots>
<layoutdefaults spacing="6" margin="11"/>
<includes>
<include location="global" impldecl="in implementation">klineedit.h</include>
diff --git a/kig/modes/label.cpp b/kig/modes/label.cpp
index 12f0d57c..73d26808 100644
--- a/kig/modes/label.cpp
+++ b/kig/modes/label.cpp
@@ -231,7 +231,7 @@ void TextLabelModeBase::mouseMoved( TQMouseEvent* e, KigWidget* w )
TQString s = d->locationparent->imp()->type()->attachToThisStatement();
mdoc.emitStatusBarText( s );
- KigPainter p( w->screenInfo(), TQT_TQPAINTDEVICE(&w->curPix), mdoc.document() );
+ KigPainter p( w->screenInfo(), &w->curPix, mdoc.document() );
// set the text next to the arrow cursor
TQPoint point = e->pos();
diff --git a/kig/modes/linkslabel.cpp b/kig/modes/linkslabel.cpp
index 9d37d840..19cb744d 100644
--- a/kig/modes/linkslabel.cpp
+++ b/kig/modes/linkslabel.cpp
@@ -67,8 +67,8 @@ LinksLabel::~LinksLabel()
void LinksLabel::urlClicked()
{
- const TQObject* o = TQT_TQOBJECT_CONST(const_cast<const TQT_BASE_OBJECT_NAME*>(sender()));
- std::vector<KURLLabel*>::iterator i = std::find( p->urllabels.begin(), p->urllabels.end(), static_cast<const KURLLabel*>(TQT_TQWIDGET_CONST( o )) );
+ const TQObject* o = sender();
+ std::vector<KURLLabel*>::iterator i = std::find( p->urllabels.begin(), p->urllabels.end(), static_cast<const KURLLabel*>( o ) );
assert( i != p->urllabels.end() );
emit linkClicked( i - p->urllabels.begin() );
}
@@ -112,7 +112,7 @@ void LinksLabel::applyEdit( LinksLabelEditBuf& buf )
i->second, this );
p->urllabels.push_back( l );
p->layout->addWidget( l );
- connect( l, TQT_SIGNAL( leftClickedURL() ), TQT_SLOT( urlClicked() ) );
+ connect( l, TQ_SIGNAL( leftClickedURL() ), TQ_SLOT( urlClicked() ) );
}
else
{
@@ -129,6 +129,6 @@ void LinksLabel::applyEdit( LinksLabelEditBuf& buf )
p->layout->activate();
- std::for_each( p->urllabels.begin(), p->urllabels.end(), mem_fun( &TQWidget::show ) );
- std::for_each( p->labels.begin(), p->labels.end(), mem_fun( &TQWidget::show ) );
+ std::for_each( p->urllabels.begin(), p->urllabels.end(), mem_fn( &TQWidget::show ) );
+ std::for_each( p->labels.begin(), p->labels.end(), mem_fn( &TQWidget::show ) );
}
diff --git a/kig/modes/linkslabel.h b/kig/modes/linkslabel.h
index a45777d5..cb556a70 100644
--- a/kig/modes/linkslabel.h
+++ b/kig/modes/linkslabel.h
@@ -29,7 +29,7 @@
*/
class LinksLabel : public TQWidget
{
- Q_OBJECT
+ TQ_OBJECT
public:
diff --git a/kig/modes/macro.cpp b/kig/modes/macro.cpp
index 8fe16b4d..be69d80b 100644
--- a/kig/modes/macro.cpp
+++ b/kig/modes/macro.cpp
@@ -94,11 +94,11 @@ void DefineMacroMode::namePageEntered()
std::vector<ObjectCalcer*> given;
std::transform( mgiven.begin(), mgiven.end(),
std::back_inserter( given ),
- std::mem_fun( memfun ) );
+ std::mem_fn( memfun ) );
std::vector<ObjectCalcer*> final;
std::transform( mfinal.begin(), mfinal.end(),
std::back_inserter( final ),
- std::mem_fun( memfun ) );
+ std::mem_fn( memfun ) );
ObjectHierarchy hier( given, final );
if ( hier.resultDoesNotDependOnGiven() )
{
@@ -132,11 +132,11 @@ void DefineMacroMode::finishPressed()
std::vector<ObjectCalcer*> given;
std::transform( mgiven.begin(), mgiven.end(),
std::back_inserter( given ),
- std::mem_fun( memfun ) );
+ std::mem_fn( memfun ) );
std::vector<ObjectCalcer*> final;
std::transform( mfinal.begin(), mfinal.end(),
std::back_inserter( final ),
- std::mem_fun( memfun ) );
+ std::mem_fn( memfun ) );
ObjectHierarchy hier( given, final );
MacroConstructor* ctor =
new MacroConstructor( hier,
@@ -167,7 +167,7 @@ void DefineMacroMode::dragRect( const TQPoint& p, KigWidget& w )
std::vector<ObjectHolder*>* objs = mwizard->currentPage() == mwizard->mpgiven ? &mgiven : &mfinal;
DragRectMode dm( p, mdoc, w );
mdoc.runMode( &dm );
- KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
+ KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
if ( ! dm.cancelled() )
{
std::vector<ObjectHolder*> ret = dm.ret();
@@ -196,7 +196,7 @@ void DefineMacroMode::leftClickedObject( ObjectHolder* o, const TQPoint&,
if ( isselected ) objs->erase( iter );
else objs->push_back( o );
- KigPainter p( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
+ KigPainter p( w.screenInfo(), &w.stillPix, mdoc.document() );
p.drawObject( o, !isselected );
w.updateCurPix( p.overlay() );
w.updateWidget();
@@ -224,7 +224,7 @@ void DefineMacroMode::mouseMoved( const std::vector<ObjectHolder*>& os, const TQ
// statusbar text
mdoc.emitStatusBarText( selectstat );
- KigPainter p( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
+ KigPainter p( w.screenInfo(), &w.curPix, mdoc.document() );
// set the text next to the arrow cursor
TQPoint point = pt;
diff --git a/kig/modes/macrowizard.cpp b/kig/modes/macrowizard.cpp
index c6b8f36c..3d1e598d 100644
--- a/kig/modes/macrowizard.cpp
+++ b/kig/modes/macrowizard.cpp
@@ -27,10 +27,10 @@
MacroWizard::MacroWizard( TQWidget* parent, DefineMacroMode* m )
: MacroWizardBase( parent, "Define Macro Wizard", false ), mmode( m )
{
- connect( KLineEdit2, TQT_SIGNAL( textChanged( const TQString& ) ),
- this, TQT_SLOT( nameTextChanged( const TQString& ) ) );
- connect( this, TQT_SIGNAL( helpClicked() ), this,
- TQT_SLOT( slotHelpClicked() ) );
+ connect( KLineEdit2, TQ_SIGNAL( textChanged( const TQString& ) ),
+ this, TQ_SLOT( nameTextChanged( const TQString& ) ) );
+ connect( this, TQ_SIGNAL( helpClicked() ), this,
+ TQ_SLOT( slotHelpClicked() ) );
}
MacroWizard::~MacroWizard()
@@ -85,6 +85,6 @@ void MacroWizard::accept()
void MacroWizard::slotHelpClicked()
{
- kapp->invokeHelp( TQString::fromLatin1( "defining-macros"),
+ tdeApp->invokeHelp( TQString::fromLatin1( "defining-macros"),
TQString::fromLatin1( "kig" ) );
}
diff --git a/kig/modes/macrowizard.h b/kig/modes/macrowizard.h
index ebd4c519..acb67b5f 100644
--- a/kig/modes/macrowizard.h
+++ b/kig/modes/macrowizard.h
@@ -24,7 +24,7 @@ class DefineMacroMode;
class MacroWizard : public MacroWizardBase
{
- Q_OBJECT
+ TQ_OBJECT
public:
MacroWizard( TQWidget* parent, DefineMacroMode* m );
diff --git a/kig/modes/moving.cpp b/kig/modes/moving.cpp
index 593c7077..d7d07e89 100644
--- a/kig/modes/moving.cpp
+++ b/kig/modes/moving.cpp
@@ -55,13 +55,13 @@ void MovingModeBase::initScreen( const std::vector<ObjectCalcer*>& in )
std::inserter( notmovingobjs, notmovingobjs.begin() ) );
mview.clearStillPix();
- KigPainter p( mview.screenInfo(), TQT_TQPAINTDEVICE(&mview.stillPix), mdoc.document() );
+ KigPainter p( mview.screenInfo(), &mview.stillPix, mdoc.document() );
p.drawGrid( mdoc.document().coordinateSystem(), mdoc.document().grid(),
mdoc.document().axes() );
p.drawObjects( notmovingobjs.begin(), notmovingobjs.end(), false );
mview.updateCurPix();
- KigPainter p2( mview.screenInfo(), TQT_TQPAINTDEVICE(&mview.curPix), mdoc.document() );
+ KigPainter p2( mview.screenInfo(), &mview.curPix, mdoc.document() );
p2.drawObjects( drawableset.begin(), drawableset.end(), true );
}
@@ -91,7 +91,7 @@ void MovingModeBase::mouseMoved( TQMouseEvent* e, KigWidget* v )
for ( std::vector<ObjectCalcer*>::iterator i = mcalcable.begin();
i != mcalcable.end(); ++i )
( *i )->calc( mdoc.document() );
- KigPainter p( v->screenInfo(), TQT_TQPAINTDEVICE(&v->curPix), mdoc.document() );
+ KigPainter p( v->screenInfo(), &v->curPix, mdoc.document() );
// TODO: only draw the explicitly moving objects as selected, the
// other ones as deselected.. Needs some support from the
// subclasses..
diff --git a/kig/modes/normal.cpp b/kig/modes/normal.cpp
index 9a30c213..b91db417 100644
--- a/kig/modes/normal.cpp
+++ b/kig/modes/normal.cpp
@@ -71,8 +71,8 @@ void NormalMode::selectObjects( const std::vector<ObjectHolder*>& os )
{
// hehe, don't you love this c++ stuff ;)
std::for_each( os.begin(), os.end(),
- std::bind1st(
- std::mem_fun( &NormalMode::selectObject ), this ) );
+ std::bind(
+ std::mem_fn( &NormalMode::selectObject ), this, std::placeholders::_1 ) );
}
void NormalMode::unselectObject( ObjectHolder* o )
@@ -133,7 +133,7 @@ void NormalMode::dragRect( const TQPoint& p, KigWidget& w )
DragRectMode d( p, mdoc, w );
mdoc.runMode( &d );
- KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
+ KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
if ( ! d.cancelled() )
{
@@ -174,7 +174,7 @@ void NormalMode::dragObject( const std::vector<ObjectHolder*>& oco, const TQPoin
void NormalMode::leftClickedObject( ObjectHolder* o, const TQPoint&,
KigWidget& w, bool ctrlOrShiftDown )
{
- KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
+ KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
if ( ! o )
{
@@ -269,7 +269,7 @@ void NormalMode::mouseMoved( const std::vector<ObjectHolder*>& os,
// statusbar text
mdoc.emitStatusBarText( stat );
- KigPainter p( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
+ KigPainter p( w.screenInfo(), &w.curPix, mdoc.document() );
// set the text next to the arrow cursor
TQPoint point = plc;
diff --git a/kig/modes/popup.cpp b/kig/modes/popup.cpp
index 05dc5d24..0a7e0265 100644
--- a/kig/modes/popup.cpp
+++ b/kig/modes/popup.cpp
@@ -190,7 +190,7 @@ NormalModePopupObjects::NormalModePopupObjects( KigPart& part,
{
bool empty = objs.empty();
bool single = objs.size() == 1;
- connect( this, TQT_SIGNAL( activated( int ) ), this, TQT_SLOT( toplevelMenuSlot( int ) ) );
+ connect( this, TQ_SIGNAL( activated( int ) ), this, TQ_SLOT( toplevelMenuSlot( int ) ) );
TQString title;
if ( empty )
@@ -246,24 +246,24 @@ NormalModePopupObjects::NormalModePopupObjects( KigPart& part,
for ( uint i = 0; i < NumberOfMenus; ++i )
mmenus[i] = new TQPopupMenu( this );
- connect( mmenus[TransformMenu], TQT_SIGNAL( activated( int ) ),
- this, TQT_SLOT( transformMenuSlot( int ) ) );
- connect( mmenus[TestMenu], TQT_SIGNAL( activated( int ) ),
- this, TQT_SLOT( testMenuSlot( int ) ) );
- connect( mmenus[ConstructMenu], TQT_SIGNAL( activated( int ) ),
- this, TQT_SLOT( constructMenuSlot( int ) ) );
- connect( mmenus[StartMenu], TQT_SIGNAL( activated( int ) ),
- this, TQT_SLOT( startMenuSlot( int ) ) );
- connect( mmenus[ShowMenu], TQT_SIGNAL( activated( int ) ),
- this, TQT_SLOT( showMenuSlot( int ) ) );
- connect( mmenus[SetColorMenu], TQT_SIGNAL( activated( int ) ),
- this, TQT_SLOT( setColorMenuSlot( int ) ) );
- connect( mmenus[SetSizeMenu], TQT_SIGNAL( activated( int ) ),
- this, TQT_SLOT( setSizeMenuSlot( int ) ) );
- connect( mmenus[SetStyleMenu], TQT_SIGNAL( activated( int ) ),
- this, TQT_SLOT( setStyleMenuSlot( int ) ) );
- connect( mmenus[SetCoordinateSystemMenu], TQT_SIGNAL( activated( int ) ),
- this, TQT_SLOT( setCoordinateSystemMenuSlot( int ) ) );
+ connect( mmenus[TransformMenu], TQ_SIGNAL( activated( int ) ),
+ this, TQ_SLOT( transformMenuSlot( int ) ) );
+ connect( mmenus[TestMenu], TQ_SIGNAL( activated( int ) ),
+ this, TQ_SLOT( testMenuSlot( int ) ) );
+ connect( mmenus[ConstructMenu], TQ_SIGNAL( activated( int ) ),
+ this, TQ_SLOT( constructMenuSlot( int ) ) );
+ connect( mmenus[StartMenu], TQ_SIGNAL( activated( int ) ),
+ this, TQ_SLOT( startMenuSlot( int ) ) );
+ connect( mmenus[ShowMenu], TQ_SIGNAL( activated( int ) ),
+ this, TQ_SLOT( showMenuSlot( int ) ) );
+ connect( mmenus[SetColorMenu], TQ_SIGNAL( activated( int ) ),
+ this, TQ_SLOT( setColorMenuSlot( int ) ) );
+ connect( mmenus[SetSizeMenu], TQ_SIGNAL( activated( int ) ),
+ this, TQ_SLOT( setSizeMenuSlot( int ) ) );
+ connect( mmenus[SetStyleMenu], TQ_SIGNAL( activated( int ) ),
+ this, TQ_SLOT( setStyleMenuSlot( int ) ) );
+ connect( mmenus[SetCoordinateSystemMenu], TQ_SIGNAL( activated( int ) ),
+ this, TQ_SLOT( setCoordinateSystemMenuSlot( int ) ) );
for ( int i = 0; i <= NumberOfMenus; ++i )
{
@@ -470,23 +470,23 @@ void BuiltinObjectActionsProvider::fillUpMenu( NormalModePopupObjects& popup, in
TQPixmap p( 20, 20 );
p.fill( popup.eraseColor() );
ScreenInfo si( Rect( -1, -1, 2, 2 ), p.rect() );
- KigPainter ptr( si, TQT_TQPAINTDEVICE(&p), popup.part().document(), false );
+ KigPainter ptr( si, &p, popup.part().document(), false );
PointImp pt( Coordinate( 0, 0 ) );
- ObjectDrawer d( color, -1, true, Qt::SolidLine, i );
+ ObjectDrawer d( color, -1, true, TQt::SolidLine, i );
d.draw( pt, ptr, false );
popup.addAction( menu, p, nextfree++ );
}
else
{
- Qt::PenStyle penstyles[] = {Qt::SolidLine, Qt::DashLine, Qt::DashDotLine, Qt::DashDotDotLine, Qt::DotLine};
- for ( int i = 0; i < (int) ( sizeof( penstyles ) / sizeof( Qt::PenStyle ) ); ++i )
+ TQt::PenStyle penstyles[] = {TQt::SolidLine, TQt::DashLine, TQt::DashDotLine, TQt::DashDotDotLine, TQt::DotLine};
+ for ( int i = 0; i < (int) ( sizeof( penstyles ) / sizeof( TQt::PenStyle ) ); ++i )
{
TQPixmap p( 50, 20 );
p.fill( popup.eraseColor() );
ScreenInfo si( Rect( -2.5, -1, 5, 2 ), p.rect() );
- KigPainter ptr( si, TQT_TQPAINTDEVICE(&p), popup.part().document(), false );
+ KigPainter ptr( si, &p, popup.part().document(), false );
LineImp line( Coordinate( -1, 0 ), Coordinate( 1, 0 ) );
- Qt::PenStyle ps = penstyles[i];
+ TQt::PenStyle ps = penstyles[i];
ObjectDrawer d( color, -1, true, ps, 1 );
d.draw( line, ptr, false );
popup.addAction( menu, p, nextfree++ );
@@ -712,9 +712,9 @@ bool BuiltinObjectActionsProvider::executeAction(
}
else
{
- Qt::PenStyle penstyles[] = {Qt::SolidLine, Qt::DashLine, Qt::DashDotLine, Qt::DashDotDotLine, Qt::DotLine};
- assert( id < (int)( sizeof( penstyles ) / sizeof( Qt::PenStyle ) ) );
- Qt::PenStyle p = penstyles[id];
+ TQt::PenStyle penstyles[] = {TQt::SolidLine, TQt::DashLine, TQt::DashDotLine, TQt::DashDotDotLine, TQt::DotLine};
+ assert( id < (int)( sizeof( penstyles ) / sizeof( TQt::PenStyle ) ) );
+ TQt::PenStyle p = penstyles[id];
KigCommand* kc = new KigCommand( doc, i18n( "Change Object Style" ) );
for ( std::vector<ObjectHolder*>::const_iterator i = os.begin(); i != os.end(); ++i )
if ( ! (*i)->imp()->inherits( PointImp::stype() ) )
@@ -1187,7 +1187,7 @@ ObjectChooserPopup::ObjectChooserPopup( const TQPoint& p, KigWidget& view,
i );
}
- connect( this, TQT_SIGNAL( activated( int ) ), this, TQT_SLOT( actionActivatedSlot( int ) ) );
+ connect( this, TQ_SIGNAL( activated( int ) ), this, TQ_SLOT( actionActivatedSlot( int ) ) );
}
ObjectChooserPopup::~ObjectChooserPopup()
diff --git a/kig/modes/popup.h b/kig/modes/popup.h
index 16078c15..5ba95428 100644
--- a/kig/modes/popup.h
+++ b/kig/modes/popup.h
@@ -46,7 +46,7 @@ class ObjectHolder;
class NormalModePopupObjects
: public TDEPopupMenu
{
- Q_OBJECT
+ TQ_OBJECT
public:
@@ -117,7 +117,7 @@ private:
class ObjectChooserPopup
: public TDEPopupMenu
{
- Q_OBJECT
+ TQ_OBJECT
public:
diff --git a/kig/modes/textlabelwizard.cpp b/kig/modes/textlabelwizard.cpp
index c92068de..f52e9bb0 100644
--- a/kig/modes/textlabelwizard.cpp
+++ b/kig/modes/textlabelwizard.cpp
@@ -29,12 +29,12 @@
TextLabelWizard::TextLabelWizard( TQWidget* parent, TextLabelModeBase* mode )
: TextLabelWizardBase( parent, "TextLabelWizard", false ), mmode( mode )
{
- connect( labelTextInput, TQT_SIGNAL( textChanged() ),
- TQT_SLOT( textChanged() ) );
- connect( myCustomWidget1, TQT_SIGNAL( linkClicked( int ) ),
- TQT_SLOT( linkClicked( int ) ) );
- connect( this, TQT_SIGNAL( helpClicked() ),
- this, TQT_SLOT( slotHelpClicked() ) );
+ connect( labelTextInput, TQ_SIGNAL( textChanged() ),
+ TQ_SLOT( textChanged() ) );
+ connect( myCustomWidget1, TQ_SIGNAL( linkClicked( int ) ),
+ TQ_SLOT( linkClicked( int ) ) );
+ connect( this, TQ_SIGNAL( helpClicked() ),
+ this, TQ_SLOT( slotHelpClicked() ) );
labelTextInput->setFocus();
}
@@ -89,7 +89,7 @@ void TextLabelWizard::relayoutArgsPage()
void TextLabelWizard::slotHelpClicked()
{
- kapp->invokeHelp( TQString::fromLatin1( "text-labels" ),
+ tdeApp->invokeHelp( TQString::fromLatin1( "text-labels" ),
TQString::fromLatin1( "kig" ) );
}
diff --git a/kig/modes/textlabelwizard.h b/kig/modes/textlabelwizard.h
index 5e22ada2..f586b62f 100644
--- a/kig/modes/textlabelwizard.h
+++ b/kig/modes/textlabelwizard.h
@@ -24,7 +24,7 @@ class TextLabelModeBase;
class TextLabelWizard : public TextLabelWizardBase
{
- Q_OBJECT
+ TQ_OBJECT
public:
TextLabelWizard( TQWidget* parent, TextLabelModeBase* mode );
diff --git a/kig/modes/typesdialog.cpp b/kig/modes/typesdialog.cpp
index d8219308..0c3609c5 100644
--- a/kig/modes/typesdialog.cpp
+++ b/kig/modes/typesdialog.cpp
@@ -81,10 +81,10 @@ TypesDialog::TypesDialog( TQWidget* parent, KigPart& part )
loadAllMacros();
popup = new TQPopupMenu( this );
- popup->insertItem( SmallIcon( "edit" ), i18n( "&Edit..." ), this, TQT_SLOT( editType() ) );
- popup->insertItem( SmallIcon( "edit-delete" ), i18n( "&Delete" ), this, TQT_SLOT( deleteType() ) );
+ popup->insertItem( SmallIcon( "edit" ), i18n( "&Edit..." ), this, TQ_SLOT( editType() ) );
+ popup->insertItem( SmallIcon( "edit-delete" ), i18n( "&Delete" ), this, TQ_SLOT( deleteType() ) );
popup->insertSeparator();
- popup->insertItem( SmallIcon( "fileexport" ), i18n( "E&xport..." ), this, TQT_SLOT( exportType() ) );
+ popup->insertItem( SmallIcon( "fileexport" ), i18n( "E&xport..." ), this, TQ_SLOT( exportType() ) );
// saving types
part.saveTypes();
@@ -108,7 +108,7 @@ TypesDialog::~TypesDialog()
void TypesDialog::helpSlot()
{
- kapp->invokeHelp( TQString::fromLatin1( "working-with-types" ),
+ tdeApp->invokeHelp( TQString::fromLatin1( "working-with-types" ),
TQString::fromLatin1( "kig" ) );
}
diff --git a/kig/modes/typesdialog.h b/kig/modes/typesdialog.h
index 636999c5..6afb40f1 100644
--- a/kig/modes/typesdialog.h
+++ b/kig/modes/typesdialog.h
@@ -38,7 +38,7 @@ class KigDocument;
*/
class TypesDialog : public TypesDialogBase
{
- Q_OBJECT
+ TQ_OBJECT
// necessary because some MacroList functions need it..
diff --git a/kig/modes/typesdialogbase.ui b/kig/modes/typesdialogbase.ui
index bea69868..5aa9f34b 100644
--- a/kig/modes/typesdialogbase.ui
+++ b/kig/modes/typesdialogbase.ui
@@ -316,7 +316,7 @@
<forwards>
<forward>class TQListViewItem;</forward>
</forwards>
-<Q_SLOTS>
+<slots>
<slot access="protected">deleteType()</slot>
<slot access="protected">exportType()</slot>
<slot>helpSlot()</slot>
@@ -325,7 +325,7 @@
<slot access="protected">editType()</slot>
<slot access="protected">contextMenuRequested( TQListViewItem* i, const TQPoint&amp; p, int c )</slot>
<slot>cancelSlot()</slot>
-</Q_SLOTS>
+</slots>
<layoutdefaults spacing="6" margin="11"/>
<includes>
<include location="global" impldecl="in implementation">kpushbutton.h</include>
diff --git a/kig/objects/object_calcer.cpp b/kig/objects/object_calcer.cpp
index 40545ed1..b15766bc 100644
--- a/kig/objects/object_calcer.cpp
+++ b/kig/objects/object_calcer.cpp
@@ -31,7 +31,7 @@ void ObjectTypeCalcer::calc( const KigDocument& doc )
Args a;
a.reserve( mparents.size() );
std::transform( mparents.begin(), mparents.end(),
- std::back_inserter( a ), std::mem_fun( &ObjectCalcer::imp ) );
+ std::back_inserter( a ), std::mem_fn( &ObjectCalcer::imp ) );
ObjectImp* n = mtype->calc( a, doc );
delete mimp;
mimp = n;
@@ -42,7 +42,7 @@ ObjectTypeCalcer::ObjectTypeCalcer( const ObjectType* type,
: mparents( ( sort )?type->sortArgs( parents ):parents ), mtype( type ), mimp( 0 )
{
std::for_each( mparents.begin(), mparents.end(),
- std::bind2nd( std::mem_fun( &ObjectCalcer::addChild ), this ) );
+ std::bind( std::mem_fn( &ObjectCalcer::addChild ), std::placeholders::_1, this ) );
}
ObjectCalcer::~ObjectCalcer()
@@ -122,7 +122,7 @@ void ObjectCalcer::delChild( ObjectCalcer* c )
ObjectTypeCalcer::~ObjectTypeCalcer()
{
std::for_each( mparents.begin(), mparents.end(),
- std::bind2nd( std::mem_fun( &ObjectCalcer::delChild ), this ) );
+ std::bind( std::mem_fn( &ObjectCalcer::delChild ), std::placeholders::_1, this ) );
delete mimp;
}
@@ -201,7 +201,7 @@ const ObjectImpType* ObjectTypeCalcer::impRequirement(
std::transform(
os.begin(), os.end(),
std::back_inserter( args ),
- std::mem_fun( &ObjectCalcer::imp ) );
+ std::mem_fn( &ObjectCalcer::imp ) );
assert( std::find( args.begin(), args.end(), o->imp() ) != args.end() );
return mtype->impRequirement( o->imp(), args );
}
@@ -219,9 +219,9 @@ void ObjectConstCalcer::setImp( ObjectImp* newimp )
void ObjectTypeCalcer::setParents( const std::vector<ObjectCalcer*> np )
{
std::for_each( np.begin(), np.end(),
- std::bind2nd( std::mem_fun( &ObjectCalcer::addChild ), this ) );
+ std::bind( std::mem_fn( &ObjectCalcer::addChild ), std::placeholders::_1, this ) );
std::for_each( mparents.begin(), mparents.end(),
- std::bind2nd( std::mem_fun( &ObjectCalcer::delChild ), this ) );
+ std::bind( std::mem_fn( &ObjectCalcer::delChild ), std::placeholders::_1, this ) );
mparents = np;
}
@@ -314,7 +314,7 @@ bool ObjectTypeCalcer::isDefinedOnOrThrough( const ObjectCalcer* o ) const
std::transform(
mparents.begin(), mparents.end(),
std::back_inserter( args ),
- std::mem_fun( &ObjectCalcer::imp ) );
+ std::mem_fn( &ObjectCalcer::imp ) );
if ( std::find( args.begin(), args.end(), o->imp() ) == args.end() )
return false;
diff --git a/kig/objects/object_drawer.cpp b/kig/objects/object_drawer.cpp
index d6e41144..f1541f66 100644
--- a/kig/objects/object_drawer.cpp
+++ b/kig/objects/object_drawer.cpp
@@ -31,7 +31,7 @@ void ObjectDrawer::draw( const ObjectImp& imp, KigPainter& p, bool sel ) const
bool nv = p.getNightVision( );
if ( mshown || nv )
{
- p.setBrushStyle( Qt::NoBrush );
+ p.setBrushStyle( TQt::NoBrush );
p.setBrushColor( sel ? TQt::red : ( mshown?mcolor:TQt::gray ) );
p.setPen( TQPen ( sel ? TQt::red : ( mshown?mcolor:TQt::gray ), 1) );
p.setWidth( mwidth );
@@ -90,7 +90,7 @@ ObjectDrawer* ObjectDrawer::getCopyWidth( int w ) const
return ret;
}
-ObjectDrawer* ObjectDrawer::getCopyStyle( Qt::PenStyle s ) const
+ObjectDrawer* ObjectDrawer::getCopyStyle( TQt::PenStyle s ) const
{
ObjectDrawer* ret = new ObjectDrawer;
ret->mcolor = mcolor;
@@ -117,7 +117,7 @@ int ObjectDrawer::width() const
return mwidth;
}
-Qt::PenStyle ObjectDrawer::style() const
+TQt::PenStyle ObjectDrawer::style() const
{
return mstyle;
}
@@ -127,13 +127,13 @@ int ObjectDrawer::pointStyle() const
return mpointstyle;
}
-ObjectDrawer::ObjectDrawer( const TQColor& color, int width, bool shown, Qt::PenStyle style, int pointStyle )
+ObjectDrawer::ObjectDrawer( const TQColor& color, int width, bool shown, TQt::PenStyle style, int pointStyle )
: mcolor( color ), mshown( shown ), mwidth( width ), mstyle( style ), mpointstyle( pointStyle )
{
}
ObjectDrawer::ObjectDrawer()
- : mcolor( TQt::blue ), mshown( true ), mwidth( -1 ), mstyle( Qt::SolidLine ), mpointstyle( 0 )
+ : mcolor( TQt::blue ), mshown( true ), mwidth( -1 ), mstyle( TQt::SolidLine ), mpointstyle( 0 )
{
}
@@ -173,19 +173,19 @@ TQString ObjectDrawer::pointStyleToString() const
return TQString();
}
-Qt::PenStyle ObjectDrawer::styleFromString( const TQString& style )
+TQt::PenStyle ObjectDrawer::styleFromString( const TQString& style )
{
if ( style == "SolidLine" )
- return Qt::SolidLine;
+ return TQt::SolidLine;
else if ( style == "DashLine" )
- return Qt::DashLine;
+ return TQt::DashLine;
else if ( style == "DotLine" )
- return Qt::DotLine;
+ return TQt::DotLine;
else if ( style == "DashDotLine" )
- return Qt::DashDotLine;
+ return TQt::DashDotLine;
else if ( style == "DashDotDotLine" )
- return Qt::DashDotDotLine;
- else return Qt::SolidLine;
+ return TQt::DashDotDotLine;
+ else return TQt::SolidLine;
}
TQString ObjectDrawer::styleToString() const
diff --git a/kig/objects/object_drawer.h b/kig/objects/object_drawer.h
index cbd1374a..b5336a06 100644
--- a/kig/objects/object_drawer.h
+++ b/kig/objects/object_drawer.h
@@ -48,7 +48,7 @@ class ObjectDrawer
TQColor mcolor;
bool mshown;
int mwidth;
- Qt::PenStyle mstyle;
+ TQt::PenStyle mstyle;
int mpointstyle;
public:
/**
@@ -57,7 +57,7 @@ public:
* and pointstyle ( 0 )
*/
ObjectDrawer();
- ObjectDrawer( const TQColor& color, int width = -1, bool shown = true, Qt::PenStyle = Qt::SolidLine, int pointStyle = 0 );
+ ObjectDrawer( const TQColor& color, int width = -1, bool shown = true, TQt::PenStyle = TQt::SolidLine, int pointStyle = 0 );
/**
* Draw the object \p imp on kigpainter \p p . If \p selected is true, it is
* drawn in red, otherwise in its normal color.
@@ -91,7 +91,7 @@ public:
/**
* return PenStyle for all objects except points
*/
- Qt::PenStyle style() const;
+ TQt::PenStyle style() const;
/**
* return pointStyle for points
*/
@@ -123,7 +123,7 @@ public:
* returns a new ObjectDrawer that is identical to this one.. except
* that the PenStyle state is set to \p s ..
*/
- ObjectDrawer* getCopyStyle( Qt::PenStyle s ) const;
+ ObjectDrawer* getCopyStyle( TQt::PenStyle s ) const;
/**
* returns a new ObjectDrawer that is identical to this one.. except
* that the pointStyle state is set to \p p ..
@@ -140,7 +140,7 @@ public:
* given \p style string is unknown. In that case it returns a default
* value.
*/
- static Qt::PenStyle styleFromString( const TQString& style );
+ static TQt::PenStyle styleFromString( const TQString& style );
};
#endif
diff --git a/kig/objects/object_factory.cpp b/kig/objects/object_factory.cpp
index bf333094..7235e834 100644
--- a/kig/objects/object_factory.cpp
+++ b/kig/objects/object_factory.cpp
@@ -296,7 +296,7 @@ void ObjectFactory::redefinePoint(
std::vector<ObjectCalcer*> os;
ObjectCalcer* (ObjectHolder::*calcmeth)() = &ObjectHolder::calcer;
std::transform( hos.begin(), hos.end(), std::back_inserter( os ),
- std::mem_fun( calcmeth ) );
+ std::mem_fn( calcmeth ) );
ObjectCalcer* v = 0;
// we don't want one of our children as a parent...
diff --git a/kig/objects/text_type.cpp b/kig/objects/text_type.cpp
index c82c2047..05d564ff 100644
--- a/kig/objects/text_type.cpp
+++ b/kig/objects/text_type.cpp
@@ -144,7 +144,7 @@ void TextType::executeAction( int i, ObjectHolder& o, ObjectTypeCalcer& c,
if ( i == 0 )
{
- TQClipboard* cb = kapp->clipboard();
+ TQClipboard* cb = tdeApp->clipboard();
// copy the text into the clipboard
const TextImp* ti = static_cast<const TextImp*>( c.imp() );
diff --git a/kig/pykig/pykig.py b/kig/pykig/pykig.py
index 106c8a0c..50cd5f2b 100755
--- a/kig/pykig/pykig.py
+++ b/kig/pykig/pykig.py
@@ -6,7 +6,7 @@
# #
#--Maurizio Paolini-Daniele Zambelli-----------------------------2005---#
#
-# (licenza GPL)
+# (GPL license)
version="0.2.11"
@@ -112,18 +112,18 @@ def kig_relpoint(obj, displ):
#####
#####
-# Classe KigDocument
+# Class KigDocument
#####
class KigDocument(object):
- """ Classe che produce il documento kig.
+ """ This class creates the kig document.
- genealogia:
+ hierarchy:
KigDocument <- object
- attributi di classe:
+ class attributes:
- attributi:
+ attributes:
axes
grid
outfilename
@@ -140,7 +140,7 @@ class KigDocument(object):
shown
color
- metodi:
+ methods:
viewappend
hierarchyappend
setcallkig
@@ -234,24 +234,24 @@ class KigDocument(object):
def setinternal(self, v): self.internal=v
#####
-# Classe KigDOP
+# Class KigDOP
#####
#class KigDOP(KigOut):
class KigDOP(object):
- """Classe da cui deriva ogni elemento che ha un id: Data, Object, Property.
+ """Base class for all object containing an id: Data, Object, Property.
- genealogia:
+ hierarchy:
kigDOP <- object
- attributo di classe:
+ class attributes:
id-counter
- attributi:
+ attributes:
id
type
- metodi:
+ methods:
getid
str_hierarchy
"""
@@ -269,20 +269,20 @@ class KigDOP(object):
def str_hierarchy(self): pass
#####
-# Classe KigView
+# Class KigView
#####
#class KigView(KigOut):
class KigView(object):
- """ Classe con i dati di visualizzazione
+ """ Class containing visualization data
- genealogia:
+ hierarchy:
KigView <- object
- attributi di classe:
+ class attributes:
_kd
- attributi:
+ attributes:
shown
width
style
@@ -290,7 +290,7 @@ class KigView(object):
name
pointstyle
- metodi:
+ methods:
str_view
show
hide
@@ -308,9 +308,9 @@ class KigView(object):
KigView._kd.viewappend(self)
def str_view(self):
- """Produce la stringa che viene scritta sotto <View>.
+ """Creates the string written in <View>.
- esempio:
+ Example:
<Draw width="-1" point-style="Round" namecalcer="none"
style="SolidLine" shown=None color="#0000ff" object="3" />
"""
@@ -321,19 +321,19 @@ style="SolidLine" shown=None color="#0000ff" object="3" />
self.linestyle, self.shown, self.color, self.object.getid())
#####
-# Classe Data
+# Class Data
#####
class Data(KigDOP):
- """ Classe da cui deriva ogni elemento Data
+ """ Base class for all Data element
- genealogia:
+ hierarchy:
Data <- KigDOP <- object
- attributi:
+ attributes:
val
- metodi:
+ methods:
str_hierarchy
"""
def __init__(self, type, val):
@@ -341,32 +341,32 @@ class Data(KigDOP):
KigDOP.__init__(self, type)
def str_hierarchy(self):
- """Produce la stringa che viene scritta sotto <Data>.
+ """Creates the <Data> string.
- esempio:
+ Example:
<Data type="double" id="170" >0.1</Data>
"""
return ' <Data type="%s" id="%s" >%s</Data>\n' % \
(self._type, self.getid(), self.val)
#####
-# Classe PropObj
+# Class PropObj
#####
class PropObj(KigDOP):
- """ Classe da cui deriva ogni elemento visibile
+ """ Base class for all visible object
- genealogia:
+ hierarchy:
PropObj <- KigDOP <- object
- attributi di classe:
+ class attributes:
- attributi:
+ attributes:
prop
objvec
view
- metodi:
+ methods:
str_hierarchy
showname(self, n)
show(self)
@@ -393,8 +393,7 @@ class PropObj(KigDOP):
if internal:
self.view = None
else:
-# Qui si assume che, se viene dato un nome ad un oggetto,
-# si voglia anche visualizzare questo nome
+# Here we assume that if an object is named, the name should also be shown.
if name: n_id=self.showname(name, shown, width, pointstyle, linestyle,
color)
else: n_id=None
@@ -402,14 +401,14 @@ class PropObj(KigDOP):
color)
def str_hierarchy(self):
- """Produce la stringa che viene scritta sotto <Data>.
+ """Creates the <Data> string.
- esempio:
+ Example:
<Property which="mid-point" id="170" >
<Parent id="..." />
</Property>
- oppure:
+ or:
<Object type="ConstrainedPoint" id="14" >
<Parent id="13" />
<Parent id="10" />
@@ -448,13 +447,13 @@ class PropObj(KigDOP):
def setshown(self, s): self.view.shown=s
#####
-# Classe Property
+# Class Property
#####
class Property(PropObj):
- """ Classe da cui deriva ogni elemento Property
+ """ Base class for all Property elements
- genealogia:
+ hierarchy:
Property <- PropObj <- KigDOP <- object
"""
def __init__(self, type, parent, shown, name, internal,
@@ -464,13 +463,13 @@ class Property(PropObj):
# print shown
#####
-# Classe Object
+# Class Object
#####
class Object(PropObj):
- """ Classe da cui deriva ogni elemento Oggetto
+ """ Base class for all Object elements
- genealogia:
+ hierarchy:
Object <- PropObj <- KigDOP <- object
"""
@@ -509,7 +508,7 @@ for d in data:
#####
# Objects
#####
-"""Da aggiungere:
+"""To be added:
("ConvexHall", "ConvexHall", "polygon,", "(polygon,),"),
("EllipseByFocusFocusPoint", "EllipseBFFP", "p1, p2, p3,", "(p1, p2, p3,),"),
("HyperbolaByFocusFocusPoint", "HyperbolaBFFP", "p1, p2, p3,", "(p1, p2, p3,),"),
@@ -547,28 +546,27 @@ objects=(\
#####
("LineLineIntersection", "LineLineIntersection", "l1, l2,", "(l1, l2),"),
#####
-# Classe CircleCircleIntersection e ConicLineIntersection
-# l'intero "which" puo' assumere i valori 1 o -1 per indicare quale
-# delle due intersezioni si desidera ottenere
-# si potrebbe mettere un controllo...
+# Class CircleCircleIntersection and ConicLineIntersection
+# the value of the "which" integer (1 or -1) indicates which of the two
+# intersections we want to get.
#####
("CircleCircleIntersection", "CircleCircleIntersection",
"c1, c2, witch,", "(c1, c2, Int(witch),),"),
("ConicLineIntersection", "ConicLineIntersection",
"conic, line, witch,", "(conic, line, Int(witch),),"),
-###### Classe Triangle
+###### Class Triangle
("Triangle", "TriangleB3P", "p1, p2, p3,", "(p1, p2, p3),"),
-###### Classe Polygon (the only argument is a points vect)
+###### Class Polygon (the only argument is a points vect)
("Polygon", "PolygonBNP", "pvec,", "pvec,"),
-###### Classe PolygonBCV
-# Poligono regolare dati il centro e un vertice; il terzo argomento
-# e' un intero contenente il numero di lati
+###### Class PolygonBCV
+# Regular polygon given the center and a vertex; the third parameter
+# is an integer containing the number of sides.
("PolygonBCV", "PoligonBCV",
"center, vertex, n,", "(center, vertex, Int(n)),"),
-##### Classe PolygonVertex (poligono, intero >= 0)
+##### Class PolygonVertex (polygon, integer >= 0)
("PolygonVertex", "PolygonVertex",
"polygon, i,", "(polygon, Int(i)),"),
-##### Classe PolygonSide (poligono, intero >= 0)
+##### Class PolygonSide (polygon, integer >= 0)
("PolygonSide", "PolygonSide",
"polygon, i,", "(polygon, Int(i)),"),
###### vector, angle,...
@@ -677,7 +675,7 @@ for p in property:
#####
# Start of properties definitions as Object's metod
#####
-# da sistemare!
+# fixme!
points =(Point, ConstrainedPoint, RelativePoint, PolygonVertex)
lines=(Segment, Ray, Vector, InvertLine)
segments=(Segment, Vector, PolygonSide, InvertSegment)
@@ -774,9 +772,9 @@ def prog():
elif _opt in ("-o", "--output"):
_outfilename=_arg
_of=True
- _callKig=False # se c'è il file di output, non viene chiamato Kig
+ _callKig=False # if the output filename is provided, don't call Kig
if len(_args)==0:
- _infilename=raw_input("Nome del file di input: ")
+ _infilename=raw_input("Input filename: ")
if not _infilename:
print "No Input filename"
usage(2)
@@ -803,7 +801,7 @@ def prog():
execfile(_infilename, globals())
except:
print >> sys.stderr, 'syntax error in', _infilename
- _info = sys.exc_info() # vorrei stampare il traceback...
+ _info = sys.exc_info() # print the traceback
traceback.print_exc()
sys.exit(3)
kigdocument.close()
diff --git a/kig/scripting/newscriptwizard.cpp b/kig/scripting/newscriptwizard.cpp
index 9cb4d9e2..0268b67c 100644
--- a/kig/scripting/newscriptwizard.cpp
+++ b/kig/scripting/newscriptwizard.cpp
@@ -97,11 +97,11 @@ NewScriptWizard::NewScriptWizard( TQWidget* parent, ScriptModeBase* mode )
TDEPopupMenu* pm = new TDEPopupMenu( editor );
// creating the actions for the code editor...
TDEActionCollection* ac = new TDEActionCollection( editor );
- TDEAction* undoAction = KStdAction::undo( TQT_TQOBJECT(this), TQT_SLOT( slotUndo() ), ac );
- TDEAction* redoAction = KStdAction::redo( TQT_TQOBJECT(this), TQT_SLOT( slotRedo() ), ac );
- TDEAction* cutAction = KStdAction::cut( TQT_TQOBJECT(this), TQT_SLOT( slotCut() ), ac );
- TDEAction* copyAction = KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT( slotCopy() ), ac );
- TDEAction* pasteAction = KStdAction::paste( TQT_TQOBJECT(this), TQT_SLOT( slotPaste() ), ac );
+ TDEAction* undoAction = KStdAction::undo( this, TQ_SLOT( slotUndo() ), ac );
+ TDEAction* redoAction = KStdAction::redo( this, TQ_SLOT( slotRedo() ), ac );
+ TDEAction* cutAction = KStdAction::cut( this, TQ_SLOT( slotCut() ), ac );
+ TDEAction* copyAction = KStdAction::copy( this, TQ_SLOT( slotCopy() ), ac );
+ TDEAction* pasteAction = KStdAction::paste( this, TQ_SLOT( slotPaste() ), ac );
// ... and plugging them into the popup menu (to build it, of course :) )
undoAction->plug( pm );
redoAction->plug( pm );
@@ -114,7 +114,7 @@ NewScriptWizard::NewScriptWizard( TQWidget* parent, ScriptModeBase* mode )
dynamic_cast<KTextEditor::PopupMenuInterface*>( editor )->installPopup( pm );
}
- connect( this, TQT_SIGNAL( helpClicked() ), this, TQT_SLOT( slotHelpClicked() ) );
+ connect( this, TQ_SIGNAL( helpClicked() ), this, TQ_SLOT( slotHelpClicked() ) );
}
void NewScriptWizard::back()
@@ -159,7 +159,7 @@ void NewScriptWizard::accept()
void NewScriptWizard::slotHelpClicked()
{
- kapp->invokeHelp( TQString::fromLatin1( "scripting" ),
+ tdeApp->invokeHelp( TQString::fromLatin1( "scripting" ),
TQString::fromLatin1( "kig" ) );
}
diff --git a/kig/scripting/newscriptwizard.h b/kig/scripting/newscriptwizard.h
index 6fa9d07f..ad0203d3 100644
--- a/kig/scripting/newscriptwizard.h
+++ b/kig/scripting/newscriptwizard.h
@@ -34,7 +34,7 @@ class ScriptModeBase;
class NewScriptWizard
: public NewScriptWizardBase
{
- Q_OBJECT
+ TQ_OBJECT
ScriptModeBase* mmode;
public:
diff --git a/kig/scripting/python_scripter.cpp b/kig/scripting/python_scripter.cpp
index 00c7e162..f39d7121 100644
--- a/kig/scripting/python_scripter.cpp
+++ b/kig/scripting/python_scripter.cpp
@@ -495,9 +495,9 @@ ObjectImp* PythonScripter::calc( CompiledPythonScript& script, const Args& args
};
tuple argstup( argstuph );
- handle<> reth( PyEval_CallObject( calcfunc.ptr(), argstup.ptr() ) );
+ handle<> reth( PyObject_CallObject( calcfunc.ptr(), argstup.ptr() ) );
// object resulto = calcfunc( argstup );
-// handle<> reth( PyEval_CallObject( calcfunc.ptr(), args ) );
+// handle<> reth( PyObject_CallObject( calcfunc.ptr(), args ) );
object resulto( reth );
extract<ObjectImp&> result( resulto );
diff --git a/kig/scripting/script_mode.cpp b/kig/scripting/script_mode.cpp
index 1fd88405..228ad739 100644
--- a/kig/scripting/script_mode.cpp
+++ b/kig/scripting/script_mode.cpp
@@ -45,7 +45,7 @@ void ScriptModeBase::dragRect( const TQPoint& p, KigWidget& w )
mdoc.runMode( &dm );
std::vector<ObjectHolder*> ret = dm.ret();
- KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
+ KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
if ( dm.needClear() )
{
std::vector<ObjectHolder*> tmp( margs.begin(), margs.begin() );
@@ -67,7 +67,7 @@ void ScriptModeBase::leftClickedObject( ObjectHolder* o, const TQPoint&,
if ( mwawd != SelectingArgs ) return;
- KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
+ KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
if ( (dup_o = std::find( margs.begin(), margs.end(), o )) != margs.end() )
{
@@ -105,7 +105,7 @@ void ScriptModeBase::mouseMoved( const std::vector<ObjectHolder*>& os,
// statusbar text
mdoc.emitStatusBarText( selectstat );
- KigPainter p( w.screenInfo(), TQT_TQPAINTDEVICE(&w.curPix), mdoc.document() );
+ KigPainter p( w.screenInfo(), &w.curPix, mdoc.document() );
// set the text next to the arrow cursor
TQPoint point = pt;
@@ -246,7 +246,7 @@ void ScriptModeBase::setScriptType( ScriptType::Type type )
void ScriptModeBase::addArgs( const std::vector<ObjectHolder*>& obj, KigWidget& w )
{
- KigPainter pter( w.screenInfo(), TQT_TQPAINTDEVICE(&w.stillPix), mdoc.document() );
+ KigPainter pter( w.screenInfo(), &w.stillPix, mdoc.document() );
std::copy( obj.begin(), obj.end(), std::inserter( margs, margs.begin() ) );
pter.drawObjects( obj, true );
diff --git a/kig/tdefile/Makefile.am b/kig/tdefile/Makefile.am
index ca77dc8e..59d1817d 100644
--- a/kig/tdefile/Makefile.am
+++ b/kig/tdefile/Makefile.am
@@ -9,11 +9,11 @@ kde_module_LTLIBRARIES = \
tdefile_kig.la
tdefile_drgeo_la_SOURCES = tdefile_drgeo.cpp
-tdefile_drgeo_la_LDFLAGS = $(all_libraries) $(LIB_QT) $(LIB_TDECORE) $(LIB_TDEUI) $(LIB_TDEIO) -module $(KDE_PLUGIN)
+tdefile_drgeo_la_LDFLAGS = $(all_libraries) $(LIB_TQT) $(LIB_TDECORE) $(LIB_TDEUI) $(LIB_TDEIO) -module $(KDE_PLUGIN)
tdefile_drgeo_la_LIBADD = $(LIB_TDEIO)
tdefile_kig_la_SOURCES = tdefile_kig.cpp
-tdefile_kig_la_LDFLAGS = $(all_libraries) $(LIB_QT) $(LIB_TDECORE) $(LIB_TDEUI) $(LIB_TDEIO) -module $(KDE_PLUGIN)
+tdefile_kig_la_LDFLAGS = $(all_libraries) $(LIB_TQT) $(LIB_TDECORE) $(LIB_TDEUI) $(LIB_TDEIO) -module $(KDE_PLUGIN)
tdefile_kig_la_LIBADD = $(LIB_TDEIO)
METASOURCES = AUTO
diff --git a/kig/tdefile/tdefile_drgeo.h b/kig/tdefile/tdefile_drgeo.h
index 1eca85fa..ba0e97bf 100644
--- a/kig/tdefile/tdefile_drgeo.h
+++ b/kig/tdefile/tdefile_drgeo.h
@@ -27,7 +27,7 @@ class TQStringList;
class DrgeoPlugin: public KFilePlugin
{
- Q_OBJECT
+ TQ_OBJECT
public:
diff --git a/kig/tdefile/tdefile_kig.cpp b/kig/tdefile/tdefile_kig.cpp
index a1294641..e2fc6645 100644
--- a/kig/tdefile/tdefile_kig.cpp
+++ b/kig/tdefile/tdefile_kig.cpp
@@ -28,7 +28,7 @@
#include <kgenericfactory.h>
#include <tdeglobal.h>
#include <tdelocale.h>
-#include <kstandarddirs.h>
+#include <tdestandarddirs.h>
#include <ktar.h>
typedef KGenericFactory<KigPlugin> kigFactory;
diff --git a/kig/tdefile/tdefile_kig.h b/kig/tdefile/tdefile_kig.h
index 087caf17..97c44479 100644
--- a/kig/tdefile/tdefile_kig.h
+++ b/kig/tdefile/tdefile_kig.h
@@ -27,7 +27,7 @@ class TQStringList;
class KigPlugin: public KFilePlugin
{
- Q_OBJECT
+ TQ_OBJECT
public: