[Tutor] Qpixmaps

Vijay Kumar Bagavath Singh vijaykumar at linuxmail.org
Thu Jun 3 23:10:39 EDT 2004


This is not specific to Python or PyQt. The pixmap created by QT designer is in the XPM format. You can use Gimp, ImageMagick and most of the other bitmap tools in GNU/Linux to create such XPMs. If you have ImageMagick installed, you can convert bmp files to xpm using

convert myfile.bmp myfile.xpm

Vijay

----- Original Message -----
> Date: Thu, 03 Jun 2004 10:30:11 -0700
> From: John Fabiani <jfabiani at yolo.com>
> Subject: [Tutor] Qpixmaps
> To: Python tutor help <tutor at python.org>
> Message-ID: <40BF6023.9020203 at yolo.com>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
> 
> Hi,
> I using PyQt as my GUI.  When I build a app from the QT designer and add 
> menu's and toolbars the designer creates a bitmap of the icons for the 
> app.  As follows
> fileopen = [
>     '16 13 5 1',
>     '. c #040404',
>     '# c #808304',
>     'a c None',
>     'b c #f3f704',
>     'c c #f3f7f3',
>     'aaaaaaaaa...aaaa',
>     'aaaaaaaa.aaa.a.a',
>     'aaaaaaaaaaaaa..a',
>     'a...aaaaaaaa...a',
>     '.bcb.......aaaaa',
>     '.cbcbcbcbc.aaaaa',
>     '.bcbcbcbcb.aaaaa',
>     '.cbcb...........',
>     '.bcb.#########.a',
>     '.cb.#########.aa',
>     '.b.#########.aaa',
>     '..#########.aaaa',
>     '...........aaaaa'
> ]
> 
> I think I understand that this a description of a bitmap and is painted 
> (displayed) using QPixmap().  My question is how was the fileopen (a 
> list) bitmap created.  Are there any tools that convert from a bmp file 
> or some other file type to what is used by PyQt?   It seems that 
> wxPython uses something similar. 
> 
> Thanks
> John

-- 
______________________________________________
Check out the latest SMS services @ http://www.linuxmail.org 
This allows you to send and receive SMS through your mailbox.


Powered by Outblaze



More information about the Tutor mailing list