Version: 3.1.4
wxGraphicsPenInfo Class Reference

#include <wx/graphics.h>

Detailed Description

This class is a helper used for wxGraphicsPen creation using named parameter idiom: it allows specifying various wxGraphicsPen attributes using the chained calls to its clearly named methods instead of passing them in the fixed order to wxGraphicsPen constructors.

Typically you would use wxGraphicsPenInfo with a wxGraphicsContext, e.g. to start drawing with a dotted blue pen slightly wider than normal you could write the following:

Since
3.1.1

Public Member Functions

 wxGraphicsPenInfo (const wxColour &colour=wxColour(), wxDouble width=1.0, wxPenStyle style=wxPENSTYLE_SOLID)
 
wxGraphicsPenInfoColour (const wxColour &col)
 
wxGraphicsPenInfoWidth (wxDouble width)
 
wxGraphicsPenInfoStyle (wxPenStyle style)
 
wxGraphicsPenInfoStipple (const wxBitmap &stipple)
 
wxGraphicsPenInfoDashes (int nb_dashes, const wxDash *dash)
 
wxGraphicsPenInfoJoin (wxPenJoin join)
 
wxGraphicsPenInfoCap (wxPenCap cap)
 
wxGraphicsPenInfoLinearGradient (wxDouble x1, wxDouble y1, wxDouble x2, wxDouble y2, const wxColour &c1, const wxColour &c2, const wxGraphicsMatrix &matrix=wxNullGraphicsMatrix)
 
wxGraphicsPenInfoLinearGradient (wxDouble x1, wxDouble y1, wxDouble x2, wxDouble y2, const wxGraphicsGradientStops &stops, const wxGraphicsMatrix &matrix=wxNullGraphicsMatrix)
 
wxGraphicsPenInfoRadialGradient (wxDouble startX, wxDouble startY, wxDouble endX, wxDouble endY, wxDouble radius, const wxColour &oColor, const wxColour &cColor, const wxGraphicsMatrix &matrix=wxNullGraphicsMatrix)
 
wxGraphicsPenInfoRadialGradient (wxDouble startX, wxDouble startY, wxDouble endX, wxDouble endY, wxDouble radius, const wxGraphicsGradientStops &stops, const wxGraphicsMatrix &matrix=wxNullGraphicsMatrix)
 
wxColour GetColour () const
 
wxBitmap GetStipple () const
 
wxPenStyle GetStyle () const
 
wxPenJoin GetJoin () const
 
wxPenCap GetCap () const
 
int GetDashes (wxDash **ptr)
 
int GetDashCount () const
 
wxDash * GetDash () const
 
bool IsTransparent () const
 
wxDouble GetWidth () const
 
wxGradientType GetGradientType () const
 
wxDouble GetX1 () const
 
wxDouble GetY1 () const
 
wxDouble GetX2 () const
 
wxDouble GetY2 () const
 
wxDouble GetStartX () const
 
wxDouble GetStartY () const
 
wxDouble GetEndX () const
 
wxDouble GetEndY () const
 
wxDouble GetRadius () const
 
const wxGraphicsGradientStopsGetStops () const
 

Constructor & Destructor Documentation

wxGraphicsPenInfo::wxGraphicsPenInfo ( const wxColour colour = wxColour(),
wxDouble  width = 1.0,
wxPenStyle  style = wxPENSTYLE_SOLID 
)
explicit

Member Function Documentation

wxGraphicsPenInfo& wxGraphicsPenInfo::Cap ( wxPenCap  cap)
wxGraphicsPenInfo& wxGraphicsPenInfo::Colour ( const wxColour col)
wxGraphicsPenInfo& wxGraphicsPenInfo::Dashes ( int  nb_dashes,
const wxDash *  dash 
)
wxPenCap wxGraphicsPenInfo::GetCap ( ) const
wxColour wxGraphicsPenInfo::GetColour ( ) const
wxDash* wxGraphicsPenInfo::GetDash ( ) const
int wxGraphicsPenInfo::GetDashCount ( ) const
int wxGraphicsPenInfo::GetDashes ( wxDash **  ptr)
wxDouble wxGraphicsPenInfo::GetEndX ( ) const
wxDouble wxGraphicsPenInfo::GetEndY ( ) const
wxGradientType wxGraphicsPenInfo::GetGradientType ( ) const
wxPenJoin wxGraphicsPenInfo::GetJoin ( ) const
wxDouble wxGraphicsPenInfo::GetRadius ( ) const
wxDouble wxGraphicsPenInfo::GetStartX ( ) const
wxDouble wxGraphicsPenInfo::GetStartY ( ) const
wxBitmap wxGraphicsPenInfo::GetStipple ( ) const
const wxGraphicsGradientStops& wxGraphicsPenInfo::GetStops ( ) const
wxPenStyle wxGraphicsPenInfo::GetStyle ( ) const
wxDouble wxGraphicsPenInfo::GetWidth ( ) const
wxDouble wxGraphicsPenInfo::GetX1 ( ) const
wxDouble wxGraphicsPenInfo::GetX2 ( ) const
wxDouble wxGraphicsPenInfo::GetY1 ( ) const
wxDouble wxGraphicsPenInfo::GetY2 ( ) const
bool wxGraphicsPenInfo::IsTransparent ( ) const
wxGraphicsPenInfo& wxGraphicsPenInfo::Join ( wxPenJoin  join)
wxGraphicsPenInfo& wxGraphicsPenInfo::LinearGradient ( wxDouble  x1,
wxDouble  y1,
wxDouble  x2,
wxDouble  y2,
const wxColour c1,
const wxColour c2,
const wxGraphicsMatrix matrix = wxNullGraphicsMatrix 
)
wxGraphicsPenInfo& wxGraphicsPenInfo::LinearGradient ( wxDouble  x1,
wxDouble  y1,
wxDouble  x2,
wxDouble  y2,
const wxGraphicsGradientStops stops,
const wxGraphicsMatrix matrix = wxNullGraphicsMatrix 
)
wxGraphicsPenInfo& wxGraphicsPenInfo::RadialGradient ( wxDouble  startX,
wxDouble  startY,
wxDouble  endX,
wxDouble  endY,
wxDouble  radius,
const wxColour oColor,
const wxColour cColor,
const wxGraphicsMatrix matrix = wxNullGraphicsMatrix 
)
wxGraphicsPenInfo& wxGraphicsPenInfo::RadialGradient ( wxDouble  startX,
wxDouble  startY,
wxDouble  endX,
wxDouble  endY,
wxDouble  radius,
const wxGraphicsGradientStops stops,
const wxGraphicsMatrix matrix = wxNullGraphicsMatrix 
)
wxGraphicsPenInfo& wxGraphicsPenInfo::Stipple ( const wxBitmap stipple)
wxGraphicsPenInfo& wxGraphicsPenInfo::Style ( wxPenStyle  style)
wxGraphicsPenInfo& wxGraphicsPenInfo::Width ( wxDouble  width)