Commit 9790d8aa authored by Eike Ziller's avatar Eike Ziller

Merge remote-tracking branch 'origin/3.4'

parents 674b7983 044eeacd
......@@ -199,8 +199,9 @@
\row
\li Type
\li String
\li Optional. Value \c Required or \c Optional. Defines if the dependency is
a hard requirement or optional. Defaults to \c{Required}.
\li Optional. Value \c Required, \c Optional, or \c Test. Defines if the dependency is
a hard requirement, optional, or required for running the plugin's tests.
Defaults to \c{Required}.
\endtable
\section3 Optional Dependencies
......@@ -223,6 +224,18 @@
ExtensionSystem::PluginManager::getObjectByClassName(), and use QMetaObject functions to call
functions on it.
\section3 Test Dependencies
When the user runs the application with the \c{-test} command line argument, only
the specified plugins and their dependencies are loaded. This is done in order to
speed up the execution of tests by avoiding the loading of unneeded plugins.
A plugin can specify additional dependencies that are required for running its
tests, but not for its normal execution, by declaring dependencies with
\c {"Type" : "Test"}. Test dependencies are force loaded, and do not affect load order.
This type of dependency is not transitive.
\section2 Command Line Arguments
Plugins can register command line arguments that the user can give
......
......@@ -51,6 +51,10 @@
indicates lines that contain added text (painted a darker green) in the
right pane.
To revert the changes, right-click added text and then select
\uicontrol {Revert Chunk} in the context menu. To apply the changes, select
removed text and then select \uicontrol {Apply Chunk}.
To view the differences in a unified view where changed rows are placed
below each other, select
\inlineimage qtcreator-switchto-unified-diffeditor.png
......@@ -99,4 +103,8 @@
If the files change outside \QC, select
\inlineimage qtcreator-regenerate-index.png
(\uicontrol {Reload Editor}) to compare them again and to show the results.
To send a chunk of changes to a \l{Pasting and Fetching Code Snippets}
{code pasting service}, select \uicontrol {Send Chunk to CodePaster} in the
context menu.
*/
......@@ -1029,6 +1029,9 @@
To paste any content that you copied to the clipboard, select \uicontrol Tools >
\uicontrol {Code Pasting} > \uicontrol {Paste Snippet}.
To paste content from the \l{Comparing Files}{diff editor}, right-click a
chunk and select \uicontrol {Send Chunk to CodePaster} in the context menu.
To fetch a snippet of code from the server, select \uicontrol{Tools} >
\uicontrol{Code Pasting} > \uicontrol{Fetch Snippet} or press \key{Alt+C,Alt+F}. Select
the snippet to fetch from the list.
......
......@@ -202,7 +202,7 @@
\image qtcreator-vcs-diff.png
With Git, the diff is displayed side-by-side in a \l{Comparing Files}
With Git and Subversion, the diff is displayed side-by-side in a \l{Comparing Files}
{diff editor} by default. To use the inline diff view instead, select the
\uicontrol {Switch to Text Diff Editor} option from the toolbar. In the inline
diff view, you can use context menu commands to apply, revert, stage, and
......
......@@ -290,7 +290,7 @@
If it is a scheduled feature, you can see this in the task tracker. If a
feature already has been implemented, it is mentioned in the
\l{http://qt.gitorious.org/qt-creator/qt-creator/trees/master/dist}{changes file}
\l{https://code.qt.io/cgit/qt-creator/qt-creator.git/tree/dist}{changes file}
for the upcoming release.
\b {Why does \QC not use tabs for editors?}
......
......@@ -90,7 +90,7 @@
here:
\list
\li QtCreator/src/libs/3rdparty
\li \l{http://qt.gitorious.org/qt-creator/qt-creator/trees/master/src/libs/3rdparty}
\li \l{https://code.qt.io/cgit/qt-creator/qt-creator.git/tree/src/libs/3rdparty}
\endlist
\li \b{ANGLE (Windows)}
......
......@@ -115,8 +115,8 @@
\list 1
\li Download the export script, \e{Export QML.jx}, from
\l{http://qt.gitorious.org/qt-labs/photoshop-qmlexporter/trees/master}
{Gitorious}.
\l{https://code.qt.io/cgit/qt-labs/photoshop-qmlexporter.git/}
{code.qt.io}.
\note Read the README.txt file in the repository for latest
information about the script.
......@@ -173,8 +173,8 @@
{Tutorial: Installing Python for GIMP 2.6 (Windows)}.
\li Download the export script, \e qmlexporter.py, from
\l{http://qt.gitorious.org/qt-labs/gimp-qmlexporter/trees/master}
{Gitorious}.
\l{https://code.qt.io/cgit/qt-labs/gimp-qmlexporter.git/}
{code.qt.io}.
\note Read the INSTALL.txt in the repository for latest information
about the script.
......
......@@ -8,6 +8,7 @@ QtcProduct {
property var pluginJsonReplacements
property var pluginRecommends: []
property var pluginTestDepends: []
property string minimumQtVersion: "5.3.1"
condition: QtcFunctions.versionIsAtLeast(Qt.core.version, minimumQtVersion)
......
......@@ -36,6 +36,7 @@ Module {
}
}
cmd.plugin_recommends = product.pluginRecommends
cmd.plugin_test_depends = product.pluginTestDepends
cmd.sourceCode = function() {
var i;
......@@ -57,6 +58,9 @@ Module {
for (i in plugin_recommends) {
deplist.push(" { \"Name\" : \"" + plugin_recommends[i] + "\", \"Version\" : \"" + project.qtcreator_version + "\", \"Type\" : \"optional\" }");
}
for (i in plugin_test_depends) {
deplist.push(" { \"Name\" : \"" + plugin_test_depends[i] + "\", \"Version\" : \"" + project.qtcreator_version + "\", \"Type\" : \"test\" }");
}
deplist = deplist.join(",\n")
vars['dependencyList'] = "\"Dependencies\" : [\n" + deplist + "\n ]";
for (i in vars) {
......
......@@ -67,7 +67,7 @@ def qdump__Debugger__Internal__WatchData(d, value):
d.putPlainChildren(value)
def qdump__Debugger__Internal__WatchItem(d, value):
d.putByteArrayValue(value["d"]["iname"])
d.putByteArrayValue(value["iname"])
d.putPlainChildren(value)
def qdump__Debugger__Internal__BreakpointModelId(d, value):
......
This diff is collapsed.
......@@ -1075,35 +1075,8 @@ class Dumper(DumperBase):
self.putItem(self.expensiveDowncast(value), False)
return
format = self.currentItemFormat(typeName)
if self.useFancy and (format is None or format >= 1):
self.putType(typeName)
nsStrippedType = self.stripNamespaceFromType(typeName)\
.replace("::", "__")
# The following block is only needed for D.
if nsStrippedType.startswith("_A"):
# DMD v2.058 encodes string[] as _Array_uns long long.
# With spaces.
if nsStrippedType.startswith("_Array_"):
qdump_Array(self, value)
return
if nsStrippedType.startswith("_AArray_"):
qdump_AArray(self, value)
return
#warn(" STRIPPED: %s" % nsStrippedType)
#warn(" DUMPERS: %s" % self.qqDumpers)
#warn(" DUMPERS: %s" % (nsStrippedType in self.qqDumpers))
dumper = self.qqDumpers.get(nsStrippedType, None)
if not dumper is None:
if tryDynamic:
dumper(self, self.expensiveDowncast(value))
else:
dumper(self, value)
return
if self.tryPutPrettyItem(typeName, value):
return
# D arrays, gdc compiled.
if typeName.endswith("[]"):
......
......@@ -1063,15 +1063,8 @@ class Dumper(DumperBase):
#warn("VALUE: %s" % value)
#warn("FANCY: %s" % self.useFancy)
if self.useFancy:
stripped = self.stripNamespaceFromType(typeName).replace("::", "__")
#warn("STRIPPED: %s" % stripped)
#warn("DUMPABLE: %s" % (stripped in self.qqDumpers))
if stripped in self.qqDumpers:
self.putType(typeName)
self.context = value
self.qqDumpers[stripped](self, value)
return
if self.tryPutPrettyItem(typeName, value):
return
# Normal value
#numchild = 1 if value.MightHaveChildren() else 0
......
......@@ -53,24 +53,25 @@ def qdump__QAtomicPointer(d, value):
d.putSubItem("_q_value", q.dereference())
def qform__QByteArray():
return "Latin1 String,Latin1 String in Separate Window,UTF-8 String,UTF-8 String in Separate Window"
return [Latin1StringFormat, SeparateLatin1StringFormat,
Utf8StringFormat, SeparateUtf8StringFormat ]
def qdump__QByteArray(d, value):
data, size, alloc = d.byteArrayData(value)
d.putNumChild(size)
elided, p = d.encodeByteArrayHelper(d.extractPointer(value), d.displayStringLimit)
format = d.currentItemFormat()
if format == 1 or format is None:
displayFormat = d.currentItemFormat()
if displayFormat == AutomaticFormat or displayFormat == Latin1StringFormat:
d.putDisplay(StopDisplay)
d.putValue(p, Hex2EncodedLatin1, elided=elided)
elif format == 2:
elif displayFormat == SeparateLatin1StringFormat:
d.putValue(p, Hex2EncodedLatin1, elided=elided)
d.putField("editformat", DisplayLatin1String)
d.putField("editvalue", d.encodeByteArray(value, limit=100000))
elif format == 3:
elif displayFormat == Utf8StringFormat:
d.putDisplay(StopDisplay)
d.putValue(p, Hex2EncodedUtf8, elided=elided)
elif format == 4:
elif displayFormat == SeparateUtf8StringFormat:
d.putValue(p, Hex2EncodedUtf8, elided=elided)
d.putField("editformat", DisplayUtf8String)
d.putField("editvalue", d.encodeByteArray(value, limit=100000))
......@@ -92,14 +93,14 @@ def qdump__QChar(d, value):
def qform__QAbstractItemModel():
return "Normal,Enhanced"
return [SimpleFormat, EnhancedFormat]
def qdump__QAbstractItemModel(d, value):
format = d.currentItemFormat()
if format == 1:
displayFormat = d.currentItemFormat()
if displayFormat == SimpleFormat:
d.putPlainChildren(value)
return
#format == 2:
#displayFormat == EnhancedFormat:
# Create a default-constructed QModelIndex on the stack.
try:
ri = d.makeValue(d.qtNamespace() + "QModelIndex", "-1, -1, 0, 0")
......@@ -134,11 +135,11 @@ def qdump__QAbstractItemModel(d, value):
#gdb.execute("call free($ri)")
def qform__QModelIndex():
return "Normal,Enhanced"
return [SimpleFormat, EnhancedFormat]
def qdump__QModelIndex(d, value):
format = d.currentItemFormat()
if format == 1:
displayFormat = d.currentItemFormat()
if displayFormat == SimpleFormat:
d.putPlainChildren(value)
return
r = value["r"]
......@@ -768,7 +769,7 @@ def qdump__QIPv6Address(d, value):
d.putPlainChildren(c)
def qform__QList():
return "Assume Direct Storage,Assume Indirect Storage"
return [DirectQListStorageFormat, IndirectQListStorageFormat]
def qdump__QList(d, value):
base = d.extractPointer(value)
......@@ -794,10 +795,10 @@ def qdump__QList(d, value):
# but this data is available neither in the compiled binary nor
# in the frontend.
# So as first approximation only do the 'isLarge' check:
format = d.currentItemFormat()
if format == 1:
displayFormat = d.currentItemFormat()
if displayFormat == DirectQListStorageFormat:
isInternal = True
elif format == 2:
elif displayFormat == IndirectQListStorageFormat:
isInternal = False
else:
isInternal = innerSize <= stepSize and d.isMovableType(innerType)
......@@ -818,7 +819,7 @@ def qdump__QList(d, value):
d.putSubItem(i, x)
def qform__QImage():
return "Normal,Displayed"
return [SimpleFormat, SeparateFormat]
def qdump__QImage(d, value):
# This relies on current QImage layout:
......@@ -861,10 +862,10 @@ def qdump__QImage(d, value):
d.putNumChild(0)
d.putType("void *")
format = d.currentItemFormat()
if format == 1:
displayFormat = d.currentItemFormat()
if displayFormat == SimpleFormat:
d.putDisplay(StopDisplay)
elif format == 2:
elif displayFormat == SeparateFormat:
# This is critical for performance. Writing to an external
# file using the following is faster when using GDB.
# file = tempfile.mkstemp(prefix="gdbpy_")
......@@ -1751,16 +1752,16 @@ def qedit__QString(d, value, data):
d.setValues(base, "short", [ord(c) for c in data])
def qform__QString():
return "Inline,Separate Window"
return [SimpleFormat, SeparateFormat]
def qdump__QString(d, value):
d.putStringValue(value)
data, size, alloc = d.stringData(value)
d.putNumChild(size)
format = d.currentItemFormat()
if format == 1:
displayFormat = d.currentItemFormat()
if displayFormat == SimpleFormat:
d.putDisplay(StopDisplay)
elif format == 2:
elif displayFormat == SeparateFormat:
d.putField("editformat", DisplayUtf16String)
d.putField("editvalue", d.encodeString(value, limit=100000))
if d.isExpanded():
......@@ -1847,7 +1848,7 @@ def qdump__QTextDocument(d, value):
def qform__QUrl():
return "Inline,Separate Window"
return [SimpleFormat, SeparateFormat]
def qdump__QUrl(d, value):
if d.qtVersion() < 0x050000:
......@@ -1911,10 +1912,10 @@ def qdump__QUrl(d, value):
url += path
d.putValue(url, Hex4EncodedLittleEndian)
format = d.currentItemFormat()
if format == 1:
displayFormat = d.currentItemFormat()
if displayFormat == SimpleFormat:
d.putDisplay(StopDisplay)
elif format == 2:
elif displayFormat == SeparateFormat:
d.putField("editformat", DisplayUtf16String)
d.putField("editvalue", url)
......
......@@ -398,7 +398,8 @@ def qdump__std____debug__stack(d, value):
qdump__std__stack(d, value)
def qform__std__string():
return "Latin1 String,Latin1 String in Separate Window,UTF-8 String,UTF-8 String in Separate Window"
return [Latin1StringFormat, SeparateLatin1StringFormat,
Utf8StringFormat, SeparateUtf8StringFormat ]
def qdump__std__string(d, value):
qdump__std__stringHelper1(d, value, 1, d.currentItemFormat())
......@@ -787,7 +788,7 @@ def qdump__string(d, value):
qdump__std__string(d, value)
def qform__std__wstring():
return "Inline String,String in Separate Window"
return [SimpleFormat, SeparateFormat]
def qdump__std__wstring(d, value):
charSize = d.lookupType('wchar_t').sizeof
......
......@@ -87,6 +87,10 @@ OutputPaneToggleButtonTextColorChecked=text
OutputPaneToggleButtonTextColorUnchecked=text
QtOutputFormatter_LinkTextColor=ff0000ff
CompileOutput_ErrorOutput=ffff6c6c
CompileOutput_MessageOutput=ff008787
CompileOutput_ErrorMessageOutput=ffff6c6c
Welcome_BackgroundColorNormal=normalBackground
Welcome_Button_BorderColorNormal=0
Welcome_Button_BorderColorPressed=0
......
......@@ -81,6 +81,10 @@ OutputPaneToggleButtonTextColorChecked=ffffffff
OutputPaneToggleButtonTextColorUnchecked=ff000000
QtOutputFormatter_LinkTextColor=ff0000aa
CompileOutput_ErrorOutput=ffaa0000
CompileOutput_MessageOutput=ff0000aa
CompileOutput_ErrorMessageOutput=ffaa0000
Welcome_BackgroundColorNormal=ffffffff
Welcome_Button_BorderColorNormal=ff737373
Welcome_Button_BorderColorPressed=ff333333
......
......@@ -63,8 +63,10 @@ public:
{
TypeVisitor::accept(ty.type());
unsigned flags = ty.flags();
flags |= temps.back().flags();
temps.back().setFlags(flags);
if (!temps.isEmpty()) {
flags |= temps.back().flags();
temps.back().setFlags(flags);
}
}
public:
......@@ -73,7 +75,7 @@ public:
FullySpecifiedType operator()(const FullySpecifiedType &ty)
{
accept(ty);
return temps.takeLast();
return (!temps.isEmpty()) ? temps.takeLast() : ty;
}
virtual void visit(UndefinedType *)
......@@ -241,7 +243,7 @@ public:
return 0;
accept(name);
return temps.takeLast();
return (!temps.isEmpty()) ? temps.takeLast() : name;
}
virtual void visit(const QualifiedNameId *name)
......
......@@ -91,6 +91,7 @@ bool OptionsParser::parse()
}
if (m_isDependencyRefreshNeeded)
m_pmPrivate->resolveDependencies();
m_pmPrivate->enableOnlyTestedSpecs();
return !m_hasError;
}
......
......@@ -98,8 +98,16 @@ void PluginDetailsView::update(PluginSpec *spec)
QString depString = dep.name;
depString += QLatin1String(" (");
depString += dep.version;
if (dep.type == PluginDependency::Optional)
switch (dep.type) {
case PluginDependency::Required:
break;
case PluginDependency::Optional:
depString += QLatin1String(", optional");
break;
case PluginDependency::Test:
depString += QLatin1String(", test");
break;
}
depString += QLatin1Char(')');
depStrings.append(depString);
}
......
......@@ -1255,7 +1255,14 @@ bool PluginManagerPrivate::loadQueue(PluginSpec *spec, QList<PluginSpec *> &queu
}
// add dependencies
foreach (PluginSpec *depSpec, spec->dependencySpecs()) {
QHashIterator<PluginDependency, PluginSpec *> it(spec->dependencySpecs());
while (it.hasNext()) {
it.next();
// Skip test dependencies since they are not real dependencies but just force-loaded
// plugins when running tests
if (it.key().type == PluginDependency::Test)
continue;
PluginSpec *depSpec = it.value();
if (!loadQueue(depSpec, queue, circularityCheckQueue)) {
spec->d->hasError = true;
spec->d->errorString =
......@@ -1299,7 +1306,7 @@ void PluginManagerPrivate::loadPlugin(PluginSpec *spec, PluginSpec::State destSt
QHashIterator<PluginDependency, PluginSpec *> it(spec->dependencySpecs());
while (it.hasNext()) {
it.next();
if (it.key().type == PluginDependency::Optional)
if (it.key().type != PluginDependency::Required)
continue;
PluginSpec *depSpec = it.value();
if (depSpec->state() != destState) {
......@@ -1423,6 +1430,35 @@ void PluginManagerPrivate::resolveDependencies()
}
}
void PluginManagerPrivate::enableOnlyTestedSpecs()
{
if (testSpecs.isEmpty())
return;
QList<PluginSpec *> specsForTests;
foreach (const TestSpec &testSpec, testSpecs) {
QList<PluginSpec *> circularityCheckQueue;
loadQueue(testSpec.pluginSpec, specsForTests, circularityCheckQueue);
// add plugins that must be force loaded when running tests for the plugin
// (aka "test dependencies")
QHashIterator<PluginDependency, PluginSpec *> it(testSpec.pluginSpec->dependencySpecs());
while (it.hasNext()) {
it.next();
if (it.key().type != PluginDependency::Test)
continue;
PluginSpec *depSpec = it.value();
circularityCheckQueue.clear();
loadQueue(depSpec, specsForTests, circularityCheckQueue);
}
}
foreach (PluginSpec *spec, pluginSpecs)
spec->setForceDisabled(true);
foreach (PluginSpec *spec, specsForTests) {
spec->setForceDisabled(false);
spec->setForceEnabled(true);
}
}
// Look in argument descriptions of the specs for the option.
PluginSpec *PluginManagerPrivate::pluginForOption(const QString &option, bool *requiresArgument) const
{
......
......@@ -73,6 +73,7 @@ public:
QList<PluginSpec *> loadQueue();
void loadPlugin(PluginSpec *spec, PluginSpec::State destState);
void resolveDependencies();
void enableOnlyTestedSpecs();
void initProfiling();
void profilingSummary() const;
void profilingReport(const char *what, const PluginSpec *spec = 0);
......
......@@ -86,6 +86,8 @@
Dependency is not necessarily needed. You need to make sure that
the plugin is able to load without this dependency installed, so
for example you may not link to the dependency's library.
\value Test
Dependency needs to be force-loaded for running tests of the plugin.
*/
/*!
......@@ -471,6 +473,7 @@ namespace {
const char DEPENDENCY_TYPE[] = "Type";
const char DEPENDENCY_TYPE_SOFT[] = "optional";
const char DEPENDENCY_TYPE_HARD[] = "required";
const char DEPENDENCY_TYPE_TEST[] = "test";
const char ARGUMENTS[] = "Arguments";
const char ARGUMENT_NAME[] = "Name";
const char ARGUMENT_PARAMETER[] = "Parameter";
......@@ -763,6 +766,8 @@ bool PluginSpecPrivate::readMetaData(const QJsonObject &metaData)
dep.type = PluginDependency::Required;
} else if (typeValue.toLower() == QLatin1String(DEPENDENCY_TYPE_SOFT)) {
dep.type = PluginDependency::Optional;
} else if (typeValue.toLower() == QLatin1String(DEPENDENCY_TYPE_TEST)) {
dep.type = PluginDependency::Test;
} else {
return reportError(tr("Dependency: \"%1\" must be \"%2\" or \"%3\" (is \"%4\")")
.arg(QLatin1String(DEPENDENCY_TYPE),
......@@ -917,7 +922,7 @@ void PluginSpecPrivate::disableIndirectlyIfDependencyDisabled()
QHashIterator<PluginDependency, PluginSpec *> it(dependencySpecs);
while (it.hasNext()) {
it.next();
if (it.key().type == PluginDependency::Optional)
if (it.key().type != PluginDependency::Required)
continue;
PluginSpec *dependencySpec = it.value();
if (!dependencySpec->isEffectivelyEnabled()) {
......
......@@ -55,7 +55,8 @@ struct EXTENSIONSYSTEM_EXPORT PluginDependency
{
enum Type {
Required,
Optional
Optional,
Test
};
PluginDependency() : type(Required) {}
......
......@@ -1731,7 +1731,8 @@ static inline bool dumpQByteArray(const SymbolGroupValue &v, std::wostream &str,
char *memory;
unsigned fullSize;
unsigned size;
if (!readQt5StringData(dV, qtInfo, false, 0, 10240, &fullSize, &size, &memory))
const unsigned &maxStringSize = ExtensionContext::instance().parameters().maxStringLength;
if (!readQt5StringData(dV, qtInfo, false, 0, maxStringSize, &fullSize, &size, &memory))
return false;
if (size) {
// Emulate CDB's behavior of replacing unprintable characters
......
......@@ -28,8 +28,8 @@
**
****************************************************************************/
vec4 orange = vec4(1.0, 165.0 / 255.0, 0.0, 1.0);
varying float d;
lowp vec4 orange = vec4(1.0, 165.0 / 255.0, 0.0, 1.0);
varying lowp float d;
void main()
{
......
......@@ -28,17 +28,22 @@
**
****************************************************************************/
#ifdef GL_OES_standard_derivatives
#extension GL_OES_standard_derivatives : enable
// else we probably have fwidth() in core
#endif
varying lowp vec3 edgeColor;
varying lowp vec3 color;
varying lowp vec2 barycentric;
vec4 zero = vec4(0.0);
lowp vec4 zero = vec4(0.0);
void main()
{
vec2 d = fwidth(barycentric) * 5.0;
vec4 edge_closeness = smoothstep(zero, vec4(d.x, d.y, d.x, d.y),
lowp vec2 d = fwidth(barycentric) * 5.0;
lowp vec4 edge_closeness = smoothstep(zero, vec4(d.x, d.y, d.x, d.y),
vec4(barycentric.x, barycentric.y, 1.0 - barycentric.x, 1.0 - barycentric.y));
float total = min(min(edge_closeness[0], edge_closeness[1]),
lowp float total = min(min(edge_closeness[0], edge_closeness[1]),
min(edge_closeness[2], edge_closeness[3]));
// square to make lines sharper
total = total > 0.5 ? (1.0 - (1.0 - total) * (1.0 - total) * 2.0) : total * total * 2.0;
......
......@@ -47,13 +47,13 @@ void main()
gl_Position = matrix * vertexCoord;
// Make very narrow events somewhat wider so that they don't collapse into 0 pixels
highp float scaledWidth = scale.x * rectSize.x;
highp float shift = sign(scaledWidth) * max(0, 3.0 - abs(scaledWidth)) * 0.0005;
float scaledWidth = scale.x * rectSize.x;
float shift = sign(scaledWidth) * max(0.0, 3.0 - abs(scaledWidth)) * 0.0005;
gl_Position.x += shift;
// Ditto for events with very small height
highp float scaledHeight = scale.y * rectSize.y;
gl_Position.y += float(rectSize.y > 0.0) * max(0, 3.0 - scaledHeight) * 0.003;
float scaledHeight = scale.y * rectSize.y;
gl_Position.y += float(rectSize.y > 0.0) * max(0.0, 3.0 - scaledHeight) * 0.003;
barycentric = vec2(rectSize.x > 0.0 ? 1.0 : 0.0, rectSize.y > 0.0 ? 1.0 : 0.0);
color = vertexColor.rgb;
......
......@@ -133,6 +133,12 @@ public:
QtOutputFormatter_LinkTextColor,
/* Compile Output Pane */
CompileOutput_ErrorOutput,
CompileOutput_MessageOutput,
CompileOutput_ErrorMessageOutput,
/* Welcome Plugin */
Welcome_TextColorNormal,
......
......@@ -725,6 +725,17 @@ void TreeItem::removeChildren()
}
}
void TreeItem::sortChildren(const std::function<bool(const TreeItem *, const TreeItem *)> &cmp)
{
if (m_model) {
m_model->layoutAboutToBeChanged();
std::sort(m_children.begin(), m_children.end(), cmp);