KateVi::NormalViMode
#include <normalvimode.h>
Inherits KateVi::ModeBase.
Inherited by KateVi::VisualViMode.
Public Member Functions | |
NormalViMode (InputModeManager *viInputModeManager, KTextEditor::ViewPrivate *view, KateViewInternal *viewInternal) | |
void | beginMonitoringDocumentChanges () |
bool | commandAbort () |
bool | commandAddToNumber () |
bool | commandAlignLine () |
bool | commandAlignLines () |
bool | commandAppendToBlock () |
bool | commandBottomView (bool onFirst) |
bool | commandBottomViewOnCursor () |
bool | commandBottomViewOnNonBlank () |
bool | commandCenterView (bool onFirst) |
bool | commandCenterViewOnCursor () |
bool | commandCenterViewOnNonBlank () |
bool | commandChange () |
bool | commandChangeCase () |
bool | commandChangeCaseLine () |
bool | commandChangeCaseRange () |
bool | commandChangeLine () |
bool | commandChangeToEOL () |
bool | commandCloseNocheck () |
bool | commandCloseView () |
bool | commandCloseWrite () |
bool | commandCollapseLocal () |
bool | commandCollapseToplevelNodes () |
bool | commandDelete () |
bool | commandDeleteChar () |
bool | commandDeleteCharBackward () |
bool | commandDeleteLine () |
bool | commandDeleteToEOL () |
bool | commandEnterInsertMode () |
bool | commandEnterInsertModeAppend () |
bool | commandEnterInsertModeAppendEOL () |
bool | commandEnterInsertModeBeforeFirstNonBlankInLine () |
bool | commandEnterInsertModeLast () |
bool | commandEnterReplaceMode () |
bool | commandEnterVisualBlockMode () |
bool | commandEnterVisualLineMode () |
bool | commandEnterVisualMode () |
bool | commandExpandAll () |
bool | commandExpandLocal () |
bool | commandFormatLine () |
bool | commandFormatLines () |
bool | commandGoToNextJump () |
bool | commandGoToPrevJump () |
bool | commandgPaste () |
bool | commandgPasteBefore () |
bool | commandIndentedPaste () |
bool | commandIndentedPasteBefore () |
bool | commandIndentLine () |
bool | commandIndentLines () |
bool | commandJoinLines () |
bool | commandMakeLowercase () |
bool | commandMakeLowercaseLine () |
bool | commandMakeUppercase () |
bool | commandMakeUppercaseLine () |
bool | commandOpenNewLineOver () |
bool | commandOpenNewLineUnder () |
bool | commandPaste () |
bool | commandPasteBefore () |
bool | commandPrependToBlock () |
bool | commandPrintCharacterCode () |
bool | commandRedo () |
bool | commandRepeatLastChange () |
bool | commandReplaceCharacter () |
bool | commandReplayMacro () |
bool | commandReselectVisual () |
bool | commandScrollHalfPageDown () |
bool | commandScrollHalfPageUp () |
bool | commandScrollPageDown () |
bool | commandScrollPageUp () |
bool | commandSearchBackward () |
bool | commandSearchForward () |
bool | commandSetMark () |
bool | commandSplitHoriz () |
bool | commandSplitVert () |
bool | commandStartRecordingMacro () |
bool | commandSubstituteChar () |
bool | commandSubstituteLine () |
bool | commandSubtractFromNumber () |
bool | commandSwitchToCmdLine () |
bool | commandSwitchToDownView () |
bool | commandSwitchToLeftView () |
bool | commandSwitchToNextTab () |
bool | commandSwitchToNextView () |
bool | commandSwitchToPrevTab () |
bool | commandSwitchToRightView () |
bool | commandSwitchToUpView () |
bool | commandToggleRegionVisibility () |
bool | commandToOtherEnd () |
bool | commandTopView (bool onFirst) |
bool | commandTopViewOnCursor () |
bool | commandTopViewOnNonBlank () |
bool | commandUndo () |
bool | commandUnindentLine () |
bool | commandUnindentLines () |
bool | commandYank () |
bool | commandYankLine () |
bool | commandYankToEOL () |
bool | handleKeypress (const QKeyEvent *e) override |
Range | motionDown () |
Range | motionDownToFirstNonBlank () |
Range | motionFindChar () |
Range | motionFindCharBackward () |
Range | motionHalfPageDown () |
Range | motionHalfPageUp () |
Range | motionLeft () |
Range | motionPageDown () |
Range | motionPageUp () |
Range | motionRepeatlastTF () |
Range | motionRepeatlastTFBackward () |
Range | motionRight () |
Range | motionToAfterParagraph () |
Range | motionToBeforeParagraph () |
Range | motionToChar () |
Range | motionToCharBackward () |
Range | motionToColumn0 () |
Range | motionToEndOfPrevWord () |
Range | motionToEndOfPrevWORD () |
Range | motionToEndOfWord () |
Range | motionToEndOfWORD () |
Range | motionToEOL () |
Range | motionToFirstCharacterOfLine () |
Range | motionToFirstLineOfWindow () |
Range | motionToIncrementalSearchMatch () |
Range | motionToLastLineOfWindow () |
Range | motionToLineFirst () |
Range | motionToLineLast () |
Range | motionToMark () |
Range | motionToMarkLine () |
Range | motionToMatchingItem () |
Range | motionToMiddleLineOfWindow () |
Range | motionToNextBraceBlockEnd () |
Range | motionToNextBraceBlockStart () |
Range | motionToNextOccurrence () |
Range | motionToNextSentence () |
Range | motionToNextVisualLine () |
Range | motionToPreviousBraceBlockEnd () |
Range | motionToPreviousBraceBlockStart () |
Range | motionToPreviousSentence () |
Range | motionToPrevOccurrence () |
Range | motionToPrevVisualLine () |
Range | motionToScreenColumn () |
Range | motionUp () |
Range | motionUpToFirstNonBlank () |
Range | motionWordBackward () |
Range | motionWORDBackward () |
Range | motionWordForward () |
Range | motionWORDForward () |
virtual void | reset () |
Range | textObjectABackQuote () |
Range | textObjectABracket () |
Range | textObjectAComma () |
Range | textObjectACurlyBracket () |
Range | textObjectAInequalitySign () |
Range | textObjectAParagraph () |
Range | textObjectAParen () |
Range | textObjectAQuoteDouble () |
Range | textObjectAQuoteSingle () |
Range | textObjectASentence () |
Range | textObjectAWord () |
Range | textObjectAWORD () |
Range | textObjectInnerBackQuote () |
Range | textObjectInnerBracket () |
Range | textObjectInnerComma () |
Range | textObjectInnerCurlyBracket () |
Range | textObjectInnerInequalitySign () |
Range | textObjectInnerParagraph () |
Range | textObjectInnerParen () |
Range | textObjectInnerQuoteDouble () |
Range | textObjectInnerQuoteSingle () |
Range | textObjectInnerSentence () |
Range | textObjectInnerWord () |
Range | textObjectInnerWORD () |
Protected Types | |
enum | PasteLocation { AtCurrentPosition, AfterCurrentPosition } |
Protected Member Functions | |
void | addHighlightYank (KTextEditor::Range range) |
virtual const std::vector< Command > & | commands () |
void | executeCommand (const Command *cmd) |
bool | executeKateCommand (const QString &command) |
KTextEditor::Cursor | findParagraphEnd () |
KTextEditor::Cursor | findParagraphStart () |
KTextEditor::Cursor | findSentenceEnd () |
KTextEditor::Cursor | findSentenceStart () |
QRegularExpression | generateMatchingItemRegex () const |
int | getFirstNonBlank (int line=-1) const |
OperationMode | getOperationMode () const |
QSet< KTextEditor::MovingRange * > & | highlightedYankForDocument () |
void | highlightYank (const Range &range, const OperationMode mode=CharWise) |
void | joinLines (unsigned int from, unsigned int to) const |
virtual const std::vector< Motion > & | motions () |
bool | motionWillBeUsedWithCommand () const |
bool | paste (NormalViMode::PasteLocation pasteLocation, bool isgPaste, bool isIndentedPaste) |
void | reformatLines (unsigned int from, unsigned int to) const |
void | resetParser () |
void | shrinkRangeAroundCursor (Range &toShrink, const Range &rangeToShrinkTo) const |
Range | textObjectComma (bool inner) const |
bool | waitingForRegisterOrCharToSearch () |
Static Protected Member Functions | |
static KTextEditor::Cursor | cursorPosAtEndOfPaste (const KTextEditor::Cursor pasteLocation, const QString &pastedText) |
Protected Attributes | |
QStack< int > | m_awaitingMotionOrTextObject |
bool | m_commandShouldKeepSelection |
bool | m_commandWithMotion |
unsigned int | m_countTemp |
KTextEditor::Cursor | m_currentChangeEndMarker |
bool | m_deleteCommand |
bool | m_findWaitingForChar |
QSet< KTextEditor::MovingRange * > | m_highlightedYanks |
KTextEditor::Attribute::Ptr | m_highlightYankAttribute |
bool | m_isRepeatedTFcommand |
bool | m_isUndo |
KeyParser * | m_keyParser |
QString | m_keys |
bool | m_lastMotionWasLinewiseInnerBlock |
QString | m_lastTFcommand |
bool | m_linewiseCommand |
QVector< int > | m_matchingCommands |
QHash< QString, QString > | m_matchingItems |
QVector< int > | m_matchingMotions |
QRegularExpression | m_matchItemRegex |
bool | m_motionCanChangeWholeVisualModeSelection |
int | m_motionOperatorIndex |
bool | m_pendingResetIsDueToExit |
KTextEditor::Cursor | m_positionWhenIncrementalSearchBegan |
int | m_scroll_count_limit |
Detailed Description
Commands for the vi normal mode.
Definition at line 39 of file normalvimode.h.
Member Function Documentation
◆ commandEnterInsertMode()
bool NormalViMode::commandEnterInsertMode | ( | ) |
enter insert mode at the cursor position
Definition at line 504 of file normalvimode.cpp.
◆ commandEnterInsertModeAppend()
bool NormalViMode::commandEnterInsertModeAppend | ( | ) |
enter insert mode after the current character
Definition at line 515 of file normalvimode.cpp.
◆ commandEnterInsertModeAppendEOL()
bool NormalViMode::commandEnterInsertModeAppendEOL | ( | ) |
start insert mode after the last character of the line
Definition at line 541 of file normalvimode.cpp.
◆ commandEnterInsertModeLast()
bool NormalViMode::commandEnterInsertModeLast | ( | ) |
enter insert mode at the last insert position
Definition at line 569 of file normalvimode.cpp.
◆ commands()
|
protectedvirtual |
Return commands available for this mode.
Overwritten in sub classes to replace them, must be a stable reference!
Definition at line 3970 of file normalvimode.cpp.
◆ getFirstNonBlank()
|
protected |
Get the index of the first non-blank character from the given line.
- Parameters
-
line The line to be picked. The current line will picked instead if this parameter is set to a negative value.
- Returns
- the index of the first non-blank character from the given line. If a non-space character cannot be found, the 0 is returned.
Definition at line 3689 of file normalvimode.cpp.
◆ handleKeypress()
|
override |
parses a key stroke to check if it's a valid (part of) a command
- Returns
- true if a command was completed and executed, false otherwise
Definition at line 89 of file normalvimode.cpp.
◆ motions()
|
protectedvirtual |
Return motions available for this mode.
Overwritten in sub classes to replace them, must be a stable reference!
Definition at line 4089 of file normalvimode.cpp.
◆ resetParser()
|
protected |
(re)set to start configuration.
This is done when a command is completed executed or when a command is aborted
Definition at line 410 of file normalvimode.cpp.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2022 The KDE developers.
Generated on Sun Jun 26 2022 03:49:56 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.