From a44f3b5a890fbb2a88ef9adafd94f662e1664889 Mon Sep 17 00:00:00 2001 From: Francesco Montorsi Date: Sun, 9 Nov 2008 16:46:52 +0000 Subject: [PATCH] ifacecheck manual fixes git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@56720 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- interface/wx/dirctrl.h | 3 ++- interface/wx/event.h | 30 ++++++++++++++++++++---------- interface/wx/filectrl.h | 4 ++-- interface/wx/filedlg.h | 10 +++++----- interface/wx/filename.h | 7 +++++-- interface/wx/filepicker.h | 8 ++++---- interface/wx/font.h | 13 ++++++------- interface/wx/fontpicker.h | 2 +- interface/wx/frame.h | 2 +- interface/wx/gauge.h | 2 +- interface/wx/glcanvas.h | 2 +- interface/wx/graphics.h | 34 +++++++++++++++++----------------- interface/wx/grid.h | 2 +- interface/wx/hash.h | 2 +- interface/wx/html/helpctrl.h | 8 ++++---- interface/wx/html/helpfrm.h | 4 +++- interface/wx/html/htmlpars.h | 2 +- interface/wx/html/htmltag.h | 5 ++++- interface/wx/html/htmlwin.h | 6 +++--- interface/wx/html/htmprint.h | 2 +- interface/wx/icon.h | 19 ++++--------------- interface/wx/iconbndl.h | 2 +- interface/wx/log.h | 12 +++++++++--- interface/wx/window.h | 6 +++--- 24 files changed, 100 insertions(+), 87 deletions(-) diff --git a/interface/wx/dirctrl.h b/interface/wx/dirctrl.h index 60910dbbbc..09067ef001 100644 --- a/interface/wx/dirctrl.h +++ b/interface/wx/dirctrl.h @@ -38,6 +38,7 @@ public: Default constructor. */ wxGenericDirCtrl(); + /** Main constructor. @@ -63,7 +64,7 @@ public: @param name The window name. */ - wxGenericDirCtrl(wxWindow* parent, const wxWindowID id = -1, + wxGenericDirCtrl(wxWindow* parent, const wxWindowID id = wxID_ANY, const wxString& dir = wxDirDialogDefaultFolderStr, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, diff --git a/interface/wx/event.h b/interface/wx/event.h index 9b35297a12..22e06d8fe6 100644 --- a/interface/wx/event.h +++ b/interface/wx/event.h @@ -417,8 +417,8 @@ public: @param eventSink Object whose member function should be called. */ - bool Disconnect(wxEventType eventType = wxEVT_NULL, - wxObjectEventFunction function = NULL, + bool Disconnect(wxEventType eventType, + wxObjectEventFunction function, wxObject* userData = NULL, wxEvtHandler* eventSink = NULL); @@ -440,8 +440,8 @@ public: This overload takes an additional range of source IDs. */ - bool Disconnect(int id, int lastId = wxID_ANY, - wxEventType eventType = wxEVT_NULL, + bool Disconnect(int id, int lastId, + wxEventType eventType, wxObjectEventFunction function = NULL, wxObject* userData = NULL, wxEvtHandler* eventSink = NULL); @@ -2333,13 +2333,10 @@ public: -/** - Indicates how a wxHelpEvent was generated. -*/ enum wxHelpEventOrigin { - wxHE_ORIGIN_UNKNOWN = -1, /**< unrecognized event source. */ - wxHE_ORIGIN_KEYBOARD, /**< event generated from F1 key press. */ + wxHE_ORIGIN_UNKNOWN = -1, + wxHE_ORIGIN_KEYBOARD, /** event generated by wxContextHelp or from the [?] button on the title bar (Windows). */ @@ -2382,13 +2379,26 @@ enum wxHelpEventOrigin class wxHelpEvent : public wxCommandEvent { public: + /** + Indicates how a wxHelpEvent was generated. + */ + enum Origin + { + Origin_Unknown, /**< unrecognized event source. */ + Origin_Keyboard, /**< event generated from F1 key press. */ + + /** event generated by wxContextHelp or from the [?] button on + the title bar (Windows). */ + Origin_HelpButton + }; + /** Constructor. */ wxHelpEvent(wxEventType type = wxEVT_NULL, wxWindowID winid = 0, const wxPoint& pt = wxDefaultPosition, - wxHelpEventOrigin origin = wxHE_ORIGIN_UNKNOWN); + wxHelpEvent::Origin origin = Origin_Unknown); /** Returns the origin of the help event which is one of the ::wxHelpEventOrigin diff --git a/interface/wx/filectrl.h b/interface/wx/filectrl.h index 72149989d5..a802d5b771 100644 --- a/interface/wx/filectrl.h +++ b/interface/wx/filectrl.h @@ -88,7 +88,7 @@ public: long style = wxFC_DEFAULT_STYLE, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, - const wxString& name = "filectrl"); + const wxString& name = wxFileCtrlNameStr); /** Create function for two-step construction. See wxFileCtrl() for details. @@ -206,7 +206,7 @@ public: /** Constructor. */ - wxFileCtrlEvent(wxEventType type, wxObject evtObject, int id); + wxFileCtrlEvent(wxEventType type, wxObject *evtObject, int id); /** Returns the current directory. diff --git a/interface/wx/filedlg.h b/interface/wx/filedlg.h index a3851926db..1ff73a0603 100644 --- a/interface/wx/filedlg.h +++ b/interface/wx/filedlg.h @@ -90,14 +90,14 @@ public: Dialog name. Not implemented. */ wxFileDialog(wxWindow* parent, - const wxString& message = "Choose a file", - const wxString& defaultDir = "", - const wxString& defaultFile = "", - const wxString& wildcard = ".", + const wxString& message = wxFileSelectorPromptStr, + const wxString& defaultDir = wxEmptyString, + const wxString& defaultFile = wxEmptyString, + const wxString& wildcard = wxFileSelectorDefaultWildcardStr, long style = wxFD_DEFAULT_STYLE, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, - const wxString& name = "filedlg"); + const wxString& name = wxFileDialogNameStr); /** Destructor. diff --git a/interface/wx/filename.h b/interface/wx/filename.h index 2310985da8..4917fecce9 100644 --- a/interface/wx/filename.h +++ b/interface/wx/filename.h @@ -334,14 +334,17 @@ public: */ void AssignHomeDir(); + //@{ /** The function calls CreateTempFileName() to create a temporary file and sets this object to the name of the file. + If a temporary file couldn't be created, the object is put into an invalid state (see IsOk()) */ - void AssignTempFileName(const wxString& prefix, - wxFile* fileTemp = NULL); + void AssignTempFileName(const wxString& prefix, wxFile* fileTemp); + void AssignTempFileName(const wxString& prefix, wxFFile* fileTemp); + //@} /** Reset all components to default, uninitialized state. diff --git a/interface/wx/filepicker.h b/interface/wx/filepicker.h index f3a46de190..aed89f0067 100644 --- a/interface/wx/filepicker.h +++ b/interface/wx/filepicker.h @@ -63,13 +63,13 @@ public: */ wxFilePickerCtrl(wxWindow* parent, wxWindowID id, const wxString& path = wxEmptyString, - const wxString& message = "Select a file", - const wxString& wildcard = ".", + const wxString& message = wxFileSelectorPromptStr, + const wxString& wildcard = wxFileSelectorDefaultWildcardStr, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = wxFLP_DEFAULT_STYLE, const wxValidator& validator = wxDefaultValidator, - const wxString& name = "filepickerctrl"); + const wxString& name = wxFilePickerCtrlNameStr); /** Creates this widget with the given parameters. @@ -282,7 +282,7 @@ public: */ wxFileDirPickerEvent(wxEventType type, wxObject* generator, int id, - const wxString path); + const wxString& path); /** Retrieve the absolute path of the file/directory the user has just selected. diff --git a/interface/wx/font.h b/interface/wx/font.h index 3ffd7e94c3..a008843ba7 100644 --- a/interface/wx/font.h +++ b/interface/wx/font.h @@ -529,7 +529,7 @@ public: @see GetFamily(), SetFaceName() */ - void SetFamily(wxFontFamily family); + virtual void SetFamily(wxFontFamily family); /** Creates the font corresponding to the given native font description string @@ -586,7 +586,7 @@ public: @see GetStyle() */ - void SetStyle(wxFontStyle style); + virtual void SetStyle(wxFontStyle style); /** Sets underlining. @@ -606,7 +606,7 @@ public: @see GetWeight() */ - void SetWeight(wxFontWeight weight); + virtual void SetWeight(wxFontWeight weight); /** Inequality operator. @@ -692,10 +692,9 @@ public: Finds a font of the given specification, or creates one and adds it to the list. See the @ref wxFont "wxFont constructor" for details of the arguments. */ - wxFont* FindOrCreateFont(int point_size, int family, int style, - int weight, - bool underline = false, - const wxString& facename = NULL, + wxFont* FindOrCreateFont(int point_size, wxFontFamily family, wxFontStyle style, + wxFontWeight weight, bool underline = false, + const wxString& facename = wxEmptyString, wxFontEncoding encoding = wxFONTENCODING_DEFAULT); }; diff --git a/interface/wx/fontpicker.h b/interface/wx/fontpicker.h index 6c37b1703c..33497c5bf1 100644 --- a/interface/wx/fontpicker.h +++ b/interface/wx/fontpicker.h @@ -59,7 +59,7 @@ public: const wxSize& size = wxDefaultSize, long style = wxFNTP_DEFAULT_STYLE, const wxValidator& validator = wxDefaultValidator, - const wxString& name = "fontpickerctrl"); + const wxString& name = wxFontPickerCtrlNameStr); /** Creates this widget with given parameters. diff --git a/interface/wx/frame.h b/interface/wx/frame.h index 78ea432f42..84a81d2ebb 100644 --- a/interface/wx/frame.h +++ b/interface/wx/frame.h @@ -332,7 +332,7 @@ public: @param id The identifier for a menu item. */ - void ProcessCommand(int id); + bool ProcessCommand(int id); /** Tells the frame to show the given menu bar. diff --git a/interface/wx/gauge.h b/interface/wx/gauge.h index a36e7a444a..52ed8be8a5 100644 --- a/interface/wx/gauge.h +++ b/interface/wx/gauge.h @@ -74,7 +74,7 @@ public: const wxSize& size = wxDefaultSize, long style = wxGA_HORIZONTAL, const wxValidator& validator = wxDefaultValidator, - const wxString& name = "gauge"); + const wxString& name = wxGaugeNameStr); /** Destructor, destroying the gauge. diff --git a/interface/wx/glcanvas.h b/interface/wx/glcanvas.h index 887e55d76d..9f0ab531f0 100644 --- a/interface/wx/glcanvas.h +++ b/interface/wx/glcanvas.h @@ -261,7 +261,7 @@ public: @return @false if an error occurred. */ - bool SetCurrent(const wxGLContext context); + bool SetCurrent(const wxGLContext& context) const; /** Swaps the double-buffer of this window, making the back-buffer the diff --git a/interface/wx/graphics.h b/interface/wx/graphics.h index 190aed1da3..f9427a950f 100644 --- a/interface/wx/graphics.h +++ b/interface/wx/graphics.h @@ -53,9 +53,9 @@ public: Adds a cubic bezier curve from the current point, using two control points and an end point. */ - void AddCurveToPoint(wxDouble cx1, wxDouble cy1, - wxDouble cx2, wxDouble cy2, - wxDouble x, wxDouble y); + virtual void AddCurveToPoint(wxDouble cx1, wxDouble cy1, + wxDouble cx2, wxDouble cy2, + wxDouble x, wxDouble y); /** Adds a cubic bezier curve from the current point, using two control points and an end point. @@ -319,12 +319,12 @@ public: Creates a native brush, having a linear gradient, starting at (x1,y1) with color c1 to (x2,y2) with color c2 */ - wxGraphicsBrush CreateLinearGradientBrush(wxDouble x1, - wxDouble y1, - wxDouble x2, - wxDouble y2, - const wxColouramp;c1, - const wxColouramp;c2) const; + virtual wxGraphicsBrush CreateLinearGradientBrush(wxDouble x1, + wxDouble y1, + wxDouble x2, + wxDouble y2, + const wxColour& c1, + const wxColour& c2) const; /** Creates a native affine transformation matrix from the passed in values. The @@ -332,8 +332,8 @@ public: */ virtual wxGraphicsMatrix CreateMatrix(wxDouble a = 1.0, wxDouble b = 0.0, wxDouble c = 0.0, wxDouble d = 1.0, - wxDouble tx = 0.0, - wxDouble ty = 0.0) const; + wxDouble tx = 0.0, + wxDouble ty = 0.0) const; /** Creates a native graphics path which is initially empty. @@ -585,11 +585,11 @@ public: color c1 to (x2,y2) with color c2 */ wxGraphicsBrush CreateLinearGradientBrush(wxDouble x1, - wxDouble y1, - wxDouble x2, - wxDouble y2, - const wxColouramp;c1, - const wxColouramp;c2); + wxDouble y1, + wxDouble x2, + wxDouble y2, + const wxColour& c1, + const wxColour& c2) = 0; /** Creates a native affine transformation matrix from the passed in values. The @@ -597,7 +597,7 @@ public: */ virtual wxGraphicsMatrix CreateMatrix(wxDouble a = 1.0, wxDouble b = 0.0, wxDouble c = 0.0, wxDouble d = 1.0, - wxDouble tx = 0.0, + wxDouble tx = 0.0, wxDouble ty = 0.0) = 0; /** diff --git a/interface/wx/grid.h b/interface/wx/grid.h index 2d400ab0f2..3777a22a1e 100644 --- a/interface/wx/grid.h +++ b/interface/wx/grid.h @@ -1680,7 +1680,7 @@ public: /** Overridden wxWindow method. */ - void Fit(); + virtual void Fit(); /** Causes immediate repainting of the grid. diff --git a/interface/wx/hash.h b/interface/wx/hash.h index b14e32f539..200314dd92 100644 --- a/interface/wx/hash.h +++ b/interface/wx/hash.h @@ -54,7 +54,7 @@ public: Constructor. @a key_type is one of wxKEY_INTEGER, or wxKEY_STRING, and indicates what sort of keying is required. @a size is optional. */ - wxHashTable(unsigned int key_type, int size = 1000); + wxHashTable(wxKeyType key_type = wxKEY_INTEGER, size_t size = 1000); /** Destroys the hash table. diff --git a/interface/wx/html/helpctrl.h b/interface/wx/html/helpctrl.h index 83dc2b5127..3b0803bf0d 100644 --- a/interface/wx/html/helpctrl.h +++ b/interface/wx/html/helpctrl.h @@ -101,7 +101,7 @@ public: @param showWaitMsg If @true then a decoration-less window with progress message is displayed. */ - bool AddBook(const wxFileName& bookFile, bool showWaitMsg); + bool AddBook(const wxFileName& bookFile, bool showWaitMsg = false); /** Adds a book (i.e. a @ref overview_html_helpformats ".hhp file"; an HTML Help @@ -115,7 +115,7 @@ public: @param showWaitMsg If @true then a decoration-less window with progress message is displayed. */ - bool AddBook(const wxString& bookUrl, bool showWaitMsg); + bool AddBook(const wxString& bookUrl, bool showWaitMsg = false); /** Displays page @a x. @@ -133,14 +133,14 @@ public: -# try to find x in index (if x is for example "How To ...") -# switch to Search panel and start searching */ - void Display(const wxString& x); + bool Display(const wxString& x); /** @overload This alternative form is used to search help contents by numeric IDs. */ - void Display(const int id); + bool Display(int id); /** Displays help window and focuses contents panel. diff --git a/interface/wx/html/helpfrm.h b/interface/wx/html/helpfrm.h index a53c0ef7f6..68153b12b2 100644 --- a/interface/wx/html/helpfrm.h +++ b/interface/wx/html/helpfrm.h @@ -29,7 +29,9 @@ public: wxHtmlHelpFrame(wxWindow* parent, int wxWindowID, const wxString& title = wxEmptyString, int style = wxHF_DEFAULT_STYLE, - wxHtmlHelpData* data = NULL); + wxHtmlHelpData* data = NULL, + wxConfigBase* config = NULL, + const wxString& rootpath = wxEmptyString); /** You may override this virtual method to add more buttons to the help window's diff --git a/interface/wx/html/htmlpars.h b/interface/wx/html/htmlpars.h index 20ff8e07d4..82dfb28c49 100644 --- a/interface/wx/html/htmlpars.h +++ b/interface/wx/html/htmlpars.h @@ -139,7 +139,7 @@ public: /** Parses the m_Source from @a begin_pos to @a end_pos - 1. */ - void DoParsing(int begin_pos, int end_pos); + void DoParsing(const const_iterator& begin_pos, const const_iterator& end_pos); /** Parses the whole m_Source. diff --git a/interface/wx/html/htmltag.h b/interface/wx/html/htmltag.h index 903d23ff3a..10136ab202 100644 --- a/interface/wx/html/htmltag.h +++ b/interface/wx/html/htmltag.h @@ -148,6 +148,7 @@ public: */ bool HasParam(const wxString& par) const; + //@{ /** This method scans the given parameter. Usage is exactly the same as sscanf's usage except that you don't pass a string but a parameter name as the first @@ -161,6 +162,8 @@ public: @param value pointer to a variable to store the value in */ - wxString ScanParam(const wxString& par, const wxChar* format, void* value) const; + int ScanParam(const wxString& par, const wchar_t* format, void* value) const; + int ScanParam(const wxString& par, const char* format, void* value) const; + //@} }; diff --git a/interface/wx/html/htmlwin.h b/interface/wx/html/htmlwin.h index 2aa8bb3c9e..ecadb27cfc 100644 --- a/interface/wx/html/htmlwin.h +++ b/interface/wx/html/htmlwin.h @@ -61,12 +61,11 @@ public: Constructor. The parameters are the same as wxScrolled::wxScrolled() constructor. */ - wxHtmlWindow(wxWindow parent, wxWindowID id = -1, + wxHtmlWindow(wxWindow *parent, wxWindowID id = wxID_ANY, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = wxHW_DEFAULT_STYLE, const wxString& name = "htmlWindow"); - //@} /** Adds @ref overview_html_filters "input filter" to the static list of available @@ -464,7 +463,8 @@ public: */ wxHtmlCellEvent(wxEventType commandType, int id, wxHtmlCell* cell, - const wxPoint& point); + const wxPoint& point, + const wxMouseEvent& ev); /** Returns the wxHtmlCellEvent associated with the event. diff --git a/interface/wx/html/htmprint.h b/interface/wx/html/htmprint.h index 3cf0281c07..268189df7e 100644 --- a/interface/wx/html/htmprint.h +++ b/interface/wx/html/htmprint.h @@ -59,7 +59,7 @@ public: Render() changes the DC's user scale and does NOT restore it. */ int Render(int x, int y, wxArrayInt& known_pagebreaks, int from = 0, - int dont_render = 0, int to = INT_MAX); + int dont_render = false, int to = INT_MAX); /** Assign DC instance to the renderer. diff --git a/interface/wx/icon.h b/interface/wx/icon.h index 3f5e9dcf25..bab04d6e6d 100644 --- a/interface/wx/icon.h +++ b/interface/wx/icon.h @@ -90,24 +90,13 @@ public: @param bits Specifies an array of pixel values. @param width - Specifies the width of the bitmap. + The width of the image. @param height - Specifies the height of the bitmap. - @param depth - Specifies the depth of the bitmap. - If this is omitted, then a value of 1 (monochrome bitmap) is used. - */ - wxIcon(const char bits[], int width, int height, int depth = 1); - - - /** - Creates a new icon. A depth of ::wxICON_SCREEN_DEPTH indicates the - depth of the current screen or visual. + The height of the image. - Some platforms only support 1 for monochrome and ::wxICON_SCREEN_DEPTH for - the current colour setting. + @onlyfor{wxmsw,wxmac} */ - wxIcon(int width, int height, int depth = wxICON_SCREEN_DEPTH); + wxIcon(const char bits[], int width, int height); /** Creates a bitmap from XPM data. diff --git a/interface/wx/iconbndl.h b/interface/wx/iconbndl.h index 0b4335242a..9e35cc0dde 100644 --- a/interface/wx/iconbndl.h +++ b/interface/wx/iconbndl.h @@ -73,7 +73,7 @@ public: /** Same as @code GetIcon( wxSize( size, size ) ) @endcode. */ - const wxIcon GetIcon(wxCoord size = -1) const; + wxIcon GetIcon(wxCoord size = wxDefaultCoord) const; /** Returns the icon with exactly the given size or ::wxNullIcon if this diff --git a/interface/wx/log.h b/interface/wx/log.h index 0f874d9da4..ef8b2a9d83 100644 --- a/interface/wx/log.h +++ b/interface/wx/log.h @@ -405,8 +405,10 @@ public: @class wxLogStderr This class can be used to redirect the log messages to a C file stream (not to - be confused with C++ streams). It is the default log target for the non-GUI - wxWidgets applications which send all the output to @c stderr. + be confused with C++ streams). + + It is the default log target for the non-GUI wxWidgets applications which + send all the output to @c stderr. @library{wxbase} @category{logging} @@ -527,6 +529,9 @@ public: Otherwise, it is completely hidden behind the @e wxLogXXX() functions and you may not even know about its existence. + @note For console-mode applications, the default target is wxLogStderr, so + that all @e wxLogXXX() functions print on @c stderr when @c wxUSE_GUI = 0. + @section log_derivingyours Deriving your own log target @@ -627,7 +632,8 @@ public: @li SetRepetitionCounting() @li GetRepetitionCounting() - @note Timestamping is disabled for Visual C++ users in debug builds by + @note + Timestamping is disabled for Visual C++ users in debug builds by default because otherwise it would be impossible to directly go to the line from which the log message was generated by simply clicking in the debugger window on the corresponding error message. If you wish to enable it, please diff --git a/interface/wx/window.h b/interface/wx/window.h index ade519c6fb..bc0f7c33f5 100644 --- a/interface/wx/window.h +++ b/interface/wx/window.h @@ -1435,9 +1435,9 @@ public: only redrawing those areas, which have been exposed. */ bool IsExposed(int x, int y) const; - const bool IsExposed(wxPoint amp;pt) const; - const bool IsExposed(int x, int y, int w, int h) const; - const bool IsExposed(wxRect amp;rect) const; + bool IsExposed(wxPoint& pt) const; + bool IsExposed(int x, int y, int w, int h) const; + bool IsExposed(wxRect& rect) const; //@} /** -- 2.45.2