.. include:: headings.inc .. currentmodule:: dataview .. _dataview.DataViewItemAttr: ========================================================================================================================================== |phoenix_title| **DataViewItemAttr** ========================================================================================================================================== This class is used to indicate to a :ref:`dataview.DataViewCtrl` that a certain item (see :ref:`dataview.DataViewItem`) has extra font attributes for its renderer. For this, it is required to override :meth:`DataViewModel.GetAttr` . Attributes are currently only supported by DataViewTextRendererText. | |class_hierarchy| Inheritance Diagram ===================================== Inheritance diagram for class **DataViewItemAttr** .. raw:: html

Inheritance diagram of DataViewItemAttr

| |method_summary| Methods Summary ================================ ================================================================================ ================================================================================ :meth:`~DataViewItemAttr.__init__` Constructor. :meth:`~DataViewItemAttr.SetBackgroundColour` Call this to set the background colour to use. :meth:`~DataViewItemAttr.SetBold` Call this to indicate that the item shall be displayed in bold text. :meth:`~DataViewItemAttr.SetColour` Call this to indicate that the item shall be displayed with that colour. :meth:`~DataViewItemAttr.SetItalic` Call this to indicate that the item shall be displayed in italic text. ================================================================================ ================================================================================ | |api| Class API =============== .. class:: DataViewItemAttr(object) This class is used to indicate to a DataViewCtrl that a certain item (see DataViewItem) has extra font attributes for its renderer. **Possible constructors**:: DataViewItemAttr() .. method:: __init__(self) Constructor. .. method:: SetBackgroundColour(self, colour) Call this to set the background colour to use. Currently this attribute is only supported in the generic version of :ref:`dataview.DataViewCtrl` and ignored by the native GTK+ and OS X implementations. :param `colour`: :type `colour`: Colour .. versionadded:: 2.9.4 .. method:: SetBold(self, set) Call this to indicate that the item shall be displayed in bold text. :param `set`: :type `set`: bool .. method:: SetColour(self, colour) Call this to indicate that the item shall be displayed with that colour. :param `colour`: :type `colour`: Colour .. method:: SetItalic(self, set) Call this to indicate that the item shall be displayed in italic text. :param `set`: :type `set`: bool