KTextEditor
exporter.cpp
56 const KTextEditor::Range range = useSelection ? m_view->selectionRange() : m_view->document()->documentRange();
64 std::unique_ptr<AbstractExporter> exporter = std::make_unique<HTMLExporter>(m_view, output, !useSelection);
68 for (int i = range.start().line(); (i <= range.end().line()) && (i < m_view->document()->lines()); ++i) {
constexpr int column() const noexcept
Retrieve the column on which this cursor is situated.
Definition cursor.h:192
constexpr int line() const noexcept
Retrieve the line on which this cursor is situated.
Definition cursor.h:174
An object representing a section of text, from one Cursor to another.
Definition include/ktexteditor/range.h:49
constexpr Cursor end() const noexcept
Get the end position of this range.
Definition include/ktexteditor/range.h:163
constexpr Cursor start() const noexcept
Get the start position of this range.
Definition include/ktexteditor/range.h:153
constexpr int columnWidth() const noexcept
Returns the number of columns separating the start() and end() positions.
Definition include/ktexteditor/range.h:290
constexpr bool onSingleLine() const noexcept
Check whether this range is wholly contained within one line, ie.
Definition include/ktexteditor/range.h:268
virtual Document * document() const =0
Get the view's document, that means the view is a view of the returned document.
virtual bool blockSelection() const =0
Get the status of the selection mode.
virtual QList< KTextEditor::AttributeBlock > lineAttributes(int line)=0
Get the list of AttributeBlocks for a given line in the document.
virtual bool selection() const =0
Query the view whether it has selected text, i.e.
virtual Range selectionRange() const =0
Get the range occupied by the current selection.
Q_SCRIPTABLE Q_NOREPLY void start()
void setMimeData(QMimeData *src, Mode mode)
QClipboard * clipboard()
WriteOnly
void setHtml(const QString &html)
void setText(const QString &text)
qsizetype length() const const
QString mid(qsizetype position, qsizetype n) const const
void flush()
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:11:26 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:11:26 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.