File indexing completed on 2024-04-28 05:42:49

0001 /*
0002     SPDX-FileCopyrightText: 2001-2003 Otto Bruggeman <otto.bruggeman@home.nl>
0003     SPDX-FileCopyrightText: 2001-2003 John Firebaugh <jfirebaugh@kde.org>
0004 
0005     SPDX-License-Identifier: GPL-2.0-or-later
0006 */
0007 
0008 #ifndef VIEWSETTINGS_H
0009 #define VIEWSETTINGS_H
0010 
0011 #include <QColor>
0012 #include <QWidget>
0013 
0014 #include <KompareDiff2/Difference>
0015 
0016 #include "settingsbase.h"
0017 #include "dialogpages_export.h"
0018 
0019 class DIALOGPAGES_EXPORT ViewSettings : public SettingsBase
0020 {
0021     Q_OBJECT
0022 public:
0023     static const QColor default_removeColor;
0024     static const QColor default_changeColor;
0025     static const QColor default_addColor;
0026     static const QColor default_appliedColor;
0027 
0028     explicit ViewSettings(QWidget* parent);
0029     ~ViewSettings() override;
0030 public:
0031     // some virtual functions that will be overloaded from the base class
0032     void loadSettings(KConfig* config) override;
0033     void saveSettings(KConfig* config) override;
0034     QColor colorForDifferenceType(int type, bool selected = false, bool applied = false);
0035 
0036 public:
0037     QColor m_removeColor;
0038     QColor m_changeColor;
0039     QColor m_addColor;
0040     QColor m_appliedColor;
0041     QColor m_selectedRemoveColor;
0042     QColor m_selectedChangeColor;
0043     QColor m_selectedAddColor;
0044     QColor m_selectedAppliedColor;
0045     int    m_scrollNoOfLines;
0046     int    m_tabToNumberOfSpaces;
0047 
0048     QFont  m_font;
0049 };
0050 
0051 #endif // VIEWSETTINGS_H