Sibylle Koczian wrote:
> Hello,
>
> Am 17.10.2010 12:10, schrieb Fraser Burns:
>   
>> I tried your simple code example, but couldn't get it to display the
>> text on the form until I changed it to afterInitAll()
>> It seemed so straightforward that I couldn't understand why we might
>> have a timing issue at this level. Is it a typical situation with
>> slightly older hardware or something?
>>
>> import dabo
>> dabo.ui.loadUI("wx")
>>
>> class HelloPyConForm(dabo.ui.dForm):
>>      def afterInit(self):
>>          self.Caption = "Hello PyCon Form"
>>          self.lblHello = dabo.ui.dLabel(self,
>>                  Caption ="Hello PyCon", FontSize=24,
>>                  ForeColor="blue")
>>
>> app = dabo.dApp()
>> app.MainFormClass = HelloPyConForm
>> app.start()
>>
>>     
>
> You might try the Command Window as described in the tutorial and look 
> at the position of the label: enter "self.Top" and "self.Left". One or 
> both of the values might be negative, which would explain why you don't 
> see the label.
>
> But I can't reliably reproduce this: I thought it always happens the 
> first time I call the example (and only then), but I just tried and the 
> label was shown quite correctly. Perhaps because I used _another_ dabo 
> application before?? Very strange, all of it.
>
> All of this with label construction in afterInit, not afterInitAll.
>
> HTH,
> Sibylle
>
>
>   
Quite correct !
Left was -54
Right was -36
So why was it hiding out there?
Is this part of why we should use sizers?
- - Fraser Burns
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/[email protected]

Reply via email to