Skip to content

Qt 6

This is where all Qt 6 related questions belong

816 Topics 3.9k Posts
QtWS25 Call for Papers
  • 0 Votes
    4 Posts
    473 Views
    R

    Closing - files are in qrc system. Codegen errors are likely just due to some setting that is on a more sensitive setting.

  • QLocation and QTextToSpeech in Qt 6.x

    Moved Unsolved
    3
    0 Votes
    3 Posts
    174 Views
    SGaistS

    Hi,

    There's currently work in progress to bring QtLocation to Qt 6.

    If memory serves well you should be able to build both modules yourself.

  • Building Qt-6.2.3 on Windows has troubles with tiff

    Solved
    8
    0 Votes
    8 Posts
    771 Views
    S

    I walked around the issue by specifying "-qt-zlib" instead of "-system-zlib".
    Customizing building Qt is really hard.
    Thanks @jsulm .

  • How to unset QMenu from QPushButton?

    Solved
    5
    0 Votes
    5 Posts
    305 Views
    Christian EhrlicherC

    @DeeDee14 Then you're doing something wrong. It works as expected, also the code explicitly allows this.

    QPushButton pb; QMenu *myMenu = new QMenu; pb.setMenu(myMenu); QTimer::singleShot(2000, &pb, [&]() { pb.setMenu(nullptr); }); pb.show();
  • qtwebview and webworkers

    Unsolved
    1
    0 Votes
    1 Posts
    104 Views
    No one has replied
  • 0 Votes
    2 Posts
    383 Views
    Christian EhrlicherC

    If you want to validate xml you should use XSLT

  • How to get screen size in PyQt6?

    Unsolved
    3
    0 Votes
    3 Posts
    3k Views
    Christian EhrlicherC

    QScreen should also be available for PyQt.

  • Analog of QWinTaskbarProgress in Qt 6

    Unsolved
    2
    0 Votes
    2 Posts
    554 Views
    Christian EhrlicherC

    See https://forum.qt.io/topic/131934 - no more news on this.

  • 0 Votes
    5 Posts
    1k Views
    J

    @jsulm Thank you very much !

    It's exactly what I needed.

    In the top !

  • Ability to process mouse events in a mask

    Unsolved
    7
    0 Votes
    7 Posts
    579 Views
    C

    Yeah, already tried these with no luck.
    Because with setWindowFlag(Qt::WindowTransparentForInput, true) or using QWidget::setMask, QApplication::event() isn't called anyway.

  • QtCreator open source installation error

    Solved
    13
    0 Votes
    13 Posts
    1k Views
    C

    @jsulm Thank you .......
    I can't believe you helped me so patiently throughout this whole process. I really really appreciate your help, Sir. I am so grateful to you.

  • Qt 6.2.2 and QtQuickExtras

    Unsolved
    2
    0 Votes
    2 Posts
    208 Views
    M

    Hello
    try with core5compact
    https://doc.qt.io/qt-6/qtcore5-index.html

  • How add Qpushbutton in QLineEdit with PyQt6 ?

    Solved
    5
    0 Votes
    5 Posts
    278 Views
    J

    @jsulm said in How add Qpushbutton in QLineEdit with PyQt6 ?:

    QPushButton

    Thank you very much jsulm, I looked at the doc and that's exactly it

  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    58 Views
    No one has replied
  • how to make a window in the middle of the screen?

    Unsolved
    4
    0 Votes
    4 Posts
    928 Views
    Christian EhrlicherC

    All I can say it works fine for me with Qt6.dev on Linux.

  • how to get the current height and width of the window?

    Unsolved
    5
    0 Votes
    5 Posts
    445 Views
    JonBJ

    @aria_aa
    One way is to subclass your QWidget and override void QWidget::showEvent(QShowEvent *event), and read the size there.

  • Temporary files after debugging any QT program

    Unsolved
    5
    0 Votes
    5 Posts
    336 Views
    S

    @JonB,
    Yes, maybe MinGW debugger. 4.jpg 3.jpg 2.jpg 1.jpg

  • How to create a custom QML item on Qt6+CMake ?

    Unsolved
    2
    0 Votes
    2 Posts
    282 Views
    R

    Ok. I've found example of CMakeLists.txt in Qt6 repo.

    it works if apply all sources of sub-item to main executable
    like

    qt_add_executable(chapter1-basics main.cpp piechart.cpp piechart.h )

    but is there way to separate sub-item as external library ?
    something like a

    qt_add_executable(chapter1-basics main.cpp ) ... qt_add_library(lib_piechart piechart.cpp piechart.h) target_link_libraries(lib_piechart PUBLIC Qt::Core Qt::Gui Qt::Qml Qt::Quick) target_link_libraries(chapter1-basics PRIVATE lib_piechart)
  • Qt 6.2, QML Camera, change resolution on image capture

    Unsolved
    3
    0 Votes
    3 Posts
    967 Views
    R

    I have the following solution:

    QML:

    CaptureSession { id: captureSession videoOutput: videoOutput Component.onCompleted: { camera.cameraFormat = classPhoto.getCameraFormat(); camera.start() } ...

    C++

    Q_INVOKABLE QCameraFormat getCameraFormat() const { auto formats = QMediaDevices::defaultVideoInput().videoFormats(); for (const auto &format : formats) { if (format.resolution() == ***) { return format; } } return QCameraFormat(); }
  • Error on Qt 6 Building from source for Windows Based

    Solved
    59
    0 Votes
    59 Posts
    12k Views
    N

    Thank you !

    Following your advise, I comment llvm, clang, perl, g++ so thery are out of PATH env var ( and after some where verifications), then launch configure.bat as described by official doc step-4-build-the-qt-library from src path like that :

    ********************************************************************** ** Visual Studio 2019 Developer Command Prompt v16.11.6 ** Copyright (c) 2021 Microsoft Corporation ********************************************************************** [vcvarsall.bat] Environment initialized for: 'x64' C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional>d: D:\>cd Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2 D:\Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2>where where C:\Windows\System32\where.exe D:\Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2>where clang Information : impossible de trouver des fichiers pour le(s) modèle(s) spécifié(s). D:\Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2>where perl Information : impossible de trouver des fichiers pour le(s) modèle(s) spécifié(s). D:\Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2>where ninja C:\ninja-win\ninja.exe C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\Common7\IDE\CommonExtensions\Microsoft\CMake\Ninja\ninja.exe D:\Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2>where g++ Information : impossible de trouver des fichiers pour le(s) modèle(s) spécifié(s). D:\Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2>where gcc Information : impossible de trouver des fichiers pour le(s) modèle(s) spécifié(s). D:\Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2>where cmake C:\CMake\bin\cmake.exe C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin\cmake.exe D:\Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2>configure.bat + cd qtbase + D:\Logiciels\Qt\6.2.2\qt-everywhere-src-6.2.2\qtbase\configure.bat -top-level

    This is the CMakeError.log

    Checking whether the ASM compiler is GNU using "--version" did not match "(GNU assembler)|(GCC)|(Free Software Foundation)": Compilateur d'optimisation Microsoft (R) C/C++ version 19.29.30137 pour x64 Copyright (C) Microsoft Corporation. Tous droits réservés. cl : Ligne de commande warning D9002 : option '--version' inconnue ignorée cl : Ligne de commande error D8003 : nom de fichier de la source absent Checking whether the ASM compiler is Clang using "--version" did not match "(clang version)": Compilateur d'optimisation Microsoft (R) C/C++ version 19.29.30137 pour x64 Copyright (C) Microsoft Corporation. Tous droits réservés. cl : Ligne de commande warning D9002 : option '--version' inconnue ignorée cl : Ligne de commande error D8003 : nom de fichier de la source absent Checking whether the ASM compiler is AppleClang using "--version" did not match "(Apple LLVM version)": Compilateur d'optimisation Microsoft (R) C/C++ version 19.29.30137 pour x64 Copyright (C) Microsoft Corporation. Tous droits réservés. cl : Ligne de commande warning D9002 : option '--version' inconnue ignorée cl : Ligne de commande error D8003 : nom de fichier de la source absent Checking whether the ASM compiler is ARMClang using "--version" did not match "armclang": Compilateur d'optimisation Microsoft (R) C/C++ version 19.29.30137 pour x64 Copyright (C) Microsoft Corporation. Tous droits réservés. cl : Ligne de commande warning D9002 : option '--version' inconnue ignorée cl : Ligne de commande error D8003 : nom de fichier de la source absent Checking whether the ASM compiler is HP using "-V" did not match "HP C": Compilateur d'optimisation Microsoft (R) C/C++ version 19.29.30137 pour x64 Copyright (C) Microsoft Corporation. Tous droits réservés. cl : Ligne de commande error D8004 : '/V' nécessite un argument Checking whether the ASM compiler is Intel using "--version" did not match "(ICC)": Compilateur d'optimisation Microsoft (R) C/C++ version 19.29.30137 pour x64 Copyright (C) Microsoft Corporation. Tous droits réservés. cl : Ligne de commande warning D9002 : option '--version' inconnue ignorée cl : Ligne de commande error D8003 : nom de fichier de la source absent Checking whether the ASM compiler is IntelLLVM using "--version" did not match "(Intel[^ ]+oneAPI)": Compilateur d'optimisation Microsoft (R) C/C++ version 19.29.30137 pour x64 Copyright (C) Microsoft Corporation. Tous droits réservés. cl : Ligne de commande warning D9002 : option '--version' inconnue ignorée cl : Ligne de commande error D8003 : nom de fichier de la source absent Checking whether the ASM compiler is SunPro using "-V" did not match "Sun C": Compilateur d'optimisation Microsoft (R) C/C++ version 19.29.30137 pour x64 Copyright (C) Microsoft Corporation. Tous droits réservés. cl : Ligne de commande error D8004 : '/V' nécessite un argument Checking whether the ASM compiler is XL using "-qversion" did not match "XL C": Compilateur d'optimisation Microsoft (R) C/C++ version 19.29.30137 pour x64 Copyright (C) Microsoft Corporation. Tous droits réservés. cl : Ligne de commande warning D9002 : option '-qversion' inconnue ignorée cl : Ligne de commande error D8003 : nom de fichier de la source absent

    Amazing.