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

2021-06-04 Thread Juergen Bocklage-Ryannel
Hi,

My 2 cents: I might not a good idea to name the document “MenuBar.qml" and use 
a “MenuBar" component inside. Not sure but could give naming conflicts, if the 
MenuBar component is resolved to the local “MenuBar.qml" document.

So rename your MenuBar.qml to Main.qml, update the code and try again.

Why not in python? I expect the local file url changes the lookup behaviour.

/ jryannel

https://apigear.io



> On 4. Jun 2021, at 16:59, Jérôme Godbout  wrote:
> 
> 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  > 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 

Re: [Interest] Qt Creator licensing for companies with Qt Commercial developers

2020-03-30 Thread Juergen Bocklage-Ryannel
Hi,

I guess the conflicting terms are these:

“Prohibited Combination” shall mean any means to (i) use, combine, incorporate, 
link or integrate Licensed Software with any software created with or 
incorporating Open Source Qt, (ii) use Licensed Software for creation of any 
software created with or incorporating Open Source Qt, or (iii) incorporate or 
integrate Applications into a hardware device or product other than a Device."

Especially this combination: “use … Licensed Software with any software created 
with … Open Source Qt”

KDE, doxygen, Wireshark (just to name a few) are using Open Source Qt. 

Can someone reflect how does it apply to that software? Can a customer use them 
to create software under the Qt commercial License terms?

I understand the wishes of Qt Company. Business wise these make sense, still 
there might be a conflict with other Licenses (especially Qt Creator Open 
Source). I am unsure if the Qt Commercial License is in direct conflict with 
(L)GPL license. But I guess someone has thought this through.

Best regards
/ jryannel

I am not a lawyer and any opinion towards Licensing is my personal very 
subjective opinion.



> On 30. Mar 2020, at 20:02, Tuukka Turunen  wrote:
> 
>  
> Hi Andy,
>  
> I know that the dual licensing can be confusing. To defend it a bit: it gets 
> confusing mainly when the question is about mixing the license types. It is 
> simple and straightforward when a company uses commercial license and asks 
> also possible contractors (working in the same project) to use commercial. 
> Similarly it is simple when all use the open-source version.
>  
> If you want to understand the topic better, please read the commercial 
> license agreement and the licensing FAQ. The restriction has nothing to do 
> with open-source licensing. It is about a company, who is using a 
> commercially licensed Qt not to use parts of the same licensed Qt product 
> under open-source license. If there was no such restriction, a company could 
> have a team of 10 developers, but only 1 or 2 commercial license for Qt.
>  
> I do understand that it can feel off to have such a restriction for using "Qt 
> Creator" when others are using "Qt libraries". The important point is that 
> both these are included in the Qt for Application Development product. So 
> both need to be used with same type of license: open-source or commercial. 
>  
> Yours,
> Tuukka
>  
>  
> From: Andy 
> Date: Monday 30. March 2020 at 20.50
> To: Tuukka Turunen 
> Cc: Giuseppe D'Angelo , "interest@qt-project.org" 
> 
> Subject: Re: [Interest] Qt Creator licensing for companies with Qt Commercial 
> developers
>  
> That makes no sense. Your license prevents a company from using an 
> open-source tool? It says "if you license our stuff you cannot use the 
> open-source tool X"?
>  
> This whole thread is yet another great example of where the Qt Company is 
> totally tone-deaf.
>  
> Nobody understands your licensing. You have fewer people using Qt and 
> Qt-based things because of this.
>  
> ---
> Andy Maloney  //  https://asmaloney.com 
> twitter ~ @asmaloney 
>  
>  
>  
> On Mon, Mar 30, 2020 at 1:43 PM Tuukka Turunen  > wrote:
>>  
>> Hi,
>>  
>> That is not the question that was originally asked. 
>>  
>> The question was about some developers using commercially licensed “Qt for 
>> Application Development” product and other developers using Qt Creator under 
>> open-source license. This is not allowed, because the license agreement of 
>> Qt for Application Development does not allow use of open-source versions of 
>> its contents in the same project (and Qt Creator is part of Qt for 
>> Application Development).
>>  
>> Yours,
>>  
>> Tuukka
>>  
>> From: Andy mailto:asmalo...@gmail.com>>
>> Date: Friday 27. March 2020 at 17.29
>> To: Tuukka Turunen mailto:tuukka.turu...@qt.io>>
>> Cc: Giuseppe D'Angelo > >, "interest@qt-project.org 
>> " > >
>> Subject: Re: [Interest] Qt Creator licensing for companies with Qt 
>> Commercial developers
>>  
>> "This seems to become a longer thread than I envisioned, as apparently my 
>> original response was not clear enough."
>>  
>> As I pointed out - it's because you're not answering the question that was 
>> asked, and therefore confusing the issue.
>>  
>> "Is it still possible for the developers who don't use Qt libraries in any 
>> way, use Qt Creator IDE for editing and debugging?"
>>  
>> The answer is yes.
>>  
>> ---
>> Andy Maloney  //  https://asmaloney.com 
>> twitter ~ @asmaloney 
>>  
>>  
>>  
>> On Fri, Mar 27, 2020 at 11:23 AM Tuukka Turunen > > wrote:
>>> 
>>> Hi,
>>> 
>>> This seems to become a longer thread than I envisioned, as apparently my 
>>> 

Re: [Interest] Belligerent QML ListView

2015-03-31 Thread Juergen Bocklage-Ryannel
Hi,

Maybe you want to provide a small example to the reader so that he can 
examine your thoughts and point you to a possible mistake. All people 
here love to see code snippets.

You could use https://gist.github.com to help the reader to inspect your 
example. The example should be small and focused on the problem you try 
to solve and not taken from a large code base, which just confuses the 
reader.

My normal try is to create a QtQuick UI in Qt Creator with a minimal 
source code to showcase the problem.

/ jryannel



On 27/03/15 23:19, Jason H wrote:
 I want to do a simple pop-up, centered on screen.
 Rectangle {
 Row (centered){
 [Title]
 [ListView
 ...
 ...
 ...
 ...]
 [Ok]
 } //row
 } //Rect
 However I can't get this to layout right.  The ListView width does not 
 evaluate to anything but 0. This results in the ListView delegates starting 
 at the center of the screen and no Rectangle (width evals to zero)

 How can I get ListView width and height to be the content height and width to 
 be the max width and actual height of using the actual of actual delegate 
 data?

 Thanks.
 ___
 Interest mailing list
 Interest@qt-project.org
 http://lists.qt-project.org/mailman/listinfo/interest


-- 
/ jryannel
http://qmlbook.org
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Can QML do this animation?

2015-03-24 Thread Juergen Bocklage-Ryannel
Hi,

First of all. Thanks for the great example. Love it!

I'm the author of the QmlBook (qmlbook.org). I would maybe like to use 
the example in the book if this would be okay with you. The example 
would be licensed under the BSD and the text would be copyrighted to the 
authors of the book, the book is under the CC license. I would reference 
your name on the example and the text.

Please let me know if this is okay with you. I would imagine this would 
be a good place under Advanced Techniques:

http://qmlbook.github.io/en/ch05/index.html#advanced-techniques

If i find some time I maybe even can finish it with the draining.


Take care
/ juergen



On 27/02/15 16:12, Arthur Buldauskas wrote:
 Wow, that's amazing! Thank you very much for doing this.
 It sure is quite a lot of QML code for something that looks so
 simple (and cool).
 Just curious about two things:
 1. Is there any reason why you mailed it me directly and not the
 mailing list? I think others would like this as well.
 2. Under what license do you release this? I don't have any direct
 plans to use it, but i probably will use parts of it in some
 projects (like my file manager, Accretion, where i would probably
 use this as a copy progressbar).
 Best regards,
 Mark

 Btw. disabling the line:
 rotation: indicator.rotation;
 makes it look even better :)
 The text now actually rotates with the indicator.

 My bad, forgot to reply all. Feel free to use the code, I just made this
 as a fun exercise. It could be a lot cleaner and probably smoother. A
 lot of the code is just making sure the indicator animates properly.
 http://pastebin.com/cwCPChLk


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


-- 
/ jryannel
http://qmlbook.org
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] QML Equivalent of QCustomplot

2015-03-24 Thread Juergen Bocklage-Ryannel
http://jwintz.me/blog/2014/02/15/qchart-dot-js-qml-binding-for-chart-dot-js/


On 04/03/15 17:40, Ramakanthreddy Kesireddy wrote:
 Hi,


 Please let me know if  there is any QML Equivalent of QCustomplot for
 plotting and data visualization?


 Thanks and Regards,

 Ramakanth

 
 
 Disclaimer: This message and the information contained herein is
 proprietary and confidential and subject to the Tech Mahindra policy
 statement, you may review the policy at
 http://www.techmahindra.com/Disclaimer.html externally
 http://tim.techmahindra.com/tim/disclaimer.html internally within
 TechMahindra.
 



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


-- 
/ jryannel
http://qmlbook.org
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] Qt support for WebSocket Subprotocol

2015-01-12 Thread Juergen Bocklage-Ryannel
Hi All,

I try to implement the wamp.ws (http://wamp.ws) websocket protocol, 
which would allow instances of Qt to talk to any WAMP backend.

For this Qt websockets ideally would support the subprotocol 
non-normative standard
(https://tools.ietf.org/html/rfc6455#page-12), which is currently not 
suported (http://doc.qt.io/qt-5/qwebsocket.html).

There seems to be also an initial not exposed implementation 
(https://qt.gitorious.org/qt/qtwebsockets/commit/88de191cfbde67fffedad211317afad0ff3cee3c)
 
in the Qt websockets.

Also there is a bug entry on qt.io 
(https://bugreports.qt.io/browse/QTBUG-38742).

I would like to

a) to ask people to vote for the feature if they feel it is interesting 
for them.

b) understand why subprotocols are not supported




Thanks for helping out. Take care and a nice day
-- 
/ jryannel
http://qmlbook.org
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Json support for Qt5 QML - code review needed

2014-04-06 Thread Juergen Bocklage-Ryannel
Hi,

Sounds great. I can have a look if it is okay for you. Do you plan to 
upstream it or would you like to keep it as an external module? Can you 
send me the repo url?

/ jryannel
http://qmlbook.org


On 05/04/14 15:30, Jay Sprenkle wrote:
 Good morning,

 I'm looking for a code review for an open source project.

 I've implemented Json support for use with Qt5 QML. It's in several parts.

   * A C++ version of JsonPath. If you've used XPath then this should be
 familiar. JsonPath is XPath for JSON. QJsonPath allows selecting
 arbitrary subsets of a json object given a search string.
   * A QML item to translate a JSON string, apply JsonPath and provide a
 Qt QJsonDocument.
   * A QML item to take a QJsonDocument and provide a Qt list model that
 you can use with Qt's standard control ListView.


 Used together you can request data from an arbitrary web service (or
 file), pull out a subset, and display it using the Qt controls.

 The code works but I think someone with better knowledge of Qt's
 model/view system could help make it better. Any takers?

 Thanks

 Jay


 --
 --
 Psychiatrist to patient: Don't worry. You're not deluded. You only
 think you are.
 /
 /



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

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


Re: [Interest] Caching of compiled/initialized qml code to disk possible?

2014-01-15 Thread Juergen Bocklage-Ryannel

Hi,

We are currently working on a project where we cache all screens on 
start-up, by using
Qt.createComponent(url). By this the major components are parsed and 
cached on start-up. It has also a second benefit, it verifies your 
components on syntax error on start-up.


For my knowledge the Loader element will try to load the component later 
and will hit the cache (as the URL is the same).


Actually we go even a step further to create a large registry of all 
application screens so we can call the screens by the registered name 
and not the component url.


/ jryannel


On 15.01.14 15:26, Ola Røer Thorsen wrote:

Hi all,

I have an application written with Qt 5.2 in C++ and QtQuick2, running 
on a low-end ARM device. I use the Loader item to select between 
various screens in the application (I've currently got 6 screens or 
so). This way I can limit the amount of active bindings at a given 
time, etc.


The first time I enter a new screen, there is a very noticeable delay 
(1-2 seconds), as the new items are compiled. The next time I enter 
the same screen, the delay is much shorter. So I guess some things 
have been cached in memory.


Would it be possible to cache this on disk, to prevent this from 
happening every single time the application is started? I'm asking for 
something pretty similar to Python's .pyc files.


Is it possible, or would it be possible in some future version of Qt?

Cheers,
Ola





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


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


Re: [Interest] Qt laptop stickers

2014-01-14 Thread Juergen Bocklage-Ryannel

I will stop by and bring a beer:-)

What about using a service like (http://www.zazzle.com/google+gifts), so 
that the community could order them and create additional marketing for 
Qt and DIGIA.


Maybe also a contest for best designed merchandise. Not sure if this is 
possible.


/ juergen

On 14.01.14 12:28, Turunen Tuukka wrote:


I can post you some, email me your postal address.

For wide scale availability, it is preferred to stop by the Qt booth 
in some event, for example DevDays.


Yours,

Tuukka
*From: *Curtis Mitch
*Sent: *tiistaina 14. tammikuuta 2014 13.17
*To: *Bob Hood; Juergen Bocklage-Ryannel; interest@qt-project.org; 
Turunen Tuukka

*Subject: *Re: [Interest] Qt laptop stickers


Tuukka? :)

On 01/13/2014 04:55 PM, Bob Hood wrote:

 On 1/13/2014 6:57 AM, Juergen Bocklage-Ryannel wrote:
 On 07.01.14 05:51, Николай Шатохин wrote:
 Hello.

 Does anyone have a Qt laptop stickers? Can you sell me some?

 Best regards,
 Nick


 ___
 Interest mailing list
 Interest@qt-project.org
 http://lists.qt-project.org/mailman/listinfo/interest
 Hmm,

 I think I went out of them. At least haven't seen them for a while.

 If a DIGIA person is listening. Would be great to have some general
 merchandising of Qt. E.g. Qt shirts, Qt mugs, Qt stickers, Qt-Teddy,
 Qt-Mousepad, etc... There should be some companies around which offer
 these kind of merchandise-services. DIGIA owns the copyright to the
 Qt-logo and trademark, as far as I know.

 / juergen


 I'm pretty sure there was merchandising when Nokia owned Qt.  I still
 have my (really rather cool) Qt pen, which I think I picked up at a past
 SIGGRAPH, that has the qt.nokia.com URL on it.

 I would agree:  It would be nice to have some product merchandising
 (pens, mouse pads, stickers, etc.) to be able to show our pride in this
 fantastic product.


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



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


Re: [Interest] Qt laptop stickers

2014-01-13 Thread Juergen Bocklage-Ryannel

On 07.01.14 05:51, ??? ??? wrote:

Hello.

Does anyone have a Qt laptop stickers? Can you sell me some?

Best regards,
Nick


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

Hmm,

I think I went out of them. At least haven't seen them for a while.

If a DIGIA person is listening. Would be great to have some general 
merchandising of Qt. E.g. Qt shirts, Qt mugs, Qt stickers, Qt-Teddy, 
Qt-Mousepad, etc... There should be some companies around which offer 
these kind of merchandise-services. DIGIA owns the copyright to the 
Qt-logo and trademark, as far as I know.


/ juergen
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest