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. Making a Qt custom widget without Qt Creator
Forum Updated to NodeBB v4.3 + New Features

Making a Qt custom widget without Qt Creator

Scheduled Pinned Locked Moved Solved General and Desktop
40 Posts 4 Posters 14.5k 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.
  • P Panoss

    It will run on Win 10, Win 7 and XP.

    mrjjM Offline
    mrjjM Offline
    mrjj
    Lifetime Qt Champion
    wrote on last edited by mrjj
    #29

    @Panoss
    Ok. just asking as XP is not on ppl mind anymore.
    https://forum.qt.io/topic/73292/the-last-qt-version-that-supported-windows-xp

    Sounds like using 5.6 is the best bet :)

    Did u try that version of Creator on xp?

    It didn't start or ?

    Note that Xp in virtual machine do not have openGL (often) and can only work if started with some option
    https://forum.qt.io/topic/36827/qt-creator-3-0-welcome-mode-not-working-in-virtualbox-vm

    like
    c:\path\qtcreator -noload Welcome -noload QmlDesigner -noload QmlProfiler

    1 Reply Last reply
    0
    • P Offline
      P Offline
      Panoss
      wrote on last edited by
      #30

      On XP I haven't tried Qt Creator yet.
      I was thinking of trying an older version, and adjusting the code where necessary.

      mrjjM 1 Reply Last reply
      0
      • P Panoss

        On XP I haven't tried Qt Creator yet.
        I was thinking of trying an older version, and adjusting the code where necessary.

        mrjjM Offline
        mrjjM Offline
        mrjj
        Lifetime Qt Champion
        wrote on last edited by
        #31

        @Panoss
        well if u go back to Qt4 then all plugin stuff is a bit different. ( from Qt5 series)
        So would be great if 5.6 can be used. :)

        1 Reply Last reply
        0
        • P Offline
          P Offline
          Panoss
          wrote on last edited by
          #32

          Ok, I installed VS 2015 and the debugger (Windows 10 SDK).
          Qt Creator auto-detected the VS compiler and a CDB debugger (this must be from Windows 10 SDK).
          This means I 'm ready?
          So how do I compile a plugin to dll?

          1 Reply Last reply
          0
          • SGaistS Offline
            SGaistS Offline
            SGaist
            Lifetime Qt Champion
            wrote on last edited by
            #33

            Start a "Qt Custom Designer Plugin" project and it will be all prepared for that. This one is under "Other project" in the "New File or Project" dialog.

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

            1 Reply Last reply
            1
            • P Offline
              P Offline
              Panoss
              wrote on last edited by Panoss
              #34

              I make a New Project->Qt Custom Designer Widget, Name: I enter 'AnalogClock'->Next but I see no VS kit:

              alt text

              And no VS kit is auto detected.
              Maybe I should add manually a VS kit?

              Should I make two projects? The 'main' project in wich the widget will be used, and the project of the widget (plugin)?

              1 Reply Last reply
              0
              • P Offline
                P Offline
                Panoss
                wrote on last edited by Panoss
                #35

                I tried to add a kit manually, but it raises errors:
                alt text

                (I changed C++ compiler from MingW to VS2015)

                EDIT: Ok, I had forgotten in Maintenance tool to add, at Qt5.8: msvc2015 32-bit, I'm adding it right now.

                1 Reply Last reply
                1
                • P Offline
                  P Offline
                  Panoss
                  wrote on last edited by Panoss
                  #36

                  Ok, after adding msvc2015 32-bit in Maintenance tool, everything seems ok.
                  I built the poject, and a dll was created(!!wow) in my project 's debug folder.

                  I also now have two folders:
                  c:\qt\5.8\mingw53_32\bin and
                  c:\qt\5.8\msvc2015\bin
                  which have a designer.exe inside.
                  I run them both (I suppose the one that should show my plugin is the msvc2015\bind\designer.exe) but in none of them appears my plugin.
                  Also the dll of my plugin was not copied in any of the folders of c:\qt\5.8.

                  jsulmJ 1 Reply Last reply
                  0
                  • P Panoss

                    Ok, after adding msvc2015 32-bit in Maintenance tool, everything seems ok.
                    I built the poject, and a dll was created(!!wow) in my project 's debug folder.

                    I also now have two folders:
                    c:\qt\5.8\mingw53_32\bin and
                    c:\qt\5.8\msvc2015\bin
                    which have a designer.exe inside.
                    I run them both (I suppose the one that should show my plugin is the msvc2015\bind\designer.exe) but in none of them appears my plugin.
                    Also the dll of my plugin was not copied in any of the folders of c:\qt\5.8.

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

                    @Panoss Try to copy the manually to plugins/designer directory in your msvc2015 Qt installation.

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

                    1 Reply Last reply
                    0
                    • P Offline
                      P Offline
                      Panoss
                      wrote on last edited by Panoss
                      #38

                      I copied it in C:\Qt\5.8\msvc2015\plugins\designer, but it failed: 'uses incompatible Qt library. Cannot mix debug and release libraries':
                      alt text

                      mrjjM 1 Reply Last reply
                      0
                      • P Panoss

                        I copied it in C:\Qt\5.8\msvc2015\plugins\designer, but it failed: 'uses incompatible Qt library. Cannot mix debug and release libraries':
                        alt text

                        mrjjM Offline
                        mrjjM Offline
                        mrjj
                        Lifetime Qt Champion
                        wrote on last edited by
                        #39

                        @Panoss
                        Try to build it in Release mode and then copy.

                        1 Reply Last reply
                        1
                        • P Offline
                          P Offline
                          Panoss
                          wrote on last edited by Panoss
                          #40

                          In the Qt Creator 's 'Release' button, I chose 'release', and build.
                          In folder C:\Documents\QtProjects\AnalogClockB\build-AnalogClockB-Desktop_Qt_5_8_0_MSVC2015_32bit-Release\release
                          a dll was created!!! I copied it in C:\Qt\5.8\msvc2015\plugins\designer....and...it appeared in Qt Designer!!! Wow!!

                          Thank you all guys, your help was great!

                          1 Reply Last reply
                          1

                          • Login

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