From ffe8a83e053396df448e9413828527613ca3bd46 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:46:43 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1157647 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kspell2/plugins/hspell/kspell_hspelldict.cpp | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'kspell2/plugins/hspell/kspell_hspelldict.cpp') diff --git a/kspell2/plugins/hspell/kspell_hspelldict.cpp b/kspell2/plugins/hspell/kspell_hspelldict.cpp index e8944dbf7..04f055e86 100644 --- a/kspell2/plugins/hspell/kspell_hspelldict.cpp +++ b/kspell2/plugins/hspell/kspell_hspelldict.cpp @@ -23,18 +23,18 @@ #include "kspell_hspelldict.h" #include -#include +#include using namespace KSpell2; -HSpellDict::HSpellDict( const QString& lang ) +HSpellDict::HSpellDict( const TQString& lang ) : Dictionary( lang ) { int int_error = hspell_init( &m_speller, HSPELL_OPT_DEFAULT ); if ( int_error == -1 ) kdDebug() << "HSpellDict::HSpellDict: Init failed" << endl; /* hspell understans only iso8859-8-i */ - codec = QTextCodec::codecForName( "iso8859-8-i" ); + codec = TQTextCodec::codecForName( "iso8859-8-i" ); } HSpellDict::~HSpellDict() @@ -43,11 +43,11 @@ HSpellDict::~HSpellDict() hspell_uninit( m_speller ); } -bool HSpellDict::check( const QString& word ) +bool HSpellDict::check( const TQString& word ) { kdDebug() << "HSpellDict::check word = " << word <fromUnicode( word ); + TQCString wordISO = codec->fromUnicode( word ); /* returns 1 if the word is correct, 0 otherwise */ int correct = hspell_check_word ( m_speller, wordISO, @@ -61,9 +61,9 @@ bool HSpellDict::check( const QString& word ) return correct == 1; } -QStringList HSpellDict::suggest( const QString& word ) +TQStringList HSpellDict::suggest( const TQString& word ) { - QStringList qsug; + TQStringList qsug; struct corlist cl; int n_sugg; corlist_init( &cl ); @@ -75,8 +75,8 @@ QStringList HSpellDict::suggest( const QString& word ) return qsug; } -bool HSpellDict::checkAndSuggest( const QString& word, - QStringList& suggestions ) +bool HSpellDict::checkAndSuggest( const TQString& word, + TQStringList& suggestions ) { bool c = check( word ); if( c ) @@ -84,22 +84,22 @@ bool HSpellDict::checkAndSuggest( const QString& word, return c; } -bool HSpellDict::storeReplacement( const QString& bad, - const QString& good ) +bool HSpellDict::storeReplacement( const TQString& bad, + const TQString& good ) { // hspell-0.9 cannot do this kdDebug() << "HSpellDict::storeReplacement: Sorry, cannot." << endl; return false; } -bool HSpellDict::addToPersonal( const QString& word ) +bool HSpellDict::addToPersonal( const TQString& word ) { // hspell-0.9 cannot do this kdDebug() << "HSpellDict::addToPersonal: Sorry, cannot." << endl; return false; } -bool HSpellDict::addToSession( const QString& word ) +bool HSpellDict::addToSession( const TQString& word ) { // hspell-0.9 cannot do this kdDebug() << "HSpellDict::addToSession: Sorry, cannot." << endl; -- cgit v1.2.1