[Ironpython-users] description for a property
Lee Armeanu
learmeanu at gmail.com
Sat Dec 7 11:29:27 CET 2013
Hi all,
I am trying to populate a simple PropertyGrid, something in the lines:
class Form1(System.Windows.Forms.Form):
def __init__(self):
self.PropertyGrid1 = System.Windows.Forms.PropertyGrid()
...
...
self.Load += self.Form1_Load
self.ResumeLayout(False)
def Form1_Load(self, sender, event_args):
self.PropertyGrid1.SelectedObject = Parrot()
class Parrot(object):
def __init__(self):
self._voltage = 100000
@property
def voltage(self):
"""Get the current voltage."""
return self._voltage
I would expect that the description string """Get the current voltage."""
is shown below the grid section but only "voltage" is printed.
Any suggestions?
Thanks,
Lee
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20131207/291fbd89/attachment.html>
More information about the Ironpython-users
mailing list