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. Why changes on mainwindow.ui is not reflected when run. (solved)
Forum Updated to NodeBB v4.3 + New Features

Why changes on mainwindow.ui is not reflected when run. (solved)

Scheduled Pinned Locked Moved General and Desktop
8 Posts 5 Posters 2.5k 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.
  • H Offline
    H Offline
    houmingc
    wrote on last edited by
    #1

    After making changes to mainwindow.ui, the changes is not reflected when run.
    Time stamp on mainwindow.ui has been checked updated

    Suspect it is due to project file and object file in one folder. Like to ask how to create two seperate
    folder for each? and why changes on mainwindow.ui is not reflected when run.

    1 Reply Last reply
    0
    • bagavathikumarB Offline
      bagavathikumarB Offline
      bagavathikumar
      wrote on last edited by
      #2

      Compiling the UI done by separate compiler called uic.exe. So check your compiler output. If it throws any error post it here or clean the project completely and rebuild the project.

      1 Reply Last reply
      0
      • K Offline
        K Offline
        koahnig
        wrote on last edited by
        #3

        You need to tell more about the envirnement you are using.
        In general it is easier to use an IDE like Qt creator. It does all the organisation and handling of the different tools.

        If you are using already Qt creator, you should rerun qmake and make rebuild of teh whole project. In most cases this will solve your problem.

        Vote the answer(s) that helped you to solve your issue(s)

        1 Reply Last reply
        0
        • H Offline
          H Offline
          houmingc
          wrote on last edited by
          #4

          a Promoted class QFrame(base class name) is set in a particular position many months ago.
          Now no matter how i shift the QWidget, the widget is fixed in that particular position. The position changes on mainwindow.ui is not reflected

          1 Reply Last reply
          0
          • K Offline
            K Offline
            koahnig
            wrote on last edited by
            #5

            Have you checked if uic is started at all?

            Vote the answer(s) that helped you to solve your issue(s)

            1 Reply Last reply
            0
            • H Offline
              H Offline
              houmingc
              wrote on last edited by
              #6

              uic reads XML format ui file and generate c++ header file.
              When runnning qmake, uic will be invoked automatically.
              This is written in qt help.

              Answer is to delete c++ header file

              1 Reply Last reply
              0
              • H Offline
                H Offline
                Hyprunz
                wrote on last edited by
                #7

                A strange behavior is, that if the UI_DIR folder will define after the first run of the project and in the root project folder the ui_*.h files already exist, these files will copy from the root folder to the UI_DIR folder and don´t create new actual ones.

                I was loooking for the problem for more than one hour, until I recognize that there are ui header files in the project root folder, then I delete them and everthing works like expected.

                1 Reply Last reply
                0
                • V Offline
                  V Offline
                  Vince Golubic
                  wrote on last edited by Vince Golubic
                  #8

                  Suggestion. You might also check your .pro file. As you may recall, qmake will create the Makefile and your ui_ prefixed .h files will be generated by uic compiler. Typically placed in a .ui folder in your project, but you can over ride this and specify another location (if you wish).

                  Make sure you specify the correct .ui directories and/or correct project directories. They may be
                  going to another directory (see also Makefile) location than you expect. One thing you can also do
                  is create a softlink (use: ln -s ) from .ui fiolder header files to project folder you want to specify (as another way to do that) as indicated in your .pro file.

                  I've done that myself many times myself and saw no UI changes ..then said ..duh! ..lol

                  -Vince

                  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