• Skip to content
  • Skip to link menu
KDE 3.5 API Reference
  • KDE API Reference
  • API Reference
  • Sitemap
  • Contact Us
 

kdefx

kpixmapeffect.h

Go to the documentation of this file.
00001 /* This file is part of the KDE libraries
00002     Copyright (C) 1998, 1999 Christian Tibirna <ctibirna@total.net>
00003               (C) 1998, 1999 Daniel M. Duley <mosfet@kde.org>
00004               (C) 1998, 1999 Dirk Mueller <mueller@kde.org>
00005 
00006 */
00007 
00008 // $Id: kpixmapeffect.h 399215 2005-03-20 14:33:45Z mueller $
00009 
00010 #ifndef __KPIXMAP_EFFECT_H
00011 #define __KPIXMAP_EFFECT_H
00012 
00013 #include <kdelibs_export.h>
00014 
00015 #include <qsize.h>
00016 class KPixmap;
00017 class QColor;
00018 
00027 class KDEFX_EXPORT KPixmapEffect
00028 {
00029 public:
00030     enum GradientType { VerticalGradient, HorizontalGradient,
00031             DiagonalGradient, CrossDiagonalGradient,
00032             PyramidGradient, RectangleGradient,
00033             PipeCrossGradient, EllipticGradient };
00034     enum RGBComponent { Red, Green, Blue };
00035 
00036     enum Lighting {NorthLite, NWLite, WestLite, SWLite,
00037            SouthLite, SELite, EastLite, NELite};
00038 
00051     static KPixmap& gradient(KPixmap& pixmap, const QColor &ca, const QColor &cb,
00052                             GradientType type, int ncols=3);
00053 
00069     static KPixmap& unbalancedGradient(KPixmap& pixmap, const QColor &ca,
00070                    const QColor &cb, GradientType type, int xfactor = 100,
00071                    int yfactor = 100, int ncols=3);
00072 
00084     static KPixmap createTiled(const KPixmap& pixmap, QSize size);
00085 
00093     static KPixmap& intensity(KPixmap& pixmap, float ratio);
00094 
00103     static KPixmap& channelIntensity(KPixmap& pixmap, float ratio,
00104                                     RGBComponent channel);
00105 
00123     static KPixmap& blend(KPixmap& pixmap, float initial_intensity,
00124                          const QColor &bgnd, GradientType eff,
00125                          bool anti_dir=false, int ncols=3);
00126 
00137     static KPixmap& hash(KPixmap& pixmap, Lighting lite=NorthLite,
00138                         unsigned int spacing=0, int ncols=3);
00139 
00156     static KPixmap pattern(const KPixmap& pixmap, QSize size,
00157                    const QColor &ca, const QColor &cb, int ncols=8);
00158 
00167     static KPixmap& fade(KPixmap& pixmap, double val, const QColor &color);
00168 
00177     static KPixmap& toGray(KPixmap& pixmap, bool fast=false);
00178 
00186     static KPixmap& desaturate(KPixmap& pixmap, float desat = 0.3);
00187 
00195     static KPixmap& contrast(KPixmap& pixmap, int c);
00196 
00206     static KPixmap& dither(KPixmap &pixmap, const QColor *palette, int size);
00207 
00214     static KPixmap selectedPixmap( const KPixmap &pixmap, const QColor &col );
00215 };
00216 
00217 
00218 #endif

kdefx

Skip menu "kdefx"
  • Main Page
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members

API Reference

Skip menu "API Reference"
  • dcop
  • DNSSD
  • interfaces
  • Kate
  • kconf_update
  • KDECore
  • KDED
  • kdefx
  • KDEsu
  • kdeui
  • KDocTools
  • KHTML
  • KImgIO
  • KInit
  • kio
  • kioslave
  • KJS
  • KNewStuff
  • KParts
  • KUtils
Generated for API Reference by doxygen 1.5.9
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal