Questions tagged [qt6]

For questions specific to version 6 of Qt.

Qt6 was released in late 2020 and features some incompatibilities with the Qt5 release.

See: , , , etc.

Differences from Qt5


References

694 questions
0
votes
0 answers

Qt Designer 5.11.1 doesn't set the font weight to the correct type

I get the following error when I run cmake: C:/Users/Owner/OneDrive/Documents/BJT/src/ui_BJT.h:126:24: error: invalid conversion from 'int' to 'QFont::Weight' [-fpermissive] font.setWeight(75); ^~ In file included…
Doug Fulford
  • 49
  • 11
0
votes
1 answer

qt6: Connect QFileDialog::filesSelected to a slot

Essentially I want to trigger some code after the my QFileDiag has 1 or more files selected and is accepted ("open" button clicked), the problem is that I can't seem to actually trigger my code in the slot. Here is the code in my main…
0
votes
0 answers

QT QStringList data is being added stored JSON data

In short, what is happening is I am making QStringList object and then manually adding a entry at the front called "Item Types:". Then I am taking data from the JSON file and adding it to the QStringList. Then using the addItems function for a…
laxer
  • 720
  • 11
  • 41
0
votes
0 answers

Wy is QMetaObject::invokemethod searching for a function from the wrong object

In my work project I have run into a particularly strange behaviour. During runtime, when calling QMetaObject::invokeMethod, I get a print indicating that the program is trying to find the specified method from QObject, instead of the actual class…
Narmondur
  • 111
  • 1
  • 2
  • 7
0
votes
0 answers

Qt crashes while iteracting with QTableWidget

I have a simple Qt application which is mainly based around a QTableWidget, in there I have to display data that I get from a server and the user must be able to modify and save the data. I'm still setting up my application, the problem is that I…
0
votes
1 answer

QT6.1 - Qml Why does the ProgressBar not have an animation corresponding to the indeterminate property?

As the title says, I set the indeterminate property of the ProgressBar to True, but he doesn't have any animation. Just like this: But: I use the default project and the code is very simple. I would like to know if the indeterminate itself does not…
0
votes
0 answers

How to disable Qt print "QWidget::repaint: Recursive repaint detected"

I'm using Qt6.1 and I want send my widget's pixmap when it painted. I have similar code: void MyWidget::paintEvent(QPaintEvent*) { // static bool callGrab = true; // m_callGrab initialize with true if (m_callGrab) { m_callGrab…
Cwift
  • 300
  • 1
  • 6
0
votes
1 answer

Cannot install Charts in QT

I cannot install charts in QT. I don't know why. I'm using gnu gpl v3 license. OS system: Windows 10. Do you know why this is happening?
euraad
  • 2,467
  • 5
  • 30
  • 51
0
votes
2 answers

Qt Scanning Wi-Fi with QT6

QNetworkAccessManager is removed in QT6. Has anybody an idea on how to get available SSIDs with QT6 / without QNetworkAccessManager / QNetworkconfiguration?
Flow
  • 65
  • 7
0
votes
0 answers

How to make a QTextFrame with rounded corners?

Main Application: I am trying to creating a text editor with Qt6, C++, and QTextEdit. Goal: I want to implement functionality that will allow me to insert a code block in my rich text editor, much like that you usually see in StackOverflow. The code…
Attitude12136
  • 47
  • 2
  • 9
0
votes
1 answer

What is equivalent of qmake (.pro file) CONFIG -= console in CMAKE

I have build QML application and run it. But besides of GUI running console. I know how switch off console in qmake (.pro file) CONFIG -= console. But I do not understand how it works in CMake? I tried QML opens GUI window and console but it does…
0
votes
1 answer

Bazel rules for Qt6 on Linux: How to copy required libs?

Currently, I am working on an experiment to support Qt6 via Bazel. My code can be found here. On Linux with Bazel and GCC9 installed you can test my Qt6 Bazel rules via: git clone https://github.com/Vertexwahn/rules_qt6 cd rules_qt6 bazel run…
Vertexwahn
  • 7,709
  • 6
  • 64
  • 90
0
votes
0 answers

QMetaType confuses two symbols with identical name but different namespace

Consider the following minimal example: namespace foo { struct MyStruct {}; } Q_DECLARE_METATYPE(foo::MyStruct) namespace bar { struct MyStruct {}; } Q_DECLARE_METATYPE(bar::MyStruct) // later on near the entry point of the…
Petr Mánek
  • 1,046
  • 1
  • 9
  • 24
0
votes
1 answer

QtConcurrent::mappedReduced without mapped

Consider the following code (Qt 6.0.3, C++17): const QVector arr = {1, 2, 3, 4, 5}; auto future = QtConcurrent::mappedReduced(arr, [](auto item) { return item; }, [](int& result, auto item) { result += item; }); As you can see the…
Roman Podymov
  • 4,168
  • 4
  • 30
  • 57
0
votes
1 answer

QPSQL driver not loaded (Qt6, Postgres-13)

I try to repeat QPSQL driver not loaded Qt but it does not helped me. I used x64 Postgresql and my Qt application also x64 m_dataBase.addDatabase("QPSQL"); m_dataBase.setHostName(g_hostName); m_dataBase.setPort(g_databasePort); …