Problem getting value of variable with debugger

  • Hi guys

    I come from programming with delphi, where the debugger gave me the value of variables when the mouse placed on them, but in some variables on QT, the rectangle shows me the value only a split second and it turns grey, as shown in the picture below.

    What is the problem?
    Thanks in advance!

  • Looks like a bug in Qt Creator. But there is an other option: on the right side there is a panel where you can browse your local variables. If I see it correctly then sequndos is a member variable. Open the this pointer in the panel, and you will find the value there.

    Older Qt Creators didn't even have this tooltip-like debug feature, they only had the side panel :)

  • Thanks for you reply, Gábor, but I don't find some variables on right side :(
    I made a video of my problem.

  • I see what you mean, it is indeed annoying. About the right side panel: there are some variables that I also don't see (horas, minutos, segundos), but from this context it is hard to tell where they belong. Are they local or member? Do they belong to a base class? Is there a base class at all?

    If nothing works there is still one more trick: right click on the right side panel, and choose "Add new expression evaluator .." and type the variable there.

  • horas, minutos, segundos was created on the header of .cpp file, and structs was created in other class and constructed on the header of main.
    However, your trick works fine!!!

    Thanks a lot!!

Log in to reply