qtquick2 Questions
4
I want to use a QtQuick Image object in a simple Qt project, and include the image in the project. I have added the image to the resource file. I have used debugging to be sure that the resource ex...
4
Solved
11
Solved
class StyleClass : public QObject {
public:
typedef enum
{
STYLE_RADIAL,
STYLE_ENVELOPE,
STYLE_FILLED
} Style;
Style m_style;
//...
};
The .h file has the above code. How to access the a...
2
Solved
https://doc.qt.io/qt-5/qml-qtquick-controls2-menubar.html
MenuBar is supported in ApplicationWindow and not in Window.
Following throws an error "Invalid property name: MenuBar"
Window
{
...
3
Solved
I want to align Rectangles in a RowLayout left to right. In below code example two Rectangles share additional space instead stack one after another. I used Layout.alignment: Qt.AlignLeft in RowLay...
6
The look and feel I'm trying to go for is to have a solid color button, and text on it like "Hello World" where the text is completely transparent, and the background shows through the button.
In...
Burkhard asked 6/10, 2016 at 18:53
7
Solved
From here: https://mcmap.net/q/82398/-add-the-installation-prefix-of-quot-qt5widgets-quot-to-cmake_prefix_path
I tried this:
cmake_minimum_required(VERSION 2.8.12)
project(qtquick_hello_cmake)
...
2
Solved
This works as intended with Row, but not with RowLayout. Why? What is the difference between the two?
ApplicationWindow {
title: "Testing"
width: 640
height: 480
//RowLayout {
Row {
ancho...
3
Solved
Like we have preprocessor directives in C++ for conditional includes.
Similarly, how to do conditional importing in QML?
if x
import ABC 1.0
else
import PQR 2.0
Kasey asked 12/12, 2014 at 9:22
5
Solved
I’m looking for a way of dragging frameless window in QtQuick2.
I followed this thread on the forum Link but it gives me an error.
Main difference in the code is that my code uses QtQuick2Applicat...
8
Solved
To test QML deployment I've created a very simple QML application. Here is the code:
main.cpp
#include <QApplication>
#include <QQmlApplicationEngine>
#include <QFile>
int main...
Aftmost asked 31/7, 2014 at 0:27
7
I would like to know if it's possible to use (several) different delegates for a QML ListView.
Depending on the individual object in the ListView model, I would like to visualize the objects with...
4
Solved
I'm writing my first QML/Javascript app for QtQuick 2.0.
I need to place a DatePicker control, but I haven't found any control like that under QtQuick.Controls -and nowhere, in fact-.
I'm startin...
Salesman asked 16/1, 2014 at 4:8
2
3
Solved
I have been trying to use a QML TableView to display a QAbstractTableModel. The missing part of the equation seems to be that it is not possible to have a variable number of columns in the TableVie...
5
Solved
All my dialogs appear on the top left corner of screen instead of the center.
What is the best way to let the dialogs be placed automatically correct?
import QtQuick 2.7
import QtQuick.Controls...
Darsey asked 12/7, 2017 at 7:43
3
The QT document had implied that any implementation of QAbstractItemModel can be used for TreeView.
These models are usually in C++, which is inconvenient for now.
So is there an native QML mod...
Assemblage asked 20/4, 2017 at 9:28
3
Solved
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 th...
2
Solved
I'm trying to create a tabbed pages in qml. I used TabBar associated with StackLayout:
TabBar {
id: bar
width: parent.width
TabButton {
text: qsTr("Home")
}
TabButton {
text: qsTr("Discov...
2
I want to create an application without the title bar, but with native close, minimize and maximize buttons. This is the intent of the layout:
The app is built using Go and QML. I was able to re...
Hyssop asked 5/3, 2015 at 13:4
2
Solved
I have a width property on a QML Rectangle that is set based on another Rectangle with an id of mainwindow and one of the array properties of mainwindow:
width: mainwindow.width/mainwindow.numCols...
8
Solved
To my surprise, the Image component has no radius property. I tried emulating the rounded corners by putting the image in a rounded Rectangle, but it does not clip the corners.
Rectangle {
anchor...
3
Solved
Consider this JS code:
function handleSig() {
emitter.someSig.disconnect(handleSig);
// do some work here
}
emitter.someSig.connect(handleSig);
Can it be written without the explicit disconne...
Joacima asked 10/7, 2017 at 18:15
2
It is possible to create QML components from files using Qt.createComponent(filename)
It is possible to create QML object from strings using Qt.createQmlObject(string)
It is possible to create QM...
Saunder asked 3/12, 2014 at 11:17
5
Solved
I have a row with items which should stack when the window width gets too small for displaying all items in a row, as shown in the following sketch:
The Flow component stacks the items but they ...
1 Next >
© 2022 - 2025 — McMap. All rights reserved.