summaryrefslogtreecommitdiffstats
path: root/src/gui/general
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-09-06 20:59:29 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-09-06 20:59:29 +0000
commit11f31c37e5fa4889d9989f10272f44845449cb7b (patch)
tree4383da04a76c497950d957fc6120b0fd0d9082c2 /src/gui/general
parent832eb69d571e8e518db45d0c0e6fbc0f00690209 (diff)
downloadrosegarden-11f31c37e5fa4889d9989f10272f44845449cb7b.tar.gz
rosegarden-11f31c37e5fa4889d9989f10272f44845449cb7b.zip
Initial TQt conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/rosegarden@1172292 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/gui/general')
-rw-r--r--src/gui/general/ActiveItem.h8
-rw-r--r--src/gui/general/BarLine.cpp14
-rw-r--r--src/gui/general/BarLine.h10
-rw-r--r--src/gui/general/BaseTool.cpp18
-rw-r--r--src/gui/general/BaseTool.h20
-rw-r--r--src/gui/general/BaseToolBox.cpp16
-rw-r--r--src/gui/general/BaseToolBox.h18
-rw-r--r--src/gui/general/CanvasCursor.cpp10
-rw-r--r--src/gui/general/CanvasCursor.h8
-rw-r--r--src/gui/general/CanvasItemGC.cpp6
-rw-r--r--src/gui/general/CanvasItemGC.h10
-rw-r--r--src/gui/general/CategoryElement.cpp6
-rw-r--r--src/gui/general/CategoryElement.h10
-rw-r--r--src/gui/general/ClefIndex.cpp2
-rw-r--r--src/gui/general/ClefIndex.h4
-rw-r--r--src/gui/general/EditTool.cpp28
-rw-r--r--src/gui/general/EditTool.h26
-rw-r--r--src/gui/general/EditToolBox.cpp8
-rw-r--r--src/gui/general/EditToolBox.h6
-rw-r--r--src/gui/general/EditView.cpp248
-rw-r--r--src/gui/general/EditView.h54
-rw-r--r--src/gui/general/EditViewBase.cpp120
-rw-r--r--src/gui/general/EditViewBase.h50
-rw-r--r--src/gui/general/GUIPalette.cpp130
-rw-r--r--src/gui/general/GUIPalette.h12
-rw-r--r--src/gui/general/LinedStaff.cpp58
-rw-r--r--src/gui/general/LinedStaff.h26
-rw-r--r--src/gui/general/MidiPitchLabel.cpp4
-rw-r--r--src/gui/general/MidiPitchLabel.h6
-rw-r--r--src/gui/general/PixmapFunctions.cpp114
-rw-r--r--src/gui/general/PixmapFunctions.h32
-rw-r--r--src/gui/general/PresetElement.cpp4
-rw-r--r--src/gui/general/PresetElement.h8
-rw-r--r--src/gui/general/PresetGroup.cpp60
-rw-r--r--src/gui/general/PresetGroup.h26
-rw-r--r--src/gui/general/PresetHandlerDialog.cpp54
-rw-r--r--src/gui/general/PresetHandlerDialog.h14
-rw-r--r--src/gui/general/ProgressReporter.cpp6
-rw-r--r--src/gui/general/ProgressReporter.h6
-rw-r--r--src/gui/general/RosegardenCanvasView.cpp84
-rw-r--r--src/gui/general/RosegardenCanvasView.h52
-rw-r--r--src/gui/general/RosegardenScrollView.cpp66
-rw-r--r--src/gui/general/RosegardenScrollView.h44
-rw-r--r--src/gui/general/Spline.cpp24
-rw-r--r--src/gui/general/Spline.h16
-rw-r--r--src/gui/general/StaffLine.cpp8
-rw-r--r--src/gui/general/StaffLine.h8
47 files changed, 781 insertions, 781 deletions
diff --git a/src/gui/general/ActiveItem.h b/src/gui/general/ActiveItem.h
index f8f5339..df7ca37 100644
--- a/src/gui/general/ActiveItem.h
+++ b/src/gui/general/ActiveItem.h
@@ -28,7 +28,7 @@
-class QMouseEvent;
+class TQMouseEvent;
namespace Rosegarden
@@ -43,9 +43,9 @@ namespace Rosegarden
class ActiveItem
{
public:
- virtual void handleMousePress(QMouseEvent*) = 0;
- virtual void handleMouseMove(QMouseEvent*) = 0;
- virtual void handleMouseRelease(QMouseEvent*) = 0;
+ virtual void handleMousePress(TQMouseEvent*) = 0;
+ virtual void handleMouseMove(TQMouseEvent*) = 0;
+ virtual void handleMouseRelease(TQMouseEvent*) = 0;
};
diff --git a/src/gui/general/BarLine.cpp b/src/gui/general/BarLine.cpp
index 42bb936..5b5973d 100644
--- a/src/gui/general/BarLine.cpp
+++ b/src/gui/general/BarLine.cpp
@@ -24,12 +24,12 @@
#include "BarLine.h"
-#include <qpainter.h>
+#include <tqpainter.h>
namespace Rosegarden {
void
-BarLine::drawShape(QPainter &painter)
+BarLine::drawShape(TQPainter &painter)
{
int bx = int(x());
int by = int(y());
@@ -154,11 +154,11 @@ BarLine::areaPoints() const
break;
}
- QPointArray p(4);
- p[0] = QPoint(x0, y0);
- p[1] = QPoint(x1, y0);
- p[2] = QPoint(x1, y1);
- p[3] = QPoint(x0, y1);
+ TQPointArray p(4);
+ p[0] = TQPoint(x0, y0);
+ p[1] = TQPoint(x1, y0);
+ p[2] = TQPoint(x1, y1);
+ p[3] = TQPoint(x0, y1);
return p;
}
diff --git a/src/gui/general/BarLine.h b/src/gui/general/BarLine.h
index 124bc06..3523c8a 100644
--- a/src/gui/general/BarLine.h
+++ b/src/gui/general/BarLine.h
@@ -27,17 +27,17 @@
#define _RG_BARLINE_H_
#include "LinedStaff.h"
-#include <qcanvas.h>
+#include <tqcanvas.h>
namespace Rosegarden {
class BarLine : public QCanvasPolygonalItem
{
public:
- BarLine(QCanvas *canvas, double layoutX,
+ BarLine(TQCanvas *canvas, double layoutX,
int barLineHeight, int baseBarThickness, int lineSpacing,
int inset, LinedStaff::BarStyle style) :
- QCanvasPolygonalItem(canvas),
+ TQCanvasPolygonalItem(canvas),
m_layoutX(layoutX),
m_barLineHeight(barLineHeight),
m_baseBarThickness(baseBarThickness),
@@ -47,8 +47,8 @@ public:
double getLayoutX() const { return m_layoutX; }
- virtual QPointArray areaPoints() const;
- virtual void drawShape(QPainter &);
+ virtual TQPointArray areaPoints() const;
+ virtual void drawShape(TQPainter &);
protected:
double m_layoutX;
diff --git a/src/gui/general/BaseTool.cpp b/src/gui/general/BaseTool.cpp
index 4c33610..75202ac 100644
--- a/src/gui/general/BaseTool.cpp
+++ b/src/gui/general/BaseTool.cpp
@@ -27,17 +27,17 @@
#include "misc/Debug.h"
#include <kxmlguifactory.h>
-#include <qcursor.h>
-#include <qobject.h>
-#include <qpopupmenu.h>
-#include <qstring.h>
+#include <tqcursor.h>
+#include <tqobject.h>
+#include <tqpopupmenu.h>
+#include <tqstring.h>
namespace Rosegarden
{
-BaseTool::BaseTool(const QString& menuName, KXMLGUIFactory* factory, QObject* parent)
- : QObject(parent),
+BaseTool::BaseTool(const TQString& menuName, KXMLGUIFactory* factory, TQObject* parent)
+ : TQObject(parent),
m_menuName(menuName),
m_menu(0),
m_parentFactory(factory)
@@ -67,17 +67,17 @@ void BaseTool::showMenu()
createMenu();
if (m_menu)
- m_menu->exec(QCursor::pos());
+ m_menu->exec(TQCursor::pos());
else
RG_DEBUG << "BaseTool::showMenu() : no menu to show\n";
}
-QString BaseTool::getCurrentContextHelp() const
+TQString BaseTool::getCurrentContextHelp() const
{
return m_contextHelp;
}
-void BaseTool::setContextHelp(const QString &help)
+void BaseTool::setContextHelp(const TQString &help)
{
m_contextHelp = help;
emit showContextHelp(m_contextHelp);
diff --git a/src/gui/general/BaseTool.h b/src/gui/general/BaseTool.h
index 71e6410..6dd6820 100644
--- a/src/gui/general/BaseTool.h
+++ b/src/gui/general/BaseTool.h
@@ -26,11 +26,11 @@
#ifndef _RG_BASETOOL_H_
#define _RG_BASETOOL_H_
-#include <qobject.h>
-#include <qstring.h>
+#include <tqobject.h>
+#include <tqstring.h>
-class QPopupMenu;
+class TQPopupMenu;
class KXMLGUIFactory;
@@ -76,10 +76,10 @@ public:
/**
* Retrieve current status-line type help for the tool, if any
*/
- virtual QString getCurrentContextHelp() const;
+ virtual TQString getCurrentContextHelp() const;
signals:
- void showContextHelp(const QString &);
+ void showContextHelp(const TQString &);
protected:
/**
@@ -87,22 +87,22 @@ protected:
*
* \a menuName : the name of the menu defined in the XML rc file
*/
- BaseTool(const QString& menuName, KXMLGUIFactory*, QObject* parent);
+ BaseTool(const TQString& menuName, KXMLGUIFactory*, TQObject* parent);
virtual void createMenu() = 0;
virtual bool hasMenu() { return false; }
- virtual void setContextHelp(const QString &help);
+ virtual void setContextHelp(const TQString &help);
virtual void clearContextHelp() { setContextHelp(""); }
//--------------- Data members ---------------------------------
- QString m_menuName;
- QPopupMenu* m_menu;
+ TQString m_menuName;
+ TQPopupMenu* m_menu;
KXMLGUIFactory* m_parentFactory;
- QString m_contextHelp;
+ TQString m_contextHelp;
};
diff --git a/src/gui/general/BaseToolBox.cpp b/src/gui/general/BaseToolBox.cpp
index 9e2fda9..e4c2a5f 100644
--- a/src/gui/general/BaseToolBox.cpp
+++ b/src/gui/general/BaseToolBox.cpp
@@ -26,30 +26,30 @@
#include "BaseToolBox.h"
#include "BaseTool.h"
-#include <qobject.h>
-#include <qstring.h>
-#include <qwidget.h>
+#include <tqobject.h>
+#include <tqstring.h>
+#include <tqwidget.h>
namespace Rosegarden
{
-BaseToolBox::BaseToolBox(QWidget* parent)
- : QObject(parent),
+BaseToolBox::BaseToolBox(TQWidget* parent)
+ : TQObject(parent),
m_tools(17, // default size, from the Qt docs
false) // but we want it to be case insensitive
{
//m_tools.setAutoDelete(true);
}
-BaseTool* BaseToolBox::getTool(const QString& toolName)
+BaseTool* BaseToolBox::getTool(const TQString& toolName)
{
BaseTool* tool = m_tools[toolName];
if (!tool) tool = createTool(toolName);
- connect(tool, SIGNAL(showContextHelp(const QString &)),
- this, SIGNAL(showContextHelp(const QString &)));
+ connect(tool, TQT_SIGNAL(showContextHelp(const TQString &)),
+ this, TQT_SIGNAL(showContextHelp(const TQString &)));
return tool;
}
diff --git a/src/gui/general/BaseToolBox.h b/src/gui/general/BaseToolBox.h
index 2a0242f..d061938 100644
--- a/src/gui/general/BaseToolBox.h
+++ b/src/gui/general/BaseToolBox.h
@@ -26,12 +26,12 @@
#ifndef _RG_BASETOOLBOX_H_
#define _RG_BASETOOLBOX_H_
-#include <qdict.h>
-#include <qobject.h>
+#include <tqdict.h>
+#include <tqobject.h>
-class QWidget;
-class QString;
+class TQWidget;
+class TQString;
namespace Rosegarden
@@ -50,17 +50,17 @@ class BaseToolBox : public QObject
Q_OBJECT
public:
- BaseToolBox(QWidget* parent);
+ BaseToolBox(TQWidget* parent);
- virtual BaseTool* getTool(const QString& toolName);
+ virtual BaseTool* getTool(const TQString& toolName);
signals:
- void showContextHelp(const QString &);
+ void showContextHelp(const TQString &);
protected:
- virtual BaseTool* createTool(const QString& toolName) = 0;
+ virtual BaseTool* createTool(const TQString& toolName) = 0;
- QDict<BaseTool> m_tools;
+ TQDict<BaseTool> m_tools;
};
diff --git a/src/gui/general/CanvasCursor.cpp b/src/gui/general/CanvasCursor.cpp
index 5f04794..44a8d50 100644
--- a/src/gui/general/CanvasCursor.cpp
+++ b/src/gui/general/CanvasCursor.cpp
@@ -26,18 +26,18 @@
#include "CanvasCursor.h"
#include "GUIPalette.h"
-#include <qcanvas.h>
-#include <qpen.h>
+#include <tqcanvas.h>
+#include <tqpen.h>
namespace Rosegarden
{
-CanvasCursor::CanvasCursor(QCanvas* c, int width)
- : QCanvasRectangle(c),
+CanvasCursor::CanvasCursor(TQCanvas* c, int width)
+ : TQCanvasRectangle(c),
m_width(width)
{
- QPen pen(GUIPalette::getColour(GUIPalette::Pointer));
+ TQPen pen(GUIPalette::getColour(GUIPalette::Pointer));
// pen.setWidth(width);
setPen(pen);
setBrush(GUIPalette::getColour(GUIPalette::Pointer));
diff --git a/src/gui/general/CanvasCursor.h b/src/gui/general/CanvasCursor.h
index 694e9df..a53e39f 100644
--- a/src/gui/general/CanvasCursor.h
+++ b/src/gui/general/CanvasCursor.h
@@ -27,9 +27,9 @@
#define _RG_CANVASCURSOR_H_
-#include <qcanvas.h>
+#include <tqcanvas.h>
-class QCanvas;
+class TQCanvas;
namespace Rosegarden
@@ -40,9 +40,9 @@ namespace Rosegarden
class CanvasCursor : public QCanvasRectangle
{
public:
- CanvasCursor(QCanvas*, int width);
+ CanvasCursor(TQCanvas*, int width);
void updateHeight();
-// virtual QRect boundingRect() const;
+// virtual TQRect boundingRect() const;
protected:
int m_width;
};
diff --git a/src/gui/general/CanvasItemGC.cpp b/src/gui/general/CanvasItemGC.cpp
index 6e6afb2..64ac215 100644
--- a/src/gui/general/CanvasItemGC.cpp
+++ b/src/gui/general/CanvasItemGC.cpp
@@ -27,12 +27,12 @@
#include "misc/Debug.h"
-#include <qcanvas.h>
+#include <tqcanvas.h>
namespace Rosegarden
{
-void CanvasItemGC::mark(QCanvasItem* item)
+void CanvasItemGC::mark(TQCanvasItem* item)
{
if (!item)
return ;
@@ -59,6 +59,6 @@ void CanvasItemGC::flush()
m_garbage.clear();
}
-std::vector<QCanvasItem*> CanvasItemGC::m_garbage;
+std::vector<TQCanvasItem*> CanvasItemGC::m_garbage;
}
diff --git a/src/gui/general/CanvasItemGC.h b/src/gui/general/CanvasItemGC.h
index db1833b..681e021 100644
--- a/src/gui/general/CanvasItemGC.h
+++ b/src/gui/general/CanvasItemGC.h
@@ -29,7 +29,7 @@
#include <vector>
-class QCanvasItem;
+class TQCanvasItem;
namespace Rosegarden
@@ -47,12 +47,12 @@ namespace Rosegarden
* The problem this solves is a classic ownership/double deletion
* case. The SegmentCanvas deletes all its items on destruction. But
* the SegmentItems have an auxiliary "repeat rectangle" which is a
- * QCanvasRectangle, that needs to be deleted when the SegmentItem is
+ * TQCanvasRectangle, that needs to be deleted when the SegmentItem is
* itself deleted.
*
* However, if the SegmentItem deletes its repeat rectangle, then when
* the SegmentCanvas destruction occurs, the SegmentCanvas dtor will
- * get a list of all its children (QCanvas::allItems()), containing
+ * get a list of all its children (TQCanvas::allItems()), containing
* both SegmentItems and their repeat rectangles. Deleting a
* SegmentItem will delete its repeat rectangle, which will still be
* present in the all children list which the SegmentCanvas dtor is
@@ -66,7 +66,7 @@ class CanvasItemGC
{
public:
/// mark the given item for GC
- static void mark(QCanvasItem*);
+ static void mark(TQCanvasItem*);
/// GC all marked items
static void gc();
@@ -75,7 +75,7 @@ public:
static void flush();
protected:
- static std::vector<QCanvasItem*> m_garbage;
+ static std::vector<TQCanvasItem*> m_garbage;
};
diff --git a/src/gui/general/CategoryElement.cpp b/src/gui/general/CategoryElement.cpp
index 2199ce6..5042896 100644
--- a/src/gui/general/CategoryElement.cpp
+++ b/src/gui/general/CategoryElement.cpp
@@ -27,13 +27,13 @@
#include "misc/Debug.h"
#include "PresetElement.h"
-#include <qstring.h>
+#include <tqstring.h>
namespace Rosegarden
{
-CategoryElement::CategoryElement(QString name) :
+CategoryElement::CategoryElement(TQString name) :
m_name(name)
{}
@@ -43,7 +43,7 @@ CategoryElement::~CategoryElement()
}
void
-CategoryElement::addPreset(QString name,
+CategoryElement::addPreset(TQString name,
int clef,
int transpose,
int highAm,
diff --git a/src/gui/general/CategoryElement.h b/src/gui/general/CategoryElement.h
index eeb88a5..67a51f7 100644
--- a/src/gui/general/CategoryElement.h
+++ b/src/gui/general/CategoryElement.h
@@ -27,7 +27,7 @@
#define _RG_CATEGORYELEMENT_H_
#include "PresetElement.h"
-#include <qstring.h>
+#include <tqstring.h>
@@ -43,10 +43,10 @@ namespace Rosegarden
class CategoryElement
{
public:
- CategoryElement(QString name);
+ CategoryElement(TQString name);
~CategoryElement();
- void addPreset(QString name,
+ void addPreset(TQString name,
int clef,
int transpose,
int highAm,
@@ -54,13 +54,13 @@ public:
int highPro,
int lowPro);
- QString getName() { return m_name; }
+ TQString getName() { return m_name; }
ElementContainer getPresets() { return m_categoryPresets; }
PresetElement getPresetByIndex(int index) { return m_categoryPresets [index]; }
private:
- QString m_name;
+ TQString m_name;
ElementContainer m_categoryPresets;
}; // CategoryElement
diff --git a/src/gui/general/ClefIndex.cpp b/src/gui/general/ClefIndex.cpp
index 68ad488..376b6cb 100644
--- a/src/gui/general/ClefIndex.cpp
+++ b/src/gui/general/ClefIndex.cpp
@@ -52,7 +52,7 @@ const Rosegarden::Clef clefIndexToClef(int index)
return clef;
}
-const int clefNameToClefIndex(QString s)
+const int clefNameToClefIndex(TQString s)
{
int m_elClef = 0;
if (s) {
diff --git a/src/gui/general/ClefIndex.h b/src/gui/general/ClefIndex.h
index 74e3fc8..118307c 100644
--- a/src/gui/general/ClefIndex.h
+++ b/src/gui/general/ClefIndex.h
@@ -24,7 +24,7 @@
#define _CLEF_INDEX_H_
#include "base/NotationTypes.h"
-#include <qstring.h>
+#include <tqstring.h>
// used variously by TPB, SPB, PresetHandler to correlate combo box indices to
// clef types
@@ -52,7 +52,7 @@ namespace Rosegarden
const Clef clefIndexToClef(int index);
-const int clefNameToClefIndex(QString s);
+const int clefNameToClefIndex(TQString s);
}
diff --git a/src/gui/general/EditTool.cpp b/src/gui/general/EditTool.cpp
index 52e7b11..f48017c 100644
--- a/src/gui/general/EditTool.cpp
+++ b/src/gui/general/EditTool.cpp
@@ -32,15 +32,15 @@
#include "EditView.h"
#include "RosegardenCanvasView.h"
#include <kxmlguiclient.h>
-#include <qevent.h>
-#include <qpopupmenu.h>
-#include <qstring.h>
+#include <tqevent.h>
+#include <tqpopupmenu.h>
+#include <tqstring.h>
namespace Rosegarden
{
-EditTool::EditTool(const QString& menuName, EditView* view)
+EditTool::EditTool(const TQString& menuName, EditView* view)
: BaseTool(menuName, view->factory(), view),
m_parentView(view)
{}
@@ -48,7 +48,7 @@ EditTool::EditTool(const QString& menuName, EditView* view)
void EditTool::handleMousePress(timeT time,
int height,
int staffNo,
- QMouseEvent* e,
+ TQMouseEvent* e,
ViewElement* el)
{
RG_DEBUG << "EditTool::handleMousePress : mouse button = "
@@ -57,7 +57,7 @@ void EditTool::handleMousePress(timeT time,
switch (e->button()) {
case Qt::LeftButton:
- if (e->type() == QEvent::MouseButtonDblClick) {
+ if (e->type() == TQEvent::MouseButtonDblClick) {
RG_DEBUG << "EditTool::handleMousePress: it's a double-click"
<< endl;
handleMouseDoubleClick(time, height, staffNo, e, el);
@@ -84,13 +84,13 @@ void EditTool::handleMousePress(timeT time,
void EditTool::handleMidButtonPress(timeT,
int, int,
- QMouseEvent*,
+ TQMouseEvent*,
ViewElement*)
{}
void EditTool::handleRightButtonPress(timeT,
int, int,
- QMouseEvent*,
+ TQMouseEvent*,
ViewElement*)
{
showMenu();
@@ -98,21 +98,21 @@ void EditTool::handleRightButtonPress(timeT,
void EditTool::handleMouseDoubleClick(timeT,
int, int,
- QMouseEvent*,
+ TQMouseEvent*,
ViewElement*)
{
// nothing
}
-int EditTool::handleMouseMove(timeT, int, QMouseEvent*)
+int EditTool::handleMouseMove(timeT, int, TQMouseEvent*)
{
return RosegardenCanvasView::NoFollow;
}
-void EditTool::handleMouseRelease(timeT, int, QMouseEvent*)
+void EditTool::handleMouseRelease(timeT, int, TQMouseEvent*)
{}
-void EditTool::createMenu(QString rcFileName)
+void EditTool::createMenu(TQString rcFileName)
{
setRCFileName(rcFileName);
createMenu();
@@ -125,14 +125,14 @@ void EditTool::createMenu()
setXMLFile(m_rcFileName);
m_parentFactory->addClient(this);
- QWidget* tmp = m_parentFactory->container(m_menuName, this);
+ TQWidget* tmp = m_parentFactory->container(m_menuName, this);
if (!tmp)
RG_DEBUG << "BaseTool::createMenu(" << m_rcFileName
<< ") : menu creation failed (name : "
<< m_menuName << ")\n";
- m_menu = dynamic_cast<QPopupMenu*>(tmp);
+ m_menu = dynamic_cast<TQPopupMenu*>(tmp);
}
bool EditTool::hasMenu()
diff --git a/src/gui/general/EditTool.h b/src/gui/general/EditTool.h
index 17937d1..7fda27f 100644
--- a/src/gui/general/EditTool.h
+++ b/src/gui/general/EditTool.h
@@ -28,11 +28,11 @@
#include "BaseTool.h"
#include <kxmlguiclient.h>
-#include <qstring.h>
+#include <tqstring.h>
#include "base/Event.h"
-class QMouseEvent;
+class TQMouseEvent;
namespace Rosegarden
@@ -77,7 +77,7 @@ public:
virtual void handleMousePress(timeT time,
int height,
int staffNo,
- QMouseEvent *event,
+ TQMouseEvent *event,
ViewElement*);
/**
@@ -86,7 +86,7 @@ public:
virtual void handleLeftButtonPress(timeT time,
int height,
int staffNo,
- QMouseEvent *event,
+ TQMouseEvent *event,
ViewElement*) = 0;
/**
@@ -95,7 +95,7 @@ public:
virtual void handleMidButtonPress(timeT time,
int height,
int staffNo,
- QMouseEvent*,
+ TQMouseEvent*,
ViewElement*);
/**
@@ -104,7 +104,7 @@ public:
virtual void handleRightButtonPress(timeT time,
int height,
int staffNo,
- QMouseEvent*,
+ TQMouseEvent*,
ViewElement*);
/**
@@ -113,7 +113,7 @@ public:
virtual void handleMouseDoubleClick(timeT time,
int height,
int staffNo,
- QMouseEvent*,
+ TQMouseEvent*,
ViewElement*);
/**
@@ -124,14 +124,14 @@ public:
*/
virtual int handleMouseMove(timeT time,
int height,
- QMouseEvent*);
+ TQMouseEvent*);
/**
* Do nothing
*/
virtual void handleMouseRelease(timeT time,
int height,
- QMouseEvent*);
+ TQMouseEvent*);
/**
* Respond to an event being deleted -- it may be the one the tool
@@ -146,16 +146,16 @@ protected:
*
* \a menuName : the name of the menu defined in the XML rc file
*/
- EditTool(const QString& menuName, EditView*);
+ EditTool(const TQString& menuName, EditView*);
- void setRCFileName(QString rcfilename) { m_rcFileName = rcfilename; }
+ void setRCFileName(TQString rcfilename) { m_rcFileName = rcfilename; }
virtual void createMenu();
- virtual void createMenu(QString rcFileName);
+ virtual void createMenu(TQString rcFileName);
virtual bool hasMenu();
//--------------- Data members ---------------------------------
- QString m_rcFileName;
+ TQString m_rcFileName;
EditView* m_parentView;
};
diff --git a/src/gui/general/EditToolBox.cpp b/src/gui/general/EditToolBox.cpp
index c2e24a9..48fa7e4 100644
--- a/src/gui/general/EditToolBox.cpp
+++ b/src/gui/general/EditToolBox.cpp
@@ -28,8 +28,8 @@
#include "BaseToolBox.h"
#include "EditTool.h"
#include "EditView.h"
-#include <qobject.h>
-#include <qstring.h>
+#include <tqobject.h>
+#include <tqstring.h>
#include <kmessagebox.h>
namespace Rosegarden
@@ -41,12 +41,12 @@ EditToolBox::EditToolBox(EditView *parent)
{
}
-EditTool* EditToolBox::getTool(const QString& toolName)
+EditTool* EditToolBox::getTool(const TQString& toolName)
{
return dynamic_cast<EditTool*>(BaseToolBox::getTool(toolName));
}
-EditTool* EditToolBox::createTool(const QString&)
+EditTool* EditToolBox::createTool(const TQString&)
{
KMessageBox::error(0, "EditToolBox::createTool called - this should never happen");
return 0;
diff --git a/src/gui/general/EditToolBox.h b/src/gui/general/EditToolBox.h
index 0115558..c1287b8 100644
--- a/src/gui/general/EditToolBox.h
+++ b/src/gui/general/EditToolBox.h
@@ -30,7 +30,7 @@
#include "EditTool.h"
-class QString;
+class TQString;
namespace Rosegarden
@@ -49,10 +49,10 @@ class EditToolBox : public BaseToolBox
public:
EditToolBox(EditView* parent);
- virtual EditTool* getTool(const QString& toolName);
+ virtual EditTool* getTool(const TQString& toolName);
protected:
- virtual EditTool* createTool(const QString& toolName);
+ virtual EditTool* createTool(const TQString& toolName);
//--------------- Data members ---------------------------------
diff --git a/src/gui/general/EditView.cpp b/src/gui/general/EditView.cpp
index a36b385..e37cbfc 100644
--- a/src/gui/general/EditView.cpp
+++ b/src/gui/general/EditView.cpp
@@ -24,7 +24,7 @@
#include "EditView.h"
-#include <qlayout.h>
+#include <tqlayout.h>
#include "base/BaseProperties.h"
#include <klocale.h>
@@ -87,20 +87,20 @@
#include <kstddirs.h>
#include <ktabwidget.h>
#include <kxmlguiclient.h>
-#include <qaccel.h>
-#include <qbutton.h>
-#include <qdialog.h>
-#include <qframe.h>
-#include <qinputdialog.h>
-#include <qlabel.h>
-#include <qobjectlist.h>
-#include <qpopupmenu.h>
-#include <qsize.h>
-#include <qstring.h>
-#include <qtabwidget.h>
-#include <qvbox.h>
-#include <qwidget.h>
-#include <qwmatrix.h>
+#include <tqaccel.h>
+#include <tqbutton.h>
+#include <tqdialog.h>
+#include <tqframe.h>
+#include <tqinputdialog.h>
+#include <tqlabel.h>
+#include <tqobjectlist.h>
+#include <tqpopupmenu.h>
+#include <tqsize.h>
+#include <tqstring.h>
+#include <tqtabwidget.h>
+#include <tqvbox.h>
+#include <tqwidget.h>
+#include <tqwmatrix.h>
namespace Rosegarden
@@ -119,15 +119,15 @@ static int FeatureShowVelocity = 0x00001; // show the velocity ruler
EditView::EditView(RosegardenGUIDoc *doc,
std::vector<Segment *> segments,
unsigned int cols,
- QWidget *parent, const char *name) :
+ TQWidget *parent, const char *name) :
EditViewBase(doc, segments, cols, parent, name),
m_currentEventSelection(0),
m_activeItem(0),
m_canvasView(0),
- m_rulerBox(new QVBoxLayout), // top ruler box - added to grid later on
+ m_rulerBox(new TQVBoxLayout), // top ruler box - added to grid later on
m_rulerBoxFiller(0), // On the left of m_rulerBox
- m_controlBox(new QVBoxLayout), // top control ruler box - added to grid later on
- m_bottomBox(new QVBox(this, "bottomframe")), // bottom box - added to bottom of canvas view by setCanvasView()
+ m_controlBox(new TQVBoxLayout), // top control ruler box - added to grid later on
+ m_bottomBox(new TQVBox(this, "bottomframe")), // bottom box - added to bottom of canvas view by setCanvasView()
m_topStandardRuler(0),
m_bottomStandardRuler(0),
m_controlRuler(0),
@@ -135,19 +135,19 @@ EditView::EditView(RosegardenGUIDoc *doc,
{
m_controlRulers->setHoverCloseButton(true);
m_controlRulers->setHoverCloseButtonDelayed(false);
- connect(m_controlRulers, SIGNAL(closeRequest(QWidget*)),
- this, SLOT(slotRemoveControlRuler(QWidget*)));
+ connect(m_controlRulers, TQT_SIGNAL(closeRequest(TQWidget*)),
+ this, TQT_SLOT(slotRemoveControlRuler(TQWidget*)));
- (dynamic_cast<QBoxLayout*>(m_bottomBox->layout()))->setDirection(QBoxLayout::BottomToTop);
+ (dynamic_cast<TQBoxLayout*>(m_bottomBox->layout()))->setDirection(TQBoxLayout::BottomToTop);
// m_rulerBoxFiller is a white label used to keep m_rulerBox exactly
// above the scrolling part of the view (and never above the
// RosegardenCanvasView::m_leftWidget).
- QGridLayout * gl = new QGridLayout(1, 2);
+ TQGridLayout * gl = new TQGridLayout(1, 2);
gl->setColStretch(0, 0);
gl->setColStretch(1, 1);
gl->addLayout(m_rulerBox, 0, 1);
- m_rulerBoxFiller = new QLabel(getCentralWidget());
+ m_rulerBoxFiller = new TQLabel(getCentralWidget());
gl->addWidget(m_rulerBoxFiller, 0, 0);
m_rulerBoxFiller->hide();
@@ -158,7 +158,7 @@ EditView::EditView(RosegardenGUIDoc *doc,
// m_grid->addWidget(m_controlRulers, CONTROLRULER_ROW, 2);
m_controlRulers->hide();
- m_controlRulers->setTabPosition(QTabWidget::Bottom);
+ m_controlRulers->setTabPosition(TQTabWidget::Bottom);
}
EditView::~EditView()
@@ -174,7 +174,7 @@ void EditView::updateBottomWidgetGeometry()
getCanvasView()->updateBottomWidgetGeometry();
}
-void EditView::paintEvent(QPaintEvent* e)
+void EditView::paintEvent(TQPaintEvent* e)
{
RG_DEBUG << "EditView::paintEvent()\n";
EditViewBase::paintEvent(e);
@@ -185,8 +185,8 @@ void EditView::paintEvent(QPaintEvent* e)
getCanvasView()->slotUpdate();
// update rulers
- QLayoutIterator it = m_rulerBox->iterator();
- QLayoutItem *child;
+ TQLayoutIterator it = m_rulerBox->iterator();
+ TQLayoutItem *child;
while ( (child = it.current()) != 0 ) {
if (child->widget())
child->widget()->update();
@@ -218,7 +218,7 @@ void EditView::updateControlRulers(bool updateHPos)
}
}
-void EditView::setControlRulersZoom(QWMatrix zoomMatrix)
+void EditView::setControlRulersZoom(TQWMatrix zoomMatrix)
{
m_currentRulerZoomMatrix = zoomMatrix;
@@ -266,12 +266,12 @@ void EditView::setControlRulersCurrentSegment()
*/
}
-void EditView::setTopStandardRuler(StandardRuler* w, QWidget *leftBox)
+void EditView::setTopStandardRuler(StandardRuler* w, TQWidget *leftBox)
{
delete m_topStandardRuler;
m_topStandardRuler = w;
- QGridLayout * gl = new QGridLayout(1, 2);
+ TQGridLayout * gl = new TQGridLayout(1, 2);
gl->setColStretch(0, 0);
gl->setColStretch(1, 1);
@@ -283,10 +283,10 @@ void EditView::setTopStandardRuler(StandardRuler* w, QWidget *leftBox)
m_grid->addLayout(gl, TOPBARBUTTONS_ROW, m_mainCol);
if (m_canvasView) {
- connect(m_canvasView->horizontalScrollBar(), SIGNAL(valueChanged(int)),
- m_topStandardRuler, SLOT(slotScrollHoriz(int)));
- connect(m_canvasView->horizontalScrollBar(), SIGNAL(sliderMoved(int)),
- m_topStandardRuler, SLOT(slotScrollHoriz(int)));
+ connect(m_canvasView->horizontalScrollBar(), TQT_SIGNAL(valueChanged(int)),
+ m_topStandardRuler, TQT_SLOT(slotScrollHoriz(int)));
+ connect(m_canvasView->horizontalScrollBar(), TQT_SIGNAL(sliderMoved(int)),
+ m_topStandardRuler, TQT_SLOT(slotScrollHoriz(int)));
}
}
@@ -298,30 +298,30 @@ void EditView::setBottomStandardRuler(StandardRuler* w)
// m_bottomBox->insertWidget(0, w);
if (m_canvasView) {
- connect(m_canvasView->horizontalScrollBar(), SIGNAL(valueChanged(int)),
- m_bottomStandardRuler, SLOT(slotScrollHoriz(int)));
- connect(m_canvasView->horizontalScrollBar(), SIGNAL(sliderMoved(int)),
- m_bottomStandardRuler, SLOT(slotScrollHoriz(int)));
+ connect(m_canvasView->horizontalScrollBar(), TQT_SIGNAL(valueChanged(int)),
+ m_bottomStandardRuler, TQT_SLOT(slotScrollHoriz(int)));
+ connect(m_canvasView->horizontalScrollBar(), TQT_SIGNAL(sliderMoved(int)),
+ m_bottomStandardRuler, TQT_SLOT(slotScrollHoriz(int)));
}
}
void EditView::setRewFFwdToAutoRepeat()
{
- QWidget* transportToolbar = factory()->container("Transport Toolbar", this);
+ TQWidget* transportToolbar = factory()->container("Transport Toolbar", this);
if (transportToolbar) {
- QObjectList *l = transportToolbar->queryList();
- QObjectListIt it(*l); // iterate over the buttons
- QObject *obj;
+ TQObjectList *l = transportToolbar->queryList();
+ TQObjectListIt it(*l); // iterate over the buttons
+ TQObject *obj;
while ( (obj = it.current()) != 0 ) {
// for each found object...
++it;
// RG_DEBUG << "EditView::setRewFFwdToAutoRepeat() : obj name : " << obj->name() << endl;
- QString objName = obj->name();
+ TQString objName = obj->name();
if (objName.endsWith("playback_pointer_back_bar") || objName.endsWith("playback_pointer_forward_bar")) {
- QButton* btn = dynamic_cast<QButton*>(obj);
+ TQButton* btn = dynamic_cast<TQButton*>(obj);
if (!btn) {
RG_DEBUG << "Very strange - found widgets in Transport Toolbar which aren't buttons\n";
@@ -340,19 +340,19 @@ void EditView::setRewFFwdToAutoRepeat()
}
-void EditView::addRuler(QWidget* w)
+void EditView::addRuler(TQWidget* w)
{
m_rulerBox->addWidget(w);
if (m_canvasView) {
- connect(m_canvasView->horizontalScrollBar(), SIGNAL(valueChanged(int)),
- w, SLOT(slotScrollHoriz(int)));
- connect(m_canvasView->horizontalScrollBar(), SIGNAL(sliderMoved(int)),
- w, SLOT(slotScrollHoriz(int)));
+ connect(m_canvasView->horizontalScrollBar(), TQT_SIGNAL(valueChanged(int)),
+ w, TQT_SLOT(slotScrollHoriz(int)));
+ connect(m_canvasView->horizontalScrollBar(), TQT_SIGNAL(sliderMoved(int)),
+ w, TQT_SLOT(slotScrollHoriz(int)));
}
}
-void EditView::addPropertyBox(QWidget *w)
+void EditView::addPropertyBox(TQWidget *w)
{
m_controlBox->addWidget(w);
}
@@ -365,19 +365,19 @@ void EditView::addControlRuler(ControlRuler* ruler)
m_controlRulers->showPage(ruler);
if (m_canvasView) {
- connect(m_canvasView->horizontalScrollBar(), SIGNAL(valueChanged(int)),
- ruler->horizontalScrollBar(), SIGNAL(valueChanged(int)));
- connect(m_canvasView->horizontalScrollBar(), SIGNAL(sliderMoved(int)),
- ruler->horizontalScrollBar(), SIGNAL(sliderMoved(int)));
+ connect(m_canvasView->horizontalScrollBar(), TQT_SIGNAL(valueChanged(int)),
+ ruler->horizontalScrollBar(), TQT_SIGNAL(valueChanged(int)));
+ connect(m_canvasView->horizontalScrollBar(), TQT_SIGNAL(sliderMoved(int)),
+ ruler->horizontalScrollBar(), TQT_SIGNAL(sliderMoved(int)));
}
- connect(ruler, SIGNAL(stateChange(const QString&, bool)),
- this, SLOT(slotStateChanged(const QString&, bool)));
+ connect(ruler, TQT_SIGNAL(stateChange(const TQString&, bool)),
+ this, TQT_SLOT(slotStateChanged(const TQString&, bool)));
stateChanged("have_control_ruler", KXMLGUIClient::StateReverse);
}
-void EditView::readjustViewSize(QSize requestedSize, bool exact)
+void EditView::readjustViewSize(TQSize requestedSize, bool exact)
{
Profiler profiler("EditView::readjustViewSize", true);
@@ -396,7 +396,7 @@ void EditView::readjustViewSize(QSize requestedSize, bool exact)
windowWidth = width(),
windowHeight = height();
- QSize newSize;
+ TQSize newSize;
newSize.setWidth(((requestedWidth / windowWidth) + 1) * windowWidth);
newSize.setHeight(((requestedHeight / windowHeight) + 1) * windowHeight);
@@ -426,10 +426,10 @@ void EditView::setCanvasView(RosegardenCanvasView *canvasView)
// m_horizontalScrollBar->setSteps(m_canvasView->horizontalScrollBar()->lineStep(),
// m_canvasView->horizontalScrollBar()->pageStep());
- // connect(m_horizontalScrollBar, SIGNAL(valueChanged(int)),
- // m_canvasView->horizontalScrollBar(), SIGNAL(valueChanged(int)));
- // connect(m_horizontalScrollBar, SIGNAL(sliderMoved(int)),
- // m_canvasView->horizontalScrollBar(), SIGNAL(sliderMoved(int)));
+ // connect(m_horizontalScrollBar, TQT_SIGNAL(valueChanged(int)),
+ // m_canvasView->horizontalScrollBar(), TQT_SIGNAL(valueChanged(int)));
+ // connect(m_horizontalScrollBar, TQT_SIGNAL(sliderMoved(int)),
+ // m_canvasView->horizontalScrollBar(), TQT_SIGNAL(sliderMoved(int)));
}
@@ -469,8 +469,8 @@ EditView::getInsertionTime(Clef &clef,
return t;
}
-void EditView::slotActiveItemPressed(QMouseEvent* e,
- QCanvasItem* item)
+void EditView::slotActiveItemPressed(TQMouseEvent* e,
+ TQCanvasItem* item)
{
if (!item)
return ;
@@ -723,137 +723,137 @@ EditView::setupActions()
//
// Tempo and time signature changes
//
- QString pixmapDir = KGlobal::dirs()->findResource("appdata", "pixmaps/");
- QCanvasPixmap pixmap(pixmapDir + "/toolbar/event-insert-tempo.png");
- QIconSet icon = QIconSet(pixmap);
+ TQString pixmapDir = KGlobal::dirs()->findResource("appdata", "pixmaps/");
+ TQCanvasPixmap pixmap(pixmapDir + "/toolbar/event-insert-tempo.png");
+ TQIconSet icon = TQIconSet(pixmap);
new KAction(AddTempoChangeCommand::getGlobalName(),
icon, 0,
- this, SLOT(slotAddTempo()),
+ this, TQT_SLOT(slotAddTempo()),
actionCollection(), "add_tempo");
pixmap.load(pixmapDir + "/toolbar/event-insert-timesig.png");
- icon = QIconSet(pixmap);
+ icon = TQIconSet(pixmap);
new KAction(AddTimeSignatureCommand::getGlobalName(),
icon, 0,
- this, SLOT(slotAddTimeSignature()),
+ this, TQT_SLOT(slotAddTimeSignature()),
actionCollection(), "add_time_signature");
//
// Transforms
//
new KAction(i18n("&Halve Durations"), Key_H + CTRL, this,
- SLOT(slotHalveDurations()), actionCollection(),
+ TQT_SLOT(slotHalveDurations()), actionCollection(),
"halve_durations");
new KAction(i18n("&Double Durations"), Key_H + CTRL + SHIFT, this,
- SLOT(slotDoubleDurations()), actionCollection(),
+ TQT_SLOT(slotDoubleDurations()), actionCollection(),
"double_durations");
new KAction(RescaleCommand::getGlobalName(), 0, this,
- SLOT(slotRescale()), actionCollection(),
+ TQT_SLOT(slotRescale()), actionCollection(),
"rescale");
new KAction(TransposeCommand::getGlobalName(1), 0,
Key_Up, this,
- SLOT(slotTransposeUp()), actionCollection(),
+ TQT_SLOT(slotTransposeUp()), actionCollection(),
"transpose_up");
new KAction(TransposeCommand::getGlobalName(12), 0,
Key_Up + CTRL, this,
- SLOT(slotTransposeUpOctave()), actionCollection(),
+ TQT_SLOT(slotTransposeUpOctave()), actionCollection(),
"transpose_up_octave");
new KAction(TransposeCommand::getGlobalName( -1), 0,
Key_Down, this,
- SLOT(slotTransposeDown()), actionCollection(),
+ TQT_SLOT(slotTransposeDown()), actionCollection(),
"transpose_down");
new KAction(TransposeCommand::getGlobalName( -12), 0,
Key_Down + CTRL, this,
- SLOT(slotTransposeDownOctave()), actionCollection(),
+ TQT_SLOT(slotTransposeDownOctave()), actionCollection(),
"transpose_down_octave");
new KAction(TransposeCommand::getGlobalName(0), 0, this,
- SLOT(slotTranspose()), actionCollection(),
+ TQT_SLOT(slotTranspose()), actionCollection(),
"general_transpose");
new KAction(TransposeCommand::getDiatonicGlobalName(0,0), 0, this,
- SLOT(slotDiatonicTranspose()), actionCollection(),
+ TQT_SLOT(slotDiatonicTranspose()), actionCollection(),
"general_diatonic_transpose");
new KAction(InvertCommand::getGlobalName(0), 0, this,
- SLOT(slotInvert()), actionCollection(),
+ TQT_SLOT(slotInvert()), actionCollection(),
"invert");
new KAction(RetrogradeCommand::getGlobalName(0), 0, this,
- SLOT(slotRetrograde()), actionCollection(),
+ TQT_SLOT(slotRetrograde()), actionCollection(),
"retrograde");
new KAction(RetrogradeInvertCommand::getGlobalName(0), 0, this,
- SLOT(slotRetrogradeInvert()), actionCollection(),
+ TQT_SLOT(slotRetrogradeInvert()), actionCollection(),
"retrograde_invert");
new KAction(i18n("Jog &Left"), Key_Left + ALT, this,
- SLOT(slotJogLeft()), actionCollection(),
+ TQT_SLOT(slotJogLeft()), actionCollection(),
"jog_left");
new KAction(i18n("Jog &Right"), Key_Right + ALT, this,
- SLOT(slotJogRight()), actionCollection(),
+ TQT_SLOT(slotJogRight()), actionCollection(),
"jog_right");
// Control rulers
//
new KAction(i18n("Show Velocity Property Ruler"), 0, this,
- SLOT(slotShowVelocityControlRuler()), actionCollection(),
+ TQT_SLOT(slotShowVelocityControlRuler()), actionCollection(),
"show_velocity_control_ruler");
/*
new KAction(i18n("Show Controllers Events Ruler"), 0, this,
- SLOT(slotShowControllerEventsRuler()), actionCollection(),
+ TQT_SLOT(slotShowControllerEventsRuler()), actionCollection(),
"show_controller_events_ruler");
*/
// Disabled for now
//
// new KAction(i18n("Add Control Ruler..."), 0, this,
- // SLOT(slotShowPropertyControlRuler()), actionCollection(),
+ // TQT_SLOT(slotShowPropertyControlRuler()), actionCollection(),
// "add_control_ruler");
//
// Control Ruler context menu
//
new KAction(i18n("Insert item"), 0, this,
- SLOT(slotInsertControlRulerItem()), actionCollection(),
+ TQT_SLOT(slotInsertControlRulerItem()), actionCollection(),
"insert_control_ruler_item");
// This was on Key_Delete, but that conflicts with existing Delete commands
// on individual edit views
new KAction(i18n("Erase selected items"), 0, this,
- SLOT(slotEraseControlRulerItem()), actionCollection(),
+ TQT_SLOT(slotEraseControlRulerItem()), actionCollection(),
"erase_control_ruler_item");
new KAction(i18n("Clear ruler"), 0, this,
- SLOT(slotClearControlRulerItem()), actionCollection(),
+ TQT_SLOT(slotClearControlRulerItem()), actionCollection(),
"clear_control_ruler_item");
new KAction(i18n("Insert line of controllers"), 0, this,
- SLOT(slotStartControlLineItem()), actionCollection(),
+ TQT_SLOT(slotStartControlLineItem()), actionCollection(),
"start_control_line_item");
new KAction(i18n("Flip forward"), Key_BracketRight, this,
- SLOT(slotFlipForwards()), actionCollection(),
+ TQT_SLOT(slotFlipForwards()), actionCollection(),
"flip_control_events_forward");
new KAction(i18n("Flip backwards"), Key_BracketLeft, this,
- SLOT(slotFlipBackwards()), actionCollection(),
+ TQT_SLOT(slotFlipBackwards()), actionCollection(),
"flip_control_events_back");
new KAction(i18n("Draw property line"), 0, this,
- SLOT(slotDrawPropertyLine()), actionCollection(),
+ TQT_SLOT(slotDrawPropertyLine()), actionCollection(),
"draw_property_line");
new KAction(i18n("Select all property values"), 0, this,
- SLOT(slotSelectAllProperties()), actionCollection(),
+ TQT_SLOT(slotSelectAllProperties()), actionCollection(),
"select_all_properties");
}
@@ -862,7 +862,7 @@ EditView::setupAddControlRulerMenu()
{
RG_DEBUG << "EditView::setupAddControlRulerMenu" << endl;
- QPopupMenu* addControlRulerMenu = dynamic_cast<QPopupMenu*>
+ TQPopupMenu* addControlRulerMenu = dynamic_cast<TQPopupMenu*>
(factory()->container("add_control_ruler", this));
if (addControlRulerMenu) {
@@ -883,12 +883,12 @@ EditView::setupAddControlRulerMenu()
const ControlList &list = c->getControlParameters();
int i = 0;
- QString itemStr;
+ TQString itemStr;
for (ControlList::const_iterator it = list.begin();
it != list.end(); ++it) {
if (it->getType() == Controller::EventType) {
- QString hexValue;
+ TQString hexValue;
hexValue.sprintf("(0x%x)", it->getControllerValue());
itemStr = i18n("%1 Controller %2 %3").arg(strtoqstr(it->getName()))
@@ -903,8 +903,8 @@ EditView::setupAddControlRulerMenu()
addControlRulerMenu->insertItem(itemStr, i++);
}
- connect(addControlRulerMenu, SIGNAL(activated(int)),
- SLOT(slotAddControlRuler(int)));
+ connect(addControlRulerMenu, TQT_SIGNAL(activated(int)),
+ TQT_SLOT(slotAddControlRuler(int)));
}
}
@@ -1015,7 +1015,7 @@ EditView::slotAddControlRuler(int controller)
getDocument()->slotDocumentModified();
}
-void EditView::slotRemoveControlRuler(QWidget* w)
+void EditView::slotRemoveControlRuler(TQWidget* w)
{
ControllerEventsRuler* ruler = dynamic_cast<ControllerEventsRuler*>(w);
@@ -1062,12 +1062,12 @@ void EditView::slotRemoveControlRuler(QWidget* w)
void
EditView::createInsertPitchActionMenu()
{
- QString notePitchNames[] = {
+ TQString notePitchNames[] = {
i18n("I"), i18n("II"), i18n("III"), i18n("IV"),
i18n("V"), i18n("VI"), i18n("VII"), i18n("VIII")
};
- QString flat = i18n("%1 flat");
- QString sharp = i18n("%1 sharp");
+ TQString flat = i18n("%1 flat");
+ TQString sharp = i18n("%1 sharp");
const Key notePitchKeys[3][7] = {
{
@@ -1102,7 +1102,7 @@ EditView::createInsertPitchActionMenu()
KAction *insertPitchAction = 0;
- QString octaveSuffix;
+ TQString octaveSuffix;
if (octave == 1)
octaveSuffix = "_high";
else if (octave == 2)
@@ -1116,8 +1116,8 @@ EditView::createInsertPitchActionMenu()
new KAction
(flat.arg(notePitchNames[i]),
CTRL + SHIFT + notePitchKeys[octave][i],
- this, SLOT(slotInsertNoteFromAction()), actionCollection(),
- QString("insert_%1_flat%2").arg(i).arg(octaveSuffix));
+ this, TQT_SLOT(slotInsertNoteFromAction()), actionCollection(),
+ TQString("insert_%1_flat%2").arg(i).arg(octaveSuffix));
menu->insert(insertPitchAction);
}
@@ -1126,8 +1126,8 @@ EditView::createInsertPitchActionMenu()
new KAction
(notePitchNames[i],
notePitchKeys[octave][i],
- this, SLOT(slotInsertNoteFromAction()), actionCollection(),
- QString("insert_%1%2").arg(i).arg(octaveSuffix));
+ this, TQT_SLOT(slotInsertNoteFromAction()), actionCollection(),
+ TQString("insert_%1%2").arg(i).arg(octaveSuffix));
menu->insert(insertPitchAction);
@@ -1139,8 +1139,8 @@ EditView::createInsertPitchActionMenu()
new KAction
(sharp.arg(notePitchNames[i]),
SHIFT + notePitchKeys[octave][i],
- this, SLOT(slotInsertNoteFromAction()), actionCollection(),
- QString("insert_%1_sharp%2").arg(i).arg(octaveSuffix));
+ this, TQT_SLOT(slotInsertNoteFromAction()), actionCollection(),
+ TQString("insert_%1_sharp%2").arg(i).arg(octaveSuffix));
menu->insert(insertPitchAction);
}
@@ -1154,7 +1154,7 @@ EditView::createInsertPitchActionMenu()
}
int
-EditView::getPitchFromNoteInsertAction(QString name,
+EditView::getPitchFromNoteInsertAction(TQString name,
Accidental &accidental,
const Clef &clef,
const ::Rosegarden::Key &key)
@@ -1220,12 +1220,12 @@ void EditView::slotAddTempo()
TempoDialog tempoDlg(this, getDocument());
connect(&tempoDlg,
- SIGNAL(changeTempo(timeT,
+ TQT_SIGNAL(changeTempo(timeT,
tempoT,
tempoT,
TempoDialog::TempoDialogAction)),
this,
- SIGNAL(changeTempo(timeT,
+ TQT_SIGNAL(changeTempo(timeT,
tempoT,
tempoT,
TempoDialog::TempoDialogAction)));
@@ -1268,7 +1268,7 @@ void EditView::slotAddTimeSignature()
i18n("Estimated time signature shown"));
}
- if (dialog->exec() == QDialog::Accepted) {
+ if (dialog->exec() == TQDialog::Accepted) {
insertionTime = dialog->getTime();
@@ -1354,7 +1354,7 @@ void EditView::slotShowPropertyControlRuler()
new QListBoxRGProperty(propList, BaseProperties::VELOCITY.c_str());
int rc = propChooserDialog.exec();
- if (rc == QDialog::Accepted) {
+ if (rc == TQDialog::Accepted) {
// fix for KDE 3.0
//QListBoxRGProperty* item = dynamic_cast<QListBoxRGProperty*>(propList->selectedItem());
QListBoxRGProperty* item = dynamic_cast<QListBoxRGProperty*>
@@ -1465,7 +1465,7 @@ EditView::slotRescale()
true,
true);
- if (dialog.exec() == QDialog::Accepted) {
+ if (dialog.exec() == TQDialog::Accepted) {
KTmpStatusMsg msg(i18n("Rescaling..."), this);
addCommandToHistory(new RescaleCommand
(*m_currentEventSelection,
@@ -1674,11 +1674,11 @@ ControlRuler* EditView::findRuler(const ControlParameter& controller, int &index
PropertyControlRuler* EditView::makePropertyControlRuler(PropertyName propertyName)
{
- QCanvas* controlRulerCanvas = new QCanvas(this);
- QSize viewSize = getViewSize();
+ TQCanvas* controlRulerCanvas = new TQCanvas(this);
+ TQSize viewSize = getViewSize();
controlRulerCanvas->resize(viewSize.width(), ControlRuler::DefaultRulerHeight); // TODO - keep it in sync with main canvas size
-// QCanvas* controlRulerCanvas = ControlRulerCanvasRepository::getCanvas(getCurrentSegment(), propertyName,
+// TQCanvas* controlRulerCanvas = ControlRulerCanvasRepository::getCanvas(getCurrentSegment(), propertyName,
// getViewSize());
PropertyControlRuler* controlRuler = new PropertyControlRuler
@@ -1692,10 +1692,10 @@ PropertyControlRuler* EditView::makePropertyControlRuler(PropertyName propertyNa
ControllerEventsRuler* EditView::makeControllerEventRuler(const ControlParameter *controller)
{
- QCanvas* controlRulerCanvas = new QCanvas(this);
- QSize viewSize = getViewSize();
+ TQCanvas* controlRulerCanvas = new TQCanvas(this);
+ TQSize viewSize = getViewSize();
controlRulerCanvas->resize(viewSize.width(), ControlRuler::DefaultRulerHeight); // TODO - keep it in sync with main canvas size
-// QCanvas* controlRulerCanvas = ControlRulerCanvasRepository::getCanvas(getCurrentSegment(), controller,
+// TQCanvas* controlRulerCanvas = ControlRulerCanvasRepository::getCanvas(getCurrentSegment(), controller,
// getViewSize());
diff --git a/src/gui/general/EditView.h b/src/gui/general/EditView.h
index da18982..e927281 100644
--- a/src/gui/general/EditView.h
+++ b/src/gui/general/EditView.h
@@ -29,19 +29,19 @@
#include "base/PropertyName.h"
#include "EditViewBase.h"
#include "gui/dialogs/TempoDialog.h"
-#include <qsize.h>
-#include <qstring.h>
-#include <qwmatrix.h>
+#include <tqsize.h>
+#include <tqstring.h>
+#include <tqwmatrix.h>
#include <vector>
#include "base/Event.h"
-class QWidget;
-class QVBoxLayout;
-class QVBox;
-class QPaintEvent;
-class QMouseEvent;
-class QCanvasItem;
+class TQWidget;
+class TQVBoxLayout;
+class TQVBox;
+class TQPaintEvent;
+class TQMouseEvent;
+class TQCanvasItem;
class KTabWidget;
class Accidental;
@@ -81,7 +81,7 @@ public:
EditView(RosegardenGUIDoc *doc,
std::vector<Segment *> segments,
unsigned int cols,
- QWidget *parent,
+ TQWidget *parent,
const char *name = 0);
virtual ~EditView();
@@ -94,7 +94,7 @@ public:
*
* @arg exact if true, then set to newSize exactly
*/
- virtual void readjustViewSize(QSize newSize, bool exact = false);
+ virtual void readjustViewSize(TQSize newSize, bool exact = false);
/**
* Return the active item
@@ -142,7 +142,7 @@ public slots:
* @see ActiveItem
* @see QCanvasItem#setActive
*/
- virtual void slotActiveItemPressed(QMouseEvent*, QCanvasItem*);
+ virtual void slotActiveItemPressed(TQMouseEvent*, TQCanvasItem*);
virtual void slotSetInsertCursorPosition(timeT position) = 0;
@@ -205,22 +205,22 @@ public slots:
// add control ruler
void slotAddControlRuler(int);
- void slotRemoveControlRuler(QWidget*);
+ void slotRemoveControlRuler(TQWidget*);
protected:
virtual RulerScale* getHLayout() = 0;
- QVBox* getBottomWidget() { return m_bottomBox; }
+ TQVBox* getBottomWidget() { return m_bottomBox; }
virtual void updateBottomWidgetGeometry();
- virtual void paintEvent(QPaintEvent* e);
+ virtual void paintEvent(TQPaintEvent* e);
/**
* Locate the given widgets in the top bar-buttons position and
* connect up its scrolling signals.
*/
- void setTopStandardRuler(StandardRuler*, QWidget *leftBox = NULL);
+ void setTopStandardRuler(StandardRuler*, TQWidget *leftBox = NULL);
/**
* Locate the given widget in the bottom bar-buttons position and
@@ -239,12 +239,12 @@ protected:
* connect up its scrolling signals.
* The widget has to have a slotScrollHoriz(int) slot
*/
- void addRuler(QWidget*);
+ void addRuler(TQWidget*);
/**
* Add a ruler control box
*/
- void addPropertyBox(QWidget*);
+ void addPropertyBox(TQWidget*);
/**
* Make a control ruler for the given property,
@@ -269,7 +269,7 @@ protected:
/**
* Set zoom factor of control rulers
*/
- void setControlRulersZoom(QWMatrix);
+ void setControlRulersZoom(TQWMatrix);
/**
* Set current segment for control rulers
@@ -331,7 +331,7 @@ protected:
* Exception to mean that the action is not an insert one. Also
* returns any specified accidental through the reference arg.
*/
- int getPitchFromNoteInsertAction(QString actionName,
+ int getPitchFromNoteInsertAction(TQString actionName,
Accidental &acc,
const Clef &clef,
const ::Rosegarden::Key &key);
@@ -340,13 +340,13 @@ protected:
* Abstract method to get the view size
* Typically implemented as canvas()->size().
*/
- virtual QSize getViewSize() = 0;
+ virtual TQSize getViewSize() = 0;
/**
* Abstract method to set the view size
* Typically implemented as canvas()->resize().
*/
- virtual void setViewSize(QSize) = 0;
+ virtual void setViewSize(TQSize) = 0;
/**
* Abstract method to get current insert-pointer time
@@ -382,15 +382,15 @@ protected:
RosegardenCanvasView *m_canvasView;
- QVBoxLayout *m_rulerBox;
- QLabel *m_rulerBoxFiller;
- QVBoxLayout *m_controlBox;
- QVBox *m_bottomBox;
+ TQVBoxLayout *m_rulerBox;
+ TQLabel *m_rulerBoxFiller;
+ TQVBoxLayout *m_controlBox;
+ TQVBox *m_bottomBox;
StandardRuler *m_topStandardRuler;
StandardRuler *m_bottomStandardRuler;
ControlRuler *m_controlRuler;
KTabWidget *m_controlRulers;
- QWMatrix m_currentRulerZoomMatrix;
+ TQWMatrix m_currentRulerZoomMatrix;
static const unsigned int RULERS_ROW;
static const unsigned int CONTROLS_ROW;
diff --git a/src/gui/general/EditViewBase.cpp b/src/gui/general/EditViewBase.cpp
index 0193beb..84bdef0 100644
--- a/src/gui/general/EditViewBase.cpp
+++ b/src/gui/general/EditViewBase.cpp
@@ -24,7 +24,7 @@
#include "EditViewBase.h"
-#include <qlayout.h>
+#include <tqlayout.h>
#include <kapplication.h>
#include <klocale.h>
@@ -56,15 +56,15 @@
#include <kstdaccel.h>
#include <kstdaction.h>
#include <kxmlguiclient.h>
-#include <qaccel.h>
-#include <qcanvas.h>
-#include <qdialog.h>
-#include <qframe.h>
-#include <qiconset.h>
-#include <qobject.h>
-#include <qpixmap.h>
-#include <qstring.h>
-#include <qwidget.h>
+#include <tqaccel.h>
+#include <tqcanvas.h>
+#include <tqdialog.h>
+#include <tqframe.h>
+#include <tqiconset.h>
+#include <tqobject.h>
+#include <tqpixmap.h>
+#include <tqstring.h>
+#include <tqwidget.h>
namespace Rosegarden
@@ -77,7 +77,7 @@ const unsigned int EditViewBase::NbLayoutRows = 6;
EditViewBase::EditViewBase(RosegardenGUIDoc *doc,
std::vector<Segment *> segments,
unsigned int cols,
- QWidget *parent, const char *name) :
+ TQWidget *parent, const char *name) :
KDockMainWindow(parent, name),
m_viewNumber( -1),
m_viewLocalPropertyPrefix(makeViewLocalPropertyPrefix()),
@@ -100,7 +100,7 @@ EditViewBase::EditViewBase(RosegardenGUIDoc *doc,
m_timeSigNotifier(new EditViewTimeSigNotifier(doc))
{
- QPixmap dummyPixmap; // any icon will do
+ TQPixmap dummyPixmap; // any icon will do
m_mainDockWidget = createDockWidget("Rosegarden EditView DockWidget", dummyPixmap,
0L, "editview_dock_widget");
// allow others to dock to the left and right sides only
@@ -110,8 +110,8 @@ EditViewBase::EditViewBase(RosegardenGUIDoc *doc,
setView(m_mainDockWidget); // central widget in a KDE mainwindow
setMainDockWidget(m_mainDockWidget); // master dockwidget
- m_centralFrame = new QFrame(m_mainDockWidget, "centralframe");
- m_grid = new QGridLayout(m_centralFrame, NbLayoutRows, cols);
+ m_centralFrame = new TQFrame(m_mainDockWidget, "centralframe");
+ m_grid = new TQGridLayout(m_centralFrame, NbLayoutRows, cols);
m_mainDockWidget->setWidget(m_centralFrame);
@@ -119,17 +119,17 @@ EditViewBase::EditViewBase(RosegardenGUIDoc *doc,
m_doc->attachEditView(this);
- QObject::connect
- (getCommandHistory(), SIGNAL(commandExecuted()),
- this, SLOT(update()));
+ TQObject::connect
+ (getCommandHistory(), TQT_SIGNAL(commandExecuted()),
+ this, TQT_SLOT(update()));
- QObject::connect
- (getCommandHistory(), SIGNAL(commandExecuted()),
- this, SLOT(slotTestClipboard()));
+ TQObject::connect
+ (getCommandHistory(), TQT_SIGNAL(commandExecuted()),
+ this, TQT_SLOT(slotTestClipboard()));
// create accelerators
//
- m_accelerators = new QAccel(this);
+ m_accelerators = new TQAccel(this);
}
EditViewBase::~EditViewBase()
@@ -152,39 +152,39 @@ void EditViewBase::readOptions()
getToggleAction("options_show_toolbar")->setChecked(!toolBar()->isHidden());
}
-void EditViewBase::setupActions(QString rcFileName, bool haveClipboard)
+void EditViewBase::setupActions(TQString rcFileName, bool haveClipboard)
{
setRCFileName(rcFileName);
// Actions all edit views will have
- KStdAction::showToolbar(this, SLOT(slotToggleToolBar()),
+ KStdAction::showToolbar(this, TQT_SLOT(slotToggleToolBar()),
actionCollection(), "options_show_toolbar");
- KStdAction::showStatusbar(this, SLOT(slotToggleStatusBar()),
+ KStdAction::showStatusbar(this, TQT_SLOT(slotToggleStatusBar()),
actionCollection(), "options_show_statusbar");
KStdAction::preferences(this,
- SLOT(slotConfigure()),
+ TQT_SLOT(slotConfigure()),
actionCollection());
KStdAction::keyBindings(this,
- SLOT(slotEditKeys()),
+ TQT_SLOT(slotEditKeys()),
actionCollection());
KStdAction::configureToolbars(this,
- SLOT(slotEditToolbars()),
+ TQT_SLOT(slotEditToolbars()),
actionCollection());
// File menu
- KStdAction::save (this, SIGNAL(saveFile()), actionCollection());
- KStdAction::close(this, SLOT(slotCloseWindow()), actionCollection());
+ KStdAction::save (this, TQT_SIGNAL(saveFile()), actionCollection());
+ KStdAction::close(this, TQT_SLOT(slotCloseWindow()), actionCollection());
if (haveClipboard) {
- KStdAction::cut (this, SLOT(slotEditCut()), actionCollection());
- KStdAction::copy (this, SLOT(slotEditCopy()), actionCollection());
- KStdAction::paste (this, SLOT(slotEditPaste()), actionCollection());
+ KStdAction::cut (this, TQT_SLOT(slotEditCut()), actionCollection());
+ KStdAction::copy (this, TQT_SLOT(slotEditCopy()), actionCollection());
+ KStdAction::paste (this, TQT_SLOT(slotEditPaste()), actionCollection());
}
new KToolBarPopupAction(i18n("Und&o"),
@@ -199,38 +199,38 @@ void EditViewBase::setupActions(QString rcFileName, bool haveClipboard)
actionCollection(),
KStdAction::stdName(KStdAction::Redo));
- QString pixmapDir = KGlobal::dirs()->findResource("appdata", "pixmaps/");
+ TQString pixmapDir = KGlobal::dirs()->findResource("appdata", "pixmaps/");
- QCanvasPixmap pixmap(pixmapDir + "/toolbar/matrix.png");
- QIconSet icon = QIconSet(pixmap);
+ TQCanvasPixmap pixmap(pixmapDir + "/toolbar/matrix.png");
+ TQIconSet icon = TQIconSet(pixmap);
new KAction(i18n("Open in Matri&x Editor"), icon, 0, this,
- SLOT(slotOpenInMatrix()), actionCollection(),
+ TQT_SLOT(slotOpenInMatrix()), actionCollection(),
"open_in_matrix");
pixmap.load(pixmapDir + "/toolbar/matrix-percussion.png");
- icon = QIconSet(pixmap);
+ icon = TQIconSet(pixmap);
new KAction(i18n("Open in &Percussion Matrix Editor"), icon, 0, this,
- SLOT(slotOpenInPercussionMatrix()), actionCollection(),
+ TQT_SLOT(slotOpenInPercussionMatrix()), actionCollection(),
"open_in_percussion_matrix");
pixmap.load(pixmapDir + "/toolbar/notation.png");
- icon = QIconSet(pixmap);
+ icon = TQIconSet(pixmap);
new KAction(i18n("Open in &Notation Editor"), icon, 0, this,
- SLOT(slotOpenInNotation()), actionCollection(),
+ TQT_SLOT(slotOpenInNotation()), actionCollection(),
"open_in_notation");
pixmap.load(pixmapDir + "/toolbar/eventlist.png");
- icon = QIconSet(pixmap);
+ icon = TQIconSet(pixmap);
new KAction(i18n("Open in &Event List Editor"), icon, 0, this,
- SLOT(slotOpenInEventList()), actionCollection(),
+ TQT_SLOT(slotOpenInEventList()), actionCollection(),
"open_in_event_list");
new KAction(i18n("Set Segment Start Time..."), 0, this,
- SLOT(slotSetSegmentStartTime()), actionCollection(),
+ TQT_SLOT(slotSetSegmentStartTime()), actionCollection(),
"set_segment_start");
new KAction(i18n("Set Segment Duration..."), 0, this,
- SLOT(slotSetSegmentDuration()), actionCollection(),
+ TQT_SLOT(slotSetSegmentDuration()), actionCollection(),
"set_segment_duration");
// add undo and redo to edit menu and toolbar
@@ -256,8 +256,8 @@ void EditViewBase::slotEditToolbars()
{
KEditToolbar dlg(actionCollection(), getRCFileName());
- connect(&dlg, SIGNAL(newToolbarConfig()),
- SLOT(slotUpdateToolbars()));
+ connect(&dlg, TQT_SIGNAL(newToolbarConfig()),
+ TQT_SLOT(slotUpdateToolbars()));
dlg.exec();
}
@@ -308,7 +308,7 @@ EditViewBase::makeViewLocalPropertyPrefix()
return buffer;
}
-void EditViewBase::paintEvent(QPaintEvent* e)
+void EditViewBase::paintEvent(TQPaintEvent* e)
{
// It is possible for this function to be called re-entrantly,
// because a re-layout procedure may deliberately ask the event
@@ -322,13 +322,13 @@ void EditViewBase::paintEvent(QPaintEvent* e)
if (e) {
if (m_havePendingPaintEvent) {
if (m_pendingPaintEvent) {
- QRect r = m_pendingPaintEvent->rect().unite(e->rect());
- *m_pendingPaintEvent = QPaintEvent(r);
+ TQRect r = m_pendingPaintEvent->rect().unite(e->rect());
+ *m_pendingPaintEvent = TQPaintEvent(r);
} else {
- m_pendingPaintEvent = new QPaintEvent(*e);
+ m_pendingPaintEvent = new TQPaintEvent(*e);
}
} else {
- m_pendingPaintEvent = new QPaintEvent(*e);
+ m_pendingPaintEvent = new TQPaintEvent(*e);
}
}
m_havePendingPaintEvent = true;
@@ -438,7 +438,7 @@ void EditViewBase::paintEvent(QPaintEvent* e)
*/
}
-void EditViewBase::closeEvent(QCloseEvent* e)
+void EditViewBase::closeEvent(TQCloseEvent* e)
{
RG_DEBUG << "EditViewBase::closeEvent()\n";
@@ -492,7 +492,7 @@ void EditViewBase::slotToggleStatusBar()
statusBar()->show();
}
-void EditViewBase::slotStatusMsg(const QString &text)
+void EditViewBase::slotStatusMsg(const TQString &text)
{
///////////////////////////////////////////////////////////////////
// change status message permanently
@@ -500,7 +500,7 @@ void EditViewBase::slotStatusMsg(const QString &text)
statusBar()->changeItem(text, ID_STATUS_MSG);
}
-void EditViewBase::slotStatusHelpMsg(const QString &text)
+void EditViewBase::slotStatusHelpMsg(const TQString &text)
{
///////////////////////////////////////////////////////////////////
// change status message of whole statusbar temporary (text, msec)
@@ -550,8 +550,8 @@ bool EditViewBase::getSegmentsOnlyRestsAndClefs()
}
-void EditViewBase::toggleWidget(QWidget* widget,
- const QString& toggleActionName)
+void EditViewBase::toggleWidget(TQWidget* widget,
+ const TQString& toggleActionName)
{
KToggleAction* toggleAction = getToggleAction(toggleActionName);
@@ -602,7 +602,7 @@ EditViewBase::slotToggleSolo()
}
void
-EditViewBase::slotStateChanged(const QString& s,
+EditViewBase::slotStateChanged(const TQString& s,
bool noReverse)
{
RG_DEBUG << "EditViewBase::slotStateChanged " << s << ", " << noReverse << endl;
@@ -620,7 +620,7 @@ EditViewBase::slotSetSegmentStartTime()
&getDocument()->getComposition(),
s->getStartTime(), false);
- if (dialog.exec() == QDialog::Accepted) {
+ if (dialog.exec() == TQDialog::Accepted) {
SegmentReconfigureCommand *command =
new SegmentReconfigureCommand(i18n("Set Segment Start Time"));
@@ -646,7 +646,7 @@ EditViewBase::slotSetSegmentDuration()
s->getStartTime(),
s->getEndMarkerTime() - s->getStartTime(), false);
- if (dialog.exec() == QDialog::Accepted) {
+ if (dialog.exec() == TQDialog::Accepted) {
SegmentReconfigureCommand *command =
new SegmentReconfigureCommand(i18n("Set Segment Duration"));
@@ -702,7 +702,7 @@ MultiViewCommandHistory* EditViewBase::getCommandHistory()
return getDocument()->getCommandHistory();
}
-KToggleAction* EditViewBase::getToggleAction(const QString& actionName)
+KToggleAction* EditViewBase::getToggleAction(const TQString& actionName)
{
return dynamic_cast<KToggleAction*>(actionCollection()->action(actionName));
}
diff --git a/src/gui/general/EditViewBase.h b/src/gui/general/EditViewBase.h
index 03784cb..f263795 100644
--- a/src/gui/general/EditViewBase.h
+++ b/src/gui/general/EditViewBase.h
@@ -28,17 +28,17 @@
#include <set>
#include <string>
#include <kdockwidget.h>
-#include <qstring.h>
+#include <tqstring.h>
#include <vector>
#include "base/Event.h"
-class QWidget;
-class QPaintEvent;
-class QGridLayout;
-class QFrame;
-class QCloseEvent;
-class QAccel;
+class TQWidget;
+class TQPaintEvent;
+class TQGridLayout;
+class TQFrame;
+class TQCloseEvent;
+class TQAccel;
class KToggleAction;
class KConfig;
class KCommand;
@@ -72,7 +72,7 @@ public:
EditViewBase(RosegardenGUIDoc *doc,
std::vector<Segment *> segments,
unsigned int cols,
- QWidget *parent,
+ TQWidget *parent,
const char *name = 0);
virtual ~EditViewBase();
@@ -114,7 +114,7 @@ public:
/**
* Return our local accelerator object
*/
- QAccel* getAccelerators() { return m_accelerators; }
+ TQAccel* getAccelerators() { return m_accelerators; }
/**
* Return a string unique to this view (amongst views currently
@@ -208,7 +208,7 @@ public slots:
*
* @param text the text that is displayed in the statusbar
*/
- virtual void slotStatusMsg(const QString &text);
+ virtual void slotStatusMsg(const TQString &text);
/**
* Changes the status message of the whole statusbar for two
@@ -218,7 +218,7 @@ public slots:
*
* @param text the text that is displayed in the statusbar
*/
- virtual void slotStatusHelpMsg(const QString &text);
+ virtual void slotStatusHelpMsg(const TQString &text);
/**
* A command has happened; check the clipboard in case we
@@ -231,7 +231,7 @@ public slots:
*/
virtual void slotToggleSolo();
- void slotStateChanged(const QString&, bool noReverse);
+ void slotStateChanged(const TQString&, bool noReverse);
virtual void slotOpenInMatrix();
virtual void slotOpenInPercussionMatrix();
@@ -257,12 +257,12 @@ protected:
virtual void windowActivationChange(bool);
- virtual void paintEvent(QPaintEvent* e);
+ virtual void paintEvent(TQPaintEvent* e);
/**
* @see #setInCtor
*/
- virtual void closeEvent(QCloseEvent* e);
+ virtual void closeEvent(TQCloseEvent* e);
/**
* ignore close events while we're in ctor
@@ -290,7 +290,7 @@ protected:
/**
* create menus and toolbars
*/
- virtual void setupActions(QString rcFileName, bool haveClipboard = true);
+ virtual void setupActions(TQString rcFileName, bool haveClipboard = true);
/**
* setup status bar
@@ -320,7 +320,7 @@ protected slots:
virtual void slotUpdateToolbars();
protected:
- QWidget* getCentralWidget() { return m_centralFrame; }
+ TQWidget* getCentralWidget() { return m_centralFrame; }
void initSegmentRefreshStatusIds();
@@ -334,16 +334,16 @@ protected:
bool getSegmentsOnlyRestsAndClefs();
/// Convenience function around actionCollection()->action()
- KToggleAction* getToggleAction(const QString& actionName);
+ KToggleAction* getToggleAction(const TQString& actionName);
/**
* Make a widget visible depending on the state of a
* KToggleAction
*/
- virtual void toggleWidget(QWidget* widget, const QString& toggleActionName);
+ virtual void toggleWidget(TQWidget* widget, const TQString& toggleActionName);
- void setRCFileName(QString s) { m_rcFileName = s; }
- QString getRCFileName() { return m_rcFileName; }
+ void setRCFileName(TQString s) { m_rcFileName = s; }
+ TQString getRCFileName() { return m_rcFileName; }
/**
* Set the page index of the config dialog which corresponds to
@@ -353,7 +353,7 @@ protected:
int getConfigDialogPageIndex() { return m_configDialogPageIndex; }
//--------------- Data members ---------------------------------
- QString m_rcFileName;
+ TQString m_rcFileName;
static std::set<int> m_viewNumberPool;
std::string makeViewLocalPropertyPrefix();
@@ -370,18 +370,18 @@ protected:
EditToolBox* m_toolBox;
KDockWidget *m_mainDockWidget;
- QFrame *m_centralFrame;
- QGridLayout *m_grid;
+ TQFrame *m_centralFrame;
+ TQGridLayout *m_grid;
unsigned int m_mainCol;
unsigned int m_compositionRefreshStatusId;
bool m_needUpdate;
- QPaintEvent *m_pendingPaintEvent;
+ TQPaintEvent *m_pendingPaintEvent;
bool m_havePendingPaintEvent;
static bool m_inPaintEvent; // true if _any_ edit view is in a paint event
- QAccel *m_accelerators;
+ TQAccel *m_accelerators;
int m_configDialogPageIndex;
diff --git a/src/gui/general/GUIPalette.cpp b/src/gui/general/GUIPalette.cpp
index 4705c21..a58886e 100644
--- a/src/gui/general/GUIPalette.cpp
+++ b/src/gui/general/GUIPalette.cpp
@@ -29,112 +29,112 @@
#include "base/Colour.h"
#include "document/ConfigGroups.h"
#include <kconfig.h>
-#include <qcolor.h>
+#include <tqcolor.h>
namespace Rosegarden
{
-QColor GUIPalette::getColour(const char* const colourName)
+TQColor GUIPalette::getColour(const char* const colourName)
{
KConfig* config = kapp->config();
config->setGroup(ColoursConfigGroup);
- QColor res = getInstance()->m_defaultsMap[colourName];
+ TQColor res = getInstance()->m_defaultsMap[colourName];
config->readColorEntry(colourName, &res);
return res;
}
-Colour GUIPalette::convertColour(const QColor &input)
+Colour GUIPalette::convertColour(const TQColor &input)
{
int r, g, b;
input.rgb(&r, &g, &b);
return Colour(r, g, b);
}
-QColor GUIPalette::convertColour(const Colour& input)
+TQColor GUIPalette::convertColour(const Colour& input)
{
- return QColor(input.getRed(), input.getGreen(), input.getBlue());
+ return TQColor(input.getRed(), input.getGreen(), input.getBlue());
}
GUIPalette::GUIPalette()
{
m_defaultsMap[ActiveRecordTrack] = Qt::red;
- m_defaultsMap[SegmentCanvas] = QColor(230, 230, 230);
+ m_defaultsMap[SegmentCanvas] = TQColor(230, 230, 230);
m_defaultsMap[SegmentBorder] = Qt::black;
// 1.0 colors
- // m_defaultsMap[RecordingInternalSegmentBlock] = QColor(255, 182, 193);
- // m_defaultsMap[RecordingAudioSegmentBlock] = QColor(182, 222, 255);
+ // m_defaultsMap[RecordingInternalSegmentBlock] = TQColor(255, 182, 193);
+ // m_defaultsMap[RecordingAudioSegmentBlock] = TQColor(182, 222, 255);
// MIDI recording preview (pale yellow)
- m_defaultsMap[RecordingInternalSegmentBlock] = QColor(255, 234, 182);
+ m_defaultsMap[RecordingInternalSegmentBlock] = TQColor(255, 234, 182);
// audio recording preview (pale red)
- m_defaultsMap[RecordingAudioSegmentBlock] = QColor(255, 182, 193);
+ m_defaultsMap[RecordingAudioSegmentBlock] = TQColor(255, 182, 193);
m_defaultsMap[RecordingSegmentBorder] = Qt::black;
- m_defaultsMap[RepeatSegmentBorder] = QColor(130, 133, 170);
+ m_defaultsMap[RepeatSegmentBorder] = TQColor(130, 133, 170);
- m_defaultsMap[SegmentAudioPreview] = QColor(39, 71, 22);
+ m_defaultsMap[SegmentAudioPreview] = TQColor(39, 71, 22);
m_defaultsMap[SegmentInternalPreview] = Qt::white;
m_defaultsMap[SegmentLabel] = Qt::black;
m_defaultsMap[SegmentSplitLine] = Qt::black;
m_defaultsMap[MatrixElementBorder] = Qt::black;
- m_defaultsMap[MatrixElementBlock] = QColor(98, 128, 232);
+ m_defaultsMap[MatrixElementBlock] = TQColor(98, 128, 232);
m_defaultsMap[MatrixOverlapBlock] = Qt::black;
- m_defaultsMap[LoopRulerBackground] = QColor(120, 120, 120);
+ m_defaultsMap[LoopRulerBackground] = TQColor(120, 120, 120);
m_defaultsMap[LoopRulerForeground] = Qt::white;
m_defaultsMap[LoopHighlight] = Qt::white;
- m_defaultsMap[TempoBase] = QColor(197, 211, 125);
+ m_defaultsMap[TempoBase] = TQColor(197, 211, 125);
- //m_defaultsMap[TextRulerBackground] = QColor(60, 205, 230, QColor::Hsv);
- // m_defaultsMap[TextRulerBackground] = QColor(120, 90, 238, QColor::Hsv);
- // m_defaultsMap[TextRulerBackground] = QColor(210, 220, 140);
- m_defaultsMap[TextRulerBackground] = QColor(226, 232, 187);
+ //m_defaultsMap[TextRulerBackground] = TQColor(60, 205, 230, TQColor::Hsv);
+ // m_defaultsMap[TextRulerBackground] = TQColor(120, 90, 238, TQColor::Hsv);
+ // m_defaultsMap[TextRulerBackground] = TQColor(210, 220, 140);
+ m_defaultsMap[TextRulerBackground] = TQColor(226, 232, 187);
m_defaultsMap[TextRulerForeground] = Qt::white;
- m_defaultsMap[ChordNameRulerBackground] = QColor(230, 230, 230);
+ m_defaultsMap[ChordNameRulerBackground] = TQColor(230, 230, 230);
m_defaultsMap[ChordNameRulerForeground] = Qt::black;
- m_defaultsMap[RawNoteRulerBackground] = QColor(240, 240, 240);
+ m_defaultsMap[RawNoteRulerBackground] = TQColor(240, 240, 240);
m_defaultsMap[RawNoteRulerForeground] = Qt::black;
- m_defaultsMap[LevelMeterGreen] = QColor(0, 200, 0);
- m_defaultsMap[LevelMeterOrange] = QColor(255, 165, 0);
- m_defaultsMap[LevelMeterRed] = QColor(200, 0, 0);
+ m_defaultsMap[LevelMeterGreen] = TQColor(0, 200, 0);
+ m_defaultsMap[LevelMeterOrange] = TQColor(255, 165, 0);
+ m_defaultsMap[LevelMeterRed] = TQColor(200, 0, 0);
- // m_defaultsMap[LevelMeterSolidGreen] = QColor(0, 140, 0);
- m_defaultsMap[LevelMeterSolidGreen] = QColor(84, 177, 248); // blue!
- // m_defaultsMap[LevelMeterSolidOrange] = QColor(220, 120, 0);
- m_defaultsMap[LevelMeterSolidOrange] = QColor(255, 225, 0);
- // m_defaultsMap[LevelMeterSolidRed] = QColor(255, 50, 50);
- m_defaultsMap[LevelMeterSolidRed] = QColor(255, 0, 0);
+ // m_defaultsMap[LevelMeterSolidGreen] = TQColor(0, 140, 0);
+ m_defaultsMap[LevelMeterSolidGreen] = TQColor(84, 177, 248); // blue!
+ // m_defaultsMap[LevelMeterSolidOrange] = TQColor(220, 120, 0);
+ m_defaultsMap[LevelMeterSolidOrange] = TQColor(255, 225, 0);
+ // m_defaultsMap[LevelMeterSolidRed] = TQColor(255, 50, 50);
+ m_defaultsMap[LevelMeterSolidRed] = TQColor(255, 0, 0);
m_defaultsMap[BarLine] = Qt::black;
- m_defaultsMap[BarLineIncorrect] = QColor(211, 0, 31);
- m_defaultsMap[BeatLine] = QColor(100, 100, 100);
- m_defaultsMap[SubBeatLine] = QColor(212, 212, 212);
- m_defaultsMap[StaffConnectingLine] = QColor(192, 192, 192);
- m_defaultsMap[StaffConnectingTerminatingLine] = QColor(128, 128, 128);
+ m_defaultsMap[BarLineIncorrect] = TQColor(211, 0, 31);
+ m_defaultsMap[BeatLine] = TQColor(100, 100, 100);
+ m_defaultsMap[SubBeatLine] = TQColor(212, 212, 212);
+ m_defaultsMap[StaffConnectingLine] = TQColor(192, 192, 192);
+ m_defaultsMap[StaffConnectingTerminatingLine] = TQColor(128, 128, 128);
m_defaultsMap[Pointer] = Qt::darkBlue;
- m_defaultsMap[PointerRuler] = QColor(100, 100, 100);
+ m_defaultsMap[PointerRuler] = TQColor(100, 100, 100);
- m_defaultsMap[InsertCursor] = QColor(160, 104, 186);
- m_defaultsMap[InsertCursorRuler] = QColor(160, 136, 170);
+ m_defaultsMap[InsertCursor] = TQColor(160, 104, 186);
+ m_defaultsMap[InsertCursorRuler] = TQColor(160, 136, 170);
- m_defaultsMap[TrackDivider] = QColor(145, 145, 145);
- //m_defaultsMap[MovementGuide] = QColor(172, 230, 139);
- m_defaultsMap[MovementGuide] = QColor(62, 161, 194);
- //m_defaultsMap[MovementGuide] = QColor(255, 189, 89);
- m_defaultsMap[SelectionRectangle] = QColor(103, 128, 211);
- m_defaultsMap[SelectedElement] = QColor(0, 54, 232);
+ m_defaultsMap[TrackDivider] = TQColor(145, 145, 145);
+ //m_defaultsMap[MovementGuide] = TQColor(172, 230, 139);
+ m_defaultsMap[MovementGuide] = TQColor(62, 161, 194);
+ //m_defaultsMap[MovementGuide] = TQColor(255, 189, 89);
+ m_defaultsMap[SelectionRectangle] = TQColor(103, 128, 211);
+ m_defaultsMap[SelectedElement] = TQColor(0, 54, 232);
const int SelectedElementHue = 225;
const int SelectedElementMinValue = 220;
@@ -147,42 +147,42 @@ GUIPalette::GUIPalette()
const int OutRangeNoteHue = 0;
const int OutRangeNoteMinValue = 200;
- m_defaultsMap[TextAnnotationBackground] = QColor(255, 255, 180);
+ m_defaultsMap[TextAnnotationBackground] = TQColor(255, 255, 180);
- m_defaultsMap[TextLilyPondDirectiveBackground] = QColor(95, 157, 87);
+ m_defaultsMap[TextLilyPondDirectiveBackground] = TQColor(95, 157, 87);
m_defaultsMap[AudioCountdownBackground] = Qt::darkGray;
m_defaultsMap[AudioCountdownForeground] = Qt::red;
// m_defaultsMap[RotaryFloatBackground] = Qt::cyan;
- m_defaultsMap[RotaryFloatBackground] = QColor(182, 222, 255);
+ m_defaultsMap[RotaryFloatBackground] = TQColor(182, 222, 255);
m_defaultsMap[RotaryFloatForeground] = Qt::black;
- m_defaultsMap[RotaryPastelBlue] = QColor(205, 212, 255);
- m_defaultsMap[RotaryPastelRed] = QColor(255, 168, 169);
- m_defaultsMap[RotaryPastelGreen] = QColor(231, 255, 223);
- m_defaultsMap[RotaryPastelOrange] = QColor(255, 233, 208);
- m_defaultsMap[RotaryPastelYellow] = QColor(249, 255, 208);
+ m_defaultsMap[RotaryPastelBlue] = TQColor(205, 212, 255);
+ m_defaultsMap[RotaryPastelRed] = TQColor(255, 168, 169);
+ m_defaultsMap[RotaryPastelGreen] = TQColor(231, 255, 223);
+ m_defaultsMap[RotaryPastelOrange] = TQColor(255, 233, 208);
+ m_defaultsMap[RotaryPastelYellow] = TQColor(249, 255, 208);
- m_defaultsMap[MatrixKeyboardFocus] = QColor(224, 112, 8);
+ m_defaultsMap[MatrixKeyboardFocus] = TQColor(224, 112, 8);
- // m_defaultsMap[RotaryPlugin] = QColor(185, 255, 248);
- m_defaultsMap[RotaryPlugin] = QColor(185, 200, 248);
- // m_defaultsMap[RotaryPlugin] = QColor(185, 185, 185);
+ // m_defaultsMap[RotaryPlugin] = TQColor(185, 255, 248);
+ m_defaultsMap[RotaryPlugin] = TQColor(185, 200, 248);
+ // m_defaultsMap[RotaryPlugin] = TQColor(185, 185, 185);
- m_defaultsMap[RotaryMeter] = QColor(255, 100, 0);
+ m_defaultsMap[RotaryMeter] = TQColor(255, 100, 0);
- m_defaultsMap[MarkerBackground] = QColor(185, 255, 248);
+ m_defaultsMap[MarkerBackground] = TQColor(185, 255, 248);
m_defaultsMap[QuickMarker] = Qt::red;
- // m_defaultsMap[MuteTrackLED] = QColor(218, 190, 230, QColor::Hsv);
- m_defaultsMap[MuteTrackLED] = QColor(211, 194, 238, QColor::Hsv);
- m_defaultsMap[RecordMIDITrackLED] = QColor(45, 250, 225, QColor::Hsv);
- m_defaultsMap[RecordAudioTrackLED] = QColor(0, 250, 225, QColor::Hsv);
+ // m_defaultsMap[MuteTrackLED] = TQColor(218, 190, 230, TQColor::Hsv);
+ m_defaultsMap[MuteTrackLED] = TQColor(211, 194, 238, TQColor::Hsv);
+ m_defaultsMap[RecordMIDITrackLED] = TQColor(45, 250, 225, TQColor::Hsv);
+ m_defaultsMap[RecordAudioTrackLED] = TQColor(0, 250, 225, TQColor::Hsv);
- m_defaultsMap[PlaybackFaderOutline] = QColor(211, 194, 238, QColor::Hsv);
- m_defaultsMap[RecordFaderOutline] = QColor(0, 250, 225, QColor::Hsv);
+ m_defaultsMap[PlaybackFaderOutline] = TQColor(211, 194, 238, TQColor::Hsv);
+ m_defaultsMap[RecordFaderOutline] = TQColor(0, 250, 225, TQColor::Hsv);
}
GUIPalette* GUIPalette::getInstance()
diff --git a/src/gui/general/GUIPalette.h b/src/gui/general/GUIPalette.h
index c8760fb..e2e2dd6 100644
--- a/src/gui/general/GUIPalette.h
+++ b/src/gui/general/GUIPalette.h
@@ -28,7 +28,7 @@
#include "base/Colour.h"
#include <map>
-#include <qcolor.h>
+#include <tqcolor.h>
@@ -50,10 +50,10 @@ namespace Rosegarden
class GUIPalette
{
public:
- static QColor getColour(const char* const colourName);
+ static TQColor getColour(const char* const colourName);
- static Colour convertColour(const QColor &input);
- static QColor convertColour(const Colour &input);
+ static Colour convertColour(const TQColor &input);
+ static TQColor convertColour(const Colour &input);
static const char* const ActiveRecordTrack;
@@ -167,13 +167,13 @@ public:
protected:
GUIPalette();
- QColor getDefaultColour(const char* const colourName);
+ TQColor getDefaultColour(const char* const colourName);
//--------------- Data members ---------------------------------
static GUIPalette* getInstance();
static GUIPalette* m_instance;
- typedef std::map<const char* const, QColor> colourmap;
+ typedef std::map<const char* const, TQColor> colourmap;
colourmap m_defaultsMap;
};
diff --git a/src/gui/general/LinedStaff.cpp b/src/gui/general/LinedStaff.cpp
index e2e5d12..5a4fbb6 100644
--- a/src/gui/general/LinedStaff.cpp
+++ b/src/gui/general/LinedStaff.cpp
@@ -36,13 +36,13 @@
#include "base/ViewElement.h"
#include "GUIPalette.h"
#include "BarLine.h"
-#include <qcanvas.h>
-#include <qcolor.h>
-#include <qfont.h>
-#include <qfontmetrics.h>
-#include <qpen.h>
-#include <qrect.h>
-#include <qstring.h>
+#include <tqcanvas.h>
+#include <tqcolor.h>
+#include <tqfont.h>
+#include <tqfontmetrics.h>
+#include <tqpen.h>
+#include <tqrect.h>
+#include <tqstring.h>
#include <algorithm>
@@ -54,7 +54,7 @@ namespace Rosegarden
const int pointerWidth = 3;
-LinedStaff::LinedStaff(QCanvas *canvas, Segment *segment,
+LinedStaff::LinedStaff(TQCanvas *canvas, Segment *segment,
SnapGrid *snapGrid, int id,
int resolution, int lineThickness) :
Staff(*segment),
@@ -75,15 +75,15 @@ LinedStaff::LinedStaff(QCanvas *canvas, Segment *segment,
m_startLayoutX(0),
m_endLayoutX(0),
m_current(false),
- m_pointer(new QCanvasLine(canvas)),
- m_insertCursor(new QCanvasLine(canvas)),
+ m_pointer(new TQCanvasLine(canvas)),
+ m_insertCursor(new TQCanvasLine(canvas)),
m_insertCursorTime(segment->getStartTime()),
m_insertCursorTimeValid(false)
{
initCursors();
}
-LinedStaff::LinedStaff(QCanvas *canvas, Segment *segment,
+LinedStaff::LinedStaff(TQCanvas *canvas, Segment *segment,
SnapGrid *snapGrid,
int id, int resolution, int lineThickness,
double pageWidth, int rowsPerPage, int rowSpacing) :
@@ -105,15 +105,15 @@ LinedStaff::LinedStaff(QCanvas *canvas, Segment *segment,
m_startLayoutX(0),
m_endLayoutX(0),
m_current(false),
- m_pointer(new QCanvasLine(canvas)),
- m_insertCursor(new QCanvasLine(canvas)),
+ m_pointer(new TQCanvasLine(canvas)),
+ m_insertCursor(new TQCanvasLine(canvas)),
m_insertCursorTime(segment->getStartTime()),
m_insertCursorTimeValid(false)
{
initCursors();
}
-LinedStaff::LinedStaff(QCanvas *canvas, Segment *segment,
+LinedStaff::LinedStaff(TQCanvas *canvas, Segment *segment,
SnapGrid *snapGrid,
int id, int resolution, int lineThickness,
PageMode pageMode, double pageWidth, int rowsPerPage,
@@ -136,8 +136,8 @@ LinedStaff::LinedStaff(QCanvas *canvas, Segment *segment,
m_startLayoutX(0),
m_endLayoutX(0),
m_current(false),
- m_pointer(new QCanvasLine(canvas)),
- m_insertCursor(new QCanvasLine(canvas)),
+ m_pointer(new TQCanvasLine(canvas)),
+ m_insertCursor(new TQCanvasLine(canvas)),
m_insertCursorTime(segment->getStartTime()),
m_insertCursorTimeValid(false)
{
@@ -156,7 +156,7 @@ LinedStaff::~LinedStaff()
void
LinedStaff::initCursors()
{
- QPen pen(GUIPalette::getColour(GUIPalette::Pointer));
+ TQPen pen(GUIPalette::getColour(GUIPalette::Pointer));
pen.setWidth(pointerWidth);
m_pointer->setPen(pen);
@@ -455,7 +455,7 @@ LinedStaff::getBarExtents(double x, int y) const
if (line->x() <= x)
continue;
- return QRect(int(m_barLines[i -1]->x()),
+ return TQRect(int(m_barLines[i -1]->x()),
getCanvasYForTopOfStaff(barRow),
int(line->x() - m_barLines[i - 1]->x()),
getHeightOfRow());
@@ -463,7 +463,7 @@ LinedStaff::getBarExtents(double x, int y) const
}
// failure
- return QRect(int(getX() + getMargin()), getCanvasYForTopOfStaff(), 4, getHeightOfRow());
+ return TQRect(int(getX() + getMargin()), getCanvasYForTopOfStaff(), 4, getHeightOfRow());
}
double
@@ -779,12 +779,12 @@ LinedStaff::insertBar(double layoutX, double width, bool isCorrect,
if (showBarNo) {
- QFont font;
+ TQFont font;
font.setPixelSize(m_resolution * 3 / 2);
- QFontMetrics metrics(font);
- QString text = QString("%1").arg(barNo + 1);
+ TQFontMetrics metrics(font);
+ TQString text = TQString("%1").arg(barNo + 1);
- QCanvasItem *barNoText = new QCanvasText(text, font, m_canvas);
+ TQCanvasItem *barNoText = new TQCanvasText(text, font, m_canvas);
barNoText->setX(x);
barNoText->setY(y - metrics.height() - m_resolution * 2);
barNoText->setZ( -1);
@@ -796,7 +796,7 @@ LinedStaff::insertBar(double layoutX, double width, bool isCorrect,
m_barNumbers.push_back(barNoText);
}
- QCanvasRectangle *rect = 0;
+ TQCanvasRectangle *rect = 0;
if (showBeatLines()) {
@@ -987,7 +987,7 @@ LinedStaff::resizeStaffLineRow(int row, double x, double length)
level = 200;
}
- QColor lineColour(level, level, level);
+ TQColor lineColour(level, level, level);
int h;
@@ -1009,7 +1009,7 @@ LinedStaff::resizeStaffLineRow(int row, double x, double length)
// rather arbitrary (dup in insertBar)
int barThickness = m_resolution / 12 + 1;
y = getCanvasYForTopLine(row);
- QCanvasRectangle *line = new QCanvasRectangle
+ TQCanvasRectangle *line = new QCanvasRectangle
(int(x + length), y, barThickness, m_connectingLineLength, m_canvas);
line->setPen(GUIPalette::getColour(GUIPalette::StaffConnectingTerminatingLine));
line->setBrush(GUIPalette::getColour(GUIPalette::StaffConnectingTerminatingLine));
@@ -1041,18 +1041,18 @@ LinedStaff::resizeStaffLineRow(int row, double x, double length)
// << x << "," << y << ") to (" << (x+length-1)
// << "," << y << ")" << endl;
- QCanvasItem *line;
+ TQCanvasItem *line;
delete m_staffLines[row][lineIndex];
m_staffLines[row][lineIndex] = 0;
if (m_lineThickness > 1) {
- QCanvasRectangle *rline = new QCanvasRectangle
+ TQCanvasRectangle *rline = new QCanvasRectangle
(int(x), y, int(length), m_lineThickness, m_canvas);
rline->setPen(lineColour);
rline->setBrush(lineColour);
line = rline;
} else {
- QCanvasLine *lline = new QCanvasLine(m_canvas);
+ TQCanvasLine *lline = new TQCanvasLine(m_canvas);
lline->setPoints(int(x), y, int(x + length), y);
lline->setPen(lineColour);
line = lline;
diff --git a/src/gui/general/LinedStaff.h b/src/gui/general/LinedStaff.h
index 1444bd2..359becf 100644
--- a/src/gui/general/LinedStaff.h
+++ b/src/gui/general/LinedStaff.h
@@ -29,14 +29,14 @@
#include "base/FastVector.h"
#include "base/Staff.h"
#include "base/ViewElement.h"
-#include <qrect.h>
+#include <tqrect.h>
#include <utility>
#include <vector>
-class QCanvasLine;
-class QCanvasItem;
-class QCanvas;
+class TQCanvasLine;
+class TQCanvasItem;
+class TQCanvas;
class isFirstBarInRow;
class barNo;
@@ -99,7 +99,7 @@ protected:
* \a lineThickness is the number of pixels thick a
* staff line should be
*/
- LinedStaff(QCanvas *, Segment *, SnapGrid *,
+ LinedStaff(TQCanvas *, Segment *, SnapGrid *,
int id, int resolution, int lineThickness);
/**
@@ -125,7 +125,7 @@ protected:
* \a rowSpacing is the distance in pixels between
* the tops of consecutive rows on this staff
*/
- LinedStaff(QCanvas *, Segment *, SnapGrid *,
+ LinedStaff(TQCanvas *, Segment *, SnapGrid *,
int id, int resolution, int lineThickness,
double pageWidth, int rowsPerPage, int rowSpacing);
@@ -133,7 +133,7 @@ protected:
* Create a new LinedStaff for the given Segment, with
* either page or linear layout.
*/
- LinedStaff(QCanvas *, Segment *, SnapGrid *,
+ LinedStaff(TQCanvas *, Segment *, SnapGrid *,
int id, int resolution, int lineThickness, PageMode pageMode,
double pageWidth, int rowsPerPage, int rowSpacing);
@@ -370,7 +370,7 @@ public:
* Return the full width, height and origin of the bar containing
* the given canvas cooordinates.
*/
- virtual QRect getBarExtents(double x, int y) const;
+ virtual TQRect getBarExtents(double x, int y) const;
/**
* Set whether this is the current staff or not. A staff that is
@@ -709,7 +709,7 @@ protected:
//--------------- Data members ---------------------------------
- QCanvas *m_canvas;
+ TQCanvas *m_canvas;
SnapGrid *m_snapGrid;
int m_id;
@@ -732,12 +732,12 @@ protected:
bool m_current;
- typedef std::vector<QCanvasItem *> ItemList;
+ typedef std::vector<TQCanvasItem *> ItemList;
typedef std::vector<ItemList> ItemMatrix;
ItemMatrix m_staffLines;
ItemList m_staffConnectingLines;
- typedef std::pair<double, QCanvasItem *> LineRec; // layout-x, line
+ typedef std::pair<double, TQCanvasItem *> LineRec; // layout-x, line
typedef FastVector<LineRec> LineRecList;
typedef FastVector<BarLine *> BarLineList;//!!! should be multiset I reckon
static bool compareBars(const BarLine *, const BarLine *);
@@ -747,8 +747,8 @@ protected:
LineRecList m_barConnectingLines;
ItemList m_barNumbers;
- QCanvasLine *m_pointer;
- QCanvasLine *m_insertCursor;
+ TQCanvasLine *m_pointer;
+ TQCanvasLine *m_insertCursor;
timeT m_insertCursorTime;
bool m_insertCursorTimeValid;
};
diff --git a/src/gui/general/MidiPitchLabel.cpp b/src/gui/general/MidiPitchLabel.cpp
index 47a748b..f2d714d 100644
--- a/src/gui/general/MidiPitchLabel.cpp
+++ b/src/gui/general/MidiPitchLabel.cpp
@@ -29,13 +29,13 @@
#include "document/ConfigGroups.h"
#include <kconfig.h>
#include <klocale.h>
-#include <qstring.h>
+#include <tqstring.h>
namespace Rosegarden
{
-static QString notes[] = {
+static TQString notes[] = {
i18n("C%1"), i18n("C#%1"), i18n("D%1"), i18n("D#%1"),
i18n("E%1"), i18n("F%1"), i18n("F#%1"), i18n("G%1"),
i18n("G#%1"), i18n("A%1"), i18n("A#%1"), i18n("B%1")
diff --git a/src/gui/general/MidiPitchLabel.h b/src/gui/general/MidiPitchLabel.h
index 9abcc11..4bc5253 100644
--- a/src/gui/general/MidiPitchLabel.h
+++ b/src/gui/general/MidiPitchLabel.h
@@ -27,7 +27,7 @@
#define _RG_MIDIPITCHLABEL_H_
#include <string>
-#include <qstring.h>
+#include <tqstring.h>
@@ -43,10 +43,10 @@ public:
MidiPitchLabel(int pitch);
std::string getString() const;
- QString getQString() const;
+ TQString getQString() const;
private:
- QString m_midiNote;
+ TQString m_midiNote;
};
diff --git a/src/gui/general/PixmapFunctions.cpp b/src/gui/general/PixmapFunctions.cpp
index d297dad..f61ff11 100644
--- a/src/gui/general/PixmapFunctions.cpp
+++ b/src/gui/general/PixmapFunctions.cpp
@@ -25,11 +25,11 @@
#include "PixmapFunctions.h"
-#include <qbitmap.h>
-#include <qcolor.h>
-#include <qimage.h>
-#include <qpainter.h>
-#include <qpixmap.h>
+#include <tqbitmap.h>
+#include <tqcolor.h>
+#include <tqimage.h>
+#include <tqpainter.h>
+#include <tqpixmap.h>
#include <iostream>
@@ -37,10 +37,10 @@ namespace Rosegarden
{
QBitmap
-PixmapFunctions::generateMask(const QPixmap &map, const QRgb &px)
+PixmapFunctions::generateMask(const TQPixmap &map, const QRgb &px)
{
- QImage i(map.convertToImage());
- QImage im(i.width(), i.height(), 1, 2, QImage::LittleEndian);
+ TQImage i(map.convertToImage());
+ TQImage im(i.width(), i.height(), 1, 2, TQImage::LittleEndian);
for (int y = 0; y < i.height(); ++y) {
for (int x = 0; x < i.width(); ++x) {
@@ -52,16 +52,16 @@ PixmapFunctions::generateMask(const QPixmap &map, const QRgb &px)
}
}
- QBitmap m;
+ TQBitmap m;
m.convertFromImage(im);
return m;
}
QBitmap
-PixmapFunctions::generateMask(const QPixmap &map)
+PixmapFunctions::generateMask(const TQPixmap &map)
{
- QImage i(map.convertToImage());
- QImage im(i.width(), i.height(), 1, 2, QImage::LittleEndian);
+ TQImage i(map.convertToImage());
+ TQImage im(i.width(), i.height(), 1, 2, TQImage::LittleEndian);
QRgb px0(i.pixel(0, 0));
QRgb px1(i.pixel(i.width() - 1, 0));
@@ -82,18 +82,18 @@ PixmapFunctions::generateMask(const QPixmap &map)
}
}
- QBitmap m;
+ TQBitmap m;
m.convertFromImage(im);
return m;
}
QPixmap
-PixmapFunctions::colourPixmap(const QPixmap &map, int hue, int minValue)
+PixmapFunctions::colourPixmap(const TQPixmap &map, int hue, int minValue)
{
// assumes pixmap is currently in shades of grey; maps black ->
// solid colour and greys -> shades of colour
- QImage image = map.convertToImage();
+ TQImage image = map.convertToImage();
int s, v;
@@ -102,7 +102,7 @@ PixmapFunctions::colourPixmap(const QPixmap &map, int hue, int minValue)
for (int y = 0; y < image.height(); ++y) {
for (int x = 0; x < image.width(); ++x) {
- QColor pixel(image.pixel(x, y));
+ TQColor pixel(image.pixel(x, y));
int oldHue;
pixel.hsv(&oldHue, &s, &v);
@@ -118,59 +118,59 @@ PixmapFunctions::colourPixmap(const QPixmap &map, int hue, int minValue)
}
image.setPixel
- (x, y, QColor(hue,
+ (x, y, TQColor(hue,
255 - v,
v > minValue ? v : minValue,
- QColor::Hsv).rgb());
+ TQColor::Hsv).rgb());
}
}
- QPixmap rmap;
+ TQPixmap rmap;
rmap.convertFromImage(image);
- if (map.mask())
- rmap.setMask(*map.mask());
+ if (map.tqmask())
+ rmap.setMask(*map.tqmask());
return rmap;
}
QPixmap
-PixmapFunctions::shadePixmap(const QPixmap &map)
+PixmapFunctions::shadePixmap(const TQPixmap &map)
{
- QImage image = map.convertToImage();
+ TQImage image = map.convertToImage();
int h, s, v;
for (int y = 0; y < image.height(); ++y) {
for (int x = 0; x < image.width(); ++x) {
- QColor pixel(image.pixel(x, y));
+ TQColor pixel(image.pixel(x, y));
pixel.hsv(&h, &s, &v);
image.setPixel
- (x, y, QColor(h,
+ (x, y, TQColor(h,
s,
255 - ((255 - v) / 2),
- QColor::Hsv).rgb());
+ TQColor::Hsv).rgb());
}
}
- QPixmap rmap;
+ TQPixmap rmap;
rmap.convertFromImage(image);
- if (map.mask())
- rmap.setMask(*map.mask());
+ if (map.tqmask())
+ rmap.setMask(*map.tqmask());
return rmap;
}
QPixmap
-PixmapFunctions::flipVertical(const QPixmap &map)
+PixmapFunctions::flipVertical(const TQPixmap &map)
{
- QPixmap rmap;
- QImage i(map.convertToImage());
+ TQPixmap rmap;
+ TQImage i(map.convertToImage());
rmap.convertFromImage(i.mirror(false, true));
- if (map.mask()) {
- QImage im(map.mask()->convertToImage());
- QBitmap newMask;
+ if (map.tqmask()) {
+ TQImage im(map.tqmask()->convertToImage());
+ TQBitmap newMask;
newMask.convertFromImage(im.mirror(false, true));
rmap.setMask(newMask);
}
@@ -179,15 +179,15 @@ PixmapFunctions::flipVertical(const QPixmap &map)
}
QPixmap
-PixmapFunctions::flipHorizontal(const QPixmap &map)
+PixmapFunctions::flipHorizontal(const TQPixmap &map)
{
- QPixmap rmap;
- QImage i(map.convertToImage());
+ TQPixmap rmap;
+ TQImage i(map.convertToImage());
rmap.convertFromImage(i.mirror(true, false));
- if (map.mask()) {
- QImage im(map.mask()->convertToImage());
- QBitmap newMask;
+ if (map.tqmask()) {
+ TQImage im(map.tqmask()->convertToImage());
+ TQBitmap newMask;
newMask.convertFromImage(im.mirror(true, false));
rmap.setMask(newMask);
}
@@ -195,23 +195,23 @@ PixmapFunctions::flipHorizontal(const QPixmap &map)
return rmap;
}
-std::pair<QPixmap, QPixmap>
-PixmapFunctions::splitPixmap(const QPixmap &pixmap, int x)
+std::pair<TQPixmap, TQPixmap>
+PixmapFunctions::splitPixmap(const TQPixmap &pixmap, int x)
{
- QPixmap left(x, pixmap.height(), pixmap.depth());
- QBitmap leftMask(left.width(), left.height());
+ TQPixmap left(x, pixmap.height(), pixmap.depth());
+ TQBitmap leftMask(left.width(), left.height());
- QPixmap right(pixmap.width() - x, pixmap.height(), pixmap.depth());
- QBitmap rightMask(right.width(), right.height());
+ TQPixmap right(pixmap.width() - x, pixmap.height(), pixmap.depth());
+ TQBitmap rightMask(right.width(), right.height());
- QPainter paint;
+ TQPainter paint;
paint.begin(&left);
paint.drawPixmap(0, 0, pixmap, 0, 0, left.width(), left.height());
paint.end();
paint.begin(&leftMask);
- paint.drawPixmap(0, 0, *pixmap.mask(), 0, 0, left.width(), left.height());
+ paint.drawPixmap(0, 0, *pixmap.tqmask(), 0, 0, left.width(), left.height());
paint.end();
left.setMask(leftMask);
@@ -221,23 +221,23 @@ PixmapFunctions::splitPixmap(const QPixmap &pixmap, int x)
paint.end();
paint.begin(&rightMask);
- paint.drawPixmap(0, 0, *pixmap.mask(), left.width(), 0, right.width(), right.height());
+ paint.drawPixmap(0, 0, *pixmap.tqmask(), left.width(), 0, right.width(), right.height());
paint.end();
right.setMask(rightMask);
- return std::pair<QPixmap, QPixmap>(left, right);
+ return std::pair<TQPixmap, TQPixmap>(left, right);
}
void
-PixmapFunctions::drawPixmapMasked(QPixmap &dest, QBitmap &destMask,
+PixmapFunctions::drawPixmapMasked(TQPixmap &dest, TQBitmap &destMask,
int x0, int y0,
- const QPixmap &src)
+ const TQPixmap &src)
{
- QImage idp(dest.convertToImage());
- QImage idm(destMask.convertToImage());
- QImage isp(src.convertToImage());
- QImage ism(src.mask()->convertToImage());
+ TQImage idp(dest.convertToImage());
+ TQImage idm(destMask.convertToImage());
+ TQImage isp(src.convertToImage());
+ TQImage ism(src.tqmask()->convertToImage());
for (int y = 0; y < isp.height(); ++y) {
for (int x = 0; x < isp.width(); ++x) {
diff --git a/src/gui/general/PixmapFunctions.h b/src/gui/general/PixmapFunctions.h
index 22da0f0..ea05693 100644
--- a/src/gui/general/PixmapFunctions.h
+++ b/src/gui/general/PixmapFunctions.h
@@ -26,8 +26,8 @@
#ifndef _RG_PIXMAPFUNCTIONS_H_
#define _RG_PIXMAPFUNCTIONS_H_
-#include <qbitmap.h>
-#include <qpixmap.h>
+#include <tqbitmap.h>
+#include <tqpixmap.h>
#include <utility>
@@ -41,7 +41,7 @@ class PixmapFunctions
public:
/**
* Generate a heuristic mask for the given pixmap. Unlike
- * QPixmap::createHeuristicMask, this removes from the mask all
+ * TQPixmap::createHeuristicMask, this removes from the mask all
* pixels that are apparently "background" even if they appear in
* holes in the middle of the image. This is more usually what we
* want than the default behaviour of createHeuristicMask.
@@ -50,11 +50,11 @@ public:
*
* This function is slow.
*/
- static QBitmap generateMask(const QPixmap &map, const QRgb &rgb);
+ static TQBitmap generateMask(const TQPixmap &map, const QRgb &rgb);
/**
* Generate a heuristic mask for the given pixmap. Unlike
- * QPixmap::createHeuristicMask, this removes from the mask all
+ * TQPixmap::createHeuristicMask, this removes from the mask all
* pixels that are apparently "background" even if they appear in
* holes in the middle of the image. This is more usually what we
* want than the default behaviour of createHeuristicMask.
@@ -64,31 +64,31 @@ public:
*
* This function is slow.
*/
- static QBitmap generateMask(const QPixmap &map);
+ static TQBitmap generateMask(const TQPixmap &map);
/**
* Colour a greyscale pixmap with the given hue.
* minValue specifies the minimum value (in the HSV sense) that
* will be used for any recoloured pixel.
*/
- static QPixmap colourPixmap(const QPixmap &map, int hue, int minValue);
+ static TQPixmap colourPixmap(const TQPixmap &map, int hue, int minValue);
/**
* Make a pixmap grey, or otherwise reduce its intensity.
*/
- static QPixmap shadePixmap(const QPixmap &map);
+ static TQPixmap shadePixmap(const TQPixmap &map);
- /// Return a QPixmap that is a mirror image of map (including mask)
- static QPixmap flipVertical(const QPixmap &map);
+ /// Return a TQPixmap that is a mirror image of map (including mask)
+ static TQPixmap flipVertical(const TQPixmap &map);
- /// Return a QPixmap that is a mirror image of map (including mask)
- static QPixmap flipHorizontal(const QPixmap &map);
+ /// Return a TQPixmap that is a mirror image of map (including mask)
+ static TQPixmap flipHorizontal(const TQPixmap &map);
/// Return left and right parts of the QPixmap
- static std::pair<QPixmap, QPixmap> splitPixmap(const QPixmap &original, int x);
+ static std::pair<TQPixmap, TQPixmap> splitPixmap(const TQPixmap &original, int x);
/**
- * Using QPainter::drawPixmap to draw one pixmap on another does
+ * Using TQPainter::drawPixmap to draw one pixmap on another does
* not appear to take the mask into account properly. Background
* pixels in the second pixmap erase foreground pixels in the
* first one, regardless of whether they're masked or not. This
@@ -96,9 +96,9 @@ public:
*
* Note that the source pixmap _must_ have a mask.
*/
- static void drawPixmapMasked(QPixmap &dest, QBitmap &destMask,
+ static void drawPixmapMasked(TQPixmap &dest, TQBitmap &destMask,
int x, int y,
- const QPixmap &source);
+ const TQPixmap &source);
};
diff --git a/src/gui/general/PresetElement.cpp b/src/gui/general/PresetElement.cpp
index 4158d69..cc3e0d1 100644
--- a/src/gui/general/PresetElement.cpp
+++ b/src/gui/general/PresetElement.cpp
@@ -29,13 +29,13 @@
#include "PresetElement.h"
#include "misc/Debug.h"
-#include <qstring.h>
+#include <tqstring.h>
namespace Rosegarden
{
-PresetElement::PresetElement(QString name,
+PresetElement::PresetElement(TQString name,
int clef,
int transpose,
int highAm,
diff --git a/src/gui/general/PresetElement.h b/src/gui/general/PresetElement.h
index 24d3ee4..4da78f7 100644
--- a/src/gui/general/PresetElement.h
+++ b/src/gui/general/PresetElement.h
@@ -29,7 +29,7 @@
#ifndef _RG_PRESETELEMENT_H_
#define _RG_PRESETELEMENT_H_
-#include <qstring.h>
+#include <tqstring.h>
#include <vector>
@@ -46,7 +46,7 @@ class PresetElement
{
public:
- PresetElement(QString name,
+ PresetElement(TQString name,
int clef,
int transpose,
int highAm,
@@ -57,7 +57,7 @@ public:
~PresetElement();
// accessors
- QString getName() { return m_name; }
+ TQString getName() { return m_name; }
int getClef() { return m_clef; }
int getTranspose() { return m_transpose; }
int getHighAm() { return m_highAm; }
@@ -66,7 +66,7 @@ public:
int getLowPro() { return m_lowPro; }
private:
- QString m_name;
+ TQString m_name;
int m_clef;
int m_transpose;
int m_highAm;
diff --git a/src/gui/general/PresetGroup.cpp b/src/gui/general/PresetGroup.cpp
index 4a457a9..bd5974f 100644
--- a/src/gui/general/PresetGroup.cpp
+++ b/src/gui/general/PresetGroup.cpp
@@ -36,10 +36,10 @@
#include <klocale.h>
#include <kstddirs.h>
#include <kglobal.h>
-#include <qfile.h>
-#include <qfileinfo.h>
-#include <qregexp.h>
-#include <qstring.h>
+#include <tqfile.h>
+#include <tqfileinfo.h>
+#include <tqregexp.h>
+#include <tqstring.h>
namespace Rosegarden
@@ -67,27 +67,27 @@ PresetGroup::PresetGroup() :
{
m_presetDirectory = KGlobal::dirs()->findResource("appdata", "presets/");
- QString language = KGlobal::locale()->language();
+ TQString language = KGlobal::locale()->language();
- QString presetFileName = QString("%1/presets-%2.xml")
+ TQString presetFileName = TQString("%1/presets-%2.xml")
.arg(m_presetDirectory).arg(language);
- if (!QFileInfo(presetFileName).isReadable()) {
+ if (!TQFileInfo(presetFileName).isReadable()) {
RG_DEBUG << "Failed to open " << presetFileName << endl;
- language.replace(QRegExp("_.*$"), "");
- presetFileName = QString("%1/presets-%2.xml")
+ language.replace(TQRegExp("_.*$"), "");
+ presetFileName = TQString("%1/presets-%2.xml")
.arg(m_presetDirectory).arg(language);
- if (!QFileInfo(presetFileName).isReadable()) {
+ if (!TQFileInfo(presetFileName).isReadable()) {
RG_DEBUG << "Failed to open " << presetFileName << endl;
- presetFileName = QString("%1/presets.xml")
+ presetFileName = TQString("%1/presets.xml")
.arg(m_presetDirectory);
- if (!QFileInfo(presetFileName).isReadable()) {
+ if (!TQFileInfo(presetFileName).isReadable()) {
RG_DEBUG << "Failed to open " << presetFileName << endl;
@@ -98,10 +98,10 @@ PresetGroup::PresetGroup() :
}
}
- QFile presetFile(presetFileName);
+ TQFile presetFile(presetFileName);
- QXmlInputSource source(presetFile);
- QXmlSimpleReader reader;
+ TQXmlInputSource source(presetFile);
+ TQXmlSimpleReader reader;
reader.setContentHandler(this);
reader.setErrorHandler(this);
bool ok = reader.parse(source);
@@ -118,17 +118,17 @@ PresetGroup::~PresetGroup()
}
bool
-PresetGroup::startElement(const QString &, const QString &,
- const QString &qName,
- const QXmlAttributes &attributes)
+PresetGroup::startElement(const TQString &, const TQString &,
+ const TQString &qName,
+ const TQXmlAttributes &attributes)
{
- QString lcName = qName.lower();
+ TQString lcName = qName.lower();
// RG_DEBUG << "PresetGroup::startElement: processing starting element: " << lcName << endl;
if (lcName == "category") {
- QString s = attributes.value("name");
+ TQString s = attributes.value("name");
if (s) {
m_elCategoryName = s;
// increment the current category number
@@ -150,7 +150,7 @@ PresetGroup::startElement(const QString &, const QString &,
} else if (lcName == "instrument") {
- QString s = attributes.value("name");
+ TQString s = attributes.value("name");
if (s) {
m_elInstrumentName = s;
m_name = true;
@@ -161,20 +161,20 @@ PresetGroup::startElement(const QString &, const QString &,
}
} else if (lcName == "clef") {
- QString s = attributes.value("type");
+ TQString s = attributes.value("type");
if (s) {
m_elClef = clefNameToClefIndex(s);
m_clef = true;
}
} else if (lcName == "transpose") {
- QString s = attributes.value("value");
+ TQString s = attributes.value("value");
if (s) {
m_elTranspose = s.toInt();
m_transpose = true;
}
} else if (lcName == "range") {
- QString s = attributes.value("class");
+ TQString s = attributes.value("class");
if (s == "amateur") {
s = attributes.value("low");
@@ -242,28 +242,28 @@ PresetGroup::startElement(const QString &, const QString &,
} // startElement
bool
-PresetGroup::error(const QXmlParseException& exception)
+PresetGroup::error(const TQXmlParseException& exception)
{
RG_DEBUG << "PresetGroup::error(): jubilation and glee, we have an error, whee!" << endl;
- m_errorString = QString("%1 at line %2, column %3: %4")
+ m_errorString = TQString("%1 at line %2, column %3: %4")
.arg(exception.message())
.arg(exception.lineNumber())
.arg(exception.columnNumber())
.arg(m_errorString);
- return QXmlDefaultHandler::error(exception);
+ return TQXmlDefaultHandler::error(exception);
}
bool
-PresetGroup::fatalError(const QXmlParseException& exception)
+PresetGroup::fatalError(const TQXmlParseException& exception)
{
RG_DEBUG << "PresetGroup::fatalError(): double your jubilation, and triple your glee, a fatal error doth it be!" << endl;
- m_errorString = QString("%1 at line %2, column %3: %4")
+ m_errorString = TQString("%1 at line %2, column %3: %4")
.arg(exception.message())
.arg(exception.lineNumber())
.arg(exception.columnNumber())
.arg(m_errorString);
- return QXmlDefaultHandler::fatalError(exception);
+ return TQXmlDefaultHandler::fatalError(exception);
}
}
diff --git a/src/gui/general/PresetGroup.h b/src/gui/general/PresetGroup.h
index 476a878..5397838 100644
--- a/src/gui/general/PresetGroup.h
+++ b/src/gui/general/PresetGroup.h
@@ -31,12 +31,12 @@
#include "base/Exception.h"
#include "CategoryElement.h"
-#include <qstring.h>
-#include <qxml.h>
+#include <tqstring.h>
+#include <tqxml.h>
-class QXmlParseException;
-class QXmlAttributes;
+class TQXmlParseException;
+class TQXmlAttributes;
namespace Rosegarden
@@ -59,14 +59,14 @@ public:
// Xml handler methods:
- virtual bool startElement (const QString& namespaceURI, const QString& localName,
- const QString& qName, const QXmlAttributes& atts);
+ virtual bool startElement (const TQString& namespaceURI, const TQString& localName,
+ const TQString& qName, const TQXmlAttributes& atts);
- bool error(const QXmlParseException& exception);
- bool fatalError(const QXmlParseException& exception);
+ bool error(const TQXmlParseException& exception);
+ bool fatalError(const TQXmlParseException& exception);
// I don't think I have anything to do with this, but it must return true?
-// bool characters(const QString &) { return true; }
+// bool characters(const TQString &) { return true; }
private:
@@ -74,11 +74,11 @@ private:
CategoriesContainer m_categories;
// For use when reading the XML file:
- QString m_errorString;
- QString m_presetDirectory;
+ TQString m_errorString;
+ TQString m_presetDirectory;
- QString m_elCategoryName;
- QString m_elInstrumentName;
+ TQString m_elCategoryName;
+ TQString m_elInstrumentName;
int m_elClef;
int m_elTranspose;
int m_elLowAm;
diff --git a/src/gui/general/PresetHandlerDialog.cpp b/src/gui/general/PresetHandlerDialog.cpp
index 6081f85..383a2b6 100644
--- a/src/gui/general/PresetHandlerDialog.cpp
+++ b/src/gui/general/PresetHandlerDialog.cpp
@@ -27,7 +27,7 @@
#include "PresetHandlerDialog.h"
-#include <qlayout.h>
+#include <tqlayout.h>
#include <kapplication.h>
#include <klocale.h>
@@ -39,20 +39,20 @@
#include <kcombobox.h>
#include <kconfig.h>
#include <kdialogbase.h>
-#include <qbuttongroup.h>
-#include <qdialog.h>
-#include <qframe.h>
-#include <qgroupbox.h>
-#include <qlabel.h>
-#include <qstring.h>
-#include <qvbox.h>
-#include <qwidget.h>
+#include <tqbuttongroup.h>
+#include <tqdialog.h>
+#include <tqframe.h>
+#include <tqgroupbox.h>
+#include <tqlabel.h>
+#include <tqstring.h>
+#include <tqvbox.h>
+#include <tqwidget.h>
namespace Rosegarden
{
-PresetHandlerDialog::PresetHandlerDialog(QWidget *parent, bool fromNotation)
+PresetHandlerDialog::PresetHandlerDialog(TQWidget *parent, bool fromNotation)
: KDialogBase(parent, "presethandlerdialog", true, i18n("Load track parameters preset"), Ok | Cancel, Ok),
m_config(kapp->config()),
m_fromNotation(fromNotation)
@@ -77,40 +77,40 @@ PresetHandlerDialog::initDialog()
{
RG_DEBUG << "PresetHandlerDialog::initDialog()" << endl;
- QVBox *vBox = makeVBoxMainWidget();
+ TQVBox *vBox = makeVBoxMainWidget();
- QFrame *frame = new QFrame(vBox);
+ TQFrame *frame = new TQFrame(vBox);
- QGridLayout *layout = new QGridLayout(frame, 6, 5, 10, 5);
+ TQGridLayout *layout = new TQGridLayout(frame, 6, 5, 10, 5);
- QLabel *title = new QLabel(i18n("Select preset track parameters for:"), frame);
+ TQLabel *title = new TQLabel(i18n("Select preset track parameters for:"), frame);
if (m_fromNotation) title->setText(i18n("Create appropriate notation for:"));
- QLabel *catlabel = new QLabel(i18n("Category"), frame);
+ TQLabel *catlabel = new TQLabel(i18n("Category"), frame);
m_categoryCombo = new KComboBox(frame);
- QLabel *inslabel = new QLabel(i18n("Instrument"), frame);
+ TQLabel *inslabel = new TQLabel(i18n("Instrument"), frame);
m_instrumentCombo = new KComboBox(frame);
- QLabel *plylabel = new QLabel(i18n("Player Ability"), frame);
+ TQLabel *plylabel = new TQLabel(i18n("Player Ability"), frame);
m_playerCombo = new KComboBox(frame);
m_playerCombo->insertItem(i18n("Amateur"));
m_playerCombo->insertItem(i18n("Professional"));
- QGroupBox *scopeBox = new QButtonGroup
+ TQGroupBox *scopeBox = new QButtonGroup
(1, Horizontal, i18n("Scope"), frame);
if (m_fromNotation) {
- QRadioButton *onlySelectedSegments = new
- QRadioButton(i18n("Only selected segments"), scopeBox);
+ TQRadioButton *onlySelectedSegments = new
+ TQRadioButton(i18n("Only selected segments"), scopeBox);
m_convertAllSegments = new
- QRadioButton(i18n("All segments in this track"), scopeBox);
+ TQRadioButton(i18n("All segments in this track"), scopeBox);
onlySelectedSegments->setChecked(true);
}
else {
- QRadioButton *onlyNewSegments = new
- QRadioButton(i18n("Only for new segments"), scopeBox);
+ TQRadioButton *onlyNewSegments = new
+ TQRadioButton(i18n("Only for new segments"), scopeBox);
m_convertSegments = new
- QRadioButton(i18n("Convert existing segments"), scopeBox);
+ TQRadioButton(i18n("Convert existing segments"), scopeBox);
onlyNewSegments->setChecked(true);
}
@@ -147,8 +147,8 @@ PresetHandlerDialog::initDialog()
}
- connect(m_categoryCombo, SIGNAL(activated(int)),
- SLOT(slotCategoryIndexChanged(int)));
+ connect(m_categoryCombo, TQT_SIGNAL(activated(int)),
+ TQT_SLOT(slotCategoryIndexChanged(int)));
}
QString
@@ -274,7 +274,7 @@ PresetHandlerDialog::slotOk()
m_config->writeEntry("convert_segments", m_convertSegments->isChecked());
}
- QDialog::accept();
+ TQDialog::accept();
}
}
diff --git a/src/gui/general/PresetHandlerDialog.h b/src/gui/general/PresetHandlerDialog.h
index 879ddca..c91d733 100644
--- a/src/gui/general/PresetHandlerDialog.h
+++ b/src/gui/general/PresetHandlerDialog.h
@@ -30,11 +30,11 @@
#define _RG_PRESETHANDLERDIALOG_H_
#include <kdialogbase.h>
-#include <qradiobutton.h>
-#include <qstring.h>
+#include <tqradiobutton.h>
+#include <tqstring.h>
#include "CategoryElement.h"
-class QWidget;
+class TQWidget;
class KConfig;
class KComboBox;
@@ -51,7 +51,7 @@ class PresetHandlerDialog : public KDialogBase
public:
- PresetHandlerDialog(QWidget* parent, bool fromNotation = false);
+ PresetHandlerDialog(TQWidget* parent, bool fromNotation = false);
~PresetHandlerDialog();
PresetGroup *m_presets;
@@ -62,7 +62,7 @@ public:
//-------[ accessor functions ]------------------------
- QString getName();
+ TQString getName();
int getClef();
int getTranspose();
@@ -87,8 +87,8 @@ protected:
KComboBox *m_categoryCombo;
KComboBox *m_instrumentCombo;
KComboBox *m_playerCombo;
- QRadioButton *m_convertSegments;
- QRadioButton *m_convertAllSegments;
+ TQRadioButton *m_convertSegments;
+ TQRadioButton *m_convertAllSegments;
protected slots:
diff --git a/src/gui/general/ProgressReporter.cpp b/src/gui/general/ProgressReporter.cpp
index 0d9e896..3fdfacc 100644
--- a/src/gui/general/ProgressReporter.cpp
+++ b/src/gui/general/ProgressReporter.cpp
@@ -25,14 +25,14 @@
#include "ProgressReporter.h"
-#include <qobject.h>
+#include <tqobject.h>
namespace Rosegarden
{
-ProgressReporter::ProgressReporter(QObject* parent, const char* name)
- : QObject(parent, name), m_isCancelled(false)
+ProgressReporter::ProgressReporter(TQObject* parent, const char* name)
+ : TQObject(parent, name), m_isCancelled(false)
{}
diff --git a/src/gui/general/ProgressReporter.h b/src/gui/general/ProgressReporter.h
index d8aa306..3e87ba0 100644
--- a/src/gui/general/ProgressReporter.h
+++ b/src/gui/general/ProgressReporter.h
@@ -26,7 +26,7 @@
#ifndef _RG_PROGRESSREPORTER_H_
#define _RG_PROGRESSREPORTER_H_
-#include <qobject.h>
+#include <tqobject.h>
@@ -40,7 +40,7 @@ class ProgressReporter : public QObject
{
Q_OBJECT
public:
- ProgressReporter(QObject* parent, const char* name = 0);
+ ProgressReporter(TQObject* parent, const char* name = 0);
// exception class for cancellations
class Cancelled { };
@@ -66,7 +66,7 @@ signals:
/// Report progress
void setProgress(int);
void incrementProgress(int);
- void setOperationName(QString);
+ void setOperationName(TQString);
protected:
//--------------- Data members ---------------------------------
diff --git a/src/gui/general/RosegardenCanvasView.cpp b/src/gui/general/RosegardenCanvasView.cpp
index a829aac..4893147 100644
--- a/src/gui/general/RosegardenCanvasView.cpp
+++ b/src/gui/general/RosegardenCanvasView.cpp
@@ -27,24 +27,24 @@
#include "misc/Debug.h"
#include "gui/general/CanvasItemGC.h"
-#include <qcanvas.h>
-#include <qcursor.h>
-#include <qpoint.h>
-#include <qrect.h>
-#include <qscrollbar.h>
-#include <qsize.h>
-#include <qsizepolicy.h>
-#include <qtimer.h>
-#include <qwidget.h>
+#include <tqcanvas.h>
+#include <tqcursor.h>
+#include <tqpoint.h>
+#include <tqrect.h>
+#include <tqscrollbar.h>
+#include <tqsize.h>
+#include <tqsizepolicy.h>
+#include <tqtimer.h>
+#include <tqwidget.h>
namespace Rosegarden
{
-RosegardenCanvasView::RosegardenCanvasView(QCanvas* canvas,
- QWidget* parent,
+RosegardenCanvasView::RosegardenCanvasView(TQCanvas* canvas,
+ TQWidget* parent,
const char* name, WFlags f)
- : QCanvasView(canvas, parent, name, f),
+ : TQCanvasView(canvas, parent, name, f),
m_bottomWidget(0),
m_currentBottomWidgetHeight( -1),
m_leftWidget(0),
@@ -60,33 +60,33 @@ RosegardenCanvasView::RosegardenCanvasView(QCanvas* canvas,
m_autoScrolling(false)
{
setDragAutoScroll(true);
- connect( &m_autoScrollTimer, SIGNAL( timeout() ),
- this, SLOT( doAutoScroll() ) );
+ connect( &m_autoScrollTimer, TQT_SIGNAL( timeout() ),
+ this, TQT_SLOT( doAutoScroll() ) );
}
void RosegardenCanvasView::fitWidthToContents()
{
- QRect allItemsBoundingRect;
+ TQRect allItemsBoundingRect;
- QCanvasItemList items = canvas()->allItems();
+ TQCanvasItemList items = canvas()->allItems();
- QCanvasItemList::Iterator it;
+ TQCanvasItemList::Iterator it;
for (it = items.begin(); it != items.end(); ++it) {
allItemsBoundingRect |= (*it)->boundingRect();
}
- QSize currentSize = canvas()->size();
+ TQSize currentSize = canvas()->size();
resizeContents(allItemsBoundingRect.width(), currentSize.height());
}
-void RosegardenCanvasView::setBottomFixedWidget(QWidget* w)
+void RosegardenCanvasView::setBottomFixedWidget(TQWidget* w)
{
m_bottomWidget = w;
if (m_bottomWidget) {
int lww = m_leftWidget ? m_leftWidget->sizeHint().width() : 0;
- m_bottomWidget->reparent(this, 0, QPoint(0, 0));
- m_bottomWidget->setSizePolicy(QSizePolicy(QSizePolicy::Preferred, QSizePolicy::Fixed));
+ m_bottomWidget->reparent(this, 0, TQPoint(0, 0));
+ m_bottomWidget->setSizePolicy(TQSizePolicy(TQSizePolicy::Preferred, TQSizePolicy::Fixed));
setMargins(lww, 0, 0, m_bottomWidget->sizeHint().height());
}
}
@@ -119,7 +119,7 @@ void RosegardenCanvasView::startAutoScroll()
m_autoScrollTimer.start( m_autoScrollTime );
}
- QPoint autoScrollStartPoint = viewport()->mapFromGlobal( QCursor::pos() );
+ TQPoint autoScrollStartPoint = viewport()->mapFromGlobal( TQCursor::pos() );
m_autoScrollYMargin = autoScrollStartPoint.y() / 10;
m_autoScrollXMargin = autoScrollStartPoint.x() / 10;
@@ -147,8 +147,8 @@ void RosegardenCanvasView::doAutoScroll()
{
// RG_DEBUG << "RosegardenCanvasView::doAutoScroll()\n";
- QPoint p = viewport()->mapFromGlobal( QCursor::pos() );
- QPoint dp = p - m_previousP;
+ TQPoint p = viewport()->mapFromGlobal( TQCursor::pos() );
+ TQPoint dp = p - m_previousP;
m_previousP = p;
m_autoScrollTimer.start( m_autoScrollTime );
@@ -243,7 +243,7 @@ bool RosegardenCanvasView::isTimeForSmoothScroll()
void RosegardenCanvasView::slotScrollHoriz(int hpos)
{
- QScrollBar* hbar = getMainHorizontalScrollBar();
+ TQScrollBar* hbar = getMainHorizontalScrollBar();
int currentContentYPos = contentsY();
/* Lots of performance hitting debug
@@ -285,7 +285,7 @@ void RosegardenCanvasView::slotScrollHoriz(int hpos)
void RosegardenCanvasView::slotScrollHorizSmallSteps(int hpos)
{
- QScrollBar* hbar = getMainHorizontalScrollBar();
+ TQScrollBar* hbar = getMainHorizontalScrollBar();
int currentContentYPos = contentsY();
int diff = 0;
@@ -324,7 +324,7 @@ void RosegardenCanvasView::slotScrollHorizSmallSteps(int hpos)
void RosegardenCanvasView::slotScrollVertSmallSteps(int vpos)
{
- QScrollBar* vbar = verticalScrollBar();
+ TQScrollBar* vbar = verticalScrollBar();
// RG_DEBUG << "RosegardenCanvasView::slotScrollVertSmallSteps: vpos is " << vpos << ", contentsY is " << contentsY() << ", visibleHeight is " << visibleHeight() << endl;
@@ -367,30 +367,30 @@ void RosegardenCanvasView::slotScrollVertSmallSteps(int vpos)
void RosegardenCanvasView::slotScrollVertToTop(int vpos)
{
- QScrollBar* vbar = verticalScrollBar();
+ TQScrollBar* vbar = verticalScrollBar();
if (vpos < visibleHeight() / 3)
vbar->setValue(0);
else
vbar->setValue(vpos - visibleHeight() / 5);
}
-void RosegardenCanvasView::slotSetScrollPos(const QPoint &pos)
+void RosegardenCanvasView::slotSetScrollPos(const TQPoint &pos)
{
getMainHorizontalScrollBar()->setValue(pos.x());
verticalScrollBar()->setValue(pos.y());
}
-void RosegardenCanvasView::resizeEvent(QResizeEvent* e)
+void RosegardenCanvasView::resizeEvent(TQResizeEvent* e)
{
- QCanvasView::resizeEvent(e);
+ TQCanvasView::resizeEvent(e);
if (!horizontalScrollBar()->isVisible())
updateBottomWidgetGeometry();
updateLeftWidgetGeometry();
}
-void RosegardenCanvasView::setHBarGeometry(QScrollBar &hbar, int x, int y, int w, int h)
+void RosegardenCanvasView::setHBarGeometry(TQScrollBar &hbar, int x, int y, int w, int h)
{
- QCanvasView::setHBarGeometry(hbar, x, y, w, h);
+ TQCanvasView::setHBarGeometry(hbar, x, y, w, h);
updateBottomWidgetGeometry();
}
@@ -403,14 +403,14 @@ void RosegardenCanvasView::updateBottomWidgetGeometry()
int leftWidgetWidth = 0;
if (m_leftWidget && m_leftWidget->isVisible()) {
- QScrollView * qsv = dynamic_cast<QScrollView *>(m_leftWidget);
+ TQScrollView * qsv = dynamic_cast<TQScrollView *>(m_leftWidget);
leftWidgetWidth = qsv->contentsWidth()+2;
qsv->setFixedWidth(leftWidgetWidth);
}
setMargins(leftWidgetWidth, 0, 0, bottomWidgetHeight);
- QRect r = frameRect();
+ TQRect r = frameRect();
int hScrollBarHeight = 0;
if (horizontalScrollBar()->isVisible())
hScrollBarHeight = horizontalScrollBar()->height() + 2;
@@ -431,7 +431,7 @@ void RosegardenCanvasView::updateBottomWidgetGeometry()
}
}
-void RosegardenCanvasView::wheelEvent(QWheelEvent *e)
+void RosegardenCanvasView::wheelEvent(TQWheelEvent *e)
{
if (e->state() & ControlButton) {
if (e->delta() > 0)
@@ -440,16 +440,16 @@ void RosegardenCanvasView::wheelEvent(QWheelEvent *e)
emit zoomOut();
return ;
}
- QCanvasView::wheelEvent(e);
+ TQCanvasView::wheelEvent(e);
}
-void RosegardenCanvasView::setLeftFixedWidget(QWidget* w)
+void RosegardenCanvasView::setLeftFixedWidget(TQWidget* w)
{
m_leftWidget = w;
if (m_leftWidget) {
int bwh = m_bottomWidget ? m_bottomWidget->sizeHint().height() : 0;
- m_leftWidget->reparent(this, 0, QPoint(0, 0));
- m_leftWidget->setSizePolicy(QSizePolicy(QSizePolicy::Fixed, QSizePolicy::Preferred));
+ m_leftWidget->reparent(this, 0, TQPoint(0, 0));
+ m_leftWidget->setSizePolicy(TQSizePolicy(TQSizePolicy::Fixed, TQSizePolicy::Preferred));
setMargins(m_leftWidget->sizeHint().width(), 0, 0, bwh);
}
}
@@ -461,7 +461,7 @@ void RosegardenCanvasView::updateLeftWidgetGeometry()
int leftWidgetWidth = 0;
if (m_leftWidget->isVisible()) {
- QScrollView * qsv = dynamic_cast<QScrollView *>(m_leftWidget);
+ TQScrollView * qsv = dynamic_cast<TQScrollView *>(m_leftWidget);
leftWidgetWidth = qsv->contentsWidth() + 2;
}
m_leftWidget->setFixedWidth(leftWidgetWidth);
@@ -471,7 +471,7 @@ void RosegardenCanvasView::updateLeftWidgetGeometry()
setMargins(leftWidgetWidth, 0, 0, bottomWidgetHeight);
- QRect r = frameRect();
+ TQRect r = frameRect();
int hScrollBarHeight = 0;
if (horizontalScrollBar()->isVisible())
hScrollBarHeight = horizontalScrollBar()->height() + 2;
diff --git a/src/gui/general/RosegardenCanvasView.h b/src/gui/general/RosegardenCanvasView.h
index 509c1aa..3096334 100644
--- a/src/gui/general/RosegardenCanvasView.h
+++ b/src/gui/general/RosegardenCanvasView.h
@@ -26,23 +26,23 @@
#ifndef _RG_ROSEGARDENCANVASVIEW_H_
#define _RG_ROSEGARDENCANVASVIEW_H_
-#include <qpoint.h>
-#include <qtimer.h>
-#include <qcanvas.h>
-#include <qdatetime.h>
-#include <qwmatrix.h>
+#include <tqpoint.h>
+#include <tqtimer.h>
+#include <tqcanvas.h>
+#include <tqdatetime.h>
+#include <tqwmatrix.h>
-class QWidget;
-class QWheelEvent;
-class QScrollBar;
-class QResizeEvent;
+class TQWidget;
+class TQWheelEvent;
+class TQScrollBar;
+class TQResizeEvent;
namespace Rosegarden
{
/**
- * A QCanvasView with an auxiliary horiz. scrollbar
+ * A TQCanvasView with an auxiliary horiz. scrollbar
* That scrollbar should be provided by the parent widget
* (typically an EditView). The RosegardenCanvasView keeps
* the auxilliary horiz. scrollbar range in sync with the
@@ -53,8 +53,8 @@ class RosegardenCanvasView : public QCanvasView
{
Q_OBJECT
public:
- RosegardenCanvasView(QCanvas*,
- QWidget* parent=0, const char* name=0, WFlags f=0);
+ RosegardenCanvasView(TQCanvas*,
+ TQWidget* parent=0, const char* name=0, WFlags f=0);
/**
* EditTool::handleMouseMove() returns a OR-ed combination of these
@@ -76,7 +76,7 @@ public:
* Sets the widget which will be between the scrollable part of the view
* and the horizontal scrollbar
*/
- void setBottomFixedWidget(QWidget*);
+ void setBottomFixedWidget(TQWidget*);
void updateBottomWidgetGeometry();
@@ -84,12 +84,12 @@ public:
* Sets the widget which will be between the scrollable part of the view
* and the left edge of the view.
*/
- void setLeftFixedWidget(QWidget*);
+ void setLeftFixedWidget(TQWidget*);
void updateLeftWidgetGeometry();
/// Map a point with the inverse world matrix
- QPoint inverseMapPoint(const QPoint& p) { return inverseWorldMatrix().map(p); }
+ TQPoint inverseMapPoint(const TQPoint& p) { return inverseWorldMatrix().map(p); }
void setSmoothScroll(bool s) { m_smoothScroll = s; }
@@ -99,7 +99,7 @@ public:
bool isAutoScrolling() const { return m_autoScrolling; }
- virtual void wheelEvent(QWheelEvent *);
+ virtual void wheelEvent(TQWheelEvent *);
public slots:
/// Update the RosegardenCanvasView after a change of content
@@ -135,7 +135,7 @@ public slots:
/**
* Set the x and y scrollbars to a particular position
*/
- void slotSetScrollPos(const QPoint &);
+ void slotSetScrollPos(const TQPoint &);
void startAutoScroll();
void startAutoScroll(int directionConstraint);
@@ -150,30 +150,30 @@ signals:
protected:
- virtual void resizeEvent(QResizeEvent*);
- virtual void setHBarGeometry(QScrollBar &hbar, int x, int y, int w, int h);
+ virtual void resizeEvent(TQResizeEvent*);
+ virtual void setHBarGeometry(TQScrollBar &hbar, int x, int y, int w, int h);
- virtual QScrollBar* getMainHorizontalScrollBar() { return horizontalScrollBar(); }
+ virtual TQScrollBar* getMainHorizontalScrollBar() { return horizontalScrollBar(); }
//--------------- Data members ---------------------------------
enum ScrollDirection { None, Top, Bottom, Left, Right };
- QWidget* m_bottomWidget;
+ TQWidget* m_bottomWidget;
int m_currentBottomWidgetHeight;
- QWidget* m_leftWidget;
+ TQWidget* m_leftWidget;
bool m_smoothScroll;
int m_smoothScrollTimeInterval;
float m_minDeltaScroll;
- QTime m_scrollTimer;
- QTime m_scrollAccelerationTimer;
+ TQTime m_scrollTimer;
+ TQTime m_scrollAccelerationTimer;
- QTimer m_autoScrollTimer;
+ TQTimer m_autoScrollTimer;
int m_autoScrollTime;
int m_autoScrollAccel;
- QPoint m_previousP;
+ TQPoint m_previousP;
int m_autoScrollXMargin;
int m_autoScrollYMargin;
ScrollDirection m_currentScrollDirection;
diff --git a/src/gui/general/RosegardenScrollView.cpp b/src/gui/general/RosegardenScrollView.cpp
index fbcaf79..c3184da 100644
--- a/src/gui/general/RosegardenScrollView.cpp
+++ b/src/gui/general/RosegardenScrollView.cpp
@@ -26,15 +26,15 @@
#include "RosegardenScrollView.h"
#include "misc/Debug.h"
-#include <qapplication.h>
-#include <qcursor.h>
-#include <qpoint.h>
-#include <qrect.h>
-#include <qscrollbar.h>
-#include <qscrollview.h>
-#include <qsizepolicy.h>
-#include <qtimer.h>
-#include <qwidget.h>
+#include <tqapplication.h>
+#include <tqcursor.h>
+#include <tqpoint.h>
+#include <tqrect.h>
+#include <tqscrollbar.h>
+#include <tqscrollview.h>
+#include <tqsizepolicy.h>
+#include <tqtimer.h>
+#include <tqwidget.h>
namespace Rosegarden
@@ -49,9 +49,9 @@ const int RosegardenScrollView::InitialScrollAccel = 5;
const int RosegardenScrollView::MaxScrollDelta = 100; // max a.scroll speed
const double RosegardenScrollView::ScrollAccelValue = 1.04;// acceleration rate
-RosegardenScrollView::RosegardenScrollView(QWidget* parent,
+RosegardenScrollView::RosegardenScrollView(TQWidget* parent,
const char* name, WFlags f)
- : QScrollView(parent, name, f),
+ : TQScrollView(parent, name, f),
m_bottomWidget(0),
m_currentBottomWidgetHeight( -1),
m_smoothScroll(true),
@@ -66,16 +66,16 @@ RosegardenScrollView::RosegardenScrollView(QWidget* parent,
m_autoScrolling(false)
{
setDragAutoScroll(true);
- connect( &m_autoScrollTimer, SIGNAL( timeout() ),
- this, SLOT( doAutoScroll() ) );
+ connect( &m_autoScrollTimer, TQT_SIGNAL( timeout() ),
+ this, TQT_SLOT( doAutoScroll() ) );
}
-void RosegardenScrollView::setBottomFixedWidget(QWidget* w)
+void RosegardenScrollView::setBottomFixedWidget(TQWidget* w)
{
m_bottomWidget = w;
if (m_bottomWidget) {
- m_bottomWidget->reparent(this, 0, QPoint(0, 0));
- m_bottomWidget->setSizePolicy(QSizePolicy(QSizePolicy::Preferred, QSizePolicy::Fixed));
+ m_bottomWidget->reparent(this, 0, TQPoint(0, 0));
+ m_bottomWidget->setSizePolicy(TQSizePolicy(TQSizePolicy::Preferred, TQSizePolicy::Fixed));
setMargins(0, 0, 0, m_bottomWidget->sizeHint().height());
}
}
@@ -90,7 +90,7 @@ void RosegardenScrollView::startAutoScroll()
m_autoScrollTimer.start( m_autoScrollTime );
}
- QPoint autoScrollStartPoint = viewport()->mapFromGlobal( QCursor::pos() );
+ TQPoint autoScrollStartPoint = viewport()->mapFromGlobal( TQCursor::pos() );
m_autoScrollYMargin = autoScrollStartPoint.y() / 10;
m_autoScrollXMargin = autoScrollStartPoint.x() / 10;
@@ -118,8 +118,8 @@ void RosegardenScrollView::doAutoScroll()
{
// RG_DEBUG << "RosegardenScrollView::doAutoScroll()\n";
- QPoint p = viewport()->mapFromGlobal( QCursor::pos() );
- QPoint dp = p - m_previousP;
+ TQPoint p = viewport()->mapFromGlobal( TQCursor::pos() );
+ TQPoint dp = p - m_previousP;
m_previousP = p;
m_autoScrollTimer.start( m_autoScrollTime );
@@ -184,8 +184,8 @@ const double RosegardenScrollView::DefaultMinDeltaScroll = 1.2;
bool RosegardenScrollView::isTimeForSmoothScroll()
{
- static int desktopWidth = QApplication::desktop()->width(),
- desktopHeight = QApplication::desktop()->height();
+ static int desktopWidth = TQApplication::desktop()->width(),
+ desktopHeight = TQApplication::desktop()->height();
if (m_smoothScroll) {
int ta = m_scrollAccelerationTimer.elapsed();
@@ -220,7 +220,7 @@ bool RosegardenScrollView::isTimeForSmoothScroll()
void RosegardenScrollView::slotScrollHoriz(int hpos)
{
- QScrollBar* hbar = getMainHorizontalScrollBar();
+ TQScrollBar* hbar = getMainHorizontalScrollBar();
int currentContentYPos = contentsY();
/* Lots of performance hitting debug
@@ -262,7 +262,7 @@ void RosegardenScrollView::slotScrollHoriz(int hpos)
void RosegardenScrollView::slotScrollHorizSmallSteps(int hpos)
{
- QScrollBar* hbar = getMainHorizontalScrollBar();
+ TQScrollBar* hbar = getMainHorizontalScrollBar();
int currentContentYPos = contentsY();
int diff = 0;
@@ -301,7 +301,7 @@ void RosegardenScrollView::slotScrollHorizSmallSteps(int hpos)
void RosegardenScrollView::slotScrollVertSmallSteps(int vpos)
{
- QScrollBar* vbar = verticalScrollBar();
+ TQScrollBar* vbar = verticalScrollBar();
// RG_DEBUG << "RosegardenCanvasView::slotScrollVertSmallSteps: vpos is " << vpos << ", contentsY is " << contentsY() << ", visibleHeight is " << visibleHeight() << endl;
@@ -344,30 +344,30 @@ void RosegardenScrollView::slotScrollVertSmallSteps(int vpos)
void RosegardenScrollView::slotScrollVertToTop(int vpos)
{
- QScrollBar* vbar = verticalScrollBar();
+ TQScrollBar* vbar = verticalScrollBar();
if (vpos < visibleHeight() / 3)
vbar->setValue(0);
else
vbar->setValue(vpos - visibleHeight() / 5);
}
-void RosegardenScrollView::slotSetScrollPos(const QPoint &pos)
+void RosegardenScrollView::slotSetScrollPos(const TQPoint &pos)
{
horizontalScrollBar()->setValue(pos.x());
verticalScrollBar()->setValue(pos.y());
}
-void RosegardenScrollView::resizeEvent(QResizeEvent* e)
+void RosegardenScrollView::resizeEvent(TQResizeEvent* e)
{
- QScrollView::resizeEvent(e);
+ TQScrollView::resizeEvent(e);
if (!horizontalScrollBar()->isVisible())
updateBottomWidgetGeometry();
}
-void RosegardenScrollView::setHBarGeometry(QScrollBar &hbar, int x, int y, int w, int h)
+void RosegardenScrollView::setHBarGeometry(TQScrollBar &hbar, int x, int y, int w, int h)
{
- QScrollView::setHBarGeometry(hbar, x, y, w, h);
+ TQScrollView::setHBarGeometry(hbar, x, y, w, h);
updateBottomWidgetGeometry();
}
@@ -379,7 +379,7 @@ void RosegardenScrollView::updateBottomWidgetGeometry()
int bottomWidgetHeight = m_bottomWidget->sizeHint().height();
setMargins(0, 0, 0, bottomWidgetHeight);
- QRect r = frameRect();
+ TQRect r = frameRect();
int hScrollBarHeight = 0;
if (horizontalScrollBar()->isVisible())
hScrollBarHeight = horizontalScrollBar()->height() + 2; // + 2 offset needed to preserve border shadow
@@ -400,7 +400,7 @@ void RosegardenScrollView::updateBottomWidgetGeometry()
}
-void RosegardenScrollView::wheelEvent(QWheelEvent *e)
+void RosegardenScrollView::wheelEvent(TQWheelEvent *e)
{
if (e->state() & ControlButton) {
if (e->delta() > 0)
@@ -409,7 +409,7 @@ void RosegardenScrollView::wheelEvent(QWheelEvent *e)
emit zoomOut();
return ;
}
- QScrollView::wheelEvent(e);
+ TQScrollView::wheelEvent(e);
}
}
diff --git a/src/gui/general/RosegardenScrollView.h b/src/gui/general/RosegardenScrollView.h
index 6a0dab7..a0aafbb 100644
--- a/src/gui/general/RosegardenScrollView.h
+++ b/src/gui/general/RosegardenScrollView.h
@@ -26,16 +26,16 @@
#ifndef _RG_ROSEGARDENSCROLLVIEW_H_
#define _RG_ROSEGARDENSCROLLVIEW_H_
-#include <qpoint.h>
-#include <qscrollview.h>
-#include <qdatetime.h>
-#include <qtimer.h>
+#include <tqpoint.h>
+#include <tqscrollview.h>
+#include <tqdatetime.h>
+#include <tqtimer.h>
-class QWidget;
-class QWheelEvent;
-class QScrollBar;
-class QResizeEvent;
+class TQWidget;
+class TQWheelEvent;
+class TQScrollBar;
+class TQResizeEvent;
namespace Rosegarden
@@ -44,7 +44,7 @@ namespace Rosegarden
/**
- * A QScrollView with more elaborate auto-scrolling capabilities
+ * A TQScrollView with more elaborate auto-scrolling capabilities
* and the ability to have a "fixed" (non-scrolling) widget at its bottom,
* just above the bottom scrollbar.
*/
@@ -52,7 +52,7 @@ class RosegardenScrollView : public QScrollView
{
Q_OBJECT
public:
- RosegardenScrollView(QWidget* parent=0, const char* name=0, WFlags f=0);
+ RosegardenScrollView(TQWidget* parent=0, const char* name=0, WFlags f=0);
/**
* EditTool::handleMouseMove() returns a OR-ed combination of these
@@ -74,12 +74,12 @@ public:
* Sets the widget which will be between the scrollable part of the view
* and the horizontal scrollbar
*/
- void setBottomFixedWidget(QWidget*);
+ void setBottomFixedWidget(TQWidget*);
void updateBottomWidgetGeometry();
/// Map a point with the inverse world matrix
-// QPoint inverseMapPoint(const QPoint& p) { return inverseWorldMatrix().map(p); }
+// TQPoint inverseMapPoint(const TQPoint& p) { return inverseWorldMatrix().map(p); }
void setSmoothScroll(bool s) { m_smoothScroll = s; }
@@ -89,7 +89,7 @@ public:
int getDeltaScroll() { return m_minDeltaScroll; }
- virtual void wheelEvent(QWheelEvent *);
+ virtual void wheelEvent(TQWheelEvent *);
public slots:
/**
@@ -122,7 +122,7 @@ public slots:
/**
* Set the x and y scrollbars to a particular position
*/
- void slotSetScrollPos(const QPoint &);
+ void slotSetScrollPos(const TQPoint &);
void startAutoScroll();
void startAutoScroll(int directionConstraint);
@@ -139,27 +139,27 @@ signals:
protected:
- virtual void resizeEvent(QResizeEvent*);
- virtual void setHBarGeometry(QScrollBar &hbar, int x, int y, int w, int h);
+ virtual void resizeEvent(TQResizeEvent*);
+ virtual void setHBarGeometry(TQScrollBar &hbar, int x, int y, int w, int h);
- virtual QScrollBar* getMainHorizontalScrollBar() { return horizontalScrollBar(); }
+ virtual TQScrollBar* getMainHorizontalScrollBar() { return horizontalScrollBar(); }
//--------------- Data members ---------------------------------
enum ScrollDirection { None, Top, Bottom, Left, Right };
- QWidget* m_bottomWidget;
+ TQWidget* m_bottomWidget;
int m_currentBottomWidgetHeight;
bool m_smoothScroll;
int m_smoothScrollTimeInterval;
float m_minDeltaScroll;
- QTime m_scrollTimer;
- QTime m_scrollAccelerationTimer;
+ TQTime m_scrollTimer;
+ TQTime m_scrollAccelerationTimer;
- QTimer m_autoScrollTimer;
+ TQTimer m_autoScrollTimer;
int m_autoScrollTime;
int m_autoScrollAccel;
- QPoint m_previousP;
+ TQPoint m_previousP;
int m_autoScrollXMargin;
int m_autoScrollYMargin;
ScrollDirection m_currentScrollDirection;
diff --git a/src/gui/general/Spline.cpp b/src/gui/general/Spline.cpp
index 455cca5..297c21f 100644
--- a/src/gui/general/Spline.cpp
+++ b/src/gui/general/Spline.cpp
@@ -25,7 +25,7 @@
#include "Spline.h"
-#include <qpoint.h>
+#include <tqpoint.h>
namespace Rosegarden
@@ -33,25 +33,25 @@ namespace Rosegarden
Spline::PointList *
-Spline::calculate(const QPoint &s, const QPoint &f, const PointList &cp,
- QPoint &topLeft, QPoint &bottomRight)
+Spline::calculate(const TQPoint &s, const TQPoint &f, const PointList &cp,
+ TQPoint &topLeft, TQPoint &bottomRight)
{
if (cp.size() < 2)
return 0;
int i;
PointList *acc = new PointList();
- QPoint p(s);
+ TQPoint p(s);
- topLeft = bottomRight = QPoint(0, 0);
+ topLeft = bottomRight = TQPoint(0, 0);
for (i = 1; i < cp.size(); ++i) {
- QPoint c(cp[i - 1]);
+ TQPoint c(cp[i - 1]);
int x = (c.x() + cp[i].x()) / 2;
int y = (c.y() + cp[i].y()) / 2;
- QPoint n(x, y);
+ TQPoint n(x, y);
calculateSegment(acc, p, n, c, topLeft, bottomRight);
@@ -65,8 +65,8 @@ Spline::calculate(const QPoint &s, const QPoint &f, const PointList &cp,
void
Spline::calculateSegment(PointList *acc,
- const QPoint &s, const QPoint &f, const QPoint &c,
- QPoint &topLeft, QPoint &bottomRight)
+ const TQPoint &s, const TQPoint &f, const TQPoint &c,
+ TQPoint &topLeft, TQPoint &bottomRight)
{
int x, y, n;
@@ -99,8 +99,8 @@ Spline::calculateSegment(PointList *acc,
void
Spline::calculateSegmentSub(PointList *acc,
- const QPoint &s, const QPoint &f, const QPoint &c,
- int n, QPoint &topLeft, QPoint &bottomRight)
+ const TQPoint &s, const TQPoint &f, const TQPoint &c,
+ int n, TQPoint &topLeft, TQPoint &bottomRight)
{
double ax = (double)(f.x() + s.x() - 2 * c.x()) / (double)n;
double ay = (double)(f.y() + s.y() - 2 * c.y()) / (double)n;
@@ -123,7 +123,7 @@ Spline::calculateSegmentSub(PointList *acc,
if (y > bottomRight.y())
bottomRight.setY(y);
- acc->push_back(QPoint(x, y));
+ acc->push_back(TQPoint(x, y));
}
}
diff --git a/src/gui/general/Spline.h b/src/gui/general/Spline.h
index 63946a5..292c2b3 100644
--- a/src/gui/general/Spline.h
+++ b/src/gui/general/Spline.h
@@ -29,7 +29,7 @@
#include "base/FastVector.h"
-class QPoint;
+class TQPoint;
class PointList;
@@ -41,27 +41,27 @@ namespace Rosegarden
class Spline
{
public:
- typedef FastVector<QPoint> PointList;
+ typedef FastVector<TQPoint> PointList;
/**
* Calculate a set of polyline points to approximate
* a Bezier spline. Caller takes ownership of returned
* heap-allocated container.
*/
- static PointList *calculate(const QPoint &start, const QPoint &finish,
+ static PointList *calculate(const TQPoint &start, const TQPoint &finish,
const PointList &controlPoints,
- QPoint &topLeft, QPoint &bottomRight);
+ TQPoint &topLeft, TQPoint &bottomRight);
private:
static void calculateSegment
(PointList *acc,
- const QPoint &start, const QPoint &finish, const QPoint &control,
- QPoint &topLeft, QPoint &bottomRight);
+ const TQPoint &start, const TQPoint &finish, const TQPoint &control,
+ TQPoint &topLeft, TQPoint &bottomRight);
static void calculateSegmentSub
(PointList *acc,
- const QPoint &start, const QPoint &finish, const QPoint &control, int n,
- QPoint &topLeft, QPoint &bottomRight);
+ const TQPoint &start, const TQPoint &finish, const TQPoint &control, int n,
+ TQPoint &topLeft, TQPoint &bottomRight);
};
diff --git a/src/gui/general/StaffLine.cpp b/src/gui/general/StaffLine.cpp
index ab5d5ff..90208fe 100644
--- a/src/gui/general/StaffLine.cpp
+++ b/src/gui/general/StaffLine.cpp
@@ -26,14 +26,14 @@
#include "StaffLine.h"
#include "misc/Debug.h"
-#include <qcanvas.h>
-#include <qpen.h>
+#include <tqcanvas.h>
+#include <tqpen.h>
namespace Rosegarden
{
-StaffLine::StaffLine(QCanvas *c, QCanvasItemGroup *g, int height) :
+StaffLine::StaffLine(TQCanvas *c, QCanvasItemGroup *g, int height) :
QCanvasLineGroupable(c, g),
m_height(height),
m_significant(true)
@@ -50,7 +50,7 @@ StaffLine::setHighlighted(bool highlighted)
if (highlighted) {
m_normalPen = pen();
- QPen newPen = m_normalPen;
+ TQPen newPen = m_normalPen;
newPen.setColor(red);
setPen(newPen);
diff --git a/src/gui/general/StaffLine.h b/src/gui/general/StaffLine.h
index 7d01ff4..00a02c4 100644
--- a/src/gui/general/StaffLine.h
+++ b/src/gui/general/StaffLine.h
@@ -27,11 +27,11 @@
#define _RG_STAFFLINE_H_
#include "gui/kdeext/QCanvasGroupableItem.h"
-#include <qpen.h>
+#include <tqpen.h>
class QCanvasItemGroup;
-class QCanvas;
+class TQCanvas;
namespace Rosegarden
@@ -48,7 +48,7 @@ namespace Rosegarden
class StaffLine : public QCanvasLineGroupable
{
public:
- StaffLine(QCanvas *c, QCanvasItemGroup *g, int height);
+ StaffLine(TQCanvas *c, QCanvasItemGroup *g, int height);
enum { NoHeight = -150 };
@@ -69,7 +69,7 @@ protected:
int m_height;
bool m_significant;
- QPen m_normalPen;
+ TQPen m_normalPen;
};