diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-13 08:32:36 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-01-13 08:32:36 +0000 |
commit | f7e71d47719ab6094cf4a9fafffa5ea351973522 (patch) | |
tree | 30834aa632d442019e14f88685001d94657d060b /kdeprint/lpr | |
parent | b31cfd9a1ee986fe2ae9a693f3afd7f171dd897c (diff) | |
download | tdelibs-f7e71d47719ab6094cf4a9fafffa5ea351973522.tar.gz tdelibs-f7e71d47719ab6094cf4a9fafffa5ea351973522.zip |
Initial conversion for TQt for Qt4 3.4.0 TP2
This will also compile with TQt for Qt3, and should not cause any problems
with dependent modules such as kdebase. If it does then it needs to be fixed!
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1214149 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdeprint/lpr')
-rw-r--r-- | kdeprint/lpr/apshandler.cpp | 12 | ||||
-rw-r--r-- | kdeprint/lpr/klprprinterimpl.cpp | 4 | ||||
-rw-r--r-- | kdeprint/lpr/kmlprmanager.cpp | 18 | ||||
-rw-r--r-- | kdeprint/lpr/lpchelper.cpp | 22 | ||||
-rw-r--r-- | kdeprint/lpr/lpchelper.h | 2 | ||||
-rw-r--r-- | kdeprint/lpr/lpqhelper.cpp | 6 | ||||
-rw-r--r-- | kdeprint/lpr/lpqhelper.h | 2 | ||||
-rw-r--r-- | kdeprint/lpr/lprhandler.cpp | 4 | ||||
-rw-r--r-- | kdeprint/lpr/lprngtoolhandler.cpp | 24 | ||||
-rw-r--r-- | kdeprint/lpr/matichandler.cpp | 22 | ||||
-rw-r--r-- | kdeprint/lpr/printcapreader.cpp | 8 |
11 files changed, 62 insertions, 62 deletions
diff --git a/kdeprint/lpr/apshandler.cpp b/kdeprint/lpr/apshandler.cpp index fc6ade276..526edaf49 100644 --- a/kdeprint/lpr/apshandler.cpp +++ b/kdeprint/lpr/apshandler.cpp @@ -50,8 +50,8 @@ bool ApsHandler::validate(PrintcapEntry *entry) KMPrinter* ApsHandler::createPrinter(PrintcapEntry *entry) { - entry->comment = TQString::fromLatin1("# APS%1_BEGIN:printer%2").arg(m_counter).arg(m_counter); - entry->postcomment = TQString::fromLatin1("# APS%1_END - don't delete this").arg(m_counter); + entry->comment = TQString::tqfromLatin1("# APS%1_BEGIN:printer%2").arg(m_counter).arg(m_counter); + entry->postcomment = TQString::tqfromLatin1("# APS%1_END - don't delete this").arg(m_counter); m_counter++; return LprHandler::createPrinter(entry); } @@ -148,7 +148,7 @@ TQMap<TQString,TQString> ApsHandler::loadVarFile(const TQString& filename) while (!t.atEnd()) { line = t.readLine().stripWhiteSpace(); - if (line.isEmpty() || line[0] == '#' || (p = line.find('=')) == -1) + if (line.isEmpty() || line[0] == '#' || (p = line.tqfind('=')) == -1) continue; QString variable = line.left(p).stripWhiteSpace(); QString value = line.mid(p+1).stripWhiteSpace(); @@ -187,7 +187,7 @@ DrMain* ApsHandler::loadDriver(KMPrinter *prt, PrintcapEntry *entry, bool config DrMain* ApsHandler::loadDbDriver(const TQString& s) { - int p = s.find('/'); + int p = s.tqfind('/'); DrMain *driver = loadApsDriver(true); if (driver) driver->set("gsdriver", s.mid(p+1)); @@ -309,8 +309,8 @@ PrintcapEntry* ApsHandler::createEntry(KMPrinter *prt) entry->addField("af", Field::String, sd + "/acct"); entry->addField("lf", Field::String, sd + "/log"); entry->addField("if", Field::String, sysconfDir() + "/basedir/bin/apsfilter"); - entry->comment = TQString::fromLatin1("# APS%1_BEGIN:printer%2").arg(m_counter).arg(m_counter); - entry->postcomment = TQString::fromLatin1("# APS%1_END").arg(m_counter); + entry->comment = TQString::tqfromLatin1("# APS%1_BEGIN:printer%2").arg(m_counter).arg(m_counter); + entry->postcomment = TQString::tqfromLatin1("# APS%1_END").arg(m_counter); m_counter++; return entry; } diff --git a/kdeprint/lpr/klprprinterimpl.cpp b/kdeprint/lpr/klprprinterimpl.cpp index 1d77b166c..9f0956ff3 100644 --- a/kdeprint/lpr/klprprinterimpl.cpp +++ b/kdeprint/lpr/klprprinterimpl.cpp @@ -41,7 +41,7 @@ bool KLprPrinterImpl::setupCommand(TQString& cmd, KPrinter *printer) if (!printer || m_exepath.isEmpty()) return false; - cmd = TQString::fromLatin1("%1 -P %1 '-#%1'").arg(m_exepath).arg(quote(printer->printerName())).arg( printer->numCopies() ); + cmd = TQString::tqfromLatin1("%1 -P %1 '-#%1'").arg(m_exepath).arg(quote(printer->printerName())).arg( printer->numCopies() ); QString opts = static_cast<KMLprManager*>(KMManager::self())->printOptions(printer); if (!opts.isEmpty()) cmd += (" " + opts); @@ -53,7 +53,7 @@ void KLprPrinterImpl::broadcastOption(const TQString& key, const TQString& value KPrinterImpl::broadcastOption(key,value); if (key == "kde-pagesize") { - QString pagename = TQString::fromLatin1(pageSizeToPageName((KPrinter::PageSize)value.toInt())); + QString pagename = TQString::tqfromLatin1(pageSizeToPageName((KPrinter::PageSize)value.toInt())); KPrinterImpl::broadcastOption("PageSize",pagename); } } diff --git a/kdeprint/lpr/kmlprmanager.cpp b/kdeprint/lpr/kmlprmanager.cpp index 65b08eb67..008674a78 100644 --- a/kdeprint/lpr/kmlprmanager.cpp +++ b/kdeprint/lpr/kmlprmanager.cpp @@ -160,7 +160,7 @@ LprHandler* KMLprManager::findHandler(KMPrinter *prt) { QString handlerstr(prt->option("kde-lpr-handler")); LprHandler *handler(0); - if (handlerstr.isEmpty() || (handler = m_handlers.find(handlerstr)) == NULL) + if (handlerstr.isEmpty() || (handler = m_handlers.tqfind(handlerstr)) == NULL) { return NULL; } @@ -169,7 +169,7 @@ LprHandler* KMLprManager::findHandler(KMPrinter *prt) PrintcapEntry* KMLprManager::findEntry(KMPrinter *prt) { - PrintcapEntry *entry = m_entries.find(prt->printerName()); + PrintcapEntry *entry = m_entries.tqfind(prt->printerName()); if (!entry) { return NULL; @@ -230,9 +230,9 @@ DrMain* KMLprManager::loadPrinterDriver(KMPrinter *prt, bool config) DrMain* KMLprManager::loadFileDriver(const TQString& filename) { - int p = filename.find('/'); - QString handler_str = (p != -1 ? filename.left(p) : TQString::fromLatin1("default")); - LprHandler *handler = m_handlers.find(handler_str); + int p = filename.tqfind('/'); + QString handler_str = (p != -1 ? filename.left(p) : TQString::tqfromLatin1("default")); + LprHandler *handler = m_handlers.tqfind(handler_str); if (handler) { DrMain *driver = handler->loadDbDriver(filename); @@ -311,7 +311,7 @@ bool KMLprManager::savePrintcapFile() bool KMLprManager::createPrinter(KMPrinter *prt) { // remove existing printcap entry - PrintcapEntry *oldEntry = m_entries.find(prt->printerName()); + PrintcapEntry *oldEntry = m_entries.tqfind(prt->printerName()); // look for the handler and re-create entry LprHandler *handler(0); @@ -320,11 +320,11 @@ bool KMLprManager::createPrinter(KMPrinter *prt) // or we use the handler of the existing printer // (modifying something else, handler stays the same) if (prt->driver()) - handler = m_handlers.find(prt->driver()->get("handler")); + handler = m_handlers.tqfind(prt->driver()->get("handler")); else if (oldEntry) handler = findHandler(prt); else - handler = m_handlers.find("default"); + handler = m_handlers.tqfind("default"); if (!handler) { setErrorMsg(i18n("Internal error: no handler defined.")); @@ -422,7 +422,7 @@ bool KMLprManager::removePrinter(KMPrinter *prt) TQString KMLprManager::driverDbCreationProgram() { - return TQString::fromLatin1("make_driver_db_lpr"); + return TQString::tqfromLatin1("make_driver_db_lpr"); } TQString KMLprManager::driverDirectory() diff --git a/kdeprint/lpr/lpchelper.cpp b/kdeprint/lpr/lpchelper.cpp index 516e85af3..fb39a37f9 100644 --- a/kdeprint/lpr/lpchelper.cpp +++ b/kdeprint/lpr/lpchelper.cpp @@ -82,26 +82,26 @@ void LpcHelper::parseStatusLPR(TQTextStream &t) line = t.readLine(); if (line.isEmpty()) continue; - else if (!line[0].isSpace() && (p = line.find(':')) != -1) + else if (!line[0].isSpace() && (p = line.tqfind(':')) != -1) { printer = line.left(p); m_state[printer] = KMPrinter::Idle; } - else if (line.find("printing is disabled") != -1) + else if (line.tqfind("printing is disabled") != -1) { if (!printer.isEmpty()) m_state[printer] = KMPrinter::PrinterState((KMPrinter::Stopped) | (m_state[printer] & ~KMPrinter::StateMask)); } - else if (line.find("queuing is disabled") != -1) + else if (line.tqfind("queuing is disabled") != -1) { if (!printer.isEmpty()) m_state[printer] = KMPrinter::PrinterState((KMPrinter::Rejecting) | (m_state[printer] & KMPrinter::StateMask)); } - else if (line.find("entries") != -1) + else if (line.tqfind("entries") != -1) { if (!printer.isEmpty() && (m_state[printer] & KMPrinter::StateMask) != KMPrinter::Stopped && - line.find("no entries") == -1) + line.tqfind("no entries") == -1) m_state[printer] = KMPrinter::PrinterState((m_state[printer] & ~KMPrinter::StateMask) | KMPrinter::Processing); } } @@ -121,7 +121,7 @@ void LpcHelper::parseStatusLPRng(TQTextStream& t) l = TQStringList::split(TQRegExp("\\s"), t.readLine(), false); if (l.count() < 4) continue; - p = l[0].find('@'); + p = l[0].tqfind('@'); if (p == 0) printer = l[0]; else @@ -206,11 +206,11 @@ static TQString lprngAnswer(const TQString& result, const TQString& printer) { int p, q; - p = result.find("\n" + printer); + p = result.tqfind("\n" + printer); if (p != -1) { - q = result.find(':', p)+2; - p = result.find('\n', q); + q = result.tqfind(':', p)+2; + p = result.tqfind('\n', q); QString answer = result.mid(q, p-q).stripWhiteSpace(); return answer; } @@ -274,9 +274,9 @@ bool LpcHelper::removeJob(KMJob *job, TQString& msg) return false; } QString result = execute(m_lprmpath + " -P " + KProcess::quote(job->printer()) + " " + TQString::number(job->id())); - if (result.find("dequeued") != -1) + if (result.tqfind("dequeued") != -1) return true; - else if (result.find("Permission denied") != -1 || result.find("no permissions") != -1) + else if (result.tqfind("Permission denied") != -1 || result.tqfind("no permissions") != -1) msg = i18n("Permission denied."); else msg = i18n("Execution of lprm failed: %1").arg(result); diff --git a/kdeprint/lpr/lpchelper.h b/kdeprint/lpr/lpchelper.h index d7e6c7897..2c711f41b 100644 --- a/kdeprint/lpr/lpchelper.h +++ b/kdeprint/lpr/lpchelper.h @@ -27,7 +27,7 @@ class KMJob; -class LpcHelper : public QObject +class LpcHelper : public TQObject { public: LpcHelper(TQObject *parent = 0, const char *name = 0); diff --git a/kdeprint/lpr/lpqhelper.cpp b/kdeprint/lpr/lpqhelper.cpp index 2675c9d41..aa8e19879 100644 --- a/kdeprint/lpr/lpqhelper.cpp +++ b/kdeprint/lpr/lpqhelper.cpp @@ -46,7 +46,7 @@ KMJob* LpqHelper::parseLineLpr(const TQString& line) job->setOwner(line.mid(7, 11).stripWhiteSpace()); job->setId(line.mid(18, 5).toInt()); job->setName(line.mid(23, 38).stripWhiteSpace()); - int p = line.find(' ', 61); + int p = line.tqfind(' ', 61); if (p != -1) { job->setSize(line.mid(61, p-61).toInt() / 1000); @@ -61,14 +61,14 @@ KMJob* LpqHelper::parseLineLPRng(const TQString& line) return NULL; KMJob *job = new KMJob; job->setState((rank[0].isDigit() ? KMJob::Queued : (rank == "hold" ? KMJob::Held : KMJob::Printing))); - int p = line.find('@', 7), q = line.find(' ', 7); + int p = line.tqfind('@', 7), q = line.tqfind(' ', 7); job->setOwner(line.mid(7, QMIN(p,q)-7)); while (line[q].isSpace()) q++; q++; while (line[q].isSpace()) q++; - p = line.find(' ', q); + p = line.tqfind(' ', q); job->setId(line.mid(q, p-q).toInt()); while (line[p].isSpace()) p++; diff --git a/kdeprint/lpr/lpqhelper.h b/kdeprint/lpr/lpqhelper.h index b41521f66..d79903f57 100644 --- a/kdeprint/lpr/lpqhelper.h +++ b/kdeprint/lpr/lpqhelper.h @@ -25,7 +25,7 @@ class KMJob; -class LpqHelper : public QObject +class LpqHelper : public TQObject { public: LpqHelper(TQObject *parent = 0, const char *name = 0); diff --git a/kdeprint/lpr/lprhandler.cpp b/kdeprint/lpr/lprhandler.cpp index 600df4796..4a2a96b0f 100644 --- a/kdeprint/lpr/lprhandler.cpp +++ b/kdeprint/lpr/lprhandler.cpp @@ -61,7 +61,7 @@ bool LprHandler::completePrinter(KMPrinter *prt, PrintcapEntry *entry, bool) KURL uri; if (!val.isEmpty() && val != "/dev/null") { - int p = val.find('@'); + int p = val.tqfind('@'); if (p != -1) { prt->setLocation(i18n("Remote queue (%1) on %2").arg(val.left(p)).arg(val.mid(p+1))); @@ -69,7 +69,7 @@ bool LprHandler::completePrinter(KMPrinter *prt, PrintcapEntry *entry, bool) uri.setHost(val.mid(p+1)); uri.setPath("/" + val.left(p)); } - else if ((p = val.find('%')) != -1) + else if ((p = val.tqfind('%')) != -1) { prt->setLocation(i18n("Network printer (%1)").arg("socket")); uri.setProtocol("socket"); diff --git a/kdeprint/lpr/lprngtoolhandler.cpp b/kdeprint/lpr/lprngtoolhandler.cpp index 3710496a9..624b74114 100644 --- a/kdeprint/lpr/lprngtoolhandler.cpp +++ b/kdeprint/lpr/lprngtoolhandler.cpp @@ -40,7 +40,7 @@ LPRngToolHandler::LPRngToolHandler(KMManager *mgr) bool LPRngToolHandler::validate(PrintcapEntry *entry) { if (entry->comment.startsWith("##LPRNGTOOL##") && - entry->comment.find("UNKNOWN") == -1) + entry->comment.tqfind("UNKNOWN") == -1) return true; return false; } @@ -82,14 +82,14 @@ bool LPRngToolHandler::completePrinter(KMPrinter *prt, PrintcapEntry *entry, boo if (!(str=entry->field("ifhp")).isEmpty()) { QString model; - int p = str.find("model"); + int p = str.tqfind("model"); if (p != -1) { - p = str.find('=', p); + p = str.tqfind('=', p); if (p != -1) { p++; - int q = str.find(',', p); + int q = str.tqfind(',', p); if (q == -1) model = str.mid(p); else @@ -142,7 +142,7 @@ void LPRngToolHandler::loadAuthFile(const TQString& filename, TQString& user, TQ line = t.readLine().stripWhiteSpace(); if (line.isEmpty()) continue; - int p = line.find('='); + int p = line.tqfind('='); if (p != -1) { QString key = line.left(p); @@ -182,7 +182,7 @@ DrMain* LPRngToolHandler::loadDriver(KMPrinter *prt, PrintcapEntry *entry, bool DrMain* LPRngToolHandler::loadDbDriver(const TQString& s) { - int p = s.find('/'); + int p = s.tqfind('/'); DrMain* driver = loadToolDriver(locate("data", "kdeprint/lprngtooldriver1")); if (driver) driver->set("driverID", s.mid(p+1)); @@ -209,13 +209,13 @@ TQValueList< QPair<TQString,TQStringList> > LPRngToolHandler::loadChoiceDict(con key = TQString::null; if (line.contains('|') == 2 || line.right(7) == "BOOLEAN") { - int p = line.find('|', 7); + int p = line.tqfind('|', 7); key = line.mid(7, p-7); } } else if (line.startsWith("CHOICE")) { - int p = line.find('|', 7); + int p = line.tqfind('|', 7); l << line.mid(7, p-7); } } @@ -239,7 +239,7 @@ TQMap<TQString,TQString> LPRngToolHandler::parseZOptions(const TQString& optstr) bool found(false); for (TQValueList< QPair<TQString,TQStringList> >::ConstIterator p=m_dict.begin(); p!=m_dict.end() && !found; ++p) { - if ((*p).second.find(*it) != (*p).second.end()) + if ((*p).second.tqfind(*it) != (*p).second.end()) { opts[(*p).first] = (*it); found = true; @@ -308,7 +308,7 @@ PrintcapEntry* LPRngToolHandler::createEntry(KMPrinter *prt) QString work, server, printer, user, passwd; if ( splitSmbURI( prt->device(), work, server, printer, user, passwd ) ) { - entry->addField("xfer_options", Field::String, TQString::fromLatin1("authfile=\"auth\" crlf=\"0\" hostip=\"\" host=\"%1\" printer=\"%2\" remote_mode=\"SMB\" share=\"//%3/%4\" workgroup=\"%5\"").arg(server).arg(printer).arg(server).arg(printer).arg(work)); + entry->addField("xfer_options", Field::String, TQString::tqfromLatin1("authfile=\"auth\" crlf=\"0\" hostip=\"\" host=\"%1\" printer=\"%2\" remote_mode=\"SMB\" share=\"//%3/%4\" workgroup=\"%5\"").arg(server).arg(printer).arg(server).arg(printer).arg(work)); QFile authfile(LprSettings::self()->baseSpoolDir() + "/" + prt->printerName() + "/auth"); if (authfile.open(IO_WriteOnly)) { @@ -331,8 +331,8 @@ PrintcapEntry* LPRngToolHandler::createEntry(KMPrinter *prt) DrMain *driver = prt->driver(); comment.append("filtertype=IFHP ifhp_options=status@,sync@,pagecount@,waitend@ printerdb_entry="); comment.append(driver->get("driverID")); - entry->addField("ifhp", Field::String, TQString::fromLatin1("model=%1,status@,sync@,pagecount@,waitend@").arg(driver->get("driverID"))); - entry->addField("lprngtooloptions", Field::String, TQString::fromLatin1("FILTERTYPE=\"IFHP\" IFHP_OPTIONS=\"status@,sync@,pagecount@,waitend@\" PRINTERDB_ENTRY=\"%1\"").arg(driver->get("driverID"))); + entry->addField("ifhp", Field::String, TQString::tqfromLatin1("model=%1,status@,sync@,pagecount@,waitend@").arg(driver->get("driverID"))); + entry->addField("lprngtooloptions", Field::String, TQString::tqfromLatin1("FILTERTYPE=\"IFHP\" IFHP_OPTIONS=\"status@,sync@,pagecount@,waitend@\" PRINTERDB_ENTRY=\"%1\"").arg(driver->get("driverID"))); TQMap<TQString,TQString> opts; QString optstr; driver->getOptions(opts, false); diff --git a/kdeprint/lpr/matichandler.cpp b/kdeprint/lpr/matichandler.cpp index f3f0d4cdc..9f830c821 100644 --- a/kdeprint/lpr/matichandler.cpp +++ b/kdeprint/lpr/matichandler.cpp @@ -85,7 +85,7 @@ bool MaticHandler::completePrinter(KMPrinter *prt, PrintcapEntry *entry, bool sh { prt->setLocation(i18n("Local printer on %1").arg(val)); KURL url(val); - if (val.find("usb") != -1) + if (val.tqfind("usb") != -1) url.setProtocol("usb"); else url.setProtocol("parallel"); @@ -104,7 +104,7 @@ bool MaticHandler::completePrinter(KMPrinter *prt, PrintcapEntry *entry, bool sh KURL url ( parsePostpipe(postpipe) ); if (!url.isEmpty()) { - QString ds = TQString::fromLatin1("%1 (%2)").arg(prt->location()).arg(url.protocol()); + QString ds = TQString::tqfromLatin1("%1 (%2)").arg(prt->location()).arg(url.protocol()); prt->setDevice(url.url()); prt->setLocation(ds); } @@ -115,7 +115,7 @@ bool MaticHandler::completePrinter(KMPrinter *prt, PrintcapEntry *entry, bool sh { prt->setManufacturer(m["make"].toString()); prt->setModel(m["model"].toString()); - prt->setDriverInfo(TQString::fromLatin1("%1 %2 (%3)").arg(prt->manufacturer()).arg(prt->model()).arg(m["driver"].toString())); + prt->setDriverInfo(TQString::tqfromLatin1("%1 %2 (%3)").arg(prt->manufacturer()).arg(prt->model()).arg(m["driver"].toString())); } } } @@ -167,7 +167,7 @@ TQString MaticHandler::parsePostpipe(const TQString& s) else { QString host = (args[i].length() == 2 ? args[i+1] : args[i].right(args[i].length()-2)); - int p = host.find("\\@"); + int p = host.tqfind("\\@"); if (p != -1) { url = "lpd://" + host.right(host.length()-p-2) + "/" + host.left(p); @@ -247,7 +247,7 @@ DrMain* MaticHandler::loadDbDriver(const TQString& path) } QString tmpFile = locateLocal("tmp", "foomatic_" + kapp->randomString(8)); - QString PATH = getenv("PATH") + TQString::fromLatin1(":/usr/sbin:/usr/local/sbin:/opt/sbin:/opt/local/sbin"); + QString PATH = getenv("PATH") + TQString::tqfromLatin1(":/usr/sbin:/usr/local/sbin:/opt/sbin:/opt/local/sbin"); QString exe = KStandardDirs::findExe("foomatic-datafile", PATH); if (exe.isEmpty()) { @@ -309,13 +309,13 @@ bool MaticHandler::savePrinterDriver(KMPrinter *prt, PrintcapEntry *entry, DrMai line = tin.readLine(); if (line.stripWhiteSpace().startsWith("$postpipe")) continue; - else if ((p = line.find("'name'")) != -1) + else if ((p = line.tqfind("'name'")) != -1) { - p = line.find('\'', p+6)+1; - q = line.find('\'', p); + p = line.tqfind('\'', p+6)+1; + q = line.tqfind('\'', p); optname = line.mid(p, q-p); } - else if ((p = line.find("'default'")) != -1) + else if ((p = line.tqfind("'default'")) != -1) { DrBase *opt = driver->findOption(optname); if (opt) @@ -351,7 +351,7 @@ bool MaticHandler::savePpdFile(DrMain *driver, const TQString& filename) if (mdriver.isEmpty() || mprinter.isEmpty()) return true; - QString PATH = getenv("PATH") + TQString::fromLatin1(":/usr/sbin:/usr/local/sbin:/opt/sbin:/opt/local/sbin"); + QString PATH = getenv("PATH") + TQString::tqfromLatin1(":/usr/sbin:/usr/local/sbin:/opt/sbin:/opt/local/sbin"); QString exe = KStandardDirs::findExe("foomatic-datafile", PATH); if (exe.isEmpty()) { @@ -372,7 +372,7 @@ bool MaticHandler::savePpdFile(DrMain *driver, const TQString& filename) line = tin.readLine(); if (line.startsWith("*% COMDATA #")) { - if (line.find("'default'") != -1) + if (line.tqfind("'default'") != -1) { DrBase *opt = (optname.isEmpty() ? NULL : driver->findOption(optname)); if (opt) diff --git a/kdeprint/lpr/printcapreader.cpp b/kdeprint/lpr/printcapreader.cpp index a3ab30e8f..7abd094f9 100644 --- a/kdeprint/lpr/printcapreader.cpp +++ b/kdeprint/lpr/printcapreader.cpp @@ -101,7 +101,7 @@ PrintcapEntry* PrintcapReader::nextEntry() // now parse the entry kdDebug() << "COMMENT: " << comment << endl; kdDebug() << "LINE: " << buf << endl; - int p = buf.find(':'); + int p = buf.tqfind(':'); if (p == -1) name = buf; else @@ -132,14 +132,14 @@ PrintcapEntry* PrintcapReader::nextEntry() for (TQStringList::ConstIterator it=l.begin(); it!=l.end(); ++it) { Field f; - int p = (*it).find('='); + int p = (*it).tqfind('='); if (p == -1) { - p = (*it).find('#'); + p = (*it).tqfind('#'); if (p == -1) { f.type = Field::Boolean; - p = (*it).find('@'); + p = (*it).tqfind('@'); if (p == -1) { f.name = (*it); |