aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorEike Ziller <eike.ziller@qt.io>2020-09-07 13:19:38 +0200
committerEike Ziller <eike.ziller@qt.io>2020-09-07 13:19:38 +0200
commitdf97d40a0d03d4073f45437e9ca60a8bbd70852b (patch)
tree4bbf9838a1c8a7567e2787861c7abc35cdbd24a3 /src/plugins
parentf1806621f8ac12b690b94a1e93274ff0c4d37bc8 (diff)
parentb0cad9e9c7aad209756fb2409520c0d048614dd9 (diff)
Merge remote-tracking branch 'origin/4.13' into master
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/cppeditor/cpphighlighter.cpp2
-rw-r--r--src/plugins/git/githighlighters.cpp10
-rw-r--r--src/plugins/git/githighlighters.h5
-rw-r--r--src/plugins/projectexplorer/linuxiccparser.cpp2
-rw-r--r--src/plugins/projectexplorer/outputparser_test.cpp5
-rw-r--r--src/plugins/projectexplorer/task.cpp11
-rw-r--r--src/plugins/projectexplorer/task.h3
-rw-r--r--src/plugins/projectexplorer/taskhub.cpp4
-rw-r--r--src/plugins/projectexplorer/taskmodel.cpp2
-rw-r--r--src/plugins/qmldesigner/CMakeLists.txt2
-rw-r--r--src/plugins/qmldesigner/qmldesignerplugin.qbs3
-rw-r--r--src/plugins/qtsupport/qtoutputformatter.cpp1
12 files changed, 40 insertions, 10 deletions
diff --git a/src/plugins/cppeditor/cpphighlighter.cpp b/src/plugins/cppeditor/cpphighlighter.cpp
index 3b7827d211..51aa17eed4 100644
--- a/src/plugins/cppeditor/cpphighlighter.cpp
+++ b/src/plugins/cppeditor/cpphighlighter.cpp
@@ -396,6 +396,8 @@ bool CppHighlighter::highlightRawStringLiteral(const QStringView &_text, const T
if (text.at(tk.utf16charsEnd() - 1) != '"')
return false;
const int endDelimiterOffset = tk.utf16charsEnd() - 1 - delimiter.length();
+ if (endDelimiterOffset <= delimiterOffset)
+ return false;
if (text.mid(endDelimiterOffset, delimiter.length()) != delimiter)
return false;
if (text.at(endDelimiterOffset - 1) != ')')
diff --git a/src/plugins/git/githighlighters.cpp b/src/plugins/git/githighlighters.cpp
index 4f88183391..37c9af8699 100644
--- a/src/plugins/git/githighlighters.cpp
+++ b/src/plugins/git/githighlighters.cpp
@@ -104,6 +104,11 @@ static TextEditor::TextStyle styleForFormat(int format)
case Format_Squash: return C_ENUMERATION;
case Format_Fixup: return C_NUMBER;
case Format_Exec: return C_LABEL;
+ case Format_Break: return C_PREPROCESSOR;
+ case Format_Drop: return C_REMOVED_LINE;
+ case Format_Label: return C_LABEL;
+ case Format_Reset: return C_LABEL;
+ case Format_Merge: return C_LABEL;
case Format_Count:
QTC_CHECK(false); // should never get here
return C_TEXT;
@@ -125,6 +130,11 @@ GitRebaseHighlighter::GitRebaseHighlighter(QTextDocument *parent) :
m_actions << RebaseAction("^(s|squash)\\b", Format_Squash);
m_actions << RebaseAction("^(f|fixup)\\b", Format_Fixup);
m_actions << RebaseAction("^(x|exec)\\b", Format_Exec);
+ m_actions << RebaseAction("^(b|break)\\b", Format_Break);
+ m_actions << RebaseAction("^(d|drop)\\b", Format_Drop);
+ m_actions << RebaseAction("^(l|label)\\b", Format_Label);
+ m_actions << RebaseAction("^(t|reset)\\b", Format_Reset);
+ m_actions << RebaseAction("^(m|merge)\\b", Format_Merge);
}
void GitRebaseHighlighter::highlightBlock(const QString &text)
diff --git a/src/plugins/git/githighlighters.h b/src/plugins/git/githighlighters.h
index b1c8c78f89..004e8b72cd 100644
--- a/src/plugins/git/githighlighters.h
+++ b/src/plugins/git/githighlighters.h
@@ -42,6 +42,11 @@ enum Format {
Format_Squash,
Format_Fixup,
Format_Exec,
+ Format_Break,
+ Format_Drop,
+ Format_Label,
+ Format_Reset,
+ Format_Merge,
Format_Count
};
diff --git a/src/plugins/projectexplorer/linuxiccparser.cpp b/src/plugins/projectexplorer/linuxiccparser.cpp
index 82799fecd6..41d46a3522 100644
--- a/src/plugins/projectexplorer/linuxiccparser.cpp
+++ b/src/plugins/projectexplorer/linuxiccparser.cpp
@@ -57,7 +57,7 @@ LinuxIccParser::LinuxIccParser() :
// ".pch/Qt5Core.pchi.cpp": creating precompiled header file ".pch/Qt5Core.pchi"
// "animation/qabstractanimation.cpp": using precompiled header file ".pch/Qt5Core.pchi"
- m_pchInfoLine.setPattern(QLatin1String("^\".*?\": (creating|using) precompiled header file \".*?\"\n$"));
+ m_pchInfoLine.setPattern(QLatin1String("^\".*?\": (creating|using) precompiled header file \".*?\"$"));
QTC_CHECK(m_pchInfoLine.isValid());
}
diff --git a/src/plugins/projectexplorer/outputparser_test.cpp b/src/plugins/projectexplorer/outputparser_test.cpp
index d3a162d422..e599e30686 100644
--- a/src/plugins/projectexplorer/outputparser_test.cpp
+++ b/src/plugins/projectexplorer/outputparser_test.cpp
@@ -115,11 +115,10 @@ TestTerminator::TestTerminator(OutputParserTester *t) :
Utils::OutputLineParser::Result TestTerminator::handleLine(const QString &line, Utils::OutputFormat type)
{
- QTC_CHECK(line.endsWith('\n'));
if (type == Utils::StdOutFormat)
- m_tester->m_receivedStdOutChildLine.append(line);
+ m_tester->m_receivedStdOutChildLine.append(line + '\n');
else
- m_tester->m_receivedStdErrChildLine.append(line);
+ m_tester->m_receivedStdErrChildLine.append(line + '\n');
return Status::Done;
}
diff --git a/src/plugins/projectexplorer/task.cpp b/src/plugins/projectexplorer/task.cpp
index 045e461d43..3ca1b969da 100644
--- a/src/plugins/projectexplorer/task.cpp
+++ b/src/plugins/projectexplorer/task.cpp
@@ -67,7 +67,7 @@ Task::Task(TaskType type_, const QString &description,
const QIcon &icon, Options options) :
taskId(s_nextId), type(type_), options(options), summary(description),
line(line_), movedLine(line_), category(category_),
- icon(icon.isNull() ? taskTypeIcon(type_) : icon)
+ m_icon(icon)
{
++s_nextId;
setFile(file_);
@@ -108,7 +108,7 @@ void Task::clear()
line = -1;
movedLine = -1;
category = Utils::Id();
- icon = QIcon();
+ m_icon = QIcon();
formats.clear();
m_mark.clear();
}
@@ -133,6 +133,13 @@ QString Task::description() const
return desc;
}
+QIcon Task::icon() const
+{
+ if (m_icon.isNull())
+ m_icon = taskTypeIcon(type);
+ return m_icon;
+}
+
//
// functions
//
diff --git a/src/plugins/projectexplorer/task.h b/src/plugins/projectexplorer/task.h
index 9c99117977..61aa31e4fc 100644
--- a/src/plugins/projectexplorer/task.h
+++ b/src/plugins/projectexplorer/task.h
@@ -74,6 +74,7 @@ public:
void clear();
void setFile(const Utils::FilePath &file);
QString description() const;
+ QIcon icon() const;
unsigned int taskId = 0;
TaskType type = Unknown;
@@ -85,7 +86,6 @@ public:
int line = -1;
int movedLine = -1; // contains a line number if the line was moved in the editor
Utils::Id category;
- QIcon icon;
// Having a container of QTextLayout::FormatRange in Task isn't that great
// It would be cleaner to split up the text into
@@ -101,6 +101,7 @@ private:
void setMark(TextEditor::TextMark *mark);
QSharedPointer<TextEditor::TextMark> m_mark;
+ mutable QIcon m_icon;
static unsigned int s_nextId;
friend class TaskHub;
diff --git a/src/plugins/projectexplorer/taskhub.cpp b/src/plugins/projectexplorer/taskhub.cpp
index d2528d955c..856959ed0a 100644
--- a/src/plugins/projectexplorer/taskhub.cpp
+++ b/src/plugins/projectexplorer/taskhub.cpp
@@ -78,8 +78,8 @@ public:
} else {
setToolTip(task.description());
}
- setIcon(task.icon);
- setVisible(!task.icon.isNull());
+ setIcon(task.icon());
+ setVisible(!task.icon().isNull());
}
bool isClickable() const override;
diff --git a/src/plugins/projectexplorer/taskmodel.cpp b/src/plugins/projectexplorer/taskmodel.cpp
index 7dc9f66b53..a52f2ff3ac 100644
--- a/src/plugins/projectexplorer/taskmodel.cpp
+++ b/src/plugins/projectexplorer/taskmodel.cpp
@@ -255,7 +255,7 @@ QVariant TaskModel::data(const QModelIndex &index, int role) const
else if (role == TaskModel::Category)
return m_tasks.at(index.row()).category.uniqueIdentifier();
else if (role == TaskModel::Icon)
- return m_tasks.at(index.row()).icon;
+ return m_tasks.at(index.row()).icon();
else if (role == TaskModel::Task_t)
return QVariant::fromValue(task(index));
return QVariant();
diff --git a/src/plugins/qmldesigner/CMakeLists.txt b/src/plugins/qmldesigner/CMakeLists.txt
index 5c6479653d..6c0e25c37a 100644
--- a/src/plugins/qmldesigner/CMakeLists.txt
+++ b/src/plugins/qmldesigner/CMakeLists.txt
@@ -334,6 +334,8 @@ extend_qtc_plugin(QmlDesigner
navigatortreeview.cpp navigatortreeview.h
navigatorview.cpp navigatorview.h
navigatorwidget.cpp navigatorwidget.h
+ choosetexturepropertydialog.cpp choosetexturepropertydialog.h
+ choosetexturepropertydialog.ui
)
extend_qtc_plugin(QmlDesigner
diff --git a/src/plugins/qmldesigner/qmldesignerplugin.qbs b/src/plugins/qmldesigner/qmldesignerplugin.qbs
index 5ccf34efef..40a26e7392 100644
--- a/src/plugins/qmldesigner/qmldesignerplugin.qbs
+++ b/src/plugins/qmldesigner/qmldesignerplugin.qbs
@@ -610,6 +610,9 @@ Project {
"navigator/navigatorview.h",
"navigator/navigatorwidget.cpp",
"navigator/navigatorwidget.h",
+ "navigator/choosetexturepropertydialog.cpp",
+ "navigator/choosetexturepropertydialog.h",
+ "navigator/choosetexturepropertydialog.ui",
"propertyeditor/aligndistribute.cpp",
"propertyeditor/aligndistribute.h",
"propertyeditor/designerpropertymap.cpp",
diff --git a/src/plugins/qtsupport/qtoutputformatter.cpp b/src/plugins/qtsupport/qtoutputformatter.cpp
index 8975328dd0..01036dbaaa 100644
--- a/src/plugins/qtsupport/qtoutputformatter.cpp
+++ b/src/plugins/qtsupport/qtoutputformatter.cpp
@@ -511,6 +511,7 @@ void QtSupportPlugin::testQtOutputFormatter_appendMixedAssertAndAnsi()
"Blue\n";
formatter.appendMessage(inputText, StdOutFormat);
+ formatter.flush();
QCOMPARE(edit.toPlainText(), outputText);