Navigation

    Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Search
    • Unsolved
    1. Home
    2. Tags
    3. c++ qt
    Log in to post

    • SOLVED My app crashes when trying to quit
      General and Desktop • c++ qt macos crash app quit appcrash qtcrea • • superg  

      5
      0
      Votes
      5
      Posts
      93
      Views

      @SGaist That seems to be the solution, haha! Thanks.
    • UNSOLVED Painting images over qml maps
      QML and Qt Quick • qml c++ qt qml c++ qml map qml rendering • • Matus_Varhanik  

      1
      1
      Votes
      1
      Posts
      71
      Views

      No one has replied

    • UNSOLVED How to create and use a QVector in other functions or is there an easier way to do this?
      General and Desktop • c++ qt creator c++ qt qvector optimization • • Turbotroop  

      6
      0
      Votes
      6
      Posts
      127
      Views

      @Turbotroop OK, so: Is the code pasted now currently what you have, exactly? What error do you currently have? Have you acted on the previous comments? For example: although it won't generate a compilation error, it does not make any sense to set up all these boxes or arrays in the main window destructor, does it? Why not in, say, the constructor instead?
    • SOLVED Can't set QComboBox/QSlider margins
      General and Desktop • c++ qt margins • • bibasmall  

      7
      0
      Votes
      7
      Posts
      153
      Views

      @Chris-Kawa thank you, it helped to set the margins!
    • SOLVED How to create a button and place it where I want and then run a function when the button is clicked C++ QT
      Tools • c++ qt button clickevent • • RuWex  

      17
      0
      Votes
      17
      Posts
      279
      Views

      @jsulm ou! thank you! you had helped me a lot!!
    • UNSOLVED Cyber Security Applications on QT !?
      Brainstorm • qt for python c++ qt qtwebengine security cybersecurity • • Divyang Mistry  

      2
      0
      Votes
      2
      Posts
      122
      Views

      Hi and welcome to devnet, That's a bit too vast of a topic to have a simpler answer. What element of Cyber Security do you have in mind ? At what level ? Cyber Security starts from giving people access to certain hardware / applications to the boot process of your machines/devices, the kernel/OS they are running, the applications you are using on them, the libraries that composes these applications, the devices you plug in the machines, etc.
    • SOLVED Recommended way of passing file paths
      General and Desktop • c++ qt qfile qdir filepath strongly typed • • christian_p  

      7
      0
      Votes
      7
      Posts
      407
      Views

      @SimonSchroeder QDir is only for directories, not for files. So it is not a (suitable) candidate for general "file paths".
    • SOLVED Fertigen Qt C++ Code mit dem Raspberry Pi nutzen?
      German • raspberry pi c++ qt cross platform raspberry pi 4 • • Zwenig  

      4
      0
      Votes
      4
      Posts
      194
      Views

      @Zwenig die einfachste Methode ist der package manager. den findest du eigentlich vorinstalliert in der Menüleiste, einfach nach Creator oder QtCreator suchen und installieren. darüber bekommst du auch eine version von Qt (Bibliothek), sollte neuer als 5.11 sein, also sollte dein Programm damit auch kompilieren
    • UNSOLVED QT compiler linker error
      The Lounge • qt creator c++ qt makefile error • • ELIF  

      2
      0
      Votes
      2
      Posts
      154
      Views

      @ELIF Please post the actual compiler/linker error. it is somewhere above of what you posted.
    • SOLVED How to write a QML extension from a custom C++ class?
      QML and Qt Quick • qtquick c++ qt extension • • gouneken  

      7
      0
      Votes
      7
      Posts
      225
      Views

      when I rerun, I am told that QtWebView cannot contain more than one item, so I guess I cannot save a c++ class in QtWebView, going through the doc I found that the c++ classes I needed had already been extended to the quick module. So, I'm going to use the c++ classes in this module instead. Thank you very much for your help.
    • UNSOLVED How to use QWebEngineView module in his project?
      Installation and Deployment • qt creator c++ qt webkit • • gouneken  

      4
      0
      Votes
      4
      Posts
      189
      Views

      @JonBI don't know if that's the problem, but I downloaded the QWebView module using the maintenance tool but still QtCreator does not recognize it as an existing module.
    • UNSOLVED How do I use QWebView in a computer project and get the specification of attributes and methods for QWebView in the documentation?
      Qt 6 • qt creator c++ qt qwebview qt documentatio • • gouneken  

      1
      0
      Votes
      1
      Posts
      138
      Views

      No one has replied

    • SOLVED Which class allows the analysis of files and folders present on the hard drive and their return in the form of a ready-to-use model?
      Qt 6 • model c++ qt mvc • • gouneken  

      3
      0
      Votes
      3
      Posts
      190
      Views

      @Gojir4 thank you so much
    • SOLVED What are the causes of abrupt termination of a program with Qt6?
      Qt 6 • qtcreator c++ qt • • gouneken  

      2
      0
      Votes
      2
      Posts
      231
      Views

      Hi The normal way to find out what is going on is using the debugger. So compile the app In debug mode and start it. When it crashes you should be able to see what it was doing in the call stack. The call stack is the area under the editor window when starting in debug mode As you can see it shows where the program was running. The function list. This should give a hint as to why it does crash.
    • SOLVED Reading data from device via QModbusRtuSerialMaster
      General and Desktop • c++ qt serialport modbus qmodbusdevice com-port • • BeaverShallBurn  

      3
      0
      Votes
      3
      Posts
      238
      Views

      Hi, @J-Hilk! Looks like i found desired method in QModbusDataUnit class docs. Don't know how i missed it being mentioned in List of All Members for QModbusRtuSerialMaster. I guess digging into Qt docs about Modbus was a proper way to solve this :) QModbusDataUnit::QModbusDataUnit(QModbusDataUnit::RegisterType type, int address, const QVector<quint16> &data) In my case this will be: QModbusDataUnit input(QModbusDataUnit::InputRegisters, 3001, data); Thanks for joining my journey!
    • UNSOLVED QT Serial Port
      General and Desktop • c++ qt serial port command line timer thread • • ADR_PT  

      3
      0
      Votes
      3
      Posts
      189
      Views

      @ADR_PT you may want to start using QSerialPort the asynchronous (non-blocking) approach, by using signals & slots. Take a look at the serial terminal example
    • SOLVED undefined reference to `_imp___ZN8mongocxx7v_noabi8instanceC1Ev in Qt?
      General and Desktop • qt5 c++ qt c++11 mongodb • • Vivek_A  

      23
      0
      Votes
      23
      Posts
      679
      Views

      my compiler is mingw32bit and mongocxx driver build in 64 bit . so thats make problem , i solved it by installing 64bit Qt.
    • SOLVED WindeployQT QTVirtualKeyboard not working after deployment
      Installation and Deployment • c++ qt virtualkeyboard windeployqt • • Yina  

      5
      0
      Votes
      5
      Posts
      338
      Views

      @raven-worx Thank you very much for your time, my issue is resolved :-) It was indeed the debug build causing the issue, and I am using the correct qlmdir to avoid unnecessary imports. Thank you again and have a nice day!
    • UNSOLVED Onvif camera streaming and control in QT C++
      General and Desktop • desktop c++ qt onvif • • Imran Hassan  

      7
      1
      Votes
      7
      Posts
      1498
      Views

      Hi, You might want to check KDAB's KDSoap library.
    • SOLVED Absurd QT File Handling Issue(QFile)
      C++ Gurus • qt5.6 c++ qt qfile qfiledialog file read • • Sabhya Sood  

      11
      0
      Votes
      11
      Posts
      914
      Views

      @JonB Thanks for your insight. I did as you suggested and found one of my local variable's address a nullptr(though not sure where it came from). I changed a few lines of code and apparently, my code works fine now. @Christian-Ehrlicher @J-Hilk thanks!
    • UNSOLVED C++ Qt Widget / Wie ein anderes Form in bestehenden Form öffnen?
      German • c++ qt qt 5.15 widget applicat • • sm-a  

      1
      0
      Votes
      1
      Posts
      236
      Views

      No one has replied

    • UNSOLVED malloc_consolidate(): unaligned fastbin chunk detected
      General and Desktop • c++ qt qapplication • • JoseLpd  

      6
      0
      Votes
      6
      Posts
      3612
      Views

      See https://bugreports.qt.io/browse/QTCREATORBUG-26918
    • SOLVED Pushbutton crashed.
      General and Desktop • c++ qt • • Gutks  

      26
      0
      Votes
      26
      Posts
      926
      Views

      @JonB This is exactly what I was expecting and what I thought of.... These type of games, where you have ingame shops and a lot of inventories... If you left-click an item, you probably buy it from shop or use it, if you right-click, you drop it or sell it :)
    • SOLVED Live camera image using OpenCV showing in Qlabel crashes due to out of memory error
      General and Desktop • gui qimage c++ qt opencv qpixmap • • Imran Hassan  

      9
      1
      Votes
      9
      Posts
      1089
      Views

      Thank you all guys. Your suggestions and expert opinion helped a lot with solving the problem. QT forum is always so helpful. After trying many things here is the conclusion and code is now working perfectly fine I removed the tic toc part time(&start); timer = double(getTickCount()); tic(); It was working but crashing then just to make sure that QImage is not NULL I removed the img = QImage(); // releasing memory with if(!img.isNull()) img = QImage(); Its working perfectly fine now.
    • UNSOLVED We are ready to work on any QT/QML projects
      Jobs • qt5 qtquick c++ qt qml components • • firestore  

      1
      0
      Votes
      1
      Posts
      505
      Views

      No one has replied

    • UNSOLVED Pacp - Send Data
      General and Desktop • c++ qt pcap • • neda  

      12
      0
      Votes
      12
      Posts
      417
      Views

      @neda The data is in pkt_data as far as i can see from docs so try QByteArray databuf = QByteArray(reinterpret_cast<char*>(pkt_data), header->len); qDebug()<<"data: "<<databuf ;
    • SOLVED QT image display is not working without declaring openCV namedWindow in windows 10
      General and Desktop • windows 10 c++ qt opencv qt 5.14.2 • • Imran Hassan  

      17
      0
      Votes
      17
      Posts
      1419
      Views

      @Imran-Hassan said in QT image display is not working without declaring openCV namedWindow in windows 10: The problem is solved great, so please don't forget to mark your post as such!
    • UNSOLVED problems on using the if and else statement and updating the data.
      General and Desktop • c++ qt update if and else • • Mr.Nobody645  

      18
      0
      Votes
      18
      Posts
      1020
      Views

      How did you do it now?
    • UNSOLVED Qt\QML Unit Converter (Metric\Imperial)
      Tools • qt5 c++ qt can bus qml types conversions • • simone.malvezzi  

      2
      0
      Votes
      2
      Posts
      486
      Views

      @simone-malvezzi No, Qt does not supply a set of measurement conversion tables, that's not its job. You could write it yourself, see if there is any pre-written C++ libraries/tables provided, or possibly grab them off the net, either dynamically or statically. As an aside, you will have to decide how "complete" you want to be. Personally I am great fan of Imperial instead of this Metric rubbish, but even I don't measure in "rods", "poles" & "perches" (e.g. http://www.northcravenheritage.org.uk/NCHTJto2009/Journals/2006/RodsPolesPerches/RodsPolesPerches.html) ;-) Though --- and I'm sure you're fascinated --- in winter I measure temperature in Centigrade but in summer I measure in Farenheit....
    • UNSOLVED Unresponsive GUI while append text to QTextedit
      General and Desktop • c++ qt qtextedit unresponsive • • Chaba  

      12
      0
      Votes
      12
      Posts
      472
      Views

      @SGaist My data is ready to append. So i append them directly. There are 10-100 QTextEdits. I append 100-200 line to each of QTextEdits. Lines have arround 300 characters. I have one vector of vectors source. By the way, i moved my data source to a different thread. Then emitted signals to append with BlockingQueuedConnection. Gui is responsive now. But its not smooth. I dont know using blockingqueuedconnection instead of queuedconnection is the right way but my gui is responsive while appending strings now.
    • SOLVED Adding salt to hashing in C++ - looking for library
      C++ Gurus • c++ qt hash • • bwylegly  

      15
      0
      Votes
      15
      Posts
      1098
      Views

      A quick look on bcrypt's webpage tells me this is not a library, but a program. If you want to have it as a library, there is not support for this out of the box. You need to figure it out by yourself. The general instructions for building are to use make. (Usually, nmake is the equivalent on Windows.) I don't see any instructions for Windows on the webpage. You'll have to look through the README's, etc. to figure it out. cmake and qmake will not help as these will just generate makefiles and not compile anything. However, there is already a makefile, so you don't have to run cmake or qmake to create them.
    • UNSOLVED QQuickItem::mousePressEvent() not called
      QML and Qt Quick • c++ qt c++ quicckitem • • Karim  

      1
      0
      Votes
      1
      Posts
      149
      Views

      No one has replied

    • UNSOLVED Deserializing QSqlQuery using submethod in efficient way
      C++ Gurus • mysql c++ qt • • bwylegly  

      6
      0
      Votes
      6
      Posts
      381
      Views

      No it's not, you can see that with its constructors that take a QSqlDatabase parameter. No clear is not called, the destructor is. There's no need to create QSqlQuery objects on the heap.
    • SOLVED Undefined behaviour of QDate when converted to string
      General and Desktop • c++ qt qdate • • Ahti  

      2
      0
      Votes
      2
      Posts
      186
      Views

      Hi If the database table type is of type date, it wont like a string formatted as SunFeb2020 so you need to match the toString format to the one expceted by the DBMS.
    • UNSOLVED QTNationaldex
      Showcase • c++ c++ qt pokemon pokedex • • BrandonTheProgram  

      2
      3
      Votes
      2
      Posts
      434
      Views

      Hi Thank you for sharing. I don't know anything about Pokemon but its cool you used gif so they are animated and the code looks clean and structured.
    • UNSOLVED Reading UART (RS485) with Qt
      Mobile and Embedded • c++ qt serial port serialport-byte • • SheldonC  

      8
      0
      Votes
      8
      Posts
      1317
      Views

      @RunThiner There's no need for such a loop. QSerialPort already provides an asynchronous API and if you really want to wait for data to be available, there's a blocking API for that as shown in the QSerialPort details.
    • SOLVED How to fetch coordinates of a Widget in QDockWidget?
      General and Desktop • qt5 gui c++ qt user interface • • rohit1729  

      5
      0
      Votes
      5
      Posts
      421
      Views

      @rohit1729 You should read this first: https://doc.qt.io/qt-5/signalsandslots.html void panelB::mouseMoveEvent(QMouseEvent *eventMove) { QString txt; txt = QString("(X:%1,Y:%2)").arg(eventMove->pos().x()).arg(eventMove->pos().y()); emit coordinatesChanged(eventMove->pos().x(), eventMove->pos().y()); //qDebug() << txt; } coordinatesChanged would be the signal.
    • UNSOLVED GUI freezing issue
      Mobile and Embedded • qthread gui c++ qt opencv serial interfac • • dev_512  

      3
      0
      Votes
      3
      Posts
      725
      Views

      @Gojir4 thanks, I am trying that right now. I’ve added a 1s delay in my image grabbing thread. Let’s see. Fingers crossed!
    • SOLVED How to add and access informations from dynamically created objects QT
      General and Desktop • c++ qtcreator c++ qt object • • frnklu20  

      37
      0
      Votes
      37
      Posts
      3022
      Views

      Hi You can use https://doc.qt.io/qt-5/qgraphicsitem.html#qgraphicsitem_cast and try cast to your child type if it really is, you can then use its members. so check for NULL and note the docs saying " reimplement the type() function"