#include <OSItem.hpp>
Public Slots | |
void | onRemoveClicked () |
Signals | |
void | itemClicked (OSItem *) |
void | itemRemoveClicked (OSItem *) |
void | itemReplacementDropped (OSItem *currentItem, const OSItemId &replacementItemId) |
Public Member Functions | |
bool | draggable () const |
virtual bool | equal (const OSItem *other) const =0 |
bool | inspectable () const |
bool | isDefaulted () const |
OSItemId | itemId () const |
QPixmap | leftPixmap () const |
OSItem (const OSItemId &itemId, OSItemType osItemType=OSItemType::ListItem,*parent=nullptr) | |
OSItemType | osItemType () const |
bool | removeable () const |
! is the remove button visible More... | |
QPixmap | rightPixmap () const |
bool | selected () const |
void | setAspectRatio (AspectRatio aspectRatio) |
void | setDraggable (bool draggable) |
void | setInspectable (bool inspectable) |
void | setIsDefaulted (bool isDefaulted) |
void | setLeftPixmap (const QPixmap &pixmap) |
void | setOSItemType (OSItemType osItemType) |
void | setRemoveable (bool removeable) |
! show / hide the remove button More... | |
void | setRightPixmap (const QPixmap &pixmap) |
void | setSelected (bool selected) |
void | setText (const QString &text) |
void | setUseLargeIcon (bool userLargeIcon) |
QString | text () const |
bool | useLargeIcon () |
virtual | ~OSItem () |
Static Public Member Functions | |
static OSItem * | makeItem (const OSItemId &itemId, OSItemType osItemType=OSItemType::ListItem) |
Static Public Attributes | |
static const int | BTN_HEIGHT = 20 |
static const int | BTN_WIDTH = 20 |
static const int | HEADER_HEIGHT = 40 |
! The height, if a header More... | |
static const int | HEADER_WIDTH = ITEM_WIDTH |
! The width, if a header More... | |
static const int | IMAGE_HEIGHT = 30 |
static const int | IMAGE_WIDTH = 30 |
static const int | ITEM_HEIGHT = 60 |
! The height, if a rectangle More... | |
static const int | ITEM_SIDE = 80 |
! The side length, if a square More... | |
static const int | ITEM_WIDTH = 150 |
! The width, if a rectangle More... | |
Protected Member Functions | |
void | dragEnterEvent (QDragEnterEvent *event) override |
void | dropEvent (QDropEvent *event) override |
bool | isBold () |
void | leaveEvent (QEvent *event) override |
void | mouseMoveEvent (QMouseEvent *event) override |
void | mousePressEvent (QMouseEvent *event) override |
void | mouseReleaseEvent (QMouseEvent *event) override |
void | paintEvent (QPaintEvent *event) override |
void | setBold (bool isBold) |
void | setTextColor (QColor color=Qt::black) |
QColor | textColor () |
Protected Attributes | |
MeasureBadge * | m_measureBadge |
openstudio::OSItem::OSItem | ( | const OSItemId & | itemId, |
OSItemType | osItemType = OSItemType::ListItem , |
||
* | parent = nullptr |
||
) |
|
inlinevirtual |
|
overrideprotected |
bool openstudio::OSItem::draggable | ( | ) | const |
|
overrideprotected |
|
pure virtual |
Implemented in openstudio::ScriptItem, openstudio::ModelObjectItem, and openstudio::BCLComponentItem.
bool openstudio::OSItem::inspectable | ( | ) | const |
|
protected |
bool openstudio::OSItem::isDefaulted | ( | ) | const |
|
signal |
OSItemId openstudio::OSItem::itemId | ( | ) | const |
|
signal |
|
signal |
|
overrideprotected |
QPixmap openstudio::OSItem::leftPixmap | ( | ) | const |
|
static |
|
overrideprotected |
|
overrideprotected |
|
overrideprotected |
|
slot |
OSItemType openstudio::OSItem::osItemType | ( | ) | const |
|
overrideprotected |
bool openstudio::OSItem::removeable | ( | ) | const |
! is the remove button visible
QPixmap openstudio::OSItem::rightPixmap | ( | ) | const |
bool openstudio::OSItem::selected | ( | ) | const |
void openstudio::OSItem::setAspectRatio | ( | AspectRatio | aspectRatio | ) |
|
protected |
void openstudio::OSItem::setDraggable | ( | bool | draggable | ) |
void openstudio::OSItem::setInspectable | ( | bool | inspectable | ) |
void openstudio::OSItem::setIsDefaulted | ( | bool | isDefaulted | ) |
void openstudio::OSItem::setLeftPixmap | ( | const QPixmap & | pixmap | ) |
void openstudio::OSItem::setOSItemType | ( | OSItemType | osItemType | ) |
void openstudio::OSItem::setRemoveable | ( | bool | removeable | ) |
! show / hide the remove button
void openstudio::OSItem::setRightPixmap | ( | const QPixmap & | pixmap | ) |
void openstudio::OSItem::setSelected | ( | bool | selected | ) |
void openstudio::OSItem::setText | ( | const QString & | text | ) |
|
protected |
void openstudio::OSItem::setUseLargeIcon | ( | bool | userLargeIcon | ) |
QString openstudio::OSItem::text | ( | ) | const |
|
protected |
bool openstudio::OSItem::useLargeIcon | ( | ) |
|
static |
|
static |
|
static |
! The height, if a header
|
static |
! The width, if a header
|
static |
|
static |
|
static |
! The height, if a rectangle
|
static |
! The side length, if a square
|
static |
! The width, if a rectangle
|
protected |