Choreonoid  1.8
Classes | Public Member Functions | List of all members
cnoid::ItemTreeWidget Class Reference

#include <ItemTreeWidget.h>

Inheritance diagram for cnoid::ItemTreeWidget:

Classes

class  Display
 

Public Member Functions

 ItemTreeWidget (QWidget *parent=nullptr)
 
 ~ItemTreeWidget ()
 
RootItemprojectRootItem ()
 
ItemfindRootItem ()
 
template<class ItemType >
ItemType * findRootItem ()
 
ItemfindOrCreateRootItem ()
 
template<class ItemType >
ItemType * findOrCreateRootItem ()
 
void setRootItem (Item *item)
 
void setRootItemUpdateFunction (std::function< Item *(bool doCreate)> func)
 
void setRootItemVisible (bool on)
 
bool isRootItemVisible () const
 
void setDragDropEnabled (bool on)
 
void setCheckColumnShown (bool on)
 
template<class ItemType >
void customizeVisibility (std::function< bool(ItemType *item, bool isTopLevelItemCandidate)> func)
 
template<class ItemType >
void customizeDisplay (std::function< void(ItemType *item, Display &display)> func)
 
template<class ItemType >
void customizePositionAcceptance (std::function< bool(ItemType *item, Item *parentItem)> func)
 
bool checkPositionAcceptance (Item *item, Item *parentItem) const
 
void customizeRootContextMenu (std::function< void(MenuManager &menuManager)> func)
 
template<class ItemType >
void customizeContextMenu (std::function< void(ItemType *item, MenuManager &menuManager, ItemFunctionDispatcher menuFunction)> func)
 
void updateTreeWidgetItems ()
 
void setExpanded (Item *item, bool on=true)
 
void editItemName (Item *item)
 
ItemList getItems () const
 
template<class ItemType >
ItemList< ItemType > getItems ()
 
void setSelectionSyncGroup (const std::string &id)
 
SignalProxy< void(const ItemList<> &)> sigSelectionChanged ()
 
ItemList getSelectedItems () const
 
template<class ItemType >
ItemList< ItemType > getSelectedItems ()
 
bool selectOnly (Item *item)
 
void selectAllItems ()
 
void clearSelection ()
 
void setSelectedItemsChecked (bool on)
 
void toggleSelectedItemChecks ()
 
void cutSelectedItems ()
 
void copySelectedItems ()
 
void copySelectedItemsWithSubTrees ()
 
bool pasteItems (bool doCheckPositionAcceptance=true)
 
bool checkPastable (Item *pasteParentItem) const
 
bool storeState (Archive &archive)
 
bool restoreState (const Archive &archive)
 

Constructor & Destructor Documentation

◆ ItemTreeWidget()

ItemTreeWidget::ItemTreeWidget ( QWidget *  parent = nullptr)

◆ ~ItemTreeWidget()

ItemTreeWidget::~ItemTreeWidget ( )

Member Function Documentation

◆ checkPastable()

bool ItemTreeWidget::checkPastable ( Item pasteParentItem) const

◆ checkPositionAcceptance()

bool ItemTreeWidget::checkPositionAcceptance ( Item item,
Item parentItem 
) const

◆ clearSelection()

void ItemTreeWidget::clearSelection ( )

◆ copySelectedItems()

void ItemTreeWidget::copySelectedItems ( )

◆ copySelectedItemsWithSubTrees()

void ItemTreeWidget::copySelectedItemsWithSubTrees ( )

◆ customizeContextMenu()

template<class ItemType >
void cnoid::ItemTreeWidget::customizeContextMenu ( std::function< void(ItemType *item, MenuManager &menuManager, ItemFunctionDispatcher menuFunction)>  func)
inline

◆ customizeDisplay()

template<class ItemType >
void cnoid::ItemTreeWidget::customizeDisplay ( std::function< void(ItemType *item, Display &display)>  func)
inline

◆ customizePositionAcceptance()

template<class ItemType >
void cnoid::ItemTreeWidget::customizePositionAcceptance ( std::function< bool(ItemType *item, Item *parentItem)>  func)
inline

◆ customizeRootContextMenu()

void ItemTreeWidget::customizeRootContextMenu ( std::function< void(MenuManager &menuManager)>  func)

◆ customizeVisibility()

template<class ItemType >
void cnoid::ItemTreeWidget::customizeVisibility ( std::function< bool(ItemType *item, bool isTopLevelItemCandidate)>  func)
inline

◆ cutSelectedItems()

void ItemTreeWidget::cutSelectedItems ( )

◆ editItemName()

void ItemTreeWidget::editItemName ( Item item)

◆ findOrCreateRootItem() [1/2]

Item * ItemTreeWidget::findOrCreateRootItem ( )

◆ findOrCreateRootItem() [2/2]

template<class ItemType >
ItemType* cnoid::ItemTreeWidget::findOrCreateRootItem ( )
inline

◆ findRootItem() [1/2]

Item * ItemTreeWidget::findRootItem ( )

◆ findRootItem() [2/2]

template<class ItemType >
ItemType* cnoid::ItemTreeWidget::findRootItem ( )
inline

◆ getItems() [1/2]

template<class ItemType >
ItemList<ItemType> cnoid::ItemTreeWidget::getItems ( )
inline

◆ getItems() [2/2]

ItemList ItemTreeWidget::getItems ( ) const

◆ getSelectedItems() [1/2]

template<class ItemType >
ItemList<ItemType> cnoid::ItemTreeWidget::getSelectedItems ( )
inline

◆ getSelectedItems() [2/2]

ItemList ItemTreeWidget::getSelectedItems ( ) const

◆ isRootItemVisible()

bool ItemTreeWidget::isRootItemVisible ( ) const

◆ pasteItems()

bool ItemTreeWidget::pasteItems ( bool  doCheckPositionAcceptance = true)

◆ projectRootItem()

RootItem * ItemTreeWidget::projectRootItem ( )

◆ restoreState()

bool ItemTreeWidget::restoreState ( const Archive archive)

◆ selectAllItems()

void ItemTreeWidget::selectAllItems ( )

◆ selectOnly()

bool ItemTreeWidget::selectOnly ( Item item)
Returns
true if the selected items are changed

◆ setCheckColumnShown()

void ItemTreeWidget::setCheckColumnShown ( bool  on)

◆ setDragDropEnabled()

void ItemTreeWidget::setDragDropEnabled ( bool  on)

◆ setExpanded()

void ItemTreeWidget::setExpanded ( Item item,
bool  on = true 
)

◆ setRootItem()

void ItemTreeWidget::setRootItem ( Item item)

◆ setRootItemUpdateFunction()

void ItemTreeWidget::setRootItemUpdateFunction ( std::function< Item *(bool doCreate)>  func)

◆ setRootItemVisible()

void ItemTreeWidget::setRootItemVisible ( bool  on)
Note
This functions does not update the tree widget items

◆ setSelectedItemsChecked()

void ItemTreeWidget::setSelectedItemsChecked ( bool  on)

◆ setSelectionSyncGroup()

void ItemTreeWidget::setSelectionSyncGroup ( const std::string &  id)

◆ sigSelectionChanged()

SignalProxy< void(const ItemList<> &)> ItemTreeWidget::sigSelectionChanged ( )

◆ storeState()

bool ItemTreeWidget::storeState ( Archive archive)

◆ toggleSelectedItemChecks()

void ItemTreeWidget::toggleSelectedItemChecks ( )

◆ updateTreeWidgetItems()

void ItemTreeWidget::updateTreeWidgetItems ( )

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