pyqt

PyQT and PyCairo

I know it's possible to place a PyCairo surface inside a Gtk Drawing Area. But I think Qt is a lot better to work with, so I've been wondering if there's anyway to place a PyCairo surface inside some Qt component? ...

PyQt - QScrollBar

Dear Stacktoverflow, can you show me an example of how to use a QScrollBar? Thanks. ...

Efficient Image Thumbnail Control for Python?

What is the best choice for a Python GUI application to display large number of thumbnails, e.g. 10000 or more? For performance reasons such thumbnail control must support virtual items, i.e. request application for those thumbnails only which are currently visible to user. ...

PyQt: getting widgets to resize automatically in a QDialog

I'm having difficulty getting widgets in a QDialog resized automatically when the dialog itself is resized. In the following program, the textarea resizes automatically if you resize the main window. However, the textarea within the dialog stays the same size when the dialog is resized. Is there any way of making the textarea in the d...

How to do pretty OSD in Python

Is there a library to do pretty on screen display with Python (mainly on Linux but preferably available on other OS too) ? I know there is python-osd but it uses libxosd which looks quite old. I would not call it pretty. Maybe a Python binding for libaosd. But I did not find any. ...

Qt: Erase background (Windows Aero Glass)

Update see Using Blur Behind on Windows for an example of using Qt and DWM. Original question: I want to create a Windows Aero Glass window with Qt, now it looks like this: But after calling some my_window->repaint() my window's label becomes broken: But now if I resize the window slightly, it repaints properly. The question ...

How can I hide the python.exe window in a pyqt app when running on Windows?

Surely this is possible? I have been hunting through pyqt tutorials and documentation but cannt find the answer to it. Probably I just need to phrase my search query differently. [Edit] Thanks PEZ for the answer - more details including use of the .pyw extension in Python Programming on Win32 chapter 20 ...

What ide is good for developing PyQt apps?

What ide is good for developing PyQt apps? ...

pyqt import problem

Hi, I am having some trouble doing this in Python: from PyQt4 import QtCore, QtGui from dcopext import DCOPClient, DCOPApp The traceback I get is from dcopext import DCOPClient, DCOPApp File "/usr/lib/python2.5/site-packages/dcopext.py", line 35, in <module> from dcop import DCOPClient RuntimeError: the qt and PyQt4.QtCore module...

How can I tell a QTableWidget to end editing a cell?

I'm showing a popup menu to select some values in a QTableWidget. The lowest item is a "Modify list" entry, when I select it a new window should automatically appear and the QComboBox should vanish and the cell return to a Qt::DisplayRole state. Now Qt has all those nice API-calls like QTableWidget.edit() and QTableWidget.editItem(), wh...

How to keep track of thread progress in Python without freezing the PyQt GUI?

Questions: What is the best practice for keeping track of a tread's progress without locking the GUI ("Not Responding")? Generally, what are the best practices for threading as it applies to GUI development? Question Background: I have a PyQt GUI for Windows. It is used to process sets of HTML documents. It takes anywhere from t...

How can I get rid of the resize-handle in a QDialog?

I've got the following class: class SelectDateDialog(QDialog): startDate = date.today() endDate = date.today() def __init__(self, text, isInterval = False): QDialog.__init__(self) uic.loadUi("resources/SelectDate.ui", self) Now, the dialog is resizable on Mac OS X 10.5, but it shouldn't be. It has the resi...

PyQt: No such slot

I am starting to learn Qt4 and Python, following along some tutorial i found on the interwebs. I have the following two files: lcdrange.py: from PyQt4 import QtGui, QtCore class LCDRange(QtGui.QWidget): def __init__(self, parent=None): QtGui.QWidget.__init__(self, parent) lcd = QtGui.QLCDNu...

Hiding row labels

I'm using Qt4 to create a table, using the QTableWidget class. I get something like this: Problem is: I want to hide the row labels (i.e. the numbers). I just care about columns. I want to get this: How can I accomplish this? ...

How to build PyQT project?

I have a simple PyQT project. I would like to know how to build it in Windows in such way, that it becomes runnable executable. I don't want to require user to install heavy QT framework for his computer. How to make executable with only necessary parts of QT? ...

Using PyQT, how do you filter mousePressEvent for a QComboBox with custom list

I've got a QComboBox with a custom list object. Please see Screen shot The custom list object has a custom mousePressEvent so that when the user click on one of the circles with a +/- (a twisty), the list is expanded/collapsed. When I use the list with the combo box, when the user clicks on a twisty, the list is expanded/collapsed, ...

wx's idle and UI update events in PyQt

wx (and wxPython) has two events I miss in PyQt: EVT_IDLE that's being sent to a frame. It can be used to update the various widgets according to the application's state EVT_UPDATE_UI that's being sent to a widget when it has to be repainted and updated, so I can compute its state in the handler Now, PyQt doesn't seem to have these,...

problems installing pyqt in macOs

HI, I´m trying to install pyqt in macos. I read on Internet that i need: sip + pyqt + qt (obviously) I had no problem installing qt & sip. When I try to install pyqt I can see the following error at the terminal: python configure.py Error: A Qt installation could not be found. Use the -q argument or the QTDIR environment variab...

QSortFilterProxyModel.mapToSource crashes. No info why.

I have the following code: proxy_index = self.log_list.filter_proxy_model.createIndex(index, COL_REV) model_index = self.log_list.filter_proxy_model.mapToSource(proxy_index) revno = self.log_list.model.data(model_index,QtCore.Qt.DisplayRole) self.setEditText(revno.toString()) The code crashed on the second line. There is no exception ...

PyQt4 and QtWebKit - how to auto scroll the view?

I got a QtWebKit.QWebView widget in a PyQt application window that I use to display text and stuff for a chat-like application. self.mainWindow = QtWebKit.QWebView() self.mainWindow.setHtml(self._html) As the conversation gets longer the vertical scrollbar appears. What I'd like to get, is to scroll the displayed view to the...