diff options
author | Dimitri van Heesch <doxygen@gmail.com> | 2018-10-06 14:22:35 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-06 14:22:35 (GMT) |
commit | 36eefaf9a5faeb828c0d99bffb731747a59f17fe (patch) | |
tree | b05963de2903449fac5fcceaca48a0435917963f | |
parent | d7d4d5c443887cc63211febe40d43f26dfe41bc0 (diff) | |
parent | 406b442fc3d0360e387324ff1c08251d86a1d035 (diff) | |
download | Doxygen-36eefaf9a5faeb828c0d99bffb731747a59f17fe.zip Doxygen-36eefaf9a5faeb828c0d99bffb731747a59f17fe.tar.gz Doxygen-36eefaf9a5faeb828c0d99bffb731747a59f17fe.tar.bz2 |
Merge pull request #6538 from albert-github/feature/bug_702265
Bug 702265 - Generated Doxyfile differs from result of doxygen -u
-rwxr-xr-x | addon/doxywizard/doxywizard.cpp | 2 | ||||
-rw-r--r-- | addon/doxywizard/expert.cpp | 5 | ||||
-rw-r--r-- | addon/doxywizard/input.h | 1 | ||||
-rw-r--r-- | addon/doxywizard/inputstring.h | 1 | ||||
-rw-r--r-- | addon/doxywizard/inputstrlist.cpp | 8 | ||||
-rw-r--r-- | addon/doxywizard/inputstrlist.h | 1 |
6 files changed, 15 insertions, 3 deletions
diff --git a/addon/doxywizard/doxywizard.cpp b/addon/doxywizard/doxywizard.cpp index 492912b..4e0d1aa 100755 --- a/addon/doxywizard/doxywizard.cpp +++ b/addon/doxywizard/doxywizard.cpp @@ -267,7 +267,7 @@ void MainWindow::saveConfig(const QString &fileName) { if (fileName.isEmpty()) return; QFile f(fileName); - if (!f.open(QIODevice::WriteOnly)) + if (!f.open(QIODevice::WriteOnly | QIODevice::Text )) { QMessageBox::warning(this, tr("Error saving"), diff --git a/addon/doxywizard/expert.cpp b/addon/doxywizard/expert.cpp index 66a0955..44dea78 100644 --- a/addon/doxywizard/expert.cpp +++ b/addon/doxywizard/expert.cpp @@ -765,9 +765,10 @@ void Expert::saveTopic(QTextStream &t,QDomElement &elem,QTextCodec *codec, t << convertToComment(option->templateDocs()); t << endl; } - t << name.leftJustified(MAX_OPTION_LENGTH) << "= "; - if (option) + t << name.leftJustified(MAX_OPTION_LENGTH) << "="; + if (option && !option->isEmpty()) { + t << " "; option->writeValue(t,codec); } t << endl; diff --git a/addon/doxywizard/input.h b/addon/doxywizard/input.h index 9e0a1bf..5d86cc8 100644 --- a/addon/doxywizard/input.h +++ b/addon/doxywizard/input.h @@ -30,6 +30,7 @@ class Input virtual void reset() = 0; virtual void writeValue(QTextStream &t,QTextCodec *codec) = 0; virtual void setTemplateDocs(const QString &docs) = 0; + virtual bool isEmpty() { return false; }; }; diff --git a/addon/doxywizard/inputstring.h b/addon/doxywizard/inputstring.h index dba31f6..6234256 100644 --- a/addon/doxywizard/inputstring.h +++ b/addon/doxywizard/inputstring.h @@ -60,6 +60,7 @@ class InputString : public QObject, public Input void updateDependencies() {} void writeValue(QTextStream &t,QTextCodec *codec); void setTemplateDocs(const QString &docs) { m_tdocs = docs; } + bool isEmpty() { return m_str.isEmpty(); } public slots: void reset(); diff --git a/addon/doxywizard/inputstrlist.cpp b/addon/doxywizard/inputstrlist.cpp index 660ce40..822bc4c 100644 --- a/addon/doxywizard/inputstrlist.cpp +++ b/addon/doxywizard/inputstrlist.cpp @@ -260,3 +260,11 @@ void InputStrList::writeValue(QTextStream &t,QTextCodec *codec) } } +bool InputStrList::isEmpty() +{ + foreach (QString s, m_strList) + { + if (!s.isEmpty()) return false; + } + return true; +} diff --git a/addon/doxywizard/inputstrlist.h b/addon/doxywizard/inputstrlist.h index 53f3bcc..c374092 100644 --- a/addon/doxywizard/inputstrlist.h +++ b/addon/doxywizard/inputstrlist.h @@ -55,6 +55,7 @@ class InputStrList : public QObject, public Input void updateDependencies() {} void writeValue(QTextStream &t,QTextCodec *codec); void setTemplateDocs(const QString &docs) { m_tdocs = docs; } + bool isEmpty(); public slots: void reset(); |