diff --git a/gui/platform_edit.ui b/gui/platform_edit.ui index e6d1f00..ce389b7 100644 --- a/gui/platform_edit.ui +++ b/gui/platform_edit.ui @@ -63,6 +63,11 @@ false + + + 11 + + QAbstractSpinBox::ButtonSymbols::NoButtons @@ -89,6 +94,11 @@ + + + 11 + + QAbstractSpinBox::ButtonSymbols::NoButtons @@ -105,6 +115,11 @@ + + + 11 + + Share dealing discount # of trades @@ -115,6 +130,11 @@ + + + 11 + + Share platform monthly fee cap @@ -122,6 +142,11 @@ + + + 11 + + QAbstractSpinBox::ButtonSymbols::NoButtons @@ -138,6 +163,11 @@ + + + 11 + + Share dealing fee* @@ -148,6 +178,11 @@ false + + + 11 + + QAbstractSpinBox::ButtonSymbols::NoButtons @@ -174,6 +209,11 @@ + + + 11 + + Fund dealing fee* @@ -183,10 +223,21 @@ - + + + + 11 + + + + + + 11 + + Share dealing discount amount @@ -194,6 +245,11 @@ + + + 11 + + Share platform fee* @@ -201,6 +257,11 @@ + + + 11 + + QAbstractSpinBox::ButtonSymbols::NoButtons @@ -217,6 +278,11 @@ + + + 11 + + Platform name @@ -227,6 +293,11 @@ false + + + 11 + + QAbstractSpinBox::ButtonSymbols::NoButtons @@ -255,6 +326,11 @@ 24 + + + 10 + + Save @@ -303,6 +379,11 @@ + + + 11 + + QAbstractSpinBox::ButtonSymbols::NoButtons @@ -319,6 +400,11 @@ + + + 11 + + on the first @@ -326,6 +412,11 @@ + + + 11 + + the fee is @@ -333,6 +424,11 @@ + + + 11 + + QAbstractSpinBox::ButtonSymbols::NoButtons @@ -358,6 +454,11 @@ 24 + + + 10 + + Add row @@ -371,6 +472,11 @@ 24 + + + 10 + + Remove row diff --git a/src/platform_edit.py b/src/platform_edit.py index 4f51d58..02001df 100644 --- a/src/platform_edit.py +++ b/src/platform_edit.py @@ -1,5 +1,5 @@ from PyQt6.QtCore import QRegularExpression -from PyQt6.QtGui import QRegularExpressionValidator +from PyQt6.QtGui import QRegularExpressionValidator, QFont from PyQt6.QtWidgets import QWidget, QLabel from PyQt6 import uic @@ -173,22 +173,27 @@ class PlatformEdit(QWidget): return -1 widgets = [] + font = QFont() + font.setPointSize(11) widgets.append(QLabel(self.gridLayoutWidget_2)) - widgets[0].setText(f"between {int(self.first_tier_box.value())} and") + widgets[0].setFont(font) widgets.append(FastEditQDoubleSpinBox(self.gridLayoutWidget_2)) widgets[1].setPrefix("£") widgets[1].setMaximum(9999999) widgets[1].setButtonSymbols(FastEditQDoubleSpinBox.ButtonSymbols.NoButtons) + widgets[1].setFont(font) widgets.append(QLabel(self.gridLayoutWidget_2)) widgets[2].setText(f"the fee is") + widgets[2].setFont(font) widgets.append(FastEditQDoubleSpinBox(self.gridLayoutWidget_2)) widgets[3].setSuffix("%") widgets[3].setMaximum(100) widgets[3].setButtonSymbols(FastEditQDoubleSpinBox.ButtonSymbols.NoButtons) + widgets[3].setFont(font) # TODO: why 28.5? self.gridLayoutWidget_2.setGeometry(11, 314, 611, int(round(28.5 * (self.fund_fee_rows + 1), 0))) @@ -206,7 +211,9 @@ class PlatformEdit(QWidget): prev_box_row = cur_box_pos[0] - 1 prev_box_item = self.gridLayout_2.itemAtPosition(prev_box_row, cur_box_pos[1]).widget() cur_label_item = self.gridLayout_2.itemAtPosition(cur_label_pos[0], cur_label_pos[1]).widget() - cur_label_item.setText(f"between {int(prev_box_item.value())} and") + cur_label_item.setText(f"between £{int(prev_box_item.value())} and") + + # TODO: Tab order def remove_row(self): if not self.fund_fee_rows > 1: