author | ar <ar> | 2004-05-21 20:54:44 (UTC) |
---|---|---|
committer | ar <ar> | 2004-05-21 20:54:44 (UTC) |
commit | 37294c41a902eab36427372bdda31b4462fd73ca (patch) (side-by-side diff) | |
tree | e86f2a473ac0854b451577871603a2d4f94f8f45 /noncore/styles/theme/ogfxeffect.cpp | |
parent | d0a66ef7432056016ed637597ca24e85e7bc2503 (diff) | |
download | opie-37294c41a902eab36427372bdda31b4462fd73ca.zip opie-37294c41a902eab36427372bdda31b4462fd73ca.tar.gz opie-37294c41a902eab36427372bdda31b4462fd73ca.tar.bz2 |
- convert qDebug to odebug
Diffstat (limited to 'noncore/styles/theme/ogfxeffect.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/styles/theme/ogfxeffect.cpp | 72 |
1 files changed, 38 insertions, 34 deletions
diff --git a/noncore/styles/theme/ogfxeffect.cpp b/noncore/styles/theme/ogfxeffect.cpp index 90b45fe..ab63c98 100644 --- a/noncore/styles/theme/ogfxeffect.cpp +++ b/noncore/styles/theme/ogfxeffect.cpp @@ -9,9 +9,13 @@ -#include <qimage.h> -#include <qpainter.h> +#include "ogfxeffect.h" +/* OPIE */ +#include <opie2/odebug.h> #include <qpe/qmath.h> -#include "ogfxeffect.h" +/* QT */ +#include <qimage.h> +#include <qpainter.h> +/* STD */ #include <cstdlib> @@ -27,9 +31,9 @@ QPixmap& OGfxEffect::gradient(QPixmap &pixmap, const QColor &ca, - const QColor &cb, GradientType eff, int ncols) + const QColor &cb, GradientType eff, int ncols) { - if ( !pixmap. isNull ( )) { - QImage image = gradient(pixmap.size(), ca, cb, eff, ncols); - pixmap.convertFromImage(image); - } - return pixmap; + if ( !pixmap. isNull ( )) { + QImage image = gradient(pixmap.size(), ca, cb, eff, ncols); + pixmap.convertFromImage(image); + } + return pixmap; } @@ -38,12 +42,12 @@ QImage OGfxEffect::gradient(const QSize &size, const QColor &ca, const QColor &cb, GradientType eff, int /*ncols*/) -{ - int rDiff, gDiff, bDiff; - int rca, gca, bca, rcb, gcb, bcb; - - QImage image(size, 32); +{ + int rDiff, gDiff, bDiff; + int rca, gca, bca, rcb, gcb, bcb; - if (size.width() == 0 || size.height() == 0) { - qDebug ( "WARNING: OGfxEffect::gradient: invalid image" ); - return image; - } + QImage image(size, 32); + + if (size.width() == 0 || size.height() == 0) { + odebug << "WARNING: OGfxEffect::gradient: invalid image" << oendl; + return image; + } @@ -280,15 +284,15 @@ QImage OGfxEffect::gradient(const QSize &size, const QColor &ca, QPixmap& OGfxEffect::blend(QPixmap &pixmap, float initial_intensity, - const QColor &bgnd, GradientType eff, - bool anti_dir, int /*ncols*/) + const QColor &bgnd, GradientType eff, + bool anti_dir, int /*ncols*/) { - if ( !pixmap. isNull ( )) { - QImage image = pixmap.convertToImage(); - OGfxEffect::blend(image, initial_intensity, bgnd, eff, anti_dir); + if ( !pixmap. isNull ( )) { + QImage image = pixmap.convertToImage(); + OGfxEffect::blend(image, initial_intensity, bgnd, eff, anti_dir); - if ( pixmap. depth ( ) <= 8 ) - image. convertDepth ( pixmap. depth ( )); + if ( pixmap. depth ( ) <= 8 ) + image. convertDepth ( pixmap. depth ( )); - pixmap.convertFromImage(image); - } - return pixmap; + pixmap.convertFromImage(image); + } + return pixmap; } @@ -301,3 +305,3 @@ QImage& OGfxEffect::blend(QImage &image, float initial_intensity, if (image.width() == 0 || image.height() == 0) { - qDebug ( "Invalid image\n" ); + odebug << "Invalid image" << oendl; return image; @@ -486,4 +490,4 @@ QImage& OGfxEffect::blend(QImage &image, float initial_intensity, - else - qDebug ( "not implemented\n" ); + else + odebug << "not implemented" << oendl; @@ -496,3 +500,3 @@ QImage& OGfxEffect::blend(QImage &image, float initial_intensity, QImage& KQGfxEffect::blend(QImage &image1, QImage &image2, - GradientType gt, int xf, int yf) + GradientType gt, int xf, int yf) { @@ -505,4 +509,4 @@ QImage& KQGfxEffect::blend(QImage &image1, QImage &image2, image3 = KQGfxEffect::unbalancedGradient(image1.size(), - QColor(0,0,0), QColor(255,255,255), - gt, xf, yf, 0); + QColor(0,0,0), QColor(255,255,255), + gt, xf, yf, 0); |