diff --git a/COPYING b/COPYING --- a/COPYING +++ b/COPYING @@ -2,7 +2,7 @@ Version 2, June 1991 Copyright (C) 1989, 1991 Free Software Foundation, Inc. - 51 Franklin Steet, Fifth Floor, Boston, MA 02111-1307 USA + 51 Franklin Street, Fifth Floor, Boston, MA 02111-1307 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. diff --git a/README b/README --- a/README +++ b/README @@ -6,16 +6,16 @@ KDiff3-Version: 1.7.90 Now requires Qt 5.6 or later and KF5 5.14+. Legacy 0.9.98 and earlier builds are not supported. -MacOSX build is untested since port. The Konqueror specific plugin is not ported and no longer mantained. +MacOSX build is untested since port. The Konqueror specific plugin is not ported and no longer maintained. This plugin would only apply to KDE before 4.6. Support as been removed from main CMakeLists.txt. As of 1/13/17 cmake 3.1+ is the targeted cmake version. -cmake is now the only build system supported. KF5/QT5 was big jump. A lot changed besides just the API. -I am not against a Qt5-only build variant but see no reason to mantain two sperate build systems. +cmake is now the only build system supported. KF5/Qt5 was big jump. A lot changed besides just the API. +I am not against a Qt5-only build variant but see no reason to maintain two separate build systems. At present KF5 is my focus. -The original pre KF5/Qt5 Readme fallows old build intrustions have been removed to avoid confusion: +The original pre KF5/Qt5 Readme follows old build instructions have been removed to avoid confusion: Copyright: (C) 2002-2014 by Joachim Eibl @@ -25,7 +25,7 @@ Thus there are many setup possibilities to consider. Supported Qt-versions: 4.8, 5.2 or higher. -Supported KDE-version: 4 +Supported KDE-version: 4, 5 (For KDE3/Qt3 use KDiff3-0.9.92 or older.) Contents @@ -46,11 +46,11 @@ - an integrated editor for comfortable solving of merge-conflicts - has support for KDE-KIO (ftp, sftp, http, fish, smb), - has an intuitive graphical user interface, -- provides a context menu for KDE-Konqueror and Windows-Explorer, +- provides a context menu for KDE-Dolphin and Windows-Explorer, - supports 64 bit systems. (Some build issues are discussed in here.) - Support for many encodings and Unicode. -Do you want help translating? Read the README in the po-subdirectory! +Do you want help translating? Read the instructions on https://l10n.kde.org/ ! License @@ -69,7 +69,7 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin Steet, Fifth Floor, Boston, MA 02111-1307 + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1307 USA For details see file "COPYING". diff --git a/src/DirectoryInfo.h b/src/DirectoryInfo.h --- a/src/DirectoryInfo.h +++ b/src/DirectoryInfo.h @@ -52,4 +52,4 @@ FileAccess m_dirDest; }; -#endif \ No newline at end of file +#endif diff --git a/src/MergeFileInfos.h b/src/MergeFileInfos.h --- a/src/MergeFileInfos.h +++ b/src/MergeFileInfos.h @@ -157,4 +157,4 @@ } }; -#endif // !MERGEFILEINFO_H \ No newline at end of file +#endif // !MERGEFILEINFO_H diff --git a/src/ProgressProxyExtender.h b/src/ProgressProxyExtender.h --- a/src/ProgressProxyExtender.h +++ b/src/ProgressProxyExtender.h @@ -20,8 +20,8 @@ * */ -#ifndef PROGREESPROXYEXENDER_H -#define PROGREESPROXYEXENDER_H +#ifndef PROGREESPROXYEXTENDER_H +#define PROGREESPROXYEXTENDER_H #include "progress.h" #include @@ -37,4 +37,4 @@ void slotListDirInfoMessage( KJob*, const QString& msg ); void slotPercent( KJob*, qint64 percent ); }; -#endif \ No newline at end of file +#endif diff --git a/src/Utils.h b/src/Utils.h --- a/src/Utils.h +++ b/src/Utils.h @@ -30,4 +30,4 @@ static QString getArguments(QString cmd, QString& program, QStringList& args); }; -#endif \ No newline at end of file +#endif diff --git a/src/Utils.cpp b/src/Utils.cpp --- a/src/Utils.cpp +++ b/src/Utils.cpp @@ -122,4 +122,4 @@ } return false; -} \ No newline at end of file +} diff --git a/src/common.cpp b/src/common.cpp --- a/src/common.cpp +++ b/src/common.cpp @@ -15,7 +15,7 @@ * You should have received a copy of the GNU General Public License * * along with this program; if not, write to the * * Free Software Foundation, Inc., * - * 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. * + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * ***************************************************************************/ #include "common.h" @@ -187,7 +187,7 @@ return s.mid(pos); } - return ""; + return QString(); } static int num(QString& s, int idx) diff --git a/src/cvsignorelist.h b/src/cvsignorelist.h --- a/src/cvsignorelist.h +++ b/src/cvsignorelist.h @@ -11,6 +11,8 @@ * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * ***************************************************************************/ +#ifndef CVSIGNORELIST_H +#define CVSIGNORELIST_H #include "fileaccess.h" @@ -32,4 +34,6 @@ QStringList m_startPatterns; QStringList m_endPatterns; QStringList m_generalPatterns; -}; \ No newline at end of file +}; + +#endif diff --git a/src/directorymergewindow.cpp b/src/directorymergewindow.cpp --- a/src/directorymergewindow.cpp +++ b/src/directorymergewindow.cpp @@ -2142,7 +2142,7 @@ { return mi.column() == s_ACol ? pMFI->getFileInfoA()->absoluteFilePath() : mi.column() == s_BCol ? pMFI->getFileInfoB()->absoluteFilePath() : mi.column() == s_CCol ? pMFI->getFileInfoC()->absoluteFilePath() : QString(""); } - return ""; + return QString(); } bool DirectoryMergeWindow::DirectoryMergeWindowPrivate::isDir(const QModelIndex& mi) diff --git a/src/gnudiff_analyze.cpp b/src/gnudiff_analyze.cpp --- a/src/gnudiff_analyze.cpp +++ b/src/gnudiff_analyze.cpp @@ -19,7 +19,7 @@ You should have received a copy of the GNU General Public License along with this program; see the file COPYING. If not, write to the Free Software Foundation, - 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. */ + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ /* The basic algorithm is described in: "An O(ND) Difference Algorithm and its Variations", Eugene Myers, diff --git a/src/gnudiff_diff.h b/src/gnudiff_diff.h --- a/src/gnudiff_diff.h +++ b/src/gnudiff_diff.h @@ -19,7 +19,7 @@ You should have received a copy of the GNU General Public License along with this program; see the file COPYING. If not, write to the Free Software Foundation, - 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. */ + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #ifndef GNUDIFF_DIFF_H #define GNUDIFF_DIFF_H diff --git a/src/gnudiff_io.cpp b/src/gnudiff_io.cpp --- a/src/gnudiff_io.cpp +++ b/src/gnudiff_io.cpp @@ -19,7 +19,7 @@ You should have received a copy of the GNU General Public License along with this program; see the file COPYING. If not, write to the Free Software Foundation, - 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. */ + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #include "gnudiff_diff.h" #include diff --git a/src/gnudiff_system.h b/src/gnudiff_system.h --- a/src/gnudiff_system.h +++ b/src/gnudiff_system.h @@ -19,7 +19,7 @@ You should have received a copy of the GNU General Public License along with this program; see the file COPYING. If not, write to the Free Software Foundation, - 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. */ + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #ifndef GNUDIFF_SYSTEM_H #define GNUDIFF_SYSTEM_H diff --git a/src/gnudiff_xmalloc.cpp b/src/gnudiff_xmalloc.cpp --- a/src/gnudiff_xmalloc.cpp +++ b/src/gnudiff_xmalloc.cpp @@ -17,7 +17,7 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, - Inc., 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. */ + Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #include diff --git a/src/guiutils.h b/src/guiutils.h --- a/src/guiutils.h +++ b/src/guiutils.h @@ -14,6 +14,8 @@ * (at your option) any later version. * * * ***************************************************************************/ +#ifndef GUIUTILS_H +#define GUIUTILS_H #include #include @@ -128,3 +130,5 @@ return theAction; } } + +#endif diff --git a/src/kdiff3.h b/src/kdiff3.h --- a/src/kdiff3.h +++ b/src/kdiff3.h @@ -120,7 +120,7 @@ void readOptions(KSharedConfigPtr); // Finish initialisation (virtual, so that it can be called from the shell too.) - virtual void completeInit(const QString& fn1 = "", const QString& fn2 = "", const QString& fn3 = ""); + virtual void completeInit(const QString& fn1 = QString(), const QString& fn2 = QString(), const QString& fn3 = QString()); /** queryClose is called by KMainWindow on each closeEvent of a window. Against the * default implementation (only returns true), this calles saveModified() on the document object to ask if the document shall diff --git a/src/kdiff3.cpp b/src/kdiff3.cpp --- a/src/kdiff3.cpp +++ b/src/kdiff3.cpp @@ -351,7 +351,7 @@ delete KDiff3Shell::getParser(); if(m_pKDiff3Shell == nullptr) { - completeInit(); + completeInit(QString()); } } diff --git a/src/kdiff3_part.h b/src/kdiff3_part.h --- a/src/kdiff3_part.h +++ b/src/kdiff3_part.h @@ -15,7 +15,7 @@ * You should have received a copy of the GNU General Public License * * along with this program; if not, write to the * * Free Software Foundation, Inc., * - * 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. * + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * ***************************************************************************/ #ifndef _KDIFF3PART_H_ diff --git a/src/kdiff3_part.cpp b/src/kdiff3_part.cpp --- a/src/kdiff3_part.cpp +++ b/src/kdiff3_part.cpp @@ -14,7 +14,7 @@ * You should have received a copy of the GNU General Public License * * along with this program; if not, write to the * * Free Software Foundation, Inc., * - * 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. * + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * ***************************************************************************/ #include "kdiff3_part.h" diff --git a/src/kdiff3_shell.h b/src/kdiff3_shell.h --- a/src/kdiff3_shell.h +++ b/src/kdiff3_shell.h @@ -15,7 +15,7 @@ * You should have received a copy of the GNU General Public License * * along with this program; if not, write to the * * Free Software Foundation, Inc., * - * 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. * + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * ***************************************************************************/ #ifndef _KDIFF3SHELL_H_ diff --git a/src/kdiff3_shell.cpp b/src/kdiff3_shell.cpp --- a/src/kdiff3_shell.cpp +++ b/src/kdiff3_shell.cpp @@ -15,7 +15,7 @@ * You should have received a copy of the GNU General Public License * * along with this program; if not, write to the * * Free Software Foundation, Inc., * - * 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. * + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * ***************************************************************************/ #include "kdiff3_shell.h" @@ -69,7 +69,7 @@ setCentralWidget(m_widget); if(bCompleteInit) - m_widget->completeInit(); + m_widget->completeInit(QString()); connect(m_widget, SIGNAL(createNewInstance(const QString&, const QString&, const QString&)), this, SLOT(slotNewInstance(const QString&, const QString&, const QString&))); } else diff --git a/src/mergeresultwindow.cpp b/src/mergeresultwindow.cpp --- a/src/mergeresultwindow.cpp +++ b/src/mergeresultwindow.cpp @@ -1099,7 +1099,7 @@ return s; // Very unlikely } } - return ""; // Must be an empty string, not a null string. + return QString(); // Must be an empty string, not a null string. } static void findHistoryRange(const QRegExp& historyStart, bool bThreeFiles, const Diff3LineList* pD3LList, diff --git a/src/optiondialog.h b/src/optiondialog.h --- a/src/optiondialog.h +++ b/src/optiondialog.h @@ -14,7 +14,7 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ diff --git a/src/optiondialog.cpp b/src/optiondialog.cpp --- a/src/optiondialog.cpp +++ b/src/optiondialog.cpp @@ -14,7 +14,7 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ diff --git a/src/options.h b/src/options.h --- a/src/options.h +++ b/src/options.h @@ -14,7 +14,7 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * */ diff --git a/src/pdiff.cpp b/src/pdiff.cpp --- a/src/pdiff.cpp +++ b/src/pdiff.cpp @@ -13,22 +13,20 @@ #include #include -#include #include #include #include #include #include #include -#include #include #include +#include #include #include #include #include #include -#include #include #include diff --git a/src/selection.h b/src/selection.h --- a/src/selection.h +++ b/src/selection.h @@ -7,6 +7,8 @@ * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * ***************************************************************************/ +#ifndef SELECTION_H +#define SELECTION_H #include "gnudiff_diff.h" #include "common.h" @@ -76,3 +78,5 @@ int endPos() { return firstLine==lastLine ? std::max(firstPos,lastPos) : firstLine