Qt quick controls ScrollView
I didn't found any good resource how to use this component and it still fails layout of my app (check that right properties inspector). What i did wrong?without ScrollViewwith ScrollViewscroll that...
View ArticleHow to create grouped/nested properties?
I am trying to do nested properties like 'font.family' or 'anchors.fill', but I cannot initialize them in normal way because it prints 'Cannot assign to non-existent property'. Instead I am forced to...
View ArticleHow to debug a Qt library to find out which draw the UI element?
I'm learning https://github.com/KDAB/KDDockWidgets. I forked here for updating the example code (https://github.com/mrviit/KDDockWidgets). I also update the code changes for this issue...
View ArticleQt 5.15.2 item disappear when used in StackView
I have this QML files//main.qmlimport QtQuick 2.9import QtQuick.Window 2.2import QtQuick.Controls 2.2Window { visible: true width: 640 height: 480 title: qsTr("Hello World") Component { id: firstPage...
View ArticleAuto Scroll qt quick virtual keyboard
I want to use qt virtual keyboard in a login screen. And when the user taps on the page, my input box is moved to line edit at the top of the page.Qt's example was not understandable to me at all and I...
View ArticleCoding QML where properties like 'parent.horizontalCenter' are not being...
The auto-completed Can`t give me parent.horizontalCenter or bottom When I write "parent.hor" or "parent.bot" but other parameter can show such as height,width.my Qt version is 6.7.1 which compile with...
View ArticleSpeed gauge needle malfunction
i'm trying to create a speed gauge with a custom needle, and when i try to run the code weird things happen to my needle. It has it's own qml file the code is down below and i called it as a omponent...
View ArticleAccessing Qt Quick ListView model from the nested elements in a custom delegate
I'm having difficulty finding the idiomatic way to access ListView's model from its delegate in QML.Consider the following fairly simple custom delegate that supports a checkbox near the item and...
View Articleautoresize text in qml
In the process of studying QML and QtQuick, the following question arose. How can I make the text automatically reduce the font size by decreasing the element in which it is located. Now I have this...
View ArticleHow to set the font size of a list header to a consistent value
I am trying to set the header of a ListView to a consistent font sizes. Given that I also need it to automatically grow based on the height and width of the container, how can I achieve a good-looking...
View ArticleAutosizing the pixel size of text based on text length or size using...
I am trying to use fontSizeMode in order to fix a large text in a rectangle.import QtQuick 2.9import QtQuick.Window 2.2Window{ visible: true width: 640 height: 480 title: qsTr("Hello World") Rectangle...
View ArticleGot an error: module "QtPositioning" plugin "declarative_positioning" not found
I am using Qt 5.4 on Mac and my target platform is IOS. I have a task to add geolocation to my app and I want to use PositioningSource component.I added import QtPositioning 5.2 to my QML file and QT...
View ArticleData sent from CPP causes interface crash in QML
first of all, I have a problem like this. I want to transfer the data to the QML side with a signal from C ++, but after a while my interface crashes without giving any error. I can't find the reason...
View ArticleBuilding a simple QML `TreeView` based off a Python dictionary
IntroductionI am using Qt for Python, specific Qt Quick with QML and PySide6, to build a GUI application. The application is a log viewer, and I want a TreeView QML type to display the hierarchy of...
View ArticleDisplaying QStandardItemModel from Python in a QML TableView
Please note that versions of this question have been asked before, but the various comments and proposed solutions have not worked. They either cover C++, for which I have tried replicating the...
View ArticleHow to scale a QML rectangle without also scaling any child text
I have the QML component outlined below. The problem I have is that when I scale the rectangle using a pinch area (which I want to happen), the text that is a child to that rectangle is also scaled...
View ArticleHow to bind an optional property in QML?
I'm developping a QtQuick Custom Style (according too this documentation), and I'm facing a problem.My Button template implementation expose an additionnal user propertyMyCustomStyle/Button.qmlimport...
View Articleqt6apptestqt_debug_metatypes.json: illegal value
EDITMy CMake file looks like this:cmake_minimum_required(VERSION 3.16)project(testqt VERSION 0.1 LANGUAGES CXX)set(CMAKE_AUTOMOC ON)set(CMAKE_CXX_STANDARD_REQUIRED ON)find_package(Qt6 6.4 REQUIRED...
View Articleerror: no match for 'operator!=' (operand types are 'QVector' {aka 'QList'}...
I have Qt code that looks like following:class test_gadget { Q_GADGET Q_PROPERTY(QString test MEMBER test)public: QString test;};class test_gadget2 { Q_GADGET Q_PROPERTY(QVector<test_gadget>...
View Articlemodule "QtQuick.Dialogs" version 1.3 is not installed
I'm trying to import QtQuick.Dialogs version 1.3 in a code that runs without any issue with version 1.2. However on runtime I get the following errormodule "QtQuick.Dialogs" version 1.3 is not...
View Article