flame icon indicating copy to clipboard operation
flame copied to clipboard

feat: adding ClipComponent

Open erickzanardo opened this issue 3 years ago • 4 comments

Description

Adds a new component called ClipComponent that clips the canvas area based on its size and shape.

Checklist

  • [x] The title of my PR starts with a Conventional Commit prefix (fix:, feat:, docs: etc).
  • [x] I have read the Contributor Guide and followed the process outlined for submitting PRs.
  • [x] I have updated/added tests for ALL new/updated/fixed functionality.
  • [x] I have updated/added relevant documentation in docs and added dartdoc comments with ///.
  • [x] I have updated/added relevant examples in examples.

Breaking Change

  • [ ] Yes, this is a breaking change.
  • [x] No, this is not a breaking change.

Related Issues

erickzanardo avatar Jul 01 '22 16:07 erickzanardo

Related issue: #1274

st-pasha avatar Jul 01 '22 16:07 st-pasha

@alestiago @st-pasha @renancaraujo @spydon here is what I am going to do. I will keep the rect, circle and polygon constructors as they are a nice and friendlier API than to just receive a Shape.

I will refactor so this uses a shape internally too, so I can easily implement the containsPoint method.

I will not include a constructor that receive a Shape yet though, since that class is on the experimental package. But since it will be used internally, it will be super simple to add that constructor once it gets out of the experimental state.

erickzanardo avatar Jul 22 '22 12:07 erickzanardo

it will be super simple to add that constructor once it gets out of the experimental state.

I guess we never actually discussed about when to move things out of experimental. Should it be after some future release? After a certain features that are currently lacking are implemented? Any other trigger?

st-pasha avatar Jul 22 '22 17:07 st-pasha

I guess we never actually discussed about when to move things out of experimental. Should it be after some future release? After a certain features that are currently lacking are implemented? Any other trigger?

I think it can vary depending on the complexity of the feature. But we should definitely discuss on some guidelines, maybe it is worth to open a discussion or an issue so we can discuss that.

erickzanardo avatar Jul 22 '22 17:07 erickzanardo