File indexing completed on 2024-04-14 05:37:13

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 KOMPAREDIFF2_DIFFSETTINGS_H
0009 #define KOMPAREDIFF2_DIFFSETTINGS_H
0010 
0011 // lib
0012 #include "global.h"
0013 #include "komparediff2_export.h"
0014 // Qt
0015 #include <QStringList>
0016 
0017 class KConfig;
0018 
0019 namespace KompareDiff2
0020 {
0021 
0022 /**
0023  * @class DiffSettings diffsettings.h <KompareDiff2/DiffSettings>
0024  *
0025  * The settings for a diff.
0026  */
0027 class KOMPAREDIFF2_EXPORT DiffSettings
0028 {
0029 public:
0030     DiffSettings();
0031     ~DiffSettings();
0032 
0033 public:
0034     void loadSettings(KConfig *config);
0035     void saveSettings(KConfig *config);
0036 
0037 public:
0038     QString m_diffProgram;
0039     int m_linesOfContext;
0040     Format m_format;
0041     // clang-format off
0042     bool m_largeFiles;                         ///< -H
0043     bool m_ignoreWhiteSpace;                   ///< -b
0044     bool m_ignoreAllWhiteSpace;                ///< -w
0045     bool m_ignoreEmptyLines;                   ///< -B
0046     bool m_ignoreChangesDueToTabExpansion;     ///< -E
0047     bool m_createSmallerDiff;                  ///< -d
0048     bool m_ignoreChangesInCase;                ///< -i
0049     bool m_showCFunctionChange;                ///< -p
0050     bool m_convertTabsToSpaces;                ///< -t
0051     bool m_ignoreRegExp;                       ///< -I
0052     QString m_ignoreRegExpText;                ///< the RE for -I
0053     QStringList m_ignoreRegExpTextHistory;
0054     bool m_recursive;                          ///< -r
0055     bool m_newFiles;                           ///< -N
0056 //  bool m_allText;                            ///< -a
0057     bool m_excludeFilePattern;                 ///< -x
0058     QStringList m_excludeFilePatternList;      ///< The list of patterns for -x
0059     bool m_excludeFilesFile;                   ///< -X
0060     QString m_excludeFilesFileURL;             ///< The filename to -X
0061     QStringList m_excludeFilesFileHistoryList; ///< The history list of filenames
0062     // clang-format on
0063 };
0064 
0065 }
0066 
0067 #endif