File indexing completed on 2024-05-19 05:08:26
0001 /* 0002 SPDX-FileCopyrightText: 2023 Thomas Baumgart <tbaumgart@kde.org> 0003 SPDX-License-Identifier: GPL-2.0-or-later 0004 */ 0005 0006 #ifndef SECURITYACCOUNTNAMEDELEGATE_H 0007 #define SECURITYACCOUNTNAMEDELEGATE_H 0008 0009 // ---------------------------------------------------------------------------- 0010 // QT Includes 0011 0012 class QColor; 0013 0014 // ---------------------------------------------------------------------------- 0015 // KDE Includes 0016 0017 // ---------------------------------------------------------------------------- 0018 // Project Includes 0019 0020 #include "kmmstyleditemdelegate.h" 0021 #include "mymoneyenums.h" 0022 0023 class LedgerView; 0024 class MyMoneyMoney; 0025 0026 class SecurityAccountNameDelegate : public KMMStyledItemDelegate 0027 { 0028 Q_OBJECT 0029 public: 0030 explicit SecurityAccountNameDelegate(LedgerView* parent = 0); 0031 virtual ~SecurityAccountNameDelegate(); 0032 0033 void paint(QPainter* painter, const QStyleOptionViewItem& option, const QModelIndex& index) const final override; 0034 QSize sizeHint(const QStyleOptionViewItem& option, const QModelIndex& index) const final override; 0035 0036 protected: 0037 bool eventFilter(QObject* o, QEvent* event) final override; 0038 0039 private: 0040 class Private; 0041 Private* const d; 0042 }; 0043 0044 #endif // SECURITYACCOUNTNAMEDELEGATE_H