Tinkercell::CodeEditor Class Reference

#include <CodeEditor.h>

Public Member Functions

 CodeEditor (QWidget *parent=0)
void lineNumberAreaPaintEvent (QPaintEvent *event)
int lineNumberAreaWidth ()
void setCompleter (QCompleter *c)
QCompleter * completer () const
void zoomIn (int r=1)
void zoomOut (int r=1)

Data Fields

QWidget * lineNumberArea
QColor lineHighlightColor
QColor lineNumberBackground
QColor lineNumberText

Protected Member Functions

void resizeEvent (QResizeEvent *event)
virtual void wheelEvent (QWheelEvent *wheelEvent)
void keyPressEvent (QKeyEvent *e)
void focusInEvent (QFocusEvent *e)

Private Slots

void updateLineNumberAreaWidth (int newBlockCount)
void highlightCurrentLine ()
void updateLineNumberArea (const QRect &, int)
void insertCompletion (const QString &completion)

Private Member Functions

QString textUnderCursor () const

Private Attributes

QCompleter * c

Detailed Description

Definition at line 70 of file CodeEditor.h.


Constructor & Destructor Documentation

Tinkercell::CodeEditor::CodeEditor ( QWidget *  parent = 0  ) 

Member Function Documentation

QCompleter * Tinkercell::CodeEditor::completer (  )  const

Definition at line 68 of file CodeEditor.cpp.

References c.

void Tinkercell::CodeEditor::focusInEvent ( QFocusEvent *  e  )  [protected]

Definition at line 92 of file CodeEditor.cpp.

References c.

void Tinkercell::CodeEditor::highlightCurrentLine (  )  [private, slot]

Definition at line 209 of file CodeEditor.cpp.

References lineHighlightColor, and selection.

Referenced by CodeEditor().

void Tinkercell::CodeEditor::insertCompletion ( const QString &  completion  )  [private, slot]

Definition at line 73 of file CodeEditor.cpp.

References c.

Referenced by setCompleter().

void Tinkercell::CodeEditor::keyPressEvent ( QKeyEvent *  e  )  [protected]

Definition at line 99 of file CodeEditor.cpp.

References c, cr, and textUnderCursor().

void Tinkercell::CodeEditor::lineNumberAreaPaintEvent ( QPaintEvent *  event  ) 

Definition at line 228 of file CodeEditor.cpp.

References lineNumberArea, lineNumberBackground, and lineNumberText.

int Tinkercell::CodeEditor::lineNumberAreaWidth (  ) 

Definition at line 163 of file CodeEditor.cpp.

References max.

Referenced by resizeEvent(), and updateLineNumberAreaWidth().

void Tinkercell::CodeEditor::resizeEvent ( QResizeEvent *  event  )  [protected]

Definition at line 199 of file CodeEditor.cpp.

References cr, lineNumberArea, and lineNumberAreaWidth().

void Tinkercell::CodeEditor::setCompleter ( QCompleter *  c  ) 

Definition at line 51 of file CodeEditor.cpp.

References c, and insertCompletion().

QString Tinkercell::CodeEditor::textUnderCursor (  )  const [private]

Definition at line 85 of file CodeEditor.cpp.

Referenced by keyPressEvent().

void Tinkercell::CodeEditor::updateLineNumberArea ( const QRect &  rect,
int  dy 
) [private, slot]

Definition at line 186 of file CodeEditor.cpp.

References lineNumberArea, and updateLineNumberAreaWidth().

Referenced by CodeEditor().

void Tinkercell::CodeEditor::updateLineNumberAreaWidth ( int  newBlockCount  )  [private, slot]

Definition at line 179 of file CodeEditor.cpp.

References lineNumberAreaWidth().

Referenced by CodeEditor(), and updateLineNumberArea().

void Tinkercell::CodeEditor::wheelEvent ( QWheelEvent *  wheelEvent  )  [protected, virtual]

Definition at line 290 of file CodeEditor.cpp.

References zoomIn(), and zoomOut().

void Tinkercell::CodeEditor::zoomIn ( int  r = 1  ) 

Definition at line 264 of file CodeEditor.cpp.

References f.

Referenced by wheelEvent(), and zoomOut().

void Tinkercell::CodeEditor::zoomOut ( int  r = 1  ) 

Definition at line 285 of file CodeEditor.cpp.

References zoomIn().

Referenced by wheelEvent().


Field Documentation

QCompleter* Tinkercell::CodeEditor::c [private]

Definition at line 108 of file CodeEditor.h.

Referenced by completer(), focusInEvent(), insertCompletion(), keyPressEvent(), and setCompleter().

Definition at line 88 of file CodeEditor.h.

Referenced by CodeEditor(), and highlightCurrentLine().

Definition at line 89 of file CodeEditor.h.

Referenced by CodeEditor(), and lineNumberAreaPaintEvent().

Definition at line 90 of file CodeEditor.h.

Referenced by CodeEditor(), and lineNumberAreaPaintEvent().


The documentation for this class was generated from the following files:

Generated on Tue Nov 3 23:17:14 2009 for Network Evolution Library by  doxygen 1.6.1