- Home
- Forum
- Xamarin.Forms
- SfNumericTextBox TextColor cannot be set to Black
SfNumericTextBox TextColor cannot be set to Black
Hello,
I'm using SfNumericTextBox in Xamarin Forms and it looks like it does not set Black value to TextColor.
My input layout looks like this:
<inputLayout:SfTextInputLayout
Hint="{Binding AmountHint}"
HelperText="{Binding AmountHelperText}"
ErrorColor="Red"
HasError="{Binding Path=AmountHasError, Mode=TwoWay}"
ErrorText="{Binding Path=AmountErrorMessage, Mode=TwoWay}">
<numericBox:SfNumericTextBox
TextColor="Black"
Value="{Binding AmountValue, Mode=TwoWay}" />
</inputLayout:SfTextInputLayout>
When iOS runs in Dark mode - control will ignore TextColor="Black". At the same time if I set any other color - it work as expected.
I use 18.3.0.47 version.
I tried to use both direct setting of TextColor as above and DynamicResource as well - it works well unless I try to set it to black.
SIGN IN To post a reply.
8 Replies
1 reply marked as answer
AL
Alex
November 11, 2020 06:47 AM UTC
As a workaround that I use now is setting it not to Black (or #000000), but to #000001 - it looks almost as black for humans and it works.
RS
Ramya Soundar Rajan
Syncfusion Team
November 11, 2020 12:27 PM UTC
Hi Alex,
We are glad that your issue is resolved by your workaround solution.
We have also checked reported issue in iPhone but not reproduced on our side. So, can you share the possible code example to replicate it at our end to replicate it and provide a possible solution earlier?
For your information, find the result from our testing
This will be helpful for us to validate the issue on our side further.
Regards,
Ramya S
Marked as answer
AL
Alex
November 11, 2020 12:51 PM UTC
Hi Ramya,
Thanks a lot for checking and writing back. Maybe this issue appears in some specific cases. I would not say that there is something extraordinary that I use. Only thing - I use Prism framework, that's it.
Before posting this message I checked for a similar issues and seems that such behaviour occurs from time to time with other people as well. One example is here: https://www.syncfusion.com/forums/148219/rendering-issue-forcing-white-text - that gentleman solved it by setting color to blue and than to black programmatically. In my case I just used slightly modified color.
As you asked - I have uploaded full XAML code here: https://alex.ihnatusha.pro/downloads/sfExample.txt
The resource dictionary from where DynamicResource styles are loaded are here: https://alex.ihnatusha.pro/downloads/sfDynamicResource.txt
If I change #000001 to Black or #000000 in InputNumeric - colours will remain white.
Thanks for checking.
Alex
RS
Ramya Soundar Rajan
Syncfusion Team
November 12, 2020 02:16 PM UTC
Hi Alex,
Thanks for sharing your code snippet.
Currently we are validating on this problem. We will update you the status to provide the possible source or sample solution on November 16, 2020.
Regards,
Ramya S
RS
Ramya Soundar Rajan
Syncfusion Team
November 16, 2020 02:16 PM UTC
Hi Alex,
On further analysis, the reported problem occurred in the framework entry control when setting the dynamic resource text color using dark mode. So, we will check and fix the reported problem in SfNumericTextBox in volume 4 release which is expected to be rolled out in the month of December 2020.
Regards,
Ramya S
AL
Alex
November 16, 2020 02:20 PM UTC
Thanks a lot!
HM
Hemalatha Marikumar
Syncfusion Team
November 17, 2020 01:45 PM UTC
Hi Alex,
Welcome. As promised earlier, we will move this in our volume 4, 2020 release. We will let you know once it gets rolled out.
Regards,
Hemalatha M.
Hemalatha M.
RS
Ramya Soundar Rajan
Syncfusion Team
December 18, 2020 01:54 PM UTC
Hi Alex,
We are glad to announce that our Essential Studio 2020 Volume 4 release v18.4.0.30 is rolled out and is available for download under the following link.
We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.
Regards,
Ramya S
SIGN IN To post a reply.