wxRuby Documentation Home
Wx::HtmlPrintout
This class serves as printout class for HTML documents.
Derived from
Printout
HtmlPrintout.new
HtmlPrintout.new(%(arg-type)String% title = “Printout”)
Constructor.
HtmlPrintout#add_filter
add_filter(%(arg-type)HtmlFilter% filter)
Adds a filter to the static list of filters for HtmlPrintout. See HtmlFilter for
further information.
HtmlPrintout#set_fonts
set_fonts(%(arg-type)String% normal_face, String fixed_face,
Integer sizes = nil)
Sets fonts. See HtmlWindow#set_fonts for
detailed description.
set_footer(%(arg-type)String% footer, Integer pg = PAGE_ALL)
Sets page footer.
Parameters
- footer HTML text to be used as footer. You can use macros in it:
PAGENUM
is replaced by page number
PAGESCNT
is replaced by total number of pages
- pg one of PAGE_ODD, PAGE_EVEN and PAGE_ALL constants.
set_header(%(arg-type)String% header, Integer pg = PAGE_ALL)
Sets page header.
Parameters
- header HTML text to be used as header. You can use macros in it:
PAGENUM
is replaced by page number
PAGESCNT
is replaced by total number of pages
- pg one of PAGE_ODD, PAGE_EVEN and PAGE_ALL constants.
HtmlPrintout#set_html_file
set_html_file(%(arg-type)String% htmlfile)
Prepare the class for printing this HTML file. The file may be located on
any virtual file system or it may be normal file.
HtmlPrintout#set_html_text
set_html_text(%(arg-type)String% html, String basepath = ’’,
Boolean isdir = true)
Prepare the class for printing this HTML text.
Parameters
- html HTML text. (NOT file!)
- basepath base directory (html string would be stored there if it was in
file). It is used to determine path for loading images, for example.
- isdir false if basepath is filename, true if it is directory name
(see FileSystem for detailed explanation)
HtmlPrintout#set_margins
set_margins(%(arg-type)Float% top = 25.2, Float bottom = 25.2,
Float left = 25.2,
Float right = 25.2,
Float spaces = 5)
Sets margins in millimeters. Defaults to 1 inch for margins and 0.5cm for space
between text and header and/or footer
[This page automatically generated from the Textile source at 2023-06-13 21:31:42 +0000]