Page 1 of 2
Display the value of a variable in tooltip on mouse-over
Posted: Thu Apr 26, 2007 4:55 pm
by DevilDog
It would be very helpful if we didn't have to go to the variable window to see the value of a variable.
We should have the ability much like VB has had since version 6.0 to view the value of a variable by placing the mouse over it and having it display in a tooltip.
It would be awesome if we could see the contents of a List in a "tree" format much like you see arrays in .Net. You place your mouse over the List or array and it displays in a tooltip the name of the List or array with a "+" sign next to it.
When you click the "+" sign it opens up and shows you the rows available, up to around 10 or 15 (you can scroll to see more). If the List or array is a single dimension, the value of each row is shown.
If the List or array has multiple dimensions, each row has a "+" sign next to it and you can click it and see additional "+" signs to open those elements, etc.
Posted: Thu Apr 26, 2007 5:25 pm
by milan1612
Isn't that a question for the "Purebasic Editor" Forum?

Posted: Thu Apr 26, 2007 5:42 pm
by DevilDog
I don't know. Isn't the debugger part of PureBasic?
Isn't this a Feature Requests and Wishlists for the entire product? Or is it compartmentalized?
Re: Display the value of a variable in tooltip on mouse-over
Posted: Wed Oct 31, 2007 1:37 pm
by PB
+1
Posted: Wed Oct 31, 2007 4:44 pm
by Psychophanta
+ another 1
Posted: Wed Oct 31, 2007 7:04 pm
by Thalius
hmmm this would make the IDE surely somewhat fatter - altho theres a debugger already in. Uhm well ok as long as jaPBe isnt broken *g*.
Not sure how you want to realize this "Tooltipness" for all platforms tho ...
Well nice feature if it doesent eat too much time away from bugfixing *G*.
But seriously whats wrong with the console debugger ?
Thalius
Posted: Wed Oct 31, 2007 9:13 pm
by PB
> whats wrong with the console debugger ?
Nothing, but if you've used this idea with VB you'll know how good it is.

Posted: Wed Oct 31, 2007 9:25 pm
by Thalius
i was kidding
on that note tho .. together with the step by step debugger ( maybe timeable ) a currentline mark with realtime variable view on mouse over sounds comfortable
Thalius
Posted: Wed Oct 31, 2007 10:00 pm
by Godai
+1 - Watching variables is very bad. You even have to select the function it's in. Much easier with the tooltip and would bring debugger up to par with pro C#/Java/C++ solutions. One of the largest weaknesses with these otherwise great basic implementations (Blitz, Pure etc.) is that the debugger is much worse than Visual C++/C# and Netbeans for instance.
This makes debugging slower/worse and leads to more bugs and less debugging

Posted: Wed Oct 31, 2007 11:22 pm
by freak
Looking up a variable value like this should not be too hard to implement.
I put it on my list for the 4.20 version.
Godai wrote:One of the largest weaknesses with these otherwise great basic implementations (Blitz, Pure etc.) is that the debugger is much worse than Visual C++/C# and Netbeans for instance.
This makes debugging slower/worse and leads to more bugs and less debugging

Bring on the ideas then. I want to know anything you are missing!
I must say i do not have that much experience with debuggers of other products,
so please enlighten me and i will see what can be done.
Debugging is the most annoying part of programming (next to docs writing maybe),
so it should be made as easy and comfortable as possible...

Posted: Wed Oct 31, 2007 11:41 pm
by Psychophanta
freak wrote:Debugging is the most annoying part of programming (next to docs writing maybe),
so it should be made as easy and comfortable as possible...
I am absolutely agree in that point.
Anyway, currently the PB debugger is nice enough.
But new ideas in order to make easier the debugging tasks would be awesome, over all if they are original (not viewed before in any other compiler)

Posted: Thu Nov 01, 2007 8:28 am
by Godai
Actually I think PB has one of the better debuggers

You should be able to add global watches as it is now, although it should automatically show the value for the current function the debugger is in and then just show ### or something when the variable is not in scope.
Also, it should automatically show values in scope for the current function (local variables). If you want to watch globals, you should add them yourself to keep the view unclogged.
That would make it almost or just as good as the legendary Visual C++ debugger

Posted: Thu Nov 01, 2007 4:14 pm
by DevilDog
Bring on the ideas then. I want to know anything you are missing!
I think overall the debugger is pretty good and would be awesome with the variable viewing feature in a tooltip which is being discussed.
Also, would it be possible to display the values of an array in the debugger when you place the mouse over the array name in a "tooltip" like this:
In the "tooltip" you would display the name of the array with a "+" next to it. Then when you click the "+" sign you could display the values of the array in a "tree" like fashion?
It's the way array values are displayed in .Net and it's very convenient and helpful in debugging.
Another cool feature to add:
In the debugger when stepping through the code if it's possible to click on the left border of the debugger (where the line numbers are shown) to mark a line you wish to stop on in place of using the F9 key would be great.
Thanks!
Posted: Thu Nov 01, 2007 4:47 pm
by freak
DevilDog wrote:In the debugger when stepping through the code if it's possible to click on the left border of the debugger (where the line numbers are shown) to mark a line you wish to stop on in place of using the F9 key would be great.
This is supposed to work already:
Holding down ALT while clicking places a breakpoint
Holding down CTRL while clicking places a jump marker
Its not working in the last beta though... i have to check out whats wrong there.
[Edit]
Actually, it is working, but not in the standalone debugger.
In the IDE, clicking on the margin with the folding marks etc (not the linenumbers)
while holding down ALT will place a breakpoint.
Posted: Fri Jan 18, 2008 9:04 am
by PB
Two suggestions for the tooltips for variables:
(1) Make the tooltip delay shorter (500ms?) because 1000ms is too long.
(2) Don't make it show the variable name or put quotes around the value.
Because there is only X amount of characters that it shows, and for long
strings I can't always see the whole amount because my variable name is
long and the tooltip is wasting lots of characters on displaying it. The user
has put the mouse over the name so we don't really need it in the tooltip.