Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: Léa Massiot on November 15, 2012, 09:22:15 pm

Title: Debugging - Watch - Keyboard shortcut
Post by: Léa Massiot on November 15, 2012, 09:22:15 pm
Hello and thank you for reading my post.

Every time I want to watch a new variable, I have to:
1) select the variable,
2) right-click,
3) scroll top,
4) click "Watch <variable_name>".

Is there any keyboard shortcut which would allow me  to:
1) select the variable I want to watch
2) and then compose the keyboard shortcut to have it watched?

Thank you for your help and best regards.
Title: Re: Debugging - Watch - Keyboard shortcut
Post by: Jenna on November 15, 2012, 09:33:25 pm
If you use a recent version of C::B you can select the variable you want to watch and drag it into the watches window.
Title: Re: Debugging - Watch - Keyboard shortcut
Post by: oBFusCATed on November 15, 2012, 09:35:05 pm
I'm adding it to my TODO. Thank you for the request.
Title: Re: Debugging - Watch - Keyboard shortcut
Post by: Léa Massiot on November 15, 2012, 09:40:59 pm
If you use a recent version of C::B you can select the variable you want to watch and drag it into the watches window.

Indeed, it works for me, thank you.

I'm adding it to my TODO. Thank you for the request.

:)

Thank you and best regards.
Title: Re: Debugging - Watch - Keyboard shortcut
Post by: cbuser2 on November 16, 2012, 03:19:01 pm
If you use a recent version of C::B you can select the variable you want to watch and drag it into the watches window.

Very quick and easy. This instruction should be added to the debug wiki(nightlies section).

Right now the wiki has:

Code
Click in the empty last row in the watches window, type the name of the variable (or full expression) and hit enter.

Which meant that I was doing a lot of typing of variable names in the watches window(up to 15 variables or more), and this was error-prone for long variable names. I couldn't find a way of auto-completing variable names in the watches window - I don't think that this is actually an option?
Title: Re: Debugging - Watch - Keyboard shortcut
Post by: cbuser2 on November 16, 2012, 03:20:18 pm
I'm adding it to my TODO. Thank you for the request.

Is this in your TODO list? :D

Code
The automatic inclusion of local variables and function arguments[in the Watches window] have not being reimplemented. Sorry about the inconvenience.
Title: Re: Debugging - Watch - Keyboard shortcut
Post by: oBFusCATed on November 16, 2012, 03:48:33 pm
Yes, but it is low priority :)