WYSWYG editor for JUCE GUIs including Visualisers
Loading...
Searching...
No Matches
GradientBackground Class Reference

#include <foleys_GradientBackground.h>

Public Types

enum  Type { none = 0 , linear , radial }
 

Public Member Functions

 GradientBackground ()
 
void drawGradient (juce::Graphics &g, juce::Rectangle< float > bounds, const juce::Path &shape)
 
void setup (juce::String text, const Stylesheet &stylesheet)
 
void setupGradientFill (juce::Graphics &g, juce::Rectangle< float > bounds)
 
juce::String toString () const
 
void clear ()
 
bool isEmpty () const
 

Public Attributes

Type type = none
 
float angle = 0.0f
 
std::map< float, juce::Colour > colours
 

Member Enumeration Documentation

◆ Type

enum Type
Enumerator
none 
linear 
radial 

Constructor & Destructor Documentation

◆ GradientBackground()

References colours.

Member Function Documentation

◆ drawGradient()

void drawGradient ( juce::Graphics & g,
juce::Rectangle< float > bounds,
const juce::Path & shape )

References isEmpty(), and setupGradientFill().

◆ setup()

void setup ( juce::String text,
const Stylesheet & stylesheet )

◆ setupGradientFill()

void setupGradientFill ( juce::Graphics & g,
juce::Rectangle< float > bounds )

References angle, colours, linear, radial, and type.

Referenced by drawGradient().

◆ toString()

juce::String toString ( ) const

References angle, colours, linear, radial, and type.

◆ clear()

void clear ( )

References colours, none, and type.

Referenced by setup().

◆ isEmpty()

bool isEmpty ( ) const

References colours, none, and type.

Referenced by drawGradient().

Member Data Documentation

◆ type

◆ angle

float angle = 0.0f

Referenced by setup(), setupGradientFill(), and toString().

◆ colours

std::map<float, juce::Colour> colours

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