MWAWGraphicStyle::Gradient Struct Reference documentation

MWAWGraphicStyle::Gradient Struct Reference

a basic gradient used in a MWAWGraphicStyle More...

`#include <MWAWGraphicStyle.hxx>`

## Classes
struct | Stop
| a structure used to define the gradient limit in MWAWGraphicStyle More...

## Public Types
enum | Type { G_None , G_Axial , G_Linear , G_Radial , G_Rectangular , G_Square , G_Ellipsoid }
| an enum used to define the gradient type More...

## Public Member Functions
| Gradient ()
| constructor
bool | hasGradient (bool complex=false) const
| returns true if the gradient is defined
void | addTo (librevenge::RVNGPropertyList &propList) const
| add a gradient to the propList
bool | getAverageColor (MWAWColor &color) const
| returns the average gradient color if the gradient is defined.
int | cmp (Gradient const &a) const
| compare two gradient

## Public Attributes
Type | m_type
| the gradient type
std::vector< Stop > | m_stopList
| the list of gradient limits
float | m_angle
| the gradient angle
float | m_border
| the gradient border opacity
MWAWVec2f | m_percentCenter
| the gradient center
float | m_radius
| the gradient radius

## Friends
std::ostream & | operator<< (std::ostream &o, Gradient const &grad)
| a print operator

## Detailed Description

a basic gradient used in a MWAWGraphicStyle

## Member Enumeration Documentation

## ◆ Type

enum MWAWGraphicStyle::Gradient::Type

an enum used to define the gradient type

Enumerator
G_None |
G_Axial |
G_Linear |
G_Radial |
G_Rectangular |
G_Square |
G_Ellipsoid |

## Constructor & Destructor Documentation

## ◆ Gradient()

MWAWGraphicStyle::Gradient::Gradient | ( |  | ) |
| inline

constructor

Referenced by cmp(), and operator<<.

## Member Function Documentation

## ◆ addTo()

void MWAWGraphicStyle::Gradient::addTo | ( | librevenge::RVNGPropertyList & | propList | ) | const

add a gradient to the propList

## ◆ cmp()

int MWAWGraphicStyle::Gradient::cmp | ( | Gradient const & | a | ) | const
| inline

compare two gradient

## ◆ getAverageColor()

bool MWAWGraphicStyle::Gradient::getAverageColor | ( | MWAWColor & | color | ) | const

returns the average gradient color if the gradient is defined.

Referenced by Canvas5StyleManager::updateLineColor().

## ◆ hasGradient()

bool MWAWGraphicStyle::Gradient::hasGradient | ( | bool | complex = false | ) | const
| inline

returns true if the gradient is defined

Referenced by Canvas5StyleManager::updateLineColor(), and Canvas5StyleManager::updateSurfaceColor().

## Friends And Related Symbol Documentation

## ◆ operator<<

std::ostream & operator<< | ( | std::ostream & | o,
|  | Gradient const & | grad )
| friend

a print operator

## Member Data Documentation

## ◆ m_angle

float MWAWGraphicStyle::Gradient::m_angle

the gradient angle

Referenced by addTo(), cmp(), Gradient(), operator<<, Canvas5StyleManager::readGradient(), and CanvasStyleManager::readGradient().

## ◆ m_border

float MWAWGraphicStyle::Gradient::m_border

the gradient border opacity

Referenced by addTo(), cmp(), Gradient(), and operator<<.

## ◆ m_percentCenter

MWAWVec2f MWAWGraphicStyle::Gradient::m_percentCenter

the gradient center

Referenced by addTo(), cmp(), Gradient(), operator<<, Canvas5StyleManager::readGradient(), and CanvasStyleManager::readGradient().

## ◆ m_radius

float MWAWGraphicStyle::Gradient::m_radius

the gradient radius

Referenced by addTo(), cmp(), Gradient(), and operator<<.

## ◆ m_stopList

std::vector<Stop> MWAWGraphicStyle::Gradient::m_stopList

the list of gradient limits

Referenced by addTo(), cmp(), getAverageColor(), Gradient(), hasGradient(), operator<<, PowerPoint3Parser::readFramesList(), Canvas5StyleManager::readGradient(), CanvasStyleManager::readGradient(), CricketDrawParser::readShape(), GreatWksGraph::readStyle(), PowerPoint7Graph::readStyle(), ClarisDrawStyleManagerInternal::Gradient::update(), ClarisWksStyleManagerInternal::Gradient::update(), ClarisDrawStyleManager::updateGradient(), and ClarisWksStyleManager::updateGradient().

## ◆ m_type

Type MWAWGraphicStyle::Gradient::m_type

the gradient type

Referenced by addTo(), cmp(), Gradient(), hasGradient(), operator<<, Canvas5StyleManager::readGradient(), CanvasStyleManager::readGradient(), FreeHandParserInternal::State::updateFillStyle(), MacDrawProStyleManager::updateGradient(), and RagTime5StyleManager::updateSurfaceStyle().

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

- MWAWGraphicStyle.hxx
- MWAWGraphicStyle.cxx