Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.9k Posts
  • Multiple Clients on QTcpServer

    8
    0 Votes
    8 Posts
    17k Views
    K
    It is depending on the number of of clients you have to serve. However, apparently, the number of clients is not high. Otherwise sending to all clients creates quite some overhead. I never used sender(), so I cannot comment. For disconnecting you could go through your list and check each socket for lost connection and remove, when necessary. However, when you are earmarking with the address or other means the signals as in the example I have provided in the post, you can get around these things.
  • 0 Votes
    6 Posts
    5k Views
    R
    you should add [SOLVED] to your thread title then
  • ItemView (QListView)

    8
    0 Votes
    8 Posts
    4k Views
    A
    Please take note that there are trade-offs with all of the possible approaches. QML isn't perfect either, but it might be enough for you. I cannot make that judgement for you.
  • How to write to database (MySQL)

    5
    0 Votes
    5 Posts
    3k Views
    C
    Just one little sidenote to the subject. I've recently went through the description of QSql classes and it says that the underlying database engine must support transactions to use rollBack() and commit() features. Most of them does, I just want to note it to anybody how reads the topic later. ;)
  • Problem with TextEdit

    18
    0 Votes
    18 Posts
    6k Views
    A
    You need to come up with an asyncronous design. A design that allows to return to the event loop after each time you add output to your text edit. If you just move the loop to another function, nothing has changed. Basically, instead of polling continuiously if there is new data to display, you need to switch to a design where either only poll at a specific interval, or much better, don't poll at all but react to a signal, event or interupt or something like that as the data actually comes in.
  • Doesn't see MSVC compile option in Qt creator.

    4
    0 Votes
    4 Posts
    2k Views
    S
    Thanks guys.Never mind.It was a stupid thing.I had to check MSVC 2010 checkbox in install dialog.It is just strange it is not marked by default .
  • Displaying help text when the mouse is over pushbutton and lineedit

    17
    0 Votes
    17 Posts
    35k Views
    R
    event() is called automatically whenever any event occurs(like a key or mouse-button press,mouse move, etc.)... you don't have to call it... what the code does is that on the toolButton press, it activates the What's This? mode, then, it overrides the cursor so that the red circle is not shown... the event() function checks to see if an event is a mouse-release event and the What's This? mode is active...if not, it simply passes it on to its parent for normal processing...otherwise, it restores the cursor to its normal form and then passes it on for normal processing... P.S. - you should change this: [quote author="raaghuu" date="1340706879"] @ myClass::onToolButtonClcked(...) //...this is the SLOT for the helpButton clicked() SIGNAL { setOverrideCursor(Qt::WhatsThisCursor); QWhatsThis::enterWhatsThisMode(); } @ [/quote] to this: @ myClass::onToolButtonClcked(...) //...this is the SLOT for the helpButton clicked() SIGNAL { QWhatsThis::enterWhatsThisMode(); setOverrideCursor(Qt::WhatsThisCursor); } @
  • Debugger for Windows Binaries

    5
    0 Votes
    5 Posts
    3k Views
    T
    [quote author="Tobias Hunger" date="1340738780"]Just ignore tucnak... gdb most likely does not even apply to your problem. So which Qt version are you using to build your project with? Check the Projects mode (bar on the left side), it should show the Qt version used. Which ABI is it using? Click on "Manage" and find the Qt version you are using in the dialog that will open and hover it to get the tool tip. Is the ABI mentioning "msvcSOMEVERSION" somewhere? If it does then you will indeed need cdb for debugging. If it says "mingw" then you will need gdb instead. Sorry, but C++ development on windows is a real mess. No idea what Microsoft is thinking. Once you are sure which debugger you actually need, please make sure that it is available. Prefer the gdb that we ship with Qt Creator to the one from mingw if you have any... ours is known to work, which we can unfortunately not claim for others. If you can start debugging an application even in spite of the messages and it is just breakpoints that are not hit: Did you build in debug mode? Release mode does not have the information needed to place breakpoints based on lines.[/quote] Sorry for wrong comment. I've thought that here was another problem. Now, I will read full thread before posting.
  • 1.1 - 1.1 != 0 ???

    12
    0 Votes
    12 Posts
    6k Views
    L
    Thank you for those interesting reads and sharing them here!
  • [QT-BUG FOUND] KDE QFileDialog under Gnome

    9
    0 Votes
    9 Posts
    3k Views
    T
    tucnak: Just ask them to file a bug report and tag this post with the idea and please don't send people of on fools errands like "prepend to your thread's title - [QT-BUG-FOUND]". That is no help to anybody.
  • Qt 4.8.2 sources went 404

    3
    0 Votes
    3 Posts
    2k Views
    K
    Oh, I figured out why it went 404, it was because of my HTTPS Everywhere extension. Apparently, the downloads don't work with https.
  • QSortProxyModel dynamicSortFilter Problem

    3
    0 Votes
    3 Posts
    5k Views
    N
    yep and in this order @ live_contacts_->setSourceModel(unsorted_contacts_.get()); live_contacts_->sort(0, Qt::AscendingOrder); live_contacts_->setDynamicSortFilter(true); @ Also once the dataChanged signal is emitted if i call invalidate() on the proxy model it behaves as expected after that.
  • How do I get a variable t display in a text edit window?

    17
    0 Votes
    17 Posts
    20k Views
    I
    Code is working well now ... I am branching out to put in a menu bar and make a combo box for my program that can pick which *.csv file to read! So far so good! I could not have done this effort with out you guys! Thanks! ironmantis7x
  • QKinecticScroller

    2
    0 Votes
    2 Posts
    1k Views
    A
    Please see "this":/forums/viewthread/18122/ post.
  • Crash on button press

    2
    0 Votes
    2 Posts
    1k Views
    A
    We can't do anything with that. We have no idea what happens in your application, and the crash you post does not contain any useful details. Sorry, no way to help you. Debug your application.
  • Why has javascriptcore not been updated

    8
    0 Votes
    8 Posts
    4k Views
    C
    Hello All, I was recently asked if I have found a resolution to this issue. The answer is kind of. When I was having the problems discussed I was using the compiler that came with openSUSE 11.4. I tried downloading the most recent g++ version and experience the same problems of random crashes. I then demoed the latest intel compiler. Interestingly I have not experience any problems like the one discussed in this ticket. Not sure if this has simply moved the problem somewhere else and I am not encountering it. I tried debugging QT several times to try and isolate what section of code where there might be a problem but every time it crashed it would point to the section of code previously mentioned or worse did not give me any back trace. Hope this helps. jeff
  • [SOLVED] Qt 4.8: Step into Qt's source code on Windows using MSVC

    8
    0 Votes
    8 Posts
    5k Views
    A
    Solved, see http://bit.ly/Opco9O
  • Set a width to a layout

    6
    0 Votes
    6 Posts
    12k Views
    R
    We're all here to learn from(and help) each other... :) Happy Coding..!
  • [SOLVED] Inserting a list of QWidgets into a QScrollArea

    5
    0 Votes
    5 Posts
    7k Views
    N
    Thanks a lot for your advice :)
  • Qt 4.8: Restoring from an initial Maximized state doesn't work (anymore?)

    3
    0 Votes
    3 Posts
    2k Views
    A
    Thanks Swatwork, it's 'nice' to see that I am not the only one experiencing this problem. FWIW, I have just created a bug report for it: https://bugreports.qt-project.org/browse/QTBUG-26322