Skip to content

QML and Qt Quick

Looking for The Bling Thing(tm)? Post here!
20.0k Topics 77.4k Posts
  • How to show multiple Popup on a window? (for ToolTip)

    Solved
    3
    0 Votes
    3 Posts
    424 Views
    W
    @GrecKo Nice and good example! I can solve my problem. Thanks.
  • Using of property mouse.accepted

    Solved
    4
    1 Votes
    4 Posts
    3k Views
    GrecKoG
    not that for a single parameter you can get rid of the parenthesis, mouse => { ... } works
  • "ValueAxis.tickInterval" is not available in QtCharts 2.3.

    Solved
    3
    0 Votes
    3 Posts
    357 Views
    S
    It works ! Thanks (I don't understand it either...)
  • Qt Quick QML Types in QtQuick 2.11 ??

    Solved qml types
    2
    0 Votes
    2 Posts
    473 Views
    raven-worxR
    @timob256 you mean this? https://doc.qt.io/archives/qt-5.11/qtquick-qmlmodule.html
  • Fonts, again. Different appearance on different platforms. Same font.

    Solved
    6
    0 Votes
    6 Posts
    1k Views
    GrecKoG
    That's how font works in every UI system, there is a fallback behavior. As for why there is both font.family and fontInfo.family, it's because it makes developers life easier. You can actually see if the chosen font differs from the one that was set without having to store the expected font somewhere else. For the font family you can also gives a very vague one like "serif", "sans-serif", "monospace" and seeing what the font matched with fontInfo might be important. It would be weird to do font.family = "sans-serif"; and then getting "DejaVu Sans" back when querying font.family, wouldn't it? QML is declarative, so making font.family a function won't be very practical and give much advantages. You already have your feedback in a declarative way, I really don't see how an imperative API would be any better? Do you have a pseudo code example of what your perfect API would look like?
  • TableView header hides first elements

    Unsolved
    3
    0 Votes
    3 Posts
    700 Views
    sudarshandS
    Use topMargin property of Table View.
  • Problems with ScrollBar and ListView

    Solved
    2
    0 Votes
    2 Posts
    843 Views
    C
    I figured it out. For anyone who's interested. If you set the visibility of the contentItem to be: visible: theListView.contentHeight > theListView.height that should do the trick.
  • Dialog and DropArea issue

    Unsolved
    5
    0 Votes
    5 Posts
    2k Views
    G
    This is an annoying problem and I'm struggling with it at the moment. Did anyone manage to find a proper workaround to it?
  • Qt Creator: qml.qrc with different prefix, problem in design editor

    Unsolved
    1
    0 Votes
    1 Posts
    209 Views
    No one has replied
  • QList as qml model

    Unsolved
    2
    0 Votes
    2 Posts
    293 Views
    raven-worxR
    @Cyrille-de-Brebisson Q_PROPERTY(QList<MyObj*> liste READ getliste NOTIFY listeChanged) now emit the listeChanged signal everytime you change the list If you would implement a QAbstractListModel subclass you would have more control of rearrangements etc.
  • 0 Votes
    4 Posts
    1k Views
    raven-worxR
    @Tee_ normally a pro file results in a separate target (executable or library). Even if you "combine" them with a subdirs project. So your AppUi project must link against the AppLib
  • GTK style File Explorer on Windows OS

    Unsolved
    1
    0 Votes
    1 Posts
    192 Views
    No one has replied
  • ChartView/ValueAxis - How to NOT label the maximum value tick on the ValueAxis

    Unsolved
    4
    0 Votes
    4 Posts
    326 Views
    fcarneyF
    You could draw a line on top. Not ideal. Edit: Width of 1 rect with border.
  • Conditional Import

    Unsolved
    10
    0 Votes
    10 Posts
    2k Views
    raven-worxR
    @caicx said in Conditional Import: import QtGraphicalEffects 1.0 // Required by Qt 5.x.x vs import Qt5Compat.GraphicalEffects // Required by Qt 6.x.x yes and? Since the major version of Qt has changed you should also advance with your project, instead of importing a compat module of a previous version for the whole lifespan of Qt 6. The compat module is intended to be used as a quick solution until the porting of your application to Qt6 has finished
  • Key press events are not handled in e.g. Qml TextField but eventFilter receives it

    Unsolved
    1
    0 Votes
    1 Posts
    162 Views
    No one has replied
  • How to identify the Qt libraries are built with open source or commercial licenses

    Solved
    3
    0 Votes
    3 Posts
    434 Views
    P
    @jsulm - Thank You
  • Can't use QtQuick.Controls

    Unsolved
    3
    0 Votes
    3 Posts
    379 Views
    W
    @J-Hilk No, I haven't considered it because it has been working fine until now. Sorry, I made a mistake, it's "5.15.2" to be exact. I created a new project with the exact same settings and the exact same code, and it worked. Was there a problem with the settings that I missed somewhere?
  • Cant refresh QML item only after using it.

    Unsolved
    3
    0 Votes
    3 Posts
    333 Views
    B
    Didnt know about breaking bindings yet and I feel like I dont understand the code onActivated well. What does => means / how it's named? Currently the custom item is defined like this: LeftBind { id: enabler x: 291 y: 15 keyName: keyTranslator.getKey(Config.enabler) //Config.enabler is vkey (int), this function converts it to readable string (for example from c++ vkey 0x10 to "ALT") onAccepted: { var a = keyTranslator.getCode(keyName); // from string to vkey if(a === 404){ askForKey() } else { Config.set_enablerBtn(a) } } }
  • Scenegraph with OpenGL : Unwanted rendering

    Unsolved scengraph vtk opengl qquickwindow synchronization
    6
    0 Votes
    6 Posts
    942 Views
    J
    @JoeCFD I was working on other stuffs but now I remember why I can't override QQuickItem update() method... it is a non-virtual slot, so it can't solve my rendering issues. I am still looking for a solution ...
  • 0 Votes
    2 Posts
    960 Views
    A
    @jeanmilost Your logic seems to be correct. What you have to do is to move the re-calculation of Scrollbar size & position to the Rectangle rcPageContainer because you are applying scale for that. Rectangle { id: rcPageContainer objectName: "rcPageContainer" ... /// called when page viewport width changed onWidthChanged: { sbHorz.size = rcPageViewport.width / rcPageContainer.width sbHorz.position = Math.min(Math.max(sbHorz.position, 0.0), 1.0 - (sbHorz.size)); } /// called when page viewport height changed onHeightChanged: { sbVert.size = rcPageViewport.height / rcPageContainer.height sbVert.position = Math.min(Math.max(sbVert.position, 0.0), 1.0 - (sbVert.size)); } }