-
Notifications
You must be signed in to change notification settings - Fork 732
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NumberBox.NumberFormatter is not used on Android #18308
Comments
Thanks for the report. It should be supported by this portion: uno/src/Uno.UI/Microsoft/UI/Xaml/Controls/NumberBox/NumberBox.cs Lines 535 to 538 in b6e4604
You may to try and see if other platforms are using it. |
I have been trying to build and test it on MacOS, but no luck so far... Will let you know when I manage to build it Thanks for the response! |
Same behaviour on MacOS (as on Android, the custom formatter is not used) Maybe I can try to debug that portion of the code to find out what is wrong on Android... could you please guide me? What project should I open on Windows to debug Uno on Android? |
Thanks for the update. You can find debugging information in our docs and you can join our discord, the community can help as well. |
I was able to reproduce the same issue on Android on my side (works on WinUI, Skia, Wasm), I will try to get more details on why the calls are not being executed. My repro: |
Current behavior
I am binding a custom number formatter to a NumberBox component. Something like this:
, which I instantiate on my class:
I then bind it in a DataTemplate:
On Windows, it works as I expected: no matter what values I give to SmallChange and LargeChange (NumberBox), my formatter shows only one fraction digit.
On Android, an instance of FloatNumberRounder is actually instantiated, but then, when I click the arrows, none of the methods are called and, depending on the values of SmallChange/LargeChange, values show with 2 fraction digits. It is curious that, in the absence of a formatter, no random number of digits is shown due to imprecision (as it is on Windows)
Expected behavior
I would expect the instance of NumberFormatter to be used also on Android
How to reproduce it (as minimally and precisely as possible)
No response
Workaround
No response
Works on UWP/WinUI
None
Environment
Uno.UI / Uno.UI.WebAssembly / Uno.UI.Skia
NuGet package version(s)
No response
Affected platforms
Android
IDE
Visual Studio 2022
IDE version
No response
Relevant plugins
No response
Anything else we need to know?
No response
The text was updated successfully, but these errors were encountered: