Platforms to show: All Mac Windows Linux Cross-Platform
Back to CGFontMBS class.
CGFontMBS.CreateWithDataProvider(CGDataProvider as Variant) as CGFontMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
shared method | CoreGraphics | MBS MacCG Plugin | 14.2 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | All |
Dataprovider must be a CGDataProviderMBS object.
Returns the font object or nil if the font can't be created.
Before drawing text in a Quartz context, you must set the font in the current graphics state by calling the function CGContextMBS.SetFontSize.
CGFontMBS.CreateWithFontName(name as string) as CGFontMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
shared method | CoreGraphics | MBS MacCG Plugin | 14.2 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | All |
Returns the font object or nil if the font can't be created.
Before drawing text in a Quartz context, you must set the font in the current graphics state by calling the function CGContextMBS.SetFont.
CGFontMBS.CreateWithPlatformFont(ATSFontHandle as Integer) as CGFontMBS
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
shared method | CoreGraphics | MBS MacCG Plugin | 14.2 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | All |
Create a CGFont using platformFontReference, a handle to a platform-specific font reference.
For MacOS X, platformFontReference should be a handle to an ATSFontRef.
The items on this page are in the following plugins: MBS MacCG Plugin.