KTextEditor
expandingwidgetmodel.cpp
56 QColor totalColor = KColorUtils::mix(badMatchColor, goodMatchColor, ((float)matchQuality) / 10.0);
104 widget->deleteLater(); // By using deleteLater, we prevent crashes when an action within a widget makes the completion cancel
250 for (QMap<QModelIndex, QPointer<QWidget>>::const_iterator it = m_expandingWidgets.constBegin(); it != m_expandingWidgets.constEnd(); ++it) {
277 QList<QVariant> mergeCustomHighlighting(int leftSize, const QList<QVariant> &left, int rightSize, const QList<QVariant> &right)
319 QList<QVariant> mergeCustomHighlighting(QStringList strings, QList<QVariantList> highlights, int grapBetweenStrings)
332 qCWarning(LOG_KTE) << "Length of string-list is " << strings.count() << " while count of highlightings is " << highlights.count() << ", should be same";
344 totalHighlighting = mergeCustomHighlighting(totalString.length(), totalHighlighting, strings[0].length(), highlights[0]);
bool isValid() const const
bool isNull() const const
QMap::const_iterator constBegin() const const
const QColor & color() const const
void placeExpandingWidget(const QModelIndex &row)
Places and shows the expanding-widget for the given row, if it should be visible and is valid.
Definition: expandingwidgetmodel.cpp:190
QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const override
Does not request data from index, this only returns local data like highlighting for expanded rows an...
Definition: expandingwidgetmodel.cpp:75
void setReadOnly(bool ro)
const QBrush & window() const const
QTextStream & right(QTextStream &stream)
void setParent(QWidget *parent)
BackgroundRole
KGUIADDONS_EXPORT QColor mix(const QColor &c1, const QColor &c2, qreal bias=0.5)
QModelIndex sibling(int row, int column) const const
int right() const const
uint matchColor(const QModelIndex &index) const
Returns the match-color for the given index, or zero if match-quality could not be computed.
Definition: expandingwidgetmodel.cpp:44
void clear()
int count(const T &value) const const
int column() const const
T value() const const
QTextStream & left(QTextStream &stream)
QRgb rgb() const const
QIcon fromTheme(const QString &name)
QColor light(int factor) const const
KGUIADDONS_EXPORT QColor tint(const QColor &base, const QColor &color, qreal amount=0.3)
void clearExpanding()
Unexpand all rows and clear all cached information about them(this includes deleting the expanding-wi...
Definition: expandingwidgetmodel.cpp:99
int left() const const
void hide()
void setRight(int x)
bool isVisible() const const
QVariant data(int role) const const
int bottom() const const
int top() const const
void setHeight(int height)
QMap::const_iterator constEnd() const const
void pop_front()
int length() const const
bool isValid() const const
CharFormat
bool isEmpty() const const
virtual int columnCount(const QModelIndex &parent) const const=0
void setExpanded(QModelIndex index, bool expanded)
Change the expand-state of the row given through index. The display will be updated.
Definition: expandingwidgetmodel.cpp:138
bool isExpanded(const QModelIndex &row) const
Definition: expandingwidgetmodel.cpp:132
QTextStream & left(QTextStream &s)
bool isValid() const const
The KTextEditor namespace contains all the public API that is required to use the KTextEditor compone...
Definition: katetextblock.h:22
bool toBool() const const
void show()
int row() const const
bool canConvert(int targetTypeId) const const
QTextStream & right(QTextStream &s)
void setGeometry(int x, int y, int w, int h)
void setTop(int y)
void resize(int w, int h)
height
QWidget * expandingWidget(const QModelIndex &row) const
Definition: expandingwidgetmodel.cpp:255
bool isExpandable(const QModelIndex &index) const
Definition: expandingwidgetmodel.cpp:117
geometry
QModelIndex parent() const const
QPalette palette()
void setLeft(int x)
QObject * parent() const const
const QAbstractItemModel * model() const const
QString toString() const const
void placeExpandingWidgets()
Place or hides all expanding-widgets to the correct positions. Should be called after the view was sc...
Definition: expandingwidgetmodel.cpp:248
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Fri Dec 8 2023 03:50:31 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2023 The KDE developers.
Generated on Fri Dec 8 2023 03:50:31 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.