Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.7k Posts
  • Static OpenGL libraries don't work

    1
    0 Votes
    1 Posts
    3k Views
    No one has replied
  • StatusBar::showMessage causes max processor load - report bug/patch qt?

    7
    0 Votes
    7 Posts
    4k Views
    R
    [quote author="DerManu" date="1332520217"]There it is: https://bugreports.qt-project.org/browse/QTBUG-24948 Looked into getting a setup ready for contributing but they're certainly not interested in making it easy for new contributers, so I just posted the diff in the bugreport. Let's see what happens.[/quote] Actually, getting set up as a contributor is pretty simple, and there's lots of docs on the wiki at http://wiki.qt-project.org/ your diff in the bug tracker cannot be used since unlike the gerrit system used for contributions, it doesn't ensure you've agreed to the contributor agreement etc.
  • 2 bugs in QtextEdit?

    4
    0 Votes
    4 Posts
    2k Views
    S
    The bug report (https://bugreports.qt-project.org/browse/QTBUG-24973) contains more updated info about the bugs.
  • 0 Votes
    5 Posts
    3k Views
    M
    Using a layout or grid or table widget is independent of using a QSignalMapper. How you generate an id is up to you. You could just as easily manually number your QComboBoxes as (0..n)
  • QGraphicsItem child's type()

    2
    0 Votes
    2 Posts
    2k Views
    W
    Unfortunately, I've found that my hack won't work with Qt now, but the question about quality of this solution and about other possible solutions is still actual.
  • Destruction of container of QGlyphRuns fails

    6
    0 Votes
    6 Posts
    3k Views
    A
    I have found out that the problem is caused by use of "release" QT libraries in "debug" version of the project. After switching to the "debug" version the exception has gone.
  • QGraphicsSvgItem and mousePressEvent troubles

    3
    0 Votes
    3 Posts
    2k Views
    H
    I got it. Thanks
  • Item paint() on every re-call to addItem() to QGraphicsScene

    3
    0 Votes
    3 Posts
    2k Views
    S
    Thanks for the reply. My project involves drawing lines and nodes. And condition to be satisified is if line is open-ended, the ends shuld be marked by different color. If line is joined by other line it should be painted in other color. Hence, I need to have paint function called on every line draw so that I see if line is open-ended or not. But thanks anyways, cacheMode() worked!.
  • Implementing multi-selection in QTextEdit

    2
    0 Votes
    2 Posts
    2k Views
    _
    No ideas? It would be also fine to implement some mode in which it's possible to position the cursor at any point of the edit. I mean something like Borland Delphi's source code editor.
  • [Solved] QLineEdit input incorrectly uppercased

    4
    0 Votes
    4 Posts
    3k Views
    K
    No problem. I am glad that you have solved your problem. I have wondered what that could be. However, by asking for a small compilable example, I have expected already that you will find somehow your issue. That happens to most developers and for sure it had heppened to me as well. So, do not worry. You might want to mark your post with [Solved] in the title line.
  • CGAffineTransformInvert in Mac OS Qt 4.8.0

    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • [SOLVED] scope of signals/slots

    3
    0 Votes
    3 Posts
    2k Views
    L
    [quote author="planarian" date="1332729166"]What are the limitations on where a slot can be located in order for a signal to reach it? For example, can an object in an array signal other instances of its own class located in the same array? (I.e., the array cells are pointers to the objects).[/quote] There is no limitation. As long as both objects derive from QObject they can establish a connection, irregardless of their storage or thread affinity.
  • QStandardItem::setData takes too much time

    6
    0 Votes
    6 Posts
    5k Views
    M
    [quote author="DerManu" date="1332634658"]Does really the setData call take so long or is it the delay between the signal emission and slot execution due to the queued connection? You could test that with some timing debug output: @qDebug() << "start" << QDateTime::currentDateTime().toMSecsSinceEpoch(); item->setData(...) qDebug() << "stop" << QDateTime::currentDateTime().toMSecsSinceEpoch();@[/quote] Yes, to test it I called the setData function directly in the GUI thread, without using threads at all. I use QTime:start QTime:elapsed() to measure the time span.
  • QGraphicsView zooming with QSlider

    4
    0 Votes
    4 Posts
    5k Views
    ?
    [quote author="depecheSoul" date="1332708102"]Thank you Jake007. Hope someone will help me with QSlider. [/quote] Just use the code snippet from Jake007 and instead of zoom factor use the value from your slider, set the range for the slider to the amount of zooming in and out you want and you are done.
  • [WIP] Equivalent of QTabWidget with tabs on left and horizontal text

    2
    0 Votes
    2 Posts
    3k Views
    J
    Fixed a few issues but I'm still struggling at getting icons to be saved correctly. Anyone who want to help me?
  • Compilling with Xcode

    1
    0 Votes
    1 Posts
    938 Views
    No one has replied
  • Creating Dynamic GridLayout

    2
    0 Votes
    2 Posts
    6k Views
    D
    I have done this code this way. Hope it helps: @ int row=0; int numberOfButtons=0; while (numberOfButtons<=34) { for (int f2=0; f2<4; f2++) { numberOfButtons++; if (numberOfButtons>34) break; QPushButton *button=new QPushButton(); button->setText(QString::number(numberOfButtons)); glayout->addWidget(button, row, f2); } row++; } @
  • QThread - Why do threads wait one another to start running?

    2
    0 Votes
    2 Posts
    2k Views
    D
    Use the start() method to begin execution, not run() method. In this link you can find good tutorials about threads: http://www.voidrealms.com/tutorials.aspx?filter=qt
  • How can i compare 2 icons?

    4
    0 Votes
    4 Posts
    8k Views
    B
    First you have to make from QIcon to QPixmap (QIcon::pixmap(...)). After this you have to convert from QPixmap to QImage (QPixmap::toImage()). The real comparison at the end: @ bool ImageComp::pixelCompareImages( const QImage &a, const QImage &b ) { if( a.size() != b.size() ) return false; if( a.format() != b.format() ) return false; for( int x=0; x<a.width(); ++x ) for( int y=0; y<a.height(); ++y ) if( a.pixel(x,y) != b.pixel(x,y) ) return false; return true; } @
  • 2 questions about QTreeView

    4
    0 Votes
    4 Posts
    3k Views
    R
    Thank you for your help! It is work