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.5k Topics 35.0k Posts
  • Exec show hide problem i have

    Unsolved
    2
    0 Votes
    2 Posts
    15 Views
    SGaistS
    Hi and welcome to devnet, Are you trying to implement some sort of wizard ? If so, take a look a QWizard.
  • Creator very very very slow on finding/creating slot funktion from designer

    Unsolved
    3
    0 Votes
    3 Posts
    41 Views
    Andy314A
    Now I use Creator 16.0.1 for Windows. My previous version was very old 10.0.1.
  • Creator crashes by opening a special cpp-file

    Unsolved
    3
    0 Votes
    3 Posts
    118 Views
    Andy314A
    @Axel-Spoerl said in Creator crashes by opening a special cpp-file: A copy of this file, does not crash during opening, but crashed after collapsing the code view. What's the difference between the copy and the original? Network drive / local harddisk? Different network locations? Try opening the file from a hard disk and run Qt Creator from the command line with the -noload all option. It disables all plugins. The copy was in the same directory. I think the only difference was, that the Creator stores and restore the last state and it was in collapsed state. Now the file is unders some circumstances again in un-collasing state and I can work on it. Neverthlesse, I can reproducable a cash of creator with this special file with "unfold all" - I have define a hotkey for it. I can share the file, if someone will test it.
  • 0 Votes
    1 Posts
    24 Views
    No one has replied
  • Using Program Arguments with perf with Terminal Window

    Unsolved
    7
    0 Votes
    7 Posts
    562 Views
    RokeJulianLockhartR
    @Alex-sw30, you might find strace useful for debugging this, since it should display the calls Qt Creator makes to invoke your application. Whether these differ with those options enabled or not might demonstrate something of use, although it's quite verbose.
  • How to debug a qt creator build dll memory leak in exe?

    Unsolved
    1
    0 Votes
    1 Posts
    50 Views
    No one has replied
  • 0 Votes
    1 Posts
    39 Views
    No one has replied
  • Help needed using conan package manager inside QtCreator15.0.0

    Solved conan qtcreator15 cmake
    15
    0 Votes
    15 Posts
    502 Views
    S
    @cristian-adam Thanks no everything is working. <3 Really appreciate that you took the time. I'll mark this post as solved for others who may come across this post. So my learnings are: Solution/Learnings -Conan 2.0 + Qt Creator . You don't need the conan plugin for Qt Creator --> as for now March 2025; QT Version 6.9, Creator Version 16.0.0 conanfile 2.0 support for .txt and .py is build in Enable packagemanager auto setup in the cmake settings of your qt creator project If everything works fine you don't have to enter any conan command manual For anyone to copy and paste here the small demofiles for spdlog: conanfile.py: from conan import ConanFile from conan.tools.cmake import cmake_layout class ExampleRecipe(ConanFile): settings = "os", "compiler", "build_type", "arch" generators = "CMakeDeps", "CMakeToolchain" def requirements(self): self.requires("spdlog/1.15.1") def layout(self): cmake_layout(self) main.cpp: #include <iostream> #include <spdlog/spdlog.h> #include <spdlog/sinks/basic_file_sink.h> #include <spdlog/sinks/rotating_file_sink.h> #include <memory> int main() { try { // Einfacher Konsolen-Logger spdlog::info("Welcome to spdlog!"); spdlog::warn("This is a warning!"); spdlog::error("This is an error message!"); spdlog::debug("This debug message won't show unless you change the log level."); // Log-Level auf debug setzen spdlog::set_level(spdlog::level::debug); spdlog::debug("Now debug messages are visible!"); // Logger, der in eine Datei schreibt auto file_logger = spdlog::basic_logger_mt("file_logger", "logs/basic_log.txt"); file_logger->info("Logging to basic file."); file_logger->warn("Some warning in file log."); // Rotating file logger (max 5 MB pro Datei, max 3 Dateien) auto rotating_logger = spdlog::rotating_logger_mt("rot_logger", "logs/rotating_log.txt", 1048576 * 5, 3); rotating_logger->info("This is a rotating logger."); rotating_logger->error("Something went wrong in rotating logger."); // Log-Pattern ändern spdlog::set_pattern("[%Y-%m-%d %H:%M:%S.%e] %v [%l]"); spdlog::info("Using custom log pattern now."); // Flushing spdlog::flush_on(spdlog::level::info); } catch (const spdlog::spdlog_ex& ex) { std::cerr << "Log initialization failed: " << ex.what() << std::endl; return 1; } } CMakeLists.cpp: cmake_minimum_required(VERSION 3.24) set(CMAKE_CXX_STANDARD 20) project(spdlogexample) find_package(spdlog REQUIRED) add_executable(spdlogexample main.cpp) target_link_libraries(spdlogexample PRIVATE spdlog::spdlog) install(TARGETS spdlogexample)
  • How to open an exists project from the remote PC?

    Solved
    8
    0 Votes
    8 Posts
    185 Views
    SGaistS
    So it's exactly the same as for embedded systems. You cross-compile, copy and execute. Otherwise you also have VS Code (or alternatives) that have a remote dev feature through tunneling and some additional software installed on the other machine.
  • 0 Votes
    2 Posts
    107 Views
    Christian EhrlicherC
    Use a debugger and set a breakpoint in qsslsocket_openssl_symbols.cpp/tryToLoadOpenSslWin32Library: https://code.qt.io/cgit/qt/qtbase.git/tree/src/network/ssl/qsslsocket_openssl_symbols.cpp?h=5.3
  • Qt Creator 16 crash under Wayland during debugger break mode

    Solved
    4
    0 Votes
    4 Posts
    153 Views
    U
    I found that turning off the "Clang Code Model" plugin returned qt creator to normal operation, without the need for the QT_QPA_PLATFORM=xcb workaround.
  • 0 Votes
    2 Posts
    74 Views
    Axel SpoerlA
    @pi-squared said in Menu bar menu so long it cuts off, making me unable to add more buttons. (Yes, I'm being serious.): It works looks fine when running it, though. Do I understand that correctly - the first screenshot is from the Widgets Designer as part of Qt Creator, the second is from running the compiled executable? If I create large menus, I usually do it programmatically, not in Widgets Designer. I'd probably use a static constexpr std::array to store menu texts, maybe use a struct as a type that tells me whether a menu's action is enabled by default. Maybe I'd even keep an enum around that has a key for each action. Just loop over the array and add actions. That's much easier to maintain, than to change an entry in Widgets Designer. It hasn't been programmed to handle super large menus...
  • 0 Votes
    4 Posts
    116 Views
    P
    I forgot to mark it as solved
  • Disabling TMP files in Qt Creator 16.0.0

    Solved
    10
    0 Votes
    10 Posts
    305 Views
    J
    Thank you @cristian-adam That is exactly what I needed. (I searched the documentation website for that environment variable and found nothing. Where should I be looking for information on useful environment variables for Qt tools?)
  • 0 Votes
    9 Posts
    541 Views
    Christian EhrlicherC
    @m0xf Please read the documentation: https://doc.qt.io/qt-6/qqmlparserstatus.html#details "To use QQmlParserStatus, you must inherit both a QObject-derived class and QQmlParserStatus, and use the Q_INTERFACES() macro."
  • How to change font on debug views ?

    Unsolved
    1
    0 Votes
    1 Posts
    47 Views
    No one has replied
  • A single project that builds multiple executables

    Unsolved
    4
    0 Votes
    4 Posts
    150 Views
    S
    @Noobish said in A single project that builds multiple executables: The benefit would be not having to sync changes to the common code between the two projects and compiling everything would perhaps be quicker since when a common class has been compiled it does not have to be compiled again (I guess)? Put common code into a library (which would be yet another project) and link against this library for these two executables. Or, like @Christian-Ehrlicher said, combine all projects into one. Even then, it would make sense to have one library and two executables as build targets.
  • Increase font size of the project files tab

    Moved Solved
    3
    0 Votes
    3 Posts
    130 Views
    Z
    @cristian-adam said in Increase font size of the project files tab: See here https://forum.qt.io/topic/153476/how-to-increase-qt-creator-font/3?_=1747559433165 It worked. Thanks!
  • Elements added by QtDesigner does not show up in QtCreator

    Unsolved
    4
    0 Votes
    4 Posts
    111 Views
    JonBJ
    @Noobish For code completion the .ui must be processed by uic to produce the ui_....h file as C++ code. This should happen as part of build, every time you update the .ui or force clean rebuild. There are many little things you can investigate: For qmake the .h file is generated into the build output directory (where object and executable files are). I do not know for cmake, where you say you found it may be reasonable. Make sure there are no other instances of that file elsewhere which could be picked up. Update the .ui, do a build, verify the timestamp on the .h has been updated. Read the .h into Creator and have a look through it. It's just C++ code. Verify you can see the lines generated for the components you add. Forget about code completion for a moment. Type in what (you believe) is right to access some new ui-> element in your code. Do an actual compile/build. If that errors on your new component you are doing something wrong; if that succeeds but the code completion does not you have some problem in the latter area. Do a complete delete and rebuild. Create a brand new, standalone project elsewhere and see how you get on with creating new components.
  • cross-compiling from Linux to get an executable windows

    Unsolved
    2
    0 Votes
    2 Posts
    82 Views
    Christian EhrlicherC
    As the error message tells you, you forgot to specify the source directory.