Questions tagged [qtreewidgetitem]

The QTreeWidgetItem class, part of the Qt framework, provides an item for use with the QTreeWidget class.

Documentation can be found here (Qt4) and here (Qt5).

219 questions
0
votes
1 answer

QTreeWidget Expanding individual Items from memory in C++

I have a Qt QTreeWidget and I am trying to save the state of which header items were expanded so that when I refresh my tree with new information it can re expand the items that were previously expanded. Each time an itemExpanded or itemCollapsed…
silverzx
  • 1,209
  • 4
  • 14
  • 18
0
votes
2 answers

QTreeWidget insertTopLevelItem - index given not accurately displayed in Tree?

I am unable to properly insert a QTreeWidgetItem at a specific index, in this case I am removing all QTreeWidgetItems from the tree, doing a custom sort on their Date Objects and then inserting them back into the QTreeWidget. However, upon…
crackerbunny
  • 139
  • 4
  • 12
0
votes
2 answers

How to make a subchild to a child in QTreeWidget?

I want to make it so that I can expand a third level (subchild) to a child under the top level item (root). All I've been able to do is make multiple children to a single root. this is in my .cpp QStringList string1, string2; …
EricaAKrause
  • 11
  • 1
  • 2
0
votes
1 answer

Multiple file insert in QTreewidget using Drag and Drop events

I am working in Qt4.7 on MAC OSx. I want to insert files in QTreewidget using the Drag and Drop events. I want to add multiple files at a time. I am using this: void MainWindow::dragEnterEvent(QDragEnterEvent * e) { …
Ashish
  • 219
  • 2
  • 6
  • 22
0
votes
1 answer

get qtreewidgetitemiterator values

I am able to display data in a qtreewidget form. While reading values ( and after googling ), I find qTreeWidgetItemIterator as a way to iterate through all the items. iterator = QTreeWidgetItemIterator(self.light_write, QTreeWidgetItemIterator.All)…
0
votes
1 answer

multiple setting qtreewidgetiitem checksatate not working

i have a qtreewidget with checkable items, i want to change state to be checked or not base on some value, first time i create toplevelitems i set item to be unchecked and it works, but after that when i want to checked it inside code it get checked…
mari
  • 417
  • 1
  • 6
  • 21
0
votes
2 answers

QTreewidget only displays first letter of item name

Im learning how to use QTreeWidget and Im stuck adding new items to it. The QTreewidget itself is created with qtdesigner, so my idea was just to add items. eg: tw = self.ui.treeWidget item =…
Hubschr
  • 1,285
  • 6
  • 18
  • 35
0
votes
0 answers

QTreewidget scrolling gets slowdown in case of multiple files

I am using QTreewidget in my application. I am filling this QTreewidget on runtime with some files addresses. Now my problem is when there are excess number of files(more than 200) the scrolling gets slow down in the QTreewidget which creates…
Ashish
  • 219
  • 2
  • 6
  • 22
0
votes
2 answers

Creating GUI with PySide

I have some Python command line tools ready. So now I am trying to create a GUI so that with one click, I can execute the tool. I am trying out Pyside and creating a QTreewidget at the moment. I am inputting the items one by one on QT designer.…
dorothy
  • 1,213
  • 5
  • 20
  • 35
0
votes
1 answer

Qt QTreeWidget how to get the row a QComboBox is on

I have a QTreeWidget with several QComboBoxes as QTreeWidgetItems. I am trying to find a way to get the current QTreeWidget row of the selected QComboBox. ui->sensorTree is the QTreeWidget. My tree looks something like this: parent0 child0 …
Jared Price
  • 5,217
  • 7
  • 44
  • 74
0
votes
1 answer

Retrieve QTreeWidgetItem object at drop event Pyside

I'm writing a program where I need data from the QTreeWidgetItem that has been dropped into another part of my QTreeWidget. The drag and drop is working perfectly, and I am able to get a QEvent.Drop type event in my eventFilter. But I cant get the…
Yvo Götz
  • 15
  • 1
  • 3
0
votes
1 answer

How to prepend a child item in qtreewidgetitem?

I want to keep the latest child nodes always to in the top level items in qtreewidget, how is this possible ? Normally QTreeWidgetItem::addChild() append the child item, so I tried QTreeWidgetItem::insertChild(0, childItem) but this doesnt helped…
Prady
  • 663
  • 3
  • 11
  • 28
0
votes
1 answer

how to delete checked items from QTreeWidget?

I have list of QTreeWidget items with check boxes, which are child items with few top level items. I want to delete the items which are in checked state, how can I iterate the qtreewidget and delete those items ?
Prady
  • 663
  • 3
  • 11
  • 28
0
votes
0 answers

Why there is no find item to get a unique item in QTreeWidget?

I have unique QTreeWidgetItems in QTreeWidget, I am using findItems() to find a specific item, it returns list of items. From this list taking the first item and storing in QTreeWidgetItem. but i wonder is there any method to find an item which…
Prady
  • 663
  • 3
  • 11
  • 28
0
votes
1 answer

Single QTreeWidgetItem instance on multiple QTreeWidget?

I'm trying to show a single QTreeWidgetItem instance on 2 QTreeWidgets, which ends up the item shown only on the 1st tree without being notified. I haven't seen its API doc talks about a limitation if any. Is there a way to…
IsaacS
  • 3,551
  • 6
  • 39
  • 61
1 2 3
14
15