summaryrefslogtreecommitdiffstats
path: root/src/gui/rulers/TextRuler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/rulers/TextRuler.cpp')
-rw-r--r--src/gui/rulers/TextRuler.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/gui/rulers/TextRuler.cpp b/src/gui/rulers/TextRuler.cpp
index 0acb3ea..4ef0569 100644
--- a/src/gui/rulers/TextRuler.cpp
+++ b/src/gui/rulers/TextRuler.cpp
@@ -32,12 +32,12 @@
#include "base/RulerScale.h"
#include "base/Segment.h"
#include "gui/general/GUIPalette.h"
-#include <qfont.h>
-#include <qfontmetrics.h>
-#include <qpainter.h>
-#include <qrect.h>
-#include <qsize.h>
-#include <qwidget.h>
+#include <tqfont.h>
+#include <tqfontmetrics.h>
+#include <tqpainter.h>
+#include <tqrect.h>
+#include <tqsize.h>
+#include <tqwidget.h>
namespace Rosegarden
@@ -46,9 +46,9 @@ namespace Rosegarden
TextRuler::TextRuler(RulerScale *rulerScale,
Segment *segment,
int height,
- QWidget *parent,
+ TQWidget *parent,
const char *name)
- : QWidget(parent, name),
+ : TQWidget(parent, name),
m_height(height),
m_currentXOffset(0),
m_width( -1),
@@ -98,7 +98,7 @@ TextRuler::sizeHint() const
m_rulerScale->getBarPosition(m_rulerScale->getLastVisibleBar()) +
m_rulerScale->getBarWidth(m_rulerScale->getLastVisibleBar());
- QSize res(std::max(int(width), m_width), m_height);
+ TQSize res(std::max(int(width), m_width), m_height);
return res;
}
@@ -107,20 +107,20 @@ QSize
TextRuler::minimumSizeHint() const
{
double firstBarWidth = m_rulerScale->getBarWidth(0);
- QSize res = QSize(int(firstBarWidth), m_height);
+ TQSize res = TQSize(int(firstBarWidth), m_height);
return res;
}
void
-TextRuler::paintEvent(QPaintEvent* e)
+TextRuler::paintEvent(TQPaintEvent* e)
{
- QPainter paint(this);
+ TQPainter paint(this);
paint.setPen(GUIPalette::getColour(GUIPalette::TextRulerForeground));
paint.setClipRegion(e->region());
paint.setClipRect(e->rect().normalize());
- QRect clipRect = paint.clipRegion().boundingRect();
+ TQRect clipRect = paint.clipRegion().boundingRect();
timeT from = m_rulerScale->getTimeForX
(clipRect.x() - m_currentXOffset - 100);
@@ -142,7 +142,7 @@ TextRuler::paintEvent(QPaintEvent* e)
continue;
}
- QRect bounds = m_fontMetrics.boundingRect(strtoqstr(text));
+ TQRect bounds = m_fontMetrics.boundingRect(strtoqstr(text));
double x = m_rulerScale->getXForTime((*i)->getAbsoluteTime()) +
m_currentXOffset - bounds.width() / 2;