Gui::DocumentObjectItem Class Reference

The link between the tree and a document object. More...

#include <Tree.h>

Public Member Functions

void displayStatusInfo ()
 
 DocumentObjectItem (DocumentItem *ownerDocItem, DocumentObjectDataPtr data)
 
App::DocumentObjectgetFullSubName (std::ostringstream &str, DocumentObjectItem *parent=0) const
 
const char * getName () const
 
DocumentItemgetOwnerDocument () const
 
DocumentItemgetParentDocument () const
 
DocumentObjectItemgetParentItem () const
 
App::DocumentObjectgetRelativeParent (std::ostringstream &str, DocumentObjectItem *cousin, App::DocumentObject **topParent=0, std::string *topSubname=0) const
 
int getSubName (std::ostringstream &str, App::DocumentObject *&topParent) const
 
TreeWidgetgetTree () const
 
const char * getTreeName () const
 
bool isChildOfItem (DocumentObjectItem *)
 
int isGroup () const
 
bool isLink () const
 
bool isLinkFinal () const
 
int isParentGroup () const
 
bool isParentLink () const
 
Gui::ViewProviderDocumentObjectobject () const
 
bool requiredAtRoot (bool excludeSelf=true) const
 
void restoreBackground ()
 
void setData (int column, int role, const QVariant &value)
 
void setExpandedStatus (bool)
 
void setHighlight (bool set, HighlightMode mode=HighlightMode::LightBlue)
 
void testStatus (bool resetStatus)
 
void testStatus (bool resetStatus, QIcon &icon1, QIcon &icon2)
 
 ~DocumentObjectItem ()
 

Friends

class DocumentItem
 
class TreeWidget
 

Detailed Description

The link between the tree and a document object.

Every object in the document gets its associated DocumentObjectItem which controls the visibility and the functions of the object.

Author
Werner Mayer

Constructor & Destructor Documentation

◆ DocumentObjectItem()

DocumentObjectItem::DocumentObjectItem ( DocumentItem ownerDocItem,
DocumentObjectDataPtr  data 
)

◆ ~DocumentObjectItem()

DocumentObjectItem::~DocumentObjectItem ( )

Member Function Documentation

◆ displayStatusInfo()

◆ getFullSubName()

App::DocumentObject * DocumentObjectItem::getFullSubName ( std::ostringstream &  str,
DocumentObjectItem parent = 0 
) const

◆ getName()

◆ getOwnerDocument()

◆ getParentDocument()

DocumentItem * DocumentObjectItem::getParentDocument ( ) const

◆ getParentItem()

◆ getRelativeParent()

App::DocumentObject * DocumentObjectItem::getRelativeParent ( std::ostringstream &  str,
DocumentObjectItem cousin,
App::DocumentObject **  topParent = 0,
std::string *  topSubname = 0 
) const

References getName(), and getSubName().

◆ getSubName()

int DocumentObjectItem::getSubName ( std::ostringstream &  str,
App::DocumentObject *&  topParent 
) const

◆ getTree()

TreeWidget * DocumentObjectItem::getTree ( ) const

Referenced by getParentDocument(), and testStatus().

◆ getTreeName()

const char * DocumentObjectItem::getTreeName ( ) const

◆ isChildOfItem()

bool DocumentObjectItem::isChildOfItem ( DocumentObjectItem item)

◆ isGroup()

◆ isLink()

◆ isLinkFinal()

bool DocumentObjectItem::isLinkFinal ( ) const

◆ isParentGroup()

int DocumentObjectItem::isParentGroup ( ) const

◆ isParentLink()

bool DocumentObjectItem::isParentLink ( ) const

References getParentItem().

◆ object()

◆ requiredAtRoot()

bool DocumentObjectItem::requiredAtRoot ( bool  excludeSelf = true) const

◆ restoreBackground()

void DocumentObjectItem::restoreBackground ( )

◆ setData()

void DocumentObjectItem::setData ( int  column,
int  role,
const QVariant &  value 
)

◆ setExpandedStatus()

void DocumentObjectItem::setExpandedStatus ( bool  on)

◆ setHighlight()

◆ testStatus() [1/2]

void DocumentObjectItem::testStatus ( bool  resetStatus)

References testStatus().

◆ testStatus() [2/2]

Friends And Related Function Documentation

◆ DocumentItem

friend class DocumentItem
friend

◆ TreeWidget

friend class TreeWidget
friend

The documentation for this class was generated from the following files:
  • Sources/FreeCAD/src/Gui/Tree.h
  • Sources/FreeCAD/src/Gui/Tree.cpp