Core Plot (macOS)
Cocoa plotting framework for macOS, iOS, and tvOS
CPTPlatformSpecificFunctions.m File Reference
+ Include dependency graph for CPTPlatformSpecificFunctions.m:

Functions

void CPTPushCGContext (__nonnull CGContextRef newContext)
 Pushes the current AppKit graphics context onto a stack and replaces it with the given Core Graphics context. More...
 
void CPTPopCGContext (void)
 Pops the top context off the stack and restores it to the AppKit graphics context. More...
 
__nonnull CGColorRef CPTCreateCGColorFromNSColor (NSColor *__nonnull nsColor)
 Creates a CGColorRef from an NSColor. More...
 
CPTRGBAColor CPTRGBAColorFromNSColor (NSColor *__nonnull nsColor)
 Creates a CPTRGBAColor from an NSColor. More...
 
CPTNativeImage *__nonnull CPTQuickLookImage (CGRect rect, __nonnull CPTQuickLookImageBlock renderBlock)
 

Function Documentation

◆ CPTCreateCGColorFromNSColor()

__nonnull CGColorRef CPTCreateCGColorFromNSColor ( NSColor *__nonnull  nsColor)

Creates a CGColorRef from an NSColor.

The caller must release the returned CGColorRef. Pattern colors are not supported.

Parameters
nsColorThe NSColor.
Returns
The CGColorRef.

◆ CPTPopCGContext()

void CPTPopCGContext ( void  )

Pops the top context off the stack and restores it to the AppKit graphics context.

◆ CPTPushCGContext()

void CPTPushCGContext ( __nonnull CGContextRef  newContext)

Pushes the current AppKit graphics context onto a stack and replaces it with the given Core Graphics context.

Parameters
newContextThe graphics context.

◆ CPTQuickLookImage()

CPTNativeImage* __nonnull CPTQuickLookImage ( CGRect  rect,
__nonnull CPTQuickLookImageBlock  renderBlock 
)

◆ CPTRGBAColorFromNSColor()

CPTRGBAColor CPTRGBAColorFromNSColor ( NSColor *__nonnull  nsColor)

Creates a CPTRGBAColor from an NSColor.

Pattern colors are not supported.

Parameters
nsColorThe NSColor.
Returns
The CPTRGBAColor.