X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/5bddd46dde044ccb04952e027b4ec27bb1251bba..92c0fc34c104c8d7c12d6a3b78ea232690fc23f4:/interface/wx/html/htmltag.h diff --git a/interface/wx/html/htmltag.h b/interface/wx/html/htmltag.h index e5ef38cb44..6f88e3b00b 100644 --- a/interface/wx/html/htmltag.h +++ b/interface/wx/html/htmltag.h @@ -2,8 +2,7 @@ // Name: html/htmltag.h // Purpose: interface of wxHtmlTag // Author: wxWidgets team -// RCS-ID: $Id$ -// Licence: wxWindows license +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// /** @@ -33,7 +32,7 @@ public: Example: tag contains \. Call to tag.GetAllParams() would return @c 'SIZE=+2 COLOR="#000000"'. */ - const wxString GetAllParams() const; + wxString GetAllParams() const; /** Returns beginning position of the text @e between this tag and paired @@ -73,7 +72,7 @@ public: /** Returns tag's name. The name is always in uppercase and it doesn't contain - " or '/' characters. (So the name of \ tag is "FONT" + " or '/' characters. (So the name of \ tag is "FONT" and name of \ is "TABLE"). */ wxString GetName() const; @@ -108,6 +107,8 @@ public: Returns @true on success and @false if @a par is not colour specification or if the tag has no such parameter. + + @see ParseAsColour() */ bool GetParamAsColour(const wxString& par, wxColour* clr) const; @@ -148,6 +149,22 @@ public: */ bool HasParam(const wxString& par) const; + /** + Parses the given string as an HTML colour. + + This function recognizes the standard named HTML 4 colours as well as + the usual RGB syntax. + + @since 2.9.1 + + @see wxColour::Set() + + @return @true if the string was successfully parsed and @a clr was + filled with the result or @false otherwise. + */ + static bool ParseAsColour(const wxString& str, wxColour *clr); + + //@{ /** 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 +178,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; + //@} };