Creator + Docker + Resources = ๐ฃ
Has anyone tried to use a (working) CI docker container as build device for .pro projects?
As of QtCreator 12 it mostly works, but royally screws up file and resource paths, thus making development almost impossible, since cross-references and assets are not readily available as they do on a native environment.
Whatโs weird is that compiling works flawlessly through creator.
Any help?
https://redd.it/19egrpr
@qt_reddit
Has anyone tried to use a (working) CI docker container as build device for .pro projects?
As of QtCreator 12 it mostly works, but royally screws up file and resource paths, thus making development almost impossible, since cross-references and assets are not readily available as they do on a native environment.
Whatโs weird is that compiling works flawlessly through creator.
Any help?
https://redd.it/19egrpr
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
Is there any verification of qmlc files?
Does anybody know if the qmlc files (qml cache) are verified in any way to protect from tampering? Would it be possible for a malicious attacker to replace/modify these files?
https://redd.it/19ecflv
@qt_reddit
Does anybody know if the qmlc files (qml cache) are verified in any way to protect from tampering? Would it be possible for a malicious attacker to replace/modify these files?
https://redd.it/19ecflv
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
pyside5 Qt for Python in depth tutorial - Qt Group
https://www.youtube.com/watch?v=wOMlDutOWXI
https://redd.it/1ady1r7
@qt_reddit
https://www.youtube.com/watch?v=wOMlDutOWXI
https://redd.it/1ady1r7
@qt_reddit
YouTube
Python and C++ interoperability with Shiboken {On-demand webinar}
C++ and Python are two fantastic programming languages that bring to the table a considerable amount of features which made them the number one option for different tasks. How we can bring the best of two worlds together? With Shiboken.
Shiboken is the bindingโฆ
Shiboken is the bindingโฆ
Memory address of a Singleton instance is different when printed in C++ debug log and QML console log
Let's say I have created a singleton class in C++ to be used as QML type.
I tried to print the address of the singleton instance from C++ and from QML
qDebug() << this; // SingletonClass(0x2b0d98915c0)
console.log(SingletonClass); // qml: SingletonClass(0x2b0d41b7990)
What are the possible mistakes that could lead to this? Isn't it supposed to be the same address when printed?
https://redd.it/1ae3w6k
@qt_reddit
Let's say I have created a singleton class in C++ to be used as QML type.
I tried to print the address of the singleton instance from C++ and from QML
qDebug() << this; // SingletonClass(0x2b0d98915c0)
console.log(SingletonClass); // qml: SingletonClass(0x2b0d41b7990)
What are the possible mistakes that could lead to this? Isn't it supposed to be the same address when printed?
https://redd.it/1ae3w6k
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
rhombus at end of each file
I am using qt creator12.01 in windows 11. At the end of each file, there is a rhombus mark.
Is there a way to not show this mark?
​
https://preview.redd.it/4or9fc3akhfc1.png?width=789&format=png&auto=webp&s=37a575e8703bfa9cca9e4fc430b76a04c8b6f9f8
https://redd.it/1aed74x
@qt_reddit
I am using qt creator12.01 in windows 11. At the end of each file, there is a rhombus mark.
Is there a way to not show this mark?
​
https://preview.redd.it/4or9fc3akhfc1.png?width=789&format=png&auto=webp&s=37a575e8703bfa9cca9e4fc430b76a04c8b6f9f8
https://redd.it/1aed74x
@qt_reddit
Qt Creator 12.0.1 (Community) keeps crashing in Design mode
I can't even specify what I do to make it crash. It's like I'm playing russian roulette with Qt Creator. Every click is risky and it could crash at any point. I noticed it crashing more frequently when I go from an objects attributes tab to the code tab. My PC should be able to handle Qt Creator. It has 16GB of RAM and a decent CPU. My graphics driver is also up to date. I'm on Windows 11, installed Qt through the Online/Open Source Installer. All I could find about this problem online is that I need to disable the UpdateInfo Plugin, which I did but it's still crashing.
​
Any ideas before I go completely insane? I've been at war with this stupid framework for over a week now and I'm considering using something else to create my GUI because this is getting ridiculous.
https://redd.it/1aep18u
@qt_reddit
I can't even specify what I do to make it crash. It's like I'm playing russian roulette with Qt Creator. Every click is risky and it could crash at any point. I noticed it crashing more frequently when I go from an objects attributes tab to the code tab. My PC should be able to handle Qt Creator. It has 16GB of RAM and a decent CPU. My graphics driver is also up to date. I'm on Windows 11, installed Qt through the Online/Open Source Installer. All I could find about this problem online is that I need to disable the UpdateInfo Plugin, which I did but it's still crashing.
​
Any ideas before I go completely insane? I've been at war with this stupid framework for over a week now and I'm considering using something else to create my GUI because this is getting ridiculous.
https://redd.it/1aep18u
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
Dowloading qt drivers for a flight software.
I have little to no knowledge when it comes to this stuff but I have been making a project that involves the use of ADSB data. The project is supposed to take the data it recieves from aircraft and display it on the software. The software I intend to use is called Stratofier. Well in the install portion of the software it says you need to have the qt drivers installed before the Stratofier software can be installed. I have a raspberry pi 4 and I have failed miserably at getting this to work. Any help would be appreciated.
https://redd.it/1aex8eb
@qt_reddit
I have little to no knowledge when it comes to this stuff but I have been making a project that involves the use of ADSB data. The project is supposed to take the data it recieves from aircraft and display it on the software. The software I intend to use is called Stratofier. Well in the install portion of the software it says you need to have the qt drivers installed before the Stratofier software can be installed. I have a raspberry pi 4 and I have failed miserably at getting this to work. Any help would be appreciated.
https://redd.it/1aex8eb
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
How to set QtWebEngine Content-Security-Policy (CSP) to default-src?
Hello, i have a qtwebengine view inside my app, and I'm having issues with apple music regarding the CPS, for some reason, it is set to
I don't want to use the
does anyone know how to do this?
https://redd.it/1aex59p
@qt_reddit
Hello, i have a qtwebengine view inside my app, and I'm having issues with apple music regarding the CPS, for some reason, it is set to
script-srchttps://music.apple.com/us/browse:143 Refused to execute inline script because it violates the following Content Security Policy directive:
"script-src 'self' https://*.apple.com blob: 'sha256- .... 'unsafe-eval'".
Either the 'unsafe-inline' keyword, a hash ....., or a nonce ('nonce-...') is required to enable inline execution.
I don't want to use the
--disable-web-security flag to disable CSP, i want to change it to default-srcdoes anyone know how to do this?
https://redd.it/1aex59p
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
License question
I am a PhD student who has been working on a hobby project for many years now.
Without much research, I developed a software on Windows Forms CLI C++. But, if you know you are on the wrong train, you get off at the next stop. ๐
I am still uncertain about what I want to do with the software, could go commercial, could go open-source... But before I start, wanted your help to clarify certain details. ๐
I designed electronics which is nearly open source with the instructions on it. And I wanted to design a UI as a companion for it. I hope to integrate cloud and AI to it, so there will be a cloud and closed source element to it for cyber-security, and for training of AI using user input.
And Qt licence says if you want to go commercial, make open devices, and also says make library modifiable.
1. Are any modifications known to cause serious issues? What is its use in the first place?
2. Is off-loaded computation for AI allowed under these terms?
3. What does open devices mean? How open? It is designed to be modifyable, but for quality only to a degree, and I am not sharing manufacturing data?
4. Using the GUI, I wish to export a binary file for compactness, and it likely will change over time, and would be easier to make it proprietary than to document it. Does that mean it isn't open enough?
5. Android, I believe doesn't work with dll and web deployment would probably have a similar issue, so these aren't allowed if it is free license then? (Is it fine for Windows, Linux and Osx?
6. Also, I am also hoping to make the qt made software free to use, and cloud based part charged. What happens if that section is free to download and use, yet happens to be a part of the revenue stream?
Looking forward to your reply. Thank you very much in advance. ๐๐
https://redd.it/1af5rru
@qt_reddit
I am a PhD student who has been working on a hobby project for many years now.
Without much research, I developed a software on Windows Forms CLI C++. But, if you know you are on the wrong train, you get off at the next stop. ๐
I am still uncertain about what I want to do with the software, could go commercial, could go open-source... But before I start, wanted your help to clarify certain details. ๐
I designed electronics which is nearly open source with the instructions on it. And I wanted to design a UI as a companion for it. I hope to integrate cloud and AI to it, so there will be a cloud and closed source element to it for cyber-security, and for training of AI using user input.
And Qt licence says if you want to go commercial, make open devices, and also says make library modifiable.
1. Are any modifications known to cause serious issues? What is its use in the first place?
2. Is off-loaded computation for AI allowed under these terms?
3. What does open devices mean? How open? It is designed to be modifyable, but for quality only to a degree, and I am not sharing manufacturing data?
4. Using the GUI, I wish to export a binary file for compactness, and it likely will change over time, and would be easier to make it proprietary than to document it. Does that mean it isn't open enough?
5. Android, I believe doesn't work with dll and web deployment would probably have a similar issue, so these aren't allowed if it is free license then? (Is it fine for Windows, Linux and Osx?
6. Also, I am also hoping to make the qt made software free to use, and cloud based part charged. What happens if that section is free to download and use, yet happens to be a part of the revenue stream?
Looking forward to your reply. Thank you very much in advance. ๐๐
https://redd.it/1af5rru
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
Basic help with openGL versions
I'm experimenting with QT for the first time and wanting to do some basic openGL.
​
The examples,Cube and OpenGL window both compile fine, but I'm trying to update them to GL4.5 to experiment with instancing and compute shaders
​
In either one if I set GL version ( with e.g.format.setVersion(3,1);) to anything higher than 2.x, the programs still run but simply display nothing
Is there something fundamental in the shaders I need to change, or a way to debug the opengl and see why nothing is displaying?
Cant find any example QT code that uses instancing to compare.
​
​
https://redd.it/1ag7t3d
@qt_reddit
I'm experimenting with QT for the first time and wanting to do some basic openGL.
​
The examples,Cube and OpenGL window both compile fine, but I'm trying to update them to GL4.5 to experiment with instancing and compute shaders
​
In either one if I set GL version ( with e.g.format.setVersion(3,1);) to anything higher than 2.x, the programs still run but simply display nothing
Is there something fundamental in the shaders I need to change, or a way to debug the opengl and see why nothing is displaying?
Cant find any example QT code that uses instancing to compare.
​
​
https://redd.it/1ag7t3d
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
Qt Stomp Library
Hello all, I created an open source library for clients communicating to servers through the Stomp protocol. Feel free to use it or share comments / ideal about it. https://github.com/xxxcucus/stomplib
Best wishes,
https://redd.it/1agi9dz
@qt_reddit
Hello all, I created an open source library for clients communicating to servers through the Stomp protocol. Feel free to use it or share comments / ideal about it. https://github.com/xxxcucus/stomplib
Best wishes,
https://redd.it/1agi9dz
@qt_reddit
GitHub
GitHub - xxxcucus/stomplib: Qt Library for the STOMP protocol
Qt Library for the STOMP protocol. Contribute to xxxcucus/stomplib development by creating an account on GitHub.
Need Help On Building Qt Quick/QML with Cmake
I am trying to build a C++ app using Qt Quick. However, while CMake generates build file successfully, I am having errors while building the app. This app actually nothing as of now, which means, it is just a way to build.
Here is my Top level CMake file
---
Here, I would Like to add that:
OS Environment: Windows 11
Qt version: 6.6.1
Compiler: g++ from mingw64 (MSYS2)
Command Line tool: Powershell
---
My Directory looks like this:
And I am trying to generate build files with these:
And after this when I try to build I get this error:
---
Note That
- Running
- I am only using C++ to build the app,
I am trying to build a C++ app using Qt Quick. However, while CMake generates build file successfully, I am having errors while building the app. This app actually nothing as of now, which means, it is just a way to build.
Here is my Top level CMake file
cmake_minimum_required(VERSION 3.28)
project(CGPA_Calculator VERSION 0.1 LANGUAGES CXX)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_PREFIX_PATH "D:/Dev_Install/Qt/6.6.1/mingw_64" CACHE PATH "Qt6 install path")
set(Qt6_DIR "D:/Dev_Install/Qt/6.6.1/mingw_64/lib/cmake/Qt6" CACHE PATH "Qt6 cmake directory")
find_package(Qt6 6.1 REQUIRED COMPONENTS Quick)
qt_standard_project_setup()
add_subdirectory(src)
add_subdirectory(QML_Files)
qt_add_qml_module(app
URI Calc
VERSION 1.0
QML_FILES
QML_Files/Main.qml
QML_Files/Page1.qml
QML_Files/Body.qml
QML_Files/ContHead.qml
# SOURCES
#src/cgpa_calculator.cpp src/cgpa_calculator.h
)
set_target_properties(app PROPERTIES
WIN32_EXECUTABLE TRUE
)
target_link_libraries(app PRIVATE Qt6::Quick)
include(GNUInstallDirs)
install(TARGETS app
BUNDLE DESTINATION ${CMAKE_INSTALL_BINDIR}
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
)
---
Here, I would Like to add that:
OS Environment: Windows 11
Qt version: 6.6.1
Compiler: g++ from mingw64 (MSYS2)
Command Line tool: Powershell
---
My Directory looks like this:
Directory: O:\CGPA Calculator
Mode LastWriteTime Length Name
---- ------------- ------ ----
d---- 02/02/2024 04:45 PM QML_Files
d---- 02/02/2024 12:43 AM src
-a--- 02/02/2024 04:45 PM 1059 CMakeLists.txt
And I am trying to generate build files with these:
PS O:\CGPA Calculator> cmake -G "MinGW Makefiles" -S . -B ".\build"
-- The CXX compiler identification is GNU 13.2.0
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/msys64/mingw64/bin/g++.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Performing Test HAVE_STDATOMIC
-- Performing Test HAVE_STDATOMIC - Success
-- Found WrapAtomic: TRUE
-- Could NOT find WrapVulkanHeaders (missing: Vulkan_INCLUDE_DIR)
-- Could NOT find WrapVulkanHeaders (missing: Vulkan_INCLUDE_DIR)
CMake Warning (dev) at D:/Dev_Install/Qt/6.6.1/mingw_64/lib/cmake/Qt6Core/Qt6CoreMacros.cmake:2768 (message):
Qt policy QTP0001 is not set: ':/qt/qml/' is the default resource prefix
for QML modules. Check https://doc.qt.io/qt-6/qt-cmake-policy-qtp0001.html
for policy details. Use the qt_policy command to set the policy and
suppress this warning.
Call Stack (most recent call first):
D:/Dev_Install/Qt/6.6.1/mingw_64/lib/cmake/Qt6Qml/Qt6QmlMacros.cmake:468 (__qt_internal_setup_policy)
D:/Dev_Install/Qt/6.6.1/mingw_64/lib/cmake/Qt6Qml/Qt6QmlMacros.cmake:716 (qt6_add_qml_module)
CMakeLists.txt:17 (qt_add_qml_module)
This warning is for project developers. Use -Wno-dev to suppress it.
-- Configuring done (2.7s)
-- Generating done (0.1s)
-- Build files have been written to: O:/CGPA Calculator/build
And after this when I try to build I get this error:
PS O:\CGPA Calculator> cmake --build .\build
[ 4%] Automatic QML type registration for target app
Error 5 while parsing O:/CGPA Calculator/build/src/meta_types/qt6app_metatypes.json: illegal value
mingw32-make[2]: *** [CMakeFiles\app_tooling.dir\build.make:135: src/app_qmltyperegistrations.cpp] Error 1
mingw32-make[1]: *** [CMakeFiles\Makefile2:444: CMakeFiles/app_tooling.dir/all] Error 2
mingw32-make: *** [Makefile:135: all] Error 2
---
Note That
- Running
qml .\QML_Files\Main.qml runs the file without any issue- I am only using C++ to build the app,
and not using anything interconnected other than that
---
I can't figure out what seems to be the problem here?
https://redd.it/1ah7x30
@qt_reddit
---
I can't figure out what seems to be the problem here?
https://redd.it/1ah7x30
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
How do you transfer errors qml <- c++?
Hi! There is no common way to transfer errors to QML. In case of Q_INVOKABLE it's easy, but it's a rare case. Mostly, I call a background operation via a signal and get a result via a slot(s) + not only QML will subscribe on the error signals. How do you implement that?
I tried:
1. one signal and many slots for each error type:
```
slots:
void onDoSomething();
signal void doSomethingErrorType1(arg1,arg2,arg...);
signal void doSomethingErrorType2(arg1,arg2,arg...);
```
But it's hard to handle and easy to forget about a specific error.
2. one signal and one slot with QVarian:
```
slots:
void onDoSomething();
signal void doSomethingError(QVariant errors);
```
But, even if you use Q_GADGET + Q_DECLARE_METATYPE, it requires a default constructor and that makes the error type quite wordy and inconvenient to use in C++
3. I ended up with the following solution:
```
struct Error1 { ... }
struct Error2 { ... }
class QmlError {
Q_GADGET;
// In non common getters I use QVariant to make a field optional depends on ErrorType.
static QmlError fromError(variant<Error1, Error2> error) { ... }
// to distinguish error types in qml
ErrorType type; enum ErrorType { Error1, Error2 } Q_ENUM(ErrorType)
```
And I can cast C++ Errors into QmlError in a proxy object for qml and use normal types in C++.
Maybe I do something wrong? Maybe there are some common patterns for error-handling?
https://redd.it/1ajgjkd
@qt_reddit
Hi! There is no common way to transfer errors to QML. In case of Q_INVOKABLE it's easy, but it's a rare case. Mostly, I call a background operation via a signal and get a result via a slot(s) + not only QML will subscribe on the error signals. How do you implement that?
I tried:
1. one signal and many slots for each error type:
```
slots:
void onDoSomething();
signal void doSomethingErrorType1(arg1,arg2,arg...);
signal void doSomethingErrorType2(arg1,arg2,arg...);
```
But it's hard to handle and easy to forget about a specific error.
2. one signal and one slot with QVarian:
```
slots:
void onDoSomething();
signal void doSomethingError(QVariant errors);
```
But, even if you use Q_GADGET + Q_DECLARE_METATYPE, it requires a default constructor and that makes the error type quite wordy and inconvenient to use in C++
3. I ended up with the following solution:
```
struct Error1 { ... }
struct Error2 { ... }
class QmlError {
Q_GADGET;
// In non common getters I use QVariant to make a field optional depends on ErrorType.
static QmlError fromError(variant<Error1, Error2> error) { ... }
// to distinguish error types in qml
ErrorType type; enum ErrorType { Error1, Error2 } Q_ENUM(ErrorType)
```
And I can cast C++ Errors into QmlError in a proxy object for qml and use normal types in C++.
Maybe I do something wrong? Maybe there are some common patterns for error-handling?
https://redd.it/1ajgjkd
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
How to display more than one chart (preferably without a GraphicsView)?
https://redd.it/1ajha21
@qt_reddit
https://redd.it/1ajha21
@qt_reddit
Help! All the pushButtons that I create are suddenly not working anymore, no QMessageBox is appearing
\#include "mainwindow.h"
\#include "ui_mainwindow.h"
\#include <QMessageBox>
\#include "snaptaskapp.h"
​
MainWindow::MainWindow(QWidget *parent)
: QMainWindow(parent)
, ui(new Ui::MainWindow)
{
ui->setupUi(this);
QPixmap snaptasklogo("C:/Users/Louie/Downloads/Blue and White Circle Surfing Club Logo/1.png");
int w = ui->label_snaptasklogo->width();
int h = ui->label_snaptasklogo->height();
ui->label_snaptasklogo->setPixmap(snaptasklogo.scaled(w,h));
}
​
MainWindow::\~MainWindow()
{
delete ui;
}
​
void MainWindow::on_pushButton_learnsort_clicked()
{
QMessageBox::information(this, "Learn about Sorting System", "SnapTask prioritizes simplicity and effectiveness in task handling. Its intuitive design allows users to effortlessly create, organize, and manage tasks, ensuring nothing falls through the cracks. With core CRUD (Create, Read, Update, Delete) operations seamlessly integrated, users can easily navigate through their tasks, maintaining a clear overview of their workload.");
}
​
​
https://redd.it/1akh87p
@qt_reddit
\#include "mainwindow.h"
\#include "ui_mainwindow.h"
\#include <QMessageBox>
\#include "snaptaskapp.h"
​
MainWindow::MainWindow(QWidget *parent)
: QMainWindow(parent)
, ui(new Ui::MainWindow)
{
ui->setupUi(this);
QPixmap snaptasklogo("C:/Users/Louie/Downloads/Blue and White Circle Surfing Club Logo/1.png");
int w = ui->label_snaptasklogo->width();
int h = ui->label_snaptasklogo->height();
ui->label_snaptasklogo->setPixmap(snaptasklogo.scaled(w,h));
}
​
MainWindow::\~MainWindow()
{
delete ui;
}
​
void MainWindow::on_pushButton_learnsort_clicked()
{
QMessageBox::information(this, "Learn about Sorting System", "SnapTask prioritizes simplicity and effectiveness in task handling. Its intuitive design allows users to effortlessly create, organize, and manage tasks, ensuring nothing falls through the cracks. With core CRUD (Create, Read, Update, Delete) operations seamlessly integrated, users can easily navigate through their tasks, maintaining a clear overview of their workload.");
}
​
​
https://redd.it/1akh87p
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
PyQT: How to deal with widget creation order ?
I'm new to Qt and specifically using PyQt (well, PySide6...).
I find the order of how widgets get created/initialized increasingly frustrating. At least when following the Qt Creator toolchain (which translates .ui files to python code), the generated code is essentially as follow:
the_parent = QWidget(parent=...)
# various the_parent setters ...
child1 = QWidget(parent=the_parent)
# various child1.setters ...
child2 = QWidget(parent=the_parent)
# various child2.setters ...
Maybe I'm doing something fundamentally wrong. I try to build the UI hierarchically by composing various widgets into a parent widget (say a QGroupBox), then subclassing that parent to implement some functionality. The problem is, at \_\_init\_\_ time of the parent, the children do not exist yet, there is no chance to connect signals to slots yet. Even if I would like to do that later, after the child get initialized there is no notification/callback to the parent.
​
I would rather like to use something like this:
child1 = QWidget()
# various child1 setters ...
child2 = QWidget()
# various child2 setters ...
the_parent = QWidget(child1, child2, ...)
That way, all objects observed (except self) are initialized already.
How do people deal with that problem ?
https://redd.it/1al4ijm
@qt_reddit
I'm new to Qt and specifically using PyQt (well, PySide6...).
I find the order of how widgets get created/initialized increasingly frustrating. At least when following the Qt Creator toolchain (which translates .ui files to python code), the generated code is essentially as follow:
the_parent = QWidget(parent=...)
# various the_parent setters ...
child1 = QWidget(parent=the_parent)
# various child1.setters ...
child2 = QWidget(parent=the_parent)
# various child2.setters ...
Maybe I'm doing something fundamentally wrong. I try to build the UI hierarchically by composing various widgets into a parent widget (say a QGroupBox), then subclassing that parent to implement some functionality. The problem is, at \_\_init\_\_ time of the parent, the children do not exist yet, there is no chance to connect signals to slots yet. Even if I would like to do that later, after the child get initialized there is no notification/callback to the parent.
​
I would rather like to use something like this:
child1 = QWidget()
# various child1 setters ...
child2 = QWidget()
# various child2 setters ...
the_parent = QWidget(child1, child2, ...)
That way, all objects observed (except self) are initialized already.
How do people deal with that problem ?
https://redd.it/1al4ijm
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
Dynamic rendered SVG... Qt the right thing.
Hey I'm a mech engineer and was writing a tool in python to use it for design purposes in jupyter notebook.
Beside some calculation it generates a conplex svg2 file which i embed into the notebook.
It would be fine to have a gui for playing with parameters / optimize in product design phases.
I made some apps using PySide6 /Qt6 , widgets/qml but it seems like there is not a good way to implement this?
I would like to be able to do:
- enter parameters (~30) into a form
- run some optimization code
- create svg graphic from results
- change color of related svg objects when hover on it and display some explaination
- optional: highlight related parameters to the svg object
- generate python /markdown for jupyter nb.
Is there a qt way or should i go using something else?
------
I think it would be possible (meaning not too much effort) to rewrite everything in C++.
https://redd.it/1am56p7
@qt_reddit
Hey I'm a mech engineer and was writing a tool in python to use it for design purposes in jupyter notebook.
Beside some calculation it generates a conplex svg2 file which i embed into the notebook.
It would be fine to have a gui for playing with parameters / optimize in product design phases.
I made some apps using PySide6 /Qt6 , widgets/qml but it seems like there is not a good way to implement this?
I would like to be able to do:
- enter parameters (~30) into a form
- run some optimization code
- create svg graphic from results
- change color of related svg objects when hover on it and display some explaination
- optional: highlight related parameters to the svg object
- generate python /markdown for jupyter nb.
Is there a qt way or should i go using something else?
------
I think it would be possible (meaning not too much effort) to rewrite everything in C++.
https://redd.it/1am56p7
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community
Hello guys please help me with QT on a mac
I have never touched a mac before but someone im working for really wants me to build a mac application too. My windows version works fine but I am having trouble with my mac version.
Here is what the application does: takes some input from the user and manipulates that data and writes it to a json file (and does further stuff with that json file but first lets cross this hurdle)
I know how the QJsonDocument and other things work. Because it works on my windows system.
I am using QFileDialogue to get the destination folder where this json file must be saved (on usually in the documents folder)
However on mac when I build the project for release it just, doesn't work. The QFileDialogue returns a "/" which I assume is the root folder which obviously doesnt have write priveledges. And while the other functionalities happen to some extent, this writing json does not happen at all.
Why is that? How could I fix this? Where do i even start with the googling?
Oh yeah one more thing: when I run the app in Qt creator itself it works when I run it as a deployed .app then it does not work.
https://redd.it/1am5hdg
@qt_reddit
I have never touched a mac before but someone im working for really wants me to build a mac application too. My windows version works fine but I am having trouble with my mac version.
Here is what the application does: takes some input from the user and manipulates that data and writes it to a json file (and does further stuff with that json file but first lets cross this hurdle)
I know how the QJsonDocument and other things work. Because it works on my windows system.
I am using QFileDialogue to get the destination folder where this json file must be saved (on usually in the documents folder)
However on mac when I build the project for release it just, doesn't work. The QFileDialogue returns a "/" which I assume is the root folder which obviously doesnt have write priveledges. And while the other functionalities happen to some extent, this writing json does not happen at all.
Why is that? How could I fix this? Where do i even start with the googling?
Oh yeah one more thing: when I run the app in Qt creator itself it works when I run it as a deployed .app then it does not work.
https://redd.it/1am5hdg
@qt_reddit
Reddit
From the QtFramework community on Reddit
Explore this post and more from the QtFramework community