.. wxPython Phoenix documentation This file was generated by Phoenix's sphinx generator and associated tools, do not edit by hand. Copyright: (c) 2011-2018 by Total Control Software License: wxWindows License .. include:: headings.inc .. currentmodule:: wx.lib.agw.xlsgrid .. highlight:: python .. _wx.lib.agw.xlsgrid.XLSBackground: ========================================================================================================================================== |phoenix_title| **wx.lib.agw.xlsgrid.XLSBackground** ========================================================================================================================================== This is a class which holds information about the cell background, in terms of background colour and background pattern (hatching). | |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>XLSBackground</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.lib.agw.xlsgrid.XLSBackground_inheritance.png" alt="Inheritance diagram of XLSBackground" usemap="#dummy" class="inheritance"/></center> <script type="text/javascript">toggleVisibilityOnLoad(document.getElementById('toggleBlock'))</script> <map id="dummy" name="dummy"> <area shape="rect" id="node1" href="wx.lib.agw.xlsgrid.XLSBackground.html" title="This is a class which holds information about the cell background, in terms" alt="" coords="5,5,256,35"/> </map> </p> </div> | |method_summary| Methods Summary ================================ ================================================================================ ================================================================================ :meth:`~wx.lib.agw.xlsgrid.XLSBackground.__init__` Default class constructor. :meth:`~wx.lib.agw.xlsgrid.XLSBackground.CombineAttr` Combines the input attribute `attr` with the features of the :class:`XLSBackground` class. :meth:`~wx.lib.agw.xlsgrid.XLSBackground.CreateBackgroundColour` Creates a suitable wxPython colour for the cell background starting from :meth:`~wx.lib.agw.xlsgrid.XLSBackground.Draw` Actually draws the cell background and pattern hatching on a grid cell. ================================================================================ ================================================================================ | |api| Class API =============== .. class:: XLSBackground(object) This is a class which holds information about the cell background, in terms of background colour and background pattern (hatching). .. method:: __init__(self, book, xf_index) Default class constructor. :param `book`: an instance of the `xlrd.Book` class; :param `xf_index`: an index into `xlrd.Book.xf_list`, which holds a reference to the `xlrd.sheet.Cell` class (the actual cell for `xlrd`). .. method:: CombineAttr(self, attr) Combines the input attribute `attr` with the features of the :class:`XLSBackground` class. :param `attr`: an instance of :class:`grid.GridCellAttr`. .. method:: CreateBackgroundColour(self, background_colour, pattern_colour, fill_pattern) Creates a suitable wxPython colour for the cell background starting from a `xlrd` tuple representing this colour. :param `background_colour`: a tuple representing the RGB components of the cell background colour. If `background_colour` is ``None``, use the default ``wx.SYS_COLOUR_WINDOW``; :param `pattern_colour`: a tuple representing the RGB components of the cell pattern colour; :param `fill_pattern`: the pattern to use to draw hatches on top of the background. .. method:: Draw(self, dc, rect) Actually draws the cell background and pattern hatching on a grid cell. :param `dc`: an instance of :class:`wx.DC`; :param `rect`: an instance of :class:`wx.Rect`, representing the cell rectangle.