feat(pie_chart): Add individual border control for pie chart sections#2053
Open
MatthiasMRC wants to merge 3 commits intoimaNNeo:mainfrom
Open
feat(pie_chart): Add individual border control for pie chart sections#2053MatthiasMRC wants to merge 3 commits intoimaNNeo:mainfrom
MatthiasMRC wants to merge 3 commits intoimaNNeo:mainfrom
Conversation
Add PieChartSectionBorder class to allow controlling each border side independently (outer arc, inner arc, left radial, right radial). This solves the issue where adjacent sections have doubled borders when using a single borderSide for all edges. New features: - PieChartSectionBorder class with outer, inner, left, right properties - PieChartSectionBorder.all() - same border on all sides - PieChartSectionBorder.arcsOnly() - borders only on arcs (no radial lines) - PieChartSectionBorder.outerOnly() - border only on outer arc The existing borderSide parameter is deprecated but still supported for backwards compatibility.
Add PieChartSectionBorder class to allow controlling each border side independently (outer arc, inner arc, left radial, right radial). This solves the issue where adjacent sections have doubled borders when using a single borderSide for all edges. New constructors: - PieChartSectionBorder.all() - same border on all sides - PieChartSectionBorder.arcsOnly() - borders only on arcs - PieChartSectionBorder.outerOnly() - border only on outer arc - PieChartSectionBorder.smart() - outer + inner + right (avoids doubled borders) The existing borderSide parameter is deprecated but still supported for backwards compatibility.
Add PieChartSectionBorder class to allow controlling each border side independently (outer arc, inner arc, left radial, right radial). New constructors: - PieChartSectionBorder.all() - same border on all sides - PieChartSectionBorder.arcsOnly() - borders only on arcs - PieChartSectionBorder.outerOnly() - border only on outer arc The existing borderSide parameter is deprecated but still supported for backwards compatibility. Added unit tests for PieChartSectionBorder and drawSectionIndividualBorders.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
PieChartSectionBorderclass to allow controlling each border side independently on pie chart sectionsouter(outer arc),inner(inner arc),left(left radial),right(right radial).all(),.arcsOnly(),.outerOnly()borderSideparameter (still works for backwards compatibility)Fixes #2052
Problem
When pie chart sections are adjacent, borders appear doubled/thicker because
borderSideapplies the same border to all sides.Changes
PieChartSectionBorderclass with individual border propertiesdrawSectionIndividualBordersmethod inPieChartPainterPieChartSectionDatawith newborderparameterUsage
Test plan