xamarin-macios
xamarin-macios copied to clipboard
Make UIFontWeightConstants & UIFont.GetFontWeight public
Actual Behavior
I am trying to create a "semi bold" variant of a custom font using this approach.
However, it seems that the UIFontWeight constants are not public in Xamarin so I cannot use the underlying float value (which seems to be 0.30000001192092896f for UIFontWeightSemiBold).
Maybe you could also make this helper method publicly available that Xamarin uses internally to create a system font with a given UIFontWeight enum
Environment
=== Visual Studio Community 2019 for Mac ===
Version 8.8.10 (build 2)
Installation UUID: 62fad2e5-5b57-42c2-ad56-98da5949675b
GTK+ 2.24.23 (Raleigh theme)
Xamarin.Mac 6.18.0.23 (d16-6 / 088c73638)
Package version: 612000122
=== Mono Framework MDK ===
Runtime:
Mono 6.12.0.122 (2020-02/c621c35ffa0) (64-bit)
Package version: 612000122
=== Roslyn (Language Service) ===
3.8.0-5.20519.18+4c195c3ac1974edcefa76774d7a59a2350ec55fa
=== NuGet ===
Version: 5.8.0.6860
=== .NET Core SDK ===
SDK: Not installed
MSBuild SDKs: /Applications/Visual Studio.app/Contents/Resources/lib/monodevelop/bin/MSBuild/Current/bin/Sdks
=== .NET Core Runtime ===
Runtime: Not installed
=== .NET Core 3.1 SDK ===
SDK: Not installed
=== Xamarin.Profiler ===
Version: 1.6.15.68
Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler
=== Updater ===
Version: 11
=== Apple Developer Tools ===
Xcode 12.4 (17801)
Build 12D4e
=== Xamarin.Mac ===
Version: 7.4.0.10 (Visual Studio Community)
Hash: a4c70e7d0
Branch: xcode12.4
Build date: 2021-02-17 17:40:51-0500
=== Xamarin.iOS ===
Version: 14.10.0.4 (Visual Studio Community)
Hash: 5a05865f6
Branch: xcode12.4
Build date: 2021-01-28 02:30:23-0500
=== Xamarin Designer ===
Version: 16.8.0.510
Hash: 44e3f3ce9
Branch: remotes/origin/d16-8
Build date: 2020-12-10 00:06:14 UTC
=== Xamarin.Android ===
Not Installed
=== Microsoft OpenJDK for Mobile ===
Java SDK: Not Found
Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL
=== Android SDK Manager ===
Version: 16.8.0.32
Hash: 01a7774
Branch: remotes/origin/d16-8
Build date: 2021-01-14 00:34:58 UTC
=== Android Device Manager ===
Version: 16.8.0.46
Hash: 0a81419
Branch: remotes/origin/d16-8
Build date: 2021-01-14 00:35:22 UTC
=== Build Information ===
Release ID: 808100002
Git revision: f81ffa2444a28c09f173849935ec9ee0195a5b17
Build date: 2021-02-18 12:02:12-05
Build branch: release-8.8
Xamarin extensions: f81ffa2444a28c09f173849935ec9ee0195a5b17
=== Operating System ===
Mac OS X 10.16.0
Darwin 20.3.0 Darwin Kernel Version 20.3.0
Thu Jan 21 00:06:51 PST 2021
root:xnu-7195.81.3~1/RELEASE_ARM64_T8101 x86_64
Valid point, added as an enhancement and will be addressed.