Skip to content

QML and Qt Quick

Looking for The Bling Thing(tm)? Post here!
20.1k Topics 77.6k Posts
  • Gridview highlight with different view and size

    1
    0 Votes
    1 Posts
    546 Views
    No one has replied
  • Change language on runtime in QML application

    7
    0 Votes
    7 Posts
    8k Views
    K
    thank you Rahul Das and SGaist. I have succeed. But I make a little change on example you gave. I used translation file with qm extension and included it to resource file. Otherwise it did not work on my example. I dont know why.
  • Qt 4.8.5 with PostgreSQL 9.1 !!

    12
    0 Votes
    12 Posts
    5k Views
    M
    Hi, to get 8.3 names you can type on Windows Command Prompt @ dir /X @
  • How to get int value from QPoint angleDelta() ?

    1
    0 Votes
    1 Posts
    902 Views
    No one has replied
  • Font Scaling issue with Quicksand

    3
    0 Votes
    3 Posts
    1k Views
    K
    Just tried this, it didn't change anything. My target is Embedded Linux at Qt 4.8.3. But I've also tried this on my desktop machine (Ubuntu 12.04 with Qt 5.1.1) too and there is no change. Do you think Font Formats might have something to do with this, I'm using TrueType in both cases. Appreciate the help. [quote author="Jens" date="1385392028"]It might be an artifact of distance field rendering relying on fixed resolution pixmaps. You can try setting renderType: Text.NativeRendering in Qt Quick 2 and see if that helps depending on what the use case is.[/quote]
  • 0 Votes
    1 Posts
    1k Views
    No one has replied
  • OpenGL under QML does not work with dynamic object creation

    2
    0 Votes
    2 Posts
    1k Views
    J
    This issue turned out not to be the OpenGL control. In my QML I was loading the control as a child of a 'COLUMN' item. If you don't get the properties of the child controls correct the column will render the item but not display it. It may be rendering it out of the valid area and it's clipped off. I changed my QML to remove the column item and use anchors to place items in the positions I wanted.
  • TabView Tabs icon

    2
    0 Votes
    2 Posts
    1k Views
    J
    Not directly but if you set a tabViewStyle on the tabview, it is possible to create a custom label for each tab.
  • Subtitles and audio track selection support on MediaPlayer / Video

    1
    0 Votes
    1 Posts
    601 Views
    No one has replied
  • The replacement of "window" object in Javascript

    5
    0 Votes
    5 Posts
    2k Views
    benlauB
    That will throw : @ ReferenceError: someObject is not defined @
  • QtWebKit 3.0 and Mouse to select text

    1
    0 Votes
    1 Posts
    629 Views
    No one has replied
  • Gantt Chart

    4
    0 Votes
    4 Posts
    3k Views
    sierdzioS
    Yes, it is. "absolute coords" in QML does not mean the whole scene: you give the positions relative to the parent. DO some test apps to get a feeling of how it works, it's really easy.
  • How to load qml file from resources, using QtQuick 2 Controls

    2
    0 Votes
    2 Posts
    998 Views
    sierdzioS
    QtQuick2ControlsApplicationViewer is just an auto-generated template (by Qt Creator). Get into the source and modify it to suit your needs, or switch to the more - IMO - useful QQuickView. You probably need to specify the file by QUrl.
  • Faster alternative for grabWindow?

    1
    1 Votes
    1 Posts
    2k Views
    No one has replied
  • Please advise how to set the property from qml1 to qml2

    3
    0 Votes
    3 Posts
    1k Views
    A
    Thanks a lot. That worked. learned something new today.
  • TextArea QTextCharFormat::setUnderlineStyle

    1
    0 Votes
    1 Posts
    761 Views
    No one has replied
  • 0 Votes
    1 Posts
    648 Views
    No one has replied
  • [solved] QML dynamic object creation in C++

    7
    0 Votes
    7 Posts
    16k Views
    N
    hello, I have an application, in which i am using the same approach. now if i want to access the properties of baseObj, which meant to be parent of my dynamically created object, what should i do. Here is example of my code.. main.qml import FirstButtonClick 1.0 Rectangle{ property string myString : "My String" Text{ text : "main file" } MouseArea{ onClicked:{ buttonClick.openPage("qrc:qml/FirstButton.qml") } } FirstButtonClick{ id : buttonClick } } FirstButton.qml Rectangle{ Text{ text : "FirstButton Page" } Component.onCompleted{ console.log("main.qml property : " + myString // main.qml property) } } main.cpp #include "FirstButtonClick.h" #include "main.h" int main(int argc, char *argv[]) { qmlRegisterType<>("FirstButtonClick", 1, 0, "FirstButtonClick"); QApplication app(argc, argv); m_view = new QDeclarativeView; m_view.setSource(QUrl("qrc:qml/main.qml")); m_view.showFullScreen(); return app.exec(); } main.h QDeclarativeView* m_view; FirstButtonClick.h extern QDeclarativeView* m_view; class FirstButtonClick : public OQbject { Q_OBJECT; public : Q_INVOKABLE QObject* openPage(QString fileName); } FirstButtonClick.cpp #include "FirstButtonClick.h" QObject* FirstButtonClick :: openPage(QString fileName) { QDeclarativeContext* context = m_view->engine()->rootContext(); QDeclarativeComponent* component = new QDeclarativeComponent(m_view->engine(), QUrl(fileName), m_view->engine()); QObject * object = component->create(); QDeclarativeItem* myDialog = qobject_cast<QDeclarativeItem*>(object); QDeclarativeItem *rootitem = qobject_cast<QDeclarativeItem*>(m_view->rootObject()); myDialog->setParentItem(rootitem); return object; } the problem with the above code is FirstButton.qml page is loaded but when it tries to access the property of main.qml ie. myString it cant access it. suggest me me a way to use it properly
  • How to export Qt Quick2 project into a video clip

    1
    0 Votes
    1 Posts
    532 Views
    No one has replied
  • [SOLVED] ListView to show variable width images.

    2
    0 Votes
    2 Posts
    837 Views
    C
    The reason is the animation on ListView. It works after I changed the size after the animation.