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 FlDotLineSegmentPainter for Enhanced Chart Customization #1544

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

JaredEzz
Copy link

@JaredEzz JaredEzz commented Jan 9, 2024

This pull request introduces a new FlDotLineSegmentPainter to the fl_chart library, expanding the customization options available for dot decorations in line charts. The FlDotLineSegmentPainter is designed to draw a vertical line segment at each data point, with an optional numerical value label displayed above.

Key features and benefits of the FlDotLineSegmentPainter include:

  • Customizable Line Segments: Users can specify the color, width, and height of the line segments, allowing for precise control over their appearance.
  • Value Labels: Each line segment can be accompanied by a label showing its numerical value, enhancing the informativeness of the chart.
  • Optional Labels: The showText parameter enables users to toggle the display of value labels, providing flexibility for minimalistic designs or when labels are not necessary.
  • Consistent Style: The painter follows the established coding and commenting conventions of the library, ensuring a seamless integration.

The addition of this painter is particularly helpful for users who require a clear visual distinction between data points, or for those who wish to emphasize the exact value of each point without cluttering the chart with markers.

Example picture:
image

@imaNNeo
Copy link
Owner

imaNNeo commented Jan 10, 2024

Oh, it seems a very cool feature!
Actually I think we need to have a catalog of the DotPainters someday somewhere.

Thanks a lot.

Copy link

codecov bot commented Jan 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 86.78%. Comparing base (930ac12) to head (e736269).
Report is 14 commits behind head on main.

❗ Current head e736269 differs from pull request most recent head 5c33e55. Consider uploading reports for the commit 5c33e55 to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1544      +/-   ##
==========================================
- Coverage   87.52%   86.78%   -0.75%     
==========================================
  Files          45       45              
  Lines        3078     3034      -44     
==========================================
- Hits         2694     2633      -61     
- Misses        384      401      +17     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@imaNNeo
Copy link
Owner

imaNNeo commented Jan 10, 2024

Oh, it seems there is a formatting issue,
Don't forget to read the contributing guidelines carefully.

# Conflicts:
#	lib/src/chart/base/axis_chart/axis_chart_data.dart
@JaredEzz
Copy link
Author

Totally my bad! I'm used to Github Actions steps that clean up the formatting for me. Forgive the negligence. All cleaned up now

@imaNNeo
Copy link
Owner

imaNNeo commented Jan 22, 2024

Can you please rebase your branch?
There are some conflicts

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.

2 participants