QElectroTech  0.70
Public Member Functions | Public Attributes | Private Member Functions | List of all members
SplittedHelperCell Class Reference

#include <splittedhelpercell.h>

Public Member Functions

 SplittedHelperCell (QGraphicsItem *=nullptr)
 
 ~SplittedHelperCell () override
 
void paint (QPainter *, const QStyleOptionGraphicsItem *, QWidget *=nullptr) override
 
- Public Member Functions inherited from HelperCell
 HelperCell (QGraphicsItem *=nullptr)
 
 ~HelperCell () override
 
void setGeometry (const QRectF &) override
 
QSizeF sizeHint (Qt::SizeHint, const QSizeF &=QSizeF()) const override
 
QRectF boundingRect () const override
 
void paint (QPainter *, const QStyleOptionGraphicsItem *, QWidget *=nullptr) override
 
virtual void setType (QET::TitleBlockColumnLength)
 
virtual void setActions (const QList< QAction *> &)
 
virtual QList< QAction * > actions () const
 
virtual void setLabel (const QString &text, bool=true)
 

Public Attributes

QColor split_background_color
 Background color on the split side. More...
 
QColor split_foreground_color
 Text color on the split side. More...
 
QString split_label
 Text displayed on the split side. More...
 
int split_size
 Length of the split side. More...
 
- Public Attributes inherited from HelperCell
QColor background_color
 Background color when rendering this cell. More...
 
QColor foreground_color
 Text color when rendering this cell. More...
 
QString label
 Label displayed in this cell. More...
 
Qt::Orientation orientation
 Orientation of this cell. More...
 
int index
 Index of this cell. More...
 

Private Member Functions

 SplittedHelperCell (const SplittedHelperCell &)
 

Additional Inherited Members

- Signals inherited from HelperCell
void contextMenuTriggered (HelperCell *)
 
void doubleClicked (HelperCell *)
 
- Protected Member Functions inherited from HelperCell
void contextMenuEvent (QGraphicsSceneContextMenuEvent *) override
 
void mouseDoubleClickEvent (QGraphicsSceneMouseEvent *) override
 

Detailed Description

This class is a variant of HelperCell having the ability to display two labels, with a split line between them.

Definition at line 26 of file splittedhelpercell.h.

Constructor & Destructor Documentation

◆ SplittedHelperCell() [1/2]

SplittedHelperCell::SplittedHelperCell ( QGraphicsItem *  parent = nullptr)

Constructor

Parameters
parentParent QGraphicsItem

Definition at line 24 of file splittedhelpercell.cpp.

◆ ~SplittedHelperCell()

SplittedHelperCell::~SplittedHelperCell ( )
override

Destructor

Definition at line 35 of file splittedhelpercell.cpp.

◆ SplittedHelperCell() [2/2]

SplittedHelperCell::SplittedHelperCell ( const SplittedHelperCell )
private

Member Function Documentation

◆ paint()

void SplittedHelperCell::paint ( QPainter *  painter,
const QStyleOptionGraphicsItem *  option,
QWidget *  widget = nullptr 
)
override

Handles the splitted helper cell visual rendering

Parameters
painterQPainter to be used for the rendering
optionRendering options
widgetQWidget being painted, if any

Definition at line 44 of file splittedhelpercell.cpp.

References HelperCell::background_color, HelperCell::foreground_color, HelperCell::label, HelperCell::paint(), split_background_color, split_foreground_color, split_label, and split_size.

Member Data Documentation

◆ split_background_color

QColor SplittedHelperCell::split_background_color

Background color on the split side.

Definition at line 39 of file splittedhelpercell.h.

Referenced by paint().

◆ split_foreground_color

QColor SplittedHelperCell::split_foreground_color

Text color on the split side.

Definition at line 40 of file splittedhelpercell.h.

Referenced by paint().

◆ split_label

QString SplittedHelperCell::split_label

Text displayed on the split side.

Definition at line 41 of file splittedhelpercell.h.

Referenced by paint().

◆ split_size

int SplittedHelperCell::split_size

Length of the split side.

Definition at line 42 of file splittedhelpercell.h.

Referenced by paint().


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