KTextEditor
#include <modeinterface.h>
Public Member Functions | |
ModeInterface () | |
virtual | ~ModeInterface () |
virtual QStringList | allPossibleModes () const =0 |
virtual QString | modeAt (const Cursor &position)=0 |
Detailed Description
Mode information interface for the Document.
Introduction
The ModeInterface provides access to the modes of a document
Accessing the ModeInterface
The ModeInterface is supposed to be an extension interface for a Document, i.e. the Document inherits the interface provided that the used KTextEditor library implements the interface. Use qobject_cast to access the interface:
- See also
- KTextEditor::Document
Definition at line 63 of file modeinterface.h.
Constructor & Destructor Documentation
ModeInterface::ModeInterface | ( | ) |
Constructor.
Definition at line 305 of file ktexteditor.cpp.
|
virtual |
Virtual destructor.
Definition at line 308 of file ktexteditor.cpp.
Member Function Documentation
|
pure virtual |
Get all available file modes for the current document.
- Returns
- Returns a list of all possible modes within a document.
- See also
- KTextEditor::Document::mode()
Get the possible modes for a given position.
The mode of a certain position might be ambiguos. eg. mode C++ could stand for the source or the header file. In most cases this mode will be equal to the highlighting name but it does not have to be. Modes should not be mixed with HighlightingModes. For instance for the toplevel in a document this might defer. For sub modes it might in the future
- See also
- modes()
TODO: I intended to make this const but Kate's implementation needs to call kateTextline which is non-const. Solution?
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:31:42 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.