On 01/04/13 19:47, eryksun wrote:
On Sun, Mar 31, 2013 at 8:13 PM, Phil wrote:
I have the answer (provided by a member of another list) and I was correct,
it was something basic.
from PyQt4 import QtGui
QtGui.QTable etc
Sorry, I assumed you were familiar with the package layout.
http://pyq
On Sun, Mar 31, 2013 at 8:13 PM, Phil wrote:
>
> I have the answer (provided by a member of another list) and I was correct,
> it was something basic.
>
> from PyQt4 import QtGui
> QtGui.QTable etc
Sorry, I assumed you were familiar with the package layout.
http://pyqt.sourceforge.net/Docs/PyQt4
On 31/03/13 21:43, eryksun wrote:
You can use setHorizontalHeaderItem(0, QTableWidgetItem('col 0'), and
so on. It may be simpler to use setHorizontalHeaderLabels(['col 0',
'col 1', 'etc']).
I have the answer (provided by a member of another list) and I was
correct, it was something basic.
On 31/03/13 21:43, eryksun wrote:
You can use setHorizontalHeaderItem(0, QTableWidgetItem('col 0'), and
so on. It may be simpler to use setHorizontalHeaderLabels(['col 0',
'col 1', 'etc']).
Thanks Eryksun,
I had already tried your suggestion last night and this is the result;
"global name
On Sun, Mar 31, 2013 at 4:23 AM, Alan Gauld wrote:
> On 31/03/13 08:30, Phil wrote:
>
>> self.tableWidget.setHorizontalHeaderItem (1, QTableWidgetItem *item)
>>
>> I have done this many years ago in C++ but I don't quite see how to get
>> a QTableWidgetItem in Python.
>
> Presumably by instantiati
On 31/03/13 08:30, Phil wrote:
self.tableWidget.setHorizontalHeaderItem (1, QTableWidgetItem *item)
I have done this many years ago in C++ but I don't quite see how to get
a QTableWidgetItem in Python.
Presumably by instantiating a TableWidgetItem class?
But you will likely get better help o
On 31/03/13 14:29, Phil wrote:
Thank you for reading this.
I want to set a table widget header based on its cell contents.
The following sets all of the headers;
self.tableWidget.setHorizontalHeaderLabels(["One", "Two", "Etc"])
However, self.setHorizontalHeaderItem ( 1, ["test"]) and
self.set
Thank you for reading this.
I want to set a table widget header based on its cell contents.
The following sets all of the headers;
self.tableWidget.setHorizontalHeaderLabels(["One", "Two", "Etc"])
However, self.setHorizontalHeaderItem ( 1, ["test"]) and
self.setHorizontalHeaderItem ( 1, "test