KTextEditor
appcommands.cpp
26 : KTextEditor::Command({QStringLiteral("q"), QStringLiteral("qa"), QStringLiteral("qall"), QStringLiteral("q!"), QStringLiteral("qa!"),
27 QStringLiteral("qall!"), QStringLiteral("w"), QStringLiteral("wq"), QStringLiteral("wa"), QStringLiteral("wqa"),
28 QStringLiteral("x"), QStringLiteral("xa"), QStringLiteral("new"), QStringLiteral("vnew"), QStringLiteral("e"),
29 QStringLiteral("edit"), QStringLiteral("enew"), QStringLiteral("sp"), QStringLiteral("split"), QStringLiteral("vs"),
30 QStringLiteral("vsplit"), QStringLiteral("only"), QStringLiteral("tabe"), QStringLiteral("tabedit"), QStringLiteral("tabnew"),
31 QStringLiteral("bd"), QStringLiteral("bdelete"), QStringLiteral("tabc"), QStringLiteral("tabclose"), QStringLiteral("clo"),
52bool AppCommands::exec(KTextEditor::View *view, const QString &cmd, QString &msg, const KTextEditor::Range &)
155 QUrl(base.resolved(arg2path)); // resolved handles the case where the args is a relative path, and is the same as using QUrl(args) elsewise
158 .resolved(arg2path)); // + "/" is needed because of https://lists.qt-project.org/pipermail/qt-interest-old/2011-May/033913.html
161 // either find existing document or just open it, openUrl will take care of non-existing files, too
280KTextEditor::View *AppCommands::findViewInDifferentSplitView(KTextEditor::MainWindow *window, KTextEditor::View *view)
378bool BufferCommands::exec(KTextEditor::View *view, const QString &cmd, QString &, const KTextEditor::Range &)
521 } else if (cmd == QLatin1String("bp") || cmd == QLatin1String("bprevious") || cmd == QLatin1String("tabp") || cmd == QLatin1String("tabprevious")) {
529 } else if (cmd == QLatin1String("bn") || cmd == QLatin1String("bnext") || cmd == QLatin1String("tabn") || cmd == QLatin1String("tabnext")) {
537 } else if (cmd == QLatin1String("bf") || cmd == QLatin1String("bfirst") || cmd == QLatin1String("tabf") || cmd == QLatin1String("tabfirst")) {
543 } else if (cmd == QLatin1String("bl") || cmd == QLatin1String("blast") || cmd == QLatin1String("tabl") || cmd == QLatin1String("tablast")) {
bool isEmpty() const
QUrl url() const
bool isModified() const
void setModified()
This class allows the application that embeds the KTextEditor component to allow it access to applica...
Definition application.h:44
KTextEditor::Document * openUrl(const QUrl &url, const QString &encoding=QString())
Open the document url with the given encoding.
Definition application.cpp:66
bool closeDocuments(const QList< KTextEditor::Document * > &documents)
Close a list of documents.
Definition application.cpp:87
KTextEditor::Document * findUrl(const QUrl &url)
Get the document with the URL url.
Definition application.cpp:58
bool closeDocument(KTextEditor::Document *document)
Close the given document.
Definition application.cpp:79
KTextEditor::MainWindow * activeMainWindow()
Accessor to the active main window.
Definition application.cpp:40
QList< KTextEditor::Document * > documents()
Get a list of all documents that are managed by the application.
Definition application.cpp:50
virtual KTextEditor::Application * application() const =0
Current hosting application, if any set.
This class allows the application that embeds the KTextEditor component to allow it to access parts o...
Definition mainwindow.h:47
KTextEditor::View * openUrl(const QUrl &url, const QString &encoding=QString())
Open the document url with the given encoding.
Definition mainwindow.cpp:73
QList< KTextEditor::View * > views()
Get a list of all views for this main window.
Definition mainwindow.cpp:45
KTextEditor::View * activateView(KTextEditor::Document *document)
Activate the view with the corresponding document.
Definition mainwindow.cpp:61
void splitView(Qt::Orientation orientation)
Split current view space according to orientation.
Definition mainwindow.cpp:89
An object representing a section of text, from one Cursor to another.
Definition include/ktexteditor/range.h:49
virtual Document * document() const =0
Get the view's document, that means the view is a view of the returned document.
virtual KTextEditor::MainWindow * mainWindow() const =0
Get the view's main window, if any.
QString i18n(const char *text, const TYPE &arg...)
KCOREADDONS_EXPORT Result match(QStringView pattern, QStringView str)
PostalAddress address(const QVariant &location)
KGUIADDONS_EXPORT QWindow * window(QObject *job)
const QList< QKeySequence > & save()
The KTextEditor namespace contains all the public API that is required to use the KTextEditor compone...
Definition katetextblock.h:18
QString currentPath()
const_reference at(qsizetype i) const const
T & first()
qsizetype indexOf(const AT &value, qsizetype from) const const
bool isEmpty() const const
T & last()
qsizetype size() const const
QRegularExpressionMatch match(QStringView subjectView, qsizetype offset, MatchType matchType, MatchOptions matchOptions) const const
bool hasMatch() const const
bool isEmpty() const const
QStringList split(QChar sep, Qt::SplitBehavior behavior, Qt::CaseSensitivity cs) const const
Horizontal
SkipEmptyParts
singleShot
QUrl fromLocalFile(const QString &localFile)
bool isValid() const const
QUrl resolved(const QUrl &relative) const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:01:56 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:01:56 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.