.. include:: headings.inc .. module:: lib.agw.pybusyinfo .. currentmodule:: lib.agw.pybusyinfo .. highlight:: python .. _lib.agw.pybusyinfo: ========================================================================================================================================== |phoenix_title| **pybusyinfo** ========================================================================================================================================== :class:`PyBusyInfo` constructs a busy info window and displays a message in it. Description =========== :class:`PyBusyInfo` constructs a busy info window and displays a message in it. This class makes it easy to tell your user that the program is temporarily busy. Just create a :class:`PyBusyInfo` object, and within the current scope, a message window will be shown. For example:: busy = PyBusyInfo("Please wait, working...") for i in xrange(10000): DoACalculation() del busy It works by creating a window in the constructor, and deleting it in the destructor. You may also want to call :func:`Yield` () to refresh the window periodically (in case it had been obscured by other windows, for example). Usage ===== Usage example:: import wx import wx.lib.agw.pybusyinfo as PBI class MyFrame(wx.Frame): def __init__(self, parent): wx.Frame.__init__(self, parent, -1, "PyBusyInfo Demo") panel = wx.Panel(self) b = wx.Button(panel, -1, "Test PyBusyInfo ", (50,50)) self.Bind(wx.EVT_BUTTON, self.OnButton, b) def OnButton(self, event): message = "Please wait 5 seconds, working..." busy = PBI.PyBusyInfo(message, parent=self, title="Really Busy") wx.Yield() for indx in xrange(5): wx.MilliSleep(1000) del busy # our normal wxApp-derived class, as usual app = wx.App(0) frame = MyFrame(None) app.SetTopWindow(frame) frame.Show() app.MainLoop() Supported Platforms =================== :class:`PyBusyInfo` has been tested on the following platforms: * Windows (Windows XP). Window Styles ============= `No particular window styles are available for this class.` Events Processing ================= `No custom events are available for this class.` License And Version =================== :class:`PyBusyInfo` is distributed under the wxPython license. Latest Revision: Andrea Gavana @ 20 Mar 2012, 21.00 GMT Version 0.2 | |class_hierarchy| Inheritance Diagram ===================================== Inheritance diagram for module **pybusyinfo** .. raw:: html

Inheritance diagram of pybusyinfo

| |class_summary| Classes Summary =============================== ================================================================================ ================================================================================ :ref:`lib.agw.pybusyinfo.PyBusyInfo` Constructs a busy info window as child of parent and displays a message in it. :ref:`lib.agw.pybusyinfo.PyInfoFrame` Base class for :class:`PyBusyInfo`. ================================================================================ ================================================================================ | .. toctree:: :maxdepth: 1 :hidden: lib.agw.pybusyinfo.PyBusyInfo lib.agw.pybusyinfo.PyInfoFrame