commit 586f592af1207b48fd0c7e66d0d26e381b81cb3d
parent 270c60b3c8b26f9767446e52c053d4c3e1d61c64
Author: ThomasV <thomasv@gitorious>
Date: Tue, 11 Nov 2014 16:03:06 +0100
invoices: change column order
Diffstat:
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/gui/qt/main_window.py b/gui/qt/main_window.py
@@ -1354,14 +1354,14 @@ class ElectrumWindow(QMainWindow):
def create_invoices_tab(self):
- l, w = self.create_list_tab([_('Status'), _('Date'), _('Requestor'), _('Memo'), _('Amount')])
- l.setColumnWidth(0, 60)
+ l, w = self.create_list_tab([_('Date'), _('Requestor'), _('Memo'), _('Amount'), _('Status')])
+ l.setColumnWidth(0, 150)
l.setColumnWidth(1, 150)
- l.setColumnWidth(2, 150)
- l.setColumnWidth(4, 150)
+ l.setColumnWidth(3, 150)
+ l.setColumnWidth(4, 40)
h = l.header()
h.setStretchLastSection(False)
- h.setResizeMode(3, QHeaderView.Stretch)
+ h.setResizeMode(2, QHeaderView.Stretch)
l.setContextMenuPolicy(Qt.CustomContextMenu)
l.customContextMenuRequested.connect(self.create_invoice_menu)
self.invoices_list = l
@@ -1376,13 +1376,13 @@ class ElectrumWindow(QMainWindow):
if status == PR_UNPAID and expiration_date and expiration_date < time.time():
status = PR_EXPIRED
date_str = datetime.datetime.fromtimestamp(expiration_date).isoformat(' ')[:-3]
- item = QTreeWidgetItem( [ '', date_str, domain, memo, self.format_amount(amount, whitespaces=True)] )
+ item = QTreeWidgetItem( [ date_str, domain, memo, self.format_amount(amount, whitespaces=True), ''] )
icon = QIcon(pr_icons.get(status))
- item.setIcon(0, icon)
- item.setToolTip(0, pr_tooltips.get(status,''))
+ item.setIcon(4, icon)
+ item.setToolTip(4, pr_tooltips.get(status,''))
item.setData(0, 32, key)
+ item.setFont(1, QFont(MONOSPACE_FONT))
item.setFont(2, QFont(MONOSPACE_FONT))
- item.setFont(3, QFont(MONOSPACE_FONT))
l.addTopLevelItem(item)
l.setCurrentItem(l.topLevelItem(0))