Skip to content

Qt Creator and other tools

Have a question about Qt Creator, our cross-platform IDE, or any of the other tools? Ask here!
7.6k Topics 35.5k Posts
  • use -v to see invocation ??

    Unsolved
    3
    0 Votes
    3 Posts
    479 Views
    A
    @JonB said in use -v to see invocation ??: LIBS += -v Adding to .pro , either way, did not show and more erro details . Here is the latest snippet of the output make[1]: Leaving directory '/mnt/A_BT_DEC10/BT__PROGRAMS/A_MAR7_MAR15/A_MAR7_MAR17/TEST_PROJECT' /usr/bin/ld: /usr/bin/ld: DWARF error: invalid or unhandled FORM value: 0x23 mainwindow.o: in function MainWindow::menu_slot_indexed(int)': mainwindow.cpp:(.text+0x965b): undefined reference to terminal_ORIGINAL_MainWindow::terminal_ORIGINAL_MainWindow(QWidget*)' clang: error: linker command failed with exit code 1 (use -v to see invocation) make[1]: Leaving directory '/mnt/A_BT_DEC10/BT__PROGRAMS/A_MAR7_MAR15/A_BT_LIBRARY/mdi' make[1]: *** [Makefile:293: mdi] Error 1 make: *** [Makefile:596: sub----A_BT_LIBRARY-mdi-make_first] Error 2 13:41:19: The process "/usr/bin/make" exited with code 2. Error while building/deploying project A_Mar7_MAR17 (kit: Qt 5.15.2 (gcc_64)) When executing step "Make" 13:41:19: Elapsed time: 00:29. there is one more not analyzed error : /usr/bin/ld: /usr/bin/ld: DWARF error: invalid or unhandled FORM value: 0x23 I could use some help with
  • How to change keyboard shortcuts for copying and paste from and to Qt internal terminal

    Moved Unsolved
    4
    0 Votes
    4 Posts
    425 Views
    J
    @JacobNovitsky this worked control c for copy to Qt Creator and from Qt Creator inner terminal [image: ddf56756-4a09-4c94-b8d0-3a2eb9952ee1.png]
  • Why does the mousePressEvent function not be called when the mouse clicks on textedit?

    Unsolved
    7
    0 Votes
    7 Posts
    755 Views
    A
    @jsulm it doesn't go into the if .I guess it was intercepted by something when I clicked.
  • How to use QMAKE_EXTRA_COMPILERS to run rcc -binary

    Unsolved
    7
    0 Votes
    7 Posts
    2k Views
    S
    Chiming in 5 years later. CONFIG needs to be capitalized, and I found that I also had to add target_predeps to get mine to work. resource_build.CONFIG += no_link target_predeps
  • I'm back with a GPU.. Qt Creator still not working

    Unsolved
    144
    0 Votes
    144 Posts
    67k Views
    M
    @Momo007 I figured out how to add the function in Qt Design Studio. I will explain it for anyone else who ends up here. Apologies in advance if any of this is wrong or bad practice, but there was nothing else to go by. Say your ui file is Main.ui.qml and it has a button, and you want to trigger a function with the onClick. Now you need to switch things around because you want this: MainForm.ui.qml = UI code Main.qml = Override with anything that can't go in the ui file Technically the 'MainForm' name can be anything you want except for 'Main' so long as it is referenced by Main, but I think it is a good naming standard for clarity. So the first step is to rename your Main.ui.qml file to MainForm.ui.qml. Now you need to create a QML file that will hold all your logic. I couldn't find a way to create a blank QML file in desginer really. I suppose I could have gone into the terminal and touched the file. What I did was just use File->New File..->QML Files->listModel. Name it Main.qml. Then when the component editor comes up just delete all the code keeping in mind to leave the import or add any others you need, and add: MainForm { id: mainRoot } Inside this object is where you put all your functions and any other things that go with the functionality of the UI. Note that you are instantiating the form component with all the real QML and anything you add to here will override that component. Moving along... Now you need to manually add the onClick handler and the function. So add the function to your Main component: MainForm { id: formMainRoot function handleClicked() { console.log("HANDLE CLICKED"); } } After I added the function I did not see it in the 'Connections' selection for the button until after I manually edited the button with it, though it may have appeared with time. It did appear after I made the setting in the code, don't know what magic happens in the background. So you also need to modify the handler in the button manually as below: Button { id: button text: qsTr("Button") Connections { target: button onClicked: formMainRoot.handleClicked() } } This worked for me in the executed version. My preferred way to do it though will be switched up, because it keeps all the manual editing out of the UI file which is the main intent, I think. To do it this way you need to make the button visible to the parent Main component which will allow it to modify the button. Select your button in the 2D editor and click on the @ to the right of the id field. This will create an alias at the top of the component, thus making the button visible. I found that I had to do this through the UI rather than adding the alias code or the compile wouldn't work. Now instead of modifying the MainForm file, just put it all in the Main component: MainForm { id: formMainRoot function handleClicked() { console.log("HANDLE CLICKED"); } Connections { target: button onClicked: handleClicked() } } I hope this unconfuses some people. I pieced this together through many bits I found on the internet. I do not know why this is not explained anywhere. Obviously you could adapt this to do basically anything you wanted. It's quite a nice way to separate things, but at a cost of having to flip between two files all the time as well as flipping from 2D to code tabs, to get essentially one thing done.
  • Problem in setting up Android with Qt 6.7

    Unsolved
    1
    0 Votes
    1 Posts
    150 Views
    No one has replied
  • QtCreator use gdb as debugger is quite slow

    Unsolved
    6
    0 Votes
    6 Posts
    1k Views
    F
    @andr hi, thanks for your answer, but I've tried your suggestion, it doesn't help. it looks like when qtcreator use the gdb debugger, it always try to ask the debugger to find out the qt binary debugg info? that's wired.
  • Qtdesigner: how radio button group together?

    6
    1 Votes
    6 Posts
    69k Views
    K
    @andre thanks. it's 2024 now and this tips still work. and it also work with checkboxes too.
  • Question about qml2puppet binary

    Unsolved
    2
    0 Votes
    2 Posts
    274 Views
    jsulmJ
    @Mlibu said in Question about qml2puppet binary: Does this mean that I need GCC 10 installed to execute it properly? No, it doesn't matter what compiler was used to build a tool.
  • where is my C code?

    Unsolved
    12
    0 Votes
    12 Posts
    1k Views
    A
    @Pl45m4 This "discussion" did provide SOME help in implementing / tracking basic SIGNAL / SLOT (concept) as defined by Qt. And I do appreciate that. However, it got diverted off the original post and is no longer of (any) help TO ME personally. It is up to the forum users to continue with various speculations and terminology variations. I am "over and out "....
  • Qt creator 4.2.1 UI is huge and doesn't fit on my screen

    Solved
    7
    0 Votes
    7 Posts
    6k Views
    S
    @mrjj said in Qt creator 4.2.1 UI is huge and doesn't fit on my screen: -platform windows:dpiawareness=0 Yeah, the "-platform windows:dpiawareness=0" option worked for me.
  • auto-connect - questions

    Unsolved
    2
    0 Votes
    2 Posts
    313 Views
    Axel SpoerlA
    why is is called "auto_connect" if there is no word (in recommended code format ?) not even close to say "auto_connect" ? What „is is“ called „auto_connect“? I can’t find that anywhere in the documentation. If you mean the on_objectName_slotName syntax: it has been chosen because it’s nicely human readable. OK, it works when inheritance is in place , however, does that means they have "parent / child " relations too? Parent / child hierarchy has little to do with inheritance, and nothing with signal/slot connections. You can make connections between any two classes as long as both inherit from QObject. Their parental relationship is irrelevant for that purpose.
  • QT Creator Erroneuos Highlighting on Jetson Orin Nano Development Kit

    Moved Unsolved
    2
    0 Votes
    2 Posts
    365 Views
    I
    More info on Qt Creator version Qt Creator 4.11.0 Based on Qt 5.12.8 (GCC 9.3.0, 64 bit)
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    6 Views
    No one has replied
  • Any way of disabling mnemonic shortcuts in QT Creator?

    Moved Unsolved
    2
    0 Votes
    2 Posts
    429 Views
    SGaistS
    Hi and welcome to devnet, From a very quick look, you might be able to do that using the eMacs keys plugin. It might be a bit too specific though. You might want to consider opening a feature request to add that as a more global feature.
  • Go forward / backward arrows...

    Unsolved
    2
    0 Votes
    2 Posts
    280 Views
    Axel SpoerlA
    @AnneRanch Try this to see all keyboard shortcuts in Creator. CTRL+L is the default keyboard shortcut to jump to a specific line. If you open a file with the locator (CTRL+K), you can add line and column by adding e.g. „:42:13“ to the file name.
  • Project setup language supply

    Unsolved
    1
    0 Votes
    1 Posts
    144 Views
    No one has replied
  • QT IFW PerformInstallationPageCallback

    Unsolved
    1
    0 Votes
    1 Posts
    188 Views
    No one has replied
  • Could you guys explain the differences between versions of Qt?

    Solved
    14
    0 Votes
    14 Posts
    4k Views
    jsulmJ
    @Teemo-of-LOL said in Could you guys explain the differences between versions of Qt?: but I think installing 5.15.2 would be more convenient for me Yes, this is the easiest option and as long as you do not experience any bugs which were fixed in newer versions there is no need to go for newer versions.
  • 0 Votes
    5 Posts
    560 Views
    T
    @jsulm After reading the bug website, this issue is indeed a bug, and QT has not yet resolved it. Thank you for your reply