kate Library API Documentation

KateCSAndSIndent Class Reference

Inheritance diagram for KateCSAndSIndent:

KateNormalIndent KateAutoIndent List of all members.

Public Member Functions

 KateCSAndSIndent (KateDocument *doc)
 ~KateCSAndSIndent ()
virtual void processNewline (KateDocCursor &begin, bool needContinue)
virtual void processChar (QChar c)
virtual void processLine (KateDocCursor &line)
virtual void processSection (KateDocCursor &begin, KateDocCursor &end)
virtual bool canProcessLine () const
virtual uint modeNumber () const

Detailed Description

Definition at line 357 of file kateautoindent.h.


Member Function Documentation

void KateCSAndSIndent::processNewline KateDocCursor begin,
bool  needContinue
[virtual]
 

User pressed enter.

Line has been split; begin is on the new line.

Parameters:
begin Three unrelated variables: the new line number, where the first non-whitespace char was on the previous line, and the document.
needContinue Something to do with indenting the current line; always true.

Reimplemented from KateNormalIndent.

Definition at line 1475 of file kateautoindent.cpp.

References KateAutoIndent::doc, KateTextCursor::line(), KateDocument::lineLength(), KateDocument::plainKateTextLine(), processLine(), and KateTextCursor::setCol().

void KateCSAndSIndent::processChar QChar  c  )  [virtual]
 

Called every time a character is inserted into the document.

Parameters:
c character inserted

Reimplemented from KateNormalIndent.

Definition at line 1895 of file kateautoindent.cpp.

References KateDocument::activeView(), KateTextCursor::col(), KateView::cursorColumn(), KateView::cursorLine(), KateAutoIndent::doc, KateNormalIndent::doxyCommentAttrib, QString::find(), KateTextCursor::line(), KateDocument::plainKateTextLine(), processLine(), and KateDocument::removeText().

void KateCSAndSIndent::processLine KateDocCursor line  )  [virtual]
 

Aligns/indents the given line to the proper indent position.

Reimplemented from KateNormalIndent.

Definition at line 1339 of file kateautoindent.cpp.

References KateTextCursor::col(), KateAutoIndent::doc, KateDocument::insertText(), QString::length(), KateTextCursor::line(), KateDocument::lineLength(), KateDocument::plainKateTextLine(), KateDocument::removeText(), and KateTextCursor::setCol().

Referenced by processChar(), processNewline(), and processSection().

void KateCSAndSIndent::processSection KateDocCursor begin,
KateDocCursor end
[virtual]
 

Processes a section of text, indenting each line in between.

Reimplemented from KateNormalIndent.

Definition at line 1366 of file kateautoindent.cpp.

References QTime::elapsed(), endl(), KateDocCursor::gotoNextLine(), kdDebug(), KateTextCursor::line(), processLine(), and QTime::start().

virtual bool KateCSAndSIndent::canProcessLine  )  const [inline, virtual]
 

Set to true if an actual implementation of 'processLine' is present.

This is used to prevent a needless Undo action from being created.

Reimplemented from KateNormalIndent.

Definition at line 369 of file kateautoindent.h.

virtual uint KateCSAndSIndent::modeNumber  )  const [inline, virtual]
 

Mode index of this mode.

Returns:
modeNumber

Reimplemented from KateNormalIndent.

Definition at line 371 of file kateautoindent.h.


The documentation for this class was generated from the following files:
KDE Logo
This file is part of the documentation for kate Library Version 3.4.1.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Mon Jan 23 19:36:43 2006 by doxygen 1.4.3 written by Dimitri van Heesch, © 1997-2003