rename the following methods:

tqfind find
tqreplace replace
tqcontains contains


git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
v3.5.13-sru
tpearson 14 years ago
parent ef39e8e417
commit b6edfe41c9

@ -232,7 +232,7 @@ bool KisAbstractColorSpace::convertPixelsTo(const TQ_UINT8 * src,
if (!tf && m_profile && dstColorSpace->getProfile()) {
if (!m_transforms.tqcontains(dstColorSpace)) {
if (!m_transforms.contains(dstColorSpace)) {
tf = createTransform(dstColorSpace,
m_profile,
dstColorSpace->getProfile(),

@ -100,7 +100,7 @@ KisColorSpaceFactoryRegistry::~KisColorSpaceFactoryRegistry()
KisProfile * KisColorSpaceFactoryRegistry::getProfileByName(const TQString & name)
{
if (m_profileMap.tqfind(name) == m_profileMap.end()) {
if (m_profileMap.find(name) == m_profileMap.end()) {
return 0;
}
@ -160,7 +160,7 @@ KisColorSpace * KisColorSpaceFactoryRegistry::getColorSpace(const KisID & csID,
TQString name = csID.id() + "<comb>" + profileName;
if (m_csMap.tqfind(name) == m_csMap.end()) {
if (m_csMap.find(name) == m_csMap.end()) {
KisColorSpaceFactory *csf = get(csID);
if(!csf)
return 0;
@ -175,7 +175,7 @@ KisColorSpace * KisColorSpaceFactoryRegistry::getColorSpace(const KisID & csID,
m_csMap[name] = cs;
}
if(m_csMap.tqcontains(name))
if(m_csMap.contains(name))
return m_csMap[name];
else
return 0;

@ -27,7 +27,7 @@ class TQStringList;
class KisPaintDeviceAction;
/**
* This class tqcontains:
* This class contains:
* - a registry of colorspace instantiated with specific profiles.
* - a registry of singleton colorspace factories.
* - a registry of icc profiles

@ -190,7 +190,7 @@ void KisWetColorSpace::fromTQColor(const TQColor& c, TQ_UINT8 *dst, KisProfile *
}
// Translate the special TQCOlors from our paintbox to wetpaint paints.
if (m_conversionMap.tqcontains(key)) {
if (m_conversionMap.contains(key)) {
(*p).paint = m_conversionMap[key];
(*p).adsorb = m_conversionMap[key]; // or maybe best add water here?
} else {

@ -59,7 +59,7 @@ modification follow.
GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which tqcontains
0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program"
@ -154,7 +154,7 @@ Sections 1 and 2 above provided that you also do one of the following:
The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source
code means all the source code for all modules it tqcontains, plus any
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include

@ -84,10 +84,10 @@ dcopiface_template = """/*
def parseHeader(headerfile, classname):
# parse the source class header to get a list of functions we're going to wrap
functions = []
if (headerfile.tqfind("private:") > -1):
lines = headerfile[headerfile.tqfind(classname):headerfile.tqfind("private")].splitlines()
if (headerfile.find("private:") > -1):
lines = headerfile[headerfile.find(classname):headerfile.find("private")].splitlines()
else:
lines = headerfile[headerfile.tqfind(classname):headerfile.tqfind("#endif")].splitlines()
lines = headerfile[headerfile.find(classname):headerfile.find("#endif")].splitlines()
i = 0
while i < len(lines):
line = lines[i].strip()
@ -100,7 +100,7 @@ def parseHeader(headerfile, classname):
line.startswith("#") or
line.startswith("}") or
line.startswith("public Q_SLOTS:") or
line.tqfind("~") != -1 or
line.find("~") != -1 or
len(line) == 0
):
i+=1
@ -112,17 +112,17 @@ def parseHeader(headerfile, classname):
function = line
complete = 0
# strip the inline implementation
if (line.tqfind("{") > -1):
function = line[:line.tqfind("{")]
if function.tqfind("}") > -1:
function += line[line.tqfind("}") + 1:]
if (line.find("{") > -1):
function = line[:line.find("{")]
if function.find("}") > -1:
function += line[line.find("}") + 1:]
complete = 1
else:
i += 1
# search for the missing } on the next lines
while i < len(lines):
if (lines[i].tqfind("}") > -1):
function += lines[i][lines[i].tqfind("}") + 1:]
if (lines[i].find("}") > -1):
function += lines[i][lines[i].find("}") + 1:]
complete = 1
i += 1
else:

@ -36,7 +36,7 @@ class KisExifInfo
bool getValue(TQString name, ExifValue& value)
{
if ( m_values.tqfind( name ) == m_values.end() ) {
if ( m_values.find( name ) == m_values.end() ) {
return false;
}
else {

@ -109,7 +109,7 @@ TQ_INT32 KisFilterConfiguration::version() const
void KisFilterConfiguration::setProperty(const TQString & name, const TQVariant & value)
{
if ( m_properties.tqfind( name ) == m_properties.end() ) {
if ( m_properties.find( name ) == m_properties.end() ) {
m_properties.insert( name, value );
}
else {
@ -119,7 +119,7 @@ void KisFilterConfiguration::setProperty(const TQString & name, const TQVariant
bool KisFilterConfiguration::getProperty(const TQString & name, TQVariant & value)
{
if ( m_properties.tqfind( name ) == m_properties.end() ) {
if ( m_properties.find( name ) == m_properties.end() ) {
return false;
}
else {
@ -130,7 +130,7 @@ bool KisFilterConfiguration::getProperty(const TQString & name, TQVariant & valu
TQVariant KisFilterConfiguration::getProperty(const TQString & name)
{
if ( m_properties.tqfind( name ) == m_properties.end() ) {
if ( m_properties.find( name ) == m_properties.end() ) {
return TQVariant();
}
else {

@ -163,7 +163,7 @@ void KisGroupLayer::setIndex(KisLayerSP layer, int index)
bool KisGroupLayer::addLayer(KisLayerSP newLayer, int x)
{
if (x < 0 || kClamp(uint(x), uint(0), childCount()) != uint(x) ||
newLayer->tqparent() || m_layers.tqcontains(newLayer))
newLayer->tqparent() || m_layers.contains(newLayer))
{
kdWarning() << "invalid input to KisGroupLayer::addLayer(KisLayerSP newLayer, int x)!" << endl;
return false;

@ -228,8 +228,8 @@ bool KisImagePipeBrush::init()
}
TQString paramline = TQString::fromUtf8((&line2[0]), line2.size());
TQ_UINT32 m_numOfBrushes = paramline.left(paramline.tqfind(' ')).toUInt();
m_parasite = paramline.mid(paramline.tqfind(' ') + 1);
TQ_UINT32 m_numOfBrushes = paramline.left(paramline.find(' ')).toUInt();
m_parasite = paramline.mid(paramline.find(' ') + 1);
i++; // Skip past the second newline
TQ_UINT32 numOfBrushes = 0;

@ -311,7 +311,7 @@ void KisLayer::setClean(const TQRect & rect)
// XXX: We should only set the parts clean that were actually cleaned. However, extent and exactBounds conspire
// to make that very hard atm.
//if (rect.tqcontains(m_dirtyRect)) m_dirtyRect = TQRect();
//if (rect.contains(m_dirtyRect)) m_dirtyRect = TQRect();
m_dirtyRect = TQRect();
}

@ -137,12 +137,12 @@ public:
/**
* Returns true of x,y is within the extent of this paint device
*/
bool tqcontains(TQ_INT32 x, TQ_INT32 y) const;
bool contains(TQ_INT32 x, TQ_INT32 y) const;
/**
* Convenience method for the above
*/
bool tqcontains(const TQPoint& pt) const;
bool contains(const TQPoint& pt) const;
/**
* Retrieve the bounds of the paint device. The size is not exact,

@ -238,7 +238,7 @@ bool KisPalette::init()
}
else if (!lines[i].isEmpty())
{
TQStringList a = TQStringList::split(" ", lines[i].tqreplace(TQChar('\t'), " "));
TQStringList a = TQStringList::split(" ", lines[i].replace(TQChar('\t'), " "));
if (a.count() < 3)
{

@ -277,7 +277,7 @@ bool KisPattern::init()
KisPaintDeviceSP KisPattern::image(KisColorSpace * colorSpace) {
// Check if there's already a pattern prepared for this colorspace
TQMap<TQString, KisPaintDeviceSP>::const_iterator it = m_colorspaces.tqfind(colorSpace->id().id());
TQMap<TQString, KisPaintDeviceSP>::const_iterator it = m_colorspaces.find(colorSpace->id().id());
if (it != m_colorspaces.end())
return (*it);

@ -27,7 +27,7 @@ KisSubPerspectiveGrid::KisSubPerspectiveGrid(KisPerspectiveGridNodeSP topLeft, K
}
bool KisSubPerspectiveGrid::tqcontains(const KisPoint p) const
bool KisSubPerspectiveGrid::contains(const KisPoint p) const
{
return true;
KisPerspectiveMath::LineEquation d1 = KisPerspectiveMath::computeLineEquation( topLeft(), topRight() );
@ -90,7 +90,7 @@ KisSubPerspectiveGrid* KisPerspectiveGrid::gridAt(KisPoint p)
{
for( TQValueList<KisSubPerspectiveGrid*>::const_iterator it = begin(); it != end(); ++it)
{
if( (*it)->tqcontains(p) )
if( (*it)->contains(p) )
{
return *it;
}

@ -67,7 +67,7 @@ class KisSubPerspectiveGrid {
/**
* @return true if the point p is contain by the grid
*/
bool tqcontains(const KisPoint p) const;
bool contains(const KisPoint p) const;
private:
inline KisPoint computeVanishingPoint(KisPerspectiveGridNodeSP p11, KisPerspectiveGridNodeSP p12, KisPerspectiveGridNodeSP p21, KisPerspectiveGridNodeSP p22)
{

@ -204,9 +204,9 @@ void KisSelection::startCachingExactRect()
void KisSelection::paintUniformSelectionRegion(TQImage img, const TQRect& imageRect, const TQRegion& uniformRegion)
{
Q_ASSERT(img.size() == imageRect.size());
Q_ASSERT(imageRect.tqcontains(uniformRegion.boundingRect()));
Q_ASSERT(imageRect.contains(uniformRegion.boundingRect()));
if (img.isNull() || img.size() != imageRect.size() || !imageRect.tqcontains(uniformRegion.boundingRect())) {
if (img.isNull() || img.size() != imageRect.size() || !imageRect.contains(uniformRegion.boundingRect())) {
return;
}

@ -115,18 +115,18 @@ void KisThreadPool::dequeue(KisThread * thread)
m_poolMutex.lock();
int i = m_threads.tqfindRef(thread);
int i = m_threads.findRef(thread);
if (i >= 0) {
t = m_threads.take(i);
m_numberOfQueuedThreads--;
} else {
i = m_runningThreads.tqfindRef(thread);
i = m_runningThreads.findRef(thread);
if (i >= 0) {
t = m_runningThreads.take(i);
m_numberOfRunningThreads--;
}
else {
i = m_oldThreads.tqfindRef(thread);
i = m_oldThreads.findRef(thread);
if (i >= 0) {
t = m_oldThreads.take(i);
}

@ -25,7 +25,7 @@ class KisTiledDataManager;
class KisTiledIterator;
/**
* Provides abstraction to a tile. A tile tqcontains
* Provides abstraction to a tile. A tile contains
* a part of a PaintDevice, but only the individual pixels
* are accesable and that only via iterators.
*/

@ -245,7 +245,7 @@ void KisTiledDataManager::setExtent(TQ_INT32 x, TQ_INT32 y, TQ_INT32 w, TQ_INT32
//printRect("oldRect", oldRect);
// Do nothing if the desired size is bigger than we currently are: that is handled by the autoextending automatically
if (newRect.tqcontains(oldRect)) return;
if (newRect.contains(oldRect)) return;
// Loop through all tiles, if a tile is wholly outside the extent, add to the memento, then delete it,
// if the tile is partially outside the extent, clear the outside pixels to the default pixel.
@ -259,7 +259,7 @@ void KisTiledDataManager::setExtent(TQ_INT32 x, TQ_INT32 y, TQ_INT32 w, TQ_INT32
TQRect tileRect = TQRect(tile->getCol() * KisTile::WIDTH, tile->getRow() * KisTile::HEIGHT, KisTile::WIDTH, KisTile::HEIGHT);
//printRect("tileRect", tileRect);
if (newRect.tqcontains(tileRect)) {
if (newRect.contains(tileRect)) {
// Completely inside, do nothing
previousTile = tile;
tile = tile->getNext();
@ -279,7 +279,7 @@ void KisTiledDataManager::setExtent(TQ_INT32 x, TQ_INT32 y, TQ_INT32 w, TQ_INT32
tile->addReader();
for (int y = 0; y < KisTile::HEIGHT; ++y) {
for (int x = 0; x < KisTile::WIDTH; ++x) {
if (!intersection.tqcontains(x,y)) {
if (!intersection.contains(x,y)) {
TQ_UINT8 * ptr = tile->data(x, y);
memcpy(ptr, m_defPixel, m_pixelSize);
}

@ -157,11 +157,11 @@ void KisTileManager::deregisterTile(KisTile* tile) {
m_swapMutex->lock();
if (!m_tileMap.tqcontains(tile)) {
if (!m_tileMap.contains(tile)) {
m_swapMutex->unlock();
return;
}
// Q_ASSERT(m_tileMap.tqcontains(tile));
// Q_ASSERT(m_tileMap.contains(tile));
TileInfo* info = m_tileMap[tile];

@ -6,7 +6,7 @@ sources:
* The old Chalk brush code (http://webcvs.kde.org/cgi-bin/cvsweb.cgi/koffice/chalk/tools/kis_tool_brush.cc?rev=1.58&content-type=text/x-cvsweb-markup)
* Peter Jodda's Perico (http://software.jodda.de/perico.html)
* The source of the Gimp (both current and 0.99.11 -- the oldest version I could tqfind) (http://www.gimp.org)
* The source of the Gimp (both current and 0.99.11 -- the oldest version I could find) (http://www.gimp.org)
* David Hodson's article on Gimp brushes (http://members.ozemail.com.au/~hodsond/gimpbrush.html)
* Raph Levien's article on Gimp brushes (http://www.levien.com/gimp/brush-arch.html)

@ -342,7 +342,7 @@ data to rbg for screen rendering." visibility="public" xmi.id="259" name="CMYK"
<UML:Operation visibility="public" xmi.id="271" type="virtual KisStrategyColorSpaceSP" name="create" >
<UML:Parameter visibility="private" xmi.id="272" value="" type="enumImgType" name="imgType" />
</UML:Operation>
<UML:Operation visibility="protected" xmi.id="273" type="KisStrategyColorSpaceSP" name="tqfind" >
<UML:Operation visibility="protected" xmi.id="273" type="KisStrategyColorSpaceSP" name="find" >
<UML:Parameter visibility="private" xmi.id="274" value="" type="enumImgType" name="imgType" />
</UML:Operation>
<UML:Operation visibility="public" xmi.id="275" type="virtual " name="~KisColorSpaceFactoryFlyweight" />
@ -650,7 +650,7 @@ of tile in x and y." visibility="public" xmi.id="408" type="void" name="tileCoor
</UML:Operation>
<UML:Operation visibility="public" xmi.id="480" type="virtual " name="~KisTileCacheInterface" />
</UML:Class>
<UML:Class stereotype="class" comment="Provides abstraction to a tile. A tile tqcontains
<UML:Class stereotype="class" comment="Provides abstraction to a tile. A tile contains
a part of a layer. Layers form an image." visibility="public" xmi.id="481" name="KisTile" >
<UML:Operation visibility="protected" xmi.id="496" type="KisTile &amp;" name="=" >
<UML:Parameter visibility="private" xmi.id="497" value="" type="const KisTile &amp;" />
@ -1059,7 +1059,7 @@ pixels in the brush." visibility="public" xmi.id="705" type="virtual KisAlphaMas
<UML:Parameter visibility="private" xmi.id="810" value="" type="Q_INT32" name="yOffset" />
<UML:Parameter visibility="private" xmi.id="811" value="" type="double" name="zoom" />
</UML:Operation>
<UML:Operation visibility="public" xmi.id="812" type="KisGuideSP" name="tqfind" >
<UML:Operation visibility="public" xmi.id="812" type="KisGuideSP" name="find" >
<UML:Parameter visibility="private" xmi.id="813" value="" type="double" name="x" />
<UML:Parameter visibility="private" xmi.id="814" value="" type="double" name="y" />
<UML:Parameter visibility="private" xmi.id="815" value="" type="double" name="d" />
@ -1208,7 +1208,7 @@ pixels in the brush." visibility="public" xmi.id="705" type="virtual KisAlphaMas
<UML:Operation visibility="public" xmi.id="929" type="virtual bool" name="completeSaving" >
<UML:Parameter visibility="private" xmi.id="930" value="" type="KoStore *" />
</UML:Operation>
<UML:Operation visibility="public" xmi.id="931" type="bool" name="tqcontains" >
<UML:Operation visibility="public" xmi.id="931" type="bool" name="contains" >
<UML:Parameter visibility="private" xmi.id="932" value="" type="KisImageSP" name="img" />
</UML:Operation>
<UML:Operation visibility="protected" xmi.id="933" type="virtual KoView *" name="createViewInstance" >
@ -1906,11 +1906,11 @@ cannot be abstract, because otherwise this class would be abstract." visibility=
<UML:Parameter visibility="private" xmi.id="1511" value="" type="const QString &amp;" name="name" />
<UML:Parameter visibility="private" xmi.id="1512" value="" type="CompositeOp" name="compositeOp" />
</UML:Operation>
<UML:Operation visibility="public" xmi.id="1513" type="bool" name="tqcontains" >
<UML:Operation visibility="public" xmi.id="1513" type="bool" name="contains" >
<UML:Parameter visibility="private" xmi.id="1514" value="" type="Q_INT32" name="x" />
<UML:Parameter visibility="private" xmi.id="1515" value="" type="Q_INT32" name="y" />
</UML:Operation>
<UML:Operation visibility="public" xmi.id="1516" type="bool" name="tqcontains" >
<UML:Operation visibility="public" xmi.id="1516" type="bool" name="contains" >
<UML:Parameter visibility="private" xmi.id="1517" value="" type="const QPoint &amp;" name="pt" />
</UML:Operation>
<UML:Operation visibility="public" xmi.id="1518" type="virtual const KisTileMgrSP" name="data" />
@ -3629,7 +3629,7 @@ in the constructor, you have to call loadAsync.
<listitem open="0" type="815" id="268" label="KisColorSpaceFactoryFlyweight" />
<listitem open="0" type="815" id="269" label="create" />
<listitem open="0" type="815" id="271" label="create" />
<listitem open="0" type="815" id="273" label="tqfind" />
<listitem open="0" type="815" id="273" label="find" />
<listitem open="0" type="815" id="275" label="~KisColorSpaceFactoryFlyweight" />
</listitem>
<listitem open="0" type="813" id="193" label="KisColorSpaceFactoryInterface" >
@ -3714,7 +3714,7 @@ in the constructor, you have to call loadAsync.
<listitem open="0" type="815" id="926" label="clipboardSelection" />
<listitem open="0" type="815" id="927" label="completeLoading" />
<listitem open="0" type="815" id="929" label="completeSaving" />
<listitem open="0" type="815" id="931" label="tqcontains" />
<listitem open="0" type="815" id="931" label="contains" />
<listitem open="0" type="815" id="933" label="createViewInstance" />
<listitem open="0" type="815" id="936" label="dcopObject" />
<listitem open="0" type="815" id="937" label="empty" />
@ -3838,7 +3838,7 @@ in the constructor, you have to call loadAsync.
<listitem open="0" type="815" id="802" label="KisGuideMgr" />
<listitem open="0" type="815" id="803" label="add" />
<listitem open="0" type="815" id="806" label="erase" />
<listitem open="0" type="815" id="812" label="tqfind" />
<listitem open="0" type="815" id="812" label="find" />
<listitem open="0" type="815" id="816" label="findHorizontal" />
<listitem open="0" type="815" id="819" label="findVertical" />
<listitem open="0" type="815" id="822" label="hasSelected" />
@ -4116,8 +4116,8 @@ in the constructor, you have to call loadAsync.
<listitem open="0" type="815" id="1504" label="colorAt" />
<listitem open="0" type="815" id="1505" label="compositeOp" />
<listitem open="0" type="815" id="1506" label="configure" />
<listitem open="0" type="815" id="1513" label="tqcontains" />
<listitem open="0" type="815" id="1516" label="tqcontains" />
<listitem open="0" type="815" id="1513" label="contains" />
<listitem open="0" type="815" id="1516" label="contains" />
<listitem open="0" type="815" id="1519" label="data" />
<listitem open="0" type="815" id="1518" label="data" />
<listitem open="0" type="815" id="1524" label="expand" />
@ -29680,7 +29680,7 @@ in the constructor, you have to call loadAsync.
</codeblockwithcomments>
<cppheaderclassdeclarationblock parent_id="481" tag="classDeclarationBlock" canDelete="false" role_id="-1" >
<header>
<cppcodecomment tag="" text="Class KisTile&amp;#010;Provides abstraction to a tile. A tile tqcontains&amp;#010;a part of a layer. Layers form an image." />
<cppcodecomment tag="" text="Class KisTile&amp;#010;Provides abstraction to a tile. A tile contains&amp;#010;a part of a layer. Layers form an image." />
</header>
<textblocks>
<hierarchicalcodeblock tag="publicBlock" canDelete="false" >

@ -933,14 +933,14 @@ below this layer, remove the specified layer." isSpecification="false" isLeaf="f
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="1469" isRoot="false" value="" type="558" isAbstract="false" name="v" />
</UML:BehavioralFeature.parameter>
</UML:Operation>
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="1470" isRoot="false" isAbstract="false" name="tqcontains" >
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="1470" isRoot="false" isAbstract="false" name="contains" >
<UML:BehavioralFeature.parameter>
<UML:Parameter kind="return" xmi.id="5372" type="558" />
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="1471" isRoot="false" value="" type="463" isAbstract="false" name="x" />
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="1472" isRoot="false" value="" type="463" isAbstract="false" name="y" />
</UML:BehavioralFeature.parameter>
</UML:Operation>
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="1473" isRoot="false" isAbstract="false" name="tqcontains" >
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="1473" isRoot="false" isAbstract="false" name="contains" >
<UML:BehavioralFeature.parameter>
<UML:Parameter kind="return" xmi.id="5373" type="558" />
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="1474" isRoot="false" value="" type="498" isAbstract="false" name="pt" />
@ -2243,7 +2243,7 @@ and the clipboard." isSpecification="false" isLeaf="false" visibility="public" x
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="700" isRoot="false" value="" type="430" isAbstract="false" name="gd" />
</UML:BehavioralFeature.parameter>
</UML:Operation>
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="701" isRoot="false" isAbstract="false" name="tqfind" >
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="701" isRoot="false" isAbstract="false" name="find" >
<UML:BehavioralFeature.parameter>
<UML:Parameter kind="return" xmi.id="5458" type="430" />
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="702" isRoot="false" value="" type="7" isAbstract="false" name="x" />

@ -1208,14 +1208,14 @@ there is no guarantee that the iterator will work scanline by scanline." isSpeci
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="1187" isRoot="false" value="" type="5" isAbstract="false" name="visible" />
</UML:BehavioralFeature.parameter>
</UML:Operation>
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="1188" isRoot="false" isAbstract="false" name="tqcontains" >
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="1188" isRoot="false" isAbstract="false" name="contains" >
<UML:BehavioralFeature.parameter>
<UML:Parameter kind="return" xmi.id="17100" type="5" />
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="1189" isRoot="false" value="" type="43" isAbstract="false" name="x" />
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="1190" isRoot="false" value="" type="43" isAbstract="false" name="y" />
</UML:BehavioralFeature.parameter>
</UML:Operation>
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="1191" isRoot="false" isAbstract="false" name="tqcontains" >
<UML:Operation isSpecification="false" isLeaf="false" visibility="public" xmi.id="1191" isRoot="false" isAbstract="false" name="contains" >
<UML:BehavioralFeature.parameter>
<UML:Parameter kind="return" xmi.id="17101" type="5" />
<UML:Parameter isSpecification="false" isLeaf="false" visibility="private" xmi.id="1192" isRoot="false" value="" type="1176" isAbstract="false" name="pt" />
@ -2699,7 +2699,7 @@ Doubles are in the 0-1 range, use the producer's positionToString function to di
<UML:EnumerationLiteral isSpecification="false" isLeaf="false" visibility="public" xmi.id="486" isRoot="false" isAbstract="false" name="LOGARITHMIC" />
</UML:Enumeration>
<UML:Class isSpecification="false" isLeaf="false" visibility="public" xmi.id="497" isRoot="false" isAbstract="false" name="Q_UINT32" />
<UML:Class comment="Provides abstraction to a tile. A tile tqcontains
<UML:Class comment="Provides abstraction to a tile. A tile contains
a part of a PaintDevice, but only the individual pixels
are accesable and that only via iterators." isSpecification="false" isLeaf="false" visibility="public" xmi.id="558" isRoot="false" isAbstract="false" name="KisTile" >
<UML:Classifier.feature>

@ -5144,7 +5144,7 @@ namespace cimg_library {
\par Image structure
The \ref CImg<\c T> structure tqcontains \a five fields :
The \ref CImg<\c T> structure contains \a five fields :
- \ref width defines the number of \a columns of the image (size along the X-axis).
- \ref height defines the number of \a rows of the image (size along the Y-axis).
- \ref depth defines the number of \a slices of the image (size along the Z-axis).

@ -87,7 +87,7 @@ void KisBrightnessContrastFilterConfiguration::fromXML( const TQString& s )
curve.clear(); // XXX TQPtrList, sure I won't leak stuff here?
for (TQStringList::Iterator it = pairStart; it != pairEnd; ++it) {
TQString pair = * it;
if (pair.tqfind(",") > -1) {
if (pair.find(",") > -1) {
TQPair<double,double> *p = new TQPair<double,double>;
p->first = pair.section(",", 0, 0).toDouble();
p->second = pair.section(",", 1, 1).toDouble();

@ -86,7 +86,7 @@ curvesElement.text() );
TQStringList::Iterator pairEnd = data.end();
for (TQStringList::Iterator it = pairStart; it != pairEnd; ++it) {
TQString pair = * it;
if (pair.tqfind(",") > -1) {
if (pair.find(",") > -1) {
TQPair<double,double> *p = new TQPair<double,double>;
p->first = pair.section(",", 0, 0).toDouble();
p->second = pair.section(",", 1, 1).toDouble();

@ -159,7 +159,7 @@ uint KisOilPaintFilter::MostFrequentColor (KisPaintDeviceSP src, const TQRect& b
while (!it.isDone()) {
if (bounds.tqcontains(it.x(), it.y())) {
if (bounds.contains(it.x(), it.y())) {
// XXX: COLORSPACE_INDEPENDENCE

@ -104,7 +104,7 @@ void KisToolColorPicker::buttonPress(KisButtonPressEvent *e)
TQPoint pos = TQPoint(e->pos().floorX(), e->pos().floorY());
if (!img->bounds().tqcontains(pos)) {
if (!img->bounds().contains(pos)) {
return;
}

@ -151,7 +151,7 @@ void KisToolFill::buttonRelease(KisButtonReleaseEvent *e)
int x, y;
x = m_startPos.floorX();
y = m_startPos.floorY();
if (!m_currentImage->bounds().tqcontains(x, y)) {
if (!m_currentImage->bounds().contains(x, y)) {
return;
}
flood(x, y);

@ -818,7 +818,7 @@ TQ_INT32 KisToolCrop::mouseOnHandle(TQPoint currentViewPoint)
endy=start.y();
}
if ( toTQRect ( startx - m_handleSize / 2.0, starty - m_handleSize / 2.0, m_handleSize, m_handleSize ).tqcontains( currentViewPoint ) )
if ( toTQRect ( startx - m_handleSize / 2.0, starty - m_handleSize / 2.0, m_handleSize, m_handleSize ).contains( currentViewPoint ) )
{
if( !m_selecting )
{
@ -827,7 +827,7 @@ TQ_INT32 KisToolCrop::mouseOnHandle(TQPoint currentViewPoint)
}
return UpperLeft;
}
else if ( toTQRect ( startx - m_handleSize / 2.0, endy - m_handleSize / 2.0, m_handleSize, m_handleSize ).tqcontains( currentViewPoint ) )
else if ( toTQRect ( startx - m_handleSize / 2.0, endy - m_handleSize / 2.0, m_handleSize, m_handleSize ).contains( currentViewPoint ) )
{
if( !m_selecting )
{
@ -836,7 +836,7 @@ TQ_INT32 KisToolCrop::mouseOnHandle(TQPoint currentViewPoint)
}
return LowerLeft;
}
else if ( toTQRect ( endx - m_handleSize / 2.0, starty - m_handleSize / 2.0, m_handleSize, m_handleSize ).tqcontains( currentViewPoint ) )
else if ( toTQRect ( endx - m_handleSize / 2.0, starty - m_handleSize / 2.0, m_handleSize, m_handleSize ).contains( currentViewPoint ) )
{
if( !m_selecting )
{
@ -845,7 +845,7 @@ TQ_INT32 KisToolCrop::mouseOnHandle(TQPoint currentViewPoint)
}
return UpperRight;
}
else if ( toTQRect ( endx - m_handleSize / 2.0, endy - m_handleSize / 2.0, m_handleSize, m_handleSize ).tqcontains( currentViewPoint ) )
else if ( toTQRect ( endx - m_handleSize / 2.0, endy - m_handleSize / 2.0, m_handleSize, m_handleSize ).contains( currentViewPoint ) )
{
if( !m_selecting )
{
@ -854,7 +854,7 @@ TQ_INT32 KisToolCrop::mouseOnHandle(TQPoint currentViewPoint)
}
return LowerRight;
}
else if ( toTQRect ( startx + ( endx - startx - m_handleSize ) / 2.0, starty - m_handleSize / 2.0, m_handleSize, m_handleSize ).tqcontains( currentViewPoint ) )
else if ( toTQRect ( startx + ( endx - startx - m_handleSize ) / 2.0, starty - m_handleSize / 2.0, m_handleSize, m_handleSize ).contains( currentViewPoint ) )
{
if( !m_selecting )
{
@ -862,7 +862,7 @@ TQ_INT32 KisToolCrop::mouseOnHandle(TQPoint currentViewPoint)
}
return Upper;
}
else if ( toTQRect ( startx + ( endx - startx - m_handleSize ) / 2.0, endy - m_handleSize / 2, m_handleSize, m_handleSize ).tqcontains( currentViewPoint ) )
else if ( toTQRect ( startx + ( endx - startx - m_handleSize ) / 2.0, endy - m_handleSize / 2, m_handleSize, m_handleSize ).contains( currentViewPoint ) )
{
if( !m_selecting )
{
@ -870,7 +870,7 @@ TQ_INT32 KisToolCrop::mouseOnHandle(TQPoint currentViewPoint)
}
return Lower;
}
else if ( toTQRect ( startx - m_handleSize / 2.0, starty + ( endy - starty - m_handleSize ) / 2.0, m_handleSize, m_handleSize ).tqcontains( currentViewPoint ) )
else if ( toTQRect ( startx - m_handleSize / 2.0, starty + ( endy - starty - m_handleSize ) / 2.0, m_handleSize, m_handleSize ).contains( currentViewPoint ) )
{
if( !m_selecting )
{
@ -878,7 +878,7 @@ TQ_INT32 KisToolCrop::mouseOnHandle(TQPoint currentViewPoint)
}
return Left;
}
else if ( toTQRect ( endx - m_handleSize / 2.0 , starty + ( endy - starty - m_handleSize ) / 2.0, m_handleSize, m_handleSize ).tqcontains( currentViewPoint ) )
else if ( toTQRect ( endx - m_handleSize / 2.0 , starty + ( endy - starty - m_handleSize ) / 2.0, m_handleSize, m_handleSize ).contains( currentViewPoint ) )
{
if( !m_selecting )
{
@ -886,7 +886,7 @@ TQ_INT32 KisToolCrop::mouseOnHandle(TQPoint currentViewPoint)
}
return Right;
}
else if ( toTQRect ( startx , starty, endx - startx , endy - starty ).tqcontains( currentViewPoint ) )
else if ( toTQRect ( startx , starty, endx - startx , endy - starty ).contains( currentViewPoint ) )
{
return Inside;
}

@ -79,12 +79,12 @@ KisCurve KisCurve::selectedPivots(bool selected)
KisCurve KisCurve::subCurve(const KisPoint& tend)
{
return subCurve(tqfind(tend).previousPivot(),tqfind(tend));
return subCurve(find(tend).previousPivot(),find(tend));
}
KisCurve KisCurve::subCurve(const CurvePoint& tend)
{
return subCurve(tqfind(tend).previousPivot(),tqfind(tend));
return subCurve(find(tend).previousPivot(),find(tend));
}
KisCurve KisCurve::subCurve(iterator tend)
@ -94,12 +94,12 @@ KisCurve KisCurve::subCurve(iterator tend)
KisCurve KisCurve::subCurve(const KisPoint& tstart, const KisPoint& tend)
{
return subCurve(tqfind(tstart),tqfind(tend));
return subCurve(find(tstart),find(tend));
}
KisCurve KisCurve::subCurve(const CurvePoint& tstart, const CurvePoint& tend)
{
return subCurve(tqfind(tstart),tqfind(tend));
return subCurve(find(tstart),find(tend));
}
KisCurve KisCurve::subCurve(iterator tstart, iterator tend)
@ -137,7 +137,7 @@ KisCurve::iterator KisCurve::deleteCurve (const KisPoint& pos1, const KisPoint&
KisCurve::iterator KisCurve::deleteCurve (const CurvePoint& pos1, const CurvePoint& pos2)
{
return deleteCurve (tqfind(pos1),tqfind(pos2));
return deleteCurve (find(pos1),find(pos2));
}
KisCurve::iterator KisCurve::deleteCurve (KisCurve::iterator pos1, KisCurve::iterator pos2)
@ -154,12 +154,12 @@ KisCurve::iterator KisCurve::deleteCurve (KisCurve::iterator pos1, KisCurve::ite
KisCurve::iterator KisCurve::selectPivot(const KisPoint& pt, bool isSelected)
{
return selectPivot(tqfind(CurvePoint(pt,true)),isSelected);
return selectPivot(find(CurvePoint(pt,true)),isSelected);
}
KisCurve::iterator KisCurve::selectPivot(const CurvePoint& pt, bool isSelected)
{
return selectPivot(tqfind(pt),isSelected);
return selectPivot(find(pt),isSelected);
}
KisCurve::iterator KisCurve::selectPivot(KisCurve::iterator it, bool isSelected)
@ -171,7 +171,7 @@ KisCurve::iterator KisCurve::selectPivot(KisCurve::iterator it, bool isSelected)
}
KisCurve selected = pivots();
for (iterator i = selected.begin(); i != selected.end(); i++)
(*tqfind((*i))).setSelected(sel);
(*find((*i))).setSelected(sel);
(*it).setSelected(isSelected);
return it;
@ -184,7 +184,7 @@ KisCurve::iterator KisCurve::movePivot(const KisPoint& oldPt, const KisPoint& ne
KisCurve::iterator KisCurve::movePivot(const CurvePoint& oldPt, const KisPoint& newPt)
{
return movePivot(tqfind(oldPt), newPt);
return movePivot(find(oldPt), newPt);
}
KisCurve::iterator KisCurve::movePivot(KisCurve::iterator it, const KisPoint& newPt)
@ -213,7 +213,7 @@ void KisCurve::deletePivot (const KisPoint& pt)
void KisCurve::deletePivot (const CurvePoint& pt)
{
deletePivot(tqfind(pt));
deletePivot(find(pt));
}
void KisCurve::deletePivot (KisCurve::iterator it)

@ -130,10 +130,10 @@ public:
iterator begin() const;
iterator lastIterator() const;
iterator end() const;
iterator tqfind(const CurvePoint& pt);
iterator tqfind(const KisPoint& pt);
iterator tqfind(iterator it, const CurvePoint& pt);
iterator tqfind(iterator it, const KisPoint& pt);
iterator find(const CurvePoint& pt);
iterator find(const KisPoint& pt);
iterator find(iterator it, const CurvePoint& pt);
iterator find(iterator it, const KisPoint& pt);
KisCurve pivots();
KisCurve selectedPivots(bool = true);
@ -312,34 +312,34 @@ inline KisCurve::iterator KisCurve::end() const
return iterator(*this,m_curve.end());
}
inline KisCurve::iterator KisCurve::tqfind (const CurvePoint& pt)
inline KisCurve::iterator KisCurve::find (const CurvePoint& pt)
{
return iterator(*this,m_curve.tqfind(pt));
return iterator(*this,m_curve.find(pt));
}
inline KisCurve::iterator KisCurve::tqfind (const KisPoint& pt)
inline KisCurve::iterator KisCurve::find (const KisPoint& pt)
{
return iterator(*this,m_curve.tqfind(CurvePoint(pt)));
return iterator(*this,m_curve.find(CurvePoint(pt)));
}
inline KisCurve::iterator KisCurve::tqfind (KisCurve::iterator it, const CurvePoint& pt)
inline KisCurve::iterator KisCurve::find (KisCurve::iterator it, const CurvePoint& pt)
{
return iterator(*this,m_curve.tqfind(it.position(),pt));
return iterator(*this,m_curve.find(it.position(),pt));
}
inline KisCurve::iterator KisCurve::tqfind (iterator it, const KisPoint& pt)
inline KisCurve::iterator KisCurve::find (iterator it, const KisPoint& pt)
{
return iterator(*this,m_curve.tqfind(it.position(),CurvePoint(pt)));
return iterator(*this,m_curve.find(it.position(),CurvePoint(pt)));
}
inline void KisCurve::calculateCurve(const KisPoint& start, const KisPoint& end, KisCurve::iterator it)
{
calculateCurve(tqfind(CurvePoint(start)),tqfind(CurvePoint(end)),it);
calculateCurve(find(CurvePoint(start)),find(CurvePoint(end)),it);
}
inline void KisCurve::calculateCurve(const CurvePoint& start, const CurvePoint& end, KisCurve::iterator it)
{
calculateCurve(tqfind(start),tqfind(end),it);
calculateCurve(find(start),find(end),it);
}
inline void KisCurve::calculateCurve(KisCurve::iterator, KisCurve::iterator, KisCurve::iterator)

@ -289,7 +289,7 @@ KisCurve::iterator KisToolBezier::handleUnderMouse(const TQPoint& pos)
continue;
if (hint == BEZIERENDHINT && (m_actionOptions & SHIFTOPTION))
continue;
if (pivotRect(qpos).tqcontains(pos)) {
if (pivotRect(qpos).contains(pos)) {
inHandle.pushPoint((*it));
if (hint == BEZIERENDHINT && !(m_actionOptions & SHIFTOPTION))
break;
@ -300,7 +300,7 @@ KisCurve::iterator KisToolBezier::handleUnderMouse(const TQPoint& pos)
if (inHandle.isEmpty())
return m_curve->end();
return m_curve->tqfind(inHandle.last());
return m_curve->find(inHandle.last());
}
KisCurve::iterator KisToolBezier::drawPoint (KisCanvasPainter& gc, KisCurve::iterator point)

@ -124,7 +124,7 @@ void KisToolCurve::buttonPress(KisButtonPressEvent *event)
m_curve->selectAll(false);
draw(true, true);
draw(m_curve->end());
m_previous = m_curve->tqfind(m_curve->last());
m_previous = m_curve->find(m_curve->last());
m_current = m_curve->pushPivot(event->pos());
if (m_curve->pivots().count() > 1)
m_curve->calculateCurve(m_previous,m_current,m_current);
@ -158,7 +158,7 @@ void KisToolCurve::keyPress(TQKeyEvent *event)
draw(false);
m_dragging = false;
m_curve->deleteSelected();
m_current = m_curve->tqfind(m_curve->last());
m_current = m_curve->find(m_curve->last());
m_previous = m_curve->selectPivot(m_current);
draw(false);
}
@ -250,12 +250,12 @@ KisCurve::iterator KisToolCurve::handleUnderMouse(const TQPoint& pos)
KisCurve pivs = m_curve->pivots(), inHandle;
KisCurve::iterator it;
for (it = pivs.begin(); it != pivs.end(); it++) {
if (pivotRect(m_subject->canvasController()->windowToView((*it).point().toTQPoint())).tqcontains(pos))
if (pivotRect(m_subject->canvasController()->windowToView((*it).point().toTQPoint())).contains(pos))
inHandle.pushPoint((*it));
}
if (inHandle.isEmpty())
return m_curve->end();
return m_curve->tqfind(inHandle.last());
return m_curve->find(inHandle.last());
}
KisCurve::iterator KisToolCurve::selectByMouse(KisCurve::iterator it)
@ -344,8 +344,8 @@ void KisToolCurve::draw(KisCurve::iterator inf, bool pivotonly, bool minimal)
return;
}
for (KisCurve::iterator i = sel.begin(); i != sel.end(); i++) {
it = m_curve->tqfind(*i).previousPivot();
finish = m_curve->tqfind(*i).nextPivot();
it = m_curve->find(*i).previousPivot();
finish = m_curve->find(*i).nextPivot();
if ((*finish).isSelected())
finish = finish.previousPivot();
while (it != finish) {

@ -97,7 +97,7 @@ void KisToolPerspectiveGrid::update (KisCanvasSubject *subject)
bool KisToolPerspectiveGrid::mouseNear(const TQPoint& mousep, const TQPoint point)
{
return (TQRect( (point.x() - m_handleHalfSize), (point.y() - m_handleHalfSize), m_handleSize, m_handleSize).tqcontains(mousep) );
return (TQRect( (point.x() - m_handleHalfSize), (point.y() - m_handleHalfSize), m_handleSize, m_handleSize).contains(mousep) );
}
void KisToolPerspectiveGrid::buttonPress(KisButtonPressEvent *event)

@ -240,7 +240,7 @@ void KisToolPerspectiveTransform::paint(KisCanvasPainter& gc, const TQRect& rc)
bool KisToolPerspectiveTransform::mouseNear(const TQPoint& mousep, const TQPoint point)
{
return (TQRect( (point.x() - m_handleHalfSize), (point.y() - m_handleHalfSize), m_handleSize, m_handleSize).tqcontains(mousep) );
return (TQRect( (point.x() - m_handleHalfSize), (point.y() - m_handleHalfSize), m_handleSize, m_handleSize).contains(mousep) );
}
void KisToolPerspectiveTransform::buttonPress(KisButtonPressEvent *event)

@ -133,7 +133,7 @@ void KisDropshadow::dropshadow(KisProgressDisplayInterface * progress, TQ_INT32
{
TQRect shadowBounds = shadowDev->exactBounds();
if (!image->bounds().tqcontains(shadowBounds)) {
if (!image->bounds().contains(shadowBounds)) {
TQRect newImageSize = image->bounds() | shadowBounds;
image->resize(newImageSize.width(), newImageSize.height());

@ -60,7 +60,7 @@ void SizeTip::positionTip( const TQRect &rect )
TQRect deskR = KGlobalSettings::desktopGeometry( TQPoint( 0, 0 ) );
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() );
}

@ -57,7 +57,7 @@ public:
return super::erase(first, last);
}
bool tqcontains(KSharedPtr<T> ptr) const
bool contains(KSharedPtr<T> ptr) const
{
for (int i = 0, n = super::count(); i < n; ++i)
if (super::at(i) == ptr)

@ -55,7 +55,7 @@ KisCompositeOp KisCmbComposite::currentItem() const
void KisCmbComposite::setCurrentItem(const KisCompositeOp& op)
{
if (m_list.tqfind(op) != m_list.end()) {
if (m_list.find(op) != m_list.end()) {
super::setCurrentText(op.id().name());
}
}

@ -57,7 +57,7 @@ KisID KisCmbIDList::currentItem() const
void KisCmbIDList::setCurrent(const KisID id)
{
if (m_list.tqfind(id) != m_list.end())
if (m_list.find(id) != m_list.end())
super::setCurrentText(id.name());
else {
m_list.push_back(id);

@ -72,7 +72,7 @@ KisDlgImageProperties::KisDlgImageProperties(KisImageSP image, TQWidget *tqparen
//m_page->cmbColorSpaces->hide();
//m_page->lblColorSpaces->setText(image->colorSpace()->id().name());
KisIDList colorSpaces = KisMetaRegistry::instance()->csRegistry()->listKeys();
KisIDList::iterator i = colorSpaces.tqfind(KisID("WET",""));
KisIDList::iterator i = colorSpaces.find(KisID("WET",""));
if (i != colorSpaces.end()) {
colorSpaces.remove(i);
}

@ -130,7 +130,7 @@ ColorSettingsTab::ColorSettingsTab(TQWidget *tqparent, const char *name )
refillMonitorProfiles(KisID("RGBA", ""));
refillPrintProfiles(KisID(cfg.printerColorSpace(), ""));
if(m_page->cmbMonitorProfile->tqcontains(cfg.monitorProfile()))
if(m_page->cmbMonitorProfile->contains(cfg.monitorProfile()))
m_page->cmbMonitorProfile->setCurrentText(cfg.monitorProfile());
if(m_page->cmbPrintProfile->contains(cfg.printerProfile()))
m_page->cmbPrintProfile->setCurrentText(cfg.printerProfile());

@ -95,57 +95,57 @@ void KisFilterManager::setup(KActionCollection * ac)
if (!f) break;
TQString s = f->menuCategory();
if (s == "adjust" && !m_filterActionMenus.tqfind("adjust")) {
if (s == "adjust" && !m_filterActionMenus.find("adjust")) {
am = new KActionMenu(i18n("Adjust"), ac, "adjust_filters");
m_filterActionMenus.insert("adjust", am);
}
else if (s == "artistic" && !m_filterActionMenus.tqfind("artistic")) {
else if (s == "artistic" && !m_filterActionMenus.find("artistic")) {
am = new KActionMenu(i18n("Artistic"), ac, "artistic_filters");
m_filterActionMenus.insert("artistic", am);
}
else if (s == "blur" && !m_filterActionMenus.tqfind("blur")) {
else if (s == "blur" && !m_filterActionMenus.find("blur")) {
am = new KActionMenu(i18n("Blur"), ac, "blur_filters");
m_filterActionMenus.insert("blur", am);
}
else if (s == "colors" && !m_filterActionMenus.tqfind("colors")) {
else if (s == "colors" && !m_filterActionMenus.find("colors")) {
am = new KActionMenu(i18n("Colors"), ac, "color_filters");
m_filterActionMenus.insert("colors", am);
}
else if (s == "decor" && !m_filterActionMenus.tqfind("decor")) {
else if (s == "decor" && !m_filterActionMenus.find("decor")) {
am = new KActionMenu(i18n("Decor"), ac, "decor_filters");
m_filterActionMenus.insert("decor", am);
}
else if (s == "edge" && !m_filterActionMenus.tqfind("edge")) {
else if (s == "edge" && !m_filterActionMenus.find("edge")) {
am = new KActionMenu(i18n("Edge Detection"), ac, "edge_filters");
m_filterActionMenus.insert("edge", am);
}
else if (s == "emboss" && !m_filterActionMenus.tqfind("emboss")) {
else if (s == "emboss" && !m_filterActionMenus.find("emboss")) {
am = new KActionMenu(i18n("Emboss"), ac, "emboss_filters");
m_filterActionMenus.insert("emboss", am);
}
else if (s == "enhance" && !m_filterActionMenus.tqfind("enhance")) {
else if (s == "enhance" && !m_filterActionMenus.find("enhance")) {
am = new KActionMenu(i18n("Enhance"), ac, "enhance_filters");
m_filterActionMenus.insert("enhance", am);
}
else if (s == "map" && !m_filterActionMenus.tqfind("map")) {
else if (s == "map" && !m_filterActionMenus.find("map")) {
am = new KActionMenu(i18n("Map"), ac, "map_filters");
m_filterActionMenus.insert("map", am);
}
else if (s == "nonphotorealistic" && !m_filterActionMenus.tqfind("nonphotorealistic")) {
else if (s == "nonphotorealistic" && !m_filterActionMenus.find("nonphotorealistic")) {
am = new KActionMenu(i18n("Non-photorealistic"), ac, "nonphotorealistic_filters");
m_filterActionMenus.insert("nonphotorealistic", am);
}
else if (s == "other" && !m_filterActionMenus.tqfind("other")) {
else if (s == "other" && !m_filterActionMenus.find("other")) {
other = new KActionMenu(i18n("Other"), ac, "misc_filters");
m_filterActionMenus.insert("other", other);
}
@ -171,7 +171,7 @@ void KisFilterManager::setup(KActionCollection * ac)
TQString("chalk_filter_%1").tqarg((*it) . id()).ascii());
// Add action to the right submenu
KActionMenu * m = m_filterActionMenus.tqfind( f->menuCategory() );
KActionMenu * m = m_filterActionMenus.find( f->menuCategory() );
if (m) {
m->insert(a);
}

@ -173,7 +173,7 @@ void KisFiltersListView::setLayer(KisLayerSP layer) {
void KisFiltersListView::setCurrentFilter(KisID filter)
{
setCurrentItem(tqfindItem(filter.name()));
setCurrentItem(findItem(filter.name()));
}
void KisFiltersListView::buildPreview()

@ -132,20 +132,20 @@ void KisGradientSliderWidget::mousePressEvent( TQMouseEvent * e )
// Change the activation order of the handles to avoid deadlocks
if( t > 0.5 )
{
if( leftHandle.tqcontains( e->pos() ) )
if( leftHandle.contains( e->pos() ) )
m_drag = LEFT_DRAG;
else if( middleHandle.tqcontains( e->pos() ) )
else if( middleHandle.contains( e->pos() ) )
m_drag = MIDDLE_DRAG;
else if( rightHandle.tqcontains( e->pos() ) )
else if( rightHandle.contains( e->pos() ) )
m_drag = RIGHT_DRAG;
}
else
{
if( rightHandle.tqcontains( e->pos() ) )
if( rightHandle.contains( e->pos() ) )
m_drag = RIGHT_DRAG;
else if( middleHandle.tqcontains( e->pos() ) )
else if( middleHandle.contains( e->pos() ) )
m_drag = MIDDLE_DRAG;
else if( leftHandle.tqcontains( e->pos() ) )
else if( leftHandle.contains( e->pos() ) )
m_drag = LEFT_DRAG;
}

@ -499,7 +499,7 @@ void KisLayerBox::slotAddMenuActivated(int type)
void KisLayerBox::slotRmClicked()
{
TQValueList<int> l = list()->selectedLayerIDs();
if (l.count() < 2 && list()->activeLayer() && !l.tqcontains(list()->activeLayer()->id()))
if (l.count() < 2 && list()->activeLayer() && !l.contains(list()->activeLayer()->id()))
{
l.clear();
l.append(list()->activeLayer()->id());
@ -515,7 +515,7 @@ void KisLayerBox::slotRmClicked()
void KisLayerBox::slotRaiseClicked()
{
TQValueList<int> l = list()->selectedLayerIDs();
if (l.count() < 2 && list()->activeLayer() && !l.tqcontains(list()->activeLayer()->id()))
if (l.count() < 2 && list()->activeLayer() && !l.contains(list()->activeLayer()->id()))
{
l.clear();
l.append(list()->activeLayer()->id());
@ -542,7 +542,7 @@ void KisLayerBox::slotRaiseClicked()
void KisLayerBox::slotLowerClicked()
{
TQValueList<LayerItem*> l = list()->selectedLayers();
if (l.count() < 2 && list()->activeLayer() && !l.tqcontains(list()->activeLayer()))
if (l.count() < 2 && list()->activeLayer() && !l.contains(list()->activeLayer()))
{
l.clear();
l.append(list()->activeLayer());
@ -594,7 +594,7 @@ TQPixmap KisLayerBox::loadPixmap(const TQString& filename, const KIconLoader&
TQPixmap pixmap = il.loadIcon(filename, KIcon::NoGroup, size);
if (pixmap.isNull())
KMessageBox::error(0, i18n("Cannot tqfind %1").tqarg(filename),
KMessageBox::error(0, i18n("Cannot find %1").tqarg(filename),
i18n("Canvas"));
return pixmap;
@ -612,7 +612,7 @@ void KisLayerBox::markModified(KisLayer* layer)
layer = layer->tqparent();
}
for (int i = v.count() - 1; i >= 0; --i)
if (!m_modified.tqcontains(v[i]))
if (!m_modified.contains(v[i]))
m_modified.append(v[i]);
}

@ -126,7 +126,7 @@ void KisPaintopBox::colorSpaceChanged(KisColorSpace *cs)
}
}
int index = m_displayedOps->tqfindIndex(currentPaintop());
int index = m_displayedOps->findIndex(currentPaintop());
if (index == -1) {
// Must change the paintop as the current one is not supported
@ -162,7 +162,7 @@ void KisPaintopBox::slotInputDeviceChanged(const KisInputDevice & inputDevice)
paintop = (*it).second;
}
int index = m_displayedOps->tqfindIndex(paintop);
int index = m_displayedOps->findIndex(paintop);
if (index == -1) {
// Must change the paintop as the current one is not supported
@ -238,7 +238,7 @@ const KisPaintOpSettings *KisPaintopBox::paintopSettings(const KisID & paintop,
settingsArray = (*it).second;
}
const int index = m_paintops->tqfindIndex(paintop);
const int index = m_paintops->findIndex(paintop);
if (index >= 0 && index < (int)settingsArray.count())
return settingsArray[index];
else

@ -129,7 +129,7 @@ void KisPartLayerImpl::paintSelection(TQImage &img, TQ_INT32 x, TQ_INT32 y, TQ_I
for (int y2 = y; y2 < h + y; ++y2) {
for (int x2 = x; x2 < w + x; ++x2) {
if (!rect.tqcontains(x2, y2)) {
if (!rect.contains(x2, y2)) {
TQ_UINT8 g = (*(j + 0) + *(j + 1 ) + *(j + 2 )) / 9;
*(j+0) = 165+g;
*(j+1) = 128+g;

@ -64,7 +64,7 @@ KisResource *KisResourceMediator::currentResource() const
KisIconItem *KisResourceMediator::itemFor(KisResource *r) const
{
if(m_items.tqcontains(r))
if(m_items.contains(r))
{
return m_items[r];
}

@ -64,7 +64,7 @@ void KisResourceServerBase::loadResources(TQStringList filenames)
// XXX: Don't load resources with the same filename. Actually, we should look inside
// the resource to find out whether they are really the same, but for now this
// will prevent the same brush etc. showing up twice.
if (uniqueFiles.empty() || uniqueFiles.tqfind(fname) == uniqueFiles.end()) {
if (uniqueFiles.empty() || uniqueFiles.find(fname) == uniqueFiles.end()) {
uniqueFiles.append(fname);
KisResource *resource;
resource = createResource(front);

@ -87,7 +87,7 @@ void KisToolFreehand::buttonPress(KisButtonPressEvent *e)
// People complain that they can't start brush strokes outside of the image boundaries.
// This makes sense, especially when combined with BUG:132759, so commenting out the
// next line makes sense.
//if (!m_currentImage->bounds().tqcontains(e->pos().floorTQPoint())) return;
//if (!m_currentImage->bounds().contains(e->pos().floorTQPoint())) return;
initPaint(e);
paintAt(e->pos(), e->pressure(), e->xTilt(), e->yTilt());
@ -309,7 +309,7 @@ void KisToolFreehand::paintOutline(const KisPoint& point) {
KisCanvasController *controller = m_subject->canvasController();
if (currentImage() && !currentImage()->bounds().tqcontains(point.floorTQPoint())) {
if (currentImage() && !currentImage()->bounds().contains(point.floorTQPoint())) {
if (m_paintedOutline) {
controller->kiscanvas()->update();
m_paintedOutline = false;

@ -244,7 +244,7 @@ void KisToolPaint::updateCompositeOpComboBox()
KisCompositeOpList compositeOps = device->colorSpace()->userVisiblecompositeOps();
m_cmbComposite->setCompositeOpList(compositeOps);
if (compositeOps.tqfind(m_compositeOp) == compositeOps.end()) {
if (compositeOps.find(m_compositeOp) == compositeOps.end()) {
m_compositeOp = COMPOSITE_OVER;
}
m_cmbComposite->setCurrentItem(m_compositeOp);

@ -2281,7 +2281,7 @@ void KisView::canvasGotButtonPressEvent(KisButtonPressEvent *e)
// m_currentGuide = 0;
//
// if ((e->state() & ~TQt::ShiftButton) == Qt::NoButton) {
// KisGuideSP gd = mgr->tqfind(static_cast<TQ_INT32>(pt.x() / zoom()), static_cast<TQ_INT32>(pt.y() / zoom()), TQMAX(2.0, 2.0 / zoom()));
// KisGuideSP gd = mgr->find(static_cast<TQ_INT32>(pt.x() / zoom()), static_cast<TQ_INT32>(pt.y() / zoom()), TQMAX(2.0, 2.0 / zoom()));
//
// if (gd) {
// m_currentGuide = gd;
@ -3544,7 +3544,7 @@ bool KisView::eventFilter(TQObject *o, TQEvent *e)
mgr = img->guides();
if (e->type() == TQEvent::MouseMove && (me->state() & Qt::LeftButton)) {
bool flag = tqgeometry().tqcontains(pt);
bool flag = tqgeometry().contains(pt);
KisGuideSP gd;
if (m_currentGuide == 0 && flag) {

@ -362,23 +362,23 @@ KoBirdEyePanel::enumDragHandle KoBirdEyePanel::dragHandleAt(TQPoint p)
TQRect top = TQRect(m_visibleAreaInThumbnail.left()-1, m_visibleAreaInThumbnail.top()-1, m_visibleAreaInThumbnail.width()+2, 3);
TQRect bottom = TQRect(m_visibleAreaInThumbnail.left()-1, m_visibleAreaInThumbnail.bottom()-1, m_visibleAreaInThumbnail.width()+2, 3);
if (left.tqcontains(p)) {
if (left.contains(p)) {
return DragHandleLeft;
}
if (right.tqcontains(p)) {
if (right.contains(p)) {
return DragHandleRight;
}
if (top.tqcontains(p)) {
if (top.contains(p)) {
return DragHandleTop;
}
if (bottom.tqcontains(p)) {
if (bottom.contains(p)) {
return DragHandleBottom;
}
if (m_visibleAreaInThumbnail.tqcontains(p)) {
if (m_visibleAreaInThumbnail.contains(p)) {
return DragHandleCentre;
}
@ -403,7 +403,7 @@ void KoBirdEyePanel::handleMouseMove(TQPoint p)
break;
default:
case DragHandleNone:
if (TQT_TQRECT_OBJECT(m_thumbnail.rect()).tqcontains(p)) {
if (TQT_TQRECT_OBJECT(m_thumbnail.rect()).contains(p)) {
cursor = TQt::PointingHandCursor;
} else {
cursor = TQt::arrowCursor;
@ -462,7 +462,7 @@ void KoBirdEyePanel::handleMousePress(TQPoint p)
enumDragHandle dragHandle = dragHandleAt(p);
if (dragHandle == DragHandleNone) {
if (TQT_TQRECT_OBJECT(m_thumbnail.rect()).tqcontains(p)) {
if (TQT_TQRECT_OBJECT(m_thumbnail.rect()).contains(p)) {
// Snap visible area centre to p and begin a centre drag.

@ -681,7 +681,7 @@ void LayerList::contentsMouseDoubleClickEvent( TQMouseEvent *e )
super::contentsMouseDoubleClickEvent( e );
if( LayerItem *layer = static_cast<LayerItem*>( itemAt( contentsToViewport( e->pos() ) ) ) )
{
if( !layer->iconsRect().tqcontains( layer->mapFromListView( e->pos() ) ) )
if( !layer->iconsRect().contains( layer->mapFromListView( e->pos() ) ) )
{
emit requestLayerProperties( layer );
emit requestLayerProperties( layer->id() );
@ -867,7 +867,7 @@ void LayerItem::init()
LayerItem::~LayerItem()
{
if (listView() && (listView()->activeLayer() == this || tqcontains(listView()->activeLayer())))
if (listView() && (listView()->activeLayer() == this || contains(listView()->activeLayer())))
listView()->setActiveLayer( static_cast<LayerItem*>( 0 ) );
delete d;
}
@ -885,7 +885,7 @@ bool LayerItem::isFolder() const
return d->isFolder;
}
bool LayerItem::tqcontains(const LayerItem *item)
bool LayerItem::contains(const LayerItem *item)
{
TQListViewItemIterator it(this);
@ -1180,7 +1180,7 @@ bool LayerItem::mousePressEvent( TQMouseEvent *e )
const TQRect ir = iconsRect(), tr = textRect();
if( ir.tqcontains( e->pos() ) )
if( ir.contains( e->pos() ) )
{
const int iconWidth = iconSize().width();
int x = e->pos().x() - ir.left();
@ -1201,7 +1201,7 @@ bool LayerItem::mousePressEvent( TQMouseEvent *e )
return true;
}
else if( tr.tqcontains( e->pos() ) && isSelected() && !listView()->renameLineEdit()->isVisible() )
else if( tr.contains( e->pos() ) && isSelected() && !listView()->renameLineEdit()->isVisible() )
{
listView()->rename( this, 0 );
TQRect r( listView()->contentsToViewport( mapToListView( tr.topLeft() ) ), tr.size() );

@ -178,7 +178,7 @@ public:
// Returns true if this item is the given item or the tree rooted at
// this item contains the given item.
bool tqcontains(const LayerItem *item);
bool contains(const LayerItem *item);
int id() const;

@ -76,7 +76,7 @@ SqueezedComboBox::~SqueezedComboBox()
delete m_timer;
}
bool SqueezedComboBox::tqcontains( const TQString& _text ) const
bool SqueezedComboBox::contains( const TQString& _text ) const
{
if ( _text.isEmpty() )
return false;

@ -97,7 +97,7 @@ public:
*/
virtual ~SqueezedComboBox();
bool tqcontains(const TQString & text) const;
bool contains(const TQString & text) const;
/**
* This inserts a item to the list. See TQComboBox::insertItem()

@ -1025,7 +1025,7 @@ KisImageBuilder_Result KisImageMagickConverter::decode(const KURL& uri, bool isB
description = info -> description;
kdDebug(41008) << "Found import filter for: " << name << "\n";
if (!description.isEmpty() && !description.tqcontains('/')) {
if (!description.isEmpty() && !description.contains('/')) {
all += "*." + name.lower() + " *." + name + " ";
s += "*." + name.lower() + " *." + name + "|";
s += i18n(description.utf8());
@ -1042,7 +1042,7 @@ KisImageBuilder_Result KisImageMagickConverter::decode(const KURL& uri, bool isB
description = mi -> description;
kdDebug(41008) << "Found import filter for: " << name << "\n";
if (!description.isEmpty() && !description.tqcontains('/')) {
if (!description.isEmpty() && !description.contains('/')) {
all += "*." + name.lower() + " *." + name + " ";
s += "*." + name.lower() + " *." + name + "|";
s += i18n(description.utf8());
@ -1102,7 +1102,7 @@ KisImageBuilder_Result KisImageMagickConverter::decode(const KURL& uri, bool isB
description = info -> description;
if (!description.isEmpty() && !description.tqcontains('/')) {
if (!description.isEmpty() && !description.contains('/')) {
all += "*." + name.lower() + " *." + name + " ";
s += "*." + name.lower() + " *." + name + "|";
s += i18n(description.utf8());
@ -1121,7 +1121,7 @@ KisImageBuilder_Result KisImageMagickConverter::decode(const KURL& uri, bool isB
description = mi -> description;
if (!description.isEmpty() && !description.tqcontains('/')) {
if (!description.isEmpty() && !description.contains('/')) {
all += "*." + name.lower() + " *." + name + " ";
s += "*." + name.lower() + " *." + name + "|";
s += i18n(description.utf8());

@ -133,7 +133,7 @@ write_icc_profile (j_compress_ptr cinfo,
void
setup_read_icc_profile (j_decompress_ptr cinfo)
{
/* Tell the library to keep any APP2 data it may tqfind */
/* Tell the library to keep any APP2 data it may find */
jpeg_save_markers(cinfo, ICC_MARKER, 0xFFFF);
}

@ -970,7 +970,7 @@ KisImageBuilder_Result KisImageMagickConverter::decode(const KURL& uri, bool isB
description = info -> description;
kdDebug(41008) << "Found import filter for: " << name << "\n";
if (!description.isEmpty() && !description.tqcontains('/')) {
if (!description.isEmpty() && !description.contains('/')) {
all += "*." + name.lower() + " *." + name + " ";
s += "*." + name.lower() + " *." + name + "|";
s += i18n(description.utf8());
@ -987,7 +987,7 @@ KisImageBuilder_Result KisImageMagickConverter::decode(const KURL& uri, bool isB
description = mi -> description;
kdDebug(41008) << "Found import filter for: " << name << "\n";
if (!description.isEmpty() && !description.tqcontains('/')) {
if (!description.isEmpty() && !description.contains('/')) {
all += "*." + name.lower() + " *." + name + " ";
s += "*." + name.lower() + " *." + name + "|";
s += i18n(description.utf8());
@ -1047,7 +1047,7 @@ KisImageBuilder_Result KisImageMagickConverter::decode(const KURL& uri, bool isB
description = info -> description;
if (!description.isEmpty() && !description.tqcontains('/')) {
if (!description.isEmpty() && !description.contains('/')) {
all += "*." + name.lower() + " *." + name + " ";
s += "*." + name.lower() + " *." + name + "|";
s += i18n(description.utf8());
@ -1066,7 +1066,7 @@ KisImageBuilder_Result KisImageMagickConverter::decode(const KURL& uri, bool isB
description = mi -> description;
if (!description.isEmpty() && !description.tqcontains('/')) {
if (!description.isEmpty() && !description.contains('/')) {
all += "*." + name.lower() + " *." + name + " ";
s += "*." + name.lower() + " *." + name + "|";
s += i18n(description.utf8());

@ -128,7 +128,7 @@ xcf_load_image (XcfInfo * info)
goto hard_error;
/* check for a GimpGrid parasite */
parasite = gimp_image_parasite_tqfind (GIMP_IMAGE (gimage),
parasite = gimp_image_parasite_find (GIMP_IMAGE (gimage),
gimp_grid_parasite_name ());
if (parasite)
{

@ -791,16 +791,16 @@ void AIParserBase::_handleDocumentProcessColors(const char *data) {
signed int index;
index = tmp.tqfind ("Cyan");
index = tmp.find ("Cyan");
if (index > 0) colorSet |= PC_Cyan;
index = tmp.tqfind ("Magenta");
index = tmp.find ("Magenta");
if (index > 0) colorSet |= PC_Magenta;
index = tmp.tqfind ("Yellow");
index = tmp.find ("Yellow");
if (index > 0) colorSet |= PC_Yellow;
index = tmp.tqfind ("Black");
index = tmp.find ("Black");
if (index > 0) colorSet |= PC_Black;
if (m_documentHandler) m_documentHandler->gotProcessColors (colorSet);
@ -945,7 +945,7 @@ void AIParserBase::gotToken (const char *value) {
TQString string(value);
if (m_modules.tqfindIndex(string) != -1)
if (m_modules.findIndex(string) != -1)
{
AIElement element (string, AIElement::Reference);
handleElement (element);
@ -1067,7 +1067,7 @@ CommentOperation AIParserBase::getCommentOperation (const char *command) {
for(;;) {
CommentOperationMapping map = commentMappings[i];
if (map.op == NULL) return CO_Other;
index = data.tqfind (map.op);
index = data.find (map.op);
if (index >= 0) return map.action;
i++;
}
@ -1088,7 +1088,7 @@ void GStateHandlerBase::gotStrokePattern (const char *pname, double px, double p
const char *AIParserBase::getValue (const char *input) {
TQString data(input);
signed int index = data.tqfind (':');
signed int index = data.find (':');
if (index < 0) return "";
index++;
while (data.at(index) == ' ') index++;
@ -1099,7 +1099,7 @@ bool AIParserBase::getRectangle (const char* input, int &llx, int &lly, int &urx
if (input == NULL) return false;
TQString s(input);
if (s.tqcontains ("(atend)")) return false;
if (s.contains ("(atend)")) return false;
TQStringList values = TQStringList::split (" ", input);
if (values.size() < 5) return false;
llx = values[1].toInt();

@ -231,11 +231,11 @@ KoFilter::ConversiontqStatus APPLIXGRAPHICImport::convert( const TQCString& from
//mystr.remove (0, 7);
//remove_pos = mystr.tqfind ('(');
//remove_pos = mystr.find ('(');
//mystr.remove (0, remove_pos);
//agLine.offX= mystr.toInt();
//remove_pos = mystr.tqfind (',');
//remove_pos = mystr.find (',');
//mystr.remove (0, remove_pos);
//agLine.offY= mystr.toInt();
rueck = sscanf ((const char *) mystr.latin1(), "(%d,%d)",

@ -298,7 +298,7 @@ BoundingBoxExtractor::~BoundingBoxExtractor() {}
void BoundingBoxExtractor::gotComment (const char *value)
{
TQString data (value);
if (data.tqfind("%BoundingBox:")==-1) return;
if (data.find("%BoundingBox:")==-1) return;
getRectangle (value, m_llx, m_lly, m_urx, m_ury);
}
@ -308,7 +308,7 @@ bool BoundingBoxExtractor::getRectangle (const char* input, int &llx, int &lly,
if (input == NULL) return false;
TQString s(input);
if (s.tqcontains ("(atend)")) return false;
if (s.contains ("(atend)")) return false;
TQString s2 = s.remove("%BoundingBox:");
TQStringList values = TQStringList::split (" ", s2.latin1());

@ -659,7 +659,7 @@ OoDrawImport::parseViewBox( const TQDomElement& object )
{
// allow for viewbox def with ',' or whitespace
TQString viewbox( object.attributeNS( ooNS::svg, "viewBox", TQString() ) );
TQStringList points = TQStringList::split( ' ', viewbox.tqreplace( ',', ' ').simplifyWhiteSpace() );
TQStringList points = TQStringList::split( ' ', viewbox.replace( ',', ' ').simplifyWhiteSpace() );
rect.setX( points[0].toFloat() );
rect.setY( points[1].toFloat() );
@ -715,19 +715,19 @@ OoDrawImport::parseColor( VColor &color, const TQString &s )
TQString g = colors[1];
TQString b = colors[2].left( ( colors[2].length() - 1 ) );
if( r.tqcontains( "%" ) )
if( r.contains( "%" ) )
{
r = r.left( r.length() - 1 );
r = TQString::number( int( ( double( 255 * r.toDouble() ) / 100.0 ) ) );
}
if( g.tqcontains( "%" ) )
if( g.contains( "%" ) )
{
g = g.left( g.length() - 1 );
g = TQString::number( int( ( double( 255 * g.toDouble() ) / 100.0 ) ) );
}
if( b.tqcontains( "%" ) )
if( b.contains( "%" ) )
{
b = b.left( b.length() - 1 );
b = TQString::number( int( ( double( 255 * b.toDouble() ) / 100.0 ) ) );

@ -63,7 +63,7 @@ KoFilter::ConversiontqStatus SvgImport::convert(const TQCString& from, const TQC
//Find the last extension
TQString strExt;
TQString fileIn ( m_chain->inputFile() );
const int result=fileIn.tqfindRev('.');
const int result=fileIn.findRev('.');
if (result>=0)
strExt=fileIn.mid(result).lower();
@ -143,7 +143,7 @@ void SvgImport::convert()
{
// allow for viewbox def with ',' or whitespace
TQString viewbox( docElem.attribute( "viewBox" ) );
TQStringList points = TQStringList::split( ' ', viewbox.tqreplace( ',', ' ').simplifyWhiteSpace() );
TQStringList points = TQStringList::split( ' ', viewbox.replace( ',', ' ').simplifyWhiteSpace() );
gc->matrix.scale( width / points[2].toFloat() , height / points[3].toFloat() );
m_outerRect.setWidth( m_outerRect.width() * ( points[2].toFloat() / width ) );
@ -310,11 +310,11 @@ VObject* SvgImport::findObject( const TQString &name )
SvgImport::GradientHelper* SvgImport::findGradient( const TQString &id, const TQString &href)
{
// check if gradient was already parsed, and return it
if( m_gradients.tqcontains( id ) )
if( m_gradients.contains( id ) )
return &m_gradients[ id ];
// check if gradient was stored for later parsing
if( !m_defs.tqcontains( id ) )
if( !m_defs.contains( id ) )
return 0L;
TQDomElement e = m_defs[ id ];
@ -322,7 +322,7 @@ SvgImport::GradientHelper* SvgImport::findGradient( const TQString &id, const TQ
{
TQString mhref = e.attribute("xlink:href").mid(1);
if(m_defs.tqcontains(mhref))
if(m_defs.contains(mhref))
return findGradient(mhref, id);
else
return 0L;
@ -340,7 +340,7 @@ SvgImport::GradientHelper* SvgImport::findGradient( const TQString &id, const TQ
else
n = href;
if( m_gradients.tqcontains( n ) )
if( m_gradients.contains( n ) )
return &m_gradients[ n ];
else
return 0L;
@ -456,19 +456,19 @@ void SvgImport::parseColor( VColor &color, const TQString &s )
TQString g = colors[1];
TQString b = colors[2].left( ( colors[2].length() - 1 ) );
if( r.tqcontains( "%" ) )
if( r.contains( "%" ) )
{
r = r.left( r.length() - 1 );
r = TQString::number( int( ( double( 255 * r.toDouble() ) / 100.0 ) ) );
}
if( g.tqcontains( "%" ) )
if( g.contains( "%" ) )
{
g = g.left( g.length() - 1 );
g = TQString::number( int( ( double( 255 * g.toDouble() ) / 100.0 ) ) );
}
if( b.tqcontains( "%" ) )
if( b.contains( "%" ) )
{
b = b.left( b.length() - 1 );
b = TQString::number( int( ( double( 255 * b.toDouble() ) / 100.0 ) ) );
@ -504,7 +504,7 @@ void SvgImport::parseColorStops( VGradient *gradient, const TQDomElement &e )
{
float offset;
TQString temp = stop.attribute( "offset" );
if( temp.tqcontains( '%' ) )
if( temp.contains( '%' ) )
{
temp = temp.left( temp.length() - 1 );
offset = temp.toFloat() / 100.0;
@ -582,7 +582,7 @@ void SvgImport::parseGradient( const TQDomElement &e , const TQDomElement &refer
if( !id.isEmpty() )
{
// Copy existing gradient if it exists
if( m_gradients.tqfind( id ) != m_gradients.end() )
if( m_gradients.find( id ) != m_gradients.end() )
gradhelper.gradient = m_gradients[ id ].gradient;
}
@ -676,8 +676,8 @@ void SvgImport::parsePA( VObject *obj, SvgGraphicsContext *gc, const TQString &c
gc->fill.setType( VFill::none );
else if( params.startsWith( "url(" ) )
{
unsigned int start = params.tqfind("#") + 1;
unsigned int end = params.tqfindRev(")");
unsigned int start = params.find("#") + 1;
unsigned int end = params.findRev(")");
TQString key = params.mid( start, end - start );
GradientHelper *gradHelper = findGradient( key );
if( gradHelper )
@ -739,8 +739,8 @@ void SvgImport::parsePA( VObject *obj, SvgGraphicsContext *gc, const TQString &c
gc->stroke.setType( VStroke::none );
else if( params.startsWith( "url(" ) )
{
unsigned int start = params.tqfind("#") + 1;
unsigned int end = params.tqfindRev(")");
unsigned int start = params.find("#") + 1;
unsigned int end = params.findRev(")");
TQString key = params.mid( start, end - start );
GradientHelper *gradHelper = findGradient( key );
@ -810,7 +810,7 @@ void SvgImport::parsePA( VObject *obj, SvgGraphicsContext *gc, const TQString &c
else if( command == "font-family" )
{
TQString family = params;
family.tqreplace( '\'' , ' ' );
family.replace( '\'' , ' ' );
gc->font.setFamily( family );
}
else if( command == "font-size" )
@ -1006,7 +1006,7 @@ void SvgImport::parseUse( VGroup *grp, const TQDomElement &e )
m_gc.current()->matrix.translate(tx,ty);
}
if(m_defs.tqcontains(key))
if(m_defs.contains(key))
{
TQDomElement a = m_defs[key];
if(a.tagName() == "g" || a.tagName() == "a")
@ -1100,7 +1100,7 @@ void SvgImport::parseDefs( const TQDomElement &e )
TQString definition = b.attribute( "id" );
if( !definition.isEmpty() )
{
if( !m_defs.tqcontains( definition ) )
if( !m_defs.contains( definition ) )
m_defs.insert( definition, b );
}
}
@ -1152,7 +1152,7 @@ void SvgImport::createText( VGroup *grp, const TQDomElement &b )
continue;
TQString key = e.attribute( "xlink:href" ).mid( 1 );
if( ! m_defs.tqcontains(key) )
if( ! m_defs.contains(key) )
{
// try to find referenced object in document
VObject* obj = findObject( key );
@ -1214,7 +1214,7 @@ void SvgImport::createText( VGroup *grp, const TQDomElement &b )
continue;
TQString key = e.attribute( "xlink:href" ).mid( 1 );
if( ! m_defs.tqcontains(key) )
if( ! m_defs.contains(key) )
{
// try to find referenced object in document
VObject* obj = findObject( key );
@ -1328,7 +1328,7 @@ void SvgImport::createObject( VGroup *grp, const TQDomElement &b, const VObject:
bool bFirst = true;
TQString points = b.attribute( "points" ).simplifyWhiteSpace();
points.tqreplace( ',', ' ' );
points.replace( ',', ' ' );
points.remove( '\r' );
points.remove( '\n' );
TQStringList pointList = TQStringList::split( ' ', points );

@ -61,7 +61,7 @@ KoFilter::ConversiontqStatus XAMLImport::convert(const TQCString& from, const TQ
//Find the last extension
TQString strExt;
TQString fileIn ( m_chain->inputFile() );
const int result=fileIn.tqfindRev('.');
const int result=fileIn.findRev('.');
if (result>=0)
{
strExt=fileIn.mid(result).lower();
@ -133,7 +133,7 @@ XAMLImport::convert()
{
// allow for viewbox def with ',' or whitespace
TQString viewbox( docElem.attribute( "viewBox" ) );
TQStringList points = TQStringList::split( ' ', viewbox.tqreplace( ',', ' ').simplifyWhiteSpace() );
TQStringList points = TQStringList::split( ' ', viewbox.replace( ',', ' ').simplifyWhiteSpace() );
gc->matrix.scale( width / points[2].toFloat() , height / points[3].toFloat() );
m_outerRect.setWidth( m_outerRect.width() * ( points[2].toFloat() / width ) );
@ -303,19 +303,19 @@ XAMLImport::parseColor( VColor &color, const TQString &s )
TQString g = colors[1];
TQString b = colors[2].left( ( colors[2].length() - 1 ) );
if( r.tqcontains( "%" ) )
if( r.contains( "%" ) )
{
r = r.left( r.length() - 1 );
r = TQString::number( int( ( double( 255 * r.toDouble() ) / 100.0 ) ) );
}
if( g.tqcontains( "%" ) )
if( g.contains( "%" ) )
{
g = g.left( g.length() - 1 );
g = TQString::number( int( ( double( 255 * g.toDouble() ) / 100.0 ) ) );
}
if( b.tqcontains( "%" ) )
if( b.contains( "%" ) )
{
b = b.left( b.length() - 1 );
b = TQString::number( int( ( double( 255 * b.toDouble() ) / 100.0 ) ) );
@ -347,7 +347,7 @@ XAMLImport::parseColorStops( VGradient *gradient, const TQDomElement &e )
{
float offset;
TQString temp = stop.attribute( "offset" );
if( temp.tqcontains( '%' ) )
if( temp.contains( '%' ) )
{
temp = temp.left( temp.length() - 1 );
offset = temp.toFloat() / 100.0;
@ -454,8 +454,8 @@ XAMLImport::parsePA( VObject *obj, XAMLGraphicsContext *gc, const TQString &comm
gc->fill.setType( VFill::none );
else if( params.startsWith( "url(" ) )
{
unsigned int start = params.tqfind("#") + 1;
unsigned int end = params.tqfindRev(")");
unsigned int start = params.find("#") + 1;
unsigned int end = params.findRev(")");
TQString key = params.mid( start, end - start );
gc->fill.gradient() = m_gradients[ key ].gradient;
if( m_gradients[ key ].bbox )
@ -505,8 +505,8 @@ XAMLImport::parsePA( VObject *obj, XAMLGraphicsContext *gc, const TQString &comm
gc->stroke.setType( VStroke::none );
else if( params.startsWith( "url(" ) )
{
unsigned int start = params.tqfind("#") + 1;
unsigned int end = params.tqfindRev(")");
unsigned int start = params.find("#") + 1;
unsigned int end = params.findRev(")");
TQString key = params.mid( start, end - start );
gc->stroke.gradient() = m_gradients[ key ].gradient;
gc->stroke.gradient().transform( m_gradients[ key ].gradientTransform );
@ -567,7 +567,7 @@ XAMLImport::parsePA( VObject *obj, XAMLGraphicsContext *gc, const TQString &comm
else if( command == "font-family" )
{
TQString family = params;
family.tqreplace( '\'' , ' ' );
family.replace( '\'' , ' ' );
gc->font.setFamily( family );
}
else if( command == "font-size" )
@ -750,10 +750,10 @@ XAMLImport::parseGroup( VGroup *grp, const TQDomElement &e )
if( !b.attribute( "xlink:href" ).isEmpty() )
{
TQString params = b.attribute( "xlink:href" );
unsigned int start = params.tqfind("#") + 1;
unsigned int end = params.tqfindRev(")");
unsigned int start = params.find("#") + 1;
unsigned int end = params.findRev(")");
TQString key = params.mid( start, end - start );
if(m_paths.tqcontains(key))
if(m_paths.contains(key))
{
TQDomElement a = m_paths[key];
obj = createObject( a );
@ -854,10 +854,10 @@ void XAMLImport::createText( VGroup *grp, const TQDomElement &b )
continue;
TQString uri = e.attribute( "xlink:href" );
unsigned int start = uri.tqfind("#") + 1;
unsigned int end = uri.tqfindRev(")");
unsigned int start = uri.find("#") + 1;
unsigned int end = uri.findRev(")");
TQString key = uri.mid( start, end - start );
if( ! m_paths.tqcontains(key) )
if( ! m_paths.contains(key) )
{
VObject* obj = findObject( key );
if( obj )
@ -899,11 +899,11 @@ void XAMLImport::createText( VGroup *grp, const TQDomElement &b )
continue;
TQString uri = e.attribute( "xlink:href" );
unsigned int start = uri.tqfind("#") + 1;
unsigned int end = uri.tqfindRev(")");
unsigned int start = uri.find("#") + 1;
unsigned int end = uri.findRev(")");
TQString key = uri.mid( start, end - start );
if( ! m_paths.tqcontains(key) )
if( ! m_paths.contains(key) )
{
VObject* obj = findObject( key );
if( obj )
@ -1000,7 +1000,7 @@ VObject* XAMLImport::createObject( const TQDomElement &b )
bool bFirst = true;
TQString points = b.attribute( "points" ).simplifyWhiteSpace();
points.tqreplace( ',', ' ' );
points.replace( ',', ' ' );
points.remove( '\r' );
points.remove( '\n' );
TQStringList pointList = TQStringList::split( ' ', points );

@ -84,14 +84,14 @@ class MgpImporter:
def __setupDefaultFonts(self,command):
tokens=string.split(command,' ')
_key=string.tqreplace(tokens[1], '"', '')
_val=string.tqreplace(tokens[3], '"', '')
_key=string.replace(tokens[1], '"', '')
_val=string.replace(tokens[3], '"', '')
self.defFonts[_key]=_val
#print self.defFonts
def __setFontIndirect(self,command):
tokens=string.split(command,' ')
_font=string.tqreplace(tokens[1], '"', '')
_font=string.replace(tokens[1], '"', '')
if _font in self.defFonts.keys(): # we have a "default" font, find it in the map
self.__setFont(None,self.defFonts[_font])
#print self.defFonts[_font]
@ -99,9 +99,9 @@ class MgpImporter:
def __setFont(self,command,font=""):
if command:
tokens=string.split(command,' ')
font=string.tqreplace(tokens[1], '"', '').strip() #XLFD-like, eg: mincho-medium-r (family-weight-slant)
font=string.replace(tokens[1], '"', '').strip() #XLFD-like, eg: mincho-medium-r (family-weight-slant)
_numDash=string.tqfind(font,"-") #find dashes
_numDash=string.find(font,"-") #find dashes
if (_numDash==-1): #mincho
self.fontName=font
@ -124,7 +124,7 @@ class MgpImporter:
def __setBgColor(self, command):
tokens=string.split(command,' ')
self.bctype="0"
self.color1=string.tqreplace(tokens[1].strip(),'"', '') #strip quotes and \n
self.color1=string.replace(tokens[1].strip(),'"', '') #strip quotes and \n
def __setBgGradient(self, command):
tokens=string.split(command,' ')
@ -135,8 +135,8 @@ class MgpImporter:
try:
dir=tokens[4]
self.color1=string.tqreplace(tokens[6].strip(),'"', '') #strip quotes and \n
self.color2=string.tqreplace(tokens[7].strip(),'"', '')
self.color1=string.replace(tokens[6].strip(),'"', '') #strip quotes and \n
self.color2=string.replace(tokens[7].strip(),'"', '')
except:
self.bctype="0"
self.color1="black"
@ -296,14 +296,14 @@ class MgpImporter:
def __setTextColor(self,command):
tokens=string.split(command,' ')
self.textColor=string.tqreplace(tokens[1].strip(),'"', '') #strip quotes
self.textColor=string.replace(tokens[1].strip(),'"', '') #strip quotes
#print self.textColor
def __handleBar(self,command):
tokens=string.split(command,' ')
try:
color=string.tqreplace(tokens[1].strip(),'"', '') #strip quotes and \n
color=string.replace(tokens[1].strip(),'"', '') #strip quotes and \n
width=tokens[2].strip()/1000*Y_OFFSET #in per mils of display height
start=tokens[3].strip()/100*PAGE_WIDTH #start position percent of display width
length=tokens[4].strip()/100*PAGE_WIDTH #length percent of display width
@ -357,7 +357,7 @@ class MgpImporter:
if (line.startswith('#') or line.startswith('%%')): #skip comments
continue
elif (line.startswith('%')): #commands
commands=string.split(string.tqreplace(line, '%', ''),',') #list of commands, comma separated, remove '%'
commands=string.split(string.replace(line, '%', ''),',') #list of commands, comma separated, remove '%'
for command in commands:
command=command.strip().lower()
#print command

@ -886,7 +886,7 @@ void OoImpressExport::appendPicture( TQDomDocument & doc, TQDomElement & source,
{
TQString str = pictureKey( key );
TQString returnstr = m_kpresenterPictureLst[str];
const int pos=returnstr.tqfindRev('.');
const int pos=returnstr.findRev('.');
if (pos!=-1)
{
const TQString extension( returnstr.mid(pos+1) );

@ -828,11 +828,11 @@ void OoImpressImport::append2DGeometry( TQDomDocument& doc, TQDomElement& e, con
kdDebug(30518)<<" object transform \n";
//todo parse it
TQString transform = object.attributeNS( ooNS::draw, "transform", TQString() );
if( transform.tqcontains("rotate ("))
if( transform.contains("rotate ("))
{
//kdDebug(30518)<<" rotate object \n";
transform = transform.remove("rotate (" );
transform = transform.left(transform.tqfind(")"));
transform = transform.left(transform.find(")"));
//kdDebug(30518)<<" transform :"<<transform<<endl;
bool ok;
double radian = transform.toDouble(&ok);
@ -1353,7 +1353,7 @@ void OoImpressImport::appendShadow( TQDomDocument& doc, TQDomElement& e )
// use the shadow attribute to indicate a text-shadow
TQDomElement shadow = doc.createElement( "SHADOW" );
TQString distance = m_styleStack.attributeNS( ooNS::fo, "text-shadow" );
distance.truncate( distance.tqfind( ' ' ) );
distance.truncate( distance.find( ' ' ) );
shadow.setAttribute( "distance", KoUnit::parseValue( distance ) );
shadow.setAttribute( "direction", 5 );
shadow.setAttribute( "color", "#a0a0a0" );
@ -2045,7 +2045,7 @@ TQString OoImpressImport::storeImage( const TQDomElement& object )
TQString url = object.attributeNS( ooNS::xlink, "href", TQString() ).remove( '#' );
KArchiveFile* file = (KArchiveFile*) m_zip->directory()->entry( url );
TQString extension = url.mid( url.tqfind( '.' ) );
TQString extension = url.mid( url.find( '.' ) );
TQString fileName = TQString( "picture%1" ).tqarg( m_numPicture++ ) + extension;
KoStoreDevice* out = m_chain->storageFile( "pictures/" + fileName, KoStore::Write );
@ -2071,7 +2071,7 @@ TQString OoImpressImport::storeSound(const TQDomElement & object, TQDomElement &
if (!file.exists())
return TQString();
TQString extension = url.mid( url.tqfind( '.' ) );
TQString extension = url.mid( url.find( '.' ) );
TQString fileName = TQString( "sound%1" ).tqarg( m_numSound++ ) + extension;
fileName = "sounds/" + fileName;
KoStoreDevice* out = m_chain->storageFile( fileName, KoStore::Write );

@ -139,7 +139,7 @@ void Object::setBackground( bool bg )
bool Object::hasProperty( std::string name )
{
std::map<std::string,PropertyValue>::const_iterator i;
i = d->properties.tqfind( name );
i = d->properties.find( name );
if( i == d->properties.end() )
return false;
else

@ -526,7 +526,7 @@ unsigned long UString::toULong(bool *ok) const
return static_cast<unsigned long>(d);
}
int UString::tqfind(const UString &f, int pos) const
int UString::find(const UString &f, int pos) const
{
if (isNull())
return -1;

@ -334,7 +334,7 @@ namespace Libppt {
* @return Position of first occurence of f starting at position pos.
* -1 if the search was not successful.
*/
int tqfind(const UString &f, int pos = 0) const;
int find(const UString &f, int pos = 0) const;
/**
* @return Position of first occurence of f searching backwards from
* position pos.

@ -181,7 +181,7 @@ KoFilter::ConversiontqStatus APPLIXSPREADImport::convert( const TQCString& from,
// Search for ')'
pos = mystr.tqfind (')');
pos = mystr.find (')');
typestr = mystr.left (pos);
@ -190,7 +190,7 @@ KoFilter::ConversiontqStatus APPLIXSPREADImport::convert( const TQCString& from,
// alllenght = alllenght - pos - 1;
// Search for ':'
pos = mystr.tqfind (':');
pos = mystr.find (':');
// Copy cellnumber informations
cellnostr = mystr.left (pos);
@ -201,7 +201,7 @@ KoFilter::ConversiontqStatus APPLIXSPREADImport::convert( const TQCString& from,
// Split Table and Cell Number
pos = cellnostr.tqfind ('!');
pos = cellnostr.find ('!');
// Copy tabnumber informations
tabnostr = cellnostr.left (pos);
@ -215,7 +215,7 @@ KoFilter::ConversiontqStatus APPLIXSPREADImport::convert( const TQCString& from,
pos = cellnostr.tqfind (TQRegExp ("[0-9]"));
pos = cellnostr.find (TQRegExp ("[0-9]"));
kdDebug()<<" findpos :"<<pos<<endl;
@ -251,9 +251,9 @@ KoFilter::ConversiontqStatus APPLIXSPREADImport::convert( const TQCString& from,
// Replace part for this characters: <, >, &
mystr.tqreplace (TQRegExp ("&"), "&amp;");
mystr.tqreplace (TQRegExp ("<"), "&lt;");
mystr.tqreplace (TQRegExp (">"), "&gt;");
mystr.replace (TQRegExp ("&"), "&amp;");
mystr.replace (TQRegExp ("<"), "&lt;");
mystr.replace (TQRegExp (">"), "&gt;");
// Replace part for Applix Characters
@ -265,7 +265,7 @@ KoFilter::ConversiontqStatus APPLIXSPREADImport::convert( const TQCString& from,
// initialize
foundSpecialCharakter = false;
pos = mystr.tqfind ("^");
pos = mystr.find ("^");
// is there a special character ?
if (pos > -1 )
@ -277,7 +277,7 @@ KoFilter::ConversiontqStatus APPLIXSPREADImport::convert( const TQCString& from,
newchar = specCharfind (mystr[pos+1], mystr[pos+2]);
// replace the character
mystr.tqreplace (pos, 3, newchar);
mystr.replace (pos, 3, newchar);
}
}
@ -290,8 +290,8 @@ KoFilter::ConversiontqStatus APPLIXSPREADImport::convert( const TQCString& from,
TQString typeCharStr;
TQString typeCellStr;
int pos1 = typestr.tqfind ("|");
int pos2 = typestr.tqfindRev ("|");
int pos1 = typestr.find ("|");
int pos2 = typestr.findRev ("|");
typeFormStr = typestr.left (pos1);
@ -313,7 +313,7 @@ KoFilter::ConversiontqStatus APPLIXSPREADImport::convert( const TQCString& from,
tabctr = tabnostr;
// Searching for the rowcol part and adding to the hole string
pos = my_rc.tabname.tqfindIndex (tabnostr);
pos = my_rc.tabname.findIndex (tabnostr);
if (pos > -1) str += my_rc.rc[pos];
}
@ -936,12 +936,12 @@ APPLIXSPREADImport::readColormap (TQTextStream &stream, TQPtrList<t_mycolor> &m
kdDebug()<<" -> "<< mystr<<endl;
// Count the number of whitespaces
contcount = mystr.tqcontains (' ');
contcount = mystr.contains (' ');
kdDebug()<< "contcount: "<< contcount<<endl;
contcount -= 5;
// Begin off interest
pos = mystr.tqfind (" 0 ");
pos = mystr.find (" 0 ");
// get colorname
colstr = mystr.left (pos);
@ -1035,7 +1035,7 @@ APPLIXSPREADImport::readView (TQTextStream &stream, TQString instr, t_rc &rc)
sscanf ((*it).latin1(), "%c:%d", &ccolumn, &colwidth);
int len = (*it).length ();
int pos = (*it).tqfind (":");
int pos = (*it).find (":");
(*it).remove (pos, len-pos);
printf( " >%s<- -<%c><%d> \n", (*it).latin1(), ccolumn, colwidth);
@ -1120,7 +1120,7 @@ APPLIXSPREADImport::filterSHFGBG (TQString it, int *style, int *bgcolor,
int m2=0, m3=0;
// filter SH = Brushstyle Background
pos = it.tqfind ("SH");
pos = it.find ("SH");
if (pos > -1)
{
tmpstr = it;
@ -1134,7 +1134,7 @@ APPLIXSPREADImport::filterSHFGBG (TQString it, int *style, int *bgcolor,
// filter FG = FGCOLOR
pos = it.tqfind ("FG");
pos = it.find ("FG");
if (pos > -1)
{
tmpstr = it;
@ -1148,7 +1148,7 @@ APPLIXSPREADImport::filterSHFGBG (TQString it, int *style, int *bgcolor,
// filter BG = BGCOLOR
pos = it.tqfind ("BG");
pos = it.find ("BG");
if (pos > -1)
{
tmpstr = it;

@ -351,7 +351,7 @@ void CSVDialog::fillTable( )
for (column = 0; column < m_dialog->m_sheet->numCols(); ++column)
{
const TQString header = m_dialog->m_sheet->horizontalHeader()->label(column);
if ( m_formatList.tqfind( header ) == m_formatList.end() )
if ( m_formatList.find( header ) == m_formatList.end() )
m_dialog->m_sheet->horizontalHeader()->setLabel(column, i18n("Text"));
m_dialog->m_sheet->adjustColumn(column);

@ -93,18 +93,18 @@ TQString CSVExport::exportCSVCell( Sheet const * const sheet, int col, int row,
bool quote = false;
if ( !text.isEmpty() )
{
if ( text.tqfind( textQuote ) != -1 )
if ( text.find( textQuote ) != -1 )
{
TQString doubleTextQuote(textQuote);
doubleTextQuote.append(textQuote);
text.tqreplace(textQuote, doubleTextQuote);
text.replace(textQuote, doubleTextQuote);
quote = true;
} else if ( text[0].isSpace() || text[text.length()-1].isSpace() )
quote = true;
else if ( text.tqfind( csvDelimiter ) != -1 )
else if ( text.find( csvDelimiter ) != -1 )
quote = true;
else if ( text.tqfind( "\n" ) != -1 || text.tqfind( "\r" ) != -1 )
else if ( text.find( "\n" ) != -1 || text.find( "\r" ) != -1 )
quote = true;
}
@ -308,10 +308,10 @@ KoFilter::ConversiontqStatus CSVExport::convert( const TQCString & from, const T
else
name = "********<SHEETNAME>********";
const TQString tname( i18n("<SHEETNAME>") );
int pos = name.tqfind( tname );
int pos = name.find( tname );
if ( pos != -1 )
{
name.tqreplace( pos, tname.length(), sheet->sheetName() );
name.replace( pos, tname.length(), sheet->sheetName() );
}
str += name;
str += m_eol;

@ -193,7 +193,7 @@ KoFilter::ConversiontqStatus CSVFilter::convert( const TQCString& from, const TQ
bool ok = false;
TQString tmp ( text );
tmp.remove ( TQRegExp( "[^0-9,Ee+-]" ) ); // Keep only 0 to 9, comma, E, e, plus, minus
tmp.tqreplace ( ',', '.' );
tmp.replace ( ',', '.' );
kdDebug(30501) << "Comma: " << text << " => " << tmp << endl;
const double d = tmp.toDouble( &ok );
if ( !ok )
@ -214,7 +214,7 @@ KoFilter::ConversiontqStatus CSVFilter::convert( const TQCString& from, const TQ
bool ok = false;
TQString tmp ( text );
tmp.remove ( TQRegExp( "[^0-9\\.EeD+-]" ) ); // Keep only 0 to 9, dot, E, e, D, plus, minus
tmp.tqreplace ( 'D', 'E' ); // double from FORTRAN use D instead of E
tmp.replace ( 'D', 'E' ); // double from FORTRAN use D instead of E
kdDebug(30501) << "Point: " << text << " => " << tmp << endl;
const double d = tmp.toDouble( &ok );
if ( !ok )

@ -692,7 +692,7 @@ void ExcelImport::Private::processCellForStyle( Cell* cell, KoXmlWriter* xmlWrit
if( !xmlWriter ) return;
// only IF automatic style for this format has not been already created yet
if( !styleFormats.tqcontains( cell->formatIndex() ) )
if( !styleFormats.contains( cell->formatIndex() ) )
{
styleFormats[ cell->formatIndex() ] = true;

@ -5520,11 +5520,11 @@ void ExcelReader::handleFooter( FooterRecord* record )
int pos = -1, len = 0;
// left part
pos = footer.tqfind( UString("&L") );
pos = footer.find( UString("&L") );
if( pos >= 0 )
{
pos += 2;
len = footer.tqfind( UString("&C") ) - pos;
len = footer.find( UString("&C") ) - pos;
if( len > 0 )
{
left = footer.substr( pos, len );
@ -5533,11 +5533,11 @@ void ExcelReader::handleFooter( FooterRecord* record )
}
// center part
pos = footer.tqfind( UString("&C") );
pos = footer.find( UString("&C") );
if( pos >= 0 )
{
pos += 2;
len = footer.tqfind( UString("&R") ) - pos;
len = footer.find( UString("&R") ) - pos;
if( len > 0 )
{
center = footer.substr( pos, len );
@ -5546,7 +5546,7 @@ void ExcelReader::handleFooter( FooterRecord* record )
}
// right part
pos = footer.tqfind( UString("&R") );
pos = footer.find( UString("&R") );
if( pos >= 0 )
{
pos += 2;
@ -5569,11 +5569,11 @@ void ExcelReader::handleHeader( HeaderRecord* record )
int pos = -1, len = 0;
// left part of the header
pos = header.tqfind( UString("&L") );
pos = header.find( UString("&L") );
if( pos >= 0 )
{
pos += 2;
len = header.tqfind( UString("&C") ) - pos;
len = header.find( UString("&C") ) - pos;
if( len > 0 )
{
left = header.substr( pos, len );
@ -5582,11 +5582,11 @@ void ExcelReader::handleHeader( HeaderRecord* record )
}
// center part of the header
pos = header.tqfind( UString("&C") );
pos = header.find( UString("&C") );
if( pos >= 0 )
{
pos += 2;
len = header.tqfind( UString("&R") ) - pos;
len = header.find( UString("&R") ) - pos;
if( len > 0 )
{
center = header.substr( pos, len );
@ -5595,7 +5595,7 @@ void ExcelReader::handleHeader( HeaderRecord* record )
}
// right part of the header
pos = header.tqfind( UString("&R") );
pos = header.find( UString("&R") );
if( pos >= 0 )
{
pos += 2;

@ -1838,7 +1838,7 @@ private:
/**
Class MergedCellsRecord represents MergedCells record, which tqcontains
Class MergedCellsRecord represents MergedCells record, which contains
a list of all merged cells in the current sheets. Each entry in this list
define the range of cells that should be merged, namely firstRow, lastRow,
firstColumn and lastColumn.

@ -492,7 +492,7 @@ UString UString::substr(int pos, int len) const
return result;
}
int UString::tqfind(const UString &f, int pos) const
int UString::find(const UString &f, int pos) const
{
if (isNull())
return -1;

@ -333,7 +333,7 @@ namespace Swinder {
* @return Position of first occurence of f starting at position pos.
* -1 if the search was not successful.
*/
int tqfind(const UString &f, int pos = 0) const;
int find(const UString &f, int pos = 0) const;
/**
* Static instance of a null string.

@ -1340,8 +1340,8 @@ KoFilter::ConversiontqStatus GNUMERICExport::convert( const TQCString& from, con
if ( cell->isFormula() )
{
TQString tmp = cell->text();
if ( tmp.tqcontains( "==" ) )
tmp=tmp.tqreplace( "==", "=" );
if ( tmp.contains( "==" ) )
tmp=tmp.replace( "==", "=" );
text = tmp;
isLink = false;
}
@ -1406,7 +1406,7 @@ KoFilter::ConversiontqStatus GNUMERICExport::convert( const TQCString& from, con
isLink = false;
TQString tmp = cell->text();
if ( tmp =="==" )
tmp=tqreplace( "==", "=" );
tmp=replace( "==", "=" );
/* cell->calc( TRUE ); // Incredible, cells are not calculated if the document was just opened text = cell->valueString(); */
text = tmp;
break;
@ -1561,12 +1561,12 @@ TQString GNUMERICExport::convertRefToBase( const TQString & table, const TQRect
TQString GNUMERICExport::convertVariable( TQString headerFooter )
{
headerFooter = headerFooter.tqreplace( "<sheet>", "&[TAB]" );
headerFooter = headerFooter.tqreplace( "<date>", "&[DATE]" );
headerFooter = headerFooter.tqreplace( "<page>", "&[PAGE]" );
headerFooter = headerFooter.tqreplace( "<pages>", "&[PAGES]" );
headerFooter = headerFooter.tqreplace( "<time>", "&[TIME]" );
headerFooter = headerFooter.tqreplace( "<file>", "&[FILE]" );
headerFooter = headerFooter.replace( "<sheet>", "&[TAB]" );
headerFooter = headerFooter.replace( "<date>", "&[DATE]" );
headerFooter = headerFooter.replace( "<page>", "&[PAGE]" );
headerFooter = headerFooter.replace( "<pages>", "&[PAGES]" );
headerFooter = headerFooter.replace( "<time>", "&[TIME]" );
headerFooter = headerFooter.replace( "<file>", "&[FILE]" );
return headerFooter;
}

@ -176,8 +176,8 @@ void convert_string_to_qcolor(TQString color_string, TQColor * color)
bool number_ok;
first_col_pos = color_string.tqfind(":", 0);
second_col_pos = color_string.tqfind(":", first_col_pos + 1);
first_col_pos = color_string.find(":", 0);
second_col_pos = color_string.find(":", first_col_pos + 1);
/* Fore="0:0:FF00" */
/* If GNUmeric kicks out some invalid colors, we could crash. */
@ -196,30 +196,30 @@ void areaNames( Doc * ksdoc, const TQString &_name, TQString _zone )
{
//Sheet2!$A$2:$D$8
TQString tableName;
int pos = _zone.tqfind( '!' );
int pos = _zone.find( '!' );
if ( pos != -1 )
{
tableName = _zone.left( pos );
_zone = _zone.right( _zone.length()-pos-1 );
pos = _zone.tqfind( ':' );
pos = _zone.find( ':' );
TQRect rect;
if ( pos != -1 )
{
TQString left = _zone.mid( 1, pos-1 );
TQString right = _zone.mid( pos+2, _zone.length()-pos-2 );
int pos = left.tqfind( '$' );
int pos = left.find( '$' );
rect.setLeft( util_decodeColumnLabelText(left.left(pos ) ) );
rect.setTop( left.right( left.length()-pos-1 ).toInt() );
pos = right.tqfind( '$' );
pos = right.find( '$' );
rect.setRight( util_decodeColumnLabelText(right.left(pos ) ) );
rect.setBottom( right.right( right.length()-pos-1 ).toInt() );
}
else
{
TQString left = _zone;
int pos = left.tqfind( '$' );
int pos = left.find( '$' );
int leftPos = util_decodeColumnLabelText(left.left(pos ) );
rect.setLeft( leftPos );
rect.setRight( leftPos );
@ -814,15 +814,15 @@ TQString GNUMERICFilter::convertVars( TQString const & str, Sheet * table ) cons
for ( uint i = 0; i < count; ++i )
{
int n = result.tqfind( list1[i] );
int n = result.find( list1[i] );
if ( n != -1 )
{
kdDebug(30521) << "Found var: " << list1[i] << endl;
if ( i == 0 )
result = result.tqreplace( list1[i], table->tableName() );
result = result.replace( list1[i], table->tableName() );
else
result = result.tqreplace( list1[i], list2[i] );
result = result.replace( list1[i], list2[i] );
}
}
@ -926,7 +926,7 @@ void GNUMERICFilter::ParsePrintInfo( TQDomNode const & printInfo, Sheet * table
if ( !repeate.isEmpty() )
{
//fix row too high
repeate = repeate.tqreplace( "65536", "32500" );
repeate = repeate.replace( "65536", "32500" );
Range range(repeate);
//kdDebug()<<" repeate :"<<repeate<<"range. ::start row : "<<range.startRow ()<<" start col :"<<range.startCol ()<<" end row :"<<range.endRow ()<<" end col :"<<range.endCol ()<<endl;
table->print()->setPrintRepeatColumns( tqMakePair( range.startCol (),range.endCol ()) );
@ -983,7 +983,7 @@ void GNUMERICFilter::ParseFormat(TQString const & formatString, Cell * kspread_c
{
if ((formatString[0] == '[') && (formatString[1] == '$'))
{
int n = formatString.tqfind(']');
int n = formatString.find(']');
if (n != -1)
{
TQString currency = formatString.mid(2, n - 2);
@ -992,7 +992,7 @@ void GNUMERICFilter::ParseFormat(TQString const & formatString, Cell * kspread_c
}
lastPos = ++n;
}
else if (formatString.tqfind("E+0") != -1)
else if (formatString.find("E+0") != -1)
{
kspread_cell->format()->setFormatType(Scientific_format);
}
@ -1004,7 +1004,7 @@ void GNUMERICFilter::ParseFormat(TQString const & formatString, Cell * kspread_c
if ( setType(kspread_cell, formatString, content) )
return;
if (formatString.tqfind("?/?") != -1)
if (formatString.find("?/?") != -1)
{
// TODO: fixme!
kspread_cell->format()->setFormatType( fraction_three_digits );
@ -1035,7 +1035,7 @@ void GNUMERICFilter::ParseFormat(TQString const & formatString, Cell * kspread_c
while (formatString[lastPos] == ' ')
++lastPos;
int n = formatString.tqfind( '.', lastPos );
int n = formatString.find( '.', lastPos );
if ( n != -1)
{
lastPos = n + 1;
@ -1051,12 +1051,12 @@ void GNUMERICFilter::ParseFormat(TQString const & formatString, Cell * kspread_c
}
bool red = false;
if (formatString.tqfind("[RED]", lastPos) != -1)
if (formatString.find("[RED]", lastPos) != -1)
{
red = true;
kspread_cell->format()->setFloatColor( Format::NegRed );
}
if ( formatString.tqfind('(', lastPos) != -1 )
if ( formatString.find('(', lastPos) != -1 )
{
if ( red )
kspread_cell->format()->setFloatColor( Format::NegRedBrackets );
@ -1067,11 +1067,11 @@ void GNUMERICFilter::ParseFormat(TQString const & formatString, Cell * kspread_c
void GNUMERICFilter::convertFormula( TQString & formula ) const
{
int n = formula.tqfind( '=', 1 );
int n = formula.find( '=', 1 );
// TODO: check if we do not screw something up here...
if ( n != -1 )
formula = formula.tqreplace( n, 1, "==" );
formula = formula.replace( n, 1, "==" );
bool inQuote1 = false;
bool inQuote2 = false;
@ -1083,7 +1083,7 @@ void GNUMERICFilter::convertFormula( TQString & formula ) const
else if ( formula[i] == '"' )
inQuote2 = !inQuote2;
else if ( formula[i] == ',' && !inQuote1 && !inQuote2 )
formula = formula.tqreplace( i, 1, ";" );
formula = formula.replace( i, 1, ";" );
}
}

@ -105,7 +105,7 @@ KoFilter::ConversiontqStatus HTMLExport::convert( const TQCString& from, const T
Sheet *sheet = ksdoc->map()->firstSheet();
TQString filenameBase = m_chain->outputFile();
filenameBase = filenameBase.left( filenameBase.tqfindRev( '.' ) );
filenameBase = filenameBase.left( filenameBase.findRev( '.' ) );
TQStringList sheets;
while( sheet != 0 )
@ -345,10 +345,10 @@ void HTMLExport::convertSheet( Sheet *sheet, TQString &str, int iMaxUsedRow, int
text = text.right(text.length()-1);
} else if ( !link ) {
// Escape HTML characters.
text.tqreplace ('&' , strAmp)
.tqreplace ('<' , strLt)
.tqreplace ('>' , strGt)
.tqreplace (' ' , nbsp);
text.replace ('&' , strAmp)
.replace ('<' , strLt)
.replace ('>' , strGt)
.replace (' ' , nbsp);
}
line += ">\n";

@ -474,14 +474,14 @@ bool OpenCalcExport::exportBody( TQDomDocument & doc, TQDomElement & content, co
TQString name( sheet->tableName() );
int n = name.tqfind( ' ' );
int n = name.find( ' ' );
if ( n != -1 )
{
kdDebug(30518) << "Sheet name converting: " << name << endl;
name[n] == '_';
kdDebug(30518) << "Sheet name converted: " << name << endl;
}
name = name.tqreplace( ' ', "_" );
name = name.replace( ' ', "_" );
TQRect _printRange = sheet->print()->printRange();
if ( _printRange != ( TQRect( TQPoint( 1, 1 ), TQPoint( KS_colMax, KS_rowMax ) ) ) )

@ -80,7 +80,7 @@ OpenCalcImport::OpenCalcPoint::OpenCalcPoint( TQString const & str )
int colonPos = -1;
TQString range;
// tqreplace '.' with '!'
// replace '.' with '!'
for ( int i = 0; i < l; ++i )
{
if ( str[i] == '$' )
@ -261,9 +261,9 @@ void OpenCalcImport::checkForNamedAreas( TQString & formula ) const
}
if ( word.length() > 0 )
{
if ( m_namedAreas.tqfind( word ) != m_namedAreas.end() )
if ( m_namedAreas.find( word ) != m_namedAreas.end() )
{
formula = formula.tqreplace( start, word.length(), "'" + word + "'" );
formula = formula.replace( start, word.length(), "'" + word + "'" );
l = formula.length();
++i;
kdDebug(30518) << "Formula: " << formula << ", L: " << l << ", i: " << i + 1 <<endl;
@ -276,9 +276,9 @@ void OpenCalcImport::checkForNamedAreas( TQString & formula ) const
}
if ( word.length() > 0 )
{
if ( m_namedAreas.tqfind( word ) != m_namedAreas.end() )
if ( m_namedAreas.find( word ) != m_namedAreas.end() )
{
formula = formula.tqreplace( start, word.length(), "'" + word + "'" );
formula = formula.replace( start, word.length(), "'" + word + "'" );
l = formula.length();
++i;
kdDebug(30518) << "Formula: " << formula << ", L: " << l << ", i: " << i + 1 <<endl;
@ -635,13 +635,13 @@ bool OpenCalcImport::readCells( TQDomElement & rowNode, Sheet * table, int row,
int year=0, month=0, day=0;
ok = false;
int p1 = value.tqfind( '-' );
int p1 = value.find( '-' );
if ( p1 > 0 )
year = value.left( p1 ).toInt( &ok );
kdDebug(30518) << "year: " << value.left( p1 ) << endl;
int p2 = value.tqfind( '-', ++p1 );
int p2 = value.find( '-', ++p1 );
if ( ok )
month = value.mid( p1, p2 - p1 ).toInt( &ok );
@ -807,14 +807,14 @@ void OpenCalcImport::loadOasisCondition(Cell*cell,const TQDomElement &property )
void OpenCalcImport::loadOasisConditionValue( const TQString &styleCondition, Conditional &newCondition )
{
TQString val( styleCondition );
if ( val.tqcontains( "cell-content()" ) )
if ( val.contains( "cell-content()" ) )
{
val = val.remove( "cell-content()" );
loadOasisCondition( val,newCondition );
}
//GetFunction ::= cell-content-is-between(Value, Value) | cell-content-is-not-between(Value, Value)
//for the moment we support just int/double value, not text/date/time :(
if ( val.tqcontains( "cell-content-is-between(" ) )
if ( val.contains( "cell-content-is-between(" ) )
{
val = val.remove( "cell-content-is-between(" );
val = val.remove( ")" );
@ -822,7 +822,7 @@ void OpenCalcImport::loadOasisConditionValue( const TQString &styleCondition, Co
loadOasisValidationValue( listVal, newCondition );
newCondition.cond = Conditional::Between;
}
if ( val.tqcontains( "cell-content-is-not-between(" ) )
if ( val.contains( "cell-content-is-not-between(" ) )
{
val = val.remove( "cell-content-is-not-between(" );
val = val.remove( ")" );
@ -837,33 +837,33 @@ void OpenCalcImport::loadOasisConditionValue( const TQString &styleCondition, Co
void OpenCalcImport::loadOasisCondition( TQString &valExpression, Conditional &newCondition )
{
TQString value;
if (valExpression.tqfind( "<=" )==0 )
if (valExpression.find( "<=" )==0 )
{
value = valExpression.remove( 0,2 );
newCondition.cond = Conditional::InferiorEqual;
}
else if (valExpression.tqfind( ">=" )==0 )
else if (valExpression.find( ">=" )==0 )
{
value = valExpression.remove( 0,2 );
newCondition.cond = Conditional::SuperiorEqual;
}
else if (valExpression.tqfind( "!=" )==0 )
else if (valExpression.find( "!=" )==0 )
{
//add Differentto attribute
value = valExpression.remove( 0,2 );
newCondition.cond = Conditional::DifferentTo;
}
else if ( valExpression.tqfind( "<" )==0 )
else if ( valExpression.find( "<" )==0 )
{
value = valExpression.remove( 0,1 );
newCondition.cond = Conditional::Inferior;
}
else if(valExpression.tqfind( ">" )==0 )
else if(valExpression.find( ">" )==0 )
{
value = valExpression.remove( 0,1 );
newCondition.cond = Conditional::Superior;
}
else if (valExpression.tqfind( "=" )==0 )
else if (valExpression.find( "=" )==0 )
{
value = valExpression.remove( 0,1 );
newCondition.cond = Conditional::Equal;
@ -1135,9 +1135,9 @@ bool OpenCalcImport::readColLayouts( TQDomElement & content, Sheet * table )
void replaceMacro( TQString & text, TQString const & old, TQString const & newS )
{
int n = text.tqfind( old );
int n = text.find( old );
if ( n != -1 )
text = text.tqreplace( n, old.length(), newS );
text = text.replace( n, old.length(), newS );
}
TQString getPart( TQDomNode const & part )
@ -1332,35 +1332,35 @@ void OpenCalcImport::loadOasisMasterLayoutPage( Sheet * table,KoStyleStack &styl
TQString str = styleStack.attributeNS( ooNS::style, "print" );
kdDebug(30518)<<" style:print :"<<str<<endl;
if (str.tqcontains( "headers" ) )
if (str.contains( "headers" ) )
{
//todo implement it into kspread
}
if ( str.tqcontains( "grid" ) )
if ( str.contains( "grid" ) )
{
table->print()->setPrintGrid( true );
}
if ( str.tqcontains( "annotations" ) )
if ( str.contains( "annotations" ) )
{
//todo it's not implemented
}
if ( str.tqcontains( "objects" ) )
if ( str.contains( "objects" ) )
{
//todo it's not implemented
}
if ( str.tqcontains( "charts" ) )
if ( str.contains( "charts" ) )
{
//todo it's not implemented
}
if ( str.tqcontains( "drawings" ) )
if ( str.contains( "drawings" ) )
{
//todo it's not implemented
}
if ( str.tqcontains( "formulas" ) )
if ( str.contains( "formulas" ) )
{
table->setShowFormula(true);
}
if ( str.tqcontains( "zero-values" ) )
if ( str.contains( "zero-values" ) )
{
//todo it's not implemented
}
@ -1624,11 +1624,11 @@ void OpenCalcImport::loadOasisAreaName( const TQDomElement&body )
TQString range( point.translation );
if ( point.translation.tqfind( ':' ) == -1 )
if ( point.translation.find( ':' ) == -1 )
{
Point p( point.translation );
int n = range.tqfind( '!' );
int n = range.find( '!' );
if ( n > 0 )
range = range + ":" + range.right( range.length() - n - 1);
@ -2001,7 +2001,7 @@ void OpenCalcImport::loadBorder( Format * tqlayout, TQString const & borderDef,
if ( borderDef == "none" )
return;
int p = borderDef.tqfind( ' ' );
int p = borderDef.find( ' ' );
if ( p < 0 )
return;
@ -2011,7 +2011,7 @@ void OpenCalcImport::loadBorder( Format * tqlayout, TQString const & borderDef,
++p;
int p2 = borderDef.tqfind( ' ', p );
int p2 = borderDef.find( ' ', p );
TQString s = borderDef.mid( p, p2 - p );
kdDebug(30518) << "Borderstyle: " << s << endl;
@ -2031,7 +2031,7 @@ void OpenCalcImport::loadBorder( Format * tqlayout, TQString const & borderDef,
}
++p2;
p = borderDef.tqfind( ' ', p2 );
p = borderDef.find( ' ', p2 );
if ( p == -1 )
p = borderDef.length();
@ -2224,7 +2224,7 @@ void OpenCalcImport::readInStyle( Format * tqlayout, TQDomElement const & style
if ( style.hasAttributeNS( ooNS::style, "tqparent-style-name" ) )
{
Format * cp
= m_defaultStyles.tqfind( style.attributeNS( ooNS::style, "tqparent-style-name", TQString() ) );
= m_defaultStyles.find( style.attributeNS( ooNS::style, "tqparent-style-name", TQString() ) );
kdDebug(30518) << "Copying tqlayout from " << style.attributeNS( ooNS::style, "tqparent-style-name", TQString() ) << endl;
if ( cp != 0 )
@ -2233,7 +2233,7 @@ void OpenCalcImport::readInStyle( Format * tqlayout, TQDomElement const & style
else if ( style.hasAttributeNS( ooNS::style, "family") )
{
TQString name = style.attribute( "style-family" ) + "default";
Format * cp = m_defaultStyles.tqfind( name );
Format * cp = m_defaultStyles.find( name );
kdDebug(30518) << "Copying tqlayout from " << name << ", " << !cp << endl;
@ -2440,7 +2440,7 @@ void OpenCalcImport::loadOasisValidation( Validity* val, const TQString& validat
//A NumberValue is a whole or decimal number. It must not contain comma separators for numbers of 1000 or greater.
//ExtendedTrueCondition
if ( valExpression.tqcontains( "cell-content-text-length()" ) )
if ( valExpression.contains( "cell-content-text-length()" ) )
{
//"cell-content-text-length()>45"
valExpression = valExpression.remove("cell-content-text-length()" );
@ -2450,7 +2450,7 @@ void OpenCalcImport::loadOasisValidation( Validity* val, const TQString& validat
loadOasisValidationCondition( val, valExpression );
}
//cell-content-text-length-is-between(Value, Value) | cell-content-text-length-is-not-between(Value, Value)
else if ( valExpression.tqcontains( "cell-content-text-length-is-between" ) )
else if ( valExpression.contains( "cell-content-text-length-is-between" ) )
{
val->m_restriction = Restriction::TextLength;
val->m_cond = Conditional::Between;
@ -2460,7 +2460,7 @@ void OpenCalcImport::loadOasisValidation( Validity* val, const TQString& validat
TQStringList listVal = TQStringList::split( ",", valExpression );
loadOasisValidationValue( val, listVal );
}
else if ( valExpression.tqcontains( "cell-content-text-length-is-not-between" ) )
else if ( valExpression.contains( "cell-content-text-length-is-not-between" ) )
{
val->m_restriction = Restriction::TextLength;
val->m_cond = Conditional::Different;
@ -2475,36 +2475,36 @@ void OpenCalcImport::loadOasisValidation( Validity* val, const TQString& validat
//TrueFunction ::= cell-content-is-whole-number() | cell-content-is-decimal-number() | cell-content-is-date() | cell-content-is-time()
else
{
if (valExpression.tqcontains( "cell-content-is-whole-number()" ) )
if (valExpression.contains( "cell-content-is-whole-number()" ) )
{
val->m_restriction = Restriction::Number;
valExpression = valExpression.remove( "cell-content-is-whole-number() and " );
}
else if (valExpression.tqcontains( "cell-content-is-decimal-number()" ) )
else if (valExpression.contains( "cell-content-is-decimal-number()" ) )
{
val->m_restriction = Restriction::Integer;
valExpression = valExpression.remove( "cell-content-is-decimal-number() and " );
}
else if (valExpression.tqcontains( "cell-content-is-date()" ) )
else if (valExpression.contains( "cell-content-is-date()" ) )
{
val->m_restriction = Restriction::Date;
valExpression = valExpression.remove( "cell-content-is-date() and " );
}
else if (valExpression.tqcontains( "cell-content-is-time()" ) )
else if (valExpression.contains( "cell-content-is-time()" ) )
{
val->m_restriction = Restriction::Time;
valExpression = valExpression.remove( "cell-content-is-time() and " );
}
kdDebug(30518)<<"valExpression :"<<valExpression<<endl;
if ( valExpression.tqcontains( "cell-content()" ) )
if ( valExpression.contains( "cell-content()" ) )
{
valExpression = valExpression.remove( "cell-content()" );
loadOasisValidationCondition( val, valExpression );
}
//GetFunction ::= cell-content-is-between(Value, Value) | cell-content-is-not-between(Value, Value)
//for the moment we support just int/double value, not text/date/time :(
if ( valExpression.tqcontains( "cell-content-is-between(" ) )
if ( valExpression.contains( "cell-content-is-between(" ) )
{
valExpression = valExpression.remove( "cell-content-is-between(" );
valExpression = valExpression.remove( ")" );
@ -2513,7 +2513,7 @@ void OpenCalcImport::loadOasisValidation( Validity* val, const TQString& validat
val->m_cond = Conditional::Between;
}
if ( valExpression.tqcontains( "cell-content-is-not-between(" ) )
if ( valExpression.contains( "cell-content-is-not-between(" ) )
{
valExpression = valExpression.remove( "cell-content-is-not-between(" );
valExpression = valExpression.remove( ")" );
@ -2623,33 +2623,33 @@ void OpenCalcImport::loadOasisValidationValue( Validity* val, const TQStringList
void OpenCalcImport::loadOasisValidationCondition( Validity* val,TQString &valExpression )
{
TQString value;
if (valExpression.tqcontains( "<=" ) )
if (valExpression.contains( "<=" ) )
{
value = valExpression.remove( "<=" );
val->m_cond = Conditional::InferiorEqual;
}
else if (valExpression.tqcontains( ">=" ) )
else if (valExpression.contains( ">=" ) )
{
value = valExpression.remove( ">=" );
val->m_cond = Conditional::SuperiorEqual;
}
else if (valExpression.tqcontains( "!=" ) )
else if (valExpression.contains( "!=" ) )
{
//add Differentto attribute
value = valExpression.remove( "!=" );
val->m_cond = Conditional::DifferentTo;
}
else if ( valExpression.tqcontains( "<" ) )
else if ( valExpression.contains( "<" ) )
{
value = valExpression.remove( "<" );
val->m_cond = Conditional::Inferior;
}
else if(valExpression.tqcontains( ">" ) )
else if(valExpression.contains( ">" ) )
{
value = valExpression.remove( ">" );
val->m_cond = Conditional::Superior;
}
else if (valExpression.tqcontains( "=" ) )
else if (valExpression.contains( "=" ) )
{
value = valExpression.remove( "=" );
val->m_cond = Conditional::Equal;

@ -214,7 +214,7 @@ static const QpFormulaConv gConv[] =
{73, QpFormula::func3, "@mid("},
{74, QpFormula::func1, "@char("},
{75, QpFormula::func1, "@code("},
{76, QpFormula::func3, "@tqfind("},
{76, QpFormula::func3, "@find("},
{77, QpFormula::func1, "@dateVal("},
{78, QpFormula::func1, "@timeVal("},
{79, QpFormula::func1, "@cellPtr("},
@ -244,7 +244,7 @@ static const QpFormulaConv gConv[] =
{103, QpFormula::func1, "@lower("},
{104, QpFormula::func2, "@left("},
{105, QpFormula::func2, "@right("},
{106, QpFormula::func4, "@tqreplace("},
{106, QpFormula::func4, "@replace("},
{107, QpFormula::func1, "@proper("},
{108, QpFormula::func2, "@cell("},
{109, QpFormula::func1, "@trim("},

@ -26,7 +26,7 @@
bool AbiPropsMap::setProperty(const TQString& newName, const TQString& newValue)
{
tqreplace(newName,AbiProps(newValue));
replace(newName,AbiProps(newValue));
return true;
}
@ -43,7 +43,7 @@ void AbiPropsMap::splitAndAddAbiProps(const TQString& strProps)
TQStringList::ConstIterator end(list.end());
for (it=list.begin();it!=end;++it)
{
const int result=(*it).tqfind(':');
const int result=(*it).find(':');
if (result==-1)
{
name=(*it);

@ -57,7 +57,7 @@ void StyleDataMap::defineNewStyleFromOld(const TQString& strName, const TQString
return;
}
StyleDataMap::Iterator it=tqfind(strOld);
StyleDataMap::Iterator it=find(strOld);
if (it==end())
{
defineNewStyle(strName,level,strProps);
@ -76,7 +76,7 @@ void StyleDataMap::defineNewStyle(const TQString& strName, const int level,
{
// Despite its name, this method can be called multiple times
// We must take care that KWord just gets it only one time.
StyleDataMap::Iterator it=tqfind(strName);
StyleDataMap::Iterator it=find(strName);
if (it==end())
{
// The style does not exist yet, so we must define it.
@ -95,7 +95,7 @@ void StyleDataMap::defineNewStyle(const TQString& strName, const int level,
StyleDataMap::Iterator StyleDataMap::useOrCreateStyle(const TQString& strName)
{
// We are using a style but we are not sure if it is defined
StyleDataMap::Iterator it=tqfind(strName);
StyleDataMap::Iterator it=find(strName);
if (it==end())
{
// The style is not yet defined!

@ -153,7 +153,7 @@ bool AbiWordWorker::doOpenFile(const TQString& filenameOut, const TQString& )
<< " (in AbiWordWorker::doOpenFile)" << endl;
//Find the last extension
TQString strExt;
const int result=filenameOut.tqfindRev('.');
const int result=filenameOut.findRev('.');
if (result>=0)
{
strExt=filenameOut.mid(result);
@ -253,7 +253,7 @@ void AbiWordWorker::writePictureData(const TQString& koStoreName, const TQString
TQByteArray image;
TQString strExtension(koStoreName.lower());
const int result=koStoreName.tqfindRev(".");
const int result=koStoreName.findRev(".");
if (result>=0)
{
strExtension=koStoreName.mid(result+1);
@ -543,7 +543,7 @@ void AbiWordWorker::writeAbiProps (const TextFormatting& formatLayout, const Tex
TQString abiprops=textFormatToAbiProps(formatLayout,format,false);
// Erase the last semi-comma (as in CSS2, semi-commas only separate instructions and do not terminate them)
const int result=abiprops.tqfindRev(";");
const int result=abiprops.findRev(";");
if (result>=0)
{
@ -566,9 +566,9 @@ void AbiWordWorker::processNormalText ( const TQString &paraText,
// Replace line feeds by line breaks
int pos;
while ((pos=partialText.tqfind(TQChar(10)))>-1)
while ((pos=partialText.find(TQChar(10)))>-1)
{
partialText.tqreplace(pos,1,"<br/>");
partialText.replace(pos,1,"<br/>");
}
if (formatData.text.missing)
@ -904,7 +904,7 @@ bool AbiWordWorker::doFullParagraph(const TQString& paraText, const LayoutData&
{
// Find the last semi-comma
// Note: as in CSS2, semi-commas only separates instructions (like in PASCAL) and do not terminate them (like in C)
const int result=props.tqfindRev(";");
const int result=props.findRev(";");
if (result>=0)
{
// Remove the last semi-comma and the space thereafter
@ -956,7 +956,7 @@ bool AbiWordWorker::doFullDefineStyle(LayoutData& tqlayout)
TQString abiprops=layoutToCss(tqlayout,tqlayout,true);
const int result=abiprops.tqfindRev(";");
const int result=abiprops.findRev(";");
if (result>=0)
{
// Remove the last semi-comma and the space thereafter

@ -157,7 +157,7 @@ bool StructureParser::StartElementC(StackItem* stackItem, StackItem* stackCurren
TQString strStyleName=attributes.value("style").stripWhiteSpace();
if (!strStyleName.isEmpty())
{
StyleDataMap::Iterator it=styleDataMap.tqfind(strStyleName);
StyleDataMap::Iterator it=styleDataMap.find(strStyleName);
if (it!=styleDataMap.end())
{
strStyleProps=it.data().m_props;
@ -823,7 +823,7 @@ static bool StartElementPBR(StackItem* /*stackItem*/, StackItem* stackCurrent,
if (!nodeList.count())
{
kdError(30506) << "Unable to tqfind <LAYOUT> element! Aborting! (in StartElementPBR)" <<endl;
kdError(30506) << "Unable to find <LAYOUT> element! Aborting! (in StartElementPBR)" <<endl;
return false;
}
@ -1587,7 +1587,7 @@ bool StructureParser::endDocument(void)
StyleDataMap::ConstIterator it;
// At first, we put the Normal style
it=styleDataMap.tqfind("Normal");
it=styleDataMap.find("Normal");
if (it!=styleDataMap.end())
{
kdDebug(30506) << "\"" << it.key() << "\" => " << it.data().m_props << endl;
@ -1774,7 +1774,7 @@ KoFilter::ConversiontqStatus ABIWORDImport::convert( const TQCString& from, cons
//Find the last extension
TQString strExt;
TQString fileIn = m_chain->inputFile();
const int result=fileIn.tqfindRev('.');
const int result=fileIn.findRev('.');
if (result>=0)
{
strExt=fileIn.mid(result);

@ -160,7 +160,7 @@ KoFilter::ConversiontqStatus APPLIXWORDImport::convert( const TQCString& from, c
if (mystr.startsWith ("<color "))
{
mystr.remove (0, 8);
pos = mystr.tqfind ("\"");
pos = mystr.find ("\"");
coltxt = mystr.left (pos);
mystr.remove (0,pos+1);
rueck = sscanf ((const char *) mystr.latin1() ,
@ -252,7 +252,7 @@ KoFilter::ConversiontqStatus APPLIXWORDImport::convert( const TQCString& from, c
int y=0;
do
{
pos = mystr.tqfind ("\"", y);
pos = mystr.find ("\"", y);
kdDebug(30517)<<"POS:"<<pos<<" length:"<< mystr.length()<<" y:"<<y <<endl;
kdDebug(30517)<<"< "<<mystr<<" >\n";
@ -334,7 +334,7 @@ KoFilter::ConversiontqStatus APPLIXWORDImport::convert( const TQCString& from, c
(*it).remove (0, 7);
(*it).remove ((*it).length()-1, 1);
colname = *it;
colpos = mcoltxt.tqfindIndex (colname);
colpos = mcoltxt.findIndex (colname);
kdDebug(30517) <<" Color: "<< colname<<" "<< colpos <<" \n";
}
else
@ -691,9 +691,9 @@ APPLIXWORDImport::replaceSpecial (TQString &textstr)
int ok, pos;
// 1. Replace Part for this characters: <, >, &
textstr.tqreplace ('&', "&amp;");
textstr.tqreplace ('<', "&lt;");
textstr.tqreplace ('>', "&gt;");
textstr.replace ('&', "&amp;");
textstr.replace ('<', "&lt;");
textstr.replace ('>', "&gt;");
// 2. Replace part for this characters: applixwear qoutes
@ -702,12 +702,12 @@ APPLIXWORDImport::replaceSpecial (TQString &textstr)
do
{
// Searching for an quote
pos = textstr.tqfind ('\"', pos);
pos = textstr.find ('\"', pos);
// Is it an textqoute ?
if ((pos > -1) && (textstr[pos-1] == '\\'))
{
textstr.tqreplace (pos-1, 2,"\"");
textstr.replace (pos-1, 2,"\"");
}
else
{
@ -727,7 +727,7 @@ APPLIXWORDImport::replaceSpecial (TQString &textstr)
// initialize
foundSpecialCharakter = false;
pos = textstr.tqfind ("^");
pos = textstr.find ("^");
// is there a special character ?
if (pos > -1 )
@ -739,7 +739,7 @@ APPLIXWORDImport::replaceSpecial (TQString &textstr)
newchar = specCharfind (textstr[pos+1], textstr[pos+2]);
// replace the character
textstr.tqreplace (pos, 3, newchar);
textstr.replace (pos, 3, newchar);
}
}
while (foundSpecialCharakter == true);

@ -391,7 +391,7 @@ bool ASCIIWorker::ProcessParagraphData(const TQString& paraText,
case 1: // Normal text
{
TQString strText(paraText.mid((*paraFormatDataIt).pos,(*paraFormatDataIt).len));
strText = strText.tqreplace(TQChar(10), m_eol, true);
strText = strText.replace(TQChar(10), m_eol, true);
*m_streamOut << strText;
break;
}
@ -409,7 +409,7 @@ bool ASCIIWorker::ProcessParagraphData(const TQString& paraText,
TQValueList<ParaData>::ConstIterator it;
TQValueList<ParaData>::ConstIterator end(paraList->end());
for (it=paraList->begin();it!=end;++it)
notestr += (*it).text.stripWhiteSpace().tqreplace(TQChar(10), m_eol, true) + m_eol;
notestr += (*it).text.stripWhiteSpace().replace(TQChar(10), m_eol, true) + m_eol;
*m_streamOut << "[";
if (automatic) {

@ -404,7 +404,7 @@ void ASCIIImport::sentenceConvert(TQTextStream& stream, TQDomDocument& mainDocum
lastChar=strLine[lastPos];
if (lastChar.isNull())
break;
else if (skippingQuotes.tqfind(lastChar)==-1)
else if (skippingQuotes.find(lastChar)==-1)
break;
else
lastPos--;
@ -413,7 +413,7 @@ void ASCIIImport::sentenceConvert(TQTextStream& stream, TQDomDocument& mainDocum
lastChar=strLine[lastPos];
if (lastChar.isNull())
continue;
else if (stoppingPunctuation.tqfind(lastChar)!=-1)
else if (stoppingPunctuation.find(lastChar)!=-1)
break;
}
#if 1
@ -659,12 +659,12 @@ bool ASCIIImport::Table( TQString *Line, int *linecount, int no_lines,
}
// find column positions and record text fields
while((index2 = Line->tqfind( TQRegExp("\t"),index)) > index
while((index2 = Line->find( TQRegExp("\t"),index)) > index
|| (index3 = MultSpaces( *Line, index)) > index )
{
index1 = kMax(index2, index3);
if( index2 > index3)
index1 = Line->tqfind( TQRegExp("[^\t]"), index1);
index1 = Line->find( TQRegExp("[^\t]"), index1);
tabcount++;
tabs[i].field[no_cols] = Line->mid(index, (index1 - index -1));
tabs[i].width[no_cols] = index1 - index + spacespertab - 1;
@ -916,13 +916,13 @@ int ASCIIImport::MultSpaces(const TQString& text, const int index) const
{
type = "6";
// delete * at beginning of line
text.tqreplace( TQRegExp("^[ \t]*\\* "), "");
text.replace( TQRegExp("^[ \t]*\\* "), "");
}
else if( listtype[begin] == dash) // write out a dash list
{
type = "7";
// delete - at beginning of line
text.tqreplace( TQRegExp("^[ \t]*\\- "), "");
text.replace( TQRegExp("^[ \t]*\\- "), "");
}
else if( listtype[begin] == none) // write out a paragraph
type = "";
@ -965,7 +965,7 @@ bool ASCIIImport::IsListItem( TQString FirstLine, TQChar mark )
int k = FirstLine.tqfind(mark);
int k = FirstLine.find(mark);
if( k < 0) return false; // list item mark not on line

@ -200,7 +200,7 @@ TQByteArray HancomWordImport::Private::createContent()
for( uint i = 0; i < paragraphs.count(); i++ )
{
TQString text = paragraphs[i];
text.tqreplace( '\r', ' ' );
text.replace( '\r', ' ' );
contentWriter->startElement( "text:p" );
contentWriter->addTextNode( text );
contentWriter->endElement(); // text:p

@ -101,7 +101,7 @@ TQString HtmlCssWorker::textFormatToCss(const TextFormatting& formatOrigin,
&& (force || (formatOrigin.fontName!=formatData.fontName)))
{
strElement+="font-family: ";
if (fontName.tqfind(' ')==-1)
if (fontName.find(' ')==-1)
strElement+=escapeHtmlText(fontName);
else
{ // If the font name contains a space, it should be quoted.

@ -66,7 +66,7 @@ void HtmlDocStructWorker::openFormatData(const FormatData& formatOrigin,
{
// TODO/FIXME: find another way to find fixed fonts
// TODO/FIXME: (leaves out "Typewriter", "Monospace", "Mono")
if (format.text.fontName.tqcontains("ourier"))
if (format.text.fontName.contains("ourier"))
{
*m_streamOut << "<tt>"; // teletype
}
@ -133,7 +133,7 @@ void HtmlDocStructWorker::closeFormatData(const FormatData& formatOrigin,
}
}
if (format.text.fontName.tqcontains("ourier")) // Courier?
if (format.text.fontName.contains("ourier")) // Courier?
{
*m_streamOut << "</tt>"; // teletype
}

@ -98,7 +98,7 @@ TQString HtmlWorker::getAdditionalFileName(const TQString& additionalName)
TQString strFileName(m_strSubDirectoryName);
strFileName+="/";
const int result=additionalName.tqfindRev("/");
const int result=additionalName.findRev("/");
if (result>=0)
{
strFileName+=additionalName.mid(result+1);
@ -140,7 +140,7 @@ bool HtmlWorker::makeImage(const FrameAnchor& anchor)
const double height = anchor.frame.bottom - anchor.frame.top;
const double width = anchor.frame.right - anchor.frame.left;
const int pos = anchor.picture.koStoreName.tqfindRev( '.' );
const int pos = anchor.picture.koStoreName.findRev( '.' );
TQString extension;
if ( pos > -1 )
extension = anchor.picture.koStoreName.mid( pos+1 ).lower();
@ -243,9 +243,9 @@ void HtmlWorker::formatTextParagraph(const TQString& strText,
// Replace line feeds by line breaks
int pos;
TQString strBr(isXML()?TQString("<br />"):TQString("<br>"));
while ((pos=strEscaped.tqfind(TQChar(10)))>-1)
while ((pos=strEscaped.find(TQChar(10)))>-1)
{
strEscaped.tqreplace(pos,1,strBr);
strEscaped.replace(pos,1,strBr);
}
if (!format.text.missing)

@ -147,7 +147,7 @@ void KWord13Document::xmldump( TQIODevice* io )
TQString KWord13Document::getDocumentInfo( const TQString& name ) const
{
TQMap<TQString,TQString>::ConstIterator it ( m_documentInfo.tqfind( name ) );
TQMap<TQString,TQString>::ConstIterator it ( m_documentInfo.find( name ) );
if ( it == m_documentInfo.end() )
{
// Property does not exist
@ -176,7 +176,7 @@ TQString KWord13Document::getProperty( const TQString& name, const TQString& old
TQString KWord13Document::getPropertyInternal( const TQString& name ) const
{
TQMap<TQString,TQString>::ConstIterator it ( m_documentProperties.tqfind( name ) );
TQMap<TQString,TQString>::ConstIterator it ( m_documentProperties.find( name ) );
if ( it == m_documentProperties.end() )
{
// Property does not exist

@ -48,7 +48,7 @@ TQString KWord13FormatOneData::key( void ) const
TQString KWord13FormatOneData::getProperty( const TQString& name ) const
{
TQMap<TQString,TQString>::ConstIterator it ( m_properties.tqfind( name ) );
TQMap<TQString,TQString>::ConstIterator it ( m_properties.find( name ) );
if ( it == m_properties.end() )
{
// Property does not exist

@ -63,7 +63,7 @@ TQString KWord13Layout::key( void ) const
TQString KWord13Layout::getProperty( const TQString& name ) const
{
TQMap<TQString,TQString>::ConstIterator it ( m_layoutProperties.tqfind( name ) );
TQMap<TQString,TQString>::ConstIterator it ( m_layoutProperties.find( name ) );
if ( it == m_layoutProperties.end() )
{
// Property does not exist

@ -474,7 +474,7 @@ bool KWord13Parser::startElementAnchor( const TQString& name, const TQXmlAttribu
six->m_anchorName = frameset;
}
// add frameset name to the list of anchored framesets
if ( m_kwordDocument->m_anchoredFramesetNames.tqfind( frameset ) == m_kwordDocument->m_anchoredFramesetNames.end() )
if ( m_kwordDocument->m_anchoredFramesetNames.find( frameset ) == m_kwordDocument->m_anchoredFramesetNames.end() )
{
m_kwordDocument->m_anchoredFramesetNames.append( frameset );
}

@ -72,7 +72,7 @@ TQString KWord13Picture::getOasisPictureName( void ) const
number += TQString::number( (long long)( (void*) m_tempFile ) , 16 ); // in hex
TQString strExtension( m_storeName.lower() );
const int result = m_storeName.tqfindRev( '.' );
const int result = m_storeName.findRev( '.' );
if ( result >= 0 )
{
strExtension = m_storeName.mid( result );

@ -102,7 +102,7 @@ void PixmapFrame::getPixmap(const TQDomNode balise_initiale)
FileHeader::instance()->useGraphics();
TQString file = getKey();
/* Remove the extension */
int posExt = file.tqfindRev('.');
int posExt = file.findRev('.');
file.truncate(posExt);
/* Remove the path */
file = file.section('/', -1);
@ -166,7 +166,7 @@ void PixmapFrame::convert()
Config::instance()->getPicturesDir() == NULL)
{
dir = getFilename();
dir.truncate(getFilename().tqfindRev('/'));
dir.truncate(getFilename().findRev('/'));
}
else
dir = Config::instance()->getPicturesDir();

@ -269,7 +269,7 @@ void TextZone::convert(TQString& text, int tqunicode, const char* escape)
if( !TQString(escape).isEmpty() )
{
/*1. translate special characters with a space after. */
text = text.tqreplace( TQRegExp( expression), TQString(escape));
text = text.replace( TQRegExp( expression), TQString(escape));
}
}
@ -347,7 +347,7 @@ void TextZone::display(TQString texte, TQTextStream& out)
{
TQString line;
int index = 0, end = 0;
end = texte.tqfind(' ', 60, false);
end = texte.find(' ', 60, false);
if(end != -1)
line = texte.mid(index, end - index);
else
@ -361,7 +361,7 @@ void TextZone::display(TQString texte, TQTextStream& out)
out << line << endl;
Config::instance()->writeIndent(out);
index = end;
end = texte.tqfind(' ', index + 60, false);
end = texte.find(' ', index + 60, false);
line = texte.mid(index, end - index);
}
kdDebug(30522) << line << endl;

@ -86,16 +86,16 @@ Command::~Command()
void Command::addParam(const char* )
{
/*TQString test = TQString(name);
TQString key = test.left(test.tqfind("="));
TQString value = test.right(test.tqfind("="));
TQString key = test.left(test.find("="));
TQString value = test.right(test.find("="));
addParam(key, value);*/
}
void Command::addOption(const char* )
{
/*TQString test = TQString(name);
TQString key = test.left(test.tqfind("="));
TQString value = test.right(test.tqfind("="));
TQString key = test.left(test.find("="));
TQString value = test.right(test.find("="));
addOption(key, value);*/
}

@ -30,7 +30,7 @@ Env::Env(const char* command)
setType(Element::LATEX_ENV);
/* Parse the command name */
TQString pattern = TQString(command);
int pos = pattern.tqfind("{");
int pos = pattern.find("{");
/* Remove \begin{ at the begining and the } at the end. */
if(pos != -1)
_name = pattern.mid(pos + 1, pattern.length() - pos - 2);

@ -178,7 +178,7 @@ static void ProcessParagraphTag ( TQDomNode myNode,
AllowNoAttributes (myNode);
// We need to adjust the paragraph number (0 if first)
TQMap<TQString,int>::Iterator it = leader->m_paraCountMap.tqfind( leader->m_currentFramesetName );
TQMap<TQString,int>::Iterator it = leader->m_paraCountMap.find( leader->m_currentFramesetName );
if ( it == leader->m_paraCountMap.end() )
leader->m_paraCountMap.insert( leader->m_currentFramesetName, 0 );
else

@ -47,7 +47,7 @@ class KWEFKWordLeader;
* AllowNoSubtags () allow for easing parsing of subtags in the
* current tag. If don't expect any subtags you call AllowNoSubtags ().
* Otherwise you create a list of TagProcessing elements and pass that
* to ProcessSubtags () which will go through all subtags it can tqfind,
* to ProcessSubtags () which will go through all subtags it can find,
* call the corresponding processing function, and do all the
* necessary error handling.
*/
@ -89,7 +89,7 @@ void AllowNoSubtags ( const TQDomNode& myNode, KWEFKWordLeader *leader );
* attributes. If don't expect any attributes you call AllowNoAttributes ().
* Otherwise you create a list of AttrProcessing elements and pass
* that to ProcessAttributes () which will go through all attributes
* it can tqfind, retrieve the value in the datatype defined, and do all
* it can find, retrieve the value in the datatype defined, and do all
* the necessary error handling.
*/

@ -497,7 +497,7 @@ TQString KWordTextHandler::getFont(unsigned fc) const
static const unsigned ENTRIES = 6;
static const char* const fuzzyLookup[ENTRIES][2] =
{
// MS tqcontains X11 font family
// MS contains X11 font family
// substring. non-Xft name.
{ "times", "times" },
{ "courier", "courier" },
@ -515,7 +515,7 @@ TQString KWordTextHandler::getFont(unsigned fc) const
for (i = 0; i < ENTRIES; i++)
{
// The loop will leave unchanged any MS font name not fuzzy-matched.
if (font.tqfind(fuzzyLookup[i][0], 0, FALSE) != -1)
if (font.find(fuzzyLookup[i][0], 0, FALSE) != -1)
{
font = fuzzyLookup[i][1];
break;

@ -1028,7 +1028,7 @@ public:
MSWrite::DWord imageSize = 0;
TQString imageType;
int pos = frameAnchor.picture.koStoreName.tqfindRev ('.');
int pos = frameAnchor.picture.koStoreName.findRev ('.');
if (pos != -1) imageType = frameAnchor.picture.koStoreName.mid (pos).lower ();
kdDebug (30509) << "\timageType: " << imageType << endl;
@ -1783,19 +1783,19 @@ public:
if (softHyphen == -2)
{
softHyphen = stringUnicode.tqfind (TQChar (0xAD), upto);
softHyphen = stringUnicode.find (TQChar (0xAD), upto);
if (softHyphen == -1) softHyphen = INT_MAX;
}
if (nonBreakingSpace == -2)
{
nonBreakingSpace = stringUnicode.tqfind (TQChar (0xA0), upto);
nonBreakingSpace = stringUnicode.find (TQChar (0xA0), upto);
if (nonBreakingSpace == -1) nonBreakingSpace = INT_MAX;
}
if (newLine == -2)
{
newLine = stringUnicode.tqfind (TQChar ('\n'), upto);
newLine = stringUnicode.find (TQChar ('\n'), upto);
if (newLine == -1) newLine = INT_MAX;
}

@ -1182,11 +1182,11 @@ public:
m_charInfoCountLen += strUnicode.length ();
// make string XML-friendly (TODO: speed up)
strUnicode.tqreplace ('&', "&amp;");
strUnicode.tqreplace ('<', "&lt;");
strUnicode.tqreplace ('>', "&gt;");
strUnicode.tqreplace ('\"', "&quot;");
strUnicode.tqreplace ('\'', "&apos;");
strUnicode.replace ('&', "&amp;");
strUnicode.replace ('<', "&lt;");
strUnicode.replace ('>', "&gt;");
strUnicode.replace ('\"', "&quot;");
strUnicode.replace ('\'', "&apos;");
return writeTextInternal (strUnicode);
}

@ -479,7 +479,7 @@ namespace MSWrite
code++;
}
// couldn't tqfind
// couldn't find
return 0xFFFFFFFF;
}

@ -361,7 +361,7 @@ void OOWriterWorker::writeFontDeclaration(void)
TQMap<TQString,TQString>::ConstIterator end(m_fontNames.end());
for (TQMap<TQString,TQString>::ConstIterator it=m_fontNames.begin(); it!=end; ++it)
{
const bool space=(it.key().tqfind(' ')>=0); // Does the font has at least a space in its name
const bool space=(it.key().find(' ')>=0); // Does the font has at least a space in its name
const TQString fontName(escapeOOText(it.key()));
zipWriteData(" <style:font-decl style:name=\"");
zipWriteData(fontName);
@ -864,7 +864,7 @@ TQString OOWriterWorker::textFormatToStyle(const TextFormatting& formatOrigin,
const TQString lang ( formatData.language );
if ( ! lang.isEmpty() )
{
const int res = lang.tqfind( '_' );
const int res = lang.find( '_' );
if ( res >= 0 )
{
@ -1054,7 +1054,7 @@ bool OOWriterWorker::makeTableRows( const TQString& tableName, const Table& tabl
const TQString props ( cellToProperties( (*itCell), key ) );
TQString automaticCellStyle;
TQMap<TQString,TQString>::ConstIterator it ( mapCellStyleKeys.tqfind( key ) );
TQMap<TQString,TQString>::ConstIterator it ( mapCellStyleKeys.find( key ) );
if ( it == mapCellStyleKeys.end() )
{
automaticCellStyle = makeAutomaticStyleName( tableName + ".Cell", cellNumber );
@ -1349,7 +1349,7 @@ bool OOWriterWorker::makePicture( const FrameAnchor& anchor, const AnchorType an
TQByteArray image;
TQString strExtension(koStoreName.lower());
const int result=koStoreName.tqfindRev(".");
const int result=koStoreName.findRev(".");
if (result>=0)
{
strExtension=koStoreName.mid(result+1);
@ -1495,7 +1495,7 @@ void OOWriterWorker::processNormalText ( const TQString &paraText,
TQString styleKey;
const TQString props ( textFormatToStyle(formatLayout,formatData.text,false,styleKey) );
TQMap<TQString,TQString>::ConstIterator it ( m_mapTextStyleKeys.tqfind(styleKey) );
TQMap<TQString,TQString>::ConstIterator it ( m_mapTextStyleKeys.find(styleKey) );
kdDebug(30518) << "Searching text key: " << styleKey << endl;
TQString automaticStyle;
@ -1989,7 +1989,7 @@ bool OOWriterWorker::doFullParagraph(const TQString& paraText, const LayoutData&
TQString actualStyle(tqlayout.styleName);
if (!props.isEmpty())
{
TQMap<TQString,TQString>::ConstIterator it ( m_mapParaStyleKeys.tqfind(styleKey) );
TQMap<TQString,TQString>::ConstIterator it ( m_mapParaStyleKeys.find(styleKey) );
kdDebug(30518) << "Searching paragraph key: " << styleKey << endl;
TQString automaticStyle;
@ -2156,7 +2156,7 @@ void OOWriterWorker::declareFont(const TQString& fontName)
if (fontName.isEmpty())
return;
if (m_fontNames.tqfind(fontName)==m_fontNames.end())
if (m_fontNames.find(fontName)==m_fontNames.end())
{
TQString props;
@ -2205,22 +2205,22 @@ TQString OOWriterWorker::makeAutomaticStyleName(const TQString& prefix, ulong& c
// Checks if the automatic style has not the same name as a user one.
// If it is the case, change it!
if (m_styleMap.tqfind(str)==m_styleMap.end())
if (m_styleMap.find(str)==m_styleMap.end())
return str; // Unique, so let's go!
TQString str2(str+"_bis");
if (m_styleMap.tqfind(str2)==m_styleMap.end())
if (m_styleMap.find(str2)==m_styleMap.end())
return str2;
str2 = str+"_ter";
if (m_styleMap.tqfind(str2)==m_styleMap.end())
if (m_styleMap.find(str2)==m_styleMap.end())
return str2;
// If it is still not unique, try a time stamp.
const TQDateTime dt(TQDateTime::tqcurrentDateTime(Qt::UTC));
str2 = str + "_" + TQString::number(dt.toTime_t(),16);
if (m_styleMap.tqfind(str2)==m_styleMap.end())
if (m_styleMap.find(str2)==m_styleMap.end())
return str2;
kdWarning(30518) << "Could not make an unique style name: " << str2 << endl;

@ -1131,7 +1131,7 @@ void OoWriterImport::parseSpanOrSimilar( TQDomDocument& doc, const TQDomElement&
}
else if ( isTextNS && localName == "bookmark-end" ) {
TQString bkName = ts.attributeNS( ooNS::text, "name", TQString() );
BookmarkStartsMap::iterator it = m_bookmarkStarts.tqfind( bkName );
BookmarkStartsMap::iterator it = m_bookmarkStarts.find( bkName );
if ( it == m_bookmarkStarts.end() ) { // bookmark end without start. This seems to happen..
// insert simple bookmark then
appendBookmark( doc, numberOfParagraphs( m_currentFrameset ),
@ -1811,7 +1811,7 @@ TQString OoWriterImport::appendPicture(TQDomDocument& doc, const TQDomElement& o
if ( href[0]=='#' )
{
TQString strExtension;
const int result=href.tqfindRev(".");
const int result=href.findRev(".");
if (result>=0)
{
strExtension=href.mid(result+1); // As we are using KoPicture, the extension should be without the dot.
@ -1953,7 +1953,7 @@ void OoWriterImport::appendField(TQDomDocument& doc, TQDomElement& outputFormats
{
TQString dataStyleName = object.attributeNS( ooNS::style, "data-style-name", TQString() );
TQString dateFormat = "locale";
DataFormatsMap::const_iterator it = m_dateTimeFormats.tqfind( dataStyleName );
DataFormatsMap::const_iterator it = m_dateTimeFormats.find( dataStyleName );
if ( it != m_dateTimeFormats.end() )
dateFormat = (*it);
@ -2234,7 +2234,7 @@ void OoWriterImport::parseTable( TQDomDocument &doc, const TQDomElement& tqparen
repeat=1; // At least one column defined!
const TQString styleName ( elem.attributeNS( ooNS::table, "style-name", TQString()) );
kdDebug(30518) << "Column " << col << " style " << styleName << endl;
const TQDomElement* style=m_styles.tqfind(styleName);
const TQDomElement* style=m_styles.find(styleName);
double width=0.0;
if (style)
{
@ -2481,7 +2481,7 @@ TQString OoWriterImport::kWordStyleName( const TQString& ooStyleName )
{
if ( ooStyleName.startsWith( "Contents " ) ) {
TQString s( ooStyleName );
return s.tqreplace( 0, 9, TQString("Contents Head ") ); // Awful hack for KWord's broken "update TOC" feature
return s.replace( 0, 9, TQString("Contents Head ") ); // Awful hack for KWord's broken "update TOC" feature
} else {
return ooStyleName;
}

@ -133,11 +133,11 @@ TQString PalmDocImport::processPlainParagraph( TQString text )
tqlayout.append( "</LAYOUT>\n" );
// encode text for XML-ness
text.tqreplace( '&', "&amp;" );
text.tqreplace( '<', "&lt;" );
text.tqreplace( '>', "&gt;" );
text.tqreplace( '"', "&quot;" );
text.tqreplace( '\'', "&apos;" );
text.replace( '&', "&amp;" );
text.replace( '<', "&lt;" );
text.replace( '>', "&gt;" );
text.replace( '"', "&quot;" );
text.replace( '\'', "&apos;" );
// construct the <PARAGRAPH>
result.append( "<PARAGRAPH>\n" );
@ -160,7 +160,7 @@ TQString PalmDocImport::processPlainDocument( TQString plaindoc )
for( unsigned int i = 0; i < paragraphs.count(); i++ )
{
TQString text = paragraphs[i];
text.tqreplace( '\n', ' ' );
text.replace( '\n', ' ' );
content.append( processPlainParagraph( text ) );
}

@ -177,17 +177,17 @@ static const KnownData KNOWN_DATA[] = {
void Font::init(const TQString &n)
{
// check if font already parsed
_data = _dict->tqfind(n);
_data = _dict->find(n);
if ( _data==0 ) {
// kdDebug(30516) << "font " << n << endl;
TQString name = n;
name.tqreplace("oblique", "italic");
name.replace("oblique", "italic");
// check if known font
_data = new Data;
uint i = 0;
while ( KNOWN_DATA[i].name!=0 ) {
if ( name.tqfind(KNOWN_DATA[i].name)!=-1 ) {
if ( name.find(KNOWN_DATA[i].name)!=-1 ) {
// kdDebug(30516) << "found " << KNOWN_DATA[i].name
// << " " << isBold(KNOWN_DATA[i].style) << endl;
_data->family = FAMILY_DATA[KNOWN_DATA[i].family];
@ -201,13 +201,13 @@ void Font::init(const TQString &n)
if ( _data->family.isEmpty() ) { // let's try harder
// simple heuristic
kdDebug(30516) << "unknown font : " << n << endl;
if ( name.tqfind("times")!=-1 )
if ( name.find("times")!=-1 )
_data->family = FAMILY_DATA[Times];
else if ( name.tqfind("helvetica")!=-1 )
else if ( name.find("helvetica")!=-1 )
_data->family = FAMILY_DATA[Helvetica];
else if ( name.tqfind("courier")!=-1 )
else if ( name.find("courier")!=-1 )
_data->family = FAMILY_DATA[Courier];
else if ( name.tqfind("symbol")!=-1 )
else if ( name.find("symbol")!=-1 )
_data->family = FAMILY_DATA[Symbol];
else { // with TQt
TQFontDatabase fdb;
@ -223,8 +223,8 @@ void Font::init(const TQString &n)
}
}
bool italic = ( name.tqfind("italic")!=-1 );
bool bold = ( name.tqfind("bold")!=-1 );
bool italic = ( name.find("italic")!=-1 );
bool bold = ( name.find("bold")!=-1 );
_data->style = toStyle(bold, italic);
_data->latex = false;
}
@ -233,7 +233,7 @@ void Font::init(const TQString &n)
}
// check if TQFont already created
if ( !_data->height.tqcontains(_pointSize) ) {
if ( !_data->height.contains(_pointSize) ) {
TQFont font(_data->family, _pointSize,
(isBold(_data->style) ? TQFont::Bold : TQFont::Normal),
isItalic(_data->style));

@ -97,7 +97,7 @@ void *GHash::lookup(const GString *key) {
GHashBucket *p;
int h;
if (!(p = tqfind(key, &h))) {
if (!(p = find(key, &h))) {
return NULL;
}
return p->val;
@ -107,7 +107,7 @@ void *GHash::lookup(const char *key) {
GHashBucket *p;
int h;
if (!(p = tqfind(key, &h))) {
if (!(p = find(key, &h))) {
return NULL;
}
return p->val;
@ -119,7 +119,7 @@ void *GHash::remove(const GString *key) {
void *val;
int h;
if (!(p = tqfind(key, &h))) {
if (!(p = find(key, &h))) {
return NULL;
}
q = &tab[h];
@ -142,7 +142,7 @@ void *GHash::remove(const char *key) {
void *val;
int h;
if (!(p = tqfind(key, &h))) {
if (!(p = find(key, &h))) {
return NULL;
}
q = &tab[h];
@ -190,7 +190,7 @@ void GHash::killIter(GHashIter **iter) {
*iter = NULL;
}
GHashBucket *GHash::tqfind(const GString *key, int *h) {
GHashBucket *GHash::find(const GString *key, int *h) {
GHashBucket *p;
*h = hash(key);
@ -202,7 +202,7 @@ GHashBucket *GHash::tqfind(const GString *key, int *h) {
return NULL;
}
GHashBucket *GHash::tqfind(const char *key, int *h) {
GHashBucket *GHash::find(const char *key, int *h) {
GHashBucket *p;
*h = hash(key);

@ -37,8 +37,8 @@ public:
private:
GHashBucket *tqfind(const GString *key, int *h);
GHashBucket *tqfind(const char *key, int *h);
GHashBucket *find(const GString *key, int *h);
GHashBucket *find(const char *key, int *h);
int hash(const GString *key);
int hash(const char *key);

@ -61,7 +61,7 @@ CMap *CMap::parse(CMapCache *cache, GString *collectionA,
return new CMap(collectionA->copy(), cMapNameA->copy(), 1);
}
error(-1, "Couldn't tqfind '%s' CMap file for '%s' collection",
error(-1, "Couldn't find '%s' CMap file for '%s' collection",
cMapNameA->getCString(), collectionA->getCString());
return NULL;
}

@ -45,7 +45,7 @@ public:
GBool match(GString *collectionA, GString *cMapNameA);
// Return the CID corresponding to the character code starting at
// <s>, which tqcontains <len> bytes. Sets *<nUsed> to the number of
// <s>, which contains <len> bytes. Sets *<nUsed> to the number of
// bytes used by the char code.
CID getCID(char *s, int len, int *nUsed);

@ -50,7 +50,7 @@ void Dict::add(char *key, Object *val) {
++length;
}
inline DictEntry *Dict::tqfind(const char *key) {
inline DictEntry *Dict::find(const char *key) {
int i;
for (i = 0; i < length; ++i) {
@ -63,19 +63,19 @@ inline DictEntry *Dict::tqfind(const char *key) {
GBool Dict::is(const char *type) {
DictEntry *e;
return (e = tqfind("Type")) && e->val.isName(type);
return (e = find("Type")) && e->val.isName(type);
}
Object *Dict::lookup(const char *key, Object *obj) {
DictEntry *e;
return (e = tqfind(key)) ? e->val.fetch(xref, obj) : obj->initNull();
return (e = find(key)) ? e->val.fetch(xref, obj) : obj->initNull();
}
Object *Dict::lookupNF(const char *key, Object *obj) {
DictEntry *e;
return (e = tqfind(key)) ? e->val.copy(obj) : obj->initNull();
return (e = find(key)) ? e->val.copy(obj) : obj->initNull();
}
char *Dict::getKey(int i) {

@ -71,7 +71,7 @@ private:
int length; // number of entries in dictionary
int ref; // reference count
DictEntry *tqfind(const char *key);
DictEntry *find(const char *key);
};
#endif

@ -1121,7 +1121,7 @@ void JBIG2Bitmap::combine(JBIG2Bitmap *bitmap, int x, int y,
case 3: // xnor
dest ^= ((src1 ^ 0xff) >> s1) & m2;
break;
case 4: // tqreplace
case 4: // replace
dest = (dest & ~m3) | ((src1 >> s1) & m3);
break;
}
@ -1144,7 +1144,7 @@ void JBIG2Bitmap::combine(JBIG2Bitmap *bitmap, int x, int y,
case 3: // xnor
dest ^= (src1 ^ 0xff) & m2;
break;
case 4: // tqreplace
case 4: // replace
dest = (src1 & m2) | (dest & m1);
break;
}
@ -1174,7 +1174,7 @@ void JBIG2Bitmap::combine(JBIG2Bitmap *bitmap, int x, int y,
case 3: // xnor
dest ^= (src1 ^ 0xff) >> s1;
break;
case 4: // tqreplace
case 4: // replace
dest = (dest & (0xff << s2)) | (src1 >> s1);
break;
}
@ -1206,7 +1206,7 @@ void JBIG2Bitmap::combine(JBIG2Bitmap *bitmap, int x, int y,
case 3: // xnor
dest ^= src ^ 0xff;
break;
case 4: // tqreplace
case 4: // replace
dest = src;
break;
}
@ -1231,7 +1231,7 @@ void JBIG2Bitmap::combine(JBIG2Bitmap *bitmap, int x, int y,
case 3: // xnor
dest ^= (src ^ 0xff) & m2;
break;
case 4: // tqreplace
case 4: // replace
dest = (src & m2) | (dest & m1);
break;
}

@ -713,7 +713,7 @@ Links::~Links() {
gfree(links);
}
LinkAction *Links::tqfind(double x, double y) {
LinkAction *Links::find(double x, double y) {
int i;
for (i = numLinks - 1; i >= 0; --i) {

@ -357,7 +357,7 @@ public:
// If point <x>,<y> is in a link, return the associated action;
// else return NULL.
LinkAction *tqfind(double x, double y);
LinkAction *find(double x, double y);
// Return true if <x>,<y> is in a link.
GBool onLink(double x, double y);

@ -103,7 +103,7 @@ public:
// If point <x>,<y> is in a link, return the associated action;
// else return NULL.
LinkAction *findLink(double x, double y) { return links->tqfind(x, y); }
LinkAction *findLink(double x, double y) { return links->find(x, y); }
// Return true if <x>,<y> is in a link.
GBool onLink(double x, double y) { return links->onLink(x, y); }

@ -1231,10 +1231,10 @@ void XPDFCore::runCommand(GString *cmdFmt, GString *arg) {
//------------------------------------------------------------------------
// tqfind
// find
//------------------------------------------------------------------------
void XPDFCore::tqfind(char *s) {
void XPDFCore::find(char *s) {
Unicode *u;
TextOutputDev *textOut;
int xMin, yMin, xMax, yMax;

@ -142,9 +142,9 @@ public:
void doAction(LinkAction *action);
//----- tqfind
//----- find
void tqfind(char *s);
void find(char *s);
//----- simple modal dialogs

@ -690,7 +690,7 @@ void XPDFViewer::initWindow() {
zoomMenu = XmCreateOptionMenu(toolBar, "zoomMenu", args, n);
XtManageChild(zoomMenu);
// tqfind/print/about buttons
// find/print/about buttons
n = 0;
XtSetArg(args[n], XmNleftAttachment, XmATTACH_WIDGET); ++n;
XtSetArg(args[n], XmNleftWidget, zoomMenu); ++n;
@ -698,7 +698,7 @@ void XPDFViewer::initWindow() {
XtSetArg(args[n], XmNbottomAttachment, XmATTACH_FORM); ++n;
XtSetArg(args[n], XmNmarginWidth, 6); ++n;
XtSetArg(args[n], XmNlabelString, emptyString); ++n;
findBtn = XmCreatePushButton(toolBar, "tqfind", args, n);
findBtn = XmCreatePushButton(toolBar, "find", args, n);
XtManageChild(findBtn);
XtAddCallback(findBtn, XmNactivateCallback,
&findCbk, (XtPointer)this);
@ -1741,7 +1741,7 @@ void XPDFViewer::openOkCbk(Widget widget, XtPointer ptr,
}
//------------------------------------------------------------------------
// GUI code: "tqfind" dialog
// GUI code: "find" dialog
//------------------------------------------------------------------------
void XPDFViewer::initFindDialog() {
@ -1780,7 +1780,7 @@ void XPDFViewer::initFindDialog() {
findText = XmCreateTextField(row1, "text", args, n);
XtManageChild(findText);
//----- "tqfind" and "close" buttons
//----- "find" and "close" buttons
n = 0;
XtSetArg(args[n], XmNtopAttachment, XmATTACH_WIDGET); ++n;
XtSetArg(args[n], XmNtopWidget, row1); ++n;
@ -1816,7 +1816,7 @@ void XPDFViewer::findFindCbk(Widget widget, XtPointer ptr,
XtPointer callData) {
XPDFViewer *viewer = (XPDFViewer *)ptr;
viewer->core->tqfind(XmTextFieldGetString(viewer->findText));
viewer->core->find(XmTextFieldGetString(viewer->findText));
}
void XPDFViewer::findCloseCbk(Widget widget, XtPointer ptr,

@ -139,7 +139,7 @@ private:
static void openOkCbk(Widget widget, XtPointer ptr,
XtPointer callData);
//----- GUI code: "tqfind" dialog
//----- GUI code: "find" dialog
void initFindDialog();
static void findFindCbk(Widget widget, XtPointer ptr,
XtPointer callData);

@ -200,7 +200,7 @@ TQString RTFWorker::makeImage(const FrameAnchor& anchor)
kdDebug(30515) << "RTFWorker::makeImage" << endl << anchor.picture.koStoreName << endl;
const int pos=strImageName.tqfindRev('.');
const int pos=strImageName.findRev('.');
if(pos!=-1) strExt = strImageName.mid(pos+1).lower();
TQString strTag;
@ -345,9 +345,9 @@ TQString RTFWorker::formatTextParagraph(const TQString& strText,
// Replace line feeds by forced line breaks
int pos;
TQString strBr("\\line ");
while ((pos=strEscaped.tqfind(TQChar(10)))>-1)
while ((pos=strEscaped.find(TQChar(10)))>-1)
{
strEscaped.tqreplace(pos,1,strBr);
strEscaped.replace(pos,1,strBr);
}
str+=strEscaped;
@ -609,26 +609,26 @@ TQString RTFWorker::ProcessParagraphData ( const TQString &paraText,
// KLocale's key differ from KWord
// Date
key.tqreplace( "%Y", "yyyy" ); // Year 4 digits
key.tqreplace( "%y", "yy" ); // Year 2 digits
key.tqreplace( "%n", "M" ); // Month 1 digit
key.tqreplace( "%m", "MM" ); // Month 2 digits
key.tqreplace( "%e", "d" ); // Day 1 digit
key.tqreplace( "%d", "dd" ); // Day 2 digits
key.tqreplace( "%b", "MMM" ); // Month 3 letters
key.tqreplace( "%B", "MMMM" ); // Month all letters
key.tqreplace( "%a", "ddd" ); // Day 3 letters
key.tqreplace( "%A", "dddd" ); // Day all letters
key.replace( "%Y", "yyyy" ); // Year 4 digits
key.replace( "%y", "yy" ); // Year 2 digits
key.replace( "%n", "M" ); // Month 1 digit
key.replace( "%m", "MM" ); // Month 2 digits
key.replace( "%e", "d" ); // Day 1 digit
key.replace( "%d", "dd" ); // Day 2 digits
key.replace( "%b", "MMM" ); // Month 3 letters
key.replace( "%B", "MMMM" ); // Month all letters
key.replace( "%a", "ddd" ); // Day 3 letters
key.replace( "%A", "dddd" ); // Day all letters
// 12h
key.tqreplace( "%p", "am/pm" ); // AM/PM (KLocale knows it only lower case)
key.tqreplace( "%I", "hh" ); // 12 hour 2 digits
key.tqreplace( "%l", "h" ); // 12 hour 1 digits
key.replace( "%p", "am/pm" ); // AM/PM (KLocale knows it only lower case)
key.replace( "%I", "hh" ); // 12 hour 2 digits
key.replace( "%l", "h" ); // 12 hour 1 digits
// 24h
key.tqreplace( "%H", "HH" ); // 24 hour 2 digits
key.tqreplace( "%k", "H" ); // 24 hour 1 digit
key.replace( "%H", "HH" ); // 24 hour 2 digits
key.replace( "%k", "H" ); // 24 hour 1 digit
// Other times
key.tqreplace( "%M", "mm" ); // minute 2 digits (KLocale knows it with 2 digits)
key.tqreplace( "%S", "ss" ); // second 2 digits (KLocale knows it with 2 digits)
key.replace( "%M", "mm" ); // minute 2 digits (KLocale knows it with 2 digits)
key.replace( "%S", "ss" ); // second 2 digits (KLocale knows it with 2 digits)
kdDebug(30515) << "Locale date in RTF format: " << key << endl;
}
@ -638,18 +638,18 @@ TQString RTFWorker::ProcessParagraphData ( const TQString &paraText,
if (regexp.search(key)!=-1)
{
// 12h
key.tqreplace("ap","am/pm");
key.tqreplace("AP","AM/PM");
key.replace("ap","am/pm");
key.replace("AP","AM/PM");
}
else
{
//24h
key.tqreplace('h','H'); // MS Word uses H for 24hour times
key.replace('h','H'); // MS Word uses H for 24hour times
}
// MS Word do not know possesive months
key.tqreplace("PPP","MMM");
key.tqreplace("PPPP","MMMM");
key.tqreplace("zzz","000"); // replace microseconds by 000
key.replace("PPP","MMM");
key.replace("PPPP","MMMM");
key.replace("zzz","000"); // replace microseconds by 000
kdDebug(30515) << "New format: " << key << endl;
content += "\\@ \"";
content += key;
@ -954,9 +954,9 @@ void RTFWorker::writeFontData(void)
{
const TQString strLower( (*it).lower() );
*m_streamOut << "{\\f" << count;
if ( (strLower.tqfind("symbol")>-1) || (strLower.tqfind("dingbat")>-1) )
if ( (strLower.find("symbol")>-1) || (strLower.find("dingbat")>-1) )
*m_streamOut << "\\ftech";
else if ( (strLower.tqfind("script")>-1) )
else if ( (strLower.find("script")>-1) )
*m_streamOut << "\\fscript";
#if 1

@ -1,4 +1,4 @@
// kate: space-indent on; indent-width 4; tqreplace-tabs off;
// kate: space-indent on; indent-width 4; replace-tabs off;
/*
This file is part of the KDE project
Copyright (C) 2001 Ewald Snel <ewald@rambo.its.tudelft.nl>
@ -1347,7 +1347,7 @@ void RTFImport::parseFontTable( RTFProperty * )
qFont.setStyleHint( font.tqstyleHint );
for(;!qFont.exactMatch();)
{
int space=font.name.tqfindRev(' ', font.name.length());
int space=font.name.findRev(' ', font.name.length());
if(space==-1)
break;
font.name.truncate(space);
@ -1571,7 +1571,7 @@ void RTFImport::addImportedPicture( const TQString& rawFileName )
}
TQString slashPath( rawFileName );
slashPath.tqreplace('\\','/'); // Replace directory separators.
slashPath.replace('\\','/'); // Replace directory separators.
// ### TODO: what with MS-DOS absolute paths? (Will only work for KOffice on Win32)
TQFileInfo info;
info.setFile( inFileName );
@ -1801,10 +1801,10 @@ void RTFImport::parseField( RTFProperty * )
}
TQString format(regexp.cap(1));
kdDebug(30515) << "Date/time field format: " << format << endl;
format.tqreplace("am/pm", "ap");
format.tqreplace("a/p", "ap"); // Approximation
format.tqreplace("AM/PM", "AP");
format.tqreplace("A/P", "AP"); // Approximation
format.replace("am/pm", "ap");
format.replace("a/p", "ap"); // Approximation
format.replace("AM/PM", "AP");
format.replace("A/P", "AP"); // Approximation
format.remove("'"); // KWord 1.3 cannot protect text in date/time
addDateTime( format, (fieldName == "DATE"), fldfmt );
}
@ -2110,7 +2110,7 @@ void RTFImport::addFormat( DomNode &node, const KWFormat& format, const RTFForma
{
node.addNode( "FONT" );
if (fontTable.tqcontains( format.fmt.font ))
if (fontTable.contains( format.fmt.font ))
{
node.setAttribute( "name", fontTable[format.fmt.font] );
}
@ -2524,10 +2524,10 @@ void RTFImport::finishTable()
// ### TODO: use ConstIterator
for (uint k=0; k < row.cells.count(); k++)
{
if (!cellx.tqcontains( row.cells[k].x ))
if (!cellx.contains( row.cells[k].x ))
cellx << row.cells[k].x;
}
if (!cellx.tqcontains( row.left ))
if (!cellx.contains( row.left ))
{
cellx << row.left;
}
@ -2562,7 +2562,7 @@ void RTFImport::finishTable()
{
char buf[64];
int x2 = row.cells[k].x;
int col = cellx.tqfindIndex( x1 );
int col = cellx.findIndex( x1 );
sprintf( buf, "Table %d Cell %d,%d", textState->table, i, col );
frameSets.addFrameSet( buf, 1, 0 );
@ -2571,7 +2571,7 @@ void RTFImport::finishTable()
frameSets.setAttribute( "row", (int)i );
frameSets.setAttribute( "col", col );
frameSets.setAttribute( "rows", 1 );
frameSets.setAttribute( "cols", cellx.tqfindIndex( x2 ) - col );
frameSets.setAttribute( "cols", cellx.findIndex( x2 ) - col );
frameSets.addFrame( x1, y1, x2, y2, (row.height < 0) ? 2 : 0, 1, 0 );

@ -33,11 +33,11 @@ TQString CheckAndEscapeXmlText(const TQString& strText)
const int test = ch.tqunicode();
// The i+= is for the additional characters
if (test == 38) { strReturn.tqreplace(i, 1, "&amp;"); i+=4; } // &
else if (test == 60) { strReturn.tqreplace(i, 1, "&lt;"); i+=3; } // <
else if (test == 62) { strReturn.tqreplace(i, 1, "&gt;"); i+=3; } // >
else if (test == 34) { strReturn.tqreplace(i, 1, "&quot;"); i+=5; } // "
else if (test == 39) { strReturn.tqreplace(i, 1, "&apos;"); i+=5; } // '
if (test == 38) { strReturn.replace(i, 1, "&amp;"); i+=4; } // &
else if (test == 60) { strReturn.replace(i, 1, "&lt;"); i+=3; } // <
else if (test == 62) { strReturn.replace(i, 1, "&gt;"); i+=3; } // >
else if (test == 34) { strReturn.replace(i, 1, "&quot;"); i+=5; } // "
else if (test == 39) { strReturn.replace(i, 1, "&apos;"); i+=5; } // '
else if (test >= 32) continue; // Normal character (from space on)
else if ((test == 9) || (test == 10) || (test == 13) ) continue; // Allowed control characters: TAB, LF, CR
else
@ -47,7 +47,7 @@ TQString CheckAndEscapeXmlText(const TQString& strText)
// - could be not supported encoding.
// In any case, we must replace this character.
kdDebug(30515) << "Control character in XML stream: " << test << endl;
strReturn.tqreplace(i, 1, '?'); // Replacement character
strReturn.replace(i, 1, '?'); // Replacement character
}
}

@ -167,9 +167,9 @@ bool WMLConverter::doParagraph( TQString atext, WMLFormatList formatList,
// encode the text for XML-ness
text = atext;
text.tqreplace( '&', "&amp;" );
text.tqreplace( '<', "&lt;" );
text.tqreplace( '>', "&gt;" );
text.replace( '&', "&amp;" );
text.replace( '<', "&lt;" );
text.replace( '>', "&gt;" );
// formats, taken from formatList
WMLFormatList::iterator it;

@ -282,11 +282,11 @@ KWordFilter::parse (const TQString & filename)
// encode text for XML-ness
// FIXME could be faster without TQRegExp
text.tqreplace( TQRegExp("&"), "&amp;" );
text.tqreplace( TQRegExp("<"), "&lt;" );
text.tqreplace( TQRegExp(">"), "&gt;" );
text.tqreplace( TQRegExp("\""), "&quot;" );
text.tqreplace( TQRegExp("'"), "&apos;" );
text.replace( TQRegExp("&"), "&amp;" );
text.replace( TQRegExp("<"), "&lt;" );
text.replace( TQRegExp(">"), "&gt;" );
text.replace( TQRegExp("\""), "&quot;" );
text.replace( TQRegExp("'"), "&apos;" );
// construct the <PARAGRAPH>
root.append( "<PARAGRAPH>\n" );

@ -130,7 +130,7 @@ bool KLaola::enterDir(const OLENode *dirHandle) {
return false;
}
const KLaola::NodeList KLaola::tqfind(const TQString &name, bool onlyCurrentDir) {
const KLaola::NodeList KLaola::find(const TQString &name, bool onlyCurrentDir) {
OLENode *node;
NodeList ret;

@ -73,7 +73,7 @@ public:
NodeList parseRootDir();
NodeList parseCurrentDir();
const NodeList currentPath() const;
const NodeList tqfind(const TQString &name, bool onlyCurrentDir=false);
const NodeList find(const TQString &name, bool onlyCurrentDir=false);
bool enterDir(const OLENode *node);
bool leaveDir();

@ -226,7 +226,7 @@ void OLEFilter::slotSavePic(
if(nameIN.isEmpty())
return;
TQMap<TQString, TQString>::ConstIterator it = imageMap.tqfind(nameIN);
TQMap<TQString, TQString>::ConstIterator it = imageMap.find(nameIN);
if (it != imageMap.end())
// The key is already here - return the part id.
@ -284,7 +284,7 @@ void OLEFilter::slotGetStream(const TQString &name, myFile &stream) {
KLaola::NodeList handle;
handle=docfile->tqfind(name, true); // search only in current dir!
handle=docfile->find(name, true); // search only in current dir!
if (handle.count()==1)
stream=docfile->stream(handle.at(0));
@ -348,22 +348,22 @@ void OLEFilter::convert( const TQCString& mimeTypeHint )
myFile main;
KLaola::NodeList tmp;
tmp=docfile->tqfind("WordDocument", true);
tmp=docfile->find("WordDocument", true);
if(tmp.count()==1) {
// okay, not a dummy
main=docfile->stream(tmp.at(0));
myFile table0, table1, data;
tmp=docfile->tqfind("0Table", true);
tmp=docfile->find("0Table", true);
if(tmp.count()==1)
table0=docfile->stream(tmp.at(0));
tmp=docfile->tqfind("1Table", true);
tmp=docfile->find("1Table", true);
if(tmp.count()==1)
table1=docfile->stream(tmp.at(0));
tmp=docfile->tqfind("Data", true);
tmp=docfile->find("Data", true);
if(tmp.count()==1)
data=docfile->stream(tmp.at(0));
@ -380,11 +380,11 @@ void OLEFilter::convert( const TQCString& mimeTypeHint )
myFile workbook;
KLaola::NodeList tmp;
tmp = docfile->tqfind( "Workbook", true );
tmp = docfile->find( "Workbook", true );
if ( tmp.count() == 1 )
workbook = docfile->stream( tmp.at( 0 ) );
else {
tmp = docfile->tqfind( "Book", true );
tmp = docfile->find( "Book", true );
if ( tmp.count() == 1 )
workbook = docfile->stream( tmp.at( 0 ) );
}
@ -398,23 +398,23 @@ void OLEFilter::convert( const TQCString& mimeTypeHint )
myFile main, currentUser, pictures, summary, documentSummary;
KLaola::NodeList tmp;
tmp=docfile->tqfind("PowerPoint Document", true);
tmp=docfile->find("PowerPoint Document", true);
if(tmp.count()==1)
main=docfile->stream(tmp.at(0));
tmp=docfile->tqfind("Current User", true);
tmp=docfile->find("Current User", true);
if(tmp.count()==1)
currentUser=docfile->stream(tmp.at(0));
tmp=docfile->tqfind("Pictures", true);
tmp=docfile->find("Pictures", true);
if(tmp.count()==1)
pictures=docfile->stream(tmp.at(0));
tmp=docfile->tqfind("SummaryInformation", true);
tmp=docfile->find("SummaryInformation", true);
if(tmp.count()==1)
summary=docfile->stream(tmp.at(0));
tmp=docfile->tqfind("DocumentSummaryInformation", true);
tmp=docfile->find("DocumentSummaryInformation", true);
if(tmp.count()==1)
documentSummary=docfile->stream(tmp.at(0));
@ -426,7 +426,7 @@ void OLEFilter::convert( const TQCString& mimeTypeHint )
myFile prvText;
KLaola::NodeList tmp;
tmp = docfile->tqfind( "PrvText", true );
tmp = docfile->find( "PrvText", true );
if( tmp.count() == 1 ) prvText = docfile->stream( tmp.at( 0 ) );
myFilter = new HancomWordFilter( prvText );

@ -724,7 +724,7 @@ void Powerpoint::opPersistPtrIncrementalBlock(
// Create a record of this persistent reference.
if (m_persistentReferences.end() == m_persistentReferences.tqfind(reference))
if (m_persistentReferences.end() == m_persistentReferences.find(reference))
{
if(reference < 5)
{
@ -1287,7 +1287,7 @@ void Powerpoint::walkRecord(TQ_UINT32 mainStreamOffset)
void Powerpoint::walkReference(TQ_UINT32 reference)
{
if (m_persistentReferences.end() == m_persistentReferences.tqfind(reference))
if (m_persistentReferences.end() == m_persistentReferences.find(reference))
{
kdError(s_area) << "cannot find reference: " << reference << endl;
}

@ -64,15 +64,15 @@ void PptXml::encode(TQString &text)
// accidentally converting user text into one of the other escape
// sequences.
text.tqreplace('&', "&amp;");
text.tqreplace('<', "&lt;");
text.tqreplace('>', "&gt;"); // Needed to avoid ]]>
text.replace('&', "&amp;");
text.replace('<', "&lt;");
text.replace('>', "&gt;"); // Needed to avoid ]]>
// Strictly, there is no need to encode " or ', but we do so to allow
// them to co-exist!
text.tqreplace('"', "&quot;");
text.tqreplace('\'', "&apos;");
text.replace('"', "&quot;");
text.replace('\'', "&apos;");
}
const TQString PptXml::getXml() const

@ -97,7 +97,7 @@ XSLTExportDia::XSLTExportDia(KoStoreDevice* in, const TQCString &format, TQWidge
name = tempList.last();
tempList.pop_back();
kdDebug() << name << " " << file << endl;
if(!_namesList.tqcontains(name) && file == "main.xsl")
if(!_namesList.contains(name) && file == "main.xsl")
{
_filesList.append(file);
_namesList.append(name);
@ -210,7 +210,7 @@ void XSLTExportDia::okSlot()
TQString stylesheet = _currentFile.directory() + TQDir::separator() + _currentFile.fileName();
/* Add the current file in the recent list if is not and save the list. */
if(_recentList.tqcontains(stylesheet) == 0)
if(_recentList.contains(stylesheet) == 0)
{
kdDebug() << "Style sheet add to recent list" << endl;
/* Remove the older stylesheet used */

@ -92,7 +92,7 @@ XSLTImportDia::XSLTImportDia(KoStore* out, const TQCString &format, TQWidget* tq
name = tempList.last();
tempList.pop_back();
kdDebug() << name << " " << file << endl;
if(!_namesList.tqcontains(name) && file == "main.xsl")
if(!_namesList.contains(name) && file == "main.xsl")
{
_filesList.append(file);
_namesList.append(name);
@ -209,7 +209,7 @@ void XSLTImportDia::okSlot()
TQString stylesheet = _currentFile.directory() + "/" + _currentFile.fileName();
/* Add the current file in the recent list if is not and save the list. */
if(_recentList.tqcontains(stylesheet) == 0)
if(_recentList.contains(stylesheet) == 0)
{
kdDebug() << "Style sheet add to recent list" << endl;
/* Remove the older stylesheet used */

@ -82,7 +82,7 @@ VCommandHistory::addCommand( VCommand* command, bool execute )
}
m_commands.append( command );
kdDebug(38000) << "History: new command: " << m_commands.tqfindRef( command ) << endl;
kdDebug(38000) << "History: new command: " << m_commands.findRef( command ) << endl;
if( execute )
{
@ -176,7 +176,7 @@ VCommandHistory::redo()
void
VCommandHistory::undo( VCommand* command )
{
if( ( m_commands.tqfindRef( command ) == -1 ) || ( !command->success() ) )
if( ( m_commands.findRef( command ) == -1 ) || ( !command->success() ) )
return;
command->unexecute();
@ -192,7 +192,7 @@ VCommandHistory::undo( VCommand* command )
void
VCommandHistory::redo( VCommand* command )
{
if( ( m_commands.tqfindRef( command ) == -1 ) || ( command->success() ) )
if( ( m_commands.findRef( command ) == -1 ) || ( command->success() ) )
return;
command->execute();
@ -210,7 +210,7 @@ VCommandHistory::undoAllTo( VCommand* command )
{
int to;
if( ( to = m_commands.tqfindRef( command ) ) == -1 )
if( ( to = m_commands.findRef( command ) ) == -1 )
return;
int i = m_commands.count() - 1;
@ -239,7 +239,7 @@ VCommandHistory::redoAllTo( VCommand* command )
{
int to;
if( ( to = m_commands.tqfindRef( command ) ) == -1 )
if( ( to = m_commands.findRef( command ) ) == -1 )
return;
int i = 0;

@ -29,7 +29,7 @@ class VSelection;
/**
* VReplacingCmd is a generic command. Derive from it if you plan to do complex
* transformations upon selected objects which make it necessary to tqreplace
* transformations upon selected objects which make it necessary to replace
* each object as a whole with a new object.
*/

@ -264,7 +264,7 @@ bool
VPath::pointIsInside( const KoPoint& p ) const
{
// Check if point is inside boundingbox.
if( !boundingBox().tqcontains( p ) )
if( !boundingBox().contains( p ) )
return false;
@ -422,7 +422,7 @@ VPath::transformByViewbox( const TQDomElement &element, TQString viewbox )
if( ! viewbox.isEmpty() )
{
// allow for viewbox def with ',' or whitespace
TQStringList points = TQStringList::split( ' ', viewbox.tqreplace( ',', ' ' ).simplifyWhiteSpace() );
TQStringList points = TQStringList::split( ' ', viewbox.replace( ',', ' ' ).simplifyWhiteSpace() );
double w = KoUnit::parseValue( element.attributeNS( KoXmlNS::svg, "width", TQString() ) );
double h = KoUnit::parseValue( element.attributeNS( KoXmlNS::svg, "height", TQString() ) );

@ -151,20 +151,20 @@ VDocument::removeLayer( VLayer* layer )
bool VDocument::canRaiseLayer( VLayer* layer )
{
int pos = m_layers.tqfind( layer );
int pos = m_layers.find( layer );
return (pos != int( m_layers.count() ) - 1 && pos >= 0 );
}
bool VDocument::canLowerLayer( VLayer* layer )
{
int pos = m_layers.tqfind( layer );
int pos = m_layers.find( layer );
return (pos>0);
}
void
VDocument::raiseLayer( VLayer* layer )
{
int pos = m_layers.tqfind( layer );
int pos = m_layers.find( layer );
if( pos != int( m_layers.count() ) - 1 && pos >= 0 )
{
VLayer* layer = m_layers.take( pos );
@ -175,7 +175,7 @@ VDocument::raiseLayer( VLayer* layer )
void
VDocument::lowerLayer( VLayer* layer )
{
int pos = m_layers.tqfind( layer );
int pos = m_layers.find( layer );
if ( pos > 0 )
{
VLayer* layer = m_layers.take( pos );
@ -186,13 +186,13 @@ VDocument::lowerLayer( VLayer* layer )
int
VDocument::layerPos( VLayer* layer )
{
return m_layers.tqfind( layer );
return m_layers.find( layer );
} // VDocument::layerPos
void
VDocument::setActiveLayer( VLayer* layer )
{
if ( m_layers.tqfind( layer ) != -1 )
if ( m_layers.find( layer ) != -1 )
m_activeLayer = layer;
} // VDocument::setActiveLayer
@ -318,6 +318,6 @@ VDocument::accept( VVisitor& visitor )
TQString
VDocument::objectName( const VObject *obj ) const
{
TQMap<const VObject *, TQString>::ConstIterator it = m_objectNames.tqfind( obj );
TQMap<const VObject *, TQString>::ConstIterator it = m_objectNames.find( obj );
return it == m_objectNames.end() ? 0L : it.data();
}

@ -383,7 +383,7 @@ VGroup::insertInfrontOf( VObject* newObject, VObject* oldObject )
{
newObject->setParent( this );
m_objects.insert( m_objects.tqfind( oldObject ), newObject );
m_objects.insert( m_objects.find( oldObject ), newObject );
invalidateBoundingBox();
}

@ -111,7 +111,7 @@ VLayer::downwards( const VObject& object )
{
if( m_objects.getFirst() == &object ) return;
int index = m_objects.tqfind( &object );
int index = m_objects.find( &object );
bool bLast = m_objects.getLast() == &object;
m_objects.remove( index );

@ -416,7 +416,7 @@ bool
VSubpath::pointIsInside( const KoPoint& p ) const
{
// If the point is not inside the boundingbox, it cannot be inside the path either.
if( !boundingBox().tqcontains( p ) )
if( !boundingBox().contains( p ) )
return false;
// First check if the point is inside the knot polygon (beziers are treated

@ -135,7 +135,7 @@ VSelection::append( VObject* object )
// only append if item is not deleted or not already in list
if( object->state() != deleted )
{
if( ! m_objects.tqcontainsRef( object ) )
if( ! m_objects.containsRef( object ) )
m_objects.append( object );
object->setState( selected );
invalidateBoundingBox();
@ -295,7 +295,7 @@ VSelection::handleNode( const KoPoint &point ) const
{
for( uint i = node_lt; i <= node_rb; ++i )
{
if( m_handleRect[i].tqcontains( point ) )
if( m_handleRect[i].contains( point ) )
return static_cast<VHandleNode>( i );
}

@ -660,7 +660,7 @@ VText::buildRequest( TQString family, int weight, int slant, double size, int &i
{
// Strip those stupid [Xft or whatever]...
int pos;
if( ( pos = family.tqfind( '[' ) ) )
if( ( pos = family.find( '[' ) ) )
family = family.left( pos );
// Use FontConfig to locate & select fonts and use FreeType2 to open them

@ -110,7 +110,7 @@ VDocumentPreview::eventFilter( TQObject* object, TQEvent* event )
m_lastPoint = m_firstPoint;
KoPoint p3( m_firstPoint.x() / scaleFactor - xoffset,
( height() - m_firstPoint.y() ) / scaleFactor - yoffset );
m_dragging = rect.tqcontains( p3 );
m_dragging = rect.contains( p3 );
}
else if( event->type() == TQEvent::MouseButtonRelease )
{
@ -144,7 +144,7 @@ VDocumentPreview::eventFilter( TQObject* object, TQEvent* event )
{
KoPoint p3( mouseEvent->pos().x() / scaleFactor - xoffset,
( height() - mouseEvent->pos().y() ) / scaleFactor - yoffset );
setCursor( rect.tqcontains( p3 ) ? TQCursor::SizeAllCursor : TQCursor( TQt::arrowCursor ) );
setCursor( rect.contains( p3 ) ? TQCursor::SizeAllCursor : TQCursor( TQt::arrowCursor ) );
}
}
@ -1014,7 +1014,7 @@ VLayersTab::removeDeletedObjectsFromList()
{
VGroup *group = dynamic_cast<VGroup*>( layerItem->layer() );
// check if object of item is still child of object of tqparent item
if( group && ! group->objects().tqcontains( it.current()->object() ) )
if( group && ! group->objects().contains( it.current()->object() ) )
{
layerItem->takeItem( it.current() );
delete it.current();
@ -1028,7 +1028,7 @@ VLayersTab::removeDeletedObjectsFromList()
{
VGroup *group = dynamic_cast<VGroup*>( objectItem->object() );
// check if object of item is still child of object of tqparent item
if( group && ! group->objects().tqcontains( it.current()->object() ) )
if( group && ! group->objects().contains( it.current()->object() ) )
{
objectItem->takeItem( it.current() );
delete it.current();

@ -102,7 +102,7 @@ VRoundCornersCmd::visitVSubpath( VSubpath& path )
return;
// Note: we modiy segments from path. that doesn't hurt, since we
// tqreplace "path" with the temporary path "newPath" afterwards.
// replace "path" with the temporary path "newPath" afterwards.
VSubpath newPath( 0L );

@ -293,25 +293,25 @@ VKoPainter::fillPath()
if( m_index == 0 ) return;
// find begin of last subpath
int tqfind = -1;
int find = -1;
for( int i = m_index - 1; i >= 0; i-- )
{
if( m_path[i].code == ART_MOVETO_OPEN || m_path[i].code == ART_MOVETO )
{
tqfind = i;
find = i;
break;
}
}
// for now, always close
if( tqfind != -1 && ( m_path[ tqfind ].x3 != m_path[ m_index - 1 ].x3 ||
m_path[ tqfind ].y3 != m_path[ m_index - 1 ].y3 ) )
if( find != -1 && ( m_path[ find ].x3 != m_path[ m_index - 1 ].x3 ||
m_path[ find ].y3 != m_path[ m_index - 1 ].y3 ) )
{
ensureSpace( m_index + 1 );
m_path[ m_index ].code = ART_LINETO;
m_path[ m_index ].x3 = m_path[ tqfind ].x3;
m_path[ m_index ].y3 = m_path[ tqfind ].y3;
m_path[ m_index ].x3 = m_path[ find ].x3;
m_path[ m_index ].y3 = m_path[ find ].y3;
m_index++;
m_path[ m_index ].code = ART_END;

@ -48,7 +48,7 @@ VPolygon::init()
bool bFirst = true;
TQString points = m_points.simplifyWhiteSpace();
points.tqreplace( ',', ' ' );
points.replace( ',', ' ' );
points.remove( '\r' );
points.remove( '\n' );
TQStringList pointList = TQStringList::split( ' ', points );

@ -52,7 +52,7 @@ VPolyline::init()
bool bFirst = true;
TQString points = m_points.simplifyWhiteSpace();
points.tqreplace( ',', ' ' );
points.replace( ',', ' ' );
points.remove( '\r' );
points.remove( '\n' );
TQStringList pointList = TQStringList::split( ' ', points );

@ -425,7 +425,7 @@ static double NewtonRaphsonRootFind(KoPoint *Q,KoPoint P,double u)
/*
* Reparameterize:
* Given set of points and their parameterization, try to tqfind
* Given set of points and their parameterization, try to find
* a better parameterization.
*
*/

@ -289,16 +289,16 @@ VGradientTool::mouseButtonPress()
m_current = first();
// set the apropriate editing state
if( m_center.tqcontains( m_current ) && shiftPressed())
if( m_center.contains( m_current ) && shiftPressed())
{
m_state = moveCenter;
}
else if( m_origin.tqcontains( m_current ) )
else if( m_origin.contains( m_current ) )
{
m_state = moveOrigin;
m_fixed = m_vector.center();
}
else if( m_vector.tqcontains( m_current ) )
else if( m_vector.contains( m_current ) )
{
m_state = moveVector;
m_fixed = m_origin.center();
@ -489,7 +489,7 @@ VGradientTool::setCursor() const
if( !view() ) return;
// set a different cursor if mouse is inside the handle rects
if( m_origin.tqcontains( last() ) || m_vector.tqcontains( last() ) || m_center.tqcontains( last() ) )
if( m_origin.contains( last() ) || m_vector.contains( last() ) || m_center.contains( last() ) )
view()->setCursor( TQCursor( TQt::SizeAllCursor ) );
else
view()->setCursor( TQCursor( TQt::arrowCursor ) );

@ -300,12 +300,12 @@ VPatternTool::mouseButtonPress()
m_current = first();
// set the apropriate editing state
if( m_origin.tqcontains( m_current ) )
if( m_origin.contains( m_current ) )
{
m_state = moveOrigin;
m_fixed = m_vector.center();
}
else if( m_vector.tqcontains( m_current ) )
else if( m_vector.contains( m_current ) )
{
m_state = moveVector;
m_fixed = m_origin.center();
@ -472,7 +472,7 @@ VPatternTool::setCursor() const
if( !view() ) return;
// set a different cursor if mouse is inside the handle rects
if( m_origin.tqcontains( last() ) || m_vector.tqcontains( last() ) )
if( m_origin.contains( last() ) || m_vector.contains( last() ) )
view()->setCursor( TQCursor( TQt::SizeAllCursor ) );
else
view()->setCursor( TQCursor( TQt::arrowCursor ) );

@ -120,7 +120,7 @@ VSelectNodesTool::setCursor() const
{
VSegment* seg = segments.at( 0 );
for( int i = 0; i < seg->degree(); ++i )
if( seg->pointIsSelected( i ) && selrect.tqcontains( seg->point( i ) ) )
if( seg->pointIsSelected( i ) && selrect.contains( seg->point( i ) ) )
{
view()->setCursor( VCursor::needleMoveArrow() );
break;
@ -158,16 +158,16 @@ VSelectNodesTool::mouseButtonPress()
// allow moving bezier points only if one of the bezier points is within the selection rect
// and no neighboring knot is selected
if( segments.count() == 1 && ! selrect.tqcontains( seg->knot() ) && ! seg->knotIsSelected()
if( segments.count() == 1 && ! selrect.contains( seg->knot() ) && ! seg->knotIsSelected()
&& ( prev && ! prev->knotIsSelected() ) )
{
if( selrect.tqcontains( seg->point( 1 ) ) )
if( selrect.contains( seg->point( 1 ) ) )
{
m_state = movingbezier1;
if( next )
next->selectPoint( 0, false );
}
else if( selrect.tqcontains( seg->point( 0 ) ) )
else if( selrect.contains( seg->point( 0 ) ) )
{
m_state = movingbezier2;
if( prev )
@ -180,7 +180,7 @@ VSelectNodesTool::mouseButtonPress()
{
for( int i = 0; i < seg->degree(); ++i )
{
if( seg->pointIsSelected( i ) && selrect.tqcontains( seg->point( i ) ) )
if( seg->pointIsSelected( i ) && selrect.contains( seg->point( i ) ) )
{
m_state = moving;
break;
@ -197,7 +197,7 @@ VSelectNodesTool::mouseButtonPress()
{
for( int i = 0; i < seg->degree(); ++i )
{
if( selrect.tqcontains( seg->point( i ) ) )
if( selrect.contains( seg->point( i ) ) )
{
KoPoint vDist = seg->point( i ) - m_current;
double dist = vDist.x()*vDist.x() + vDist.y()*vDist.y();

@ -183,7 +183,7 @@ VSelectTool::mouseButtonPress()
if( m_activeNode != node_none )
m_state = scaling;
else if( rect.tqcontains( m_current ) && m_state == normal )
else if( rect.contains( m_current ) && m_state == normal )
m_state = moving;
recalc();
@ -274,7 +274,7 @@ VSelectTool::mouseButtonRelease()
VObjectListIterator it( newSelection );
for( ; it.current(); ++it )
{
if( oldSelection.tqcontains( it.current() ) )
if( oldSelection.contains( it.current() ) )
lastMatched = it.current();
}
@ -282,7 +282,7 @@ VSelectTool::mouseButtonRelease()
// - none is selected
// - the stack's bottom object was the last selected object
if( lastMatched && lastMatched != newSelection.first() )
view()->part()->document().selection()->append( newSelection.at( newSelection.tqfind( lastMatched )-1 ) );
view()->part()->document().selection()->append( newSelection.at( newSelection.find( lastMatched )-1 ) );
else
view()->part()->document().selection()->append( newSelection.last() );
}

@ -678,7 +678,7 @@ VTextTool::mouseButtonRelease()
VObject* selObj = selection->objects().getFirst();
// initialize dialog with single selected object
if( selection->objects().count() == 1 && selObj->boundingBox().tqcontains( last() ) )
if( selection->objects().count() == 1 && selObj->boundingBox().contains( last() ) )
m_optionsWidget->initialize( *selObj );
else
{
@ -691,7 +691,7 @@ VTextTool::mouseButtonRelease()
return;
}
if( dynamic_cast<VText*>( selObj ) && selObj->boundingBox().tqcontains( last() ) )
if( dynamic_cast<VText*>( selObj ) && selObj->boundingBox().contains( last() ) )
m_optionsWidget->setCaption( i18n( "Change Text") );
else
m_optionsWidget->setCaption( i18n( "Insert Text") );

@ -54,7 +54,7 @@ VSelectNodes::visitVSubpath( VSubpath& path )
// select all control points inside the selection rect
for( int i = 0; i < curr->degree()-1; ++i )
{
if( m_rect.tqcontains( curr->point( i ) ) )
if( m_rect.contains( curr->point( i ) ) )
{
curr->selectPoint( i, m_select );
setSuccess();
@ -81,7 +81,7 @@ VSelectNodes::visitVSubpath( VSubpath& path )
}
}
if( m_rect.tqcontains( curr->knot() ) )
if( m_rect.contains( curr->knot() ) )
{
curr->selectKnot( m_select );
// select the last control point before the knot, if segment is curve
@ -122,7 +122,7 @@ VTestNodes::visitVSubpath( VSubpath& path )
while( path.current() )
{
for( int i = 0; i < path.current()->degree(); i++ )
if( m_rect.tqcontains( path.current()->point( i ) ) ) //&&
if( m_rect.contains( path.current()->point( i ) ) ) //&&
//path.current()->pointIsSelected( i ) )
{
m_segments.append( path.current() );

@ -44,7 +44,7 @@ VSelectObjects::visitVPath( VPath& composite )
{
// Check if composite is completely inside the selection rectangle.
// This test should be the first test since it's the less expensive one.
if( m_rect.tqcontains( composite.boundingBox() ) )
if( m_rect.contains( composite.boundingBox() ) )
{
selected = true;
}
@ -117,7 +117,7 @@ VSelectObjects::visitVPath( VPath& composite )
if( m_select )
{
composite.setState( VObject::selected );
if( ! m_selection.tqcontainsRef( &composite ) )
if( ! m_selection.containsRef( &composite ) )
m_selection.append( &composite );
}
else
@ -148,7 +148,7 @@ VSelectObjects::visitVObject( VObject& object )
if( m_rect.intersects( object.boundingBox() ) )
{
object.setState( VObject::selected );
if( ! m_selection.tqcontainsRef( &object ) )
if( ! m_selection.containsRef( &object ) )
m_selection.append( &object );
setSuccess();
}
@ -168,7 +168,7 @@ VSelectObjects::visitVObject( VObject& object )
if( m_select )
{
object.setState( VObject::selected );
if( ! m_selection.tqcontainsRef( &object ) )
if( ! m_selection.containsRef( &object ) )
m_selection.append( &object );
setSuccess();
}
@ -183,12 +183,12 @@ VSelectObjects::visitVObject( VObject& object )
// selection by point
else
{
if( object.boundingBox().tqcontains( m_point ) )
if( object.boundingBox().contains( m_point ) )
{
if( m_select )
{
object.setState( VObject::selected );
if( ! m_selection.tqcontainsRef( &object ) )
if( ! m_selection.containsRef( &object ) )
m_selection.append( &object );
}
else
@ -239,7 +239,7 @@ VSelectObjects::visitVText( VText& text )
kdDebug(38000) << "selected: " << itr.current() << endl;
m_selection.remove( &c );
text.setState( VObject::selected );
if( ! m_selection.tqcontainsRef( &text ) )
if( ! m_selection.containsRef( &text ) )
m_selection.append( &text );
return;
}

@ -65,7 +65,7 @@ VToolController::setCurrentTool( VTool *tool )
void
VToolController::registerTool( VTool *tool )
{
if( !m_tools.tqfind( tool->name() ) )
if( !m_tools.find( tool->name() ) )
m_tools.insert( tool->name(), tool );
//kdDebug(38000) << "active tool : " << m_currentTool->name() << endl;
}

@ -174,7 +174,7 @@ void VGradientWidget::paintEvent( TQPaintEvent* )
void VGradientWidget::mousePressEvent( TQMouseEvent* e )
{
if( ! m_pntArea.tqcontains( e->x(), e->y() ) )
if( ! m_pntArea.contains( e->x(), e->y() ) )
return;
TQPtrList<VColorStop>& colorStops = m_gradient->m_colorStops;
@ -217,7 +217,7 @@ void VGradientWidget::mouseReleaseEvent( TQMouseEvent* e )
{
if( e->button() == Qt::RightButton && currentPoint )
{
if( m_pntArea.tqcontains( e->x(), e->y() ) && ( currentPoint % 2 == 1 ) )
if( m_pntArea.contains( e->x(), e->y() ) && ( currentPoint % 2 == 1 ) )
{
int x = e->x() - m_pntArea.left();
// check if we are still above the actual ramp point
@ -235,7 +235,7 @@ void VGradientWidget::mouseReleaseEvent( TQMouseEvent* e )
void VGradientWidget::mouseDoubleClickEvent( TQMouseEvent* e )
{
if( ! m_pntArea.tqcontains( e->x(), e->y() ) )
if( ! m_pntArea.contains( e->x(), e->y() ) )
return;
if( e->button() != Qt::LeftButton )

@ -378,7 +378,7 @@ void CSVImportDialog::fillTable( )
for (column = 0; column < m_dialog->m_sheet->numCols(); ++column)
{
const TQString header = m_dialog->m_sheet->horizontalHeader()->label(column);
if ( m_formatList.tqfind( header ) == m_formatList.end() )
if ( m_formatList.find( header ) == m_formatList.end() )
m_dialog->m_sheet->horizontalHeader()->setLabel(column, i18n("Text"));
m_dialog->m_sheet->adjustColumn(column);

@ -194,19 +194,19 @@ void KChartBackgroundPixmapConfigPage::loadWallpaperFilesList()
if (imageCaption.isEmpty())
{
imageCaption = fileName;
imageCaption.tqreplace('_', ' ');
imageCaption.replace('_', ' ');
imageCaption = KStringHandler::capwords(imageCaption);
}
// avoid name collisions
TQString rs = imageCaption;
TQString lrs = rs.lower();
for (int n = 1; papers.tqfind(lrs) != papers.end(); ++n)
for (int n = 1; papers.find(lrs) != papers.end(); ++n)
{
rs = imageCaption + " (" + TQString::number(n) + ')';
lrs = rs.lower();
}
int slash = (*it).tqfindRev('/') + 1;
int slash = (*it).findRev('/') + 1;
TQString directory = (*it).left(slash);
bool canLoadScaleable = false;
#ifdef HAVE_LIBART
@ -233,8 +233,8 @@ void KChartBackgroundPixmapConfigPage::loadWallpaperFilesList()
if (imageCaption.isEmpty())
{
int slash = (*it).tqfindRev('/') + 1;
int endDot = (*it).tqfindRev('.');
int slash = (*it).findRev('/') + 1;
int endDot = (*it).findRev('.');
// strip the extension if it exists
if (endDot != -1 && endDot > slash)
@ -242,14 +242,14 @@ void KChartBackgroundPixmapConfigPage::loadWallpaperFilesList()
else
imageCaption = (*it).mid(slash);
imageCaption.tqreplace('_', ' ');
imageCaption.replace('_', ' ');
imageCaption = KStringHandler::capwords(imageCaption);
}
// avoid name collisions
TQString rs = imageCaption;
TQString lrs = rs.lower();
for (int n = 1; papers.tqfind(lrs) != papers.end(); ++n)
for (int n = 1; papers.find(lrs) != papers.end(); ++n)
{
rs = imageCaption + " (" + TQString::number(n) + ')';
lrs = rs.lower();
@ -455,12 +455,12 @@ void KChartBackgroundPixmapConfigPage::showSettings( const TQString& fileName )
{
wallCB->blockSignals(true);
if (m_wallpaper.tqfind(fileName) == m_wallpaper.end())
if (m_wallpaper.find(fileName) == m_wallpaper.end())
{
int i = wallCB->count();
TQString imageCaption;
int slash = fileName.tqfindRev('/') + 1;
int endDot = fileName.tqfindRev('.');
int slash = fileName.findRev('/') + 1;
int endDot = fileName.findRev('.');
// strip the extension if it exists
if (endDot != -1 && endDot > slash)

@ -73,7 +73,7 @@ KChartWizardSelectChartTypePage::KChartWizardSelectChartTypePage( TQWidget* tqpa
addButton( i18n( "Ring" ), "chart_ring", KChartParams::Ring );
addButton( i18n( "Polar" ), "chart_polar", KChartParams::Polar);
TQPushButton *current = ((TQPushButton*)m_typeBG->tqfind( m_chart->params()->chartType() ));
TQPushButton *current = ((TQPushButton*)m_typeBG->find( m_chart->params()->chartType() ));
if (current != NULL) {
current->setOn( true );
}

@ -58,7 +58,7 @@
\brief Provides a single entry-point to the charting engine for
applications that wish to provide their own TQPainter.
It is not useful to instantiate this class as it tqcontains
It is not useful to instantiate this class as it contains
static methods only.
\note If for some reason you are NOT using the

@ -43,7 +43,7 @@
\brief Definition of a single entry-point to the charting engine for
applications that wish to provide their own TQPainter.
It is not useful to instantiate the KDChart class as it only tqcontains
It is not useful to instantiate the KDChart class as it only contains
static methods.
*/

@ -2479,7 +2479,7 @@ void KDChartAxesPainter::calculateLabelTexts(
modf( ddelta, &ddelta );
bool positive = ( 0.0 <= ddelta );
int delta = static_cast < int > ( fabs( ddelta ) );
// tqfind 1st significant entry
// find 1st significant entry
TQStringList::Iterator it = positive
? tmpList.begin()
: tmpList.fromLast();
@ -3663,7 +3663,7 @@ TQString KDChartAxesPainter::truncateBehindComma( const double nVal,
//qDebug("nVal: %f sVal: "+sVal, nVal );
//qDebug( TQString(" %1").tqarg(sVal));
if ( bUseAutoDigits ) {
int comma = sVal.tqfind( '.' );
int comma = sVal.find( '.' );
if ( -1 < comma ) {
if ( bAutoDelta ) {
int i = sVal.length();
@ -3684,7 +3684,7 @@ TQString KDChartAxesPainter::truncateBehindComma( const double nVal,
if ( '.' == sDelta[ i - 1 ] )
trueBehindComma = 0;
else {
int deltaComma = sDelta.tqfind( '.' );
int deltaComma = sDelta.find( '.' );
if ( -1 < deltaComma )
trueBehindComma = sDelta.length() - deltaComma - 1;
else
@ -3753,9 +3753,9 @@ TQString KDChartAxesPainter::applyLabelsFormat( const double nVal_,
trueBehindComma );
//qDebug("sVal : "+sVal+" behindComma: %i",behindComma);
int posComma = sVal.tqfind( '.' );
int posComma = sVal.find( '.' );
if( 0 <= posComma ){
sVal.tqreplace( posComma, 1, decimalPoint);
sVal.replace( posComma, 1, decimalPoint);
}else{
posComma = sVal.length();
}
@ -3795,7 +3795,7 @@ TQString KDChartAxesPainter::applyLabelsFormat( const double nVal_,
*and the user has set axisLabelsDigitsBehindComma() == 0
*return an empty string
*/
if ( behindComma == 0 && TQString::number(nVal).tqfind('.') > 0 )
if ( behindComma == 0 && TQString::number(nVal).find('.') > 0 )
sVal = TQString();//sVal = "";
return sVal;
}
@ -3854,7 +3854,7 @@ void KDChartAxesPainter::calculateOrdinateFactors(
if ( 100.0 > nDist )
nDivisor = 1.0;
else {
int comma = sDistDigis2.tqfind( '.' );
int comma = sDistDigis2.find( '.' );
if ( -1 < comma )
sDistDigis2.truncate( comma );
nDivisor = fastPow10( (int)sDistDigis2.length() - 2 );

@ -1933,7 +1933,7 @@ void KDChartAxisParams::setAxisValues( bool axisSteadyValueCalc,
with the next value lower than your start value that can be
divided by the delta factor.
\param isExactValue set this to FALSE if KD Chart shall tqfind
\param isExactValue set this to FALSE if KD Chart shall find
a better value than the one you have specified by setAxisValueStart()
\sa setAxisValues, setAxisValueEnd, setAxisValueDelta
\sa axisValueStartIsExact, axisValueStart
@ -2401,7 +2401,7 @@ void KDChartAxisParams::setAxisDtHighPos( double x, double y )
\note Calling this function results in overwriting the information
that you might have set by previous calls of that function.
Only <b>one</b> data row can be specified as containing label texts.
To specify a data row that tqcontains (or might contain) axis label texts just
To specify a data row that contains (or might contain) axis label texts just
call this function with \c LabelsFromDataRowYes (or \c LabelsFromDataRowGuess,
resp.) specifying this row but do <b>not</b> call the function n times with
the \c LabelsFromDataRowNo parameter to 'deactivate' the other rows.
@ -2409,7 +2409,7 @@ void KDChartAxisParams::setAxisDtHighPos( double x, double y )
the data rows is containing the axis label texts (this is the default
setting).