diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-19 19:03:33 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-19 19:03:33 +0000 |
commit | e69e8b1d09fb579316595b4e6a850e717358a8b1 (patch) | |
tree | a24fc20865f65772f530d16177520190594ffdd2 /kcoloredit/palette.cpp | |
parent | eecec9afb81fdebb0f22e9da22635874c403f854 (diff) | |
download | tdegraphics-e69e8b1d09fb579316595b4e6a850e717358a8b1.tar.gz tdegraphics-e69e8b1d09fb579316595b4e6a850e717358a8b1.zip |
TQt4 port kdegraphics
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegraphics@1237557 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kcoloredit/palette.cpp')
-rw-r--r-- | kcoloredit/palette.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/kcoloredit/palette.cpp b/kcoloredit/palette.cpp index 42758b41..6f830278 100644 --- a/kcoloredit/palette.cpp +++ b/kcoloredit/palette.cpp @@ -108,14 +108,14 @@ bool Palette::load(TQTextStream& stream, bool loadName /* = true */) { int lineNum = 0; while (!stream.atEnd()) { TQString string = stream.readLine().append(' '); - if(string.find( TQRegExp("[^\\s]") ) == -1 || + if(string.tqfind( TQRegExp("[^\\s]") ) == -1 || string.stripWhiteSpace().at( 0 ) == '#' || ( loadName && lineNum == 0 )) { if(loadName && lineNum == 0) setName(string.stripWhiteSpace()); } else { Color* newColor = new Color(); - int position = string.find(TQRegExp( "[^\\s]" )); + int position = string.tqfind(TQRegExp( "[^\\s]" )); for(int componentIndex = 0; componentIndex < Color::COMPONENTS_NUM; ++componentIndex) { if(position == -1) { @@ -123,7 +123,7 @@ bool Palette::load(TQTextStream& stream, bool loadName /* = true */) { result = false; break; } - int endPosition = string.find(TQRegExp( "\\s" ), position); + int endPosition = string.tqfind(TQRegExp( "\\s" ), position); if(endPosition == -1) { m_errorString = i18n("Invalid format"); result = false; @@ -139,7 +139,7 @@ bool Palette::load(TQTextStream& stream, bool loadName /* = true */) { break; } newColor->setComponent(componentIndex, componentValue); - position = string.find(TQRegExp( "[^\\s]" ), endPosition); + position = string.tqfind(TQRegExp( "[^\\s]" ), endPosition); } if(!result) { delete newColor; |