QEditorView Class Reference
#include <qeditor_view.h>
Inheritance diagram for QEditorView:

Public Slots | |
void | configChanged () |
void | gotoLine () |
void | setLanguage (const QString &) |
void | doFind () |
void | doReplace () |
void | indent () |
void | ensureTextIsVisible (QTextParagraph *) |
void | expandBlock (QTextParagraph *) |
void | collapseBlock (QTextParagraph *) |
void | expandAllBlocks () |
void | collapseAllBlocks () |
virtual void | copy () const |
copies selected text | |
virtual void | cut () |
copies selected text | |
virtual void | paste () |
copies selected text | |
virtual void | selectAll () |
select all text | |
Signals | |
void | cursorPositionChanged () |
void | completionAborted () |
This signal is emitted when the completion list disappears and no completion has been done. | |
void | completionDone () |
This signal is emitted when the completion list disappears and a completion has been inserted into text. | |
void | completionDone (KTextEditor::CompletionEntry) |
This signal is the same as completionDone(), but additionally it carries the information which completion item was used. | |
void | argHintHidden () |
This signal is emitted when the argument hint disappears. | |
void | filterInsertString (KTextEditor::CompletionEntry *, QString *) |
This signal is emitted just before a completion takes place. | |
void | aboutToShowCompletionBox () |
void | needTextHint (int line, int column, QString &) |
void | newStatus () |
Public Member Functions | |
QEditorView (QEditorPart *, QWidget *=0, const char *=0) | |
find/replace adapted from KOffice KoText Copyright (C) 1998, 1999 Reginald Stadlbauer <reggie@kde.org> Copyright (C) 2001, S.R.Haque <srhaque@iee.org> Copyright (C) 2001, David Faure <david@mandrakesoft.com> | |
virtual | ~QEditorView () |
KTextEditor::Document * | document () const |
QEditorPart * | doc () const |
QEditor * | editor () const |
QString | currentTextLine () const |
void | insertText (const QString &) |
QString | language () const |
bool | isMarkerWidgetVisible () const |
void | setMarkerWidgetVisible (bool) |
MarkerWidget * | markerWidget () |
bool | isLineNumberWidgetVisible () const |
void | setLineNumberWidgetVisible (bool) |
bool | isLevelWidgetVisible () const |
void | setLevelWidgetVisible (bool) |
int | tabStop () const |
void | setTabStop (int) |
virtual QPoint | cursorCoordinates () |
Get the current cursor coordinates in pixels. | |
virtual void | cursorPosition (unsigned int *line, unsigned int *col) |
Get the cursor position. | |
virtual void | cursorPositionReal (unsigned int *line, unsigned int *col) |
Get the cursor position, calculated with 1 character per tab. | |
virtual bool | setCursorPosition (unsigned int line, unsigned int col) |
Set the cursor position. | |
virtual bool | setCursorPositionReal (unsigned int line, unsigned int col) |
Set the cursor position, use 1 character per tab. | |
virtual unsigned int | cursorLine () |
virtual unsigned int | cursorColumn () |
virtual unsigned int | cursorColumnReal () |
virtual void | installPopup (class QPopupMenu *rmb_Menu) |
Install a Popup Menu. | |
virtual void | showArgHint (QStringList functionList, const QString &strWrapping, const QString &strDelimiter) |
This shows an argument hint. | |
virtual void | showCompletionBox (QValueList< KTextEditor::CompletionEntry > complList, int offset=0, bool casesensitive=true) |
This shows a completion list. | |
QString | computeTextHint (int line, int column) |
void | enableTextHints (int timeout) |
void | disableTextHints () |
Protected Slots | |
void | highlight (const QString &, int, int, const QRect &) |
void | replace (const QString &, int, int, int, const QRect &) |
Protected Member Functions | |
void | proceed () |
bool | find_real (QTextParagraph *firstParag, int firstIndex, QTextParagraph *lastParag, int lastIndex) |
bool | process (const QString &) |
void | doRepaint () |
void | internalEnsureVisibleBlock (QTextParagraph *) |
void | internalExpandBlock (QTextParagraph *) |
void | internalCollapseBlock (QTextParagraph *) |
Private Member Functions | |
void | setupActions () |
Private Attributes | |
QTextParagraph * | m_currentParag |
KoFindDialog * | m_findDialog |
KoReplaceDialog * | m_replaceDialog |
KoFind * | m_find |
KoReplace * | m_replace |
long | m_options |
int | m_offset |
QEditorPart * | m_document |
QEditor * | m_editor |
QEditorCodeCompletion * | m_pCodeCompletion |
LineNumberWidget * | m_lineNumberWidget |
MarkerWidget * | m_markerWidget |
LevelWidget * | m_levelWidget |
QEditorTextHint * | m_textHintToolTip |
Constructor & Destructor Documentation
|
find/replace adapted from KOffice KoText Copyright (C) 1998, 1999 Reginald Stadlbauer <reggie@kde.org> Copyright (C) 2001, S.R.Haque <srhaque@iee.org> Copyright (C) 2001, David Faure <david@mandrakesoft.com>
Definition at line 58 of file qeditor_view.cpp. References argHintHidden(), collapseBlock(), completionAborted(), completionDone(), configChanged(), cursorPositionChanged(), doc(), doRepaint(), ensureTextIsVisible(), expandBlock(), filterInsertString(), m_currentParag, m_editor, m_find, m_findDialog, m_levelWidget, m_lineNumberWidget, m_markerWidget, m_offset, m_options, m_pCodeCompletion, m_replace, m_replaceDialog, newStatus(), QEditorView(), and setupActions(). Referenced by QEditorView(). |
|
Definition at line 135 of file qeditor_view.cpp. References m_pCodeCompletion. |
Member Function Documentation
|
Referenced by showCompletionBox(). |
|
This signal is emitted when the argument hint disappears. This is the case e.g. when the user moves the cursor somewhere else. IMPORTANT: Please check if a connect to this signal worked, and implement some fallback when the implementation doesn't support it IMPORTANT FOR IMPLEMENTERS: When you don't support this signal, please just override the inherited function, if you support it, declare it as a signal Implements KTextEditor::CodeCompletionInterface. Referenced by QEditorView(). |
|
Definition at line 768 of file qeditor_view.cpp. References QEditor::document(), doRepaint(), internalCollapseBlock(), ParagData::isBlockStart(), m_editor, and QEditor::refresh(). Referenced by setupActions(). |
|
Definition at line 654 of file qeditor_view.cpp. References collapseBlock(), doRepaint(), internalCollapseBlock(), m_editor, and QEditor::refresh(). Referenced by collapseBlock(), and QEditorView(). |
|
This signal is emitted when the completion list disappears and no completion has been done. This is the case e.g. when the user presses Escape. IMPORTANT: Please check if a connect to this signal worked, and implement some fallback when the implementation doesn't support it IMPORTANT FOR IMPLEMENTERS: When you don't support this signal, please just override the inherited function, if you support it, declare it as a signal Implements KTextEditor::CodeCompletionInterface. Referenced by QEditorView(). |
|
This signal is the same as completionDone(), but additionally it carries the information which completion item was used. IMPORTANT: Please check if a connect to this signal worked, and implement some fallback when the implementation doesn't support it IMPORTANT: The pointer to the CompleteionEntry, is only valid in the slots connected to this signal when the connected slots are left, the data element may be destroyed, depending on the implementation IMPORTANT FOR IMPLEMENTERS: When you don't support this signal, please just override the inherited function, if you support it, declare it as a signal. Implements KTextEditor::CodeCompletionInterface. |
|
This signal is emitted when the completion list disappears and a completion has been inserted into text. This is the case e.g. when the user presses Return on a selected item in the completion list. IMPORTANT: Please check if a connect to this signal worked, and implement some fallback when the implementation doesn't support it IMPORTANT FOR IMPLEMENTERS: When you don't support this signal, please just override the inherited function, if you support it, declare it as a signal Implements KTextEditor::CodeCompletionInterface. Referenced by QEditorView(). |
|
Definition at line 783 of file qeditor_view.cpp. References computeTextHint(), and needTextHint(). Referenced by computeTextHint(), and QEditorTextHint::maybeTip(). |
|
Definition at line 142 of file qeditor_view.cpp. References QEditor::configChanged(), m_editor, setLevelWidgetVisible(), setLineNumberWidgetVisible(), and setMarkerWidgetVisible(). Referenced by QEditorPart::configDialog(), QEditorView(), and QEditorPart::readConfig(). |
|
copies selected text
Implements KTextEditor::ClipboardInterface. Definition at line 291 of file qeditor_view.cpp. References m_editor. Referenced by QEditorBrowserExtension::copy(), and setupActions(). |
|
Definition at line 326 of file qeditor_view.cpp. References m_editor. Referenced by QEditorCodeCompletion::eventFilter(), and QEditorCodeCompletion::updateBox(). |
|
Implements KTextEditor::ViewCursorInterface. Definition at line 265 of file qeditor_view.cpp. References m_editor, and text(). Referenced by cursorPosition(). |
|
Implements KTextEditor::ViewCursorInterface. Definition at line 284 of file qeditor_view.cpp. References m_editor. Referenced by cursorPositionReal(), QEditorCodeCompletion::eventFilter(), and QEditorCodeCompletion::updateBox(). |
|
Get the current cursor coordinates in pixels.
Implements KTextEditor::ViewCursorInterface. Definition at line 208 of file qeditor_view.cpp. References m_editor, and QEditor::textCursor(). Referenced by QEditorCodeCompletion::showArgHint(). |
|
Implements KTextEditor::ViewCursorInterface. Definition at line 258 of file qeditor_view.cpp. References m_editor. Referenced by cursorPosition(), and cursorPositionReal(). |
|
Get the cursor position.
Implements KTextEditor::ViewCursorInterface. Definition at line 220 of file qeditor_view.cpp. References cursorColumn(), cursorLine(), and cursorPosition(). Referenced by cursorPosition(). |
|
Implements KTextEditor::ViewCursorInterface. Referenced by QEditorView(). |
|
Get the cursor position, calculated with 1 character per tab.
Implements KTextEditor::ViewCursorInterface. Definition at line 226 of file qeditor_view.cpp. References cursorColumnReal(), cursorLine(), and cursorPositionReal(). Referenced by cursorPositionReal(), QEditorCodeCompletion::showArgHint(), QEditorCodeCompletion::showCompletionBox(), and QEditorCodeCompletion::slotCursorPosChanged(). |
|
copies selected text
Implements KTextEditor::ClipboardInterface. Definition at line 296 of file qeditor_view.cpp. References m_editor. Referenced by setupActions(). |
|
Implements KTextEditor::TextHintInterface. Definition at line 802 of file qeditor_view.cpp. References m_textHintToolTip. |
|
Definition at line 69 of file qeditor_view.h. References m_document. Referenced by QEditorArgHint::cursorPositionChanged(), QEditorView(), and setupActions(). |
|
Implements KTextEditor::View. Definition at line 203 of file qeditor_view.cpp. References m_document. |
|
Definition at line 473 of file qeditor_view.cpp. References KoFind::abort(), highlight(), m_editor, m_find, KoFindDialog::m_find, m_findDialog, m_options, KoFindDialog::options(), KoFindDialog::pattern(), proceed(), and KComboBox::setEditURL(). Referenced by setupActions(). |
|
Definition at line 663 of file qeditor_view.cpp. References LevelWidget::doRepaint(), LineNumberWidget::doRepaint(), MarkerWidget::doRepaint(), m_levelWidget, m_lineNumberWidget, and m_markerWidget. Referenced by collapseAllBlocks(), collapseBlock(), ensureTextIsVisible(), expandAllBlocks(), expandBlock(), and QEditorView(). |
|
Definition at line 493 of file qeditor_view.cpp. References KoReplace::abort(), highlight(), m_editor, KoFindDialog::m_find, m_options, m_replace, m_replaceDialog, KoReplaceDialog::options(), KoFindDialog::pattern(), proceed(), replace(), KoReplaceDialog::replacement(), and KComboBox::setEditURL(). Referenced by setupActions(). |
|
|
Implements KTextEditor::TextHintInterface. Definition at line 790 of file qeditor_view.cpp. References enableTextHints(), and m_textHintToolTip. Referenced by enableTextHints(). |
|
Definition at line 545 of file qeditor_view.cpp. References doRepaint(), ensureTextIsVisible(), internalEnsureVisibleBlock(), m_editor, and QEditor::refresh(). Referenced by ensureTextIsVisible(), QEditorView(), setCursorPosition(), and setCursorPositionReal(). |
|
Definition at line 753 of file qeditor_view.cpp. References QEditor::document(), doRepaint(), internalExpandBlock(), ParagData::isBlockStart(), m_editor, and QEditor::refresh(). Referenced by setupActions(). |
|
Definition at line 645 of file qeditor_view.cpp. References doRepaint(), expandBlock(), internalExpandBlock(), m_editor, and QEditor::refresh(). Referenced by expandBlock(), and QEditorView(). |
|
This signal is emitted just before a completion takes place. You can use it to modify the KTextEditor::CompletionEntry. The modified entry will not be visible in the completion list (because that has just disappeared) but it will be used when the completion is inserted into the text. IMPORTANT: Please check if a connect to this signal worked, and implement some fallback when the implementation doesn't support it IMPORTANT FOR IMPLEMENTERS: When you don't support this signal, please just override the inherited function, if you support it, declare it as a signal Implements KTextEditor::CodeCompletionInterface. Referenced by QEditorView(). |
|
Definition at line 421 of file qeditor_view.cpp. References find_real(), m_currentParag, m_offset, m_options, and process(). Referenced by find_real(), and proceed(). |
|
Definition at line 353 of file qeditor_view.cpp. References m_editor, and GotoLineDialog::setEditor(). Referenced by setupActions(). |
|
Definition at line 527 of file qeditor_view.cpp. References highlight(), m_currentParag, and m_editor. Referenced by doFind(), doReplace(), and highlight(). |
|
Definition at line 348 of file qeditor_view.cpp. References QEditor::indent(), and m_editor. Referenced by setupActions(). |
|
Definition at line 333 of file qeditor_view.cpp. References insertText(), m_editor, and text(). Referenced by QEditorCodeCompletion::eventFilter(), and insertText(). |
|
Install a Popup Menu. The Popup Menu will be activated on a right mouse button press event. Implements KTextEditor::PopupMenuInterface. Definition at line 306 of file qeditor_view.cpp. References installPopup(), m_editor, and QEditor::setApplicationMenu(). Referenced by installPopup(). |
|
Definition at line 618 of file qeditor_view.cpp. References internalCollapseBlock(), ParagData::level(), and ParagData::setOpen(). Referenced by collapseAllBlocks(), collapseBlock(), and internalCollapseBlock(). |
|
Definition at line 566 of file qeditor_view.cpp. References internalEnsureVisibleBlock(), internalExpandBlock(), and ParagData::level(). Referenced by ensureTextIsVisible(), and internalEnsureVisibleBlock(). |
|
Definition at line 593 of file qeditor_view.cpp. References internalExpandBlock(), ParagData::level(), and ParagData::setOpen(). Referenced by expandAllBlocks(), expandBlock(), internalEnsureVisibleBlock(), and internalExpandBlock(). |
|
Definition at line 179 of file qeditor_view.cpp. References m_levelWidget. |
|
Definition at line 165 of file qeditor_view.cpp. References m_lineNumberWidget. |
|
Definition at line 151 of file qeditor_view.cpp. References m_markerWidget. |
|
Definition at line 343 of file qeditor_view.cpp. References QEditor::language(), and m_editor. |
|
Definition at line 79 of file qeditor_view.h. References m_markerWidget. Referenced by QEditorPart::setDescription(), QEditorPart::setMarksUserChangable(), and QEditorPart::setPixmap(). |
|
Implements KTextEditor::TextHintInterface. Referenced by computeTextHint(). |
|
Referenced by QEditorView(). |
|
copies selected text
Implements KTextEditor::ClipboardInterface. Definition at line 301 of file qeditor_view.cpp. References m_editor. Referenced by setupActions(). |
|
Definition at line 360 of file qeditor_view.cpp. References QEditor::document(), find_real(), m_editor, m_options, and QEditor::textCursor(). Referenced by doFind(), and doReplace(). |
|
Definition at line 516 of file qeditor_view.cpp. References KoFind::find(), m_find, m_replace, process(), KoReplace::replace(), and text(). Referenced by find_real(), and process(). |
|
Definition at line 533 of file qeditor_view.cpp. References m_currentParag, m_editor, m_replaceDialog, replace(), and KoReplaceDialog::replacement(). Referenced by doReplace(), and replace(). |
|
select all text
Definition at line 670 of file qeditor_view.cpp. References m_editor. Referenced by setupActions(). |
|
Set the cursor position.
Implements KTextEditor::ViewCursorInterface. Definition at line 232 of file qeditor_view.cpp. References QEditor::document(), endl(), ensureTextIsVisible(), kdDebug(), m_editor, and setCursorPosition(). Referenced by setCursorPosition(). |
|
Set the cursor position, use 1 character per tab.
Implements KTextEditor::ViewCursorInterface. Definition at line 247 of file qeditor_view.cpp. References QEditor::document(), ensureTextIsVisible(), m_editor, and setCursorPositionReal(). Referenced by setCursorPositionReal(). |
|
Definition at line 338 of file qeditor_view.cpp. References m_editor, QEditor::setLanguage(), and setLanguage(). Referenced by QEditorPart::setHlMode(), and setLanguage(). |
|
Definition at line 184 of file qeditor_view.cpp. References m_levelWidget, and setLevelWidgetVisible(). Referenced by configChanged(), and setLevelWidgetVisible(). |
|
Definition at line 170 of file qeditor_view.cpp. References m_lineNumberWidget, and setLineNumberWidgetVisible(). Referenced by configChanged(), and setLineNumberWidgetVisible(). |
|
Definition at line 156 of file qeditor_view.cpp. References m_markerWidget, and setMarkerWidgetVisible(). Referenced by configChanged(), and setMarkerWidgetVisible(). |
|
Definition at line 198 of file qeditor_view.cpp. References m_editor, QEditor::setTabStop(), and setTabStop(). Referenced by setTabStop(). |
|
Definition at line 675 of file qeditor_view.cpp. References KXMLGUIClient::actionCollection(), collapseAllBlocks(), copy(), KStdAction::copy(), cut(), KStdAction::cut(), doc(), doFind(), doReplace(), editor(), expandAllBlocks(), KStdAction::find(), gotoLine(), KStdAction::gotoLine(), indent(), KStdAction::open(), paste(), KStdAction::pasteText(), KStdAction::redo(), KStdAction::replace(), KStdAction::save(), KStdAction::saveAs(), selectAll(), KStdAction::selectAll(), and KStdAction::undo(). Referenced by QEditorView(). |
|
This shows an argument hint.
Implements KTextEditor::CodeCompletionInterface. Definition at line 311 of file qeditor_view.cpp. References m_pCodeCompletion, QEditorCodeCompletion::showArgHint(), and showArgHint(). Referenced by showArgHint(). |
|
This shows a completion list.
Definition at line 318 of file qeditor_view.cpp. References aboutToShowCompletionBox(), m_pCodeCompletion, QEditorCodeCompletion::showCompletionBox(), and showCompletionBox(). Referenced by showCompletionBox(). |
|
Definition at line 193 of file qeditor_view.cpp. References m_editor, and QEditor::tabStop(). |
Member Data Documentation
|
Definition at line 121 of file qeditor_view.h. Referenced by find_real(), highlight(), QEditorView(), and replace(). |
|
Definition at line 288 of file qeditor_view.h. Referenced by doc(), and document(). |
|
Definition at line 289 of file qeditor_view.h. Referenced by collapseAllBlocks(), collapseBlock(), configChanged(), copy(), currentTextLine(), cursorColumn(), cursorColumnReal(), cursorCoordinates(), cursorLine(), cut(), doFind(), doReplace(), editor(), ensureTextIsVisible(), expandAllBlocks(), expandBlock(), gotoLine(), highlight(), indent(), insertText(), installPopup(), language(), paste(), proceed(), QEditorView(), replace(), selectAll(), setCursorPosition(), setCursorPositionReal(), setLanguage(), setTabStop(), and tabStop(). |
|
Definition at line 124 of file qeditor_view.h. Referenced by doFind(), process(), and QEditorView(). |
|
Definition at line 122 of file qeditor_view.h. Referenced by doFind(), and QEditorView(). |
|
Definition at line 293 of file qeditor_view.h. Referenced by doRepaint(), isLevelWidgetVisible(), QEditorView(), and setLevelWidgetVisible(). |
|
Definition at line 291 of file qeditor_view.h. Referenced by doRepaint(), isLineNumberWidgetVisible(), QEditorView(), and setLineNumberWidgetVisible(). |
|
Definition at line 292 of file qeditor_view.h. Referenced by doRepaint(), isMarkerWidgetVisible(), markerWidget(), QEditorView(), and setMarkerWidgetVisible(). |
|
Definition at line 127 of file qeditor_view.h. Referenced by find_real(), and QEditorView(). |
|
Definition at line 126 of file qeditor_view.h. Referenced by doFind(), doReplace(), find_real(), proceed(), and QEditorView(). |
|
Definition at line 290 of file qeditor_view.h. Referenced by QEditorView(), showArgHint(), showCompletionBox(), and ~QEditorView(). |
|
Definition at line 125 of file qeditor_view.h. Referenced by doReplace(), process(), and QEditorView(). |
|
Definition at line 123 of file qeditor_view.h. Referenced by doReplace(), QEditorView(), and replace(). |
|
Definition at line 294 of file qeditor_view.h. Referenced by disableTextHints(), and enableTextHints(). |
The documentation for this class was generated from the following files:
- editors/qeditor/qeditor_view.h
- editors/qeditor/qeditor_view.cpp