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

digikam

albumiconitem.h

Go to the documentation of this file.
00001 /* ============================================================
00002  *
00003  * This file is a part of digiKam project
00004  * http://www.digikam.org
00005  *
00006  * Date        : 2003-04-25
00007  * Description : implementation to render album icon item.
00008  *
00009  * Copyright (C) 2003-2005 by Renchi Raju <renchi@pooh.tam.uiuc.edu>
00010  * Copyright (C) 2003-2008 by Gilles Caulier <caulier dot gilles at gmail dot com>
00011  *
00012  * This program is free software; you can redistribute it
00013  * and/or modify it under the terms of the GNU General
00014  * Public License as published by the Free Software Foundation;
00015  * either version 2, or (at your option)
00016  * any later version.
00017  *
00018  * This program is distributed in the hope that it will be useful,
00019  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00020  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00021  * GNU General Public License for more details.
00022  *
00023  * ============================================================ */
00024 
00025 #ifndef ALBUMICONITEM_H
00026 #define ALBUMICONITEM_H
00027 
00028 // Qt includes
00029 
00030 #include <QString>
00031 #include <QDateTime>
00032 #include <QRect>
00033 
00034 // Local includes
00035 
00036 #include "iconitem.h"
00037 
00038 class QPainter;
00039 
00040 namespace Digikam
00041 {
00042 
00043 class ImageInfo;
00044 class AlbumIconItemPriv;
00045 
00046 class AlbumIconItem : public IconItem
00047 {
00048 
00049 public:
00050 
00051     AlbumIconItem(IconGroupItem* parent, const ImageInfo& info);
00052     ~AlbumIconItem();
00053 
00054     ImageInfo imageInfo() const;
00055     QString   filePath() const;
00056 
00057     QRect thumbnailRect() const;
00058 
00059     bool isDirty();
00060 
00061     static void dateToString(const QDateTime& datetime, QString& str);
00062     static QString squeezedText(QPainter* p, int width, const QString& text);
00063 
00064     virtual int compare(IconItem *item);
00065     virtual QRect clickToOpenRect();
00066     virtual QRect clickToRateRect();
00067 
00068     virtual void  setRating(int rating);
00069     virtual int   rating() const;
00070 
00071 protected:
00072 
00073     virtual void paintItem(QPainter *p);
00074 
00075 private:
00076 
00077     AlbumIconItemPriv* const d;
00078 };
00079 
00080 }  // namespace Digikam
00081 
00082 #endif  // ALBUMICONITEM_H

digikam

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

API Reference

Skip menu "API Reference"
  • digikam
Generated for API Reference by doxygen 1.5.9-20090814
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