From 647ae51a462fdb8d5256fde65596695e7611e2ff Mon Sep 17 00:00:00 2001 From: Scott Kostyshak Date: Fri, 19 Apr 2013 07:48:15 -0400 Subject: [PATCH] GuiRef: do not hide labels that start with ':' If a label starts with ':' and 'Group' is checked, the label is now shown under "" instead of not shown. Note that labels starting with ':' can be valid in LaTeX. --- src/frontends/qt4/GuiRef.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/frontends/qt4/GuiRef.cpp b/src/frontends/qt4/GuiRef.cpp index 9e64750486..15e6583623 100644 --- a/src/frontends/qt4/GuiRef.cpp +++ b/src/frontends/qt4/GuiRef.cpp @@ -392,11 +392,11 @@ void GuiRef::redoRefs() QString const ref = refsStrings.at(i); if ((ref.startsWith(cat + QString(":"))) || (cat == qt_("") - && !ref.contains(":"))) { - QTreeWidgetItem * child = - new QTreeWidgetItem(item); - child->setText(0, ref); - item->addChild(child); + && (!ref.mid(1).contains(":") || ref.left(1).contains(":")))) { + QTreeWidgetItem * child = + new QTreeWidgetItem(item); + child->setText(0, ref); + item->addChild(child); } } refsCats.append(item); -- 2.39.5