.. 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.customtreectrl .. highlight:: python .. _wx.lib.agw.customtreectrl.TreeItemAttr: ========================================================================================================================================== |phoenix_title| **wx.lib.agw.customtreectrl.TreeItemAttr** ========================================================================================================================================== Creates the item attributes (text colour, background colour and font). .. note:: This class is inspired by the wxWidgets generic implementation of :class:`TreeItemAttr`. | |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>TreeItemAttr</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.customtreectrl.TreeItemAttr_inheritance.png" alt="Inheritance diagram of TreeItemAttr" 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.customtreectrl.TreeItemAttr.html" title="Creates the item attributes (text colour, background colour and font)." alt="" coords="5,5,289,35"/> </map> </p> </div> | |method_summary| Methods Summary ================================ ================================================================================ ================================================================================ :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.__init__` Default class constructor. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.GetBackgroundColour` Returns the attribute background colour. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.GetBorderColour` Returns the attribute border colour. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.GetFont` Returns the attribute font. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.GetTextColour` Returns the attribute text colour. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.HasBackgroundColour` Returns whether the attribute has background colour. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.HasBorderColour` Returns whether the attribute has border colour. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.HasFont` Returns whether the attribute has font. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.HasTextColour` Returns whether the attribute has text colour. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.SetBackgroundColour` Sets the item background colour attribute. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.SetBorderColour` Sets the item border colour attribute. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.SetFont` Sets the item font attribute. :meth:`~wx.lib.agw.customtreectrl.TreeItemAttr.SetTextColour` Sets the text colour attribute. ================================================================================ ================================================================================ | |api| Class API =============== .. class:: TreeItemAttr(object) Creates the item attributes (text colour, background colour and font). .. note:: This class is inspired by the wxWidgets generic implementation of :class:`TreeItemAttr`. .. method:: __init__(self, colText=wx.NullColour, colBack=wx.NullColour, colBorder=wx.NullColour,font=wx.NullFont) Default class constructor. For internal use: do not call it in your code! :param `colText`: the text colour, an instance of :class:`wx.Colour`; :param `colBack`: the tree item background colour, an instance of :class:`wx.Colour`; :param `colBorder`: the tree item border colour, an instance of :class:`wx.Colour`; :param `font`: the tree item font, an instance of :class:`wx.Font`. .. method:: GetBackgroundColour(self) Returns the attribute background colour. :return: An instance of :class:`wx.Colour`. .. method:: GetBorderColour(self) Returns the attribute border colour. :return: An instance of :class:`wx.Colour`. .. versionadded:: 0.9.6 .. method:: GetFont(self) Returns the attribute font. :return: An instance of :class:`wx.Font`. .. method:: GetTextColour(self) Returns the attribute text colour. :return: An instance of :class:`wx.Colour`. .. method:: HasBackgroundColour(self) Returns whether the attribute has background colour. :return: ``True`` if the background colour attribute has been set, ``False`` otherwise. .. method:: HasBorderColour(self) Returns whether the attribute has border colour. :return: ``True`` if the border colour attribute has been set, ``False`` otherwise. .. versionadded:: 0.9.6 .. method:: HasFont(self) Returns whether the attribute has font. :return: ``True`` if the font attribute has been set, ``False`` otherwise. .. method:: HasTextColour(self) Returns whether the attribute has text colour. :return: ``True`` if the text colour attribute has been set, ``False`` otherwise. .. method:: SetBackgroundColour(self, colBack) Sets the item background colour attribute. :param `colBack`: an instance of :class:`wx.Colour`. .. method:: SetBorderColour(self, colBorder) Sets the item border colour attribute. :param `colBack`: an instance of :class:`wx.Colour`. .. versionadded:: 0.9.6 .. method:: SetFont(self, font) Sets the item font attribute. :param `font`: an instance of :class:`wx.Font`. .. method:: SetTextColour(self, colText) Sets the text colour attribute. :param `colText`: an instance of :class:`wx.Colour`.