summaryrefslogtreecommitdiffstats
path: root/kopete/kopete/chatwindow/krichtexteditpart.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kopete/kopete/chatwindow/krichtexteditpart.cpp')
-rw-r--r--kopete/kopete/chatwindow/krichtexteditpart.cpp50
1 files changed, 25 insertions, 25 deletions
diff --git a/kopete/kopete/chatwindow/krichtexteditpart.cpp b/kopete/kopete/chatwindow/krichtexteditpart.cpp
index 392e187a..61149c0d 100644
--- a/kopete/kopete/chatwindow/krichtexteditpart.cpp
+++ b/kopete/kopete/chatwindow/krichtexteditpart.cpp
@@ -10,7 +10,7 @@
#include <tqclipboard.h>
#include <tqevent.h>
#include <kparts/genericfactory.h>
-#include <private/qrichtext_p.h>
+#include <private/tqrichtext_p.h>
#include "krichtexteditpart.h"
#include "krichtexteditpart.moc"
@@ -23,8 +23,8 @@ K_EXPORT_COMPONENT_FACTORY( libkopeterichtexteditpart, KopeteRichTextEditPartFac
class KopeteTextEdit : public KTextEdit
{
public:
- KopeteTextEdit( TQWidget *parent ) : KTextEdit( parent ) {}
- const QTextCursor * cursor() { return textCursor(); }
+ KopeteTextEdit( TQWidget *tqparent ) : KTextEdit( tqparent ) {}
+ const TQTextCursor * cursor() { return textCursor(); }
bool event(TQEvent *event)
{
// don't allow TQTextEdit to override accels
@@ -35,21 +35,21 @@ public:
}
};
-KopeteRichTextEditPart::KopeteRichTextEditPart( TQWidget *wparent, const char *wname, TQObject*, const char*, const TQStringList& )
- : KParts::ReadOnlyPart( wparent, wname ? wname : "rich_text_part" )
+KopeteRichTextEditPart::KopeteRichTextEditPart( TQWidget *wtqparent, const char *wname, TQObject*, const char*, const TQStringList& )
+ : KParts::ReadOnlyPart( TQT_TQOBJECT(wtqparent), wname ? wname : "rich_text_part" )
{
- KopeteRichTextEditPart( wparent, wname, false );
+ KopeteRichTextEditPart( wtqparent, wname, false );
}
-KopeteRichTextEditPart::KopeteRichTextEditPart( TQWidget *parent, const char *name, int capabilities )
- : KParts::ReadOnlyPart( parent, name ? name : "rich_text_part" ),
+KopeteRichTextEditPart::KopeteRichTextEditPart( TQWidget *tqparent, const char *name, int capabilities )
+ : KParts::ReadOnlyPart( TQT_TQOBJECT(tqparent), name ? name : "rich_text_part" ),
m_capabilities( capabilities ),
m_richTextEnabled( true )
{
// we need an instance
setInstance( KopeteRichTextEditPartFactory::instance() );
- editor = new KopeteTextEdit( parent );
+ editor = new KopeteTextEdit( tqparent );
editor->setReadOnly( false );
setWidget( editor );
@@ -78,11 +78,11 @@ void KopeteRichTextEditPart::slotSetRichTextEnabled( bool enable )
if( m_richTextEnabled )
{
- editor->setTextFormat( Qt::RichText );
+ editor->setTextFormat( TQt::RichText );
}
else
{
- editor->setTextFormat( Qt::PlainText );
+ editor->setTextFormat( TQt::PlainText );
}
emit toggleToolbar( buttonsEnabled() );
@@ -131,7 +131,7 @@ void KopeteRichTextEditPart::createActions( KActionCollection *ac )
this, TQT_SLOT( slotSetRichTextEnabled(bool) ) );
checkSpelling = new KAction( i18n("Check &Spelling"), "spellcheck", 0,
- editor, TQT_SLOT( checkSpelling() ), ac, "check_spelling" );
+ TQT_TQOBJECT(editor), TQT_SLOT( checkSpelling() ), ac, "check_spelling" );
//Fg Color
actionFgColor = new KAction( i18n("Text &Color..."), "color_line", 0,
@@ -200,10 +200,10 @@ void KopeteRichTextEditPart::createActions( KActionCollection *ac )
connect( action_align_justify, TQT_SIGNAL( toggled(bool) ),
this, TQT_SLOT( setAlignJustify(bool) ) );
- action_align_left->setExclusiveGroup( "alignment" );
- action_align_center->setExclusiveGroup( "alignment" );
- action_align_right->setExclusiveGroup( "alignment" );
- action_align_justify->setExclusiveGroup( "alignment" );
+ action_align_left->setExclusiveGroup( "tqalignment" );
+ action_align_center->setExclusiveGroup( "tqalignment" );
+ action_align_right->setExclusiveGroup( "tqalignment" );
+ action_align_justify->setExclusiveGroup( "tqalignment" );
connect( editor, TQT_SIGNAL( cursorPositionChanged( int,int ) ),
this, TQT_SLOT( updateAligment() ) );
@@ -248,7 +248,7 @@ void KopeteRichTextEditPart::updateCharFmt()
void KopeteRichTextEditPart::clear()
{
- editor->setText( TQString::null );
+ editor->setText( TQString() );
setFont( mFont );
setFgColor( mFgColor );
@@ -268,7 +268,7 @@ void KopeteRichTextEditPart::clear()
void KopeteRichTextEditPart::updateAligment()
{
- int align = editor->alignment();
+ int align = editor->tqalignment();
switch ( align )
{
@@ -351,7 +351,7 @@ void KopeteRichTextEditPart::writeConfig()
config->writeEntry("FontUnderline", mFont.underline() );
config->writeEntry("BgColor", mBgColor );
config->writeEntry("FgColor", mFgColor );
- config->writeEntry("EditAlignment", editor->alignment() );
+ config->writeEntry("EditAlignment", editor->tqalignment() );
config->sync();
}
@@ -515,34 +515,34 @@ void KopeteRichTextEditPart::setUnderline( bool b )
void KopeteRichTextEditPart::setAlignLeft( bool yes )
{
if ( yes )
- editor->setAlignment( AlignLeft );
+ editor->tqsetAlignment( AlignLeft );
writeConfig();
}
void KopeteRichTextEditPart::setAlignRight( bool yes )
{
if ( yes )
- editor->setAlignment( AlignRight );
+ editor->tqsetAlignment( AlignRight );
writeConfig();
}
void KopeteRichTextEditPart::setAlignCenter( bool yes )
{
if ( yes )
- editor->setAlignment( AlignCenter );
+ editor->tqsetAlignment( AlignCenter );
writeConfig();
}
void KopeteRichTextEditPart::setAlignJustify( bool yes )
{
if ( yes )
- editor->setAlignment( AlignJustify );
+ editor->tqsetAlignment( AlignJustify );
writeConfig();
}
-TQString KopeteRichTextEditPart::text( Qt::TextFormat fmt ) const
+TQString KopeteRichTextEditPart::text( TQt::TextFormat fmt ) const
{
- if( fmt == editor->textFormat() || fmt != Qt::PlainText )
+ if( fmt == editor->textFormat() || fmt != TQt::PlainText )
return editor->text();
else
return editor->cursor()->document()->plainText();