.. wxPython Phoenix documentation

   This file was generated by Phoenix's sphinx generator and associated
   tools, do not edit by hand.

   Copyright: (c) 2011-2017 by Total Control Software
   License:   wxWindows License

.. include:: headings.inc



.. _wx.PreviewCanvas:

==========================================================================================================================================
|phoenix_title|  **wx.PreviewCanvas**
==========================================================================================================================================

A preview canvas is the default canvas used by the print preview system to display the preview.          







         



.. seealso:: :ref:`wx.PreviewFrame`, :ref:`wx.PreviewControlBar`, :ref:`wx.PrintPreview`    







|

|class_hierarchy| Class Hierarchy
=================================

.. raw:: html

   <div id="toggleBlock" onclick="return toggleVisibility(this)" class="closed" style="cursor:pointer;">
   <img id="toggleBlock-trigger" src="_static/images/closed.png"/>
   Inheritance diagram for class <strong>PreviewCanvas</strong>:
   </div>
   <div id="toggleBlock-summary" style="display:block;"></div>
   <div id="toggleBlock-content" style="display:none;">
   <p class="graphviz">
   <center><img src="_static/images/inheritance/wx.PreviewCanvas_inheritance.png" alt="Inheritance diagram of PreviewCanvas" usemap="#dummy" class="inheritance"/></center>
   </div>
   <script type="text/javascript">toggleVisibilityOnLoad(document.getElementById('toggleBlock'))</script>
   <map id="dummy" name="dummy"> <area shape="rect" id="node1" href="wx.PreviewCanvas.html" title="wx.PreviewCanvas" alt="" coords="13,179,149,208"/> <area shape="rect" id="node2" href="Scrolled&lt; wxPanel &gt;.html" title="Scrolled&lt; wxPanel &gt;" alt="" coords="5,101,157,131"/> </map> 
   </p>

|


|method_summary| Methods Summary
================================

================================================================================ ================================================================================
:meth:`~wx.PreviewCanvas.__init__`                                               Constructor.
:meth:`~wx.PreviewCanvas.OnPaint`                                                Calls :meth:`wx.PrintPreview.PaintPage`   to refresh the canvas.
================================================================================ ================================================================================


|


|api| Class API
===============


.. class:: wx.PreviewCanvas(ScrolledWindow)

   **Possible constructors**::

       PreviewCanvas(preview, parent, pos=DefaultPosition, size=DefaultSize,
                     style=0, name="canvas")
       
   
   A preview canvas is the default canvas used by the print preview
   system to display the preview.



   .. method:: __init__(self, preview, parent, pos=DefaultPosition, size=DefaultSize, style=0, name="canvas")

      Constructor.                  


      :param `preview`: 
      :type `preview`: wx.PrintPreview
      :param `parent`: 
      :type `parent`: wx.Window
      :param `pos`: 
      :type `pos`: wx.Point
      :param `size`: 
      :type `size`: wx.Size
      :param `style`: 
      :type `style`: long
      :param `name`: 
      :type `name`: string







   .. method:: OnPaint(self, event)

      Calls :meth:`wx.PrintPreview.PaintPage`   to refresh the canvas.                  


      :param `event`: 
      :type `event`: wx.PaintEvent






