Rename old tq methods that no longer need a unique name

r14.0.x
Timothy Pearson 13 years ago
parent 3b005fadaa
commit b3604f731c

@ -217,7 +217,7 @@ bool BT_ThMLHTML::handleToken(sword::SWBuf &buf, const char *token, sword::Basic
if (tag.getAttribute("lang")) { if (tag.getAttribute("lang")) {
const char* abbrev = tag.getAttribute("lang"); const char* abbrev = tag.getAttribute("lang");
//const CLanguageMgr::Language* const language = CPointers::languageMgr()->languageForAbbrev( TQString::tqfromLatin1(abbrev) ); //const CLanguageMgr::Language* const language = CPointers::languageMgr()->languageForAbbrev( TQString::fromLatin1(abbrev) );
buf.append("<span class=\"foreign\" lang=\""); buf.append("<span class=\"foreign\" lang=\"");
buf.append(abbrev); buf.append(abbrev);

@ -163,7 +163,7 @@ namespace Rendering {
entry.append("<span class=\"entryname\" dir=\"ltr\">").append(entryLink(i, *mod_Itr)).append("</span>"); entry.append("<span class=\"entryname\" dir=\"ltr\">").append(entryLink(i, *mod_Itr)).append("</span>");
if (m_settings.addText) { if (m_settings.addText) {
//entry.append( TQString::tqfromLatin1("<span %1>%2</span>").tqarg(langAttr).tqarg(key_renderedText) ); //entry.append( TQString::fromLatin1("<span %1>%2</span>").tqarg(langAttr).tqarg(key_renderedText) );
entry.append( key_renderedText ); entry.append( key_renderedText );
} }

@ -227,7 +227,7 @@ const unsigned int CSwordBibleModuleInfo::bookNumber(const TQString &book) {
/** Returns true if his module has the text of desired type of testament */ /** Returns true if his module has the text of desired type of testament */
const bool CSwordBibleModuleInfo::hasTestament( CSwordBibleModuleInfo::Testament type ) { const bool CSwordBibleModuleInfo::hasTestament( CSwordBibleModuleInfo::Testament type ) {
if (m_hasOT == -1 || m_hasNT == -1) { if (m_hasOT == -1 || m_hasNT == -1) {
const bool oldtqStatus = module()->getSkipConsecutiveLinks(); const bool oldStatus = module()->getSkipConsecutiveLinks();
module()->setSkipConsecutiveLinks(true); module()->setSkipConsecutiveLinks(true);
*module() = sword::TOP; //position to first entry *module() = sword::TOP; //position to first entry
@ -250,7 +250,7 @@ const bool CSwordBibleModuleInfo::hasTestament( CSwordBibleModuleInfo::Testament
m_hasNT = 1; m_hasNT = 1;
} }
module()->setSkipConsecutiveLinks(oldtqStatus); module()->setSkipConsecutiveLinks(oldStatus);
} }
switch (type) { switch (type) {

@ -107,8 +107,8 @@ TQStringList* const CSwordLexiconModuleInfo::entries() {
m_entryList->append(TQString::fromUtf8(my_module->KeyText())); m_entryList->append(TQString::fromUtf8(my_module->KeyText()));
// qWarning("Entry: %s", my_module->KeyText() ); // qWarning("Entry: %s", my_module->KeyText() );
} }
else { //for latin1 modules use tqfromLatin1 because of speed else { //for latin1 modules use fromLatin1 because of speed
// m_entryList->append(TQString::tqfromLatin1(my_module->KeyText())); // m_entryList->append(TQString::fromLatin1(my_module->KeyText()));
TQTextCodec *codec = TQTextCodec::codecForName("CP1252"); TQTextCodec *codec = TQTextCodec::codecForName("CP1252");
m_entryList->append(codec->toUnicode(my_module->KeyText())); m_entryList->append(codec->toUnicode(my_module->KeyText()));
@ -148,7 +148,7 @@ TQStringList* const CSwordLexiconModuleInfo::entries() {
if (m_entryList->count()) { if (m_entryList->count()) {
//create cache //create cache
TQString dir = KGlobal::dirs()->saveLocation("data", "bibletime/cache/"); TQString dir = KGlobal::dirs()->saveLocation("data", "bibletime/cache/");
//TQFile f2( TQString::tqfromLatin1("%1/%2").tqarg(dir).tqarg( name() ) ); //TQFile f2( TQString::fromLatin1("%1/%2").tqarg(dir).tqarg( name() ) );
TQFile f2( TQString(dir).append("/").append(name()) ); TQFile f2( TQString(dir).append("/").append(name()) );

@ -153,13 +153,13 @@ const bool CSwordModuleInfo::unlockKeyIsValid() {
(*m_module) = sword::TOP; (*m_module) = sword::TOP;
// This needs to use ::tqfromLatin1 because if the text is still locked, // This needs to use ::fromLatin1 because if the text is still locked,
// a lot of garbage will show up. It will also work with properly decrypted // a lot of garbage will show up. It will also work with properly decrypted
// Unicode text, because all non-ASCII Unicode chars consist of bytes >127 // Unicode text, because all non-ASCII Unicode chars consist of bytes >127
// and therefore contain no control (nonprintable) characters, which are all <127. // and therefore contain no control (nonprintable) characters, which are all <127.
TQString test = isUnicode() TQString test = isUnicode()
? TQString::fromUtf8(m_module->getRawEntryBuf().c_str()) ? TQString::fromUtf8(m_module->getRawEntryBuf().c_str())
: TQString::tqfromLatin1( m_module->getRawEntryBuf().c_str() ); : TQString::fromLatin1( m_module->getRawEntryBuf().c_str() );
if (test.isEmpty()) { if (test.isEmpty()) {
qWarning("Unlock key of module %s is NOT valid", name().latin1()); qWarning("Unlock key of module %s is NOT valid", name().latin1());
@ -756,7 +756,7 @@ TQString CSwordModuleInfo::aboutText() const {
for (opts = CSwordModuleInfo::filterTypesMIN; opts <= CSwordModuleInfo::filterTypesMAX; ++opts) { for (opts = CSwordModuleInfo::filterTypesMIN; opts <= CSwordModuleInfo::filterTypesMAX; ++opts) {
if (has(static_cast < CSwordModuleInfo::FilterTypes > (opts))) { if (has(static_cast < CSwordModuleInfo::FilterTypes > (opts))) {
if (!options.isEmpty()) { if (!options.isEmpty()) {
options += TQString::tqfromLatin1(", "); options += TQString::fromLatin1(", ");
} }
options += CSwordBackend::translatedOptionName(static_cast < CSwordModuleInfo::FilterTypes > (opts)); options += CSwordBackend::translatedOptionName(static_cast < CSwordModuleInfo::FilterTypes > (opts));
@ -871,7 +871,7 @@ const CLanguageMgr::Language * const CSwordModuleInfo::language() const {
TQString CSwordModuleInfo::getSimpleConfigEntry(const TQString& name) const { TQString CSwordModuleInfo::getSimpleConfigEntry(const TQString& name) const {
TQString ret = isUnicode() TQString ret = isUnicode()
? TQString::fromUtf8(m_module->getConfigEntry(name.latin1())) ? TQString::fromUtf8(m_module->getConfigEntry(name.latin1()))
: TQString::tqfromLatin1(m_module->getConfigEntry(name.latin1())); : TQString::fromLatin1(m_module->getConfigEntry(name.latin1()));
return ret.isEmpty() ? TQString() : ret; return ret.isEmpty() ? TQString() : ret;
} }
@ -882,7 +882,7 @@ TQString CSwordModuleInfo::getFormattedConfigEntry(const TQString& name) const {
RTF_Filter.processText(RTF_Buffer, 0, 0); RTF_Filter.processText(RTF_Buffer, 0, 0);
TQString ret = isUnicode() TQString ret = isUnicode()
? TQString::fromUtf8(RTF_Buffer.c_str()) ? TQString::fromUtf8(RTF_Buffer.c_str())
: TQString::tqfromLatin1(RTF_Buffer.c_str()); : TQString::fromLatin1(RTF_Buffer.c_str());
return ret.isEmpty() ? TQString() : ret; return ret.isEmpty() ? TQString() : ret;
} }

@ -173,19 +173,19 @@ const bool CSwordVerseKey::next( const JumpType type ) {
case UseVerse: { case UseVerse: {
if (m_module && m_module->module()) { if (m_module && m_module->module()) {
const bool oldtqStatus = m_module->module()->getSkipConsecutiveLinks(); const bool oldStatus = m_module->module()->getSkipConsecutiveLinks();
m_module->module()->setSkipConsecutiveLinks(true); m_module->module()->setSkipConsecutiveLinks(true);
//disable headings for next verse //disable headings for next verse
const bool useHeaders = (Verse() == 0); const bool useHeaders = (Verse() == 0);
const bool oldHeadingstqStatus = ((VerseKey*)(m_module->module()->getKey()))->Headings( useHeaders ); const bool oldHeadingsStatus = ((VerseKey*)(m_module->module()->getKey()))->Headings( useHeaders );
//don't use setKey(), that would create a new key without Headings set //don't use setKey(), that would create a new key without Headings set
m_module->module()->getKey()->setText( (const char*)key().utf8() ); m_module->module()->getKey()->setText( (const char*)key().utf8() );
(*(m_module->module()) )++; (*(m_module->module()) )++;
((VerseKey*)(m_module->module()->getKey()))->Headings(oldHeadingstqStatus); ((VerseKey*)(m_module->module()->getKey()))->Headings(oldHeadingsStatus);
m_module->module()->setSkipConsecutiveLinks(oldtqStatus); m_module->module()->setSkipConsecutiveLinks(oldStatus);
if (!m_module->module()->Error()) { if (!m_module->module()->Error()) {
key( TQString::fromUtf8(m_module->module()->KeyText()) ); key( TQString::fromUtf8(m_module->module()->KeyText()) );
@ -258,16 +258,16 @@ const bool CSwordVerseKey::previous( const JumpType type ) {
case UseVerse: { case UseVerse: {
if (m_module && m_module->module()) { if (m_module && m_module->module()) {
const bool useHeaders = (Verse() == 0); const bool useHeaders = (Verse() == 0);
const bool oldHeadingstqStatus = ((VerseKey*)(m_module->module()->getKey()))->Headings( useHeaders ); const bool oldHeadingsStatus = ((VerseKey*)(m_module->module()->getKey()))->Headings( useHeaders );
m_module->module()->getKey()->setText( (const char*)key().utf8() ); m_module->module()->getKey()->setText( (const char*)key().utf8() );
const bool oldtqStatus = m_module->module()->getSkipConsecutiveLinks(); const bool oldStatus = m_module->module()->getSkipConsecutiveLinks();
m_module->module()->setSkipConsecutiveLinks(true); m_module->module()->setSkipConsecutiveLinks(true);
( *( m_module->module() ) )--; ( *( m_module->module() ) )--;
((VerseKey*)(m_module->module()->getKey()))->Headings( oldHeadingstqStatus ); ((VerseKey*)(m_module->module()->getKey()))->Headings( oldHeadingsStatus );
m_module->module()->setSkipConsecutiveLinks(oldtqStatus); m_module->module()->setSkipConsecutiveLinks(oldStatus);
if (!m_module->module()->Error()) { if (!m_module->module()->Error()) {
key( TQString::fromUtf8(m_module->module()->KeyText()) );//don't use fromUtf8 key( TQString::fromUtf8(m_module->module()->KeyText()) );//don't use fromUtf8

@ -324,6 +324,6 @@ void BibleTime::polish() {
m_initialized = true; m_initialized = true;
KMainWindow::polish(); KMainWindow::polish();
applyMainWindowSettings(CBTConfig::getConfig(), TQString::tqfromLatin1("MainWindow")); applyMainWindowSettings(CBTConfig::getConfig(), TQString::fromLatin1("MainWindow"));
} }

@ -41,7 +41,7 @@ namespace BookshelfManager {
const TQString BTInstallMgr::Tool::LocalConfig::swordConfigFilename() { const TQString BTInstallMgr::Tool::LocalConfig::swordConfigFilename() {
// Q_ASSERT( CPointers::backend()->sysconfig ); // Q_ASSERT( CPointers::backend()->sysconfig );
return TQString::tqfromLatin1("%1/.sword/sword.conf").tqarg(getenv("HOME")); return TQString::fromLatin1("%1/.sword/sword.conf").tqarg(getenv("HOME"));
} }
TQStringList BTInstallMgr::Tool::RemoteConfig::sourceList( sword::InstallMgr* mgr ) { TQStringList BTInstallMgr::Tool::RemoteConfig::sourceList( sword::InstallMgr* mgr ) {
@ -65,7 +65,7 @@ namespace BookshelfManager {
while (sourceBegin != sourceEnd) { while (sourceBegin != sourceEnd) {
InstallSource is("DIR", sourceBegin->second.c_str()); InstallSource is("DIR", sourceBegin->second.c_str());
names << TQString::tqfromLatin1(is.caption.c_str()); names << TQString::fromLatin1(is.caption.c_str());
sourceBegin++; sourceBegin++;
} }
@ -117,7 +117,7 @@ namespace BookshelfManager {
if (!directAccess) { //use tdesu to move the file to the right place if (!directAccess) { //use tdesu to move the file to the right place
KProcess *proc = new KProcess; KProcess *proc = new KProcess;
*proc << "tdesu"; *proc << "tdesu";
*proc << TQString::tqfromLatin1("-c") << TQString("mv %1 %2").tqarg(filename).tqarg(LocalConfig::swordConfigFilename()); *proc << TQString::fromLatin1("-c") << TQString("mv %1 %2").tqarg(filename).tqarg(LocalConfig::swordConfigFilename());
proc->start(KProcess::Block); proc->start(KProcess::Block);
} }
} }
@ -326,7 +326,7 @@ namespace BookshelfManager {
emit completed(totalPercent, filePercent); emit completed(totalPercent, filePercent);
} }
void BTInstallMgr::pretqStatus(long totalBytes, long completedBytes, const char* /*message*/) { void BTInstallMgr::preStatus(long totalBytes, long completedBytes, const char* /*message*/) {
qWarning("pre Status: %i / %i", (int)totalBytes, (int)completedBytes); qWarning("pre Status: %i / %i", (int)totalBytes, (int)completedBytes);
emit downloadStarted( "unknown filename" ); emit downloadStarted( "unknown filename" );

@ -94,7 +94,7 @@ public:
protected: protected:
/* Reimplementations of method in StatusReporter */ /* Reimplementations of method in StatusReporter */
virtual void statusUpdate(double dltotal, double dlnow); virtual void statusUpdate(double dltotal, double dlnow);
virtual void pretqStatus(long totalBytes, long completedBytes, const char *message); virtual void preStatus(long totalBytes, long completedBytes, const char *message);
// virtual FTPTransport *createFTPTransport(const char *host, StatusReporter *statusReporter); // virtual FTPTransport *createFTPTransport(const char *host, StatusReporter *statusReporter);

@ -48,7 +48,7 @@ const char* CDragDropMgr::BTDrag::format( int i ) const {
bool CDragDropMgr::BTDrag::decode(const TQMimeSource* e, TQString& str) { bool CDragDropMgr::BTDrag::decode(const TQMimeSource* e, TQString& str) {
if (canDecode(e)) { if (canDecode(e)) {
str = TQString( e->tqencodedData( "BibleTime/DND" ) ); str = TQString( e->encodedData( "BibleTime/DND" ) );
return true; return true;
} }
return false; return false;
@ -58,8 +58,8 @@ bool CDragDropMgr::BTDrag::decode(const TQMimeSource* e, TQString& str, TQCStrin
return decode(e, str); return decode(e, str);
}; };
TQByteArray CDragDropMgr::BTDrag::tqencodedData( const char* /*type*/ ) const { TQByteArray CDragDropMgr::BTDrag::encodedData( const char* /*type*/ ) const {
return TQTextDrag::tqencodedData("text/plain"); //hack because TQTextDrag only accepts text/plainand not our BibleTime/DND type return TQTextDrag::encodedData("text/plain"); //hack because TQTextDrag only accepts text/plainand not our BibleTime/DND type
}; };
///////////////////////////// new class ////////////////////// ///////////////////////////// new class //////////////////////

@ -135,7 +135,7 @@ public:
virtual bool provides( const char* type ) const; virtual bool provides( const char* type ) const;
virtual const char* format( int i = 0 ) const; virtual const char* format( int i = 0 ) const;
virtual TQByteArray tqencodedData( const char* type ) const; virtual TQByteArray encodedData( const char* type ) const;
protected: protected:
friend class CDragDropMgr; friend class CDragDropMgr;

@ -44,7 +44,7 @@ using namespace Rendering;
using namespace Printing; using namespace Printing;
CExportManager::CExportManager(const TQString& caption, const bool showProgress, const TQString& progressLabel, const CSwordBackend::FilterOptions filterOptions, const CSwordBackend::DisplayOptions displayOptions) { CExportManager::CExportManager(const TQString& caption, const bool showProgress, const TQString& progressLabel, const CSwordBackend::FilterOptions filterOptions, const CSwordBackend::DisplayOptions displayOptions) {
m_caption = !caption.isEmpty() ? caption : TQString::tqfromLatin1("BibleTime"); m_caption = !caption.isEmpty() ? caption : TQString::fromLatin1("BibleTime");
m_progressLabel = progressLabel; m_progressLabel = progressLabel;
m_filterOptions = filterOptions; m_filterOptions = filterOptions;
m_displayOptions = displayOptions; m_displayOptions = displayOptions;
@ -485,7 +485,7 @@ const TQString CExportManager::getSaveFileName(const Format format) {
/** Returns a string containing the linebreak for the current format. */ /** Returns a string containing the linebreak for the current format. */
const TQString CExportManager::lineBreak(const Format format) { const TQString CExportManager::lineBreak(const Format format) {
if (static_cast<bool>(m_displayOptions.lineBreaks)) if (static_cast<bool>(m_displayOptions.lineBreaks))
return (format == HTML) ? TQString::tqfromLatin1("<br/>\n") : TQString::tqfromLatin1("\n"); return (format == HTML) ? TQString::fromLatin1("<br/>\n") : TQString::fromLatin1("\n");
return TQString(); return TQString();
} }

@ -87,12 +87,12 @@ void CModuleIndexDialog::slotModuleProgress( int percentage ) {
// qDebug("progress %d", percentage); // qDebug("progress %d", percentage);
progress->progressBar()->setProgress( m_currentModuleIndex * 100 + percentage ); progress->progressBar()->setProgress( m_currentModuleIndex * 100 + percentage );
KApplication::kApplication()->tqprocessEvents( 10 ); //10 ms only KApplication::kApplication()->processEvents( 10 ); //10 ms only
} }
void CModuleIndexDialog::slotFinished( ) { void CModuleIndexDialog::slotFinished( ) {
qDebug("indexing finished()"); qDebug("indexing finished()");
progress->progressBar()->setProgress( progress->progressBar()->totalSteps() ); progress->progressBar()->setProgress( progress->progressBar()->totalSteps() );
KApplication::kApplication()->tqprocessEvents( 1 ); //1 ms only KApplication::kApplication()->processEvents( 1 ); //1 ms only
} }

@ -276,7 +276,7 @@ void COptionsDialog::initLanguages() {
(CBTConfig::language).local8Bit() (CBTConfig::language).local8Bit()
); );
if (locale) { if (locale) {
currentLanguageName = TQString::tqfromLatin1(locale->getDescription()); currentLanguageName = TQString::fromLatin1(locale->getDescription());
} }
} }
@ -351,7 +351,7 @@ void COptionsDialog::initLanguages() {
m_settings.fonts.fontChooser->setFont( m_settings.fonts.fontMap[m_settings.fonts.usage->currentText()].second ); m_settings.fonts.fontChooser->setFont( m_settings.fonts.fontMap[m_settings.fonts.usage->currentText()].second );
useOwnFontClicked( m_settings.fonts.fontMap[m_settings.fonts.usage->currentText()].first ); useOwnFontClicked( m_settings.fonts.fontMap[m_settings.fonts.usage->currentText()].first );
m_settings.fonts.useOwnFontBox->setChecked( m_settings.fonts.fontMap[m_settings.fonts.usage->currentText()].first ); m_settings.fonts.useOwnFontBox->setChecked( m_settings.fonts.fontMap[m_settings.fonts.usage->currentText()].first );
m_settings.fonts.fontChooser->setMinimumSize(m_settings.fonts.fontChooser->tqsizeHint()); m_settings.fonts.fontChooser->setMinimumSize(m_settings.fonts.fontChooser->sizeHint());
} }
} }
@ -853,8 +853,8 @@ void COptionsDialog::saveSword() {
SWLocale* locale = LocaleMgr::getSystemLocaleMgr()->getLocale((*it).c_str()); SWLocale* locale = LocaleMgr::getSystemLocaleMgr()->getLocale((*it).c_str());
Q_ASSERT(locale); Q_ASSERT(locale);
if ( locale && (TQString::tqfromLatin1(locale->getDescription()) == currentLanguageName) ) { if ( locale && (TQString::fromLatin1(locale->getDescription()) == currentLanguageName) ) {
languageAbbrev = TQString::tqfromLatin1(locale->getName()); //we found the abbrevation for the current language languageAbbrev = TQString::fromLatin1(locale->getName()); //we found the abbrevation for the current language
break; break;
} }
} }

@ -89,7 +89,7 @@ namespace Printing {
Q_ASSERT(printItem); Q_ASSERT(printItem);
if (printItem && printItem->hasAlternativeContent()) { if (printItem && printItem->hasAlternativeContent()) {
TQString ret = TQString::tqfromLatin1("<div class=\"entry\"><div class=\"rangeheading\">%1</div>").tqarg(printItem->getAlternativeContent()); TQString ret = TQString::fromLatin1("<div class=\"entry\"><div class=\"rangeheading\">%1</div>").tqarg(printItem->getAlternativeContent());
if (i.hasChildItems()) { if (i.hasChildItems()) {
KeyTree const * tree = i.childList(); KeyTree const * tree = i.childList();

@ -424,7 +424,7 @@ the module remote installation feature!</b>")
prefixPath = prefixPath.remove( prefixPath.find(dataPath), dataPath.length() ); prefixPath = prefixPath.remove( prefixPath.find(dataPath), dataPath.length() );
} }
else { //fall back to default Sword config path else { //fall back to default Sword config path
prefixPath = TQString::tqfromLatin1(backend()->prefixPath); prefixPath = TQString::fromLatin1(backend()->prefixPath);
} }
sword::SWMgr* mgr = mgrDict[ prefixPath ]; sword::SWMgr* mgr = mgrDict[ prefixPath ];
@ -758,7 +758,7 @@ the module remote installation feature!</b>")
//prefixPath = prefixPath.replace(dataPath, ""); //old code working with TQt 3.2 //prefixPath = prefixPath.replace(dataPath, ""); //old code working with TQt 3.2
} }
else { else {
prefixPath = TQString::tqfromLatin1(backend()->prefixPath); prefixPath = TQString::fromLatin1(backend()->prefixPath);
} }
sword::SWMgr mgr(prefixPath.latin1()); sword::SWMgr mgr(prefixPath.latin1());

@ -50,7 +50,7 @@ namespace BookshelfManager {
TQListViewItem* i = m_parent->itemAt(pos); TQListViewItem* i = m_parent->itemAt(pos);
Q_ASSERT(i); Q_ASSERT(i);
const TQRect rect = m_parent->tqitemRect(i); const TQRect rect = m_parent->itemRect(i);
if (m_parent->showTooltip(i, pos, 0)) { if (m_parent->showTooltip(i, pos, 0)) {
const TQString tipText = m_parent->tooltip(i, 0); const TQString tipText = m_parent->tooltip(i, 0);
tip(rect, tipText); tip(rect, tipText);

@ -66,15 +66,15 @@ void CHTMLWriteDisplay::toggleUnderline() {
void CHTMLWriteDisplay::alignLeft() { void CHTMLWriteDisplay::alignLeft() {
tqsetAlignment(TQt::AlignLeft); setAlignment(TQt::AlignLeft);
}; };
void CHTMLWriteDisplay::alignCenter() { void CHTMLWriteDisplay::alignCenter() {
tqsetAlignment(TQt::AlignHCenter); setAlignment(TQt::AlignHCenter);
}; };
void CHTMLWriteDisplay::alignRight() { void CHTMLWriteDisplay::alignRight() {
tqsetAlignment(TQt::AlignRight); setAlignment(TQt::AlignRight);
}; };
@ -153,7 +153,7 @@ void CHTMLWriteDisplay::setupToolbar(KToolBar * bar, KActionCollection * actions
m_colorButton = new KColorButton(bar); m_colorButton = new KColorButton(bar);
connect(m_colorButton, TQT_SIGNAL(changed(const TQColor&)), TQT_TQOBJECT(this), TQT_SLOT(slotColorSelected(const TQColor&))); connect(m_colorButton, TQT_SIGNAL(changed(const TQColor&)), TQT_TQOBJECT(this), TQT_SLOT(slotColorSelected(const TQColor&)));
bar->insertWidget(50, m_colorButton->tqsizeHint().width(), m_colorButton); bar->insertWidget(50, m_colorButton->sizeHint().width(), m_colorButton);
TQToolTip::add TQToolTip::add
(m_colorButton, CResMgr::displaywindows::writeWindow::fontColor::tooltip ); (m_colorButton, CResMgr::displaywindows::writeWindow::fontColor::tooltip );

@ -138,7 +138,7 @@ void CPlainWriteDisplay::contentsDropEvent( TQDropEvent* e ) {
TQString moduleText = key->strippedText(); TQString moduleText = key->strippedText();
const TQString text = TQString::tqfromLatin1("%1\n(%2, %3)\n").tqarg(moduleText).tqarg((*it).bookmarkKey()).tqarg((*it).bookmarkModule()); const TQString text = TQString::fromLatin1("%1\n(%2, %3)\n").tqarg(moduleText).tqarg((*it).bookmarkKey()).tqarg((*it).bookmarkModule());
placeCursor( e->pos() ); placeCursor( e->pos() );
insert( text ); insert( text );

@ -53,10 +53,10 @@ void CBibleReadWindow::applyProfileSettings( CProfileWindow* const settings ) {
for (int i = count-1; i>=1; i--) { for (int i = count-1; i>=1; i--) {
if (result-(int)pow((double)2,i-1)>= 0) { //2^i was added before, so item with index i is set if (result-(int)pow((double)2,i-1)>= 0) { //2^i was added before, so item with index i is set
result -= (int)pow((double)2,i-1); result -= (int)pow((double)2,i-1);
displaySettingsButton()->setItemtqStatus(i,true); displaySettingsButton()->setItemStatus(i,true);
} }
else { else {
displaySettingsButton()->setItemtqStatus(i,false); displaySettingsButton()->setItemStatus(i,false);
} }
} }
displaySettingsButton()->setChanged(); displaySettingsButton()->setChanged();
@ -69,7 +69,7 @@ void CBibleReadWindow::storeProfileSettings( CProfileWindow* const settings ) {
int result = 0; int result = 0;
//now check every item //now check every item
for (int i = 1; i < count; i++) { //first item is a title for (int i = 1; i < count; i++) { //first item is a title
if (displaySettingsButton()->itemtqStatus(i)) //item is checked if (displaySettingsButton()->itemStatus(i)) //item is checked
result += (int)pow((double)2,i-1);//add 2^i (the i. digit in binary) result += (int)pow((double)2,i-1);//add 2^i (the i. digit in binary)
} }
settings->setWindowSettings(result); settings->setWindowSettings(result);

@ -134,7 +134,7 @@ void CBookReadWindow::initToolbars() {
m_actions.backInHistory->plug( mainToolBar(), 0 ); m_actions.backInHistory->plug( mainToolBar(), 0 );
m_actions.forwardInHistory->plug( mainToolBar(), 1 ); m_actions.forwardInHistory->plug( mainToolBar(), 1 );
mainToolBar()->insertWidget(0,keyChooser()->tqsizeHint().width(),keyChooser()); mainToolBar()->insertWidget(0,keyChooser()->sizeHint().width(),keyChooser());
m_treeAction->plug(buttonsToolBar()); m_treeAction->plug(buttonsToolBar());
m_treeAction->setChecked(false); m_treeAction->setChecked(false);

@ -65,7 +65,7 @@
// sword::StringList::iterator it; // sword::StringList::iterator it;
// //
// for (it = options.begin(); it != options.end(); ++it) { // for (it = options.begin(); it != options.end(); ++it) {
// int id = m_popup->insertItem(TQString::tqfromLatin1((*it).c_str())); // int id = m_popup->insertItem(TQString::fromLatin1((*it).c_str()));
// if (m_filterOptions->transliteration == m_popup->indexOf(id)-1 ) { //workaround // if (m_filterOptions->transliteration == m_popup->indexOf(id)-1 ) { //workaround
// m_popup->setItemChecked(id, true); // m_popup->setItemChecked(id, true);
// } // }
@ -198,7 +198,7 @@ const int CDisplaySettingsButton::menuItemCount() {
} }
/** Sets the item at position pos to the satet given as 2nd paramter. */ /** Sets the item at position pos to the satet given as 2nd paramter. */
void CDisplaySettingsButton::setItemtqStatus( const int index, const bool checked ) { void CDisplaySettingsButton::setItemStatus( const int index, const bool checked ) {
const int ID = m_popup->idAt(index); const int ID = m_popup->idAt(index);
m_popup->setItemChecked(ID, checked); m_popup->setItemChecked(ID, checked);
const TQString text = m_popup->text(ID).remove('&'); const TQString text = m_popup->text(ID).remove('&');
@ -208,7 +208,7 @@ void CDisplaySettingsButton::setItemtqStatus( const int index, const bool checke
} }
/** Returns the status of the item at position "index" */ /** Returns the status of the item at position "index" */
const bool CDisplaySettingsButton::itemtqStatus( const int index ) { const bool CDisplaySettingsButton::itemStatus( const int index ) {
return m_popup->isItemChecked( m_popup->idAt(index) ); return m_popup->isItemChecked( m_popup->idAt(index) );
} }

@ -65,7 +65,7 @@ public:
/** /**
* Sets the item at position pos to the satet given as 2nd paramter. * Sets the item at position pos to the satet given as 2nd paramter.
*/ */
void setItemtqStatus( const int pos, const bool checked ); void setItemStatus( const int pos, const bool checked );
/** /**
* Returns the number of usable menu items in the setttings menu. * Returns the number of usable menu items in the setttings menu.
*/ */
@ -73,7 +73,7 @@ public:
/** /**
* Returns the status of the item at position "index" * Returns the status of the item at position "index"
*/ */
const bool itemtqStatus( const int index ); const bool itemStatus( const int index );
/** /**
* Sets the status to changed. The signal changed will be emitted. * Sets the status to changed. The signal changed will be emitted.
*/ */

@ -41,7 +41,7 @@ void CHTMLWriteWindow::initView() {
addDockWindow(mainToolBar()); addDockWindow(mainToolBar());
setKeyChooser( CKeyChooser::createInstance(modules(), key(), mainToolBar()) ); setKeyChooser( CKeyChooser::createInstance(modules(), key(), mainToolBar()) );
mainToolBar()->insertWidget(0,keyChooser()->tqsizeHint().width(),keyChooser()); mainToolBar()->insertWidget(0,keyChooser()->sizeHint().width(),keyChooser());
mainToolBar()->setFullSize(false); mainToolBar()->setFullSize(false);
}; };

@ -162,7 +162,7 @@ void CLexiconReadWindow::initView() {
setKeyChooser( CKeyChooser::createInstance(modules(), key(), mainToolBar()) ); setKeyChooser( CKeyChooser::createInstance(modules(), key(), mainToolBar()) );
mainToolBar()->insertWidget(0, keyChooser()->tqsizeHint().width(), keyChooser()); mainToolBar()->insertWidget(0, keyChooser()->sizeHint().width(), keyChooser());
mainToolBar()->setFullSize(false); mainToolBar()->setFullSize(false);
setModuleChooserBar( new CModuleChooserBar(modules(), modules().first()->type(), this) ); setModuleChooserBar( new CModuleChooserBar(modules(), modules().first()->type(), this) );

@ -190,7 +190,7 @@ void CModuleChooserButton::populateMenu() {
TQString lang = (*it)->language()->translatedName(); TQString lang = (*it)->language()->translatedName();
if (lang.isEmpty()) { if (lang.isEmpty()) {
//lang = TQString::tqfromLatin1("xx"); //unknown language -- do not use English as default!! //lang = TQString::fromLatin1("xx"); //unknown language -- do not use English as default!!
lang = (*it)->language()->abbrev(); lang = (*it)->language()->abbrev();
if (lang.isEmpty()) { if (lang.isEmpty()) {
lang = "xx"; lang = "xx";

@ -46,7 +46,7 @@ void CPlainWriteWindow::initView() {
addDockWindow(mainToolBar()); addDockWindow(mainToolBar());
setKeyChooser( CKeyChooser::createInstance(modules(), key(), mainToolBar()) ); setKeyChooser( CKeyChooser::createInstance(modules(), key(), mainToolBar()) );
mainToolBar()->insertWidget(0,keyChooser()->tqsizeHint().width(),keyChooser()); mainToolBar()->insertWidget(0,keyChooser()->sizeHint().width(),keyChooser());
mainToolBar()->setFullSize(false); mainToolBar()->setFullSize(false);
} }
@ -134,7 +134,7 @@ void CPlainWriteWindow::saveCurrentText( const TQString& /*key*/ ) {
textChanged(); textChanged();
} else { } else {
KMessageBox::error( this, KMessageBox::error( this,
TQString::tqfromLatin1("<qt><B>%1</B><BR>%2</qt>") TQString::fromLatin1("<qt><B>%1</B><BR>%2</qt>")
.tqarg( i18n("Module is not writable.") ) .tqarg( i18n("Module is not writable.") )
.tqarg( i18n("Either the module may not be edited, or " .tqarg( i18n("Either the module may not be edited, or "
"you do not have write permission.") ), "you do not have write permission.") ),

@ -69,7 +69,7 @@ void CWriteWindow::storeProfileSettings(CProfileWindow * const settings) {
sword::VerseKey* vk = dynamic_cast<sword::VerseKey*>(key()); sword::VerseKey* vk = dynamic_cast<sword::VerseKey*>(key());
TQString oldLang; TQString oldLang;
if (vk) { if (vk) {
oldLang = TQString::tqfromLatin1(vk->getLocale()); oldLang = TQString::fromLatin1(vk->getLocale());
vk->setLocale("en"); //save english locale names as default! vk->setLocale("en"); //save english locale names as default!
} }
settings->setKey( key()->key() ); settings->setKey( key()->key() );

@ -291,7 +291,7 @@ void CBookTreeChooser::show() {
if (!m_treeView->childCount()) { if (!m_treeView->childCount()) {
KApplication::setOverrideCursor(WaitCursor); KApplication::setOverrideCursor(WaitCursor);
setupTree(); //create the first level of the tree structure setupTree(); //create the first level of the tree structure
m_treeView->resize(m_treeView->tqsizeHint()); m_treeView->resize(m_treeView->sizeHint());
KApplication::restoreOverrideCursor(); KApplication::restoreOverrideCursor();
} }
} }

@ -147,7 +147,7 @@ void CKeyChooserWidget::reset(TQStringList *list, int index, bool do_emit) {
oldKey = TQString(); oldKey = TQString();
// m_comboBox->setUpdatesEnabled(false); // m_comboBox->setUpdatesEnabled(false);
//DON'T REMOVE THE HIDE: Otherwise TQComboBox's tqsizeHint() function won't work properly //DON'T REMOVE THE HIDE: Otherwise TQComboBox's sizeHint() function won't work properly
m_comboBox->hide(); m_comboBox->hide();
m_comboBox->clear(); m_comboBox->clear();
if (list) { if (list) {
@ -168,8 +168,8 @@ void CKeyChooserWidget::reset(TQStringList *list, int index, bool do_emit) {
emit changed(m_comboBox->currentItem()); emit changed(m_comboBox->currentItem());
} }
const TQSize dummySize = m_comboBox->tqsizeHint(); //without this function call the combo box won't be properly sized! const TQSize dummySize = m_comboBox->sizeHint(); //without this function call the combo box won't be properly sized!
//DON'T REMOVE OR MOVE THE show()! Otherwise TQComboBox's tqsizeHint() function won't work properly! //DON'T REMOVE OR MOVE THE show()! Otherwise TQComboBox's sizeHint() function won't work properly!
m_comboBox->show(); m_comboBox->show();
// m_comboBox->setFont( m_comboBox->font() ); // m_comboBox->setFont( m_comboBox->font() );

@ -44,7 +44,7 @@ public:
/** /**
* Returns the size this widget would like to have. * Returns the size this widget would like to have.
*/ */
// virtual TQSize tqsizeHint() const; // virtual TQSize sizeHint() const;
protected: protected:
/** /**

@ -37,9 +37,9 @@ const unsigned int MOVER_HEIGHT = 6;
CScrollerWidgetSet::CScrollerWidgetSet(TQWidget *parent, const char *name) : TQWidget(parent,name) { CScrollerWidgetSet::CScrollerWidgetSet(TQWidget *parent, const char *name) : TQWidget(parent,name) {
m_layout = new TQVBoxLayout(this); m_layout = new TQVBoxLayout(this);
m_layout->tqsetAlignment(TQt::AlignHCenter | TQt::AlignCenter); m_layout->setAlignment(TQt::AlignHCenter | TQt::AlignCenter);
//tqsetAlignment(TQt::AlignHCenter | TQt::AlignCenter); //setAlignment(TQt::AlignHCenter | TQt::AlignCenter);
btn_up = new TQToolButton( UpArrow, this, "btn_up" ); btn_up = new TQToolButton( UpArrow, this, "btn_up" );
btn_up->setFixedSize(WIDTH, ARROW_HEIGHT); btn_up->setFixedSize(WIDTH, ARROW_HEIGHT);

@ -67,7 +67,7 @@ KStartupLogo::KStartupLogo()
//Please not change the margin //Please not change the margin
textLabel = new TQLabel(this); textLabel = new TQLabel(this);
textLabel->setGeometry(0,pm.height(),pm.width(),textLabel->tqsizeHint().height()+10); textLabel->setGeometry(0,pm.height(),pm.width(),textLabel->sizeHint().height()+10);
textLabel->setBackgroundColor( TQColor("#0d6de9") ); textLabel->setBackgroundColor( TQColor("#0d6de9") );
textLabel->setFrameStyle(TQFrame::Panel | TQFrame::Plain); textLabel->setFrameStyle(TQFrame::Panel | TQFrame::Plain);
textLabel->setLineWidth(1); textLabel->setLineWidth(1);
@ -94,7 +94,7 @@ KStartupLogo::KStartupLogo()
void KStartupLogo::setText(const TQString text) { void KStartupLogo::setText(const TQString text) {
//Please not make the text bold & let the first character be blank //Please not make the text bold & let the first character be blank
textLabel->setText( TQString::tqfromLatin1(" %1").tqarg(text) ); textLabel->setText( TQString::fromLatin1(" %1").tqarg(text) );
KApplication::kApplication()->processEvents(); KApplication::kApplication()->processEvents();
} }

@ -284,7 +284,7 @@ void CBookmarkItem::update() {
setMultiLinesEnabled(true); setMultiLinesEnabled(true);
setPixmap(0,SmallIcon(CResMgr::mainIndex::bookmark::icon,16)); setPixmap(0,SmallIcon(CResMgr::mainIndex::bookmark::icon,16));
const TQString title = TQString::tqfromLatin1("%1 (%2)") const TQString title = TQString::fromLatin1("%1 (%2)")
.tqarg(key()) .tqarg(key())
.tqarg(module() ? module()->name() : i18n("unknown")); .tqarg(module() ? module()->name() : i18n("unknown"));
setText(0, title); setText(0, title);
@ -325,7 +325,7 @@ const TQString CBookmarkItem::toolTip() {
Q_ASSERT(k.get()); Q_ASSERT(k.get());
if (fontPair.first) { //use a special font if (fontPair.first) { //use a special font
qWarning("using a font, %s", TQString(fontPair.second.family()).latin1()); qWarning("using a font, %s", TQString(fontPair.second.family()).latin1());
ret = TQString::tqfromLatin1("<b>%1 (%2)</b><br/><small>%3</small><hr><font face=\"%4\" size=\"4\">%5</font>") ret = TQString::fromLatin1("<b>%1 (%2)</b><br/><small>%3</small><hr><font face=\"%4\" size=\"4\">%5</font>")
.tqarg(key()) .tqarg(key())
.tqarg(module()->name()) .tqarg(module()->name())
.tqarg(description()) .tqarg(description())
@ -333,7 +333,7 @@ const TQString CBookmarkItem::toolTip() {
.tqarg(k->renderedText()); .tqarg(k->renderedText());
} }
else { else {
ret = TQString::tqfromLatin1("<b>%1 (%2)</b><br/><small>%3</small><hr>%4") ret = TQString::fromLatin1("<b>%1 (%2)</b><br/><small>%3</small><hr>%4")
.tqarg(key()) .tqarg(key())
.tqarg(module()->name()) .tqarg(module()->name())
.tqarg(description()) .tqarg(description())
@ -652,19 +652,19 @@ void CTreeFolder::initTree() {
continue; continue;
} }
if (language() == TQString::tqfromLatin1("*") || (language() != TQString::tqfromLatin1("*") && TQString::tqfromLatin1((*it)->module()->Lang()) == language()) )//right type and language! if (language() == TQString::fromLatin1("*") || (language() != TQString::fromLatin1("*") && TQString::fromLatin1((*it)->module()->Lang()) == language()) )//right type and language!
usedModules.append(*it); usedModules.append(*it);
} }
} }
//we have now all modules we want to have //we have now all modules we want to have
if (language() == TQString::tqfromLatin1("*")) { //create subfolders for each language if (language() == TQString::fromLatin1("*")) { //create subfolders for each language
TQStringList usedLangs; TQStringList usedLangs;
// for (CSwordModuleInfo* m = usedModules.first(); m; m = usedModules.next()) { // for (CSwordModuleInfo* m = usedModules.first(); m; m = usedModules.next()) {
/*ListCSwordModuleInfo::iterator*/ /*ListCSwordModuleInfo::iterator*/
end_it = usedModules.end(); end_it = usedModules.end();
for (ListCSwordModuleInfo::iterator it(usedModules.begin()); it != end_it; ++it) { for (ListCSwordModuleInfo::iterator it(usedModules.begin()); it != end_it; ++it) {
TQString lang = TQString::tqfromLatin1((*it)->module()->Lang()); TQString lang = TQString::fromLatin1((*it)->module()->Lang());
// if (lang.isEmpty()) // if (lang.isEmpty())
// lang = "); // lang = ");
if (!usedLangs.contains(lang)) { if (!usedLangs.contains(lang)) {
@ -1138,8 +1138,8 @@ void CGlossaryFolder::initTree() {
} }
//found a glossary //found a glossary
//ToDo: this is ugly code //ToDo: this is ugly code
if (language() == TQString::tqfromLatin1("*") if (language() == TQString::fromLatin1("*")
|| (language() != TQString::tqfromLatin1("*") || (language() != TQString::fromLatin1("*")
&& (*it)->config(CSwordModuleInfo::GlossaryFrom) == fromLanguage() && (*it)->config(CSwordModuleInfo::GlossaryFrom) == fromLanguage()
&& (*it)->config(CSwordModuleInfo::GlossaryTo) == toLanguage() && (*it)->config(CSwordModuleInfo::GlossaryTo) == toLanguage()
) )
@ -1150,7 +1150,7 @@ void CGlossaryFolder::initTree() {
} }
//we have now all modules we want to have //we have now all modules we want to have
if (language() == TQString::tqfromLatin1("*")) { //create subfolders for each language if (language() == TQString::fromLatin1("*")) { //create subfolders for each language
typedef std::pair<TQString, TQString> LanguagePair; typedef std::pair<TQString, TQString> LanguagePair;
typedef TQValueList<LanguagePair> LanguagePairList; typedef TQValueList<LanguagePair> LanguagePairList;

@ -51,7 +51,7 @@ void CMainIndex::ToolTip::maybeTip(const TQPoint& p) {
return; return;
} }
TQRect r = m_mainIndex->tqitemRect(i); TQRect r = m_mainIndex->itemRect(i);
if (!r.isValid()) { if (!r.isValid()) {
return; return;
} }

@ -32,7 +32,7 @@ ManageIndicesForm::ManageIndicesForm( TQWidget* parent, const char* name, WFlags
ManageIndicesFormLayout = new TQVBoxLayout( this, 0, 8, "ManageIndicesFormLayout"); ManageIndicesFormLayout = new TQVBoxLayout( this, 0, 8, "ManageIndicesFormLayout");
m_labelFrame = new TQFrame( this, "m_labelFrame" ); m_labelFrame = new TQFrame( this, "m_labelFrame" );
m_labelFrame->tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)5, 0, 0, m_labelFrame->sizePolicy().hasHeightForWidth() ) ); m_labelFrame->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)5, 0, 0, m_labelFrame->sizePolicy().hasHeightForWidth() ) );
m_labelFrame->setFrameShape( TQFrame::NoFrame ); m_labelFrame->setFrameShape( TQFrame::NoFrame );
m_labelFrame->setFrameShadow( TQFrame::Plain ); m_labelFrame->setFrameShadow( TQFrame::Plain );
ManageIndicesFormLayout->addWidget( m_labelFrame ); ManageIndicesFormLayout->addWidget( m_labelFrame );
@ -54,7 +54,7 @@ ManageIndicesForm::ManageIndicesForm( TQWidget* parent, const char* name, WFlags
tqlayout1->addWidget( m_deleteIndicesButton ); tqlayout1->addWidget( m_deleteIndicesButton );
ManageIndicesFormLayout->addLayout( tqlayout1 ); ManageIndicesFormLayout->addLayout( tqlayout1 );
languageChange(); languageChange();
resize( TQSize(415, 404).expandedTo(tqminimumSizeHint()) ); resize( TQSize(415, 404).expandedTo(minimumSizeHint()) );
clearWState( WState_Polished ); clearWState( WState_Polished );
} }

@ -78,7 +78,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>40</width> <width>40</width>
<height>20</height> <height>20</height>

@ -100,7 +100,7 @@ void CRangeChooserDialog::initView() {
m_rangeList = new KListView(plainPage()); m_rangeList = new KListView(plainPage());
m_rangeList->addColumn(i18n("Search range")); m_rangeList->addColumn(i18n("Search range"));
m_rangeList->tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Expanding)); m_rangeList->setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Expanding));
m_rangeList->setFullWidth(true); m_rangeList->setFullWidth(true);
m_rangeList->setSorting(0, true); m_rangeList->setSorting(0, true);
m_rangeList->header()->setClickEnabled(false); m_rangeList->header()->setClickEnabled(false);
@ -123,7 +123,7 @@ void CRangeChooserDialog::initView() {
grid->addWidget(m_nameEdit,0,4); grid->addWidget(m_nameEdit,0,4);
label = new TQLabel(i18n("Edit current search range:"), plainPage()); label = new TQLabel(i18n("Edit current search range:"), plainPage());
label->setFixedSize(label->tqsizeHint()); label->setFixedSize(label->sizeHint());
m_rangeEdit = new TQTextEdit(plainPage()); m_rangeEdit = new TQTextEdit(plainPage());
m_rangeEdit->setTextFormat(TQt::PlainText); m_rangeEdit->setTextFormat(TQt::PlainText);
grid->addMultiCellWidget(label,1,1,3,4); grid->addMultiCellWidget(label,1,1,3,4);

@ -85,7 +85,7 @@ void CSearchAnalysisDialog::initView() {
TQPushButton* button = new TQPushButton(plainPage(), "button"); TQPushButton* button = new TQPushButton(plainPage(), "button");
button->setIconSet(SmallIconSet("filesave")); button->setIconSet(SmallIconSet("filesave"));
button->setText(i18n("Save search analysis as HTML")); button->setText(i18n("Save search analysis as HTML"));
button->setFixedSize(button->tqsizeHint()); button->setFixedSize(button->sizeHint());
tqlayout->addWidget(button); tqlayout->addWidget(button);
tqlayout->addSpacing(10); tqlayout->addSpacing(10);
@ -160,7 +160,7 @@ void CSearchAnalysis::analyse(ListCSwordModuleInfo modules) {
moduleIndex = 0; moduleIndex = 0;
ListCSwordModuleInfo::iterator end_it = m_moduleList.end(); ListCSwordModuleInfo::iterator end_it = m_moduleList.end();
for (ListCSwordModuleInfo::iterator it(m_moduleList.begin()); it != end_it; ++it) { for (ListCSwordModuleInfo::iterator it(m_moduleList.begin()); it != end_it; ++it) {
KApplication::kApplication()->tqprocessEvents( 10 ); //10 ms only KApplication::kApplication()->processEvents( 10 ); //10 ms only
if (!m_lastPosList.contains(*it)) { if (!m_lastPosList.contains(*it)) {
m_lastPosList.insert(*it,0); m_lastPosList.insert(*it,0);
} }
@ -415,14 +415,14 @@ CSearchAnalysisView::CSearchAnalysisView(TQCanvas* canvas, TQWidget* parent)
: TQCanvasView(canvas, parent) { : TQCanvasView(canvas, parent) {
setFocusPolicy(TQ_WheelFocus); setFocusPolicy(TQ_WheelFocus);
m_toolTip = new ToolTip(this); m_toolTip = new ToolTip(this);
resize(tqsizeHint()); resize(sizeHint());
} }
/** Returns the tqsizeHint for this view */ /** Returns the sizeHint for this view */
TQSize CSearchAnalysisView::tqsizeHint() { TQSize CSearchAnalysisView::sizeHint() {
if ( parentWidget() ) if ( parentWidget() )
return parentWidget()->tqsizeHint(); return parentWidget()->sizeHint();
return TQCanvasView::tqsizeHint(); return TQCanvasView::sizeHint();
} }
/** No descriptions */ /** No descriptions */

@ -187,11 +187,11 @@ public:
*/ */
CSearchAnalysisView(TQCanvas* canvas, TQWidget* parent); CSearchAnalysisView(TQCanvas* canvas, TQWidget* parent);
/** /**
* Returns the tqsizeHint for this view * Returns the sizeHint for this view
* We give back the size of the parent widgetas default. * We give back the size of the parent widgetas default.
* This is a reimplementation from TQCanvasView::tqsizeHint(). * This is a reimplementation from TQCanvasView::sizeHint().
*/ */
virtual TQSize tqsizeHint(); virtual TQSize sizeHint();
/** /**
* Returns the item at position p. * Returns the item at position p.
* If there no item at that point return 0. * If there no item at that point return 0.

@ -172,7 +172,7 @@ const ListCSwordModuleInfo CSearchDialog::modules() {
/** Sets the list of modules for the search. */ /** Sets the list of modules for the search. */
void CSearchDialog::setModules( const ListCSwordModuleInfo modules ) { void CSearchDialog::setModules( const ListCSwordModuleInfo modules ) {
m_searchOptionsPage->setModules(modules); m_searchOptionsPage->setModules(modules);
resize( tqsizeHint() ); resize( sizeHint() );
} }
/** Returns the search text which is set currently. */ /** Returns the search text which is set currently. */

@ -73,7 +73,7 @@ void StrongsResultClass::initStrongsResults(void) {
count = result.Count(); count = result.Count();
if (!count) if (!count)
return; return;
KApplication::kApplication()->tqprocessEvents( 1 ); //1 ms only KApplication::kApplication()->processEvents( 1 ); //1 ms only
srList.clear(); srList.clear();
// for whatever reason the text "Parsing...translations." does not appear. // for whatever reason the text "Parsing...translations." does not appear.
// this is not critical but the text is necessary to get the dialog box // this is not critical but the text is necessary to get the dialog box
@ -85,7 +85,7 @@ void StrongsResultClass::initStrongsResults(void) {
progress->raise(); progress->raise();
for (index = 0; index < count; index++){ for (index = 0; index < count; index++){
progress->progressBar()->setProgress( int( (index*100) / count ) ); progress->progressBar()->setProgress( int( (index*100) / count ) );
KApplication::kApplication()->tqprocessEvents( 1 ); //1 ms only KApplication::kApplication()->processEvents( 1 ); //1 ms only
key = TQString::fromUtf8(result.GetElement(index)->getText()); key = TQString::fromUtf8(result.GetElement(index)->getText());
text = render.renderSingleKey(key, modules, settings); text = render.renderSingleKey(key, modules, settings);
@ -662,12 +662,12 @@ void CSearchOptionsPage::setModules( ListCSwordModuleInfo modules ) {
m_modules.append( *it ); m_modules.append( *it );
t.append( (*it)->name() ); t.append( (*it)->name() );
if (*it != modules.last()) { if (*it != modules.last()) {
t += TQString::tqfromLatin1(", "); // so that it will become a readable list (WLC, LXX, GerLut...) t += TQString::fromLatin1(", "); // so that it will become a readable list (WLC, LXX, GerLut...)
} }
} }
}; };
m_modulesLabel->setText(t); m_modulesLabel->setText(t);
emit( sigSetSearchButtontqStatus( (modules.count() != 0) ) ); emit( sigSetSearchButtonStatus( (modules.count() != 0) ) );
} }
/** Opens the modules chooser dialog. */ /** Opens the modules chooser dialog. */

@ -160,8 +160,8 @@ public:
*/ */
void setSearchResult(ListCSwordModuleInfo modules); void setSearchResult(ListCSwordModuleInfo modules);
TQSize tqsizeHint() const { return baseSize(); } TQSize sizeHint() const { return baseSize(); }
TQSize tqminimumSizeHint() const { return tqminimumSize(); } TQSize minimumSizeHint() const { return minimumSize(); }
public slots: // Public slots public slots: // Public slots
/** /**
@ -241,8 +241,8 @@ public:
*/ */
//const CSwordModuleSearch::scopeType scopeType(); //const CSwordModuleSearch::scopeType scopeType();
TQSize tqsizeHint() const { return baseSize(); } TQSize sizeHint() const { return baseSize(); }
TQSize tqminimumSizeHint() const { return tqminimumSize(); } TQSize minimumSizeHint() const { return minimumSize(); }
bool hasSearchScope(); bool hasSearchScope();
private: private:
@ -285,7 +285,7 @@ protected slots: // Protected slots
void syntaxHelp(); void syntaxHelp();
signals: signals:
void sigSetSearchButtontqStatus(bool); void sigSetSearchButtonStatus(bool);
}; };
} //end of namespace Search::Options } //end of namespace Search::Options

@ -28,7 +28,7 @@ SearchOptionsForm::SearchOptionsForm( TQWidget* parent, const char* name, WFlags
{ {
if ( !name ) if ( !name )
setName( "SearchOptionsForm" ); setName( "SearchOptionsForm" );
tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)0, 0, 0, sizePolicy().hasHeightForWidth() ) ); setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)0, 0, 0, sizePolicy().hasHeightForWidth() ) );
setMinimumSize( TQSize( 260, 130 ) ); setMinimumSize( TQSize( 260, 130 ) );
setBaseSize( TQSize( 420, 150 ) ); setBaseSize( TQSize( 420, 150 ) );
SearchOptionsFormLayout = new TQHBoxLayout( this, 0, 3, "SearchOptionsFormLayout"); SearchOptionsFormLayout = new TQHBoxLayout( this, 0, 3, "SearchOptionsFormLayout");
@ -39,10 +39,10 @@ SearchOptionsForm::SearchOptionsForm( TQWidget* parent, const char* name, WFlags
searchGroupBox->tqlayout()->setSpacing( 3 ); searchGroupBox->tqlayout()->setSpacing( 3 );
searchGroupBox->tqlayout()->setMargin( 6 ); searchGroupBox->tqlayout()->setMargin( 6 );
searchGroupBoxLayout = new TQGridLayout( searchGroupBox->tqlayout() ); searchGroupBoxLayout = new TQGridLayout( searchGroupBox->tqlayout() );
searchGroupBoxLayout->tqsetAlignment( TQt::AlignTop ); searchGroupBoxLayout->setAlignment( TQt::AlignTop );
m_searchTextLabel = new TQLabel( searchGroupBox, "m_searchTextLabel" ); m_searchTextLabel = new TQLabel( searchGroupBox, "m_searchTextLabel" );
m_searchTextLabel->tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, m_searchTextLabel->sizePolicy().hasHeightForWidth() ) ); m_searchTextLabel->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, m_searchTextLabel->sizePolicy().hasHeightForWidth() ) );
searchGroupBoxLayout->addWidget( m_searchTextLabel, 0, 0 ); searchGroupBoxLayout->addWidget( m_searchTextLabel, 0, 0 );
@ -59,17 +59,17 @@ SearchOptionsForm::SearchOptionsForm( TQWidget* parent, const char* name, WFlags
searchGroupBoxLayout->addWidget( m_chooseRangeButton, 2, 2 ); searchGroupBoxLayout->addWidget( m_chooseRangeButton, 2, 2 );
m_searchScopeLabel = new TQLabel( searchGroupBox, "m_searchScopeLabel" ); m_searchScopeLabel = new TQLabel( searchGroupBox, "m_searchScopeLabel" );
m_searchScopeLabel->tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, m_searchScopeLabel->sizePolicy().hasHeightForWidth() ) ); m_searchScopeLabel->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, m_searchScopeLabel->sizePolicy().hasHeightForWidth() ) );
searchGroupBoxLayout->addWidget( m_searchScopeLabel, 2, 0 ); searchGroupBoxLayout->addWidget( m_searchScopeLabel, 2, 0 );
m_rangeChooserCombo = new KComboBox( FALSE, searchGroupBox, "m_rangeChooserCombo" ); m_rangeChooserCombo = new KComboBox( FALSE, searchGroupBox, "m_rangeChooserCombo" );
m_rangeChooserCombo->tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)0, 0, 0, m_rangeChooserCombo->sizePolicy().hasHeightForWidth() ) ); m_rangeChooserCombo->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)0, 0, 0, m_rangeChooserCombo->sizePolicy().hasHeightForWidth() ) );
searchGroupBoxLayout->addWidget( m_rangeChooserCombo, 2, 1 ); searchGroupBoxLayout->addWidget( m_rangeChooserCombo, 2, 1 );
m_searchTextCombo = new KHistoryCombo( searchGroupBox, "m_searchTextCombo" ); m_searchTextCombo = new KHistoryCombo( searchGroupBox, "m_searchTextCombo" );
m_searchTextCombo->tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)0, 0, 0, m_searchTextCombo->sizePolicy().hasHeightForWidth() ) ); m_searchTextCombo->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)0, 0, 0, m_searchTextCombo->sizePolicy().hasHeightForWidth() ) );
m_searchTextCombo->setFocusPolicy( KHistoryCombo::WheelFocus ); m_searchTextCombo->setFocusPolicy( KHistoryCombo::WheelFocus );
m_searchTextCombo->setSizeLimit( 25 ); m_searchTextCombo->setSizeLimit( 25 );
m_searchTextCombo->setInsertionPolicy( KHistoryCombo::AtBottom ); m_searchTextCombo->setInsertionPolicy( KHistoryCombo::AtBottom );
@ -78,14 +78,14 @@ SearchOptionsForm::SearchOptionsForm( TQWidget* parent, const char* name, WFlags
searchGroupBoxLayout->addWidget( m_searchTextCombo, 0, 1 ); searchGroupBoxLayout->addWidget( m_searchTextCombo, 0, 1 );
m_modulesLabel = new TQLabel( searchGroupBox, "m_modulesLabel" ); m_modulesLabel = new TQLabel( searchGroupBox, "m_modulesLabel" );
m_modulesLabel->tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, m_modulesLabel->sizePolicy().hasHeightForWidth() ) ); m_modulesLabel->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, m_modulesLabel->sizePolicy().hasHeightForWidth() ) );
m_modulesLabel->setTextFormat( TQLabel::RichText ); m_modulesLabel->setTextFormat( TQLabel::RichText );
m_modulesLabel->tqsetAlignment( int( TQLabel::WordBreak | TQLabel::AlignVCenter | TQLabel::AlignLeft ) ); m_modulesLabel->setAlignment( int( TQLabel::WordBreak | TQLabel::AlignVCenter | TQLabel::AlignLeft ) );
searchGroupBoxLayout->addMultiCellWidget( m_modulesLabel, 1, 1, 0, 1 ); searchGroupBoxLayout->addMultiCellWidget( m_modulesLabel, 1, 1, 0, 1 );
SearchOptionsFormLayout->addWidget( searchGroupBox ); SearchOptionsFormLayout->addWidget( searchGroupBox );
languageChange(); languageChange();
resize( TQSize(648, 130).expandedTo(tqminimumSizeHint()) ); resize( TQSize(648, 130).expandedTo(minimumSizeHint()) );
clearWState( WState_Polished ); clearWState( WState_Polished );
} }

@ -20,7 +20,7 @@
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="tqminimumSize"> <property name="minimumSize">
<size> <size>
<width>260</width> <width>260</width>
<height>130</height> <height>130</height>

@ -29,7 +29,7 @@ SearchResultsForm::SearchResultsForm( TQWidget* parent, const char* name, WFlags
{ {
if ( !name ) if ( !name )
setName( "SearchResultsForm" ); setName( "SearchResultsForm" );
tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)7, 0, 0, sizePolicy().hasHeightForWidth() ) ); setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)7, 0, 0, sizePolicy().hasHeightForWidth() ) );
setMinimumSize( TQSize( 300, 220 ) ); setMinimumSize( TQSize( 300, 220 ) );
setBaseSize( TQSize( 440, 290 ) ); setBaseSize( TQSize( 440, 290 ) );
SearchResultsFormLayout = new TQVBoxLayout( this, 0, 3, "SearchResultsFormLayout"); SearchResultsFormLayout = new TQVBoxLayout( this, 0, 3, "SearchResultsFormLayout");
@ -58,12 +58,12 @@ SearchResultsForm::SearchResultsForm( TQWidget* parent, const char* name, WFlags
rightSideBox->addLayout( buttonLayout ); rightSideBox->addLayout( buttonLayout );
m_displayFrame = new TQFrame( displaySplitter, "m_displayFrame" ); m_displayFrame = new TQFrame( displaySplitter, "m_displayFrame" );
m_displayFrame->tqsetSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)7, 0, 0, m_displayFrame->sizePolicy().hasHeightForWidth() ) ); m_displayFrame->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)7, 0, 0, m_displayFrame->sizePolicy().hasHeightForWidth() ) );
m_displayFrame->setFrameShape( TQFrame::NoFrame ); m_displayFrame->setFrameShape( TQFrame::NoFrame );
m_displayFrame->setFrameShadow( TQFrame::Plain ); m_displayFrame->setFrameShadow( TQFrame::Plain );
SearchResultsFormLayout->addWidget( displaySplitter ); SearchResultsFormLayout->addWidget( displaySplitter );
languageChange(); languageChange();
resize( TQSize(300, 220).expandedTo(tqminimumSizeHint()) ); resize( TQSize(300, 220).expandedTo(minimumSizeHint()) );
clearWState( WState_Polished ); clearWState( WState_Polished );
} }

@ -20,7 +20,7 @@
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="tqminimumSize"> <property name="minimumSize">
<size> <size>
<width>300</width> <width>300</width>
<height>220</height> <height>220</height>
@ -49,7 +49,7 @@
<property name="name"> <property name="name">
<cstring>displaySplitter</cstring> <cstring>displaySplitter</cstring>
</property> </property>
<property name="tqminimumSize"> <property name="minimumSize">
<size> <size>
<width>134</width> <width>134</width>
<height>44</height> <height>44</height>
@ -116,7 +116,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>10</width> <width>10</width>
<height>20</height> <height>20</height>

@ -74,7 +74,7 @@ bool CToolClass::savePlainFile( const TQString& filename, const TQString& text,
if (saveFile.exists()) { if (saveFile.exists()) {
if (!forceOverwrite && KMessageBox::warningYesNo(0, if (!forceOverwrite && KMessageBox::warningYesNo(0,
TQString::tqfromLatin1("<qt><B>%1</B><BR>%2</qt>") TQString::fromLatin1("<qt><B>%1</B><BR>%2</qt>")
.tqarg( i18n("The file already exists.") ) .tqarg( i18n("The file already exists.") )
.tqarg( i18n("Do you want to overwrite it?") .tqarg( i18n("Do you want to overwrite it?")
) )
@ -95,7 +95,7 @@ bool CToolClass::savePlainFile( const TQString& filename, const TQString& text,
ret = true; ret = true;
} }
else { else {
KMessageBox::error(0, TQString::tqfromLatin1("<qt>%1<BR><B>%2</B></qt>") KMessageBox::error(0, TQString::fromLatin1("<qt>%1<BR><B>%2</B></qt>")
.tqarg( i18n("The file couldn't be saved.") ) .tqarg( i18n("The file couldn't be saved.") )
.tqarg( i18n("Please check permissions etc."))); .tqarg( i18n("Please check permissions etc.")));
saveFile.close(); saveFile.close();
@ -160,7 +160,7 @@ TQPixmap CToolClass::getIconForModule( CSwordModuleInfo* module_info ) {
} }
TQLabel* CToolClass::explanationLabel(TQWidget* parent, const TQString& heading, const TQString& text ) { TQLabel* CToolClass::explanationLabel(TQWidget* parent, const TQString& heading, const TQString& text ) {
TQLabel* label = new TQLabel( TQString::tqfromLatin1("<B>%1</B><BR>%2").tqarg(heading).tqarg(text),parent ); TQLabel* label = new TQLabel( TQString::fromLatin1("<B>%1</B><BR>%2").tqarg(heading).tqarg(text),parent );
label->setAutoResize(true); label->setAutoResize(true);
label->setMargin(1); label->setMargin(1);
label->setFrameStyle(TQFrame::Box | TQFrame::Plain); label->setFrameStyle(TQFrame::Box | TQFrame::Plain);
@ -198,7 +198,7 @@ TQString CToolClass::moduleToolTip(CSwordModuleInfo* module) {
TQString text; TQString text;
text = TQString("<b>%1</b> ").tqarg( module->name() ) text = TQString("<b>%1</b> ").tqarg( module->name() )
+ ((module->category() == CSwordModuleInfo::Cult) ? TQString::tqfromLatin1("<small><b>%1</b></small><br>").tqarg(i18n("Take care, this work contains cult / questionable material!")) : TQString()); + ((module->category() == CSwordModuleInfo::Cult) ? TQString::fromLatin1("<small><b>%1</b></small><br>").tqarg(i18n("Take care, this work contains cult / questionable material!")) : TQString());
text += TQString("<small>(") + module->config(CSwordModuleInfo::Description) + TQString(")</small><hr>"); text += TQString("<small>(") + module->config(CSwordModuleInfo::Description) + TQString(")</small><hr>");
@ -218,7 +218,7 @@ TQString CToolClass::moduleToolTip(CSwordModuleInfo* module) {
for (opts = CSwordModuleInfo::filterTypesMIN; opts <= CSwordModuleInfo::filterTypesMAX; ++opts) { for (opts = CSwordModuleInfo::filterTypesMIN; opts <= CSwordModuleInfo::filterTypesMAX; ++opts) {
if (module->has( static_cast<CSwordModuleInfo::FilterTypes>(opts) )) { if (module->has( static_cast<CSwordModuleInfo::FilterTypes>(opts) )) {
if (!options.isEmpty()) { if (!options.isEmpty()) {
options += TQString::tqfromLatin1(", "); options += TQString::fromLatin1(", ");
} }
options += CSwordBackend::translatedOptionName( options += CSwordBackend::translatedOptionName(
@ -228,10 +228,10 @@ TQString CToolClass::moduleToolTip(CSwordModuleInfo* module) {
} }
if (!options.isEmpty()) { if (!options.isEmpty()) {
text += i18n("Options") + TQString::tqfromLatin1(": <small>") + options + TQString("</small>"); text += i18n("Options") + TQString::fromLatin1(": <small>") + options + TQString("</small>");
} }
if (text.right(4) == TQString::tqfromLatin1("<br>")) { if (text.right(4) == TQString::fromLatin1("<br>")) {
text = text.left(text.length()-4); text = text.left(text.length()-4);
} }

Loading…
Cancel
Save