fix: make recurring tab buttons readable and properly sized in table
Reduced vertical padding for buttons inside tables and set fixed column widths so Confirm/Dismiss buttons fit cleanly within their cells. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -57,9 +57,12 @@ class RecurringView(QWidget):
|
||||
"Annual Cost", "Last Date", "Status",
|
||||
"", "",
|
||||
])
|
||||
self.table.horizontalHeader().setSectionResizeMode(
|
||||
0, QHeaderView.ResizeMode.Stretch,
|
||||
)
|
||||
header = self.table.horizontalHeader()
|
||||
header.setSectionResizeMode(0, QHeaderView.ResizeMode.Stretch)
|
||||
header.setSectionResizeMode(6, QHeaderView.ResizeMode.Fixed)
|
||||
header.setSectionResizeMode(7, QHeaderView.ResizeMode.Fixed)
|
||||
self.table.setColumnWidth(6, 100)
|
||||
self.table.setColumnWidth(7, 100)
|
||||
self.table.setEditTriggers(QAbstractItemView.EditTrigger.NoEditTriggers)
|
||||
self.table.setSelectionBehavior(QAbstractItemView.SelectionBehavior.SelectRows)
|
||||
self.table.verticalHeader().setVisible(False)
|
||||
|
||||
@@ -81,6 +81,21 @@ QPushButton:disabled {
|
||||
color: #6c7086;
|
||||
}
|
||||
|
||||
/* ---------- QPushButton inside tables ---------- */
|
||||
QTableView QPushButton, QTableWidget QPushButton {
|
||||
background-color: #89b4fa;
|
||||
color: #1e1e2e;
|
||||
padding: 2px 12px;
|
||||
}
|
||||
|
||||
QTableView QPushButton:hover, QTableWidget QPushButton:hover {
|
||||
background-color: #74a8fc;
|
||||
}
|
||||
|
||||
QTableView QPushButton:pressed, QTableWidget QPushButton:pressed {
|
||||
background-color: #5b96f7;
|
||||
}
|
||||
|
||||
/* ---------- QTableView / QTableWidget ---------- */
|
||||
QTableView, QTableWidget {
|
||||
background-color: #2a2a3c;
|
||||
|
||||
@@ -81,6 +81,21 @@ QPushButton:disabled {
|
||||
color: #9ca0b0;
|
||||
}
|
||||
|
||||
/* ---------- QPushButton inside tables ---------- */
|
||||
QTableView QPushButton, QTableWidget QPushButton {
|
||||
background-color: #1e66f5;
|
||||
color: #ffffff;
|
||||
padding: 2px 12px;
|
||||
}
|
||||
|
||||
QTableView QPushButton:hover, QTableWidget QPushButton:hover {
|
||||
background-color: #1a5be0;
|
||||
}
|
||||
|
||||
QTableView QPushButton:pressed, QTableWidget QPushButton:pressed {
|
||||
background-color: #1650c8;
|
||||
}
|
||||
|
||||
/* ---------- QTableView / QTableWidget ---------- */
|
||||
QTableView, QTableWidget {
|
||||
background-color: #ffffff;
|
||||
|
||||
Reference in New Issue
Block a user