Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overview page: Grid widget: confusion when some phases in watts and others in kilowatts #1272

Conversation

DanielMcInnes
Copy link
Contributor

@DanielMcInnes DanielMcInnes commented Jun 24, 2024

'Small' AcWidgets no longer hide the total power, as there is enough space to show it.
'ExtraSmall' and 'Small' AcWidgets now display units for each phase, eg 'kW', 'W'.

@DanielMcInnes DanielMcInnes self-assigned this Jun 24, 2024
@DanielMcInnes DanielMcInnes marked this pull request as draft June 24, 2024 03:01
@DanielMcInnes DanielMcInnes force-pushed the 1264-overview-page-grid-widget-incorrect-scaling-when-some-phases-in-watts-and-others-in-kilowatts branch from 34cc1ea to 2b49d8c Compare June 24, 2024 03:14
@blammit
Copy link
Contributor

blammit commented Jun 24, 2024

Can you improve the commit's first line so it is less generic than "fix bug in X"? E.g. "Show per-unit phase in overview AC widget" or "Change display of units and total quantity in overview AC widget". Also add a reference to the issue number.

@DanielMcInnes DanielMcInnes force-pushed the 1264-overview-page-grid-widget-incorrect-scaling-when-some-phases-in-watts-and-others-in-kilowatts branch 2 times, most recently from dcb2530 to 9354f6f Compare June 24, 2024 04:43
@DanielMcInnes
Copy link
Contributor Author

Can you improve the commit's first line so it is less generic than "fix bug in X"? E.g. "Show per-unit phase in overview AC widget" or "Change display of units and total quantity in overview AC widget". Also add a reference to the issue number.

done

@DanielMcInnes DanielMcInnes force-pushed the 1264-overview-page-grid-widget-incorrect-scaling-when-some-phases-in-watts-and-others-in-kilowatts branch from 9354f6f to 74f22d0 Compare June 25, 2024 01:13
@DanielMcInnes DanielMcInnes changed the title Fix bug in AcWidget quantityLabel visibility Overview page: Grid widget: confusion when some phases in watts and others in kilowatts Jun 25, 2024
@DanielMcInnes
Copy link
Contributor Author

Serj commented:

Hi, thank you for sharing this. One problem i see is that text may become unreadable on target screen at that dimension (smallest we currently have is 12px) However changing from Museo to Roboto font gives us more vertical space, as Roboto is more condensed. In scenarios where we have multiple energy sources - 5 containers on the left, the totals for 3 phases wont fit, and there can be two sources with 3 phases and 5 blocks to show (super yacht scenario). I would say, if we can read it on GX target screen then do not mind to go with proposal you shared. Taking in consideration all corner cases.

@DanielMcInnes
Copy link
Contributor Author

I can't test on the device with 5 widgets on the left, but on the desktop, a 5" display looks ok:
image

@DanielMcInnes DanielMcInnes marked this pull request as ready for review June 25, 2024 01:19
Copy link
Contributor

@blammit blammit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, minor comment about clean-up.

@@ -75,7 +75,6 @@ Flow {
: 0
dataObject: model
font.pixelSize: phaseLabel.font.pixelSize
unitVisible: root.widgetSize >= VenusOS.OverviewWidget_Size_M
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you remove unitVisible from QuantityLabel? With this change, it will no longer be used.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Small AC widgets now display total power.
Fixes #1264
@DanielMcInnes DanielMcInnes force-pushed the 1264-overview-page-grid-widget-incorrect-scaling-when-some-phases-in-watts-and-others-in-kilowatts branch from 74f22d0 to 38a87d6 Compare June 26, 2024 07:31
@DanielMcInnes DanielMcInnes merged commit c1dbec6 into main Jun 26, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Overview page: Grid widget: confusion when some phases in watts and others in kilowatts
3 participants