Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
83.6k Topics 457.7k Posts
  • Qreal in QVariant

    13
    0 Votes
    13 Posts
    8k Views
    L
    If you really want any reasonable help you won't get around providing some real world code.
  • QT + DLL + LIB + MSVC + unresolved externals

    4
    0 Votes
    4 Posts
    3k Views
    B
    Ok, forget about the __inline. I have made a small solution with 3 projects. A c++ MFC project, a Qt project and a c++ dll project. Dll has a simple foo function exported with __declspecs(dllexport). lib shows that function. In dll project I have 2 headers one with the definition and one with the body. Now the MFC project copiles and link ok and calls foo. Qt project doesn't. I think I am doing something wrong. The Qt project was made in Qt creator, a simple project. I saved and moved all project dir in my Visual solution dir. I have imported the Qt proj using Qt addin than in project settings beside the Qt libs(core, gui etc) I have entered my lib. Also I am calling foo() in mainwindow class(in constructor) and added #include of the header with the definition of the function. Finally I have compiled but got unresolved externals.
  • QWizard Next, Back

    9
    0 Votes
    9 Posts
    9k Views
    X
    [quote author="Andre" date="1320941333"]No need to implement it, just do: @ emit completeChanged(); @ to notify connected objects (like QWizard) that the status (may) have changed. You never implement a slot; Qt does that for you.[/quote] Finally got it, after LOT of thinking: I did object only for the selectPage did a public variable called bool isDecided in my Parrent QWizard. When either buttons are pressed, parent->isDecided = true; emit completedChanged() like the following: @void SelectPage::gotoCreate() { parentW->isNew = true; emit completeChanged(); parentW->gotoCreate(); }@ Here is my code (partial) @NewDB::NewDB(QWidget *parent) : QWizard(parent) { setPage(Page_Intro, new IntroPage(this)); setPage(Page_Select, new SelectPage(this)); setPage(Page_After1, BlankPage()); } void NewDB::gotoCreate() { removePage(Page_After1); addPage(CreatePage()); next(); } SelectPage::SelectPage(NewDB *parent) : QWizardPage(parent) { parentW = parent; // Object NewDB ... parentW->isNew = false; // Button Actions connect(linkNew, SIGNAL(clicked()), this, SLOT(gotoCreate())); ... } void SelectPage::gotoCreate() { parentW->isNew = true; emit completeChanged(); parentW->gotoCreate(); } bool SelectPage::isComplete () const { if(parentW->isNew == true) { return true; } else { return false; } }@ Thanks a lot for the hint!
  • [Solved] gdb process crashed

    7
    0 Votes
    7 Posts
    5k Views
    B
    I've just report a bug (QTCREATORBUG-6516) with attachment debugger log file in text format. Waiting for your reply...
  • How to set Active Tab in DockWidget?

    5
    0 Votes
    5 Posts
    6k Views
    C
    Quote from docs ... bq. Two dock widgets may also be stacked on top of each other. A QTabBar is then used to select which of the widgets that should be displayed. Maybe if you find this tabbar pointer ... :-) (I don't know, maybe somebody else have the solution)
  • Phonon::VolumeSlider, How to change - adjust volume programmatically?

    3
    0 Votes
    3 Posts
    2k Views
    G
    You are right. Thanks Andre!!!
  • How to do directory browsing?

    5
    0 Votes
    5 Posts
    5k Views
    A
    [[doc:QFileDialog]] is not what you need?
  • Shared Library: Import and export simultaneously ?

    3
    0 Votes
    3 Posts
    3k Views
    D
    See http://doc.qt.nokia.com/stable/sharedlibrary.html for hints.
  • ComboBox Max Amount of Items?

    4
    0 Votes
    4 Posts
    3k Views
    F
    Not sure if you are reporting a problem or thinking about what could be a problem. On Linux it usually works with a scrollbar on the combo to scroll to other items. Some themes report a down arrow at the end of the combo to allow the user to scroll.
  • Mixing Qt3 and Qt4 core in an application

    3
    0 Votes
    3 Posts
    3k Views
    C
    Maybe this helps as well: "Possible: Program executing Qt3 and Qt4 code?":http://stackoverflow.com/questions/910230/possible-program-executing-qt3-and-qt4-code"
  • How to change the text color in QTableView

    3
    0 Votes
    3 Posts
    22k Views
    A
    Rajveer, are you using a QTableView this time, or are you really using a QTableModel as you were in your last questions? In the latter case, you should check out setting the Qt::ForeGroundRole on the cell you want to color. @ QTableWidgetItem* myItem; //set it to the item you want to manipulate myItem->setForeground(QColor::fromRgb(255,0,0)); //make this item red. @ If you really have your own model, then you need to return this color as a variant from your data() method, but I doubt you are doing that.
  • QGraphicsTextItem img path in html

    5
    0 Votes
    5 Posts
    3k Views
    R
    [quote author="fober" date="1320851449"]I've made additional tests and the behavior difference looks like a bug to me. Thus I'd like to: make a bug report. Any place to report? stop soliloquising :-) -- Dominique[/quote] For bug reports use "this":https://bugreports.qt.nokia.com [quote]soliloquising[/quote] -Is it Italian? Does it in English mean monologues sing- :-) ? P.S. Oh, google translate helps me, it's soliloquies sing :-) . Thank's for new word.
  • 0 Votes
    7 Posts
    16k Views
    A
    I get these errors every couple of days. My standard procedure (until it works) is: -) Run qmake -) Manually delete the obj files of the source modules I know need to be re-compiled, maybe also delete certain Makefiles (if I am in a multi-sub-project environment, and only want to rebuild one of those projects) -) Do a clean, manually delete any Makefiles, and rebuild Usually, deleting the corresponding obj file is enough. Edit: BTW, Windows XP here
  • When generally we need to use QMetaobject class?

    5
    0 Votes
    5 Posts
    4k Views
    A
    I use QMetaObject extensively to get information about an object's properties in a scheme to load and save objects to an XML structure. Thanks to that system, I can automatically generate XML key names from the property names, as well as the type. I can then read the XML, and automatically convert the contained strings to the correct type, and set them as a property. I the other direction, I read the properties, convert them to a locale-independent string, and write them to the XML. The scheme took a while to set up, but now adding a new object to the scheme is a breeze, and changes to name or type of an XML parameter happens in exactly one place. Thanks to QMetaEnum, I can even save enum value names, which makes the XML more user-readable.
  • Doubt in Screenshot Example Code

    7
    0 Votes
    7 Posts
    4k Views
    S
    @Andre, @Broadpeak, @Mkosim Thank You...
  • Application deployment

    8
    0 Votes
    8 Posts
    6k Views
    Z
    For my view, I used "InstallJammer":http://www.installjammer.com/ to make installer in windows & linux. It likes BitRock but it's opensource :) For Mac, I used .dmg files to deploy application. But one things to remember that, .dmg files are not writable media. It likes disc images.
  • [Solved] Starting a GUI program through Terminal with Arguments

    8
    0 Votes
    8 Posts
    6k Views
    G
    You're welcome. Mac behaves sometimes like an alien - it feels a bit strange at first, but one gets used to it :)
  • Qlocalserver & qlocalsocket server restart

    2
    0 Votes
    2 Posts
    3k Views
    S
    Here's a twist (maybe...) I'm wondering if it makes more sense start the server as a QProcess of the client. That way, it might be easier|better to monitor the server's state as well as control restarts. As I mentioned, I'm a newbie. Just starting out w/Qt and only a moderate c++ programming to begin with. So if I'm way off base, just let me know and go back and do some more research.
  • Make QTableWidget expand when dialog window size is changed

    5
    0 Votes
    5 Posts
    6k Views
    P
    although the widgets, buttons do change position and size with respect to the parent dialog window
  • Any meetings/trainings after QtDevDays 2011 at San Fransisco

    1
    0 Votes
    1 Posts
    2k Views
    No one has replied