JUCE  v6.1.6 (6.0.8-1114)
JUCE API
Looking for a senior C++ dev?
I'm looking for work. Hire me!
juce::CoreGraphicsContext Class Reference

#include <juce_mac_CoreGraphicsContext.h>

Inheritance diagram for juce::CoreGraphicsContext:
Collaboration diagram for juce::CoreGraphicsContext:

Classes

struct  SavedState
 

Public Member Functions

 CoreGraphicsContext (CGContextRef context, float flipHeight)
 
 ~CoreGraphicsContext () override
 
void addTransform (const AffineTransform &) override
 
void beginTransparencyLayer (float opacity) override
 
bool clipRegionIntersects (const Rectangle< int > &) override
 
void clipToImageAlpha (const Image &, const AffineTransform &) override
 
void clipToPath (const Path &, const AffineTransform &) override
 
bool clipToRectangle (const Rectangle< int > &) override
 
bool clipToRectangleList (const RectangleList< int > &) override
 
void drawGlyph (int glyphNumber, const AffineTransform &) override
 
void drawImage (const Image &sourceImage, const AffineTransform &) override
 
void drawLine (const Line< float > &) override
 
bool drawTextLayout (const AttributedString &, const Rectangle< float > &) override
 
void endTransparencyLayer () override
 
void excludeClipRectangle (const Rectangle< int > &) override
 
void fillPath (const Path &, const AffineTransform &) override
 
void fillRect (const Rectangle< float > &) override
 
void fillRect (const Rectangle< int > &, bool replaceExistingContents) override
 
void fillRectList (const RectangleList< float > &) override
 
Rectangle< intgetClipBounds () const override
 
const FontgetFont () override
 
float getPhysicalPixelScaleFactor () override
 
bool isClipEmpty () const override
 
bool isVectorDevice () const override
 Returns true if this device is vector-based, e.g. More...
 
void restoreState () override
 
void saveState () override
 
void setFill (const FillType &) override
 
void setFont (const Font &) override
 
void setInterpolationQuality (Graphics::ResamplingQuality) override
 
void setOpacity (float) override
 
void setOrigin (Point< int >) override
 Moves the origin to a new position. More...
 

Private Member Functions

void applyTransform (const AffineTransform &) const
 
bool clipToRectangleListWithoutTest (const RectangleList< int > &)
 
void createPath (const Path &) const
 
void createPath (const Path &, const AffineTransform &) const
 
void drawGradient ()
 
void drawImage (const Image &, const AffineTransform &, bool fillEntireClipAsTiles)
 
void fillCGRect (const CGRect &, bool replaceExistingContents)
 
void flip () const
 

Private Attributes

detail::ContextPtr context
 
const CGFloat flipHeight
 
detail::ColorSpacePtr greyColourSpace
 
Rectangle< intlastClipRect
 
bool lastClipRectIsValid = false
 
detail::ColorSpacePtr rgbColourSpace
 
std::unique_ptr< SavedStatestate
 
OwnedArray< SavedStatestateStack
 

Constructor & Destructor Documentation

◆ CoreGraphicsContext()

juce::CoreGraphicsContext::CoreGraphicsContext ( CGContextRef  context,
float  flipHeight 
)

◆ ~CoreGraphicsContext()

juce::CoreGraphicsContext::~CoreGraphicsContext ( )
override

Member Function Documentation

◆ addTransform()

void juce::CoreGraphicsContext::addTransform ( const AffineTransform )
overridevirtual

◆ applyTransform()

void juce::CoreGraphicsContext::applyTransform ( const AffineTransform ) const
private

◆ beginTransparencyLayer()

void juce::CoreGraphicsContext::beginTransparencyLayer ( float  opacity)
overridevirtual

◆ clipRegionIntersects()

bool juce::CoreGraphicsContext::clipRegionIntersects ( const Rectangle< int > &  )
overridevirtual

◆ clipToImageAlpha()

void juce::CoreGraphicsContext::clipToImageAlpha ( const Image ,
const AffineTransform  
)
overridevirtual

◆ clipToPath()

void juce::CoreGraphicsContext::clipToPath ( const Path ,
const AffineTransform  
)
overridevirtual

◆ clipToRectangle()

bool juce::CoreGraphicsContext::clipToRectangle ( const Rectangle< int > &  )
overridevirtual

◆ clipToRectangleList()

bool juce::CoreGraphicsContext::clipToRectangleList ( const RectangleList< int > &  )
overridevirtual

◆ clipToRectangleListWithoutTest()

bool juce::CoreGraphicsContext::clipToRectangleListWithoutTest ( const RectangleList< int > &  )
private

◆ createPath() [1/2]

void juce::CoreGraphicsContext::createPath ( const Path ) const
private

◆ createPath() [2/2]

void juce::CoreGraphicsContext::createPath ( const Path ,
const AffineTransform  
) const
private

◆ drawGlyph()

void juce::CoreGraphicsContext::drawGlyph ( int  glyphNumber,
const AffineTransform  
)
overridevirtual

◆ drawGradient()

void juce::CoreGraphicsContext::drawGradient ( )
private

◆ drawImage() [1/2]

void juce::CoreGraphicsContext::drawImage ( const Image ,
const AffineTransform ,
bool  fillEntireClipAsTiles 
)
private

◆ drawImage() [2/2]

void juce::CoreGraphicsContext::drawImage ( const Image sourceImage,
const AffineTransform  
)
overridevirtual

◆ drawLine()

void juce::CoreGraphicsContext::drawLine ( const Line< float > &  )
overridevirtual

◆ drawTextLayout()

bool juce::CoreGraphicsContext::drawTextLayout ( const AttributedString ,
const Rectangle< float > &   
)
overridevirtual

Reimplemented from juce::LowLevelGraphicsContext.

◆ endTransparencyLayer()

void juce::CoreGraphicsContext::endTransparencyLayer ( )
overridevirtual

◆ excludeClipRectangle()

void juce::CoreGraphicsContext::excludeClipRectangle ( const Rectangle< int > &  )
overridevirtual

◆ fillCGRect()

void juce::CoreGraphicsContext::fillCGRect ( const CGRect &  ,
bool  replaceExistingContents 
)
private

◆ fillPath()

void juce::CoreGraphicsContext::fillPath ( const Path ,
const AffineTransform  
)
overridevirtual

◆ fillRect() [1/2]

void juce::CoreGraphicsContext::fillRect ( const Rectangle< float > &  )
overridevirtual

◆ fillRect() [2/2]

void juce::CoreGraphicsContext::fillRect ( const Rectangle< int > &  ,
bool  replaceExistingContents 
)
overridevirtual

◆ fillRectList()

void juce::CoreGraphicsContext::fillRectList ( const RectangleList< float > &  )
overridevirtual

◆ flip()

void juce::CoreGraphicsContext::flip ( ) const
private

◆ getClipBounds()

Rectangle<int> juce::CoreGraphicsContext::getClipBounds ( ) const
overridevirtual

◆ getFont()

const Font& juce::CoreGraphicsContext::getFont ( )
overridevirtual

◆ getPhysicalPixelScaleFactor()

float juce::CoreGraphicsContext::getPhysicalPixelScaleFactor ( )
overridevirtual

◆ isClipEmpty()

bool juce::CoreGraphicsContext::isClipEmpty ( ) const
overridevirtual

◆ isVectorDevice()

bool juce::CoreGraphicsContext::isVectorDevice ( ) const
inlineoverridevirtual

Returns true if this device is vector-based, e.g.

a printer.

Implements juce::LowLevelGraphicsContext.

◆ restoreState()

void juce::CoreGraphicsContext::restoreState ( )
overridevirtual

◆ saveState()

void juce::CoreGraphicsContext::saveState ( )
overridevirtual

◆ setFill()

void juce::CoreGraphicsContext::setFill ( const FillType )
overridevirtual

◆ setFont()

void juce::CoreGraphicsContext::setFont ( const Font )
overridevirtual

◆ setInterpolationQuality()

void juce::CoreGraphicsContext::setInterpolationQuality ( Graphics::ResamplingQuality  )
overridevirtual

◆ setOpacity()

void juce::CoreGraphicsContext::setOpacity ( float  )
overridevirtual

◆ setOrigin()

void juce::CoreGraphicsContext::setOrigin ( Point< int )
overridevirtual

Moves the origin to a new position.

The coordinates are relative to the current origin, and indicate the new position of (0, 0).

Implements juce::LowLevelGraphicsContext.

Member Data Documentation

◆ context

detail::ContextPtr juce::CoreGraphicsContext::context
private

◆ flipHeight

const CGFloat juce::CoreGraphicsContext::flipHeight
private

◆ greyColourSpace

detail::ColorSpacePtr juce::CoreGraphicsContext::greyColourSpace
private

◆ lastClipRect

Rectangle<int> juce::CoreGraphicsContext::lastClipRect
mutableprivate

◆ lastClipRectIsValid

bool juce::CoreGraphicsContext::lastClipRectIsValid = false
mutableprivate

◆ rgbColourSpace

detail::ColorSpacePtr juce::CoreGraphicsContext::rgbColourSpace
private

◆ state

std::unique_ptr<SavedState> juce::CoreGraphicsContext::state
private

◆ stateStack

OwnedArray<SavedState> juce::CoreGraphicsContext::stateStack
private

The documentation for this class was generated from the following file: