From a0c03a8b6bdd11720ce060730e86c601d828a863 Mon Sep 17 00:00:00 2001 From: Tyler Goodlet Date: Mon, 30 Aug 2021 17:45:10 -0400 Subject: [PATCH] Format pnl label with % type --- piker/ui/_forms.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/piker/ui/_forms.py b/piker/ui/_forms.py index c0dbd29f..6d19cdc4 100644 --- a/piker/ui/_forms.py +++ b/piker/ui/_forms.py @@ -377,8 +377,7 @@ def mk_form( # TODO: generate components from model # instead of schema dict (aka use an ORM) form = FieldsForm(parent=parent) - - form._font_size = font_size or _font.px_size + form._font_size = font_size or _font_small.px_size # generate sub-components from schema dict for key, config in fields_schema.items(): @@ -550,7 +549,7 @@ def mk_fill_status_bar( bar_labels_lhs = QVBoxLayout(fields) left_label = fields.add_field_label( dedent(""" - {pnl}% pnl + {pnl:>+.2%} pnl """), font_size=bar_label_font_size, font_color='gunmetal',