KTextEditor

katecompletiondelegate.h
1 /*
2  SPDX-FileCopyrightText: 2007 David Nolden <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6 
7 #ifndef KATECOMPLETIONDELEGATE_H
8 #define KATECOMPLETIONDELEGATE_H
9 
10 #include "expandingtree/expandingdelegate.h"
11 
12 class KateRenderer;
13 namespace KTextEditor
14 {
15 class DocumentPrivate;
16 }
18 
19 class KateCompletionDelegate : public ExpandingDelegate
20 {
21 public:
22  explicit KateCompletionDelegate(ExpandingWidgetModel *model, KateCompletionWidget *parent);
23 
24  KateRenderer *renderer() const;
26  KTextEditor::DocumentPrivate *document() const;
27 
28 protected:
29  void adjustStyle(const QModelIndex &index, QStyleOptionViewItem &option) const override;
30  mutable int m_cachedRow;
31  mutable QList<int> m_cachedColumnStarts;
32  void heightChanged() const override;
33  QVector<QTextLayout::FormatRange> createHighlighting(const QModelIndex &index, QStyleOptionViewItem &option) const override;
34 };
35 
36 #endif
QWidget * widget() override
Handles all of the work of rendering the text (used for the views and printing)
Definition: katerenderer.h:45
This is the code completion&#39;s main widget, and also contains the core interface logic.
The KTextEditor namespace contains all the public API that is required to use the KTextEditor compone...
This is a delegate that cares, together with ExpandingWidgetModel, about embedded widgets in tree-vie...
Cares about expanding/un-expanding items in a tree-view together with ExpandingDelegate.
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Sun Oct 25 2020 23:01:55 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.