mailr16575 - /branches/uf_redesign/prompt/uf_objects.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on May 31, 2012 - 18:23:
Author: bugman
Date: Thu May 31 18:23:25 2012
New Revision: 16575

URL: http://svn.gna.org/viewcvs/relax?rev=16575&view=rev
Log:
Improved the user function class prompt help string.

The user function list now uses bold text, and the user function title is 
also now given.


Modified:
    branches/uf_redesign/prompt/uf_objects.py

Modified: branches/uf_redesign/prompt/uf_objects.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/uf_redesign/prompt/uf_objects.py?rev=16575&r1=16574&r2=16575&view=diff
==============================================================================
--- branches/uf_redesign/prompt/uf_objects.py (original)
+++ branches/uf_redesign/prompt/uf_objects.py Thu May 31 18:23:25 2012
@@ -89,7 +89,18 @@
         doc += build_subtitle("User functions")
         doc += "This class contains the following user functions:\n\n"
         for uf_name, uf in uf_info.uf_loop(self._name):
-            doc += "    - %s\n" % uf_name
+            # The unformatted text.
+            text = "    %s:  %s" % (uf_name, uf.title)
+
+            # Format.
+            text = format_text(text)
+
+            # Replace the arg text with bold text.
+            length = 7 + len(uf_name)
+            text = "    %s:  %s" % (bold_text(uf_name), text[length:])
+
+            # Add to the docstring.
+            doc += "%s\n" % text
 
         # Return the documentation.
         return doc




Related Messages


Powered by MHonArc, Updated Fri Jun 01 00:00:02 2012