X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/6953da00886c52a9e1d9183e1f1f27e75843cfa4..c21f7aa162dfc4ff910c67a9d6241557dab96075:/include/wx/html/htmlpars.h?ds=sidebyside
diff --git a/include/wx/html/htmlpars.h b/include/wx/html/htmlpars.h
index d0392418b2..7a7951b3e8 100644
--- a/include/wx/html/htmlpars.h
+++ b/include/wx/html/htmlpars.h
@@ -7,14 +7,9 @@
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
-
#ifndef _WX_HTMLPARS_H_
#define _WX_HTMLPARS_H_
-#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
-#pragma interface "htmlpars.h"
-#endif
-
#include "wx/defs.h"
#if wxUSE_HTML
@@ -104,7 +99,7 @@ public:
// handler can handle only 'myitems' (e.g. it's GetSupportedTags returns "MYITEMS")
// you can call PushTagHandler(handler, "IT") when you find
// and call PopTagHandler() when you find
- void PushTagHandler(wxHtmlTagHandler *handler, wxString tags);
+ void PushTagHandler(wxHtmlTagHandler *handler, const wxString& tags);
// Restores state before last call to PushTagHandler
void PopTagHandler();
@@ -121,6 +116,10 @@ public:
// empty
virtual bool RestoreState();
+ // Returns HTML source inside the element (i.e. between the starting
+ // and ending tag)
+ wxString GetInnerSource(const wxHtmlTag& tag);
+
// Parses HTML string 'markup' and extracts charset info from tag
// if present. Returns empty string if the tag is missing.
// For wxHTML's internal use.
@@ -229,6 +228,12 @@ protected:
void ParseInner(const wxHtmlTag& tag)
{ m_Parser->DoParsing(tag.GetBeginPos(), tag.GetEndPos1()); }
+ // Parses given source as if it was tag's inner code (see
+ // wxHtmlParser::GetInnerSource). Unlike ParseInner(), this method lets
+ // you specify the source code to parse. This is useful when you need to
+ // modify the inner text before parsing.
+ void ParseInnerSource(const wxString& source);
+
wxHtmlParser *m_Parser;
DECLARE_NO_COPY_CLASS(wxHtmlTagHandler)