Mercurial > fife-parpg
comparison engine/python/fife/extensions/pychan/widgets/widget.py @ 586:dc19d9e38880
- added small addition to pychan documentation - not sure if we should file a bug ticket here:
- pychan widgets have beforeShow / afterHide methods, which can be overriden (and are empty)
- BUT if you have a container widget, those methods contain the call _resetTiling(), which seems to be
vital for the layout engine
- so, on overriding the containers beforeShow, you'll also loose this call - therefore e.g. a background_image
is "invisible"
author | chewie@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Sun, 08 Aug 2010 22:54:11 +0000 |
parents | f44b149f63e7 |
children | 2de93d36ca6d |
comparison
equal
deleted
inserted
replaced
585:c2de5aafe788 | 586:dc19d9e38880 |
---|---|
289 def beforeShow(self): | 289 def beforeShow(self): |
290 """ | 290 """ |
291 This method is called just before the widget is shown. | 291 This method is called just before the widget is shown. |
292 You can override this in derived widgets to add finalization | 292 You can override this in derived widgets to add finalization |
293 behaviour. | 293 behaviour. |
294 | |
295 NOTE: | |
296 - if your widget is a container, you have to call | |
297 _resetTiling(), as you will loose this call by using | |
298 your override method | |
294 """ | 299 """ |
295 | 300 |
296 def afterHide(self): | 301 def afterHide(self): |
297 """ | 302 """ |
298 This method is called just before the widget is hidden. | 303 This method is called just before the widget is hidden. |