XRC-related question

Rob Gayvert rtg at rochester.rr.com
Wed Jul 27 15:28:35 UTC 2005


Cees De Groot wrote:

>On 7/27/05, Cees De Groot <cdegroot at gmail.com> wrote:
>  
>
>>Hmm... tried some more, and it's not doing what the 'Fit to parent'
>>button in wxGlade does. I wonder what code is behind it (probably need
>>to grab the wxGlade source code for that...)
>>
>>    
>>
>Ok, two steps gave the solution:
>- A multi-line static text needs to be run through 'replaceAll:
>Character cr with: Character lf'. Apparently Wx, even though it
>displays the CR's correctly, doesn't handle them when calculating
>sizes;
>  
>
Yes, I forgot about that. In the demo code you'll see a lot of 
references to #crToLf.

>- "self view getSizer fit: self view" seems to be necessary before the
>call to #layout. Haven't got a clue what it does, I nicked it from the
>wxGlade sources.
>  
>
Sizers seem more complicated than necessary, especially with this 
fit/layout business. I'm hoping we
can find a way to simplify this.

>Got my 'message dialog with check box' component now. And my first XRC UI!
>  
>
Very cool, and definitely a Good Thing.




More information about the Wxsqueak mailing list