Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
Developer Community or GitHub with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
Setting the font size of a label using one of the named sizes in xaml either via a style or via onplatform is not working.
If I set the named size directly on a label element the size is applied ok.
But if I try to use a style or set the size using onplatform the size is not applied and the default size is used.
I have a thread about the problem here: https://forums.xamarin.com/discussion/comment/263653#Comment_263653
And a small repo showing the problem here: https://github.com/appbureauet/NamedSizeTest
Thank you for reporting this! Let me confirm that I can reproduce the issue with the project you linked to and I will update the report with my results.
I was able to reproduce this issue with the project on GitHub.
The following works:
<Setter Property="FontSize" Value="Large" />
However it's when trying to also use OnPlatform that the issue occurs:
I am confirming the report so the team can investigate further and determine whether or not this is expected behavior.
A workaround you can do is to set the Font property instead of FontSize:
This should work in the meantime, however be cautioned that the Font property has been deprecated so its usage may break the app in a future update.
### Version Tests
Hi Jimmy, thanks for the update.
And thanks for the workaround using the Font property.
I actually did try that, but when I tried it I used it to set multiple attributes like so:
And then it doesn't work. But only setting the size seems to work for now.
Still exist in 2.3.4 stable.
Makes styling the app pretty much impossible with a XAML style.
Can work round it with OnPlatForm and FontSize but that bug does exists still.
This appears to be resolved in 2.3.5. I ran the sample project in the description using 2.3.5-pre3 and the Labels used the expected FontSize. This works using both the old and new OnPlatform syntax.
Can you confirm that it is also working for you with 2.3.5-pre3? Thanks!
I can confirm that it is working with 126.96.36.199-pre3.
Fixed on 188.8.131.52-pre3