data: Option to run only C/C++ preprocessor when indexing (issue 297)

* Added as checkbox to indexing start dialog
* Only shown for C/C++ projects
* Files will be marked incomplete
This commit is contained in:
Eberhard Graether
2017-04-18 22:11:20 +02:00
parent 2b24b88745
commit 63087913bd
31 changed files with 373 additions and 231 deletions
+33
View File
@@ -0,0 +1,33 @@
#include "qt/element/QtHelpButton.h"
#include <QMessageBox>
#include "utility/ResourcePaths.h"
QtHelpButton::QtHelpButton(const QString& helpText, QWidget* parent)
: QtIconButton(
(ResourcePaths::getGuiPath() + "window/help.png").c_str(),
(ResourcePaths::getGuiPath() + "window/help_hover.png").c_str(),
parent)
, m_helpText(helpText)
{
setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
setAttribute(Qt::WA_LayoutUsesWidgetRect); // fixes layouting on Mac
setMouseTracking(true);
setToolTip("help");
leaveEvent(nullptr);
connect(this, SIGNAL(clicked()), this, SLOT(handleHelpPress()));
}
void QtHelpButton::handleHelpPress()
{
QMessageBox msgBox;
msgBox.setText("Help");
msgBox.setInformativeText(m_helpText);
msgBox.setStandardButtons(QMessageBox::Ok);
msgBox.setDefaultButton(QMessageBox::Ok);
msgBox.exec();
}