File indexing completed on 2025-01-19 11:19:01
0001 /* 0002 SPDX-FileCopyrightText: 2017-2018 Michail Vourlakos <mvourlakos@gmail.com> 0003 SPDX-License-Identifier: GPL-2.0-or-later 0004 */ 0005 0006 #ifndef LAYOUTNAMEDELEGATE_H 0007 #define LAYOUTNAMEDELEGATE_H 0008 0009 // Qt 0010 #include <QStyledItemDelegate> 0011 0012 namespace Latte { 0013 namespace Settings { 0014 namespace Layout { 0015 namespace Delegate { 0016 0017 class LayoutName : public QStyledItemDelegate 0018 { 0019 public: 0020 LayoutName(QObject *parent = 0); 0021 0022 QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index) const override; 0023 void setEditorData(QWidget *editor, const QModelIndex &index) const override; 0024 void setModelData(QWidget *editor, QAbstractItemModel *model, const QModelIndex &index) const override; 0025 void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const override; 0026 }; 0027 0028 } 0029 } 0030 } 0031 } 0032 #endif