Skip to content

QML and Qt Quick

Looking for The Bling Thing(tm)? Post here!
20.0k Topics 77.4k Posts
  • QQmlListProperty constructor doesn't accept my arguments

    qqmllistpropert
    16
    0 Votes
    16 Posts
    6k Views
    T
    solved :-) no one saw it ;-) public: QQmlListProperty<TestItem> lstTestItems() const; this can't be const. Thats it.
  • Must Q_PROPERTYs with user-defined C++ types be of pointer type?

    1
    0 Votes
    1 Posts
    410 Views
    No one has replied
  • Repeater child's parent null during destruction?

    qml
    3
    0 Votes
    3 Posts
    2k Views
    E
    That example sometimes uses parent properties directly and sometimes with protection. What's the rule we should apply regarding whether to use null protection or not?
  • how to disable pinch/zoom resizing of full screen browser?

    5
    0 Votes
    5 Posts
    2k Views
    E
    How do I edit the original post? I dont see that option listed anywhere on the page, just an option to reply.
  • How to Create list detail screen ?

    listview lismodel
    4
    0 Votes
    4 Posts
    1k Views
    p3c0P
    @shwt.saxena Please format your code before pasting and use ``` (3 backticks) for posting code blocks. The code that you posted doesn't show how details screen in invoked. Is it is a Component or a separate QML ? Please post those details.
  • [solved] QML TextInput with Time format hh:mm:ss

    qml textedit imhtime
    2
    0 Votes
    2 Posts
    5k Views
    p3c0P
    @HappyCoder Apart from using inputMask you will also need to set a validator. RegExpValidator would be perfect choice for it. A common validator for hh:mm:ss I found was this /^(?:(?:([01]?\d|2[0-3]):)?([0-5]?\d):)?([0-5]?\d)$/ Usage is simple: validator: RegExpValidator { regExp: /^(?:(?:([01]?\d|2[0-3]):)?([0-5]?\d):)?([0-5]?\d)$/ } You can also find another validators.
  • QML ListView visible

    6
    0 Votes
    6 Posts
    4k Views
    p3c0P
    @beh_zad Thanks for sharing.
  • FileDialog bug? Extremely slow when debugging is active

    filedialog slow
    3
    0 Votes
    3 Posts
    2k Views
    p3c0P
    @Bremenpl It could be a bug. Please report it Qt BugTracker.
  • Running onClicked [solved]

    8
    0 Votes
    8 Posts
    2k Views
    p3c0P
    @joanaguimas Congratulations :) Happy Coding..
  • TextField in TableView Row

    3
    0 Votes
    3 Posts
    801 Views
    Malek_KhlifM
    @p3c0 Thank you very much :)
  • Any QValidator class in which I can pass QStringList as valid options.

    4
    1 Votes
    4 Posts
    2k Views
    SGaistS
    Hi, Sounds like you should implement your own validator and check against a given list of words
  • Integrating QML Video Element to platform media player

    video
    1
    0 Votes
    1 Posts
    638 Views
    No one has replied
  • Create model QML Dialog from C++

    qt5 qtquick qml
    8
    0 Votes
    8 Posts
    8k Views
    p3c0P
    @PhTe Well that too because you have visible set to true for Dialog. You're Welcome. Happy Coding..
  • Transparent background and opaque rectangles

    transparency opacity qml opengl
    11
    0 Votes
    11 Posts
    18k Views
    p3c0P
    @Juaruipav Yes it is activated. Did you try by deactivating it ? May be it is a bug on Windows 8.1. Better you should report it on Qt Bug Tracker.
  • 0 Votes
    4 Posts
    2k Views
    p3c0P
    @Buttink The attached properties are not always directly accessible by the children. It is documented here. It states: A common error is to assume that attached properties and signal handlers are directly accessible from the children of the object to which these attributes have been attached. This is not the case. The instance of the attaching type is only attached to specific objects, not to the object and all of its children. Check out the example provided there.
  • Getting mouse location from animated Rectangle

    7
    0 Votes
    7 Posts
    2k Views
    p3c0P
    @pDogg As I said earlier it wont work. From the doc for containsMouse: Warning: This property is not updated if the area moves under the mouse: containsMouse will not change. In addition, if hoverEnabled is false, containsMouse will only be valid when the mouse is pressed while the mouse cursor is inside the MouseArea. I think you will need to calculate it manually.
  • Connect to C++ signal from QML

    8
    0 Votes
    8 Posts
    3k Views
    R
    I found a simple solution for my problem. I just declare a property Q_PROPERTY(QJSValue onMouseUp READ onMouseUp WRITE setOnMouseUp) that I can call from C++ side as QJSValue::call(). It allows me to write more clean code and ensure to have a single signal handler for this event (it's also important for me)
  • 0 Votes
    4 Posts
    2k Views
    p3c0P
    @svyatoslav911512 You can read more about property binding here. Happy coding..
  • QDeclartiveItem-Qt Quick 1 or QQuickItem- Qt Quick 2.

    5
    0 Votes
    5 Posts
    1k Views
    jeremy_kJ
    It's hard to guess without more context, but if you're using Creator, try the "Run qmake" build option before building.
  • Layout Width

    4
    0 Votes
    4 Posts
    2k Views
    p3c0P
    @Cyril You're Welcome :) However it gets a bit confused having anchors, width height, Layout. all for item placing I would suggest you go through following for more info : http://doc.qt.io/qt-5/qtquick-positioning-topic.html http://doc.qt.io/qt-5/qtquick-usecase-layouts.html