[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [pygame] set_icon not working in 1.4?



At 08:31 1.2.2002 -0800, you wrote:
>Ludek Smid wrote:
>>it looks like pygame.display.set_icon doesn't set an icon in 1.4 - 
>>default icon is always displayed (it was working correctly in 1.3). Are 
>>there any new limitations for icons? I've tried both 16x16 and 32x32 
>>images. Sample code attached.
>
>the problem here is you are setting the icon before the windows is opened 
>with set_mode(). i wasn't even aware that setting the icon before the 
>window worked. for now just set the icon after the window is open. i'll 
>smarted up the icon stuff so it doesn't override any user set icons with 
>the default.

 From the documentation:
--------------------------------
set_icon
pygame.display.set_icon(Surface) -> None

       Sets the runtime icon that your system uses to decorate the program 
window. It is also used when the application is iconfified. This must be 
called before the first call to pygame.display.set_mode().
--------------------------------
So, I sugest to change sentence from "This must be called before the first 
call to..." to "This must be called after the first call to..."

____________________________________
pygame mailing list
pygame-users@seul.org
http://pygame.seul.org