Show More
@@ -204,6 +204,19 b' class Configurable(HasTraits):' | |||||
204 | lines.append(c(desc)) |
|
204 | lines.append(c(desc)) | |
205 | lines.append('') |
|
205 | lines.append('') | |
206 |
|
206 | |||
|
207 | parents = [] | |||
|
208 | for parent in cls.mro(): | |||
|
209 | # only include parents that are not base classes | |||
|
210 | # and are not the class itself | |||
|
211 | if issubclass(parent, Configurable) and \ | |||
|
212 | not parent in (Configurable, SingletonConfigurable, cls): | |||
|
213 | parents.append(parent) | |||
|
214 | ||||
|
215 | if parents: | |||
|
216 | pstr = ', '.join([ p.__name__ for p in parents ]) | |||
|
217 | lines.append(c('%s will inherit config from: %s'%(cls.__name__, pstr))) | |||
|
218 | lines.append('') | |||
|
219 | ||||
207 | for name,trait in cls.class_traits(config=True).iteritems(): |
|
220 | for name,trait in cls.class_traits(config=True).iteritems(): | |
208 | help = trait.get_metadata('help') or '' |
|
221 | help = trait.get_metadata('help') or '' | |
209 | lines.append(c(help)) |
|
222 | lines.append(c(help)) |
General Comments 0
You need to be logged in to leave comments.
Login now