Logo Search packages:      
Sourcecode: codeblocks version File versions  Download package

int wxPdfDocument::AxialGradient ( const wxPdfColour col1,
const wxPdfColour col2,
double  x1 = 0,
double  y1 = 0,
double  x2 = 1,
double  y2 = 0,
double  intexp = 1 
) [virtual]

Defines a axial gradient shading.

Parameters:
col1first color (RGB or CMYK).
col2second color (RGB or CMYK).
x1start point of gradient vector, default: 0 (range 0 .. 1)
y1start point of gradient vector, default: 0 (range 0 .. 1)
x2end point of gradient vector, default: 1 (range 0 .. 1)
y2end point of gradient vector, default: 0 (range 0 .. 1)
intexpinterpolation exponent, default: 1

Definition at line 1895 of file pdfgraphics.cpp.

{
  int n = 0;
  if (ColorSpaceOk(col1, col2))
  {
    n = (*m_gradients).size()+1;
    (*m_gradients)[n] = new wxPdfAxialGradient(col1, col2, x1, y1, x2, y2, intexp);
  }
  else
  {
    wxLogError(_("wxPdfDocument::LinearGradient: Color spaces do not match."));
  }
  return n;
}

Generated by  Doxygen 1.6.0   Back to index