forked from qt-creator/qt-creator
Merge branch '1.1' of git@scm.dev.nokia.troll.no:creator/mainline into 1.1
This commit is contained in:
2
dist/changes-1.1.0
vendored
2
dist/changes-1.1.0
vendored
@@ -77,5 +77,3 @@ Lots of improvements to
|
|||||||
Additional credits go to:
|
Additional credits go to:
|
||||||
* Martin Aumueller <aumuell@reserv.at> (FakeVim improvements)
|
* Martin Aumueller <aumuell@reserv.at> (FakeVim improvements)
|
||||||
* Kris Wong (different patches)
|
* Kris Wong (different patches)
|
||||||
|
|
||||||
//TODO: this refers to commit c6419ff008bbf1afd2dfa4ed18a09de039cccef6
|
|
||||||
|
@@ -47,7 +47,7 @@ public:
|
|||||||
virtual ~IOutputPane() {}
|
virtual ~IOutputPane() {}
|
||||||
|
|
||||||
virtual QWidget *outputWidget(QWidget *parent) = 0;
|
virtual QWidget *outputWidget(QWidget *parent) = 0;
|
||||||
virtual QList<QWidget*> toolBarWidgets(void) const = 0;
|
virtual QList<QWidget*> toolBarWidgets() const = 0;
|
||||||
virtual QString name() const = 0;
|
virtual QString name() const = 0;
|
||||||
|
|
||||||
// -1 don't show in statusBar
|
// -1 don't show in statusBar
|
||||||
|
@@ -48,7 +48,7 @@ public:
|
|||||||
~MessageOutputWindow();
|
~MessageOutputWindow();
|
||||||
|
|
||||||
QWidget *outputWidget(QWidget *parent);
|
QWidget *outputWidget(QWidget *parent);
|
||||||
QList<QWidget*> toolBarWidgets(void) const { return QList<QWidget *>(); }
|
QList<QWidget*> toolBarWidgets() const { return QList<QWidget *>(); }
|
||||||
|
|
||||||
QString name() const;
|
QString name() const;
|
||||||
int priorityInStatusBar() const;
|
int priorityInStatusBar() const;
|
||||||
|
@@ -1073,20 +1073,6 @@ void CPPEditor::unCommentSelection()
|
|||||||
cursor.endEditBlock();
|
cursor.endEditBlock();
|
||||||
}
|
}
|
||||||
|
|
||||||
int CPPEditor::endOfNameAtPosition(int pos)
|
|
||||||
{
|
|
||||||
if (pos == -1)
|
|
||||||
pos = position();
|
|
||||||
|
|
||||||
QChar chr = characterAt(pos);
|
|
||||||
|
|
||||||
// Skip to the start of a name
|
|
||||||
while (chr.isLetterOrNumber() || chr == QLatin1Char('_'))
|
|
||||||
chr = characterAt(++pos);
|
|
||||||
|
|
||||||
return pos;
|
|
||||||
}
|
|
||||||
|
|
||||||
CPPEditor::Link CPPEditor::linkToSymbol(CPlusPlus::Symbol *symbol)
|
CPPEditor::Link CPPEditor::linkToSymbol(CPlusPlus::Symbol *symbol)
|
||||||
{
|
{
|
||||||
const QString fileName = QString::fromUtf8(symbol->fileName(),
|
const QString fileName = QString::fromUtf8(symbol->fileName(),
|
||||||
|
@@ -127,8 +127,6 @@ private:
|
|||||||
|
|
||||||
void createToolBar(CPPEditorEditable *editable);
|
void createToolBar(CPPEditorEditable *editable);
|
||||||
|
|
||||||
int endOfNameAtPosition(int pos);
|
|
||||||
|
|
||||||
struct Link
|
struct Link
|
||||||
{
|
{
|
||||||
Link(const QString &fileName = QString(),
|
Link(const QString &fileName = QString(),
|
||||||
|
@@ -46,7 +46,7 @@ public:
|
|||||||
DebuggerOutputWindow(QWidget *parent = 0);
|
DebuggerOutputWindow(QWidget *parent = 0);
|
||||||
|
|
||||||
QWidget *outputWidget(QWidget *) { return this; }
|
QWidget *outputWidget(QWidget *) { return this; }
|
||||||
QList<QWidget*> toolBarWidgets(void) const { return QList<QWidget *>(); }
|
QList<QWidget*> toolBarWidgets() const { return QList<QWidget *>(); }
|
||||||
|
|
||||||
QString name() const { return windowTitle(); }
|
QString name() const { return windowTitle(); }
|
||||||
void visibilityChanged(bool /*visible*/) {}
|
void visibilityChanged(bool /*visible*/) {}
|
||||||
|
@@ -90,10 +90,10 @@ int SearchResultTreeItemDelegate::drawLineNumber(QPainter *painter, const QStyle
|
|||||||
else if (!(option.state & QStyle::State_Enabled))
|
else if (!(option.state & QStyle::State_Enabled))
|
||||||
cg = QPalette::Disabled;
|
cg = QPalette::Disabled;
|
||||||
|
|
||||||
painter->fillRect(lineNumberAreaRect, QBrush(isSelected?
|
painter->fillRect(lineNumberAreaRect, QBrush(isSelected ?
|
||||||
option.palette.brush(cg, QPalette::Highlight):QBrush(qRgb(230, 230, 230))));
|
option.palette.brush(cg, QPalette::Highlight) : QBrush(qRgb(230, 230, 230))));
|
||||||
painter->setPen(isSelected?
|
painter->setPen(isSelected ?
|
||||||
option.palette.color(cg, QPalette::HighlightedText):Qt::darkGray);
|
option.palette.color(cg, QPalette::HighlightedText) : Qt::darkGray);
|
||||||
painter->drawText(lineNumberAreaRect.adjusted(0, 0, -lineNumberAreaHorizontalPadding, 0),
|
painter->drawText(lineNumberAreaRect.adjusted(0, 0, -lineNumberAreaHorizontalPadding, 0),
|
||||||
Qt::AlignRight, QString::number(lineNumber));
|
Qt::AlignRight, QString::number(lineNumber));
|
||||||
|
|
||||||
|
@@ -34,7 +34,7 @@ namespace Find {
|
|||||||
namespace Internal {
|
namespace Internal {
|
||||||
namespace ItemDataRoles {
|
namespace ItemDataRoles {
|
||||||
|
|
||||||
enum roles
|
enum Roles
|
||||||
{
|
{
|
||||||
TypeRole = Qt::UserRole,
|
TypeRole = Qt::UserRole,
|
||||||
FileNameRole,
|
FileNameRole,
|
||||||
@@ -49,6 +49,6 @@ enum roles
|
|||||||
|
|
||||||
} // namespace Internal
|
} // namespace Internal
|
||||||
} // namespace Find
|
} // namespace Find
|
||||||
} // namespace itemDataRoles
|
} // namespace ItemDataRoles
|
||||||
|
|
||||||
#endif // SEARCHRESULTTREEITEMROLES_H
|
#endif // SEARCHRESULTTREEITEMROLES_H
|
||||||
|
@@ -31,7 +31,7 @@
|
|||||||
|
|
||||||
using namespace Find::Internal;
|
using namespace Find::Internal;
|
||||||
|
|
||||||
SearchResultTreeItem::SearchResultTreeItem(SearchResultTreeItem::itemType type, const SearchResultTreeItem *parent)
|
SearchResultTreeItem::SearchResultTreeItem(SearchResultTreeItem::ItemType type, const SearchResultTreeItem *parent)
|
||||||
: m_type(type), m_parent(parent)
|
: m_type(type), m_parent(parent)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@@ -41,33 +41,33 @@ SearchResultTreeItem::~SearchResultTreeItem()
|
|||||||
clearChildren();
|
clearChildren();
|
||||||
}
|
}
|
||||||
|
|
||||||
void SearchResultTreeItem::clearChildren(void)
|
void SearchResultTreeItem::clearChildren()
|
||||||
{
|
{
|
||||||
qDeleteAll(m_children);
|
qDeleteAll(m_children);
|
||||||
m_children.clear();
|
m_children.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
SearchResultTreeItem::itemType SearchResultTreeItem::getItemType(void) const
|
SearchResultTreeItem::ItemType SearchResultTreeItem::itemType() const
|
||||||
{
|
{
|
||||||
return m_type;
|
return m_type;
|
||||||
}
|
}
|
||||||
|
|
||||||
int SearchResultTreeItem::getChildrenCount(void) const
|
int SearchResultTreeItem::childrenCount() const
|
||||||
{
|
{
|
||||||
return m_children.count();
|
return m_children.count();
|
||||||
}
|
}
|
||||||
|
|
||||||
int SearchResultTreeItem::getRowOfItem(void) const
|
int SearchResultTreeItem::rowOfItem() const
|
||||||
{
|
{
|
||||||
return (m_parent?m_parent->m_children.indexOf(const_cast<SearchResultTreeItem*>(this)):0);
|
return (m_parent ? m_parent->m_children.indexOf(const_cast<SearchResultTreeItem*>(this)):0);
|
||||||
}
|
}
|
||||||
|
|
||||||
const SearchResultTreeItem* SearchResultTreeItem::getChild(int index) const
|
const SearchResultTreeItem* SearchResultTreeItem::childAt(int index) const
|
||||||
{
|
{
|
||||||
return m_children.at(index);
|
return m_children.at(index);
|
||||||
}
|
}
|
||||||
|
|
||||||
const SearchResultTreeItem *SearchResultTreeItem::getParent(void) const
|
const SearchResultTreeItem *SearchResultTreeItem::parent() const
|
||||||
{
|
{
|
||||||
return m_parent;
|
return m_parent;
|
||||||
}
|
}
|
||||||
@@ -78,8 +78,10 @@ void SearchResultTreeItem::appendChild(SearchResultTreeItem *child)
|
|||||||
}
|
}
|
||||||
|
|
||||||
SearchResultTextRow::SearchResultTextRow(int index, int lineNumber,
|
SearchResultTextRow::SearchResultTextRow(int index, int lineNumber,
|
||||||
const QString &rowText, int searchTermStart, int searchTermLength, const SearchResultTreeItem *parent)
|
const QString &rowText,
|
||||||
: SearchResultTreeItem(resultRow, parent),
|
int searchTermStart, int searchTermLength,
|
||||||
|
const SearchResultTreeItem *parent):
|
||||||
|
SearchResultTreeItem(ResultRow, parent),
|
||||||
m_index(index),
|
m_index(index),
|
||||||
m_lineNumber(lineNumber),
|
m_lineNumber(lineNumber),
|
||||||
m_rowText(rowText),
|
m_rowText(rowText),
|
||||||
@@ -113,12 +115,13 @@ int SearchResultTextRow::searchTermLength() const
|
|||||||
return m_searchTermLength;
|
return m_searchTermLength;
|
||||||
}
|
}
|
||||||
|
|
||||||
SearchResultFile::SearchResultFile(const QString &fileName, const SearchResultTreeItem *parent)
|
SearchResultFile::SearchResultFile(const QString &fileName, const SearchResultTreeItem *parent):
|
||||||
: SearchResultTreeItem(resultFile, parent), m_fileName(fileName)
|
SearchResultTreeItem(ResultFile, parent),
|
||||||
|
m_fileName(fileName)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
QString SearchResultFile::getFileName(void) const
|
QString SearchResultFile::fileName() const
|
||||||
{
|
{
|
||||||
return m_fileName;
|
return m_fileName;
|
||||||
}
|
}
|
||||||
@@ -126,6 +129,7 @@ QString SearchResultFile::getFileName(void) const
|
|||||||
void SearchResultFile::appendResultLine(int index, int lineNumber, const QString &rowText, int searchTermStart,
|
void SearchResultFile::appendResultLine(int index, int lineNumber, const QString &rowText, int searchTermStart,
|
||||||
int searchTermLength)
|
int searchTermLength)
|
||||||
{
|
{
|
||||||
SearchResultTreeItem *child = new SearchResultTextRow(index, lineNumber, rowText, searchTermStart, searchTermLength, this);
|
SearchResultTreeItem *child = new SearchResultTextRow(index, lineNumber, rowText,
|
||||||
|
searchTermStart, searchTermLength, this);
|
||||||
appendChild(child);
|
appendChild(child);
|
||||||
}
|
}
|
||||||
|
@@ -42,31 +42,31 @@ class SearchResultTreeItem;
|
|||||||
class SearchResultTreeItem
|
class SearchResultTreeItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
enum itemType
|
enum ItemType
|
||||||
{
|
{
|
||||||
root,
|
Root,
|
||||||
resultRow,
|
ResultRow,
|
||||||
resultFile
|
ResultFile
|
||||||
};
|
};
|
||||||
|
|
||||||
SearchResultTreeItem(itemType type = root, const SearchResultTreeItem *parent = NULL);
|
SearchResultTreeItem(ItemType type = Root, const SearchResultTreeItem *parent = NULL);
|
||||||
virtual ~SearchResultTreeItem();
|
virtual ~SearchResultTreeItem();
|
||||||
|
|
||||||
itemType getItemType() const;
|
ItemType itemType() const;
|
||||||
const SearchResultTreeItem *getParent() const;
|
const SearchResultTreeItem *parent() const;
|
||||||
const SearchResultTreeItem *getChild(int index) const;
|
const SearchResultTreeItem *childAt(int index) const;
|
||||||
void appendChild(SearchResultTreeItem *child);
|
void appendChild(SearchResultTreeItem *child);
|
||||||
int getChildrenCount() const;
|
int childrenCount() const;
|
||||||
int getRowOfItem() const;
|
int rowOfItem() const;
|
||||||
void clearChildren();
|
void clearChildren();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
itemType m_type;
|
ItemType m_type;
|
||||||
const SearchResultTreeItem *m_parent;
|
const SearchResultTreeItem *m_parent;
|
||||||
QList<SearchResultTreeItem *> m_children;
|
QList<SearchResultTreeItem *> m_children;
|
||||||
};
|
};
|
||||||
|
|
||||||
class SearchResultTextRow: public SearchResultTreeItem
|
class SearchResultTextRow : public SearchResultTreeItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
SearchResultTextRow(int index, int lineNumber, const QString &rowText, int searchTermStart,
|
SearchResultTextRow(int index, int lineNumber, const QString &rowText, int searchTermStart,
|
||||||
@@ -85,11 +85,11 @@ private:
|
|||||||
int m_searchTermLength;
|
int m_searchTermLength;
|
||||||
};
|
};
|
||||||
|
|
||||||
class SearchResultFile: public SearchResultTreeItem
|
class SearchResultFile : public SearchResultTreeItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
SearchResultFile(const QString &fileName, const SearchResultTreeItem *parent);
|
SearchResultFile(const QString &fileName, const SearchResultTreeItem *parent);
|
||||||
QString getFileName() const;
|
QString fileName() const;
|
||||||
void appendResultLine(int index, int lineNumber, const QString &rowText, int searchTermStart,
|
void appendResultLine(int index, int lineNumber, const QString &rowText, int searchTermStart,
|
||||||
int searchTermLength);
|
int searchTermLength);
|
||||||
|
|
||||||
|
@@ -37,9 +37,11 @@
|
|||||||
using namespace Find::Internal;
|
using namespace Find::Internal;
|
||||||
|
|
||||||
SearchResultTreeModel::SearchResultTreeModel(QObject *parent)
|
SearchResultTreeModel::SearchResultTreeModel(QObject *parent)
|
||||||
: QAbstractItemModel(parent), m_lastAppendedResultFile(0)
|
: QAbstractItemModel(parent)
|
||||||
|
, m_lastAppendedResultFile(0)
|
||||||
{
|
{
|
||||||
m_rootItem = new SearchResultTreeItem();
|
m_rootItem = new SearchResultTreeItem();
|
||||||
|
m_textEditorFont = QFont("Courier");
|
||||||
}
|
}
|
||||||
|
|
||||||
SearchResultTreeModel::~SearchResultTreeModel()
|
SearchResultTreeModel::~SearchResultTreeModel()
|
||||||
@@ -47,6 +49,11 @@ SearchResultTreeModel::~SearchResultTreeModel()
|
|||||||
delete m_rootItem;
|
delete m_rootItem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void SearchResultTreeModel::setTextEditorFont(const QFont &font)
|
||||||
|
{
|
||||||
|
m_textEditorFont = font;
|
||||||
|
}
|
||||||
|
|
||||||
QModelIndex SearchResultTreeModel::index(int row, int column,
|
QModelIndex SearchResultTreeModel::index(int row, int column,
|
||||||
const QModelIndex &parent) const
|
const QModelIndex &parent) const
|
||||||
{
|
{
|
||||||
@@ -60,7 +67,7 @@ QModelIndex SearchResultTreeModel::index(int row, int column,
|
|||||||
else
|
else
|
||||||
parentItem = static_cast<const SearchResultTreeItem*>(parent.internalPointer());
|
parentItem = static_cast<const SearchResultTreeItem*>(parent.internalPointer());
|
||||||
|
|
||||||
const SearchResultTreeItem *childItem = parentItem->getChild(row);
|
const SearchResultTreeItem *childItem = parentItem->childAt(row);
|
||||||
if (childItem)
|
if (childItem)
|
||||||
return createIndex(row, column, (void *)childItem);
|
return createIndex(row, column, (void *)childItem);
|
||||||
else
|
else
|
||||||
@@ -73,12 +80,12 @@ QModelIndex SearchResultTreeModel::parent(const QModelIndex &index) const
|
|||||||
return QModelIndex();
|
return QModelIndex();
|
||||||
|
|
||||||
const SearchResultTreeItem *childItem = static_cast<const SearchResultTreeItem*>(index.internalPointer());
|
const SearchResultTreeItem *childItem = static_cast<const SearchResultTreeItem*>(index.internalPointer());
|
||||||
const SearchResultTreeItem *parentItem = childItem->getParent();
|
const SearchResultTreeItem *parentItem = childItem->parent();
|
||||||
|
|
||||||
if (parentItem == m_rootItem)
|
if (parentItem == m_rootItem)
|
||||||
return QModelIndex();
|
return QModelIndex();
|
||||||
|
|
||||||
return createIndex(parentItem->getRowOfItem(), 0, (void *)parentItem);
|
return createIndex(parentItem->rowOfItem(), 0, (void *)parentItem);
|
||||||
}
|
}
|
||||||
|
|
||||||
int SearchResultTreeModel::rowCount(const QModelIndex &parent) const
|
int SearchResultTreeModel::rowCount(const QModelIndex &parent) const
|
||||||
@@ -93,7 +100,7 @@ int SearchResultTreeModel::rowCount(const QModelIndex &parent) const
|
|||||||
else
|
else
|
||||||
parentItem = static_cast<const SearchResultTreeItem*>(parent.internalPointer());
|
parentItem = static_cast<const SearchResultTreeItem*>(parent.internalPointer());
|
||||||
|
|
||||||
return parentItem->getChildrenCount();
|
return parentItem->childrenCount();
|
||||||
}
|
}
|
||||||
|
|
||||||
int SearchResultTreeModel::columnCount(const QModelIndex &parent) const
|
int SearchResultTreeModel::columnCount(const QModelIndex &parent) const
|
||||||
@@ -111,12 +118,12 @@ QVariant SearchResultTreeModel::data(const QModelIndex &index, int role) const
|
|||||||
|
|
||||||
QVariant result;
|
QVariant result;
|
||||||
|
|
||||||
if (item->getItemType() == SearchResultTreeItem::resultRow)
|
if (item->itemType() == SearchResultTreeItem::ResultRow)
|
||||||
{
|
{
|
||||||
const SearchResultTextRow *row = static_cast<const SearchResultTextRow *>(item);
|
const SearchResultTextRow *row = static_cast<const SearchResultTextRow *>(item);
|
||||||
result = data(row, role);
|
result = data(row, role);
|
||||||
}
|
}
|
||||||
else if (item->getItemType() == SearchResultTreeItem::resultFile)
|
else if (item->itemType() == SearchResultTreeItem::ResultFile)
|
||||||
{
|
{
|
||||||
const SearchResultFile *file = static_cast<const SearchResultFile *>(item);
|
const SearchResultFile *file = static_cast<const SearchResultFile *>(item);
|
||||||
result = data(file, role);
|
result = data(file, role);
|
||||||
@@ -135,7 +142,7 @@ QVariant SearchResultTreeModel::data(const SearchResultTextRow *row, int role) c
|
|||||||
result = row->rowText().trimmed();
|
result = row->rowText().trimmed();
|
||||||
break;
|
break;
|
||||||
case Qt::FontRole:
|
case Qt::FontRole:
|
||||||
result = QFont("courier");
|
result = m_textEditorFont;
|
||||||
break;
|
break;
|
||||||
case ItemDataRoles::ResultLineRole:
|
case ItemDataRoles::ResultLineRole:
|
||||||
case Qt::DisplayRole:
|
case Qt::DisplayRole:
|
||||||
@@ -158,8 +165,8 @@ QVariant SearchResultTreeModel::data(const SearchResultTextRow *row, int role) c
|
|||||||
break;
|
break;
|
||||||
case ItemDataRoles::FileNameRole:
|
case ItemDataRoles::FileNameRole:
|
||||||
{
|
{
|
||||||
const SearchResultFile *file = dynamic_cast<const SearchResultFile *>(row->getParent());
|
const SearchResultFile *file = dynamic_cast<const SearchResultFile *>(row->parent());
|
||||||
result = file->getFileName();
|
result = file->fileName();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
@@ -179,22 +186,15 @@ QVariant SearchResultTreeModel::data(const SearchResultFile *file, int role) con
|
|||||||
case Qt::BackgroundRole:
|
case Qt::BackgroundRole:
|
||||||
result = QColor(qRgb(245, 245, 245));
|
result = QColor(qRgb(245, 245, 245));
|
||||||
break;
|
break;
|
||||||
case Qt::FontRole:
|
|
||||||
{
|
|
||||||
QFont font;
|
|
||||||
font.setPointSize(font.pointSize() + 1);
|
|
||||||
result = font;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case Qt::DisplayRole:
|
case Qt::DisplayRole:
|
||||||
result = file->getFileName() + " (" + QString::number(file->getChildrenCount()) + ")";
|
result = file->fileName() + " (" + QString::number(file->childrenCount()) + ")";
|
||||||
break;
|
break;
|
||||||
case ItemDataRoles::FileNameRole:
|
case ItemDataRoles::FileNameRole:
|
||||||
case Qt::ToolTipRole:
|
case Qt::ToolTipRole:
|
||||||
result = file->getFileName();
|
result = file->fileName();
|
||||||
break;
|
break;
|
||||||
case ItemDataRoles::ResultLinesCountRole:
|
case ItemDataRoles::ResultLinesCountRole:
|
||||||
result = file->getChildrenCount();
|
result = file->childrenCount();
|
||||||
break;
|
break;
|
||||||
case ItemDataRoles::TypeRole:
|
case ItemDataRoles::TypeRole:
|
||||||
result = "file";
|
result = "file";
|
||||||
@@ -220,20 +220,20 @@ void SearchResultTreeModel::appendResultFile(const QString &fileName)
|
|||||||
{
|
{
|
||||||
m_lastAppendedResultFile = new SearchResultFile(fileName, m_rootItem);
|
m_lastAppendedResultFile = new SearchResultFile(fileName, m_rootItem);
|
||||||
|
|
||||||
beginInsertRows(QModelIndex(), m_rootItem->getChildrenCount(), m_rootItem->getChildrenCount());
|
beginInsertRows(QModelIndex(), m_rootItem->childrenCount(), m_rootItem->childrenCount());
|
||||||
m_rootItem->appendChild(m_lastAppendedResultFile);
|
m_rootItem->appendChild(m_lastAppendedResultFile);
|
||||||
endInsertRows();
|
endInsertRows();
|
||||||
}
|
}
|
||||||
|
|
||||||
void SearchResultTreeModel::appendResultLine(int index, int lineNumber, const QString &rowText, int searchTermStart,
|
void SearchResultTreeModel::appendResultLine(int index, int lineNumber, const QString &rowText,
|
||||||
int searchTermLength)
|
int searchTermStart, int searchTermLength)
|
||||||
{
|
{
|
||||||
if (!m_lastAppendedResultFile)
|
if (!m_lastAppendedResultFile)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
QModelIndex lastFile(createIndex(m_lastAppendedResultFile->getRowOfItem(), 0, m_lastAppendedResultFile));
|
QModelIndex lastFile(createIndex(m_lastAppendedResultFile->rowOfItem(), 0, m_lastAppendedResultFile));
|
||||||
|
|
||||||
beginInsertRows(lastFile, m_lastAppendedResultFile->getChildrenCount(), m_lastAppendedResultFile->getChildrenCount());
|
beginInsertRows(lastFile, m_lastAppendedResultFile->childrenCount(), m_lastAppendedResultFile->childrenCount());
|
||||||
m_lastAppendedResultFile->appendResultLine(index, lineNumber, rowText, searchTermStart, searchTermLength);
|
m_lastAppendedResultFile->appendResultLine(index, lineNumber, rowText, searchTermStart, searchTermLength);
|
||||||
endInsertRows();
|
endInsertRows();
|
||||||
|
|
||||||
@@ -243,13 +243,13 @@ void SearchResultTreeModel::appendResultLine(int index, int lineNumber, const QS
|
|||||||
void SearchResultTreeModel::appendResultLine(int index, const QString &fileName, int lineNumber, const QString &rowText,
|
void SearchResultTreeModel::appendResultLine(int index, const QString &fileName, int lineNumber, const QString &rowText,
|
||||||
int searchTermStart, int searchTermLength)
|
int searchTermStart, int searchTermLength)
|
||||||
{
|
{
|
||||||
if (!m_lastAppendedResultFile || (m_lastAppendedResultFile->getFileName() != fileName))
|
if (!m_lastAppendedResultFile || (m_lastAppendedResultFile->fileName() != fileName))
|
||||||
appendResultFile(fileName);
|
appendResultFile(fileName);
|
||||||
|
|
||||||
appendResultLine(index, lineNumber, rowText, searchTermStart, searchTermLength);
|
appendResultLine(index, lineNumber, rowText, searchTermStart, searchTermLength);
|
||||||
}
|
}
|
||||||
|
|
||||||
void SearchResultTreeModel::clear(void)
|
void SearchResultTreeModel::clear()
|
||||||
{
|
{
|
||||||
m_lastAppendedResultFile = NULL;
|
m_lastAppendedResultFile = NULL;
|
||||||
m_rootItem->clearChildren();
|
m_rootItem->clearChildren();
|
||||||
|
@@ -31,6 +31,7 @@
|
|||||||
#define SEARCHRESULTTREEMODEL_H
|
#define SEARCHRESULTTREEMODEL_H
|
||||||
|
|
||||||
#include <QtCore/QAbstractItemModel>
|
#include <QtCore/QAbstractItemModel>
|
||||||
|
#include <QtGui/QFont>
|
||||||
|
|
||||||
namespace Find {
|
namespace Find {
|
||||||
namespace Internal {
|
namespace Internal {
|
||||||
@@ -47,8 +48,9 @@ public:
|
|||||||
SearchResultTreeModel(QObject *parent = 0);
|
SearchResultTreeModel(QObject *parent = 0);
|
||||||
~SearchResultTreeModel();
|
~SearchResultTreeModel();
|
||||||
|
|
||||||
QModelIndex index(int row, int column,
|
void setTextEditorFont(const QFont &font);
|
||||||
const QModelIndex &parent = QModelIndex()) const;
|
|
||||||
|
QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const;
|
||||||
QModelIndex parent(const QModelIndex &child) const;
|
QModelIndex parent(const QModelIndex &child) const;
|
||||||
int rowCount(const QModelIndex &parent = QModelIndex()) const;
|
int rowCount(const QModelIndex &parent = QModelIndex()) const;
|
||||||
int columnCount(const QModelIndex &parent = QModelIndex()) const;
|
int columnCount(const QModelIndex &parent = QModelIndex()) const;
|
||||||
@@ -62,20 +64,21 @@ signals:
|
|||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void clear();
|
void clear();
|
||||||
void appendResultLine(int index, int lineNumber, const QString &rowText, int searchTermStart,
|
void appendResultLine(int index, int lineNumber, const QString &rowText,
|
||||||
int searchTermLength);
|
int searchTermStart, int searchTermLength);
|
||||||
void appendResultLine(int index, const QString &fileName, int lineNumber, const QString &rowText, int searchTermStart,
|
void appendResultLine(int index, const QString &fileName, int lineNumber, const QString &rowText,
|
||||||
int searchTermLength);
|
int searchTermStart, int searchTermLength);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void appendResultFile(const QString &fileName);
|
void appendResultFile(const QString &fileName);
|
||||||
QVariant data(const SearchResultTextRow *row, int role) const;
|
QVariant data(const SearchResultTextRow *row, int role) const;
|
||||||
QVariant data(const SearchResultFile *file, int role) const;
|
QVariant data(const SearchResultFile *file, int role) const;
|
||||||
void initializeData(void);
|
void initializeData();
|
||||||
void disposeData(void);
|
void disposeData();
|
||||||
|
|
||||||
SearchResultTreeItem *m_rootItem;
|
SearchResultTreeItem *m_rootItem;
|
||||||
SearchResultFile *m_lastAppendedResultFile;
|
SearchResultFile *m_lastAppendedResultFile;
|
||||||
|
QFont m_textEditorFont;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace Internal
|
} // namespace Internal
|
||||||
|
@@ -37,7 +37,8 @@
|
|||||||
using namespace Find::Internal;
|
using namespace Find::Internal;
|
||||||
|
|
||||||
SearchResultTreeView::SearchResultTreeView(QWidget *parent)
|
SearchResultTreeView::SearchResultTreeView(QWidget *parent)
|
||||||
: QTreeView(parent), m_autoExpandResults(false)
|
: QTreeView(parent)
|
||||||
|
, m_autoExpandResults(false)
|
||||||
{
|
{
|
||||||
m_model = new SearchResultTreeModel(this);
|
m_model = new SearchResultTreeModel(this);
|
||||||
setModel(m_model);
|
setModel(m_model);
|
||||||
@@ -46,7 +47,7 @@ SearchResultTreeView::SearchResultTreeView(QWidget *parent)
|
|||||||
setIndentation(14);
|
setIndentation(14);
|
||||||
header()->hide();
|
header()->hide();
|
||||||
|
|
||||||
connect (this, SIGNAL(activated(QModelIndex)), this, SLOT(emitJumpToSearchResult(QModelIndex)));
|
connect(this, SIGNAL(activated(QModelIndex)), this, SLOT(emitJumpToSearchResult(QModelIndex)));
|
||||||
}
|
}
|
||||||
|
|
||||||
void SearchResultTreeView::setAutoExpandResults(bool expand)
|
void SearchResultTreeView::setAutoExpandResults(bool expand)
|
||||||
@@ -54,7 +55,12 @@ void SearchResultTreeView::setAutoExpandResults(bool expand)
|
|||||||
m_autoExpandResults = expand;
|
m_autoExpandResults = expand;
|
||||||
}
|
}
|
||||||
|
|
||||||
void SearchResultTreeView::clear(void)
|
void SearchResultTreeView::setTextEditorFont(const QFont &font)
|
||||||
|
{
|
||||||
|
m_model->setTextEditorFont(font);
|
||||||
|
}
|
||||||
|
|
||||||
|
void SearchResultTreeView::clear()
|
||||||
{
|
{
|
||||||
m_model->clear();
|
m_model->clear();
|
||||||
}
|
}
|
||||||
|
@@ -44,7 +44,9 @@ class SearchResultTreeView : public QTreeView
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
SearchResultTreeView(QWidget *parent = 0);
|
SearchResultTreeView(QWidget *parent = 0);
|
||||||
|
|
||||||
void setAutoExpandResults(bool expand);
|
void setAutoExpandResults(bool expand);
|
||||||
|
void setTextEditorFont(const QFont &font);
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void jumpToSearchResult(int index, const QString &fileName, int lineNumber,
|
void jumpToSearchResult(int index, const QString &fileName, int lineNumber,
|
||||||
|
@@ -82,6 +82,43 @@ SearchResultWindow::~SearchResultWindow()
|
|||||||
m_items.clear();
|
m_items.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void SearchResultWindow::visibilityChanged(bool /*visible*/)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
QWidget *SearchResultWindow::outputWidget(QWidget *)
|
||||||
|
{
|
||||||
|
return m_widget;
|
||||||
|
}
|
||||||
|
|
||||||
|
QList<QWidget*> SearchResultWindow::toolBarWidgets() const
|
||||||
|
{
|
||||||
|
return QList<QWidget*>() << m_expandCollapseToolButton;
|
||||||
|
}
|
||||||
|
|
||||||
|
void SearchResultWindow::clearContents()
|
||||||
|
{
|
||||||
|
m_widget->setCurrentWidget(m_searchResultTreeView);
|
||||||
|
m_searchResultTreeView->clear();
|
||||||
|
qDeleteAll(m_items);
|
||||||
|
m_items.clear();
|
||||||
|
}
|
||||||
|
|
||||||
|
void SearchResultWindow::showNoMatchesFound()
|
||||||
|
{
|
||||||
|
m_widget->setCurrentWidget(m_noMatchesFoundDisplay);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool SearchResultWindow::isEmpty() const
|
||||||
|
{
|
||||||
|
return (m_searchResultTreeView->model()->rowCount() < 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
int SearchResultWindow::numberOfResults() const
|
||||||
|
{
|
||||||
|
return m_searchResultTreeView->model()->rowCount();
|
||||||
|
}
|
||||||
|
|
||||||
bool SearchResultWindow::hasFocus()
|
bool SearchResultWindow::hasFocus()
|
||||||
{
|
{
|
||||||
return m_searchResultTreeView->hasFocus();
|
return m_searchResultTreeView->hasFocus();
|
||||||
@@ -98,41 +135,9 @@ void SearchResultWindow::setFocus()
|
|||||||
m_searchResultTreeView->setFocus();
|
m_searchResultTreeView->setFocus();
|
||||||
}
|
}
|
||||||
|
|
||||||
void SearchResultWindow::visibilityChanged(bool /*visible*/)
|
void SearchResultWindow::setTextEditorFont(const QFont &font)
|
||||||
{
|
{
|
||||||
}
|
m_searchResultTreeView->setTextEditorFont(font);
|
||||||
|
|
||||||
QWidget *SearchResultWindow::outputWidget(QWidget *)
|
|
||||||
{
|
|
||||||
return m_widget;
|
|
||||||
}
|
|
||||||
|
|
||||||
QList<QWidget*> SearchResultWindow::toolBarWidgets(void) const
|
|
||||||
{
|
|
||||||
return QList<QWidget*>() << m_expandCollapseToolButton;
|
|
||||||
}
|
|
||||||
|
|
||||||
void SearchResultWindow::clearContents()
|
|
||||||
{
|
|
||||||
m_widget->setCurrentWidget(m_searchResultTreeView);
|
|
||||||
m_searchResultTreeView->clear();
|
|
||||||
qDeleteAll(m_items);
|
|
||||||
m_items.clear();
|
|
||||||
}
|
|
||||||
|
|
||||||
void SearchResultWindow::showNoMatchesFound(void)
|
|
||||||
{
|
|
||||||
m_widget->setCurrentWidget(m_noMatchesFoundDisplay);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool SearchResultWindow::isEmpty() const
|
|
||||||
{
|
|
||||||
return (m_searchResultTreeView->model()->rowCount() < 1);
|
|
||||||
}
|
|
||||||
|
|
||||||
int SearchResultWindow::numberOfResults() const
|
|
||||||
{
|
|
||||||
return m_searchResultTreeView->model()->rowCount();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void SearchResultWindow::handleJumpToSearchResult(int index, const QString &fileName, int lineNumber,
|
void SearchResultWindow::handleJumpToSearchResult(int index, const QString &fileName, int lineNumber,
|
||||||
@@ -169,7 +174,7 @@ void SearchResultWindow::handleExpandCollapseToolButton(bool checked)
|
|||||||
m_searchResultTreeView->collapseAll();
|
m_searchResultTreeView->collapseAll();
|
||||||
}
|
}
|
||||||
|
|
||||||
void SearchResultWindow::readSettings(void)
|
void SearchResultWindow::readSettings()
|
||||||
{
|
{
|
||||||
QSettings *s = Core::ICore::instance()->settings();
|
QSettings *s = Core::ICore::instance()->settings();
|
||||||
if (s) {
|
if (s) {
|
||||||
@@ -179,7 +184,7 @@ void SearchResultWindow::readSettings(void)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void SearchResultWindow::writeSettings(void)
|
void SearchResultWindow::writeSettings()
|
||||||
{
|
{
|
||||||
QSettings *s = Core::ICore::instance()->settings();
|
QSettings *s = Core::ICore::instance()->settings();
|
||||||
if (s) {
|
if (s) {
|
||||||
|
@@ -64,7 +64,7 @@ public:
|
|||||||
~SearchResultWindow();
|
~SearchResultWindow();
|
||||||
|
|
||||||
QWidget *outputWidget(QWidget *);
|
QWidget *outputWidget(QWidget *);
|
||||||
QList<QWidget*> toolBarWidgets(void) const;
|
QList<QWidget*> toolBarWidgets() const;
|
||||||
|
|
||||||
QString name() const { return tr("Search Results"); }
|
QString name() const { return tr("Search Results"); }
|
||||||
int priorityInStatusBar() const;
|
int priorityInStatusBar() const;
|
||||||
@@ -75,6 +75,8 @@ public:
|
|||||||
bool canFocus();
|
bool canFocus();
|
||||||
void setFocus();
|
void setFocus();
|
||||||
|
|
||||||
|
void setTextEditorFont(const QFont &font);
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void clearContents();
|
void clearContents();
|
||||||
void showNoMatchesFound();
|
void showNoMatchesFound();
|
||||||
|
@@ -50,7 +50,7 @@ using namespace Core::Utils;
|
|||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
class DirModel: public QDirModel
|
class DirModel : public QDirModel
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
DirModel(QObject *parent)
|
DirModel(QObject *parent)
|
||||||
@@ -178,6 +178,11 @@ QString GenericProjectWizardDialog::path() const
|
|||||||
return m_firstPage->path();
|
return m_firstPage->path();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void GenericProjectWizardDialog::setPath(const QString &path)
|
||||||
|
{
|
||||||
|
m_firstPage->setPath(path);
|
||||||
|
}
|
||||||
|
|
||||||
QString GenericProjectWizardDialog::projectName() const
|
QString GenericProjectWizardDialog::projectName() const
|
||||||
{
|
{
|
||||||
return m_firstPage->name();
|
return m_firstPage->name();
|
||||||
@@ -201,6 +206,7 @@ void GenericProjectWizardDialog::updateFilesView(const QModelIndex ¤t,
|
|||||||
|
|
||||||
void GenericProjectWizardDialog::initializePage(int id)
|
void GenericProjectWizardDialog::initializePage(int id)
|
||||||
{
|
{
|
||||||
|
Q_UNUSED(id)
|
||||||
#if 0
|
#if 0
|
||||||
if (id == m_secondPageId) {
|
if (id == m_secondPageId) {
|
||||||
using namespace Core::Utils;
|
using namespace Core::Utils;
|
||||||
@@ -251,6 +257,8 @@ QWizard *GenericProjectWizard::createWizardDialog(QWidget *parent,
|
|||||||
GenericProjectWizardDialog *wizard = new GenericProjectWizardDialog(parent);
|
GenericProjectWizardDialog *wizard = new GenericProjectWizardDialog(parent);
|
||||||
setupWizard(wizard);
|
setupWizard(wizard);
|
||||||
|
|
||||||
|
wizard->setPath(defaultPath);
|
||||||
|
|
||||||
foreach (QWizardPage *p, extensionPages)
|
foreach (QWizardPage *p, extensionPages)
|
||||||
wizard->addPage(p);
|
wizard->addPage(p);
|
||||||
|
|
||||||
@@ -302,6 +310,8 @@ bool GenericProjectWizard::isValidDir(const QFileInfo &fileInfo) const
|
|||||||
Core::GeneratedFiles GenericProjectWizard::generateFiles(const QWizard *w,
|
Core::GeneratedFiles GenericProjectWizard::generateFiles(const QWizard *w,
|
||||||
QString *errorMessage) const
|
QString *errorMessage) const
|
||||||
{
|
{
|
||||||
|
Q_UNUSED(errorMessage)
|
||||||
|
|
||||||
const GenericProjectWizardDialog *wizard = qobject_cast<const GenericProjectWizardDialog *>(w);
|
const GenericProjectWizardDialog *wizard = qobject_cast<const GenericProjectWizardDialog *>(w);
|
||||||
const QString projectPath = wizard->path();
|
const QString projectPath = wizard->path();
|
||||||
const QDir dir(projectPath);
|
const QDir dir(projectPath);
|
||||||
|
@@ -64,6 +64,8 @@ public:
|
|||||||
virtual ~GenericProjectWizardDialog();
|
virtual ~GenericProjectWizardDialog();
|
||||||
|
|
||||||
QString path() const;
|
QString path() const;
|
||||||
|
void setPath(const QString &path);
|
||||||
|
|
||||||
QString projectName() const;
|
QString projectName() const;
|
||||||
|
|
||||||
private Q_SLOTS:
|
private Q_SLOTS:
|
||||||
|
@@ -50,7 +50,7 @@ public:
|
|||||||
~PerforceOutputWindow();
|
~PerforceOutputWindow();
|
||||||
|
|
||||||
QWidget *outputWidget(QWidget *parent);
|
QWidget *outputWidget(QWidget *parent);
|
||||||
QList<QWidget*> toolBarWidgets(void) const { return QList<QWidget *>(); }
|
QList<QWidget*> toolBarWidgets() const { return QList<QWidget *>(); }
|
||||||
|
|
||||||
QString name() const;
|
QString name() const;
|
||||||
int priorityInStatusBar() const;
|
int priorityInStatusBar() const;
|
||||||
|
@@ -47,7 +47,7 @@ class CompileOutputWindow : public Core::IOutputPane
|
|||||||
public:
|
public:
|
||||||
CompileOutputWindow(BuildManager *bm);
|
CompileOutputWindow(BuildManager *bm);
|
||||||
QWidget *outputWidget(QWidget *);
|
QWidget *outputWidget(QWidget *);
|
||||||
QList<QWidget*> toolBarWidgets(void) const { return QList<QWidget *>(); }
|
QList<QWidget*> toolBarWidgets() const { return QList<QWidget *>(); }
|
||||||
QString name() const { return tr("Compile Output"); }
|
QString name() const { return tr("Compile Output"); }
|
||||||
int priorityInStatusBar() const;
|
int priorityInStatusBar() const;
|
||||||
void clearContents();
|
void clearContents();
|
||||||
|
@@ -61,7 +61,7 @@ public:
|
|||||||
~OutputPane();
|
~OutputPane();
|
||||||
|
|
||||||
QWidget *outputWidget(QWidget *);
|
QWidget *outputWidget(QWidget *);
|
||||||
QList<QWidget*> toolBarWidgets(void) const;
|
QList<QWidget*> toolBarWidgets() const;
|
||||||
QString name() const;
|
QString name() const;
|
||||||
int priorityInStatusBar() const;
|
int priorityInStatusBar() const;
|
||||||
void clearContents();
|
void clearContents();
|
||||||
|
@@ -56,7 +56,7 @@ public:
|
|||||||
~TaskWindow();
|
~TaskWindow();
|
||||||
|
|
||||||
QWidget *outputWidget(QWidget *);
|
QWidget *outputWidget(QWidget *);
|
||||||
QList<QWidget*> toolBarWidgets(void) const;
|
QList<QWidget*> toolBarWidgets() const;
|
||||||
|
|
||||||
QString name() const { return tr("Build Issues"); }
|
QString name() const { return tr("Build Issues"); }
|
||||||
int priorityInStatusBar() const;
|
int priorityInStatusBar() const;
|
||||||
|
@@ -56,21 +56,21 @@ class InfoItemConfigurationCross : public SPEInfoItem
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemConfigurationCross(): SPEInfoItem("", Configuration) {}
|
InfoItemConfigurationCross(): SPEInfoItem("", Configuration) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Debug and Release"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Debug and Release"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
class InfoItemConfigurationDebug : public SPEInfoItem
|
class InfoItemConfigurationDebug : public SPEInfoItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemConfigurationDebug(): SPEInfoItem("debug", Configuration) {}
|
InfoItemConfigurationDebug(): SPEInfoItem("debug", Configuration) {}
|
||||||
QString name(void) const {return QCoreApplication::translate("SimpleProEditor", "Debug specific");}
|
QString name() const {return QCoreApplication::translate("SimpleProEditor", "Debug specific");}
|
||||||
};
|
};
|
||||||
|
|
||||||
class InfoItemConfigurationRelease : public SPEInfoItem
|
class InfoItemConfigurationRelease : public SPEInfoItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemConfigurationRelease(): SPEInfoItem("release", Configuration) {}
|
InfoItemConfigurationRelease(): SPEInfoItem("release", Configuration) {}
|
||||||
QString name(void) const {return QCoreApplication::translate("SimpleProEditor", "Release specific");}
|
QString name() const {return QCoreApplication::translate("SimpleProEditor", "Release specific");}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@@ -79,28 +79,28 @@ class InfoItemPlatformCross : public SPEInfoItem
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemPlatformCross(): SPEInfoItem("", Platform) {}
|
InfoItemPlatformCross(): SPEInfoItem("", Platform) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "All platforms"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "All platforms"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
class InfoItemPlatformWindows : public SPEInfoItem
|
class InfoItemPlatformWindows : public SPEInfoItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemPlatformWindows(): SPEInfoItem("win32", Platform) {}
|
InfoItemPlatformWindows(): SPEInfoItem("win32", Platform) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "MS Windows specific"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "MS Windows specific"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
class InfoItemPlatformUnix : public SPEInfoItem
|
class InfoItemPlatformUnix : public SPEInfoItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemPlatformUnix(): SPEInfoItem("unix", Platform) {}
|
InfoItemPlatformUnix(): SPEInfoItem("unix", Platform) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Linux/Unix specific"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Linux/Unix specific"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
class InfoItemPlatformOSX : public SPEInfoItem
|
class InfoItemPlatformOSX : public SPEInfoItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemPlatformOSX(): SPEInfoItem("macx", Platform) {}
|
InfoItemPlatformOSX(): SPEInfoItem("macx", Platform) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Mac OSX specific"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Mac OSX specific"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@@ -113,8 +113,8 @@ public:
|
|||||||
m_data.insert(keyImageFileName, ":/variableimages/images/target.png");
|
m_data.insert(keyImageFileName, ":/variableimages/images/target.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Target Options");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Target Options");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Type and name of the target.");
|
"Type and name of the target.");
|
||||||
@@ -129,8 +129,8 @@ public:
|
|||||||
m_data.insert(keyImageFileName, ":/variableimages/images/defines.png");
|
m_data.insert(keyImageFileName, ":/variableimages/images/defines.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Preprocessor Definitions");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Preprocessor Definitions");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Setting of the preprocessor definitions.");
|
"Setting of the preprocessor definitions.");
|
||||||
@@ -146,8 +146,8 @@ public:
|
|||||||
m_data.insert(keyImageFileName, ":/variableimages/images/includes.png");
|
m_data.insert(keyImageFileName, ":/variableimages/images/includes.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Include path"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Include path"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Setting of the pathes where the header files are located.");
|
"Setting of the pathes where the header files are located.");
|
||||||
@@ -162,8 +162,8 @@ public:
|
|||||||
m_data.insert(keyImageFileName, ":/variableimages/images/libs.png");
|
m_data.insert(keyImageFileName, ":/variableimages/images/libs.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Libraries");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Libraries");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Defining the libraries to link the target against and the pathes where these are located.");
|
"Defining the libraries to link the target against and the pathes where these are located.");
|
||||||
@@ -179,8 +179,8 @@ public:
|
|||||||
m_data.insert(keyImageFileName, ":/variableimages/images/sources.png");
|
m_data.insert(keyImageFileName, ":/variableimages/images/sources.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Source Files");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Source Files");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"");
|
"");
|
||||||
@@ -196,8 +196,8 @@ public:
|
|||||||
m_data.insert(keyImageFileName, ":/variableimages/images/headers.png");
|
m_data.insert(keyImageFileName, ":/variableimages/images/headers.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Header Files");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Header Files");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"");
|
"");
|
||||||
@@ -213,8 +213,8 @@ public:
|
|||||||
m_data.insert(keyImageFileName, ":/variableimages/images/forms.png");
|
m_data.insert(keyImageFileName, ":/variableimages/images/forms.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Forms");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Forms");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"");
|
"");
|
||||||
@@ -229,8 +229,8 @@ public:
|
|||||||
m_data.insert(keyImageFileName, ":/variableimages/images/qtmodules.png");
|
m_data.insert(keyImageFileName, ":/variableimages/images/qtmodules.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Qt Modules");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Qt Modules");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Setting up which of the Qt modules will be used in the target application.");
|
"Setting up which of the Qt modules will be used in the target application.");
|
||||||
@@ -246,8 +246,8 @@ public:
|
|||||||
m_data.insert(keyImageFileName, ":/variableimages/images/resources.png");
|
m_data.insert(keyImageFileName, ":/variableimages/images/resources.png");
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Resource files");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Resource files");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"");
|
"");
|
||||||
@@ -258,8 +258,8 @@ class InfoItemVariableTarget : public SPEInfoItem
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemVariableTarget(): SPEInfoItem("TARGET", Variable) {}
|
InfoItemVariableTarget(): SPEInfoItem("TARGET", Variable) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Target name");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Target name");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"The name of the resulting target.");
|
"The name of the resulting target.");
|
||||||
@@ -270,8 +270,8 @@ class InfoItemVariableConfig : public SPEInfoItem
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemVariableConfig(): SPEInfoItem("CONFIG", Variable) {}
|
InfoItemVariableConfig(): SPEInfoItem("CONFIG", Variable) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Configuration");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Configuration");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Configuration.");
|
"Configuration.");
|
||||||
@@ -282,8 +282,8 @@ class InfoItemVariableDestdir : public SPEInfoItem
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemVariableDestdir(): SPEInfoItem("DESTDIR", Variable) {}
|
InfoItemVariableDestdir(): SPEInfoItem("DESTDIR", Variable) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Destination directory");}
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Destination directory");}
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Where the resulting target will be created.");
|
"Where the resulting target will be created.");
|
||||||
@@ -300,8 +300,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, true);
|
m_data.insert(keyIncludedByDefault, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtCore Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtCore Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Core non-GUI classes used by other modules");
|
"Core non-GUI classes used by other modules");
|
||||||
@@ -316,8 +316,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, true);
|
m_data.insert(keyIncludedByDefault, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtGui Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtGui Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Graphical user interface components");
|
"Graphical user interface components");
|
||||||
@@ -332,8 +332,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtNetwork Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtNetwork Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Classes for network programming");
|
"Classes for network programming");
|
||||||
@@ -348,8 +348,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtOpenGL Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtOpenGL Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"OpenGL support classes");
|
"OpenGL support classes");
|
||||||
@@ -364,8 +364,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtSql Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtSql Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Classes for database integration using SQL");
|
"Classes for database integration using SQL");
|
||||||
@@ -380,8 +380,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtScript Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtScript Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Classes for evaluating Qt Scripts");
|
"Classes for evaluating Qt Scripts");
|
||||||
@@ -396,8 +396,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtSvg Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtSvg Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Classes for displaying the contents of SVG files");
|
"Classes for displaying the contents of SVG files");
|
||||||
@@ -412,8 +412,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtWebKit Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtWebKit Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Classes for displaying and editing Web content");
|
"Classes for displaying and editing Web content");
|
||||||
@@ -428,8 +428,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtXml Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtXml Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Classes for handling XML");
|
"Classes for handling XML");
|
||||||
@@ -444,8 +444,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtXmlPatterns Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtXmlPatterns Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"An XQuery/XPath engine for XML and custom data models");
|
"An XQuery/XPath engine for XML and custom data models");
|
||||||
@@ -460,8 +460,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Phonon Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Phonon Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Multimedia framework classes");
|
"Multimedia framework classes");
|
||||||
@@ -476,8 +476,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Qt3Support Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Qt3Support Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Classes that ease porting from Qt 3 to Qt 4");
|
"Classes that ease porting from Qt 3 to Qt 4");
|
||||||
@@ -492,8 +492,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtTest Module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtTest Module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Tool classes for unit testing");
|
"Tool classes for unit testing");
|
||||||
@@ -508,8 +508,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "QtDBus module"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "QtDBus module"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Classes for Inter-Process Communication using the D-Bus");
|
"Classes for Inter-Process Communication using the D-Bus");
|
||||||
@@ -526,8 +526,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Application"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Application"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Create a standalone application");
|
"Create a standalone application");
|
||||||
@@ -542,8 +542,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Dynamic Library"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Dynamic Library"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Create a dynamic library for usage in other applications");
|
"Create a dynamic library for usage in other applications");
|
||||||
@@ -558,8 +558,8 @@ public:
|
|||||||
m_data.insert(keyIncludedByDefault, false);
|
m_data.insert(keyIncludedByDefault, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Static Library"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Static Library"); }
|
||||||
QString description(void) const
|
QString description() const
|
||||||
{
|
{
|
||||||
return QCoreApplication::translate("SimpleProEditor",
|
return QCoreApplication::translate("SimpleProEditor",
|
||||||
"Create a static library for usage in other applications");
|
"Create a static library for usage in other applications");
|
||||||
@@ -571,35 +571,35 @@ class InfoItemOperatorsAdd : public SPEInfoItem
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemOperatorsAdd(): SPEInfoItem("+=", Operator) {}
|
InfoItemOperatorsAdd(): SPEInfoItem("+=", Operator) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Add Operator"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Add Operator"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
class InfoItemOperatorsRemove : public SPEInfoItem
|
class InfoItemOperatorsRemove : public SPEInfoItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemOperatorsRemove(): SPEInfoItem("-=", Operator) {}
|
InfoItemOperatorsRemove(): SPEInfoItem("-=", Operator) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Remove Operator"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Remove Operator"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
class InfoItemOperatorsReplace : public SPEInfoItem
|
class InfoItemOperatorsReplace : public SPEInfoItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemOperatorsReplace(): SPEInfoItem("~=", Operator) {}
|
InfoItemOperatorsReplace(): SPEInfoItem("~=", Operator) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Replace Operator"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Replace Operator"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
class InfoItemOperatorsSet : public SPEInfoItem
|
class InfoItemOperatorsSet : public SPEInfoItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemOperatorsSet(): SPEInfoItem("=", Operator) {}
|
InfoItemOperatorsSet(): SPEInfoItem("=", Operator) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Set Operator"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Set Operator"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
class InfoItemOperatorsUniqueAdd : public SPEInfoItem
|
class InfoItemOperatorsUniqueAdd : public SPEInfoItem
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
InfoItemOperatorsUniqueAdd(): SPEInfoItem("*=", Operator) {}
|
InfoItemOperatorsUniqueAdd(): SPEInfoItem("*=", Operator) {}
|
||||||
QString name(void) const { return QCoreApplication::translate("SimpleProEditor", "Unique Add Operator"); }
|
QString name() const { return QCoreApplication::translate("SimpleProEditor", "Unique Add Operator"); }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@@ -625,7 +625,7 @@ QVariant SPEInfoItem::data(const QString &key) const
|
|||||||
return m_data.value(key);
|
return m_data.value(key);
|
||||||
}
|
}
|
||||||
|
|
||||||
const SPEInfoItem *SPEInfoItem::parentItem(void) const
|
const SPEInfoItem *SPEInfoItem::parentItem() const
|
||||||
{
|
{
|
||||||
return m_parentItem;
|
return m_parentItem;
|
||||||
}
|
}
|
||||||
@@ -651,7 +651,7 @@ QString SPEInfoItem::id() const
|
|||||||
return m_id;
|
return m_id;
|
||||||
}
|
}
|
||||||
|
|
||||||
SPEInfoItem::InfoKind SPEInfoItem::infoKind(void) const
|
SPEInfoItem::InfoKind SPEInfoItem::infoKind() const
|
||||||
{
|
{
|
||||||
return m_infoKind;
|
return m_infoKind;
|
||||||
}
|
}
|
||||||
@@ -686,7 +686,7 @@ void SPEInfo::addListToHash(const QList<SPEInfoItem*> &list)
|
|||||||
m_itemHash.insert(qMakePair(item->infoKind(), item->id()), item);
|
m_itemHash.insert(qMakePair(item->infoKind(), item->id()), item);
|
||||||
}
|
}
|
||||||
|
|
||||||
void SPEInfo::initializeLists(void)
|
void SPEInfo::initializeLists()
|
||||||
{
|
{
|
||||||
InfoItemConfigurationCross *infoItemConfigurationCross = new InfoItemConfigurationCross;
|
InfoItemConfigurationCross *infoItemConfigurationCross = new InfoItemConfigurationCross;
|
||||||
InfoItemConfigurationDebug *infoItemConfigurationDebug = new InfoItemConfigurationDebug;
|
InfoItemConfigurationDebug *infoItemConfigurationDebug = new InfoItemConfigurationDebug;
|
||||||
@@ -762,7 +762,7 @@ void SPEInfo::initializeLists(void)
|
|||||||
m_listsInitialized = true;
|
m_listsInitialized = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void SPEInfo::deleteLists(void)
|
void SPEInfo::deleteLists()
|
||||||
{
|
{
|
||||||
m_itemHash.clear();
|
m_itemHash.clear();
|
||||||
|
|
||||||
|
@@ -52,12 +52,12 @@ public:
|
|||||||
SPEInfoItem(const QString &id, InfoKind kind);
|
SPEInfoItem(const QString &id, InfoKind kind);
|
||||||
virtual ~SPEInfoItem() {}
|
virtual ~SPEInfoItem() {}
|
||||||
|
|
||||||
QString id(void) const;
|
QString id() const;
|
||||||
InfoKind infoKind(void) const;
|
InfoKind infoKind() const;
|
||||||
virtual QString name(void) const;
|
virtual QString name() const;
|
||||||
virtual QString description(void) const;
|
virtual QString description() const;
|
||||||
QVariant data(const QString &key) const;
|
QVariant data(const QString &key) const;
|
||||||
const SPEInfoItem *parentItem(void) const;
|
const SPEInfoItem *parentItem() const;
|
||||||
void setParentItem(const SPEInfoItem *parentItem);
|
void setParentItem(const SPEInfoItem *parentItem);
|
||||||
|
|
||||||
bool isAncestorOf(const SPEInfoItem *ancestor) const;
|
bool isAncestorOf(const SPEInfoItem *ancestor) const;
|
||||||
@@ -92,8 +92,8 @@ public:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
static void addListToHash(const QList<SPEInfoItem*> &list);
|
static void addListToHash(const QList<SPEInfoItem*> &list);
|
||||||
static void initializeLists(void);
|
static void initializeLists();
|
||||||
static void deleteLists(void);
|
static void deleteLists();
|
||||||
|
|
||||||
static QList<SPEInfoItem*> m_configurationList;
|
static QList<SPEInfoItem*> m_configurationList;
|
||||||
static QList<SPEInfoItem*> m_platformList;
|
static QList<SPEInfoItem*> m_platformList;
|
||||||
|
@@ -50,7 +50,7 @@ public:
|
|||||||
~SubversionOutputWindow();
|
~SubversionOutputWindow();
|
||||||
|
|
||||||
QWidget *outputWidget(QWidget *parent);
|
QWidget *outputWidget(QWidget *parent);
|
||||||
QList<QWidget*> toolBarWidgets(void) const {
|
QList<QWidget*> toolBarWidgets() const {
|
||||||
return QList<QWidget *>();
|
return QList<QWidget *>();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -48,6 +48,7 @@
|
|||||||
#include <coreplugin/editormanager/editormanager.h>
|
#include <coreplugin/editormanager/editormanager.h>
|
||||||
#include <extensionsystem/pluginmanager.h>
|
#include <extensionsystem/pluginmanager.h>
|
||||||
#include <texteditor/texteditoractionhandler.h>
|
#include <texteditor/texteditoractionhandler.h>
|
||||||
|
#include <find/searchresultwindow.h>
|
||||||
#include <utils/qtcassert.h>
|
#include <utils/qtcassert.h>
|
||||||
|
|
||||||
#include <QtCore/QtPlugin>
|
#include <QtCore/QtPlugin>
|
||||||
@@ -63,7 +64,8 @@ TextEditorPlugin::TextEditorPlugin()
|
|||||||
: m_settings(0),
|
: m_settings(0),
|
||||||
m_wizard(0),
|
m_wizard(0),
|
||||||
m_editorFactory(0),
|
m_editorFactory(0),
|
||||||
m_lineNumberFilter(0)
|
m_lineNumberFilter(0),
|
||||||
|
m_searchResultWindow(0)
|
||||||
{
|
{
|
||||||
QTC_ASSERT(!m_instance, return);
|
QTC_ASSERT(!m_instance, return);
|
||||||
m_instance = this;
|
m_instance = this;
|
||||||
@@ -137,6 +139,13 @@ bool TextEditorPlugin::initialize(const QStringList &arguments, QString *errorMe
|
|||||||
void TextEditorPlugin::extensionsInitialized()
|
void TextEditorPlugin::extensionsInitialized()
|
||||||
{
|
{
|
||||||
m_editorFactory->actionHandler()->initializeActions();
|
m_editorFactory->actionHandler()->initializeActions();
|
||||||
|
|
||||||
|
m_searchResultWindow = ExtensionSystem::PluginManager::instance()->getObject<Find::SearchResultWindow>();
|
||||||
|
|
||||||
|
connect(m_settings, SIGNAL(fontSettingsChanged(TextEditor::FontSettings)),
|
||||||
|
this, SLOT(updateSearchResultsFont(TextEditor::FontSettings)));
|
||||||
|
|
||||||
|
updateSearchResultsFont(m_settings->fontSettings());
|
||||||
}
|
}
|
||||||
|
|
||||||
void TextEditorPlugin::initializeEditor(PlainTextEditor *editor)
|
void TextEditorPlugin::initializeEditor(PlainTextEditor *editor)
|
||||||
@@ -155,5 +164,10 @@ void TextEditorPlugin::invokeCompletion()
|
|||||||
editor->triggerCompletions();
|
editor->triggerCompletions();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void TextEditorPlugin::updateSearchResultsFont(const FontSettings &settings)
|
||||||
|
{
|
||||||
|
if (m_searchResultWindow)
|
||||||
|
m_searchResultWindow->setTextEditorFont(QFont(settings.family(), settings.fontSize()));
|
||||||
|
}
|
||||||
|
|
||||||
Q_EXPORT_PLUGIN(TextEditorPlugin)
|
Q_EXPORT_PLUGIN(TextEditorPlugin)
|
||||||
|
@@ -32,6 +32,10 @@
|
|||||||
|
|
||||||
#include <extensionsystem/iplugin.h>
|
#include <extensionsystem/iplugin.h>
|
||||||
|
|
||||||
|
namespace Find {
|
||||||
|
class SearchResultWindow;
|
||||||
|
}
|
||||||
|
|
||||||
namespace TextEditor {
|
namespace TextEditor {
|
||||||
|
|
||||||
class FontSettings;
|
class FontSettings;
|
||||||
@@ -65,6 +69,7 @@ public:
|
|||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void invokeCompletion();
|
void invokeCompletion();
|
||||||
|
void updateSearchResultsFont(const TextEditor::FontSettings &);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
static TextEditorPlugin *m_instance;
|
static TextEditorPlugin *m_instance;
|
||||||
@@ -72,6 +77,7 @@ private:
|
|||||||
TextFileWizard *m_wizard;
|
TextFileWizard *m_wizard;
|
||||||
PlainTextEditorFactory *m_editorFactory;
|
PlainTextEditorFactory *m_editorFactory;
|
||||||
LineNumberFilter *m_lineNumberFilter;
|
LineNumberFilter *m_lineNumberFilter;
|
||||||
|
Find::SearchResultWindow *m_searchResultWindow;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace Internal
|
} // namespace Internal
|
||||||
|
@@ -199,9 +199,8 @@ ResourceView::ResourceView(QUndoStack *history, QWidget *parent) :
|
|||||||
enableContextMenu(true);
|
enableContextMenu(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
ResourceView::~ResourceView(void)
|
ResourceView::~ResourceView()
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ResourceView::currentChanged(const QModelIndex ¤t, const QModelIndex &previous)
|
void ResourceView::currentChanged(const QModelIndex ¤t, const QModelIndex &previous)
|
||||||
@@ -477,7 +476,7 @@ void ResourceView::onEditAlias()
|
|||||||
changeAlias(index);
|
changeAlias(index);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ResourceView::load(QString fileName)
|
bool ResourceView::load(const QString &fileName)
|
||||||
{
|
{
|
||||||
const QFileInfo fi(fileName);
|
const QFileInfo fi(fileName);
|
||||||
m_qrcModel->setFileName(fi.absoluteFilePath());
|
m_qrcModel->setFileName(fi.absoluteFilePath());
|
||||||
@@ -488,7 +487,7 @@ bool ResourceView::load(QString fileName)
|
|||||||
return m_qrcModel->reload();
|
return m_qrcModel->reload();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ResourceView::save(void)
|
bool ResourceView::save()
|
||||||
{
|
{
|
||||||
return m_qrcModel->save();
|
return m_qrcModel->save();
|
||||||
}
|
}
|
||||||
|
@@ -84,10 +84,10 @@ public:
|
|||||||
};
|
};
|
||||||
|
|
||||||
ResourceView(QUndoStack *history, QWidget *parent = 0);
|
ResourceView(QUndoStack *history, QWidget *parent = 0);
|
||||||
~ResourceView(void);
|
~ResourceView();
|
||||||
|
|
||||||
bool load(QString fileName);
|
bool load(const QString &fileName);
|
||||||
bool save(void);
|
bool save();
|
||||||
QString fileName() const;
|
QString fileName() const;
|
||||||
void setFileName(const QString &fileName);
|
void setFileName(const QString &fileName);
|
||||||
|
|
||||||
@@ -114,7 +114,7 @@ public:
|
|||||||
bool defaultAddFileEnabled() const;
|
bool defaultAddFileEnabled() const;
|
||||||
|
|
||||||
void findSamePlacePostDeletionModelIndex(int &row, QModelIndex &parent) const;
|
void findSamePlacePostDeletionModelIndex(int &row, QModelIndex &parent) const;
|
||||||
EntryBackup * removeEntry(const QModelIndex &index);
|
EntryBackup *removeEntry(const QModelIndex &index);
|
||||||
void addFiles(int prefixIndex, const QStringList &fileNames, int cursorFile,
|
void addFiles(int prefixIndex, const QStringList &fileNames, int cursorFile,
|
||||||
int &firstFile, int &lastFile);
|
int &firstFile, int &lastFile);
|
||||||
void removeFiles(int prefixIndex, int firstFileIndex, int lastFileIndex);
|
void removeFiles(int prefixIndex, int firstFileIndex, int lastFileIndex);
|
||||||
@@ -158,8 +158,8 @@ public:
|
|||||||
void changeValue(const QModelIndex &nodeIndex, NodeProperty property, const QString &value);
|
void changeValue(const QModelIndex &nodeIndex, NodeProperty property, const QString &value);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void addUndoCommand(const QModelIndex &nodeIndex, NodeProperty property, const QString &before,
|
void addUndoCommand(const QModelIndex &nodeIndex, NodeProperty property,
|
||||||
const QString &after);
|
const QString &before, const QString &after);
|
||||||
|
|
||||||
QPoint m_releasePos;
|
QPoint m_releasePos;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user