]>
git.saurik.com Git - wxWidgets.git/blob - interface/wx/html/htmlfilt.h
d407a857ba8552180bd61922d4421bb22130b1e9
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: html/htmlfilt.h
3 // Purpose: interface of wxHtmlFilter
4 // Author: wxWidgets team
6 // Licence: wxWindows licence
7 /////////////////////////////////////////////////////////////////////////////
12 This class is the parent class of input filters for wxHtmlWindow.
13 It allows you to read and display files of different file formats.
18 @see @ref overview_html_filters
20 class wxHtmlFilter
: public wxObject
29 Returns @true if this filter is capable of reading file @e file.
32 bool MyFilter::CanRead(const wxFSFile& file)
34 return (file.GetMimeType() == "application/x-ugh");
38 virtual bool CanRead(const wxFSFile
& file
) const = 0;
41 Reads the file and returns string with HTML document.
44 wxString MyImgFilter::ReadFile(const wxFSFile& file)
46 return "<html><body><img src=\"" + file.GetLocation() +
51 virtual wxString
ReadFile(const wxFSFile
& file
) const = 0;