Open NickeManarin opened 5 years ago
It has something to do with the previous view being displayed. I have to do more tests.
Duplicate of https://github.com/xamarin/Xamarin.Forms/issues/6317 See my comment for workaround
@toomasz Is it? Because mine is a simple Label
, not a FontImageSource
.
Btw, I noticed that it only happens when going back and forth displaying the previous View in which it contains a dragabble list view by the Sharpnado nuget and images from FFImageLoading nuget.
For example, if I go to the next view and go back to the view that displays the label from the picture, it will work normally.
@NickeManarin I strongly suggest you attach a sample which reproduces the issue in order to increase the chance of getting it fixed. I know, I know, it's boring but it's worth it 👌.
@andreinitescu Yes, that was my original idea. But since the project is closed source, I need to create a sample project that simulates the issue. I'm going to do that in the following days.
@NickeManarin Try the fix here https://github.com/xamarin/Xamarin.Forms/issues/6317#issuecomment-498358580 if it fixes the issue then it's a duplicate as mentioned above.
It happened something worse, now the icons inside a FontImageSource
(inside a button) are gone.
But... I'm not experiencing the issue with the faulty icon anymore with the IconLabel
(that extends a Label
).
At first I thought it could be something related to the fact that my button was invisible at first (but later was being displayed), but I tested on a button that is always visible... Same issue.
Duplicate of #6317. @NickeManarin if you think it's different, add a comment. And if you can a repro sample ;)
So, here's the test project: https://github.com/NickeManarin/Xamarin.Demos2
There's two files in which I want you people to see:
TestApp.Droid/Renderers/FontIconLabelRenderer.cs
TestApp.Droid/Helpers/FontImageSourceHandler.cs
Both have commented lines, right above the namespace
declaration.
So, the only way to solve this issue for me was to create a label renderer that sets its Font
manually.
Thanks for the sample!. Yes, I see the problem.
@NickeManarin I built a custom nuget based on https://github.com/xamarin/Xamarin.Forms/issues/6317 / https://github.com/xamarin/Xamarin.Forms/pull/6470 and it does seem to fix your issue. Give it a try and confirm if that is the case? Xamarin.Forms.9.9.16.zip
@NickeManarin would you be able to have another look with the latest Xamarin.Forms version?
According to issue #6317 this is likely to be fixed now. Would be great if you could verify that this fixes it for you as well and close the issue accordingly, thanks!
The bug is fixed for most controls in the latest Xamarin version, but this is still an issue, when a FontImageSource
is used as Shell.FlyoutIcon
or SearchHandler.QueryIcon
.
Description
I'm trying to use a custom glyph font. It works the first time that the View appears, but the second time a rectangle with a X inside will be rendered instead.
Steps to Reproduce
IconLabel
extendingLabel
.Basic Information
Rg.Plugins.Popup
1.1.5.188
MyAppMicrosoft.EntityFrameworkCore
2.2.4
MyAppPolly
7.1.0
MyAppMicrosoft.EntityFrameworkCore.Sq...
2.2.4
MyAppXamarin.FFImageLoading
2.4.11.982
MyAppNodaTime
2.4.5
MyAppMicrosoft.EntityFrameworkCore.De...
2.2.4
MyAppXamarin.Forms.GoogleMaps
3.2.0
MyAppSharpnado.Forms.HorizontalListView
1.1.0
MyAppXamarin.FFImageLoading.Forms
2.4.11.982
MyAppPlugin.Permissions
5.0.0-beta
MyAppXam.Plugin.Connectivity
3.2.0
MyAppXamarin.FFImageLoading.Transform...
2.4.11.982
MyAppCarouselView.FormsPlugin
5.2.0
MyAppDLToolkit.Forms.Controls.FlowLis...
2.0.11
MyAppForms.Controls.FlexButton
0.9.1
MyAppfusillade
2.0.5
MyAppIdeine.ModernHttpClient
3.2.2
MyAppDLToolkit.Forms.Controls.TagEntr...
1.0.5
MyAppMicrosoft.EntityFrameworkCore.Tools
2.2.4
MyAppMLToolkit.Forms.SwipeCardView
2.0.0
MyAppXam.Plugin.Media
4.0.1.5
MyAppXamarin.Essentials
1.1.0
MyAppNETStandard.Library
2.0.3
MyAppXamarin.Forms.PancakeView
1.0.21
MyAppRefit
4.7.9
MyAppXamarin.Forms
4.0.0.482894
MyAppDLToolkit.Forms.Controls.ImageCr...
1.0.7
MyAppCarouselView.FormsPlugin
5.2.0
MyApp.iOSDLToolkit.Forms.Controls.FlowLis...
2.0.11
MyApp.iOSDLToolkit.Forms.Controls.ImageCr...
1.0.7
MyApp.iOSDLToolkit.Forms.Controls.TagEntr...
1.0.5
MyApp.iOSForms.Controls.FlexButton
0.9.1
MyApp.iOSPlugin.Permissions
5.0.0-beta
MyApp.iOSRg.Plugins.Popup
1.1.5.188
MyApp.iOSSharpnado.Forms.HorizontalListView
1.1.0
MyApp.iOSXam.Plugin.Media
4.0.1.5
MyApp.iOSXamarin.FFImageLoading
2.4.11.982
MyApp.iOSXamarin.FFImageLoading.Forms
2.4.11.982
MyApp.iOSXamarin.FFImageLoading.Transform...
2.4.11.982
MyApp.iOSXamarin.Forms
4.0.0.482894
MyApp.iOSXamarin.Essentials
1.1.0
MyApp.iOSXamarin.Forms.GoogleMaps
3.2.0
MyApp.iOSCarouselView.FormsPlugin
5.2.0
MyApp.AndroidDLToolkit.Forms.Controls.FlowLis...
2.0.11
MyApp.AndroidDLToolkit.Forms.Controls.ImageCr...
1.0.7
MyApp.AndroidDLToolkit.Forms.Controls.TagEntr...
1.0.5
MyApp.AndroidForms.Controls.FlexButton
0.9.1
MyApp.AndroidPlugin.Permissions
5.0.0-beta
MyApp.AndroidRg.Plugins.Popup
1.1.5.188
MyApp.AndroidSharpnado.Forms.HorizontalListView
1.1.0
MyApp.AndroidXam.Plugin.Media
4.0.1.5
MyApp.AndroidXamarin.FFImageLoading
2.4.11.982
MyApp.AndroidXamarin.FFImageLoading.Forms
2.4.11.982
MyApp.AndroidXamarin.FFImageLoading.Transform...
2.4.11.982
MyApp.AndroidXamarin.Forms
4.0.0.482894
MyApp.AndroidXamarin.Android.Support.Design
28.0.0.1
MyApp.AndroidXamarin.Android.Support.v7.AppCo...
28.0.0.1
MyApp.AndroidXamarin.Android.Support.v4
28.0.0.1
MyApp.AndroidXamarin.Android.Support.v7.CardView
28.0.0.1
MyApp.AndroidXamarin.Android.Support.v7.Media...
28.0.0.1
MyApp.AndroidXamarin.Android.Support.Core.Utils
28.0.0.1
MyApp.AndroidXamarin.Android.Support.CustomTabs
28.0.0.1
MyApp.AndroidXamarin.Essentials
1.1.0
MyApp.AndroidXamarin.Forms.GoogleMaps
3.2.0
MyApp.AndroidXamarin.GooglePlayServices.Location
60.1142.1
MyApp.AndroidScreenshots
This is the result:
Reproduction Link
Not yet...