Skip to content

QML and Qt Quick

Looking for The Bling Thing(tm)? Post here!
20.1k Topics 77.6k Posts
  • Using raw OpenGL in QQuickItem?

    3
    0 Votes
    3 Posts
    4k Views
    A
    [quote author="z.emb" date="1360759775"]http://qt-project.org/forums/viewthread/21396/#114311 doesn't help you at all? In my thread mentioned above is also a link to the "Ogre":http://qt.gitorious.org/qt-labs/qmlogre implementation which does basically the same thing.[/quote] Thank you, it helped me, but... not enough.
  • Dynamically resizing of QML scenes

    7
    0 Votes
    7 Posts
    4k Views
    ?
    Hi mbrier, Did you tried QQuickView::setResizeMode(QQuickView::SizeRootObjectToView) in your main program. It takes care of the resolution in a better way. Regards Ansif
  • [Solved] Item::mapToItem(): wrong returned values

    9
    0 Votes
    9 Posts
    10k Views
    ?
    Good luck!!!!!!!!!
  • Undefined reference to `_imp___ZN7CxImageC1Ej'

    17
    0 Votes
    17 Posts
    7k Views
    M
    Guys I have been just told that I need to use the version of the compiler that will be compatible with both Windows and Linux, which is MinGW but 4.4 version, the one I've started using at the beginning. Please help me guys.
  • Data file

    14
    0 Votes
    14 Posts
    4k Views
    T
    Qt and/or QML is not using Java.
  • Display here maps in qml + webview (QtWebKit 3.0)

    1
    0 Votes
    1 Posts
    984 Views
    No one has replied
  • [SOLVED] QtQuick-Plugin - get QmlViewer object

    3
    0 Votes
    3 Posts
    2k Views
    S
    When I said QmlViewer I meant the Qt qmlviewer.exe. So you solved my problem. The thing is, is have an application which loads n instances of the qml viewer as an DLL. My QtQuick item has an static List which collects the pointers of all created elements of this type. And with the QGraphicsItem::scene () mehod I can find out, which elements are on the same qml viewer page. :)
  • Manipulating a model inside a ListView with Javascript

    3
    0 Votes
    3 Posts
    3k Views
    T
    Thanks very much for your reply :)! I guess you are refering to the following: @ ListView { id: storageListView model: storageModel } ListModel { id: storageModel ListElement { name: "Apple" cost: 2.45 show: true } ListElement { name: "Orange" cost: 3.25 show: true } ListElement { name: "Banana" cost: 1.95 show: true } } @ storageModel.remove(listView.currentIndex) => This would work in order to remove the element. But storageModel (which is an id not a reference) is given to ListView with a property binding: @ model: storageModel @ This means that if I manipulate storageModel it will emit a change which will lead to the reevaluation of the model property binding and the storageModel will be copied over to the model property of listView. QML isn't working with references here (one could say unfortunatly but it has advantages as well ;)). Then as I said: It is important to me to manipulate the model inside of ListView and not manipulating my model outside of listView and the setting it new. Which is what I described above. The reason is that If I the model updates and is copied over to the ListView model there will be a refresh to the listView. The listView positions itself at index 0 and then back to currentIndex. But the currentIndex Element will e.g. not be in the middle of listView but at the bottom afterwards. But thanks again for taking the time to reply. Tobias
  • [Cosed/Duplicate] QtWebView + D3 Javascript Visualization Library

    Locked
    3
    0 Votes
    3 Posts
    4k Views
    M
    Since it's already been reposted there, I'll close this thread. So you'll know next time, quantumavatar, a moderator can move thread for you if need be.
  • How to create a TransparentWindow, using Qt5, with QtQuick1

    3
    0 Votes
    3 Posts
    2k Views
    D
    What is we use QGLWidget as viewport. It will be failed
  • [Qt5] How to make a QQuickView TranslucentBackground?

    8
    0 Votes
    8 Posts
    9k Views
    D
    Interesting, what we have now?
  • Custom button bug

    3
    0 Votes
    3 Posts
    1k Views
    G
    I think binding function call to a text property is ok, like any expression. Problem is that containsMouse is not updated when MouseArea is disabled and enabled again. There is a simpler program to show this. @import QtQuick 1.1 Item { width: 300; height: 200 focus: true MouseArea { id: mouseArea anchors.fill: parent hoverEnabled: true } Text { text: "enabled: " + mouseArea.enabled + "; containsMouse: " + mouseArea.containsMouse } Keys.onDigit1Pressed: mouseArea.enabled = !mouseArea.enabled }@ If move mouse to window, disable mouse area by pressing 1, then move mouse from window and enable mouse area by pressing 1 again, it shows that containsMouse stays true.
  • Qml QtDesktop and a custom GLWidget.

    5
    0 Votes
    5 Posts
    2k Views
    M
    I have successfully created a project that merges both but the open gl is not being displayed to the window? "WIP":https://www.dropbox.com/s/2n813f6uu14g4d9/ApplicationTemplate.zip EDIT: I think it has something to do with QTDesktop redrawing over our window
  • How to force listview to draw all items?

    1
    0 Votes
    1 Posts
    958 Views
    No one has replied
  • Shader Effect meets Marquee [SOLVED]

    2
    0 Votes
    2 Posts
    2k Views
    W
    Ok I managed to solve the issue: define the Item element with the Text element inside define the ShaderEffectSource pointing to the Item and set hideSource to true so that the actual Item doesn't show define the ShaderEffect which uses the ShaderEffectSource (and with it the Text element) in the ShaderEffect, set a scrolling animation for the Item/Text element to slide horizontally and set the traditional animation for the shader (wobbly edges for the letters) encapsulate the ShaderEffect in a rectangle with clip:true, shorter width and transparent color Result: the encapsulated rectangle shows sliding text inside, which is being animated with shaders for the wobbly effect. I managed to get there by using one of the examples: /Qt5/Qt5.0.0/5.0.0/Src/qtdeclarative/examples/quick/shadereffects The example shows a grid 3x2 with shader examples and the 1x1 element drags with the mouse to rotate between the Text "Qt" or the images of the Qt Logo and a Smiley Face - the mouse drag and box clipping were the elements to get me there! @ import QtQuick 2.0 import "content" Rectangle { id: root width: 1280 height: 600 Image { anchors.fill: parent source: "content/bg.jpg" } //! [source] ShaderEffectSource { id: theSource sourceItem: theItem hideSource: true } //! [source] Item { id: theItem width: 3000 height: 160 Text { width: 3000 height: 140 horizontalAlignment: Text.AlignHCenter verticalAlignment: Text.AlignVCenter font.pixelSize: 120 font.family: "Times" color: "blue" text: "1234567890 abcdefghijklmnopqrstuvwxyz ABCDEF" } } Rectangle { id: marquee clip:true width: 400 height: 140 anchors.centerIn: parent color: "transparent" ShaderEffect { id: teste width: 3000 height: 160 property variant source: theSource property real amplitude: 0.04 * wobbleSlider.value property real frequency: 20 property real time: 0 NumberAnimation on time { loops: Animation.Infinite; from: 0; to: Math.PI * 2; duration: 600 } PropertyAnimation on x {running: true; loops: Animation.Infinite; from: marquee.width; to: -teste.width; duration: 100000; } //! [fragment] fragmentShader: "uniform lowp float qt_Opacity;" + "uniform highp float amplitude;" + "uniform highp float frequency;" + "uniform highp float time;" + "uniform sampler2D source;" + "varying highp vec2 qt_TexCoord0;" + "void main() {" + " highp vec2 p = sin(time + frequency * qt_TexCoord0);" + " gl_FragColor = texture2D(source, qt_TexCoord0 + amplitude * vec2(p.y, -p.x)) * qt_Opacity;" + "}" //! [fragment] Slider { id: wobbleSlider anchors.left: parent.left anchors.right: parent.right anchors.bottom: parent.bottom height: 40 } } } } @
  • QLabel to stretch with text

    4
    0 Votes
    4 Posts
    3k Views
    J
    You do not really provide enough context to solve the issue. QLabel should never be used inside a qt quick Item. If you are indeed trying to use a QLabel in a QQuickPaintedItem, it might be that your QLabel size is simply not connected to the size of the QQuickItem and stays fixed size never allowing it to expand to its full size.
  • [SOLVED] Qt Quick 2.0 doesn't work for me

    8
    0 Votes
    8 Posts
    6k Views
    M
    You need to click on edit for your first post in this thread which has opened the thread. Then you can edit the headline.
  • Looping a video infinitely, using QtMultimedia 5.0

    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • Qt Quick in Windows XP

    2
    0 Votes
    2 Posts
    2k Views
    sierdzioS
    That is MS Visual C++ library, yet you are using MinGW Qt. Either your setup is wrong, or somehow MinGW requires that lib. You could copy the dll from your Win7 machine, but I don't know if that would work.
  • [SOLVED]How to write onMinimunScaleCange event handler on PinchArea

    5
    0 Votes
    5 Posts
    2k Views
    D
    I had misspelled "console". But it does not matter. Following error when you perform a QML Viewer than that. @D:\Qt\4.8.4\bin\qmlviewer.exe D:/DEV/Demo/PinchAreaTest/PinchAreaTest.qml を起動中 file:///D:/DEV/Demo/PinchAreaTest/PinchAreaTest.qml:28:9: Cannot assign to non-existent property "onMinimumScaleChanged" onMinimumScaleChanged :{ ^ @ If the error has not occurred, would have pointed out errors are displayed.