Inheritance diagram for IAEX::Cell:
Public Slots | |
virtual void | addRule (Rule *r) |
Adds a rule to the cell. | |
virtual void | setStyle (const QString &stylename) |
Set cell style. | |
virtual void | setStyle (CellStyle style) |
Set the current cell style. | |
void | setCellTag (QString tagname) |
Set cells tag name. | |
virtual void | setBackgroundColor (const QColor color) |
Set the cells background color. | |
virtual void | setSelected (const bool selected) |
Set the value for selectec_ to true if the cell is selected. | |
virtual void | setHeight (const int height) |
Sets the height of the cell. | |
void | hideTreeView (const bool hidden) |
Public Member Functions | |
Cell (QWidget *parent=0) | |
The class constructor. | |
virtual | ~Cell () |
The class destructor. | |
virtual QTextCursor | textCursor () |
return the cells text cursor. if the cell don't have a cursor that have been created by the default constructor and is a null cursor. | |
virtual void | accept (Visitor &v) |
Implements visitor acceptability. | |
const bool | isSelected () const |
const bool | isTreeViewVisible () const |
const bool | isViewExpression () const |
Function for telling if the function viewExpression is activated or not. | |
const QColor | backgroundColor () const |
get the current backgroundcolor. | |
virtual CellStyle * | style () |
Get the current cell style. | |
QString | cellTag () |
Get the cell tag name. | |
QWidget * | mainWidget () |
Protected Slots | |
void | setTreeWidget (TreeView *newTreeWidget) |
Add a treeview widget to the cell. | |
void | setMainWidget (QWidget *newWidget) |
Set the cells mainwidget. | |
void | addChapterCounter (QWidget *counter) |
Update the cell layout with a chapter counter. | |
Protected Member Functions | |
void | mouseReleaseEvent (QMouseEvent *event) |
Describes what will happen if a mousebutton is released when the mouse is over the treeview widget. | |
void | mouseMoveEvent (QMouseEvent *event) |
Mouse move event is triggered when the mouse is moved. | |
void | applyRulesToStyle () |
Apply any rules to the current cellstyle. |
To extend the Qt Notebook application with new type of cells subclass this class. Then subclass or reimplement a CellFactory so it creates the new type of cell. Examples of adding new cell look at InputCell and ImageCell.
Cells contains of two parts, a mainwidget containing the cells data, and the treewidget containing the treeview at the right side of the cell.
|
The class constructor.
|
|
The class destructor.
|
|
Update the cell layout with a chapter counter.
|
|
Adds a rule to the cell.
|
|
Apply any rules to the current cellstyle.
|
|
get the current backgroundcolor.
|
|
Get the cell tag name.
|
|
|
|
|
|
|
|
Function for telling if the function viewExpression is activated or not.
|
|
|
|
Mouse move event is triggered when the mouse is moved. This method must be implemented when adding support for drag and drop. Also look at the QT manual for more information about drag and drop.
|
|
Describes what will happen if a mousebutton is released when the mouse is over the treeview widget.
|
|
Set the cells background color.
|
|
Set cells tag name.
|
|
Sets the height of the cell.
|
|
Set the cells mainwidget.
|
|
Set the value for selectec_ to true if the cell is selected.
|
|
Set the current cell style.
Reimplemented in IAEX::CellGroup, IAEX::InputCell, and IAEX::TextCell. |
|
Set cell style.
Reimplemented in IAEX::InputCell, and IAEX::TextCell. |
|
Get the current cell style.
Reimplemented in IAEX::CellGroup. |
|
return the cells text cursor. if the cell don't have a cursor that have been created by the default constructor and is a null cursor.
Reimplemented in IAEX::InputCell, and IAEX::TextCell. |