Skip to content

QML and Qt Quick

Looking for The Bling Thing(tm)? Post here!
20.0k Topics 77.3k Posts
  • Clickable places in QGraphicsSceen

    2
    0 Votes
    2 Posts
    800 Views
    SGaistS
    Hi, Please enclose your code in coding tags, otherwise it's extremely hard to read and people won't be motived to read the code to help you
  • Standard example: Texture in SGNode - Rendering FBOs

    4
    0 Votes
    4 Posts
    2k Views
    Q
    On ubuntu examples works well without modifications, but without shader programm one-thread example does not work. So, i use gDEBugger GL and found that after after qml drawing depth test enabled and some shader programm binded. So this helps me: @ QOpenGLFunctions_2_1 glf21; glf21.initializeOpenGLFunctions(); ..... glDisable(GL_DEPTH_TEST); glf21.glUseProgram(0);@
  • Problem with qml

    4
    0 Votes
    4 Posts
    1k Views
    sierdzioS
    The path is relative and you are doing a shadow build - it's almost certain that qml.qml is not in the folder the executable is placed in (in your case: file:///C:/Users/USER/Desktop/projectsQt/test 11/build-test1-Desktop_Qt_5_1_0_MinGW_32bit-Debug/).
  • Rounded Image Corners

    3
    0 Votes
    3 Posts
    2k Views
    P
    Hi Andre, thanks for your reply. However enabling clipping sadly did not solve the problem. This is the updated code: @import QtQuick 2.0 Image { id: background source: "../background.jpg" width: 360 height: 360 focus: true Rectangle { id: rectangle x: 30 y: 30 width: 300 height: 300 color: "#ffffff" radius: 20 border.width: 5 border.color: "#000000" clip: true Image { id: image width: 300 height: 300 source: "../example.jpg" } } } @ Do you have an idea how to fix this issue?
  • Invoke C++ method from QML with "parent" as QWidget does not seem to work

    1
    0 Votes
    1 Posts
    657 Views
    No one has replied
  • Why model data isn't exposed as properties of the delegate object?

    6
    0 Votes
    6 Posts
    2k Views
    F
    Need I request a feature on the bug tracker?
  • Import Qtquick 1.0 into Qt 4.7

    2
    0 Votes
    2 Posts
    769 Views
    sierdzioS
    What are those "Shapes"? Some custom library of yours? Edit: you can easily switch to Qt 4.8.5 and benefit from updates introduced in QtQuick 1.1.
  • QSqlQueryModel in a QML view causes items being shown twice

    1
    0 Votes
    1 Posts
    805 Views
    No one has replied
  • QQuickPaintedItem is not advised?

    12
    0 Votes
    12 Posts
    10k Views
    T
    [quote author="sierdzio" date="1375359070"]. Anyway, we are getting way off the topic :P[/quote] You're right, I just want qml Items could be created from C++ :) That would make life much easier.
  • TextEdit font rendering scaling problem in QtQuick 1.1

    1
    0 Votes
    1 Posts
    660 Views
    No one has replied
  • Qt5 Scene Graph custom geometry and gradients

    4
    0 Votes
    4 Posts
    1k Views
    U
    I don't really have an example as the code will highly depend on the kind of shape and gradient you are trying to achieve. The easiest way is to use QSGGeometry::ColoredPoint2D for your vertices data and to adjust their color and placement in such way that when color is interpolated between vertices in fragment shader you get your desired gradient. I don't know if this will be implemented in ready made materials in the future.
  • How to reload a qml changing contents.

    1
    0 Votes
    1 Posts
    848 Views
    No one has replied
  • I18N - Qt Quick5.0 - How to implement for user entered text string(s)

    1
    0 Votes
    1 Posts
    472 Views
    No one has replied
  • [Solved] Launch a child QML window from a parent QML window

    3
    0 Votes
    3 Posts
    31k Views
    G
    Thanks, it worked! I was inane enough to use "this" instead of the id of ApplicationWindow. I am curious though, as to how this could be implemented in QML + C++. Please guide me if you know that. Also, I want a value (access token, to be specific) back from the child window. How do you suggest I do that? My thought was to add a property to the child window: access_token, which I might access in the parent window before closing the child window. Do you have a better suggestion? [quote author="stevenceuppens" date="1375278713"]Hi Bhoot, you can try this, AuthorizationBrowser.qml @ import QtQuick 2.0 import QtQuick.Window 2.1 // needed for the Window component Window { width: 300 height: 200 Rectangle { anchors.fill: parent color: "lightGrey" Text { anchors.centerIn: parent text: "My New Window" } } } @ main.qml @ import QtQuick 2.0 Rectangle { id: root width: 360 height: 360 property variant win; // you can hold this as a reference.. Text { text: "Click here to open new window!" anchors.centerIn: parent } MouseArea { anchors.fill: parent onClicked: { var component = Qt.createComponent("AuthorizationBrowser.qml"); win = component.createObject(root); win.show(); } } } @[/quote]
  • How to display errors for Loader?

    2
    0 Votes
    2 Posts
    792 Views
    sierdzioS
    You need to anchor your Text element. Also, make sure Loader is working as you expect with: @ id: view // ... onStatusChanged: { console.log("Loader status changed to " + status); } @
  • [SOLVED] QtQuick Controls 1.0 Designer style and actual style

    3
    0 Votes
    3 Posts
    1k Views
    sierdzioS
    Nice catch! Thank you for sharing the solution :)
  • C++ model (QAbstractItemModel) with Qt Quick view?

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • [SOLVED] Referencing neighbouring QML types from QML file

    3
    0 Votes
    3 Posts
    999 Views
    T
    As per my comment on the bug page. My mistake. Simply missing an initial '/'.
  • [solved]using inpaint of opencv in qt

    4
    0 Votes
    4 Posts
    3k Views
    S
    If you are on windows and using the g++ come with Qt, you need to recompile the openCV by yourself.
  • Javascript trans data to qml have problems

    2
    0 Votes
    2 Posts
    933 Views
    S
    I use a way to solve this problem, use result as a parameter in getCurweatherInfo(cityName, result),it can be ok. PS: it seemed very silly,because I am a javascript and qml freshman.