Skip to content

C++ Gurus

The forum for all discussions in C++ land.
1.3k Topics 8.7k Posts
  • How to initialize QMultiMap with default values in a namespace

    3
    0 Votes
    3 Posts
    3k Views
    L
    Thanks for the quick reply.
  • [Moved] Wierd ISO C++ forbids delaration with no type error

    11
    0 Votes
    11 Posts
    9k Views
    P
    I moved the headers, and I found that the problem might lie in the classes. They reference some classes that also use winserialport.h and other classes. I think there might be a class that uses startpage so I changed the class name and the associated files and all is well. Now I ran accross another problem. But I will start a new post. I am not sure if it should be in QT or here in C++ I think it should go in QT as the error references a qt file. Thanks for your help.
  • [Solved] Load Fortran DLL (Microsoft Digital Visual Fortran)

    3
    0 Votes
    3 Posts
    5k Views
    A
    Hi Gerolf, Thanks a lot for help. I used dependency walker and found that DFORRT.DLL was missing. I copied this DLL to System 32 directory. Now I am able to load DLL and run function. thanks, Azghar
  • Pre allocation of memory

    18
    0 Votes
    18 Posts
    12k Views
    G
    But that only helps if you are deleting the objects. I think the intention was: using a QVector which is storing objects and using pointers on those objects. And there it definitly does not work.
  • [Moved] Include files

    4
    0 Votes
    4 Posts
    3k Views
    I
    For even faster (much) compilation, and some other nice side-effects (like binary compatibility for libraries) see the "d-ptr paradigm (Opaque pointer)":http://en.wikipedia.org/wiki/Opaque_pointer As far as the compilation speed goes - this way you can minimize the number of includes (a small speed boost) and you can change classes(1) without having chain reactions to recompile everything that uses them (big speed boost). -- (1) naturally, doesn't apply to all changes
  • [Moved/ANSWERED] STL::Map

    2
    0 Votes
    2 Posts
    3k Views
    B
    You can do this with map or multimap containers, or you can creat your own container if you know somethink about OOP and templates :) it is fun and when you end container you will be pround :) but faster way is use one of containers from STL
  • [ANSWERED] Include Files

    18
    0 Votes
    18 Posts
    11k Views
    W
    [quote author="Tobias Hunger" date="1294679366"]Wolf P.: You only use two compilers? You are lucky then![/quote] How many compilers do you use? BTW: this sounds like a suggestion for one of our next polls ;)
  • [ANSWERED] Operator Overloading with Pointers

    9
    0 Votes
    9 Posts
    11k Views
    P
    Sorry, if I wasn't clear. I made two suggestions to solve your problem and the longer i think about the first one the less I like my own solution. Because it would work in another way than the standard library and thus may confuse readers of your code. I as an user of your binary heap would expect that the implementations calls operator<(T, T) for all possible T in the same way.
  • The difference between Qwidget object and pointer

    20
    0 Votes
    20 Posts
    17k Views
    G
    Peppe, your right. I mixed up things from what I looked up in the sources some times ago. The layout only keeps book of the widgets it manages, but does not take ownership. But what's really important for the users: After the UI is set up, all parent-child relationships are correct. I really do like Qt :-)
  • .c file in project compiles but gives undefined reference

    6
    0 Votes
    6 Posts
    16k Views
    F
    Wooh! Kind of Holiday/Vacation presents all these posts, now that I came from vacation. Thank you all for the support