Skip to content

QML and Qt Quick

Looking for The Bling Thing(tm)? Post here!
20.0k Topics 77.3k Posts
  • QDeclarativeImageProvider does not load image in container

    2
    0 Votes
    2 Posts
    2k Views
    V
    I found answer on stackoverflow: "Columns get a bit funny with items that don't declare their width and height" from funkybro. @Column { id:screenImage Image { id: backImage width: screenImage.width height: screenImage.height source: "image://imageprovider/backimage" } }@
  • Model property set in listview: delegate can't find properties.

    6
    0 Votes
    6 Posts
    5k Views
    B
    That did the trick.. Very strange because I tried this before but then it didn't work.
  • XmlListModel with multiple sources

    3
    0 Votes
    3 Posts
    2k Views
    G
    Be patient! It's no more than 16 and a half hour after your first post. Not everyone sits in front of his/her computer all the time, the folks are spread all over the world. You should wait at least a couple of days before bumping your subject to the front again.
  • How do i send a signal with parameters from QML to cpp code

    5
    0 Votes
    5 Posts
    5k Views
    M
    I've updated my reply...the js code is crucial to propagate the data to the cpp code.
  • How to address all the ListModel ListElements and not just one?

    8
    0 Votes
    8 Posts
    12k Views
    C
    Ah I see...thanks!;) that helps to address similar issues as well...but I definitely need an upgrade...(of my expertise...)
  • How to create a nested Listview

    7
    0 Votes
    7 Posts
    5k Views
    D
    [quote author="Milnadar" date="1303892815"]How about to create new listModel for every folder, and to keep them invisible until not pressed needed item? Are there any nested folders in folders which you click on? Or just files?[/quote] Indeed in a folder there are possibly subfolders and files. :(
  • QGraphicsItem::itemChange nerver called

    3
    0 Votes
    3 Posts
    4k Views
    M
    With this flag enable the function is called in different occasion like @ItemFlagsChange ItemFlagsHaveChanged ItemChildAddedChange ItemSceneChange ItemSceneHasChanged@ But never when my children move. I will try to connect to xChanged signal. Edit : I've found a way to make it work @QVariant Line::itemChange ( GraphicsItemChange change, const QVariant & value ) { if(change == QGraphicsItem::ItemChildAddedChange) { QGraphicsItem* item = value.value<QGraphicsItem*>(); QDeclarativeItem* item2 = dynamic_cast<QDeclarativeItem*>(item); QList<QObject*> loc_o_childrens = children(); foreach(QObject* obj,loc_o_childrens) { QDeclarativeItem* child = dynamic_cast<QDeclarativeItem*>(obj); if(child == item2) { connect(child,SIGNAL(xChanged()),this,SLOT(repaint())); connect(child,SIGNAL(yChanged()),this,SLOT(repaint())); } } } return QGraphicsItem::itemChange(change, value); }@ I really dislike this way of doing things but I can't get the ItemPositionChange.
  • Custom properties in QML

    3
    0 Votes
    3 Posts
    3k Views
    M
    thanks. I've put my data in a class derived from QObject.
  • Moving graphic in QML

    2
    0 Votes
    2 Posts
    2k Views
    S
    Did you take a look at the examples in Qt Creator? There are some dedicated to animation :)
  • [Solved] QML state onload

    4
    0 Votes
    4 Posts
    11k Views
    F
    i set rotation: 3600, with duration 10000, then the image still rotating for 10 seconds Thanks again @mlong
  • 0 Votes
    2 Posts
    2k Views
    V
    Mayby, "QProcess":http://doc.qt.nokia.com/4.7/qprocess.html can help you out?
  • [Solved] Some help about Add New, Modify, Delete

    15
    0 Votes
    15 Posts
    4k Views
    S
    bq. “[solved]” before it Not at the end ... this way somebody searching in the forum could easily see it :)
  • Lock orientation of the phone for specific QML pages

    6
    0 Votes
    6 Posts
    8k Views
    Z
    You could call the setOrientation() function from your QML scene as needed. You would need to make it a slot or mark it as a Q_INVOKABLE I think. Edit: And expose the object via QDeclarativeContext::setContextProperty.
  • Whats wrong with if else? [SOLVED]

    4
    0 Votes
    4 Posts
    2k Views
    C
    SOLVED:) thanks both!!!
  • QML ListView Drag and Drop reorder

    7
    0 Votes
    7 Posts
    12k Views
    A
    Thanks for reporting back with your solution! It was a nice read, and I'm sure someone will benefit from it in the future.
  • Vector3d type as property in QML (2D)

    9
    0 Votes
    9 Posts
    6k Views
    Q
    It seems that it works ... I have to check if it works with my C++ model for Qvector3D property binding
  • How to check in QML if plugin is available

    4
    0 Votes
    4 Posts
    3k Views
    M
    There isn't any official, built-in way to do this from QML in Qt Quick 1.x. It isn't especially elegant, but as minimoog77 suggested, a workaround is to use Loader or dynamic item creation to try and load a file with the needed import, and then check whether or not you've received any errors. Hopefully we'll have a better solution for this in a future version of QML.
  • Changing QML property from C++ : how to change width of QML property?

    3
    0 Votes
    3 Posts
    3k Views
    D
    I think you've meant @ Rectangle { property int counter: model.counter width: counter * 10 } @ Do you change qml property or property of model from c++? If second, then you should use alias instead of full qml property. And don't forget about emitting signal on property change (one mentioned in NOTIFY). P.S. And please, don't forget to highlight your code
  • QML video speed

    3
    0 Votes
    3 Posts
    3k Views
    S
    Also, this seems to grow in memory usage by about 50-100MB/s, which is insane. Is this just not being used by anyone? Just not on a mac? I used the latest released qt-mobility compiled from scratch, if that's helpful.
  • Why QML TextInput's setInputMask is removing spaces?

    Locked
    2
    0 Votes
    2 Posts
    3k Views
    V
    Is it intentional that you almost repeated your question you asked in this "thread":http://developer.qt.nokia.com/forums/viewthread/5331? Edit: closed for this very reason; Andre