Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.7k Topics 458.1k Posts
  • How disable multiple selection in QTableWidget?

    2
    0 Votes
    2 Posts
    10k Views
    A
    Use setSelectionMode() to the mode you want. See the documentation for QAbstractItemModel for details (base class of QTableWidget).
  • Type casting in QtScript.

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied
  • [solved] Please help me understand QThread

    5
    0 Votes
    5 Posts
    3k Views
    A
    WOW... I feel so much better now. Thank you all! No more errors and I actually know how things work :)
  • [Split] Font color in QTextEdit

    3
    0 Votes
    3 Posts
    4k Views
    G
    I split off this question into it's own thread as it was completely unrelated to the previous discussion in the "old thread":http://developer.qt.nokia.com/forums/viewthread/4645 Please open a new thread in the correct forum if you have new questions, don't just reply in any old thread.
  • QT_NO_XRENDER

    2
    0 Votes
    2 Posts
    4k Views
    Z
    At a guess I would say defining that variable prevents Qt from using the XRender extension. ;-) The XRender extension allows certain graphic operations to be accelerated. However, actual driver support for XRender varies and often XRender still hits code paths that are not optimised/accelerated by hardware. I think that this was one of the reasons why Qt has concentrated on the raster graphicssystem as opposed to the X11 one recently. To try the raster graphics system, you can specify an option on the command line like this: @./myapp -graphicssystem raster@ This option can also be compiled into Qt as the default or enforced by the application itself via a call to QApplication::setGraphicsSystem( "raster" ).
  • Qt Modality Over Another Application?

    3
    0 Votes
    3 Posts
    2k Views
    G
    It is not possible to give memory from one process to another directly. The address spaces are separated. You can use some IPC mechanisms to communicate between them, but the resources stay in the process where they are.
  • How to make cells blinking in a QTableView

    4
    0 Votes
    4 Posts
    6k Views
    G
    If you have any further questions, just ask. It was a short shot, but it will work :-)
  • Pixel manipulation in QGraphicsView

    2
    0 Votes
    2 Posts
    2k Views
    H
    What's the recommended way? I'm not sure. Perhaps you could copy the framebuffer to a texture, manipulate that, and copy it back to the framebuffer.
  • Autosizing scrollable window

    8
    0 Votes
    8 Posts
    11k Views
    R
    Sorry, I guess I didn't understand at first, but you are correct. -Thanks The following worked: @MainWindow::MainWindow(QWidget parent) : QMainWindow(parent), ui(new Ui::MainWindow) { ui->setupUi(this); QScrollArea scrollArea = new QScrollArea(); this->setCentralWidget(scrollArea); //create the widget with elements that require scrolling to view QWidget* widget = new CustomWidget(); scrollArea->setWidget(widget); } @
  • WIDGET ERROR

    4
    0 Votes
    4 Posts
    2k Views
    W
    in your header you need to include the lines @namespace Ui { class dialogEmail; }@
  • Can work QPrinter in a thread?

    11
    0 Votes
    11 Posts
    6k Views
    G
    [quote author="webmaster.skelton" date="1302199366"]I believe that Volker is correct, aa QPrinter inherits from QPaintDevice, though I have not found anything that explicitly says it is always "thunked" back into the GUI thread. This may also be a stupid question, but when you call the thread you call it by using "start()" and not "run()" correct? As this will also cause strange behavior. [/quote] yes, i call it with "start()"...
  • QSqlTableModel - setFilter cannot be validated

    11
    0 Votes
    11 Posts
    8k Views
    A
    [quote author="harry" date="1302197599"]that's the first thing i did [/quote] Thanks!
  • 0 Votes
    3 Posts
    3k Views
    F
    Quick answer, it's fairly hard to understand your problem. Just as a reminder : slot is just a regular method, which can be magically called by framework when a signal connected to this slot is emitted. It's a convenient way in multithreaded environement to have cross-threads messaging. a signal is just (from the external) a way to notify (think broadcast) information linking the slot and the signal is done with a QObject static method (connect) if you want some help, you'll have to rephrase clearly what you're trying to do provide some code to analyze explain what you expect and what you observe
  • QSortFilterProxyModel - strange filtering behavior

    8
    0 Votes
    8 Posts
    6k Views
    H
    Well if they insist some more that's what I'll end up doing, but like you said it's not the best handling of a case: it feels like they're trying to give you a run around....
  • Problem with QUdpSocket

    14
    0 Votes
    14 Posts
    14k Views
    A
    The group of people working with Qt is obviously broader than well-versed unix programmers. I find it weird to talk about connections when you are dealing with a protocol that does not handle connections. I looked it up what it does in Unix. It seems that it does two things: set a default host address where data packages are send to limit receiving datagrams to only those from the host you "connected" to. The QUdpSocket documentation mentions neither, but seems to do something like 1) at least. What's more, it first states that UDP is connectionless, and then in the next paragraph, explains that you need to connect to use certain methods. Excuse me, but I find that weird and inconsistent, no matter what older Unix API may use the same kind of terminology.
  • A question about paintEvent function

    6
    0 Votes
    6 Posts
    8k Views
    G
    If you are neither on Windows nor on Mac OS X, you can try Qt::WA_PaintOutsidePaintEvent bq. From "QWidget":http://doc.qt.nokia.com/4.7/qwidget.html docs: Warning: When the paintdevice is a widget, QPainter can only be used inside a paintEvent() function or in a function called by paintEvent(); that is unless the Qt::WA_PaintOutsidePaintEvent widget attribute is set. On Mac OS X and Windows, you can only paint in a paintEvent() function regardless of this attribute's setting. bq. From "Qt namespace":http://doc.qt.nokia.com/4.7/qt.html docs: Qt::WA_PaintOutsidePaintEvent - Makes it possible to use QPainter to paint on the widget outside paintEvent(). This flag is not supported on Windows, Mac OS X or Embedded Linux. We recommend that you use it only when porting Qt 3 code to Qt 4.
  • C++ console application to Qt GUI

    7
    0 Votes
    7 Posts
    6k Views
    S
    I was thinking that when I did a bit of research but I have no idea how to implement this. I have only just started with programming (I have a php background) but I'm picking it up fairly quickly. Any resources I can read up on to get this sorted? I use visual studio 2010 express if that helps.
  • How to create a wireless temporary hot(AP) using QT?

    3
    0 Votes
    3 Posts
    2k Views
    A
    [quote author="fancy967" date="1302151626"]just like the function win7 built-in [/quote] Why would you assume that this is anywhere near the scope of Qt? An interface for such a thing: sure. But an actual access point requires you interact with your wifi hardware, which is outside of Qt's scope. That will require platform and probably hardware dependent code.
  • Error starting new project in Visual Studio2010

    4
    0 Votes
    4 Posts
    3k Views
    ZlatomirZ
    You only installed the VSAddin? If yes... that is not enough. You will need the Qt framework too, form "here":http://qt.nokia.com/downloads you can download: the SDK(uses MinGW compiler) //this will be the easiest way to start with Qt or the "source code":http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-4.7.2.zip or the Qt framework built with Visual Studio 2008 ( that won't work with Visual Studio 2010 - your applications will give run-time errors) Ok now if you really need Qt in Visual Studio 2010, you need to build Qt framework with VS2010, do achieve that you will need the Qt source code (see the link above) and then: un-zip the source code in a folder where you want to install Qt framework: lets say C:\Qt-4.7 start the Visual Studio cmd and navigate to C:\Qt-4.7 run configure with the desired options //see this "link":http://doc.qt.nokia.com/latest/configure-options.html for more information //wait for configure to finish... a couple of minutes run nmake //or nmake sub-src to build the framework and then nmake sub-tools to build the tools //takes 2-3 (maybe more) hours depending on your system configuration add a Qt version in the Addin menu (select the folder where you built Qt <C:\Qt-4.7> - it will have a qmake.exe ;) ) A more detailed version of what i said can be found "here":http://doc.qt.nokia.com/latest/install-win.html
  • [Moved] compile 32bit app on 64bit qt on snow leopard webkit problem

    13
    0 Votes
    13 Posts
    6k Views
    M
    ok, i've just created an html page locally with a video and it worked :) maybe on the example it was some js conflict. once more: thanks a lot Volker!