#include <sxUiComponent.h>
Public Types | |
enum | { TYPE = UserType + 1 } |
Public Member Functions | |
virtual void | Adjust () |
Adjust port position. | |
void | ReparentPorts (sxUiComponent *prnt) |
sxComponent * | Component () const |
QFont | Font () const |
void | SetFont (const QFont &f) |
QRectF | boundingRect () const |
virtual void | paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=0) |
virtual QVariant | itemChange (GraphicsItemChange change, const QVariant &value) |
method called when item change. | |
int | type () const |
virtual int | ShowPropertyDialog (QWidget *parent=0) |
virtual QWidget * | UiWidget () const |
user interface widget if any | |
Protected Member Functions | |
bool | SaveGui (QDomElement &guiNode) |
save gui property call this method from sxComponent::SaveGui | |
bool | LoadGui (const QDomElement &guiNode) |
Load position from file call this method form sxComponent::LoadGui. | |
virtual bool | SaveCustomGui (QDomElement &guiNode) |
virtual bool | LoadCustomGui (const QDomElement &guiNode) |
sxInPort * | CreateInputPort () const |
sxOutPort * | CreateOutputPort () const |
sxUiComponent (sxComponent *comp, const QString &pixmapName=QString()) | |
Protected Attributes | |
sxUiTextItem * | xText |
sxComponent * | xComp |
qreal | xTextHeight |
qreal | xMargin |
QString | xPixmapName |
QPixmap * | xPixmap |
QRectF | xBoundingRect |
void sxUiComponent::Adjust | ( | ) | [virtual] |
Adjust port position.
This method will be called once by component factory after ports allocation
References sxCaptionItem::Caption(), sxUiPort::East, sxUiPort::Location(), sxUiPort::North, sxUiPort::South, and sxUiPort::West.
Referenced by sxUiDesign::AdjustComponents().
QVariant sxUiComponent::itemChange | ( | GraphicsItemChange | change, | |
const QVariant & | value | |||
) | [virtual] |
method called when item change.
when item position changed, call sxUiDesign->SetModified(), and adjust port's connection
References sxUiPort::AdjustConnections(), and sxUiDesign::SetModified().