MCPcopy Create free account
hub / github.com/KDE/okular / TextAreaEdit

Method TextAreaEdit

part/formwidgets.cpp:707–724  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

705}
706
707TextAreaEdit::TextAreaEdit(Okular::FormFieldText *text, PageView *pageView)
708 : KTextEdit(pageView->viewport())
709 , FormWidgetIface(this, text)
710{
711 setAcceptRichText(text->isRichText());
712 setCheckSpellingEnabled(text->canBeSpellChecked());
713 setAlignment(text->textAlignment());
714 setPlainText(text->text());
715 setUndoRedoEnabled(false);
716
717 connect(this, &QTextEdit::textChanged, this, &TextAreaEdit::slotChanged);
718 connect(this, &QTextEdit::cursorPositionChanged, this, &TextAreaEdit::slotChanged);
719 connect(this, &KTextEdit::aboutToShowContextMenu, this, &TextAreaEdit::slotUpdateUndoAndRedoInContextMenu);
720 m_prevCursorPos = textCursor().position();
721 m_prevAnchorPos = textCursor().anchor();
722 m_editing = false;
723 setVisible(text->isVisible());
724}
725
726TextAreaEdit::~TextAreaEdit()
727{

Callers

nothing calls this directly

Calls 5

isRichTextMethod · 0.45
canBeSpellCheckedMethod · 0.45
textAlignmentMethod · 0.45
textMethod · 0.45
isVisibleMethod · 0.45

Tested by

no test coverage detected