Gui::TextEditor Class Reference

#include <TextEdit.h>

Inheritance diagram for Gui::TextEditor:
Gui::TextEdit Gui::WindowParameter Gui::PythonEditor

List of all members.

Public Member Functions

void lineNumberAreaPaintEvent (QPaintEvent *)
int lineNumberAreaWidth ()
void OnChange (Base::Subject< const char * > &rCaller, const char *rcReason)
 Sets the font, font size and tab size of the editor.
void setSyntaxHighlighter (SyntaxHighlighter *)
 TextEditor (QWidget *parent=0)
 Constructs a TextEditor which is a child of 'parent' and does the syntax highlighting for the Python language.
 ~TextEditor ()
 Destroys the object and frees any allocated resources.

Protected Member Functions

virtual void drawMarker (int line, int x, int y, QPainter *)
void keyPressEvent (QKeyEvent *e)
 Set the approproriate item of the completion box or hide it, if needed.
void paintEvent (QPaintEvent *e)
 Draw a beam in the line where the cursor is.
void resizeEvent (QResizeEvent *e)

Friends

class SyntaxHighlighter

Detailed Description

Definition at line 78 of file TextEdit.h.


Constructor & Destructor Documentation

TextEditor::TextEditor ( QWidget *  parent = 0  ) 

Constructs a TextEditor which is a child of 'parent' and does the syntax highlighting for the Python language.

Definition at line 204 of file TextEdit.cpp.

References draftlibs::fcgeo::connect(), and Gui::WindowParameter::getWindowParameter().

TextEditor::~TextEditor (  ) 

Destroys the object and frees any allocated resources.

Definition at line 233 of file TextEdit.cpp.

References Gui::WindowParameter::getWindowParameter().


Member Function Documentation

void TextEditor::drawMarker ( int  line,
int  x,
int  y,
QPainter *  p 
) [protected, virtual]

Reimplemented in Gui::PythonEditor.

Definition at line 287 of file TextEdit.cpp.

Referenced by lineNumberAreaPaintEvent().

void TextEditor::keyPressEvent ( QKeyEvent *  e  )  [protected]

Set the approproriate item of the completion box or hide it, if needed.

Reimplemented from Gui::TextEdit.

Definition at line 323 of file TextEdit.cpp.

References Gui::WindowParameter::getWindowParameter(), indent, and RobotExample::pos.

void TextEditor::lineNumberAreaPaintEvent ( QPaintEvent *  event  ) 

Definition at line 291 of file TextEdit.cpp.

References drawMarker(), and Py::int.

Referenced by Gui::LineMarker::paintEvent().

int TextEditor::lineNumberAreaWidth (  ) 

Definition at line 240 of file TextEdit.cpp.

Referenced by resizeEvent(), and Gui::LineMarker::sizeHint().

void TextEditor::OnChange ( Base::Subject< const char * > &  rCaller,
const char *  sReason 
)

Sets the font, font size and tab size of the editor.

Reimplemented from Gui::WindowParameter.

Definition at line 410 of file TextEdit.cpp.

References Gui::TextEditorP::colormap, Gui::WindowParameter::getWindowParameter(), and Gui::SyntaxHighlighter::setColor().

void TextEditor::paintEvent ( QPaintEvent *  e  )  [protected]

Draw a beam in the line where the cursor is.

Definition at line 443 of file TextEdit.cpp.

void TextEditor::resizeEvent ( QResizeEvent *  e  )  [protected]

Definition at line 261 of file TextEdit.cpp.

References cr, and lineNumberAreaWidth().

void TextEditor::setSyntaxHighlighter ( SyntaxHighlighter sh  ) 

Definition at line 317 of file TextEdit.cpp.

Referenced by open(), and Gui::PythonEditor::PythonEditor().


Friends And Related Function Documentation

friend class SyntaxHighlighter [friend]

Definition at line 109 of file TextEdit.h.


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

Generated on Wed Nov 23 19:02:03 2011 for FreeCAD by  doxygen 1.6.1