Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.5k Topics 457.3k Posts
  • How to move the downloaded file to specified directory in Qt

    3
    0 Votes
    3 Posts
    4k Views
    X
    thank you for your advice,It works ! Thanks again!
  • Inserting row into QSqlQueryModel trough QDataWidgetMapper

    1
    0 Votes
    1 Posts
    3k Views
    No one has replied
  • How to kill a windows process if running from my Qt Application?

    5
    0 Votes
    5 Posts
    7k Views
    T
    You can use #ifdef Q_OS_WIN or something to mask out your windows code when not building on windows or put the OS specific code into separate files and have the build system sort out which object files to link together.
  • Unexpected behaviour in slot with Qt::DirectConnection

    31
    0 Votes
    31 Posts
    12k Views
    Z
    There is no automatic multi-threading mode for plugins and so it cannot be documented. What you are seeing is the direct and predictable result of the code you designed and implemented. Whether this was a conscious decision or an unexpected/unanticipated behaviour on your part does not matter. This is not a bug in Qt (either documentation or source). If you are still convinced that this is a bug in Qt then you will need to spend the time to make small compilable example that reproduces the issue. With this then we or the trolls can help you in fixing it or explaining the code paths that lead to the observed behaviour. Doing the above is often a valuable process anyway since by doing so you very often find the bug or the key to understanding the issue. Nobody is trying to accuse you of not understanding signals/slots/connections or multi-threading. Just that sometimes when used in conjunction these topics can lead to what seems like strange behaviour. I have been there myself many times ;-) Good luck with the rest of your project.
  • 0 Votes
    6 Posts
    6k Views
    P
    Thank you :) This code is working fine for me.
  • QTcpSocket with signal capability

    4
    0 Votes
    4 Posts
    3k Views
    A
    As a general rule: if you find that some method, signal, property... that you think should obviously be in a class isn't in the documentation for that class, you should either browse the documentation of the superclasses, or just click the "List of all members, including inherited members" link. There is a good chance you'll find what you are looking for in (abstract) base class.
  • MVC Architecture

    14
    0 Votes
    14 Posts
    9k Views
    M
    [quote author="iamcreasy" date="1308493651"]@sigrid "You might want to make this post sticky":http://developer.qt.nokia.com/forums/viewthread/6749/ There is no system of PM in this forum. I could send it you directly.[/quote] We seldom use stickies on this forum, mostly for procedural things or events while they happen. We don't have a PM system, but you can send e-mail to any member from their profile page.
  • Hiding rows in QTableView seems to be slow

    8
    0 Votes
    8 Posts
    10k Views
    S
    The procedure I described above works very well. Thanks a lot to Eddy and loladiro. Just one thing I would like to add is that instead of calling "invalidateFilter()" on the custom QSortFilterProxyModel, one should call "invalidate()" which is considerably faster. I don't know why... Steffen
  • Regarding Layout Management

    3
    0 Votes
    3 Posts
    2k Views
    L
    I don't think that's the problem. I always construct layouts that way, and have never had any problems. With Qt 3.x you could run into all kinds of problems if you didn't do things in the right order, but with Qt 4.x it tends to just work, regardless of the order in which you create things and put them in the layouts. I think the problem is with the arguments to addWidget. Looks like you are adding btnExport and table in exactly the same place, for example. And btnImport and btnExport are overlapping.
  • Align elements in QHBoxLayout

    4
    0 Votes
    4 Posts
    11k Views
    S
    Try to Align QToolBar vertically: @QHBoxLayout::addWidget(widget, int stretch, Qt::AlignVCenter)@
  • 0 Votes
    2 Posts
    2k Views
    A
    The low pitch problem and the different time needed to fill the buffer seems to indicate you are recording at a higher sample rate on MacOsX than on Windows. Did you check that the format was supported (like in "the example code from QAudioInput documentation":http://doc.trolltech.com/latest/qaudioinput.html#details), and that the "nearestFormat" returned the same sampleRate as the one you requested ?
  • Crash when trying to start KMyMoney with QT 4.7.3 debug version

    13
    0 Votes
    13 Posts
    5k Views
    M
    Sad, but thanks for all your efforts up to now. :-)
  • 0 Votes
    4 Posts
    4k Views
    L
    [quote author="Gerolf" date="1308505407"] An abstract method is a dummy code method which has no implementation. It is often used as a placeholder to be overridden later by a subclass of or an object prototyped from the one that implements the abstract method. In this way, abstract methods help to partially specify a framework. [/quote] Just wanted to add to that, that it is possible to actually implement pure virtual functions and then call them from the derived class (in which you still have to implement it though). So a function can be pure virtual, but not abstract. Another thing as to not confuse the OP, @ QRectF QGraphicsItem::boundingRect () const @ is pure virtual in QGraphicsItem and was just used as an example by Gerolf.
  • Update to a nighty or un-official version?

    9
    0 Votes
    9 Posts
    4k Views
    EddyE
    Glad you like it, but the stuff you are referring to is also accessible "on devnet ":http://developer.qt.nokia.com/resources
  • Socket local address and peer address

    4
    0 Votes
    4 Posts
    9k Views
    G
    The doc is quite clear about that: bq. "QAbstractSocket::localAddress() ":http://doc.qt.nokia.com/4.7/qabstractsocket.html#localAddress: Returns the host address of the local socket if available; otherwise returns QHostAddress::Null. bq. "QAbstractSocket::peerAddress() ":http://doc.qt.nokia.com/4.7/qabstractsocket.html#peerAddress: Returns the address of the connected peer if the socket is in ConnectedState; otherwise returns QHostAddress::Null. Peer in network context always means the other side of the connection (not necessarily remote - you can connect to your local machine too!). So you're right with your assumptions.
  • [Moved] excel puzzle in qt4

    10
    0 Votes
    10 Posts
    4k Views
    G
    That would be a good start :)
  • 0 Votes
    5 Posts
    2k Views
    M
    Nope, unfortunately the above did not solve this issue, as it turned out now. :-(
  • Stylesheet font-size not working with hover

    3
    0 Votes
    3 Posts
    5k Views
    G
    font-size also doesn't work. But I've now created a subclass of QPushButton were I hardcoded the change of the stylesheet in the enterEvent(). That works, the effort is just a little more. But thanks anyway
  • Handling setRestorable on Mac 10.7 Lion

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • [SOLVED] How to deploy QtMobility together with an application

    2
    0 Votes
    2 Posts
    2k Views
    U
    Ok, I solved the problem from reading the source code (this is the advantage of open source :O). In file qmediapluginloade.cpp I found the following lines: @ #ifdef QTM_PLUGIN_PATH // Mobility's plugin directory paths << QLatin1String(QTM_PLUGIN_PATH); #endif // Qt paths paths << QCoreApplication::libraryPaths(); @ The plugin loader searches in the QTM_PLUGIN_PATH C:\QtMobility\plugins and in the QCoreApplication library paths. These library paths also contain the path to the application binary. So I simply need to install the mediaservice plugin into myapp/mediaservice/. I tested this and it works.