Qt-Advanced-Docking-System icon indicating copy to clipboard operation
Qt-Advanced-Docking-System copied to clipboard

win11, qt6 : default svg icon cannot show

Open likedev opened this issue 1 year ago • 4 comments

all button svgs cannot show except tabs-menu-button.svg, using default configurtion.

OS: windows 11, Qt Version: Qt 6.6.2 with all modules installed image

My Solution It seems that the CMAKELists.txt miss some qt6 module/dlls configuration. And it seems that qt6 default doesn't support svg image formats.

  1. Add Qt6::svg, Qt6::SvgWidgets to CMakeLists.txt

  2. Copy "C:\Qt\6.6.2\msvc2019_64\plugins\imageformats\qsvg.dll" to ${PROJECT_ROOT}\cmake-build-release\plugins\imageformats

Then it works:

image

likedev avatar Feb 16 '24 07:02 likedev

I can not confirm this bug. I just checked out the latest master branch and compiled it with Qt 6.6.2 and MSVC 2019 on Windows 11. I can see all SVG icons in the demo application.

githubuser0xFFFF avatar Feb 19 '24 12:02 githubuser0xFFFF

I got the same issue, @likedev 's solution works for me. My Qt version: 6.7.2.

ba7lya avatar Jul 23 '24 17:07 ba7lya

@BA7LYA Ok, then please create a pull request to fix this properly for all users.

githubuser0xFFFF avatar Jul 24 '24 05:07 githubuser0xFFFF

Hi, I've been testing the PySide6 bindings for this and just came across the same problem. Unfortunately it doesn't seem that it can be as easily fixed from the user side by dropping the DLL file anywhere. A small addition, this is fixed by importing PySide6.QtSvg right before PySide6QtAds, I guess this best needs to happen in the init of QtAds.

steveway avatar Mar 21 '25 15:03 steveway

@likedev Hi, I just tested this with Qt 6.6.2 doing the following steps:

  1. Opening the CMakeLists file of ADS in QtCreator
  2. Configure the project for Qt 6.6.2
  3. Compile ther whole project including demo application and example
  4. Run demo application

I can see all SVG icons in the demo and example aplication.

Could you please try to reprodcue the problem with the demo and example applicatinos with Qt 6.6.2. If you can reproduce the problem, then please tell me the steps.

githubuser0xFFFF avatar May 08 '25 19:05 githubuser0xFFFF

Closing this issue because it does not seem to be very important. No pull requests with fixes yet.

githubuser0xFFFF avatar Aug 13 '25 03:08 githubuser0xFFFF