 
       wx.richtext.RichTextPrintout¶
  wx.richtext.RichTextPrintout¶This class implements print layout for wx.richtext.RichTextBuffer.
Instead of using it directly, you should normally use the wx.richtext.RichTextPrinting class.
 Methods Summary¶
 Methods Summary¶| __init__ | Constructor. | 
| CalculateScaling | Calculates scaling and text, header and footer rectangles. | 
| GetHeaderFooterData | Returns the header and footer data associated with the printout. | 
| GetPageInfo | Gets the page information. | 
| GetRichTextBuffer | Returns a pointer to the buffer being rendered. | 
| HasPage | Returns Trueif the given page exists in the printout. | 
| OnPreparePrinting | Prepares for printing, laying out the buffer and calculating pagination. | 
| OnPrintPage | Does the actual printing for this page. | 
| SetHeaderFooterData | Sets the header and footer data associated with the printout. | 
| SetMargins | Sets margins in 10ths of millimetre. | 
| SetRichTextBuffer | Sets the buffer to print. | 
 Properties Summary¶
 Properties Summary¶| HeaderFooterData | See GetHeaderFooterDataandSetHeaderFooterData | 
| RichTextBuffer | See GetRichTextBufferandSetRichTextBuffer | 
 Class API¶
 Class API¶wx.richtext.RichTextPrintout(Printout)¶Possible constructors:
RichTextPrintout(title="Printout")
This class implements print layout for RichTextBuffer.
__init__(self, title="Printout")¶Constructor.
| Parameters: | title (string) – | 
|---|
CalculateScaling(self, dc, textRect, headerRect, footerRect)¶Calculates scaling and text, header and footer rectangles.
| Parameters: | 
|---|
Returns the header and footer data associated with the printout.
| Return type: | wx.richtext.RichTextHeaderFooterData | 
|---|
GetPageInfo(self)¶Gets the page information.
| Return type: | tuple | 
|---|---|
| Returns: | ( minPage, maxPage, selPageFrom, selPageTo ) | 
GetRichTextBuffer(self)¶Returns a pointer to the buffer being rendered.
| Return type: | wx.richtext.RichTextBuffer | 
|---|
HasPage(self, page)¶Returns True if the given page exists in the printout.
| Parameters: | page (int) – | 
|---|---|
| Return type: | bool | 
OnPreparePrinting(self)¶Prepares for printing, laying out the buffer and calculating pagination.
OnPrintPage(self, page)¶Does the actual printing for this page.
| Parameters: | page (int) – | 
|---|---|
| Return type: | bool | 
Sets the header and footer data associated with the printout.
| Parameters: | data (wx.richtext.RichTextHeaderFooterData) – | 
|---|
SetMargins(self, top=254, bottom=254, left=254, right=254)¶Sets margins in 10ths of millimetre.
Defaults to 1 inch for margins.
| Parameters: | 
 | 
|---|
SetRichTextBuffer(self, buffer)¶Sets the buffer to print.
wx.richtext.RichTextPrintout does not manage this pointer; it should be managed by the calling code, such as wx.richtext.RichTextPrinting.
| Parameters: | buffer (wx.richtext.RichTextBuffer) – | 
|---|
RichTextBuffer¶See GetRichTextBuffer and SetRichTextBuffer