Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.5k Topics 457.1k Posts
  • Connecting QApplication event with QMainWindow instance

    Solved
    3
    0 Votes
    3 Posts
    792 Views
    X
    @kenchan Reading the documentation you shared with me I found an easy solution adding this line inside the event() method of MyApplication: QApplication::sendEvent(mainWindow, event); Thanks!
  • This topic is deleted!

    Unsolved
    1
    0 Votes
    1 Posts
    32 Views
    No one has replied
  • Right way to avoid 100% cpu on main thread

    Unsolved
    2
    0 Votes
    2 Posts
    795 Views
    aha_1980A
    hi @trikko the correct way is to react to a signal in a slot instead of using wait loops (at least in main thread). what exactly are you waiting for?
  • qt::ascendingorder problem

    Unsolved
    2
    0 Votes
    2 Posts
    994 Views
    K
    @R4leY Hi and welcome to devnet forum The sorting is based on Latin-1 and the order is given here. That explains probably the ordering you currently see. As a solution you probably have to use a custom sort filter model. I am suggesting to have a close look to this example and try to run the example. Unfortunately I do have enough experience to help you right away. However, pleasedo not hesitate to raise questions in the forum when you have trouble to understand.
  • SVG animation in QSvgWidget - Working example?

    Unsolved
    5
    0 Votes
    5 Posts
    3k Views
    mrjjM
    Hi Oh yes, it seems so. \o/ All samples i could find, uses CSS and would not animate.
  • Raw audio sample from QAudioInput to .mp3 file

    Unsolved
    2
    0 Votes
    2 Posts
    1k Views
    A
    This should help you with the file format. From there you just write out the proper header for the sound bytes you have and write it to a file. https://en.wikipedia.org/wiki/MP3 I don't work with sound much in Qt so there may be an easier way but I looked at the Qt Multimedia classes like QAudioBuffer/QAudioFormat/etc and none of them looked like they could convert raw bytes to an mp3. So that means you will have to write a small class that takes raw bytes and makes mp3 packets out of it. With that file format and description in the wiki page you should have plenty of info to do it. You may also want to search the web for a class that can do it that someone else may have done and open sourced already.
  • This topic is deleted!

    Unsolved
    1
    -1 Votes
    1 Posts
    2 Views
    No one has replied
  • This topic is deleted!

    Unsolved
    1
    -1 Votes
    1 Posts
    2 Views
    No one has replied
  • This topic is deleted!

    Unsolved
    1
    -1 Votes
    1 Posts
    2 Views
    No one has replied
  • This topic is deleted!

    Unsolved
    1
    -1 Votes
    1 Posts
    2 Views
    No one has replied
  • This topic is deleted!

    Unsolved
    1
    -1 Votes
    1 Posts
    2 Views
    No one has replied
  • This topic is deleted!

    Unsolved
    1
    -1 Votes
    1 Posts
    5 Views
    No one has replied
  • Questions about Mac Deployment

    Unsolved
    4
    0 Votes
    4 Posts
    966 Views
    M
    Not sure, but it seems that CFBundleTypeIconFiles (with an s) is for IOS. CFBundleTypeIconFiles An array of strings containing the names of the image files to use for the document icon in iOS. For more information about specifying document icons, see Document Icons. see Recommended Keys for Cocoa Apps here: (core foundation) https://developer.apple.com/library/content/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html I experienced such issues too. The trouble is that usely they are multi instances of the same app (debug/release) and the finder can be confused with. Try to delete the multiple copies of your app and restart the computer. Hope it helps.
  • QAbstractItemModel item identification from ModelIndex

    Unsolved qmodelindex qtreeview
    4
    0 Votes
    4 Posts
    1k Views
    SGaistS
    Then you have to propagate the information when your underlying data changes.
  • Playing Wav over modem.

    Unsolved
    24
    0 Votes
    24 Posts
    6k Views
    A
    Where i am now... I put a timer to prevent the modem buffer from being saturated m_command = "AT+VTX;\r"; output = m_command.toStdString().c_str(); m_serial->write(output); m_serial->flush(); timer = new QTimer(this); connect(timer, SIGNAL(timeout()), this, SLOT(sendWave())); timer->start(Latence); The first bugg is the time it takes for the Hayes command to respond before sending a wave sample data to the modem. I don't know how to wait the answer. I think about a boolean to stop timer. But I saw the example talking about waitForReadyRead. I will not certain where i need to put this wait because of use connect(m_serial, &QSerialPort::readyRead, this, &MainWindow::readData); An idea. Thanks for reading.
  • Inserting and removing data with QXmlQuery

    2
    0 Votes
    2 Posts
    3k Views
    A
    Hello I had the same problem. It is looks like that Qt currently only supports "Minimal Conformance" and yet does not support optional XQuery features as it is described here: QXMLQuery Features and Conformance: XQuery 1.0 Qt XML Patterns aims at being a conformant XQuery processor. It adheres to Minimal Conformance and supports the Serialization Feature and the Full Axis Feature. Qt XML Patterns currently passes 97% of the tests in the XML Query Test Suite. Areas where conformance may be questionable and where behavior may be changed in future releases include: Some corner cases involving namespaces and element constructors are incorrect. XPath is a subset of XQuery and the implementation of Qt XML Patterns uses XPath 2.0 with XQuery 1.0. The specifications discusses conformance further: XQuery 1.0: An XML Query Language. W3C's XQuery testing effort can be of interest as well, XML Query Test Suite. Currently fn:collection() does not access any data set, and there is no API for providing data through the collection. As a result, evaluating fn:collection() returns the empty sequence. We intend to provide functionality for this in a future release of Qt. Only queries encoded in UTF-8 are supported. And here is the relation of XQuery update with "Minimal Conformance" So I guess this feature is not included in the current version of QXMLQuery Instead it is possible to use QDomDocument.
  • QXmlQuery update of attributes

    Unsolved
    2
    0 Votes
    2 Posts
    895 Views
    A
    Hello I had the same problem. It is looks like that Qt currently only supports "Minimal Conformance" and yet does not support optional XQuery features as it is described here: QXMLQuery Features and Conformance: XQuery 1.0 Qt XML Patterns aims at being a conformant XQuery processor. It adheres to Minimal Conformance and supports the Serialization Feature and the Full Axis Feature. Qt XML Patterns currently passes 97% of the tests in the XML Query Test Suite. Areas where conformance may be questionable and where behavior may be changed in future releases include: Some corner cases involving namespaces and element constructors are incorrect. XPath is a subset of XQuery and the implementation of Qt XML Patterns uses XPath 2.0 with XQuery 1.0. The specifications discusses conformance further: XQuery 1.0: An XML Query Language. W3C's XQuery testing effort can be of interest as well, XML Query Test Suite. Currently fn:collection() does not access any data set, and there is no API for providing data through the collection. As a result, evaluating fn:collection() returns the empty sequence. We intend to provide functionality for this in a future release of Qt. Only queries encoded in UTF-8 are supported. And here is the relation of XQuery update with "Minimal Conformance" So I guess this feature is not included in the current version of QXMLQuery Instead it is possible to use QDomDocument
  • Has anyone made scrollarea zoom with widget

    Solved
    7
    0 Votes
    7 Posts
    2k Views
    mrjjM
    @Prince_0912 Hi and welcome I you can place a QLabel on it and set its Pixmap property to an image.
  • model/view

    Unsolved
    26
    0 Votes
    26 Posts
    7k Views
    U
    should i user two different containers???
  • This topic is deleted!

    1
    0 Votes
    1 Posts
    19 Views
    No one has replied