Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
6.2.0, 6.2.1
-
None
Description
When an SVG image is included in a .qrc file and loaded via QIcon(":/ns/filename.svg") constructor, no error is shown, but no image is displayed.
Attached is a project that demonstrate this behavior: in the window there are 2 buttons, one is set to an icon loaded from a png file, the other with a svg. Both are embedded via the qrc file in a shared library.
On Qt 5.15, both images are shown.
On Qt 6.2, only the one with png is shown.
Tested on Windows.
On Linux, the same problem can be seen if libQt6Svg6 (or equivalent) is not installed. There is no compile-time or run-time warnings.