Core Plot (macOS)
Cocoa plotting framework for macOS, iOS, and tvOS
CPTPlatformSpecificFunctions.h File Reference
+ Include dependency graph for CPTPlatformSpecificFunctions.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

Graphics Context Save Stack
void CPTPushCGContext (__nonnull CGContextRef context)
 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...
 
Color Conversion
__nonnull CGColorRef CPTCreateCGColorFromNSColor (NSColor *__nonnull nsColor) CF_RETURNS_RETAINED
 Creates a CGColorRef from an NSColor. More...
 
CPTRGBAColor CPTRGBAColorFromNSColor (NSColor *__nonnull nsColor)
 Creates a CPTRGBAColor from an NSColor. More...
 
Debugging
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.