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. How to add a UI file afterwards
QtWS25 Last Chance

How to add a UI file afterwards

Scheduled Pinned Locked Moved General and Desktop
6 Posts 2 Posters 6.8k Views
  • 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.
  • H Offline
    H Offline
    h3rky
    wrote on last edited by
    #1

    hi all,

    i'm having a hard time adding a ui file to custom widget for qt designer (.pri). could some point me into the right direction?

    in fact, this may - or may not :D - sound strange to some cpp gozu, still i would like to know how to do that so i can bundle together some widgets and use them as "custom widgets" in the external Qt Designer.

    tia!

    h3rky

    1 Reply Last reply
    0
    • A Offline
      A Offline
      andre
      wrote on last edited by
      #2

      Just add a like like this to the .pri file?

      @
      FORMS += mySuperCoolFormFile.ui
      @

      I do that all the time, and it works just fine for me. What exactly is your problem?

      1 Reply Last reply
      0
      • H Offline
        H Offline
        h3rky
        wrote on last edited by
        #3

        thank you for your reply,

        i just tried that.

        my exact problem is that the generated plugin has no content. in my test case its just a collection of widget positioned next to each other (myevencoolerwidget.ui) - what i expect is to see my collection when i drag and drop my test1 widget in qt designer. instead its just a minimum sized empty and transparent "nothing". i can resize it, thats all :P

        thx again for answers ia,

        h3rky

        1 Reply Last reply
        0
        • A Offline
          A Offline
          andre
          wrote on last edited by
          #4

          Ah... so you are building a designer plugin? That is a bit more involved than just constructing a .pri file...

          1 Reply Last reply
          0
          • H Offline
            H Offline
            h3rky
            wrote on last edited by
            #5

            ;-) ... so could you be a bit more precise about the mentioned "involvingness" ...

            i do know that this way i can code what i want to have on my own and then use it in the qt designer (for instance to have a push button with a different example label ... ), but i'm trying to do so with less typing and more usage of the designer as i want to bundle some widgets together

            this way i can use them as one and don't have to re-arrange the same setup all the time. copy & paste worked out being a mucho headache because sometimes it's seriously hard to paste stuff at the right position and so on ... (alike exploding layouts because something little has to be changed)

            greets,

            1 Reply Last reply
            0
            • A Offline
              A Offline
              andre
              wrote on last edited by
              #6

              [quote author="h3rky" date="1301588003"];-) ... so could you be a bit more precise about the mentioned "involvingness" ...
              greets,[/quote]

              Well, you might start with the designer manual then on this "topic":http://doc.qt.nokia.com/latest/designer-creating-custom-widgets.html.

              1 Reply Last reply
              0

              • Login

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