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 use ui form in anthoer ui from directly without c++ codes.
Forum Updated to NodeBB v4.3 + New Features

How to use ui form in anthoer ui from directly without c++ codes.

Scheduled Pinned Locked Moved General and Desktop
4 Posts 4 Posters 969 Views 1 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.
  • L Offline
    L Offline
    lygstate
    wrote on last edited by
    #1

    So we can easily design qt ui files.

    1 Reply Last reply
    0
    • X Offline
      X Offline
      xXDarkShadowXx
      wrote on last edited by
      #2

      I don't think it's possible, even when using C++ code.

      Because in order to access MainWindow.ui inside MainDialog.ui you'd have to make the object used to display MainWindow.ui global by using extern.

      And every time I've tried to make a .ui object global, my compiler exploded and threw this at me.

      @QWidget: Must construct a QApplication before a QPaintDevice@

      You can test it if you want, go to your main.cpp file and place MainWindow w; outside of your int main() function, chances are your compiler is gonna explode as well.

      1 Reply Last reply
      0
      • J Offline
        J Offline
        jakakishan
        wrote on last edited by
        #3

        its not possible,
        have to make object for this.

        Jkishan

        1 Reply Last reply
        0
        • JeroentjehomeJ Offline
          JeroentjehomeJ Offline
          Jeroentjehome
          wrote on last edited by
          #4

          Hi,
          You might want to look into how to use ui designer forms in Qt.
          "Designer Ui files in Application":http://qt-project.org/doc/qt-5.0/qtdesigner/designer-using-a-ui-file.html
          It tells you all about the use of the form files.

          Without C++ code?? What do you want to achieve?? Use the same form in multiple dialogs? Change the form for an used dialog??
          Maybe if you tell what you want, we are of more help.

          Greetz, Jeroen

          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