KTextEditor::InlineNoteInterface
#include <KTextEditor/InlineNoteInterface>
Inherited by KTextEditor::ViewPrivate.
Public Member Functions | |
virtual void | registerInlineNoteProvider (KTextEditor::InlineNoteProvider *provider)=0 |
virtual void | unregisterInlineNoteProvider (KTextEditor::InlineNoteProvider *provider)=0 |
Detailed Description
Inline notes interface for rendering notes in the text.
Introduction
The inline notes interface provides a way to render arbitrary things in the text. The text layout of the line is adapted to create space for the note. Possible applications include showing a name of a function parameter in a function call or rendering a square with a color preview next to CSS color property.

To register as inline note provider, call registerInlineNoteProvider() with an instance that inherits InlineNoteProvider. Finally, make sure you remove your inline note provider by calling unregisterInlineNoteProvider().
Accessing the InlineNoteInterface
The InlineNoteInterface is an extension interface for a View, i.e. the View inherits the interface. Use qobject_cast to access the interface:
- See also
- InlineNoteProvider
- InlineNote
- Since
- 5.50
Definition at line 69 of file inlinenoteinterface.h.
Member Function Documentation
◆ registerInlineNoteProvider()
|
pure virtual |
Register the inline note provider provider
.
Whenever a line is painted, the provider
will be queried for notes that should be painted in it. When the provider is about to be destroyed, make sure to call unregisterInlineNoteProvider() to avoid a dangling pointer.
- Parameters
-
provider inline note provider
◆ unregisterInlineNoteProvider()
|
pure virtual |
Unregister the inline note provider provider
.
- Parameters
-
provider inline note provider to unregister
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2023 The KDE developers.
Generated on Thu Mar 30 2023 03:58:48 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.