summaryrefslogtreecommitdiffstats
path: root/kmid/kdisptext.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kmid/kdisptext.cpp')
-rw-r--r--kmid/kdisptext.cpp42
1 files changed, 21 insertions, 21 deletions
diff --git a/kmid/kdisptext.cpp b/kmid/kdisptext.cpp
index 7d160c2f..cc1eb4d3 100644
--- a/kmid/kdisptext.cpp
+++ b/kmid/kdisptext.cpp
@@ -22,11 +22,11 @@
***************************************************************************/
#include "kdisptext.h"
-#include <qpainter.h>
-#include <qfont.h>
-#include <qfontmetrics.h>
-#include <qrect.h>
-#include <qtextcodec.h>
+#include <tqpainter.h>
+#include <tqfont.h>
+#include <tqfontmetrics.h>
+#include <tqrect.h>
+#include <tqtextcodec.h>
#include <kconfig.h>
#include <kglobal.h>
@@ -40,7 +40,7 @@
//#define DRAW_BOUNDING_RECTS
-KDisplayText::KDisplayText(QWidget *parent,const char *name) : QScrollView(parent,name)
+KDisplayText::KDisplayText(TQWidget *parent,const char *name) : TQScrollView(parent,name)
{
first_line_[0]=first_line_[1]=NULL;
linked_list_[0]=linked_list_[1]=NULL;
@@ -54,15 +54,15 @@ KDisplayText::KDisplayText(QWidget *parent,const char *name) : QScrollView(paren
nlines=0;
lyrics_codec=KGlobal::locale()->codecForEncoding();
- viewport()->setBackgroundColor(QColor (110,110,110));
+ viewport()->setBackgroundColor(TQColor (110,110,110));
// setBackgroundMode(NoBackground);
KConfig *kcfg=KGlobal::instance()->config();
kcfg->setGroup("KMid");
typeoftextevents=kcfg->readNumEntry("TypeOfTextEvents",1);
- QFont *qtextfontdefault=new QFont(KGlobalSettings::fixedFont().family(),22);
- qtextfont=new QFont(kcfg->readFontEntry("KaraokeFont",qtextfontdefault));
+ TQFont *qtextfontdefault=new TQFont(KGlobalSettings::fixedFont().family(),22);
+ qtextfont=new TQFont(kcfg->readFontEntry("KaraokeFont",qtextfontdefault));
delete qtextfontdefault;
- qfmetr=new QFontMetrics(*qtextfont);
+ qfmetr=new TQFontMetrics(*qtextfont);
nvisiblelines=height()/qfmetr->lineSpacing();
autoscrollv=0;
}
@@ -261,7 +261,7 @@ while (t!=NULL)
return start;
}
-void KDisplayText::drawContents(QPainter *p, int /*clipx*/, int clipy, int /*clipw*/, int cliph)
+void KDisplayText::drawContents(TQPainter *p, int /*clipx*/, int clipy, int /*clipw*/, int cliph)
{
p->setFont(*qtextfont);
if (linked_list==NULL) return;
@@ -320,9 +320,9 @@ void KDisplayText::drawContents(QPainter *p, int /*clipx*/, int clipy, int /*cli
}
-void KDisplayText::resizeEvent(QResizeEvent *e)
+void KDisplayText::resizeEvent(TQResizeEvent *e)
{
- QScrollView::resizeEvent(e);
+ TQScrollView::resizeEvent(e);
nvisiblelines=visibleHeight()/qfmetr->lineSpacing();
if ( (nlines>nvisiblelines) || (nvisiblelines==0) )
resizeContents(maxX[(typeoftextevents==1)?0:1],maxY[(typeoftextevents==1)?0:1]);
@@ -492,7 +492,7 @@ void KDisplayText::gotomsec(ulong i)
}
}
-QFont *KDisplayText::getFont(void)
+TQFont *KDisplayText::getFont(void)
{
return qtextfont;
}
@@ -501,11 +501,11 @@ void KDisplayText::fontChanged(void)
{
KConfig *kcfg=KGlobal::instance()->config();
kcfg->setGroup("KMid");
- QFont *qtextfontdefault=new QFont(*qtextfont);
+ TQFont *qtextfontdefault=new TQFont(*qtextfont);
delete qtextfont;
- qtextfont=new QFont(kcfg->readFontEntry("KaraokeFont",qtextfontdefault));
+ qtextfont=new TQFont(kcfg->readFontEntry("KaraokeFont",qtextfontdefault));
delete qtextfontdefault;
- qfmetr=new QFontMetrics(*qtextfont);
+ qfmetr=new TQFontMetrics(*qtextfont);
calculatePositions();
nvisiblelines=height()/qfmetr->lineSpacing();
viewport()->repaint(TRUE);
@@ -587,7 +587,7 @@ void KDisplayText::saveLyrics(FILE *fh)
}
}
-void KDisplayText::timerEvent(QTimerEvent *e)
+void KDisplayText::timerEvent(TQTimerEvent *e)
{
int dy;
if (autoscrollv>0)
@@ -619,13 +619,13 @@ void KDisplayText::timerEvent(QTimerEvent *e)
}
-void KDisplayText::setLyricsEncoding(const QString &enc)
+void KDisplayText::setLyricsEncoding(const TQString &enc)
{
- QTextCodec *newcodec;
+ TQTextCodec *newcodec;
if (enc.isEmpty())
newcodec=KGlobal::locale()->codecForEncoding();
else
- newcodec=QTextCodec::codecForName(enc.latin1());
+ newcodec=TQTextCodec::codecForName(enc.latin1());
if (newcodec!=lyrics_codec)
{