]> git.saurik.com Git - wxWidgets.git/commitdiff
docstrign tweaks
authorRobin Dunn <robin@alldunn.com>
Thu, 17 Jun 2004 05:52:01 +0000 (05:52 +0000)
committerRobin Dunn <robin@alldunn.com>
Thu, 17 Jun 2004 05:52:01 +0000 (05:52 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27848 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

wxPython/src/_window.i
wxPython/wx/lib/analogclock.py
wxPython/wx/lib/anchors.py
wxPython/wx/lib/evtmgr.py
wxPython/wx/lib/fancytext.py
wxPython/wx/lib/filebrowsebutton.py
wxPython/wx/lib/floatcanvas/FloatCanvas.py

index d907a437595e564444c32b10c8eede65740a171c..3c8958510126f3f2945bdbe5f824011d2e1059c7 100644 (file)
@@ -829,7 +829,6 @@ by pressing <Enter> such as the OK button on a wx.Dialog.", "");
         "Set this child as temporary default", "");
     
 
         "Set this child as temporary default", "");
     
 
-    // Navigates in the specified direction by sending a wxNavigationKeyEvent
     DocDeclAStr(
         virtual bool , Navigate(int flags = wxNavigationKeyEvent::IsForward),
         "Navigate(self, int flags=NavigationKeyEvent.IsForward) -> bool",
     DocDeclAStr(
         virtual bool , Navigate(int flags = wxNavigationKeyEvent::IsForward),
         "Navigate(self, int flags=NavigationKeyEvent.IsForward) -> bool",
@@ -837,14 +836,13 @@ by pressing <Enter> such as the OK button on a wx.Dialog.", "");
 `wx.NavigationKeyEvent`.", "
  
     :param flags: A combination of the ``IsForward`` and ``WinChange``
 `wx.NavigationKeyEvent`.", "
  
     :param flags: A combination of the ``IsForward`` and ``WinChange``
-                  values in the `wx.NavigationKeyEvent` class, which
-                  determine if the navigation should be in forward or
-                  reverse order, and if it should be able to cross
-                  parent window boundaries, such as between notebook
-                  pages or MDI child frames.  Typically the status of
-                  the Shift key (for forward or reverse) or the
-                  Control key (for WinChange) would be used to
-                  determine how to set the flags.
+        values in the `wx.NavigationKeyEvent` class, which determine
+        if the navigation should be in forward or reverse order, and
+        if it should be able to cross parent window boundaries, such
+        as between notebook pages or MDI child frames.  Typically the
+        status of the Shift key (for forward or reverse) or the
+        Control key (for WinChange) would be used to determine how to
+        set the flags.
 
 One situation in which you may wish to call this method is from a text
 control custom keypress handler to do the default navigation behaviour
 
 One situation in which you may wish to call this method is from a text
 control custom keypress handler to do the default navigation behaviour
index 116ce170934be2e8373988775186daef6d550688..428cc279893a2365ad4dc92352d17943411d315b 100644 (file)
@@ -735,21 +735,23 @@ class AnalogClockWindow(wx.PyWindow):
 
     def SetClockStyle(self, style):
         """
 
     def SetClockStyle(self, style):
         """
-        Set the clock style, acording to the options:
+        Set the clock style, acording to these options:
 
 
-            SHOW_QUARTERS_TICKS - Show marks for hours 3, 6, 9, 12
-            SHOW_HOURS_TICKS    - Show marks for all hours
-            SHOW_MINUTES_TICKS  - Show marks for minutes
+            ====================  ================================
+            SHOW_QUARTERS_TICKS   Show marks for hours 3, 6, 9, 12
+            SHOW_HOURS_TICKS      Show marks for all hours
+            SHOW_MINUTES_TICKS    Show marks for minutes
 
 
-            SHOW_HOURS_HAND     - Show hours hand
-            SHOW_MINUTES_HAND   - Show minutes hand
-            SHOW_SECONDS_HAND   - Show seconds hand
+            SHOW_HOURS_HAND       Show hours hand
+            SHOW_MINUTES_HAND     Show minutes hand
+            SHOW_SECONDS_HAND     Show seconds hand
 
 
-            SHOW_SHADOWS        - Show hands and marks shadows
+            SHOW_SHADOWS          Show hands and marks shadows
 
 
-            ROTATE_TICKS        - Align tick marks to watch
-            OVERLAP_TICKS       - Draw tick marks for minutes even
+            ROTATE_TICKS          Align tick marks to watch
+            OVERLAP_TICKS         Draw tick marks for minutes even
                                   when they match the hours marks.
                                   when they match the hours marks.
+            ====================  ================================
         """
 
         self.clockStyle = style
         """
 
         self.clockStyle = style
@@ -759,14 +761,17 @@ class AnalogClockWindow(wx.PyWindow):
         """
         Set the ticks styles, acording to the options below.
 
         """
         Set the ticks styles, acording to the options below.
 
-            TICKS_NONE          = Don't show tick marks.
-            TICKS_SQUARE        = Use squares as tick marks.
-            TICKS_CIRCLE        = Use circles as tick marks.
-            TICKS_POLY          = Use a polygon as tick marks. The polygon
-                                  must be passed using SetTickShapes,
-                                  otherwise the default polygon will be used.
-            TICKS_DECIMAL       = Use decimal numbers.
-            TICKS_ROMAN         = Use Roman numbers.
+            =================   =====================================
+            TICKS_NONE          Don't show tick marks.
+            TICKS_SQUARE        Use squares as tick marks.
+            TICKS_CIRCLE        Use circles as tick marks.
+            TICKS_POLY          Use a polygon as tick marks. The
+                                polygon must be passed using
+                                SetTickShapes, otherwise the default
+                                polygon will be used.
+            TICKS_DECIMAL       Use decimal numbers.
+            TICKS_ROMAN         Use Roman numbers.
+            =================   =====================================
         """
 
         if h:
         """
 
         if h:
index af7cd8abfebf4be64acc5d35179d1ab4efea2c3f..88909ba7412732123b7c07e21e80a560963b7256 100644 (file)
 import  wx
 
 class LayoutAnchors(wx.LayoutConstraints):
 import  wx
 
 class LayoutAnchors(wx.LayoutConstraints):
-    """ A class that implements Delphi's Anchors with wx.LayoutConstraints.
+    """
+    A class that implements Delphi's Anchors with wx.LayoutConstraints.
 
 
-        Anchored sides maintain the distance from the edge of the
-        control to the same edge of the parent.
-        When neither side is selected, the control keeps the same
-        relative position to both sides.
+    Anchored sides maintain the distance from the edge of the control
+    to the same edge of the parent.  When neither side is selected,
+    the control keeps the same relative position to both sides.
 
 
-        The current position and size of the control and it's parent
-        is used when setting up the constraints. To change the size or
-        position of an already anchored control, set the constraints to
-        None, reposition or resize and reapply the anchors.
+    The current position and size of the control and it's parent is
+    used when setting up the constraints. To change the size or
+    position of an already anchored control, set the constraints to
+    None, reposition or resize and reapply the anchors.
 
 
-        Examples:
+    Examples::
 
         Let's anchor the right and bottom edge of a control and
         resize it's parent.
 
         Let's anchor the right and bottom edge of a control and
         resize it's parent.
@@ -59,6 +59,7 @@ class LayoutAnchors(wx.LayoutConstraints):
                             | +-------*-------+ |
                             +-------------------+
         * = anchored edge
                             | +-------*-------+ |
                             +-------------------+
         * = anchored edge
+        
     """
     def __init__(self, control, left=1, top=1, right=0, bottom=0):
         wx.LayoutConstraints.__init__(self)
     """
     def __init__(self, control, left=1, top=1, right=0, bottom=0):
         wx.LayoutConstraints.__init__(self)
index 94b729a75c841550ebaf77665f1db647d0310391..b6e8765f0f6e6037b504aa619ce46e6ac129f0d2 100644 (file)
@@ -63,17 +63,17 @@ class EventManager:
         """
         Registers a listener function (or any callable object) to
         receive events of type event coming from the source window.
         """
         Registers a listener function (or any callable object) to
         receive events of type event coming from the source window.
-        For example:
-
+        For example::
             eventManager.Register(self.OnButton, EVT_BUTTON, theButton)
 
         Alternatively, the specific window where the event is
         delivered, and/or the ID of the event source can be specified.
             eventManager.Register(self.OnButton, EVT_BUTTON, theButton)
 
         Alternatively, the specific window where the event is
         delivered, and/or the ID of the event source can be specified.
-        For example:
-
+        For example::
             eventManager.Register(self.OnButton, EVT_BUTTON, win=self, id=ID_BUTTON)
             eventManager.Register(self.OnButton, EVT_BUTTON, win=self, id=ID_BUTTON)
-        or
+            
+        or::
             eventManager.Register(self.OnButton, EVT_BUTTON, theButton, self)
             eventManager.Register(self.OnButton, EVT_BUTTON, theButton, self)
+            
         """
 
         # 1. Check if the 'event' is actually one of the multi-
         """
 
         # 1. Check if the 'event' is actually one of the multi-
index ddc45b0667d1e7fc155ab6c67d5e0516e0f1472d..c07d6f04612bba55f05b2bef24349e545f0cd9dc 100644 (file)
@@ -3,42 +3,40 @@
 # o Updated for 2.5 compatability.
 #
 
 # o Updated for 2.5 compatability.
 #
 
-"""<font weight="bold" size="16">FancyText</font> -- <font style="italic" size="16">methods for rendering XML specified text</font>
-<font family="swiss" size="12">
+"""
+FancyText -- methods for rendering XML specified text
+
 This module exports four main methods::
 This module exports four main methods::
-<font family="fixed" style="slant">
+
     def GetExtent(str, dc=None, enclose=True)
     def GetFullExtent(str, dc=None, enclose=True)
     def RenderToBitmap(str, background=None, enclose=True)
     def RenderToDC(str, dc, x, y, enclose=True)
     def GetExtent(str, dc=None, enclose=True)
     def GetFullExtent(str, dc=None, enclose=True)
     def RenderToBitmap(str, background=None, enclose=True)
     def RenderToDC(str, dc, x, y, enclose=True)
-</font>
-In all cases, 'str' is an XML string. Note that start and end tags
-are only required if *enclose* is set to False. In this case the 
-text should be wrapped in FancyText tags.
+
+In all cases, 'str' is an XML string. Note that start and end tags are
+only required if *enclose* is set to False. In this case the text
+should be wrapped in FancyText tags.
 
 In addition, the module exports one class::
 
 In addition, the module exports one class::
-<font family="fixed" style="slant">
+
     class StaticFancyText(self, window, id, text, background, ...)
     class StaticFancyText(self, window, id, text, background, ...)
-</font>
-This class works similar to StaticText except it interprets its text 
+
+This class works similar to StaticText except it interprets its text
 as FancyText.
 
 as FancyText.
 
-The text can support<sup>superscripts</sup> and <sub>subscripts</sub>, text
-in different <font size="20">sizes</font>, <font color="blue">colors</font>, <font style="italic">styles</font>, <font weight="bold">weights</font> and
-<font family="script">families</font>. It also supports a limited set of symbols,
-currently <times/>, <infinity/>, <angle/> as well as greek letters in both
-upper case (<Alpha/><Beta/>...<Omega/>) and lower case (<alpha/><beta/>...<omega/>).
+The text can support superscripts and subscripts, text in different
+sizes, colors, styles, weights and families. It also supports a
+limited set of symbols, currently *times*, *infinity*, *angle* as well
+as greek letters in both upper case (*Alpha* *Beta*... *Omega*) and
+lower case (*alpha* *beta*... *omega*).
 
 
-We can use doctest/guitest to display this string in all its marked up glory.
-<font family="fixed">
 >>> frame = wx.Frame(wx.NULL, -1, "FancyText demo", wx.DefaultPosition)
 >>> frame = wx.Frame(wx.NULL, -1, "FancyText demo", wx.DefaultPosition)
->>> sft = StaticFancyText(frame, -1, __doc__, wx.Brush("light grey", wx.SOLID))
+>>> sft = StaticFancyText(frame, -1, testText, wx.Brush("light grey", wx.SOLID))
 >>> frame.SetClientSize(sft.GetSize())
 >>> didit = frame.Show()
 >>> from guitest import PauseTests; PauseTests()
 
 >>> frame.SetClientSize(sft.GetSize())
 >>> didit = frame.Show()
 >>> from guitest import PauseTests; PauseTests()
 
-</font></font>
-The End"""
+"""
 
 # Copyright 2001-2003 Timothy Hochberg
 # Use as you see fit. No warantees, I cannot be held responsible, etc.
 
 # Copyright 2001-2003 Timothy Hochberg
 # Use as you see fit. No warantees, I cannot be held responsible, etc.
@@ -403,11 +401,49 @@ renderToDC = RenderToDC
 # Test Driver
 
 def test():
 # Test Driver
 
 def test():
+    testText = 
+"""<font weight="bold" size="16">FancyText</font> -- <font style="italic" size="16">methods for rendering XML specified text</font>
+<font family="swiss" size="12">
+This module exports four main methods::
+<font family="fixed" style="slant">
+    def GetExtent(str, dc=None, enclose=True)
+    def GetFullExtent(str, dc=None, enclose=True)
+    def RenderToBitmap(str, background=None, enclose=True)
+    def RenderToDC(str, dc, x, y, enclose=True)
+</font>
+In all cases, 'str' is an XML string. Note that start and end tags
+are only required if *enclose* is set to False. In this case the 
+text should be wrapped in FancyText tags.
+
+In addition, the module exports one class::
+<font family="fixed" style="slant">
+    class StaticFancyText(self, window, id, text, background, ...)
+</font>
+This class works similar to StaticText except it interprets its text 
+as FancyText.
+
+The text can support<sup>superscripts</sup> and <sub>subscripts</sub>, text
+in different <font size="20">sizes</font>, <font color="blue">colors</font>, <font style="italic">styles</font>, <font weight="bold">weights</font> and
+<font family="script">families</font>. It also supports a limited set of symbols,
+currently <times/>, <infinity/>, <angle/> as well as greek letters in both
+upper case (<Alpha/><Beta/>...<Omega/>) and lower case (<alpha/><beta/>...<omega/>).
+
+We can use doctest/guitest to display this string in all its marked up glory.
+<font family="fixed">
+>>> frame = wx.Frame(wx.NULL, -1, "FancyText demo", wx.DefaultPosition)
+>>> sft = StaticFancyText(frame, -1, __doc__, wx.Brush("light grey", wx.SOLID))
+>>> frame.SetClientSize(sft.GetSize())
+>>> didit = frame.Show()
+>>> from guitest import PauseTests; PauseTests()
+
+</font></font>
+The End"""
+
     app = wx.PySimpleApp()
     box = wx.BoxSizer(wx.VERTICAL)
     frame = wx.Frame(None, -1, "FancyText demo", wx.DefaultPosition)
     frame.SetBackgroundColour("light grey")
     app = wx.PySimpleApp()
     box = wx.BoxSizer(wx.VERTICAL)
     frame = wx.Frame(None, -1, "FancyText demo", wx.DefaultPosition)
     frame.SetBackgroundColour("light grey")
-    sft = StaticFancyText(frame, -1, __doc__)
+    sft = StaticFancyText(frame, -1, testText)
     box.Add(sft, 1, wx.EXPAND)
     frame.SetSizer(box)
     frame.SetAutoLayout(True)
     box.Add(sft, 1, wx.EXPAND)
     frame.SetSizer(box)
     frame.SetAutoLayout(True)
index 9777d73861cb4f63dbbeee045fb0d7e792c95cf5..230551d4193ccf9e100a37b5b0593417b69cdaa6 100644 (file)
@@ -24,42 +24,37 @@ import  wx
 #----------------------------------------------------------------------
 
 class FileBrowseButton(wx.Panel):
 #----------------------------------------------------------------------
 
 class FileBrowseButton(wx.Panel):
-    """ A control to allow the user to type in a filename
-    or browse with the standard file dialog to select file
-
-    __init__ (
-        parent, id, pos, size -- passed directly to wxPanel initialisation
-        style = wxTAB_TRAVERSAL -- passed directly to wxPanel initialisation
-        labelText -- Text for label to left of text field
-        buttonText -- Text for button which launches the file dialog
-        toolTip -- Help text
-        dialogTitle -- Title used in file dialog
-        startDirectory -- Default directory for file dialog startup
-        fileMask -- File mask (glob pattern, such as *.*) to use in file dialog
-        fileMode -- wxOPEN or wxSAVE, indicates type of file dialog to use
-        changeCallback -- callback receives all > > changes in value of control
-    )
-    GetValue() -- retrieve current value of text control
-    SetValue(string) -- set current value of text control
-    label -- pointer to internal label widget
-    textControl -- pointer to internal text control
-    browseButton -- pointer to button
+    """
+    A control to allow the user to type in a filename or browse with
+    the standard file dialog to select file
     """
     def __init__ (self, parent, id= -1,
     """
     def __init__ (self, parent, id= -1,
-              pos = wx.DefaultPosition, size = wx.DefaultSize,
-              style = wx.TAB_TRAVERSAL,
-              labelText= "File Entry:",
-              buttonText= "Browse",
-              toolTip= "Type filename or click browse to choose file",
-              # following are the values for a file dialog box
-              dialogTitle = "Choose a file",
-              startDirectory = ".",
-              initialValue = "",
-              fileMask = "*.*",
-              fileMode = wx.OPEN,
-              # callback for when value changes (optional)
-              changeCallback= lambda x:x
+                  pos = wx.DefaultPosition,
+                  size = wx.DefaultSize,
+                  style = wx.TAB_TRAVERSAL,
+                  labelText= "File Entry:",
+                  buttonText= "Browse",
+                  toolTip= "Type filename or click browse to choose file",
+                  # following are the values for a file dialog box
+                  dialogTitle = "Choose a file",
+                  startDirectory = ".",
+                  initialValue = "",
+                  fileMask = "*.*",
+                  fileMode = wx.OPEN,
+                  # callback for when value changes (optional)
+                  changeCallback= lambda x:x
         ):
         ):
+        """
+        :param labelText:      Text for label to left of text field
+        :param buttonText:     Text for button which launches the file dialog
+        :param toolTip:        Help text
+        :param dialogTitle:    Title used in file dialog
+        :param startDirectory: Default directory for file dialog startup
+        :param fileMask:       File mask (glob pattern, such as *.*) to use in file dialog
+        :param fileMode:       wx.OPEN or wx.SAVE, indicates type of file dialog to use
+        :param changeCallback: callback receives all changes in value of control
+        """
+      
         # store variables
         self.labelText = labelText
         self.buttonText = buttonText
         # store variables
         self.labelText = labelText
         self.buttonText = buttonText
@@ -176,11 +171,13 @@ class FileBrowseButton(wx.Panel):
 
 
     def GetValue (self):
 
 
     def GetValue (self):
-        """ Convenient access to text control value """
+        """
+        retrieve current value of text control
+        """
         return self.textControl.GetValue()
 
     def SetValue (self, value, callBack=1):
         return self.textControl.GetValue()
 
     def SetValue (self, value, callBack=1):
-        """ Convenient setting of text control value """
+        """set current value of text control"""
         save = self.callCallback
         self.callCallback = callBack
         self.textControl.SetValue(value)
         save = self.callCallback
         self.callCallback = callBack
         self.textControl.SetValue(value)
@@ -207,27 +204,34 @@ class FileBrowseButton(wx.Panel):
 
 
 class FileBrowseButtonWithHistory( FileBrowseButton ):
 
 
 class FileBrowseButtonWithHistory( FileBrowseButton ):
-    """ with following additions:
+    """
+    with following additions:
         __init__(..., history=None)
 
             history -- optional list of paths for initial history drop-down
                 (must be passed by name, not a positional argument)
                 If history is callable it will must return a list used
                 for the history drop-down
         __init__(..., history=None)
 
             history -- optional list of paths for initial history drop-down
                 (must be passed by name, not a positional argument)
                 If history is callable it will must return a list used
                 for the history drop-down
+
             changeCallback -- as for FileBrowseButton, but with a work-around
                 for win32 systems which don't appear to create wx.EVT_COMBOBOX
                 events properly.  There is a (slight) chance that this work-around
                 will cause some systems to create two events for each Combobox
                 selection. If you discover this condition, please report it!
             changeCallback -- as for FileBrowseButton, but with a work-around
                 for win32 systems which don't appear to create wx.EVT_COMBOBOX
                 events properly.  There is a (slight) chance that this work-around
                 will cause some systems to create two events for each Combobox
                 selection. If you discover this condition, please report it!
+
             As for a FileBrowseButton.__init__ otherwise.
             As for a FileBrowseButton.__init__ otherwise.
+            
         GetHistoryControl()
             Return reference to the control which implements interfaces
             required for manipulating the history list.  See GetHistoryControl
             documentation for description of what that interface is.
         GetHistoryControl()
             Return reference to the control which implements interfaces
             required for manipulating the history list.  See GetHistoryControl
             documentation for description of what that interface is.
+            
         GetHistory()
             Return current history list
         GetHistory()
             Return current history list
+            
         SetHistory( value=(), selectionIndex = None )
             Set current history list, if selectionIndex is not None, select that index
         SetHistory( value=(), selectionIndex = None )
             Set current history list, if selectionIndex is not None, select that index
+            
         """
     def __init__( self, *arguments, **namedarguments):
         self.history = namedarguments.get( "history" )
         """
     def __init__( self, *arguments, **namedarguments):
         self.history = namedarguments.get( "history" )
@@ -257,12 +261,15 @@ class FileBrowseButtonWithHistory( FileBrowseButton ):
 
 
     def GetHistoryControl( self ):
 
 
     def GetHistoryControl( self ):
-        """Return a pointer to the control which provides (at least)
-        the following methods for manipulating the history list.:
+        """
+        Return a pointer to the control which provides (at least)
+        the following methods for manipulating the history list:
+        
             Append( item ) -- add item
             Clear() -- clear all items
             Delete( index ) -- 0-based index to delete from list
             SetSelection( index ) -- 0-based index to select in list
             Append( item ) -- add item
             Clear() -- clear all items
             Delete( index ) -- 0-based index to delete from list
             SetSelection( index ) -- 0-based index to select in list
+            
         Semantics of the methods follow those for the wxComboBox control
         """
         return self.textControl
         Semantics of the methods follow those for the wxComboBox control
         """
         return self.textControl
index 4ff0fcb513d52813e8c52226cf74335cdc604eca..0d5142fcabd12a2ecb49e53be25bba876c07d281 100644 (file)
@@ -942,18 +942,22 @@ class ScaledText(DrawObject, TextObjectMixin, XYObjectMixin):
 
     Family:
         Font family, a generic way of referring to fonts without
 
     Family:
         Font family, a generic way of referring to fonts without
-        specifying actual facename. One of:
+        specifying actual facename. One of::
             wx.DEFAULT:  Chooses a default font. 
             wx.DECORATI: A decorative font. 
             wx.ROMAN: A formal, serif font. 
             wx.SCRIPT: A handwriting font. 
             wx.SWISS: A sans-serif font. 
             wx.MODERN: A fixed pitch font.
             wx.DEFAULT:  Chooses a default font. 
             wx.DECORATI: A decorative font. 
             wx.ROMAN: A formal, serif font. 
             wx.SCRIPT: A handwriting font. 
             wx.SWISS: A sans-serif font. 
             wx.MODERN: A fixed pitch font.
+            
         NOTE: these are only as good as the wxWindows defaults, which aren't so good.
         NOTE: these are only as good as the wxWindows defaults, which aren't so good.
+        
     Style:
         One of wx.NORMAL, wx.SLANT and wx.ITALIC.
     Style:
         One of wx.NORMAL, wx.SLANT and wx.ITALIC.
+        
     Weight:
         One of wx.NORMAL, wx.LIGHT and wx.BOLD.
     Weight:
         One of wx.NORMAL, wx.LIGHT and wx.BOLD.
+        
     Underline:
         The value can be True or False. At present this may have an an
         effect on Windows only.
     Underline:
         The value can be True or False. At present this may have an an
         effect on Windows only.
@@ -1952,8 +1956,8 @@ def _makeFloatCanvasAddMethods(): ## lrk's code for doing this in module __init_
         addshapemethod = getaddshapemethod()
         methodname = "Add" + classname
         setattr(FloatCanvas, methodname, addshapemethod)
         addshapemethod = getaddshapemethod()
         methodname = "Add" + classname
         setattr(FloatCanvas, methodname, addshapemethod)
-        docstring = "Creates %s and adds its reference to the canvas.\n" % classname
-        docstring += "Argument protocol same as %s class" % classname
+        docstring = "        Creates %s and adds its reference to the canvas.\n" % classname
+        docstring += "        Argument protocol same as %s class" % classname
         if klass.__doc__:
             docstring += ", whose docstring is:\n%s" % klass.__doc__
         FloatCanvas.__dict__[methodname].__doc__ = docstring
         if klass.__doc__:
             docstring += ", whose docstring is:\n%s" % klass.__doc__
         FloatCanvas.__dict__[methodname].__doc__ = docstring