1 /* 2 SPDX-FileCopyrightText: 2001-2003 Otto Bruggeman <otto.bruggeman@home.nl> 3 SPDX-FileCopyrightText: 2001-2003 John Firebaugh <jfirebaugh@kde.org> 4 5 SPDX-License-Identifier: GPL-2.0-or-later 6 */ 7 8 #ifndef VIEWSETTINGS_H 9 #define VIEWSETTINGS_H 10 11 #include <QColor> 12 #include <QWidget> 13 14 #include <libkomparediff2/difference.h> 15 #include <libkomparediff2/settingsbase.h> 16 17 #include "dialogpages_export.h" 18 19 class DIALOGPAGES_EXPORT ViewSettings : public SettingsBase 20 { 21 Q_OBJECT 22 public: 23 static const QColor default_removeColor; 24 static const QColor default_changeColor; 25 static const QColor default_addColor; 26 static const QColor default_appliedColor; 27 28 explicit ViewSettings(QWidget* parent); 29 ~ViewSettings() override; 30 public: 31 // some virtual functions that will be overloaded from the base class 32 void loadSettings(KConfig* config) override; 33 void saveSettings(KConfig* config) override; 34 QColor colorForDifferenceType(int type, bool selected = false, bool applied = false); 35 36 public: 37 QColor m_removeColor; 38 QColor m_changeColor; 39 QColor m_addColor; 40 QColor m_appliedColor; 41 QColor m_selectedRemoveColor; 42 QColor m_selectedChangeColor; 43 QColor m_selectedAddColor; 44 QColor m_selectedAppliedColor; 45 int m_scrollNoOfLines; 46 int m_tabToNumberOfSpaces; 47 48 QFont m_font; 49 }; 50 51 #endif // VIEWSETTINGS_H 52