Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.7k Posts
  • Difference between my code and testcon code

    3
    0 Votes
    3 Posts
    2k Views
    K
    ok but i copy my code from testcon example,i will wrote it here but you can't run it because it communicate with a fingerprint device you don't have it, the problem is on testcon it get me a correct integer input but in my program it is crashed
  • Qt Creator and Valgrind

    4
    0 Votes
    4 Posts
    4k Views
    T
    You can always "file a bug report":http://bugreports.qt.nokia.com/, giving information how to recreate the issue or at least what those external errors were. Then we might be able to fix them. Patches are of course also welcome on "codereview.qt-project.org":https://codereview.qt-project.org/.
  • Mousemove event

    7
    0 Votes
    7 Posts
    9k Views
    P
    I've reimplemented mouseMoveEvent and enabled mouseTracking. When none button is pressed my widget receivers mouseMoveEvent only when cursor is leaving the widget. Shouldn't it receive this event all the time when i move mouse and mouse cursor remains on the widget?
  • How do I prevent blitting on resize?

    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • [Solved] QSystemTrayIcon close without exit.

    2
    0 Votes
    2 Posts
    3k Views
    P
    Look at "quitOnLastWindowClosed property":http://doc.qt.nokia.com/latest/qapplication.html#quitOnLastWindowClosed-prop
  • [SOLVED]Disable shortcut

    2
    0 Votes
    2 Posts
    2k Views
    S
    Once again copy and paste bites me in the tail again.
  • Manager->get(....) is going into trans state and not coming back.

    7
    0 Votes
    7 Posts
    3k Views
    A
    I already gave you a hint. We can not help you debug your issue if you are not willing to take suggestions.
  • Can't receive tcp message when popping up a modal dialog?

    11
    0 Votes
    11 Posts
    10k Views
    A
    [quote author="Lukas Geyer" date="1319212513"]I guess you've meant necroposting ;-)[/quote] Shame Yes, I totally meant that. I have corrected the offending posting, and apologize if anyone was offended by it.
  • Application resizing

    3
    0 Votes
    3 Posts
    3k Views
    EddyE
    Have a look at "scalability in the docs":http://developer.qt.nokia.com/doc/qt-4.7/scalability.html.
  • [Solved] Direct3d (D3D10) Full Screen

    3
    0 Votes
    3 Posts
    3k Views
    H
    I think I have a full-screen solution for now. I'm going to use Qt::FramelessWindowHint and showMaximized() to display a full screen. This doesn't let me alt-enter to change modes but is good enough for me at the moment.
  • Size of PDF files generated with Qt

    5
    0 Votes
    5 Posts
    6k Views
    A
    You can't choose the compression options, they are hard-coded in the private class that generate the pdf. Since the JPEG plugin is found, you can't improve the PDF size on that point. You might have to find an external tool that can recompress the images in the pdf.
  • My ScoreBoard inherits QMainWindow()

    9
    0 Votes
    9 Posts
    5k Views
    R
    [quote author="mkoskim" date="1319202757"][quote author="RichardM198030" date="1319200911"] LOL, sorry, I confused ya, I meant, I have to make 1 QWidget *cw; and a 2Nd QWidget *mainWIdget? [/quote] No, one widget is enough. You place it to your main window. This is a wild guess, but what if you inherit your ScoreBoard from QWidget, and use just plain QMainWindow to show it? [code] class ScoreBoard : public QWidget { ... } ... main() { QMainWindow *mainwindow = new QMainWindow; mainwindow->setCentralWidget(new ScoreBoard); ... } [/code] [/quote] Just came with something different too.. I can keep my cw widget, make a mainwidget, add the layout to mainwidget, add the mainwidget to cw, and add cw to the ScoreBoard class, =).
  • Qt Mobility and QtMultimediaKit on Desktop

    2
    0 Votes
    2 Posts
    2k Views
    Q
    sample code of what am trying to do @QMediaPlayer *player = new QMediaPlayer(this); player->setMedia(QUrl::fromLocalFile(spath)); player->play();@
  • [Solved] QTableWidget - problem when editing multiple items

    2
    0 Votes
    2 Posts
    4k Views
    X
    The link below can help you: http://www.qtcentre.org/threads/45348-QTableWidget-problem-when-editing-multiple-items
  • Solaris x10 Getting Virtual IP

    2
    0 Votes
    2 Posts
    2k Views
    F
    What if you cann "allAddresses":http://developer.qt.nokia.com/doc/qt-4.7/qnetworkinterface.html#id-5d3766c1-dabd-426d-993a-c359798abfc9 ? If this works, then you have to call ip() on each result of allInterfaces to get (also) the virtual ip. By the way, I don't think is a c++ related post.
  • Resizing MDI subwindow?

    2
    0 Votes
    2 Posts
    4k Views
    G
    mdiArea->addSubWindow returns a QMdiSubwindow instance, so that's why you need to call resize on the parent (which is the sub window itself). You can keep the returned pointer and call resize on it directly.
  • QModelIndex invalid when returning from a dialog

    2
    0 Votes
    2 Posts
    2k Views
    F
    I think I get it: the problem seems to be that the qdatawidgetmapper::submit() method invalidates (?) the currentIndex or something alike. In fact the following piece of code works fine: @int modelIndex = widgetMapper->currentIndex(); retVal = widgetMapper->submit(); // emphasize the current record tableView->selectRow( modelIndex );@ while the following is not working: @ retVal = widgetMapper->submit(); // emphasize the current record ableView->selectRow( widgetMapper->currentIndex() ); @ The difference is that in the working code the current index of the qdatawidgetmapper is hold before the actual submit, so I guess the submit produces something on the widget mapper or the model itself that prevents the selection of such index. It is still not clear to me what really happens, can anybody explain better where the problem is?
  • Eventfilter crashes

    2
    0 Votes
    2 Posts
    3k Views
    G
    Of course it will crash. In line 24 and 29 you step into an infinite loop. You're calling the implementation of the eventFilter method of this class. You should call the base class' implementation: @ return QDialog::eventFilter(object, event); @ PS: eventFilter is not a slot! It's just an ordinary virtual public method.
  • How to throw cell click event of QTable Widget

    16
    0 Votes
    16 Posts
    19k Views
    G
    selectRow(0) is the slot to use. You could have found yourself very easily if you had scanned through the fine API documentation of [[Doc:QTableWidget]] and its base classes [[Doc:QTableView]] and [[Doc:QAbstractItemView]]. Finding that slot with a quick search in the browser is a no brainer.
  • How to Disable Maximise button of Main Window

    3
    0 Votes
    3 Posts
    5k Views
    I
    Hi Kitten Not working in fullscreen mode I m not even able to see titlebar.