florent37 / florent37/ShapeOfView
java.lang.IllegalArgumentException: Invalid Region.Op - only INTERSECT and DIFFERENCE are allowed
- Dominant language
- Java
- Stars
- 3.2k
- Forks
- 400
- PR merge metrics
- No merged PRs in 30d
Description
on android pie there is a render problem that appears when i try to use
android:elevation.
java.lang.IllegalArgumentException: Invalid Region.Op - only INTERSECT and DIFFERENCE are allowed at android.graphics.Canvas.checkValidClipOp(Canvas.java:779) at android.graphics.Canvas.clipRect(Canvas.java:826) at android.view.ViewGroup_Delegate.drawShadow(ViewGroup_Delegate.java:86) at android.view.ViewGroup_Delegate.drawChild(ViewGroup_Delegate.java:58) at android.view.ViewGroup.drawChild(ViewGroup.java:4333) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4112) at androidx.constraintlayout.widget.ConstraintLayout.dispatchDraw(ConstraintLayout.java:2070) at android.view.View.draw_Original(View.java:20075) at android.view.View_Delegate.draw(View_Delegate.java:68) at android.view.View.draw(View.java:19849) at android.view.ViewGroup.drawChild_Original(ViewGroup.java:4333) at android.view.ViewGroup_Delegate.drawChild(ViewGroup_Delegate.java:63) at android.view.ViewGroup.drawChild(ViewGroup.java:4333) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4112) at android.view.View.draw_Original(View.java:20075) at android.view.View_Delegate.draw(View_Delegate.java:68) at android.view.View.draw(View.java:19849) at android.view.ViewGroup.drawChild_Original(ViewGroup.java:4333) at android.view.ViewGroup_Delegate.drawChild(ViewGroup_Delegate.java:63) at android.view.ViewGroup.drawChild(ViewGroup.java:4333) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4112) at android.view.View.draw_Original(View.java:20075) at android.view.View_Delegate.draw(View_Delegate.java:68) at android.view.View.draw(View.java:19849) at android.view.ViewGroup.drawChild_Original(ViewGroup.java:4333) at android.view.ViewGroup_Delegate.drawChild(ViewGroup_Delegate.java:63) at android.view.ViewGroup.drawChild(ViewGroup.java:4333) at android.view.ViewGroup.dispatchDraw(ViewGroup.java:4112) at android.view.View.draw_Original(View.java:20210) at android.view.View_Delegate.draw(View_Delegate.java:56) at android.view.View.draw(View.java:20177) Copy stack to clipboard
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the Android Pie rendering problem with android:elevation and begin with the stack trace at ViewGroup_Delegate.drawShadow and Canvas.clipRect. Confirm the issue is fixed when the elevated view renders without the Invalid Region.Op exception.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, java
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100