5 #ifndef CNOID_BASE_TREE_WIDGET_H
6 #define CNOID_BASE_TREE_WIDGET_H
8 #include <cnoid/Signal>
10 #include <QHeaderView>
11 #include "exportdecl.h"
23 void setHeaderSectionResizeMode(
int column, QHeaderView::ResizeMode mode);
24 void setVerticalGridLineShown(
bool on);
26 SignalProxy<void(QTreeWidgetItem* current, QTreeWidgetItem* previous)> sigCurrentItemChanged();
27 SignalProxy<void(QTreeWidgetItem* item,
int column)> sigItemActivated();
28 SignalProxy<void(QTreeWidgetItem* item,
int column)> sigItemChanged();
29 SignalProxy<void(QTreeWidgetItem* item,
int column)> sigItemClicked();
30 SignalProxy<void(QTreeWidgetItem* item)> sigItemCollapsed();
31 SignalProxy<void(QTreeWidgetItem* item,
int column)> sigItemDoubleClicked();
32 SignalProxy<void(QTreeWidgetItem* item,
int column)> sigItemEntered();
33 SignalProxy<void(QTreeWidgetItem* item)> sigItemExpanded();
34 SignalProxy<void(QTreeWidgetItem* item,
int column)> sigItemPressed();
38 SignalProxy<void(
const QModelIndex &parent,
int first,
int last)> sigRowsAboutToBeRemoved();
39 SignalProxy<void(
const QModelIndex &parent,
int first,
int last)> sigRowsRemoved();
40 SignalProxy<void(
const QModelIndex &parent,
int first,
int last)> sigRowsInserted();
43 SignalProxy<void(
int logicalIndex,
int oldSize,
int newSize)> sigSectionResized();
46 virtual void paintEvent(QPaintEvent* event);
47 virtual void scrollContentsBy(
int dx,
int dy);
50 void onCurrentItemChanged(QTreeWidgetItem* current, QTreeWidgetItem* previous);
51 void onItemActivated(QTreeWidgetItem* item,
int column);
52 void onItemChanged(QTreeWidgetItem* item,
int column);
53 void onItemClicked(QTreeWidgetItem* item,
int column);
54 void onItemCollapsed(QTreeWidgetItem* item);
55 void onItemDoubleClicked(QTreeWidgetItem* item,
int column);
56 void onItemEntered(QTreeWidgetItem* item,
int column);
57 void onItemExpanded(QTreeWidgetItem* item);
58 void onItemPressed(QTreeWidgetItem* item,
int column);
59 void onItemSelectionChanged(
void);
60 void onRowsAboutToBeRemoved(
const QModelIndex &parent,
int first,
int last);
61 void onRowsRemoved(
const QModelIndex &parent,
int first,
int last);
62 void onRowsInserted(
const QModelIndex &parent,
int first,
int last);
63 void onSectionResized(
int logicalIndex,
int oldSize,
int newSize);