PDA

View Full Version : Add pictures svg in QIcon



giorgik
6th September 2010, 14:48
Hi,
I have file .qrc with pictures svg. I would want to visualize the figures in QIcon without to supply with l' exe. How I must make?

wladek
7th September 2010, 07:35
Hi giorgik,

I don't think you can use svg with QIcon.
See the QtSvg module for more documentation.

Regards,
Wladek

giorgik
7th September 2010, 09:00
Yes, is possible:

QIcon(":/ostacolo.svg")

where the file risorsa.qrc:

<RCC>
<qresource>
<file>robot.svg</file>
<file>ostacolo.svg</file>
</qresource>
</RCC>