Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.4k Topics 456.4k Posts
  • 0 Votes
    12 Posts
    14k Views
    G
    I see. Well in fact, I'm using both composition and aggregation, so QObjects as children might not really work for me... Thank you
  • QObject::connect question

    9
    0 Votes
    9 Posts
    8k Views
    C
    [quote author="Andre" date="1311919259"]That new syntax is not going to help anybody as long as it is not in any released Qt version.[/quote] Yes, but it's still a good way/article to learn Qt :D
  • [SOLVED] Erase tool

    12
    0 Votes
    12 Posts
    5k Views
    A
    Yep, this helps. As I was thinking system cursor can;t be resized. silver47, thanks for the help and code example.
  • QDataWidgetMapper && QSqlRelationalTableModel && QComboBox

    10
    0 Votes
    10 Posts
    7k Views
    P
    [quote author="Luca" date="1311879787"][quote author="pate" date="1311819665"]After addMapping to QComboBox,you should do this: @ QSqlTableModel *relationalModel = tableModel->relationModel(i); ui->menuComboBox->setModel(relationalModel); ui->menuComboBox->setModelColumn(relationalModel->fieldIndex("menu"); @ [/quote] What is "i" in : @ QSqlTableModel *relationalModel = tableModel->relationModel(i); @ ?[/quote] Sorry!It's the index of the field "menu". Here it should be @ QSqlTableModel *relationalModel = tableModel->relationModel(tableModel->fieldIndex("menu"));@
  • SOLVED: notch locations w/ QDial

    4
    0 Votes
    4 Posts
    2k Views
    M
    No problem! If that works for you, please edit your original post and add [Solved] to the beginning of the title. Thanks!
  • Reimplementing winEvent: getting stuck in API call

    20
    0 Votes
    20 Posts
    11k Views
    J
    I have changed the way I interface the COM object, and now with this code: @bool Bridge::winEvent(MSG *message, long *result) { if( message->message == WM_USER && message->hwnd == winId() ) { myQAxObject->dynamicCall("Play()"); return true; } // give the event to qt return false; }@ I get this error: "QAxBase: Error calling IDispatch member Play: Unknown error" While if I call myQAxObject->dynamicCall("Play()"); from anywhere else in my code it works.
  • Feature Request: Qt Examples of openCV

    10
    0 Votes
    10 Posts
    9k Views
    K
    How do I correctly ask for or propose this new feature, to add one or more openCV demos to Qt Creator so people will be able to use it in the next update? I appreciate all the advice and hope to get it done for my own use but I'm thinking other Qt users may be interested in working with the camera whether on an N900 or a laptop or desktop PC. Likewise if such a proven link existed, it would draw more openCV users to Qt. I'll look at the tutorials but I would like to know some of the real Qt developers have my back by being aware of this feature request and hopefully working on it. Thanks.
  • Problem with horizontal wheelEvent

    7
    0 Votes
    7 Posts
    5k Views
    S
    I received a new iMac, tried the program compiled for both Windows 7 and Mac OS X Lion and it worked perfectly with the magic mouse so it was a problem with my laptop, for some reason it doesn't work with its touchpad even if horizontal scroll works with other programs. If somebody experiences the same problem it's an Acer Aspire with a Synaptics touchpad.
  • [SOLVED] Help on QSplitter

    8
    0 Votes
    8 Posts
    9k Views
    EddyE
    You're welcome. Have fun Qt programming!
  • [Solved] Accessing QLineEdit in QDialog

    7
    0 Votes
    7 Posts
    10k Views
    K
    Thank you both for the responses. I have updated the code to keep all the internals of the dialog private, with public accessors if needed.
  • QTCreator on Windows compiling MS Win libraries

    4
    0 Votes
    4 Posts
    2k Views
    M
    Ah, yes. I missed the part where he said QtCreator on Windows. My deepest apologies.
  • [Solved] Qt always tries to use OpenGL ES2 under Win7 64-Bit

    12
    0 Votes
    12 Posts
    16k Views
    L
    [quote author="vochinin" date="1311861449"] Evrethyng is working. I'm new to that forum but I think thread creator should mark it as "solved". It seems topic starter had a little bit another problem. [/quote] Ah ok, you're not the thread-starter -- sorry my confusion ;)
  • Can't resize QSplitter's children after customization

    5
    0 Votes
    5 Posts
    3k Views
    M
    Hi... I am also facing similar problem...like this.. I have set the stylesheet of my QSplitter as @ parentsplitter->setStyleSheet("QSplitter { border-color: rgb(255, 0, 0); color: rgb(145, 145, 145); height: 5px;background-color: rgb(225,230,234); }"); @ But i can see only the background color of my QSplitter is getting changed, but i want to change my border color of QSplitter from my main window.. Please help me on this..
  • Changing the color of QTreeView's branches

    6
    0 Votes
    6 Posts
    9k Views
    B
    Thanks Andre and Eddy! I will set the image of the branch
  • 0 Votes
    4 Posts
    4k Views
    T
    That's how it is set in the constructor, and when printing the key, that's what also comes out for all calls to initialize: @QSharedMemory FGEDLinkMemory("FGEDLinkMemory");@ I call this init function in a dynamically linked shared library and I have to make sure that my shared memory is set up, so all other functions of the library first call the init method so they are surely attached to the memory. I now have a bool is_initialized that get's set and immediately exits the init function if it was already called once, but i think it shouldn't be necessary.(And every process runs through it anyway once since this bool is not shared) Maybe I am making just a dumb design mistake by doing things that way? I thought it was the easiest way to make sure all programs calling my DLL can just call functions and don't need to call some init_function first. It's easier for the programmer who uses my DLL I thought. Thanks for taking interest btw!
  • Static compilation licensing issues?

    Locked
    2
    0 Votes
    2 Posts
    2k Views
    A
    Please refer to one of the many discussions on that exist already.
  • Video playback on Windows and Mac

    3
    1 Votes
    3 Posts
    3k Views
    G
    Thank you for the post Chuck! Which codec would you suggest for mp4? (sorry if this is a very noob-ish question, I am very new to all things video related) I decided at this stage it is best to go with MultiMediaKit. I don't really want to invest the time into a library that is about to be deprecated, and MultiMediaKit doesn't involve as large a time investment as I first thought. I did some further testing with the divx codec and the code sample shown "here":http://doc.qt.nokia.com/qtmobility-1.1/qmediaplayer.html#details. For this test note that I have 2 windows XP computers setup with Qt. The short version of the test results is that the divx codec allows me to play .avi videos (this is verified against a computer without the divx codec and by a divx watermark that appears for the first few seconds of playback). However I still cannot play divx files using the MultiMediaKit. When I try to do so, I get an error "DirectShowPlayerService::doRender unresolved error code 80040218". I was unable to step through the code to find this error, but may try again later. The next experiment I would like to try is continually polling the backend for supported mimetypes while systematically installing new codecs. I am hoping to see a predictable increase in codec support. I am trying the following code: @ QStringList mimes = QMediaPlayer::supportedMimeTypes(); for (int i=0; i<mimes.count(); i++) ui->mimeList->addItem(mimes.at(i)); // mimeList is a combo box @ Unfortunately I never get any elements in the mimes QStringList. So I cannot run this test. Ultimately I would like to identify a video format that uses a nice safe codec. When the program runs, it will poll the end user's system to see if it supports that specific video format. If that format is not supported it will display a link instructing the user to install the correct codec. This would be easily done using the call: @ QtMultimediaKit::SupportEstimate QMediaPlayer::hasSupport ( const QString & mimeType, const QStringList & codecs, ... ) @ However, since the supportedMimeTypes call isn't working I really don't know what I would pass into this second call. Any suggestions on "safe" codecs I could use, or on what could be preventing the above code from working?
  • Osx environment variables

    5
    0 Votes
    5 Posts
    3k Views
    M
    Ah.. Just noticed the path values I am hoping to find are being set in my .bash_profile; I have should checked there first. Thanks.
  • Javascript inheritance in QT app

    1
    0 Votes
    1 Posts
    1k Views
    No one has replied
  • Starting and terminating processes needed by my application

    6
    0 Votes
    6 Posts
    3k Views
    L
    At the end, I came up with a solution which seems to work for the moment. The problem I suppose was related to the fact that the application was terminated before the mydestroy() method ended. This executes the method in the same thread and seems to work better: @QObject::connect(&a, SIGNAL(aboutToQuit()), ProcessHolder::getInstance(), SLOT(mydestroy()), Qt:DirectConnection);@