File indexing completed on 2024-10-06 04:26:03

0001 /* 
0002     SPDX-FileCopyrightText: 1998-2007 Sebastian Trueg <trueg@k3b.org>
0003     SPDX-License-Identifier: GPL-2.0-or-later
0004 */
0005 
0006 #ifndef _K3B_THEMED_LABEL_H_
0007 #define _K3B_THEMED_LABEL_H_
0008 
0009 #include "k3bthememanager.h"
0010 
0011 #include <KSqueezedTextLabel>
0012 
0013 namespace K3b {
0014 
0015 class ThemedLabel : public KSqueezedTextLabel
0016 {
0017     Q_OBJECT
0018 
0019 public:
0020     explicit ThemedLabel( QWidget* parent = 0 );
0021     explicit ThemedLabel( const QString& text, QWidget* parent = 0 );
0022     explicit ThemedLabel( Theme::PixmapType, QWidget* parent = 0 );
0023 
0024 protected:
0025     bool event( QEvent* event ) override;
0026 
0027 public Q_SLOTS:
0028     void setThemePixmap( Theme::PixmapType );
0029 
0030 private Q_SLOTS:
0031     void slotThemeChanged();
0032 
0033 private:
0034     int m_themePixmapCode;
0035 };
0036 
0037 }
0038 
0039 #endif