Don't mention wxPenInfoBase in the documentation

This is an implementation detail, don't confuse the user with this
template class which isn't supposed to be used in the user code.

Also improve the example in the documentation, the old one (using pen of
width 0 but with a colour) didn't make much sense.
This commit is contained in:
Vadim Zeitlin
2017-09-10 01:28:38 +02:00
parent a156d5fa40
commit af3581758b
2 changed files with 15 additions and 12 deletions

View File

@@ -109,18 +109,20 @@ enum wxPenCap
calls to its clearly named methods instead of passing them in the fixed
order to wxPen constructors.
For instance, to create a blue pen with a width of 0:
For instance, to create a dotted blue pen with the given join style you
could do
@code
wxPen pen(wxPenInfo(*wxBLUE, 0));
wxPen pen(wxPenInfo(*wxBLUE).Style(wxPENSTYLE_DOT).Join(wxJOIN_BEVEL));
@endcode
@since 3.1.1
*/
class wxPenInfo : public wxPenInfoBase<wxPenInfo>
class wxPenInfo
{
public:
explicit wxPenInfo(const wxColour& colour = wxColour(), int width = 1, wxPenStyle style = wxPENSTYLE_SOLID);
explicit wxPenInfo(const wxColour& colour = wxColour(),
int width = 1,
wxPenStyle style = wxPENSTYLE_SOLID);
wxPenInfo& Colour(const wxColour& col);