Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.7k Posts
  • QSqlDatabase: QMYSQL driver not loaded: What am I doing wrong?

    Unsolved
    8
    0 Votes
    8 Posts
    1k Views
    Christian EhrlicherC
    @Menre said in QSqlDatabase: QMYSQL driver not loaded: What am I doing wrong?: implement the line below with my code please? so what did you do until now? How did you configure the plugin? Please show use the output (as text, no pictures please)
  • Unable to download and install QT

    Unsolved
    11
    0 Votes
    11 Posts
    2k Views
    jsulmJ
    @Parthasaradhi You will not find MSVC itself in Qt installer as it is not allowed by Microsoft. You need to download MSVC from microsoft and install it. Then install Qt for MSVC using Qt online installer.
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    14 Views
    No one has replied
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    6 Views
    No one has replied
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    19 Views
    No one has replied
  • About QSerialPort

    Unsolved qserialport qt 5.12
    3
    0 Votes
    3 Posts
    605 Views
    SGaistS
    Hi and welcome to devnet, This is a known issue: QTBUG-78086. It's fixed and will be part of Qt 5.12.6 and 5.13.2.
  • How to get yyyy-MM-ddThh: mm: ssTZD from QDateTime

    Unsolved
    2
    0 Votes
    2 Posts
    1k Views
    SGaistS
    Hi, Are you looking to the date in the ISO-8601 format ? If so, I think this overload of toString will be of interest. Hope it helps
  • Prevent abnormal program termination

    Solved
    3
    0 Votes
    3 Posts
    373 Views
    S
    Hi SGaist and many thanks for your answer :)
  • Adding tree view to form in Qt Designer - from scratch , not in code

    Unsolved
    4
    0 Votes
    4 Posts
    1k Views
    A
    @Chris-Kawa Thanks Chris, I will go for QTreeWidget, it will do the job.
  • Non-video tutorials?

    Unsolved
    3
    0 Votes
    3 Posts
    267 Views
    A
    @mrjj Thanks for posting the links.
  • No protocol specified

    Solved
    7
    0 Votes
    7 Posts
    4k Views
    taku-sT
    The problem has been solved. I installed it in / usr / local / bin as root, but it seemed that the owner of the executable file was left as root. If I change the owner to user, I can execute it. The warning remains.
  • QStandardItemModel & Deleting

    Solved
    10
    0 Votes
    10 Posts
    8k Views
    B
    Try this: Here I was adding 4 standardItem in one row starting from column 1. The same I am deleting before clearing the Model. m_qsimAlarmModel is my object of QStandardItemModel. Below code is not tested, some change may required. for (int i = 0; i<m_qsimAlarmModel->rowCount();i++) { QStandardItem *test = nullptr; test = m_qsimAlarmModel->takeItem(i,1); delete test; test = nullptr; test = m_qsimAlarmModel->takeItem(i,2); delete test; test = nullptr; test = m_qsimAlarmModel->takeItem(i,3); delete test; test = nullptr; test = m_qsimAlarmModel->takeItem(i,4); delete test; test = nullptr; }
  • Adding text to same row, but next column?

    Unsolved
    11
    0 Votes
    11 Posts
    2k Views
    Christian EhrlicherC
    So when you take a look at this model you will see QVariant TreeItem::data(int column) const { if (column < 0 || column >= m_itemData.size()) return QVariant(); return m_itemData.at(column); } And here is the full description for this class: https://doc.qt.io/qt-5/qtwidgets-itemviews-simpletreemodel-example.html#treeitem-class-definition "Information about the number of columns associated with the item is provided by columnCount(), and the data in each column can be obtained with the data() function"
  • New to Qt - Layout issues

    Solved
    7
    0 Votes
    7 Posts
    525 Views
    SGaistS
    @Driftwood said in New to Qt - Layout issues: But, alas, I'm a man of my word. Just send me your first name and little John (or Jane) will get it stamped to their birth cert :D For the greater good of that human being to come, I won't hold you to that promise ;-) Just take the time to choose something wisely :-)
  • How in QChart to set the axis text instead of numbers

    Unsolved
    1
    0 Votes
    1 Posts
    150 Views
    No one has replied
  • QGraphicsItem, location of 2 items in each other local space

    Unsolved qgraphicsitem
    5
    0 Votes
    5 Posts
    678 Views
    D
    @SGaist Possibly yes... I'm back to this & lost again... I think I figured out the last problem without needing it, but now I need it again... Scenario = bezier curve, 4 points, first start, control left, control right, endpoints. Start and end can never cross each other on Z-axis. Control left can not pass end on the Z-axis and control Right can not pass start on z-axis either. Control points are children of start/endpoints. (Hope this make sense...) So what I need to find out is... location of End point while being inside Control Left event. I need to somehow map scenePos() of End point to my Control Left local space.... here is some debuging I was trying to do... (test case, moving right control point towards left Start item) targetPos : QPointF(348,-478) // scenePos() of Start item myPos : QPointF(336,-617) // scenePos() of rightControl scenePos() - already invalid position because we passed the Z location of targetPos item. myLocPos : QPointF(-237,2) This should match other item loc at some point... localPos of rightControl mapFromScene: QPointF(12,139) // mappings mapToItem : QPointF(113,-477) // mappings mapFromItem : QPointF(583,-479) // mappings one of mappings should return a number close to myLocPos but none of them do :- ( Debug code : qDebug() << "oh snap!" << "\n targetPos : " << itemPos << "\n myPos : " << myPos << "\n myLocPos : " << newPos << "local pos of rightControl item" << "\n mapFromScene: " << mapFromScene(itemPos) << "\n mapToItem : " << mapToItem(items[x], itemPos) << "\n mapFromItem : " << mapFromItem(items[x], itemPos); Esentially this : [image: 1e3b77d8-9ab6-40cb-a748-1377ac582d47.png] Top left item, is the myPos/newPos variable newPos being local and myPos being scenePos(), item below is the "Start"
  • Flowchart drawing

    Unsolved
    5
    0 Votes
    5 Posts
    2k Views
    mrjjM
    Hi A talented friend of mine - made this library https://forum.qt.io/topic/104100/diagram-schematic-components-library which have many nice features out of the box. Have a look if would fit your requirements or be an option for a base for your own solution. There is also https://doc.qt.io/qt-5/qtwidgets-graphicsview-diagramscene-example.html Which is a mini flow chart-ish app.
  • Forcing Qt container bounds checking

    Solved
    2
    0 Votes
    2 Posts
    403 Views
    aha_1980A
    @Asperamanca AFAIK, the code is highly optimized for size and speed. So beside the assertations the is no extra safety net - at least for the code I'm aware of. you can always check yourself - the sources are available after all. Regards
  • Stylesheet problem with Qt > 5.12.2

    Unsolved
    15
    0 Votes
    15 Posts
    2k Views
    R
    @Christian-Ehrlicher thank you!
  • Qt win10 QMYSQL driver not loaded

    Solved
    9
    0 Votes
    9 Posts
    1k Views
    Christian EhrlicherC
    You should look for mysql libraries, not for ones from windows.