PyQtForSoftimage icon indicating copy to clipboard operation
PyQtForSoftimage copied to clipboard

typing in an 'editable' combobox seems to be passed on to Softimage shortcuts

Open lichtwerk opened this issue 12 years ago • 2 comments

when you have an "editable" QComboBox and start typing, the events/letters seem to be passed on to Softimage. This results in keyboard shortcuts being performed in Softimage instead of text being written in the QComboBox...

==== code to reproduce (just run from the script editor) =========== from PyQt4 import QtGui, QtCore import sip si = Application sianchor = sip.wrapinstance(long(si.getQtSoftimageAnchor()), QtGui.QWidget)

dialog = QtGui.QMainWindow(sianchor) uiComboBox = QtGui.QComboBox(parent=dialog) uiComboBox.setFocusPolicy(QtCore.Qt.StrongFocus) uiComboBox.setEditable(True) dialog.show() ==== code to reproduce (just run from the script editor) ===========

Greetz Philipp

P.S.: still using PyQtForSoftimage_beta5.xsiaddon from 05/02/2013

lichtwerk avatar May 06 '13 11:05 lichtwerk

just forwarding Simon Anderson's findings from the softimage mailinglist here: = = ==============================================================

just did a test and it seems that if you have a blank combo box it doesn't work, but when there are a few items in it, it seems to work correctly once the combo box has been selected. using the standard released build.

My thought is that if you don't delegate a string item it doesn't know what is meant to be in the QCombox, that is why keyboard input doesn't work.

from PyQt4 import QtGui, QtCore import sip si = Application sianchor = sip.wrapinstance(long(si.getQtSoftimageAnchor()), QtGui.QWidget)

dialog = QtGui.QMainWindow(sianchor) uiComboBox = QtGui.QComboBox(parent=dialog) uiComboBox.setFocusPolicy(QtCore.Qt.StrongFocus) uiComboBox.setEditable(True) uiComboBox.addItem("test") uiComboBox.addItem("zzz") dialog.show()

lichtwerk avatar May 06 '13 14:05 lichtwerk

a few items? is there a specific number?

can we reproduce with standalone pyqt?

caron avatar May 07 '13 02:05 caron