shashankpali / EZYGradientView

Create gradients and blur gradients without a single line of code
MIT License
376 stars 43 forks source link

Gradient partially not working #16

Open LinusGeffarth opened 6 years ago

LinusGeffarth commented 6 years ago

I have a view with a gradient view inside, that looks like this:

screen shot 2018-06-25 at 14 54 56

However, I'm seeing this result only after opening the view controller twice.
When first opening the vc, I see this:

screen shot 2018-06-25 at 14 54 32

Any idea why this happens?
Also, is there any like redraw() method or something, so that I could refresh the gradient manually after the view appeared?


Update

So it seems the issue occurs when embedding the EZYGradientView inside another view and setting the constraints to leading, trailing, top, and bottom equal to superview.*.
I was able to resolve the issue by specifying a fixed with for the gradient view itself.

LinusGeffarth commented 5 years ago

@shashankpali any updates on this?