Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.5k Topics 457.3k Posts
  • macOS 14 Sonoma save file dialog not showing

    Solved
    6
    0 Votes
    6 Posts
    2k Views
    M
    I have this same problem and open/save dialogs don't work at all, and there's nothing wrong with my Info.plist file. I downloaded and installed from the online installer today (I was using 6.5.0, now 6.5.3). I tried to build the examples and open/save dialogs don't work, even in Qt Creator!
  • Proper way to delete QOpcUaClient object

    Solved
    2
    0 Votes
    2 Posts
    152 Views
    SGaistS
    Hi, Signal/Slot disconnection should happen automatically upon deletion so there's no need to do that. Other than that, it looks good.
  • How modify the Q3DBars with multiple color bars?

    Unsolved
    3
    1 Votes
    3 Posts
    413 Views
    R
    @f-lerdino if you want something like this: [image: 4afb1704-e915-4837-a6c0-9996c7bdd402.png] there is code: QGuiApplication app (argc, argv); Q3DBars bars; bars.resize (800, 800); // Remove the frame for a borderless window bars.setFlags (bars.flags () ^ Qt::FramelessWindowHint); bars.rowAxis ()->setRange (0, 4); bars.columnAxis ()->setRange (0, 4); QBar3DSeries* series = new QBar3DSeries; // Set the color style for the series to ColorStyleRangeGradient series->setColorStyle (Q3DTheme::ColorStyleRangeGradient); // Define colors for the color style range gradient QLinearGradient gradient; gradient.setColorAt (0.0, Qt::green); gradient.setColorAt (0.5, Qt::yellow); gradient.setColorAt (1.0, Qt::red); // Create a data proxy for the series QBarDataProxy* dataProxy = new QBarDataProxy; // Create data items with values QBarDataRow* dataRow = new QBarDataRow; for (int i = 0; i < 5; ++i) { dataRow->append (QBarDataItem (1.0f * 0.1 * i)); } // Assign color style range gradient to the data proxy //dataProxy->setColorStyle (gradient); // Add data row to the data proxy dataProxy->addRow (dataRow); // Set data proxy for the series series->setDataProxy (dataProxy); series->setBaseGradient (gradient); bars.addSeries (series); bars.show (); return app.exec (); } the key is "series->setColorStyle (Q3DTheme::ColorStyleRangeGradient);"
  • QSqlQueryModel - and fetchMore?

    Unsolved
    10
    0 Votes
    10 Posts
    2k Views
    Christian EhrlicherC
    QSqlQueryModel::fetchMore() is not used for database drivers returning the query size like postgresql does. Therefore it's not called / called but does nothing because the size (bottom) is already known. QSqlQueryModel::data() calls QSqlQuery::seek() to get the data from the correct row. This also means that the underlying driver might already transferred all the data from the server to the client at this time (which is what the op sees). there is no way to tell the driver to do a lazy fetch (at least I'm not aware of a way for postgresql) except a forward-only query which is not what you want here. Therefore you have to implement the paging by yourself.
  • Problem with a progress dialog with 6.5.3

    Unsolved
    3
    0 Votes
    3 Posts
    190 Views
    PerdrixP
    @JonB I will ask the developer who looks after that progress control to see if he can provide one.
  • Unresolved external symbol with Qt6

    Unsolved
    4
    0 Votes
    4 Posts
    1k Views
    L
    @ChrisW67 Looks like the conan package is broken. I had to explicitly link with a dcomp.lib windows library, but that fixed it. Did a search in the windows docs for the missing symbol and just copy and pasted its static lib. Whether or not this runs is a different story: target_link_libraries(QtGUIImpl CONAN_PKG::qt Dcomp.lib)
  • Colour differences in a group box on Windows

    Unsolved
    10
    0 Votes
    10 Posts
    537 Views
    PerdrixP
    @Christian-Ehrlicher Err no, it could still be a Qt problem that I can't work out how to create a small test case for...
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    15 Views
    No one has replied
  • using QML_ELEMENT macro causes runtime error

    Solved
    7
    0 Votes
    7 Posts
    1k Views
    mzimmersM
    @JoeCFD yeah, I ran across that earlier. I’ll try it and see whether it helps me expose the enums in my struct. My testing is still preliminary but currently it seems that my QML doesn’t see my struct enums.
  • QTimeEdit issues

    Unsolved
    8
    0 Votes
    8 Posts
    652 Views
    JonBJ
    @Perdrix said in QTimeEdit issues: nice to have an editor that would use e.g. DD|hh|mm|ss|zzzzzz - similar to QTimeEdit but extended to handle many days and better than millisecond accuracy. If you don't mind my saying, I do not think that would be useful. I just do not see where many applications would require input ranging from days to micro or nanoseconds. My point was that only QElapsedTimer is for representing a duration, QTime is not. I would not be using a QTimeEdit for your specification. Anyway, you could put together 5 spin boxes as a widget. IMO, each to their own.
  • How can I find QTextTable in QTextDocument?

    Solved
    2
    0 Votes
    2 Posts
    197 Views
    jsulmJ
    @Alexey-Serebryakov Documentation (https://doc.qt.io/qt-6/qtextdocument.html) says: "The entire document structure is stored as a hierarchy of document elements beneath the root frame, found with the rootFrame() function". So, use rootFrame() and then https://doc.qt.io/qt-6/qtextframe.html#childFrames to get all frames and try to cast each of them to QTextTable.
  • 0 Votes
    7 Posts
    5k Views
    F
    @yoavmil I have been searching many forum and what was missing for me was the setDataTerminalReady(true); Finaly, it is working now!
  • How to delete the last n items in a QSet

    Solved qset
    5
    0 Votes
    5 Posts
    770 Views
    O
    @Christian-Ehrlicher Thanks, it works with while(m_set.size() > number) m_set.erase(m_set.constBegin());
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    23 Views
    No one has replied
  • How to set the position of the input method editor?

    Unsolved ime
    2
    0 Votes
    2 Posts
    310 Views
    L
    @helloword rocket bot royale said in How to set the position of the input method editor?: I use the QTextedit in windows 8 system. When I use IME, Candidate panel for input method editor didn’t show in the correct position? Is there a way to set the correct location for the input method editor? Right-click on Taskbar > select Taskbar settings. Scroll to find, and then click Turn System icons on or off. Select On from the drop-down menu for the input indicator. Click OK.
  • Resizing dynamically created QPushbuttons within a QTableWidget

    Unsolved
    5
    0 Votes
    5 Posts
    492 Views
    T
    @jsulm I see. Thank you. https://forum.qt.io/topic/150252/dynamically-creating-a-vector-of-push-buttons-to-a-grid-layout-in-qt-c?_=1696555429922 I wasn't entirely sure how to track the player movements and scoring (similar to tic tac toe) using a QGridLayout. The code in the link was something I found online, while trying to figure out how to implement it.
  • QT designer with custom widget plugin setting incorrect qualified enum property name

    Solved
    3
    0 Votes
    3 Posts
    541 Views
    H
    @Christian-Ehrlicher damn, you are correct. Making it an Enum fixed it. Thanks!
  • QWebSocketServer does not accept new connections

    Unsolved
    6
    0 Votes
    6 Posts
    491 Views
    SGaistS
    I don't think they should. Can you reduce your code a minimal example that still exhibits this behaviour ?
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    11 Views
    No one has replied
  • how to mirror Sprite / SpriteSequence

    Solved
    2
    0 Votes
    2 Posts
    270 Views
    S
    If this helps to anyone then: transform: Scale { origin.x: image.width / 2 not to just flip, but flip in the middle of the picture xScale: -1 // 1 is for no scale... 0.5 for half size, 0 for 0 size, -1 to flip totaly vertically }