Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Custom widget plugin not shown on plugins list
Forum Updated to NodeBB v4.3 + New Features

Custom widget plugin not shown on plugins list

Scheduled Pinned Locked Moved Solved General and Desktop
12 Posts 3 Posters 560 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • DragoonD Offline
    DragoonD Offline
    Dragoon
    wrote on last edited by Dragoon
    #1

    Hallo, I'm trying to create my first widget and a corrisponding plugin.
    I followed official tutorials and some other sources and I finally managed to compile everything correctly, the widget works fine... When I try to open the 'About plugins' window in Qt Creator I got this error (in terminal window):

    qt.core.plugin.loader: In /opt/Qt/Tools/QtCreator/lib/Qt/plugins/designer/libvirtualpadplugin.so:
      Plugin uses incompatible Qt library (5.15.0) [debug]
    

    Of course my widget is not shown in QtCreator widget palette.

    I'm using Qt 5.15.2 , Qt Creator 9.0.0 under Linux 20.04.
    Qt have been installed trough official Qt online installer.

    bye by[t]e{s}... Mike

    SGaistS 1 Reply Last reply
    0
    • DragoonD Dragoon

      Hallo, I'm trying to create my first widget and a corrisponding plugin.
      I followed official tutorials and some other sources and I finally managed to compile everything correctly, the widget works fine... When I try to open the 'About plugins' window in Qt Creator I got this error (in terminal window):

      qt.core.plugin.loader: In /opt/Qt/Tools/QtCreator/lib/Qt/plugins/designer/libvirtualpadplugin.so:
        Plugin uses incompatible Qt library (5.15.0) [debug]
      

      Of course my widget is not shown in QtCreator widget palette.

      I'm using Qt 5.15.2 , Qt Creator 9.0.0 under Linux 20.04.
      Qt have been installed trough official Qt online installer.

      SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      You should check which version of Qt was used to build Qt Creator. That's the one you need to use to build your plugin.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      DragoonD 2 Replies Last reply
      1
      • SGaistS SGaist

        Hi,

        You should check which version of Qt was used to build Qt Creator. That's the one you need to use to build your plugin.

        DragoonD Offline
        DragoonD Offline
        Dragoon
        wrote on last edited by
        #3

        @SGaist I cannot update Qt... can I downgrade Qt Creator? Which version of Qt Creator is based on Qt 5.15.2 (if any)?

        bye by[t]e{s}... Mike

        SGaistS DragoonD 2 Replies Last reply
        0
        • DragoonD Dragoon

          @SGaist I cannot update Qt... can I downgrade Qt Creator? Which version of Qt Creator is based on Qt 5.15.2 (if any)?

          SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          You can download the specific Qt Creator installer.

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          DragoonD 1 Reply Last reply
          0
          • DragoonD Dragoon

            @SGaist I cannot update Qt... can I downgrade Qt Creator? Which version of Qt Creator is based on Qt 5.15.2 (if any)?

            DragoonD Offline
            DragoonD Offline
            Dragoon
            wrote on last edited by
            #5

            @Dragoon uhm... where I can find the version matching table?
            Qt Creator 9.00 -> Qt 6.40
            Qt Creator 4.11 -> Qt 5.12.8
            Qt Creator ?.?? -> Qt 5.15.2

            Hope there's a version matrix somewhere ....

            bye by[t]e{s}... Mike

            jsulmJ 1 Reply Last reply
            0
            • DragoonD Dragoon

              @Dragoon uhm... where I can find the version matching table?
              Qt Creator 9.00 -> Qt 6.40
              Qt Creator 4.11 -> Qt 5.12.8
              Qt Creator ?.?? -> Qt 5.15.2

              Hope there's a version matrix somewhere ....

              jsulmJ Offline
              jsulmJ Offline
              jsulm
              Lifetime Qt Champion
              wrote on last edited by
              #6

              @Dragoon In QtCreator: "Help/About QtCreator...".

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              DragoonD 1 Reply Last reply
              0
              • jsulmJ jsulm

                @Dragoon In QtCreator: "Help/About QtCreator...".

                DragoonD Offline
                DragoonD Offline
                Dragoon
                wrote on last edited by Dragoon
                #7

                @jsulm that's not what I asked. I meant... is there a compatibility matrix that tells which Qt Creator version is based on a specific Qt version? Of course the answer could be NOT (not nice but I will appreaciate the honesty).

                As I stated Qt Creator 9.0.0 is based upon Qt 6.4
                Qt Creator 4.11.0 is based on Qt 5.12.8
                Qt Creator 4.5.2 is baed on Qt 5.9.5

                ... at the moment I didn't found a version of Qt Creator based on Qt 5.15.2 and that means that plugins produced with Qt 5.15.2 are not usable.
                Hope the only way to find this information is NOT to install each version of Qt Creator available and look into the About dialog box... (waste of time apart this could also ends with: none found).

                bye by[t]e{s}... Mike

                jsulmJ 1 Reply Last reply
                0
                • DragoonD Dragoon

                  @jsulm that's not what I asked. I meant... is there a compatibility matrix that tells which Qt Creator version is based on a specific Qt version? Of course the answer could be NOT (not nice but I will appreaciate the honesty).

                  As I stated Qt Creator 9.0.0 is based upon Qt 6.4
                  Qt Creator 4.11.0 is based on Qt 5.12.8
                  Qt Creator 4.5.2 is baed on Qt 5.9.5

                  ... at the moment I didn't found a version of Qt Creator based on Qt 5.15.2 and that means that plugins produced with Qt 5.15.2 are not usable.
                  Hope the only way to find this information is NOT to install each version of Qt Creator available and look into the About dialog box... (waste of time apart this could also ends with: none found).

                  jsulmJ Offline
                  jsulmJ Offline
                  jsulm
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  @Dragoon Why don't you simply use Qt version which was used to build your version of QtCreator? Why does it have to be Qt 5.15.2?

                  https://forum.qt.io/topic/113070/qt-code-of-conduct

                  DragoonD 1 Reply Last reply
                  0
                  • jsulmJ jsulm

                    @Dragoon Why don't you simply use Qt version which was used to build your version of QtCreator? Why does it have to be Qt 5.15.2?

                    DragoonD Offline
                    DragoonD Offline
                    Dragoon
                    wrote on last edited by
                    #9

                    @jsulm being 'backaward' compatible with Qt 5.15.2 is a mandatory requirement.

                    bye by[t]e{s}... Mike

                    1 Reply Last reply
                    0
                    • SGaistS SGaist

                      Hi,

                      You should check which version of Qt was used to build Qt Creator. That's the one you need to use to build your plugin.

                      DragoonD Offline
                      DragoonD Offline
                      Dragoon
                      wrote on last edited by Dragoon
                      #10

                      @SGaist I managed to compile the plugin under Qt 6.4.0 and then installed it inside

                      /opt/Qt/Tools/QtCreator/lib/Qt/plugins/designer/
                      

                      But when I open QtCreator 9.0.0 (based on Qt 6.4.0) plugins window I still got this:

                      Plugin uses incompatible Qt library (5.15.0) [debug]
                      

                      As an interesting sidenote this's qtplugininfo output:

                      qtplugininfo: libvirtualpadplugin.so: No plug-in meta-data found: The shared library was not found.
                      

                      Moreover if the qtplugininfo is run when the plugin is copied into plugin folder than the error become:

                      IID "org.qt-project.Qt.QDesignerCustomWidgetInterface" Qt 5.15.0 (debug)
                      qtplugininfo: /opt/Qt/5.15.2/gcc_64/plugins/designer/libvirtualpadplugin.so: invalid metadata, user data is not a JSON object
                      

                      bye by[t]e{s}... Mike

                      1 Reply Last reply
                      0
                      • SGaistS SGaist

                        You can download the specific Qt Creator installer.

                        DragoonD Offline
                        DragoonD Offline
                        Dragoon
                        wrote on last edited by Dragoon
                        #11

                        @SGaist I finally managed to make it work. I needed to downgrade the Qt version to 5.12.8 making a standard system wide installation on Ubuntu (trough apt of course).
                        Then I compiled the plugin and placed it into:

                        /usr/lib/x86_64-linux-gnu/qt5/plugins/designer/
                        

                        This works fine but I have a minor issue that's very annoying.
                        I would like to change the name of the widget in designer pallette from QTVirtualPad to Virtual Pad .
                        Changing plugin name() return value will disrupt everything so this's not the way... but every standard Qt component shows a name different to that of its class so it should be possibile... but how?

                        09d65ced-c737-491c-91c5-780d5fcbb49a-image.png

                        bye by[t]e{s}... Mike

                        DragoonD 1 Reply Last reply
                        0
                        • DragoonD Dragoon

                          @SGaist I finally managed to make it work. I needed to downgrade the Qt version to 5.12.8 making a standard system wide installation on Ubuntu (trough apt of course).
                          Then I compiled the plugin and placed it into:

                          /usr/lib/x86_64-linux-gnu/qt5/plugins/designer/
                          

                          This works fine but I have a minor issue that's very annoying.
                          I would like to change the name of the widget in designer pallette from QTVirtualPad to Virtual Pad .
                          Changing plugin name() return value will disrupt everything so this's not the way... but every standard Qt component shows a name different to that of its class so it should be possibile... but how?

                          09d65ced-c737-491c-91c5-780d5fcbb49a-image.png

                          DragoonD Offline
                          DragoonD Offline
                          Dragoon
                          wrote on last edited by
                          #12

                          @Dragoon I found a way to fix the name of the widget in Qt Creator palette: it's needed to add (or modify if already present) the tag displayname provided in the most external node of xml element returned by plugin's domXml() method.
                          In my code :

                          QString VirtualPadPlugin::domXml() const {
                            return "<ui language=\"c++\" displayname=\"Virtual Pad\">\n"
                          ...
                          

                          bye by[t]e{s}... Mike

                          1 Reply Last reply
                          0
                          • DragoonD Dragoon has marked this topic as solved on

                          • Login

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • Users
                          • Groups
                          • Search
                          • Get Qt Extensions
                          • Unsolved