Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

[Bug] Frame.Background not displaying GradientBrush on iOS #13092

Closed
sthch opened this issue Dec 10, 2020 · 3 comments · Fixed by #13101
Closed

[Bug] Frame.Background not displaying GradientBrush on iOS #13092

sthch opened this issue Dec 10, 2020 · 3 comments · Fixed by #13101
Assignees
Labels
a/brushes a/frame blocker Issue blocks next stable release. Prioritize fixing and reviewing this issue. e/3 🕒 3 in-progress This issue has an associated pull request that may resolve it! t/bug 🐛
Milestone

Comments

@sthch
Copy link

sthch commented Dec 10, 2020

Description

Set GradientBrush as Frame's background doesn't work on iOS, but working fine on Android.

Expected Behavior

Frame's background can be rendered as expected on Android.
微信截图_20201210102831

Actual Behavior

Frame's background can't be rendered correctly on iOS.
微信截图_20201210102923

Basic Information

  • Version with issue: 5.0-pre5
  • Platform Target Frameworks:
    • iOS: 14.2
    • Android: 10
@sthch sthch added s/unverified New report that has yet to be verified t/bug 🐛 labels Dec 10, 2020
@samhouts samhouts added this to New in Triage Dec 10, 2020
@jsuarezruiz
Copy link
Contributor

I have created a sample where try to reproduce the issue:
Issue13092.zip

But cannot reproduce it:
Captura de pantalla 2020-12-10 a las 10 02 41

Tested with Xamarin.Forms 5.0-pre5 on iOS 14 and Android 10. Could you review the attached sample or attach a sample where reproduce the issue?

Some questions:

  • Do you use Visual?
  • Are you using DynamicResource, AppThemeBinding etc?

@jsuarezruiz jsuarezruiz moved this from New to Needs Info in Triage Dec 10, 2020
@jsuarezruiz jsuarezruiz added s/needs-info ❓ A question has been asked that requires an answer before work can continue on this issue. s/needs-repro ❔ This reported issue doesn't include a sample project reproducing the issue. Please provide one. labels Dec 10, 2020
@sthch
Copy link
Author

sthch commented Dec 10, 2020

I have created a sample where try to reproduce the issue:
Issue13092.zip

But cannot reproduce it:
Captura de pantalla 2020-12-10 a las 10 02 41

Tested with Xamarin.Forms 5.0-pre5 on iOS 14 and Android 10. Could you review the attached sample or attach a sample where reproduce the issue?

Some questions:

  • Do you use Visual?
  • Are you using DynamicResource, AppThemeBinding etc?

Thanks for the reply!
I've find that the reason of my problem is I forget setting the Offset of the GradientStop, after setting the Offset, everything goes fine.
(BUT, on Android, it's all fine without setting the Offset of the GradientStop)

@jsuarezruiz jsuarezruiz added in-progress This issue has an associated pull request that may resolve it! and removed s/needs-info ❓ A question has been asked that requires an answer before work can continue on this issue. s/needs-repro ❔ This reported issue doesn't include a sample project reproducing the issue. Please provide one. s/unverified New report that has yet to be verified labels Dec 10, 2020
@jsuarezruiz
Copy link
Contributor

Ohh, I see. Thanks for your feedback!. I sent a PR to have the same behavior between platforms.

@jsuarezruiz jsuarezruiz moved this from Needs Info to Ready For Work in Triage Dec 10, 2020
@rmarinho rmarinho added this to the 5.0.0 milestone Dec 11, 2020
@rmarinho rmarinho added the blocker Issue blocks next stable release. Prioritize fixing and reviewing this issue. label Dec 11, 2020
@rmarinho rmarinho added this to To do in vNext+1 (5.0.0) via automation Dec 11, 2020
@rmarinho rmarinho moved this from To do to In Progress in vNext+1 (5.0.0) Dec 11, 2020
@rmarinho rmarinho removed this from Ready For Work in Triage Dec 11, 2020
vNext+1 (5.0.0) automation moved this from In Progress to Done Dec 15, 2020
rmarinho pushed a commit that referenced this issue Dec 15, 2020
…13101) fixes #13092

* Set same offsets behavior in gradientbrush on macOS and iOS.

* Updated sample

* Created shared BrushExtensions class between iOS and macOS
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
a/brushes a/frame blocker Issue blocks next stable release. Prioritize fixing and reviewing this issue. e/3 🕒 3 in-progress This issue has an associated pull request that may resolve it! t/bug 🐛
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

3 participants