wxPython - GetClassDefaultAttributes() method in wx.StaticLine Last Updated : 27 Feb, 2023 Summarize Comments Improve Suggest changes Share Like Article Like Report In this article we are going to learn about GetClassDefaultAttributes() function associated with wx.StaticLine class of wxPython. GetClassDefaultAttributes() function is used to return wx.VisualAttributes object for properties like background colour, foreground colour and font. Syntax: wx.StaticLIne.GetClassDefaultAttributes(variant=WINDOW_VARIANT_NORMAL)Parameters ParameterInput TypeDescriptionvariantWindowVariantvariant used for static line Return Type: wx.VisualAttributes Code Example: Python3 import wx class FrameUI(wx.Frame): def __init__(self, parent, title): super(FrameUI, self).__init__(parent, title = title, size =(300, 200)) # function for in-frame components self.InitUI() def InitUI(self): # parent panel for radio box pnl = wx.Panel(self) # list of choices hlist = ['Item One', 'Item Two'] vlist =['Item One', 'Item Two'] # create vertical line from point (50, 0) t0 (50, 250) self.sl = wx.StaticLine(pnl, 2, pos =(50, 0), size = (1, 250), style = wx.LI_VERTICAL) # create visual attributes instance for static line att = self.sl.GetClassDefaultAttributes() # print background and foregound colours print (att.colBg) print (att.colFg) # set frame in centre self.Centre() # set size of frame self.SetSize((400, 250)) # show output frame self.Show(True) # wx App instance ex = wx.App() # Example instance FrameUI(None, 'RadioButton and RadioBox') ex.MainLoop() Console Output: (0, 0, 0, 26) (61, 61, 61, 255) Output Window: Comment More infoAdvertise with us Next Article wxPython - GetClassDefaultAttributes() function in wx.StatusBar R RahulSabharwal Follow Improve Article Tags : Python Python-gui Python-wxPython Python wxPython-StaticLine Practice Tags : python Similar Reads wxPython - GetDefaultSize() method in wx.StaticLine In this article we are going to learn about method GetDefaultSize() associated with wx.StaticLine class of wxPython. GetDefaultSize() method is simply used to return the size which will be given to the smaller dimension of the static line, i.e. Its height for a horizontal line or its width for a ver 1 min read wxPython - GetClassDefaultAttributes() in wx.RadioButton Python provides wxpython package which allows us to create a highly functional graphical user interface. It is implemented as a set of extension modules that wrap the GUI components of the wxWidgets library which is written in C++. It is a cross-platform GUI toolkit for python, Phoenix version Phoen 2 min read wxPython - GetClassDefaultAttributes() function in wx.StatusBar In this article we are going to learn about GetClassDefaultAttributes() associated to the class wx.StatusBar of wxPython. GetClassDefaultAttributes() is used to return visual attributes of statusbar like background color, foreground color, the font used for control label/text inside it. Syntax : wx. 1 min read wxPython | GetClassDefaultAttributes() function in python In this article we are going to learn about GetClassDefaultAttributes() of class wx.ToolBar of wxPython. GetClassDefaultAttributes() is used to return visual attributes of toolbar like background color, foreground color, the font used for control label/text inside it. Parameters : ParameterInput Typ 1 min read wxPython - GetClassDefaultAttributes() function in wx.Button In this article we are going to learn about GetClassDefaultAttributes() function associated with wx.Button class of wxPython. GetClassDefaultAttributes() function is used to return wx.VisualAttributes object for properties like background colour, foreground colour and font.It takes variant as argume 1 min read wxPython - Enable() method in wx.StaticBox In this article we are going to learn about Enable() method associated with wx.StaticBox class of wxPython. Enable() function is simply used in order to enable or disable the box without affecting its label window, if any. It takes a boolean 'enable' parameter if True enables the window else disable 1 min read Like