rename the following methods:

tqfind find
tqreplace replace
tqcontains contains


git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegraphics@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
v3.5.13-sru
tpearson 13 years ago
parent d0a269b9b0
commit da4be7880f

@ -184,7 +184,7 @@ void KKameraConfig::load(bool useDefaults )
for (it = groupList.begin(); it != groupList.end(); it++) { for (it = groupList.begin(); it != groupList.end(); it++) {
if (*it != "<default>") { if (*it != "<default>") {
m_config->setGroup(*it); m_config->setGroup(*it);
if (m_config->readEntry("Path").tqcontains("usb:")) if (m_config->readEntry("Path").contains("usb:"))
continue; continue;
kcamera = new KCamera(*it,m_config->readEntry("Path")); kcamera = new KCamera(*it,m_config->readEntry("Path"));
@ -218,7 +218,7 @@ void KKameraConfig::load(bool useDefaults )
if (!strcmp(value,"usb:")) if (!strcmp(value,"usb:"))
names[model] = value; names[model] = value;
} }
if (ports.tqcontains("usb:") && names[ports["usb:"]]!="usb:") if (ports.contains("usb:") && names[ports["usb:"]]!="usb:")
ports.remove("usb:"); ports.remove("usb:");
TQMap<TQString,TQString>::iterator portit; TQMap<TQString,TQString>::iterator portit;
@ -268,15 +268,15 @@ void KKameraConfig::afterCameraOperation(void)
TQString KKameraConfig::suggestName(const TQString &name) TQString KKameraConfig::suggestName(const TQString &name)
{ {
TQString new_name = name; TQString new_name = name;
new_name.tqreplace("/", ""); // we cannot have a slash in a URI's host new_name.replace("/", ""); // we cannot have a slash in a URI's host
if (!m_devices.tqcontains(new_name)) return new_name; if (!m_devices.contains(new_name)) return new_name;
// try new names with a number appended until we find a free one // try new names with a number appended until we find a free one
int i = 1; int i = 1;
while (i++ < 0xffff) { while (i++ < 0xffff) {
new_name = name + " (" + TQString::number(i) + ")"; new_name = name + " (" + TQString::number(i) + ")";
if (!m_devices.tqcontains(new_name)) return new_name; if (!m_devices.contains(new_name)) return new_name;
} }
return TQString(); return TQString();
@ -302,7 +302,7 @@ void KKameraConfig::slot_addCamera()
void KKameraConfig::slot_removeCamera() void KKameraConfig::slot_removeCamera()
{ {
TQString name = m_deviceSel->currentItem()->text(); TQString name = m_deviceSel->currentItem()->text();
if (m_devices.tqcontains(name)) { if (m_devices.contains(name)) {
KCamera *m_device = m_devices[name]; KCamera *m_device = m_devices[name];
m_devices.remove(name); m_devices.remove(name);
delete m_device; delete m_device;
@ -317,7 +317,7 @@ void KKameraConfig::slot_testCamera()
beforeCameraOperation(); beforeCameraOperation();
TQString name = m_deviceSel->currentItem()->text(); TQString name = m_deviceSel->currentItem()->text();
if (m_devices.tqcontains(name)) { if (m_devices.contains(name)) {
KCamera *m_device = m_devices[name]; KCamera *m_device = m_devices[name];
if (m_device->test()) if (m_device->test())
KMessageBox::information(this, i18n("Camera test was successful.")); KMessageBox::information(this, i18n("Camera test was successful."));
@ -329,7 +329,7 @@ void KKameraConfig::slot_testCamera()
void KKameraConfig::slot_configureCamera() void KKameraConfig::slot_configureCamera()
{ {
TQString name = m_deviceSel->currentItem()->text(); TQString name = m_deviceSel->currentItem()->text();
if (m_devices.tqcontains(name)) { if (m_devices.contains(name)) {
KCamera *m_device = m_devices[name]; KCamera *m_device = m_devices[name];
m_device->configure(); m_device->configure();
} }
@ -339,7 +339,7 @@ void KKameraConfig::slot_cameraSummary()
{ {
TQString summary; TQString summary;
TQString name = m_deviceSel->currentItem()->text(); TQString name = m_deviceSel->currentItem()->text();
if (m_devices.tqcontains(name)) { if (m_devices.contains(name)) {
KCamera *m_device = m_devices[name]; KCamera *m_device = m_devices[name];
summary = m_device->summary(); summary = m_device->summary();
if (!summary.isNull()) { if (!summary.isNull()) {

@ -209,7 +209,7 @@ void KCamera::save(KConfig *config)
TQString KCamera::portName() TQString KCamera::portName()
{ {
TQString port = m_path.left(m_path.tqfind(":")).lower(); TQString port = m_path.left(m_path.find(":")).lower();
if (port == "serial") return i18n("Serial"); if (port == "serial") return i18n("Serial");
if (port == "usb") return i18n("USB"); if (port == "usb") return i18n("USB");
return i18n("Unknown port"); return i18n("Unknown port");
@ -403,7 +403,7 @@ void KameraDeviceSelectDialog::save()
void KameraDeviceSelectDialog::load() void KameraDeviceSelectDialog::load()
{ {
TQString path = m_device->path(); TQString path = m_device->path();
TQString port = path.left(path.tqfind(":")).lower(); TQString port = path.left(path.find(":")).lower();
if (port == "serial") setPortType(INDEX_SERIAL); if (port == "serial") setPortType(INDEX_SERIAL);
if (port == "usb") setPortType(INDEX_USB); if (port == "usb") setPortType(INDEX_USB);

@ -574,7 +574,7 @@ void KameraProtocol::listDir(const KURL &url)
gp_list_free (list); gp_list_free (list);
/* Avoid duplicated entry for usb: and usb:001,042 entries. */ /* Avoid duplicated entry for usb: and usb:001,042 entries. */
if (ports.tqcontains("usb:") && names[ports["usb:"]]!="usb:") if (ports.contains("usb:") && names[ports["usb:"]]!="usb:")
ports.remove("usb:"); ports.remove("usb:");
for (it = groupList.begin(); it != groupList.end(); it++) { for (it = groupList.begin(); it != groupList.end(); it++) {
@ -606,7 +606,7 @@ void KameraProtocol::listDir(const KURL &url)
xurl.setProtocol("camera"); xurl.setProtocol("camera");
xurl.setUser(*it); xurl.setUser(*it);
/* Avoid setting usb:xxx,yyy. */ /* Avoid setting usb:xxx,yyy. */
if (m_cfgPath.tqcontains("usb:")>0) { if (m_cfgPath.contains("usb:")>0) {
names[*it] = "usb:"; names[*it] = "usb:";
xurl.setHost("usb:"); xurl.setHost("usb:");
} else { } else {

@ -37,7 +37,7 @@ public:
/** Pastes a stream at index. Uses undo/redo history */ /** Pastes a stream at index. Uses undo/redo history */
void paste(const int index, EDITABLE_STREAM& pasteStream); void paste(const int index, EDITABLE_STREAM& pasteStream);
/** Replaces a stream at index. Uses undo/redo history */ /** Replaces a stream at index. Uses undo/redo history */
void tqreplace(const int index, EDITABLE_STREAM& replaceStream); void replace(const int index, EDITABLE_STREAM& replaceStream);
/** @return Whether undo possible */ /** @return Whether undo possible */
bool undoPossible(); bool undoPossible();
/** @return Whether redo possible */ /** @return Whether redo possible */
@ -76,7 +76,7 @@ template <class EDITABLE_STREAM> void
} }
template <class EDITABLE_STREAM> void template <class EDITABLE_STREAM> void
EditableStreamHistory<EDITABLE_STREAM>::tqreplace(const int index, EDITABLE_STREAM& replaceStream) { EditableStreamHistory<EDITABLE_STREAM>::replace(const int index, EDITABLE_STREAM& replaceStream) {
m_editableStream->cut(index, replaceStream.length()); m_editableStream->cut(index, replaceStream.length());
m_editableStream->paste(index, replaceStream); m_editableStream->paste(index, replaceStream);
} }

@ -281,11 +281,11 @@ void KColorEditDoc::insert(int index, const Color& color) {
slotRedrawAllViews(0); slotRedrawAllViews(0);
} }
void KColorEditDoc::tqreplace(int index, const Color& color) { void KColorEditDoc::replace(int index, const Color& color) {
Palette paletteReplace; Palette paletteReplace;
Color* replaceColor = new Color(color); Color* replaceColor = new Color(color);
paletteReplace.append(replaceColor); paletteReplace.append(replaceColor);
m_paletteHistory.tqreplace(index, paletteReplace); m_paletteHistory.replace(index, paletteReplace);
setPaletteSelection(0, 0); setPaletteSelection(0, 0);
setModified(true); setModified(true);
slotRedrawAllViews(0); slotRedrawAllViews(0);

@ -112,7 +112,7 @@ class KColorEditDoc : public TQObject
/** Inserts a color at index */ /** Inserts a color at index */
void insert(int index, const Color& color); void insert(int index, const Color& color);
/** Replaces a color at index */ /** Replaces a color at index */
void tqreplace(int index, const Color& color); void replace(int index, const Color& color);
protected: protected:
/** Sets an error string if an IO operation was unsuccesfull */ /** Sets an error string if an IO operation was unsuccesfull */

@ -234,7 +234,7 @@ void KColorEditView::slotAddColor() {
case REPLACE_COLOR: case REPLACE_COLOR:
if(index < palette->length()) if(index < palette->length())
document()->tqreplace(index, color); document()->replace(index, color);
else else
document()->insert(index, color); document()->insert(index, color);
break; break;
@ -274,7 +274,7 @@ void KColorEditView::slotSetColorName(const TQString& name) {
palette->color(cursorPos)->component(Color::BLUE_INDEX), palette->color(cursorPos)->component(Color::BLUE_INDEX),
name); name);
doNotUpdateColorLabels = true; doNotUpdateColorLabels = true;
document()->tqreplace(cursorPos, newColor); document()->replace(cursorPos, newColor);
doNotUpdateColorLabels = false; doNotUpdateColorLabels = false;
} }
} }

@ -45,7 +45,7 @@ LoadPaletteDlg::LoadPaletteDlg(TQWidget *tqparent, const char *name)
TQStringList palettesList = Palette::kdePalettes(); TQStringList palettesList = Palette::kdePalettes();
for(TQStringList::Iterator palette = palettesList.begin(); for(TQStringList::Iterator palette = palettesList.begin();
palette != palettesList.end(); ++palette) { palette != palettesList.end(); ++palette) {
bool prepend = (*palette).tqcontains( "colors/Custom_Colors" ); bool prepend = (*palette).contains( "colors/Custom_Colors" );
TQString fileName = locate("config", (*palette)); TQString fileName = locate("config", (*palette));
if(prepend) { if(prepend) {
palettesFileNames.prepend(fileName); palettesFileNames.prepend(fileName);

@ -108,14 +108,14 @@ bool Palette::load(TQTextStream& stream, bool loadName /* = true */) {
int lineNum = 0; int lineNum = 0;
while (!stream.atEnd()) { while (!stream.atEnd()) {
TQString string = stream.readLine().append(' '); TQString string = stream.readLine().append(' ');
if(string.tqfind( TQRegExp("[^\\s]") ) == -1 || if(string.find( TQRegExp("[^\\s]") ) == -1 ||
string.stripWhiteSpace().at( 0 ) == '#' || string.stripWhiteSpace().at( 0 ) == '#' ||
( loadName && lineNum == 0 )) { ( loadName && lineNum == 0 )) {
if(loadName && lineNum == 0) if(loadName && lineNum == 0)
setName(string.stripWhiteSpace()); setName(string.stripWhiteSpace());
} else { } else {
Color* newColor = new Color(); Color* newColor = new Color();
int position = string.tqfind(TQRegExp( "[^\\s]" )); int position = string.find(TQRegExp( "[^\\s]" ));
for(int componentIndex = 0; componentIndex < Color::COMPONENTS_NUM; for(int componentIndex = 0; componentIndex < Color::COMPONENTS_NUM;
++componentIndex) { ++componentIndex) {
if(position == -1) { if(position == -1) {
@ -123,7 +123,7 @@ bool Palette::load(TQTextStream& stream, bool loadName /* = true */) {
result = false; result = false;
break; break;
} }
int endPosition = string.tqfind(TQRegExp( "\\s" ), position); int endPosition = string.find(TQRegExp( "\\s" ), position);
if(endPosition == -1) { if(endPosition == -1) {
m_errorString = i18n("Invalid format"); m_errorString = i18n("Invalid format");
result = false; result = false;
@ -139,7 +139,7 @@ bool Palette::load(TQTextStream& stream, bool loadName /* = true */) {
break; break;
} }
newColor->setComponent(componentIndex, componentValue); newColor->setComponent(componentIndex, componentValue);
position = string.tqfind(TQRegExp( "[^\\s]" ), endPosition); position = string.find(TQRegExp( "[^\\s]" ), endPosition);
} }
if(!result) { if(!result) {
delete newColor; delete newColor;

@ -362,7 +362,7 @@ void dvifile::renumber()
TQString dvifile::convertPDFtoPS(const TQString &PDFFilename) TQString dvifile::convertPDFtoPS(const TQString &PDFFilename)
{ {
// Check if the PDFFile is known // Check if the PDFFile is known
TQMap<TQString, TQString>::Iterator it = convertedFiles.tqfind(PDFFilename); TQMap<TQString, TQString>::Iterator it = convertedFiles.find(PDFFilename);
if (it != convertedFiles.end()) { if (it != convertedFiles.end()) {
// PDF-File is known. Good. // PDF-File is known. Good.
return it.data(); return it.data();

@ -507,7 +507,7 @@ bool dviRenderer::setFile(const TQString &fname, const KURL &base)
TQString includePath; TQString includePath;
if (!baseURL.isLocalFile()) { if (!baseURL.isLocalFile()) {
includePath = filename; includePath = filename;
includePath.truncate(includePath.tqfindRev('/')); includePath.truncate(includePath.findRev('/'));
} }
PS_interface->setIncludePath(includePath); PS_interface->setIncludePath(includePath);
@ -629,7 +629,7 @@ Anchor dviRenderer::parseReference(const TQString &reference)
// points to line number 1111 in the file "Filename". KDVI then // points to line number 1111 in the file "Filename". KDVI then
// looks for source specials of the form "src:xxxxFilename", and // looks for source specials of the form "src:xxxxFilename", and
// tries to find the special with the biggest xxxx // tries to find the special with the biggest xxxx
if (reference.tqfind("src:",0,false) == 0) { if (reference.find("src:",0,false) == 0) {
// Extract the file name and the numeral part from the reference string // Extract the file name and the numeral part from the reference string
DVI_SourceFileSplitter splitter(reference, dviFile->filename); DVI_SourceFileSplitter splitter(reference, dviFile->filename);
@ -651,7 +651,7 @@ Anchor dviRenderer::parseReference(const TQString &reference)
// whose line number is the biggest among those that are smaller // whose line number is the biggest among those that are smaller
// than the refLineNumber. That way, the position in the DVI file // than the refLineNumber. That way, the position in the DVI file
// which is highlighted is always a little further up than the // which is highlighted is always a little further up than the
// position in the editor, e.g. if the DVI file tqcontains // position in the editor, e.g. if the DVI file contains
// positional information at the beginning of every paragraph, // positional information at the beginning of every paragraph,
// KDVI jumps to the beginning of the paragraph that the cursor is // KDVI jumps to the beginning of the paragraph that the cursor is
// in, and never to the next paragraph. If source file anchors for // in, and never to the next paragraph. If source file anchors for
@ -756,7 +756,7 @@ void dviRenderer::handleSRCLink(const TQString &linkText, TQMouseEvent *e, Docum
else else
return; return;
} }
command = command.tqreplace( "%l", TQString::number(splitter.line()) ).tqreplace( "%f", KShellProcess::quote(TeXfile) ); command = command.replace( "%l", TQString::number(splitter.line()) ).replace( "%f", KShellProcess::quote(TeXfile) );
#ifdef DEBUG_SPECIAL #ifdef DEBUG_SPECIAL
kdDebug(4300) << "Calling program: " << command << endl; kdDebug(4300) << "Calling program: " << command << endl;
@ -810,27 +810,27 @@ TQString dviRenderer::PDFencodingToTQString(const TQString& _pdfstring)
// replaces them by UTF8. See Section 3.2.3 of the PDF reference // replaces them by UTF8. See Section 3.2.3 of the PDF reference
// guide for information. // guide for information.
TQString pdfstring = _pdfstring; TQString pdfstring = _pdfstring;
pdfstring = pdfstring.tqreplace("\\n", "\n"); pdfstring = pdfstring.replace("\\n", "\n");
pdfstring = pdfstring.tqreplace("\\r", "\n"); pdfstring = pdfstring.replace("\\r", "\n");
pdfstring = pdfstring.tqreplace("\\t", "\t"); pdfstring = pdfstring.replace("\\t", "\t");
pdfstring = pdfstring.tqreplace("\\f", "\f"); pdfstring = pdfstring.replace("\\f", "\f");
pdfstring = pdfstring.tqreplace("\\(", "("); pdfstring = pdfstring.replace("\\(", "(");
pdfstring = pdfstring.tqreplace("\\)", ")"); pdfstring = pdfstring.replace("\\)", ")");
pdfstring = pdfstring.tqreplace("\\\\", "\\"); pdfstring = pdfstring.replace("\\\\", "\\");
// Now replace octal character codes with the characters they encode // Now replace octal character codes with the characters they encode
int pos; int pos;
TQRegExp rx( "(\\\\)(\\d\\d\\d)" ); // matches "\xyz" where x,y,z are numbers TQRegExp rx( "(\\\\)(\\d\\d\\d)" ); // matches "\xyz" where x,y,z are numbers
while((pos = rx.search( pdfstring )) != -1) { while((pos = rx.search( pdfstring )) != -1) {
pdfstring = pdfstring.tqreplace(pos, 4, TQChar(rx.cap(2).toInt(0,8))); pdfstring = pdfstring.replace(pos, 4, TQChar(rx.cap(2).toInt(0,8)));
} }
rx.setPattern( "(\\\\)(\\d\\d)" ); // matches "\xy" where x,y are numbers rx.setPattern( "(\\\\)(\\d\\d)" ); // matches "\xy" where x,y are numbers
while((pos = rx.search( pdfstring )) != -1) { while((pos = rx.search( pdfstring )) != -1) {
pdfstring = pdfstring.tqreplace(pos, 3, TQChar(rx.cap(2).toInt(0,8))); pdfstring = pdfstring.replace(pos, 3, TQChar(rx.cap(2).toInt(0,8)));
} }
rx.setPattern( "(\\\\)(\\d)" ); // matches "\x" where x is a number rx.setPattern( "(\\\\)(\\d)" ); // matches "\x" where x is a number
while((pos = rx.search( pdfstring )) != -1) { while((pos = rx.search( pdfstring )) != -1) {
pdfstring = pdfstring.tqreplace(pos, 4, TQChar(rx.cap(2).toInt(0,8))); pdfstring = pdfstring.replace(pos, 4, TQChar(rx.cap(2).toInt(0,8)));
} }
return pdfstring; return pdfstring;
} }

@ -290,7 +290,7 @@ void dviRenderer::draw_part(double current_dimconv, bool is_vfmacro)
(this->*currinf.set_char_p)(ch, ch); (this->*currinf.set_char_p)(ch, ch);
} else } else
if (FNTNUM0 <= ch && ch <= (unsigned char) (FNTNUM0 + 63)) { if (FNTNUM0 <= ch && ch <= (unsigned char) (FNTNUM0 + 63)) {
currinf.fontp = currinf.fonttable->tqfind(ch - FNTNUM0); currinf.fontp = currinf.fonttable->find(ch - FNTNUM0);
if (currinf.fontp == NULL) { if (currinf.fontp == NULL) {
errorMsg = i18n("The DVI code referred to font #%1, which was not previously defined.").tqarg(ch - FNTNUM0); errorMsg = i18n("The DVI code referred to font #%1, which was not previously defined.").tqarg(ch - FNTNUM0);
return; return;
@ -511,7 +511,7 @@ void dviRenderer::draw_part(double current_dimconv, bool is_vfmacro)
case FNT1: case FNT1:
case FNT2: case FNT2:
case FNT3: case FNT3:
currinf.fontp = currinf.fonttable->tqfind(readUINT(ch - FNT1 + 1)); currinf.fontp = currinf.fonttable->find(readUINT(ch - FNT1 + 1));
if (currinf.fontp == NULL) { if (currinf.fontp == NULL) {
errorMsg = i18n("The DVI code referred to a font which was not previously defined."); errorMsg = i18n("The DVI code referred to a font which was not previously defined.");
return; return;
@ -520,7 +520,7 @@ void dviRenderer::draw_part(double current_dimconv, bool is_vfmacro)
break; break;
case FNT4: case FNT4:
currinf.fontp = currinf.fonttable->tqfind(readINT(ch - FNT1 + 1)); currinf.fontp = currinf.fonttable->find(readINT(ch - FNT1 + 1));
if (currinf.fontp == NULL) { if (currinf.fontp == NULL) {
errorMsg = i18n("The DVI code referred to a font which was not previously defined."); errorMsg = i18n("The DVI code referred to a font which was not previously defined.");
return; return;

@ -94,7 +94,7 @@ void dviRenderer::exportPDF()
// Generate a suggestion for a reasonable file name // Generate a suggestion for a reasonable file name
TQString suggestedName = dviFile->filename; TQString suggestedName = dviFile->filename;
suggestedName = suggestedName.left(suggestedName.tqfind(".")) + ".pdf"; suggestedName = suggestedName.left(suggestedName.find(".")) + ".pdf";
TQString fileName = KFileDialog::getSaveFileName(suggestedName, i18n("*.pdf|Portable Document Format (*.pdf)"), parentWidget, i18n("Export File As")); TQString fileName = KFileDialog::getSaveFileName(suggestedName, i18n("*.pdf|Portable Document Format (*.pdf)"), parentWidget, i18n("Export File As"));
if (fileName.isEmpty()) if (fileName.isEmpty())
@ -193,7 +193,7 @@ void dviRenderer::exportPS(const TQString& fname, const TQString& options, KPrin
if (fname.isEmpty()) { if (fname.isEmpty()) {
// Generate a suggestion for a reasonable file name // Generate a suggestion for a reasonable file name
TQString suggestedName = dviFile->filename; TQString suggestedName = dviFile->filename;
suggestedName = suggestedName.left(suggestedName.tqfind(".")) + ".ps"; suggestedName = suggestedName.left(suggestedName.find(".")) + ".ps";
fileName = KFileDialog::getSaveFileName(suggestedName, i18n("*.ps|PostScript (*.ps)"), parentWidget, i18n("Export File As")); fileName = KFileDialog::getSaveFileName(suggestedName, i18n("*.ps|PostScript (*.ps)"), parentWidget, i18n("Export File As"));
if (fileName.isEmpty()) if (fileName.isEmpty())

@ -60,7 +60,7 @@ void dviRenderer::prescan_embedPS(char *cp, TQ_UINT8 *beginningOfSpecialCommand)
// (already the simplifyWhiteSpace() above is wrong). If you have // (already the simplifyWhiteSpace() above is wrong). If you have
// files like this, go away. // files like this, go away.
TQString EPSfilename = include_command; TQString EPSfilename = include_command;
EPSfilename.truncate(EPSfilename.tqfind(' ')); EPSfilename.truncate(EPSfilename.find(' '));
// Strip enclosing quotation marks which are included by some LaTeX // Strip enclosing quotation marks which are included by some LaTeX
// macro packages (but not by others). This probably means that // macro packages (but not by others). This probably means that
@ -118,7 +118,7 @@ void dviRenderer::prescan_embedPS(char *cp, TQ_UINT8 *beginningOfSpecialCommand)
int angle = 0; int angle = 0;
// just to avoid ambiguities; the filename could contain keywords // just to avoid ambiguities; the filename could contain keywords
include_command = include_command.mid(include_command.tqfind(' ')); include_command = include_command.mid(include_command.find(' '));
parse_special_argument(include_command, "llx=", &llx); parse_special_argument(include_command, "llx=", &llx);
parse_special_argument(include_command, "lly=", &lly); parse_special_argument(include_command, "lly=", &lly);
@ -128,7 +128,7 @@ void dviRenderer::prescan_embedPS(char *cp, TQ_UINT8 *beginningOfSpecialCommand)
parse_special_argument(include_command, "rhi=", &rhi); parse_special_argument(include_command, "rhi=", &rhi);
parse_special_argument(include_command, "angle=", &angle); parse_special_argument(include_command, "angle=", &angle);
int clip=include_command.tqfind(" clip"); // -1 if clip keyword is not present, >= 0 otherwise int clip=include_command.find(" clip"); // -1 if clip keyword is not present, >= 0 otherwise
// Generate the PostScript commands to be included // Generate the PostScript commands to be included
TQString PS = TQString("ps: @beginspecial %1 @llx %2 @lly %3 @urx %4 @ury").tqarg(llx).tqarg(lly).tqarg(urx).tqarg(ury); TQString PS = TQString("ps: @beginspecial %1 @llx %2 @lly %3 @urx %4 @ury").tqarg(llx).tqarg(lly).tqarg(urx).tqarg(ury);
@ -271,7 +271,7 @@ void dviRenderer::prescan_ParseBackgroundSpecial(const TQString& cp)
void dviRenderer::prescan_ParseHTMLAnchorSpecial(const TQString& _cp) void dviRenderer::prescan_ParseHTMLAnchorSpecial(const TQString& _cp)
{ {
TQString cp = _cp; TQString cp = _cp;
cp.truncate(cp.tqfind('"')); cp.truncate(cp.find('"'));
Length l; Length l;
l.setLength_in_inch(currinf.data.dvi_v/(resolutionInDPI*shrinkfactor)); l.setLength_in_inch(currinf.data.dvi_v/(resolutionInDPI*shrinkfactor));
anchorList[cp] = Anchor(current_page+1, l); anchorList[cp] = Anchor(current_page+1, l);
@ -355,14 +355,14 @@ void dviRenderer::prescan_ParsePSSpecial(const TQString& cp)
if (cp.startsWith("ps:SDict begin /product where{pop product(Distiller)")) if (cp.startsWith("ps:SDict begin /product where{pop product(Distiller)"))
return; // hyperref tries to work around Distiller bug return; // hyperref tries to work around Distiller bug
if (cp.startsWith("ps:SDict begin [") && cp.endsWith(" pdfmark end")) { // hyperref definition of link/anchor/bookmark/etc if (cp.startsWith("ps:SDict begin [") && cp.endsWith(" pdfmark end")) { // hyperref definition of link/anchor/bookmark/etc
if (cp.tqcontains("/DEST")) { // The PostScript code defines an anchor if (cp.contains("/DEST")) { // The PostScript code defines an anchor
TQString anchorName = cp.section('(', 1, 1).section(')', 0, 0); TQString anchorName = cp.section('(', 1, 1).section(')', 0, 0);
Length l; Length l;
l.setLength_in_inch(currinf.data.dvi_v/(resolutionInDPI*shrinkfactor)); l.setLength_in_inch(currinf.data.dvi_v/(resolutionInDPI*shrinkfactor));
anchorList[anchorName] = Anchor(current_page+1, l); anchorList[anchorName] = Anchor(current_page+1, l);
} }
// The PostScript code defines a bookmark // The PostScript code defines a bookmark
if (cp.tqcontains("/Dest") && cp.tqcontains("/Title")) if (cp.contains("/Dest") && cp.contains("/Title"))
prebookmarks.append(PreBookmark(PDFencodingToTQString(cp.section('(', 2, 2).section(')', 0, 0)), prebookmarks.append(PreBookmark(PDFencodingToTQString(cp.section('(', 2, 2).section(')', 0, 0)),
cp.section('(', 1, 1).section(')', 0, 0), cp.section('(', 1, 1).section(')', 0, 0),
cp.section('-', 1, 1).section(' ', 0, 0).toUInt() cp.section('-', 1, 1).section(' ', 0, 0).toUInt()
@ -374,14 +374,14 @@ void dviRenderer::prescan_ParsePSSpecial(const TQString& cp)
double PS_H = (currinf.data.dvi_h*300.0)/(65536*1200)-300; double PS_H = (currinf.data.dvi_h*300.0)/(65536*1200)-300;
double PS_V = (currinf.data.dvi_v*300.0)/1200 - 300; double PS_V = (currinf.data.dvi_v*300.0)/1200 - 300;
if (cp.tqfind("ps::[begin]", 0, false) == 0) { if (cp.find("ps::[begin]", 0, false) == 0) {
PostScriptOutPutString->append( TQString(" %1 %2 moveto\n").tqarg(PS_H).tqarg(PS_V) ); PostScriptOutPutString->append( TQString(" %1 %2 moveto\n").tqarg(PS_H).tqarg(PS_V) );
PostScriptOutPutString->append( TQString(" %1\n").tqarg(cp.mid(11)) ); PostScriptOutPutString->append( TQString(" %1\n").tqarg(cp.mid(11)) );
} else { } else {
if (cp.tqfind("ps::[end]", 0, false) == 0) { if (cp.find("ps::[end]", 0, false) == 0) {
PostScriptOutPutString->append( TQString(" %1\n").tqarg(cp.mid(9)) ); PostScriptOutPutString->append( TQString(" %1\n").tqarg(cp.mid(9)) );
} else { } else {
if (cp.tqfind("ps::", 0, false) == 0) { if (cp.find("ps::", 0, false) == 0) {
PostScriptOutPutString->append( TQString(" %1\n").tqarg(cp.mid(4)) ); PostScriptOutPutString->append( TQString(" %1\n").tqarg(cp.mid(4)) );
} else { } else {
PostScriptOutPutString->append( TQString(" %1 %2 moveto\n").tqarg(PS_H).tqarg(PS_V) ); PostScriptOutPutString->append( TQString(" %1 %2 moveto\n").tqarg(PS_H).tqarg(PS_V) );
@ -406,7 +406,7 @@ void dviRenderer::prescan_ParsePSFileSpecial(const TQString& cp)
// (already the simplifyWhiteSpace() above is wrong). If you have // (already the simplifyWhiteSpace() above is wrong). If you have
// files like this, go away. // files like this, go away.
TQString EPSfilename = include_command; TQString EPSfilename = include_command;
EPSfilename.truncate(EPSfilename.tqfind(' ')); EPSfilename.truncate(EPSfilename.find(' '));
// Strip enclosing quotation marks which are included by some LaTeX // Strip enclosing quotation marks which are included by some LaTeX
// macro packages (but not by others). This probably means that // macro packages (but not by others). This probably means that
@ -444,7 +444,7 @@ void dviRenderer::prescan_ParsePSFileSpecial(const TQString& cp)
int angle = 0; int angle = 0;
// just to avoid ambiguities; the filename could contain keywords // just to avoid ambiguities; the filename could contain keywords
include_command = include_command.mid(include_command.tqfind(' ')); include_command = include_command.mid(include_command.find(' '));
parse_special_argument(include_command, "llx=", &llx); parse_special_argument(include_command, "llx=", &llx);
parse_special_argument(include_command, "lly=", &lly); parse_special_argument(include_command, "lly=", &lly);
@ -454,7 +454,7 @@ void dviRenderer::prescan_ParsePSFileSpecial(const TQString& cp)
parse_special_argument(include_command, "rhi=", &rhi); parse_special_argument(include_command, "rhi=", &rhi);
parse_special_argument(include_command, "angle=", &angle); parse_special_argument(include_command, "angle=", &angle);
int clip=include_command.tqfind(" clip"); // -1 if clip keyword is not present, >= 0 otherwise int clip=include_command.find(" clip"); // -1 if clip keyword is not present, >= 0 otherwise
if (TQFile::exists(EPSfilename)) { if (TQFile::exists(EPSfilename)) {
double PS_H = (currinf.data.dvi_h*300.0)/(65536*1200)-300; double PS_H = (currinf.data.dvi_h*300.0)/(65536*1200)-300;
@ -631,7 +631,7 @@ void dviRenderer::prescan(parseSpecials specialParser)
} }
if (FNTNUM0 <= ch && ch <= (unsigned char) (FNTNUM0 + 63)) { if (FNTNUM0 <= ch && ch <= (unsigned char) (FNTNUM0 + 63)) {
currinf.fontp = currinf.fonttable->tqfind(ch - FNTNUM0); currinf.fontp = currinf.fonttable->find(ch - FNTNUM0);
if (currinf.fontp == NULL) { if (currinf.fontp == NULL) {
errorMsg = i18n("The DVI code referred to font #%1, which was not previously defined.").tqarg(ch - FNTNUM0); errorMsg = i18n("The DVI code referred to font #%1, which was not previously defined.").tqarg(ch - FNTNUM0);
return; return;
@ -750,7 +750,7 @@ void dviRenderer::prescan(parseSpecials specialParser)
case FNT2: case FNT2:
case FNT3: case FNT3:
case FNT4: case FNT4:
currinf.fontp = currinf.fonttable->tqfind(readUINT(ch - FNT1 + 1)); currinf.fontp = currinf.fonttable->find(readUINT(ch - FNT1 + 1));
if (currinf.fontp == NULL) if (currinf.fontp == NULL)
return; return;
currinf.set_char_p = currinf.fontp->set_char_p; currinf.set_char_p = currinf.fontp->set_char_p;

@ -53,7 +53,7 @@ void DVIWidget::mousePressEvent(TQMouseEvent* e)
for(unsigned int i=0; i<pageData->sourceHyperLinkList.size(); i++) for(unsigned int i=0; i<pageData->sourceHyperLinkList.size(); i++)
{ {
if (pageData->sourceHyperLinkList[i].box.tqcontains(e->pos())) if (pageData->sourceHyperLinkList[i].box.contains(e->pos()))
{ {
emit(SRCLink(pageData->sourceHyperLinkList[i].linkText, e, this)); emit(SRCLink(pageData->sourceHyperLinkList[i].linkText, e, this));
e->accept(); e->accept();
@ -99,7 +99,7 @@ void DVIWidget::mouseMoveEvent(TQMouseEvent* e)
// Check if the cursor hovers over a sourceHyperlink. // Check if the cursor hovers over a sourceHyperlink.
for(unsigned int i=0; i<pageData->sourceHyperLinkList.size(); i++) { for(unsigned int i=0; i<pageData->sourceHyperLinkList.size(); i++) {
if (pageData->sourceHyperLinkList[i].box.tqcontains(e->pos())) { if (pageData->sourceHyperLinkList[i].box.contains(e->pos())) {
clearStatusBarTimer.stop(); clearStatusBarTimer.stop();
// The macro-package srcltx gives a special like "src:99 test.tex" // The macro-package srcltx gives a special like "src:99 test.tex"

Binary file not shown.

@ -48,7 +48,7 @@
* a different name and with a different encoding ---the map file * a different name and with a different encoding ---the map file
* (fontMap.h) can probably see to that. * (fontMap.h) can probably see to that.
* *
* Summing up: this class tqcontains 256 glyph names read from an * Summing up: this class contains 256 glyph names read from an
* encoding file during the construction of this class. * encoding file during the construction of this class.
* *
* @author Stefan Kebekus <kebekus@kde.org> * @author Stefan Kebekus <kebekus@kde.org>

@ -18,7 +18,7 @@ fontEncodingPool::fontEncodingPool()
fontEncoding *fontEncodingPool::findByName(const TQString &name) fontEncoding *fontEncodingPool::findByName(const TQString &name)
{ {
fontEncoding *ptr = dictionary.tqfind( name ); fontEncoding *ptr = dictionary.find( name );
if (ptr == 0) { if (ptr == 0) {
ptr = new fontEncoding(name); ptr = new fontEncoding(name);

@ -78,7 +78,7 @@ fontMap::fontMap()
encodingName = encodingName.mid(1); encodingName = encodingName.mid(1);
double slant = 0.0; double slant = 0.0;
int i = line.tqfind("SlantFont"); int i = line.find("SlantFont");
if (i >= 0) { if (i >= 0) {
bool ok; bool ok;
slant = line.left(i).section(' ', -1, -1 ,TQString::SectionSkipEmpty).toDouble(&ok); slant = line.left(i).section(' ', -1, -1 ,TQString::SectionSkipEmpty).toDouble(&ok);
@ -115,7 +115,7 @@ fontMap::fontMap()
const TQString &fontMap::findFileName(const TQString &TeXName) const TQString &fontMap::findFileName(const TQString &TeXName)
{ {
TQMap<TQString, fontMapEntry>::Iterator it = fontMapEntries.tqfind(TeXName); TQMap<TQString, fontMapEntry>::Iterator it = fontMapEntries.find(TeXName);
if (it != fontMapEntries.end()) if (it != fontMapEntries.end())
return it.data().fontFileName; return it.data().fontFileName;
@ -126,7 +126,7 @@ const TQString &fontMap::findFileName(const TQString &TeXName)
const TQString &fontMap::findFontName(const TQString &TeXName) const TQString &fontMap::findFontName(const TQString &TeXName)
{ {
TQMap<TQString, fontMapEntry>::Iterator it = fontMapEntries.tqfind(TeXName); TQMap<TQString, fontMapEntry>::Iterator it = fontMapEntries.find(TeXName);
if (it != fontMapEntries.end()) if (it != fontMapEntries.end())
return it.data().fullFontName; return it.data().fullFontName;
@ -137,7 +137,7 @@ const TQString &fontMap::findFontName(const TQString &TeXName)
const TQString &fontMap::findEncoding(const TQString &TeXName) const TQString &fontMap::findEncoding(const TQString &TeXName)
{ {
TQMap<TQString, fontMapEntry>::Iterator it = fontMapEntries.tqfind(TeXName); TQMap<TQString, fontMapEntry>::Iterator it = fontMapEntries.find(TeXName);
if (it != fontMapEntries.end()) if (it != fontMapEntries.end())
return it.data().fontEncoding; return it.data().fontEncoding;
@ -148,7 +148,7 @@ const TQString &fontMap::findEncoding(const TQString &TeXName)
double fontMap::findSlant(const TQString &TeXName) double fontMap::findSlant(const TQString &TeXName)
{ {
TQMap<TQString, fontMapEntry>::Iterator it = fontMapEntries.tqfind(TeXName); TQMap<TQString, fontMapEntry>::Iterator it = fontMapEntries.find(TeXName);
if (it != fontMapEntries.end()) if (it != fontMapEntries.end())
return it.data().slant; return it.data().slant;

@ -13,7 +13,7 @@
#include <tqstring.h> #include <tqstring.h>
/** /**
* This class represents one line of a font map file, and tqcontains * This class represents one line of a font map file, and contains
* three pieces of information about a font: its file name, the full * three pieces of information about a font: its file name, the full
* name of the font, and the encoding. * name of the font, and the encoding.
* *

@ -46,7 +46,7 @@ fontPool::fontPool()
i18n( "KDVI is currently generating bitmap fonts..." ), i18n( "KDVI is currently generating bitmap fonts..." ),
i18n( "Aborts the font generation. Don't do this." ), i18n( "Aborts the font generation. Don't do this." ),
i18n( "KDVI is currently generating bitmap fonts which are needed to display your document. " i18n( "KDVI is currently generating bitmap fonts which are needed to display your document. "
"For this, KDVI uses a number of external programs, such as MetaFont. You can tqfind " "For this, KDVI uses a number of external programs, such as MetaFont. You can find "
"the output of these programs later in the document info dialog." ), "the output of these programs later in the document info dialog." ),
i18n( "KDVI is generating fonts. Please wait." ), i18n( "KDVI is generating fonts. Please wait." ),
0 ) 0 )
@ -558,32 +558,32 @@ void fontPool::mf_output_receiver(KProcess *, char *buffer, int buflen)
// We'd like to print only full lines of text. // We'd like to print only full lines of text.
int numleft; int numleft;
bool show_prog = false; bool show_prog = false;
while( (numleft = MetafontOutput.tqfind('\n')) != -1) { while( (numleft = MetafontOutput.find('\n')) != -1) {
TQString line = MetafontOutput.left(numleft+1); TQString line = MetafontOutput.left(numleft+1);
#ifdef DEBUG_FONTPOOL #ifdef DEBUG_FONTPOOL
kdDebug(4300) << "MF OUTPUT RECEIVED: " << line; kdDebug(4300) << "MF OUTPUT RECEIVED: " << line;
#endif #endif
// Search for a line which marks the beginning of a MetaFont run // Search for a line which marks the beginning of a MetaFont run
// and show the progress dialog at the end of this method. // and show the progress dialog at the end of this method.
if (line.tqfind("kpathsea:") == 0) if (line.find("kpathsea:") == 0)
show_prog = true; show_prog = true;
// If the Output of the kpsewhich program contains a line starting // If the Output of the kpsewhich program contains a line starting
// with "kpathsea:", this means that a new MetaFont-run has been // with "kpathsea:", this means that a new MetaFont-run has been
// started. We filter these lines out and update the display // started. We filter these lines out and update the display
// accordingly. // accordingly.
int startlineindex = line.tqfind("kpathsea:"); int startlineindex = line.find("kpathsea:");
if (startlineindex != -1) { if (startlineindex != -1) {
int endstartline = line.tqfind("\n",startlineindex); int endstartline = line.find("\n",startlineindex);
TQString startLine = line.mid(startlineindex,endstartline-startlineindex); TQString startLine = line.mid(startlineindex,endstartline-startlineindex);
// The last word in the startline is the name of the font which we // The last word in the startline is the name of the font which we
// are generating. The second-to-last word is the resolution in // are generating. The second-to-last word is the resolution in
// dots per inch. Display this info in the text label below the // dots per inch. Display this info in the text label below the
// progress bar. // progress bar.
int lastblank = startLine.tqfindRev(' '); int lastblank = startLine.findRev(' ');
TQString fontName = startLine.mid(lastblank+1); TQString fontName = startLine.mid(lastblank+1);
int secondblank = startLine.tqfindRev(' ',lastblank-1); int secondblank = startLine.findRev(' ',lastblank-1);
TQString dpi = startLine.mid(secondblank+1,lastblank-secondblank-1); TQString dpi = startLine.mid(secondblank+1,lastblank-secondblank-1);
progress.show(); progress.show();

@ -89,7 +89,7 @@ void infoDialog::setFontInfo(fontPool *fp)
void infoDialog::outputReceiver(const TQString& _op) void infoDialog::outputReceiver(const TQString& _op)
{ {
TQString op = _op; TQString op = _op;
op = op.tqreplace( TQRegExp("<"), "&lt;" ); op = op.replace( TQRegExp("<"), "&lt;" );
if (MFOutputReceived == false) { if (MFOutputReceived == false) {
TextLabel3->setText("<b>"+headline+"</b><br>"); TextLabel3->setText("<b>"+headline+"</b><br>");
@ -99,7 +99,7 @@ void infoDialog::outputReceiver(const TQString& _op)
// It seems that the TQTextView wants that we append only full lines. // It seems that the TQTextView wants that we append only full lines.
// We see to that. // We see to that.
pool = pool+op; pool = pool+op;
int idx = pool.tqfindRev("\n"); int idx = pool.findRev("\n");
while(idx != -1) { while(idx != -1) {
TQString line = pool.left(idx); TQString line = pool.left(idx);
@ -108,9 +108,9 @@ void infoDialog::outputReceiver(const TQString& _op)
// If the Output of the kpsewhich program contains a line starting // If the Output of the kpsewhich program contains a line starting
// with "kpathsea:", this means that a new MetaFont-run has been // with "kpathsea:", this means that a new MetaFont-run has been
// started. We filter these lines out and print them in boldface. // started. We filter these lines out and print them in boldface.
int startlineindex = line.tqfind("kpathsea:"); int startlineindex = line.find("kpathsea:");
if (startlineindex != -1) { if (startlineindex != -1) {
int endstartline = line.tqfind("\n",startlineindex); int endstartline = line.find("\n",startlineindex);
TQString startLine = line.mid(startlineindex,endstartline-startlineindex); TQString startLine = line.mid(startlineindex,endstartline-startlineindex);
if (MFOutputReceived) if (MFOutputReceived)
TextLabel3->append("<hr>\n<b>"+startLine+"</b>"); TextLabel3->append("<hr>\n<b>"+startLine+"</b>");
@ -119,7 +119,7 @@ void infoDialog::outputReceiver(const TQString& _op)
TextLabel3->append(line.mid(endstartline)); TextLabel3->append(line.mid(endstartline));
} else } else
TextLabel3->append(line); TextLabel3->append(line);
idx = pool.tqfindRev("\n"); idx = pool.findRev("\n");
} }
MFOutputReceived = true; MFOutputReceived = true;

@ -141,7 +141,7 @@ void KDVIMultiPage::slotSave()
// Try to guess the proper ending... // Try to guess the proper ending...
TQString formats; TQString formats;
TQString ending; TQString ending;
int rindex = m_file.tqfindRev("."); int rindex = m_file.findRev(".");
if (rindex == -1) { if (rindex == -1) {
ending = TQString(); ending = TQString();
formats = TQString(); formats = TQString();
@ -157,7 +157,7 @@ void KDVIMultiPage::slotSave()
// Add the ending to the filename. I hope the user likes it that // Add the ending to the filename. I hope the user likes it that
// way. // way.
if (!ending.isEmpty() && fileName.tqfind(ending) == -1) if (!ending.isEmpty() && fileName.find(ending) == -1)
fileName = fileName+ending; fileName = fileName+ending;
if (TQFile(fileName).exists()) { if (TQFile(fileName).exists()) {

@ -98,7 +98,7 @@ int main(int argc, char** argv)
QCStringList apps = app.dcopClient()->registeredApplications(); QCStringList apps = app.dcopClient()->registeredApplications();
for ( QCStringList::Iterator it = apps.begin(); it != apps.end(); ++it ) for ( QCStringList::Iterator it = apps.begin(); it != apps.end(); ++it )
{ {
if ((*it).tqfind("kviewshell") == 0) if ((*it).find("kviewshell") == 0)
{ {
TQByteArray data, replyData; TQByteArray data, replyData;
TQCString replyType; TQCString replyType;

@ -64,14 +64,14 @@ void ghostscript_interface::setPostScript(const PageNumber& page, const TQString
kdDebug(4300) << "ghostscript_interface::setPostScript( " << page << ", ... )" << endl; kdDebug(4300) << "ghostscript_interface::setPostScript( " << page << ", ... )" << endl;
#endif #endif
if (pageList.tqfind(page) == 0) { if (pageList.find(page) == 0) {
pageInfo *info = new pageInfo(PostScript); pageInfo *info = new pageInfo(PostScript);
// Check if dict is big enough // Check if dict is big enough
if (pageList.count() > pageList.size() -2) if (pageList.count() > pageList.size() -2)
pageList.resize(pageList.size()*2); pageList.resize(pageList.size()*2);
pageList.insert(page, info); pageList.insert(page, info);
} else } else
*(pageList.tqfind(page)->PostScriptString) = PostScript; *(pageList.find(page)->PostScriptString) = PostScript;
} }
@ -88,7 +88,7 @@ void ghostscript_interface::setBackgroundColor(const PageNumber& page, const TQC
kdDebug(4300) << "ghostscript_interface::setBackgroundColor( " << page << ", " << background_color << " )" << endl; kdDebug(4300) << "ghostscript_interface::setBackgroundColor( " << page << ", " << background_color << " )" << endl;
#endif #endif
if (pageList.tqfind(page) == 0) { if (pageList.find(page) == 0) {
pageInfo *info = new pageInfo(TQString()); pageInfo *info = new pageInfo(TQString());
info->background = background_color; info->background = background_color;
if (permanent) if (permanent)
@ -98,9 +98,9 @@ void ghostscript_interface::setBackgroundColor(const PageNumber& page, const TQC
pageList.resize(pageList.size()*2); pageList.resize(pageList.size()*2);
pageList.insert(page, info); pageList.insert(page, info);
} else { } else {
pageList.tqfind(page)->background = background_color; pageList.find(page)->background = background_color;
if (permanent) if (permanent)
pageList.tqfind(page)->permanentBackground = background_color; pageList.find(page)->permanentBackground = background_color;
} }
} }
@ -109,10 +109,10 @@ void ghostscript_interface::restoreBackgroundColor(const PageNumber& page)
#ifdef DEBUG_PSGS #ifdef DEBUG_PSGS
kdDebug(4300) << "ghostscript_interface::restoreBackgroundColor( " << page << " )" << endl; kdDebug(4300) << "ghostscript_interface::restoreBackgroundColor( " << page << " )" << endl;
#endif #endif
if (pageList.tqfind(page) == 0) if (pageList.find(page) == 0)
return; return;
pageInfo *info = pageList.tqfind(page); pageInfo *info = pageList.find(page);
info->background = info->permanentBackground; info->background = info->permanentBackground;
} }
@ -124,10 +124,10 @@ TQColor ghostscript_interface::getBackgroundColor(const PageNumber& page) const
kdDebug(4300) << "ghostscript_interface::getBackgroundColor( " << page << " )" << endl; kdDebug(4300) << "ghostscript_interface::getBackgroundColor( " << page << " )" << endl;
#endif #endif
if (pageList.tqfind(page) == 0) if (pageList.find(page) == 0)
return TQt::white; return TQt::white;
else else
return pageList.tqfind(page)->background; return pageList.find(page)->background;
} }
@ -151,7 +151,7 @@ void ghostscript_interface::gs_generate_graphics_file(const PageNumber& page, co
emit(setStatusBarText(i18n("Generating PostScript graphics..."))); emit(setStatusBarText(i18n("Generating PostScript graphics...")));
pageInfo *info = pageList.tqfind(page); pageInfo *info = pageList.find(page);
// Generate a PNG-file // Generate a PNG-file
// Step 1: Write the PostScriptString to a File // Step 1: Write the PostScriptString to a File
@ -239,7 +239,7 @@ void ghostscript_interface::gs_generate_graphics_file(const PageNumber& page, co
// ghostscript. If so, try again with another device. // ghostscript. If so, try again with another device.
TQString GSoutput; TQString GSoutput;
while(proc.readln(GSoutput) != -1) { while(proc.readln(GSoutput) != -1) {
if (GSoutput.tqcontains("Unknown device")) { if (GSoutput.contains("Unknown device")) {
kdDebug(4300) << TQString("The version of ghostview installed on this computer does not support " kdDebug(4300) << TQString("The version of ghostview installed on this computer does not support "
"the '%1' ghostview device driver.").tqarg(*gsDevice) << endl; "the '%1' ghostview device driver.").tqarg(*gsDevice) << endl;
knownDevices.remove(gsDevice); knownDevices.remove(gsDevice);
@ -293,7 +293,7 @@ void ghostscript_interface::graphics(const PageNumber& page, double dpi, long ma
pixel_page_w = paint->viewport().width(); pixel_page_w = paint->viewport().width();
pixel_page_h = paint->viewport().height(); pixel_page_h = paint->viewport().height();
pageInfo *info = pageList.tqfind(page); pageInfo *info = pageList.find(page);
// No PostScript? Then return immediately. // No PostScript? Then return immediately.
if ((info == 0) || (info->PostScriptString->isEmpty())) { if ((info == 0) || (info->PostScriptString->isEmpty())) {
@ -317,7 +317,7 @@ void ghostscript_interface::graphics(const PageNumber& page, double dpi, long ma
TQString ghostscript_interface::locateEPSfile(const TQString &filename, const KURL &base) TQString ghostscript_interface::locateEPSfile(const TQString &filename, const KURL &base)
{ {
// If the base URL indicates that the DVI file is local, try to tqfind // If the base URL indicates that the DVI file is local, try to find
// the graphics file in the directory where the DVI file resides // the graphics file in the directory where the DVI file resides
if (base.isLocalFile()) { if (base.isLocalFile()) {
TQString path = base.path(); // -> "/bar/foo.dvi" TQString path = base.path(); // -> "/bar/foo.dvi"

@ -120,7 +120,7 @@ TQColor dviRenderer::parseColorSpecification(const TQString& colorSpec)
TQString specType = colorSpec.section(' ', 0, 0); TQString specType = colorSpec.section(' ', 0, 0);
if (specType.tqfind("rgb", false) == 0) { if (specType.find("rgb", false) == 0) {
bool ok; bool ok;
double r = colorSpec.section(' ', 1, 1).toDouble(&ok); double r = colorSpec.section(' ', 1, 1).toDouble(&ok);
@ -138,7 +138,7 @@ TQColor dviRenderer::parseColorSpecification(const TQString& colorSpec)
return TQColor((int)(r*255.0+0.5), (int)(g*255.0+0.5), (int)(b*255.0+0.5)); return TQColor((int)(r*255.0+0.5), (int)(g*255.0+0.5), (int)(b*255.0+0.5));
} }
if (specType.tqfind("hsb", false) == 0) { if (specType.find("hsb", false) == 0) {
bool ok; bool ok;
double h = colorSpec.section(' ', 1, 1).toDouble(&ok); double h = colorSpec.section(' ', 1, 1).toDouble(&ok);
@ -156,7 +156,7 @@ TQColor dviRenderer::parseColorSpecification(const TQString& colorSpec)
return TQColor((int)(h*359.0+0.5), (int)(s*255.0+0.5), (int)(b*255.0+0.5), TQColor::Hsv); return TQColor((int)(h*359.0+0.5), (int)(s*255.0+0.5), (int)(b*255.0+0.5), TQColor::Hsv);
} }
if (specType.tqfind("cmyk", false) == 0) { if (specType.find("cmyk", false) == 0) {
bool ok; bool ok;
double c = colorSpec.section(' ', 1, 1).toDouble(&ok); double c = colorSpec.section(' ', 1, 1).toDouble(&ok);
@ -189,7 +189,7 @@ TQColor dviRenderer::parseColorSpecification(const TQString& colorSpec)
return TQColor((int)(r*255.0+0.5), (int)(g*255.0+0.5), (int)(b*255.0+0.5)); return TQColor((int)(r*255.0+0.5), (int)(g*255.0+0.5), (int)(b*255.0+0.5));
} }
if (specType.tqfind("gray", false) == 0) { if (specType.find("gray", false) == 0) {
bool ok; bool ok;
double g = colorSpec.section(' ', 1, 1).toDouble(&ok); double g = colorSpec.section(' ', 1, 1).toDouble(&ok);
@ -200,7 +200,7 @@ TQColor dviRenderer::parseColorSpecification(const TQString& colorSpec)
} }
// Check if the color is one of the known named colors. // Check if the color is one of the known named colors.
TQMap<TQString, TQColor>::Iterator f = namedColors.tqfind(specType); TQMap<TQString, TQColor>::Iterator f = namedColors.find(specType);
if (f != namedColors.end()) if (f != namedColors.end())
return *f; return *f;
@ -254,7 +254,7 @@ void dviRenderer::color_special(const TQString& _cp)
void dviRenderer::html_href_special(const TQString& _cp) void dviRenderer::html_href_special(const TQString& _cp)
{ {
TQString cp = _cp; TQString cp = _cp;
cp.truncate(cp.tqfind('"')); cp.truncate(cp.find('"'));
#ifdef DEBUG_SPECIAL #ifdef DEBUG_SPECIAL
kdDebug(4300) << "HTML-special, href " << cp.latin1() << endl; kdDebug(4300) << "HTML-special, href " << cp.latin1() << endl;
@ -292,10 +292,10 @@ void dviRenderer::source_special(const TQString& cp)
void parse_special_argument(const TQString& strg, const char* argument_name, int* variable) void parse_special_argument(const TQString& strg, const char* argument_name, int* variable)
{ {
int index = strg.tqfind(argument_name); int index = strg.find(argument_name);
if (index >= 0) { if (index >= 0) {
TQString tmp = strg.mid(index + strlen(argument_name)); TQString tmp = strg.mid(index + strlen(argument_name));
index = tmp.tqfind(' '); index = tmp.find(' ');
if (index >= 0) if (index >= 0)
tmp.truncate(index); tmp.truncate(index);
@ -327,7 +327,7 @@ void dviRenderer::epsf_special(const TQString& cp)
// (already the simplifyWhiteSpace() above is wrong). If you have // (already the simplifyWhiteSpace() above is wrong). If you have
// files like this, go away. // files like this, go away.
TQString EPSfilename_orig = include_command; TQString EPSfilename_orig = include_command;
EPSfilename_orig.truncate(EPSfilename_orig.tqfind(' ')); EPSfilename_orig.truncate(EPSfilename_orig.find(' '));
// Strip enclosing quotation marks which are included by some LaTeX // Strip enclosing quotation marks which are included by some LaTeX
// macro packages (but not by others). This probably means that // macro packages (but not by others). This probably means that
@ -348,7 +348,7 @@ void dviRenderer::epsf_special(const TQString& cp)
int angle = 0; int angle = 0;
// just to avoid ambiguities; the filename could contain keywords // just to avoid ambiguities; the filename could contain keywords
include_command = include_command.mid(include_command.tqfind(' ')); include_command = include_command.mid(include_command.find(' '));
parse_special_argument(include_command, "llx=", &llx); parse_special_argument(include_command, "llx=", &llx);
parse_special_argument(include_command, "lly=", &lly); parse_special_argument(include_command, "lly=", &lly);

@ -735,7 +735,7 @@ void TopLevel::printIt( KPrinter &printer, TQPainter &painter )
++currentpage; ++currentpage;
// should this page be printed ? // should this page be printed ?
if (printer.pageList().tqfindIndex(currentpage) < 0) if (printer.pageList().findIndex(currentpage) < 0)
continue; continue;
XImage *Image = Pimage(pn); XImage *Image = Pimage(pn);

@ -118,7 +118,7 @@ int main(int argc, char** argv)
QCStringList apps = app.dcopClient()->registeredApplications(); QCStringList apps = app.dcopClient()->registeredApplications();
for ( QCStringList::Iterator it = apps.begin(); it != apps.end(); ++it ) for ( QCStringList::Iterator it = apps.begin(); it != apps.end(); ++it )
{ {
if ((*it).tqfind("kviewshell") == 0) if ((*it).find("kviewshell") == 0)
{ {
TQByteArray data, replyData; TQByteArray data, replyData;
TQCString replyType; TQCString replyType;

@ -234,7 +234,7 @@ bool GSCreator::create(const TQString &path, int width, int height, TQImage &img
} }
const bool is_encapsulated = no_dvi && const bool is_encapsulated = no_dvi &&
(path.tqfind(TQRegExp("\\.epsi?$", false, false)) > 0) && (path.find(TQRegExp("\\.epsi?$", false, false)) > 0) &&
(dsc.bbox()->width() > 0) && (dsc.bbox()->height() > 0) && (dsc.bbox()->width() > 0) && (dsc.bbox()->height() > 0) &&
(dsc.page_count() <= 1); (dsc.page_count() <= 1);

@ -143,8 +143,8 @@ bool KRgbPlugin::readInfo(KFileMetaInfo& info, uint /*what*/)
TQMap<TQ_UINT32, uint>::Iterator end = map.end(); TQMap<TQ_UINT32, uint>::Iterator end = map.end();
for (k = 0; k < (ysize * zsize); k++) { for (k = 0; k < (ysize * zsize); k++) {
dstream >> offs; dstream >> offs;
if ((it = map.tqfind(offs)) != end) if ((it = map.find(offs)) != end)
map.tqreplace(offs, it.data() + 1); map.replace(offs, it.data() + 1);
else else
map[offs] = 0; map[offs] = 0;
} }

@ -248,7 +248,7 @@ bool KTiffPlugin::readInfo(KFileMetaInfo& info, uint)
int imageBpp = bitsPerSample*samplesPerPixel; int imageBpp = bitsPerSample*samplesPerPixel;
if (imageAlpha && colorMode==PHOTOMETRIC_RGB) if (imageAlpha && colorMode==PHOTOMETRIC_RGB)
m_colorMode.tqreplace(PHOTOMETRIC_RGB, new TQString(I18N_NOOP("RGBA"))); m_colorMode.replace(PHOTOMETRIC_RGB, new TQString(I18N_NOOP("RGBA")));
KFileMetaInfoGroup group = appendGroup(info, "General"); KFileMetaInfoGroup group = appendGroup(info, "General");
if (description) if (description)

@ -85,13 +85,13 @@ KGVPart::KGVPart( TQWidget* parentWidget, const char*,
_isGuiInitialized( false ), _isGuiInitialized( false ),
_isFileDirty( false ), _isFileDirty( false ),
_stickyOptions( false ), _stickyOptions( false ),
_embeddedInKGhostView( !args.tqcontains( "KParts::ReadOnlyPart" ) ), _embeddedInKGhostView( !args.contains( "KParts::ReadOnlyPart" ) ),
_customZoomIndex( -1 ) _customZoomIndex( -1 )
{ {
setInstance( KGVFactory::instance() ); setInstance( KGVFactory::instance() );
// Don't show the progress info dialog if we're embedded in Konqueror. // Don't show the progress info dialog if we're embedded in Konqueror.
setProgressInfoEnabled( !args.tqcontains( "Browser/View") ); setProgressInfoEnabled( !args.contains( "Browser/View") );
_document = new KGVDocument( this ); _document = new KGVDocument( this );
connect( _document, TQT_SIGNAL( fileChangeFailed() ), connect( _document, TQT_SIGNAL( fileChangeFailed() ),
@ -582,7 +582,7 @@ void KGVPart::updateZoomActions()
first != last; first != last;
++first ) { ++first ) {
TQString cur = *first; TQString cur = *first;
cur.remove( cur.tqfind( '%' ), 1 ); cur.remove( cur.find( '%' ), 1 );
cur = cur.simplifyWhiteSpace(); cur = cur.simplifyWhiteSpace();
bool ok = false; bool ok = false;
double z = cur.toDouble(&ok); double z = cur.toDouble(&ok);
@ -682,7 +682,7 @@ void KGVPart::openURLContinue()
// mimetype-determination (e.g. koffice) // mimetype-determination (e.g. koffice)
TQString extension; TQString extension;
TQString fileName = m_url.fileName(); TQString fileName = m_url.fileName();
int extensionPos = fileName.tqfindRev( '.' ); int extensionPos = fileName.findRev( '.' );
if( extensionPos != -1 ) if( extensionPos != -1 )
extension = fileName.mid( extensionPos ); // keep the '.' extension = fileName.mid( extensionPos ); // keep the '.'
KTempFile tempFile( TQString(), extension ); KTempFile tempFile( TQString(), extension );
@ -901,7 +901,7 @@ void KGVPart::slotZoom( const TQString& nz )
{ {
TQString z = nz; TQString z = nz;
double zoom; double zoom;
z.remove( z.tqfind( '%' ), 1 ); z.remove( z.find( '%' ), 1 );
zoom = KGlobal::locale()->readNumber( z ) / 100; zoom = KGlobal::locale()->readNumber( z ) / 100;
kdDebug( 4500 ) << "ZOOM = " << nz << ", setting zoom = " << zoom << endl; kdDebug( 4500 ) << "ZOOM = " << nz << ", setting zoom = " << zoom << endl;
@ -968,7 +968,7 @@ void KGVPart::setDisplayOptions( const DisplayOptions& options )
_docManager->setDisplayOptions( options ); _docManager->setDisplayOptions( options );
_selectOrientation->setCurrentItem( options.overrideOrientation() ); _selectOrientation->setCurrentItem( options.overrideOrientation() );
TQStringList medias = document()->mediaNames(); TQStringList medias = document()->mediaNames();
TQStringList::Iterator now = medias.tqfind( options.overridePageMedia() ); TQStringList::Iterator now = medias.find( options.overridePageMedia() );
if ( now != medias.end() ){ if ( now != medias.end() ){
// The options are displayed in inverted order. // The options are displayed in inverted order.
// Therefore, size() - index gets you the display index // Therefore, size() - index gets you the display index

@ -269,7 +269,7 @@ void KColorGrid::setColor( int colNum, uint col, bool update )
return; return;
//kdDebug(4640) << "KColorGrid::setColor - before adding" << endl; //kdDebug(4640) << "KColorGrid::setColor - before adding" << endl;
if(!numcolors.tqcontains(col)) if(!numcolors.contains(col))
{ {
//kdDebug(4640) << "KColorGrid::setColor() - adding " << // col << " - " << tqRed(col) << " " << tqGreen(col) << " " << tqBlue(col) << endl; //kdDebug(4640) << "KColorGrid::setColor() - adding " << // col << " - " << tqRed(col) << " " << tqGreen(col) << " " << tqBlue(col) << endl;
numcolors.append(col); numcolors.append(col);
@ -279,9 +279,9 @@ void KColorGrid::setColor( int colNum, uint col, bool update )
} }
//kdDebug(4640) << "KColorGrid::setColor - before removing" << endl; //kdDebug(4640) << "KColorGrid::setColor - before removing" << endl;
if(!gridcolors.tqcontains(oldcolor)) if(!gridcolors.contains(oldcolor))
{ {
int idx = numcolors.tqfind(oldcolor); int idx = numcolors.find(oldcolor);
if(idx != -1) if(idx != -1)
{ {
//kdDebug(4640) << "KColorGrid::setColor() - removing " << // oldcolor << " - " << tqRed(oldcolor) << " " << tqGreen(oldcolor) << " " << tqBlue(oldcolor) << endl; //kdDebug(4640) << "KColorGrid::setColor() - removing " << // oldcolor << " - " << tqRed(oldcolor) << " " << tqGreen(oldcolor) << " " << tqBlue(oldcolor) << endl;
@ -317,7 +317,7 @@ void KColorGrid::updateColors()
for(int i = 0; i < (int)gridcolors.size(); i++) for(int i = 0; i < (int)gridcolors.size(); i++)
{ {
uint col = gridcolors.at(i); uint col = gridcolors.at(i);
if(!numcolors.tqcontains(col)) if(!numcolors.contains(col))
numcolors.append(col); numcolors.append(col);
} }
emit colorschanged(numcolors.size(), numcolors.data()); emit colorschanged(numcolors.size(), numcolors.data());

@ -56,7 +56,7 @@ public:
bool hasGrid() { return hasgrid; } bool hasGrid() { return hasgrid; }
uint numColors() { return numcolors.size(); } uint numColors() { return numcolors.size(); }
uint colors( uint *c ) { c = numcolors.data(); return numcolors.size(); } uint colors( uint *c ) { c = numcolors.data(); return numcolors.size(); }
bool tqcontains(uint c) { return numcolors.tqcontains(c); } bool contains(uint c) { return numcolors.contains(c); }
uint colorAt(int idx) { return gridcolors.at(idx); } uint colorAt(int idx) { return gridcolors.at(idx); }
uint *data() {return numcolors.data(); } uint *data() {return numcolors.data(); }
void fill(uint color); void fill(uint color);

@ -119,7 +119,7 @@ void KCustomColors::mouseDoubleClickEvent(TQMouseEvent *e)
void KCustomColors::addColor(uint c) void KCustomColors::addColor(uint c)
{ {
if(!tqcontains(c)) if(!contains(c))
{ {
int f = getFreeCell(); int f = getFreeCell();
if(f != -1) if(f != -1)

@ -1179,7 +1179,7 @@ TQImage KIconEditGrid::getSelection(bool cut)
{ {
int x = pntarray[i].x(); int x = pntarray[i].x();
int y = pntarray[i].y(); int y = pntarray[i].y();
if(img->valid(x, y) && rect.tqcontains(TQPoint(x, y))) if(img->valid(x, y) && rect.contains(TQPoint(x, y)))
{ {
*((uint*)tmp.scanLine(y-ny) + (x-nx)) = *((uint*)img->scanLine(y) + x); *((uint*)tmp.scanLine(y-ny) + (x-nx)) = *((uint*)img->scanLine(y) + x);
if(cut) if(cut)
@ -1909,7 +1909,7 @@ void KIconEditGrid::drawPointArray(TQPointArray a, DrawAction action)
int x = a[i].x(); int x = a[i].x();
int y = a[i].y(); int y = a[i].y();
if(img->valid(x, y) && TQT_TQRECT_OBJECT(a.boundingRect()).tqcontains(a[ i ])) if(img->valid(x, y) && TQT_TQRECT_OBJECT(a.boundingRect()).contains(a[ i ]))
{ {
//kdDebug(4640) << "x: " << x << " - y: " << y << endl; //kdDebug(4640) << "x: " << x << " - y: " << y << endl;
switch( action ) switch( action )
@ -2195,7 +2195,7 @@ void KIconEditGrid::mapToKDEPalette()
{ {
if(*l != TRANSPARENT) if(*l != TRANSPARENT)
{ {
if(!iconcolors.tqcontains(*l)) if(!iconcolors.contains(*l))
*l = iconcolors.closestMatch(*l); *l = iconcolors.closestMatch(*l);
} }
} }

@ -112,7 +112,7 @@ void PaletteToolBar::addColors( uint n, uint *c )
void PaletteToolBar::addColor( uint color ) void PaletteToolBar::addColor( uint color )
{ {
if( !m_sysColors->tqcontains( color ) ) if( !m_sysColors->contains( color ) )
m_customColors->addColor( color ); m_customColors->addColor( color );
} }

@ -48,11 +48,11 @@ make install DESTDIR=$RPM_BUILD_ROOT
cd $RPM_BUILD_ROOT cd $RPM_BUILD_ROOT
tqfind . -type d | sed '1,2d;s,^\.,\%attr(-\,root\,root) \%dir ,' > $RPM_BUILD_DIR/file.list.%{name} find . -type d | sed '1,2d;s,^\.,\%attr(-\,root\,root) \%dir ,' > $RPM_BUILD_DIR/file.list.%{name}
tqfind . -type f | sed 's,^\.,\%attr(-\,root\,root) ,' >> $RPM_BUILD_DIR/file.list.%{name} find . -type f | sed 's,^\.,\%attr(-\,root\,root) ,' >> $RPM_BUILD_DIR/file.list.%{name}
tqfind . -type l | sed 's,^\.,\%attr(-\,root\,root) ,' >> $RPM_BUILD_DIR/file.list.%{name} find . -type l | sed 's,^\.,\%attr(-\,root\,root) ,' >> $RPM_BUILD_DIR/file.list.%{name}
%clean %clean
rm -rf $RPM_BUILD_ROOT rm -rf $RPM_BUILD_ROOT

@ -74,9 +74,9 @@ void IndexCleaner::startNext()
TQString dir = m_dirs.first(); TQString dir = m_dirs.first();
m_dirs.pop_front(); m_dirs.pop_front();
int index = cmd.tqfind( "%d" ); int index = cmd.find( "%d" );
if ( index != -1 ) if ( index != -1 )
cmd.tqreplace( index, 2, TQUOTE( dir ) ); cmd.replace( index, 2, TQUOTE( dir ) );
else // no %d? What else can we do? else // no %d? What else can we do?
cmd.append( TQString::tqfromLatin1(" ") + TQUOTE( dir ) ); cmd.append( TQString::tqfromLatin1(" ") + TQUOTE( dir ) );

@ -93,14 +93,14 @@ void Indexer::processNext()
TQString cmd = m_config->addCollectionCommandLine().simplifyWhiteSpace().stripWhiteSpace(); TQString cmd = m_config->addCollectionCommandLine().simplifyWhiteSpace().stripWhiteSpace();
// in the commandline, tqreplace %d with the directory to process and // in the commandline, replace %d with the directory to process and
// %t with the thumbnail dir // %t with the thumbnail dir
int index = cmd.tqfind( "%d" ); // ### TQFile::encodeName()? int index = cmd.find( "%d" ); // ### TQFile::encodeName()?
if ( index != -1 ) if ( index != -1 )
cmd.tqreplace( index, 2, TQUOTE( m_currentDir ) ); cmd.replace( index, 2, TQUOTE( m_currentDir ) );
index = cmd.tqfind( "%t" ); index = cmd.find( "%t" );
if ( index != -1 ) if ( index != -1 )
cmd.tqreplace( index, 2, TQUOTE(m_currentDir + "_thumbnails") ); cmd.replace( index, 2, TQUOTE(m_currentDir + "_thumbnails") );
// qDebug("****** command: %s", cmd.latin1()); // qDebug("****** command: %s", cmd.latin1());
#if KDE_VERSION >= 306 #if KDE_VERSION >= 306

@ -341,7 +341,7 @@ void MainPage::slotRemoveClicked()
void MainPage::enableWidgetsFor( const KMrml::ServerSettings& settings ) void MainPage::enableWidgetsFor( const KMrml::ServerSettings& settings )
{ {
TQString host = settings.host; TQString host = settings.host;
bool enableWidgets = (m_config->hosts().tqfindIndex( host ) > -1); bool enableWidgets = (m_config->hosts().findIndex( host ) > -1);
m_serverWidget->m_addButton->setEnabled(!enableWidgets && !host.isEmpty()); m_serverWidget->m_addButton->setEnabled(!enableWidgets && !host.isEmpty());
m_serverWidget->m_removeButton->setEnabled( enableWidgets && m_serverWidget->m_removeButton->setEnabled( enableWidgets &&
!host.isEmpty() && !host.isEmpty() &&

@ -137,7 +137,7 @@ ServerSettings Config::settingsForHost( const TQString& host ) const
void Config::addSettings( const ServerSettings& settings ) void Config::addSettings( const ServerSettings& settings )
{ {
TQString host = settings.host; TQString host = settings.host;
if ( m_hostList.tqfind( host ) == m_hostList.end() ) if ( m_hostList.find( host ) == m_hostList.end() )
m_hostList.append( host ); m_hostList.append( host );
m_config->setGroup( CONFIG_GROUP ); m_config->setGroup( CONFIG_GROUP );
@ -181,13 +181,13 @@ TQString Config::addCollectionCommandLine() const
m_config->setGroup( CONFIG_GROUP ); m_config->setGroup( CONFIG_GROUP );
TQString cmd = m_config->readEntry( "AddCollection Commandline", TQString cmd = m_config->readEntry( "AddCollection Commandline",
DEFAULT_ADDCOLLECTION_CMD ); DEFAULT_ADDCOLLECTION_CMD );
int index = cmd.tqfind( "%h" ); int index = cmd.find( "%h" );
if ( index != -1 ) if ( index != -1 )
cmd.tqreplace( index, 2, TQUOTE( mrmldDataDir() ) ); cmd.replace( index, 2, TQUOTE( mrmldDataDir() ) );
index = cmd.tqfind( "%e" ); index = cmd.find( "%e" );
if ( index != -1 ) if ( index != -1 )
cmd.tqreplace( index, 2, TQTextCodec::codecForLocale()->mimeName() ); cmd.replace( index, 2, TQTextCodec::codecForLocale()->mimeName() );
return cmd; return cmd;
} }
@ -203,13 +203,13 @@ TQString Config::removeCollectionCommandLine() const
m_config->setGroup( CONFIG_GROUP ); m_config->setGroup( CONFIG_GROUP );
TQString cmd = m_config->readEntry( "RemoveCollection Commandline", TQString cmd = m_config->readEntry( "RemoveCollection Commandline",
DEFAULT_REMOVECOLLECTION_CMD ); DEFAULT_REMOVECOLLECTION_CMD );
int index = cmd.tqfind( "%h" ); int index = cmd.find( "%h" );
if ( index != -1 ) if ( index != -1 )
cmd.tqreplace( index, 2, TQUOTE( mrmldDataDir() ) ); cmd.replace( index, 2, TQUOTE( mrmldDataDir() ) );
index = cmd.tqfind( "%e" ); index = cmd.find( "%e" );
if ( index != -1 ) if ( index != -1 )
cmd.tqreplace( index, 2, TQTextCodec::codecForLocale()->mimeName() ); cmd.replace( index, 2, TQTextCodec::codecForLocale()->mimeName() );
return cmd; return cmd;
} }
@ -231,17 +231,17 @@ TQString Config::mrmldCommandline() const
DEFAULT_MRMLD_CMD ); DEFAULT_MRMLD_CMD );
// add data directory and port to the commandline // add data directory and port to the commandline
int index = cmd.tqfind( "%p" ); int index = cmd.find( "%p" );
if ( index != -1 ) if ( index != -1 )
{ {
TQString port = settings.autoPort ? TQString port = settings.autoPort ?
TQString() : TQString::number( settings.configuredPort ); TQString() : TQString::number( settings.configuredPort );
cmd.tqreplace( index, 2, port ); cmd.replace( index, 2, port );
} }
index = cmd.tqfind( "%d" ); index = cmd.find( "%d" );
if ( index != -1 ) if ( index != -1 )
{ {
cmd.tqreplace( index, 2, TQUOTE( mrmldDataDir() ) ); cmd.replace( index, 2, TQUOTE( mrmldDataDir() ) );
} }
qDebug("***** commandline: %s", cmd.latin1()); qDebug("***** commandline: %s", cmd.latin1());

@ -72,7 +72,7 @@ void Loader::requestDownload( const KURL& url )
void Loader::slotData( KIO::Job *job, const TQByteArray& data ) void Loader::slotData( KIO::Job *job, const TQByteArray& data )
{ {
DownloadIterator it = m_downloads.tqfind( static_cast<KIO::TransferJob*>(job) ); DownloadIterator it = m_downloads.find( static_cast<KIO::TransferJob*>(job) );
if ( it != m_downloads.end() ) { if ( it != m_downloads.end() ) {
TQBuffer& buffer = it.data()->m_buffer; TQBuffer& buffer = it.data()->m_buffer;
if ( !buffer.isOpen() ) if ( !buffer.isOpen() )
@ -90,7 +90,7 @@ void Loader::slotResult( KIO::Job *job )
{ {
KIO::TransferJob *tjob = static_cast<KIO::TransferJob*>( job ); KIO::TransferJob *tjob = static_cast<KIO::TransferJob*>( job );
DownloadIterator it = m_downloads.tqfind( tjob ); DownloadIterator it = m_downloads.find( tjob );
if ( it != m_downloads.end() ) { if ( it != m_downloads.end() ) {
Download *d = it.data(); Download *d = it.data();

@ -194,7 +194,7 @@ bool QueryParadigm::equalMaps( const TQMap<TQString,TQString> m1,
TQMapConstIterator<TQString,TQString> it = m1.begin(); TQMapConstIterator<TQString,TQString> it = m1.begin();
for ( ; it != m1.end(); ++it ) for ( ; it != m1.end(); ++it )
{ {
TQMapConstIterator<TQString,TQString> it2 = m2.tqfind( it.key() ); TQMapConstIterator<TQString,TQString> it2 = m2.find( it.key() );
if ( it2 == m2.end() || it.data() != it2.data() ) if ( it2 == m2.end() || it.data() != it2.data() )
return false; return false;
} }

@ -325,7 +325,7 @@ void MrmlPart::downloadReferenceFiles( const KURL::List& downloadList )
for ( ; it != downloadList.end(); it++ ) for ( ; it != downloadList.end(); it++ )
{ {
TQString extension; TQString extension;
int index = (*it).fileName().tqfindRev( '.' ); int index = (*it).fileName().findRev( '.' );
if ( index != -1 ) if ( index != -1 )
extension = (*it).fileName().mid( index ); extension = (*it).fileName().mid( index );

@ -120,7 +120,7 @@ void MrmlView::clear()
TQPixmap * MrmlView::getPixmap( const KURL& url ) TQPixmap * MrmlView::getPixmap( const KURL& url )
{ {
TQString u = url.url(); TQString u = url.url();
TQPixmap *pix = m_pixmapCache.tqfind( u ); TQPixmap *pix = m_pixmapCache.find( u );
if ( pix ) if ( pix )
return pix; return pix;
@ -130,7 +130,7 @@ TQPixmap * MrmlView::getPixmap( const KURL& url )
p = m_unavailablePixmap; p = m_unavailablePixmap;
m_pixmapCache.insert( u, p ); m_pixmapCache.insert( u, p );
return m_pixmapCache.tqfind( u ); return m_pixmapCache.find( u );
} }
else { // remote url, download with KIO else { // remote url, download with KIO
Loader::self()->requestDownload( url ); Loader::self()->requestDownload( url );

@ -56,11 +56,11 @@ bool Watcher::requireDaemon( const TQCString& clientAppId,
<< ": Client AppID is not registered with DCOP: " << ": Client AppID is not registered with DCOP: "
<< clientAppId << endl; << clientAppId << endl;
DaemonData *daemon = m_daemons.tqfind( daemonKey ); DaemonData *daemon = m_daemons.find( daemonKey );
if ( daemon ) if ( daemon )
{ {
if ( !daemon->apps.tqfind( clientAppId ) ) if ( !daemon->apps.find( clientAppId ) )
daemon->apps.append( clientAppId ); daemon->apps.append( clientAppId );
// timeout, commandline and restart values are: first come, first serve // timeout, commandline and restart values are: first come, first serve
@ -93,7 +93,7 @@ bool Watcher::requireDaemon( const TQCString& clientAppId,
void Watcher::unrequireDaemon( const TQCString& clientAppId, void Watcher::unrequireDaemon( const TQCString& clientAppId,
const TQString& daemonKey ) const TQString& daemonKey )
{ {
unrequireDaemon( m_daemons.tqfind( daemonKey ), clientAppId ); unrequireDaemon( m_daemons.find( daemonKey ), clientAppId );
} }
void Watcher::unrequireDaemon( DaemonData *daemon, void Watcher::unrequireDaemon( DaemonData *daemon,
@ -243,7 +243,7 @@ void Watcher::slotAppUnregistered( const TQCString& appId )
TQDictIterator<DaemonData> it( m_daemons ); TQDictIterator<DaemonData> it( m_daemons );
for ( ; (daemon = it.current()); ++it ) for ( ; (daemon = it.current()); ++it )
{ {
if ( daemon->apps.tqfind( appId ) != -1 ) if ( daemon->apps.find( appId ) != -1 )
unrequireDaemon( daemon, appId ); unrequireDaemon( daemon, appId );
} }
} }

@ -396,7 +396,7 @@ static bool mimeTypeSupportsProperty (const TQString &mimeType,
const TQStringList mimeTypeList = mimeTypesSupportingProperty ( const TQStringList mimeTypeList = mimeTypesSupportingProperty (
property, defaultMimeTypesWithPropertyList); property, defaultMimeTypesWithPropertyList);
return mimeTypeList.tqcontains (mimeType); return mimeTypeList.contains (mimeType);
} }

@ -939,7 +939,7 @@ void kpMainWindow::dropEvent (TQDropEvent *e)
#endif #endif
if (m_thumbnailView && if (m_thumbnailView &&
kpWidgetMapper::toGlobal (m_thumbnailView, m_thumbnailView->rect ()) kpWidgetMapper::toGlobal (m_thumbnailView, m_thumbnailView->rect ())
.tqcontains (globalPos)) .contains (globalPos))
{ {
// TODO: Code will never get executed. // TODO: Code will never get executed.
// Thumbnail doesn't accept drops. // Thumbnail doesn't accept drops.
@ -947,13 +947,13 @@ void kpMainWindow::dropEvent (TQDropEvent *e)
} }
else if (m_mainView && else if (m_mainView &&
kpWidgetMapper::toGlobal (m_mainView, m_mainView->rect ()) kpWidgetMapper::toGlobal (m_mainView, m_mainView->rect ())
.tqcontains (globalPos) && .contains (globalPos) &&
m_scrollView && m_scrollView &&
kpWidgetMapper::toGlobal (m_scrollView, kpWidgetMapper::toGlobal (m_scrollView,
TQRect (0, 0, TQRect (0, 0,
m_scrollView->visibleWidth (), m_scrollView->visibleWidth (),
m_scrollView->visibleHeight ())) m_scrollView->visibleHeight ()))
.tqcontains (globalPos)) .contains (globalPos))
{ {
view = m_mainView; view = m_mainView;
} }
@ -967,7 +967,7 @@ void kpMainWindow::dropEvent (TQDropEvent *e)
// viewUnderCursor() is hacky and can return a view when we aren't // viewUnderCursor() is hacky and can return a view when we aren't
// over one thanks to drags. // over one thanks to drags.
if (m_document && m_document->rect ().tqcontains (docPoint)) if (m_document && m_document->rect ().contains (docPoint))
{ {
selTopLeft = docPoint; selTopLeft = docPoint;

@ -548,7 +548,7 @@ bool kpMainWindow::save (bool localOnly)
{ {
if (m_document->url ().isEmpty () || if (m_document->url ().isEmpty () ||
KImageIO::mimeTypes (KImageIO::Writing) KImageIO::mimeTypes (KImageIO::Writing)
.tqfindIndex (m_document->saveOptions ()->mimeType ()) < 0 || .findIndex (m_document->saveOptions ()->mimeType ()) < 0 ||
// SYNC: kpDocument::getPixmapFromFile() can't determine quality // SYNC: kpDocument::getPixmapFromFile() can't determine quality
// from file so it has been set initially to an invalid value. // from file so it has been set initially to an invalid value.
(m_document->saveOptions ()->mimeTypeHasConfigurableQuality () && (m_document->saveOptions ()->mimeTypeHasConfigurableQuality () &&
@ -639,7 +639,7 @@ KURL kpMainWindow::askForSaveURL (const TQString &caption,
} }
#define MIME_TYPE_IS_VALID() (!fdSaveOptions.mimeTypeIsInvalid () && \ #define MIME_TYPE_IS_VALID() (!fdSaveOptions.mimeTypeIsInvalid () && \
mimeTypes.tqfindIndex (fdSaveOptions.mimeType ()) >= 0) mimeTypes.findIndex (fdSaveOptions.mimeType ()) >= 0)
if (!MIME_TYPE_IS_VALID ()) if (!MIME_TYPE_IS_VALID ())
{ {
#if DEBUG_KP_MAIN_WINDOW #if DEBUG_KP_MAIN_WINDOW
@ -658,9 +658,9 @@ KURL kpMainWindow::askForSaveURL (const TQString &caption,
kdDebug () << "\tmimeType=" << fdSaveOptions.mimeType () kdDebug () << "\tmimeType=" << fdSaveOptions.mimeType ()
<< " not valid, get hardcoded" << endl; << " not valid, get hardcoded" << endl;
#endif #endif
if (mimeTypes.tqfindIndex ("image/png") > -1) if (mimeTypes.findIndex ("image/png") > -1)
fdSaveOptions.setMimeType ("image/png"); fdSaveOptions.setMimeType ("image/png");
else if (mimeTypes.tqfindIndex ("image/x-bmp") > -1) else if (mimeTypes.findIndex ("image/x-bmp") > -1)
fdSaveOptions.setMimeType ("image/x-bmp"); fdSaveOptions.setMimeType ("image/x-bmp");
else else
fdSaveOptions.setMimeType (mimeTypes.first ()); fdSaveOptions.setMimeType (mimeTypes.first ());
@ -964,7 +964,7 @@ void kpMainWindow::sendFilenameToPrinter (KPrinter *printer)
int dot; int dot;
TQString fileName = url.fileName (); TQString fileName = url.fileName ();
dot = fileName.tqfindRev ('.'); dot = fileName.findRev ('.');
// file.ext but not .hidden-file? // file.ext but not .hidden-file?
if (dot > 0) if (dot > 0)

@ -114,7 +114,7 @@ void kpMainWindow::slotHelpTakingScreenshots ()
#if DEBUG_KP_MAIN_WINDOW #if DEBUG_KP_MAIN_WINDOW
kdDebug () << "\tdcopApps=" << dcopApps << endl; kdDebug () << "\tdcopApps=" << dcopApps << endl;
#endif #endif
bool isRunningKDE = (dcopApps.tqfindIndex ("kwin") >= 0); bool isRunningKDE = (dcopApps.findIndex ("kwin") >= 0);
#if 0 #if 0
{ {

@ -404,7 +404,7 @@ void kpMainWindow::zoomTo (int zoomLevel, bool centerUnderCursor)
<< endl; << endl;
#endif #endif
if (vuc->clipRegion ().tqcontains (viewPoint)) if (vuc->clipRegion ().contains (viewPoint))
{ {
const TQPoint globalPoint = const TQPoint globalPoint =
kpWidgetMapper::toGlobal (vuc, viewPoint); kpWidgetMapper::toGlobal (vuc, viewPoint);

@ -490,18 +490,18 @@ int kpSelection::height () const
} }
// public // public
bool kpSelection::tqcontains (const TQPoint &point) const bool kpSelection::contains (const TQPoint &point) const
{ {
TQRect rect = boundingRect (); TQRect rect = boundingRect ();
#if DEBUG_KP_SELECTION && 1 #if DEBUG_KP_SELECTION && 1
kdDebug () << "kpSelection::tqcontains(" << point kdDebug () << "kpSelection::contains(" << point
<< ") rect==" << rect << ") rect==" << rect
<< " #points=" << m_points.size () << " #points=" << m_points.size ()
<< endl; << endl;
#endif #endif
if (!rect.tqcontains (point)) if (!rect.contains (point))
return false; return false;
// OPT: TQRegion is probably incredibly slow - cache // OPT: TQRegion is probably incredibly slow - cache
@ -514,20 +514,20 @@ bool kpSelection::tqcontains (const TQPoint &point) const
case kpSelection::Text: case kpSelection::Text:
return true; return true;
case kpSelection::Ellipse: case kpSelection::Ellipse:
return TQRegion (m_rect, TQRegion::Ellipse).tqcontains (point); return TQRegion (m_rect, TQRegion::Ellipse).contains (point);
case kpSelection::Points: case kpSelection::Points:
// TODO: make this always include the border // TODO: make this always include the border
// (draw up a rect sel in this mode to see what I mean) // (draw up a rect sel in this mode to see what I mean)
return TQRegion (m_points, false/*even-odd algo*/).tqcontains (point); return TQRegion (m_points, false/*even-odd algo*/).contains (point);
default: default:
return false; return false;
} }
} }
// public // public
bool kpSelection::tqcontains (int x, int y) bool kpSelection::contains (int x, int y)
{ {
return tqcontains (TQPoint (x, y)); return contains (TQPoint (x, y));
} }
@ -1000,7 +1000,7 @@ bool kpSelection::pointIsInTextBorderArea (const TQPoint &globalPoint) const
return false; return false;
} }
return (m_rect.tqcontains (globalPoint) && !pointIsInTextArea (globalPoint)); return (m_rect.contains (globalPoint) && !pointIsInTextArea (globalPoint));
} }
// public // public
@ -1012,7 +1012,7 @@ bool kpSelection::pointIsInTextArea (const TQPoint &globalPoint) const
return false; return false;
} }
return textAreaRect ().tqcontains (globalPoint); return textAreaRect ().contains (globalPoint);
} }

@ -127,8 +127,8 @@ public:
// (for non-rectangular selections, may return false even if // (for non-rectangular selections, may return false even if
// kpView::onSelectionResizeHandle()) // kpView::onSelectionResizeHandle())
bool tqcontains (const TQPoint &point) const; bool contains (const TQPoint &point) const;
bool tqcontains (int x, int y); bool contains (int x, int y);
// (Avoid using for text selections since text selection may // (Avoid using for text selections since text selection may

@ -668,7 +668,7 @@ bool kpView::mouseOnSelection (const TQPoint &viewPoint) const
if (!selViewRect.isValid ()) if (!selViewRect.isValid ())
return false; return false;
return selViewRect.tqcontains (mouseViewPoint (viewPoint)); return selViewRect.contains (mouseViewPoint (viewPoint));
} }
@ -874,7 +874,7 @@ int kpView::mouseOnSelectionResizeHandle (const TQPoint &viewPoint) const
#define LOCAL_POINT_IN_BOX_AT(x,y) \ #define LOCAL_POINT_IN_BOX_AT(x,y) \
TQRect ((x), (y), atomicLength, atomicLength).tqcontains (viewPointRelSel) TQRect ((x), (y), atomicLength, atomicLength).contains (viewPointRelSel)
// Favour the bottom & right and the corners. // Favour the bottom & right and the corners.
if (LOCAL_POINT_IN_BOX_AT (selViewRect.width () - atomicLength, if (LOCAL_POINT_IN_BOX_AT (selViewRect.width () - atomicLength,
@ -969,7 +969,7 @@ void kpView::mouseMoveEvent (TQMouseEvent *e)
// TODO: This is wrong if you leaveEvent the mainView by mouseMoving on the // TODO: This is wrong if you leaveEvent the mainView by mouseMoving on the
// mainView, landing on top of the thumbnailView cleverly put on top // mainView, landing on top of the thumbnailView cleverly put on top
// of the mainView. // of the mainView.
setHasMouse (TQT_TQRECT_OBJECT(rect ()).tqcontains (e->pos ())); setHasMouse (TQT_TQRECT_OBJECT(rect ()).contains (e->pos ()));
if (tool ()) if (tool ())
tool ()->mouseMoveEvent (e); tool ()->mouseMoveEvent (e);
@ -1003,7 +1003,7 @@ void kpView::mouseReleaseEvent (TQMouseEvent *e)
<< endl; << endl;
#endif #endif
setHasMouse (TQT_TQRECT_OBJECT(rect ()).tqcontains (e->pos ())); setHasMouse (TQT_TQRECT_OBJECT(rect ()).contains (e->pos ()));
if (tool ()) if (tool ())
tool ()->mouseReleaseEvent (e); tool ()->mouseReleaseEvent (e);

@ -78,7 +78,7 @@ void kpViewManager::registerView (kpView *view)
#if DEBUG_KP_VIEW_MANAGER && 1 #if DEBUG_KP_VIEW_MANAGER && 1
kdDebug () << "kpViewManager::registerView (" << view << ")" << endl; kdDebug () << "kpViewManager::registerView (" << view << ")" << endl;
#endif #endif
if (view && m_views.tqfindRef (view) < 0) if (view && m_views.findRef (view) < 0)
{ {
#if DEBUG_KP_VIEW_MANAGER && 1 #if DEBUG_KP_VIEW_MANAGER && 1
kdDebug () << "\tadded view" << endl; kdDebug () << "\tadded view" << endl;
@ -469,7 +469,7 @@ kpView *kpViewManager::viewUnderCursor (bool usingTQt) const
{ {
kpViewManager *nonConstThis = const_cast <kpViewManager *> (this); kpViewManager *nonConstThis = const_cast <kpViewManager *> (this);
if (m_viewUnderCursor && nonConstThis->m_views.tqfindRef (m_viewUnderCursor) < 0) if (m_viewUnderCursor && nonConstThis->m_views.findRef (m_viewUnderCursor) < 0)
{ {
kdError () << "kpViewManager::viewUnderCursor(): invalid view" << endl; kdError () << "kpViewManager::viewUnderCursor(): invalid view" << endl;
nonConstThis->m_viewUnderCursor = 0; nonConstThis->m_viewUnderCursor = 0;

@ -898,23 +898,23 @@ void kpViewScrollableContainer::recalculateStatusMessage ()
// //
if (kpWidgetMapper::toGlobal (this, if (kpWidgetMapper::toGlobal (this,
TQRect (0, 0, visibleWidth (), visibleHeight ())) TQRect (0, 0, visibleWidth (), visibleHeight ()))
.tqcontains (TQCursor::pos ())) .contains (TQCursor::pos ()))
{ {
if (m_bottomRightGrip->isShown () && if (m_bottomRightGrip->isShown () &&
m_bottomRightGrip->hotRect (true/*to global*/) m_bottomRightGrip->hotRect (true/*to global*/)
.tqcontains (TQCursor::pos ())) .contains (TQCursor::pos ()))
{ {
m_bottomRightGrip->setUserMessage (i18n ("Left drag the handle to resize the image.")); m_bottomRightGrip->setUserMessage (i18n ("Left drag the handle to resize the image."));
} }
else if (m_bottomGrip->isShown () && else if (m_bottomGrip->isShown () &&
m_bottomGrip->hotRect (true/*to global*/) m_bottomGrip->hotRect (true/*to global*/)
.tqcontains (TQCursor::pos ())) .contains (TQCursor::pos ()))
{ {
m_bottomGrip->setUserMessage (i18n ("Left drag the handle to resize the image.")); m_bottomGrip->setUserMessage (i18n ("Left drag the handle to resize the image."));
} }
else if (m_rightGrip->isShown () && else if (m_rightGrip->isShown () &&
m_rightGrip->hotRect (true/*to global*/) m_rightGrip->hotRect (true/*to global*/)
.tqcontains (TQCursor::pos ())) .contains (TQCursor::pos ()))
{ {
m_rightGrip->setUserMessage (i18n ("Left drag the handle to resize the image.")); m_rightGrip->setUserMessage (i18n ("Left drag the handle to resize the image."));
} }
@ -1119,7 +1119,7 @@ bool kpViewScrollableContainer::beginDragScroll (const TQPoint &/*docPoint*/,
bool stopDragScroll = true; bool stopDragScroll = true;
bool scrolled = false; bool scrolled = false;
if (!noDragScrollRect ().tqcontains (p)) if (!noDragScrollRect ().contains (p))
{ {
if (m_dragScrollTimer->isActive ()) if (m_dragScrollTimer->isActive ())
{ {

@ -196,7 +196,7 @@ bool kpFloodFill::prepare ()
kdDebug () << "\tperforming NOP check" << endl; kdDebug () << "\tperforming NOP check" << endl;
#endif #endif
// get the color we need to tqreplace // get the color we need to replace
if (m_processedColorSimilarity == 0 && m_color == m_colorToChange) if (m_processedColorSimilarity == 0 && m_color == m_colorToChange)
{ {
// need to do absolutely nothing (this is a significant optimisation // need to do absolutely nothing (this is a significant optimisation

@ -34,7 +34,7 @@
// at the other extreme would not be deemed similar enough. The // at the other extreme would not be deemed similar enough. The
// key is to find the median color as the reference but how do // key is to find the median color as the reference but how do
// you do this if you don't know which pixels to sample in the first // you do this if you don't know which pixels to sample in the first
// place (that's what you're trying to tqfind)? Chicken and egg situation. // place (that's what you're trying to find)? Chicken and egg situation.
// //
// The other heuristic that is in doubt is the use of the average // The other heuristic that is in doubt is the use of the average
// color in determining the similarity of sides (it is possible // color in determining the similarity of sides (it is possible

@ -266,7 +266,7 @@ void kpToolPen::hover (const TQPoint &point)
} }
#if DEBUG_KP_TOOL_PEN && 0 #if DEBUG_KP_TOOL_PEN && 0
if (document ()->rect ().tqcontains (point)) if (document ()->rect ().contains (point))
{ {
TQImage image = kpPixmapFX::convertToImage (*document ()->pixmap ()); TQImage image = kpPixmapFX::convertToImage (*document ()->pixmap ());
@ -538,7 +538,7 @@ void kpToolPen::draw (const TQPoint &thisPoint, const TQPoint &lastPoint, const
bool didSomething = wash (&painter, &maskPainter, bool didSomething = wash (&painter, &maskPainter,
image, image,
color (1 - m_mouseButton)/*color to tqreplace*/, color (1 - m_mouseButton)/*color to replace*/,
rect, rect); rect, rect);
if (painter.isActive ()) if (painter.isActive ())

@ -141,7 +141,7 @@ TQString kpToolSelection::haventBegunDrawUserMessage () const
else else
return i18n ("Left drag to scale selection."); return i18n ("Left drag to scale selection.");
} }
else if (sel && sel->tqcontains (m_currentPoint)) else if (sel && sel->contains (m_currentPoint))
{ {
if (m_mode == Text) if (m_mode == Text)
{ {
@ -300,7 +300,7 @@ void kpToolSelection::beginDraw ()
} }
viewManager ()->restoreQueueUpdates (); viewManager ()->restoreQueueUpdates ();
} }
else if (sel->tqcontains (m_currentPoint)) else if (sel->contains (m_currentPoint))
{ {
if (m_mode == Text && onSelectionToSelectText () && !controlOrShiftPressed ()) if (m_mode == Text && onSelectionToSelectText () && !controlOrShiftPressed ())
{ {
@ -408,7 +408,7 @@ const TQCursor &kpToolSelection::cursor () const
return TQt::arrowCursor; return TQt::arrowCursor;
} }
else if (sel && sel->tqcontains (m_currentPoint)) else if (sel && sel->contains (m_currentPoint))
{ {
#if DEBUG_KP_TOOL_SELECTION && 1 #if DEBUG_KP_TOOL_SELECTION && 1
kdDebug () << "\tsel contains currentPoint; selecting text? " kdDebug () << "\tsel contains currentPoint; selecting text? "

@ -203,8 +203,8 @@ TQRect kpDualColorButton::backgroundRect () const
// protected virtual [base TQWidget] // protected virtual [base TQWidget]
void kpDualColorButton::dragMoveEvent (TQDragMoveEvent *e) void kpDualColorButton::dragMoveEvent (TQDragMoveEvent *e)
{ {
e->accept ((foregroundRect ().tqcontains (e->pos ()) || e->accept ((foregroundRect ().contains (e->pos ()) ||
backgroundRect ().tqcontains (e->pos ())) && backgroundRect ().contains (e->pos ())) &&
KColorDrag::canDecode (e)); KColorDrag::canDecode (e));
} }
@ -216,9 +216,9 @@ void kpDualColorButton::dropEvent (TQDropEvent *e)
if (col.isValid ()) if (col.isValid ())
{ {
if (foregroundRect ().tqcontains (e->pos ())) if (foregroundRect ().contains (e->pos ()))
setForegroundColor (kpColor (col.rgb ())); setForegroundColor (kpColor (col.rgb ()));
else if (backgroundRect ().tqcontains (e->pos ())) else if (backgroundRect ().contains (e->pos ()))
setBackgroundColor (kpColor (col.rgb ())); setBackgroundColor (kpColor (col.rgb ()));
} }
} }
@ -235,9 +235,9 @@ void kpDualColorButton::mouseDoubleClickEvent (TQMouseEvent *e)
{ {
int whichColor = -1; int whichColor = -1;
if (foregroundRect ().tqcontains (e->pos ())) if (foregroundRect ().contains (e->pos ()))
whichColor = 0; whichColor = 0;
else if (backgroundRect ().tqcontains (e->pos ())) else if (backgroundRect ().contains (e->pos ()))
whichColor = 1; whichColor = 1;
if (whichColor == 0 || whichColor == 1) if (whichColor == 0 || whichColor == 1)
@ -266,7 +266,7 @@ void kpDualColorButton::mouseDoubleClickEvent (TQMouseEvent *e)
// protected virtual [base TQWidget] // protected virtual [base TQWidget]
void kpDualColorButton::mouseReleaseEvent (TQMouseEvent *e) void kpDualColorButton::mouseReleaseEvent (TQMouseEvent *e)
{ {
if (swapPixmapRect ().tqcontains (e->pos ()) && if (swapPixmapRect ().contains (e->pos ()) &&
m_color [0] != m_color [1]) m_color [0] != m_color [1])
{ {
#if DEBUG_KP_COLOR_TOOL_BAR && 1 #if DEBUG_KP_COLOR_TOOL_BAR && 1
@ -783,7 +783,7 @@ void kpTransparentColorCell::mousePressEvent (TQMouseEvent * /*e*/)
// protected virtual [base TQWidget] // protected virtual [base TQWidget]
void kpTransparentColorCell::mouseReleaseEvent (TQMouseEvent *e) void kpTransparentColorCell::mouseReleaseEvent (TQMouseEvent *e)
{ {
if (TQT_TQRECT_OBJECT(rect ()).tqcontains (e->pos ())) if (TQT_TQRECT_OBJECT(rect ()).contains (e->pos ()))
{ {
if (e->button () == Qt::LeftButton) if (e->button () == Qt::LeftButton)
{ {

@ -549,7 +549,7 @@ void kpToolWidgetBase::mousePressEvent (TQMouseEvent *e)
{ {
for (int j = 0; j < (int) m_pixmapRects [i].count (); j++) for (int j = 0; j < (int) m_pixmapRects [i].count (); j++)
{ {
if (m_pixmapRects [i][j].tqcontains (e->pos ())) if (m_pixmapRects [i][j].contains (e->pos ()))
{ {
setSelected (i, j); setSelected (i, j);
e->accept (); e->accept ();

@ -176,7 +176,7 @@ void FormatDialog::check_subformat( const TQString & format )
void FormatDialog::setSelectedFormat( TQString fo ) void FormatDialog::setSelectedFormat( TQString fo )
{ {
TQListBoxItem *item = lb_format->tqfindItem( fo ); TQListBoxItem *item = lb_format->findItem( fo );
if( item ) if( item )
{ {
@ -728,7 +728,7 @@ TQString ImgSaver::extension( const KURL& url )
{ {
TQString extension = url.fileName(); TQString extension = url.fileName();
int dotPos = extension.tqfindRev( '.' ); int dotPos = extension.findRev( '.' );
if( dotPos > 0 ) if( dotPos > 0 )
{ {
int len = extension.length(); int len = extension.length();

@ -56,7 +56,7 @@ void ImageNameCombo::slotPathRemove( KFileTreeBranch *branch, const TQString& re
kdDebug(28000) << "ImageNameCombo: Removing " << path << endl; kdDebug(28000) << "ImageNameCombo: Removing " << path << endl;
TQString select = currentText(); TQString select = currentText();
if( items.tqcontains( path )) if( items.contains( path ))
{ {
kdDebug(28000) << "ImageNameCombo: Item exists-> deleting" << endl; kdDebug(28000) << "ImageNameCombo: Item exists-> deleting" << endl;
items.remove( path ); items.remove( path );
@ -74,7 +74,7 @@ void ImageNameCombo::rewriteList( KFileTreeBranch *branch, const TQString& selTe
insertItem( branch->pixmap(), *it ); insertItem( branch->pixmap(), *it );
} }
int index = items.tqfindIndex( selText ); int index = items.findIndex( selText );
setCurrentItem( index ); setCurrentItem( index );
} }

@ -163,7 +163,7 @@ EngineError KadmosDialog::findClassifiers()
if( name.startsWith( "ttf" ) ) if( name.startsWith( "ttf" ) )
{ {
TQString lang = name.mid(3,2); TQString lang = name.mid(3,2);
if( allCountries.tqcontains(lang) ) if( allCountries.contains(lang) )
{ {
TQString lngCountry = locale->twoAlphaToCountryName(lang); TQString lngCountry = locale->twoAlphaToCountryName(lang);
if( lngCountry.isEmpty() ) if( lngCountry.isEmpty() )
@ -188,7 +188,7 @@ EngineError KadmosDialog::findClassifiers()
else if( name.startsWith( "hand" ) ) else if( name.startsWith( "hand" ) )
{ {
TQString lang = name.mid(4,2); TQString lang = name.mid(4,2);
if( allCountries.tqcontains(lang) ) if( allCountries.contains(lang) )
{ {
TQString lngCountry = locale->twoAlphaToCountryName(lang); TQString lngCountry = locale->twoAlphaToCountryName(lang);
if( lngCountry.isEmpty() ) if( lngCountry.isEmpty() )
@ -461,7 +461,7 @@ TQString KadmosDialog::getSelClassifierName() const
/* Get the long text from the combo box */ /* Get the long text from the combo box */
TQString selLang = m_cbLang->currentText(); TQString selLang = m_cbLang->currentText();
TQString trans; TQString trans;
if( fType != "norm" && m_longCountry2short.tqcontains( selLang )) if( fType != "norm" && m_longCountry2short.contains( selLang ))
{ {
TQString langType = m_longCountry2short[selLang]; TQString langType = m_longCountry2short[selLang];
trans = fType+langType+".rec"; trans = fType+langType+".rec";

@ -207,7 +207,7 @@ TQString KookaPreferences::tryFindBinary( const TQString& bin, const TQString& c
if( res != "notFound" ) if( res != "notFound" )
{ {
TQFileInfo fi( res ); TQFileInfo fi( res );
if( fi.exists() && fi.isExecutable() && !fi.isDir() && res.tqcontains(bin) ) if( fi.exists() && fi.isExecutable() && !fi.isDir() && res.contains(bin) )
{ {
return res; return res;
} }
@ -272,7 +272,7 @@ void KookaPreferences::checkOCRBinarySilent( const TQString& cmd )
#endif #endif
bool KookaPreferences::checkOCRBinIntern( const TQString& cmd, const TQString& tool, bool show_msg ) bool KookaPreferences::checkOCRBinIntern( const TQString& cmd, const TQString& tool, bool show_msg )
{ {
if( ! cmd.tqcontains( tool )) return false; if( ! cmd.contains( tool )) return false;
bool ret = true; bool ret = true;
TQFileInfo fi( cmd ); TQFileInfo fi( cmd );

@ -890,7 +890,7 @@ bool KSANEOCR::readORF( const TQString& fileName, TQString& errStr )
{ {
/* Read one line per character */ /* Read one line per character */
TQString charLine = stream.readLine(); TQString charLine = stream.readLine();
int semiPos = charLine.tqfind(';'); int semiPos = charLine.find(';');
if( semiPos == -1 ) if( semiPos == -1 )
{ {
kdDebug(28000) << "invalid line: " << charLine << endl; kdDebug(28000) << "invalid line: " << charLine << endl;
@ -906,7 +906,7 @@ bool KSANEOCR::readORF( const TQString& fileName, TQString& errStr )
// find the amount of alternatives. // find the amount of alternatives.
int altCount = 0; int altCount = 0;
int h = results.tqfind(','); // search the first comma int h = results.find(','); // search the first comma
if( h > -1 ) { if( h > -1 ) {
// kdDebug(28000) << "Results of count search: " << results.left(h) << endl; // kdDebug(28000) << "Results of count search: " << results.left(h) << endl;
altCount = results.left(h).toInt(); altCount = results.left(h).toInt();

@ -75,11 +75,11 @@ void ocrResEdit::slSelectWord( int line, const ocrWord& word )
if( line < paragraphs() ) if( line < paragraphs() )
{ {
TQString editLine = text(line); TQString editLine = text(line);
int cnt = editLine.tqcontains( word); int cnt = editLine.contains( word);
if( cnt > 0 ) if( cnt > 0 )
{ {
int pos = editLine.tqfind(word); int pos = editLine.find(word);
setCursorPosition( line, pos ); setCursorPosition( line, pos );
setSelection( line, pos, line, pos + word.length()); setSelection( line, pos, line, pos + word.length());
} }
@ -96,11 +96,11 @@ void ocrResEdit::slReplaceWord( int line, const TQString& wordFrom,
if( line < paragraphs() ) if( line < paragraphs() )
{ {
TQString editLine = text(line); TQString editLine = text(line);
int cnt = editLine.tqcontains( wordFrom ); int cnt = editLine.contains( wordFrom );
if( cnt > 0 ) if( cnt > 0 )
{ {
int pos = editLine.tqfind(wordFrom); int pos = editLine.find(wordFrom);
setSelection( line, pos, line, pos+wordFrom.length()); setSelection( line, pos, line, pos+wordFrom.length());
TQColor saveCol = this->color(); TQColor saveCol = this->color();

@ -76,7 +76,7 @@ TQStringList ocrWordList::stringList()
* decided. Solution: KSpell should treat dash-linked words correctly. * decided. Solution: KSpell should treat dash-linked words correctly.
* We live with the problem here that dashes bring confusion ;-) * We live with the problem here that dashes bring confusion ;-)
*/ */
if( (*it).tqcontains( rx ) ) if( (*it).contains( rx ) )
res += TQStringList::split( rx, (*it) ); res += TQStringList::split( rx, (*it) );
else else
#endif #endif
@ -95,9 +95,9 @@ bool ocrWordList::updateOCRWord( const TQString& from, const TQString& to )
{ {
TQString word = (*it); TQString word = (*it);
kdDebug(28000) << "updateOCRWord in list: Comparing word " << word << endl; kdDebug(28000) << "updateOCRWord in list: Comparing word " << word << endl;
if( word.tqcontains( from, true ) ) // case sensitive search if( word.contains( from, true ) ) // case sensitive search
{ {
word.tqreplace( from, to ); word.replace( from, to );
*it = ocrWord( word ); *it = ocrWord( word );
res = true; res = true;
break; break;

@ -420,7 +420,7 @@ TQString ScanPackager::itemDirectory( const KFileTreeViewItem* item, bool relati
if( ! item->isDir() ) if( ! item->isDir() )
{ {
// Cut off the filename in case it is not a dir // Cut off the filename in case it is not a dir
relativUrl.truncate( relativUrl.tqfindRev( '/' )+1); relativUrl.truncate( relativUrl.findRev( '/' )+1);
} }
else else
{ {
@ -464,7 +464,7 @@ void ScanPackager::slotSelectDirectory( const TQString & dirString )
kdDebug(28000) << "Trying to decode directory string " << dirString << endl; kdDebug(28000) << "Trying to decode directory string " << dirString << endl;
TQString searchFor = TQString::tqfromLatin1(" - "); TQString searchFor = TQString::tqfromLatin1(" - ");
int pos = dirString.tqfind( searchFor ); int pos = dirString.find( searchFor );
if( pos > -1 ) if( pos > -1 )
{ {

@ -145,7 +145,7 @@ bool KPDFDocument::openDocument( const TQString & docFile, const KURL & url, con
// determine the related "xml document-info" filename // determine the related "xml document-info" filename
d->url = url; d->url = url;
d->docFileName = docFile; d->docFileName = docFile;
TQString fn = docFile.tqcontains('/') ? docFile.section('/', -1, -1) : docFile; TQString fn = docFile.contains('/') ? docFile.section('/', -1, -1) : docFile;
fn = "kpdf/" + TQString::number(fileReadTest.size()) + "." + fn + ".xml"; fn = "kpdf/" + TQString::number(fileReadTest.size()) + "." + fn + ".xml";
fileReadTest.close(); fileReadTest.close();
d->xmlFileName = locateLocal( "data", fn ); d->xmlFileName = locateLocal( "data", fn );
@ -298,7 +298,7 @@ void KPDFDocument::addObserver( DocumentObserver * pObserver )
void KPDFDocument::removeObserver( DocumentObserver * pObserver ) void KPDFDocument::removeObserver( DocumentObserver * pObserver )
{ {
// remove observer from the map. it won't receive notifications anymore // remove observer from the map. it won't receive notifications anymore
if ( d->observers.tqcontains( pObserver->observerId() ) ) if ( d->observers.contains( pObserver->observerId() ) )
{ {
// free observer's pixmap data // free observer's pixmap data
int observerId = pObserver->observerId(); int observerId = pObserver->observerId();
@ -633,7 +633,7 @@ bool KPDFDocument::searchText( int searchID, const TQString & text, bool fromSta
return false; return false;
// if searchID search not recorded, create new descriptor and init params // if searchID search not recorded, create new descriptor and init params
if ( !d->searches.tqcontains( searchID ) ) if ( !d->searches.contains( searchID ) )
{ {
RunningSearch * search = new RunningSearch(); RunningSearch * search = new RunningSearch();
search->continueOnPage = -1; search->continueOnPage = -1;
@ -707,7 +707,7 @@ bool KPDFDocument::searchText( int searchID, const TQString & text, bool fromSta
{ {
foundAMatch = true; foundAMatch = true;
s->highlightedPages.append( pageNumber ); s->highlightedPages.append( pageNumber );
if ( !pagesToNotify.tqcontains( pageNumber ) ) if ( !pagesToNotify.contains( pageNumber ) )
pagesToNotify.append( pageNumber ); pagesToNotify.append( pageNumber );
} }
} }
@ -779,7 +779,7 @@ bool KPDFDocument::searchText( int searchID, const TQString & text, bool fromSta
pages_vector[ currentPage ]->setHighlight( searchID, match, color ); pages_vector[ currentPage ]->setHighlight( searchID, match, color );
// ..queue page for notifying changes.. // ..queue page for notifying changes..
if ( !pagesToNotify.tqcontains( currentPage ) ) if ( !pagesToNotify.contains( currentPage ) )
pagesToNotify.append( currentPage ); pagesToNotify.append( currentPage );
// ..move the viewport to show the searched word centered // ..move the viewport to show the searched word centered
@ -860,7 +860,7 @@ bool KPDFDocument::searchText( int searchID, const TQString & text, bool fromSta
{ {
foundAMatch = true; foundAMatch = true;
s->highlightedPages.append( pageNumber ); s->highlightedPages.append( pageNumber );
if ( !pagesToNotify.tqcontains( pageNumber ) ) if ( !pagesToNotify.contains( pageNumber ) )
pagesToNotify.append( pageNumber ); pagesToNotify.append( pageNumber );
} }
} }
@ -884,7 +884,7 @@ bool KPDFDocument::searchText( int searchID, const TQString & text, bool fromSta
bool KPDFDocument::continueSearch( int searchID ) bool KPDFDocument::continueSearch( int searchID )
{ {
// check if searchID is present in runningSearches // check if searchID is present in runningSearches
if ( !d->searches.tqcontains( searchID ) ) if ( !d->searches.contains( searchID ) )
return false; return false;
// start search with cached parameters from last search by searchID // start search with cached parameters from last search by searchID
@ -897,7 +897,7 @@ bool KPDFDocument::continueSearch( int searchID )
void KPDFDocument::resetSearch( int searchID ) void KPDFDocument::resetSearch( int searchID )
{ {
// check if searchID is present in runningSearches // check if searchID is present in runningSearches
if ( !d->searches.tqcontains( searchID ) ) if ( !d->searches.contains( searchID ) )
return; return;
// get previous parameters for search // get previous parameters for search
@ -1074,7 +1074,7 @@ void KPDFDocument::processLink( const KPDFLink * link )
TQString url = browse->url(); TQString url = browse->url();
// fix for #100366, documents with relative links that are the form of http:foo.pdf // fix for #100366, documents with relative links that are the form of http:foo.pdf
if (url.tqfind("http:") == 0 && url.tqfind("http://") == -1 && url.right(4) == ".pdf") if (url.find("http:") == 0 && url.find("http://") == -1 && url.right(4) == ".pdf")
{ {
openRelativeFile(url.mid(5)); openRelativeFile(url.mid(5));
return; return;
@ -1117,7 +1117,7 @@ void KPDFDocument::requestDone( PixmapRequest * req )
break; break;
} }
if ( d->observers.tqcontains( req->id ) ) if ( d->observers.contains( req->id ) )
{ {
// [MEM] 1.2 append memory allocation descriptor to the FIFO // [MEM] 1.2 append memory allocation descriptor to the FIFO
int memoryBytes = 4 * req->width * req->height; int memoryBytes = 4 * req->width * req->height;

@ -423,12 +423,12 @@ bool PDFGenerator::print( KPrinter& printer )
marginBottom = (int)printer.option("kde-margin-bottom").toDouble(); marginBottom = (int)printer.option("kde-margin-bottom").toDouble();
bool forceRasterize = printer.option("kde-kpdf-forceRaster").toInt(); bool forceRasterize = printer.option("kde-kpdf-forceRaster").toInt();
if (ps.tqfind(TQRegExp("w\\d+h\\d+")) == 0) if (ps.find(TQRegExp("w\\d+h\\d+")) == 0)
{ {
// size not supported by TQt, CUPS gives us the size as wWIDTHhHEIGHT, at least on the printers i tester // size not supported by TQt, CUPS gives us the size as wWIDTHhHEIGHT, at least on the printers i tester
// remove the w // remove the w
ps = ps.mid(1); ps = ps.mid(1);
int hPos = ps.tqfind("h"); int hPos = ps.find("h");
paperWidth = ps.left(hPos).toInt(); paperWidth = ps.left(hPos).toInt();
paperHeight = ps.mid(hPos+1).toInt(); paperHeight = ps.mid(hPos+1).toInt();
} }

@ -74,7 +74,7 @@ void KPDFPage::setRotation( int r )
bool KPDFPage::hasPixmap( int id, int width, int height ) const bool KPDFPage::hasPixmap( int id, int width, int height ) const
{ {
if ( !m_pixmaps.tqcontains( id ) ) if ( !m_pixmaps.contains( id ) )
return false; return false;
if ( width == -1 || height == -1 ) if ( width == -1 || height == -1 )
return true; return true;
@ -98,7 +98,7 @@ bool KPDFPage::hasObjectRect( double x, double y ) const
return false; return false;
TQValueList< ObjectRect * >::const_iterator it = m_rects.begin(), end = m_rects.end(); TQValueList< ObjectRect * >::const_iterator it = m_rects.begin(), end = m_rects.end();
for ( ; it != end; ++it ) for ( ; it != end; ++it )
if ( (*it)->tqcontains( x, y ) ) if ( (*it)->contains( x, y ) )
return true; return true;
return false; return false;
} }
@ -190,7 +190,7 @@ const ObjectRect * KPDFPage::hasObject( ObjectRect::ObjectType type, double x, d
{ {
TQValueList< ObjectRect * >::const_iterator it = m_rects.begin(), end = m_rects.end(); TQValueList< ObjectRect * >::const_iterator it = m_rects.begin(), end = m_rects.end();
for ( ; it != end; ++it ) for ( ; it != end; ++it )
if ( (*it)->tqcontains( x, y ) ) if ( (*it)->contains( x, y ) )
if ((*it)->objectType() == type) return *it; if ((*it)->objectType() == type) return *it;
return 0; return 0;
} }
@ -203,7 +203,7 @@ const KPDFPageTransition * KPDFPage::getTransition() const
void KPDFPage::setPixmap( int id, TQPixmap * pixmap ) void KPDFPage::setPixmap( int id, TQPixmap * pixmap )
{ {
if ( m_pixmaps.tqcontains( id ) ) if ( m_pixmaps.contains( id ) )
delete m_pixmaps[id]; delete m_pixmaps[id];
m_pixmaps[id] = pixmap; m_pixmaps[id] = pixmap;
} }
@ -252,7 +252,7 @@ void KPDFPage::setTransition( KPDFPageTransition * transition )
void KPDFPage::deletePixmap( int id ) void KPDFPage::deletePixmap( int id )
{ {
if ( m_pixmaps.tqcontains( id ) ) if ( m_pixmaps.contains( id ) )
{ {
delete m_pixmaps[ id ]; delete m_pixmaps[ id ];
m_pixmaps.remove( id ); m_pixmaps.remove( id );
@ -304,7 +304,7 @@ NormalizedRect::NormalizedRect( const TQRect & r, double xScale, double yScale )
: left( (double)r.left() / xScale ), top( (double)r.top() / yScale ), : left( (double)r.left() / xScale ), top( (double)r.top() / yScale ),
right( (double)r.right() / xScale ), bottom( (double)r.bottom() / yScale ) {} right( (double)r.right() / xScale ), bottom( (double)r.bottom() / yScale ) {}
bool NormalizedRect::tqcontains( double x, double y ) const bool NormalizedRect::contains( double x, double y ) const
{ {
return x >= left && x <= right && y >= top && y <= bottom; return x >= left && x <= right && y >= top && y <= bottom;
} }

@ -32,7 +32,7 @@ class NormalizedRect
NormalizedRect( double l, double t, double r, double b ); NormalizedRect( double l, double t, double r, double b );
NormalizedRect( const TQRect & r, double xScale, double yScale ); NormalizedRect( const TQRect & r, double xScale, double yScale );
bool tqcontains( double x, double y ) const; bool contains( double x, double y ) const;
bool intersects( const NormalizedRect & normRect ) const; bool intersects( const NormalizedRect & normRect ) const;
bool intersects( double l, double t, double r, double b ) const; bool intersects( double l, double t, double r, double b ) const;

@ -151,7 +151,7 @@ Part::Part(TQWidget *parentWidget, const char *widgetName,
connect( m_document, TQT_SIGNAL( openURL(const KURL &) ), this, TQT_SLOT( openURLFromDocument(const KURL &) ) ); connect( m_document, TQT_SIGNAL( openURL(const KURL &) ), this, TQT_SLOT( openURLFromDocument(const KURL &) ) );
connect( m_document, TQT_SIGNAL( close() ), this, TQT_SLOT( close() ) ); connect( m_document, TQT_SIGNAL( close() ), this, TQT_SLOT( close() ) );
if (tqparent && tqparent->tqmetaObject()->slotNames(true).tqcontains("slotQuit()")) if (tqparent && tqparent->tqmetaObject()->slotNames(true).contains("slotQuit()"))
connect( m_document, TQT_SIGNAL( quit() ), tqparent, TQT_SLOT( slotQuit() ) ); connect( m_document, TQT_SIGNAL( quit() ), tqparent, TQT_SLOT( slotQuit() ) );
else else
connect( m_document, TQT_SIGNAL( quit() ), this, TQT_SLOT( cannotQuit() ) ); connect( m_document, TQT_SIGNAL( quit() ), this, TQT_SLOT( cannotQuit() ) );
@ -278,8 +278,8 @@ Part::Part(TQWidget *parentWidget, const char *widgetName,
m_historyNext->setWhatsThis( i18n( "Go to the place you were after" ) ); m_historyNext->setWhatsThis( i18n( "Go to the place you were after" ) );
// Find and other actions // Find and other actions
m_tqfind = KStdAction::find( this, TQT_SLOT( slotFind() ), ac, "tqfind" ); m_find = KStdAction::find( this, TQT_SLOT( slotFind() ), ac, "find" );
m_tqfind->setEnabled( false ); m_find->setEnabled( false );
m_findNext = KStdAction::findNext( this, TQT_SLOT( slotFindNext() ), ac, "find_next" ); m_findNext = KStdAction::findNext( this, TQT_SLOT( slotFindNext() ), ac, "find_next" );
m_findNext->setEnabled( false ); m_findNext->setEnabled( false );
@ -452,7 +452,7 @@ bool Part::openFile()
bool ok = m_document->openDocument( m_file, url(), mime ); bool ok = m_document->openDocument( m_file, url(), mime );
// update one-time actions // update one-time actions
m_tqfind->setEnabled( ok && m_document-> supportsSearching()); m_find->setEnabled( ok && m_document-> supportsSearching());
m_findNext->setEnabled( ok && m_document-> supportsSearching()); m_findNext->setEnabled( ok && m_document-> supportsSearching());
m_saveAs->setEnabled( ok ); m_saveAs->setEnabled( ok );
m_printPreview->setEnabled( ok ); m_printPreview->setEnabled( ok );
@ -552,7 +552,7 @@ bool Part::closeURL()
} }
slotHidePresentation(); slotHidePresentation();
m_tqfind->setEnabled( false ); m_find->setEnabled( false );
m_findNext->setEnabled( false ); m_findNext->setEnabled( false );
m_saveAs->setEnabled( false ); m_saveAs->setEnabled( false );
m_printPreview->setEnabled( false ); m_printPreview->setEnabled( false );

@ -179,7 +179,7 @@ private:
KAction *m_lastPage; KAction *m_lastPage;
KAction *m_historyBack; KAction *m_historyBack;
KAction *m_historyNext; KAction *m_historyNext;
KAction *m_tqfind; KAction *m_find;
KAction *m_findNext; KAction *m_findNext;
KAction *m_saveAs; KAction *m_saveAs;
KAction *m_printPreview; KAction *m_printPreview;

@ -26,7 +26,7 @@ void PagePainter::paintPageOnPainter( const KPDFPage * page, int id, int flags,
TQPixmap * pixmap = 0; TQPixmap * pixmap = 0;
// if a pixmap is present for given id, use it // if a pixmap is present for given id, use it
if ( page->m_pixmaps.tqcontains( id ) ) if ( page->m_pixmaps.contains( id ) )
pixmap = page->m_pixmaps[ id ]; pixmap = page->m_pixmaps[ id ];
// else find the closest match using pixmaps of other IDs (great optim!) // else find the closest match using pixmaps of other IDs (great optim!)

@ -80,7 +80,7 @@ public:
TQRect mouseSelectionRect; TQRect mouseSelectionRect;
TQColor selectionRectColor; TQColor selectionRectColor;
// type ahead tqfind // type ahead find
bool typeAheadActive; bool typeAheadActive;
TQString typeAheadString; TQString typeAheadString;
TQTimer * findTimeoutTimer; TQTimer * findTimeoutTimer;
@ -577,7 +577,7 @@ void PageView::viewportPaintEvent( TQPaintEvent * pe )
// 2) Layer 1: pixmap manipulated areas // 2) Layer 1: pixmap manipulated areas
// 3) Layer 2: paint (blend) transparent selection // 3) Layer 2: paint (blend) transparent selection
if ( !selectionRect.isNull() && selectionRect.intersects( contentsRect ) && if ( !selectionRect.isNull() && selectionRect.intersects( contentsRect ) &&
!selectionRectInternal.tqcontains( contentsRect ) ) !selectionRectInternal.contains( contentsRect ) )
{ {
TQRect blendRect = selectionRectInternal.intersect( contentsRect ); TQRect blendRect = selectionRectInternal.intersect( contentsRect );
// skip rectangles covered by the selection's border // skip rectangles covered by the selection's border
@ -616,7 +616,7 @@ void PageView::viewportPaintEvent( TQPaintEvent * pe )
// 2) Layer 1: opaque manipulated ares (filled / contours) // 2) Layer 1: opaque manipulated ares (filled / contours)
// 3) Layer 2: paint opaque selection // 3) Layer 2: paint opaque selection
if ( !selectionRect.isNull() && selectionRect.intersects( contentsRect ) && if ( !selectionRect.isNull() && selectionRect.intersects( contentsRect ) &&
!selectionRectInternal.tqcontains( contentsRect ) ) !selectionRectInternal.contains( contentsRect ) )
{ {
screenPainter.setPen( tqpalette().active().highlight().dark(110) ); screenPainter.setPen( tqpalette().active().highlight().dark(110) );
screenPainter.drawRect( selectionRect ); screenPainter.drawRect( selectionRect );
@ -1338,7 +1338,7 @@ void PageView::paintItems( TQPainter * p, const TQRect & contentsRect )
outlineGeometry.addCoords( -1, -1, 3, 3 ); outlineGeometry.addCoords( -1, -1, 3, 3 );
// draw the page outline (little black border and 2px shadow) // draw the page outline (little black border and 2px shadow)
if ( !pixmapGeometry.tqcontains( contentsRect ) ) if ( !pixmapGeometry.contains( contentsRect ) )
{ {
int pixmapWidth = pixmapGeometry.width(), int pixmapWidth = pixmapGeometry.width(),
pixmapHeight = pixmapGeometry.height(); pixmapHeight = pixmapGeometry.height();
@ -1513,7 +1513,7 @@ void PageView::updateZoom( ZoomMode newZoomMode )
{ {
case ZoomFixed:{ //ZoomFixed case case ZoomFixed:{ //ZoomFixed case
TQString z = d->aZoom->currentText(); TQString z = d->aZoom->currentText();
newFactor = KGlobal::locale()->readNumber( z.remove( z.tqfind( '%' ), 1 ) ) / 100.0; newFactor = KGlobal::locale()->readNumber( z.remove( z.find( '%' ), 1 ) ) / 100.0;
}break; }break;
case ZoomIn: case ZoomIn:
newFactor += (newFactor > 0.99) ? ( newFactor > 1.99 ? 0.5 : 0.2 ) : 0.1; newFactor += (newFactor > 0.99) ? ( newFactor > 1.99 ? 0.5 : 0.2 ) : 0.1;

@ -242,7 +242,7 @@ void PresentationWidget::mousePressEvent( TQMouseEvent * e )
return; return;
// handle clicking on top-right overlay // handle clicking on top-right overlay
if ( m_overlayGeometry.tqcontains( e->pos() ) ) if ( m_overlayGeometry.contains( e->pos() ) )
{ {
overlayClick( e->pos() ); overlayClick( e->pos() );
return; return;
@ -290,7 +290,7 @@ void PresentationWidget::mouseMoveEvent( TQMouseEvent * e )
if ( e->y() <= (tqgeometry().top() + 1) ) if ( e->y() <= (tqgeometry().top() + 1) )
m_topBar->show(); m_topBar->show();
// handle "dragging the wheel" if clicking on its tqgeometry // handle "dragging the wheel" if clicking on its tqgeometry
else if ( e->state() == Qt::LeftButton && m_overlayGeometry.tqcontains( e->pos() ) ) else if ( e->state() == Qt::LeftButton && m_overlayGeometry.contains( e->pos() ) )
overlayClick( e->pos() ); overlayClick( e->pos() );
} }
} }
@ -963,7 +963,7 @@ const KPDFPageTransition PresentationWidget::defaultTransition( int type ) const
/** ONLY the TRANSITIONS GENERATION function from here on **/ /** ONLY the TRANSITIONS GENERATION function from here on **/
void PresentationWidget::initTransition( const KPDFPageTransition *transition ) void PresentationWidget::initTransition( const KPDFPageTransition *transition )
{ {
// if it's just a 'tqreplace' transition, tqrepaint the screen // if it's just a 'replace' transition, tqrepaint the screen
if ( transition->type() == KPDFPageTransition::Replace ) if ( transition->type() == KPDFPageTransition::Replace )
{ {
update(); update();
@ -1175,7 +1175,7 @@ void PresentationWidget::initTransition( const KPDFPageTransition *transition )
m_transitionDelay = (int)( (totalTime * 1000) / steps ); m_transitionDelay = (int)( (totalTime * 1000) / steps );
} break; } break;
// dissolve: tqreplace 'random' rects // dissolve: replace 'random' rects
case KPDFPageTransition::Dissolve: case KPDFPageTransition::Dissolve:
{ {
const int gridXsteps = 50; const int gridXsteps = 50;

@ -20,7 +20,7 @@ class m_inputDelayTimer;
#define SW_SEARCH_ID 3 #define SW_SEARCH_ID 3
/** /**
* @short A widget for tqfind-as-you-type search. Outputs to the Document. * @short A widget for find-as-you-type search. Outputs to the Document.
* *
* This widget accepts keyboard input and performs a call to findTextAll(..) * This widget accepts keyboard input and performs a call to findTextAll(..)
* in the KPDFDocument class when there are 3 or more chars to search for. * in the KPDFDocument class when there are 3 or more chars to search for.

@ -2057,7 +2057,7 @@ FILE *GlobalParams::findToUnicodeFile(GString *name) {
void parseStyle(TQString& name, int& weight, int& slant, int& width) void parseStyle(TQString& name, int& weight, int& slant, int& width)
{ {
if (name.tqfind("MS-") == 0) name = "MS " + name.remove(0,3); if (name.find("MS-") == 0) name = "MS " + name.remove(0,3);
if (!name.contains('-') && !name.contains(',')) return; if (!name.contains('-') && !name.contains(',')) return;
TQString type = name.section(TQRegExp("[-,]"),-1); TQString type = name.section(TQRegExp("[-,]"),-1);

@ -182,11 +182,11 @@
</rule> </rule>
<rule> <rule>
<class name="Texture"/> <class name="Texture"/>
<tqcontains><class name="Texture"/></tqcontains> <contains><class name="Texture"/></contains>
</rule> </rule>
<rule> <rule>
<class name="InteriorTexture"/> <class name="InteriorTexture"/>
<tqcontains><class name="InteriorTexture"/></tqcontains> <contains><class name="InteriorTexture"/></contains>
</rule> </rule>
</targetclass> </targetclass>
@ -211,16 +211,16 @@
<class name="SolidColor"/> <class name="SolidColor"/>
<class name="ColorList"/> <class name="ColorList"/>
<class name="DensityList"/> <class name="DensityList"/>
<not><tqcontains><group name="Sum"/></tqcontains></not> <not><contains><group name="Sum"/></contains></not>
</rule> </rule>
<rule> <rule>
<class name="Pattern"/> <class name="Pattern"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="Pattern"/> <class name="Pattern"/>
<group name="ListPattern"/> <group name="ListPattern"/>
</tqcontains> </contains>
</not> </not>
<not><after><group name="Map"/></after></not> <not><after><group name="Map"/></after></not>
<not><after><class name="Warp"/></after></not> <not><after><class name="Warp"/></after></not>
@ -236,11 +236,11 @@
<group name="Map"/> <group name="Map"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<group name="Map"/> <group name="Map"/>
<group name="ListPattern"/> <group name="ListPattern"/>
<class name="SolidColor"/> <class name="SolidColor"/>
</tqcontains> </contains>
</not> </not>
<not><before><class name="Pattern"/></before></not> <not><before><class name="Pattern"/></before></not>
</and> </and>
@ -297,15 +297,15 @@
</rule> </rule>
<rule> <rule>
<class name="LooksLike"/> <class name="LooksLike"/>
<not><tqcontains><class name="LooksLike"/></tqcontains></not> <not><contains><class name="LooksLike"/></contains></not>
</rule> </rule>
<rule> <rule>
<class name="ProjectedThrough"/> <class name="ProjectedThrough"/>
<not><tqcontains><class name="ProjectedThrough"/></tqcontains></not> <not><contains><class name="ProjectedThrough"/></contains></not>
</rule> </rule>
<rule> <rule>
<class name="Photons"/> <class name="Photons"/>
<not><tqcontains><class name="Photons"/></tqcontains></not> <not><contains><class name="Photons"/></contains></not>
</rule> </rule>
</targetclass> </targetclass>
@ -420,9 +420,9 @@
<rule> <rule>
<class name="GraphicalObject"/> <class name="GraphicalObject"/>
<not> <not>
<tqcontains> <contains>
<class name="GraphicalObject"/> <class name="GraphicalObject"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
</targetclass> </targetclass>
@ -435,9 +435,9 @@
<rule> <rule>
<class name="GraphicalObject"/> <class name="GraphicalObject"/>
<not> <not>
<tqcontains> <contains>
<class name="GraphicalObject"/> <class name="GraphicalObject"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
</targetclass> </targetclass>
@ -450,9 +450,9 @@
<rule> <rule>
<class name="GraphicalObject"/> <class name="GraphicalObject"/>
<not> <not>
<tqcontains> <contains>
<class name="GraphicalObject"/> <class name="GraphicalObject"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
</targetclass> </targetclass>
@ -485,7 +485,7 @@
<rule> <rule>
<class name="BumpMap"/> <class name="BumpMap"/>
<not> <not>
<tqcontains> <contains>
<class name="BumpMap"/> <class name="BumpMap"/>
<class name="NormalList"/> <class name="NormalList"/>
<class name="Pattern"/> <class name="Pattern"/>
@ -493,31 +493,31 @@
<class name="SlopeMap"/> <class name="SlopeMap"/>
<class name="Warp"/> <class name="Warp"/>
<class name="BlendMapModifiers"/> <class name="BlendMapModifiers"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="NormalList"/> <class name="NormalList"/>
<not> <not>
<tqcontains> <contains>
<class name="BumpMap"/> <class name="BumpMap"/>
<class name="NormalList"/> <class name="NormalList"/>
<class name="Pattern"/> <class name="Pattern"/>
<class name="NormalMap"/> <class name="NormalMap"/>
<class name="SlopeMap"/> <class name="SlopeMap"/>
<class name="Warp"/> <class name="Warp"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="Pattern"/> <class name="Pattern"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="BumpMap"/> <class name="BumpMap"/>
<class name="NormalList"/> <class name="NormalList"/>
<class name="Pattern"/> <class name="Pattern"/>
</tqcontains> </contains>
</not> </not>
<not><after><class name="NormalMap"/></after></not> <not><after><class name="NormalMap"/></after></not>
<not><after><class name="SlopeMap"/></after></not> <not><after><class name="SlopeMap"/></after></not>
@ -534,11 +534,11 @@
<class name="NormalMap"/> <class name="NormalMap"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="BumpMap"/> <class name="BumpMap"/>
<class name="NormalMap"/> <class name="NormalMap"/>
<class name="NormalList"/> <class name="NormalList"/>
</tqcontains> </contains>
</not> </not>
<not><after><class name="SlopeMap"/></after></not> <not><after><class name="SlopeMap"/></after></not>
<not><after><class name="BlendMapModifiers"/></after></not> <not><after><class name="BlendMapModifiers"/></after></not>
@ -549,11 +549,11 @@
<class name="SlopeMap"/> <class name="SlopeMap"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="BumpMap"/> <class name="BumpMap"/>
<class name="SlopeMap"/> <class name="SlopeMap"/>
<class name="NormalList"/> <class name="NormalList"/>
</tqcontains> </contains>
</not> </not>
<not><after><class name="BlendMapModifiers"/></after></not> <not><after><class name="BlendMapModifiers"/></after></not>
<not><after><group name="Transformations"/></after></not> <not><after><group name="Transformations"/></after></not>
@ -563,14 +563,14 @@
<rule> <rule>
<class name="BlendMapModifiers"/> <class name="BlendMapModifiers"/>
<and> <and>
<not><tqcontains><class name="BlendMapModifiers"/></tqcontains></not> <not><contains><class name="BlendMapModifiers"/></contains></not>
<or> <or>
<not> <not>
<tqcontains> <contains>
<class name="BumpMap"/> <class name="BumpMap"/>
<class name="NormalMap"/> <class name="NormalMap"/>
<class name="SlopeMap"/> <class name="SlopeMap"/>
</tqcontains> </contains>
</not> </not>
<after><class name="NormalMap"/></after> <after><class name="NormalMap"/></after>
<after><class name="SlopeMap"/></after> <after><class name="SlopeMap"/></after>
@ -613,17 +613,17 @@
<rule> <rule>
<group name="Color"/> <group name="Color"/>
<group name="ListPattern"/> <group name="ListPattern"/>
<not><tqcontains><group name="Sum"/></tqcontains></not> <not><contains><group name="Sum"/></contains></not>
</rule> </rule>
<rule> <rule>
<class name="Pattern"/> <class name="Pattern"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<group name="Color"/> <group name="Color"/>
<class name="Pattern"/> <class name="Pattern"/>
<group name="ListPattern"/> <group name="ListPattern"/>
</tqcontains> </contains>
</not> </not>
<not><after><group name="Map"/></after></not> <not><after><group name="Map"/></after></not>
<not><after><class name="Warp"/></after></not> <not><after><class name="Warp"/></after></not>
@ -639,11 +639,11 @@
<group name="Map"/> <group name="Map"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<group name="Map"/> <group name="Map"/>
<group name="ListPattern"/> <group name="ListPattern"/>
<group name="Color"/> <group name="Color"/>
</tqcontains> </contains>
</not> </not>
<not><before><class name="Pattern"/></before></not> <not><before><class name="Pattern"/></before></not>
</and> </and>
@ -652,10 +652,10 @@
<class name="BlendMapModifiers"/> <class name="BlendMapModifiers"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="BlendMapModifiers"/> <class name="BlendMapModifiers"/>
<group name="Color"/> <group name="Color"/>
</tqcontains> </contains>
</not> </not>
<not><before><group name="Map"/></before></not> <not><before><group name="Map"/></before></not>
<not><before><class name="Pattern"/></before></not> <not><before><class name="Pattern"/></before></not>
@ -695,18 +695,18 @@
</rule> </rule>
<rule> <rule>
<class name="GlobalSettings"/> <class name="GlobalSettings"/>
<not><tqcontains><class name="GlobalSettings"/></tqcontains></not> <not><contains><class name="GlobalSettings"/></contains></not>
</rule> </rule>
</targetclass> </targetclass>
<targetclass name="GlobalSettings"> <targetclass name="GlobalSettings">
<rule> <rule>
<class name="Radiosity"/> <class name="Radiosity"/>
<not><tqcontains><class name="Radiosity"/></tqcontains></not> <not><contains><class name="Radiosity"/></contains></not>
</rule> </rule>
<rule> <rule>
<class name="GlobalPhotons"/> <class name="GlobalPhotons"/>
<not><tqcontains><class name="GlobalPhotons"/></tqcontains></not> <not><contains><class name="GlobalPhotons"/></contains></not>
</rule> </rule>
</targetclass> </targetclass>
@ -734,56 +734,56 @@
<rule> <rule>
<class name="MaterialMap"/> <class name="MaterialMap"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<group name="SumPigment"/> <group name="SumPigment"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="Pigment"/> <class name="Pigment"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<class name="Pigment"/> <class name="Pigment"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="Normal"/> <class name="Normal"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<class name="Normal"/> <class name="Normal"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="Finish"/> <class name="Finish"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<class name="Finish"/> <class name="Finish"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="Pattern"/> <class name="Pattern"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="Pattern"/> <class name="Pattern"/>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumPigment"/> <group name="SumPigment"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
<not><after><class name="TextureMap"/></after></not> <not><after><class name="TextureMap"/></after></not>
<not><after><class name="Warp"/></after></not> <not><after><class name="Warp"/></after></not>
@ -795,12 +795,12 @@
<class name="TextureMap"/> <class name="TextureMap"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="TextureMap"/> <class name="TextureMap"/>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumPigment"/> <group name="SumPigment"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
<not><before><class name="Pattern"/></before></not> <not><before><class name="Pattern"/></before></not>
<not><after><class name="BlendMapModifiers"/></after></not> <not><after><class name="BlendMapModifiers"/></after></not>
@ -809,12 +809,12 @@
<rule> <rule>
<class name="TextureList"/> <class name="TextureList"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<group name="SumPigment"/> <group name="SumPigment"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
@ -829,10 +829,10 @@
<class name="BlendMapModifiers"/> <class name="BlendMapModifiers"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="MaterialMap"/> <class name="MaterialMap"/>
<class name="BlendMapModifiers"/> <class name="BlendMapModifiers"/>
</tqcontains> </contains>
</not> </not>
<not><before><class name="TextureMap"/></before></not> <not><before><class name="TextureMap"/></before></not>
<not><before><class name="Pattern"/></before></not> <not><before><class name="Pattern"/></before></not>
@ -860,56 +860,56 @@
<rule> <rule>
<class name="MaterialMap"/> <class name="MaterialMap"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<group name="SumPigment"/> <group name="SumPigment"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="Pigment"/> <class name="Pigment"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<class name="Pigment"/> <class name="Pigment"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="Normal"/> <class name="Normal"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<class name="Normal"/> <class name="Normal"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="Finish"/> <class name="Finish"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<class name="Finish"/> <class name="Finish"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
<class name="Pattern"/> <class name="Pattern"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="Pattern"/> <class name="Pattern"/>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumPigment"/> <group name="SumPigment"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
<not><after><class name="TextureMap"/></after></not> <not><after><class name="TextureMap"/></after></not>
<not><after><class name="Warp"/></after></not> <not><after><class name="Warp"/></after></not>
@ -921,12 +921,12 @@
<class name="TextureMap"/> <class name="TextureMap"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="TextureMap"/> <class name="TextureMap"/>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumPigment"/> <group name="SumPigment"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
<not><before><class name="Pattern"/></before></not> <not><before><class name="Pattern"/></before></not>
<not><after><class name="BlendMapModifiers"/></after></not> <not><after><class name="BlendMapModifiers"/></after></not>
@ -935,12 +935,12 @@
<rule> <rule>
<class name="TextureList"/> <class name="TextureList"/>
<not> <not>
<tqcontains> <contains>
<class name="TextureList"/> <class name="TextureList"/>
<group name="SumMap"/> <group name="SumMap"/>
<group name="SumPigment"/> <group name="SumPigment"/>
<class name="MaterialMap"/> <class name="MaterialMap"/>
</tqcontains> </contains>
</not> </not>
</rule> </rule>
<rule> <rule>
@ -955,10 +955,10 @@
<class name="BlendMapModifiers"/> <class name="BlendMapModifiers"/>
<and> <and>
<not> <not>
<tqcontains> <contains>
<class name="MaterialMap"/> <class name="MaterialMap"/>
<class name="BlendMapModifiers"/> <class name="BlendMapModifiers"/>
</tqcontains> </contains>
</not> </not>
<not><before><class name="TextureMap"/></before></not> <not><before><class name="TextureMap"/></before></not>
<not><before><class name="Pattern"/></before></not> <not><before><class name="Pattern"/></before></not>

@ -197,7 +197,7 @@ PMVector PM2DControlPoint::to3D( const PMVector& v ) const
void PM2DControlPoint::addLinkedPoint( PM2DControlPoint* p ) void PM2DControlPoint::addLinkedPoint( PM2DControlPoint* p )
{ {
if( !m_linkedPoints.tqcontainsRef( p ) ) if( !m_linkedPoints.containsRef( p ) )
m_linkedPoints.append( p ); m_linkedPoints.append( p );
} }

@ -186,7 +186,7 @@ void PMAddCommand::undo( PMCommandManager* theManager )
if( decl ) if( decl )
{ {
m_links.append( lit.current( ) ); m_links.append( lit.current( ) );
if( !m_linkedDeclares.tqcontainsRef( decl ) ) if( !m_linkedDeclares.containsRef( decl ) )
m_linkedDeclares.append( decl ); m_linkedDeclares.append( decl );
} }
} }

@ -162,14 +162,14 @@ bool PMDeclareEdit::isDataValid( )
// valid identifer! // valid identifer!
PMReservedWordDict* dict = PMScanner::reservedWords( ); PMReservedWordDict* dict = PMScanner::reservedWords( );
if( dict->tqfind( text.latin1( ) ) != -1 ) if( dict->find( text.latin1( ) ) != -1 )
{ {
KMessageBox::error( this, i18n( "You can't use a povray reserved word" KMessageBox::error( this, i18n( "You can't use a povray reserved word"
" as an identifier!" ), i18n( "Error" ) ); " as an identifier!" ), i18n( "Error" ) );
return false; return false;
} }
dict = PMScanner::directives( ); dict = PMScanner::directives( );
if( dict->tqfind( text.latin1( ) ) != -1 ) if( dict->find( text.latin1( ) ) != -1 )
{ {
KMessageBox::error( this, i18n( "You can't use a povray directive" KMessageBox::error( this, i18n( "You can't use a povray directive"
" as an identifier!" ), i18n( "Error" ) ); " as an identifier!" ), i18n( "Error" ) );
@ -178,7 +178,7 @@ bool PMDeclareEdit::isDataValid( )
// no reserved word // no reserved word
PMSymbolTable* st = part( )->symbolTable( ); PMSymbolTable* st = part( )->symbolTable( );
if( st->tqfind( text ) ) if( st->find( text ) )
{ {
KMessageBox::error( this, i18n( "Please enter a unique identifier!" ), KMessageBox::error( this, i18n( "Please enter a unique identifier!" ),
i18n( "Error" ) ); i18n( "Error" ) );

@ -105,7 +105,7 @@ void PMDeleteCommand::execute( PMCommandManager* theManager )
if( decl ) if( decl )
{ {
m_links.append( oit.current( ) ); m_links.append( oit.current( ) );
if( !m_linkedDeclares.tqcontainsRef( decl ) ) if( !m_linkedDeclares.containsRef( decl ) )
m_linkedDeclares.append( decl ); m_linkedDeclares.append( decl );
} }
} }
@ -232,7 +232,7 @@ int PMDeleteCommand::errorFlags( PMPart* )
for( obj = links.current( ); obj && !insideSelection; for( obj = links.current( ); obj && !insideSelection;
obj = obj->tqparent( ) ) obj = obj->tqparent( ) )
{ {
if( m_deletedObjects.tqfind( obj ) ) if( m_deletedObjects.find( obj ) )
insideSelection = true; insideSelection = true;
} }
@ -241,7 +241,7 @@ int PMDeleteCommand::errorFlags( PMPart* )
bool stop = false; bool stop = false;
for( obj = links.current( ); obj && !stop; obj = obj->tqparent( ) ) for( obj = links.current( ); obj && !stop; obj = obj->tqparent( ) )
{ {
if( m_deletedObjects.tqfind( obj ) ) if( m_deletedObjects.find( obj ) )
stop = true; stop = true;
else else
m_deletedObjects.insert( obj, new bool( true ) ); m_deletedObjects.insert( obj, new bool( true ) );

@ -408,8 +408,8 @@ void PMDialogEditBase::slotTexturePreview( )
{ {
link = rit.current( )->linkedObject( ); link = rit.current( )->linkedObject( );
if( link ) if( link )
if( !neededDeclares.tqcontainsRef( link ) ) if( !neededDeclares.containsRef( link ) )
if( !objectsToSerialize.tqfind( link ) ) if( !objectsToSerialize.find( link ) )
neededDeclares.append( link ); neededDeclares.append( link );
} }
objectsToSerialize.insert( it.current( ), it.current( ) ); objectsToSerialize.insert( it.current( ), it.current( ) );
@ -434,7 +434,7 @@ void PMDialogEditBase::slotTexturePreview( )
{ {
if( otr->type( ) == "Declare" ) if( otr->type( ) == "Declare" )
{ {
if( objectsToSerialize.tqfind( otr ) ) if( objectsToSerialize.find( otr ) )
{ {
dev->serialize( otr ); dev->serialize( otr );
numDeclares--; numDeclares--;
@ -542,7 +542,7 @@ void PMDialogEditBase::slotPreviewFinished( int exitStatus )
"See the povray output for details." ) "See the povray output for details." )
.tqarg( exitStatus ) ); .tqarg( exitStatus ) );
} }
else if( m_pRenderWidget->povrayOutput( ).tqcontains( "ERROR" ) ) else if( m_pRenderWidget->povrayOutput( ).contains( "ERROR" ) )
{ {
KMessageBox::error( this, i18n( "There were errors while rendering.\n" KMessageBox::error( this, i18n( "There were errors while rendering.\n"
"See the povray output for details." ) ); "See the povray output for details." ) );

@ -1464,10 +1464,10 @@ PMDockWidget* PMDockManager::findDockWidgetAt( const TQPoint& pos )
} }
w = p; w = p;
} }
if ( qt_tqfind_obj_child( TQT_TQOBJECT(w), "PMDockSplitter", "_dock_split_" ) ) return 0L; if ( qt_find_obj_child( TQT_TQOBJECT(w), "PMDockSplitter", "_dock_split_" ) ) return 0L;
if ( qt_tqfind_obj_child( TQT_TQOBJECT(w), "PMDockTabGroup", "_dock_tab" ) ) return 0L; if ( qt_find_obj_child( TQT_TQOBJECT(w), "PMDockTabGroup", "_dock_tab" ) ) return 0L;
if (!childDockWidgetList) return 0L; if (!childDockWidgetList) return 0L;
if ( childDockWidgetList->tqfind(w) != -1 ) return 0L; if ( childDockWidgetList->find(w) != -1 ) return 0L;
if ( currentDragWidget->isGroup && ((PMDockWidget*)w)->parentDockTabGroup() ) return 0L; if ( currentDragWidget->isGroup && ((PMDockWidget*)w)->parentDockTabGroup() ) return 0L;
PMDockWidget* www = (PMDockWidget*)w; PMDockWidget* www = (PMDockWidget*)w;
@ -1511,7 +1511,7 @@ void PMDockManager::findChildDockWidget( TQWidget*& ww, const TQWidget* p, const
while ( it.current() ) { while ( it.current() ) {
if ( it.current()->isWidgetType() ) { if ( it.current()->isWidgetType() ) {
w = (TQWidget*)it.current(); w = (TQWidget*)it.current();
if ( w->isVisible() && w->tqgeometry().tqcontains(pos) ) { if ( w->isVisible() && w->tqgeometry().contains(pos) ) {
if ( w->inherits("PMDockWidget") ) ww = w; if ( w->inherits("PMDockWidget") ) ww = w;
findChildDockWidget( ww, w, w->mapFromParent(pos) ); findChildDockWidget( ww, w, w->mapFromParent(pos) );
return; return;
@ -1809,8 +1809,8 @@ void PMDockManager::writeConfig(TQDomElement &base)
nList.first(); nList.first();
while ( nList.current() ) { while ( nList.current() ) {
PMDockWidget *obj = getDockWidgetFromName( nList.current() ); PMDockWidget *obj = getDockWidgetFromName( nList.current() );
if (obj->isGroup && (nameList.tqfind( obj->firstName.latin1() ) == -1 if (obj->isGroup && (nameList.find( obj->firstName.latin1() ) == -1
|| nameList.tqfind(obj->lastName.latin1()) == -1)) { || nameList.find(obj->lastName.latin1()) == -1)) {
// Skip until tqchildren are saved (why?) // Skip until tqchildren are saved (why?)
nList.next(); nList.next();
if ( !nList.current() ) nList.first(); if ( !nList.current() ) nList.first();
@ -2034,7 +2034,7 @@ void PMDockManager::writeConfig( KConfig* c, TQString group )
} }
/*************************************************************************************************/ /*************************************************************************************************/
if ( obj->isGroup ){ if ( obj->isGroup ){
if ( findList.tqfind( obj->firstName.latin1() ) != -1 && findList.tqfind( obj->lastName.latin1() ) != -1 ){ if ( findList.find( obj->firstName.latin1() ) != -1 && findList.find( obj->lastName.latin1() ) != -1 ){
c->writeEntry( cname+":type", "GROUP"); c->writeEntry( cname+":type", "GROUP");
if ( !obj->tqparent() ){ if ( !obj->tqparent() ){
@ -2057,9 +2057,9 @@ void PMDockManager::writeConfig( KConfig* c, TQString group )
} else { } else {
/*************************************************************************************************/ /*************************************************************************************************/
//debug(" Skip %s", nList.current()); //debug(" Skip %s", nList.current());
//if ( findList.tqfind( obj->firstName ) == -1 ) //if ( findList.find( obj->firstName ) == -1 )
// debug(" ? Not found %s", obj->firstName); // debug(" ? Not found %s", obj->firstName);
//if ( findList.tqfind( obj->lastName ) == -1 ) //if ( findList.find( obj->lastName ) == -1 )
// debug(" ? Not found %s", obj->lastName); // debug(" ? Not found %s", obj->lastName);
nList.next(); nList.next();
if ( !nList.current() ) nList.first(); if ( !nList.current() ) nList.first();

@ -30,7 +30,7 @@ KStaticDeleter<PMDocumentationMap> PMDocumentationMap::s_staticDeleter;
TQString PMDocumentationVersion::documentation( const TQString& className ) const TQString PMDocumentationVersion::documentation( const TQString& className ) const
{ {
if( m_map.tqcontains( className ) ) if( m_map.contains( className ) )
return m_map[className]; return m_map[className];
return m_index; return m_index;
} }

@ -40,7 +40,7 @@ TQStringList PMEnumProperty::enumValues( ) const
bool PMEnumProperty::setProtected( PMObject* obj, const PMVariant& v ) bool PMEnumProperty::setProtected( PMObject* obj, const PMVariant& v )
{ {
PMEnumStringValueMap::iterator it = m_stringMap.tqfind( v.stringData( ) ); PMEnumStringValueMap::iterator it = m_stringMap.find( v.stringData( ) );
if( it == m_stringMap.end( ) ) if( it == m_stringMap.end( ) )
return false; return false;
setEnum( obj, it.data( ) ); setEnum( obj, it.data( ) );
@ -50,7 +50,7 @@ bool PMEnumProperty::setProtected( PMObject* obj, const PMVariant& v )
PMVariant PMEnumProperty::getProtected( const PMObject* obj ) PMVariant PMEnumProperty::getProtected( const PMObject* obj )
{ {
int v = getEnum( obj ); int v = getEnum( obj );
PMEnumValueStringMap::const_iterator it = m_valueMap.tqfind( v ); PMEnumValueStringMap::const_iterator it = m_valueMap.find( v );
if( it == m_valueMap.end( ) ) if( it == m_valueMap.end( ) )
return PMVariant( TQString() ); return PMVariant( TQString() );
return it.data( ); return it.data( );

@ -53,7 +53,7 @@ PMErrorDialog::PMErrorDialog( const PMMessageList& messages, int errorFlags,
PMObject* obj = pit.current( )->linkedObject( ); PMObject* obj = pit.current( )->linkedObject( );
for( ; obj; obj = obj->tqparent( ) ) for( ; obj; obj = obj->tqparent( ) )
{ {
TQPtrList<PMMessage>* pList = m_messageDict.tqfind( obj ); TQPtrList<PMMessage>* pList = m_messageDict.find( obj );
if( !pList ) if( !pList )
{ {
pList = new TQPtrList<PMMessage>; pList = new TQPtrList<PMMessage>;

@ -1064,7 +1064,7 @@ PMVector PMGLView::mousePosition( PMControlPoint* cp, int x, int y )
result[1] = screenToInternalY( y ); result[1] = screenToInternalY( y );
if( cp ) if( cp )
{ {
index = m_controlPoints.tqfindRef( cp ); index = m_controlPoints.findRef( cp );
if( index >= 0 ) if( index >= 0 )
{ {
p = m_controlPointsPosition.at( ( uint ) index ); p = m_controlPointsPosition.at( ( uint ) index );

@ -535,7 +535,7 @@ void PMImageMapEdit::slotAddFilterEntry( )
if( button ) if( button )
{ {
int index = m_filterAddButtons.tqfindRef( button ); int index = m_filterAddButtons.findRef( button );
if( index >= 0 ) if( index >= 0 )
{ {
entriesFilters = filters( ); entriesFilters = filters( );
@ -561,7 +561,7 @@ void PMImageMapEdit::slotRemoveFilterEntry( )
if( button ) if( button )
{ {
int index = m_filterRemoveButtons.tqfindRef( button ); int index = m_filterRemoveButtons.findRef( button );
if( index >= 0 ) if( index >= 0 )
{ {
entriesFilters = filters( ); entriesFilters = filters( );
@ -583,7 +583,7 @@ void PMImageMapEdit::slotAddTransmitEntry( )
if( button ) if( button )
{ {
int index = m_transmitAddButtons.tqfindRef( button ); int index = m_transmitAddButtons.findRef( button );
if( index >= 0 ) if( index >= 0 )
{ {
entriesTransmits = transmits( ); entriesTransmits = transmits( );
@ -609,7 +609,7 @@ void PMImageMapEdit::slotRemoveTransmitEntry( )
if( button ) if( button )
{ {
int index = m_transmitRemoveButtons.tqfindRef( button ); int index = m_transmitRemoveButtons.findRef( button );
if( index >= 0 ) if( index >= 0 )
{ {
entriesTransmits = transmits( ); entriesTransmits = transmits( );

@ -39,23 +39,23 @@
Insert a list of groups and classes (the object classes that can be inserted) Insert a list of groups and classes (the object classes that can be inserted)
and one condition. If the condition is omitted, and one condition. If the condition is omitted,
the classes can allways be inserted. --> the classes can allways be inserted. -->
<!ELEMENT rule ((group | class)+, (and | or | not | before | after | tqcontains <!ELEMENT rule ((group | class)+, (and | or | not | before | after | contains
| greater | less | equal)?)> | greater | less | equal)?)>
<!-- Simple negation. Insert one condition --> <!-- Simple negation. Insert one condition -->
<!ELEMENT not (and | or | before | after | tqcontains | greater | less | equal)> <!ELEMENT not (and | or | before | after | contains | greater | less | equal)>
<!-- Logical and. Insert any number of conditions --> <!-- Logical and. Insert any number of conditions -->
<!ELEMENT and (and | or | not | before | after | tqcontains | greater | less | equal)+> <!ELEMENT and (and | or | not | before | after | contains | greater | less | equal)+>
<!-- Logical or. Insert any number of conditions --> <!-- Logical or. Insert any number of conditions -->
<!ELEMENT or (and | or | not | before | after | tqcontains | greater | less | equal)+> <!ELEMENT or (and | or | not | before | after | contains | greater | less | equal)+>
<!-- Condition. Value is true if the object already tqcontains <!-- Condition. Value is true if the object already contains
objects of the given class or group before the insert point. --> objects of the given class or group before the insert point. -->
<!ELEMENT before (class | group)> <!ELEMENT before (class | group)>
<!-- Condition. Value is true if the object already tqcontains <!-- Condition. Value is true if the object already contains
objects of the given class or group after the insert point. --> objects of the given class or group after the insert point. -->
<!ELEMENT after (class | group)> <!ELEMENT after (class | group)>
@ -71,9 +71,9 @@
is less than the second. --> is less than the second. -->
<!ELEMENT less ((property | count | const), (property | count | const))> <!ELEMENT less ((property | count | const), (property | count | const))>
<!-- Condition. Value is true if the object tqcontains <!-- Condition. Value is true if the object contains
objects of the given classes and groups. --> objects of the given classes and groups. -->
<!ELEMENT tqcontains (group | class)+> <!ELEMENT contains (group | class)+>
<!-- Value. Value is the class property of the object, where the <!-- Value. Value is the class property of the object, where the

@ -136,7 +136,7 @@ bool isCondition( TQDomElement& e )
{ {
return( e.tagName( ) == "not" || e.tagName( ) == "and" || return( e.tagName( ) == "not" || e.tagName( ) == "and" ||
e.tagName( ) == "or" || e.tagName( ) == "before" || e.tagName( ) == "or" || e.tagName( ) == "before" ||
e.tagName( ) == "after" || e.tagName( ) == "tqcontains" || e.tagName( ) == "after" || e.tagName( ) == "contains" ||
e.tagName( ) == "greater" || e.tagName( ) == "less" || e.tagName( ) == "greater" || e.tagName( ) == "less" ||
e.tagName( ) == "equal" ); e.tagName( ) == "equal" );
} }
@ -168,7 +168,7 @@ PMRuleCondition* newCondition( TQDomElement& e,
return new PMRuleBefore( e, globalGroups, localGroups ); return new PMRuleBefore( e, globalGroups, localGroups );
if( e.tagName( ) == "after" ) if( e.tagName( ) == "after" )
return new PMRuleAfter( e, globalGroups, localGroups ); return new PMRuleAfter( e, globalGroups, localGroups );
if( e.tagName( ) == "tqcontains" ) if( e.tagName( ) == "contains" )
return new PMRuleContains( e, globalGroups, localGroups ); return new PMRuleContains( e, globalGroups, localGroups );
if( e.tagName( ) == "greater" ) if( e.tagName( ) == "greater" )
return new PMRuleGreater( e, globalGroups, localGroups ); return new PMRuleGreater( e, globalGroups, localGroups );
@ -383,7 +383,7 @@ PMRuleBefore::PMRuleBefore( TQDomElement& e,
TQPtrList<PMRuleDefineGroup>& localGroups ) TQPtrList<PMRuleDefineGroup>& localGroups )
: PMRuleCondition( ) : PMRuleCondition( )
{ {
m_tqcontains = false; m_contains = false;
TQDomNode m = e.firstChild( ); TQDomNode m = e.firstChild( );
while( !m.isNull( ) ) while( !m.isNull( ) )
{ {
@ -405,23 +405,23 @@ PMRuleBefore::~PMRuleBefore( )
bool PMRuleBefore::evaluate( const PMObject* ) bool PMRuleBefore::evaluate( const PMObject* )
{ {
return m_tqcontains; return m_contains;
} }
void PMRuleBefore::countChildProtected( const TQString& className, void PMRuleBefore::countChildProtected( const TQString& className,
bool afterInsertPoint ) bool afterInsertPoint )
{ {
if( afterInsertPoint && !m_tqcontains ) if( afterInsertPoint && !m_contains )
{ {
TQPtrListIterator<PMRuleCategory> it( m_categories ); TQPtrListIterator<PMRuleCategory> it( m_categories );
for( ; it.current( ) && !m_tqcontains; ++it ) for( ; it.current( ) && !m_contains; ++it )
m_tqcontains = it.current( )->matches( className ); m_contains = it.current( )->matches( className );
} }
} }
void PMRuleBefore::resetProtected( ) void PMRuleBefore::resetProtected( )
{ {
m_tqcontains = false; m_contains = false;
} }
PMRuleAfter::PMRuleAfter( TQDomElement& e, PMRuleAfter::PMRuleAfter( TQDomElement& e,
@ -429,7 +429,7 @@ PMRuleAfter::PMRuleAfter( TQDomElement& e,
TQPtrList<PMRuleDefineGroup>& localGroups ) TQPtrList<PMRuleDefineGroup>& localGroups )
: PMRuleCondition( ) : PMRuleCondition( )
{ {
m_tqcontains = false; m_contains = false;
TQDomNode m = e.firstChild( ); TQDomNode m = e.firstChild( );
while( !m.isNull( ) ) while( !m.isNull( ) )
{ {
@ -451,23 +451,23 @@ PMRuleAfter::~PMRuleAfter( )
bool PMRuleAfter::evaluate( const PMObject* ) bool PMRuleAfter::evaluate( const PMObject* )
{ {
return m_tqcontains; return m_contains;
} }
void PMRuleAfter::countChildProtected( const TQString& className, void PMRuleAfter::countChildProtected( const TQString& className,
bool afterInsertPoint ) bool afterInsertPoint )
{ {
if( !afterInsertPoint && !m_tqcontains ) if( !afterInsertPoint && !m_contains )
{ {
TQPtrListIterator<PMRuleCategory> it( m_categories ); TQPtrListIterator<PMRuleCategory> it( m_categories );
for( ; it.current( ) && !m_tqcontains; ++it ) for( ; it.current( ) && !m_contains; ++it )
m_tqcontains = it.current( )->matches( className ); m_contains = it.current( )->matches( className );
} }
} }
void PMRuleAfter::resetProtected( ) void PMRuleAfter::resetProtected( )
{ {
m_tqcontains = false; m_contains = false;
} }
PMRuleContains::PMRuleContains( TQDomElement& e, PMRuleContains::PMRuleContains( TQDomElement& e,
@ -475,7 +475,7 @@ PMRuleContains::PMRuleContains( TQDomElement& e,
TQPtrList<PMRuleDefineGroup>& localGroups ) TQPtrList<PMRuleDefineGroup>& localGroups )
: PMRuleCondition( ) : PMRuleCondition( )
{ {
m_tqcontains = false; m_contains = false;
TQDomNode m = e.firstChild( ); TQDomNode m = e.firstChild( );
while( !m.isNull( ) ) while( !m.isNull( ) )
{ {
@ -497,22 +497,22 @@ PMRuleContains::~PMRuleContains( )
bool PMRuleContains::evaluate( const PMObject* ) bool PMRuleContains::evaluate( const PMObject* )
{ {
return m_tqcontains; return m_contains;
} }
void PMRuleContains::countChildProtected( const TQString& className, bool ) void PMRuleContains::countChildProtected( const TQString& className, bool )
{ {
if( !m_tqcontains ) if( !m_contains )
{ {
TQPtrListIterator<PMRuleCategory> it( m_categories ); TQPtrListIterator<PMRuleCategory> it( m_categories );
for( ; it.current( ) && !m_tqcontains; ++it ) for( ; it.current( ) && !m_contains; ++it )
m_tqcontains = it.current( )->matches( className ); m_contains = it.current( )->matches( className );
} }
} }
void PMRuleContains::resetProtected( ) void PMRuleContains::resetProtected( )
{ {
m_tqcontains = false; m_contains = false;
} }
PMRuleCompare::PMRuleCompare( TQDomElement& e, PMRuleCompare::PMRuleCompare( TQDomElement& e,
@ -829,7 +829,7 @@ PMInsertRuleSystem::~PMInsertRuleSystem( )
void PMInsertRuleSystem::loadRules( const TQString& fileName ) void PMInsertRuleSystem::loadRules( const TQString& fileName )
{ {
PMRuleClass::s_pPrototypeManager = m_pPart->prototypeManager( ); PMRuleClass::s_pPrototypeManager = m_pPart->prototypeManager( );
if( m_loadedFiles.tqfind( fileName ) != m_loadedFiles.end( ) ) if( m_loadedFiles.find( fileName ) != m_loadedFiles.end( ) )
return; return;
m_loadedFiles.push_back( fileName ); m_loadedFiles.push_back( fileName );
@ -877,7 +877,7 @@ void PMInsertRuleSystem::loadRules( const TQString& fileName )
PMRuleTargetClass* target = 0; PMRuleTargetClass* target = 0;
if( !m_rulesDict.isEmpty( ) ) if( !m_rulesDict.isEmpty( ) )
target = m_rulesDict.tqfind( className ); target = m_rulesDict.find( className );
if( target ) if( target )
target->appendRules( ce, m_groups ); target->appendRules( ce, m_groups );
@ -908,7 +908,7 @@ bool PMInsertRuleSystem::canInsert( const PMObject* parentObject,
PMMetaObject* meta = parentObject->tqmetaObject( ); PMMetaObject* meta = parentObject->tqmetaObject( );
for( ; meta && !possible; meta = meta->superClass( ) ) for( ; meta && !possible; meta = meta->superClass( ) )
{ {
PMRuleTargetClass* tc = m_rulesDict.tqfind( meta->className( ) ); PMRuleTargetClass* tc = m_rulesDict.find( meta->className( ) );
if( tc ) if( tc )
{ {
// check the exception list // check the exception list
@ -999,7 +999,7 @@ int PMInsertRuleSystem::canInsert( const PMObject* parentObject,
PMMetaObject* meta = parentObject->tqmetaObject( ); PMMetaObject* meta = parentObject->tqmetaObject( );
for( ; meta; meta = meta->superClass( ) ) for( ; meta; meta = meta->superClass( ) )
{ {
PMRuleTargetClass* tc = m_rulesDict.tqfind( meta->className( ) ); PMRuleTargetClass* tc = m_rulesDict.find( meta->className( ) );
if( tc ) if( tc )
targetClassList.append( tc ); targetClassList.append( tc );
} }

@ -344,7 +344,7 @@ private:
}; };
/** /**
* Condition. Value is true if the object already tqcontains * Condition. Value is true if the object already contains
* objects of certaint classes before the insert point. * objects of certaint classes before the insert point.
*/ */
class PMRuleBefore : public PMRuleCondition class PMRuleBefore : public PMRuleCondition
@ -371,11 +371,11 @@ protected:
virtual void resetProtected( ); virtual void resetProtected( );
private: private:
TQPtrList<PMRuleCategory> m_categories; TQPtrList<PMRuleCategory> m_categories;
bool m_tqcontains; bool m_contains;
}; };
/** /**
* Condition. Value is true if the object already tqcontains * Condition. Value is true if the object already contains
* objects of certaint classes after the insert point. * objects of certaint classes after the insert point.
*/ */
class PMRuleAfter : public PMRuleCondition class PMRuleAfter : public PMRuleCondition
@ -402,11 +402,11 @@ protected:
virtual void resetProtected( ); virtual void resetProtected( );
private: private:
TQPtrList<PMRuleCategory> m_categories; TQPtrList<PMRuleCategory> m_categories;
bool m_tqcontains; bool m_contains;
}; };
/** /**
* Condition. Value is true if the object already tqcontains * Condition. Value is true if the object already contains
* objects of certaint classes. * objects of certaint classes.
*/ */
class PMRuleContains : public PMRuleCondition class PMRuleContains : public PMRuleCondition
@ -433,7 +433,7 @@ protected:
virtual void resetProtected( ); virtual void resetProtected( );
private: private:
TQPtrList<PMRuleCategory> m_categories; TQPtrList<PMRuleCategory> m_categories;
bool m_tqcontains; bool m_contains;
}; };
/** /**

@ -47,9 +47,9 @@ void PMIOManager::addFormat( PMIOFormat* format )
{ {
if( !format ) if( !format )
return; return;
if( !m_formats.tqcontainsRef( format ) ) if( !m_formats.containsRef( format ) )
{ {
if( !m_dict.tqfind( format->name( ) ) ) if( !m_dict.find( format->name( ) ) )
{ {
m_formats.append( format ); m_formats.append( format );
m_dict.insert( format->name( ), format ); m_dict.insert( format->name( ), format );
@ -73,7 +73,7 @@ void PMIOManager::removeFormat( const TQString& name )
PMIOFormat* PMIOManager::format( const TQString& name ) const PMIOFormat* PMIOManager::format( const TQString& name ) const
{ {
return m_dict.tqfind( name ); return m_dict.find( name );
} }
PMIOFormat* PMIOManager::formatForMimeType( const TQString& mime ) const PMIOFormat* PMIOManager::formatForMimeType( const TQString& mime ) const

@ -262,7 +262,7 @@ void PMLayoutSettings::slotAddLayout( )
new_name = i18n( "Unnamed" ); new_name = i18n( "Unnamed" );
str.setNum( i ); str.setNum( i );
while( m_pViewLayouts->tqfindItem( new_name, TQt::ExactMatch ) ) while( m_pViewLayouts->findItem( new_name, TQt::ExactMatch ) )
{ {
new_name = i18n( "Unnamed" ) + str; new_name = i18n( "Unnamed" ) + str;
i++; i++;
@ -275,7 +275,7 @@ void PMLayoutSettings::slotAddLayout( )
m_currentViewLayout++; m_currentViewLayout++;
m_viewLayouts.insert( m_currentViewLayout, l ); m_viewLayouts.insert( m_currentViewLayout, l );
displayLayoutList( ); displayLayoutList( );
m_pViewLayouts->setCurrentItem( m_pViewLayouts->tqfindItem( new_name, TQt::ExactMatch ) ); m_pViewLayouts->setCurrentItem( m_pViewLayouts->findItem( new_name, TQt::ExactMatch ) );
m_pRemoveLayout->setEnabled( true ); m_pRemoveLayout->setEnabled( true );
} }

@ -302,7 +302,7 @@ PMLibraryHandle::PMResult PMLibraryHandle::createNewSubLibrary( const TQString /
if( m_readOnly ) if( m_readOnly )
return PMLibraryHandle::ReadOnlyLib; return PMLibraryHandle::ReadOnlyLib;
if( m_libraries.tqfind( subLibName ) ) if( m_libraries.find( subLibName ) )
return PMLibraryHandle::ExistingDir; return PMLibraryHandle::ExistingDir;
s = s+ "/libXXXXXX"; s = s+ "/libXXXXXX";
@ -364,14 +364,14 @@ PMLibraryHandle::PMResult PMLibraryHandle::changeParentLibrary( const TQString&
{ {
PMLibraryHandle lib = PMLibraryHandle( *itr.current( ) ); PMLibraryHandle lib = PMLibraryHandle( *itr.current( ) );
lib.changeParentLibrary( newPath ); lib.changeParentLibrary( newPath );
m_libraries.tqreplace( itr.currentKey( ), new TQString( newPath + "/" + lib.path( ) ) ); m_libraries.replace( itr.currentKey( ), new TQString( newPath + "/" + lib.path( ) ) );
} }
PMLibraryHandle::EntryIterator objItr( m_objects ); PMLibraryHandle::EntryIterator objItr( m_objects );
for( ; objItr.current( ); ++objItr ) for( ; objItr.current( ); ++objItr )
{ {
TQString test = newPath + "/" + objItr.current( )->section( '/', -1 ); TQString test = newPath + "/" + objItr.current( )->section( '/', -1 );
m_objects.tqreplace( objItr.currentKey( ), new TQString( newPath + "/" + objItr.current( )->section( '/', -1 ) ) ); m_objects.replace( objItr.currentKey( ), new TQString( newPath + "/" + objItr.current( )->section( '/', -1 ) ) );
} }
saveLibraryInfo( ); saveLibraryInfo( );

@ -402,7 +402,7 @@ public:
*/ */
PMPropertyBase* property( const TQString& name ) const PMPropertyBase* property( const TQString& name ) const
{ {
return m_propertiesDict.tqfind( name ); return m_propertiesDict.find( name );
} }
private: private:

@ -281,7 +281,7 @@ int PMMoveCommand::errorFlags( PMPart* )
for( obj = links.current( ); obj && !insideSelection; for( obj = links.current( ); obj && !insideSelection;
obj = obj->tqparent( ) ) obj = obj->tqparent( ) )
{ {
if( deletedObjects.tqfind( obj ) ) if( deletedObjects.find( obj ) )
insideSelection = true; insideSelection = true;
} }
@ -290,7 +290,7 @@ int PMMoveCommand::errorFlags( PMPart* )
bool stop = false; bool stop = false;
for( obj = links.current( ); obj && !stop; obj = obj->tqparent( ) ) for( obj = links.current( ); obj && !stop; obj = obj->tqparent( ) )
{ {
if( deletedObjects.tqfind( obj ) ) if( deletedObjects.find( obj ) )
stop = true; stop = true;
else else
deletedObjects.insert( obj, new bool( true ) ); deletedObjects.insert( obj, new bool( true ) );
@ -327,7 +327,7 @@ int PMMoveCommand::errorFlags( PMPart* )
// check if insert point is before the top level // check if insert point is before the top level
// tqparent object // tqparent object
if( !objectsAfterInsertPosition.tqfind( obj ) ) if( !objectsAfterInsertPosition.find( obj ) )
{ {
stop = false; stop = false;
obj = obj->prevSibling( ); obj = obj->prevSibling( );
@ -335,7 +335,7 @@ int PMMoveCommand::errorFlags( PMPart* )
{ {
if( obj == m_pAfter ) if( obj == m_pAfter )
stop = true; stop = true;
else if( objectsAfterInsertPosition.tqfind( obj ) ) else if( objectsAfterInsertPosition.find( obj ) )
stop = true; stop = true;
else else
obj = obj->prevSibling( ); obj = obj->prevSibling( );
@ -419,13 +419,13 @@ int PMMoveCommand::errorFlags( PMPart* )
if( linked ) if( linked )
{ {
if( !deletedObjects.tqfind( linked ) ) if( !deletedObjects.find( linked ) )
{ {
// Object is linked to a declare and the declare // Object is linked to a declare and the declare
// will not be moved. // will not be moved.
// Check, if the insert point is after the declare // Check, if the insert point is after the declare
if( !declaresBeforeInsertPosition.tqfind( linked ) ) if( !declaresBeforeInsertPosition.find( linked ) )
ok = false; ok = false;
} }
} }

@ -202,7 +202,7 @@ int PMObjectSelect::selectObject( PMObject* link,
while( o && !l && last ) while( o && !l && last )
{ {
if( t.tqfindIndex( o->type( ) ) >= 0 ) if( t.findIndex( o->type( ) ) >= 0 )
s.m_pListBox->insertItem( new PMListBoxObject( o ) ); s.m_pListBox->insertItem( new PMListBoxObject( o ) );
if( o == last ) if( o == last )
@ -325,7 +325,7 @@ int PMObjectSelect::selectDeclare( PMObject* link, const TQStringList& declareTy
if( o->type( ) == "Declare" ) if( o->type( ) == "Declare" )
{ {
decl = ( PMDeclare* ) o; decl = ( PMDeclare* ) o;
if( declareTypes.tqfindIndex( decl->declareType( ) ) >= 0 ) if( declareTypes.findIndex( decl->declareType( ) ) >= 0 )
s.m_pListBox->insertItem( new PMListBoxObject( o ) ); s.m_pListBox->insertItem( new PMListBoxObject( o ) );
} }

@ -304,9 +304,9 @@ bool PMParser::insertChild( PMObject* child, PMObject* tqparent )
void PMParser::checkID( PMDeclare* decl ) void PMParser::checkID( PMDeclare* decl )
{ {
PMSymbolTable* st = m_pPart->symbolTable( ); PMSymbolTable* st = m_pPart->symbolTable( );
PMSymbol* s = m_pLocalST.tqfind( decl->id( ) ); PMSymbol* s = m_pLocalST.find( decl->id( ) );
if( !s ) if( !s )
s = st->tqfind( decl->id( ) ); s = st->find( decl->id( ) );
if( s ) if( s )
{ {
@ -336,7 +336,7 @@ void PMParser::checkID( PMDeclare* decl )
void PMParser::checkID( const TQString& id, const PMValue& v ) void PMParser::checkID( const TQString& id, const PMValue& v )
{ {
PMSymbolTable* st = m_pPart->symbolTable( ); PMSymbolTable* st = m_pPart->symbolTable( );
PMSymbol* s = m_pLocalST.tqfind( id ); PMSymbol* s = m_pLocalST.find( id );
if( s ) if( s )
{ {
@ -374,9 +374,9 @@ PMDeclare* PMParser::checkLink( const TQString& id )
bool ok = false; bool ok = false;
// is object declared? // is object declared?
PMSymbol* s = m_pLocalST.tqfind( id ); PMSymbol* s = m_pLocalST.find( id );
if( !s ) if( !s )
s = t->tqfind( id ); s = t->find( id );
if( !s ) if( !s )
printError( i18n( "Undefined object \"%1\"." ).tqarg( id ) ); printError( i18n( "Undefined object \"%1\"." ).tqarg( id ) );
@ -386,7 +386,7 @@ PMDeclare* PMParser::checkLink( const TQString& id )
{ {
// the object is declared // the object is declared
// is the id already in m_okDeclares // is the id already in m_okDeclares
bool* lok = m_okDeclares.tqfind( id ); bool* lok = m_okDeclares.find( id );
if( lok ) if( lok )
ok = true; ok = true;
else else
@ -425,9 +425,9 @@ PMDeclare* PMParser::checkLink( const TQString& id )
PMSymbol* PMParser::getSymbol( const TQString& id ) const PMSymbol* PMParser::getSymbol( const TQString& id ) const
{ {
PMSymbol* s = m_pLocalST.tqfind( id ); PMSymbol* s = m_pLocalST.find( id );
if( !s ) if( !s )
s = m_pPart->symbolTable( )->tqfind( id ); s = m_pPart->symbolTable( )->find( id );
return s; return s;
} }

@ -1023,7 +1023,7 @@ bool PMPart::setActiveObject( const TQString& name )
tmpObj = activeObject( ); tmpObj = activeObject( );
// get the first element // get the first element
pos = objPath.tqfind( '/' ); pos = objPath.find( '/' );
if( pos != -1 ) if( pos != -1 )
{ {
pathElem = objPath.mid( 0, pos ); pathElem = objPath.mid( 0, pos );
@ -1040,10 +1040,10 @@ bool PMPart::setActiveObject( const TQString& name )
if( !pathElem.isEmpty( ) ) if( !pathElem.isEmpty( ) )
{ {
// Special treatment for brackets // Special treatment for brackets
firstBracket = pathElem.tqfind( '[' ); firstBracket = pathElem.find( '[' );
if( firstBracket != -1 ) if( firstBracket != -1 )
{ {
lastBracket = pathElem.tqfindRev( ']' ); lastBracket = pathElem.findRev( ']' );
objIndex = pathElem.mid( firstBracket + 1, lastBracket - firstBracket - 1).toInt( ); objIndex = pathElem.mid( firstBracket + 1, lastBracket - firstBracket - 1).toInt( );
pathElem = pathElem.left( firstBracket ); pathElem = pathElem.left( firstBracket );
} }
@ -1070,7 +1070,7 @@ bool PMPart::setActiveObject( const TQString& name )
} }
// Get the next element // Get the next element
pos = objPath.tqfind( '/' ); pos = objPath.find( '/' );
if( pos != -1 ) if( pos != -1 )
{ {
pathElem = objPath.mid( 0, pos ); pathElem = objPath.mid( 0, pos );
@ -1864,7 +1864,7 @@ void PMPart::slotObjectChanged( PMObject* obj, const int m,
else else
m_pNewSelection = 0; m_pNewSelection = 0;
} }
if( m_selectedObjects.tqcontainsRef( obj ) ) if( m_selectedObjects.containsRef( obj ) )
{ {
m_selectedObjects.removeRef( obj ); m_selectedObjects.removeRef( obj );
if( m_selectedObjects.isEmpty( ) ) if( m_selectedObjects.isEmpty( ) )
@ -1903,7 +1903,7 @@ void PMPart::slotObjectChanged( PMObject* obj, const int m,
if( obj->isA( "Declare" ) ) if( obj->isA( "Declare" ) )
{ {
PMDeclare* decl = ( PMDeclare* ) obj; PMDeclare* decl = ( PMDeclare* ) obj;
PMSymbol* s = m_pSymbolTable->tqfind( decl->id( ) ); PMSymbol* s = m_pSymbolTable->find( decl->id( ) );
if( !s ) if( !s )
m_pSymbolTable->insert( decl->id( ), m_pSymbolTable->insert( decl->id( ),
new PMSymbol( decl->id( ), decl ) ); new PMSymbol( decl->id( ), decl ) );
@ -1977,7 +1977,7 @@ void PMPart::slotIDChanged( PMObject* obj, const TQString& oldID )
if( obj->isA( "Declare" ) ) if( obj->isA( "Declare" ) )
{ {
PMDeclare* d = ( PMDeclare* ) obj; PMDeclare* d = ( PMDeclare* ) obj;
PMSymbol* s = m_pSymbolTable->tqfind( oldID ); PMSymbol* s = m_pSymbolTable->find( oldID );
if( s ) if( s )
{ {
if( s->type( ) == PMSymbol::Object ) if( s->type( ) == PMSymbol::Object )

@ -81,7 +81,7 @@ PMPluginManager* PMPluginManager::theManager( )
void PMPluginManager::registerPart( PMPart* p ) void PMPluginManager::registerPart( PMPart* p )
{ {
if( !m_parts.tqcontainsRef( p ) ) if( !m_parts.containsRef( p ) )
{ {
m_parts.append( p ); m_parts.append( p );
Plugin::loadPlugins( p, p, PMFactory::instance( ), false ); Plugin::loadPlugins( p, p, PMFactory::instance( ), false );

@ -32,7 +32,7 @@ PMPovrayFormat::~PMPovrayFormat( )
void PMPovrayFormat::registerMethod( const TQString& className, void PMPovrayFormat::registerMethod( const TQString& className,
PMPovraySerializeMethod method ) PMPovraySerializeMethod method )
{ {
PMPovraySerializeMethodInfo* info = m_methodDict.tqfind( className ); PMPovraySerializeMethodInfo* info = m_methodDict.find( className );
if( info ) if( info )
kdWarning( PMArea ) << "Serialization method for " << className kdWarning( PMArea ) << "Serialization method for " << className
<< " shadows old implementation" << endl; << " shadows old implementation" << endl;
@ -48,5 +48,5 @@ void PMPovrayFormat::removeMethod( const TQString& className )
const PMPovraySerializeMethodInfo* PMPovrayFormat::serializationMethod( const PMPovraySerializeMethodInfo* PMPovrayFormat::serializationMethod(
const TQString& className ) const TQString& className )
{ {
return m_methodDict.tqfind( className ); return m_methodDict.find( className );
} }

@ -4658,7 +4658,7 @@ bool PMPovrayParser::parseNormalMap( PMNormalMap* normalMap )
{ {
oldConsumed = m_consumedTokens; oldConsumed = m_consumedTokens;
// If we tqfind '}' no need to search for an entry // If we find '}' no need to search for an entry
if( m_token != '}' && parseToken( '[' ) ) if( m_token != '}' && parseToken( '[' ) )
{ {
if( !parseFloat( f_number1 ) ) if( !parseFloat( f_number1 ) )
@ -4958,7 +4958,7 @@ bool PMPovrayParser::parseSlopeMap( PMSlopeMap* slopeMap )
{ {
oldConsumed = m_consumedTokens; oldConsumed = m_consumedTokens;
// If we tqfind '}' no need to search for an entry // If we find '}' no need to search for an entry
if( m_token != '}' && parseToken( '[' ) ) if( m_token != '}' && parseToken( '[' ) )
{ {
if( !parseFloat( f_number1 ) ) if( !parseFloat( f_number1 ) )
@ -5014,7 +5014,7 @@ bool PMPovrayParser::parseDensityMap( PMDensityMap* densityMap )
{ {
oldConsumed = m_consumedTokens; oldConsumed = m_consumedTokens;
// If we tqfind '}' no need to search for an entry // If we find '}' no need to search for an entry
if( m_token != '}' && parseToken( '[' ) ) if( m_token != '}' && parseToken( '[' ) )
{ {
if( !parseFloat( f_number1 ) ) if( !parseFloat( f_number1 ) )

@ -193,7 +193,7 @@ void PMPovraySettings::slotAddPath( )
TQString path = KFileDialog::getExistingDirectory( TQString(), this ); TQString path = KFileDialog::getExistingDirectory( TQString(), this );
if( !path.isEmpty( ) ) if( !path.isEmpty( ) )
{ {
TQListBoxItem* item = m_pLibraryPaths->tqfindItem( path, ExactMatch ); TQListBoxItem* item = m_pLibraryPaths->findItem( path, ExactMatch );
if( !item ) if( !item )
{ {
m_pLibraryPaths->insertItem( path, m_selectionIndex + 1 ); m_pLibraryPaths->insertItem( path, m_selectionIndex + 1 );
@ -250,7 +250,7 @@ void PMPovraySettings::slotEditPath( )
TQString path = KFileDialog::getExistingDirectory( text, this ); TQString path = KFileDialog::getExistingDirectory( text, this );
if( !path.isEmpty( ) ) if( !path.isEmpty( ) )
{ {
TQListBoxItem* item = m_pLibraryPaths->tqfindItem( path, ExactMatch ); TQListBoxItem* item = m_pLibraryPaths->findItem( path, ExactMatch );
if( !item ) if( !item )
m_pLibraryPaths->changeItem( path, m_selectionIndex ); m_pLibraryPaths->changeItem( path, m_selectionIndex );
else if( item != lbi ) else if( item != lbi )

@ -337,7 +337,7 @@ void PMPovrayWidget::slotRenderingFinished( int returntqStatus )
"See the povray output for details." ) "See the povray output for details." )
.tqarg( returntqStatus ) ); .tqarg( returntqStatus ) );
} }
else if( m_pRenderWidget->povrayOutput( ).tqcontains( "ERROR" ) ) else if( m_pRenderWidget->povrayOutput( ).contains( "ERROR" ) )
{ {
KMessageBox::error( this, i18n( "There were errors while rendering.\n" KMessageBox::error( this, i18n( "There were errors while rendering.\n"
"See the povray output for details." ) ); "See the povray output for details." ) );

@ -452,7 +452,7 @@ void PMPrismEdit::slotAddPointAbove( )
TQPushButton* bt = ( TQPushButton* ) sender( ); TQPushButton* bt = ( TQPushButton* ) sender( );
if( bt ) if( bt )
{ {
int subIndex = m_addAboveButtons.tqfindRef( bt ); int subIndex = m_addAboveButtons.findRef( bt );
if( subIndex >= 0 ) if( subIndex >= 0 )
{ {
PMVectorListEdit* ed = m_points.at( subIndex ); PMVectorListEdit* ed = m_points.at( subIndex );
@ -488,7 +488,7 @@ void PMPrismEdit::slotAddPointBelow( )
TQPushButton* bt = ( TQPushButton* ) sender( ); TQPushButton* bt = ( TQPushButton* ) sender( );
if( bt ) if( bt )
{ {
int subIndex = m_addBelowButtons.tqfindRef( bt ); int subIndex = m_addBelowButtons.findRef( bt );
if( subIndex >= 0 ) if( subIndex >= 0 )
{ {
PMVectorListEdit* ed = m_points.at( subIndex ); PMVectorListEdit* ed = m_points.at( subIndex );
@ -524,7 +524,7 @@ void PMPrismEdit::slotRemovePoint( )
TQPushButton* bt = ( TQPushButton* ) sender( ); TQPushButton* bt = ( TQPushButton* ) sender( );
if( bt ) if( bt )
{ {
int subIndex = m_removeButtons.tqfindRef( bt ); int subIndex = m_removeButtons.findRef( bt );
if( subIndex >= 0 ) if( subIndex >= 0 )
{ {
PMVectorListEdit* ed = m_points.at( subIndex ); PMVectorListEdit* ed = m_points.at( subIndex );
@ -560,7 +560,7 @@ void PMPrismEdit::slotAddSubPrism( )
TQPushButton* button = ( TQPushButton* ) sender( ); TQPushButton* button = ( TQPushButton* ) sender( );
if( button ) if( button )
{ {
int index = m_subPrismAddButtons.tqfindRef( button ); int index = m_subPrismAddButtons.findRef( button );
if( index >= 0 ) if( index >= 0 )
{ {
TQValueList< TQValueList<PMVector> > points = splinePoints( ); TQValueList< TQValueList<PMVector> > points = splinePoints( );
@ -600,7 +600,7 @@ void PMPrismEdit::slotRemoveSubPrism( )
TQPushButton* button = ( TQPushButton* ) sender( ); TQPushButton* button = ( TQPushButton* ) sender( );
if( button ) if( button )
{ {
int index = m_subPrismRemoveButtons.tqfindRef( button ); int index = m_subPrismRemoveButtons.findRef( button );
if( index >= 0 ) if( index >= 0 )
{ {
TQValueList< TQValueList<PMVector> > points = splinePoints( ); TQValueList< TQValueList<PMVector> > points = splinePoints( );

@ -148,7 +148,7 @@ void PMPrototypeManager::addPrototype( PMObject* obj )
return; return;
PMMetaObject* tqmetaObject = obj->tqmetaObject( ); PMMetaObject* tqmetaObject = obj->tqmetaObject( );
PMMetaObject* m2 = m_metaDict.tqfind( tqmetaObject->className( ) ); PMMetaObject* m2 = m_metaDict.find( tqmetaObject->className( ) );
if( m2 ) if( m2 )
{ {
kdError( PMArea ) << "PMPrototypeManager: Class '" kdError( PMArea ) << "PMPrototypeManager: Class '"
@ -168,7 +168,7 @@ void PMPrototypeManager::addPrototype( PMObject* obj )
// insert the meta object and all super classes into the hash table // insert the meta object and all super classes into the hash table
while( tqmetaObject ) while( tqmetaObject )
{ {
if( m_metaDict.tqfind( tqmetaObject->className( ) ) ) if( m_metaDict.find( tqmetaObject->className( ) ) )
tqmetaObject = 0; tqmetaObject = 0;
else else
{ {
@ -206,7 +206,7 @@ PMObject* PMPrototypeManager::newObject( const TQString& name ) const
if( name.isEmpty( ) ) if( name.isEmpty( ) )
return 0; return 0;
PMMetaObject* meta = m_metaDict.tqfind( name ); PMMetaObject* meta = m_metaDict.find( name );
if( !meta ) if( !meta )
return 0; return 0;
return meta->newObject( m_pPart ); return meta->newObject( m_pPart );
@ -216,7 +216,7 @@ PMMetaObject* PMPrototypeManager::tqmetaObject( const TQString& name ) const
{ {
if( name.isNull( ) ) if( name.isNull( ) )
return 0; return 0;
return m_metaDict.tqfind( name ); return m_metaDict.find( name );
} }
bool PMPrototypeManager::isA( const TQString& className, bool PMPrototypeManager::isA( const TQString& className,
@ -236,7 +236,7 @@ bool PMPrototypeManager::isA( PMMetaObject* c,
TQString PMPrototypeManager::className( const TQString& lowercase ) const TQString PMPrototypeManager::className( const TQString& lowercase ) const
{ {
TQMap<TQString, TQString>::const_iterator it = m_lowerCaseDict.tqfind( lowercase ); TQMap<TQString, TQString>::const_iterator it = m_lowerCaseDict.find( lowercase );
if( it != m_lowerCaseDict.end( ) ) if( it != m_lowerCaseDict.end( ) )
return *it; return *it;
return TQString(); return TQString();

@ -146,7 +146,7 @@ void PMRenderManager::addView( PMGLView* view, PMObject* active, PMObject* top,
restart = true; restart = true;
else if( graphicalChange ) else if( graphicalChange )
{ {
m_renderTasks.tqfindRef( task ); m_renderTasks.findRef( task );
m_renderTasks.take( ); m_renderTasks.take( );
m_renderTasks.prepend( task ); m_renderTasks.prepend( task );
restart = true; restart = true;
@ -205,12 +205,12 @@ void PMRenderManager::removeView( PMGLView* view )
bool PMRenderManager::containsTask( PMGLView* view ) const bool PMRenderManager::containsTask( PMGLView* view ) const
{ {
PMRenderTaskListIterator it( m_renderTasks ); PMRenderTaskListIterator it( m_renderTasks );
bool tqcontains = false; bool contains = false;
for( ; it.current( ) && !tqcontains; ++it ) for( ; it.current( ) && !contains; ++it )
if( it.current( )->view( ) == view ) if( it.current( )->view( ) == view )
tqcontains = true; contains = true;
return tqcontains; return contains;
} }
TQColor PMRenderManager::controlPointColor( int i ) const TQColor PMRenderManager::controlPointColor( int i ) const
@ -1411,7 +1411,7 @@ void PMRenderManager::renderGrid( )
glEnd( ); glEnd( );
TQString label = TQString( "%1" ).tqarg( x * signx, 0, 'g', 4 ); TQString label = TQString( "%1" ).tqarg( x * signx, 0, 'g', 4 );
if( approxZero( x ) && label.tqfind( "e-" ) ) if( approxZero( x ) && label.find( "e-" ) )
label = "0"; label = "0";
renderString( label, screenx + 3, height / 2 - fontHeight - 2 ); renderString( label, screenx + 3, height / 2 - fontHeight - 2 );
@ -1432,7 +1432,7 @@ void PMRenderManager::renderGrid( )
glEnd( ); glEnd( );
TQString label = TQString( "%1" ).tqarg( y * signy, 0, 'g', 4 ); TQString label = TQString( "%1" ).tqarg( y * signy, 0, 'g', 4 );
if( approxZero( y ) && label.tqfind( "e-" ) ) if( approxZero( y ) && label.find( "e-" ) )
label = "0"; label = "0";
renderString( label, -width / 2 + 3, screeny + 2 ); renderString( label, -width / 2 + 3, screeny + 2 );

@ -56,7 +56,7 @@ TQString PMResourceLocator::lookUp( const TQString& file )
kdDebug( PMArea ) << "LookUp: " << file << endl; kdDebug( PMArea ) << "LookUp: " << file << endl;
TQString* ps = m_cache.tqfind( file ); TQString* ps = m_cache.find( file );
if( ps ) if( ps )
return *ps; return *ps;

@ -49,13 +49,13 @@ public:
/** /**
* Returns the token constant for the key if found, otherwise -1 * Returns the token constant for the key if found, otherwise -1
*/ */
int operator[] ( const char* key ) const { return tqfind( key ); } int operator[] ( const char* key ) const { return find( key ); }
/** /**
* Returns the token constant for the key if found, otherwise -1 * Returns the token constant for the key if found, otherwise -1
*/ */
int tqfind( const char* key ) const int find( const char* key ) const
{ {
int* result = TQAsciiDict<int>::tqfind( key ); int* result = TQAsciiDict<int>::find( key );
if( result ) if( result )
return *result; return *result;
return -1; return -1;

@ -344,7 +344,7 @@ void PMShell::slotDockWidgetClosed( )
const TQObject* o = TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender( ))); const TQObject* o = TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender( )));
if( o && o->inherits( "PMDockWidget" ) ) if( o && o->inherits( "PMDockWidget" ) )
{ {
if( m_objectsToDelete.tqcontainsRef( o ) == 0 ) if( m_objectsToDelete.containsRef( o ) == 0 )
{ {
m_objectsToDelete.append( o ); m_objectsToDelete.append( o );
TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT( slotDeleteClosedObjects( ) ) ); TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT( slotDeleteClosedObjects( ) ) );
@ -602,7 +602,7 @@ void PMShell::setCaption( const TQString& caption )
else else
{ {
if( !m_pPathAction->isChecked( ) ) if( !m_pPathAction->isChecked( ) )
tmp = caption.right( caption.length( ) - caption.tqfindRev( '/' ) - 1 ); tmp = caption.right( caption.length( ) - caption.findRev( '/' ) - 1 );
else else
tmp = caption; tmp = caption;
} }
@ -656,7 +656,7 @@ bool PMShell::overwriteURL( const KURL& u )
void PMShell::slotSelectedLayout( int id ) void PMShell::slotSelectedLayout( int id )
{ {
TQMenuItem* menu = m_pViewLayoutsAction->popupMenu( )->tqfindItem( id ); TQMenuItem* menu = m_pViewLayoutsAction->popupMenu( )->findItem( id );
PMViewLayoutManager::theManager( )->displayLayout( menu->text( ), this ); PMViewLayoutManager::theManager( )->displayLayout( menu->text( ), this );
} }

@ -85,7 +85,7 @@ TQString PMSymbolTable::findNewID( const TQString& prefix )
TQString testID; TQString testID;
unsigned int number; unsigned int number;
int* lastNumber = m_lastID.tqfind( prefix ); int* lastNumber = m_lastID.find( prefix );
if( lastNumber ) if( lastNumber )
number = *lastNumber + 1; number = *lastNumber + 1;
else else
@ -95,7 +95,7 @@ TQString PMSymbolTable::findNewID( const TQString& prefix )
do do
{ {
testID = prefix + TQString( "%1" ).tqarg( number ); testID = prefix + TQString( "%1" ).tqarg( number );
symbol = tqfind( testID ); symbol = find( testID );
if( symbol ) if( symbol )
number++; number++;
} }

@ -57,7 +57,7 @@ PMTrueTypeFont* PMTrueTypeCache::lookUp( const TQString& file )
if( file.isEmpty( ) ) if( file.isEmpty( ) )
return 0; return 0;
PMTrueTypeFont* f = m_cache.tqfind( file ); PMTrueTypeFont* f = m_cache.find( file );
if( !f ) if( !f )
{ {
FT_Face face; FT_Face face;
@ -151,7 +151,7 @@ PMTrueTypeOutline* PMTrueTypeFont::outline( TQChar c )
if( isValid( ) ) if( isValid( ) )
{ {
TQString str( c ); TQString str( c );
ol = m_cache.tqfind( str ); ol = m_cache.find( str );
if( !ol ) if( !ol )
{ {
FT_UInt glyphIndex = findGlyphIndex( c ); FT_UInt glyphIndex = findGlyphIndex( c );

@ -575,7 +575,7 @@ TQString PMVector::serializeXML( ) const
bool PMVector::loadXML( const TQString& str ) bool PMVector::loadXML( const TQString& str )
{ {
int i; int i;
int size = str.tqcontains( ' ' ) + 1; int size = str.contains( ' ' ) + 1;
TQString tmp( str ); TQString tmp( str );
TQTextStream s( &tmp, IO_ReadOnly ); TQTextStream s( &tmp, IO_ReadOnly );
TQString val; TQString val;

@ -64,7 +64,7 @@ void PMViewFactory::addViewType( PMViewTypeFactory* vt )
PMViewBase* PMViewFactory::newViewInstance( const TQString& viewType, PMViewBase* PMViewFactory::newViewInstance( const TQString& viewType,
TQWidget* tqparent, PMPart* part ) const TQWidget* tqparent, PMPart* part ) const
{ {
PMViewTypeFactory* f = m_dict.tqfind( viewType ); PMViewTypeFactory* f = m_dict.find( viewType );
if( f ) if( f )
return f->newInstance( tqparent, part ); return f->newInstance( tqparent, part );
@ -74,7 +74,7 @@ PMViewBase* PMViewFactory::newViewInstance( const TQString& viewType,
PMViewOptions* PMViewFactory::newOptionsInstance( const TQString& viewType ) const PMViewOptions* PMViewFactory::newOptionsInstance( const TQString& viewType ) const
{ {
PMViewTypeFactory* f = m_dict.tqfind( viewType ); PMViewTypeFactory* f = m_dict.find( viewType );
if( f ) if( f )
return f->newOptionsInstance( ); return f->newOptionsInstance( );
@ -84,7 +84,7 @@ PMViewOptions* PMViewFactory::newOptionsInstance( const TQString& viewType ) con
PMViewTypeFactory* PMViewFactory::viewFactory( const TQString& viewType ) const PMViewTypeFactory* PMViewFactory::viewFactory( const TQString& viewType ) const
{ {
return m_dict.tqfind( viewType ); return m_dict.find( viewType );
} }
const TQPtrList<PMViewTypeFactory>& PMViewFactory::viewTypes( ) const const TQPtrList<PMViewTypeFactory>& PMViewFactory::viewTypes( ) const

@ -451,7 +451,7 @@ void KLineal::enterEvent(TQEvent * /*inEvent*/) {
* overwritten to switch the value label and line cursor off * overwritten to switch the value label and line cursor off
*/ */
void KLineal::leaveEvent(TQEvent * /*inEvent*/) { void KLineal::leaveEvent(TQEvent * /*inEvent*/) {
if (!tqgeometry().tqcontains(TQCursor::pos())) { if (!tqgeometry().contains(TQCursor::pos())) {
hideLabel(); hideLabel();
} }
} }

@ -400,11 +400,11 @@ void KSnapshot::autoincFilename()
TQString numAsStr= name.mid(start, len); TQString numAsStr= name.mid(start, len);
TQString number = TQString::number(numAsStr.toInt() + 1); TQString number = TQString::number(numAsStr.toInt() + 1);
number = number.rightJustify( len, '0'); number = number.rightJustify( len, '0');
name.tqreplace(start, len, number ); name.replace(start, len, number );
} }
else { else {
// no number // no number
start = name.tqfindRev('.'); start = name.findRev('.');
if (start != -1) { if (start != -1) {
// has a . somewhere, e.g. it has an extension // has a . somewhere, e.g. it has an extension
name.insert(start, '1'); name.insert(start, '1');

@ -60,7 +60,7 @@ void SizeTip::positionTip( const TQRect &rect )
TQRect deskR = KGlobalSettings::desktopGeometry( TQPoint( 0, 0 ) ); TQRect deskR = KGlobalSettings::desktopGeometry( TQPoint( 0, 0 ) );
tipRect.moveCenter( TQPoint( deskR.width()/2, deskR.height()/2 ) ); tipRect.moveCenter( TQPoint( deskR.width()/2, deskR.height()/2 ) );
if ( !rect.tqcontains( tipRect, true ) && rect.intersects( tipRect ) ) if ( !rect.contains( tipRect, true ) && rect.intersects( tipRect ) )
tipRect.moveBottomRight( tqgeometry().bottomRight() ); tipRect.moveBottomRight( tqgeometry().bottomRight() );
} }

@ -303,7 +303,7 @@ void WindowGrabber::wheelEvent( TQWheelEvent *e )
void WindowGrabber::increaseScope( const TQPoint &pos ) void WindowGrabber::increaseScope( const TQPoint &pos )
{ {
for ( uint i = current + 1; i < windows.size(); i++ ) { for ( uint i = current + 1; i < windows.size(); i++ ) {
if ( windows[ i ].tqcontains( pos ) ) { if ( windows[ i ].contains( pos ) ) {
current = i; current = i;
break; break;
} }
@ -317,7 +317,7 @@ void WindowGrabber::increaseScope( const TQPoint &pos )
void WindowGrabber::decreaseScope( const TQPoint &pos ) void WindowGrabber::decreaseScope( const TQPoint &pos )
{ {
for ( int i = current - 1; i >= 0; i-- ) { for ( int i = current - 1; i >= 0; i-- ) {
if ( windows[ i ].tqcontains( pos ) ) { if ( windows[ i ].contains( pos ) ) {
current = i; current = i;
break; break;
} }
@ -330,7 +330,7 @@ void WindowGrabber::decreaseScope( const TQPoint &pos )
int WindowGrabber::windowIndex( const TQPoint &pos ) const int WindowGrabber::windowIndex( const TQPoint &pos ) const
{ {
for ( uint i = 0; i < windows.size(); i++ ) { for ( uint i = 0; i < windows.size(); i++ ) {
if ( windows[ i ].tqcontains( pos ) ) if ( windows[ i ].contains( pos ) )
return i; return i;
} }
return -1; return -1;

@ -181,7 +181,7 @@ void KSVGCanvas::resize(unsigned int w, unsigned int h)
{ {
for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it) for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it)
{ {
if(!drawables.tqcontains(*it)) if(!drawables.contains(*it))
drawables.append(*it); drawables.append(*it);
} }
} }
@ -203,7 +203,7 @@ void KSVGCanvas::resize(unsigned int w, unsigned int h)
{ {
for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it) for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it)
{ {
if(!drawables.tqcontains(*it)) if(!drawables.contains(*it))
drawables.append(*it); drawables.append(*it);
} }
} }
@ -324,11 +324,11 @@ T2P::FontVisualParams *KSVGCanvas::fontVisualParams(SVGStylableImpl *style) cons
EFontStyle fontStyle = style->getFontStyle(); EFontStyle fontStyle = style->getFontStyle();
TQString fontWeight = style->getFontWeight(); TQString fontWeight = style->getFontWeight();
if(fontWeight.tqcontains("bold")) if(fontWeight.contains("bold"))
weight |= FC_WEIGHT_DEMIBOLD; weight |= FC_WEIGHT_DEMIBOLD;
if(fontWeight.tqcontains("bolder")) if(fontWeight.contains("bolder"))
weight |= FC_WEIGHT_BOLD; weight |= FC_WEIGHT_BOLD;
if(fontWeight.tqcontains("lighter")) if(fontWeight.contains("lighter"))
weight |= FC_WEIGHT_LIGHT; weight |= FC_WEIGHT_LIGHT;
bool ok = true; bool ok = true;
@ -364,7 +364,7 @@ T2P::FontVisualParams *KSVGCanvas::fontVisualParams(SVGStylableImpl *style) cons
void KSVGCanvas::tqinvalidate(CanvasItem *item, bool recalc) void KSVGCanvas::tqinvalidate(CanvasItem *item, bool recalc)
{ {
if(m_chunksByItem.tqfind(item) != m_chunksByItem.end()) if(m_chunksByItem.find(item) != m_chunksByItem.end())
{ {
if(recalc) if(recalc)
{ {
@ -376,7 +376,7 @@ void KSVGCanvas::tqinvalidate(CanvasItem *item, bool recalc)
for(it.toFirst(); it.current(); ++it) for(it.toFirst(); it.current(); ++it)
{ {
(*it)->setDirty(); (*it)->setDirty();
if(!m_dirtyChunks.tqcontains(*it)) if(!m_dirtyChunks.contains(*it))
m_dirtyChunks.append(*it); m_dirtyChunks.append(*it);
} }
} }
@ -429,7 +429,7 @@ void KSVGCanvas::removeFromChunks(CanvasItem *item)
for(it.toFirst(); it.current(); ++it) for(it.toFirst(); it.current(); ++it)
{ {
(*it)->remove(item); (*it)->remove(item);
if(!m_dirtyChunks.tqcontains(*it)) if(!m_dirtyChunks.contains(*it))
m_dirtyChunks.append(*it); m_dirtyChunks.append(*it);
} }
m_chunksByItem.remove(item); m_chunksByItem.remove(item);
@ -540,7 +540,7 @@ void KSVGCanvas::update(const TQPoint &panPoint, bool erase)
{ {
for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it) for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it)
{ {
if(!drawables.tqcontains(*it)) if(!drawables.contains(*it))
drawables.append(*it); drawables.append(*it);
} }
} }
@ -607,7 +607,7 @@ void KSVGCanvas::update(float zoomFactor)
{ {
for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it) for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it)
{ {
if(!drawables.tqcontains(*it)) if(!drawables.contains(*it))
drawables.append(*it); drawables.append(*it);
} }
} }
@ -666,7 +666,7 @@ void KSVGCanvas::update()
for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it) for(CanvasItemList::ConstIterator it = chunk->list().begin(); it != chunk->list().end(); ++it)
{ {
// kdDebug(26005) << k_funcinfo << " Checking: " << *it << endl; // kdDebug(26005) << k_funcinfo << " Checking: " << *it << endl;
if(!drawables.tqcontains(*it)) if(!drawables.contains(*it))
{ {
// kdDebug(26005) << k_funcinfo << " Yes, appending to update list!" << endl; // kdDebug(26005) << k_funcinfo << " Yes, appending to update list!" << endl;
drawables.append(*it); drawables.append(*it);
@ -724,7 +724,7 @@ CanvasItemList KSVGCanvas::collisions(const TQPoint &p, bool exact) const
{ {
for(CanvasItemList::Iterator it = list.begin(); it != list.end(); ++it) for(CanvasItemList::Iterator it = list.begin(); it != list.end(); ++it)
{ {
if((*it)->fillContains(p) || (*it)->strokeContains(p) || (*it)->bbox().tqcontains(p)) if((*it)->fillContains(p) || (*it)->strokeContains(p) || (*it)->bbox().contains(p))
result.append(*it); result.append(*it);
} }

@ -125,7 +125,7 @@ void KSVGLoader::slotResult(KIO::Job *job)
if(m_job->error() == 0) if(m_job->error() == 0)
{ {
TQString check = static_cast<KIO::TransferJob *>(job)->url().prettyURL(); TQString check = static_cast<KIO::TransferJob *>(job)->url().prettyURL();
if(check.tqcontains(".svgz") || check.tqcontains(".svg.gz")) if(check.contains(".svgz") || check.contains(".svg.gz"))
{ {
// decode the gzipped svg and emit it // decode the gzipped svg and emit it
TQIODevice *dev = KFilterDev::device(TQT_TQIODEVICE(new TQBuffer(m_data)), "application/x-gzip"); TQIODevice *dev = KFilterDev::device(TQT_TQIODEVICE(new TQBuffer(m_data)), "application/x-gzip");
@ -348,7 +348,7 @@ public:
// Convert the id to its mangled version. // Convert the id to its mangled version.
TQString id = "@fragment@" + m_url.prettyURL() + "@" + value; TQString id = "@fragment@" + m_url.prettyURL() + "@" + value;
if(m_idMap.tqcontains(id)) if(m_idMap.contains(id))
{ {
// This is a local reference to an element within the fragment. // This is a local reference to an element within the fragment.
// Just convert the href. // Just convert the href.

@ -84,7 +84,7 @@ static const char SVGDOMNodeBridgeProto__s_hashTableStrings[] = {
"cloneNode\0" "cloneNode\0"
"getPrefix\0" "getPrefix\0"
"normalize\0" "normalize\0"
"tqcontains\0" "contains\0"
}; };

@ -81,7 +81,7 @@ public:
/** /**
* Provides access to the current animated contents of the points * Provides access to the current animated contents of the points
* attribute. * attribute.
* If the given attribute or property is being animated, tqcontains * If the given attribute or property is being animated, contains
* the current animated value of the attribute or property. * the current animated value of the attribute or property.
* If the given attribute or property is not currently being * If the given attribute or property is not currently being
* animated, contains the same value as <code>points</code>'. * animated, contains the same value as <code>points</code>'.

@ -81,7 +81,7 @@ public:
/** /**
* Provides access to the current animated contents of the points * Provides access to the current animated contents of the points
* attribute. * attribute.
* If the given attribute or property is being animated, tqcontains * If the given attribute or property is being animated, contains
* the current animated value of the attribute or property. * the current animated value of the attribute or property.
* If the given attribute or property is not currently being * If the given attribute or property is not currently being
* animated, contains the same value as <code>points</code>'. * animated, contains the same value as <code>points</code>'.

@ -56,7 +56,7 @@ class SVGSVGElementImpl;
/** /**
* A key interface definition is the SVGSVGElement interface, which is the * A key interface definition is the SVGSVGElement interface, which is the
* interface that corresponds to the 'svg' element. This interface tqcontains * interface that corresponds to the 'svg' element. This interface contains
* various miscellaneous commonly-used utility methods, such as matrix * various miscellaneous commonly-used utility methods, such as matrix
* operations and the ability to control the time of redraw on visual * operations and the ability to control the time of redraw on visual
* rendering devices. SVGSVGElement extends ViewCSS and DocumentCSS to provide * rendering devices. SVGSVGElement extends ViewCSS and DocumentCSS to provide

@ -175,7 +175,7 @@ void KSVGEcma::addEventListener(KSVGEcmaEventListener *listener)
void KSVGEcma::removeEventListener(KSVGEcmaEventListener *listener) void KSVGEcma::removeEventListener(KSVGEcmaEventListener *listener)
{ {
m_ecmaEventListeners.take(m_ecmaEventListeners.tqfind(listener)); m_ecmaEventListeners.take(m_ecmaEventListeners.find(listener));
if(m_ecmaEventListeners.count() == 0) if(m_ecmaEventListeners.count() == 0)
m_hasListeners = false; m_hasListeners = false;

@ -535,7 +535,7 @@ void WindowQObject::clearTimeout(int timerId, bool delAction)
if(delAction) if(delAction)
{ {
TQMapIterator<int, ScheduledAction *> it = scheduledActions.tqfind(timerId); TQMapIterator<int, ScheduledAction *> it = scheduledActions.find(timerId);
if(it != scheduledActions.end()) if(it != scheduledActions.end())
{ {
ScheduledAction *action = *it; ScheduledAction *action = *it;
@ -547,7 +547,7 @@ void WindowQObject::clearTimeout(int timerId, bool delAction)
void WindowQObject::timerEvent(TQTimerEvent *e) void WindowQObject::timerEvent(TQTimerEvent *e)
{ {
TQMapIterator<int, ScheduledAction *> it = scheduledActions.tqfind(e->timerId()); TQMapIterator<int, ScheduledAction *> it = scheduledActions.find(e->timerId());
if(it != scheduledActions.end()) if(it != scheduledActions.end())
{ {
ScheduledAction *action = *it; ScheduledAction *action = *it;

@ -36,7 +36,7 @@ public:
virtual ~MinOneLRUCache() {} virtual ~MinOneLRUCache() {}
void insert(const keyType& key, const valueType& value, int cost); void insert(const keyType& key, const valueType& value, int cost);
bool tqfind(const keyType& key, valueType& result); bool find(const keyType& key, valueType& result);
void setMaxTotalCost(int maxTotalCost); void setMaxTotalCost(int maxTotalCost);
int maxTotalCost() const { return m_maxTotalCost; } int maxTotalCost() const { return m_maxTotalCost; }
@ -63,7 +63,7 @@ protected:
typedef TQValueList<CacheItem> CacheItemList; typedef TQValueList<CacheItem> CacheItemList;
typename CacheItemList::iterator tqfind(const keyType& key); typename CacheItemList::iterator find(const keyType& key);
void enforceCostConstraint(); void enforceCostConstraint();
CacheItemList m_items; CacheItemList m_items;
@ -74,7 +74,7 @@ protected:
template<class keyType, class valueType> template<class keyType, class valueType>
void MinOneLRUCache<keyType, valueType>::insert(const keyType& key, const valueType& value, int cost) void MinOneLRUCache<keyType, valueType>::insert(const keyType& key, const valueType& value, int cost)
{ {
typename CacheItemList::iterator it = tqfind(key); typename CacheItemList::iterator it = find(key);
if(it != m_items.end()) if(it != m_items.end())
{ {
@ -91,10 +91,10 @@ void MinOneLRUCache<keyType, valueType>::insert(const keyType& key, const valueT
} }
template<class keyType, class valueType> template<class keyType, class valueType>
bool MinOneLRUCache<keyType, valueType>::tqfind(const keyType& key, valueType& result) bool MinOneLRUCache<keyType, valueType>::find(const keyType& key, valueType& result)
{ {
bool foundKey = false; bool foundKey = false;
typename CacheItemList::iterator it = tqfind(key); typename CacheItemList::iterator it = find(key);
if(it != m_items.end()) if(it != m_items.end())
{ {
@ -115,7 +115,7 @@ bool MinOneLRUCache<keyType, valueType>::tqfind(const keyType& key, valueType& r
} }
template<class keyType, class valueType> template<class keyType, class valueType>
typename MinOneLRUCache<keyType, valueType>::CacheItemList::iterator MinOneLRUCache<keyType, valueType>::tqfind(const keyType& key) typename MinOneLRUCache<keyType, valueType>::CacheItemList::iterator MinOneLRUCache<keyType, valueType>::find(const keyType& key)
{ {
typename CacheItemList::iterator it; typename CacheItemList::iterator it;

@ -127,7 +127,7 @@ void SVGAnimateElementImpl::handleTimerEvent()
{ {
/* m_from += m_addStep; /* m_from += m_addStep;
if(m_additive == "tqreplace" && needCombine) if(m_additive == "replace" && needCombine)
needCombine = false; needCombine = false;
applyAttribute(m_attributeName, TQString::number(m_from), needCombine); applyAttribute(m_attributeName, TQString::number(m_from), needCombine);

@ -129,7 +129,7 @@ void SVGAnimateTransformElementImpl::setAttributes()
{ {
TQString test = _values.string(); TQString test = _values.string();
if(test.tqcontains(";")) if(test.contains(";"))
{ {
SVGLengthImpl *temp = SVGSVGElementImpl::createSVGLength(); SVGLengthImpl *temp = SVGSVGElementImpl::createSVGLength();
@ -201,7 +201,7 @@ void SVGAnimateTransformElementImpl::handleTimerEvent(bool)
if(!m_lastTransform.isEmpty()) if(!m_lastTransform.isEmpty())
{ {
int pos = trans.tqfind(m_lastTransform); int pos = trans.find(m_lastTransform);
TQString extract; TQString extract;
extract += trans.mid(0, pos); extract += trans.mid(0, pos);

@ -69,12 +69,12 @@ void SVGAnimatedPointsImpl::parsePoints(TQString _points, SVGPointListImpl *poin
_points = _points.simplifyWhiteSpace(); _points = _points.simplifyWhiteSpace();
if(_points.tqcontains(",,") || _points.tqcontains(", ,")) if(_points.contains(",,") || _points.contains(", ,"))
return; return;
_points.tqreplace(',', ' '); _points.replace(',', ' ');
_points.tqreplace('\r', TQString()); _points.replace('\r', TQString());
_points.tqreplace('\n', TQString()); _points.replace('\n', TQString());
_points = _points.simplifyWhiteSpace(); _points = _points.simplifyWhiteSpace();

@ -84,8 +84,8 @@ double SVGAnimationElementImpl::parseClockValue(const TQString &data) const
double result; double result;
int doublePointOne = parse.tqfind(':'); int doublePointOne = parse.find(':');
int doublePointTwo = parse.tqfind(':', doublePointOne + 1); int doublePointTwo = parse.find(':', doublePointOne + 1);
if(doublePointOne != -1 && doublePointTwo != -1) // Spec: "Full clock values" if(doublePointOne != -1 && doublePointTwo != -1) // Spec: "Full clock values"
{ {
@ -96,7 +96,7 @@ double SVGAnimationElementImpl::parseClockValue(const TQString &data) const
result = (3600 * hours) + (60 * minutes) + seconds; result = (3600 * hours) + (60 * minutes) + seconds;
if(parse.tqfind('.') != -1) if(parse.find('.') != -1)
{ {
TQString temp = parse.mid(9, 2); TQString temp = parse.mid(9, 2);
milliseconds = temp.toUInt(); milliseconds = temp.toUInt();
@ -111,7 +111,7 @@ double SVGAnimationElementImpl::parseClockValue(const TQString &data) const
result = (60 * minutes) + seconds; result = (60 * minutes) + seconds;
if(parse.tqfind('.') != -1) if(parse.find('.') != -1)
{ {
TQString temp = parse.mid(6, 2); TQString temp = parse.mid(6, 2);
milliseconds = temp.toUInt(); milliseconds = temp.toUInt();
@ -120,7 +120,7 @@ double SVGAnimationElementImpl::parseClockValue(const TQString &data) const
} }
else // Spec: "Timecount values" else // Spec: "Timecount values"
{ {
int dotPosition = parse.tqfind('.'); int dotPosition = parse.find('.');
if(parse.endsWith("h")) if(parse.endsWith("h"))
{ {
@ -304,34 +304,34 @@ void SVGAnimationElementImpl::putValueProperty(ExecState *exec, int token, const
} }
else if(current.startsWith("wallclock")) else if(current.startsWith("wallclock"))
{ {
int firstBrace = current.tqfind("("); int firstBrace = current.find("(");
int secondBrace = current.tqfind(")"); int secondBrace = current.find(")");
TQString wallclockValue = current.mid(firstBrace + 1, secondBrace - firstBrace - 2); TQString wallclockValue = current.mid(firstBrace + 1, secondBrace - firstBrace - 2);
kdDebug() << "WALLCLOCK VALUE " << wallclockValue << endl; kdDebug() << "WALLCLOCK VALUE " << wallclockValue << endl;
} }
else if(current.tqcontains(".")) else if(current.contains("."))
{ {
int dotPosition = current.tqfind("."); int dotPosition = current.find(".");
TQString element = current.mid(0, dotPosition); TQString element = current.mid(0, dotPosition);
TQString clockValue; TQString clockValue;
if(current.tqcontains("begin")) if(current.contains("begin"))
clockValue = current.mid(dotPosition + 6); clockValue = current.mid(dotPosition + 6);
else if(current.tqcontains("end")) else if(current.contains("end"))
clockValue = current.mid(dotPosition + 4); clockValue = current.mid(dotPosition + 4);
else if(current.tqcontains("repeat")) else if(current.contains("repeat"))
clockValue = current.mid(dotPosition + 7); clockValue = current.mid(dotPosition + 7);
else // DOM2 Event Reference else // DOM2 Event Reference
{ {
int plusMinusPosition = -1; int plusMinusPosition = -1;
if(current.tqcontains("+")) if(current.contains("+"))
plusMinusPosition = current.tqfind("+"); plusMinusPosition = current.find("+");
else if(current.tqcontains("-")) else if(current.contains("-"))
plusMinusPosition = current.tqfind("-"); plusMinusPosition = current.find("-");
TQString event = current.mid(dotPosition + 1, plusMinusPosition - dotPosition - 1); TQString event = current.mid(dotPosition + 1, plusMinusPosition - dotPosition - 1);
@ -405,9 +405,9 @@ void SVGAnimationElementImpl::setAttributes()
{ {
SVGElementImpl::setAttributes(); SVGElementImpl::setAttributes();
// Spec: Default value is "tqreplace" // Spec: Default value is "replace"
if(KSVG_TOKEN_NOT_PARSED(Additive)) if(KSVG_TOKEN_NOT_PARSED(Additive))
KSVG_SET_ALT_ATTRIBUTE(Additive, "tqreplace") KSVG_SET_ALT_ATTRIBUTE(Additive, "replace")
// Spec: Default value is "none" // Spec: Default value is "none"
if(KSVG_TOKEN_NOT_PARSED(Accumulate)) if(KSVG_TOKEN_NOT_PARSED(Accumulate))

@ -398,7 +398,7 @@ void SVGColorImpl::setRGBColorICCColor(const DOM::DOMString &rgbColor, const DOM
TQColor color; TQColor color;
TQString content = iccColor.string().right(iccColor.string().length() - 10); TQString content = iccColor.string().right(iccColor.string().length() - 10);
TQString iccTarget = content.mid(0, content.tqfind(',')); TQString iccTarget = content.mid(0, content.find(','));
TQStringList colors = TQStringList::split(',', content); TQStringList colors = TQStringList::split(',', content);
TQString r = colors[1]; TQString r = colors[1];

@ -252,7 +252,7 @@ void SVGDocumentImpl::slotSVGContent(TQIODevice *dev)
args.getURLMode = false; args.getURLMode = false;
TQString url = m_baseURL.prettyURL(); TQString url = m_baseURL.prettyURL();
int pos = url.tqfind('#'); // url can become like this.svg#svgView(viewBox(63,226,74,74)), get part after '#' int pos = url.find('#'); // url can become like this.svg#svgView(viewBox(63,226,74,74)), get part after '#'
if(pos > -1) if(pos > -1)
args.SVGFragmentId = url.mid(pos + 1); args.SVGFragmentId = url.mid(pos + 1);
@ -358,7 +358,7 @@ void SVGDocumentImpl::checkFinishedLoading()
void SVGDocumentImpl::addForwardReferencingUseElement(SVGUseElementImpl *use) void SVGDocumentImpl::addForwardReferencingUseElement(SVGUseElementImpl *use)
{ {
if(!m_forwardReferencingUseElements.tqcontains(use)) if(!m_forwardReferencingUseElements.contains(use))
m_forwardReferencingUseElements.append(use); m_forwardReferencingUseElements.append(use);
} }

@ -74,7 +74,7 @@ using namespace KSVG;
isSupported SVGDOMNodeBridge::IsSupported DontDelete|Function 2 isSupported SVGDOMNodeBridge::IsSupported DontDelete|Function 2
addEventListener SVGDOMNodeBridge::AddEventListener DontDelete|Function 3 addEventListener SVGDOMNodeBridge::AddEventListener DontDelete|Function 3
removeEventListener SVGDOMNodeBridge::RemoveEventListener DontDelete|Function 3 removeEventListener SVGDOMNodeBridge::RemoveEventListener DontDelete|Function 3
tqcontains SVGDOMNodeBridge::Contains DontDelete|Function 1 contains SVGDOMNodeBridge::Contains DontDelete|Function 1
getNodeName SVGDOMNodeBridge::GetNodeName DontDelete|Function 0 getNodeName SVGDOMNodeBridge::GetNodeName DontDelete|Function 0
getNodeValue SVGDOMNodeBridge::GetNodeValue DontDelete|Function 0 getNodeValue SVGDOMNodeBridge::GetNodeValue DontDelete|Function 0
getNodeType SVGDOMNodeBridge::GetNodeType DontDelete|Function 0 getNodeType SVGDOMNodeBridge::GetNodeType DontDelete|Function 0
@ -178,10 +178,10 @@ void removeItem(ExecState *exec, DOM::Node &node)
void correctHandles(SVGElementImpl *main, DOM::Node &node) void correctHandles(SVGElementImpl *main, DOM::Node &node)
{ {
DOM::Element old(node.handle()); DOM::Element old(node.handle());
DOM::Element *tqreplace = static_cast<DOM::Element *>(main->ownerDoc()->getElementFromHandle(node.handle())); DOM::Element *replace = static_cast<DOM::Element *>(main->ownerDoc()->getElementFromHandle(node.handle()));
if(tqreplace && node.nodeType() == DOM::Node::ELEMENT_NODE) if(replace && node.nodeType() == DOM::Node::ELEMENT_NODE)
*tqreplace = old; *replace = old;
if(node.hasChildNodes()) if(node.hasChildNodes())
{ {
@ -556,7 +556,7 @@ Value SVGDOMElementBridgeProtoFunc::call(ExecState *exec, Object &thisObj, const
{ {
// For now, we strip the NS part (Rob) // For now, we strip the NS part (Rob)
DOM::DOMString attr = args[1].toString(exec).string(); DOM::DOMString attr = args[1].toString(exec).string();
int pos = attr.string().tqfind(':'); int pos = attr.string().find(':');
if(pos > -1) if(pos > -1)
attr = attr.string().mid(pos + 1); attr = attr.string().mid(pos + 1);

@ -328,7 +328,7 @@ TQDict<DOM::DOMString> &SVGElementImpl::attributes()
// khtml overrides // khtml overrides
void SVGElementImpl::setAttribute(const DOM::DOMString &name, const DOM::DOMString &value) void SVGElementImpl::setAttribute(const DOM::DOMString &name, const DOM::DOMString &value)
{ {
m_attributes.tqreplace(name.string(), new DOM::DOMString(value)); m_attributes.replace(name.string(), new DOM::DOMString(value));
} }
// Changes internal value. This will have no effect on getAttribute(). // Changes internal value. This will have no effect on getAttribute().
@ -368,7 +368,7 @@ DOM::DOMString SVGElementImpl::getAttributeInternal(const DOM::DOMString &name)
bool SVGElementImpl::hasAttribute(const DOM::DOMString &name) bool SVGElementImpl::hasAttribute(const DOM::DOMString &name)
{ {
return m_attributes.tqfind(name.string()) != 0; return m_attributes.find(name.string()) != 0;
} }
bool SVGElementImpl::hasAttributes() bool SVGElementImpl::hasAttributes()

@ -75,7 +75,7 @@ void SVGFitToViewBoxImpl::parseViewBox(const TQString &s)
// allow for viewbox def with ',' or whitespace // allow for viewbox def with ',' or whitespace
TQString viewbox(s); TQString viewbox(s);
TQStringList points = TQStringList::split(' ', viewbox.tqreplace(',', ' ').simplifyWhiteSpace()); TQStringList points = TQStringList::split(' ', viewbox.replace(',', ' ').simplifyWhiteSpace());
viewBox()->baseVal()->setX(points[0].toFloat()); viewBox()->baseVal()->setX(points[0].toFloat());
viewBox()->baseVal()->setY(points[1].toFloat()); viewBox()->baseVal()->setY(points[1].toFloat());

@ -380,7 +380,7 @@ bool SVGImageElementImpl::prepareMouseEvent(const TQPoint &p, const TQPoint &, S
if(test && m_item) if(test && m_item)
{ {
if(m_item->bbox().tqcontains(p)) if(m_item->bbox().contains(p))
{ {
mev->setTarget(dynamic_cast<SVGElementImpl *>(this)); mev->setTarget(dynamic_cast<SVGElementImpl *>(this));
return true; return true;

@ -67,19 +67,19 @@ TQString SVGLangSpaceImpl::handleText(const TQString &data) const
{ {
// Spec: What to do here? // Spec: What to do here?
// It will convert all newline and tab characters into space characters // It will convert all newline and tab characters into space characters
result.tqreplace("\n\r", TQString(" ")); result.replace("\n\r", TQString(" "));
result.tqreplace("\r\n", TQString(" ")); result.replace("\r\n", TQString(" "));
result.tqreplace('\t', ' '); result.replace('\t', ' ');
} }
else if(xmlspace() == "default") else if(xmlspace() == "default")
{ {
// Spec: What to do here? // Spec: What to do here?
// First, it will remove all newline characters (tqreplace) // First, it will remove all newline characters (replace)
// Then it will convert all tab characters into space characters (simplifyWhiteSpace) // Then it will convert all tab characters into space characters (simplifyWhiteSpace)
// Then, it will strip off all leading and trailing space characters (stripWhiteSpace) // Then, it will strip off all leading and trailing space characters (stripWhiteSpace)
// Then, all contiguous space characters will be consolidated. (simplifyWhiteSpace) // Then, all contiguous space characters will be consolidated. (simplifyWhiteSpace)
result.tqreplace('\n', TQString()); result.replace('\n', TQString());
result.tqreplace('\r', TQString()); result.replace('\r', TQString());
result = result.stripWhiteSpace().simplifyWhiteSpace(); result = result.stripWhiteSpace().simplifyWhiteSpace();
} }

@ -420,7 +420,7 @@ SVGMaskElementImpl::Mask SVGMaskElementImpl::createMask(SVGShapeImpl *referencin
{ {
CacheKey key(referencingElement, imageWidth, imageHeight); CacheKey key(referencingElement, imageWidth, imageHeight);
if(!m_maskCache.tqfind(key, tqmask)) if(!m_maskCache.find(key, tqmask))
{ {
tqmask = createMask(referencingElement, imageWidth, imageHeight); tqmask = createMask(referencingElement, imageWidth, imageHeight);
m_maskCache.insert(key, tqmask, imageWidth * imageHeight); m_maskCache.insert(key, tqmask, imageWidth * imageHeight);

@ -486,7 +486,7 @@ SVGPatternElementImpl::Tile SVGPatternElementImpl::createTile(SVGShapeImpl *refe
TQSize size(imageWidth, imageHeight); TQSize size(imageWidth, imageHeight);
TQImage image; TQImage image;
if(!m_tileCache.tqfind(size, image)) if(!m_tileCache.find(size, image))
{ {
image = createTile(referencingElement, imageWidth, imageHeight); image = createTile(referencingElement, imageWidth, imageHeight);
m_tileCache.insert(size, image, image.width() * image.height() * 4); m_tileCache.insert(size, image, image.width() * image.height() * 4);

@ -382,7 +382,7 @@ DOM::NodeList SVGSVGElementImpl::getEnclosureList(SVGRectImpl *rect, SVGElementI
{ {
// TODO : add the tqshape to list if the test succeeds // TODO : add the tqshape to list if the test succeeds
SVGRectImpl *current = tqshape->getBBox(); SVGRectImpl *current = tqshape->getBBox();
if(rect->qrect().tqcontains(current->qrect(), true)) if(rect->qrect().contains(current->qrect(), true))
kdDebug() << "tqshape : " << element->nodeName().string() << " is fully enclosed" << endl; kdDebug() << "tqshape : " << element->nodeName().string() << " is fully enclosed" << endl;
current->deref(); current->deref();
@ -412,7 +412,7 @@ bool SVGSVGElementImpl::checkEnclosure(SVGElementImpl *element, SVGRectImpl *rec
return false; return false;
SVGRectImpl *current = tqshape->getBBox(); SVGRectImpl *current = tqshape->getBBox();
bool result = rect->qrect().tqcontains(current->qrect()); bool result = rect->qrect().contains(current->qrect());
current->deref(); current->deref();
return result; return result;
} }

@ -532,7 +532,7 @@ TQString SVGStylableImpl::extractUrlId(const TQString &url)
if(url.startsWith("url(#")) if(url.startsWith("url(#"))
{ {
int idstart = url.tqfind("#") + 1; int idstart = url.find("#") + 1;
id = url.mid(idstart, url.length() - idstart - 1); id = url.mid(idstart, url.length() - idstart - 1);
} }
else else
@ -552,7 +552,7 @@ void SVGStylableImpl::setStartMarker(const TQString &startMarker)
{ {
if(startMarker.startsWith("url(#")) if(startMarker.startsWith("url(#"))
{ {
int idstart = startMarker.tqfind("#") + 1; int idstart = startMarker.find("#") + 1;
m_startMarker = startMarker.mid(idstart, startMarker.length() - idstart - 1); m_startMarker = startMarker.mid(idstart, startMarker.length() - idstart - 1);
} }
else if(startMarker == "none") else if(startMarker == "none")
@ -563,7 +563,7 @@ void SVGStylableImpl::setMidMarker(const TQString &midMarker)
{ {
if(midMarker.startsWith("url(#")) if(midMarker.startsWith("url(#"))
{ {
int idstart = midMarker.tqfind("#") + 1; int idstart = midMarker.find("#") + 1;
m_midMarker = midMarker.mid(idstart, midMarker.length() - idstart - 1); m_midMarker = midMarker.mid(idstart, midMarker.length() - idstart - 1);
} }
else if(midMarker == "none") else if(midMarker == "none")
@ -574,7 +574,7 @@ void SVGStylableImpl::setEndMarker(const TQString &endMarker)
{ {
if(endMarker.startsWith("url(#")) if(endMarker.startsWith("url(#"))
{ {
int idstart = endMarker.tqfind("#") + 1; int idstart = endMarker.find("#") + 1;
m_endMarker = endMarker.mid(idstart, endMarker.length() - idstart - 1); m_endMarker = endMarker.mid(idstart, endMarker.length() - idstart - 1);
} }
else if(endMarker == "none") else if(endMarker == "none")
@ -600,7 +600,7 @@ void SVGStylableImpl::setColor(const TQString &param, SVGColorImpl *svgColor)
{ {
if(param.stripWhiteSpace().startsWith("#")) if(param.stripWhiteSpace().startsWith("#"))
{ {
if(param.tqcontains("icc-color")) if(param.contains("icc-color"))
{ {
TQString first = param.left(7); TQString first = param.left(7);
TQString last = param.right(param.length() - 8); TQString last = param.right(param.length() - 8);
@ -622,19 +622,19 @@ void SVGStylableImpl::setColor(const TQString &param, SVGColorImpl *svgColor)
TQString g = colors[1]; TQString g = colors[1];
TQString b = colors[2].left((colors[2].length() - 1)); TQString b = colors[2].left((colors[2].length() - 1));
if(r.tqcontains("%")) if(r.contains("%"))
{ {
r = r.left(r.length() - 1); r = r.left(r.length() - 1);
r = TQString::number(int((double(255 * r.toDouble()) / 100.0))); r = TQString::number(int((double(255 * r.toDouble()) / 100.0)));
} }
if(g.tqcontains("%")) if(g.contains("%"))
{ {
g = g.left(g.length() - 1); g = g.left(g.length() - 1);
g = TQString::number(int((double(255 * g.toDouble()) / 100.0))); g = TQString::number(int((double(255 * g.toDouble()) / 100.0)));
} }
if(b.tqcontains("%")) if(b.contains("%"))
{ {
b = b.left(b.length() - 1); b = b.left(b.length() - 1);
b = TQString::number(int((double(255 * b.toDouble()) / 100.0))); b = TQString::number(int((double(255 * b.toDouble()) / 100.0)));
@ -946,12 +946,12 @@ void SVGStylableImpl::putValueProperty(ExecState *exec, int token, const Value &
// Hacks // Hacks
// #1 Replace "'" characters by "" // #1 Replace "'" characters by ""
param = param.tqreplace('\'', TQString()); param = param.replace('\'', TQString());
// #2 Replace "MS-Gothic" by "MS Gothic" // #2 Replace "MS-Gothic" by "MS Gothic"
param = param.tqreplace("MS-Gothic", "MS Gothic"); param = param.replace("MS-Gothic", "MS Gothic");
// #3 Replace "Helvetica" by "Arial" // #3 Replace "Helvetica" by "Arial"
param = param.tqreplace("Helvetica", "Arial"); param = param.replace("Helvetica", "Arial");
param = param.tqreplace("helvetica", "Arial"); param = param.replace("helvetica", "Arial");
if(!m_fontFamily) if(!m_fontFamily)
{ {

@ -111,7 +111,7 @@ bool SVGTextElementImpl::prepareMouseEvent(const TQPoint &p, const TQPoint &, SV
if(test) if(test)
{ {
if(m_item->bbox().tqcontains(p)) if(m_item->bbox().contains(p))
{ {
mev->setTarget(dynamic_cast<SVGElementImpl *>(this)); mev->setTarget(dynamic_cast<SVGElementImpl *>(this));
return true; return true;

@ -92,7 +92,7 @@ void SVGTimer::notifyAll()
animation->handleTimerEvent(); animation->handleTimerEvent();
SVGElementImpl *target = animation->targetElement(); SVGElementImpl *target = animation->targetElement();
if(!elements.tqcontains(target)) if(!elements.contains(target))
elements.append(target); elements.append(target);
} }
} }

@ -50,7 +50,7 @@ SVGAnimatedStringImpl *SVGURIReferenceImpl::href() const
bool SVGURIReferenceImpl::parseURIReference(const TQString &urireference, TQString &uri, TQString &elementreference) bool SVGURIReferenceImpl::parseURIReference(const TQString &urireference, TQString &uri, TQString &elementreference)
{ {
int seperator = urireference.tqfind("#"); int seperator = urireference.find("#");
if(seperator == -1) if(seperator == -1)
return false; return false;
@ -71,14 +71,14 @@ TQString SVGURIReferenceImpl::getTarget(const TQString &url)
{ {
if(url.startsWith("url(")) // URI References, ie. fill:url(#target) if(url.startsWith("url(")) // URI References, ie. fill:url(#target)
{ {
unsigned int start = url.tqfind("#") + 1; unsigned int start = url.find("#") + 1;
unsigned int end = url.tqfindRev(")"); unsigned int end = url.findRev(")");
return url.mid(start, end - start); return url.mid(start, end - start);
} }
else if(url.tqfind("#") > -1) // format is #target else if(url.find("#") > -1) // format is #target
{ {
unsigned int start = url.tqfind("#") + 1; unsigned int start = url.find("#") + 1;
return url.mid(start, url.length() - start); return url.mid(start, url.length() - start);
} }

@ -48,7 +48,7 @@ public:
void modify(SVGAnimatedLengthImpl *obj, const TQString &value) void modify(SVGAnimatedLengthImpl *obj, const TQString &value)
{ {
UnitData *data = m_dict.tqfind(obj); UnitData *data = m_dict.find(obj);
if(data) if(data)
data->valueAsString = value; data->valueAsString = value;

@ -31,8 +31,8 @@ make -j
make install-strip DESTDIR=$RPM_BUILD_ROOT make install-strip DESTDIR=$RPM_BUILD_ROOT
cd cd
tqfind . -type d | sed '1,2d;s,^\.,\%attr(-\,root\,root) \%dir ,' > /%{name}-master.list find . -type d | sed '1,2d;s,^\.,\%attr(-\,root\,root) \%dir ,' > /%{name}-master.list
tqfind . -type f -o -type l | sed 's|^\.||' >> $RPM_BUILD_DIR/%{name}-master.list find . -type f -o -type l | sed 's|^\.||' >> $RPM_BUILD_DIR/%{name}-master.list
%clean %clean
rm -rf $RPM_BUILD_DIR/%{name}-%{version} rm -rf $RPM_BUILD_DIR/%{name}-%{version}

@ -118,7 +118,7 @@ namespace T2P
} }
// Lookup entry // Lookup entry
SharedT tqfind(const std::string &key) SharedT find(const std::string &key)
{ {
for(typename std::vector<SharedT>::const_iterator it = m_entries.begin(); it != m_entries.end(); ++it) for(typename std::vector<SharedT>::const_iterator it = m_entries.begin(); it != m_entries.end(); ++it)
{ {

@ -90,7 +90,7 @@ void Converter::setKerning(bool mode)
SharedFont Converter::requestFont(const FontVisualParams *params) SharedFont Converter::requestFont(const FontVisualParams *params)
{ {
std::string cacheKey = cacheFontKey(params); std::string cacheKey = cacheFontKey(params);
SharedFont cached = m_fontCache.tqfind(cacheKey); SharedFont cached = m_fontCache.find(cacheKey);
// If not available in cache, create new one and cache it :) // If not available in cache, create new one and cache it :)
if(cached) if(cached)
@ -122,7 +122,7 @@ GlyphAffinePair *Converter::requestGlyph(GlyphRenderParams *params, Rectangle &b
// needed to generate the cache lookup key // needed to generate the cache lookup key
selectGlyph(params); selectGlyph(params);
SharedGlyph cached = m_glyphCache.tqfind(cacheGlyphKey(params)); SharedGlyph cached = m_glyphCache.find(cacheGlyphKey(params));
// If not available in cache, render new one and cache it :) // If not available in cache, render new one and cache it :)
// If we're mixing ie. japanese and latin characters (TTB tqlayout), // If we're mixing ie. japanese and latin characters (TTB tqlayout),

@ -100,7 +100,7 @@ SVGPathParser::parseSVG( const TQString &s, bool process )
if(!s.isEmpty()) if(!s.isEmpty())
{ {
TQString d = s; TQString d = s;
d = d.tqreplace(',', ' '); d = d.replace(',', ' ');
d = d.simplifyWhiteSpace(); d = d.simplifyWhiteSpace();
const char *ptr = d.latin1(); const char *ptr = d.latin1();
const char *end = d.latin1() + d.length() + 1; const char *end = d.latin1() + d.length() + 1;

@ -1064,29 +1064,29 @@ void LibartPath::init(const SVGMatrixImpl *screenCTM)
double cury = m_array[index - 1].y3; double cury = m_array[index - 1].y3;
// Find last subpath // Find last subpath
int tqfind = -1; int find = -1;
for(int i = index - 1; i >= 0; i--) for(int i = index - 1; i >= 0; i--)
{ {
if(m_array[i].code == ART_MOVETO_OPEN || m_array[i].code == ART_MOVETO) if(m_array[i].code == ART_MOVETO_OPEN || m_array[i].code == ART_MOVETO)
{ {
tqfind = i; find = i;
break; break;
} }
} }
// Fix a problem where the .svg file used floats as values... (sofico.svg) // Fix a problem where the .svg file used floats as values... (sofico.svg)
if(curx != m_array[tqfind].x3 && cury != m_array[tqfind].y3) if(curx != m_array[find].x3 && cury != m_array[find].y3)
{ {
if((int) curx == (int) m_array[tqfind].x3 && (int) cury == (int) m_array[tqfind].y3) if((int) curx == (int) m_array[find].x3 && (int) cury == (int) m_array[find].y3)
{ {
ensureSpace(m_array, index) ensureSpace(m_array, index)
m_array[index].code = ART_LINETO; m_array[index].code = ART_LINETO;
m_array[index].x3 = m_array[tqfind].x3; m_array[index].x3 = m_array[find].x3;
m_array[index].y3 = m_array[tqfind].y3; m_array[index].y3 = m_array[find].y3;
curx = m_array[tqfind].x3; curx = m_array[find].x3;
cury = m_array[tqfind].y3; cury = m_array[find].y3;
index++; index++;
} }
@ -1095,16 +1095,16 @@ void LibartPath::init(const SVGMatrixImpl *screenCTM)
// handle filled paths that are not closed explicitly // handle filled paths that are not closed explicitly
if(m_path->getFillColor()->paintType() != SVG_PAINTTYPE_NONE) if(m_path->getFillColor()->paintType() != SVG_PAINTTYPE_NONE)
{ {
if((int) curx != (int) m_array[tqfind].x3 || (int) cury != (int) m_array[tqfind].y3) if((int) curx != (int) m_array[find].x3 || (int) cury != (int) m_array[find].y3)
{ {
ensureSpace(m_array, index) ensureSpace(m_array, index)
m_array[index].code = (ArtPathcode)ART_END2; m_array[index].code = (ArtPathcode)ART_END2;
m_array[index].x3 = m_array[tqfind].x3; m_array[index].x3 = m_array[find].x3;
m_array[index].y3 = m_array[tqfind].y3; m_array[index].y3 = m_array[find].y3;
curx = m_array[tqfind].x3; curx = m_array[find].x3;
cury = m_array[tqfind].y3; cury = m_array[find].y3;
index++; index++;
} }
@ -1147,12 +1147,12 @@ void LibartPath::svgMoveTo(double x1, double y1, bool closed, bool)
if(index > 0 && !closed) if(index > 0 && !closed)
{ {
// Find last subpath // Find last subpath
int tqfind = -1; int find = -1;
for(int i = index - 1; i >= 0; i--) for(int i = index - 1; i >= 0; i--)
{ {
if(m_array[i].code == ART_MOVETO_OPEN || m_array[i].code == ART_MOVETO) if(m_array[i].code == ART_MOVETO_OPEN || m_array[i].code == ART_MOVETO)
{ {
tqfind = i; find = i;
break; break;
} }
} }
@ -1160,8 +1160,8 @@ void LibartPath::svgMoveTo(double x1, double y1, bool closed, bool)
ensureSpace(m_array, index) ensureSpace(m_array, index)
m_array[index].code = (ArtPathcode) ART_END2; m_array[index].code = (ArtPathcode) ART_END2;
m_array[index].x3 = m_array[tqfind].x3; m_array[index].x3 = m_array[find].x3;
m_array[index].y3 = m_array[tqfind].y3; m_array[index].y3 = m_array[find].y3;
index++; index++;
} }
@ -1205,25 +1205,25 @@ void LibartPath::svgClosePath()
double curx = m_array[index - 1].x3; double curx = m_array[index - 1].x3;
double cury = m_array[index - 1].y3; double cury = m_array[index - 1].y3;
int tqfind = -1; int find = -1;
for(int i = index - 1; i >= 0; i--) for(int i = index - 1; i >= 0; i--)
{ {
if(m_array[i].code == ART_MOVETO_OPEN || m_array[i].code == ART_MOVETO) if(m_array[i].code == ART_MOVETO_OPEN || m_array[i].code == ART_MOVETO)
{ {
tqfind = i; find = i;
break; break;
} }
} }
if(tqfind != -1) if(find != -1)
{ {
if(m_array[tqfind].x3 != curx || m_array[tqfind].y3 != cury) if(m_array[find].x3 != curx || m_array[find].y3 != cury)
{ {
ensureSpace(m_array, index) ensureSpace(m_array, index)
m_array[index].code = ART_LINETO; m_array[index].code = ART_LINETO;
m_array[index].x3 = m_array[tqfind].x3; m_array[index].x3 = m_array[find].x3;
m_array[index].y3 = m_array[tqfind].y3; m_array[index].y3 = m_array[find].y3;
} }
} }
} }
@ -1505,10 +1505,10 @@ void LibartText::update(CanvasItemUpdate reason, int param1, int param2)
bool strokeOk = stroke && stroke->svp && text->isStroked() && text->getStrokeWidth()->baseVal()->value() > 0; // Spec: A zero value causes no stroke to be painted. bool strokeOk = stroke && stroke->svp && text->isStroked() && text->getStrokeWidth()->baseVal()->value() > 0; // Spec: A zero value causes no stroke to be painted.
if(fillOk || strokeOk) if(fillOk || strokeOk)
{ {
if(m_fillPainters.tqfind(text)) if(m_fillPainters.find(text))
m_fillPainters[text]->update(text); m_fillPainters[text]->update(text);
if(m_strokePainters.tqfind(text)) if(m_strokePainters.find(text))
m_strokePainters[text]->update(text); m_strokePainters[text]->update(text);
} }
fill = ++it1; fill = ++it1;
@ -1574,10 +1574,10 @@ void LibartText::draw()
if(fillOk || strokeOk) if(fillOk || strokeOk)
{ {
if(fillOk && m_fillPainters.tqfind(text)) if(fillOk && m_fillPainters.find(text))
m_fillPainters[text]->draw(m_canvas, fill->svp, text, text); m_fillPainters[text]->draw(m_canvas, fill->svp, text, text);
if(strokeOk && m_strokePainters.tqfind(text)) if(strokeOk && m_strokePainters.find(text))
m_strokePainters[text]->draw(m_canvas, stroke->svp, text, text); m_strokePainters[text]->draw(m_canvas, stroke->svp, text, text);
} }
fill = ++it1; fill = ++it1;
@ -1655,11 +1655,11 @@ void LibartText::renderCallback(SVGTextContentElementImpl *element, const SVGMat
m_drawFillItems.append(fillElement); m_drawFillItems.append(fillElement);
m_drawStrokeItems.append(strokeElement); m_drawStrokeItems.append(strokeElement);
if(!m_fillPainters.tqfind(element) && element->isFilled()) if(!m_fillPainters.find(element) && element->isFilled())
m_fillPainters.insert(element, new LibartFillPainter(element)); m_fillPainters.insert(element, new LibartFillPainter(element));
// Spec: A zero value causes no stroke to be painted. // Spec: A zero value causes no stroke to be painted.
if(!m_strokePainters.tqfind(element) && element->isStroked() && element->getStrokeWidth()->baseVal()->value() > 0) if(!m_strokePainters.find(element) && element->isStroked() && element->getStrokeWidth()->baseVal()->value() > 0)
m_strokePainters.insert(element, new LibartStrokePainter(element)); m_strokePainters.insert(element, new LibartStrokePainter(element));
} }
} }
@ -1734,7 +1734,7 @@ void LibartText::addTextDecoration(SVGTextContentElementImpl *element, double x,
m_drawFillItems.append(fillElement); m_drawFillItems.append(fillElement);
if(!m_fillPainters.tqfind(element) && element->isFilled()) if(!m_fillPainters.find(element) && element->isFilled())
m_fillPainters.insert(element, new LibartFillPainter(element)); m_fillPainters.insert(element, new LibartFillPainter(element));
art_svp_free(temp); art_svp_free(temp);
@ -1752,7 +1752,7 @@ void LibartText::addTextDecoration(SVGTextContentElementImpl *element, double x,
m_drawStrokeItems.append(strokeElement); m_drawStrokeItems.append(strokeElement);
// Spec: A zero value causes no stroke to be painted. // Spec: A zero value causes no stroke to be painted.
if(!m_strokePainters.tqfind(element) && element->isStroked() && element->getStrokeWidth()->baseVal()->value() > 0) if(!m_strokePainters.find(element) && element->isStroked() && element->getStrokeWidth()->baseVal()->value() > 0)
m_strokePainters.insert(element, new LibartStrokePainter(element)); m_strokePainters.insert(element, new LibartStrokePainter(element));
} }
art_free(vec); art_free(vec);

@ -88,9 +88,9 @@ my %counter2;
my %counter3; my %counter3;
# Read hashtable size # Read hashtable size
my $readSize1 = `tqfind -type f | xargs grep -I DontDelete | grep -v KSVG:: | grep Function`; my $readSize1 = `find -type f | xargs grep -I DontDelete | grep -v KSVG:: | grep Function`;
my $readSize2 = `tqfind -type f | xargs grep -I DontDelete | grep -v KSVG:: | grep -v Function`; my $readSize2 = `find -type f | xargs grep -I DontDelete | grep -v KSVG:: | grep -v Function`;
my $readSize3 = `tqfind -type f | xargs grep -I DontDelete | grep KSVG::`; my $readSize3 = `find -type f | xargs grep -I DontDelete | grep KSVG::`;
my @result1 = split(/.\//, $readSize1); my @result1 = split(/.\//, $readSize1);
my @result2 = split(/.\//, $readSize2); my @result2 = split(/.\//, $readSize2);
@ -100,9 +100,9 @@ my @result3 = split(/.\//, $readSize3);
# calcSize1 = print out all prototype hashtables # calcSize1 = print out all prototype hashtables
# calcSize2 = print out all non-prototype hashtables # calcSize2 = print out all non-prototype hashtables
# calcSize3 = print out all svg*constructors hashtables # calcSize3 = print out all svg*constructors hashtables
my $calcSize1 = `tqfind -type f | xargs grep -I s_hashTable | grep \@begin | grep -v generateddata | grep -v Constructor | grep -v Impl:: | grep -v Bridge::`; my $calcSize1 = `find -type f | xargs grep -I s_hashTable | grep \@begin | grep -v generateddata | grep -v Constructor | grep -v Impl:: | grep -v Bridge::`;
my $calcSize2 = `tqfind -type f | xargs grep -I s_hashTable | grep \@begin | grep -v generateddata | grep -v Constructor | grep -v Proto::`; my $calcSize2 = `find -type f | xargs grep -I s_hashTable | grep \@begin | grep -v generateddata | grep -v Constructor | grep -v Proto::`;
my $calcSize3 = `tqfind -type f | xargs grep -I s_hashTable | grep \@begin | grep -v generateddata | grep Constructor`; my $calcSize3 = `find -type f | xargs grep -I s_hashTable | grep \@begin | grep -v generateddata | grep Constructor`;
# Bring in suitable form # Bring in suitable form
calcSize($calcSize1, \%counter1, 5); calcSize($calcSize1, \%counter1, 5);

@ -26,7 +26,7 @@ my %excludes = (
# List headers, and exclude the ones listed above # List headers, and exclude the ones listed above
my @headers = (); my @headers = ();
my $incdir=$here; my $incdir=$here;
opendir (INCS, $incdir) or die "Couldn't tqfind $incdir"; opendir (INCS, $incdir) or die "Couldn't find $incdir";
foreach $filename (readdir(INCS)) { foreach $filename (readdir(INCS)) {
$entry = $incdir."/".$filename; $entry = $incdir."/".$filename;
if ( ( -e $entry or -l $entry ) # A real file or a symlink if ( ( -e $entry or -l $entry ) # A real file or a symlink

@ -55,11 +55,11 @@ make install DESTDIR=$RPM_BUILD_ROOT
cd $RPM_BUILD_ROOT cd $RPM_BUILD_ROOT
tqfind . -type d | sed '1,2d;s,^\.,\%attr(-\,root\,root) \%dir ,' > $RPM_BUILD_DIR/file.list.%{name} find . -type d | sed '1,2d;s,^\.,\%attr(-\,root\,root) \%dir ,' > $RPM_BUILD_DIR/file.list.%{name}
tqfind . -type f | sed 's,^\.,\%attr(-\,root\,root) ,' >> $RPM_BUILD_DIR/file.list.%{name} find . -type f | sed 's,^\.,\%attr(-\,root\,root) ,' >> $RPM_BUILD_DIR/file.list.%{name}
tqfind . -type l | sed 's,^\.,\%attr(-\,root\,root) ,' >> $RPM_BUILD_DIR/file.list.%{name} find . -type l | sed 's,^\.,\%attr(-\,root\,root) ,' >> $RPM_BUILD_DIR/file.list.%{name}
%clean %clean
rm -rf $RPM_BUILD_ROOT rm -rf $RPM_BUILD_ROOT

@ -84,7 +84,7 @@ bool AboutWidget::eventFilter( TQObject *o, TQEvent *e )
{ {
if ( e->type() == TQEvent::MouseButtonPress ) { if ( e->type() == TQEvent::MouseButtonPress ) {
TQMouseEvent *ev = TQT_TQMOUSEEVENT( e ); TQMouseEvent *ev = TQT_TQMOUSEEVENT( e );
if ( !m_homepage->tqgeometry().tqcontains( ev->pos() ) ) { if ( !m_homepage->tqgeometry().contains( ev->pos() ) ) {
deleteLater(); deleteLater();
return true; return true;
} }

@ -42,7 +42,7 @@ FileCache * FileCache::self()
KuickFile * FileCache::getFile( const KURL& url ) KuickFile * FileCache::getFile( const KURL& url )
{ {
TQString urlString = url.prettyURL(); TQString urlString = url.prettyURL();
KuickFile *file = m_files.tqfind( urlString ); KuickFile *file = m_files.find( urlString );
if ( !file ) { if ( !file ) {
file = new KuickFile( url ); file = new KuickFile( url );
m_files.insert( urlString, file ); m_files.insert( urlString, file );

@ -99,7 +99,7 @@ void FileWidget::initActions()
TQPopupMenu *pMenu = menu->popupMenu(); TQPopupMenu *pMenu = menu->popupMenu();
int lastItemId = pMenu->idAt( pMenu->count() - 1 ); int lastItemId = pMenu->idAt( pMenu->count() - 1 );
TQMenuItem *mItem = pMenu->tqfindItem( lastItemId ); TQMenuItem *mItem = pMenu->findItem( lastItemId );
if ( mItem && !mItem->isSeparator() ) if ( mItem && !mItem->isSeparator() )
menu->insert( sep ); menu->insert( sep );
@ -152,7 +152,7 @@ void FileWidget::activatedMenu( const KFileItem *item, const TQPoint& pos )
void FileWidget::findCompletion( const TQString& text ) void FileWidget::findCompletion( const TQString& text )
{ {
if ( text.at(0) == '/' || text.at(0) == '~' || if ( text.at(0) == '/' || text.at(0) == '~' ||
text.tqfind('/') != -1 ) { text.find('/') != -1 ) {
TQString t = m_fileFinder->completion()->makeCompletion( text ); TQString t = m_fileFinder->completion()->makeCompletion( text );
if (m_fileFinder->completionMode() == KGlobalSettings::CompletionPopup || if (m_fileFinder->completionMode() == KGlobalSettings::CompletionPopup ||
@ -399,7 +399,7 @@ void FileWidget::slotReturnPressed( const TQString& t )
setURL( url, true ); setURL( url, true );
} }
else if ( text.tqfind('/') != (int) text.length() -1 ) { // relative path else if ( text.find('/') != (int) text.length() -1 ) { // relative path
TQString dir = m_fileFinder->completion()->replacedPath( text ); TQString dir = m_fileFinder->completion()->replacedPath( text );
KURL u( url(), dir ); KURL u( url(), dir );
setURL( u, true ); setURL( u, true );

@ -602,7 +602,7 @@ KuickImage * ImageCache::getKuimage( KuickFile * file,
return 0L; return 0L;
KuickImage *kuim = 0L; KuickImage *kuim = 0L;
int index = fileList.tqfindIndex( file ); int index = fileList.findIndex( file );
if ( index != -1 ) { if ( index != -1 ) {
if ( index == 0 ) if ( index == 0 )
kuim = kuickList.at( 0 ); kuim = kuickList.at( 0 );

@ -67,7 +67,7 @@ bool KuickFile::download()
TQString ext; TQString ext;
TQString fileName = m_url.fileName(); TQString fileName = m_url.fileName();
int extIndex = fileName.tqfindRev('.'); int extIndex = fileName.findRev('.');
if ( extIndex > 0 ) if ( extIndex > 0 )
ext = fileName.mid( extIndex + 1 ); ext = fileName.mid( extIndex + 1 );

@ -319,7 +319,7 @@ void KuickShow::initGUI( const KURL& startDir )
TQPopupMenu *mainPopup = mainActionMenu->popupMenu(); TQPopupMenu *mainPopup = mainActionMenu->popupMenu();
int sortingIndex = mainPopup->indexOf( sortingMenu->itemId( 0 ) ); int sortingIndex = mainPopup->indexOf( sortingMenu->itemId( 0 ) );
int separatorId = mainPopup->idAt( sortingIndex + 1 ); int separatorId = mainPopup->idAt( sortingIndex + 1 );
TQMenuItem *separatorItem = mainPopup->tqfindItem( separatorId ); TQMenuItem *separatorItem = mainPopup->findItem( separatorId );
if ( separatorItem && separatorItem->isSeparator() ) if ( separatorItem && separatorItem->isSeparator() )
mainPopup->removeItem( separatorId ); mainPopup->removeItem( separatorId );
mainActionMenu->remove( sortingMenu ); mainActionMenu->remove( sortingMenu );

@ -183,7 +183,7 @@ TQString Printing::minimizeString( TQString text, const TQFontMetrics&
if ( mid <= 5 ) // sanity check if ( mid <= 5 ) // sanity check
return TQString(); return TQString();
text.tqreplace( mid - 1, 3, "..." ); text.replace( mid - 1, 3, "..." );
} }
return text; return text;

@ -499,9 +499,9 @@ void KView::setupActions( TQObject * partobject )
if( extension ) if( extension )
{ {
TQStrList slotNames = extension->tqmetaObject()->slotNames(); TQStrList slotNames = extension->tqmetaObject()->slotNames();
if( slotNames.tqcontains( "print()" ) ) if( slotNames.contains( "print()" ) )
KStdAction::print( extension, TQT_SLOT( print() ), actionCollection(), "print" ); KStdAction::print( extension, TQT_SLOT( print() ), actionCollection(), "print" );
if( slotNames.tqcontains( "del()" ) ) if( slotNames.contains( "del()" ) )
( void )new KAction( i18n( "&Delete" ), "editdelete", SHIFT+Key_Delete, ( void )new KAction( i18n( "&Delete" ), "editdelete", SHIFT+Key_Delete,
extension, TQT_SLOT( del() ), actionCollection(), "del" ); extension, TQT_SLOT( del() ), actionCollection(), "del" );
connect( extension, TQT_SIGNAL( enableAction( const char *, bool ) ), TQT_SLOT( enableAction( const char *, bool ) ) ); connect( extension, TQT_SIGNAL( enableAction( const char *, bool ) ), TQT_SLOT( enableAction( const char *, bool ) ) );

@ -83,7 +83,7 @@ void KImageHolder::mousePressEvent( TQMouseEvent *ev )
void KImageHolder::mouseMoveEvent( TQMouseEvent *ev ) void KImageHolder::mouseMoveEvent( TQMouseEvent *ev )
{ {
//FIXME: when scrolling the cursorpos shouldn't change //FIXME: when scrolling the cursorpos shouldn't change
if( TQT_TQRECT_OBJECT(this->rect()).tqcontains( ev->pos(), false ) ) if( TQT_TQRECT_OBJECT(this->rect()).contains( ev->pos(), false ) )
emit cursorPos( ev->pos() ); emit cursorPos( ev->pos() );
//kdDebug( 4620 ) << k_funcinfo << " ev->state() = " << ev->state() << endl; //kdDebug( 4620 ) << k_funcinfo << " ev->state() = " << ev->state() << endl;
if( ev->state() & Qt::LeftButton || ev->state() & Qt::MidButton ) if( ev->state() & Qt::LeftButton || ev->state() & Qt::MidButton )

@ -259,7 +259,7 @@ bool KViewViewer::openURL( const KURL & url )
// Use same extension as remote file. This is important for mimetype-determination (e.g. koffice) // Use same extension as remote file. This is important for mimetype-determination (e.g. koffice)
TQString extension; TQString extension;
TQString fileName = url.fileName(); TQString fileName = url.fileName();
int extensionPos = fileName.tqfindRev( '.' ); int extensionPos = fileName.findRev( '.' );
if ( extensionPos != -1 ) if ( extensionPos != -1 )
extension = fileName.mid( extensionPos ); // keep the '.' extension = fileName.mid( extensionPos ); // keep the '.'
delete m_pTempFile; delete m_pTempFile;
@ -645,7 +645,7 @@ void KViewViewer::setZoom( const TQString & newZoom )
kdDebug( 4610 ) << k_funcinfo << newZoom << endl; kdDebug( 4610 ) << k_funcinfo << newZoom << endl;
double zoom; double zoom;
TQString z = newZoom; TQString z = newZoom;
z.remove( z.tqfind( '%' ), 1 ); z.remove( z.find( '%' ), 1 );
if( newZoom == "33%" ) if( newZoom == "33%" )
zoom = 1.0 / 3.0; zoom = 1.0 / 3.0;
else else
@ -667,14 +667,14 @@ void KViewViewer::updateZoomMenu( double zoom )
TQStringList itemsList = m_paZoom->items(); TQStringList itemsList = m_paZoom->items();
for( TQStringList::Iterator it = itemsList.begin(); it != itemsList.end(); ++it ) for( TQStringList::Iterator it = itemsList.begin(); it != itemsList.end(); ++it )
{ {
z = ( *it ).tqreplace( TQRegExp( "%" ), "" ); z = ( *it ).replace( TQRegExp( "%" ), "" );
z = z.simplifyWhiteSpace(); z = z.simplifyWhiteSpace();
val = z.toInt( &ok ); val = z.toInt( &ok );
if( ok && val > 0 && list.tqcontains( val ) == 0 ) if( ok && val > 0 && list.contains( val ) == 0 )
list << val; list << val;
} }
val = TQString::number( zoom * 100, 'f', 0 ).toInt(); // round/lround from math.h doesn't work - dunno val = TQString::number( zoom * 100, 'f', 0 ).toInt(); // round/lround from math.h doesn't work - dunno
if( list.tqcontains( val ) == 0 ) if( list.contains( val ) == 0 )
list.append( val ); list.append( val );
qHeapSort( list ); qHeapSort( list );
@ -687,7 +687,7 @@ void KViewViewer::updateZoomMenu( double zoom )
// first look if it's a new value (not in the list yet) // first look if it's a new value (not in the list yet)
TQString z = TQString( "%1%" ).tqarg( zoom * 100, 0, 'f', 0 ); TQString z = TQString( "%1%" ).tqarg( zoom * 100, 0, 'f', 0 );
TQStringList items = m_paZoom->items(); TQStringList items = m_paZoom->items();
int idx = items.tqfindIndex( z ); int idx = items.findIndex( z );
if( -1 == idx ) if( -1 == idx )
{ {
// not found XXX: remove when done // not found XXX: remove when done

@ -163,7 +163,7 @@ void KViewBrowser::setupDirLister()
{ {
TQApplication::setOverrideCursor( WaitCursor ); TQApplication::setOverrideCursor( WaitCursor );
TQString url = m_pViewer->url().prettyURL(); TQString url = m_pViewer->url().prettyURL();
int pos = url.tqfindRev( "/" ); int pos = url.findRev( "/" );
url = url.left( (unsigned int)pos ); url = url.left( (unsigned int)pos );
kdDebug( 4630 ) << "open KDirLister for " << url << endl; kdDebug( 4630 ) << "open KDirLister for " << url << endl;
m_pDirLister->openURL( KURL( url )); m_pDirLister->openURL( KURL( url ));

@ -41,7 +41,7 @@ ImageListItem::ImageListItem( KListView * tqparent, const KURL & url )
/* /*
TQString extension; TQString extension;
TQString fileName = m_url.fileName(); TQString fileName = m_url.fileName();
int extensionPos = fileName.tqfindRev( '.' ); int extensionPos = fileName.findRev( '.' );
if ( extensionPos != -1 ) if ( extensionPos != -1 )
extension = fileName.mid( extensionPos ); // keep the '.' extension = fileName.mid( extensionPos ); // keep the '.'
delete m_pTempFile; delete m_pTempFile;

@ -191,7 +191,7 @@ bool KViewPresenter::eventFilter( TQObject *obj, TQEvent *ev )
for( TQStringList::const_iterator it = l.begin(); it != l.end(); ++it ) for( TQStringList::const_iterator it = l.begin(); it != l.end(); ++it )
{ {
ImageInfo * info = new ImageInfo( KURL( *it ) ); ImageInfo * info = new ImageInfo( KURL( *it ) );
if( ! m_imagelist.tqcontains( info ) ) if( ! m_imagelist.contains( info ) )
{ {
m_imagelist.inSort( info ); m_imagelist.inSort( info );
( void )new ImageListItem( m_pImageList->m_pListView, KURL( *it ) ); ( void )new ImageListItem( m_pImageList->m_pListView, KURL( *it ) );
@ -218,7 +218,7 @@ void KViewPresenter::slotImageOpened( const KURL & url )
{ {
kdDebug( 4630 ) << k_funcinfo << "imagelist:" << endl; kdDebug( 4630 ) << k_funcinfo << "imagelist:" << endl;
ImageInfo * info = new ImageInfo( url ); ImageInfo * info = new ImageInfo( url );
if( ! m_imagelist.tqcontains( info ) ) if( ! m_imagelist.contains( info ) )
{ {
m_imagelist.inSort( info ); m_imagelist.inSort( info );
TQListViewItem * item = new ImageListItem( m_pImageList->m_pListView, url ); TQListViewItem * item = new ImageListItem( m_pImageList->m_pListView, url );
@ -248,7 +248,7 @@ void KViewPresenter::slotOpenFiles()
for( ++it; it != urls.end(); ++it ) for( ++it; it != urls.end(); ++it )
{ {
ImageInfo * info = new ImageInfo( *it ); ImageInfo * info = new ImageInfo( *it );
if( ! m_imagelist.tqcontains( info ) ) if( ! m_imagelist.contains( info ) )
{ {
m_imagelist.inSort( info ); m_imagelist.inSort( info );
( void )new ImageListItem( m_pImageList->m_pListView, *it ); ( void )new ImageListItem( m_pImageList->m_pListView, *it );
@ -431,7 +431,7 @@ void KViewPresenter::loadList()
{ {
KURL url ( t.readLine() ); KURL url ( t.readLine() );
ImageInfo * info = new ImageInfo( url ); ImageInfo * info = new ImageInfo( url );
if( ! m_imagelist.tqcontains( info ) ) if( ! m_imagelist.contains( info ) )
{ {
m_imagelist.inSort( info ); m_imagelist.inSort( info );
( void )new ImageListItem( m_pImageList->m_pListView, url ); ( void )new ImageListItem( m_pImageList->m_pListView, url );

@ -20,7 +20,7 @@
This very simple class contains a page number and a vertical position This very simple class contains a page number and a vertical position
in physical coordiantes. The vertical position is given by the in physical coordiantes. The vertical position is given by the
distance from the top of the page. Anchors are completely independent distance from the top of the page. Anchors are completely independent
of documents, there is no need for a document to exists that tqcontains of documents, there is no need for a document to exists that contains
the given page, nor does the page number need to be valid. the given page, nor does the page number need to be valid.
@author Stefan Kebekus <kebekus@kde.org> @author Stefan Kebekus <kebekus@kde.org>

@ -119,7 +119,7 @@ bool DocumentPageCache::isPageCached(const PageNumber& pageNumber, const TQSize&
// Check if the page that we are looking for is in the cache. // Check if the page that we are looking for is in the cache.
// We are not accessing the page, so we don't want it to be moved into the front. // We are not accessing the page, so we don't want it to be moved into the front.
RenderedDocumentPagePixmap* page = LRUCache.tqfind(key, false); RenderedDocumentPagePixmap* page = LRUCache.find(key, false);
if (page) if (page)
return true; return true;
@ -191,7 +191,7 @@ RenderedDocumentPagePixmap* DocumentPageCache::getPage(const PageNumber& pageNr)
// First check if the page that we are looking for is in the cache // First check if the page that we are looking for is in the cache
RenderedDocumentPagePixmap* page; RenderedDocumentPagePixmap* page;
page = LRUCache.tqfind(createKey(pageNr)); page = LRUCache.find(createKey(pageNr));
if (page) if (page)
return page; return page;

@ -122,7 +122,7 @@ Anchor DocumentRenderer::findAnchor(const TQString &locallink)
// Wait for all access to this DocumentRenderer to finish // Wait for all access to this DocumentRenderer to finish
TQMutexLocker locker(&mutex); TQMutexLocker locker(&mutex);
TQMap<TQString,Anchor>::Iterator it = anchorList.tqfind(locallink); TQMap<TQString,Anchor>::Iterator it = anchorList.find(locallink);
if (it != anchorList.end()) if (it != anchorList.end())
return *it; return *it;
else else

@ -152,7 +152,7 @@ public:
virtual void clear(); virtual void clear();
/* Returns true if the current document tqcontains 0 pages. */ /* Returns true if the current document contains 0 pages. */
bool isEmpty() const {return numPages == 0;} bool isEmpty() const {return numPages == 0;}
/* Tells if the document was modified after is was loaded. */ /* Tells if the document was modified after is was loaded. */
@ -262,7 +262,7 @@ public:
display device. In principle. In fact, kviewshell implements zooming display device. In principle. In fact, kviewshell implements zooming
by using values that are not exactly the resolution of the display, by using values that are not exactly the resolution of the display,
but multiplied with the zoom factor. Bottom line: the but multiplied with the zoom factor. Bottom line: the
DocumentRenderer should act as if this field indeed tqcontains DocumentRenderer should act as if this field indeed contains
resolution of the display device. resolution of the display device.
@param page pointer to a documentPage structure that this method @param page pointer to a documentPage structure that this method

@ -452,7 +452,7 @@ void DocumentWidget::mousePressEvent ( TQMouseEvent * e )
if (e->button() == Qt::LeftButton) { if (e->button() == Qt::LeftButton) {
if (pageData->hyperLinkList.size() > 0) if (pageData->hyperLinkList.size() > 0)
for(unsigned int i = 0; i < pageData->hyperLinkList.size(); i++) { for(unsigned int i = 0; i < pageData->hyperLinkList.size(); i++) {
if (pageData->hyperLinkList[i].box.tqcontains(e->pos())) { if (pageData->hyperLinkList[i].box.contains(e->pos())) {
emit(localLink(pageData->hyperLinkList[i].linkText)); emit(localLink(pageData->hyperLinkList[i].linkText));
return; return;
} }
@ -537,7 +537,7 @@ void DocumentWidget::mouseMoveEvent ( TQMouseEvent * e )
int lastUnderlinedLink = indexOfUnderlinedLink; int lastUnderlinedLink = indexOfUnderlinedLink;
// go through hyperlinks // go through hyperlinks
for(unsigned int i = 0; i < pageData->hyperLinkList.size(); i++) { for(unsigned int i = 0; i < pageData->hyperLinkList.size(); i++) {
if (pageData->hyperLinkList[i].box.tqcontains(e->pos())) { if (pageData->hyperLinkList[i].box.contains(e->pos())) {
clearStatusBarTimer.stop(); clearStatusBarTimer.stop();
setCursor(pointingHandCursor); setCursor(pointingHandCursor);
TQString link = pageData->hyperLinkList[i].linkText; TQString link = pageData->hyperLinkList[i].linkText;

@ -146,7 +146,7 @@ void KMultiPage::slotSave()
// Try to guess the proper ending... // Try to guess the proper ending...
TQString formats; TQString formats;
TQString ending; TQString ending;
int rindex = m_file.tqfindRev("."); int rindex = m_file.findRev(".");
if (rindex == -1) { if (rindex == -1) {
ending = TQString(); ending = TQString();
formats = TQString(); formats = TQString();
@ -162,7 +162,7 @@ void KMultiPage::slotSave()
// Add the ending to the filename. I hope the user likes it that // Add the ending to the filename. I hope the user likes it that
// way. // way.
if (!ending.isEmpty() && fileName.tqfind(ending) == -1) if (!ending.isEmpty() && fileName.find(ending) == -1)
fileName = fileName+ending; fileName = fileName+ending;
if (TQFile(fileName).exists()) { if (TQFile(fileName).exists()) {
@ -1461,7 +1461,7 @@ void KMultiPage::findNextText()
if (searchPage->textBoxList.size() == 0) if (searchPage->textBoxList.size() == 0)
continue; continue;
foundSelection = searchPage->tqfind(searchText, startingTextItem, case_sensitive); foundSelection = searchPage->find(searchText, startingTextItem, case_sensitive);
if (foundSelection.isEmpty()) if (foundSelection.isEmpty())
{ {
@ -1603,7 +1603,7 @@ void KMultiPage::findPrevText()
if (searchPage->textBoxList.size() == 0) if (searchPage->textBoxList.size() == 0)
continue; continue;
foundSelection = searchPage->tqfindRev(searchText, startingTextItem, case_sensitive); foundSelection = searchPage->findRev(searchText, startingTextItem, case_sensitive);
if (foundSelection.isEmpty()) if (foundSelection.isEmpty())
{ {
@ -1901,7 +1901,7 @@ void KMultiPage::doExportText()
{ {
// Generate a suggestion for a reasonable file name // Generate a suggestion for a reasonable file name
TQString suggestedName = url().filename(); TQString suggestedName = url().filename();
suggestedName = suggestedName.left(suggestedName.tqfind(".")) + ".txt"; suggestedName = suggestedName.left(suggestedName.find(".")) + ".txt";
TQString fileName = KFileDialog::getSaveFileName(suggestedName, i18n("*.txt|Plain Text (Latin 1) (*.txt)"), scrollView(), i18n("Export File As")); TQString fileName = KFileDialog::getSaveFileName(suggestedName, i18n("*.txt|Plain Text (Latin 1) (*.txt)"), scrollView(), i18n("Export File As"));

@ -92,7 +92,7 @@ public:
should) therefore be re-implemented if you have good code to convert should) therefore be re-implemented if you have good code to convert
your document to PostScript. your document to PostScript.
Example: If your document consists of a single A4 page that tqcontains Example: If your document consists of a single A4 page that contains
a DJVU image of 30KB, then the default implementation would render a DJVU image of 30KB, then the default implementation would render
the image in 600dpi, i.e. in about 7000x5000 pixel, and then send the image in 600dpi, i.e. in about 7000x5000 pixel, and then send
this huge graphics uncompressed to the printer. A smart this huge graphics uncompressed to the printer. A smart

@ -173,7 +173,7 @@ KViewPart::KViewPart(TQWidget *parentWidget, const char *widgetName, TQObject *t
exportTextAction = new KAction(i18n("Text..."), 0, this, TQT_SLOT(mp_exportText()), actionCollection(), "export_text"); exportTextAction = new KAction(i18n("Text..."), 0, this, TQT_SLOT(mp_exportText()), actionCollection(), "export_text");
// edit menu // edit menu
findTextAction = KStdAction::find(this, TQT_SLOT(mp_showFindTextDialog()), actionCollection(), "tqfind"); findTextAction = KStdAction::find(this, TQT_SLOT(mp_showFindTextDialog()), actionCollection(), "find");
findNextAction = KStdAction::findNext(this, TQT_SLOT(mp_findNextText()), actionCollection(), "findnext"); findNextAction = KStdAction::findNext(this, TQT_SLOT(mp_findNextText()), actionCollection(), "findnext");
findNextAction->setEnabled(false); findNextAction->setEnabled(false);
findPrevAction = KStdAction::findPrev(this, TQT_SLOT(mp_findPrevText()), actionCollection(), "findprev"); findPrevAction = KStdAction::findPrev(this, TQT_SLOT(mp_findPrevText()), actionCollection(), "findprev");
@ -553,10 +553,10 @@ TQStringList KViewPart::fileFormats() const
for(TQStringList::Iterator it = supportedPattern.begin(); it != supportedPattern.end(); ++it ) for(TQStringList::Iterator it = supportedPattern.begin(); it != supportedPattern.end(); ++it )
{ {
if ((*it).tqfind(".gz", -3) == -1) // Paranoia safety check if ((*it).find(".gz", -3) == -1) // Paranoia safety check
compressedPattern.append(*it + ".gz"); compressedPattern.append(*it + ".gz");
if ((bzip2Available) && ((*it).tqfind(".bz2", -4) == -1)) // Paranoia safety check if ((bzip2Available) && ((*it).find(".bz2", -4) == -1)) // Paranoia safety check
compressedPattern.append(*it + ".bz2"); compressedPattern.append(*it + ".bz2");
} }
@ -613,7 +613,7 @@ bool KViewPart::openFile()
for (TQStringList::Iterator it = supportedPatterns.begin(); it != supportedPatterns.end(); ++it) for (TQStringList::Iterator it = supportedPatterns.begin(); it != supportedPatterns.end(); ++it)
{ {
// Only consider patterns starting with "*." // Only consider patterns starting with "*."
if ((*it).tqfind("*.") == 0) if ((*it).find("*.") == 0)
{ {
// Remove first Letter from string // Remove first Letter from string
endings.append((*it).mid(2).stripWhiteSpace()); endings.append((*it).mid(2).stripWhiteSpace());
@ -1382,7 +1382,7 @@ void KViewPart::writeSettings()
void KViewPart::connectNotify ( const char *sig ) void KViewPart::connectNotify ( const char *sig )
{ {
if (TQString(sig).tqcontains("pageChanged")) if (TQString(sig).contains("pageChanged"))
pageChangeIsConnected = true; pageChangeIsConnected = true;
} }

@ -107,7 +107,7 @@ int main(int argc, char **argv)
QCStringList apps = app.dcopClient()->registeredApplications(); QCStringList apps = app.dcopClient()->registeredApplications();
for ( QCStringList::Iterator it = apps.begin(); it != apps.end(); ++it ) for ( QCStringList::Iterator it = apps.begin(); it != apps.end(); ++it )
{ {
if ((*it).tqfind("kviewshell") == 0) if ((*it).find("kviewshell") == 0)
{ {
TQByteArray data, replyData; TQByteArray data, replyData;
TQCString replyType; TQCString replyType;

@ -77,10 +77,10 @@ bool pageSize::setPageSize(const TQString& name)
} }
} }
// Check if the string tqcontains 'x'. If yes, we assume it is of type // Check if the string contains 'x'. If yes, we assume it is of type
// "<number>x<number>". If yes, the first number is interpreted as // "<number>x<number>". If yes, the first number is interpreted as
// the width in mm, the second as the height in mm // the width in mm, the second as the height in mm
if (name.tqfind('x') >= 0) { if (name.find('x') >= 0) {
bool wok, hok; bool wok, hok;
float pageWidth_tmp = name.section('x',0,0).toFloat(&wok); float pageWidth_tmp = name.section('x',0,0).toFloat(&wok);
float pageHeight_tmp = name.section('x',1,1).toFloat(&hok); float pageHeight_tmp = name.section('x',1,1).toFloat(&hok);
@ -95,10 +95,10 @@ bool pageSize::setPageSize(const TQString& name)
} }
} }
// Check if the string tqcontains ','. If yes, we assume it is of type // Check if the string contains ','. If yes, we assume it is of type
// "<number><unit>,<number><uni>". The first number is supposed to // "<number><unit>,<number><uni>". The first number is supposed to
// be the width, the second the height. // be the width, the second the height.
if (name.tqfind(',') >= 0) { if (name.find(',') >= 0) {
bool wok, hok; bool wok, hok;
float pageWidth_tmp = distance::convertToMM(name.section(',',0,0), &wok); float pageWidth_tmp = distance::convertToMM(name.section(',',0,0), &wok);
float pageHeight_tmp = distance::convertToMM(name.section(',',1,1), &hok); float pageHeight_tmp = distance::convertToMM(name.section(',',1,1), &hok);

@ -65,7 +65,7 @@ public:
call pageSizeNames() more than once, it is guaranteed that the call pageSizeNames() more than once, it is guaranteed that the
same list of strings will be returned. same list of strings will be returned.
@returns TQStringList that tqcontains @returns TQStringList that contains
*/ */
TQStringList pageSizeNames(); TQStringList pageSizeNames();

@ -314,7 +314,7 @@ void DjVuMultiPage::slotSave()
// Try to guess the proper ending... // Try to guess the proper ending...
TQString formats; TQString formats;
TQString ending; TQString ending;
int rindex = m_file.tqfindRev("."); int rindex = m_file.findRev(".");
if (rindex == -1) { if (rindex == -1) {
ending = TQString(); ending = TQString();
formats = TQString(); formats = TQString();
@ -330,7 +330,7 @@ void DjVuMultiPage::slotSave()
// Add the ending to the filename. I hope the user likes it that // Add the ending to the filename. I hope the user likes it that
// way. // way.
if (!ending.isEmpty() && fileName.tqfind(ending) == -1) if (!ending.isEmpty() && fileName.find(ending) == -1)
fileName = fileName+ending; fileName = fileName+ending;
if (TQFile(fileName).exists()) { if (TQFile(fileName).exists()) {

@ -361,7 +361,7 @@ void DjVuRenderer::getAnnotations(RenderedDocumentPage* page, GP<DjVuImage> djvu
TQString comment((const char*)map[pos]->comment); TQString comment((const char*)map[pos]->comment);
// Create an anchor for this link. // Create an anchor for this link.
if (!anchorList.tqcontains(url)) if (!anchorList.contains(url))
{ {
// For now we only accept links to pages in the same document. // For now we only accept links to pages in the same document.
if(url[0] == '#' && target == "_self") if(url[0] == '#' && target == "_self")

@ -190,7 +190,7 @@ ArrayRep::resize(int lo, int hi)
init1(ndata, hibound+1-nminlo, hi-nminlo); init1(ndata, hibound+1-nminlo, hi-nminlo);
destroy(data, lobound-minlo, hibound-minlo); destroy(data, lobound-minlo, hibound-minlo);
// free and tqreplace // free and replace
void *tmp=data; void *tmp=data;
data = ndata; data = ndata;
ndata=tmp; ndata=tmp;

@ -319,7 +319,7 @@ public:
/** Erases the array contents. All elements in the array are destroyed. /** Erases the array contents. All elements in the array are destroyed.
The valid subscript range is set to the empty range. */ The valid subscript range is set to the empty range. */
void empty(); void empty();
/** Extends the subscript range so that is tqcontains #n#. /** Extends the subscript range so that is contains #n#.
This function does nothing if #n# is already int the valid subscript range. This function does nothing if #n# is already int the valid subscript range.
If the valid range was empty, both the lower bound and the upper bound If the valid range was empty, both the lower bound and the upper bound
are set to #n#. Otherwise the valid subscript range is extended are set to #n#. Otherwise the valid subscript range is extended

@ -187,7 +187,7 @@ DataPool::OpenFiles_File::add_pool(GP<DataPool> &pool)
DEBUG_MSG("DataPool::OpenFiles_File::add_pool: pool=" << (void *) pool << "\n"); DEBUG_MSG("DataPool::OpenFiles_File::add_pool: pool=" << (void *) pool << "\n");
DEBUG_MAKE_INDENT(3); DEBUG_MAKE_INDENT(3);
GCriticalSectionLock lock(&pools_lock); GCriticalSectionLock lock(&pools_lock);
if (!pools_list.tqcontains(pool)) if (!pools_list.contains(pool))
pools_list.append(pool); pools_list.append(pool);
return pools_list.size(); return pools_list.size();
} }
@ -381,14 +381,14 @@ FCPools::add_pool(const GURL &url, GP<DataPool> pool)
if (url.is_local_file_url()) if (url.is_local_file_url())
{ {
GPList<DataPool> list; GPList<DataPool> list;
GPosition pos(map.tqcontains(url)); GPosition pos(map.contains(url));
if (! pos) if (! pos)
{ {
map[url]=list; map[url]=list;
pos=map.tqcontains(url); pos=map.contains(url);
} }
GPList<DataPool> &plist=map[pos]; GPList<DataPool> &plist=map[pos];
if (!plist.tqcontains(pool)) if (!plist.contains(pool))
plist.append(pool); plist.append(pool);
} }
clean(); clean();
@ -403,7 +403,7 @@ FCPools::get_pool(const GURL &url, int start, int length)
if (url.is_local_file_url()) if (url.is_local_file_url())
{ {
GCriticalSectionLock lock(&map_lock); GCriticalSectionLock lock(&map_lock);
GPosition pos(map.tqcontains(url)); GPosition pos(map.contains(url));
if (pos) if (pos)
{ {
GPList<DataPool> &plist=map[pos]; GPList<DataPool> &plist=map[pos];
@ -433,7 +433,7 @@ FCPools::del_pool(const GURL &url, GP<DataPool> pool)
if (url.is_local_file_url()) if (url.is_local_file_url())
{ {
GPosition pos; GPosition pos;
if (map.tqcontains(url, pos)) if (map.contains(url, pos))
{ {
GPList<DataPool> &list=map[pos]; GPList<DataPool> &list=map[pos];
GPosition list_pos; GPosition list_pos;
@ -458,7 +458,7 @@ FCPools::load_file(const GURL &url)
if (url.is_local_file_url()) if (url.is_local_file_url())
{ {
GPosition pos; GPosition pos;
if (map.tqcontains(url, pos)) if (map.contains(url, pos))
{ {
// We make here a copy of the list because DataPool::load_file() // We make here a copy of the list because DataPool::load_file()
// will call FCPools::del_pool(), which will modify the list // will call FCPools::del_pool(), which will modify the list

@ -116,7 +116,7 @@ class ByteStream;
Access to data in a #DataPool# may be direct (Using \Ref{get_data}() Access to data in a #DataPool# may be direct (Using \Ref{get_data}()
function) or sequential (See \Ref{get_stream}() function). function) or sequential (See \Ref{get_stream}() function).
If the #DataPool# is not connected to anything, that is it tqcontains If the #DataPool# is not connected to anything, that is it contains
some real data, this data can be added to it by means of two some real data, this data can be added to it by means of two
\Ref{add_data}() functions. One of them adds data sequentially maintaining \Ref{add_data}() functions. One of them adds data sequentially maintaining
the offset of the last block of data added by it. The other can store the offset of the last block of data added by it. The other can store

@ -363,7 +363,7 @@ DjVmDir::decode(const GP<ByteStream> &gstr)
for(pos=files_list;pos;++pos) for(pos=files_list;pos;++pos)
{ {
GP<File> file=files_list[pos]; GP<File> file=files_list[pos];
if (name2file.tqcontains(file->name)) if (name2file.contains(file->name))
G_THROW( ERR_MSG("DjVmDir.dupl_name") "\t" + file->name ); G_THROW( ERR_MSG("DjVmDir.dupl_name") "\t" + file->name );
name2file[file->name]=file; name2file[file->name]=file;
} }
@ -372,7 +372,7 @@ DjVmDir::decode(const GP<ByteStream> &gstr)
for(pos=files_list;pos;++pos) for(pos=files_list;pos;++pos)
{ {
GP<File> file=files_list[pos]; GP<File> file=files_list[pos];
if (id2file.tqcontains(file->id)) if (id2file.contains(file->id))
G_THROW( ERR_MSG("DjVmDir.dupl_id") "\t" + file->id); G_THROW( ERR_MSG("DjVmDir.dupl_id") "\t" + file->id);
id2file[file->id]=file; id2file[file->id]=file;
} }
@ -383,7 +383,7 @@ DjVmDir::decode(const GP<ByteStream> &gstr)
GP<File> file=files_list[pos]; GP<File> file=files_list[pos];
if (file->title.length()) if (file->title.length())
{ {
if (title2file.tqcontains(file->title)) if (title2file.contains(file->title))
G_THROW( ERR_MSG("DjVmDir.dupl_title") "\t" + file->title); G_THROW( ERR_MSG("DjVmDir.dupl_title") "\t" + file->title);
title2file[file->title]=file; title2file[file->title]=file;
} }
@ -542,7 +542,7 @@ DjVmDir::name_to_file(const GUTF8String & name) const
GCriticalSectionLock lock((GCriticalSection *) &class_lock); GCriticalSectionLock lock((GCriticalSection *) &class_lock);
GPosition pos; GPosition pos;
return (name2file.tqcontains(name, pos))?name2file[pos]:(GP<DjVmDir::File>(0)); return (name2file.contains(name, pos))?name2file[pos]:(GP<DjVmDir::File>(0));
} }
GP<DjVmDir::File> GP<DjVmDir::File>
@ -551,7 +551,7 @@ DjVmDir::id_to_file(const GUTF8String &id) const
GCriticalSectionLock lock((GCriticalSection *) &class_lock); GCriticalSectionLock lock((GCriticalSection *) &class_lock);
GPosition pos; GPosition pos;
return (id2file.tqcontains(id, pos))?id2file[pos]:(GP<DjVmDir::File>(0)); return (id2file.contains(id, pos))?id2file[pos]:(GP<DjVmDir::File>(0));
} }
GP<DjVmDir::File> GP<DjVmDir::File>
@ -560,7 +560,7 @@ DjVmDir::title_to_file(const GUTF8String &title) const
GCriticalSectionLock lock((GCriticalSection *) &class_lock); GCriticalSectionLock lock((GCriticalSection *) &class_lock);
GPosition pos; GPosition pos;
return (title2file.tqcontains(title, pos))?title2file[pos]:(GP<DjVmDir::File>(0)); return (title2file.contains(title, pos))?title2file[pos]:(GP<DjVmDir::File>(0));
} }
GPList<DjVmDir::File> GPList<DjVmDir::File>
@ -636,15 +636,15 @@ DjVmDir::insert_file(const GP<File> & file, int pos_num)
// Modify maps // Modify maps
// if (! File::is_legal_id(file->id)) // if (! File::is_legal_id(file->id))
// G_THROW( ERR_MSG("DjVmDir.bad_file") "\t" + file->id); // G_THROW( ERR_MSG("DjVmDir.bad_file") "\t" + file->id);
if (id2file.tqcontains(file->id)) if (id2file.contains(file->id))
G_THROW( ERR_MSG("DjVmDir.dupl_id2") "\t" + file->id); G_THROW( ERR_MSG("DjVmDir.dupl_id2") "\t" + file->id);
if (name2file.tqcontains(file->name)) if (name2file.contains(file->name))
G_THROW( ERR_MSG("DjVmDir.dupl_name2") "\t" + file->name); G_THROW( ERR_MSG("DjVmDir.dupl_name2") "\t" + file->name);
name2file[file->name]=file; name2file[file->name]=file;
id2file[file->id]=file; id2file[file->id]=file;
if (file->title.length()) if (file->title.length())
{ {
if (title2file.tqcontains(file->title)) // duplicate titles may become ok some day if (title2file.contains(file->title)) // duplicate titles may become ok some day
G_THROW( ERR_MSG("DjVmDir.dupl_title2") "\t" + file->title); G_THROW( ERR_MSG("DjVmDir.dupl_title2") "\t" + file->title);
title2file[file->title]=file; title2file[file->title]=file;
} }
@ -749,7 +749,7 @@ DjVmDir::set_file_name(const GUTF8String &id, const GUTF8String &name)
} }
// Check if ID is valid // Check if ID is valid
if (!id2file.tqcontains(id, pos)) if (!id2file.contains(id, pos))
G_THROW( ERR_MSG("DjVmDir.no_info") "\t" + GUTF8String(id)); G_THROW( ERR_MSG("DjVmDir.no_info") "\t" + GUTF8String(id));
GP<File> file=id2file[pos]; GP<File> file=id2file[pos];
name2file.del(file->name); name2file.del(file->name);
@ -776,7 +776,7 @@ DjVmDir::set_file_title(const GUTF8String &id, const GUTF8String &title)
} }
// Check if ID is valid // Check if ID is valid
if (!id2file.tqcontains(id, pos)) if (!id2file.contains(id, pos))
G_THROW( ERR_MSG("DjVmDir.no_info") "\t" + GUTF8String(id)); G_THROW( ERR_MSG("DjVmDir.no_info") "\t" + GUTF8String(id));
GP<File> file=id2file[pos]; GP<File> file=id2file[pos];
title2file.del(file->title); title2file.del(file->title);
@ -795,7 +795,7 @@ DjVmDir::resolve_duplicates(const bool save_as_bundled)
for(pos=files_list;pos;++pos) for(pos=files_list;pos;++pos)
{ {
const GUTF8String save_name=files_list[pos]->check_save_name(save_as_bundled).downcase(); const GUTF8String save_name=files_list[pos]->check_save_name(save_as_bundled).downcase();
if(save_map.tqcontains(save_name)) if(save_map.contains(save_name))
{ {
conflicts[save_name].append(files_list[pos]); conflicts[save_name].append(files_list[pos]);
}else }else
@ -813,7 +813,7 @@ DjVmDir::resolve_duplicates(const bool save_as_bundled)
{ {
GUTF8String new_name=cfiles[qpos]->get_load_name(); GUTF8String new_name=cfiles[qpos]->get_load_name();
if((new_name != GUTF8String(GNativeString(new_name))) if((new_name != GUTF8String(GNativeString(new_name)))
||conflicts.tqcontains(new_name)) ||conflicts.contains(new_name))
{ {
do do
{ {
@ -821,7 +821,7 @@ DjVmDir::resolve_duplicates(const bool save_as_bundled)
?(save_name+"-"+GUTF8String(count++)) ?(save_name+"-"+GUTF8String(count++))
:(save_name.substr(0,dot)+"-"+GUTF8String(count++)+ :(save_name.substr(0,dot)+"-"+GUTF8String(count++)+
save_name.substr(dot,(unsigned int)(-1))); save_name.substr(dot,(unsigned int)(-1)));
} while(save_map.tqcontains(new_name.downcase())); } while(save_map.contains(new_name.downcase()));
} }
cfiles[qpos]->set_save_name(new_name); cfiles[qpos]->set_save_name(new_name);
save_map[new_name]=0; save_map[new_name]=0;

@ -132,7 +132,7 @@ DjVmDir0::decode(ByteStream & bs)
GP<DjVmDir0::FileRec> GP<DjVmDir0::FileRec>
DjVmDir0::get_file(const GUTF8String &name) DjVmDir0::get_file(const GUTF8String &name)
{ {
if (name2file.tqcontains(name)) if (name2file.contains(name))
return name2file[name]; return name2file[name];
return 0; return 0;
} }

@ -109,7 +109,7 @@ save_file(
{ {
incl_str.setat(incl_str.length()-1, 0); incl_str.setat(incl_str.length()-1, 0);
} }
GPosition pos=incl.tqcontains(incl_str); GPosition pos=incl.contains(incl_str);
if(pos) if(pos)
{ {
iff_out.get_bytestream()->writestring(incl[pos]); iff_out.get_bytestream()->writestring(incl[pos]);
@ -174,7 +174,7 @@ DjVmDoc::insert_file(const GP<DjVmDir::File> & f,
if (!f) if (!f)
G_THROW( ERR_MSG("DjVmDoc.no_zero_file") ); G_THROW( ERR_MSG("DjVmDoc.no_zero_file") );
if (data.tqcontains(f->get_load_name())) if (data.contains(f->get_load_name()))
G_THROW( ERR_MSG("DjVmDoc.no_duplicate") ); G_THROW( ERR_MSG("DjVmDoc.no_duplicate") );
char buffer[4]; char buffer[4];
@ -224,7 +224,7 @@ DjVmDoc::delete_file(const GUTF8String &id)
DEBUG_MSG("DjVmDoc::delete_file(): deleting file '" << id << "'\n"); DEBUG_MSG("DjVmDoc::delete_file(): deleting file '" << id << "'\n");
DEBUG_MAKE_INDENT(3); DEBUG_MAKE_INDENT(3);
if (!data.tqcontains(id)) if (!data.contains(id))
G_THROW(GUTF8String( ERR_MSG("DjVmDoc.cant_delete") "\t") + id); G_THROW(GUTF8String( ERR_MSG("DjVmDoc.cant_delete") "\t") + id);
data.del(id); data.del(id);
@ -243,8 +243,8 @@ GP<DataPool>
DjVmDoc::get_data(const GUTF8String &id) const DjVmDoc::get_data(const GUTF8String &id) const
{ {
GPosition pos; GPosition pos;
if (!data.tqcontains(id, pos)) if (!data.contains(id, pos))
G_THROW(GUTF8String( ERR_MSG("DjVmDoc.cant_tqfind") "\t") + id); G_THROW(GUTF8String( ERR_MSG("DjVmDoc.cant_find") "\t") + id);
const GP<DataPool> pool(data[pos]); const GP<DataPool> pool(data[pos]);
// First check that the file is in IFF format // First check that the file is in IFF format
G_TRY G_TRY
@ -298,8 +298,8 @@ DjVmDoc::write(const GP<ByteStream> &gstr,
for(pos=files_list;pos;++pos) for(pos=files_list;pos;++pos)
{ {
GP<DjVmDir::File> file=files_list[pos]; GP<DjVmDir::File> file=files_list[pos];
if((do_rename=(reserved.tqcontains(file->get_load_name())?true:false)) if((do_rename=(reserved.contains(file->get_load_name())?true:false))
||(do_rename=(reserved.tqcontains(file->get_save_name())?true:false))) ||(do_rename=(reserved.contains(file->get_save_name())?true:false)))
{ {
break; break;
} }
@ -322,7 +322,7 @@ DjVmDoc::write(const GP<ByteStream> &gstr,
{ {
GP<DjVmDir::File> file=files_list[pos]; GP<DjVmDir::File> file=files_list[pos];
const GUTF8String name(::get_name(*file)); const GUTF8String name(::get_name(*file));
if(reserved.tqcontains(name)) if(reserved.contains(name))
{ {
GUTF8String new_name; GUTF8String new_name;
int series=0; int series=0;
@ -337,7 +337,7 @@ DjVmDoc::write(const GP<ByteStream> &gstr,
{ {
new_name=name+"_"+GUTF8String(++series); new_name=name+"_"+GUTF8String(++series);
} }
} while(reserved.tqcontains(new_name)||this_doc.tqcontains(new_name)); } while(reserved.contains(new_name)||this_doc.contains(new_name));
dir->set_file_name(file->get_load_name(),new_name); dir->set_file_name(file->get_load_name(),new_name);
need_new_list=true; need_new_list=true;
} }
@ -353,7 +353,7 @@ DjVmDoc::write(const GP<ByteStream> &gstr,
{ {
GP<DjVmDir::File> file=files_list[pos]; GP<DjVmDir::File> file=files_list[pos];
file->offset=0xffffffff; file->offset=0xffffffff;
GPosition data_pos=data.tqcontains(file->get_load_name()); GPosition data_pos=data.contains(file->get_load_name());
if (!data_pos) if (!data_pos)
G_THROW( ERR_MSG("DjVmDoc.no_data") "\t" + file->get_load_name()); G_THROW( ERR_MSG("DjVmDoc.no_data") "\t" + file->get_load_name());
if(do_rename) if(do_rename)
@ -541,7 +541,7 @@ DjVmDoc::write_index(const GP<ByteStream> &str)
GP<DjVmDir::File> file=files_list[pos]; GP<DjVmDir::File> file=files_list[pos];
file->offset=0; file->offset=0;
GPosition data_pos=data.tqcontains(file->get_load_name()); GPosition data_pos=data.contains(file->get_load_name());
if (!data_pos) if (!data_pos)
G_THROW( ERR_MSG("DjVmDoc.no_data") "\t" + file->get_load_name()); G_THROW( ERR_MSG("DjVmDoc.no_data") "\t" + file->get_load_name());
file->size=data[data_pos]->get_length(); file->size=data[data_pos]->get_length();
@ -609,7 +609,7 @@ DjVmDoc::save_file(
GMap<GUTF8String,GUTF8String> *incl) const GMap<GUTF8String,GUTF8String> *incl) const
{ {
const GUTF8String load_name=file.get_load_name(); const GUTF8String load_name=file.get_load_name();
if(!incl || !incl->tqcontains(load_name)) if(!incl || !incl->contains(load_name))
{ {
GMap<GUTF8String,GUTF8String> new_incl; GMap<GUTF8String,GUTF8String> new_incl;
const GUTF8String save_name( const GUTF8String save_name(

@ -243,7 +243,7 @@ DjVuDocEditor::request_data(const DjVuPort * source, const GURL & url)
{ {
GCriticalSectionLock lock(&files_lock); GCriticalSectionLock lock(&files_lock);
GPosition pos; GPosition pos;
if (files_map.tqcontains(frec->get_load_name(), pos)) if (files_map.contains(frec->get_load_name(), pos))
{ {
const GP<File> f(files_map[pos]); const GP<File> f(files_map[pos]);
if (f->file && f->file->get_init_data_pool()) if (f->file && f->file->get_init_data_pool())
@ -315,7 +315,7 @@ DjVuDocEditor::url_to_file(const GURL & url, bool dont_create) const
{ {
GCriticalSectionLock lock(&(const_cast<DjVuDocEditor *>(this)->files_lock)); GCriticalSectionLock lock(&(const_cast<DjVuDocEditor *>(this)->files_lock));
GPosition pos; GPosition pos;
if (files_map.tqcontains(frec->get_load_name(), pos)) if (files_map.contains(frec->get_load_name(), pos))
{ {
const GP<File> f(files_map[pos]); const GP<File> f(files_map[pos]);
if (f->file) if (f->file)
@ -333,7 +333,7 @@ DjVuDocEditor::url_to_file(const GURL & url, bool dont_create) const
{ {
GCriticalSectionLock lock(&(const_cast<DjVuDocEditor *>(this)->files_lock)); GCriticalSectionLock lock(&(const_cast<DjVuDocEditor *>(this)->files_lock));
GPosition pos; GPosition pos;
if (files_map.tqcontains(frec->get_load_name(), pos)) if (files_map.contains(frec->get_load_name(), pos))
{ {
files_map[frec->get_load_name()]->file=file; files_map[frec->get_load_name()]->file=file;
}else }else
@ -538,7 +538,7 @@ DjVuDocEditor::insert_file(const GURL &file_url, bool is_page,
// We do not want to insert the same file twice (important when // We do not want to insert the same file twice (important when
// we insert a group of files at the same time using insert_group()) // we insert a group of files at the same time using insert_group())
// So we check if we already did that and return if so. // So we check if we already did that and return if so.
if (name2id.tqcontains(file_url.fname())) if (name2id.contains(file_url.fname()))
return true; return true;
if(!source) if(!source)
@ -606,7 +606,7 @@ DjVuDocEditor::insert_file(const GP<DataPool> &file_pool,
// Check the name2id first... // Check the name2id first...
const GUTF8String name=file_url.fname(); const GUTF8String name=file_url.fname();
GUTF8String id; GUTF8String id;
if (name2id.tqcontains(name)) if (name2id.contains(name))
{ {
id=name2id[name]; id=name2id[name];
}else }else
@ -821,7 +821,7 @@ DjVuDocEditor::insert_group(const GList<GURL> & file_urls, int page_num,
} }
GUTF8String chkid; GUTF8String chkid;
IFFByteStream::create(xdata_pool->get_stream())->get_chunk(chkid); IFFByteStream::create(xdata_pool->get_stream())->get_chunk(chkid);
if (name2id.tqcontains(furl.fname())||(chkid=="FORM:DJVM")) if (name2id.contains(furl.fname())||(chkid=="FORM:DJVM"))
{ {
GMap<GUTF8String,void *> map; GMap<GUTF8String,void *> map;
map_ids(map); map_ids(map);
@ -936,7 +936,7 @@ DjVuDocEditor::generate_ref_map(const GP<DjVuFile> & file,
{ {
const GURL url=file->get_url(); const GURL url=file->get_url();
const GUTF8String id(djvm_dir->name_to_file(url.fname())->get_load_name()); const GUTF8String id(djvm_dir->name_to_file(url.fname())->get_load_name());
if (!visit_map.tqcontains(url)) if (!visit_map.contains(url))
{ {
visit_map[url]=0; visit_map[url]=0;
@ -950,7 +950,7 @@ DjVuDocEditor::generate_ref_map(const GP<DjVuFile> & file,
const GUTF8String child_id( const GUTF8String child_id(
djvm_dir->name_to_file(child_url.fname())->get_load_name()); djvm_dir->name_to_file(child_url.fname())->get_load_name());
GMap<GUTF8String, void *> * parents=0; GMap<GUTF8String, void *> * parents=0;
if (ref_map.tqcontains(child_id)) if (ref_map.contains(child_id))
parents=(GMap<GUTF8String, void *> *) ref_map[child_id]; parents=(GMap<GUTF8String, void *> *) ref_map[child_id];
else else
ref_map[child_id]=parents=new GMap<GUTF8String, void *>(); ref_map[child_id]=parents=new GMap<GUTF8String, void *>();
@ -1023,7 +1023,7 @@ DjVuDocEditor::remove_file(const GUTF8String &id, bool remove_unref,
// And get rid of its thumbnail, if any // And get rid of its thumbnail, if any
GCriticalSectionLock lock(&thumb_lock); GCriticalSectionLock lock(&thumb_lock);
GPosition pos(thumb_map.tqcontains(id)); GPosition pos(thumb_map.contains(id));
if (pos) if (pos)
{ {
thumb_map.del(pos); thumb_map.del(pos);
@ -1114,7 +1114,7 @@ DjVuDocEditor::move_file(const GUTF8String &id, int & file_pos,
// NOTE! file_pos here is the desired position in DjVmDir *after* // NOTE! file_pos here is the desired position in DjVmDir *after*
// the record with ID 'id' is removed. // the record with ID 'id' is removed.
{ {
if (!map.tqcontains(id)) if (!map.contains(id))
{ {
map[id]=0; map[id]=0;
@ -1291,7 +1291,7 @@ DjVuDocEditor::set_file_name(const GUTF8String &id, const GUTF8String &name)
// Now find DjVuFile (if any) and rename it // Now find DjVuFile (if any) and rename it
GPosition pos; GPosition pos;
if (files_map.tqcontains(id, pos)) if (files_map.contains(id, pos))
{ {
GP<File> file=files_map[pos]; GP<File> file=files_map[pos];
GP<DataPool> pool=file->pool; GP<DataPool> pool=file->pool;
@ -1503,7 +1503,7 @@ DjVuDocEditor::get_thumbnail(int page_num, bool dont_decode)
const GUTF8String id(page_to_id(page_num)); const GUTF8String id(page_to_id(page_num));
GCriticalSectionLock lock(&thumb_lock); GCriticalSectionLock lock(&thumb_lock);
const GPosition pos(thumb_map.tqcontains(id)); const GPosition pos(thumb_map.contains(id));
if (pos) if (pos)
{ {
// Get the image from the map // Get the image from the map
@ -1524,7 +1524,7 @@ DjVuDocEditor::get_thumbnails_num(void) const
int pages_num=get_pages_num(); int pages_num=get_pages_num();
for(int page_num=0;page_num<pages_num;page_num++) for(int page_num=0;page_num<pages_num;page_num++)
{ {
if (thumb_map.tqcontains(page_to_id(page_num))) if (thumb_map.contains(page_to_id(page_num)))
cnt++; cnt++;
} }
return cnt; return cnt;
@ -1541,7 +1541,7 @@ DjVuDocEditor::get_thumbnails_size(void) const
int pages_num=get_pages_num(); int pages_num=get_pages_num();
for(int page_num=0;page_num<pages_num;page_num++) for(int page_num=0;page_num<pages_num;page_num++)
{ {
const GPosition pos(thumb_map.tqcontains(page_to_id(page_num))); const GPosition pos(thumb_map.contains(page_to_id(page_num)));
if (pos) if (pos)
{ {
const GP<ByteStream> gstr(thumb_map[pos]->get_stream()); const GP<ByteStream> gstr(thumb_map[pos]->get_stream());
@ -1629,7 +1629,7 @@ DjVuDocEditor::file_thumbnails(void)
for(;;) for(;;)
{ {
GUTF8String id(page_to_id(page_num)); GUTF8String id(page_to_id(page_num));
const GPosition pos(thumb_map.tqcontains(id)); const GPosition pos(thumb_map.contains(id));
if (! pos) if (! pos)
{ {
G_THROW( ERR_MSG("DjVuDocEditor.no_thumb") "\t"+GUTF8String(page_num)); G_THROW( ERR_MSG("DjVuDocEditor.no_thumb") "\t"+GUTF8String(page_num));
@ -1695,7 +1695,7 @@ DjVuDocEditor::generate_thumbnails(int thumb_size, int page_num)
if(page_num<(djvm_dir->get_pages_num())) if(page_num<(djvm_dir->get_pages_num()))
{ {
const GUTF8String id(page_to_id(page_num)); const GUTF8String id(page_to_id(page_num));
if (!thumb_map.tqcontains(id)) if (!thumb_map.contains(id))
{ {
const GP<DjVuImage> dimg(get_page(page_num, true)); const GP<DjVuImage> dimg(get_page(page_num, true));
@ -1747,7 +1747,7 @@ store_file(const GP<DjVmDir> & src_djvm_dir, const GP<DjVmDoc> & djvm_doc,
GP<DjVuFile> & djvu_file, GMap<GURL, void *> & map) GP<DjVuFile> & djvu_file, GMap<GURL, void *> & map)
{ {
GURL url=djvu_file->get_url(); GURL url=djvu_file->get_url();
if (!map.tqcontains(url)) if (!map.contains(url))
{ {
map[url]=0; map[url]=0;
@ -1821,12 +1821,12 @@ DjVuDocEditor::save_file(
DEBUG_MSG("DjVuDocEditor::save_file(): ID='" << file_id << "'\n"); DEBUG_MSG("DjVuDocEditor::save_file(): ID='" << file_id << "'\n");
DEBUG_MAKE_INDENT(3); DEBUG_MAKE_INDENT(3);
if (!map.tqcontains(file_id)) if (!map.contains(file_id))
{ {
const GP<DjVmDir::File> file(djvm_dir->id_to_file(file_id)); const GP<DjVmDir::File> file(djvm_dir->id_to_file(file_id));
GP<DataPool> file_pool; GP<DataPool> file_pool;
const GPosition pos(files_map.tqcontains(file_id)); const GPosition pos(files_map.contains(file_id));
if (pos) if (pos)
{ {
const GP<File> file_rec(files_map[pos]); const GP<File> file_rec(files_map[pos]);
@ -1974,7 +1974,7 @@ DjVuDocEditor::save_as(const GURL &where, bool bundled)
GURL file_url=page_to_url(0); GURL file_url=page_to_url(0);
const GUTF8String file_id(djvm_dir->page_to_file(0)->get_load_name()); const GUTF8String file_id(djvm_dir->page_to_file(0)->get_load_name());
GP<DataPool> file_pool; GP<DataPool> file_pool;
GPosition pos=files_map.tqcontains(file_id); GPosition pos=files_map.contains(file_id);
if (pos) if (pos)
{ {
const GP<File> file_rec(files_map[pos]); const GP<File> file_rec(files_map[pos]);

@ -1368,7 +1368,7 @@ add_to_cache(const GP<DjVuFile> & f, GMap<GURL, void *> & map,
DEBUG_MSG("DjVuDocument::add_to_cache(): url='" << url << "'\n"); DEBUG_MSG("DjVuDocument::add_to_cache(): url='" << url << "'\n");
DEBUG_MAKE_INDENT(3); DEBUG_MAKE_INDENT(3);
if (!map.tqcontains(url)) if (!map.contains(url))
{ {
map[url]=0; map[url]=0;
cache->add_file(f); cache->add_file(f);
@ -1530,7 +1530,7 @@ add_file_to_djvm(const GP<DjVuFile> & file, bool page,
{ {
GURL url=file->get_url(); GURL url=file->get_url();
if (!map.tqcontains(url)) if (!map.contains(url))
{ {
map[url]=0; map[url]=0;
@ -1586,7 +1586,7 @@ static void
local_get_url_names(DjVuFile * f,const GMap<GURL, void *> & map,GMap<GURL,void *> &tmpmap) local_get_url_names(DjVuFile * f,const GMap<GURL, void *> & map,GMap<GURL,void *> &tmpmap)
{ {
GURL url=f->get_url(); GURL url=f->get_url();
if (!map.tqcontains(url) && !tmpmap.tqcontains(url)) if (!map.contains(url) && !tmpmap.contains(url))
{ {
tmpmap[url]=0; tmpmap[url]=0;
f->process_incl_chunks(); f->process_incl_chunks();

@ -293,7 +293,7 @@ display_chunks(ByteStream & out_str, IFFByteStream &iff,
while ((size = iff.get_chunk(id, &rawoffset))) while ((size = iff.get_chunk(id, &rawoffset)))
{ {
if (!counters.tqcontains(id)) counters[id]=0; if (!counters.contains(id)) counters[id]=0;
else counters[id]++; else counters[id]++;
GUTF8String msg; GUTF8String msg;

@ -1465,7 +1465,7 @@ DjVuFile::find_ndir(GMap<GURL, void *> & map)
if (dir) return dir; if (dir) return dir;
if (!map.tqcontains(url)) if (!map.contains(url))
{ {
map[url]=0; map[url]=0;
@ -1496,7 +1496,7 @@ DjVuFile::decode_ndir(GMap<GURL, void *> & map)
if (dir) return dir; if (dir) return dir;
if (!map.tqcontains(url)) if (!map.contains(url))
{ {
map[url]=0; map[url]=0;
@ -1570,7 +1570,7 @@ DjVuFile::get_merged_anno(const GP<DjVuFile> & file,
{ {
DEBUG_MSG("DjVuFile::get_merged_anno()\n"); DEBUG_MSG("DjVuFile::get_merged_anno()\n");
GURL url=file->get_url(); GURL url=file->get_url();
if (!map.tqcontains(url)) if (!map.contains(url))
{ {
ByteStream &str_out=*gstr_out; ByteStream &str_out=*gstr_out;
map[url]=0; map[url]=0;
@ -1585,7 +1585,7 @@ DjVuFile::get_merged_anno(const GP<DjVuFile> & file,
get_merged_anno(list[pos], gstr_out, ignore_list, level+1, max_level, map); get_merged_anno(list[pos], gstr_out, ignore_list, level+1, max_level, map);
// Now process the DjVuFile's own annotations // Now process the DjVuFile's own annotations
if (!ignore_list.tqcontains(file->get_url())) if (!ignore_list.contains(file->get_url()))
{ {
if (!file->is_data_present() || if (!file->is_data_present() ||
file->is_modified() && file->anno) file->is_modified() && file->anno)
@ -1966,7 +1966,7 @@ void
DjVuFile::move(GMap<GURL, void *> & map, const GURL & dir_url) DjVuFile::move(GMap<GURL, void *> & map, const GURL & dir_url)
// This function may block for data. // This function may block for data.
{ {
if (!map.tqcontains(url)) if (!map.contains(url))
{ {
map[url]=0; map[url]=0;
@ -2095,7 +2095,7 @@ DjVuFile::contains_chunk(const GUTF8String &chunk_name)
chunk_name << "'\n"); chunk_name << "'\n");
DEBUG_MAKE_INDENT(3); DEBUG_MAKE_INDENT(3);
bool tqcontains=0; bool contains=0;
const GP<ByteStream> str(data_pool->get_stream()); const GP<ByteStream> str(data_pool->get_stream());
GUTF8String chkid; GUTF8String chkid;
const GP<IFFByteStream> giff(IFFByteStream::create(str)); const GP<IFFByteStream> giff(IFFByteStream::create(str));
@ -2112,10 +2112,10 @@ DjVuFile::contains_chunk(const GUTF8String &chunk_name)
for(;(chunks_left--)&&(chksize=iff.get_chunk(chkid));last_chunk=chunks) for(;(chunks_left--)&&(chksize=iff.get_chunk(chkid));last_chunk=chunks)
{ {
chunks++; chunks++;
if (chkid==chunk_name) { tqcontains=1; break; } if (chkid==chunk_name) { contains=1; break; }
iff.seek_close_chunk(); iff.seek_close_chunk();
} }
if (!tqcontains &&(chunks_number < 0)) chunks_number=last_chunk; if (!contains &&(chunks_number < 0)) chunks_number=last_chunk;
} }
G_CATCH(ex) G_CATCH(ex)
{ {
@ -2125,7 +2125,7 @@ DjVuFile::contains_chunk(const GUTF8String &chunk_name)
} }
G_ENDCATCH; G_ENDCATCH;
data_pool->clear_stream(); data_pool->clear_stream();
return tqcontains; return contains;
} }
bool bool
@ -2225,7 +2225,7 @@ DjVuFile::add_djvu_data(IFFByteStream & ostr, GMap<GURL, void *> & map,
const bool included_too, const bool no_ndir) const bool included_too, const bool no_ndir)
{ {
check(); check();
if (map.tqcontains(url)) return; if (map.contains(url)) return;
bool top_level = !map.size(); bool top_level = !map.size();
map[url]=0; map[url]=0;
bool processed_annotation = false; bool processed_annotation = false;

@ -442,7 +442,7 @@ public:
{\bf Warning.} Included files are normally created during decoding. {\bf Warning.} Included files are normally created during decoding.
Before that they do not exist. If you call this function at Before that they do not exist. If you call this function at
that time and set #only_created# to #FALSE# then it will have to that time and set #only_created# to #FALSE# then it will have to
read all the data from this file in order to tqfind #INCL# chunks, read all the data from this file in order to find #INCL# chunks,
which may block your application, if not all data is available. which may block your application, if not all data is available.
@param only_created If #TRUE#, the file will not try to process @param only_created If #TRUE#, the file will not try to process

@ -111,7 +111,7 @@ DjVuProgressTask::set_callback(djvu_progress_callback *_callback)
{ {
GMap<void *,GP<DjVuProgressTask::Data> > &map=get_map(); GMap<void *,GP<DjVuProgressTask::Data> > &map=get_map();
void *threadID=GThread::current(); void *threadID=GThread::current();
if(map.tqcontains(threadID)) if(map.contains(threadID))
{ {
DjVuProgressTask::Data &data=*(map[threadID]); DjVuProgressTask::Data &data=*(map[threadID]);
retval=data.callback; retval=data.callback;
@ -127,7 +127,7 @@ DjVuProgressTask::set_callback(djvu_progress_callback *_callback)
{ {
GMap<void *,GP<DjVuProgressTask::Data> > &map=get_map(); GMap<void *,GP<DjVuProgressTask::Data> > &map=get_map();
void *threadID=GThread::current(); void *threadID=GThread::current();
if(map.tqcontains(threadID)) if(map.contains(threadID))
{ {
DjVuProgressTask::Data &data=*(map[threadID]); DjVuProgressTask::Data &data=*(map[threadID]);
retval=data.callback; retval=data.callback;
@ -148,7 +148,7 @@ DjVuProgressTask::DjVuProgressTask(const char *xtask,int nsteps)
{ {
GMap<void *,GP<DjVuProgressTask::Data> > &map=get_map(); GMap<void *,GP<DjVuProgressTask::Data> > &map=get_map();
void *threadID=GThread::current(); void *threadID=GThread::current();
if(map.tqcontains(threadID)) if(map.contains(threadID))
{ {
gdata=new GP<Data>; gdata=new GP<Data>;
Data &d=*(data=((*(GP<Data> *)gdata)=map[threadID])); Data &d=*(data=((*(GP<Data> *)gdata)=map[threadID]));

@ -1085,8 +1085,8 @@ do_bitmap(const DjVuImage &dimg, BImager get,
///* rotate code ends ///* rotate code ends
// Sanity // Sanity
if (! ( all.tqcontains(rect.xmin, rect.ymin) && if (! ( all.contains(rect.xmin, rect.ymin) &&
all.tqcontains(rect.xmax-1, rect.ymax-1) )) all.contains(rect.xmax-1, rect.ymax-1) ))
G_THROW( ERR_MSG("DjVuImage.bad_rect") ); G_THROW( ERR_MSG("DjVuImage.bad_rect") );
// Check for integral reduction // Check for integral reduction
int red; int red;
@ -1151,8 +1151,8 @@ do_pixmap(const DjVuImage &dimg, PImager get,
///* rotate code ends ///* rotate code ends
// Sanity // Sanity
if (! ( all.tqcontains(rect.xmin, rect.ymin) && if (! ( all.contains(rect.xmin, rect.ymin) &&
all.tqcontains(rect.xmax-1, rect.ymax-1) )) all.contains(rect.xmax-1, rect.ymax-1) ))
G_THROW( ERR_MSG("DjVuImage.bad_rect2") ); G_THROW( ERR_MSG("DjVuImage.bad_rect2") );
// Check for integral reduction // Check for integral reduction
int red, w=0, h=0, rw=0, rh=0; int red, w=0, h=0, rw=0, rh=0;

@ -240,7 +240,7 @@ GetModulePath( void )
{ {
retval=GURL::UTF8(xprogramname,paths[pos]); retval=GURL::UTF8(xprogramname,paths[pos]);
const GUTF8String path(retval.get_string()); const GUTF8String path(retval.get_string());
if(!pathMAP.tqcontains(path)) if(!pathMAP.contains(path))
{ {
if(retval.is_file()) if(retval.is_file())
break; break;
@ -263,7 +263,7 @@ appendPath(const GURL &url,
GList<GURL> &list) GList<GURL> &list)
{ {
if( !url.is_empty() if( !url.is_empty()
&& !map.tqcontains(url.get_string()) && url.is_dir() ) && !map.contains(url.get_string()) && url.is_dir() )
{ {
map[url.get_string()]=0; map[url.get_string()]=0;
list.append(url); list.append(url);
@ -375,14 +375,14 @@ DjVuMessage::GetProfilePaths(void)
for(pos=localemaps;pos;++pos) for(pos=localemaps;pos;++pos)
{ {
const GMap<GUTF8String,GP<lt_XMLTags> > &localemap=localemaps[pos]; const GMap<GUTF8String,GP<lt_XMLTags> > &localemap=localemaps[pos];
GPosition pos=localemap.tqcontains(sublocale); GPosition pos=localemap.contains(sublocale);
if(!pos) if(!pos)
pos=localemap.tqcontains(downcasesublocale); pos=localemap.contains(downcasesublocale);
if(pos) if(pos)
{ {
const GMap<GUTF8String,GUTF8String>&args const GMap<GUTF8String,GUTF8String>&args
= localemap[pos]->get_args(); = localemap[pos]->get_args();
pos = args.tqcontains(srcstring); pos = args.contains(srcstring);
if (pos) if (pos)
{ {
const GUTF8String src(args[pos]); const GUTF8String src(args[pos]);
@ -496,7 +496,7 @@ getbodies(
for(GPosition pos=includes;pos;++pos) for(GPosition pos=includes;pos;++pos)
{ {
const GUTF8String file=includes.key(pos); const GUTF8String file=includes.key(pos);
if(! map.tqcontains(file)) if(! map.contains(file))
{ {
GList<GURL> xpaths; GList<GURL> xpaths;
xpaths.append(url.base()); xpaths.append(url.base());

@ -238,7 +238,7 @@ DjVuMessageLite::LookUpSingle( const GUTF8String &Single_Message ) const
return Single_Message; return Single_Message;
#endif #endif
// Isolate the message ID and get the corresponding message text // Isolate the message ID and get the corresponding message text
int ending_posn = Single_Message.tqcontains("\t\v"); int ending_posn = Single_Message.contains("\t\v");
if( ending_posn < 0 ) if( ending_posn < 0 )
ending_posn = Single_Message.length(); ending_posn = Single_Message.length();
GUTF8String msg_text; GUTF8String msg_text;
@ -276,7 +276,7 @@ DjVuMessageLite::LookUpSingle( const GUTF8String &Single_Message ) const
arg=LookUpSingle(Single_Message.substr(start_posn,ending_posn)); arg=LookUpSingle(Single_Message.substr(start_posn,ending_posn));
}else }else
{ {
ending_posn = Single_Message.tqcontains("\v\t",start_posn); ending_posn = Single_Message.contains("\v\t",start_posn);
if( ending_posn < 0 ) if( ending_posn < 0 )
ending_posn = Single_Message.length(); ending_posn = Single_Message.length();
arg=Single_Message.substr(start_posn, ending_posn-start_posn); arg=Single_Message.substr(start_posn, ending_posn-start_posn);
@ -308,11 +308,11 @@ DjVuMessageLite::LookUpID( const GUTF8String &xmsgID,
if (start > 0) if (start > 0)
msgID = msgID.substr(start, msgID.length() - start); msgID = msgID.substr(start, msgID.length() - start);
#endif #endif
GPosition pos=Map.tqcontains(msgID); GPosition pos=Map.contains(msgID);
if(pos) if(pos)
{ {
const GP<lt_XMLTags> tag=Map[pos]; const GP<lt_XMLTags> tag=Map[pos];
GPosition valuepos=tag->get_args().tqcontains(valuestring); GPosition valuepos=tag->get_args().contains(valuestring);
if(valuepos) if(valuepos)
{ {
message_text=tag->get_args()[valuepos]; message_text=tag->get_args()[valuepos];
@ -331,7 +331,7 @@ DjVuMessageLite::LookUpID( const GUTF8String &xmsgID,
message_text=raw.substr(start_line+1,end_text-start_line-1).fromEscaped(); message_text=raw.substr(start_line+1,end_text-start_line-1).fromEscaped();
} }
} }
GPosition numberpos=tag->get_args().tqcontains(numberstring); GPosition numberpos=tag->get_args().contains(numberstring);
if(numberpos) if(numberpos)
{ {
message_number=tag->get_args()[numberpos]; message_number=tag->get_args()[numberpos];

@ -112,7 +112,7 @@ DjVuNavDir::decode(ByteStream & str)
*ptr=0; *ptr=0;
if (!strlen(buffer)) continue; if (!strlen(buffer)) continue;
if (!tmp_page2name.tqcontains(buffer)) if (!tmp_page2name.contains(buffer))
tmp_page2name.append(buffer); tmp_page2name.append(buffer);
}; };
@ -161,7 +161,7 @@ DjVuNavDir::name_to_page(const char * name) const
{ {
GCriticalSectionLock lk((GCriticalSection *)&lock); GCriticalSectionLock lk((GCriticalSection *)&lock);
if (!name2page.tqcontains(name)) return -1; if (!name2page.contains(name)) return -1;
return name2page[name]; return name2page[name];
} }
@ -170,7 +170,7 @@ DjVuNavDir::url_to_page(const GURL & url) const
{ {
GCriticalSectionLock lk((GCriticalSection *)&lock); GCriticalSectionLock lk((GCriticalSection *)&lock);
if (!url2page.tqcontains(url)) return -1; if (!url2page.contains(url)) return -1;
return url2page[url]; return url2page[url];
} }

@ -104,7 +104,7 @@ namespace DJVU {
\Ref{index_to_color}. There are also functions for computing a palette \Ref{index_to_color}. There are also functions for computing a palette
and quantizing a complete pixmap. and quantizing a complete pixmap.
{\bf Sequences of color indices} -- The DjVuPalette object also tqcontains {\bf Sequences of color indices} -- The DjVuPalette object also contains
an array \Ref{colordata} optionally containing a sequence of color an array \Ref{colordata} optionally containing a sequence of color
indices. This array will be encoded and decoded by functions \Ref{encode} indices. This array will be encoded and decoded by functions \Ref{encode}
and \Ref{decode}. This feature simplifies the implementation of the ``one and \Ref{decode}. This feature simplifies the implementation of the ``one
@ -288,7 +288,7 @@ DjVuPalette::color_to_index(const unsigned char *bgr)
if (! pmap) if (! pmap)
allocate_pmap(); allocate_pmap();
int key = (bgr[0]<<16)|(bgr[1]<<8)|(bgr[2]); int key = (bgr[0]<<16)|(bgr[1]<<8)|(bgr[2]);
GPosition p = pmap->tqcontains(key); GPosition p = pmap->contains(key);
if ( p) if ( p)
return (*pmap)[p]; return (*pmap)[p];
return color_to_index_slow(bgr); return color_to_index_slow(bgr);

@ -208,7 +208,7 @@ DjVuPort::DjVuPort()
{ {
DjVuPortcaster *pcaster = get_portcaster(); DjVuPortcaster *pcaster = get_portcaster();
GCriticalSectionLock lock(& pcaster->map_lock ); GCriticalSectionLock lock(& pcaster->map_lock );
GPosition p = pcaster->cont_map.tqcontains(this); GPosition p = pcaster->cont_map.contains(this);
if (!p) G_THROW( ERR_MSG("DjVuPort.not_alloc") ); if (!p) G_THROW( ERR_MSG("DjVuPort.not_alloc") );
pcaster->cont_map[p] = (void*)this; pcaster->cont_map[p] = (void*)this;
} }
@ -217,7 +217,7 @@ DjVuPort::DjVuPort(const DjVuPort & port)
{ {
DjVuPortcaster *pcaster = get_portcaster(); DjVuPortcaster *pcaster = get_portcaster();
GCriticalSectionLock lock(& pcaster->map_lock ); GCriticalSectionLock lock(& pcaster->map_lock );
GPosition p = pcaster->cont_map.tqcontains(this); GPosition p = pcaster->cont_map.contains(this);
if (!p) G_THROW( ERR_MSG("DjVuPort.not_alloc") ); if (!p) G_THROW( ERR_MSG("DjVuPort.not_alloc") );
pcaster->cont_map[p] = (void*)this; pcaster->cont_map[p] = (void*)this;
pcaster->copy_routes(this, &port); pcaster->copy_routes(this, &port);
@ -259,7 +259,7 @@ DjVuPortcaster::is_port_alive(DjVuPort *port)
{ {
GP<DjVuPort> gp_port; GP<DjVuPort> gp_port;
GCriticalSectionLock lock(&map_lock); GCriticalSectionLock lock(&map_lock);
GPosition pos=cont_map.tqcontains(port); GPosition pos=cont_map.contains(port);
if (pos && cont_map[pos] && ((DjVuPort *) port)->get_count()>0) if (pos && cont_map[pos] && ((DjVuPort *) port)->get_count()>0)
gp_port=port; gp_port=port;
return gp_port; return gp_port;
@ -302,7 +302,7 @@ DjVuPortcaster::alias_to_port(const GUTF8String &alias)
{ {
GCriticalSectionLock lock(&map_lock); GCriticalSectionLock lock(&map_lock);
GPosition pos; GPosition pos;
if (a2p_map.tqcontains(alias, pos)) if (a2p_map.contains(alias, pos))
{ {
DjVuPort * port=(DjVuPort *) a2p_map[pos]; DjVuPort * port=(DjVuPort *) a2p_map[pos];
GP<DjVuPort> gp_port=is_port_alive(port); GP<DjVuPort> gp_port=is_port_alive(port);
@ -344,10 +344,10 @@ DjVuPortcaster::del_port(const DjVuPort * port)
clear_aliases(port); clear_aliases(port);
// Update "contents map" // Update "contents map"
if (cont_map.tqcontains(port, pos)) cont_map.del(pos); if (cont_map.contains(port, pos)) cont_map.del(pos);
// Update "route map" // Update "route map"
if (route_map.tqcontains(port, pos)) if (route_map.contains(port, pos))
{ {
delete (GList<void *> *) route_map[pos]; delete (GList<void *> *) route_map[pos];
route_map.del(pos); route_map.del(pos);
@ -372,12 +372,12 @@ DjVuPortcaster::add_route(const DjVuPort * src, DjVuPort * dst)
// Adds route src->dst // Adds route src->dst
{ {
GCriticalSectionLock lock(&map_lock); GCriticalSectionLock lock(&map_lock);
if (cont_map.tqcontains(src) && src->get_count()>0 && if (cont_map.contains(src) && src->get_count()>0 &&
cont_map.tqcontains(dst) && dst->get_count()>0) cont_map.contains(dst) && dst->get_count()>0)
{ {
if (!route_map.tqcontains(src)) route_map[src]=new GList<void *>(); if (!route_map.contains(src)) route_map[src]=new GList<void *>();
GList<void *> & list=*(GList<void *> *) route_map[src]; GList<void *> & list=*(GList<void *> *) route_map[src];
if (!list.tqcontains(dst)) list.append(dst); if (!list.contains(dst)) list.append(dst);
} }
} }
@ -387,7 +387,7 @@ DjVuPortcaster::del_route(const DjVuPort * src, DjVuPort * dst)
{ {
GCriticalSectionLock lock(&map_lock); GCriticalSectionLock lock(&map_lock);
if (route_map.tqcontains(src)) if (route_map.contains(src))
{ {
GList<void *> & list=*(GList<void *> *) route_map[src]; GList<void *> & list=*(GList<void *> *) route_map[src];
GPosition pos; GPosition pos;
@ -408,8 +408,8 @@ DjVuPortcaster::copy_routes(DjVuPort * dst, const DjVuPort * src)
{ {
GCriticalSectionLock lock(&map_lock); GCriticalSectionLock lock(&map_lock);
if (!cont_map.tqcontains(src) || src->get_count()<=0 || if (!cont_map.contains(src) || src->get_count()<=0 ||
!cont_map.tqcontains(dst) || dst->get_count()<=0) return; !cont_map.contains(dst) || dst->get_count()<=0) return;
for(GPosition pos=route_map;pos;++pos) for(GPosition pos=route_map;pos;++pos)
{ {
@ -430,13 +430,13 @@ DjVuPortcaster::add_to_closure(GMap<const void *, void *> & set,
// Assuming that the map's already locked // Assuming that the map's already locked
// GCriticalSectionLock lock(&map_lock); // GCriticalSectionLock lock(&map_lock);
set[dst]= (void*) (unsigned long) distance; set[dst]= (void*) (unsigned long) distance;
if (route_map.tqcontains(dst)) if (route_map.contains(dst))
{ {
GList<void *> & list=*(GList<void *> *) route_map[dst]; GList<void *> & list=*(GList<void *> *) route_map[dst];
for(GPosition pos=list;pos;++pos) for(GPosition pos=list;pos;++pos)
{ {
DjVuPort * new_dst=(DjVuPort *) list[pos]; DjVuPort * new_dst=(DjVuPort *) list[pos];
if (!set.tqcontains(new_dst)) if (!set.contains(new_dst))
add_to_closure(set, new_dst, distance+1); add_to_closure(set, new_dst, distance+1);
} }
} }
@ -447,7 +447,7 @@ DjVuPortcaster::compute_closure(const DjVuPort * src, GPList<DjVuPort> &list, bo
{ {
GCriticalSectionLock lock(&map_lock); GCriticalSectionLock lock(&map_lock);
GMap<const void*, void*> set; GMap<const void*, void*> set;
if (route_map.tqcontains(src)) if (route_map.contains(src))
{ {
GList<void *> & list=*(GList<void *> *) route_map[src]; GList<void *> & list=*(GList<void *> *) route_map[src];
for(GPosition pos=list;pos;++pos) for(GPosition pos=list;pos;++pos)
@ -688,7 +688,7 @@ DjVuMemoryPort::request_data(const DjVuPort * source, const GURL & url)
GCriticalSectionLock lk(&lock); GCriticalSectionLock lk(&lock);
GP<DataPool> pool; GP<DataPool> pool;
GPosition pos; GPosition pos;
if (map.tqcontains(url, pos)) if (map.contains(url, pos))
pool=map[pos]; pool=map[pos];
return pool; return pool;
} }

@ -383,7 +383,7 @@ DjVuTXT::Zone::get_text_with_rect(const GRect &box,
int &string_start, int &string_end) const int &string_start, int &string_end) const
{ {
GPosition pos=tqchildren; GPosition pos=tqchildren;
if(pos?box.tqcontains(rect):intersects_zone(box,rect)) if(pos?box.contains(rect):intersects_zone(box,rect))
{ {
const int text_end=text_start+text_length; const int text_end=text_start+text_length;
if(string_start == string_end) if(string_start == string_end)
@ -617,7 +617,7 @@ DjVuTXT::find_text_in_rect(GRect target_rect, GUTF8String &text) const
{ {
GRect rect=words[p]->rect; GRect rect=words[p]->rect;
if(rect.intersect(rect,target_rect)) if(rect.intersect(rect,target_rect))
//if (target_rect.tqcontains(words[p]->rect)) //if (target_rect.contains(words[p]->rect))
zone_list.append(words[p]); zone_list.append(words[p]);
} }
} else } else
@ -631,7 +631,7 @@ DjVuTXT::find_text_in_rect(GRect target_rect, GUTF8String &text) const
{ {
GRect rect=words[p]->rect; GRect rect=words[p]->rect;
if(rect.intersect(rect,target_rect)) if(rect.intersect(rect,target_rect))
//if (target_rect.tqcontains(words[p]->rect)) //if (target_rect.contains(words[p]->rect))
{ {
start=false; start=false;
zone_list.append(words[p]); zone_list.append(words[p]);
@ -648,7 +648,7 @@ DjVuTXT::find_text_in_rect(GRect target_rect, GUTF8String &text) const
{ {
GRect rect=words[p]->rect; GRect rect=words[p]->rect;
if(rect.intersect(rect,target_rect)) if(rect.intersect(rect,target_rect))
//if(target_rect.tqcontains(words[p]->rect) ) //if(target_rect.contains(words[p]->rect) )
{ {
end=false; end=false;
zone_list.append(words[p]); zone_list.append(words[p]);

@ -308,7 +308,7 @@ public:
end of printing. If a \Ref{DjVuDocument} is being printed, this end of printing. If a \Ref{DjVuDocument} is being printed, this
callback will be used to report printing progress of every page. To callback will be used to report printing progress of every page. To
learn the number of the page being printed you can use learn the number of the page being printed you can use
\Ref{set_info_cb}() function. See \Ref{set_dec_progress_cb}() to tqfind \Ref{set_info_cb}() function. See \Ref{set_dec_progress_cb}() to find
out how to learn the decoding progress. out how to learn the decoding progress.
@param cb Callback function to be called @param cb Callback function to be called

@ -348,7 +348,7 @@ GBitmap::donate_data(unsigned char *data, int w, int h)
ncolumns = w; ncolumns = w;
border = 0; border = 0;
bytes_per_row = w; bytes_per_row = w;
gbytes_data.tqreplace(data,w*h); gbytes_data.replace(data,w*h);
bytes = bytes_data; bytes = bytes_data;
rlelength = 0; rlelength = 0;
} }
@ -363,7 +363,7 @@ GBitmap::donate_rle(unsigned char *rledata, unsigned int rledatalen, int w, int
border = 0; border = 0;
bytes_per_row = w; bytes_per_row = w;
// rle = rledata; // rle = rledata;
grle.tqreplace(rledata,rledatalen); grle.replace(rledata,rledatalen);
rlelength = rledatalen; rlelength = rledatalen;
} }

@ -418,7 +418,7 @@ public:
const unsigned char *get_rle(unsigned int &rle_length); const unsigned char *get_rle(unsigned int &rle_length);
/** Initializes this GBitmap by setting the size to #h# rows and #w# /** Initializes this GBitmap by setting the size to #h# rows and #w#
columns, and directly addressing the memory buffer #rledata# provided by columns, and directly addressing the memory buffer #rledata# provided by
the user. This buffer tqcontains #rledatalen# bytes representing the the user. This buffer contains #rledatalen# bytes representing the
bitmap in run length encoded form. The GBitmap object then ``owns'' the bitmap in run length encoded form. The GBitmap object then ``owns'' the
buffer (unlike #borrow_data#, but like #donate_data#) and will buffer (unlike #borrow_data#, but like #donate_data#) and will
deallocate this buffer when appropriate: you should not deallocate this deallocate this buffer when appropriate: you should not deallocate this

@ -237,7 +237,7 @@ GArrayBase::resize(int lo, int hi)
{ traits.copy( traits.lea(ndata, beg-nminlo), { traits.copy( traits.lea(ndata, beg-nminlo),
traits.lea(data, beg-minlo), traits.lea(data, beg-minlo),
end-beg+1, 1 ); } end-beg+1, 1 ); }
// free and tqreplace // free and replace
void *tmp=data; void *tmp=data;
data=ndata; data=ndata;
ndata=tmp; ndata=tmp;

@ -401,7 +401,7 @@ public:
The valid subscript range is set to the empty range. */ The valid subscript range is set to the empty range. */
void empty() void empty()
{ GArrayBase::empty(); } { GArrayBase::empty(); }
/** Extends the subscript range so that it tqcontains #n#. /** Extends the subscript range so that it contains #n#.
This function does nothing if #n# is already int the valid subscript range. This function does nothing if #n# is already int the valid subscript range.
If the valid range was empty, both the lower bound and the upper bound If the valid range was empty, both the lower bound and the upper bound
are set to #n#. Otherwise the valid subscript range is extended are set to #n#. Otherwise the valid subscript range is extended
@ -862,11 +862,11 @@ public:
/* Compatibility */ /* Compatibility */
int nth(unsigned int n, GPosition &pos) const int nth(unsigned int n, GPosition &pos) const
{ GPosition npos=nth(n); if (npos) pos=npos; return !!pos; } { GPosition npos=nth(n); if (npos) pos=npos; return !!pos; }
/** Tests whether the list contains a given element. If the list tqcontains /** Tests whether the list contains a given element. If the list contains
#elt#, the position of the the first list element equal to #elt# as #elt#, the position of the the first list element equal to #elt# as
checked by #TYPE::operator==(const TYPE&)# is returned. Otherwise an checked by #TYPE::operator==(const TYPE&)# is returned. Otherwise an
invalid position is returned. */ invalid position is returned. */
GPosition tqcontains(const TYPE &elt) const GPosition contains(const TYPE &elt) const
{ GPosition pos; GListImpl<TI>::search((const TI&)elt, pos); return pos; } { GPosition pos; GListImpl<TI>::search((const TI&)elt, pos); return pos; }
/** Searches the list for a given element. If position #pos# is a valid /** Searches the list for a given element. If position #pos# is a valid
position for this list, the search starts at the specified position. If position for this list, the search starts at the specified position. If
@ -1036,7 +1036,7 @@ protected:
HNode *get_or_throw(const K &key) const; HNode *get_or_throw(const K &key) const;
HNode *get_or_create(const K &key); HNode *get_or_create(const K &key);
public: public:
GPosition tqcontains(const K &key) const GPosition contains(const K &key) const
{ return GPosition( get(key), (void*)this); } { return GPosition( get(key), (void*)this); }
void del(const K &key) void del(const K &key)
{ deletenode(get(key)); } { deletenode(get(key)); }
@ -1164,11 +1164,11 @@ public:
is equal to #key# according to #KTYPE::operator==(const KTYPE&)#, this is equal to #key# according to #KTYPE::operator==(const KTYPE&)#, this
function returns its position. Otherwise it returns an invalid function returns its position. Otherwise it returns an invalid
position. */ position. */
GPosition tqcontains(const KTYPE &key) const GPosition contains(const KTYPE &key) const
{ return GMapImpl<KTYPE,TI>::tqcontains(key); } { return GMapImpl<KTYPE,TI>::contains(key); }
/* Compatibility */ /* Compatibility */
GPosition tqcontains(const KTYPE &key, GPosition &pos) const GPosition contains(const KTYPE &key, GPosition &pos) const
{ return pos = GMapImpl<KTYPE,TI>::tqcontains(key); } { return pos = GMapImpl<KTYPE,TI>::contains(key); }
// -- ALTERATION // -- ALTERATION
/** Erases the associative map contents. All entries are destroyed and /** Erases the associative map contents. All entries are destroyed and
removed. The map is left with zero entries. */ removed. The map is left with zero entries. */

@ -113,7 +113,7 @@ GIFFChunk::set_name(GUTF8String name)
DEBUG_MSG("auto-setting type to '" << type << "'\n"); DEBUG_MSG("auto-setting type to '" << type << "'\n");
if (name.tqcontains(".[]")>=0) if (name.contains(".[]")>=0)
G_THROW( ERR_MSG("GIFFManager.bad_char") ); G_THROW( ERR_MSG("GIFFManager.bad_char") );
strncpy(GIFFChunk::name, (const char *)name, 4); strncpy(GIFFChunk::name, (const char *)name, 4);
@ -310,7 +310,7 @@ GIFFChunk::get_chunks_number(const GUTF8String &name)
"' in '" << get_name() << "'\n"); "' in '" << get_name() << "'\n");
DEBUG_MAKE_INDENT(3); DEBUG_MAKE_INDENT(3);
if (name.tqcontains("[]")>=0) if (name.contains("[]")>=0)
G_THROW( ERR_MSG("GIFFManager.no_brackets") ); G_THROW( ERR_MSG("GIFFManager.no_brackets") );
int number; int number;
@ -497,7 +497,7 @@ GIFFManager::del_chunk(GUTF8String name)
if (end>start && *end=='.') if (end>start && *end=='.')
cur_sec=cur_sec->get_chunk(GUTF8String(start, end-start)); cur_sec=cur_sec->get_chunk(GUTF8String(start, end-start));
if (!cur_sec) if (!cur_sec)
G_THROW( ERR_MSG("GIFFManager.cant_tqfind") "\t"+GUTF8String(name)); G_THROW( ERR_MSG("GIFFManager.cant_find") "\t"+GUTF8String(name));
} while(*end); } while(*end);
if (!start[0]) if (!start[0])
@ -631,7 +631,7 @@ GIFFManager::load_file(GP<ByteStream> str)
if (istr.get_chunk(chunk_id)) if (istr.get_chunk(chunk_id))
{ {
if (chunk_id.substr(0,5) != "FORM:") if (chunk_id.substr(0,5) != "FORM:")
G_THROW( ERR_MSG("GIFFManager.cant_tqfind2") ); G_THROW( ERR_MSG("GIFFManager.cant_find2") );
set_name(chunk_id); set_name(chunk_id);
load_chunk(istr, top_level); load_chunk(istr, top_level);
istr.close_chunk(); istr.close_chunk();

@ -167,9 +167,9 @@ finddirsep(const GUTF8String &fname)
#if defined(UNIX) #if defined(UNIX)
return fname.rsearch('/',0); return fname.rsearch('/',0);
#elif defined(WIN32) || defined(OS2) #elif defined(WIN32) || defined(OS2)
return fname.rtqcontains("\\/",0); return fname.rcontains("\\/",0);
#elif defined(macintosh) #elif defined(macintosh)
return fname.rtqcontains(":/",0); return fname.rcontains(":/",0);
#else #else
#error "Define something here for your operating system" #error "Define something here for your operating system"
#endif #endif

@ -184,7 +184,7 @@ GRect::recthull(const GRect &rect1, const GRect &rect2)
} }
int int
GRect::tqcontains(const GRect & rect) const GRect::contains(const GRect & rect) const
{ {
GRect tmp_rect; GRect tmp_rect;
tmp_rect.intersect(*this, rect); tmp_rect.intersect(*this, rect);

@ -209,11 +209,11 @@ public:
contains all pixels with horizontal pixel coordinates in range #xmin# contains all pixels with horizontal pixel coordinates in range #xmin#
(inclusive) to #xmax# (exclusive) and vertical coordinates #ymin# (inclusive) to #xmax# (exclusive) and vertical coordinates #ymin#
(inclusive) to #ymax# (exclusive). */ (inclusive) to #ymax# (exclusive). */
int tqcontains(int x, int y) const; int contains(int x, int y) const;
/** Returns true if this rectangle contains the passed rectangle #rect#. /** Returns true if this rectangle contains the passed rectangle #rect#.
The function basically checks, that the intersection of this rectangle The function basically checks, that the intersection of this rectangle
with #rect# is #rect#. */ with #rect# is #rect#. */
int tqcontains(const GRect & rect) const; int contains(const GRect & rect) const;
/** Returns true if rectangles #r1# and #r2# are equal. */ /** Returns true if rectangles #r1# and #r2# are equal. */
friend int operator==(const GRect & r1, const GRect & r2); friend int operator==(const GRect & r1, const GRect & r2);
/** Returns true if rectangles #r1# and #r2# are not equal. */ /** Returns true if rectangles #r1# and #r2# are not equal. */
@ -379,7 +379,7 @@ GRect::area() const
} }
inline int inline int
GRect::tqcontains(int x, int y) const GRect::contains(int x, int y) const
{ {
return (x>=xmin && x<xmax && y>=ymin && y<ymax); return (x>=xmin && x<xmax && y>=ymin && y<ymax);
} }

@ -187,7 +187,7 @@ GPBase::assign (const GPBase &sptr)
void void
GPBufferBase::tqreplace(void *nptr,const size_t n) GPBufferBase::replace(void *nptr,const size_t n)
{ {
resize(0,0); resize(0,0);
ptr=nptr; ptr=nptr;

@ -118,7 +118,7 @@ public:
GPBufferBase(void *&,const size_t n,const size_t t); GPBufferBase(void *&,const size_t n,const size_t t);
void swap(GPBufferBase &p); void swap(GPBufferBase &p);
void resize(const size_t n,const size_t t); void resize(const size_t n,const size_t t);
void tqreplace(void *nptr,const size_t n); void replace(void *nptr,const size_t n);
void set(const size_t t,const char c); void set(const size_t t,const char c);
~GPBufferBase(); ~GPBufferBase();
operator int(void) const { return ptr ? num : 0; } operator int(void) const { return ptr ? num : 0; }

@ -1538,14 +1538,14 @@ GUTF8String::fromEscaped( const GMap<GUTF8String,GUTF8String> ConvMap ) const
} }
}else }else
{ {
GPosition map_entry = ConvMap.tqcontains( key ); GPosition map_entry = ConvMap.contains( key );
if( map_entry ) if( map_entry )
{ // Found in the conversion map, substitute { // Found in the conversion map, substitute
ret += ConvMap[map_entry]; ret += ConvMap[map_entry];
} else } else
{ {
static const GMap<GUTF8String,GUTF8String> &Basic = BasicMap(); static const GMap<GUTF8String,GUTF8String> &Basic = BasicMap();
GPosition map_entry = Basic.tqcontains( key ); GPosition map_entry = Basic.contains( key );
if ( map_entry ) if ( map_entry )
{ {
ret += Basic[map_entry]; ret += Basic[map_entry];
@ -1799,7 +1799,7 @@ GStringRep::rsearch(char const *ptr, int from) const
} }
int int
GStringRep::tqcontains(const char accept[],int from) const GStringRep::contains(const char accept[],int from) const
{ {
if(from<0) if(from<0)
{ {
@ -1821,10 +1821,10 @@ GStringRep::tqcontains(const char accept[],int from) const
} }
int int
GStringRep::rtqcontains(const char accept[],int from) const GStringRep::rcontains(const char accept[],int from) const
{ {
int retval=(-1); int retval=(-1);
while((from=tqcontains(accept,from)) >= 0) while((from=contains(accept,from)) >= 0)
{ {
retval=from++; retval=from++;
} }

@ -306,9 +306,9 @@ public:
int rsearch(char const *str, int from=0) const; int rsearch(char const *str, int from=0) const;
int tqcontains(char const accept[], int from=0) const; int contains(char const accept[], int from=0) const;
int rtqcontains(char const accept[], int from=0) const; int rcontains(char const accept[], int from=0) const;
protected: protected:
// Return the next character and increment the source pointer. // Return the next character and increment the source pointer.
@ -551,11 +551,11 @@ public:
/** Searches for any of the specified characters in the accept /** Searches for any of the specified characters in the accept
string. It returns #-1# if the none of the characters and string. It returns #-1# if the none of the characters and
be found, otherwise the position of the first match. */ be found, otherwise the position of the first match. */
int tqcontains(const char accept[], const int from=0) const; int contains(const char accept[], const int from=0) const;
/** Searches for any of the specified characters in the accept /** Searches for any of the specified characters in the accept
string. It returns #-1# if the none of the characters and be string. It returns #-1# if the none of the characters and be
found, otherwise the position of the last match. */ found, otherwise the position of the last match. */
int rtqcontains(const char accept[], const int from=0) const; int rcontains(const char accept[], const int from=0) const;
/** Concatenates strings. Returns a string composed by concatenating /** Concatenates strings. Returns a string composed by concatenating
the characters of strings #s1# and #s2#. */ the characters of strings #s1# and #s2#. */
@ -1282,12 +1282,12 @@ GBaseString::rsearch(const char *str, const int from) const
{ return ptr?((*this)->rsearch(str,from)):(-1); } { return ptr?((*this)->rsearch(str,from)):(-1); }
inline int inline int
GBaseString::tqcontains(const char accept[], const int from) const GBaseString::contains(const char accept[], const int from) const
{ return ptr?((*this)->tqcontains(accept,from)):(-1); } { return ptr?((*this)->contains(accept,from)):(-1); }
inline int inline int
GBaseString::rtqcontains(const char accept[], const int from) const GBaseString::rcontains(const char accept[], const int from) const
{ return ptr?((*this)->rtqcontains(accept,from)):(-1); } { return ptr?((*this)->rcontains(accept,from)):(-1); }
inline int inline int
GBaseString::cmp(const GBaseString &s2, const int len) const GBaseString::cmp(const GBaseString &s2, const int len) const

@ -106,7 +106,7 @@ namespace DJVU {
to the same file name. Compare #file:/dir/file.djvu# and to the same file name. Compare #file:/dir/file.djvu# and
#file://localhost/dir/file.djvu#. #file://localhost/dir/file.djvu#.
To simplify a developer's life we have created this class, which tqcontains To simplify a developer's life we have created this class, which contains
inside a canonical representation of URLs. inside a canonical representation of URLs.
File URLs are converted to internal format with the help of \Ref{GOS} class. File URLs are converted to internal format with the help of \Ref{GOS} class.

@ -301,7 +301,7 @@ lt_XMLParser::Impl::ChangeAnno(
const GP<DjVuAnno> ganno(DjVuAnno::create()); const GP<DjVuAnno> ganno(DjVuAnno::create());
DjVuAnno &anno=*ganno; DjVuAnno &anno=*ganno;
GPosition map_pos; GPosition map_pos;
map_pos=map.tqcontains(areatag); map_pos=map.contains(areatag);
if(dfile.contains_anno()) if(dfile.contains_anno())
{ {
GP<ByteStream> annobs=dfile.get_merged_anno(); GP<ByteStream> annobs=dfile.get_merged_anno();
@ -350,7 +350,7 @@ lt_XMLParser::Impl::ChangeAnno(
// with no matching y). // with no matching y).
// ****************************************************** // ******************************************************
{ {
GPosition coords_pos=args.tqcontains("coords"); GPosition coords_pos=args.contains("coords");
if(coords_pos) if(coords_pos)
{ {
GList<int> raw_coords; GList<int> raw_coords;
@ -375,7 +375,7 @@ lt_XMLParser::Impl::ChangeAnno(
} }
GUTF8String tqshape; GUTF8String tqshape;
{ {
GPosition tqshape_pos=args.tqcontains("tqshape"); GPosition tqshape_pos=args.contains("tqshape");
if(tqshape_pos) if(tqshape_pos)
{ {
tqshape=args[tqshape_pos]; tqshape=args[tqshape_pos];
@ -494,23 +494,23 @@ lt_XMLParser::Impl::ChangeAnno(
if(a) if(a)
{ {
GPosition pos; GPosition pos;
if((pos=args.tqcontains("href"))) if((pos=args.contains("href")))
{ {
a->url=args[pos]; a->url=args[pos];
} }
if((pos=args.tqcontains("target"))) if((pos=args.contains("target")))
{ {
a->target=args[pos]; a->target=args[pos];
} }
if((pos=args.tqcontains("alt"))) if((pos=args.contains("alt")))
{ {
a->comment=args[pos]; a->comment=args[pos];
} }
if((pos=args.tqcontains("bordertype"))) if((pos=args.contains("bordertype")))
{ {
GUTF8String b=args[pos]; GUTF8String b=args[pos];
static const GMap<GUTF8String,GMapArea::BorderType> typeMap=BorderTypeMap(); static const GMap<GUTF8String,GMapArea::BorderType> typeMap=BorderTypeMap();
if((pos=typeMap.tqcontains(b))) if((pos=typeMap.contains(b)))
{ {
a->border_type=typeMap[pos]; a->border_type=typeMap[pos];
}else }else
@ -518,16 +518,16 @@ lt_XMLParser::Impl::ChangeAnno(
G_THROW( (ERR_MSG("XMLAnno.unknown_border") "\t")+b ); G_THROW( (ERR_MSG("XMLAnno.unknown_border") "\t")+b );
} }
} }
a->border_always_visible=!!args.tqcontains("visible"); a->border_always_visible=!!args.contains("visible");
if((pos=args.tqcontains("bordercolor"))) if((pos=args.contains("bordercolor")))
{ {
a->border_color=convertToColor(args[pos]); a->border_color=convertToColor(args[pos]);
} }
if((pos=args.tqcontains("highlight"))) if((pos=args.contains("highlight")))
{ {
a->hilite_color=convertToColor(args[pos]); a->hilite_color=convertToColor(args[pos]);
} }
if((pos=args.tqcontains("border"))) if((pos=args.contains("border")))
{ {
a->border_width=args[pos].toInt(); //atoi(args[pos]); a->border_width=args[pos].toInt(); //atoi(args[pos]);
} }
@ -548,7 +548,7 @@ lt_XMLParser::Impl::get_file(const GURL &url,GUTF8String id)
GP<DjVuDocument> doc; GP<DjVuDocument> doc;
GCriticalSectionLock lock(&xmlparser_lock); GCriticalSectionLock lock(&xmlparser_lock);
{ {
GPosition pos=m_docs.tqcontains(url.get_string()); GPosition pos=m_docs.contains(url.get_string());
if(pos) if(pos)
{ {
doc=m_docs[pos]; doc=m_docs[pos];
@ -572,10 +572,10 @@ lt_XMLParser::Impl::get_file(const GURL &url,GUTF8String id)
} }
} }
const GURL fileurl(doc->id_to_url(id)); const GURL fileurl(doc->id_to_url(id));
GPosition dpos(m_files.tqcontains(fileurl.get_string())); GPosition dpos(m_files.contains(fileurl.get_string()));
if(!dpos) if(!dpos)
{ {
if(!doc->get_id_list().tqcontains(id)) if(!doc->get_id_list().contains(id))
{ {
G_THROW( ERR_MSG("XMLAnno.bad_page") ); G_THROW( ERR_MSG("XMLAnno.bad_page") );
} }
@ -622,7 +622,7 @@ lt_XMLParser::Impl::parse(const lt_XMLTags &tags)
GURL codebase; GURL codebase;
{ {
DEBUG_MSG("Setting up codebase... m_codebase = " << m_codebase << "\n"); DEBUG_MSG("Setting up codebase... m_codebase = " << m_codebase << "\n");
GPosition codebasePos=args.tqcontains("codebase"); GPosition codebasePos=args.contains("codebase");
// If user specified a codebase attribute, assume it is correct (absolute URL): // If user specified a codebase attribute, assume it is correct (absolute URL):
// the GURL constructor will throw an exception if it isn't // the GURL constructor will throw an exception if it isn't
if(codebasePos) if(codebasePos)
@ -642,11 +642,11 @@ lt_XMLParser::Impl::parse(const lt_XMLTags &tags)
// URL (for now, just a path and file name). If it's absolute, // URL (for now, just a path and file name). If it's absolute,
// our GURL will adequately wrap it. If it's relative, we need // our GURL will adequately wrap it. If it's relative, we need
// to use the codebase attribute to form an absolute URL first. // to use the codebase attribute to form an absolute URL first.
GPosition datapos=args.tqcontains("data"); GPosition datapos=args.contains("data");
if(datapos) if(datapos)
{ {
bool isDjVuType=false; bool isDjVuType=false;
GPosition typePos(args.tqcontains("type")); GPosition typePos(args.contains("type"));
if(typePos) if(typePos)
{ {
if(args[typePos] != mimetype) if(args[typePos] != mimetype)
@ -659,12 +659,12 @@ lt_XMLParser::Impl::parse(const lt_XMLTags &tags)
const GURL url=GURL::UTF8(args[datapos],(args[datapos][0] == '/')?codebase.base():codebase); const GURL url=GURL::UTF8(args[datapos],(args[datapos][0] == '/')?codebase.base():codebase);
int width; int width;
{ {
GPosition widthPos=args.tqcontains("width"); GPosition widthPos=args.contains("width");
width=(widthPos)?args[widthPos].toInt():0; width=(widthPos)?args[widthPos].toInt():0;
} }
int height; int height;
{ {
GPosition heightPos=args.tqcontains("height"); GPosition heightPos=args.contains("height");
height=(heightPos)?args[heightPos].toInt():0; height=(heightPos)?args[heightPos].toInt():0;
} }
GUTF8String gamma; GUTF8String gamma;
@ -672,17 +672,17 @@ lt_XMLParser::Impl::parse(const lt_XMLTags &tags)
GUTF8String page; GUTF8String page;
GUTF8String do_ocr; GUTF8String do_ocr;
{ {
GPosition paramPos(GObject.tqcontains(paramtag)); GPosition paramPos(GObject.contains(paramtag));
if(paramPos) if(paramPos)
{ {
const GPList<lt_XMLTags> Params(GObject[paramPos]); const GPList<lt_XMLTags> Params(GObject[paramPos]);
for(GPosition loc=Params;loc;++loc) for(GPosition loc=Params;loc;++loc)
{ {
const GMap<GUTF8String,GUTF8String> &pargs=Params[loc]->get_args(); const GMap<GUTF8String,GUTF8String> &pargs=Params[loc]->get_args();
GPosition namepos=pargs.tqcontains("name"); GPosition namepos=pargs.contains("name");
if(namepos) if(namepos)
{ {
GPosition valuepos=pargs.tqcontains("value"); GPosition valuepos=pargs.contains("value");
if(valuepos) if(valuepos)
{ {
const GUTF8String name=pargs[namepos].downcase(); const GUTF8String name=pargs[namepos].downcase();
@ -691,19 +691,19 @@ lt_XMLParser::Impl::parse(const lt_XMLTags &tags)
{ {
GMap<GUTF8String,GUTF8String> args; GMap<GUTF8String,GUTF8String> args;
lt_XMLTags::ParseValues(value,args,true); lt_XMLTags::ParseValues(value,args,true);
if(args.tqcontains("page")) if(args.contains("page"))
{ {
page=args["page"]; page=args["page"];
} }
if(args.tqcontains("dpi")) if(args.contains("dpi"))
{ {
dpi=args["dpi"]; dpi=args["dpi"];
} }
if(args.tqcontains("gamma")) if(args.contains("gamma"))
{ {
gamma=args["gamma"]; gamma=args["gamma"];
} }
if(args.tqcontains("ocr")) if(args.contains("ocr"))
{ {
do_ocr=args["ocr"]; do_ocr=args["ocr"];
} }
@ -749,14 +749,14 @@ lt_XMLParser::Impl::parse_anno(
{ {
GP<lt_XMLTags> map; GP<lt_XMLTags> map;
{ {
GPosition usemappos=GObject.get_args().tqcontains("usemap"); GPosition usemappos=GObject.get_args().contains("usemap");
if(usemappos) if(usemappos)
{ {
const GUTF8String mapname(GObject.get_args()[usemappos]); const GUTF8String mapname(GObject.get_args()[usemappos]);
GPosition mappos=Maps.tqcontains(mapname); GPosition mappos=Maps.contains(mapname);
if(!mappos) if(!mappos)
{ {
G_THROW((ERR_MSG("XMLAnno.map_tqfind") "\t")+mapname ); G_THROW((ERR_MSG("XMLAnno.map_find") "\t")+mapname );
}else }else
{ {
map=Maps[mappos]; map=Maps[mappos];
@ -838,7 +838,7 @@ make_child_layer(
default_rect.ymin=max(tqparent.rect.ymax,tqparent.rect.ymin); default_rect.ymin=max(tqparent.rect.ymax,tqparent.rect.ymin);
default_rect.ymax=min(tqparent.rect.ymax,tqparent.rect.ymin); default_rect.ymax=min(tqparent.rect.ymax,tqparent.rect.ymin);
// Now if there are coordinates, use those. // Now if there are coordinates, use those.
GPosition pos(tag.get_args().tqcontains("coords")); GPosition pos(tag.get_args().contains("coords"));
if(pos) if(pos)
{ {
GList<int> rectArgs; GList<int> rectArgs;
@ -1062,7 +1062,7 @@ lt_XMLParser::Impl::parse_text(
const lt_XMLTags &GObject, const lt_XMLTags &GObject,
DjVuFile &dfile ) DjVuFile &dfile )
{ {
GPosition textPos = GObject.tqcontains(hiddentexttag); GPosition textPos = GObject.contains(hiddentexttag);
if(textPos) if(textPos)
{ {
// loop through the hidden text - there should only be one // loop through the hidden text - there should only be one
@ -1078,7 +1078,7 @@ lt_XMLParser::Impl::parse_meta(
const lt_XMLTags &GObject, const lt_XMLTags &GObject,
DjVuFile &dfile ) DjVuFile &dfile )
{ {
GPosition metaPos = GObject.tqcontains(metadatatag); GPosition metaPos = GObject.contains(metadatatag);
if(metaPos) if(metaPos)
{ {
// loop through the hidden text - there should only be one // loop through the hidden text - there should only be one

@ -321,7 +321,7 @@ lt_XMLTags::init(XMLByteStream &xmlbs)
GPList<lt_XMLTags> GPList<lt_XMLTags>
lt_XMLTags::get_Tags(char const tagname[]) const lt_XMLTags::get_Tags(char const tagname[]) const
{ {
GPosition pos=allTags.tqcontains(tagname); GPosition pos=allTags.contains(tagname);
GPList<lt_XMLTags> retval; GPList<lt_XMLTags> retval;
return (pos?allTags[pos]:retval); return (pos?allTags[pos]:retval);
} }
@ -338,7 +338,7 @@ lt_XMLTags::get_Maps(char const tagname[],
if(tag) if(tag)
{ {
GPosition loc; GPosition loc;
if((loc=tag->tqcontains(tagname))) if((loc=tag->contains(tagname)))
{ {
GPList<lt_XMLTags> maps=(GPList<lt_XMLTags> &)((*tag)[loc]); GPList<lt_XMLTags> maps=(GPList<lt_XMLTags> &)((*tag)[loc]);
for(GPosition mloc=maps;mloc;++mloc) for(GPosition mloc=maps;mloc;++mloc)
@ -348,7 +348,7 @@ lt_XMLTags::get_Maps(char const tagname[],
{ {
GMap<GUTF8String,GUTF8String> &args=gtag->args; GMap<GUTF8String,GUTF8String> &args=gtag->args;
GPosition gpos; GPosition gpos;
if((gpos=args.tqcontains(argn))) if((gpos=args.contains(argn)))
{ {
map[args[gpos]]=gtag; map[args[gpos]]=gtag;
} }

@ -121,7 +121,7 @@ public:
inline void addtag(GP<lt_XMLTags> x); inline void addtag(GP<lt_XMLTags> x);
inline void addraw(GUTF8String raw); inline void addraw(GUTF8String raw);
inline GPosition tqcontains(GUTF8String name) const; inline GPosition contains(GUTF8String name) const;
inline const GPList<lt_XMLTags> & operator [] (const GUTF8String name) const; inline const GPList<lt_XMLTags> & operator [] (const GUTF8String name) const;
inline const GPList<lt_XMLTags> & operator [] (const GPosition &pos) const; inline const GPList<lt_XMLTags> & operator [] (const GPosition &pos) const;
static void ParseValues(char const *t, GMap<GUTF8String,GUTF8String> &args,bool downcase=true); static void ParseValues(char const *t, GMap<GUTF8String,GUTF8String> &args,bool downcase=true);
@ -213,9 +213,9 @@ inline const GMap<GUTF8String,GPList<lt_XMLTags> > &
lt_XMLTags::get_allTags(void) const { return allTags; } lt_XMLTags::get_allTags(void) const { return allTags; }
inline GPosition inline GPosition
lt_XMLTags::tqcontains(GUTF8String name) const lt_XMLTags::contains(GUTF8String name) const
{ {
return allTags.tqcontains(name); return allTags.contains(name);
} }
inline const GPList<lt_XMLTags> & inline const GPList<lt_XMLTags> &

@ -615,7 +615,7 @@ ZPCodec::IWencoder(const bool bit)
numbers are much more probable than large numbers. We will first group numbers are much more probable than large numbers. We will first group
our numbers into several sets. Each number is coded by first coding which our numbers into several sets. Each number is coded by first coding which
set contains the number and then coding a position within the set. Each set contains the number and then coding a position within the set. Each
set tqcontains #2^n# numbers that we consider roughly equiprobable. Since set contains #2^n# numbers that we consider roughly equiprobable. Since
the most probable values occur much more often, we want to model their the most probable values occur much more often, we want to model their
probability more precisely. Therefore we use small sets for the most probability more precisely. Therefore we use small sets for the most
probable values and large sets for the least probable values, as probable values and large sets for the least probable values, as

@ -194,7 +194,7 @@ TextSelection RenderedDocumentPage::select(const TQPoint& point)
for (unsigned int i=0; i<textBoxList.size(); i++) for (unsigned int i=0; i<textBoxList.size(); i++)
{ {
if (textBoxList[i].box.tqcontains(point)) if (textBoxList[i].box.contains(point))
{ {
selectedTextStart = i; selectedTextStart = i;
selectedTextEnd = i; selectedTextEnd = i;
@ -216,7 +216,7 @@ TextSelection RenderedDocumentPage::select(const TQPoint& point)
return selection; return selection;
} }
TextSelection RenderedDocumentPage::tqfind(const TQString& str, int index, bool caseSensitive) TextSelection RenderedDocumentPage::find(const TQString& str, int index, bool caseSensitive)
{ {
if (pageText.isNull()) if (pageText.isNull())
{ {
@ -241,7 +241,7 @@ TextSelection RenderedDocumentPage::tqfind(const TQString& str, int index, bool
subIndex += textBoxList[i].text.length(); subIndex += textBoxList[i].text.length();
} }
int textIndex = pageText.tqfind(str, subIndex, caseSensitive); int textIndex = pageText.find(str, subIndex, caseSensitive);
if (textIndex == -1) if (textIndex == -1)
return selection; return selection;
@ -291,7 +291,7 @@ TextSelection RenderedDocumentPage::tqfind(const TQString& str, int index, bool
} }
TextSelection RenderedDocumentPage::tqfindRev(const TQString& str, int index, bool caseSensitive) TextSelection RenderedDocumentPage::findRev(const TQString& str, int index, bool caseSensitive)
{ {
// Negative index means we start the search at the end of the text. // Negative index means we start the search at the end of the text.
if (index < 0) if (index < 0)
@ -322,7 +322,7 @@ TextSelection RenderedDocumentPage::tqfindRev(const TQString& str, int index, bo
subIndex += textBoxList[i].text.length(); subIndex += textBoxList[i].text.length();
} }
int textIndex = pageText.tqfindRev(str, subIndex, caseSensitive); int textIndex = pageText.findRev(str, subIndex, caseSensitive);
if (textIndex == -1) if (textIndex == -1)
return selection; return selection;

@ -197,13 +197,13 @@ class RenderedDocumentPage : public TQObject
/** Finds the first occurence of str starting by the current index. /** Finds the first occurence of str starting by the current index.
If the text is found a corresponding TextSelection is returned. If the text is found a corresponding TextSelection is returned.
If the text is not found a empty selection is returned. */ If the text is not found a empty selection is returned. */
TextSelection tqfind(const TQString& str, int index = 0, bool caseSensitive = true); TextSelection find(const TQString& str, int index = 0, bool caseSensitive = true);
/** Finds the first occurence of str starting by the current index searching backwards. /** Finds the first occurence of str starting by the current index searching backwards.
If the text is found a corresponding TextSelection is returned. If the text is found a corresponding TextSelection is returned.
If the text is not found a empty selection is returned. If the text is not found a empty selection is returned.
If index < 0 start the search at the end of the page. */ If index < 0 start the search at the end of the page. */
TextSelection tqfindRev(const TQString& str, int index = 0, bool cs = true); TextSelection findRev(const TQString& str, int index = 0, bool cs = true);
/** \brief Hyperlinks on the document page /** \brief Hyperlinks on the document page

@ -64,7 +64,7 @@ float distance::convertToMM(const TQString &distance, bool *ok)
// of the unit in 'unitPos', so that distance[0..unitPos] will hold // of the unit in 'unitPos', so that distance[0..unitPos] will hold
// the value. Store the number of mm per unit in 'MMperUnit'. // the value. Store the number of mm per unit in 'MMperUnit'.
for(int i=0; MMperUnit==0.0 && distanceUnitTable[i].name != 0; i++) { for(int i=0; MMperUnit==0.0 && distanceUnitTable[i].name != 0; i++) {
unitPos = distance.tqfindRev(distanceUnitTable[i].name); unitPos = distance.findRev(distanceUnitTable[i].name);
if (unitPos != -1) if (unitPos != -1)
MMperUnit = distanceUnitTable[i].mmPerUnit; MMperUnit = distanceUnitTable[i].mmPerUnit;
} }

@ -128,7 +128,7 @@ included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for "Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means making modifications to it. For a library, complete source code means
all the source code for all modules it tqcontains, plus any associated all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control compilation interface definition files, plus the scripts used to control compilation
and installation of the library. and installation of the library.

@ -95,7 +95,7 @@ TQCString DeviceSelector::getDeviceFromConfig( void ) const
/* Now check if the scanner read from the config file is available ! /* Now check if the scanner read from the config file is available !
* if not, ask the user ! * if not, ask the user !
*/ */
if( skipDialog && devices.tqfind( result ) > -1 ) if( skipDialog && devices.find( result ) > -1 )
{ {
kdDebug(29000) << "Scanner from Config file is available - fine." << endl; kdDebug(29000) << "Scanner from Config file is available - fine." << endl;
} }
@ -168,7 +168,7 @@ void DeviceSelector::setScanSources( const TQStrList& sources,
if( ! default_ok ) if( ! default_ok )
{ {
/* if no default found, set the first */ /* if no default found, set the first */
TQRadioButton *rb = (TQRadioButton*) selectBox->tqfind( checkDefNo ); TQRadioButton *rb = (TQRadioButton*) selectBox->find( checkDefNo );
if ( rb ) if ( rb )
rb->setChecked( true ); rb->setChecked( true );
} }

@ -783,7 +783,7 @@ void ImageCanvas::drawHAreaBorder(TQPainter &p,int x1,int x2,int y,int r)
} else if(!acquired) p.setPen(TQPen(TQColor(150,150,150))); } else if(!acquired) p.setPen(TQPen(TQColor(150,150,150)));
for(;;) { for(;;) {
if(TQT_TQRECT_OBJECT(rect()).tqcontains(TQPoint(x1,y))) { if(TQT_TQRECT_OBJECT(rect()).contains(TQPoint(x1,y))) {
if( r && acquired ) { if( r && acquired ) {
int re_x1, re_y; int re_x1, re_y;
inv_scale_matrix.map( x1+cx, y+cy, &re_x1, &re_y ); inv_scale_matrix.map( x1+cx, y+cy, &re_x1, &re_y );
@ -826,7 +826,7 @@ void ImageCanvas::drawVAreaBorder(TQPainter &p, int x, int y1, int y2, int r )
if( !acquired ) p.setPen( TQPen( TQColor(150,150,150) ) ); if( !acquired ) p.setPen( TQPen( TQColor(150,150,150) ) );
for(;;) { for(;;) {
if(TQT_TQRECT_OBJECT(rect()).tqcontains( TQPoint(x,y1) )) { if(TQT_TQRECT_OBJECT(rect()).contains( TQPoint(x,y1) )) {
if( r && acquired ) { if( r && acquired ) {
int re_y1, re_x; int re_y1, re_x;
inv_scale_matrix.map( x+cx, y1+cy, &re_x, &re_y1 ); inv_scale_matrix.map( x+cx, y1+cy, &re_x, &re_y1 );
@ -921,7 +921,7 @@ preview_state ImageCanvas::classifyPoint(int x,int y)
if(x>=a.left()&&x<=a.right()) { if(x>=a.left()&&x<=a.right()) {
if(top) return MOVE_TOP; if(top) return MOVE_TOP;
if(bottom) return MOVE_BOTTOM; if(bottom) return MOVE_BOTTOM;
if(selected->tqcontains(TQPoint(x,y))) return MOVE_WHOLE; if(selected->contains(TQPoint(x,y))) return MOVE_WHOLE;
} }
return MOVE_NONE; return MOVE_NONE;
} }
@ -1058,7 +1058,7 @@ int ImageCanvas::highlight( const TQRect& rect, const TQPen& pen, const TQBrush&
saveRect.setRect( rect.x()-2, rect.y()-2, rect.width()+4, rect.height()+4 ); saveRect.setRect( rect.x()-2, rect.y()-2, rect.width()+4, rect.height()+4 );
d->highlightRects.append( saveRect ); d->highlightRects.append( saveRect );
int idx = d->highlightRects.tqfindIndex(saveRect); int idx = d->highlightRects.findIndex(saveRect);
TQRect targetRect = scale_matrix.map( rect ); TQRect targetRect = scale_matrix.map( rect );

@ -240,7 +240,7 @@ KScanStat KScanDevice::openDevice( const TQCString& backend )
if( backend.isEmpty() ) return KSCAN_ERR_PARAM; if( backend.isEmpty() ) return KSCAN_ERR_PARAM;
// search for scanner // search for scanner
int indx = scanner_avail.tqfind( backend ); int indx = scanner_avail.find( backend );
if( indx < 0 ) { if( indx < 0 ) {
stat = KSCAN_ERR_NO_DEVICE; stat = KSCAN_ERR_NO_DEVICE;
@ -570,7 +570,7 @@ void KScanDevice::slSetDirty( const TQCString& name )
{ {
if( optionExists( name ) ) if( optionExists( name ) )
{ {
if( dirtyList.tqfind( name ) == -1 ) if( dirtyList.find( name ) == -1 )
{ {
kdDebug(29000)<< "Setting dirty <" << name << ">" << endl; kdDebug(29000)<< "Setting dirty <" << name << ">" << endl;
/* item not found */ /* item not found */
@ -675,7 +675,7 @@ const TQString KScanDevice::previewFile()
TQString fname = dir + TQString::tqfromLatin1(".previews/"); TQString fname = dir + TQString::tqfromLatin1(".previews/");
TQString sname( getScannerName(shortScannerName()) ); TQString sname( getScannerName(shortScannerName()) );
sname.tqreplace( '/', "_"); sname.replace( '/', "_");
return fname+sname; return fname+sname;
} }

@ -732,7 +732,7 @@ bool KScanOption::set( const TQCString& c_string )
TQRegExp re( "\\d+, \\d+, \\d+" ); TQRegExp re( "\\d+, \\d+, \\d+" );
re.setMinimal(true); re.setMinimal(true);
if( TQString(c_string).tqcontains( re )) if( TQString(c_string).contains( re ))
{ {
TQStringList relist = TQStringList::split( ", ", TQString(c_string) ); TQStringList relist = TQStringList::split( ", ", TQString(c_string) );

@ -86,7 +86,7 @@ bool KScanOptSet::backupOption( const KScanOption& opt )
if( retval ) if( retval )
{ {
KScanOption *newopt = tqfind( optName ); KScanOption *newopt = find( optName );
if( newopt ) if( newopt )
{ {

@ -260,7 +260,7 @@ void KScanCombo::createCombo( const TQString& text )
void KScanCombo::slSetEntry( const TQString &t ) void KScanCombo::slSetEntry( const TQString &t )
{ {
if( t.isNull() ) return; if( t.isNull() ) return;
int i = combolist.tqfind( t.local8Bit() ); int i = combolist.find( t.local8Bit() );
/* Important to check value to avoid recursive signals ;) */ /* Important to check value to avoid recursive signals ;) */
if( i == combo->currentItem() ) if( i == combo->currentItem() )

@ -547,7 +547,7 @@ void ScanParams::slSourceSelect( void )
sources = so.getList(); sources = so.getList();
#undef CHEAT_FOR_DEBUGGING #undef CHEAT_FOR_DEBUGGING
#ifdef CHEAT_FOR_DEBUGGING #ifdef CHEAT_FOR_DEBUGGING
if( sources.tqfind( "Automatic Document Feeder" ) == -1) if( sources.find( "Automatic Document Feeder" ) == -1)
sources.append( "Automatic Document Feeder" ); sources.append( "Automatic Document Feeder" );
#endif #endif

Loading…
Cancel
Save