qlistwidget Questions

6

Solved

I have a regular QListWidget with couple of signals and slots hookedup. Everything works as I expect. I can update, retrieve, clear etc. But the UI wont support multiple selections. How do I 'ena...
Mesh asked 24/10, 2010 at 14:25

3

Solved

I am adding two items to a listwidget using the code below. Now I want to set "Weekend Plus" as selected item in the listwidget, how do I do that? QStringList items; items << "All" <<...
Sherd asked 6/6, 2011 at 8:57

3

Solved

We're looking for a way to increase the padding (or margins) for a QListWidget we are using in our application. We'd like to increase this for all four directions to give the text in our list some ...
Ledge asked 21/3, 2018 at 14:55

2

Solved

In a QListWidget I have a set of entries. Now I want to allow the user to sort (reorder) these entries through two buttons (Up/Down). Here's part of my code: def __init__(self): QtGui.QMainWindo...
Oud asked 9/6, 2012 at 0:14

3

Solved

I apology if it has been already asked but would you please clarify it again: how to get all ListWidgetItems listed in QListWidget? Poster later: Here it's in action. There are 5 items in a list...
Franny asked 22/3, 2014 at 0:12

2

Solved

I dynamically add and remove items to a QListWidget based on user selections elsewhere in the application. Is there a signal that is emitted when items are added or removed to a QListWidget? The si...
Tugboat asked 16/3, 2015 at 15:15

4

I want to show only icons in my QListWidget. I set text to empty string. When I select an icon I see an empty selected square on the text place. See the screenshot: How can I get rid of this empty...
Spotless asked 5/11, 2011 at 23:7

2

Solved

I can't find any way to put a line between items in my list. Am I missing something?
Callable asked 15/10, 2011 at 20:24

2

Solved

I want to store some filenames in a QListWidget. I need to have the full file paths, but I only want to show the base filename. I probably could store the full filename in the tooltip for each item...
Wellbred asked 21/8, 2011 at 6:39

2

Solved

It's possible to select a single item/row, but I want to set multiple items selected (the widget is configured to allow that). Is it possible?
Banjo asked 10/1, 2013 at 21:4

2

Solved

In PyQt I can have QListWidget select an item programmatically using QListWidget.setCurrentItem(item). And this, of course, will select an item for me inside my QListWidget. However, I'm wondering...
Maje asked 6/3, 2018 at 21:46

3

Solved

There are two QListWIdgets sitting in a same dialog window. The DragDrop functionality has been enabled for both. If I drag and drop a file to any of two ListWidges the program recognizes it and pr...
Geochronology asked 20/3, 2014 at 19:50

6

Solved

Currently, I use the following while loop in a class that inherits QtGui.QListWidget to iterate all items: i = 0 while i < self.count(): item = self.item(i) i += 1 I was hoping I could u...
Untangle asked 7/1, 2011 at 19:45

4

Solved

I want to make a QListWidget with a resize handle at the bottom (similar to text fields you see on webpages like this one). I've seen a few people asking the same question out there but did not fin...
Milson asked 24/9, 2018 at 20:23

1

Solved

I am learning PySide and I was confused how to set the flag for a QListWidget item back to selectable after first setting it to unselectable. I know I can: QListWidget.SetFlags(QtCore.Qt.ItemIsSele...
Improvise asked 27/5, 2018 at 5:26

1

Solved

I'm using pyqt4 with python 2.7 and I have a list view widget that I can't add items to it # -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'add_category.ui' # # Crea...
Unbeliever asked 20/3, 2018 at 13:26

5

I'm writing a PyQt application and am having some trouble creating a custom list view. I'd like the list to contain arbitrary widgets (one custom widget in particular). How would I go about this? ...
Creech asked 4/6, 2009 at 3:24

2

Solved

How to remove selected items from a QListWidget? I have tried write the following code, but it does not work. QList<QListWidgetItem*> items = ui->listWidget->selectedItems(); foreach(QL...
Cobia asked 21/8, 2014 at 2:24

1

Solved

I am new to PyQt. I first made a dialog in Qt Designer, and implemented simple add, delete, up, down operations in a QListWidget. All my operations except edit worked a charm, so I did a lot of sea...
Antipas asked 24/12, 2017 at 17:48

2

Solved

In my form I have a QListWidget which contains checkable QListWidgetItems. I'm looking for a way to capture the event of a QListWidgetItem being checked/unchecked. I don't see any such signal exist...
Plafond asked 23/11, 2010 at 5:2

2

Solved

To remove a given QListWidgetItem* item from a QListWidget* lst I can use following code (taken from this answer): delete lst->takeItem(lst->row(item)); // method 1 On the other hand, if I...
Subchloride asked 27/6, 2017 at 14:43

1

Solved

while learning PyQt5 i found a little problem( maybe a bug) in the ListWidget Widget (and all other widgets) the ListWidget have a addItem method overloaded : ( the code is in c++ but this is the ...
Walkway asked 8/3, 2017 at 21:49

2

Solved

I'm using QListWidget with setItemWidget and when adding items to the list and scrolling down to the bottom I get this result: So there's an area which is completely blank at the bottom (not sel...
Forefront asked 24/1, 2017 at 11:50

1

Solved

The code below creates a single dialog window with QListWidget and QPushButton. Clicking the button fires up a scroll() function which finds and selects an "ITEM-0011". I wonder if there is a way...
Flying asked 7/1, 2017 at 4:56

1

Solved

I would like to color part of text in QListWidget I tried to include tag font int text but this does not work.
Biogen asked 12/12, 2016 at 18:28

© 2022 - 2024 — McMap. All rights reserved.