Skip to content
  • 1 Votes
    11 Posts
    1k Views
    D

    @J-Hilk Thanks for the reply. This adds a bit of complexity to my WIX installer since I don't want to list all 700+ files individually. Do you know if there is anyway to deploy these files in a folder other than where the executable is located? I would like to dump all of the QT dependencies in one folder (which can have subfolders) but I need to be able to "blow away" all of the Qt related dependencies by deleting one directory while being confident that I didn't delete anything but Qt dependencies.

  • 0 Votes
    4 Posts
    562 Views
    kshegunovK

    @ItzMeJP said in Is it possible to embbed a 3dscene in qml Pane (Qt.QuickControl) type?:

    thank you, but it still crash my application.

    What crash? You never said anything about a crash ...

    Is there any problem regarding my main.cpp code?

    Not that I can see.

  • 0 Votes
    2 Posts
    2k Views
    F

    @raphasauer I have the same issue. Could you solve it?

  • 0 Votes
    5 Posts
    1k Views
    M

    I think that I found my answer

    https://wiki.qt.io/Qt_6.0.0_Modules

    Not supported.

    7fb19ebb-b687-401d-ada4-2a18e374bf8b-image.png

    Thanks for help. I guess I will have to try to rollback.
    I wanted to write a small simple app for (for now) my own use, but the functionalities seem to be pretty restricted on Qt 6.0 then...

  • 1 Votes
    2 Posts
    1k Views
    Q

    @raphasauer
    I also have this issue . creator 6.0.2, when open qml with designer, it said QtQuick2.15 not installed

  • QtQuick TreeView

    Solved Qt 6
    5
    0 Votes
    5 Posts
    690 Views
    S

    @0-5 Could you please share your backport (on github or similar?) Did it work well?

  • 0 Votes
    6 Posts
    7k Views
    C

    Thanks, it worked with C++ by adding below line
    in project.pro, unfortunately python project don't create this file.
    But incase anyone else has a python workaround please share.

    QT += core5compat
  • 0 Votes
    2 Posts
    548 Views
    jeanmilostJ

    So as nobody answered this question, I found a workaround which seems to resolve my issue. I changed the stroke width from 1 to 1.5. However this unfortunately doesn't explain what happened here, and why the ShapePath object behaves this way. I have my own idea about that: I think it's a kind of pen alignment, as in GDI+ (https://docs.microsoft.com/en-us/windows/win32/api/gdiplusenums/ne-gdiplusenums-penalignment), however I found absolutely no way to configure that.

    So below is my solution, which works correctly in all situations on my side:

    import QtQuick 2.15 import QtQuick.Window 2.15 import QtQuick.Controls 2.15 import QtQuick.Shapes 1.15 import QtGraphicalEffects 1.15 import QtQuick.Templates 2.15 as T /** * Dashed border *@author JMR */ T.Control { // advanced properties property real m_StrokeWidth: 1.5 property int m_Radius: 5 property string m_FillColor: "transparent" property string m_StrokeColor: "#bac1db" /** * Background rectangle */ Rectangle { // common properties anchors.fill: parent color: m_FillColor radius: m_Radius /** * Dashed outline shape */ Shape { // common properties id: shDashedBorder anchors.fill: parent anchors.margins: 0 //layer.enabled: true //layer.samples: 8 smooth: true clip: true /** * Dashed outline shape path */ ShapePath { // common properties fillColor: "transparent" strokeColor: m_StrokeColor strokeWidth: m_StrokeWidth strokeStyle: ShapePath.DashLine dashPattern: [5, 5] startX: m_Radius startY: 0 // path commands PathLine {x: shDashedBorder.width - m_Radius; y: 0;} PathQuad {x: shDashedBorder.width; y: m_Radius; controlX: shDashedBorder.width; controlY: 0;} PathLine {x: shDashedBorder.width; y: shDashedBorder.height - m_Radius;} PathQuad {x: shDashedBorder.width - m_Radius; y: shDashedBorder.height; controlX: shDashedBorder.width; controlY: shDashedBorder.height;} PathLine {x: m_Radius; y: shDashedBorder.height;} PathQuad {x: 0; y: shDashedBorder.height - m_Radius; controlX: 0; controlY: shDashedBorder.height;} PathLine {x: 0; y: m_Radius;} PathQuad {x: m_Radius; y: 0; controlX: 0; controlY: 0;} } } } }
  • 0 Votes
    2 Posts
    369 Views
    B

    @tague Are you currently updating every time a point is added? If so, I wondered if you could buffer the incoming data so that you do not update so frequently? Perhaps use a QTimer to control update frequency.

  • 0 Votes
    5 Posts
    5k Views
    B

    Thanks every one for your reply. @fcarney The ColorOverlay is working fine for me. Thanks for the same.

  • 0 Votes
    2 Posts
    577 Views
    O

    @SourceSlayer Did you figure out some solution for this ? I'm in need to the same thing.

  • 0 Votes
    1 Posts
    604 Views
    No one has replied
  • 0 Votes
    2 Posts
    1k Views
    T

    I've developed a hackish workaround - if you're frustrated by this issue too, this "fix" is ugly but might help in the short-term:

    I noticed that Qt Creator still recognizes the old qmlRegisterType function calls if they're invoked from main in a project. So naturally, I made a custom compiler step for qmake that generates a header file with all QML_ELEMENT-tagged classes registered in a function.

    First, make sure you've set up qmltypes in your project as usual - your QML_IMPORT_NAME and all that is set.

    Add to the bottom of MyProject.pro:

    type_registrar_unfucker.name = type_registrar_unfucker type_registrar_unfucker.input = TYPE_REGISTRAR_SOURCES type_registrar_unfucker.commands = python3 $$PWD/type_unfuck.py ${QMAKE_FILE_IN} ${QMAKE_FILE_OUT} $$QML_IMPORT_NAME $$QML_IMPORT_MAJOR_VERSION type_registrar_unfucker.output = ${QMAKE_FILE_IN_BASE}.h type_registrar_unfucker.clean = ${QMAKE_FILE_IN_BASE}.h type_registrar_unfucker.variable_out = HEADERS QMAKE_EXTRA_COMPILERS += type_registrar_unfucker TYPE_REGISTRAR_SOURCES += $$OUT_PWD/myproject_metatypes.json

    Add as type_unfuck.py in your source directory:

    # type unfuck # ----------- # This python script deals with the issue of Qt Creator not being able to recognize element types # registered using 'QML_ELEMENT'. # # It does so by generating a header, 'myprojectname_metatypes.h'. # Include this header ONLY in main.cpp, and then call `registerTypes()` first thing in `main`. # Then, Qt Creator will stop whining. import sys import json source_path = sys.argv[1] dest_path = sys.argv[2] import_name = sys.argv[3] import_major = sys.argv[4] with open(source_path) as f: data = json.load(f) includes = ["QtQml"] types = [] for file in data: includes.append(file["inputFile"]) for type in file["classes"]: if "classInfos" in type and {"name":"QML.Element","value":"auto"} in type["classInfos"]: types.append(type["className"]) with open(dest_path, 'w') as f: for i in includes: f.write(f'#include <{i}>\n') f.write('void registerTypes() {\n') for t in types: f.write(f'\tqmlRegisterType<{t}>("{import_name}", {import_major}, 0, "{t}");\n') f.write('}\n')

    Then, just add #include <myproject_metatypes.h> to your project's main.cpp and invoke registerTypes(); immediately in your main function. Build your project, then click on Tools -> QML/JS -> Reset Code Model, and Qt Creator should now recognize your custom components correctly.

  • 0 Votes
    1 Posts
    290 Views
    No one has replied
  • 1 Votes
    7 Posts
    787 Views
    SGaistS

    Or you can fix the macdeployqt code and build it to replace your version. That way you benefit from all the file processing done during the deployment process.

  • 0 Votes
    1 Posts
    171 Views
    No one has replied
  • 0 Votes
    1 Posts
    501 Views
    No one has replied
  • 0 Votes
    1 Posts
    624 Views
    No one has replied