Re: [Interest] Yocto is application or device creation license???

2023-12-20 Thread Jérôme Godbout via Interest
Hi,
If it may interest anybody, using Yocto is defacto embedded license required. 
So using Qt into your Yocto for a product make you enter into the royalty fee 
realm and an expensive one.

Another client that will use something else. It took the client 30 seconds to 
choose after the sale representative meeting. I cannot even think they gave 
such a price for over 50k unit per years…

It make 3 ridiculous pricing for embedded I get from Qt into the past years and 
a half for different clients. None when down that road, not because of the 
tech, but the embedded royalty are just plain out of this world for embedded 
devices. Maybe for a 20k$ car it can make sense, but when you make SPA 
equipment, hospital bed, power control box, it’s plain a no go for GUI. And we 
are not talking low volume client, 15k, 40k and the other was 75k-100k. Better, 
invest that money on bigger MCU/GPU, when the royalty is above the MCU price 
it’s plain insanity.

Sad, but I have not been able to use Qt in the past few years…

[signature_2639730570]<https://www.dimonoff.com/>
Jérôme Godbout, B.Eng.
Software / Firmware Team Lead
[Smart Phone avec un remplissage uni] (581) 777-0050
[Envelope avec un remplissage uni] 
jgodb...@dimonoff.com<mailto:jgodb...@dimonoff.com>
[World avec un remplissage uni] www.dimonoff.com<http://www.dimonoff.com>


From: Interest  on behalf of Thiago Macieira 

Date: Thursday, December 14, 2023 at 4:00 PM
To: interest@qt-project.org 
Subject: Re: [Interest] Yocto is application or device creation license???
On Thursday, 14 December 2023 16:13:37 -03 Jérôme Godbout via Interest wrote:
> Can I use the Yocto Layers and Recipes in a build using BitBake (YP's build
> tool) to make a commercial application using the Application Development
> license?
>
> That’s my true question, is application development license allowed into
> that context or are we force to use the device creation license.

I think you or I are getting mixed on details.

Yocto Project, recipes, layers, and BitBake are just tools to accomplish the
build of your device. YP licences won't apply at the end. Only the cumulative
licence of all the software that you selected (by way of the layers) does and
the YP tools will create the BOM for you to analyse. This is where this
licence you're referring to comes into play.

So it doesn't matter how you built and deployed your Qt Commercial onto the
device, only that you did. Does that licence allow you to ship your device?
Does it require payment of per-unit royalties? Does it put extra requirements
on what you can or can't do? I can't answer that, since I don't know the
terms. You should get your legal department to make a decision. Qt Company's
opinion is an input, not a conclusion.

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Cloud Software Architect - Intel DCAI Cloud Engineering
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Yocto is application or device creation license???

2023-12-14 Thread Jérôme Godbout via Interest
Can I use the Yocto Layers and Recipes in a build using BitBake (YP's build
tool) to make a commercial device? Yes.

The question would then be:
Can I use the Yocto Layers and Recipes in a build using BitBake (YP's build
tool) to make a commercial application using the Application Development 
license?

That’s my true question, is application development license allowed into that 
context or are we force to use the device creation license.

There is no commercial device license on the web site it’s either Application 
development or Device creation:
[cid:image005.png@01DA2E97.A2E99F50]

[signature_599607807]<https://www.dimonoff.com/>
Jérôme Godbout, B.Eng.
Software / Firmware Team Lead
[Smart Phone avec un remplissage uni] (581) 777-0050
[Envelope avec un remplissage uni] 
jgodb...@dimonoff.com<mailto:jgodb...@dimonoff.com>
[World avec un remplissage uni] www.dimonoff.com<http://www.dimonoff.com>


From: Interest  on behalf of Thiago Macieira 

Date: Thursday, December 14, 2023 at 12:55 PM
To: interest@qt-project.org 
Subject: Re: [Interest] Yocto is application or device creation license???
On Thursday, 14 December 2023 14:00:32 -03 Jérôme Godbout via Interest wrote:
> Can the commercial Application be used with a Yocto build into a custom arm
> device?

Your question is actually:

Can I use the Yocto Layers and Recipes in a build using BitBake (YP's build
tool) to make a commercial device? Yes.

Can I use the meta-qt6 layer to build a commercial Qt? Tuukka's answer says
yes.

BitBake will produce a BOM for you with a list of licences and your
obligations.

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Cloud Software Architect - Intel DCAI Cloud Engineering
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Yocto is application or device creation license???

2023-12-14 Thread Jérôme Godbout via Interest
Hi,
We are not going into the Qt MCU code based, we will have a full fledge Linux 
build with Yocto and plan on using a full Qt with Qml views. Open Source is not 
possible without releasing the cie application business layer which the client 
does not want to do for obvious reason.

Let’s make the question clear:
Can the commercial Application be used with a Yocto build into a custom arm 
device?

[signature_106982083]<https://www.dimonoff.com/>
Jérôme Godbout, B.Eng.
Software / Firmware Team Lead
[Smart Phone avec un remplissage uni] (581) 777-0050
[Envelope avec un remplissage uni] 
jgodb...@dimonoff.com<mailto:jgodb...@dimonoff.com>
[World avec un remplissage uni] www.dimonoff.com<http://www.dimonoff.com>


From: Tuukka Turunen 
Date: Thursday, December 14, 2023 at 9:59 AM
To: Jérôme Godbout , Qt Interest 

Subject: Re: Yocto is application or device creation license???
Hi,

The meta-qt6 layer is available at: 
https://code.qt.io/cgit/yocto/meta-qt6.git/tree/ It works for both commercial 
as well as open-source Qt as described at: 
https://code.qt.io/cgit/yocto/meta-qt6.git/tree/README.md

Your email mentions MCU, so in case you are looking to use Qt for MCUs it is a 
separate codebase, which is not dual licensed. More info: 
https://www.qt.io/product/develop-software-microcontrollers-mcu

The commercial Qt for Device Creation subscription includes prebuild binaries, 
convenience items, as well as some additional functionality. You can check what 
is available under which license bundle via: https://www.qt.io/product/features

We recommend using the commercial Qt for Device Creation product when making 
embedded devices. It is also possible to build embedded devices using the 
open-source license option as long as you ensure to meet the requirements set 
by open-source licensing. You can check more information on the L/GPL 
requirements at: https://www.qt.io/licensing/open-source-lgpl-obligations

Yours,

Tuukka


From: Interest  on behalf of Jérôme Godbout 
via Interest 
Date: Thursday, December 14, 2023 at 16:36
To: Qt Interest 
Subject: [Interest] Yocto is application or device creation license???
Hi,

I have a client who is looking for a GUI stack for their SPA devices. The 
device use a yocto we build for them. The Fuzzy license of Qt is not very clear 
on where does Yocto build fall in term of licensing.

My understanding if fall into the Linux embedded and force them to go into the 
device license I think. But this will be a show stopper for them if they have 
to paid royalty fee. Does Yocto Linux count as Linux Desktop, since we are 
building a desktop on arm chipset in the end.

The device creation is just plain impossible, the royalty fee is above the cost 
of the MCU itself, which is a no go.

I feel like I always end up in that impossible licensing problems with Qt, the 
embedded license is out of touch aside from huge expensive system like car!

So far, we look at Qt for hospital bed, SPA, car charging units… The price is 
just a show stopper at each time…


[signature_917022966]<https://www.dimonoff.com/>
Jérôme Godbout, B.Eng.
Software / Firmware Team Lead
[Smart Phone avec un remplissage uni] (581) 777-0050
[Envelope avec un remplissage uni] 
jgodb...@dimonoff.com<mailto:jgodb...@dimonoff.com>
[World avec un remplissage uni] www.dimonoff.com<http://www.dimonoff.com/>

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Yocto is application or device creation license???

2023-12-14 Thread Jérôme Godbout via Interest
Hi,

I have a client who is looking for a GUI stack for their SPA devices. The 
device use a yocto we build for them. The Fuzzy license of Qt is not very clear 
on where does Yocto build fall in term of licensing.

My understanding if fall into the Linux embedded and force them to go into the 
device license I think. But this will be a show stopper for them if they have 
to paid royalty fee. Does Yocto Linux count as Linux Desktop, since we are 
building a desktop on arm chipset in the end.

The device creation is just plain impossible, the royalty fee is above the cost 
of the MCU itself, which is a no go.

I feel like I always end up in that impossible licensing problems with Qt, the 
embedded license is out of touch aside from huge expensive system like car!

So far, we look at Qt for hospital bed, SPA, car charging units… The price is 
just a show stopper at each time…


[signature_917022966]<https://www.dimonoff.com/>
Jérôme Godbout, B.Eng.
Software / Firmware Team Lead
[Smart Phone avec un remplissage uni] (581) 777-0050
[Envelope avec un remplissage uni] 
jgodb...@dimonoff.com<mailto:jgodb...@dimonoff.com>
[World avec un remplissage uni] www.dimonoff.com<http://www.dimonoff.com>

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Using a single shared Object as a message bus throughout the application?

2021-06-09 Thread Jérôme Godbout
It seems like you need an event bus (where the sender matter or not, could 
simply be the event sender id). You then could register to listen to even from 
a particular source only or any source depending on your requirement. The any 
sender is not really possible with the Signal Slot unless you have a Signal 
forwarder central unit that would do just like the event bus. But there is many 
event bus implementation that doesn’t require Qt that could suit your need, you 
could translate your signal to event with a simple lambda on the event bus.

You should have a bus provider that get or create (goc) the bus with specific 
identifier (enum, name, etc). So you could have multiple BUS inside your 
application and different privilege bus (like DBUS user and system for 
example). You could have an action bus where action could be requested to 
perform actions (could have a flag into the actions to tell if it was handled 
or not when completed) and an event bus that reflect the actual events of what 
did happened into the system.

All your conditions then become event listener that trigger actions. For 
example:
system needs to do X when Y happens and if conditions A B and C are met

You make an event listener that wait until A, B and C event happen on the BUS 
(can also request the initial state to begin with) and trigger action X and 
action Y directly or can even simply request and event/action DoX or DoY which 
could be process by something else. Decoupling your application by a lot that 
way.



From: Interest  on behalf of Tarre Tarkas via 
Interest 
Date: Wednesday, June 9, 2021 at 3:12 PM
To: interest@qt-project.org 
Subject: [Interest] Using a single shared Object as a message bus throughout 
the application?
I'm working on a daemon that needs to stay flexible/tweakable. I get
lots of random requirements in the form of "system needs to do X when Y
happens and if conditions A B and C are met".

Qt's doc and examples seems to exclusively encourage putting signals in
each component's class definitions. So that's what I did previously.
However I recently found out that you can actually emit a signal in a
different QObject. I always thought the "emit MySignal()" to be like a
private call, but no, signals are public functions, you can do
"someobj->MySignal()", or better yet "Q_EMIT someobj->MySignal()" to
make it stand out more.

I'd like to hear your thoughts on an application architecture style
where you use a single shared object as a public message bus throughout
the entire app. So all the components of the app have a reference to
this QObject, all the "public" signals used by the application are
defined in this QObject instead of being defined in the object that
emits them.

I've written a very simple example app to showcase this:
https://gitlab.com/tarre/message-bus-test

Notice how the features in the 2nd and 3rd commits were bolted on to the
existing architecture in a very straight-forward way, without having to
modify unrelated source files.

Pros:
1) Simpler application architecture. Since there's just a single source
of major events, a new developer doesn't need to understand (as much)
where their code fits with all the rest. They can add certain features
by just writing signal handlers for signals coming from that single
event bus. Also, they can discover how components interact with each
other by searching for the usage of each signal from that single file.
When writing new components, they don't need to think as much where to
place it, since there's already this structure in place.
2) Signals emitted by objects created at a low "depth" (for example
Hardware -> SensorManager -> TemperatureSensor) can be used by
components anywhere in the app in a simple clean way, without writing
repetitive boilerplate code just to be able to connect a signal to a
slot
3) If there's a refactoring somewhere, if a different component is now
responsible for emitting SignalX, consumers don't have to change
anything. Previously the only way to do this would be to use interfaces,
which is boilerplatey.

Cons:
1) Not Qt-ic (whatever the Qt equivalent of "pythonic" is)
2) You lose the ability to use sender() to get a reference to the
QObject* that did the real emit. With this, the sender is always the
message bus object. (Correct me if I'm wrong. If there's a way to get
the sender without adding it as an argument in every signal, that would
be wonderful.)

What do you think?

Tarre
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QJsonDocument::fromVariant failing with list

2021-06-09 Thread Jérôme Godbout
I understand the homogenous part when you do decoding, but encoding to json 
should support the homogenous, isn’t? why not? I understand that the decode of 
that json would alter the type.

QList • encode json • [{‘a’: ‘b’}, {‘c’:’d’}] • decode json • 
QList

Should be possible as long as QList where T can be convert to QVariant. 
Maybe an external converter function should be used. If this is not supported, 
is there a way where we could trap this at compile time warning?

Maybe there is a limitation I do not see here.


From: Interest  on behalf of Thiago Macieira 

Date: Wednesday, June 9, 2021 at 10:08 AM
To: interest@qt-project.org 
Subject: Re: [Interest] QJsonDocument::fromVariant failing with list
On Wednesday, 9 June 2021 00:34:40 PDT Allan Sandfeld Jensen wrote:
> > QList is not a type, it's a template. Neither QVariant nor QJsonDocument
> > can know all possible QList instantiations. So they have coded only a few
> > (QVariantList and QStringList only, possibly QVector and
> > QVector in Qt 5 too, I don't remember).
>
> I guess our system could detect QList as QVariantList and
> QList as QStringList. They should be binary identical anyway.

They already do.

The problem is QList of other things that it's not coded for, like
QList in this case, or QList or QList. Since JSON
arrays are not expected to be homogeneous, QJsonDocument does not support
them.

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel DPG Cloud Engineering



___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QJsonDocument::fromVariant failing with list

2021-06-08 Thread Jérôme Godbout
Most likely the QJson doesn’t known what to do with your QList<> type object. 
You should put those object into a QVariantList, right now you have a 
QVariantList that contain a QList as first element. You should convert the 
Qlist to a QVariant (not sure you want 2 level deep array, but right now you 
do). You QList and QVariantList is QList.

Right now if it could do something with the QList you would get this:
{"err":null,"letters":[[{"a": 1},{"b": 2},{"c": 3}]]}

Something like this, not sure this is possible declaration but you are looking 
to get this in the end. Or make a converter that convert your QList to a 
QVariantList if you still need that QList absolutely.

QVariantList letters {
QVariantMap {{"a",1}},
QVariantMap {{"b",2}},
QVariantMap {{"c",3}}
};

Not tested just giving the idea
// can use traits if T is QVariant to simply convert by casting since it’s the 
same
Template
QVariantList Convert(const QList& l)
{
QVariantList rv;
Rv.reserve(l.size());
for(auto i in l)
{
rv.append(QVariant::fromValue(i));
}
return rv;
}


From: Interest  on behalf of Jason H 

Date: Tuesday, June 8, 2021 at 4:23 PM
To: interestqt-project.org 
Subject: [Interest] QJsonDocument::fromVariant failing with list
I'm having trouble with QJsonDocument::fromVariant() is not handling arrays:

QVariant list;

QList letters {
QVariantMap {{"a",1}},
QVariantMap {{"b",2}},
QVariantMap {{"c",3}}
};

list.setValue(letters);
map["err"] = QVariant(); // null
map["letters"] = list;

qDebug() << QJsonDocument::fromVariant(map)
.toJson(QJsonDocument::Compact);

Output:
{"err":null,"letters":null}

I'm expecting:
{"err":null,"letters":[{"a": 1},{"b": 2},{"c": 3}]}

The debugger (screenshot attached) sees it. Is this a bug or am I doing it 
wrong?
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] is it possible to add C# compiler?

2021-06-07 Thread Jérôme Godbout
You might need to do a C++/CLI wrapper around your c# library to make this work 
properly, there was some hackish way to include them that no more work with 
recent MSVC compiler.

https://www.red-gate.com/simple-talk/development/dotnet-development/creating-ccli-wrapper/

That should allow you to simply include the cli/C wrapper lib into your Qt 
project just like any other libs. Might be more complex to maintain but that’s 
also probably the safest way of doing it. Also make sure you always target the 
same runtime with all your libraries wrapped this way, “there can be only one”. 
Might need some extra compiler option also with your program to make this work 
properly with all the c# libs and runtime.


From: Interest  on behalf of David Skoland 

Date: Monday, June 7, 2021 at 7:48 AM
To: David M. Cotter 
Cc: Qt Interest 
Subject: Re: [Interest] is it possible to add C# compiler?
Hi,

Generally, no. I believe the reason you can compile Objective C on MacOS with 
Qt is clang’s ability to link ObjC to C++ libraries (Qt). I haven’t heard of 
MSVC or any other compiler which can do the same with C#, which might already 
be tricky since C# isn’t typically compiled to native assembly.

> On 5 Jun 2021, at 20:07, David M. Cotter  wrote:
>
> I just saw a message go by about someone adding another compiler to Qt 
> Creator?
>
> I know that Qt Creator can compile Objective C on mac.
>
> Made me wonder if it could be possible to add a compiler for C# on windows?
>
> Or is that already there and i don't know about it?
>
> -dave
> ___
> Interest mailing list
> Interest@qt-project.org
> https://lists.qt-project.org/listinfo/interest

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML MenuBar : works with PySide2 but not c++ ?

2021-06-04 Thread Jérôme Godbout
The resources usage seem to be right (added to .pro properly and the name and 
path seem to match) and the case are correct (assuming the actual file has the 
same cases). The Qml module must be added like stated below but you might want 
to also add core and quick control2:
QT += core qml quick quickcontrols2

You might want to add a trace before exiting -1 into your main.cpp:
QDebug() << “Failed to load the main qml script”;
QCoreApplication::exit(-1);

Also check the application output for any error or the Qml output into Qt 
creator (if you use it) it might tell you it miss some plugins or cannot find 
something. Maybe you Qml as an error or cannot find a component, it will simply 
not load making the application return -1 above.



From: Interest  on behalf of Frank Mertens 

Date: Friday, June 4, 2021 at 6:02 AM
To: interest@qt-project.org 
Subject: Re: [Interest] QML MenuBar : works with PySide2 but not c++ ?
No, only QML components need to be uppercase. The C++ and Python code looks 
100% the same. The only difference is that the C++ code uses qrc. Must be a 
bug!-) This is Qt 5.15.

On 03.06.21 15:19, Jason H wrote:
Why? QML elements are capitalized. They must be.
the only exception is js imports: import "app.js" as App



Sent: Thursday, June 03, 2021 at 4:10 AM
From: "Frank Mertens" 
To: interest@qt-project.org
Subject: Re: [Interest] QML MenuBar : works with PySide2 but not c++ ?
Try a lowercase file name, e.g.: "qrc:/menuBar.qml".

;)


On 03.06.21 06:08, Nicholas Yue wrote:
I copied the qml loading code from another working example, I was just testing 
a change in the QML content.

I'd have to dig further about the lambda

MenuBar.pro
===
QT += quick

CONFIG += c++11

# The following define makes your compiler emit warnings if you use
# any Qt feature that has been marked deprecated (the exact warnings
# depend on your compiler). Refer to the documentation for the
# deprecated API to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS

# You can also make your code fail to compile if it uses deprecated APIs.
# In order to do so, uncomment the following line.
# You can also select to disable deprecated APIs only up to a certain version 
of Qt.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x06# disables all the APIs 
deprecated before Qt 6.0.0

SOURCES += \
main.cpp

RESOURCES += main.qrc

# Additional import path used to resolve QML modules in Qt Creator's code model
QML_IMPORT_PATH =

# Additional import path used to resolve QML modules just for Qt Quick Designer
QML_DESIGNER_IMPORT_PATH =

# Default rules for deployment.
qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target

main.qrc
===


MenuBar.qml




On Wed, 2 Jun 2021 at 20:36, Tony Rietwyk 
mailto:t...@rightsoft.com.au>> wrote:

Hi Nicholas,

The short answer is because your C++ is doing completely different things to 
the python code.  :O)

I'm not sure about using QML.  Have you included the qml file as a resource 
correctly to access via qrc:?  You aren't checking the result of the 
engine.load.  Also, why is the lambda exiting the application when the 
objectCreated matches the url?

Have run the Qt QML examples?  How is your C++ code different to those?

Hope that helps, Tony


On 3/06/2021 11:33 am, Nicholas Yue wrote:
Hi,

  I am learning about QML.

  I would like to find out why the PySide2 loading of the QML file results in a 
visible window but the C++ one does not. The compiled application runs but no 
window is displayed.

MenuBar.qml
===
import QtQuick 2.4
import QtQuick.Controls 2.13

ApplicationWindow {
visible: true
width: 720
height: 480
title: "simple window"

menuBar: MenuBar{
Menu{
title: "Menu1"
}

Menu{
title: "Menu2"
}

Menu{
title: ""
}
}
}

main.cpp

#include 
#include 

int main(int argc, char *argv[])
{
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);

QGuiApplication app(argc, argv);

QQmlApplicationEngine engine;
const QUrl url(QStringLiteral("qrc:/MenuBar.qml"));
QObject::connect(, ::objectCreated,
 , [url](QObject *obj, const QUrl ) {
if (!obj && url == objUrl)
QCoreApplication::exit(-1);
}, Qt::QueuedConnection);
engine.load(url);

return app.exec();
}

main.py
===
import sys
from PySide2 import QtCore, QtGui, QtQml

if __name__ == '__main__':

QtCore.QCoreApplication.setAttribute(QtCore.Qt.AA_EnableHighDpiScaling)
app = QtGui.QGuiApplication(sys.argv)

engine = QtQml.QQmlApplicationEngine()

url = QtCore.QUrl.fromLocalFile('MenuBar.qml')
engine.load(url)
if not engine.rootObjects():
sys.exit(-1)

sys.exit(app.exec_())

--
Nicholas Yue
Graphics - Arnold, 

Re: [Interest] QNetworkReply lambdas?

2021-06-02 Thread Jérôme Godbout
Hi, might help, this won’t answer you question directly but might give some 
helper idea to ease the pain. What we did is a wrapper around 
QNetworkAccessManager class call RequestManager that own a QNetworkManager. It 
expose the following methods:

QNetworkReply* postRequest(QNetworkRequest& request, const QByteArray& payload);
// Do the same for put, update, get…

And signal slots:
signals:
void replySuccess(QNetworkReply* reply);
void replyError(QNetworkReply* reply);

public slots:
void handleFinished(QNetworkReply *networkReply);

It manage the return code immediate and signal then valide the answer is a 
success or a failure. You can store the context or object into a map with your 
request, the reply will have the request into it so you can load back the 
needed information when you receive the replySuccess or reply Error signals 
back.  Make some helper to convert you payload to QByteArray so you can use it 
with json, text, etc…

I also made some ScopeAction class so my NetworkAccess manager reply handler 
can make sure the delete later is not forgetten:

connect(_manager, ::finished, this, 
::handleFinished);


void RequestManager::handleFinished(QNetworkReply *networkReply)
{
ScopeAction action_delete([&](){ networkReply->deleteLater(); });
… // process the reply error or success here and emit either the replySuccess 
or replyError signal here, this need to be non queued connection to avoid bad 
object access.
}

This helped me a lot to clean my network management for upper layer. So I can 
simply connect to the reply success or replyError and with the request pointer 
form the reply you can load the associated data and continue form that point 
easily.

The async/await would be nice, but I’m not sure this would play well with the 
Qt event loop and the object memory management. They are also super hard to 
debug the call stack is lost.

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_182238435]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of Jason H 

Date: Wednesday, June 2, 2021 at 10:41 AM
To: interestqt-project.org 
Subject: [Interest] QNetworkReply lambdas?
I'm trying to figure out a more flexible way to do QNetworkReply. Ideally this 
would be through some async/await but I don't think Qt is "there" yet. (C++20 
defines async/await, but there is not a library yet, and even Qt6 doesn't 
target C++20). So the callback lambda handler looks like the best option for 
now.

I have a QObject derived class, with a post() function. It takes an endpoint, 
and object (to be converted to JSON) and a lambda. Example:
remoteCloud->post("/login", credentials, [=](QNetworkReply* reply){
if (reply->error() == QNetworkReply::NoError) {
update("cartridge",
   {{"synced", QDateTime::currentDateTime()}},
   {{"cartridgeId", map["cartridgeId"]}});
}
reply->deleteLater();
});

With an implementation of:
template
QNetworkReply *RemoteCloud::post(const QString& endpoint, const QVariantMap& 
item, F ) {
QNetworkReply* reply = m_nam.post(QNetworkRequest(endpoint), 
JSON(item));
connect(reply, ::finished, lambda);
return reply;
}


Note that a lot of the Qt examples use a connect statement like this:
connect(reply, ::finished, [request, reply](){ ... });

But when I tried to set this up, I either got static assert errors or l-value 
errors.

However I am trying to go one better and have my RemoteCloud::post set up the 
connect with the lambda. Is this possible?

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML defining an object property

2021-05-31 Thread Jérôme Godbout
Here is the example you can try (if the link ever die):

import QtQuick 2.7
import QtQuick.Controls 2.3

Rectangle
{
color: "red"
anchors.fill: parent

Row
{
Button
{
text: "test"
onClicked:
{
a_.allo['toto'] = "changed";
a_.alloChanged(); // require for value to be considered
a_.allo['toto'] = "ignored";
}
}

Button
{
id: b_
text: "test2"
onClicked:
{
text = "yaga";
}
}
}

Text {
id: a_
text: "Test: " + allo['toto'] + " Test2: " + allo["baba"]
font.pixelSize: 50
color: "white"
anchors.centerIn: parent
readonly property var allo: { "toto": "yeah", "baba": b_.text}
}
}

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_969455327]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of Jérôme Godbout 

Date: Monday, May 31, 2021 at 3:00 PM
To: Alexander Dyagilev , interest@qt-project.org 

Subject: Re: [Interest] QML defining an object property
This should be working (at least into 5.15.x). Binding value into the object 
should emit the changed normally.

Take care if you want a binding to react to values changed inside the 
dictionary/object inside you property, you will need to emit the change on the 
property.

Normally an easy way is to copy the value and modify it and reassign it. But 
here since you are readonly you cannot do that.

Try to emit changed when a dependencies is modified or when you set the value 
inside it.

Ex:
Function myEditFct()
{
mainTbImg[‘up’] = “popo”;
mainTbImgChanged(); // this is the missing piece often forgotten
}

Here an example that display the behavior
https://tinyurl.com/yg7ykwc4



From: Interest  on behalf of Alexander 
Dyagilev 
Date: Monday, May 31, 2021 at 1:57 PM
To: interest@qt-project.org 
Subject: [Interest] QML defining an object property

Hello,

Am I right that this is not possible in QML?

readonly property var mainTbImg: {

up: "some string",

up_check: "some another string"

}
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML defining an object property

2021-05-31 Thread Jérôme Godbout
This should be working (at least into 5.15.x). Binding value into the object 
should emit the changed normally.

Take care if you want a binding to react to values changed inside the 
dictionary/object inside you property, you will need to emit the change on the 
property.

Normally an easy way is to copy the value and modify it and reassign it. But 
here since you are readonly you cannot do that.

Try to emit changed when a dependencies is modified or when you set the value 
inside it.

Ex:
Function myEditFct()
{
mainTbImg[‘up’] = “popo”;
mainTbImgChanged(); // this is the missing piece often forgotten
}

Here an example that display the behavior
https://tinyurl.com/yg7ykwc4



From: Interest  on behalf of Alexander 
Dyagilev 
Date: Monday, May 31, 2021 at 1:57 PM
To: interest@qt-project.org 
Subject: [Interest] QML defining an object property

Hello,

Am I right that this is not possible in QML?

readonly property var mainTbImg: {

up: "some string",

up_check: "some another string"

}
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Problems writing files to Android file system on some newer devices using QStandardPaths

2021-05-25 Thread Jérôme Godbout
You might check the best path for the Android application depending on your 
needs:
https://developer.android.com/guide/topics/data

Then compare with the QStandards path, I’m not sure they are all friendly with 
the scoped storage.

For the actual path resolving are written down into the documentation (scroll 
down a little after the enum):
https://doc.qt.io/qt-5/qstandardpaths.html#StandardLocation-enum

Anything that use  for mobile is protected against other now and are 
part of the scoped storage. Note, you cannot write into the actual application 
binary anymore and other application based binary.

AppLocalDataLocation, ConfigLocation
should be safe for example. DataLocation should also be ok too normally. But 
make sure the path resolved make sense and play well with scoped storage. Try 
to keep the data as private as much as possible depending on your requirement. 
It’s easier to expose data later then loosing access to it! You can expose the 
data into a more public when needed with an application update, loosing access 
to a path with an update will prevent you from migrating those data.

Make sure you ask for the proper permission (manifest.xml) and at runtime to 
access the storage with your application (note the read/write external storage 
on Android 11 doesn’t do much since there is now the scoped storage that is 
more restrictive, but you will still need them for older Android version). 
Normally that should work for both internal and external storage data, the 
internal data storage is now encrypted and therefore should be used for 
sensitive data.

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_1620770654]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Nuno Santos 
Date: Tuesday, May 25, 2021 at 12:02 PM
To: Jérôme Godbout 
Cc: Qt Interest 
Subject: Re: [Interest] Problems writing files to Android file system on some 
newer devices using QStandardPaths
Jerome,

Thank you very much for your reply and for the link.

DocumentsLocation is point to /storage/emulated/…

But I’ve been trying with other QStandardPath such as ConfigLocation and 
DataLocation. Those were point to something like 
/user/app_identififier_/files/, can’t remember exactly now. But when trying to 
write to those locations, it would always fail.

Are QStandardPath Android locations compatible with Scoped Storage? Would I 
need to refactor my Qt code or this is just a thing we need to enable in the 
app manifest?

Thank you!

Best regards,

Nuno

On 25 May 2021, at 14:22, Jérôme Godbout 
mailto:godbo...@amotus.ca>> wrote:

Where the standard path resolve on the device?

On Android 10, they changed the way we can access the file system, you can opt 
out with android:requestLegacyExternalStorage=“true” but this flag doesn’t work 
for Android 11+. If removing this flag break your applications, it means your 
application won’t work on any Android 11 devices.

The application are now sandboxed, Android 10 make it optional, Android 11 
enforce it. You need to move to scoped storage.
https://developer.android.com/about/versions/11/privacy/storage


Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest 
mailto:interest-boun...@qt-project.org>> on 
behalf of Nuno Santos 
mailto:nuno.san...@imaginando.pt>>
Date: Monday, May 24, 2021 at 8:17 AM
To: Qt Interest mailto:interest@qt-project.org>>
Subject: [Interest] Problems writing files to Android file system on some newer 
devices using QStandardPaths
Hi,

Is anyone aware of changes to the way that Android filesystem works and how Qt 
interacts with it?

I’ve been writing to QStandardPaths::DocumentLocations without any issues 
until. However, on some newer devices, it fails to open files for writing. One 
example is Samsung Tab A (SM-T500)

It seems though that using android:requestLegacyExternalStorage=“true” seems to 
fix the problem but this solution will not last long because it seems it will 
be ignored when the app targets API 30 (Android 11):

https://developer.android.com/training/data-storage/use-cases

Caution: After you update your app to target Android 11 (API level 30), the 
system ignores the requestLegacyExternalStorage 
attribute<https://developer.android.com/about/versions/11/privacy/storage#scoped-storage>
 when your app is running on Android 11 devices, so your app must be ready to 
support scoped storage and to migrate app 
data<https://developer.android.com/training/data-storage/use-cases#migrate-legacy-storage>
 for users on those devi

Re: [Interest] Problems writing files to Android file system on some newer devices using QStandardPaths

2021-05-25 Thread Jérôme Godbout
Where the standard path resolve on the device?

On Android 10, they changed the way we can access the file system, you can opt 
out with android:requestLegacyExternalStorage=“true” but this flag doesn’t work 
for Android 11+. If removing this flag break your applications, it means your 
application won’t work on any Android 11 devices.

The application are now sandboxed, Android 10 make it optional, Android 11 
enforce it. You need to move to scoped storage.
https://developer.android.com/about/versions/11/privacy/storage


Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_862523546]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of Nuno Santos 

Date: Monday, May 24, 2021 at 8:17 AM
To: Qt Interest 
Subject: [Interest] Problems writing files to Android file system on some newer 
devices using QStandardPaths
Hi,

Is anyone aware of changes to the way that Android filesystem works and how Qt 
interacts with it?

I’ve been writing to QStandardPaths::DocumentLocations without any issues 
until. However, on some newer devices, it fails to open files for writing. One 
example is Samsung Tab A (SM-T500)

It seems though that using android:requestLegacyExternalStorage=“true” seems to 
fix the problem but this solution will not last long because it seems it will 
be ignored when the app targets API 30 (Android 11):

https://developer.android.com/training/data-storage/use-cases

Caution: After you update your app to target Android 11 (API level 30), the 
system ignores the requestLegacyExternalStorage 
attribute<https://developer.android.com/about/versions/11/privacy/storage#scoped-storage>
 when your app is running on Android 11 devices, so your app must be ready to 
support scoped storage and to migrate app 
data<https://developer.android.com/training/data-storage/use-cases#migrate-legacy-storage>
 for users on those devices.

Is there any common knowledge about this?

Thanks!

Regards,

Nuno

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML Singleton and QTimer?

2021-05-07 Thread Jérôme Godbout
Hi,
Is your QTimer access before the QGuiApplication is created (static singleton)? 
That could explain why this complain and moving the singleton instance into the 
GuiApplcation constructor solve your problems.

What we do over here, I have a custom template method that register the 
singleton from Qml and from C++ singleton class (templated too). This keep a 
map of type and pointer to object:

typedef QMap>> SingletonMapType;
extern SingletonMapType singleton_instances_map_;

after that the C++ singleton fetch into that map and so does my Qml singleton 
register type, so I get a single instance no matter who the C++ or the Qml 
request the singleton first. It might not be ideal, but it work well. So they 
are not really a static instance but instead a version that is kept based on 
the current QQmlEngine and application. If your application only use a single 
QQmlengine (like most of them do, you can skip the first layer of the map and 
simply use the map from string to QObject. For the QString you can extract it 
from template type and T::staticMetaObject.className()

you only need a getSingleton() and a createSingleton() class to fill the 
blank. So my class are not bake with singleton, there might be an instance that 
is singleton instead (make it easier to test the class without enforcing 
singleton into it and I can still make memento and the like of those object 
without being screw to have only hard single copy.


Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_75730]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Jason H 
Date: Friday, May 7, 2021 at 10:10 AM
To: Jérôme Godbout 
Cc: interestqt-project.org 
Subject: Re: [Interest] QML Singleton and QTimer?
Well, the documentation gives the example of the singleton being instantiated 
at the main.cpp:main() level.

It felt a little wrong, but I subclassed QGuiApplication, and created and 
registered the singleton there:

GuiApplication::GuiApplication(int argc, char*argv[]):

QGuiApplication::QGuiApplication(argc, argv)

{

m_hardwareInterface = new HardwareInterface;

qmlRegisterSingletonInstance("com.company", 1, 0, "HardwareInterface", 
m_hardwareInterface);

}

This seems to work, but seemed unnatural.






Sent: Thursday, May 06, 2021 at 5:42 PM
From: "Jérôme Godbout" 
To: "Jason H" , "interestqt-project.org" 

Subject: Re: [Interest] QML Singleton and QTimer?
You can check the thread affinity of an object and the current thread that will 
display the problem you encounter. Use a queued signal into the QTimer thread 
to sent the start (it will be delayed until the thread process the event, 
hopefully you do no need precision there).

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_93124102]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of Jason H 

Date: Thursday, May 6, 2021 at 5:34 PM
To: interestqt-project.org 
Subject: [Interest] QML Singleton and QTimer?
I'm trying to have a simple singleton class, but it doesn't appear that I can 
use timers?


HardwareInterface::HardwareInterface(QObject *parent) : QObject(parent)
{
m_timer = new QTimer(this);

connect(m_timer, ::timeout, this, [=](){
qDebug() << Q_FUNC_INFO;
});

m_timer->start(100); // QObject::startTimer: Timers can only be used 
with threads started with QThread

}

main.cpp: int main() {
...
qmlRegisterSingletonInstance("com.company.example", 1, 0, "HardwareInterface", 
);
...

How do we go about using timers in singletons?

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML Singleton and QTimer?

2021-05-06 Thread Jérôme Godbout
You can check the thread affinity of an object and the current thread that will 
display the problem you encounter. Use a queued signal into the QTimer thread 
to sent the start (it will be delayed until the thread process the event, 
hopefully you do no need precision there).

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_93124102]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of Jason H 

Date: Thursday, May 6, 2021 at 5:34 PM
To: interestqt-project.org 
Subject: [Interest] QML Singleton and QTimer?
I'm trying to have a simple singleton class, but it doesn't appear that I can 
use timers?


HardwareInterface::HardwareInterface(QObject *parent) : QObject(parent)
{
m_timer = new QTimer(this);

connect(m_timer, ::timeout, this, [=](){
qDebug() << Q_FUNC_INFO;
});

m_timer->start(100); // QObject::startTimer: Timers can only be used 
with threads started with QThread

}

main.cpp: int main() {
...
qmlRegisterSingletonInstance("com.company.example", 1, 0, "HardwareInterface", 
);
...

How do we go about using timers in singletons?

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] L Word

2021-05-03 Thread Jérôme Godbout
I did work for 2 operating room equipment that was using Qt (and consulting for 
another 1). We did not had issue with Qt on this based, yes we had a fixed 
version and the complete testing phase must be roll over for a changed. So you 
keep as little changed as possible when doing maintenance fixes. Major version 
cost a lot into testing and then we allow library and framework to be upgrade 
during those extensive tests phase.

One was even using Qml for the GUI, the consulting one was moving from Widget 
to Qml and the widget only was at a time where Qml was not existing.  I do not 
see the problems, you do have to cover all ground and the tests are exhaustive, 
but that would be true to any gui framework used into that field.

So it’s totally doable, sure those application doesn’t always stay on the 
latest is greatest, they are more the stable one until we do another major rev 
or a problem is found. That kind of make it hard to have to stable requirement 
and have connected devices, this often conflict, so most of those equipment 
stay off the grid for that matter.

I now work into smart city  and IoT cie inside the service division for custom 
client products now. But when the power and lightning of a city is in play, we 
still have to deliver robust infrastructure.

The library can be faulty (they all are to a different degree), but it’s more 
about knowing about it and handling it properly without effect or consequences 
to anybody that matter, if this ain’t a risk to anybody it can be acceptable to 
have something failing as long as it’s detected and the consequence of it has 
no impact. So, it’s all about testing and proper error handling and make sure 
there is no unturned stones.

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_1466370744]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of 
eric.fedosej...@gmail.com 
Date: Monday, May 3, 2021 at 11:24 AM
To: 'Benjamin TERRIER' , 'Bob Hood' 
Cc: 'Qt Interest' 
Subject: Re: [Interest] L Word
I find this whole argument that Qt is not appropriate for functional safety 
very puzzling. Aren’t vehicle dashboards QtC’s main market these days? What are 
vehicle dashboards if not safety critical?

If Qt is no longer appropriate for embedded medical devices, why is it still 
appropriate for vehicle dashboards?

From: Interest  On Behalf Of Benjamin TERRIER
Sent: Thursday, April 29, 2021 11:27 AM
To: Bob Hood 
Cc: Qt Interest 
Subject: Re: [Interest] L Word



On Thu, 29 Apr 2021 at 15:15, Bob Hood 
mailto:bho...@comcast.net>> wrote:
On 4/29/2021 4:02 AM, Bernhard Lindner wrote:



Obviously, Qt has nothing to do with this type of software engineering. And 
it's obviously

not suitable for functional safety (at least not if you take it seriously).

If this statement is true and Roland's statement that TQC actively courted that 
industry is also true, then it seems to me that he has a valid grievance, 
regardless of how he presents it.

TQC actively courted that industry, but it does not mean that they intended Qt 
to be part of the functional safety stack.
As a proof to my above statement I bring you the Qt Safe Renderer. It is a 
commercial product from TQC targeted to functional safety industry, so yes TQC 
has courted this industry.
However, it also means that Qt itself was never meant to be a part of the 
functional safety stack and is not supposed to mess with it.
The issue at hand here is not that Roland has a valid grievance or not. At 
least some of the issues he raised are valid.
The issue is that his emails are numerous and have a very low signal/noise 
ratio, that he is borderline insulting to anyone who is out of his industry and 
that in the end it lowers the value users are getting from this mailing list.
And personally I'd add that he is so badly advocating for his grievance that 
I'd prefer him not to advocate for the points where I agree with him.
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Another Qt disappointment

2021-05-03 Thread Jérôme Godbout
+1: The 2 last project I had to start went Xamarin because of this situation, I 
guess we might restart Qt dev, when 6.2 come around, until then we have a hard 
time to work into IoT  and mobile with 6, many of our lib depends on missing 
modules, we keep our old project alive with Qt 5.15.2, but nothing will be port 
to Qt 6 until 6.2 or something else if the pressure get too high or our Xamarin 
toolbox get good enough I guess.


From: Interest  on behalf of Frank Hemer 

Date: Monday, May 3, 2021 at 11:03 AM
To: interest@qt-project.org 
Subject: Re: [Interest] Another Qt disappointment
On Montag, 3. Mai 2021 16:44:43 CEST Jason H wrote:
> I have a load cell. It's a sensor that measures weight. I wanted to make a
> quick UI for it in Qt. That went as expected. Then I wanted to put the app
> on a spare Amazon Fire tablet rather than tie up a computer with it.
>
> I was running with Qt 5.15.2, but there's. bug with Bearer in Qt 5.15.2, so
> I went to update it, and lo and behold, there is no 5.15.3. It's
> apparently, commercial-only. So I figured I'd finally update to Qt 6,
> except that after installing, it turns out Qt 6.0 doesn't have
> androidextras.
>
> It's not just me that is disappointed, everyone in the comments at
> https://www.qt.io/blog/commercial-lts-qt-5.15.3-released seems disappointed
> that 5.15.3 is commercial-only.
>
> So as I sit here waiting for Qt 6 and Qt 5.15 to uninstall, and Qt 5.12 to
> install, I figured that I'd drop this note about how things are going the
> wrong way.

+1




___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Svar: Qt permanently broke on computer

2021-04-27 Thread Jérôme Godbout
You might want to use a clean path and do an absolute path for MYPROJ, some 
tools are not super friendly with path and spaces into them too.

MYPROJ = $$clean_path($$PWD/../ phidget-spinner)
That would remove the .. from the path and resolve the actual path properly.

Try to change your variable name just to make sure you ain’t hitting a name 
clash. Try to always put the {} around your var it always mor safe, if you can 
add the “ “ to your path usage too in any case where the path has spaces.


From: Jason H 
Date: Tuesday, April 27, 2021 at 3:35 PM
To: Andy Shaw 
Cc: Jérôme Godbout , interestqt-project.org 

Subject: Re: Svar: [Interest] Qt permanently broke on computer
Good news everybody, I have partialyl figured it out, but I hope you can help 
me further.


MYPROJ = ../phidget-spinner

win32 {

INCLUDEPATH +=$$MYPROJ/libraries/phidget22-windevel/lib/c

#this works:

LIBS +=-L$$PWD/../phidget-spinner/libraries/phidget22-windevel/lib/c/x64 
-lphidget22

#these breaks Qt (each):

   LIBS +=-L$$MYPROJ/libraries/phidget22-windevel/lib/c/x64 -lphidget22

   LIBS +=-L"$${MYPROJ}/libraries/phidget22-windevel/lib/c/x64" -lphidget22

   LIBS +=-L$${MYPROJ}/libraries/phidget22-windevel/lib/c/x64 -lphidget22

}

message("PWD")
message($${PWD})
message("MYPROJ")
message($$MYPROJ)
message("INCLUDEPATH")
message($${INCLUDEPATH})
message("LIBS")
message($${LIBS})

Working:
Project MESSAGE: PWD
Project MESSAGE: C:/Users/Admin/phidget-spinner
Project MESSAGE: MYPROJ
Project MESSAGE: ../phidget-spinner
Project MESSAGE: INCLUDEPATH
Project MESSAGE: ../phidget-spinner/libraries/phidget22-windevel/lib/c
Project MESSAGE: LIBS
Project MESSAGE: 
-LC:/Users/Admin/phidget-spinner/../phidget-spinner/libraries/phidget22-windevel/lib/c/x64
 -lphidget22

Now working:
Project MESSAGE: PWD
Project MESSAGE: C:/Users/Admin/phidget-spinner
Project MESSAGE: MYPROJ
Project MESSAGE: ../phidget-spinner
Project MESSAGE: INCLUDEPATH
Project MESSAGE: ../phidget-spinner/libraries/phidget22-windevel/lib/c
Project MESSAGE: LIBS
Project MESSAGE: -L../phidget-spinner/libraries/phidget22-windevel/lib/c/x64 
-lphidget22


Not sure why $$MYPROJ works for INCLUDEPATH but breaks the linker? If the link 
path is wrong I would expect it to fail the build, bot break Qt?




Sent: Monday, April 26, 2021 at 2:47 PM
From: "Andy Shaw" 
To: "Jérôme Godbout" , "Jason H" 
Cc: "interestqt-project.org" 
Subject: Svar: [Interest] Qt permanently broke on computer
What is also useful to check is to set QT_DEBUG_PLUGINS=1 as your environment 
variable, it can tell you where it is looking for the plugin then. Maybe it 
finds a qt.conf file and it is influencing the paths incorrectly there.

Andy

Fra: Interest  på vegne av Jérôme Godbout 

Dato: mandag, 26. april 2021 kl. 19:33
Til: Jason H 
Kopi: interestqt-project.org 
Emne: Re: [Interest] Qt permanently broke on computer
You might try to delete the .user files for the project and clean the build 
folder manually (erase the whole folder). Check the project config to spot any 
differences there. If some project work with the same Qt version, the Qt 
install is probably good. Make sure all you dependencies are ok.


From: Interest  on behalf of Jason H 

Date: Monday, April 26, 2021 at 11:11 AM
To: Jason H 
Cc: interestqt-project.org 
Subject: Re: [Interest] Qt permanently broke on computer


> Sent: Monday, April 26, 2021 at 11:01 AM
> From: "Jason H" 
> To: "Jason H" 
> Cc: "interestqt-project.org" 
> Subject: Re: [Interest] Qt permanently broke on computer
>
> > I tried to port an app on a Win10 PC. That went well. Then I tried to 
> > deploy (windeployqt) it.
> >
> > Now when I run it in creator I get:
> > 10:26:28: Starting 
> > C:\Users\Admin\Projects\build-phidget-spinner-Desktop_Qt_5_15_2_MinGW_64_bit-Debug\debug\phidget-spinner.exe
> >  ...
> > qt.qpa.plugin: Could not find the Qt platform plugin "windows" in ""
> >
> > I have deleted the C:\Qt dir and re-installed.
> > I have cleaned the app source dir and deleted the shadow build dirs, 
> > deleted the .pro.user file,
> > I launched QtC from the start menu.
> >
> > I have no idea how to get this working again.
>
> Some additional info:
> Other projects work.
> The crash is in this statement:
> QGuiApplication app(argc, argv);
>
> the stack indicates a crash starting at:
> QGuiApplicationPrivate::createPlatformIntegration()
>
>
> All the online help (stackexchange) seems to be about deployment, but I'm 
> just trying to run it in creator.

Update #2:

The same thing happens on a totaly new computer, never had qt on it before, 
installed Qt, copied the source and built it, some error.
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt permanently broke on computer

2021-04-26 Thread Jérôme Godbout
You might try to delete the .user files for the project and clean the build 
folder manually (erase the whole folder). Check the project config to spot any 
differences there. If some project work with the same Qt version, the Qt 
install is probably good. Make sure all you dependencies are ok.


From: Interest  on behalf of Jason H 

Date: Monday, April 26, 2021 at 11:11 AM
To: Jason H 
Cc: interestqt-project.org 
Subject: Re: [Interest] Qt permanently broke on computer


> Sent: Monday, April 26, 2021 at 11:01 AM
> From: "Jason H" 
> To: "Jason H" 
> Cc: "interestqt-project.org" 
> Subject: Re: [Interest] Qt permanently broke on computer
>
> > I tried to port an app on a Win10 PC. That went well. Then I tried to 
> > deploy (windeployqt) it.
> >
> > Now when I run it in creator I get:
> > 10:26:28: Starting 
> > C:\Users\Admin\Projects\build-phidget-spinner-Desktop_Qt_5_15_2_MinGW_64_bit-Debug\debug\phidget-spinner.exe
> >  ...
> > qt.qpa.plugin: Could not find the Qt platform plugin "windows" in ""
> >
> > I have deleted the C:\Qt dir and re-installed.
> > I have cleaned the app source dir and deleted the shadow build dirs, 
> > deleted the .pro.user file,
> > I launched QtC from the start menu.
> >
> > I have no idea how to get this working again.
>
> Some additional info:
> Other projects work.
> The crash is in this statement:
> QGuiApplication app(argc, argv);
>
> the stack indicates a crash starting at:
> QGuiApplicationPrivate::createPlatformIntegration()
>
>
> All the online help (stackexchange) seems to be about deployment, but I'm 
> just trying to run it in creator.

Update #2:

The same thing happens on a totaly new computer, never had qt on it before, 
installed Qt, copied the source and built it, some error.
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Guide me through the Qt offerings for GUIs

2021-04-22 Thread Jérôme Godbout
I wonder if it would be possible to totally declare the QtQuick scene from C++ 
without any Qml files actually, with Qt6 you got C++ binding and the Qml is 
compiled to C++ anyway. Maybe I miss something but it could be possible to 
actually only write C++ to create the actual scene?!

I would not actually do this myself but it might attract some user that are 
scare of declarative, I love Qml and the declarative binding make it super easy 
to glue the model to the GUI and the GUI is not seen into the C++ and my model 
are stay clean. I find the Qml way to split the layer of the application pretty 
clean if you understand what you have to do (keep the model and the business 
logic into C++, Qml is only for the GUI and display). The model exposes 
property and signal/slot, that it’s doesn’t care where it come from or what is 
going to modify it. That really force you to have a split between GUI layer and 
the business logic layer. I stop using QWidgets a few years ago and I don’t 
miss it a bit, haven’t seen anything I could not achieved into Qml yet, some 
are a bit trickier than they should but in the end prototyping and modifying 
the GUI is so quick, I often make the change live when I’m working with my 
graphic designer and KDAB GammaRay (just need to apply those change after).


From: Interest  on behalf of Bernhard Lindner 

Date: Thursday, April 22, 2021 at 7:01 AM
To: interest@qt-project.org 
Subject: Re: [Interest] Guide me through the Qt offerings for GUIs

> Widgets are heavy, often very complex objects. They often come with all bells 
> and
> whistles. QPushButton always has the data structure to support 
> QPushButton::setMenu,
> even if probably <1% of buttons out there ever use that feature. That’s ok on 
> desktop
> machines, it’s not ok on embedded systems.

Hm, this kind of confirms my impression: Quick is lightweight, simplified and 
suited for
embedded and touch. While widgets are more powerful and suited for complex 
desktops
applications. This makes me wonder even more why Qt gave up widgets. The logical
explanation is, Qt kind of gave up desktop.

You explained why the widgets concept is not compatible with the Quick concept. 
Can you
also explain why it was not possible to implement Quick as an additional, 
mostly widget-
independent C++ layer and then wrap it declaratively?

--
Best Regards,
Bernhard Lindner

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Guide me through the Qt offerings for GUIs

2021-04-22 Thread Jérôme Godbout
Thanks Volker, that was insightful answer. I would love more answer like that!

From: Interest  on behalf of Volker Hilsheimer 

Date: Thursday, April 22, 2021 at 4:52 AM
To: Bernhard Lindner 
Cc: interest@qt-project.org 
Subject: Re: [Interest] Guide me through the Qt offerings for GUIs
> On 21 Apr 2021, at 22:39, Bernhard Lindner  
> wrote:
>
>
>> Personally, I think the exsting QtQuick element should be scrapped and just 
>> focus on QML
>> versions of the existing Widget functionality. I love the QML syntax, hate 
>> that it's not
>> just a layer on top of widgets.
>
> +100
>
> Why this wasn't done from the start is one of the hardest puzzles! I ask 
> myself this
> question every time I read the three letters "QML" :-)


Indeed, it’s an obvious knee-jerk reaction to have when looking at Qt and 
wondering why there are several UI frameworks.

But there are several reasons why things are as they are. Some of them:

* imperative painting

Paint-event based drawing with a “pen” is not easily reconcilable with how GPUs 
like to work. Without a persistent scene graph that is uploaded to the GPU, 
much of the performance you get from a GPU is lost. An animation at 60fps is 
ideally just a draw call on the GPU with some different transformations, not a 
completely new upload of a completely reconstructed scene graph for each frame.

Widgets can draw into a framebuffer texture that can be used, and that allows 
for some integration, but that doesn’t give you great performance.


* integer coordinates and clipping

Widgets work with integer coordinates, which starts to be problematic now that 
we have high-DPI displays. And widgets clip are clipped to their parent 
geometry, which was the right choice for those UIs, but is very limiting and 
requires a lot of complex code to solve conceptually simple problems. Hello 
macOS focus ring.
Quick items do not clip and are not clipped, which gives a lot more freedom in 
how shapes are combined and structured.


* declarative vs imperative APIs

Many widget classes don’t have a declarative-friendly API. Plenty of widget 
properties have side effects on other properties, so the order in which 
properties are set matters. That doesn’t work well in a declarative world.


* weight

Widgets are heavy, often very complex objects. They often come with all bells 
and whistles. QPushButton always has the data structure to support 
QPushButton::setMenu, even if probably <1% of buttons out there ever use that 
feature. That’s ok on desktop machines, it’s not ok on embedded systems.


* complexity and hard to customize

Inheritance and reimplementing are nice concepts on paper and works great if 
you build your own custom widget from a reasonably abstract base class. But if 
you have ever tried to subclass e.g. QTreeWidget to modify how certain 
interactions work, then you know how hard it can be to not break the complex 
states that the default implementations rely on.



So, making widgets work in a declarative, GPU friendly world where ease of 
customisation is more important than standard look’n'feel would have required 
many changes to widgets. Those would have been impossible to make without 
invalidating or breaking a lot of code out there, and still not given us the UI 
components we would have needed.

I’m sure there are opportunities to share more code between widgets and quick 
world esp on the UI framework classes, and with Qt 6 we have taken some steps 
into that direction. But whether the benefits outweigh the risks and effort 
requires a case-by-case evaluation.


Volker

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Help a unix guy on windows qmake

2021-04-21 Thread Jérôme Godbout
For my .pri and qmake build process (I haven’t move to cmake yet) I do some 
variable definition for the path:
AMOTUS_Qt_FILESYSTEM_PATH = $$clean_path($$PWD/../FileSystem)

So you could define a variable anywhere you are (relative to the .pro or .pri 
files). Might help finding your project root or define it.

This allows me to have a variable that point to some module folder later on. I 
can copy, include, etc files/folders based on those variables, also make 
conditional check if the variable is defined to include glue between module 
(extension modules with each other).

Something like:
contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, Amotus_Qt_FileSystem){
include($$AMOTUS_Qt_FILESYSTEM_PATH/Amotus_Qt_FileSystem.pri)
}

From: Interest  on behalf of Jason H 

Date: Wednesday, April 21, 2021 at 1:42 PM
To: Thiago Macieira 
Cc: interest@qt-project.org 
Subject: Re: [Interest] Help a unix guy on windows qmake


> Sent: Wednesday, April 21, 2021 at 1:14 PM
> From: "Thiago Macieira" 
> To: interest@qt-project.org
> Subject: Re: [Interest] Help a unix guy on windows qmake
>
> On Wednesday, 21 April 2021 09:54:09 PDT Jason H wrote:
> > Now, when compiling, regardless of shadow build or not, refer to the libs by
> > adding to the project: +++ project.pro
> > + mingw {
> > + INCLUDEPATH += $PROJ/libraries/win/include
> > + LIBS += -L$PROJ/libraries/win/$ARCH -lvendor
> > + }
> >
> > It seems that $PWD ${PWD} or whatever ($${PWD}?) refer to the build dir, be
> > it shadow or not. I don't want to copy the libraries to the shadow dir in
> > QMAKE_PRE_LINK because they *never* change.
>
> You're mixing environment variables and qmake variables. Qmake variables
> always start with a double dollar sign and are expanded by qmake when it
> writes the Makefile output. You can see their value with message().
>
> qmake does not expand environment variables at all.
>
> $ X=A qmake Y=b /dev/stdin -o /dev/null <<<'message(r = $X $$Y)'
> Project MESSAGE: r = $X b
>
> The environment variables are written as-is to your Makefile. It's up to you
> to write something that make will understand.
>
> $PROJ is not a valid environment variable expansion in Make.


Right. I used $PROJ for illustrative purposes. I guess the flaw in my thinking
is that when the shadow build is made, that there is some way to reference the
original location( other than ../project_name

Maybe all I need is:
PROJ=../project

Thank you for example. Very enlightening.
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Guide me through the Qt offerings for GUIs

2021-04-21 Thread Jérôme Godbout
You might want to give the showroom a look, some of them are Qml based:
https://showroom.qt.io/

Some use the Felgo layer:
https://felgo.com/resources/success-stories

http://en.esotericsoftware.com/forum/Facial-Animation-in-Qml-and-pushing-past-the-Spine-limits-3788
http://en.esotericsoftware.com/spine-runtimes#Qt%2FQML


https://opsensmedical.com/products/optomonitor/
https://www.kdab.com/development-resources/videos-webinars/demo-videos/

https://www.learnpyqt.com/examples/

Note: this is a personal point of view, strongly opinion ahead from that point
as for the Desktop application, the line is blurring more and more everyday 
(iPad and surface pro are good example that “desktop” is no more like it used 
to be for most people). The workstation is more for a specific corner case now 
a day. I would not limit myself to a few platforms, mobile and desktop are 
becoming a mix bag and removing platform is a bad future choice I think. I 
never liked the “native” look and feel, I prefer my user to be in my app feel 
across platform instead, they don’t get lost when using it on mobile, Mac OS or 
Windows… it doesn’t matter. Facebook, messenger, Google application, Apple 
application all tends to be this way too. The OS is just a low level 
tool/helper in the end, the actual work is made inside your application, the 
end user often care very little about the OS, as long as they can find and 
launch their app and do their stuff easily.

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_1674119260]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of 
eric.fedosej...@gmail.com 
Date: Wednesday, April 21, 2021 at 8:37 AM
To: interest@qt-project.org 
Subject: Re: [Interest] Guide me through the Qt offerings for GUIs
Where are the examples of real QML desktop applications on The Qt Co. website? 
I did a quick walk through the customer showcase and cannot find them.

From: Interest  On Behalf Of Giuseppe D'Angelo 
via Interest
Sent: Monday, April 19, 2021 8:36 AM

This is false, as a quick walk through the customer showcase on TQC's website 
will show.

On 18/04/2021 14:50, Roland Hughes wrote:
> I guess QML is more present in embedded? Or maybe some entreprise
> stuff we don't know about...
> Just phones and John Deere.

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Guide me through the Qt offerings for GUIs

2021-04-16 Thread Jérôme Godbout
I have been using Qml into Medical CAD software (I no longer work there), there 
ain’t much screenshot available on their web site, since this is more internal 
or Dr application:
http://bodycad.com/en/healthcare-professionals/products/fine-osteotomy#tt_content_716
Scroll down the page there is 4 screenshot of 2 different application (they 
both use Qml Qt Quick Control, the control have been skinned with a custom 
theme (they wanted the same rendering on each platform for their cie trademark 
and not the native look).

I also have seen (work a little) for
https://opsensmedical.com/products/optomonitor/
They have a custom GUI for the OR room.

These are serious application. Now if you want true native look on each 
platform, the default theme is not 100% accurate but you can easily tweak them 
and change the look and feel of QQC 2 using the templates. And you can make a 
theme system that switch color easily (dark versus light theme is a breeze if 
planned ahead and access color from a global theme object with binding).

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_1535244953]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of Matthew Woehlke 

Date: Friday, April 16, 2021 at 9:17 AM
To: Qt Interest 
Subject: Re: [Interest] Guide me through the Qt offerings for GUIs
On 15/04/2021 06.25, Rui Oliveira wrote:
> I feel very hesitant to start a project on QWidgets. It feels like
> starting a project on dead tech.
>
> I know QWidgets are no longer "interesting". Even KDE moved on from
> them...

Is there an example of a *serious* application that uses QQC? (I don't
count plasma-desktop.) Or even, any serious application using something
*like* QQC?

I'm talking something like gimp, krita, libreoffice, inkscape,
thunderbird... AFAIK all of these — indeed, everything to my knowledge
that I use on a regular bases — use Qt Widgets or something similar.

--
Matthew
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML bug?

2021-04-16 Thread Jérôme Godbout
Both are Component (header and the row delegate), they will be instantiated 
later. Component are like a recipe to be instantiated, they can bind to actual 
instance into the current scope.  So the current context doesn’t known the 
other instance value since the header is not an object instantiated but a 
Component. Both component has the ListView Context as parent Context. They are 
sibling Context so they do not known each other.

Bind the delegate tot connectionsList.width  just like the header does and that 
should remove the bind issue with hostItem.width.

If you need to have both value, add property into your listview that contain 
the value and both Component can bind to the ListView property instead.

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_1907764182]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of Alexander 
Dyagilev 
Date: Friday, April 16, 2021 at 7:25 AM
To: interest@qt-project.org 
Subject: [Interest] QML bug?

Hello,

Is this QML bug or am I misunderstanding something?

It says:
qrc:/qml_ui/desktop/BottomPanel/ConnectionsTab.qml:75: ReferenceError: hostItem 
is not defined
qrc:/qml_ui/desktop/BottomPanel/ConnectionsTab.qml:84: ReferenceError: portItem 
is not defined

Why are not they defined? These are ids of items defined in the same qml file.

Code:

import QtQuick 2.10

import QtQuick.Controls 2.4

import QtQuick.Layouts 1.3

import "../BaseElements"

import org.freedownloadmanager.fdm 1.0

Item {

anchors.fill: parent

BaseLabel {

text: qsTr("There are no connections") + App.loc.emptyString

anchors.centerIn: parent

visible: !connectionsList.visible

font.pixelSize: 13

}

ListView {

id: connectionsList

anchors.fill: parent

anchors.bottomMargin: 1

ScrollBar.vertical: ScrollBar{}

flickableDirection: Flickable.AutoFlickIfNeeded

boundsBehavior: Flickable.StopAtBounds

clip: true

headerPositioning: ListView.OverlayHeader

visible: downloadsItemTools.running && count

model: downloadsItemTools.connectionsModel

header: RowLayout {

id: columns

width: parent.width

spacing: 0

z: 2

TablesHeaderItem {

id: hostItem

text: qsTr("Host") + width + App.loc.emptyString

Layout.preferredWidth: Math.max(300, headerMinimumWidth)

color: appWindow.theme.background

}

TablesHeaderItem {

id: portItem

text: qsTr("Port") + App.loc.emptyString

Layout.preferredWidth: headerMinimumWidth

color: appWindow.theme.background

}

TablesHeaderItem {

id: countItem

text: qsTr("Connection count") + App.loc.emptyString

Layout.fillWidth: true

color: appWindow.theme.background

Rectangle {

height: parent.height

width: 1

anchors.right: parent.right

color: appWindow.theme.border

}

}

}

delegate: RowLayout {

width: parent.width

height: 22

spacing: 0

BaseLabel {

text: model.host

Layout.preferredWidth: hostItem.width

Layout.minimumWidth: Layout.preferredWidth

Layout.fillHeight: true

leftPadding: 6

Rectangle{anchors.fill: parent;color:"yellow";z:-1}

}

BaseLabel {

text: model.port

Layout.preferredWidth: portItem.width

Layout.minimumWidth: Layout.preferredWidth

Layout.fillHeight: true

Rectangle{anchors.fill: parent;color:"red";z:-1}

leftPadding: 6

}

BaseLabel {

text: model.connectionCount

Layout.fillWidth: true

Layout.fillHeight: true

leftPadding: 6

Rectangle{anchors.fill: parent;color:"blue";z:-1}

}

}

}

}




___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] [EXTERNAL] Re: Send Data to JavaScript

2021-04-14 Thread Jérôme Godbout
Yeah that would be a pain, but if it work you can try to reduce the QVariant 
usage to a minimum from that point.


  1.  QVariantMap
  2.  QMap
  3.  QMap
  4.  QMap
  5.  QMap>
  6.  QMap>
See up to where you can reach before it fail, it will tell you which data type 
is not working for the type mapping. If they all succeed, then something might 
be wrong with the QList or QStringList if you prefer. Maybe the 
exposed type doesn’t handle the typedef properly when nested.

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_960691443]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of John Schneiderman 

Date: Wednesday, April 14, 2021 at 2:56 AM
To: qt qt 
Subject: Re: [Interest] [EXTERNAL] Re: Send Data to JavaScript
On 12.04.2021 20:48, Jérôme Godbout wrote:
Have you tried with a QVariantMap for your Q_PROPERTY instead? Will be dull to 
convert from QVAriant to list and string for each values, but will probably 
work.
I've not tried using that, but looking at it, wouldn't it mean that I'd 
have to convert it each time to get the QStringList?


--

John Schneiderman

Senior Software Engineer

CDPR Squad

GOG.com
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Send Data to JavaScript

2021-04-12 Thread Jérôme Godbout
Have you tried with a QVariantMap for your Q_PROPERTY instead? Will be dull to 
convert from QVAriant to list and string for each values, but will probably 
work.

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_487195805]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of John Schneiderman 

Date: Monday, April 12, 2021 at 9:17 AM
To: qt qt 
Subject: [Interest] Send Data to JavaScript
I'm attempting to send data to the JavaScript side of the QWebEngine
code. This data is being emitted via a signal. The registration is
connected correctly as other components work just fine, though they're
emitting only a single int or QString.

An example of what I'm attempting is below:

class Demo : QObject

{

 Q_OBJECT

public:

 Q_PROPERTY(
 QMap mappings
 MEMBER mappings_
 NOTIFY mappingsChanged
 )

};


What I'm expecting is that mappings would be transformed on the
JavaScript side as:

mappings {

 "key" : ["abc", "def"]...

}

However, when I try to view the data in the emitted signal it's always
null. Any suggestions where I should look for more answers or perhaps
I'm going in an incorrect direction?

Thanks,


--
John Schneiderman
Senior Software Engineer
CDPR Squad
GOG.com
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Software architecture style options

2021-03-31 Thread Jérôme Godbout
It mostly depends on what your mobile/Desktop application capacity. If they are 
indeed doing business logic and can have some kind of offline business logic, I 
would go Qt / Qml ( you could also distribute the application on the mobile 
easily with Qt/Qml). That way you can recycle the C++ code from the raspberryPi 
into common lib with std C++.

The WebGL doesn’t allow multiple users as far as I known to render the GUI into 
WebGL (correct me if I’m wrong here I haven’t used it yet, so take this with a 
grain of salt), but I don’t see that as a solution for multiple simultaneous 
user into different usage context. I always saw this option as a good 
configuration view for a device, a config page for a router for example. I’m 
speculating on this, I haven’t play with it, but my understanding so far: If 
you would need multiple user you would need to spawn a webgl process per user 
connected (CGI script or something?!?). And having the business logic into a 
single process that the webgl GUI process access.

But if your GUI are only action controller that are process into the 
centralized business logic, that must always be connected to the device, I 
would go full web browser and can simply wrap you web site into an Electron 
app, saving you a lot of work and have a similar experience across the line and 
reduce the development time considerably.

Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_403765278]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of Megidd Git 

Date: Wednesday, March 31, 2021 at 2:22 AM
To: interest@qt-project.org 
Subject: [Interest] Software architecture style options
Hi everyone,

Maybe someone can help:

https://softwareengineering.stackexchange.com/q/424966/176220

I just need some pointers to guide me in the right direction to explore 
architecture style options.

Thanks,


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Android OpenSSL EVP

2021-03-25 Thread Jérôme Godbout
Ok, sorry for the noise, the solution was not so hard, just needed to also 
specify the libs per arch on top of the android extra libs

LIBS += \
$$OPEN_SSL_PATH/Android/$$ANDROID_TARGET_ARCH/libcrypto_1_1.so \
$$OPEN_SSL_PATH/Android/$$ANDROID_TARGET_ARCH/libssl_1_1.so


From: Interest  on behalf of Jérôme Godbout 

Date: Thursday, March 25, 2021 at 3:05 PM
To: Qt Interest 
Subject: [Interest] Android OpenSSL EVP
Hi,
anyone have use OpenSSL EVP interface under Android? I manage to make it work 
under MacOS, Windows, Linux, but under Android I can add the OpenSSL lib, I 
compiled them for each arch (x86, x86_64, armv7, armv8) and I add all the libs 
with (I use Qt 5.15.2 only for this):

INCLUDEPATH+= $$OPEN_SSL_PATH/include
ANDROID_EXTRA_LIBS += \
$$OPEN_SSL_PATH/Android/armeabi-v7a/libcrypto_1_1.so \
$$OPEN_SSL_PATH/Android/armeabi-v7a/libssl_1_1.so \
$$OPEN_SSL_PATH/Android/arm64-v8a/libcrypto_1_1.so \
$$OPEN_SSL_PATH/Android/arm64-v8a/libssl_1_1.so \
$$OPEN_SSL_PATH/Android/x86/libcrypto_1_1.so \
$$OPEN_SSL_PATH/Android/x86/libssl_1_1.so \
$$OPEN_SSL_PATH/Android/x86_64/libcrypto_1_1.so \
$$OPEN_SSL_PATH/Android/x86_64/libssl_1_1.so

This work to use OpenSSL, but I cannot use the EVP, header are added, it fail 
at link time of the Qt application.  I’m not even sure what Qt does with 
ANDROID_EXTRA_LIBS and how can the C++ code can link against the current arch 
lib?
Any way to do this that will work on each arch? This is how I compiled my libs 
btw (under MacOS):

#!/bin/bashVERSION=1.1.1j
ANDROID_SDK_HOME=/Users/Shared/AndroidSDK
export ANDROID_NDK_HOME=$ANDROID_SDK_HOME/ndk/21.1.6352462
if [ ! -f "openssl-$VERSION.tar.gz" ]; then
wget https://www.openssl.org/source/openssl-$VERSION.tar.gz
fi
for arch in "armeabi-v7a" "arm64-v8a" "x86" "x86_64"
do
pushd .
rm -fr $arch
mkdir $arch
rm -fr openssl-$VERSION
tar xf openssl-$VERSION.tar.gz
cd openssl-$VERSIONcase $arch in
armeabi-v7a)
ANDROID_API=16
CONFIG_ARCH="arm"
;;
x86)
ANDROID_API=16
CONFIG_ARCH="x86"
;;
arm64-v8a)
ANDROID_API=21
CONFIG_ARCH="arm64"
;;
x86_64)
ANDROID_API=21
CONFIG_ARCH="x86_64"
;;
esac
ANDROID_TOOLCHAIN=""
for host in "linux-x86_64" "linux-x86" "darwin-x86_64" "darwin-x86"
do
if [ -d "$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/$host/bin" ]; then

ANDROID_TOOLCHAIN="$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/$host/bin"
break
fi
doneexport PATH="$ANDROID_TOOLCHAIN":"$PATH"./Configure shared 
android-${CONFIG_ARCH} -D__ANDROID_API__=${ANDROID_API} || exit 1
make dependmake -j$(nproc) SHLIB_VERSION_NUMBER= SHLIB_EXT=_1_1.so 
build_libs || exit 1
llvm-strip --strip-all libcrypto_1_1.so
llvm-strip --strip-all libssl_1_1.so
cp libcrypto_1_1.so ../$arch || exit 1
cp libssl_1_1.so ../$arch || exit 1
popd
done



Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_868826015]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Android OpenSSL EVP

2021-03-25 Thread Jérôme Godbout
Hi,
anyone have use OpenSSL EVP interface under Android? I manage to make it work 
under MacOS, Windows, Linux, but under Android I can add the OpenSSL lib, I 
compiled them for each arch (x86, x86_64, armv7, armv8) and I add all the libs 
with (I use Qt 5.15.2 only for this):

INCLUDEPATH+= $$OPEN_SSL_PATH/include
ANDROID_EXTRA_LIBS += \
$$OPEN_SSL_PATH/Android/armeabi-v7a/libcrypto_1_1.so \
$$OPEN_SSL_PATH/Android/armeabi-v7a/libssl_1_1.so \
$$OPEN_SSL_PATH/Android/arm64-v8a/libcrypto_1_1.so \
$$OPEN_SSL_PATH/Android/arm64-v8a/libssl_1_1.so \
$$OPEN_SSL_PATH/Android/x86/libcrypto_1_1.so \
$$OPEN_SSL_PATH/Android/x86/libssl_1_1.so \
$$OPEN_SSL_PATH/Android/x86_64/libcrypto_1_1.so \
$$OPEN_SSL_PATH/Android/x86_64/libssl_1_1.so

This work to use OpenSSL, but I cannot use the EVP, header are added, it fail 
at link time of the Qt application.  I’m not even sure what Qt does with 
ANDROID_EXTRA_LIBS and how can the C++ code can link against the current arch 
lib?
Any way to do this that will work on each arch? This is how I compiled my libs 
btw (under MacOS):

#!/bin/bashVERSION=1.1.1j
ANDROID_SDK_HOME=/Users/Shared/AndroidSDK
export ANDROID_NDK_HOME=$ANDROID_SDK_HOME/ndk/21.1.6352462
if [ ! -f "openssl-$VERSION.tar.gz" ]; then
wget https://www.openssl.org/source/openssl-$VERSION.tar.gz
fi
for arch in "armeabi-v7a" "arm64-v8a" "x86" "x86_64"
do
pushd .
rm -fr $arch
mkdir $arch
rm -fr openssl-$VERSION
tar xf openssl-$VERSION.tar.gz
cd openssl-$VERSIONcase $arch in
armeabi-v7a)
ANDROID_API=16
CONFIG_ARCH="arm"
;;
x86)
ANDROID_API=16
CONFIG_ARCH="x86"
;;
arm64-v8a)
ANDROID_API=21
CONFIG_ARCH="arm64"
;;
x86_64)
ANDROID_API=21
CONFIG_ARCH="x86_64"
;;
esac
ANDROID_TOOLCHAIN=""
for host in "linux-x86_64" "linux-x86" "darwin-x86_64" "darwin-x86"
do
if [ -d "$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/$host/bin" ]; then

ANDROID_TOOLCHAIN="$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/$host/bin"
break
fi
doneexport PATH="$ANDROID_TOOLCHAIN":"$PATH"./Configure shared 
android-${CONFIG_ARCH} -D__ANDROID_API__=${ANDROID_API} || exit 1
make dependmake -j$(nproc) SHLIB_VERSION_NUMBER= SHLIB_EXT=_1_1.so 
build_libs || exit 1
llvm-strip --strip-all libcrypto_1_1.so
llvm-strip --strip-all libssl_1_1.so
cp libcrypto_1_1.so ../$arch || exit 1
cp libssl_1_1.so ../$arch || exit 1
popd
done



Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_868826015]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML Image size vs sourceSize strange things

2021-03-23 Thread Jérôme Godbout

Yes good point, take care those built-in size attributes are optional, might 
not be there into an SVG, you might not want to count on it.

From: Interest  on behalf of Giuseppe D'Angelo 
via Interest 
Date: Tuesday, March 23, 2021 at 10:53 AM
To: interest@qt-project.org 
Subject: Re: [Interest] QML Image size vs sourceSize strange things
Il 23/03/21 14:16, Jérôme Godbout ha scritto:
> Do you really need to same memory by reducing the source size? I think
> you should left the source size alone and sample the image from the full
> source. Source size for SVG doesn’t make any sense, it’s vectoriel,
> doesn’t have any size, it can scale to any dimension.

This isn't accurate. SVG files have a builtin "wanted" size, which is
IIRC what Qt would use by default:

> https://www.w3.org/TR/SVG11/struct.html#SVGElementWidthAttribute

By explictly setting `sourceSize` you're asking Qt to rasterize the SVG
at a different resolution rather than the wanted one (and downscaling
when rendering).


My 2 c,
--
Giuseppe D'Angelo | giuseppe.dang...@kdab.com | Senior Software Engineer
KDAB (France) S.A.S., a KDAB Group company
Tel. France +33 (0)4 90 84 08 53, http://www.kdab.com
KDAB - The Qt, C++ and OpenGL Experts
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML Image size vs sourceSize strange things

2021-03-23 Thread Jérôme Godbout
Do you really need to same memory by reducing the source size? I think you 
should left the source size alone and sample the image from the full source. 
Source size for SVG doesn’t make any sense, it’s vectoriel, doesn’t have any 
size, it can scale to any dimension. When playing with the image size (not the 
source) it will sample the source for each pixel, not sure about the algorithm 
but you might need an higher source resolution to get a proper image without 
artifact. I would at least take the Screen.devicePixelRatio into the source 
size into account and even add a x2 to ensure proper sampling, but I don’t see 
any real advantage to play with the source size unless you really are consuming 
way too much memory.

This might slow you down if the same image is using different sourceSize:

Note: Changing this property dynamically causes the image source to be 
reloaded, potentially even from the network, if it is not in the disk cache.


On Mar 23, 2021, at 3:31 AM, Alexander Dyagilev 
mailto:alervd...@gmail.com>> wrote:


Hello,

We had a strange problem with blurred images under Retina displays. Left part 
of the image - before, right one - after the fix.



Our QML code was using with to show images:

Image {

anchors.verticalCenter: parent.verticalCenter

sourceSize.width: 25

sourceSize.height: 25

source: preview.url

}



I've tried to multiply sourceSize by Screen.devicePixelRatio - images became 
bigger so they did not fit their places.

Then I've replaced sourceSize.width with just width and the same for height. 
And it works fine now.

My questions is:

1) Is it required to multiply sourceSize by devicePixelRatio? Or is it managed 
automatically? It seems that it is managed automatically for PNG and NOT 
managed for SVG.

2) If it is already managed automatically for PNG (these images preview.url are 
PNGs) then why was it blurred? The original PNG image is of size 64x64 pixels 
under Retina displays.

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest

Jerome Godbout
Software/Firmare Lead Amotus

C: (581) 777-0050
O: (418) 800-1073 ext.: 114
godbo...@amotus.ca

[cid:image007.png@01D70B66.39FB01C0]

dimonoff.com   |amotus.ca

We have moved!
1015 Avenue Wilfrid-Pelletier, Québec, QC G1W 0C4, 4e étage

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] The willy-nilly deletion of convenience, methods (was: Mixing Commercial and Open...)

2021-03-22 Thread Jérôme Godbout
+1 over her on Qml being my favorite UI framework, did crazy think with it
 we did render 3D into Qml scene before Qt 3D was there, rendering an 
engine into texture into our own declarative engine rendering exposed nodes.
 Multiple QQmlEngine for pipeline flow rendering pass (fast rendering into 
main GUI thread) other engine into another thread render with more precision 
into the background but declare into a declarative way of Qml. Was mostly a 
reality, only 1 thing ever stop us from releasing this at large, the Qml 
singleton bug from qmldir, this issue was never fixed btw). We could put 
rendering progress bar upside the 3D object as they get sharper and better 
smoothed and more precise into our CAD software, was very nice to see with the 
3D scene still completely fluid and user interactable while the heavy work was 
done and could be easily scripted by the high level application dev.

+1 on waiting for 6.2 before any switch can even be possible, will see when it 
get there, before it would be just plain huge waste of time.

But I see less and less Qt contract coming our way, client are scare of Qt 
license right now, everybody feel like this is a nuclear waste of some kind 
that they better to stay away as of now. I cannot really blame them, when the 
question always end up check with your lawyer, they don’t they just stroke the 
option out or if the answer the price toll depends will depend… they stroke 
that option out too!

I did my share of mobile and desktop development for 
Windows/Linux/MacOS/iOS/Android and Qt always was my fun ride to write a commun 
source code. But I touch it less and less and that make me sad, I do more and 
more Xamarin/.Net Standard 2/Unity/Blazor combo code those days.  This with 
embedded IoT device can go a long way and the cost is predictable… Client like 
predictable, they like that too much but they always do…


Jérôme Godbout, B. Ing.

Software / Firmware Team Lead
O: (418) 682-3636 ext.: 114
C: (581) 777-0050
godbo...@dimonoff.com<mailto:godbo...@dimonoff.com>
[signature_1251317868]<https://www.dimonoff.com/>
dimonoff.com<https://www.dimonoff.com/>
1015 Avenue Wilfrid-Pelletier,
Québec, QC G1W 0C4, 4e étage


From: Interest  on behalf of ekke 

Date: Monday, March 22, 2021 at 11:48 AM
To: interest@qt-project.org 
Subject: Re: [Interest] The willy-nilly deletion of convenience, methods (was: 
Mixing Commercial and Open...)
+1

Qt for me still is the best cross-platform solution for mobile app development 
enabling me to build great (and performant) apps from one source.

from time to time looking at Flutter but still feel better using QML for UI and 
C++ for the rest.

cannot say much about Qt6 yet because I'm waiting for 6.2 to get all the 
modules I need - will start refactoring all the depricated parts next 
weeks/months step by step beside my daily work

Am 22.03.21 um 16:22 schrieb Nelson, Michael:

+1 for idea that mobile support has not been the priority in QtCo's mind that I 
need it to be.

+1 for idea that filing bug reports and voting for them did not result in my 
concerns being addressed. UX with QML across mobile and desktop platforms could 
be better but many issues simply sit unaddressed.



Still, cross-platform support is nevertheless strong and QML is indeed a great 
language for UI, so I'm still a paying customer, for now. Keeping an eye on 
Flutter, though. 



Best regards,





MICHAEL NELSON | Sr. Software Engineer

T  703-406-2800, 341

michael.nel...@otthydromet.com<mailto:michael.nel...@otthydromet.com> | 
www.otthydromet.com<http://www.otthydromet.com>





--

ekke (ekkehard gentz)

independent software architect
international development native mobile business apps
Qt Mobile: Android, iOS, W10 (former projects: BlackBerry 10)

Qt Champion
BlackBerry Elite Developer

max-josefs-platz 30, D-83022 rosenheim, germany

twitter: @ekkescorner
LinkedIn: http://linkedin.com/in/ekkehard/
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QSqlQuery bind value

2021-03-17 Thread Jérôme Godbout
Oh, great, thanks for the pointer, will do, good to known.


On Mar 16, 2021, at 5:48 PM, Elvis Stansvik 
mailto:elvst...@gmail.com>> wrote:

Yea, you can always use db.driver()->escapeIdentifier(x,
QSqlDriver::TableName) if you want to sleep a little better anyway.

Elvis


Den tis 16 mars 2021 kl 21:52 skrev Jérôme Godbout 
mailto:godbo...@amotus.ca>>:

Thanks, that was the problems, this is annoying, but I do create the query 
prepare with a String with arg (I known this is bad, but the tablename is 
provided by inner code only, this is not user inputs of any sort).

On Mar 16, 2021, at 4:23 PM, Elvis Stansvik 
mailto:elvst...@gmail.com>> wrote:

Den tis 16 mars 2021 kl 21:21 skrev Elvis Stansvik 
mailto:elvst...@gmail.com>>:


Den tis 16 mars 2021 kl 20:19 skrev Jérôme Godbout 
mailto:godbo...@amotus.ca>>:


Hi,

I’m trying to use the Sql with Sqlite with Qt. The database seem to be working 
just fine, but I run into troubles with the bind value. The named bind doesn’t 
seem to work (Qt 5.15.2, Mac OS):

m_sql->m_create_table(m_database);

m_sql->m_create_table.prepare(R"raw(CREATE TABLE IF NOT EXISTS :table name 
(idkey TEXT PRIMARY KEY, data TEXT) WITHOUT ROWID)raw”);


You can't use a bound parameter value for the table name. This would
be the case even if you used the SQLite C library. I imagine this is
the case in other database engines as well.


Some good answers here:
https://stackoverflow.com/questions/11312737/can-i-parameterize-the-table-name-in-a-prepared-statement

Elvis


Elvis



Note: I did try to add the ending ; it make no difference. Is it required? I do 
not see it in any example.


The prepare return false for some reason, I did try with quotes this solve the 
prepare but I thing the escaping should be done automatically?! Is the value 
escape character automatically for named and positional args? What is wrong 
with this query, the query work just fine into sqlite3.

CREATE TABLE IF NOT EXISTS ':tablename’ (idkey TEXT PRIMARY KEY, data TEXT) 
WITHOUT ROWID;


It doesn’t complain, but create a table name :table name instead! The replace 
doesn’t occur into the quote ‘ '

This query work just fine into sqlite command line.

CREATE TABLE IF NOT EXISTS toto (idkey TEXT PRIMARY KEY, data TEXT) WITHOUT 
ROWID;


What is wrong with this?! This seem to be just like the examples, is SQLite any 
special in that regards (I known only a single statement is required for 
sqlite).

Thanks,

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Jerome Godbout
Software/Firmare Lead Amotus

C: (581) 777-0050
O: (418) 800-1073 ext.: 114
godbo...@amotus.ca



dimonoff.com   |amotus.ca

We have moved!
1015 Avenue Wilfrid-Pelletier, Québec, QC G1W 0C4, 4e étage


Jerome Godbout
Software/Firmare Lead Amotus

C: (581) 777-0050
O: (418) 800-1073 ext.: 114
godbo...@amotus.ca<mailto:godbo...@amotus.ca>

[cid:image007.png@01D70B66.39FB01C0]

dimonoff.com<http://dimonoff.com>   |amotus.ca<http://amotus.ca>

We have moved!
1015 Avenue Wilfrid-Pelletier, Québec, QC G1W 0C4, 4e étage

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QSqlQuery bind value

2021-03-16 Thread Jérôme Godbout
Thanks, that was the problems, this is annoying, but I do create the query 
prepare with a String with arg (I known this is bad, but the tablename is 
provided by inner code only, this is not user inputs of any sort).

On Mar 16, 2021, at 4:23 PM, Elvis Stansvik 
mailto:elvst...@gmail.com>> wrote:

Den tis 16 mars 2021 kl 21:21 skrev Elvis Stansvik 
mailto:elvst...@gmail.com>>:

Den tis 16 mars 2021 kl 20:19 skrev Jérôme Godbout 
mailto:godbo...@amotus.ca>>:

Hi,

I’m trying to use the Sql with Sqlite with Qt. The database seem to be working 
just fine, but I run into troubles with the bind value. The named bind doesn’t 
seem to work (Qt 5.15.2, Mac OS):

m_sql->m_create_table(m_database);

m_sql->m_create_table.prepare(R"raw(CREATE TABLE IF NOT EXISTS :table name 
(idkey TEXT PRIMARY KEY, data TEXT) WITHOUT ROWID)raw”);

You can't use a bound parameter value for the table name. This would
be the case even if you used the SQLite C library. I imagine this is
the case in other database engines as well.

Some good answers here:
https://stackoverflow.com/questions/11312737/can-i-parameterize-the-table-name-in-a-prepared-statement

Elvis


Elvis



Note: I did try to add the ending ; it make no difference. Is it required? I do 
not see it in any example.


The prepare return false for some reason, I did try with quotes this solve the 
prepare but I thing the escaping should be done automatically?! Is the value 
escape character automatically for named and positional args? What is wrong 
with this query, the query work just fine into sqlite3.

CREATE TABLE IF NOT EXISTS ':tablename’ (idkey TEXT PRIMARY KEY, data TEXT) 
WITHOUT ROWID;


It doesn’t complain, but create a table name :table name instead! The replace 
doesn’t occur into the quote ‘ '

This query work just fine into sqlite command line.

CREATE TABLE IF NOT EXISTS toto (idkey TEXT PRIMARY KEY, data TEXT) WITHOUT 
ROWID;


What is wrong with this?! This seem to be just like the examples, is SQLite any 
special in that regards (I known only a single statement is required for 
sqlite).

Thanks,

___
Interest mailing list
Interest@qt-project.org<mailto:Interest@qt-project.org>
https://lists.qt-project.org/listinfo/interest

Jerome Godbout
Software/Firmare Lead Amotus

C: (581) 777-0050
O: (418) 800-1073 ext.: 114
godbo...@amotus.ca<mailto:godbo...@amotus.ca>

[cid:image007.png@01D70B66.39FB01C0]

dimonoff.com<http://dimonoff.com>   |amotus.ca<http://amotus.ca>

We have moved!
1015 Avenue Wilfrid-Pelletier, Québec, QC G1W 0C4, 4e étage

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] QSqlQuery bind value

2021-03-16 Thread Jérôme Godbout
Hi,

I’m trying to use the Sql with Sqlite with Qt. The database seem to be working 
just fine, but I run into troubles with the bind value. The named bind doesn’t 
seem to work (Qt 5.15.2, Mac OS):


m_sql->m_create_table(m_database);

m_sql->m_create_table.prepare(R"raw(CREATE TABLE IF NOT EXISTS :table name 
(idkey TEXT PRIMARY KEY, data TEXT) WITHOUT ROWID)raw”);


Note: I did try to add the ending ; it make no difference. Is it required? I do 
not see it in any example.

The prepare return false for some reason, I did try with quotes this solve the 
prepare but I thing the escaping should be done automatically?! Is the value 
escape character automatically for named and positional args? What is wrong 
with this query, the query work just fine into sqlite3.

CREATE TABLE IF NOT EXISTS ':tablename’ (idkey TEXT PRIMARY KEY, data TEXT) 
WITHOUT ROWID;


It doesn’t complain, but create a table name :table name instead! The replace 
doesn’t occur into the quote ‘ '


This query work just fine into sqlite command line.

CREATE TABLE IF NOT EXISTS toto (idkey TEXT PRIMARY KEY, data TEXT) WITHOUT 
ROWID;


What is wrong with this?! This seem to be just like the examples, is SQLite any 
special in that regards (I known only a single statement is required for 
sqlite).

Thanks,

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qt nosql embedded file db

2021-03-16 Thread Jérôme Godbout
Hi,

Is anybody aware of some nosql file db that play well with Qt on Windows / 
MacOS / iOS / Android / Linux that doesn’t cost an arm and a leg. I have seen 
the following so far:

  *   Unqlite open source until you want to encrypt the database with cost 
10K$US
  *   EJDB2 seem to require to change some naming, since some name clash into C 
files.

There is many that goes native, but not so much that I can see expose C or C++ 
API directly. I would like to have BSON or JSON data support but this is not 
mandatory. If anybody have a success story or any info, that would be great.

Jerome Godbout
Software/Firmare Lead Amotus

C: (581) 777-0050
O: (418) 800-1073 ext.: 114
godbo...@amotus.ca
[cid:image007.png@01D70B66.39FB01C0]

dimonoff.com   |amotus.ca

We have moved!
1015 Avenue Wilfrid-Pelletier, Québec, QC G1W 0C4, 4e étage

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML MouseArea containsMouse is set to true even if it's not actually

2021-02-15 Thread Jérôme Godbout
Hi,
Check if you can tweak the following property on your mouse area. 
https://doc.qt.io/qt-5/qml-qtquick-mousearea.html#preventStealing-prop

· 
preventStealing<https://doc.qt.io/qt-5/qml-qtquick-mousearea.html#preventStealing-prop>
 : bool

· 
propagateComposedEvents<https://doc.qt.io/qt-5/qml-qtquick-mousearea.html#propagateComposedEvents-prop>
You could also handle the mouse event of the mouse area and put the accepted to 
false to avoid eating the event: 
https://doc.qt.io/qt-5/qml-qtquick-mouseevent.html#accepted-prop

Hope that help you find the proper behaviour are after.

Jérôme Godbout
Software / Firmware Lead

C: (581) 777-0050
O: (418) 800-1073 ext.: 109
godbo...@amotus.ca<mailto:godbo...@amotus.ca>
[cid:image001.png@01D70397.D06C4320]
dimonoff.com<https://www.dimonoff.com/>   |
amotus.ca<https://www.amotus-solutions.com/>

From: Interest  On Behalf Of Alexander Dyagilev
Sent: February 15, 2021 12:14 PM
To: interest@qt-project.org
Subject: [Interest] QML MouseArea containsMouse is set to true even if it's not 
actually


Hello,

In our code we have one MouseArea which fills entire parent:
MouseArea {

id: mouseAreaRow

hoverEnabled: true

anchors.fill: parent

propagateComposedEvents: true

onPressed: { mouse.accepted = false }

}

And we have another MouseArea which fills a small part of the same area which 
the first MouseArea fills:

MouseArea {

id: mouseAreaUp

hoverEnabled: true

anchors.fill: parent

cursorShape: Qt.PointingHandCursor

}

The problem is that sometimes mouseAreaUp.containsMouse continues to be set to 
true even after the mouse left its area. Most of the time it happens when the 
mouse pointer is moved very fast.

Is this a known issue or maybe some misunderstanding on our side?

Is there any workaround? Is it possible to at least force MouseArea to recheck 
if it really contains the mouse pointer?
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] How to read screen information from QGuiApplication to put in qputenv environment variable?

2021-02-15 Thread Jérôme Godbout
Since you seem to be using Qml, you can take a look at 
https://doc.qt.io/qt-5/qml-qtquick-window-screen.html that could help you and 
have most of the job done, you could do your own qml singleton if you need to 
compute scale base on those value. You could access those property fom C++ and 
export you env vairbale if you really need to, but I would stick to View = Qml, 
keep thing in Qml as much as possible, so your view stay into the view layer.

Jérôme Godbout
Software / Firmware Lead

C: (581) 777-0050
O: (418) 800-1073 ext.: 109
godbo...@amotus.ca<mailto:godbo...@amotus.ca>
[cid:image001.png@01D70378.7E27B7D0]
dimonoff.com<https://www.dimonoff.com/>   |
amotus.ca<https://www.amotus-solutions.com/>

From: Interest  On Behalf Of Anisha kaul
Sent: February 15, 2021 6:51 AM
To: interest@qt-project.org
Subject: [Interest] How to read screen information from QGuiApplication to put 
in qputenv environment variable?


Greetings,

The problem is that qputenv does not work if written after the initialization 
of QGuiApplication.

I want to calculate scale according to the information from QGuiApplication.

How do I do it? The following code throws a segmentation fault.

.

.

#include 

#include 

#include 

#include 

int main(int argc, char *argv[])

{

qreal abc = QGuiApplication::primaryScreen()->physicalDotsPerInch();



qDebug() << "null " << abc;



qputenv("QT_SCALE_FACTOR", "2");



QGuiApplication app(argc, argv);



QQmlApplicationEngine engine;

const QUrl url(QStringLiteral("qrc:/main.qml"));

QObject::connect(, ::objectCreated,

 , [url](QObject *obj, const QUrl ) {

if (!obj && url == objUrl)

QCoreApplication::exit(-1);

}, Qt::QueuedConnection);

engine.load(url);



return app.exec();

}
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Bluetooth LE: Start Encryption (opcode 0x2019)

2021-02-15 Thread Jérôme Godbout
Maybe you already knew that but just to make sure you pass the right flags on 
both end, both need to support encryption and they need to support the same 
encryption type.

[cid:image001.png@01D70377.BAAD9A90]
Which mode/level are you using? Which version of Bluetooth are you using on 
both end? The security is an optional phase into Bleutooth your peripheral and 
central must agree and handle the request on both end, else you will fallback 
on just work unencrypted connection (Phase 1 in image below), (phase 2 depend 
on Io capability):
[cid:image004.png@01D70378.00A410B0]



Jérôme Godbout
Software / Firmware Lead

C: (581) 777-0050
O: (418) 800-1073 ext.: 109
godbo...@amotus.ca<mailto:godbo...@amotus.ca>
[cid:image005.png@01D70378.00A410B0]
dimonoff.com<https://www.dimonoff.com/>   |
amotus.ca<https://www.amotus-solutions.com/>

From: Interest  On Behalf Of cagnulein
Sent: February 15, 2021 4:33 AM
To: Simon FEUTRIER 
Cc: Qt Interest 
Subject: Re: [Interest] Bluetooth LE: Start Encryption (opcode 0x2019)

Hi Simon, my peripheral is a Inspire I1.5 bike so yes, the encryption has been 
activated from the peripheral (i saw it in the hci snoof log collected using 
its own proprietary app on Android).
i guess i will wait the iOS tests, and if it will work, i will rewrite from 
scratch the bluetooth code on android (i mean, with Java not c++) to check if 
there is something wrong in the Qt layer.

Roberto Viola
Software engineer and open source enthusiast
http://robertoviola.cloud



Il giorno lun 15 feb 2021 alle ore 10:29 Simon FEUTRIER 
mailto:sfeutr...@bluegriot.com>> ha scritto:
Hi,

I'm working on Windows so it could be different (who knows) ?
Did you activate your peripheral encryption? What is your peripheral by the way 
?
In the issue, there is a link for the mailing exchange and there are some 
things about android : 
https://lists.qt-project.org/pipermail/interest/2020-August/035699.html
Also, it has been confirmed that it should be managed internally and that's why 
we don't have any command to control the encryption behaviour. Thus, we cannot 
really do a lot of things except going further in the source code or trying to 
change command order or / and timing.
Cordialement,

Simon Feutrier - Ingénieur systèmes embarqués

BLUEGRioT


Le lun. 15 févr. 2021 à 10:06, cagnulein 
mailto:cagnul...@gmail.com>> a écrit :
Hi, thanks for answering my question. The role of my app is Central and yes i 
already saw your bug reports and i think we're facing the same problem :(
I'm on android btw, and i will test the same source code on iOS and will tell 
you it will work or not.
If you have some ideas, we should talk ;)

Roberto Viola
Software engineer and open source enthusiast
http://robertoviola.cloud



Il giorno lun 15 feb 2021 alle ore 09:34 Simon FEUTRIER 
mailto:sfeutr...@bluegriot.com>> ha scritto:
Hello,

What is the role of your qt app ? Central or Peripheral ?

If it is your Central you cannot start encryption (you need to set encryption 
from the device side). If you enable your encryption from the peripheral side 
and it still does not work, look there : 
https://bugreports.qt.io/browse/QTBUG-86095

If it is your Peripheral, I cannot help you. I did not find any direct commands 
to enable or disable encryption (for both sides in fact). Neither at service / 
characteristic side nor at higher level.

Best regards,

Simon


Le lun. 8 févr. 2021 à 09:58, cagnulein 
mailto:cagnul...@gmail.com>> a écrit :
Hi, on my application I need to use the opcode 0x2019 to start an encryption 
BTLE communication. How can I do in QT?
This screenshot reports how the Bluetooth trace should be.
Thanks
R.

___
Interest mailing list
Interest@qt-project.org<mailto:Interest@qt-project.org>
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] C++ abstract class expose to Qml and property

2021-02-12 Thread Jérôme Godbout
I made a test with Q_GADGET but ended into the same problem:

class SerializationInterface
{
  Q_GADGET
public:
   virtual bool serialize(QDataStream& stream) = 0;
   virtual bool deserialize(QDataStream& stream) = 0;
};
Q_DECLARE_METATYPE(SerializationInterface*)

class OtherObject : public QObject, public Serializationinterface
{
   Q_OBJECT
public:
   bool serialize(QDataStream& stream) override;
   bool deserialize(QDataStream& stream) override;
};
Q_DECLARE_METATYPE(OtherObject*)

main.cpp
qmlRegisterUncreatableType(...);

But I'm still getting this when assigning from Qml to 
Q_PROPERTY(SerializationInterface* obj READ obj WRITE set_obj NOTIFY 
objChanged):
Error: Cannot assign QObject* to SerializationInterface*
hummm, maybe something is missing...


From: Interest  On Behalf Of Jérôme Godbout
Sent: February 12, 2021 12:46 PM
To: interest@qt-project.org
Subject: [Interest] C++ abstract class expose to Qml and property

Hi,

I'm having trouble figuring out what is the best way to do the following:

  1.  I have an C++ abstract class that doesn't inherite QObject with abstract 
method (class SerializationInterface)
  2.  I want to expose that class to Qml and be able to have 
SerializationInterface* Q_PROPERTY into some other class.
  3.  The class that implement the SerializationInterface already inherit 
QObject.

class SerializationInterface
{
public:
virtual bool serialize(QDataStream& stream) = 0;
virtual bool deserialize(QDataStream& stream) = 0;
};

class OtherObject : public QObject, public Serializationinterface // Here the 
QObject is a more complexe QObject inherited class, just to simplify writing 
for example
{
Q_OBJECT
public:
bool serialize(QDataStream& stream) override;
bool deserialize(QDataStream& stream) override;
};

class ControllerA : public QObject
{
Q_OBJECT
Q_PROPERTY(SerializationInterface* obj READ )
};

Is this possible? I have test the following so far:

  1.  Q_DECLARE_METATYPE(SerializationInterface*) seem to be impossible since 
it's not a Q_Object
  2.  Make the a Q_DECLARE_INTERFACE(SerializationInterface, 
"com.mymodulename") but I cannot use that as Property with only that.
  3.  Adding QML_INTERFACE to SerializationInterface doesn't seem to allow 
assigning a QObject* that implement the  SerializationInterface to the 
SerializationInterface* property.
  4.  I cannot call qmlRegisterInterface(...)
  5.  I did try to add Q_DECLARE_METATYPE(SerializationInterface*) after the 
Q_DECLARE_INTERFACE() now it seem to work either

gaving me this so far but it doesn't work, when try to set in Qml 
"controllerA.obj = otherObjectInstance" I always end up with : "Error: Cannot 
assign QObject* to SerializationInterface*"

class SerializationInterface
{
   QML_INTERFACE
public:
virtual bool serialize(QDataStream& stream) = 0;
virtual bool deserialize(QDataStream& stream) = 0;
};
Q_DECLARE_INTERFACE(SerializationInterface, "com.mymodulename")
Q_DECLARE_METATYPE(SerializationInterface*)

class OtherObject : public QObject, public Serializationinterface // Here the 
QObject is a more complexe QObject inherited class, just to simplify writing 
for example
{
Q_OBJECT
  Q_INTERFACES(SerializationInterface)
public:
bool serialize(QDataStream& stream) override;
bool deserialize(QDataStream& stream) override;
};


How does accomplish this properly? Is it even possible? How do you solved it?
Thanks, regards,


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] C++ abstract class expose to Qml and property

2021-02-12 Thread Jérôme Godbout
Hi,

I'm having trouble figuring out what is the best way to do the following:

  1.  I have an C++ abstract class that doesn't inherite QObject with abstract 
method (class SerializationInterface)
  2.  I want to expose that class to Qml and be able to have 
SerializationInterface* Q_PROPERTY into some other class.
  3.  The class that implement the SerializationInterface already inherit 
QObject.

class SerializationInterface
{
public:
virtual bool serialize(QDataStream& stream) = 0;
virtual bool deserialize(QDataStream& stream) = 0;
};

class OtherObject : public QObject, public Serializationinterface // Here the 
QObject is a more complexe QObject inherited class, just to simplify writing 
for example
{
Q_OBJECT
public:
bool serialize(QDataStream& stream) override;
bool deserialize(QDataStream& stream) override;
};

class ControllerA : public QObject
{
Q_OBJECT
Q_PROPERTY(SerializationInterface* obj READ )
};

Is this possible? I have test the following so far:

  1.  Q_DECLARE_METATYPE(SerializationInterface*) seem to be impossible since 
it's not a Q_Object
  2.  Make the a Q_DECLARE_INTERFACE(SerializationInterface, 
"com.mymodulename") but I cannot use that as Property with only that.
  3.  Adding QML_INTERFACE to SerializationInterface doesn't seem to allow 
assigning a QObject* that implement the  SerializationInterface to the 
SerializationInterface* property.
  4.  I cannot call qmlRegisterInterface(...)
  5.  I did try to add Q_DECLARE_METATYPE(SerializationInterface*) after the 
Q_DECLARE_INTERFACE() now it seem to work either

gaving me this so far but it doesn't work, when try to set in Qml 
"controllerA.obj = otherObjectInstance" I always end up with : "Error: Cannot 
assign QObject* to SerializationInterface*"

class SerializationInterface
{
   QML_INTERFACE
public:
virtual bool serialize(QDataStream& stream) = 0;
virtual bool deserialize(QDataStream& stream) = 0;
};
Q_DECLARE_INTERFACE(SerializationInterface, "com.mymodulename")
Q_DECLARE_METATYPE(SerializationInterface*)

class OtherObject : public QObject, public Serializationinterface // Here the 
QObject is a more complexe QObject inherited class, just to simplify writing 
for example
{
Q_OBJECT
  Q_INTERFACES(SerializationInterface)
public:
bool serialize(QDataStream& stream) override;
bool deserialize(QDataStream& stream) override;
};


How does accomplish this properly? Is it even possible? How do you solved it?
Thanks, regards,

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QPA display system query ?

2021-01-19 Thread Jérôme Godbout
For linux qt deploy there is a standalone python version that I use that work 
well: https://github.com/Larpon/linuxdeployqt.py
For my application it was working more easily and was better with Qml.

From: Interest  On Behalf Of Nicholas Yue
Sent: January 18, 2021 11:13 PM
To: Thiago Macieira 
Cc: interest@qt-project.org
Subject: Re: [Interest] QPA display system query ?

Thanks Thiago.

On Windows and Mac, there are corresponding windeployqt and macdeployqt

On *nixes, there is linuxdeployqt but that didn't work for me as it requires 
very specific glibc, the author of linxudeployqt have their legitimate reason 
for being very specific about runtime for their tool to work.

So I have to mimic the deployment as best as I can with regards to the QPA for 
display as that done in windowsdeployqt and macdeployqt so I have something 
like the following

install(FILES
  ${QT_INSTALL_PLUGINS}/platforms/libqxcb.so
  DESTINATION
  bin/platforms
  )

I was hoping to factor out the hard coding of xcb in the above which I can 
query.

So yes, it is like an XY problem.

Happy to hear of proper CMake way to install the required QPA for a software to 
be package up and ship to user without shipping the entire Qt 6.0.0 build on 
the Linux platform.

Cheers

On Mon, 18 Jan 2021 at 19:12, Thiago Macieira 
mailto:thiago.macie...@intel.com>> wrote:
On Monday, 18 January 2021 16:15:23 PST Giuseppe D'Angelo via Interest wrote:
> Hi,
>
> Il 19/01/21 00:33, Nicholas Yue ha scritto:
> > Is there some command line query I can make to determine the QPA display
> > system that is being used? For example, running that command on e.g. an
> > Ubuntu box may return something like *xcb*
>
> In general, qtdiag will tell you. However, this decision may be
> different for each application, and it's not uncommon to find
> applications that override the system default.

Actually, it should be VERY uncommon. There are few applications that need a
specific windowing system, though I don't doubt there are several that work
poorly with anything that they weren't tested with.


--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel DPG Cloud Engineering



___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


--
Nicholas Yue
Graphics - Arnold, Alembic, RenderMan, OpenGL, HDF5
Custom Dev - C++ porting, OSX, Linux, Windows
http://au.linkedin.com/in/nicholasyue
https://vimeo.com/channels/naiadtools
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] CurrentProject:QT_INSTALL_BINS missing

2021-01-13 Thread Jérôme Godbout
Because for the mobile application I have to use the desktop tool version of it 
and the binary (.ts, .qm) are working juste fine after. If I generate them from 
OSX or Windows the generated binary are exactly the same, so the platform 
doesn't seem to have any impact on the binary generated. The only thing I see 
is the version that could modify the generated binary, but even there I don't 
regen them at each Qt Version and it still work.

-Original Message-
From: Interest  On Behalf Of Christian Kandeler
Sent: January 13, 2021 2:26 AM
To: interest@qt-project.org
Subject: Re: [Interest] CurrentProject:QT_INSTALL_BINS missing

On 1/12/21 9:12 PM, Jérôme Godbout wrote:
> I wonder if that lupdate and lrelease should be part of Qt tools 
> instead of each desktop version, mobile lack it

What makes you think that? They are host tools just like qmake, and reside 
alongside it, regardless of the target architecture.


Christian




___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] CurrentProject:QT_INSTALL_BINS missing

2021-01-12 Thread Jérôme Godbout
Thganks it does work, I never realized that icon was giving variables, good to 
known. I wonder if that lupdate and lrelease should be part of Qt tools instead 
of each desktop version, mobile lack it, so all my mobile project I have to 
configure a desktop config just to run the lupdate and lrelease and toggle 
between project config. It's a bit ackward to use.

Thanks, this did it.

-Original Message-
From: Kai Köhne  
Sent: January 12, 2021 10:42 AM
To: Jérôme Godbout ; interest@qt-project.org
Subject: RE: CurrentProject:QT_INSTALL_BINS missing

> From: Interest  On Behalf Of Jérôme 
> Godbout
> Sent: Tuesday, January 12, 2021 3:48 PM
> To: interest@qt-project.org
> Subject: [Interest] CurrentProject:QT_INSTALL_BINS missing
> 
> HI,
> I was using some project setting .pri to run the lupdate based on 
> current Project Qt install bin using the following for my external tools 
> lupdate:
> %{CurrentProject:QT_INSTALL_BINS}\lupdate.exe
>
> But now into recent QtCreator, it give me the following error:
> 
> Could not find executable for 
> "%{CurrentProject:QT_INSTALL_BINS}/lupdate.exe" (expanded "%
> {CurrentProject:QT_INSTALL_BINS}/lupdate.exe")
> Could not find executable for "lupdate" (expanded "lupdate")
> 
> Is there a new way to do this? (better that does work with Android and iOS 
> config too?). I'm using the 4.14.0 QtCreator and Qt 5.15.2.

Per commit b55825a42000ee81e37c8e25bcd0784d26d6dc18 most "CurrentProject:" 
variables got removed/deprecated. 

Use "ActiveProject:QT_INSTALL_BINS" instead.

(Qt Creator btw shows you the available arguments also directly in the UI, 
click the 'A_B' icon right in the input field)

Regards

Kai
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] CurrentProject:QT_INSTALL_BINS missing

2021-01-12 Thread Jérôme Godbout
HI,
I was using some project setting .pri to run the lupdate based on current 
Project Qt install bin using the following for my external tools lupdate:
%{CurrentProject:QT_INSTALL_BINS}\lupdate.exe

But now into recent QtCreator, it give me the following error:

Could not find executable for "%{CurrentProject:QT_INSTALL_BINS}/lupdate.exe" 
(expanded "%{CurrentProject:QT_INSTALL_BINS}/lupdate.exe")
Could not find executable for "lupdate" (expanded "lupdate")

Is there a new way to do this? (better that does work with Android and iOS 
config too?). I'm using the 4.14.0 QtCreator and Qt 5.15.2.

Thanks,
Jerome

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 5.15 pull out of open source?!

2021-01-07 Thread Jérôme Godbout
e are only for 
commercial license holders, but all releases done until that point continue to 
be available for all users.

Yours,

Tuukka



From: Interest 
mailto:interest-boun...@qt-project.org>>
Date: Thursday, 7. January 2021 at 10.45
To: interest@qt-project.org<mailto:interest@qt-project.org> 
mailto:interest@qt-project.org>>
Subject: Re: [Interest] Qt 5.15 pull out of open source?!
Hi,

Il 07/01/21 04:03, Jérôme Godbout ha scritto:
> Hi,
> is this any true?
> https://www.phoronix.com/scan.php?page=news_item=Qt-5.15-LTS-Commercial-Phase

Please see the thread on development@ (no idea why the original message
was not posted on interest@ as well.).

> https://lists.qt-project.org/pipermail/development/2021-January/040798.html


HTH,

--
Giuseppe D'Angelo | giuseppe.dang...@kdab.com<mailto:giuseppe.dang...@kdab.com> 
| Senior Software Engineer
KDAB (France) S.A.S., a KDAB Group company
Tel. France +33 (0)4 90 84 08 53, http://www.kdab.com
KDAB - The Qt, C++ and OpenGL Experts
___ Interest mailing list 
Interest@qt-project.org<mailto:Interest@qt-project.org> 
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org<mailto:Interest@qt-project.org>
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 5.15 pull out of open source?!

2021-01-07 Thread Jérôme Godbout
From what I understand, opens source are only latest version, so > 5.15.2 will 
be only for commercial since 6.0 is out. So they only support open source for 
the latest release. But the trouble here is that 6.0 is not fully completed 
yet, which make it kind of trouble some.

So for what I understand. 6.2.x where is x will be open source until 6.3.0 is 
out, after that no more.

That would make sense in case 6.0 a complete replacement of 5.0, which is not 
yet.

From: Interest  On Behalf Of Michael Jackson
Sent: January 7, 2021 10:01 AM
To: Tuukka Turunen ; interest@qt-project.org
Subject: Re: [Interest] Qt 5.15 pull out of open source?!

Dear Tuukka,
As an open source developer who has used Qt since 2009, I am still a bit 
confused as to what versions of Qt6 that my open-source project should be using 
over time? For example, we might be lucky enough to port to the 6.0 release, 
and then to 6.1. If 6.2 is LTS and commercial only, what is the next Qt 6 
version that an open-source project would jump to? Would that be 6.3? Is TQtC 
going to do something like the “odd (6.1, 6.3…)” releases are opensource but 
the “even (62, 6.4…)” releases are commercial only? Is there a longer term 
roadmap available that explains TQtC vision on how this will work?

--
Michael Jackson | Owner, President
  BlueQuartz Software
[e] mike.jack...@bluequartz.net<mailto:mike.jack...@bluequartz.net>
[w] www.bluequartz.net<http://www.bluequartz.net>


From: Interest 
mailto:interest-boun...@qt-project.org>> on 
behalf of Tuukka Turunen mailto:tuukka.turu...@qt.io>>
Date: Thursday, January 7, 2021 at 4:38 AM
To: Giuseppe D'Angelo 
mailto:giuseppe.dang...@kdab.com>>, 
"interest@qt-project.org<mailto:interest@qt-project.org>" 
mailto:interest@qt-project.org>>
Subject: Re: [Interest] Qt 5.15 pull out of open source?!

Hi,

Apologies for not sending the mail also to the interest mailing list. This is 
nothing new, as this was announced in already February 2020. Otherwise Qt 
continues to be available for open-source users, but the long-term support 
releases of Qt will be available only for the commercial license holders. First 
commercial-only patch release being Qt 5.15.3 planned to be released in 
February 2021.

Qt 5.15.2 continues to be available for all users, so situation is similar as 
with Qt 5.13 and Qt 5.14, for example (no new patch releases). Qt 6.0.0 and 
subsequent patch releases, as well as upcoming Qt 6.1 and Qt 6.2 etc releases 
are also available for open-source users. Eventually we will enter 
long-term-support phase with Qt 6.2 LTS at which point again these are only for 
commercial license holders, but all releases done until that point continue to 
be available for all users.

Yours,

Tuukka



From: Interest 
mailto:interest-boun...@qt-project.org>>
Date: Thursday, 7. January 2021 at 10.45
To: interest@qt-project.org<mailto:interest@qt-project.org> 
mailto:interest@qt-project.org>>
Subject: Re: [Interest] Qt 5.15 pull out of open source?!
Hi,

Il 07/01/21 04:03, Jérôme Godbout ha scritto:
> Hi,
> is this any true?
> https://www.phoronix.com/scan.php?page=news_item=Qt-5.15-LTS-Commercial-Phase

Please see the thread on development@ (no idea why the original message
was not posted on interest@ as well.).

> https://lists.qt-project.org/pipermail/development/2021-January/040798.html


HTH,

--
Giuseppe D'Angelo | giuseppe.dang...@kdab.com<mailto:giuseppe.dang...@kdab.com> 
| Senior Software Engineer
KDAB (France) S.A.S., a KDAB Group company
Tel. France +33 (0)4 90 84 08 53, http://www.kdab.com
KDAB - The Qt, C++ and OpenGL Experts
___ Interest mailing list 
Interest@qt-project.org<mailto:Interest@qt-project.org> 
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 5.15 pull out of open source?!

2021-01-07 Thread Jérôme Godbout
Hi,
That leave a sour taste since 6.0 is far to be ready for mainstream, don't get 
me wrong it is a great rework and show many potential. But I cannot even port a 
single project to it so far (none of the project I work on have all the 
necessary module, IoT application without oauth or bluetooth and the like is 
plain impossible), it leave 5.15.2 to be the only solution until 6.2 get out, 
no more fixes or anything. That start to look pretty bad on my end.  Last few 
project have been shift to Xamarin/Blazor with C# because of recent license fog 
and that open source lock down. I feel sad, but no project owner want to take 
the risk with Qt or his high price compare to competition. 

I always loved Qt and even more with Qml. I end up doing less and less of it. 
It was a good ride with Qt, sadly, I'm not sure any more project as consultant 
will show up with Qt... I barely had 1 in the past year and a big rise on C# 
Xamarin and blazor are rising quickly, not that I like it, but that's the 
market aorund me in Montreal/Quebec start to look like lately. I also do work 
for a huge European cie that shifted to C# too. Only medical cie are sticking 
to it around me, since the cost of revalidation is too high. Might not be the 
case for everyone, but as a service cie that what we are seeing right now and 
that's sad.

Jerome
☹

-Original Message-
From: Interest  On Behalf Of Thiago Macieira
Sent: January 7, 2021 6:39 AM
To: interest@qt-project.org
Subject: Re: [Interest] Qt 5.15 pull out of open source?!

On Thursday, 7 January 2021 07:26:33 -03 Richard Weickelt wrote:
> It was ONLY communicated that releases will no longer be available. It 
> was NOT communicated that the LTS branches will be closed for new 
> commits and further patches land in a different repository.

It was. Maybe not in that same very blog post, but it was.

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel DPG Cloud Engineering



___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qt 5.15 pull out of open source?!

2021-01-06 Thread Jérôme Godbout
Hi,
is this any true?
https://www.phoronix.com/scan.php?page=news_item=Qt-5.15-LTS-Commercial-Phase

Does Qt really thing 6.0 can fill the bills of open source for all apps? so 
many modules are missing from 6.0?! all Bluetooth app using open source will do 
what exactly?!?

I surely hope this is a bad comprehension of the actual reality.

Damn, if so, I think many project should move away from Qt.

Such a nice framework, such a bad licensing and commercial behaviour...

I feel sad right now.
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QImage family of classes - image bucket

2020-12-17 Thread Jérôme Godbout
Hi,
just a though, maybe you should do a rendering into a framebuffer of each layer 
with a different z. That would make the rendering very easy and super fast on 
GPU.

After you could put the result into a QImage or QPixmap.


From: Interest  On Behalf Of Nicholas Yue
Sent: December 16, 2020 8:46 PM
To: interest@qt-project.org
Subject: [Interest] QImage family of classes - image bucket

Hi,

  I am writing an application that is receiving images in rectangular buckets.

  These buckets may be destined for different layers of images.

  I plan to create a list for the layers so that I can show selected and 
individual ones of interest.

  Which QImage class is easier to work with where I can write those rectangular 
buckets of pixels individually ?

Cheers
--
Nicholas Yue
Graphics - Arnold, Alembic, RenderMan, OpenGL, HDF5
Custom Dev - C++ porting, OSX, Linux, Windows
http://au.linkedin.com/in/nicholasyue
https://vimeo.com/channels/naiadtools
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] shell_path, QMAKE_COPY, etc. are broken when building for Android under Windows

2020-12-16 Thread Jérôme Godbout
Maybe a fallback check could be done first, Cygwin add env variables: OSTYPE 
which can be check to see if this is Cygwin. Or maybe uname detection to 
confirm. Could be more robust then path executable. With Windows Linux 
subsystem taking traction versus Cygwin, this check can become even more 
unreliable.


From: Interest  On Behalf Of Kai Köhne
Sent: December 16, 2020 4:07 AM
To: Alexander Dyagilev ; interest 
Subject: Re: [Interest] shell_path, QMAKE_COPY, etc. are broken when building 
for Android under Windows

Hi,

Do you have a sh.exe in PATH? If so , qmake assumes you’re running in a Cygwin 
shell.

Regards

Kai

From: Interest 
mailto:interest-boun...@qt-project.org>> On 
Behalf Of Alexander Dyagilev
Sent: Wednesday, December 16, 2020 9:20 AM
To: interest mailto:Interest@qt-project.org>>
Subject: [Interest] shell_path, QMAKE_COPY, etc. are broken when building for 
Android under Windows


Hello,

Is it known bug? Is there workaround?

What I mean:

The following in .pro file:

message(QMAKE_COPY = $$QMAKE_COPY)
message(shell path for PWD is: $$shell_path($$PWD))

Generates the following outputs (under Windows OS):

When building for Windows (there is no bug):
Project MESSAGE: QMAKE_COPY = copy /y
Project MESSAGE: shell path for PWD is: C:\Work\Source\fdm-qml\ui

When building for Android (there is bug, things gets unusable):
Project MESSAGE: QMAKE_COPY = cp -f
Project MESSAGE: shell path for PWD is: /C/Work/Source/fdm-qml/ui

Windows does not understand cp command and the path obviously wrong too.




___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 6.0.0 released

2020-12-09 Thread Jérôme Godbout
The Qt 6 minimum requirements:
* Windows 10
* macOS 10.14 and newer
* Linux (Ubuntu 20.04, CentOS 8.1, OpenSuSE 15.1)
* iOS 13 or newer
* Android (API level 23 or newer)

-Original Message-
From: Interest  On Behalf Of Jani Heikkinen
Sent: December 9, 2020 12:59 AM
To: Quang Phú Bùi ; Florian Bruhin 

Cc: interestqt-project.org 
Subject: Re: [Interest] Qt 6.0.0 released

Hi!

Ubuntu 18.04 isn't supported development host for Qt 6.0, see 
https://bugreports.qt.io/browse/QTBUG-85851
So please update to 20.04 and you are able to install and use Qt 6.0.0

br,
Jani


From: Interest  on behalf of Quang Phú Bùi 

Sent: Wednesday, December 9, 2020 4:58 AM
To: Florian Bruhin
Cc: interestqt-project.org
Subject: Re: [Interest] Qt 6.0.0 released

While installing Qt6 from online installer but have this error.
[Screenshot from 2020-12-09 09-43-28.png] It just happens on Qt 6, Qt5 and 
below worked fine. Does anyone have solution My system: Ubuntu 18.04.
Thanks.

On Wed, 9 Dec 2020 at 04:34, Florian Bruhin 
mailto:m...@the-compiler.org>> wrote:
On Tue, Dec 08, 2020 at 03:19:51PM +, Nuno Santos wrote:
> How can install this. It does not show up in Maintenance Tool.

Shows up just fine for me FWIW.

Florian

--
m...@the-compiler.org (Mail/XMPP) | 
https://www.qutebrowser.org
   https://bruhin.software/ | https://github.com/sponsors/The-Compiler/
   GPG: 916E B0C8 FD55 A072 | https://the-compiler.org/pubkey.asc
 I love long mails! | https://email.is-not-s.ms/ 
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] how to get and purge events from queue?

2020-11-05 Thread Jérôme Godbout
Maybe you can add an event filter and remove some of the events if they are 
happening too close to each others. But I thing doing that logic into the event 
handler is a betetr idea, where you can either cumulate and delay execution of 
the behavior.

-Original Message-
From: Interest  On Behalf Of Giuseppe D'Angelo 
via Interest
Sent: November 5, 2020 5:06 AM
To: interest@qt-project.org
Subject: Re: [Interest] how to get and purge events from queue?

Il 05/11/20 05:38, David M. Cotter ha scritto:
> when scrolling, the scroll for my app is a bit sluggish (do not ask 
> about that) which means that mouse wheel scroll events can pile up in the 
> queue while the first scroll event is being processed.
> meaning that a dozen more*slow*  events get handled after the user stops 
> scrolling.
> 
> what i want to do is: when i get a wheel scroll event, at that moment i see 
> if there are MORE scroll events in the queue. if not, i just handle this 
> event. but if there ARE i want to get the most recent one, and handle only 
> that ONE event, while purging the rest.

There is some sort of input event compression available through application 
flags. For the rest, you could just not act on events that happen too close 
together (either wait a bit before acting, so to get N events, or act on the 
first one and ignore the subsequent ones in a short time frame).

But there's just no public access to the pending event queue.

HTH,

--
Giuseppe D'Angelo | giuseppe.dang...@kdab.com | Senior Software Engineer KDAB 
(France) S.A.S., a KDAB Group company Tel. France +33 (0)4 90 84 08 53, 
http://www.kdab.com KDAB - The Qt, C++ and OpenGL Experts

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt 5.15.1 and XCode 12.1

2020-10-24 Thread Jérôme Godbout
Just found a solution (probably not the best one, but got me to load the 
project at least):
I simply made a symlink

cd 
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/

sudo ln -s iPhoneOS.sdk iPhoneOS14.0.sdk


I did try those without success:
https://codereview.qt-project.org/c/qt/qtbase/+/314636/3/mkspecs/features/toolchain.prf#185
And the Andy Shaw patch over here:
https://bugreports.qt.io/browse/QTBUG-86718




From: Interest  on behalf of Jérôme Godbout 

Sent: Thursday, October 22, 2020 3:17 PM
To: Qt Interest 
Subject: [Interest] Qt 5.15.1 and XCode 12.1

Hi,
I ran into a problem with the following combo:

  *   XCode 12.1
  *   Qt 5.15.1
  *   Qt Creator 4.13.2
  *   Mac OS 10.15.6

While opening project for iOS it fail to find:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.0.sdk

The qmake failed to load the project with this error:
Project ERROR: Cannot run target compiler 
'/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++'.
 Output:
===
Apple clang version 12.0.0 (clang-1200.0.32.21)
Target: x86_64-apple-darwin19.6.0
Thread model: posix
InstalledDir: 
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
clang: warning: no such sysroot directory: 
'/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.0.sdk'
 [-Wmissing-sysroot]
ignoring nonexistent directory 
"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.0.sdk/usr/include/c++/v1"


It doesn't exist, but there is a symlink called
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.1.sdk

That point to:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk

The setting into QtCreator fro 5.15.1 iOS is pointing to actual folder, see 
picture in attachment.


Where does this 14.0 path coming from? I try to reboot, no luck... just in case 
the path was not yet register properly.

Thanks,
Jerome
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qt 5.15.1 and XCode 12.1

2020-10-22 Thread Jérôme Godbout
Hi,
I ran into a problem with the following combo:

  *   XCode 12.1
  *   Qt 5.15.1
  *   Qt Creator 4.13.2
  *   Mac OS 10.15.6

While opening project for iOS it fail to find:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.0.sdk

The qmake failed to load the project with this error:
Project ERROR: Cannot run target compiler 
'/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++'.
 Output:
===
Apple clang version 12.0.0 (clang-1200.0.32.21)
Target: x86_64-apple-darwin19.6.0
Thread model: posix
InstalledDir: 
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
clang: warning: no such sysroot directory: 
'/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.0.sdk'
 [-Wmissing-sysroot]
ignoring nonexistent directory 
"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.0.sdk/usr/include/c++/v1"


It doesn't exist, but there is a symlink called
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.1.sdk

That point to:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk

The setting into QtCreator fro 5.15.1 iOS is pointing to actual folder, see 
picture in attachment.


Where does this 14.0 path coming from? I try to reboot, no luck... just in case 
the path was not yet register properly.

Thanks,
Jerome
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Android manifest min sdk with 5.15.1

2020-10-22 Thread Jérôme Godbout
Thanks, it does the trick, I guess I will have another version of the 
AndroidManifest.xml to maintain to support  5.12-, one for 5.13 & 5.14 and one 
for 5.15+.

It's a nice addition, but it would be nice to have something into QtCreator to 
tell us breaking changes between Qt version especially for Android and iOS 
(those move quickly and it's hard to follow the requirements change to be done 
to the projects in order to make them work).

Thanks, it does work,



From: Interest  on behalf of maitai 

Sent: Wednesday, October 21, 2020 2:30 AM
To: interest@qt-project.org 
Subject: Re: [Interest] Android manifest min sdk with 5.15.1


Hi,

Min SDK and Target SDK are now variables that you should set in the pro file, 
for instance

ANDROID_MIN_SDK_VERSION = 21
ANDROID_TARGET_SDK_VERSION = 29

See here: https://doc.qt.io/qt-5/qmake-variable-reference.html

-- Philippe




Le 20-10-2020 22:58, Jérôme Godbout a écrit :

Hi,



I run into trouble when I try to sign my package application with 5.15.1 
(without signing it build correctly and run just fine):

Caused by: com.android.builder.errors.EvalIssueException: Failed to parse XML 
in 
D:\Code\build\MyApp-Android_Qt_5_15_1_Clang_Multi_Abi-Release\android-build\AndroidManifest.xml
The minSdk version should not be declared in the android manifest file. You can 
move the version from the manifest to the defaultConfig in the build.gradle file



Anybody known why and how we can change this with Qt build?! I can easily 
remove it from the manifest, but the gradle file are auto generated by the Qt 
application no, I never add any to my project at least. Or there is something 
that have changed with the Android setup?



How does one provide the build.gradle file to Qt exactly?



Thanks,

Jerome

___
Interest mailing list
Interest@qt-project.org<mailto:Interest@qt-project.org>
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Android manifest min sdk with 5.15.1

2020-10-20 Thread Jérôme Godbout
Hi,

I run into trouble when I try to sign my package application with 5.15.1 
(without signing it build correctly and run just fine):
Caused by: com.android.builder.errors.EvalIssueException: Failed to parse XML 
in 
D:\Code\build\MyApp-Android_Qt_5_15_1_Clang_Multi_Abi-Release\android-build\AndroidManifest.xml
The minSdk version should not be declared in the android manifest file. You can 
move the version from the manifest to the defaultConfig in the build.gradle file

Anybody known why and how we can change this with Qt build?! I can easily 
remove it from the manifest, but the gradle file are auto generated by the Qt 
application no, I never add any to my project at least. Or there is something 
that have changed with the Android setup?

How does one provide the build.gradle file to Qt exactly?

Thanks,
Jerome
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML/C++ interaction in Qt6

2020-09-15 Thread Jérôme Godbout
You can also phrase your modules as C++-only static libraries and link them all 
together into the application. 
- That will depends on which C++ library your modules depends on. Not all code 
can be legally made static, this restriction, seem rather short sighted. Hope 
they change this.

-Original Message-
From: Ulf Hermann  
Sent: September 15, 2020 2:33 AM
To: Jérôme Godbout ; interestqt-project.org 

Subject: Re: [Interest] QML/C++ interaction in Qt6

On 9/14/20 5:29 PM, Jérôme Godbout wrote:
> Oh,... now that's a deal breaker... I guess I will have to stick with 
> the old method for a while, having 1 plugins per modules to be expose 
> will need some major refactor over here. I have subrepos who have a 
> single .pri and might expose a few modules and some modules are 
> partials between subrepos. I gather my .pri to build for some targets 
> and platforms specific subrepos might add stuff to it.

You can also phrase your modules as C++-only static libraries and link them all 
together into the application. Mind that tools like Qt Creator or qmllint may 
have a hard time figuring this out and might not give you a meaningful analysis 
of your QML code. You will need to manually install your .qmltypes files into 
the import path or merge them together into a single one in the application 
directory. There is no "link" step for .qmltypes files (yet).

> The idea seem good, but the result doesn't scale too well and ain't 
> flexible. Is the old way will still work into Qt 6 then?

You can still manually call qmlRegisterType, but if you want qmllint and a 
future QML-to-C++ compiler to see your C++ types, you shouldn't.

best,
Ulf
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML/C++ interaction in Qt6

2020-09-14 Thread Jérôme Godbout
Oh,... now that's a deal breaker... I guess I will have to stick with the old 
method for a while, having 1 plugins per modules to be expose will need some 
major refactor over here. I have subrepos who have a single .pri and might 
expose a few modules and some modules are partials between subrepos. I gather 
my .pri to build for some targets and platforms specific subrepos might add 
stuff to it. 

The idea seem good, but the result doesn't scale too well and ain't flexible. 
Is the old way will still work into Qt 6 then?

-Original Message-
From: Giuseppe D'Angelo  
Sent: September 14, 2020 11:22 AM
To: Jérôme Godbout 
Subject: Re: [Interest] QML/C++ interaction in Qt6

On 14/09/2020 17:19, Jérôme Godbout wrote:
> Yeah I got that part, the part I do not get is how can you have multiple 
> QML_IMPORT_NAME and multiple files in each? how do you tell into which 
> modules goes which classe? Is it the declaration order into the .pro/.pri?
> 
> I for one, also keep track of every singleton instance instanciate from Qml 
> for C++ type, so my C++ can request the same singleton if ever needed (I18n, 
> Application wide settings, style and themes...). I did make my own template 
> class wher I can register the module more easily, nt havign to retype the 
> module name and version each time. Also have the getter for those singleton 
> instance per Engine*.

As far as I know, you split the project in multiple .pro files (e.g. by 
building a bunch of static libs or QML plugins). Each .pro will have its 
own import.

HTH,

-- 
Giuseppe D'Angelo | giuseppe.dang...@kdab.com | Senior Software Engineer
KDAB (France) S.A.S., a KDAB Group company
Tel. France +33 (0)4 90 84 08 53, http://www.kdab.com
KDAB - The Qt, C++ and OpenGL Experts

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML/C++ interaction in Qt6

2020-09-14 Thread Jérôme Godbout
Hi,

Thanks for the info, I did took a look at the QML_ELEMENT at 
https://www.qt.io/blog/qml-type-registration-in-qt-5.15

I was a bit confuse about how this actually do the the convertion between 
people and person in the following example given:



***

qmlRegisterType("People", 1,0, "Person");



This would register the C++ class "Person" as a QML element also called 
"Person", into the module "People" under the version 1.0. This line has 
disappeared in Qt 5.15. Instead, the following lines have been added to the 
adding.pro file:



CONFIG += qmltypes

QML_IMPORT_NAME = People

QML_IMPORT_MAJOR_VERSION = 1



These lines specify the import name and major version for all types exposed to 
QML. Finally, the most important change, is the "QML_ELEMENT" macro added to 
the person.h file:



class Person : public QObject

{

Q_OBJECT

Q_PROPERTY(QString name READ name WRITE setName)

Q_PROPERTY(int shoeSize READ shoeSize WRITE setShoeSize)

QML_ELEMENT

public:

Person(QObject *parent = nullptr);

[...]

};

***

how does the Person class is link to the People name exactly?!? I do not 
understand how can it known that the C++ class should be link the given People 
import name?! Is like a stack, if I change the QML_IMPORT_NAMES before using 
any HEADERS += or SOURCES += ? like this:



CONFIG += qmltypes

QML_IMPORT_NAME = People

QML_IMPORT_MAJOR_VERSION = 1



HEADERS += Person.h

SOURCES += Person.cpp



QML_IMPORT_NAME = MyOtherModule

QML_IMPORT_MAJOR_VERSION = 1



HEADERS += MyOtherClass.h

SOURCES += MyOtherClass.cpp



Is that how it should work? Is the order of declaration into .pro and .pri 
matter to make this work or there is something I don’t get here? Thanks



-Original Message-----
From: Ulf Hermann 
Sent: September 12, 2020 3:24 AM
To: Jérôme Godbout ; interest@qt-project.org
Subject: Re: [Interest] QML/C++ interaction in Qt6



> Will Qt 6 still use the Meta information to access Qml properties or

> it rely more on compiled C++ now? I guess it still the same as before.

> Is the properties declaration of Qt for MCU (Qml lite or soemthign

> like that) be available (syntax wise, template)? That would leverage

> soo much redundent code to expose properties with get/set and changed

> event. That will be a slim fast for code that expose to Qml (to Meta

> data actually, Qml use the meta data) and maybe event make that layer

> disapear one day.



Registration of C++ types for QML in dev is largely unchanged from 5.15.

You get the QML_ELEMENT etc. macros we introduced in 5.15 to make the 
registration as painless as possible. The indirection through the metatype 
system is necessary for the case of dynamically interpreted QML. We can 
generate C++ code from your QML to directly access your C++ types, but if you 
want to execute that same QML in interpreted mode, those C++ types need to be 
visible to metatype system in order to be accessible.



Also, the new property system is being introduced. If you provide a BINDABLE 
property, you may be able to skip the READ, WRITE, and NOTIFY methods in the 
future. This is still being worked on, though.



best,

Ulf
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QML/C++ interaction in Qt6

2020-09-11 Thread Jérôme Godbout
Will Qt 6 still use the Meta information to access Qml properties or it rely 
more on compiled C++ now? I guess it still the same as before.
Is the properties declaration of Qt for MCU (Qml lite or soemthign like that) 
be available (syntax wise, template)? That would leverage soo much redundent 
code to expose properties with get/set and changed event. That will be a slim 
fast for code that expose to Qml (to Meta data actually, Qml use the meta data) 
and maybe event make that layer disapear one day.

-Original Message-
From: Interest  On Behalf Of Ulf Hermann
Sent: September 11, 2020 6:20 AM
To: interest@qt-project.org
Subject: Re: [Interest] QML/C++ interaction in Qt6

> - Allow QML to access public properties of classes, even if these 
> public properties do not use `Q_PROPERTY`
> - Allow QML access to classes that are neither `QObject`, nor 
> `QGadget`

This is not planned right now. Note that we rely on moc to generate the class 
descriptions that QML uses. Therefore, we need constructs like Q_OBJECT, 
Q_GADGET and Q_PROPERTY to make things visible.

best regards,
Ulf

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] No implementation found for boolean org.qtproject.qt5.android.QtNative.startQtAndroidPlugin

2020-09-11 Thread Jérôme Godbout
There was a discussion about this a while back into Slack QtMob into the 
Android channel:



my android.pri now include the right manifest based on the build version:



   MANIFEST_ANDROID_AMOTUS = AndroidManifest.xml



LIBS_ANDROID_AMOTUS = libs.xml



versionAtLeast(QT_VERSION, 5.13.0) {

AMOTUS_ANDROID_MANIFEST_FOLDER = "android-src/"

AMOTUS_ANDROID_LIBS_FOLDER = "android-src/res/values/"

}



!versionAtLeast(QT_VERSION, 5.13.0) {

AMOTUS_ANDROID_MANIFEST_FOLDER = "android-src/old"

AMOTUS_ANDROID_LIBS_FOLDER = "android-src/res/values/old"

}



QMAKE_EXTRA_TARGETS += $$androidSourceMaker("Amotus_Android_Manifest", 
"/", $$AMOTUS_ROOT, $$AMOTUS_ANDROID_MANIFEST_FOLDER, MANIFEST_ANDROID_AMOTUS)

QMAKE_EXTRA_TARGETS += $$androidSourceMaker("Amotus_Android_Libs", 
"res/values", $$AMOTUS_ROOT, $$AMOTUS_ANDROID_LIBS_FOLDER, LIBS_ANDROID_AMOTUS)



DISTFILES += \

$$AMOTUS_ANDROID_MANIFEST_FOLDER/AndroidManifest.xml \

$$AMOTUS_ANDROID_LIBS_FOLDER/libs.xml \





The androidSourceMaker is based on Luke Vear work: 
https://github.com/lukevear/qmakeAndroidSourcesHelper

This allow to cherry pick part of code and happend it to the android source 
folder, this allow multiple subrepos contributing to the android source folder 
(we can only have one, which is limiting we you keep a lots of sub repos into 
your projects).



Here is my source for it (I did sent it to Luke Vear already, but our needs 
diverge, I should open source fork it, but it is right now into a private 
repos):



# CopyAndroidSources.pri

# MIT License

#

# Copyright (c) 2018 Luke Vear

#

# Permission is hereby granted, free of charge, to any person obtaining a copy

# of this software and associated documentation files (the "Software"), to deal

# in the Software without restriction, including without limitation the rights

# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell

# copies of the Software, and to permit persons to whom the Software is

# furnished to do so, subject to the following conditions:

#

# The above copyright notice and this permission notice shall be included in all

# copies or substantial portions of the Software.

#

# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR

# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,

# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE

# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER

# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,

# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE

# SOFTWARE.

#

#

# Taken from https://github.com/lukevear/qmakeAndroidSourcesHelper

# commit e0e47e0d0f1b70bedcc9e31e9f8b217e027d3a54

#

# Modification is as follow

# 2018-06-01 JG remove the .gitignore section, not needed

# 2018-06-01 JG return with more export

# 2018-06-01 JG Add FORCE depends for created target



defineReplace(copyAndroidSources) {

commandAlias = $$1

targetDirectory = $$2

sourceFiles = $$3



# Ensure we were provided a valid alias for this command

isEmpty(commandAlias) {

error("copyAndroidSources requires a valid command alias as its first 
argument.")

}



# Ensure we were provided a valid target directory

isEmpty(targetDirectory) {

error("copyAndroidSources requires a valid target directory path as its 
second argument.")

}



# Ensure we were provide a valid set of source files

isEmpty(sourceFiles) {

error("copyAndroidSources requires a valid set of files as its third 
argument.")

}



# Make sure the command is run, TODO godboutj 2018-06-01, this should be 
depends on used files instead

$${commandAlias}.depends += FORCE



# Create the target directory

# Work around problem with Windows that cannot make or on command and syntaxt 
is not the same with Windows and other *nix system

contains(QMAKE_HOST.os, Windows) {

$${commandAlias}.commands += $$escape_expand(\n\t)$(CHK_DIR_EXISTS) 
$$shell_path($$ANDROID_PACKAGE_SOURCE_DIR/$$targetDirectory) $(MKDIR) 
$$shell_path($$ANDROID_PACKAGE_SOURCE_DIR/$$targetDirectory)

} else {

$${commandAlias}.commands += $$escape_expand(\n\t)$(CHK_DIR_EXISTS) 
$$shell_path($$ANDROID_PACKAGE_SOURCE_DIR/$$targetDirectory) || $(MKDIR) 
$$shell_path($$ANDROID_PACKAGE_SOURCE_DIR/$$targetDirectory)

}

# Process each file that we were provided

for(fileName, sourceFiles) {

# Copy the file from the source directory to the target directory

$${commandAlias}.commands += $$escape_expand(\n\t)$(COPY_FILE) 
$$shell_path($$fileName) 
$$shell_path($$ANDROID_PACKAGE_SOURCE_DIR/$$targetDirectory/$$basename(fileName))

}



# We need to make our new command globally available so that qmake can 

Re: [Interest] Double free in QItemDelegate editor

2020-09-04 Thread Jérôme Godbout
Shouldn't the FileDialog belong to the Window and not to the editor? Try 
without parent or parent to the top window on your dialog you can make it modal 
if you need to lock down the window. That would prevent the editor destruction 
to wrongly destroy the Dialog.

-Original Message-
From: Interest  On Behalf Of Kyle Edwards via 
Interest
Sent: September 4, 2020 3:20 PM
To: interest@qt-project.org
Subject: Re: [Interest] Double free in QItemDelegate editor

On 9/4/20 2:40 PM, Kyle Edwards wrote:
> After some more investigation, I've learned more about the nature of 
> the problem.
>
> The createEditor() override returns a button which, when clicked, 
> opens a file dialog (through QFileDialog::getOpenFileName() - this 
> will be important in a bit). The opening of this dialog causes the 
> editor to lose focus, which result in QAbstractItemDelegate emitting 
> its closeEditor() signal, which in turn destroys the editor. The 
> destroying of the editor also attempts to delete the file dialog, 
> since it's a child of the editor. However, the file dialog was 
> allocated on the stack by QFileDialog::getOpenFileName(). So, 
> attempting to delete the stack-allocated dialog results in a crash.
>
> So I guess the question is, how do I prevent QAbstractItemDelegate 
> from emitting closeEditor() when the file dialog opens? Either that or 
> prevent closeEditor() from actually closing the editor... I see 
> something in QAbstractItemView::closeEditor() about an editor being 
> "persistent", does that have anything to do with this?

I now have a minimum working test case:

// BEGIN

#include
#include
#include
#include
#include
#include
#include
#include
#include
classTestEdit: publicQLineEdit
{
Q_OBJECT
public:
TestEdit(QWidget*parent= nullptr);
voidresizeEvent(QResizeEvent*e) override; public slots:
voidchooseFile();
private:
QToolButton* toolButton;
};
TestEdit::TestEdit(QWidget*parent)
: QLineEdit(parent)
{
this->toolButton= newQToolButton(this);
this->toolButton->setText("...");
QObject::connect(this->toolButton, SIGNAL(clicked(bool)), this, 
SLOT(chooseFile())); }
voidTestEdit::resizeEvent(QResizeEvent*e)
{
// make the tool button fit on the right side inth= e->size().height(); // move 
the line edit to make room for the tool button
this->setContentsMargins(0, 0, h, 0);
// put the tool button in its place
this->toolButton->resize(h, h);
this->toolButton->move(this->width() - h, 0);
}
voidTestEdit::chooseFile()
{
autopath= QFileDialog::getOpenFileName(this, "title", QString(), QString(), 
nullptr, QFileDialog::DontResolveSymlinks);
if(!path.isEmpty()) {
this->setText(path);
}
}
classTestItemDelegate: publicQItemDelegate { Q_OBJECT
public:
QWidget*createEditor(QWidget*parent, constQStyleOptionViewItem,
constQModelIndex) constoverride;
};
QWidget*TestItemDelegate::createEditor(QWidget*parent,
constQStyleOptionViewItem, constQModelIndex) const { 
returnnewTestEdit(parent); } intmain(intargc, char**argv) { 
QApplicationapp(argc, argv); QWidgetwindow; QTreeViewview();
auto* model= newQStandardItemModel;
view.setModel(model);
model->insertRow(0);
model->insertColumn(0);
model->setData(model->index(0, 0), "Hello");
view.setItemDelegate(newTestItemDelegate);
window.show();
returnapp.exec();
}
#include"qttest.moc"
// END
Run the program, double click the "Hello" item, a line editor will appear, 
click the button on the right to open the dialog, and then the invalid delete 
happens.
Kyle
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] BLE : Bonding and ble security

2020-08-18 Thread Jérôme Godbout
Hi,
Just to put aside the Windows, you could try to connect using Bluetooth LE 
Explorer application: 
https://www.microsoft.com/en-us/p/bluetooth-le-explorer/9n0ztkf1qd98
It could tell if the Window BLE can perform the connection properly on his own.

Jerome

From: Simon FEUTRIER 
Sent: August 18, 2020 4:09 AM
To: Alex Blasche 
Cc: Jérôme Godbout ; interest@qt-project.org
Subject: Re: [Interest] BLE : Bonding and ble security

If you are interested to follow this problem, there is now also a bug ticket 
here :  https://bugreports.qt.io/browse/QTBUG-86095

Regards,

Simon Feutrier


Le mar. 18 août 2020 à 09:15, Simon FEUTRIER 
mailto:sfeutr...@bluegriot.com>> a écrit :
Hi !

Jérôme, yes it is well secured, very well, even I cannot communicate :D.
For your questions, Qt is supported on Windows, Bluetooth LE as well. About the 
security I am not sure I did not receive a clear reply to that question but it 
seems yes.
My ble device and my Windows are recent enough yes !
Currently in my ble device I am just activating "Just Work" security. And on 
Windows...I just cannot set the security level, so... ^^

Alex, I will create an issue then.

Thank you for your help.

Cordialement,

Simon Feutrier - Ingénieur systèmes embarqués

BLUEGRioT


Le lun. 17 août 2020 à 22:13, Alex Blasche 
mailto:alexander.blas...@qt.io>> a écrit :



From: Interest 
mailto:interest-boun...@qt-project.org>> on 
behalf of Simon FEUTRIER 
mailto:sfeutr...@bluegriot.com>>
Sent: Monday, 17 August 2020 16:31
To: Jérôme Godbout

>Alex, thank you for your quick reply. I just tried with the pre-release 5.15.1 
>and this is the same behavior.

Since you revealed that you are on Windows only, the patch I sent makes no 
sense. It is an Android only patch. This needs a proper bug report now.

--
Alex___
Interest mailing list
Interest@qt-project.org<mailto:Interest@qt-project.org>
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] List on moderation

2020-07-16 Thread Jérôme Godbout
Hi,
I did some medial software for years, it's not the programing language that 
matter most, it's the safety check (checksum, permission, double check 
validation...) that really matter. Don't loose your time with obfuscation, it 
never end well. Ensure the system integrity is good is a better alternative. 
Qml for GUI did work very well for us, we still have to tests the application 
with edges case and validate the fallback and safety catch with automated 
testing, QA, real tester... You need to provide many safety check at runtime 
too to ensure nothing can go out of hand. 

here is a few systems I worked on:
https://bodycad.com/en/products#software
https://www.zimmerbiomet.com/medical-professionals/knee/product/ORTHOSoft-guidance-system.html
https://www.zimmerbiomet.com/medical-professionals/knee/product/iassist-knee.html

The last one if embedded talking to Qt application on the navigation system.
Qml should not contain the logic or the real business logic anyway, it's just 
the GUI layer (I can understand that it's tempting to move more stuff up there, 
since it make things very flexible, but it's better to keep this into C++ so 
that layer can have the objects handling).

To pass 510K or other regulation around the globe, you need to proof your 
robustness and error catching. You have to make sure any alteration to the 
software or hardware will not go unotice and the device should refuse to work 
then. This is making it's way to desktop application with those AppStore, 
PlayStore and Microsoft Store. The application get signed and validate. It's 
just common sense to avoid supporting altered behavior and avoid some hack 
problems.

Rest assure that any byte modification on those system will prevent the 
application to launch and display an error message. Double check and launcher 
must agree that the checksum and signature are still valid. It's the testing 
that validate the robustness not the lnaguage, you could have code it in any 
languge you wanted, some language are just easier to test and strongly typed 
language make it far easier but it's not impossible to have dynamic typed 
languages. It's hard to balance flexibility and robustness in software 
architechture.

Jerome

-Original Message-
From: Interest  On Behalf Of Christian 
Gagneraud
Sent: July 16, 2020 9:57 AM
To: Andy Shaw 
Cc: interestqt-project.org 
Subject: Re: [Interest] List on moderation

On Fri, 17 Jul 2020 at 01:02, Andy Shaw  wrote:
> The global moderation is only going to be for a very short period, and we 
> will lift it because we do not want to prevent open discussion and so on, the 
> intention is to make sure this stays a safe space for the community to 
> interact and not feel afraid to be persecuted for their beliefs. Personal 
> attacks on any individual or group of people will not be tolerated.

I have in the past talked rubbish here, I've been over the top and/or border 
line quite a few times, discussions then quickly turned 'sour'.
I remember being kindly reminded off-line to 'behave' and be open. I did 
appreciate these reminders, I needed them. And I do think this is the best way 
to move forward.

6 month ago i decided that Qml was the best UI solution for a project i was 
given (my first 'real' Qml project), I still think it was the right choice 
(Qml=UI, C++=logic), but i can clearly see the risks of abusing Qml/JS and the 
consequences of letting this go uncontrolled.

Qml, JS and C++ on safety critical systems (health, aeronautics, automotive, 
marine, autonomous & industrial systems, ...) is a very interesting topic. I 
hope we'll hear more about this, and I'm looking forward to reading 
*constructive* discussion on that topic - in the open.

Maybe someone could talk about Qt+QNX (that would change from VAX/VMS ;)), I 
remember some qt.io communication about instrument clusters & human health 
monitoring demos using Qt/Qml. Then there's the new Qt for micro-controller, 
etc...
Honestly, it is healthy to criticise, and even healthier to get proper counter 
arguments.

Thanks for giving details on what is going on. Rants are definitely not cool, 
but personal attacks are worse.

My 2 cents,
Chris.

A guy who's been on the other side of the fence.
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Roland Qml

2020-07-13 Thread Jérôme Godbout
Hi,
If you write your algo into Javascript or you can edit it, you are so doing Qml 
wrong! leave your algo into C++ please, your model/controler too shall be be 
C++. Qml is for the GUI layer only, it so simple it is temping to add more 
logic into it, but that's an error that will bit you in the long run. You can 
compile Qml and with Qt6 convert Qml to C++, so I wonder what would be more a 
problem, do you ship any library into your software or you do static compiling 
of everything so nobody can inspect your lib? Cause, exposing API from a lib or 
any other languages is not hard to reverse used in any way. You do not protect 
code by obfuscation, but protect code with your license. Javascript engine was 
just a practical way at the time, probably a new engine will come one day, 
there is some Qml without Javascript engine coming into Qt6 paving the way for 
it.

Qml, is just a widgets rendering way to declare the GUI in a much simpler and 
cleaner way. If you want to stick to QWidgets, please do, there is no shame 
into QWidgets, he just have a limited future for expansion. The multiple 
rendering engine the embedded and Qt/Qml lite will be more then welcome for me. 
I have switch to Qml and could easily range it from big 3D CAD medical 
software, mobile tools and some development on embedded device. I haven't any 
issue and could reuse code for that whole range (both Qml and C++). 

Nothing in the world will make you change your idea, I known that and I do not 
expect anything to change from you. IMO your are stuck in the past, but if you 
like so much those old version, I'm sure they are still working just like they 
did back then, nobody force anybody to use the latest version as far as I can 
see, Qt4 is still useable if you truly want to keep it that way. Break into API 
happen for a good reason, to remove bad API or to allow better possibility. If 
you have never rewrite any part of the code to allow better architecture to 
take place you must be a coding god that can write code flawless or something 
must horrible into those API. Needs and requirements evolved, code need to 
evolve with them.

I for one, really enjoy Qml and the Qt Meta, wish I could get ride of the Moc, 
but this will wait until C++ get more reflexion built-in. QWidgets, ditch it 
and never been more happy since then, I had to maintain a few applications, it 
now feel cumbersome when I touch them.

This only reflect my own opion, sorry for all the noise to other users,
Jerome

-Original Message-
From: Interest  On Behalf Of Roland Hughes
Sent: July 13, 2020 8:31 AM
To: interest@qt-project.org; rjvber...@gmail.com; Donald Carr 

Subject: Re: [Interest] rebooted QtWebKit for Qt4??


On 7/13/20 5:00 AM, interest-requ...@qt-project.org wrote:
> I also didn't complain about stability, but coming from fundamental research 
> I can relate to the feeling that API breakage of the type Qt3 -> Qt4 -> Qt5 
> (and who knows what Qt6 has in stock) happens too fast, too soon.

Kittens swatting at bright shiny objects.

Let us not forget that QML+JavaScript is completely insecure in the OpenSource 
world. All of that JavaScript gets stuffed into the binary you ship as free 
text. Anyone with a decent text editor can read/extract your super secret 
proprietary algorithms. Worse yet, anyone with enough patience can change a 
binary in the field.

-- 
Roland Hughes, President
Logikal Solutions
(630)-205-1593

http://www.theminimumyouneedtoknow.com
http://www.infiniteexposure.net
http://www.johnsmith-book.com
http://www.logikalblog.com
http://www.interestingauthors.com/blog

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] I love QML

2020-07-02 Thread Jérôme Godbout
+1 totaly agree, we often forget to praise Qt for the great work. I have been 
through many framework (MFC, Xaml, wxWidgets, Xamarin...) but my favorite is 
still Qt with Qml. The binding often leverage the need for those view model or 
model convert to adapt to the view. The fact that I can have most of my lib 
(algo, GUI, controler...) into reusable code between desktop, mobile, embedded 
Yocto is such a huge win. I cannot wait for Qt 6 and C++ binding, seriously 
it's probably the feature I'm most looking forward to, remove those conditional 
connect or complex (mostly hard to maintain) flow around connect.

Long live Qt 

-Original Message-
From: Interest  On Behalf Of Jason H
Sent: July 2, 2020 11:24 AM
To: interestqt-project.org ; ulf.herm...@qt.io
Subject: [Interest] I love QML

I know I spend a lot of time talking about inadequacies of Qt, but it's out of 
love. Since discovering Qt back in oh, 2001 when I was writing MFC apps, I have 
come to love the toolkit despite its rough edges. I have been assigned to port 
our Qt/QML app to Swift. And let me say what a joy it is working with Qt/QML.
- The ability to use JSON inline, and as a proper JavaScript Object is a huge 
feature that I did not appreciate previously.
- The property bindings system eliminates so much code and the automatic 
evaluation of bindings is phenomenal.
- The lack of a separated view and view controller makes reusable components 
even easier.
- The fact that I don't need to use UI machinations in a UI builder to build an 
app (I'm looking at you, @IBOutlet) is another joy
- The fact that Qt types don't seemingly duplicate each other in quirky ways 
(UIColor, CGColor)
- I could go on...

I know Qt is going to offer an alternative to JS, but unless it has all those 
features (mainly the in-line JSON in actual JSON) I am likely to stay with the 
JavaScript version.

A big big Thank You to the Qt team!


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Building iOS from command line

2020-06-23 Thread Jérôme Godbout
Hi, just follow up with my solution that make it work into Jenkins:

The bundle identifier problem:
Into my project .pro
ios {
# The
versionAtLeast(QT_VERSION, 5.11.0) {
QMAKE_TARGET_BUNDLE_PREFIX=ca.amotus
QMAKE_BUNDLE=MyApp
}

!versionAtLeast(QT_VERSION, 5.11.0) {
Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.MyApp
Q_PRODUCT_BUNDLE_IDENTIFIER.name = PRODUCT_BUNDLE_IDENTIFIER
QMAKE_MAC_XCODE_SETTINGS += Q_PRODUCT_BUNDLE_IDENTIFIER
}
}

I dunno why this did changed, but it seem to be working this way now. Sad the 
documentation is so hard to find on those behavior.

The signing problem:
Finaly solve my problem, just made qmake generate the .xcodeproj and used 
xcodebuild to generate the remaining archive and .ipa with proper signing. I 
did try to happen the signing but the wrong certificate was used and I could 
not add my certificate with:
QMAKE_MAC_XCODE_SETTINGS+=certi certi.name=CODE_SIGN_IDENTITY 
certi.value=MyName with space
the value name have space, it did not like it, I try with
certi.value="MyName with space"
certi.value=MyName\ with\ space
but neither did work, so I gave up and went:
"/Users/Shared/Qt/5.15.0/ios/bin/qmake" MyApp.pro -spec macx-ios-clang 
CONFIG+=release CONFIG+=iphoneos CONFIG+=device CONFIG+=qtquickcompiler -after
make -f Makefile qmake_all
make -f Makefile xcodeproj
// Do like other .xcodeproj would do
// Unlock keychain here
// Allow apple-tools to keychain
// Prevent keychain prompt
xcodebuild  with manual signing info goes here
This did the trick pretty well under Jenkins and no more messing around with 
wrong provisioning used for my AdHoc.

Maybe an update to the 
https://doc.qt.io/qt-5/ios.html#building-applications-from-the-command-line
which plain said to open xcode for the command line section O.o

Hope this might help other building into a CI like Jenkins the application.

From: Jérôme Godbout 
Sent: June 18, 2020 5:25 PM
To: Jérôme Godbout ; Boris Ralchenko 
Cc: interest@qt-project.org
Subject: RE: [Interest] Building iOS from command line

I did try to use the command line on my local checkout (was open and configured 
into QtCreator) to see if the Qmake command line would generate the same thing 
as the GUI, it does generate the same thing, so the fact of opening the .pro 
and selecting ios configuration change the output of building for iOS.

A fresh checkout without .pro.user doesn’t give the same output. There is 
nothing into the .user that I can see that could do such a thing, I’m a bit 
lost why this is happenning!? QtCreator is configuring something when opening 
the .pro that is missing from the command line…

Is there a way to output the resulting Info.plist with replacement.  Is this 
the proper way to set the Info.plist:

From my .pro:
Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.NubitusApp
From my ios .pri (I use the same .pri for all iOS application):
DISTFILES += ios/Info.plist
Q_PRODUCT_BUNDLE_IDENTIFIER.name = PRODUCT_BUNDLE_IDENTIFIER
QMAKE_MAC_XCODE_SETTINGS += Q_PRODUCT_BUNDLE_IDENTIFIERQMAKE_INFO_PLIST = 
ios/Info.plist

Damn, I revert my local modification and folder with a
git clean -dfx

Now the bundle identifier is
ca.amotus.testdev.NubitusApp

?!? where does this come from? how does QMake generate the bundle identifier 
for the .xcodeproj exactly? it doesn’t seem to take the Info.plist entry, 
doesn’t seem to use the Q_PRODUCT_BUNDLE_IDENTIFIER either with 
QMAKE_MAC_XCODE_SETTINGS. Note sure if this is normal, but the Info.plist is 
not copied to the generate folder.  Damn this is painful. Can we just copy an 
Info.plist next to the .xcodeproj ? would that be considered by xcode to build 
the project?


From: Interest 
mailto:interest-boun...@qt-project.org>> On 
Behalf Of Jérôme Godbout
Sent: June 18, 2020 4:49 PM
To: Boris Ralchenko mailto:bralche...@ics.com>>
Cc: interest@qt-project.org<mailto:interest@qt-project.org>
Subject: Re: [Interest] Building iOS from command line

I have try to replace the bundle id directly into the .plist:

CFBundleIdentifier
$(PRODUCT_BUNDLE_IDENTIFIER)

by

CFBundleIdentifier
ca.amotus.NubtisuApp

But the resulting xcode project is still got replaced by 
com.yourcompany.NubitusApp, now that is strange, so the .pro value have no 
impact and something is just kind of replacing the value to this 
com.yourcompany.(Application Name). If I open the xcodeproject I can see that 
replaced value. I have no idea where it’s coming from. Anybody have an idea for 
this?

From: Boris Ralchenko mailto:bralche...@ics.com>>
Sent: June 18, 2020 3:09 PM
To: Jérôme Godbout mailto:godbo...@amotus.ca>>
Cc: interest@qt-project.org<mailto:interest@qt-project.org>
Subject: Re: [Interest] Building iOS from command line

I do have the bundle ID specified explicitly in the Info.plist.

I prefer Xcode for debugging/packaging. It appears to be more efficient way 
when I needed to figure out command line build, le

Re: [Interest] Building iOS from command line

2020-06-18 Thread Jérôme Godbout
I did try to use the command line on my local checkout (was open and configured 
into QtCreator) to see if the Qmake command line would generate the same thing 
as the GUI, it does generate the same thing, so the fact of opening the .pro 
and selecting ios configuration change the output of building for iOS.

A fresh checkout without .pro.user doesn’t give the same output. There is 
nothing into the .user that I can see that could do such a thing, I’m a bit 
lost why this is happenning!? QtCreator is configuring something when opening 
the .pro that is missing from the command line…

Is there a way to output the resulting Info.plist with replacement.  Is this 
the proper way to set the Info.plist:

From my .pro:
Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.NubitusApp
From my ios .pri (I use the same .pri for all iOS application):
DISTFILES += ios/Info.plist
Q_PRODUCT_BUNDLE_IDENTIFIER.name = PRODUCT_BUNDLE_IDENTIFIER
QMAKE_MAC_XCODE_SETTINGS += Q_PRODUCT_BUNDLE_IDENTIFIERQMAKE_INFO_PLIST = 
ios/Info.plist

Damn, I revert my local modification and folder with a
git clean -dfx

Now the bundle identifier is
ca.amotus.testdev.NubitusApp

?!? where does this come from? how does QMake generate the bundle identifier 
for the .xcodeproj exactly? it doesn’t seem to take the Info.plist entry, 
doesn’t seem to use the Q_PRODUCT_BUNDLE_IDENTIFIER either with 
QMAKE_MAC_XCODE_SETTINGS. Note sure if this is normal, but the Info.plist is 
not copied to the generate folder.  Damn this is painful. Can we just copy an 
Info.plist next to the .xcodeproj ? would that be considered by xcode to build 
the project?


From: Interest  On Behalf Of Jérôme Godbout
Sent: June 18, 2020 4:49 PM
To: Boris Ralchenko 
Cc: interest@qt-project.org
Subject: Re: [Interest] Building iOS from command line

I have try to replace the bundle id directly into the .plist:

CFBundleIdentifier
$(PRODUCT_BUNDLE_IDENTIFIER)

by

CFBundleIdentifier
ca.amotus.NubtisuApp

But the resulting xcode project is still got replaced by 
com.yourcompany.NubitusApp, now that is strange, so the .pro value have no 
impact and something is just kind of replacing the value to this 
com.yourcompany.(Application Name). If I open the xcodeproject I can see that 
replaced value. I have no idea where it’s coming from. Anybody have an idea for 
this?

From: Boris Ralchenko mailto:bralche...@ics.com>>
Sent: June 18, 2020 3:09 PM
To: Jérôme Godbout mailto:godbo...@amotus.ca>>
Cc: interest@qt-project.org<mailto:interest@qt-project.org>
Subject: Re: [Interest] Building iOS from command line

I do have the bundle ID specified explicitly in the Info.plist.

I prefer Xcode for debugging/packaging. It appears to be more efficient way 
when I needed to figure out command line build, less tools to take care of. It 
is possible that QtCreator GUI has something that command line tools have not.

  CFBundleIcons~ipad
  
  CFBundleIdentifier
  com.viewpoint.kiosk
  CFBundleInfoDictionaryVersion
  6.0
  CFBundleName
  ViewPoint
  CFBundlePackageType
  APPL
  CFBundleShortVersionString
  1.0
  CFBundleSignature
  com.viewpoint.kiosk
  CFBundleVersion
  1.0

Regards,
Boris Ralchenko.




On Jun 18, 2020, at 2:58 PM, Jérôme Godbout 
mailto:godbo...@amotus.ca>> wrote:

Hi,
I have an Info.plist that I have into my project. I have the following entry 
into my Info.plist file:

http://www.apple.com/DTDs/PropertyList-1.0.dtd;>


 CFBundleDisplayName
 ${PRODUCT_NAME}
 CFBundleExecutable
 ${EXECUTABLE_NAME}
 CFBundleGetInfoString
 Created by Qt/QMake
 CFBundleIdentifier
 $(PRODUCT_BUNDLE_IDENTIFIER)
 CFBundleName
 ${PRODUCT_NAME}
 CFBundlePackageType
 APPL
...


From my .pro:
Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.NubitusApp
From my ios .pri (I use the same .pri for all iOS application):
DISTFILES += ios/Info.plist
Q_PRODUCT_BUNDLE_IDENTIFIER.name = PRODUCT_BUNDLE_IDENTIFIER
QMAKE_MAC_XCODE_SETTINGS += Q_PRODUCT_BUNDLE_IDENTIFIERQMAKE_INFO_PLIST = 
ios/Info.plist

I was guessing the replacement should have happen. or does the above variables 
only work when inside QtCreator GUI?


From: Boris Ralchenko mailto:bralche...@ics.com>>
Sent: June 18, 2020 2:46 PM
To: Jérôme Godbout mailto:godbo...@amotus.ca>>
Cc: interest@qt-project.org<mailto:interest@qt-project.org>
Subject: Re: [Interest] Building iOS from command line

Hi Jérôme,

We have a separate Info.plist for command line build, it should solve the 
bundle ID issue. I don’t remember exactly the details, it was couple of years 
ago. But I did check - there is an Info.plist in the repository. I suspect Qt 
Creator generates one too, but I rely on the one from Xcode.

Regards,
Boris Ralchenko.





On Jun 18, 2020, at 2:30 PM, Jérôme Godbout 
mailto:godbo...@amotus.ca>> wrote:

Hi,
I’m trying to build my project from my 

Re: [Interest] Building iOS from command line

2020-06-18 Thread Jérôme Godbout
I have try to replace the bundle id directly into the .plist:

CFBundleIdentifier
$(PRODUCT_BUNDLE_IDENTIFIER)

by
CFBundleIdentifier
ca.amotus.NubtisuApp

But the resulting xcode project is still got replaced by 
com.yourcompany.NubitusApp, now that is strange, so the .pro value have no 
impact and something is just kind of replacing the value to this 
com.yourcompany.(Application Name). If I open the xcodeproject I can see that 
replaced value. I have no idea where it’s coming from. Anybody have an idea for 
this?

From: Boris Ralchenko 
Sent: June 18, 2020 3:09 PM
To: Jérôme Godbout 
Cc: interest@qt-project.org
Subject: Re: [Interest] Building iOS from command line

I do have the bundle ID specified explicitly in the Info.plist.

I prefer Xcode for debugging/packaging. It appears to be more efficient way 
when I needed to figure out command line build, less tools to take care of. It 
is possible that QtCreator GUI has something that command line tools have not.

  CFBundleIcons~ipad
  
  CFBundleIdentifier
  com.viewpoint.kiosk
  CFBundleInfoDictionaryVersion
  6.0
  CFBundleName
  ViewPoint
  CFBundlePackageType
  APPL
  CFBundleShortVersionString
  1.0
  CFBundleSignature
  com.viewpoint.kiosk
  CFBundleVersion
  1.0


Regards,
Boris Ralchenko.





On Jun 18, 2020, at 2:58 PM, Jérôme Godbout 
mailto:godbo...@amotus.ca>> wrote:

Hi,
I have an Info.plist that I have into my project. I have the following entry 
into my Info.plist file:

http://www.apple.com/DTDs/PropertyList-1.0.dtd;>


 CFBundleDisplayName
 ${PRODUCT_NAME}
 CFBundleExecutable
 ${EXECUTABLE_NAME}
 CFBundleGetInfoString
 Created by Qt/QMake
 CFBundleIdentifier
 $(PRODUCT_BUNDLE_IDENTIFIER)
 CFBundleName
 ${PRODUCT_NAME}
 CFBundlePackageType
 APPL
...


From my .pro:
Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.NubitusApp
From my ios .pri (I use the same .pri for all iOS application):
DISTFILES += ios/Info.plist
Q_PRODUCT_BUNDLE_IDENTIFIER.name = PRODUCT_BUNDLE_IDENTIFIER
QMAKE_MAC_XCODE_SETTINGS += Q_PRODUCT_BUNDLE_IDENTIFIERQMAKE_INFO_PLIST = 
ios/Info.plist

I was guessing the replacement should have happen. or does the above variables 
only work when inside QtCreator GUI?


From: Boris Ralchenko mailto:bralche...@ics.com>>
Sent: June 18, 2020 2:46 PM
To: Jérôme Godbout mailto:godbo...@amotus.ca>>
Cc: interest@qt-project.org<mailto:interest@qt-project.org>
Subject: Re: [Interest] Building iOS from command line

Hi Jérôme,

We have a separate Info.plist for command line build, it should solve the 
bundle ID issue. I don’t remember exactly the details, it was couple of years 
ago. But I did check - there is an Info.plist in the repository. I suspect Qt 
Creator generates one too, but I rely on the one from Xcode.

Regards,
Boris Ralchenko.






On Jun 18, 2020, at 2:30 PM, Jérôme Godbout 
mailto:godbo...@amotus.ca>> wrote:

Hi,
I’m trying to build my project from my CI system to generate the .ipa (and stop 
releasing by hand over. But I seem to be missing something into my way of doing 
it (I managed to do it for Android, armv7/armv8 .apk and .aab). Here is my 
steps raw command line steps (not the provisioning, certificate and the 
keychain are installed and work with a Xamarin and Unity application with the 
same setup, the question is not about those parts).

I’m building on lastest MacOS X, xcode is up to date and Qt 5.15.0


"/Users/Shared/Qt/5.15.0/ios/bin/qmake" Nubitus.pro -spec macx-ios-clang 
CONFIG+=release CONFIG+=iphoneos CONFIG+=device CONFIG+=qtquickcompiler -after

make -f Makefile qmake_all

make

The Qmake generate the makefile, make qmake_all work just fine, but the make 
build give me the following error:

Xcode couldn't find any iOS App Development provisioning profiles matching 
'com.yourcompany.NubitusApp'

but my .pro clearly indicate

Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.NubitusApp

When building from inside QtCreator this work and the provisioning is also 
working just fine. so my question: Why is the build any different? is QtCreator 
doing any extra steps not print into the output? is there any env variables 
required for Q_PRODUCT_BUNDLE_IDENTIFIER to be used? Did I miss a step?!

Extra points question: will this generate an .ipa or .app ? How does one 
generate a .ipa from the command lines out of the result build by Qt make?

Thanks,

___
Interest mailing list
Interest@qt-project.org<mailto:Interest@qt-project.org>
https://lists.qt-project.org/listinfo/interest

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Building iOS from command line

2020-06-18 Thread Jérôme Godbout
Hi,
I have an Info.plist that I have into my project. I have the following entry 
into my Info.plist file:

http://www.apple.com/DTDs/PropertyList-1.0.dtd;>


 CFBundleDisplayName
 ${PRODUCT_NAME}
 CFBundleExecutable
 ${EXECUTABLE_NAME}
 CFBundleGetInfoString
 Created by Qt/QMake
 CFBundleIdentifier
 $(PRODUCT_BUNDLE_IDENTIFIER)
 CFBundleName
 ${PRODUCT_NAME}
 CFBundlePackageType
 APPL
...


From my .pro:
Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.NubitusApp
From my ios .pri (I use the same .pri for all iOS application):
DISTFILES += ios/Info.plist
Q_PRODUCT_BUNDLE_IDENTIFIER.name = PRODUCT_BUNDLE_IDENTIFIER
QMAKE_MAC_XCODE_SETTINGS += Q_PRODUCT_BUNDLE_IDENTIFIERQMAKE_INFO_PLIST = 
ios/Info.plist

I was guessing the replacement should have happen. or does the above variables 
only work when inside QtCreator GUI?


From: Boris Ralchenko 
Sent: June 18, 2020 2:46 PM
To: Jérôme Godbout 
Cc: interest@qt-project.org
Subject: Re: [Interest] Building iOS from command line

Hi Jérôme,

We have a separate Info.plist for command line build, it should solve the 
bundle ID issue. I don’t remember exactly the details, it was couple of years 
ago. But I did check - there is an Info.plist in the repository. I suspect Qt 
Creator generates one too, but I rely on the one from Xcode.

Regards,
Boris Ralchenko.





On Jun 18, 2020, at 2:30 PM, Jérôme Godbout 
mailto:godbo...@amotus.ca>> wrote:

Hi,
I’m trying to build my project from my CI system to generate the .ipa (and stop 
releasing by hand over. But I seem to be missing something into my way of doing 
it (I managed to do it for Android, armv7/armv8 .apk and .aab). Here is my 
steps raw command line steps (not the provisioning, certificate and the 
keychain are installed and work with a Xamarin and Unity application with the 
same setup, the question is not about those parts).

I’m building on lastest MacOS X, xcode is up to date and Qt 5.15.0


"/Users/Shared/Qt/5.15.0/ios/bin/qmake" Nubitus.pro -spec macx-ios-clang 
CONFIG+=release CONFIG+=iphoneos CONFIG+=device CONFIG+=qtquickcompiler -after

make -f Makefile qmake_all

make

The Qmake generate the makefile, make qmake_all work just fine, but the make 
build give me the following error:

Xcode couldn't find any iOS App Development provisioning profiles matching 
'com.yourcompany.NubitusApp'

but my .pro clearly indicate

Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.NubitusApp

When building from inside QtCreator this work and the provisioning is also 
working just fine. so my question: Why is the build any different? is QtCreator 
doing any extra steps not print into the output? is there any env variables 
required for Q_PRODUCT_BUNDLE_IDENTIFIER to be used? Did I miss a step?!

Extra points question: will this generate an .ipa or .app ? How does one 
generate a .ipa from the command lines out of the result build by Qt make?

Thanks,

___
Interest mailing list
Interest@qt-project.org<mailto:Interest@qt-project.org>
https://lists.qt-project.org/listinfo/interest

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Building iOS from command line

2020-06-18 Thread Jérôme Godbout
Sorry, forgot to mention, the iOS settings when building into the QtCreator is
Development team: Default
Automaticaly manage signing: checked

Qmake setting from within the QtCreators:
additional arguments: is blank (nothing added)
effective calls:
/Users/Shared/Qt/5.15.0/ios/bin/qmake 
/Users/MyUSER/dev/Nubitus-App-Qml/Nubitus.pro -spec macx-ios-clang 
CONFIG+=release CONFIG+=iphoneos CONFIG+=device CONFIG+=qtquickcompiler -after 
&& /usr/bin/make qmake_all
Nothing is checked into the ABI section either.
Nothing into the make section have been added.
No env variables have been manually update there either.

So I do not specify anything more into the .user of the project. All is self 
contains and should be ready to build out of the box.


From: Interest  On Behalf Of Jérôme Godbout
Sent: June 18, 2020 2:30 PM
To: interest@qt-project.org
Subject: [Interest] Building iOS from command line

Hi,
I'm trying to build my project from my CI system to generate the .ipa (and stop 
releasing by hand over. But I seem to be missing something into my way of doing 
it (I managed to do it for Android, armv7/armv8 .apk and .aab). Here is my 
steps raw command line steps (not the provisioning, certificate and the 
keychain are installed and work with a Xamarin and Unity application with the 
same setup, the question is not about those parts).

I'm building on lastest MacOS X, xcode is up to date and Qt 5.15.0


"/Users/Shared/Qt/5.15.0/ios/bin/qmake" Nubitus.pro -spec macx-ios-clang 
CONFIG+=release CONFIG+=iphoneos CONFIG+=device CONFIG+=qtquickcompiler -after

make -f Makefile qmake_all

make

The Qmake generate the makefile, make qmake_all work just fine, but the make 
build give me the following error:

Xcode couldn't find any iOS App Development provisioning profiles matching 
'com.yourcompany.NubitusApp'

but my .pro clearly indicate

Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.NubitusApp

When building from inside QtCreator this work and the provisioning is also 
working just fine. so my question: Why is the build any different? is QtCreator 
doing any extra steps not print into the output? is there any env variables 
required for Q_PRODUCT_BUNDLE_IDENTIFIER to be used? Did I miss a step?!

Extra points question: will this generate an .ipa or .app ? How does one 
generate a .ipa from the command lines out of the result build by Qt make?

Thanks,

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Building iOS from command line

2020-06-18 Thread Jérôme Godbout
Hi,
I'm trying to build my project from my CI system to generate the .ipa (and stop 
releasing by hand over. But I seem to be missing something into my way of doing 
it (I managed to do it for Android, armv7/armv8 .apk and .aab). Here is my 
steps raw command line steps (not the provisioning, certificate and the 
keychain are installed and work with a Xamarin and Unity application with the 
same setup, the question is not about those parts).

I'm building on lastest MacOS X, xcode is up to date and Qt 5.15.0


"/Users/Shared/Qt/5.15.0/ios/bin/qmake" Nubitus.pro -spec macx-ios-clang 
CONFIG+=release CONFIG+=iphoneos CONFIG+=device CONFIG+=qtquickcompiler -after

make -f Makefile qmake_all

make

The Qmake generate the makefile, make qmake_all work just fine, but the make 
build give me the following error:

Xcode couldn't find any iOS App Development provisioning profiles matching 
'com.yourcompany.NubitusApp'

but my .pro clearly indicate

Q_PRODUCT_BUNDLE_IDENTIFIER.value = ca.amotus.NubitusApp

When building from inside QtCreator this work and the provisioning is also 
working just fine. so my question: Why is the build any different? is QtCreator 
doing any extra steps not print into the output? is there any env variables 
required for Q_PRODUCT_BUNDLE_IDENTIFIER to be used? Did I miss a step?!

Extra points question: will this generate an .ipa or .app ? How does one 
generate a .ipa from the command lines out of the result build by Qt make?

Thanks,

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] [Development] Windows 7 support will be, dropped in Qt 6

2020-06-18 Thread Jérôme Godbout
>>> But you created an object in C++; exposed it to worthless QML; being 
>>> worthless QML handed it off to JavaScript. Now three different garbage 
>>> collection systems believe they "own" it. On a gasping for its last breath 
>>> undersized processor to extend battery life, everything is fine because 
>>> garbage collection never runs. Move your code to a really good processor 
>>> and suddenly things crash all over. The object got deleted yet QML and 
>>> JavaScript each think they own it. When they try to reference (or double 
>>> delete) it fails.

You don't need to  make your object all be declare into Qml, only the Gui 
should be in Qml in a normal design, keep your controler, models and everything 
else into C++. You also can check and change the ownership of each object from 
C++ or to Javascript if you want to swing them. Nothing too difficult there. 
The Qml object follow the parent just like any other QObject. QQmlEngine 
interpret the declarative code (and soon will compile it to C++ into Qt6), what 
wrong with it? If you have double delete, you have bad design or you have 
mutliple owner of an object (just like you can do with C++ and the unique_ptr, 
shared_ptr). Qml only simplify the writing of connection between the GUI and 
the core of the application (business logic, true code). Normally if your 
application is well design, you can strip the Qml layer and make a command line 
interface without change to your core code or you can swap the Qml layer with 
QWidgets one (and take a close look at how much more code you will need to 
achieve the same results and reactivity).

The extra mile to expose the C++ object to meta is not great but also offer 
other options, Qt meta allow a lot of reflection to C++. One day we can get 
ride of it when the C++ refelection make it to the standard (there something on 
the near horizon fromwhat I saw), but I would not put too much effort on it 
until they do, no need to rewrite 3x the meta/moc.

As for RAM usage I agree, device have become very hungry, but on the other hand 
you can make something consume a lot of ram and still run quickly, nobody want 
to pay top dollars to optimize the assembly anymore, the RAM price is so cheap 
compre to developr time price, the resulting business will easily go screw 
optimization and just crank up the specs of the hardware (this is often cheaper 
and make more sense business wise).


-Original Message-
From: Interest  On Behalf Of Roland Hughes
Sent: June 18, 2020 1:27 PM
To: Matthew Woehlke ; interest@qt-project.org
Subject: Re: [Interest] [Development] Windows 7 support will be, dropped in Qt 6


On 6/18/20 11:17 AM, Matthew Woehlke wrote:
> On 18/06/2020 11.11, Roland Hughes wrote:
>> Could someone from such a background learn enough C syntax to write a 
>> student C program like this one?
>> [example program elided]
>
> Maybe. To the point various others are making, just because someone 
> hasn't learned the fundamentals doesn't mean they're incompetent.
>
> OTOH, not everyone can learn competence. The point is, *you just don't 
> know*.

The point is we are the sum of our training and experience. Without the formal 
training there is an incredibly high probability one will end up in an AGILE 
shop instead of a Software Engineering shop. In an AGILE shop, their 
"experience" won't be good stuff promoting professional growth.

As to "various others making" I get this via digest unless someone direct 
includes me. I will see the "various others making" at some point over the next 
few days when I have time to look at the digest. Trying to add Debian build 
support to Gede right now. Not a difficult thing, just needs focus.

>
>> Could that same person write a page swapping system for a Linux-like 
>> OS from scratch? No.
>
> Again, *maybe*. Not, perhaps, without learning the fundamentals first, 
> but as noted, just because they haven't learned *yet* doesn't mean 
> they can't. But, again, there are plenty of people that can muddle 
> through basic stuff with "training wheels" languages that *can't* 
> grasp the fundamentals well enough for such tasks, and that's the 
> point you (Roland) and I are making.

I guess I should have added "in under a year." There is a time thing on the 
front end too, I just don't want to put any thought into what it is right now. 
The longer you spend in an AGILE shop where nobody was professionally trained, 
the more bad practices and habits you pick up. 
There comes a tipping point where you physically can't go back and learn the 
fundamentals because they are contrary to what you do each and every day.


>
> To be fair, I might be in the latter category. I don't recall
> *formally* learning much about memory management (although there was 
> some generic algorithms stuff); nevertheless, my first professional 
> job was pure C and I managed well enough. I'd like to think I'm 
> competent, if not amazing.

You are probably way better than I. The point is when you take 

Re: [Interest] [Development] Windows 7 support will be dropped in Qt 6

2020-06-15 Thread Jérôme Godbout
Yeah API between major version is going to change, because, yeah the world is 
evolving and better concept become available, if you thing all the API changes 
are for idevice only, your saying but I beg to differ. I really like where they 
are heading. QWidgets is hard to maintain and is one reason it's mostly left as 
is, because it require a lots to maintain the native GUI on each platform so 
new platforms require a lot of effort to be added (this is no more a 3 OS only 
world anymore, those days have been over, move on). 

Qml (I have made 3D medical CAD application desktop, and it run flawlessly), I 
for one have ditch QWidgets and I don't plan to look back to the pain of 
connecting everything by hand, error prone and make way to many hard to 
maintain code. Qt bindings is coming to C++ and this will also be a huge 
welcome from me. The changes that was made is exactly to adapt to the world, 
and multiple platform out there. Qml also open the door to Qt for MCU, to Web 
assembly ... I fail to see why the iDevice is a concern, they are expending the 
allowed paltforms and this is good for a cross platform framework to do so.

If your developer have hard time learning Qt3 to Qt5, I feel sorry for you, 
your team is probably weak (but this is my personnal opinion). They must have a 
hard time with C++11 to C++17 too. I have port application from Qt3 to Qt4 back 
in the days, from PPC to x86. From Qt4 to Qt5. The new code mostly felt cleaner 
in the end. Nobody is force to update from major version if that suite you. If 
you used an unsupport OS, you probably still used the lastest framework that 
were designed to support those, don'T expect Qt to support OS that aren't event 
supported by the manufacturer anymore. You cannot take such a told in the long 
run. But if you feel like the project has gone side way and you prefer the 
alternative fork, this is what open source is for. 


-->1) Kids who only learn the new stuff can't be hired to support the old 
because they cannot even begin to function.
- We do have people from 22 to over 50, they code from embedded mcu C to Qt5 
without problems, I suggest you hired from different schools.

--> 2) If someone decides to pull the plug on their really old embedded OS in 
favor of a roll-your-own Yocto Linux build, they can't even bring their code 
forward. The entire cross-platform aspect of Qt has been abandoned. It's only 
cross-platform for "the cool kids."
- Far from it, I found Qt more open to platform (MCU, embedded, web...). What 
is wrong with rolling out Yocto? for embedded system this is a good way. If the 
OS is deprecated and unsupported, continue to use the tools that were going 
along with it and stay frozen into time with it if you want. 

-->*No core API changes that break backward compatibility. *
- They mostly have minor changes between minor version or not even at all. 
Those are between major Qt version and let's face it, it's normal to make thing 
evolve, just like C++ is evolving too. I manage to maintain few application 
from 5.6 to 5.15 in the past few years, the most problems I got was with 
Android/iOS and the Play/App Store requirements, the Qt was easy to and mostly 
smooth.

My opnion, doesn't reflect any cie but my own.

-Original Message-
From: Roland Hughes  
Sent: June 15, 2020 12:06 PM
To: Jérôme Godbout ; interest@qt-project.org; Thiago 
Macieira 
Subject: Re: [Interest] [Development] Windows 7 support will be dropped in Qt 6

You completely miss the point.

Qt has been prone to sweeping API changes mostly due to the fact they keep 
chasing the iDiot phone market. If that is the market they want, fine, but they 
had best fess up now so everyone else can go somewhere else.

You can't take someone who learned via Qt 5 and have them work in Qt 3 because 
it is night and day different.

You can change an awful lot without going down the full clinical trial path. IT 
ALL DEPENDS ON RISK.

That device I linked went through some kind of enhancement approval path. I 
don't know what it replaced exactly, but I do know the previous device did not 
use Linux or Qt. I know because I worked on that project.

When you get out into the world of industrial controls, they don't have the FDA 
level of certification. They do have 20-50 year lifespans though. These are 
things with a base price of half a million going well up past $5-$6 million. 
They have a minimum 30 year life span, most are closer to 50. Many of them are 
running DOS, WinCE, and the embedded version of Windows 7. It's bad enough that 
Qt keeps dropping everything the industrial and medical world needs in pursuit 
of the iDiot phone market, BUT ADDING INSULT TO INJURY THEY KEEP MAKING 
SWEEPING API CHANGES. This means two things:

1) Kids who only learn the new stuff can't be hired to support the old because 
they cannot even begin to function.

2) If someone decides to pull the plug on their really old embedded OS in favor 
of a roll-your-ow

Re: [Interest] [Development] Windows 7 support will be dropped in Qt 6

2020-06-15 Thread Jérôme Godbout
This is exactly my point, that device is STILL on Qt3 because you don't want to 
go all over that certifications/testing just for changing a Qt versions. You 
can enchance it, but you will need to proof the changes impacts have been cover 
in testings and no risk have been added. Those system, nearly never get update 
libs or anything at large because you have to retests and recertify the whole 
thing. Just changing the model of an harddrive into a machine make a need to 
recertify. So those device will never care if the bleeding edge Qt doesn't 
support their platform. They are fixed with known version of differents libs 
that are known to be workign together and tested.

Those device are not using anything bleeding edge, so let alone runing any 
Windows 7 or Windows 10 with Qt6 in the near time. If anything into those 
domain start using Qt6 it will probably be a new design or a new version that 
will need to be certified all over again anyway, so the upgrade path is not 
there.

-Original Message-
From: Roland Hughes  
Sent: June 15, 2020 10:11 AM
To: Jérôme Godbout ; interest@qt-project.org; Thiago 
Macieira 
Subject: Re: [Interest] [Development] Windows 7 support will be dropped in Qt 6

I seriously beg to differ.

In America "upgrades" and field patches have a completely different 
certification path than "shiny new device." What has to be certified is based 
on the extent of the changes and how well the FDA documentation is filled out.

That OS/2 Qt3 medical device I get an email about ever 18 months or so 
continues to get enhancements. Changing to even Qt for or Linux would push it 
to "shiny new device" depending on the assessed risk level.

A patient monitor like this one

https://www.welchallyn.com/en/products/categories/patient-monitoring/vital-signs-devices/connex-spot-monitor.html

Has a completely different risk level than say, an infusion pump.

I have worked on products that just added new features to existing lines. In 
America it happens all of the time.


On 6/15/20 8:33 AM, Jérôme Godbout wrote:
> I have work for medical devices for over 10 years and used Qt from 4.x to 5.8 
> (move out to IoT lately), designing system and software. Cie who do that, did 
> it wrong, you have to ensure your software will run and you maintaint it, but 
> in no way you will add any new features (you will need to certify again!). 
> You keep a system images that can recreate the exact same output (OS, build 
> tools, ...), you patch the bug that's all you should do. New features will be 
> done into a new system that will need to be certify all over again.
>
> Upgrading to Qt6 for already certified devices is a no go, no matter what for 
> them. This is totally irrelevent. You only upgrade tools and libs when you 
> create a new system (version, design, etc) that will be certified again.
>
>
> -Original Message-
> From: Interest  On Behalf Of Roland Hughes
> Sent: June 13, 2020 11:08 AM
> To: interest@qt-project.org; Thiago Macieira 
> Subject: Re: [Interest] [Development] Windows 7 support will be dropped in Qt 
> 6
>
> Medical devices are certified with their manufacturing process.
> Certification of something like a surgical robot can take 5+ years of 
> clinical trials. That is _after_ you have done all of your internal 
> development and cadaver trials.
>
> On 6/13/20 5:00 AM, interest-requ...@qt-project.org wrote:
>>> That's partially for their own peace of mind and stability, but along
>>> with that, many tool vendors take quite a while to certify their
>>> offerings, both hardware and software, which gives people another
>>> reason to stay behind.
>> More than two years?
> --
> Roland Hughes, President
> Logikal Solutions
> (630)-205-1593
>
> http://www.theminimumyouneedtoknow.com
> http://www.infiniteexposure.net
> http://www.johnsmith-book.com
> http://www.logikalblog.com
> http://www.interestingauthors.com/blog
>
> ___
> Interest mailing list
> Interest@qt-project.org
> https://lists.qt-project.org/listinfo/interest

-- 
Roland Hughes, President
Logikal Solutions
(630)-205-1593

http://www.theminimumyouneedtoknow.com
http://www.infiniteexposure.net
http://www.johnsmith-book.com
http://www.logikalblog.com
http://www.interestingauthors.com/blog

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] [Development] Windows 7 support will be dropped in Qt 6

2020-06-15 Thread Jérôme Godbout
I have work for medical devices for over 10 years and used Qt from 4.x to 5.8 
(move out to IoT lately), designing system and software. Cie who do that, did 
it wrong, you have to ensure your software will run and you maintaint it, but 
in no way you will add any new features (you will need to certify again!). You 
keep a system images that can recreate the exact same output (OS, build tools, 
...), you patch the bug that's all you should do. New features will be done 
into a new system that will need to be certify all over again.

Upgrading to Qt6 for already certified devices is a no go, no matter what for 
them. This is totally irrelevent. You only upgrade tools and libs when you 
create a new system (version, design, etc) that will be certified again.


-Original Message-
From: Interest  On Behalf Of Roland Hughes
Sent: June 13, 2020 11:08 AM
To: interest@qt-project.org; Thiago Macieira 
Subject: Re: [Interest] [Development] Windows 7 support will be dropped in Qt 6

Medical devices are certified with their manufacturing process. 
Certification of something like a surgical robot can take 5+ years of clinical 
trials. That is _after_ you have done all of your internal development and 
cadaver trials.

On 6/13/20 5:00 AM, interest-requ...@qt-project.org wrote:
>> That's partially for their own peace of mind and stability, but along 
>> with that, many tool vendors take quite a while to certify their 
>> offerings, both hardware and software, which gives people another 
>> reason to stay behind.
> More than two years?

--
Roland Hughes, President
Logikal Solutions
(630)-205-1593

http://www.theminimumyouneedtoknow.com
http://www.infiniteexposure.net
http://www.johnsmith-book.com
http://www.logikalblog.com
http://www.interestingauthors.com/blog

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] [Development] Windows 7 support will be dropped in Qt 6

2020-06-11 Thread Jérôme Godbout
Nothing force you to upgrade to Qt6, you can still make evolve that application 
into Qt 5.15 as long as your user still use Windows 7.  Windows 7 is old, the 
days of keeping old OS around have been over for 10 years IMO. Everything is 
moving to evergreen (OS, Web browser, application...). Otherwise those only 
make security and support a nightmare. Windows 10 was free upgrade for a while 
for a good reason. I don't see why Qt should support that platform any longer 
since Microsoft doesn't even support it anymore. Yes software deprecated way 
faster then hardware now a day it's the way things are. Keeping an OS for 10-15 
years won't happen again, no more XP going to last that long anymore.

If you want to stick with old OS stick with old version, nothing bad doing 
this, but don't expect new bleeding edge stuff on it. What was running should 
still be running on it. You cannot have both way, those are just painful. 

Make a good preview version with Qt 6 and try to lure them to upgrade to 
Windows 10 along with it (or Windows 11 by the time Qt 6 and you get your 
application ready "Microsoft will release Windows 11 on July 29, 2020, and will 
be available to the general public." ). But keep your main devel focus on the 
maximal version that cover your user basis.

-Original Message-
From: Interest  On Behalf Of Christoph Cullmann
Sent: June 11, 2020 12:36 PM
To: Frederik Schwarzer 
Cc: interest@qt-project.org
Subject: Re: [Interest] [Development] Windows 7 support will be dropped in Qt 6

On 2020-06-11 18:06, Frederik Schwarzer wrote:
> Am 11.06.2020 17:32 schrieb Christoph Cullmann:
> 
> Hi,
> 
> 
>> I think a lot of developers/companies will have pain because of this, 
>> if they have
>> 
>> 1) some large customers staying on Windows 7 until really EOL for 
>> them
> 
> Not really an opinion about this but this changelog entry from a 
> release two weeks ago came to mind.
> "Updated the included Qt library to version 4.8.7." ;) ... And 
> that company has a big market share.
> 
> In the industry lots of companies lag behind ... a ... bit. But I 
> would suspect those who lag behind with their Windows version to also 
> do not mind lagging behind with their Qt versions.
> And since Qt 5.15 will be supported for quite some time ... But as I 
> said, I am not in favor of or against one or another.
> 
> Do you have a customer who actually runs on Windows 7 and is otherwise 
> eager to jump on Qt6 in its early releases? I mean, maintaining old 
> Windows versions will double in price every year now, so there's some 
> pressure at least.

I think there is a misunderstanding: The customer will get some software to 
use, they don't care if it uses internally Qt X.Y or whatever.

And yes, even if they have Windows 7, they will want a new version of the 
software with feature X they paid for ;=) They will not even understand why 
that should not be possible given they have some Windows 7 support contract 
with Microsoft and will tell you "but it is not EOL for us".

I just wanted to point out that for people building software with Qt, this 
might mean they will need to maintain two versions of their software to still 
cater all their Windows customers. Which doubles the pain for them ;=)

And yes, one might argue this is a sole issue for the people building such 
software, but this issue doesn't arise for them if they use an other toolkit 
that doesn't deprecate Windows 7 now.

Greetings
Christoph

--
Ignorance is bliss...
https://cullmann.io | https://kate-editor.org 
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Oauth2 redirect url

2020-06-01 Thread Jérôme Godbout
Hi,
I’m porting an old application to new Qt version (last build was made with Qt 
5.9 if I remember well). This application was using oauth2 authentication. Now 
with Qt 5.12 or 5.15, I can an error with the redirect url since it doesn’t 
match the one that were configured.
The old one was using:
http://localhost:
and now it does:
http://127.0.0.1:

When it open the web browser, I get an error unsupported redirect url, if I 
modify the url request bar by hand and replace the 127.0.0.1 by localhost it 
work and I get to authenticate. But I cannot allow that for end user 

I guess I will have to modify the whole chain on all allowed application to add 
a new supported url and modify my info.plsit and my AndroidManifest.xml
But I was wondering if there is a way to change that url redirect somehow.

N.B.1: Why not allow any redirect url, it’s not like it add any security (I can 
handle the result with localhost and send the info to whoever I want after, it 
does so into plain http!).
N.B.2: Is any https to redirect will ever come to oauth module?

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QMake contains and include

2020-05-22 Thread Jérôme Godbout
The filter make it slightly better, still see the .pri and those part clear, I 
still have to dig them to see if they are used. I would love to see the .pri 
and folder grey out if nothing is used into it.
Thanks for the info all.

-Original Message-
From: Interest  On Behalf Of Christian Kandeler
Sent: May 22, 2020 3:34 AM
To: interest@qt-project.org
Subject: Re: [Interest] QMake contains and include

On Thu, 21 May 2020 13:35:08 +
Jérôme Godbout  wrote:

> It would be nice to see the .pri grey out or something more obvious. Or even 
> better an option to show/hide them.

The project tree filter has an option "Hide disabled files".


Christian
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QMake contains and include

2020-05-21 Thread Jérôme Godbout
I understand your point, but I would love to see a different UX for non include 
.pri to be quickly different from the one included (now I have to dig to the 
resources, headers or sources to see the difference). It would be nice to see 
the .pri grey out or something more obvious. Or even better an option to 
show/hide them.

-Original Message-
From: André Pönitz  
Sent: May 21, 2020 12:02 AM
To: Jérôme Godbout 
Cc: gm...@ratijas.tk; interest@qt-project.org
Subject: Re: [Interest] QMake contains and include

On Wed, May 20, 2020 at 04:30:41PM +, Jérôme Godbout wrote:
>It kinda work, it’s really weird, but all the project get display, the
>.pri and the include/source no matter the condition, but they are grey
>out if the include condition is false, so it does scan the .pri no
>matter what but doesn’t really include them to be used only for
>display!?! So I got all the optional part display but not really used.
>The compile seem to work. This leave an horrible UX view for developer
>to see part that aren’t used but source is display and searchable for
>the project!
> 
> 
>I think I can live with it but this is an horrible UX to display those
>include no matter the condition that include them or not, here what it
>does (image in attachment) with:

I guess you also would prefer refactorings, searches for occurences of symbols 
and translatable strings not to happen in branches of your project that are 
currently not active.

That's not the case for everybody.

Andre'
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QMake contains and include

2020-05-21 Thread Jérôme Godbout
Thanks Thiago, it clear up. It does make more sense to me now.

My use case is my projects use a subrepository that have a core code mandatory 
and some optional parts. Many projects use that subrepos and inlclude or not 
the optional part based on the application need. It look like this:

MyApp1.pro
MySubreposMandatory.pri
MySubreposOption1.pri (included)
MySubreposOption2.pri (not inlcuded)

MyApp2.pro
MySubreposMandatory.pri
MySubreposOption1.pri (included)
MySubreposOption2.pri (inlcuded)

This is a simpler use case but this is how we do reuse many code part between 
our applications with generic code. When I'm doing app2 it make sens to edit 
the  Option2, but when I do work in app1 I do not use the option2, I won't edit 
it. It ain't that bad, I was more confuse about that behavior. 

This is only my own opinion on the behavior:

Pro:
-I can see the available options project that I can include in my applications
-Search also fetch code from unused parts (replace API less chance to forget a 
code into optional part)

Cons:
-Clutter the UI with unsued parts and confuse my junior dev about what is used 
into the projects. We have to open the module and look if the source is grey 
out or not to known if that module is used into the application or look 
directly into the .pro
-Search also fetch code from unused parts (unwanted used code into application)

I do something like this into my app to easily add or remove stuff from it:


// MyApp.pro
AMOTUS_SUBREPOS_NAMES = Amotus_CPP Amotus_Qt Amotus_Qml Amotus_Style
AMOTUS_SUBREPOS_OPTIONAL_NAMES = i18n Amotus_Qt_FileSystem Amotus_Qt_OAuth 
Amotus_Qt_Network Amotus_Qt_Bluetooth Amotus_Qt_GUI 

for(a, AMOTUS_SUBREPOS_NAMES){
!include($${AMOTUS_SUBREPOS_PATH}/$${a}/pri/$${a}.pri){
error(Cannot find the sub repos 
$${AMOTUS_SUBREPOS_PATH}/$${a}/pri/$${a}.pri)
}
}


// Amotus_Qt.pri
contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, i18n){
include(i18n.pri)
HEADERS += $$AMOTUS_Qt_PATH/i18n.h
SOURCES += $$AMOTUS_Qt_PATH/i18n.cpp
}
contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, Amotus_Qt_FileSystem){
include(Amotus_Qt_FileSystem.pri)
}
...

-Original Message-
From: Interest  On Behalf Of Thiago Macieira
Sent: May 20, 2020 9:44 PM
To: interest@qt-project.org
Subject: Re: [Interest] QMake contains and include

On Wednesday, 20 May 2020 10:39:50 PDT Jérôme Godbout wrote:
> If I may, why I want that in QtCreator exactly? what is the use case 
> for this? If my project doesn't use a part, why is it parsed at all? 
> What will happen if that unused .pri make a failure for something 
> missing? Will it failed to load the project and stop? let's say I have 
> an option that require an interaction with another subrepos, one 
> project might not need that part and not have it checkout, the .pri 
> that interact with it would not be include, how would QtCreator react to this?

Are those two source files not part of your project? If they are, then they 
should be included in the file listing. I assume you sometimes edit them.

The Qt Creator ProParser code has some different error recovery mechanisms than 
qmake. Obviously it's going to be non-fatal to interact with a repository that 
is missing. It will also not run $$system() and do some other things that qmake 
would.

--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel System Software Products



___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QMake contains and include

2020-05-20 Thread Jérôme Godbout
Sorry about that, yeah it's QtCreator, I figure out it was displaying the 
unused .pri along all the file inclusion of it. At first I was thinking it was 
including the .pri straight since I could see it, then I realized the source, 
headers and resources files was gray out, which seem to indicate it won't be 
used. The compiler seem to do the right thing. It was very confusing to see the 
non included .pri showing up along their content.

If I may, why I want that in QtCreator exactly? what is the use case for this? 
If my project doesn't use a part, why is it parsed at all? What will happen if 
that unused .pri make a failure for something missing? Will it failed to load 
the project and stop? let's say I have an option that require an interaction 
with another subrepos, one project might not need that part and not have it 
checkout, the .pri that interact with it would not be include, how would 
QtCreator react to this?

Thanks,

-Original Message-
From: Interest  On Behalf Of Thiago Macieira
Sent: May 20, 2020 1:23 PM
To: interest@qt-project.org
Subject: Re: [Interest] QMake contains and include

On Wednesday, 20 May 2020 09:30:41 PDT Jérôme Godbout wrote:
> It kinda work, it’s really weird, but all the project get display, the 
> .pri and the include/source no matter the condition, but they are grey 
> out if the include condition is false, so it does scan the .pri no 
> matter what but doesn’t really include them to be used only for 
> display!?! So I got all the optional part display but not really used. 
> The compile seem to work. This leave an horrible UX view for developer 
> to see part that aren’t used but source is display and searchable for the 
> project!

Are you talking about qmake or about Qt Creator's .pro file parsing?

Qt Creator evaluates all conditions, including false ones, so it can gather all 
dependencies and all possibilities. For example, if you had:

contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, i18n): \
SOURCES += $$AMOTUS_Qt_PATH/i18n.cpp
else: \
SOURCES += $$AMOTUS_Qt_PATH/no-i18n.cpp

Then Qt Creator should display both files in your file listing. You *want* that.

But qmake will follow only one code path when generating your Makefile.

So please be precise: are you talking about Qt Creator or are you talking about 
the actual build?
--
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel System Software Products



___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QMake contains and include

2020-05-20 Thread Jérôme Godbout
It kinda work, it’s really weird, but all the project get display, the .pri and 
the include/source no matter the condition, but they are grey out if the 
include condition is false, so it does scan the .pri no matter what but doesn’t 
really include them to be used only for display!?! So I got all the optional 
part display but not really used. The compile seem to work. This leave an 
horrible UX view for developer to see part that aren’t used but source is 
display and searchable for the project!

I think I can live with it but this is an horrible UX to display those include 
no matter the condition that include them or not, here what it does (image in 
attachment) with:
if(true) {
include(Amotus_Qt_GUI.pri)
}
if(false){
include(Amotus_Qt_Commands.pri)
}


From: gm...@ratijas.tk 
Sent: May 20, 2020 11:41 AM
To: Jérôme Godbout ; interest@qt-project.org
Subject: Re: [Interest] QMake contains and include

qmake is strange, it implements custom syntax and grammar. Don't search for any 
deep logic there. It will be superseded by CMake soon anyway.

About your issue, I looked it up on DuckDuckGo, and the first result is the 
discussion on StackOverflow which looks like it:
https://stackoverflow.com/questions/46078270/qmake-scope-syntax-with-contains-function

Hope that helps somehow~

20.05.2020, 18:29, "Jérôme Godbout" 
mailto:godbo...@amotus.ca>>:

Sorry for the noise, but I did found a way simpler example to test this:



if(false){

  message(“Pass here”)

  include(“myfile.pri”)

}



myfile.pri is always included no matter what, but the message is not printed! 
this is really counter intuitive. Any way to make a conditional include?!?





From: Interest 
mailto:interest-boun...@qt-project.org>> On 
Behalf Of Jérôme Godbout
Sent: May 20, 2020 11:17 AM
To: interest@qt-project.org<mailto:interest@qt-project.org>
Subject: [Interest] QMake contains and include



Hi,

QMAKE question: anybody manage to use an include inside a contains(){} into 
QMake? the include is processed no matter what!?!

message("list: '$$AMOTUS_SUBREPOS_OPTIONAL_NAMES' ")
contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, i18n){
message("Using i18n...")
HEADERS += $$AMOTUS_Qt_PATH/i18n.h
SOURCES += $$AMOTUS_Qt_PATH/i18n.cpp
include(i18n.pri)
}contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, Amotus_Qt_Network){
message("Using Amotus_Qt_Network...")
include(Amotus_Qt_Network.pri)
}

If I put AMOTUS_SUBREPOS_OPTIONAL_NAMES = i18n
The message print:

Project MESSAGE: list: 'i18n'
Project MESSAGE: Using i18n...

The message is correct. But I get both the i18n.pri and the 
Amotus_Qt_Network.pri include anyway!? if I remove the i18n entry from the 
variable AMOTUS_SUBREPOS_OPTIONAL_NAMES =
I get the following:

Project MESSAGE: list: ''

The include for i18n.pri and Amotus_Qt_Network.pri are still included, but the 
i18n.h and i18n.cpp are grey out which seem to work for HEADERS and SOURCES but 
not include!?! is include special or parsed without any consideration of the 
scope?! I did try to close QtCreator and reopen without luck (using QtCreator 
4.12.0 on Mac OS)


,

___
Interest mailing list
Interest@qt-project.org<mailto:Interest@qt-project.org>
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] QMake contains and include

2020-05-20 Thread Jérôme Godbout
Sorry for the noise, but I did found a way simpler example to test this:

if(false){
  message("Pass here")
  include("myfile.pri")
}

myfile.pri is always included no matter what, but the message is not printed! 
this is really counter intuitive. Any way to make a conditional include?!?


From: Interest  On Behalf Of Jérôme Godbout
Sent: May 20, 2020 11:17 AM
To: interest@qt-project.org
Subject: [Interest] QMake contains and include

Hi,
QMAKE question: anybody manage to use an include inside a contains(){} into 
QMake? the include is processed no matter what!?!
message("list: '$$AMOTUS_SUBREPOS_OPTIONAL_NAMES' ")
contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, i18n){
message("Using i18n...")
HEADERS += $$AMOTUS_Qt_PATH/i18n.h
SOURCES += $$AMOTUS_Qt_PATH/i18n.cpp
include(i18n.pri)
}contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, Amotus_Qt_Network){
message("Using Amotus_Qt_Network...")
include(Amotus_Qt_Network.pri)
}
If I put AMOTUS_SUBREPOS_OPTIONAL_NAMES = i18n
The message print:
Project MESSAGE: list: 'i18n'
Project MESSAGE: Using i18n...
The message is correct. But I get both the i18n.pri and the 
Amotus_Qt_Network.pri include anyway!? if I remove the i18n entry from the 
variable AMOTUS_SUBREPOS_OPTIONAL_NAMES =
I get the following:
Project MESSAGE: list: ''
The include for i18n.pri and Amotus_Qt_Network.pri are still included, but the 
i18n.h and i18n.cpp are grey out which seem to work for HEADERS and SOURCES but 
not include!?! is include special or parsed without any consideration of the 
scope?! I did try to close QtCreator and reopen without luck (using QtCreator 
4.12.0 on Mac OS)

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] QMake contains and include

2020-05-20 Thread Jérôme Godbout
Hi,
QMAKE question: anybody manage to use an include inside a contains(){} into 
QMake? the include is processed no matter what!?!
message("list: '$$AMOTUS_SUBREPOS_OPTIONAL_NAMES' ")
contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, i18n){
message("Using i18n...")
HEADERS += $$AMOTUS_Qt_PATH/i18n.h
SOURCES += $$AMOTUS_Qt_PATH/i18n.cpp
include(i18n.pri)
}contains(AMOTUS_SUBREPOS_OPTIONAL_NAMES, Amotus_Qt_Network){
message("Using Amotus_Qt_Network...")
include(Amotus_Qt_Network.pri)
}
If I put AMOTUS_SUBREPOS_OPTIONAL_NAMES = i18n
The message print:
Project MESSAGE: list: 'i18n'
Project MESSAGE: Using i18n...
The message is correct. But I get both the i18n.pri and the 
Amotus_Qt_Network.pri include anyway!? if I remove the i18n entry from the 
variable AMOTUS_SUBREPOS_OPTIONAL_NAMES =
I get the following:
Project MESSAGE: list: ''
The include for i18n.pri and Amotus_Qt_Network.pri are still included, but the 
i18n.h and i18n.cpp are grey out which seem to work for HEADERS and SOURCES but 
not include!?! is include special or parsed without any consideration of the 
scope?! I did try to close QtCreator and reopen without luck (using QtCreator 
4.12.0 on Mac OS)

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] is it ok to push audio on a background thread, not a timer?

2020-05-20 Thread Jérôme Godbout
If you are looking for some explanation of the QThread and how to use them 
properly, here a few other links:

  1.  https://www.kdab.com/multithreading-with-qt/
  2.  http://blog.debao.me/2013/08/how-to-use-qthread-in-the-right-way-part-1/
  3.  http://blog.debao.me/2013/08/how-to-use-qthread-in-the-right-way-part-2/

The problems with QThread was the doc was lagging behind for a while (it's now 
fixed thanks to the people who updated it btw). Many people where using the 
QThread in a way that they where shooting themselves in the foot with the 
Thread affinity and the emit directly into the QThread object.
Since QThread is a QObject and it create the thread,  it doesn't itself reside 
into the created thread but in the thread that created the QThread object.

From: Interest  On Behalf Of David M. Cotter
Sent: May 19, 2020 7:11 PM
To: interest@qt-project.org
Subject: Re: [Interest] is it ok to push audio on a background thread, not a 
timer?

is it possible i'm just using QThread wrong?  and it HAPPENS to work fine on 
mac but fails on windows?

is this blogger really revealing the ONE TRUE NATURE of QThread:
https://mayaposch.wordpress.com/2011/11/01/how-to-really-truly-use-qthreads-the-full-explanation/

?

-dave


On May 19, 2020, at 4:05 PM, David M. Cotter 
mailto:d...@kjams.com>> wrote:

anybody have any other ideas?


On May 18, 2020, at 9:12 PM, David M. Cotter 
mailto:d...@kjams.com>> wrote:

Note that you do initialise the i_auP pointer in your constructor's 
initialisation list
which is not a QObject, it's my own wrapper class
Irrelevant what it derives from
then i'm not understanding what your objection is.

i thought your objection was that objects derived from QObject, if they are 
used on a back thread then they must be either allocated there or "moved" there.

but since this i_auP is NOT a QObject, it's my own class, that i'm fine to 
allocate it in one thread (main) and then use it on another thread (audio pump 
thread) (provided and assuming i am careful to mutex any access from the main 
thread)


Are you saying that this calls a function that returned null?
sorry, what is "this" and what function are you referring to that returns null?

if you mean GetCUnit_Out() it returns an object of my own (not a QObject) that 
has already been allocated and is guaranteed to not be NULL


I repeat my request for a compileable example.
i hear you loud and clear but let's assume that's not happening for now and see 
how far we get




___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Arduino TeensyLC USB serial CDC + Qt not working on Windows

2020-05-19 Thread Jérôme Godbout
Hi,
which driver is Windows 10 is using (take a look into the device manager). Also 
mayke sure no other services is using the COM port, check is busy with 
QSerialPortInfo before opening a serial port (it's obsolete but still useful 
for Windows). You can also list the availables port with it.

-Original Message-
From: Interest  On Behalf Of Henry Skoglund
Sent: May 18, 2020 7:03 PM
To: interest@qt-project.org
Subject: Re: [Interest] Arduino TeensyLC USB serial CDC + Qt not working on 
Windows

On 2020-05-19 00:52, Jason H wrote:
> The Teensy provides a virtual serial port via the USB Serial CDC. It works 
> great on OSX.
>
> I have a program where I wrote some code in Qt on my Mac.  My co-worker is 
> trying to run it on Windows 10.
> We expected to have to change the serial port name, which we did, to COM4. 
> Teensyduino IDE sees serial traffic from it on Windows.
> However, the program writes data to the teensy and expects it to reply back. 
> The program reports having written the data but no reply is received. The 
> Teensy is hooked to a contact switch and it's supposed to send a status 
> message when this happens. He can see characters in the teensy serial 
> terminal. But when we do it with Qt listening on the serial port, no 
> readyRead call back is called.
>
> Does anyone have any idea?
> It works perfectly on OSX.
>
Just guessing but perhaps some USB buffering is happening on Windows. If you 
press that contact switch multiple times (to overcome the USB buffer of 64 
bytes) do you see any bytes received in your Qt program?

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] PySide2 5.14.2 signal/slots changed

2020-04-02 Thread Jérôme Godbout
Just a follow up, the bug have been changed to P1 critical and reproduced and 
on some other use case too. Just heads up, if anybody is using pyside, you 
might want to hold before going to 5.14.2 until this get fix. 
https://bugreports.qt.io/browse/PYSIDE-1255


From: Jérôme Godbout 
Sent: April 1, 2020 11:58 AM
To: Jérôme Godbout ; interest@qt-project.org
Subject: RE: PySide2 5.14.2 signal/slots changed

A more complete example. also narrow the bug, if the parent is set to self 
before launching the object the signal no more reach it, work under 5.14.0, 
5.14.1 but not on 5.14.2. This is a show stopper for 5.14.2. I have open an 
issue:
https://bugreports.qt.io/browse/PYSIDE-1255


From: Interest 
mailto:interest-boun...@qt-project.org>> On 
Behalf Of Jérôme Godbout
Sent: April 1, 2020 11:21 AM
To: interest@qt-project.org<mailto:interest@qt-project.org>
Subject: [Interest] PySide2 5.14.2 signal/slots changed

Hi,
I was trying the signal/slots for a Python application, but with the new 
version I discovered that the signal is no more reaching my Qml anymore, 
reverting to 5.14.0 PySide2 fix the problem.

Python code:

from PySide2.QtCore import QObject, Signal

class BObj(QObject):
...

class AObj(QObject):
dataReceived = Signal(BObj)

def myFct(self):
toto = BObj(self)
print("before", flush=True) # print before and 
after on both version of PySide2 5.14.0 and 5.14.2
self.dataReceived.emit(toto)
print("after", flush=True)

Qml Code:

AObj
{
onDataReceived:
{
  console.log("Reach Qml"); // This print with PySide 5.14.0 
but not in 5.14.2
var b_obj = arguments[0]; // no named arguments from python, 
weird syntax lead to this
}
}

Is there any changes or this was not allowed??? or this is a bug into 5.14.2? 
(I could reproduce on Linxu and Windows. Is the signals syntax changes or 
something?

Jerome
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] PySide2 5.14.2 signal/slots changed

2020-04-01 Thread Jérôme Godbout
A more complete example. also narrow the bug, if the parent is set to self 
before launching the object the signal no more reach it, work under 5.14.0, 
5.14.1 but not on 5.14.2. This is a show stopper for 5.14.2. I have open an 
issue:
https://bugreports.qt.io/browse/PYSIDE-1255


From: Interest  On Behalf Of Jérôme Godbout
Sent: April 1, 2020 11:21 AM
To: interest@qt-project.org
Subject: [Interest] PySide2 5.14.2 signal/slots changed

Hi,
I was trying the signal/slots for a Python application, but with the new 
version I discovered that the signal is no more reaching my Qml anymore, 
reverting to 5.14.0 PySide2 fix the problem.

Python code:

from PySide2.QtCore import QObject, Signal

class BObj(QObject):
...

class AObj(QObject):
dataReceived = Signal(BObj)

def myFct(self):
toto = BObj(self)
print("before", flush=True) # print before and 
after on both version of PySide2 5.14.0 and 5.14.2
self.dataReceived.emit(toto)
print("after", flush=True)

Qml Code:

AObj
{
onDataReceived:
{
  console.log("Reach Qml"); // This print with PySide 5.14.0 
but not in 5.14.2
var b_obj = arguments[0]; // no named arguments from python, 
weird syntax lead to this
}
}

Is there any changes or this was not allowed??? or this is a bug into 5.14.2? 
(I could reproduce on Linxu and Windows. Is the signals syntax changes or 
something?

Jerome


test.tar.xz
Description: test.tar.xz
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] PySide2 5.14.2 signal/slots changed

2020-04-01 Thread Jérôme Godbout
Hi,
I was trying the signal/slots for a Python application, but with the new 
version I discovered that the signal is no more reaching my Qml anymore, 
reverting to 5.14.0 PySide2 fix the problem.

Python code:

from PySide2.QtCore import QObject, Signal

class BObj(QObject):
...

class AObj(QObject):
dataReceived = Signal(BObj)

def myFct(self):
toto = BObj(self)
print("before", flush=True) # print before and 
after on both version of PySide2 5.14.0 and 5.14.2
self.dataReceived.emit(toto)
print("after", flush=True)

Qml Code:

AObj
{
onDataReceived:
{
  console.log("Reach Qml"); // This print with PySide 5.14.0 
but not in 5.14.2
var b_obj = arguments[0]; // no named arguments from python, 
weird syntax lead to this
}
}

Is there any changes or this was not allowed??? or this is a bug into 5.14.2? 
(I could reproduce on Linxu and Windows. Is the signals syntax changes or 
something?

Jerome
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt Creator licensing for companies with Qt Commercial developers

2020-03-31 Thread Jérôme Godbout
Hi,
the mix is not a corner case, it’s the reality of many people around. We are a 
services compagnie, and this is really a headache to understand where it should 
fall since we do project for client but we are a single cie. The license of Qt 
have is such an ambiguity and our lawyer recommend (not even sure himself where 
we do fall) we avoid using it as much as we can given the context we are in. 
When a client have commercial license, we ask them to use their infrastructure 
and avoid having any commercial license on premise (we cannot take any chance). 
If you think your licensing is clear and make it easy, it ain’t, we do more and 
more Xamarin, just for license reason not because we like it.  I continue Qt 
mostly on hobby, really like Qml and where the binding in C++ is heading. But 
for my work job, Qt is fading out.

The departure between mixing LGPL and Commercial one is such a gray area, 
nobody want to venture anywhere there.

Note: I don’t speak in the name of my cie, but my own opinion here. Just 
stating the fact that the Qt license is the main reason we often ditch Qt for 
some application.


From: Interest  On Behalf Of Tuukka Turunen
Sent: March 31, 2020 10:33 AM
To: Andy 
Cc: interest@qt-project.org
Subject: Re: [Interest] Qt Creator licensing for companies with Qt Commercial 
developers

Hi Andy,

You are asking to explicitly define terms like project, company, product. These 
are rarely possible to define outside of the generic use of the term and each 
individual contract. I assume you understand that it is not possible to take 
any stand of those in an email. We have these listed in the FAQ and contracts 
in as clear way as we have been able to list these.

I have also tried to explain these, but your tone feels rather aggressive. I do 
not understand what makes you say: “Even a solo developer needs to hire a 
lawyer before touching anything Qt-related.” For most of the situation the 
licensing of Qt is really simple and also very permissive. Yes, there are 
certain complex corner cases, like mixing of commercial on open-source versions 
of the Qt framework/tools. But how often do you need to mix these? Most of the 
Qt users are using either the commercial or the open-source version.

Yours,

Tuukka

From: Andy mailto:asmalo...@gmail.com>>
Date: Tuesday 31. March 2020 at 16.47
To: Tuukka Turunen mailto:tuukka.turu...@qt.io>>
Cc: Giuseppe D'Angelo 
mailto:giuseppe.dang...@kdab.com>>, 
"interest@qt-project.org" 
mailto:interest@qt-project.org>>
Subject: Re: [Interest] Qt Creator licensing for companies with Qt Commercial 
developers

> "This is at the moment not listed as an allowed case..."

And this again is here the Qt company is digging it's own grave.

What constitutes a "product"? If a company has one team working on an open 
source library and another team using it in a proprietary application - what 
then? What if an internal tool uses some code or a library from proprietary 
application? What if...

Even a solo developer needs to hire a lawyer before touching anything 
Qt-related.

Once you start trying to codify all the different scenarios in your licensing, 
it becomes toxic and people will avoid it

---
Andy Maloney  //  https://asmaloney.com
twitter ~ @asmaloney



On Tue, Mar 31, 2020 at 9:36 AM Tuukka Turunen 
mailto:tuukka.turu...@qt.io>> wrote:

Hi,

The point of the "Prohibited combination" is to prevent a company or a chain of 
companies (like in a typical subcontracting scenario) from making part of the 
product with non-paid Qt and part with paid. Qt being as defined in the 
commercial license agreement, i.e. including tools and framework. This was what 
the person initiating this mail thread asked about. I do agree that it gets 
complex when one starts including items created by an independent third party. 
This is at the moment not listed as an allowed case, even though it is not 
something we specifically aimed to prevent.

Yours,

Tuukka

On 31.3.2020, 15.03, "Interest on behalf of Giuseppe D'Angelo via Interest" 
mailto:interest-boun...@qt-project.org> on 
behalf of interest@qt-project.org> wrote:

On 3/31/20 1:22 PM, Tuukka Turunen wrote:
> For completely independent projects/products this is fine. Note that 
these really should not be same or in practice the same - or in any way 
depending, relating, using etc each other as defined in the license agreement.
>
> See licensing FAQ question 2.7 
athttps://www.qt.io/faq/  and License agreement 
athttps://www.qt.io/terms-conditions/

It is still unclear if the usage of Qt _Creator_ for developing some
code would cause such code to fall under the restrictions of commercial
licensing.


Here's a few scenarios:

1) I have a Qt commercial license. In my project using commercial Qt I
want to use a 

Re: [Interest] Qt Creator licensing for companies with Qt Commercial developers

2020-03-27 Thread Jérôme Godbout
Hi,

is it just me or this is heading into the wrong way, or at least into the 
opposite direction of the market. Most IDE are now free, even the embedded 
world start giving IDE away:
 xCode is free
vs code is free
Atollic is free
STM32 TrueStudio is free
...

People are leaving pricy IDE behind, Keil anyone? less and less used. Starting 
to pay for an IDE like QtCreator, seem like you will only get less users toward 
Qt or people might be temped more and more to use VisualStudio as an IDE of 
choice.

This is my personnal point of view on the subject,
My 2 cents,

-Original Message-
From: Interest  On Behalf Of Tuukka Turunen
Sent: March 27, 2020 8:56 AM
To: Vyacheslav Lanovets ; interest@qt-project.org
Subject: Re: [Interest] Qt Creator licensing for companies with Qt Commercial 
developers


Hi,

Correct. All users need to have commercial license. It is not allowed for part 
of the team to use commercial and part use open-source. Even though Qt Creator 
is great, it can feel odd to pay for full Qt license and only use the Creator 
IDE. 

We have been thinking about selling Qt Creator separately, but so far no 
decisions made on this. 

Yours,

Tuukka

On 25.3.2020, 21.09, "Interest on behalf of Vyacheslav Lanovets" 
 wrote:

Hi,

Situation.

A company has a few developers with Qt Commercial subscription who
write applications in Qt for iOS.
There are many other developers, who work on other projects and don't
use Qt libraries.
They talk to each other and sometimes even work on the same code.

Is it still possible for the developers who don't use Qt libraries in
any way, use Qt Creator IDE for editing and debugging?
To be on the safe side, company plans to prohibit usage of Qt Creator
IDE for all employees.
I reckon this is a popular solution.
If I understand correctly, Qt even sells a special option to ban all
company IP addresses for open-source installer.

But is it really so?

Regards,
Vyacheslav
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Will Qt6 end this enum issue? (or even 5.15?)

2020-03-19 Thread Jérôme Godbout
I always put my Enum into C++, the sad part is that you need to create a dummy 
class to be exposeed to contain the enum. This make it possible to use the enum 
into Qml and C++. Enum from Qml are not super fun to be used. Can make function 
that convert the int value to the enum. Make an enum to string converter 
function too into C++. That will ease the tr() too.

-Original Message-
From: Interest  On Behalf Of Jason H
Sent: March 19, 2020 10:04 AM
To: interestqt-project.org ; Ulf Hermann 

Subject: [Interest] Will Qt6 end this enum issue? (or even 5.15?)

The enums in QML are expressed as ints when printed. 
console.log(camera.position) => 1 I work around this as:
property var positions: ["Unspecified", "BackFace", "FrontFace"]
onPositionChanged: console.log(positions[position]);

Or worse yet:
property var flashModes: {
  1: "FlashAuto",
  2: "FlashOff",
  4: "FlashOn",
  8: "FlashRedEyeReduction",
 16: "FlashFill",
 32: "FlashTorch",
 64: "FlashVideoLight",
128: "FlashSlowSyncFrontCurtain",
256: "FlashSlowSyncRearCurtain",
512: "FlashManual"
}

It seems that enums should be class with a value and label
console.log(camera.position.label) => "BackFace"
console.log(camera.position.value) => 1

Though I can understand if this might not be the preferred way. It's just I 
spend so much time doing this. I'm open to anything really
console.log(Camera.positionEnum(camera.position).label) == "BackFace"
console.log(Camera.positionEnum(camera.position).value) == 1 or
console.log(Qt.enum(camera.position).label) == "BackFace"
console.log(Qt.enum(camera.position).value) == 1

Also, in Qt I occasionally encounter enums that are not registered and cannot 
be used in QML without registering them myself. Will Qt registering all enums 
for use in QML be standard for Qt 6?



___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qml SpinBox Control 2 undo/redo

2020-03-18 Thread Jérôme Godbout
Yeah I end up with something similar:

import QtQuick 2.14
import QtQuick.Controls 2.14

SpinBox
{
id: component

signal undoRedoValues(int prev_value, int new_value)

// prepare values for undo/redo
property var previousValues: [0]
onValueChanged:
{
var prev = previousValues;
prev.push(value);
previousValues = prev.slice(-2);
}

onValueModified:
{
component.undoRedoValues(previousValues[0], value);
}
}


From: Furkan Uzumcu 
Sent: March 18, 2020 11:20 AM
To: interest@qt-project.org; Jérôme Godbout 
Subject: Re: [Interest] Qml SpinBox Control 2 undo/redo

Not very sophisticated but something like the following might work for you:


1 SpinBox {

2 id: spin

3

4 property var history: []

5 property bool _internalUpdate: false

6

7 from: 0

8 to: 100

9 onValueChanged: {

   10 if (!spin._internalUpdate) {

   11 spin.history.push(value)

   12 }

   13 }

   14 Component.onCompleted: {

   15 spin.history.push(value)

   16 }

   17 }

   18

   19 Button {

   20 text: <="" span="">

   21 onClicked: {

   22 if (spin.history.length > 0) {

   23 spin._internalUpdate = true

   24 spin.value = spin.history[

   25 Math.max(0, spin.history.length - 2)

   26 ]

   27 spin._internalUpdate = false

   28 if (spin.history.length > 1) {

   29 spin.history.splice(spin.history.length - 1, 1)

   30 }

   31 }

   32 }

Regards,
Furkan Üzümcü
On Mar 17, 2020, 16:26 -0400, Jérôme Godbout 
mailto:godbo...@amotus.ca>>, wrote:

Hi,
I’m trying to make an undo redo, I manage to have my whole thing working for 
user mouse drag n drop, add remove part into my model. One thing that bug me 
with the control 2 is the spinbox, the value is bind to the mode and the model 
get changed too, not sure this is the optimal way (I so wish we got 2 way 
binding like C# one day, this is so deeply needed and not have everybody 
reimplement there own way).

SpinBox
{
id: sequenceIndex_

value: opsModel.index

onValueChanged:
{
// This is called before value modified
}

onValueModified:
{
// The value is already modified, how can I get previous value to make 
my undo/redo ? seem too late and the value changed as already been called
}

Binding
{
target: ops_model
property: "index"
value: sequenceIndex_.value
}
}

How does one manage to do it with this control?! I guess I will have the same 
challenge with the ComboBox and all the selector controls (button are fairly 
easy since I can capture the previous value before doing the action).
___
Interest mailing list
Interest@qt-project.org<mailto:Interest@qt-project.org>
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


[Interest] Qml SpinBox Control 2 undo/redo

2020-03-17 Thread Jérôme Godbout
Hi,
I'm trying to make an undo redo, I manage to have my whole thing working for 
user mouse drag n drop, add remove part into my model. One thing that bug me 
with the control 2 is the spinbox, the value is bind to the mode and the model 
get changed too, not sure this is the optimal way (I so wish we got 2 way 
binding like C# one day, this is so deeply needed and not have everybody 
reimplement there own way).

SpinBox
{
id: sequenceIndex_

value: opsModel.index

onValueChanged:
{
// This is called before value modified
}

onValueModified:
{
// The value is already modified, how can I get previous value to make 
my undo/redo ? seem too late and the value changed as already been called
}

Binding
{
target: ops_model
property: "index"
value: sequenceIndex_.value
}
}

How does one manage to do it with this control?! I guess I will have the same 
challenge with the ComboBox and all the selector controls (button are fairly 
easy since I can capture the previous value before doing the action).
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Qt5 connect signal to signal

2020-03-10 Thread Jérôme Godbout
This should work, the default is connect type auto, which mean that it will be 
direct if both object (source and this in your example) have the same thread 
affinity. If both have a different thread affinity, the connection will be 
queued. Note, on queued signal, argument must be copiable and take care of 
QObject* that must survive and have the proper thread affinity if used. You can 
verify the QObject thread affinity with the following call:
https://doc.qt.io/qt-5/qobject.html#thread

queued connection if source->thread() != this->thread()
direct connection if source->thread() == this->thread()

You can also enforce the connection type, but normally auto is doing the right 
thing, unless you moveToThread() after the connection.


-Original Message-
From: Interest  On Behalf Of Hamish Moffatt
Sent: March 10, 2020 1:27 AM
To: interest@qt-project.org
Subject: [Interest] Qt5 connect signal to signal

In the old syntax one could:

connect(source, SIGNAL(readProgress(int)), SIGNAL(progress(int)));


In the new syntax, is it equivalent to use

connect(source, ::readProgress, this, ::progress);

... assuming that all of this is on a single thread?


I'm not quite clear what thread context the first is using when repeating the 
signal?


Hamish

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


Re: [Interest] Cross-platform local notifications?

2020-03-09 Thread Jérôme Godbout
What you describe look like a local notification (not pushed), for iOS
https://developer.apple.com/library/archive/documentation/NetworkingInternet/Conceptual/RemoteNotificationsPG/SchedulingandHandlingLocalNotifications.html


for Android you might want to take a look at NotificationCompat.Builder

https://developer.android.com/reference/android/support/v4/app/NotificationCompat.Builder

I don’t known if any Qt common layer is made for those!?


From: Interest  On Behalf Of Israel Brewster
Sent: March 9, 2020 4:22 PM
To: Interest 
Subject: [Interest] Cross-platform local notifications?

I’m writing a Qt C++ (not QML) app for iOS and android, and I need to be able 
to display a notification (such that would show up in Notification Center on 
iOS, not an alert box). How can I do this? My searches on google only find 
results for push notifications (this is all local) or maybe an implementation 
in QML.

---
Israel Brewster
Software Engineer
Alaska Volcano Observatory
Geophysical Institute - UAF
2156 Koyukuk Drive
Fairbanks AK 99775-7320
Work: 907-474-5172
cell:  907-328-9145

___
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest


  1   2   3   4   5   >