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

Add LinearGauge indicator #3222

Merged
merged 6 commits into from
Apr 13, 2022
Merged

Add LinearGauge indicator #3222

merged 6 commits into from
Apr 13, 2022

Conversation

philippjfr
Copy link
Member

@philippjfr philippjfr commented Mar 3, 2022

A LinearGauge provides a much more compact value indicator than Dial or Gauge.

Screen Shot 2022-04-13 at 15 53 15

Screen Shot 2022-04-13 at 15 53 00

  • Add tests
  • Make colors handling consistent with Gauge and Dial
  • Improve horizontal support

@jbednar
Copy link
Member

jbednar commented Mar 4, 2022

That's useful, but I'd think that in a bank of them the current value of it won't stand out much, while I'd want higher values to be very visible in many cases. The usual way that's done is to dim the alpha of the background for the areas above the current value, potentially to zero.

In general since there is really only one value being displayed, one will often want this to be very small, so it would be good if the defaults weren't assuming this needs font and tick sizes like a curve or scatterplot...

Also, the colors here seem backward if that's a failure rate. :-)

@philippjfr
Copy link
Member Author

Agree with everything you said. Total work in progress for now.

@philippjfr philippjfr changed the title WIP: Add LinearGauge indicator Add LinearGauge indicator Apr 13, 2022
@codecov
Copy link

codecov bot commented Apr 13, 2022

Codecov Report

Merging #3222 (c9feea1) into master (2fbd79b) will decrease coverage by 0.38%.
The diff coverage is 22.22%.

@@            Coverage Diff             @@
##           master    #3222      +/-   ##
==========================================
- Coverage   83.34%   82.96%   -0.39%     
==========================================
  Files         198      198              
  Lines       26791    26970     +179     
==========================================
+ Hits        22329    22375      +46     
- Misses       4462     4595     +133     
Impacted Files Coverage Δ
panel/tests/widgets/test_base.py 100.00% <ø> (ø)
panel/widgets/__init__.py 100.00% <ø> (ø)
panel/widgets/indicators.py 72.74% <22.22%> (-19.75%) ⬇️
panel/layout/accordion.py 89.79% <0.00%> (-0.74%) ⬇️
panel/pane/idom.py 27.20% <0.00%> (ø)
panel/pane/plot.py 58.37% <0.00%> (ø)
panel/pane/vega.py 83.04% <0.00%> (ø)
panel/pane/alert.py 100.00% <0.00%> (ø)
panel/pane/image.py 80.09% <0.00%> (ø)
panel/pane/media.py 97.72% <0.00%> (ø)
... and 12 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2fbd79b...c9feea1. Read the comment docs.

@philippjfr philippjfr merged commit fb66068 into master Apr 13, 2022
@philippjfr philippjfr deleted the linear_gauge branch April 13, 2022 20:54
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.

None yet

2 participants