Sonnet
spellcheckdecorator.cpp
104 if ((mousePos < wordSelectCursor.selectionStart() || mousePos >= wordSelectCursor.selectionEnd()) //
119 wordSelectCursor.movePosition(QTextCursor::NextCharacter, QTextCursor::KeepAnchor, selectedWord.size());
164void SpellCheckDecoratorPrivate::execSuggestionMenu(const QPoint &pos, const QString &selectedWord, const QTextCursor &_cursor)
172 QAction *suggestionsAction = menu.addAction(SpellCheckDecorator::tr("No suggestions for %1").arg(selectedWord));
The Sonnet Highlighter class, used for drawing pretty red lines in text fields.
Definition highlighter.h:26
void addWordToDictionary(const QString &word)
Adds the given word permanently to the dictionary.
Definition highlighter.cpp:469
bool isWordMisspelled(const QString &word)
Checks if a given word is marked as misspelled by the highlighter.
Definition highlighter.cpp:504
QStringList suggestionsForWord(const QString &word, int max=10)
Returns a list of suggested replacements for the given misspelled word.
Definition highlighter.cpp:479
virtual bool isSpellCheckingEnabledForBlock(const QString &textBlock) const
Returns true if the spell checking should be enabled for a given block of text The default implementa...
Definition spellcheckdecorator.cpp:257
SpellCheckDecorator(QTextEdit *textEdit)
Creates a spell-check decorator.
Definition spellcheckdecorator.cpp:222
Highlighter * highlighter() const
Returns the hightlighter used by the decorator.
Definition spellcheckdecorator.cpp:241
void setHighlighter(Highlighter *highlighter)
Set a custom highlighter on the decorator.
Definition spellcheckdecorator.cpp:236
AKONADI_CALENDAR_EXPORT KCalendarCore::Event::Ptr event(const Akonadi::Item &item)
QAction * end(const QObject *recvr, const char *slot, QObject *parent)
QWidget * viewport() const const
void setEnabled(bool)
text
ContextMenu
const_iterator constBegin() const const
const_iterator constEnd() const const
bool isEmpty() const const
virtual bool event(QEvent *e)
void installEventFilter(QObject *filterObj)
void removeEventFilter(QObject *obj)
QString tr(const char *sourceText, const char *disambiguation, int n)
QTextCursor cursorForPosition(const QPoint &pos) const const
void setTextCursor(const QTextCursor &cursor)
QTextCursor textCursor() const const
void chop(qsizetype n)
bool endsWith(QChar c, Qt::CaseSensitivity cs) const const
bool isEmpty() const const
qsizetype length() const const
QString right(qsizetype n) const const
qsizetype size() const const
bool startsWith(QChar c, Qt::CaseSensitivity cs) const const
bool contains(QLatin1StringView str, Qt::CaseSensitivity cs) const const
void rehighlight()
QString text() const const
MoveAnchor
NextCharacter
WordUnderCursor
QTextBlock block() const const
bool hasSelection() const const
void insertText(const QString &text)
int position() const const
int selectionEnd() const const
int selectionStart() const const
QTextCursor cursorForPosition(const QPoint &pos) const const
void setTextCursor(const QTextCursor &cursor)
QTextCursor textCursor() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 29 2024 11:46:56 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 29 2024 11:46:56 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.